Skip to content

feat: tab colors in the glass tab bar, keep color on split, test restore - #372

Merged
arzafran merged 5 commits into
mainfrom
feat/tab-color-and-sidebar-menu
Sep 29, 2026
Merged

arzafran merged 5 commits into
mainfrom
feat/tab-color-and-sidebar-menu

Conversation

@arzafran

@arzafran arzafran commented Sep 29, 2026 •

Copy link
Copy Markdown
Member

What this does

Pane tab colors already shipped on main (#367). This fills the gaps that change left:

  1. The glass tab bar (macOS 26, opt-in) now shows tab colors and has the Tab Color menu. Before, colors only appeared in the default tab bar.
  2. Splitting a pane with a tab keeps the tab's color. TabItem.init(from: Tab) replaces three hand-copied mappings in BonsplitController, so new fields can't be dropped again.
  3. A test checks that a tab color survives a session save and restore at the Workspace level.
  4. CONTRIBUTING no longer mentions a homebrew-programa submodule, and says setup needs the exact zig version from scripts/required-zig-version.sh.

Test plan

  • CI green, including the new restore test in WorkspaceUnitTests
  • Glass tab bar on: right-click a pane tab, pick a color, the tint shows; Clear removes it
  • Split a colored tab into a new pane: the color stays

@darkestdarky-bot darkestdarky-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This diff adds per-tab color persistence and menu integration, plus sidebar context menu stabilization and CI permission scoping. The permission changes are minimal and safe. The tab color plumbing touches session snapshots, bonsplit delegates, and both native tab bar implementations. The sidebar menu tracking uses process-wide NSMenu notifications with depth counting, which raises concerns about global state and notification lifetime. The native menu builder has a potential issue with NSMenuItem target lifetime that should be verified.

Review coverage: 500/1678 diff lines supplied. Partial input (truncated: diff, standards). Inline comments are limited to fully visible, valid right-side hunks. Reviewed commit: b5119bd9d5682626c711c913860108f7bb1f5cd5.

Comment thread Sources/TabItemView.swift Resolved
Comment thread Sources/WindowPaneChromePortal.swift Resolved
Comment thread Sources/TabManager.swift Resolved
Comment thread Sources/WindowPaneChromePortal.swift Resolved
Comment thread Sources/SessionPersistence.swift Resolved
Comment thread Sources/TabItemView.swift Resolved
@arzafran
arzafran force-pushed the feat/tab-color-and-sidebar-menu branch from b5119bd to dfe66f5 Compare September 29, 2026 18:04
@arzafran arzafran changed the title feat: per-tab colors, plus sidebar menu and CI token fixes feat: tab colors in the glass tab bar, keep color on split, test restore Sep 29, 2026

@darkestdarky-bot darkestdarky-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Blocking: 0

  • The new @​MainActor test constructs Workspace and calls restoreSessionSnapshot without visible setup for panel/surface state. If Workspace initialization or restore requires additional configuration, the test may be fragile, but no failure evidence is visible in the diff.

Review coverage: 188/188 diff lines supplied. 4 lockfile, generated or vendored files left out. Partial input (truncated: standards). Inline comments are limited to fully visible, valid right-side hunks. Reviewed commit: dfe66f5a954e1096ad10b7a143e29b9804fba789.

@darkestdarky-bot darkestdarky-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Blocking: 0

Reviewed visible changes to WindowPaneChromePortal.swift, WorkspaceUnitTests.swift, and CONTRIBUTING.md. The diff adds tab color handling to the native glass tab bar and context menu, replaces an unsafe force cast with a checked cast, and adds a workspace-level restore test while retaining the legacy missing-key decode test. No P0 or P1 findings are visible in the supplied diff.

Review coverage: 188/188 diff lines supplied. 4 lockfile, generated or vendored files left out. Partial input (truncated: standards). Inline comments are limited to fully visible, valid right-side hunks. Reviewed commit: 6a617b7702ede1640346040b42b253cc8cfbb797.

@arzafran

Copy link
Copy Markdown
Member Author

darky/review is red only because it skips vendored files, so it didn't see the 4 bonsplit files (TabItem.swift, PaneContainerView.swift, BonsplitController.swift, BonsplitPaneChromePortalBridge.swift). I reviewed that 65-line diff by hand:

  • TabItem(from:) carries every field, including customColorHex, and replaces the two hand-copied mappings in BonsplitController.
  • The new Tab Color submenu strings exist in both en and ja.
  • The glass tab bar handles the new submenu and tabColor menu cases.
  • The new descriptor parameters have defaults, so existing callers compile.

Nothing to fix. Its latest review of 6a617b7 found no blocking issues.

@arzafran
arzafran force-pushed the feat/tab-color-and-sidebar-menu branch from 6a617b7 to 46fc314 Compare September 29, 2026 19:33

@darkestdarky-bot darkestdarky-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Blocking: 0

Reviewed the diff for tab color support in the glass tab bar, split restoration, and session restore tests. No P0 or P1 issues were identified in the visible changes.

Review coverage: 188/188 diff lines supplied. 4 lockfile, generated or vendored files left out. Partial input (truncated: standards). Inline comments are limited to fully visible, valid right-side hunks. Reviewed commit: 46fc31434e6a10c9b2c71b641873e898f1220b14.

@arzafran
arzafran force-pushed the feat/tab-color-and-sidebar-menu branch from 46fc314 to 1c33723 Compare September 29, 2026 19:46

@darkestdarky-bot darkestdarky-bot Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Blocking: 0

The change wires tab colors through the glass tab bar, adds a shared TabItem.init(from:) conversion so split preserves color, and adds a workspace-level restore test. The SwiftUI/native menu plumbing is consistent with the existing context-menu pattern, and the removed test changes appear to replace rather than weaken coverage. No P0 or clear P1 findings are visible in the diff.

Review coverage: 387/387 diff lines supplied. Partial input (truncated: standards). Inline comments are limited to fully visible, valid right-side hunks. Reviewed commit: 1c3372358c2715b33d183d20e8c01a62131416a2.

@arzafran
arzafran merged commit 5ca2589 into main Sep 29, 2026
15 checks passed
@arzafran
arzafran deleted the feat/tab-color-and-sidebar-menu branch September 30, 2026 13:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant