Skip to content

Commit b19c233

Browse files
fix(session-tab): tint active session's SHA strip to match status color (#2)
When multiple sessions share the same status color (e.g. four open PRs all tinted green), the active tab was visually indistinguishable. Extend the active tab's tint into the SHA/PR detail strip below it so the active session reads as one continuous block. Also restore the default new-repo layout's right-pane run command to `bin/setup && bin/launch --neetly`. Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent a77ddfe commit b19c233

2 files changed

Lines changed: 17 additions & 4 deletions

File tree

Sources/NeetlyApp/SessionWindowController.swift

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -159,6 +159,7 @@ class SessionTabBar: NSView {
159159
private var tabViews: [NSView] = []
160160
private var detailViews: [NSView] = []
161161
private let plusButton = NSButton()
162+
private var activeStatusColor: NSColor?
162163
private static let tabRowHeight: CGFloat = 40
163164
static let detailRowHeight: CGFloat = 33
164165

@@ -218,7 +219,13 @@ class SessionTabBar: NSView {
218219
addSubview(plusButton)
219220

220221
// -- Detail row (full width, for active session's SHA + PR) --
221-
guard let active = sessions.first(where: { $0.isActive }) else { return }
222+
guard let active = sessions.first(where: { $0.isActive }) else {
223+
activeStatusColor = nil
224+
needsDisplay = true
225+
return
226+
}
227+
activeStatusColor = active.statusColor
228+
needsDisplay = true
222229

223230
let detailFont = NSFont.monospacedSystemFont(ofSize: 14, weight: .regular)
224231
let detailBoldFont = NSFont.monospacedDigitSystemFont(ofSize: 14, weight: .medium)
@@ -333,8 +340,14 @@ class SessionTabBar: NSView {
333340

334341
override func draw(_ dirtyRect: NSRect) {
335342
super.draw(dirtyRect)
336-
// Detail row background — same color as active tab
337-
Self.activeTabColor.setFill()
343+
// Detail row background — same color as active tab. When the active
344+
// tab carries a status color, match it (with the same alpha the tab
345+
// uses) so the strip visually merges with the active tab.
346+
if let color = activeStatusColor {
347+
color.withAlphaComponent(0.45).setFill()
348+
} else {
349+
Self.activeTabColor.setFill()
350+
}
338351
NSRect(x: 0, y: 1, width: bounds.width, height: Self.detailRowHeight - 1).fill()
339352
// Bottom border
340353
NSColor.separatorColor.setFill()

Sources/NeetlyApp/SetupView.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -283,7 +283,7 @@ struct AddRepoScreen: View {
283283
size: 40%
284284
run: claude --dangerously-skip-permissions
285285
right:
286-
run: bin/setup-mise && bin/launch --neetly
286+
run: bin/setup && bin/launch --neetly
287287
"""
288288
@State private var pullMain: Bool = true
289289
@State private var errorMessage: String?

0 commit comments

Comments
 (0)