hyper-windowtint 0.3.1 → 0.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/index.js +43 -4
  3. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -5,6 +5,14 @@ All notable changes to `hyper-windowtint` will be documented here.
5
5
  The format follows [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [0.3.2] - 2026-05-16
9
+
10
+ ### Added
11
+ - Colored side stripes on each tab. Each tab now renders a 3–4px full-height
12
+ bar on its left and right edge in the tab's project color, so the boundary
13
+ between two tabs visibly shows both projects' colors. Tab colors are now
14
+ legible at a glance without making a tab active.
15
+
8
16
  ## [0.3.1] - 2026-05-16
9
17
 
10
18
  ### Fixed
package/index.js CHANGED
@@ -607,7 +607,42 @@ exports.decorateTab = (Tab, { React }) => {
607
607
  render() {
608
608
  const uid = this.props.windowTintUid;
609
609
  const color = this.props.windowTintColor || null;
610
- const accent = React.createElement('span', {
610
+ const hex = color ? color.hex : 'transparent';
611
+ const baseOpacity = color ? (this.props.isActive ? 1 : 0.7) : 0;
612
+
613
+ // Left- and right-edge stripes — full tab height, project color. Two
614
+ // adjacent tabs put their stripes back-to-back at the boundary, so the
615
+ // separator visually shows both projects' colors. The first tab's left
616
+ // edge is often hidden under macOS traffic lights, so doing both sides
617
+ // means the color is always visible somewhere on every tab.
618
+ const stripeStyle = (side) => ({
619
+ position: 'absolute',
620
+ [side]: 0,
621
+ top: 0,
622
+ bottom: 0,
623
+ width: this.props.isActive ? 4 : 3,
624
+ background: hex,
625
+ opacity: color ? 1 : 0,
626
+ boxShadow: color ? `0 0 8px ${withAlpha(color.hex, '44')}` : 'none',
627
+ pointerEvents: 'none',
628
+ transition: 'background 0.2s ease, opacity 0.2s ease, width 0.2s ease, box-shadow 0.2s ease',
629
+ });
630
+ const sideAccentLeft = React.createElement('span', {
631
+ key: 'windowtint-side-left',
632
+ className: 'windowtint_tabAccentSide windowtint_tabAccentSideLeft',
633
+ 'data-windowtint-uid': uid,
634
+ style: stripeStyle('left'),
635
+ });
636
+ const sideAccentRight = React.createElement('span', {
637
+ key: 'windowtint-side-right',
638
+ className: 'windowtint_tabAccentSide windowtint_tabAccentSideRight',
639
+ 'data-windowtint-uid': uid,
640
+ style: stripeStyle('right'),
641
+ });
642
+
643
+ // Bottom accent — kept for the soft glow under the active tab.
644
+ const bottomAccent = React.createElement('span', {
645
+ key: 'windowtint-bottom',
611
646
  className: 'windowtint_tabAccent',
612
647
  'data-windowtint-uid': uid,
613
648
  style: {
@@ -616,15 +651,19 @@ exports.decorateTab = (Tab, { React }) => {
616
651
  right: 0,
617
652
  bottom: 0,
618
653
  height: this.props.isActive ? 3 : 2,
619
- background: color ? color.hex : 'transparent',
654
+ background: hex,
620
655
  boxShadow: color ? `0 0 12px ${withAlpha(color.hex, '66')}` : 'none',
621
- opacity: color ? (this.props.isActive ? 1 : 0.65) : 0,
656
+ opacity: baseOpacity,
622
657
  pointerEvents: 'none',
623
658
  transition: 'background 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease, height 0.2s ease',
624
659
  },
625
660
  });
661
+
626
662
  const existing = this.props.customChildrenBefore;
627
- const customChildrenBefore = existing ? [accent].concat(existing) : accent;
663
+ const accents = [sideAccentLeft, sideAccentRight, bottomAccent];
664
+ const customChildrenBefore = existing
665
+ ? accents.concat(Array.isArray(existing) ? existing : [existing])
666
+ : accents;
628
667
  return React.createElement(Tab, Object.assign({}, this.props, { customChildrenBefore }));
629
668
  }
630
669
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hyper-windowtint",
3
- "version": "0.3.1",
3
+ "version": "0.3.2",
4
4
  "description": "Give Hyper terminal tabs distinct color tints, matching tabs from the same project during the current Hyper session.",
5
5
  "main": "index.js",
6
6
  "files": [