feat(ui): rename selection to focus and use AccentGreen for focus by default

This commit is contained in:
Keith Guerin
2026-02-28 23:31:51 -08:00
parent e90f2c1339
commit 990f0280f1
15 changed files with 50 additions and 53 deletions
@@ -25,7 +25,7 @@ describe('ColorsDisplay', () => {
primary: '#000000',
message: '#111111',
input: '#222222',
selection: '#333333',
focus: '#333333',
diff: {
added: '#003300',
removed: '#330000',
@@ -42,7 +42,7 @@ const COLOR_DESCRIPTIONS: Record<string, string> = {
'background.primary': 'Main terminal background color',
'background.message': 'Subtle background for message blocks',
'background.input': 'Background for the input prompt',
'background.selection': 'Background highlight for selected/focused items',
'background.focus': 'Background highlight for selected/focused items',
'background.diff.added': 'Background for added lines in diffs',
'background.diff.removed': 'Background for removed lines in diffs',
'border.default': 'Standard border color',
@@ -98,7 +98,7 @@ describe('<Header />', () => {
primary: '',
message: '',
input: '',
selection: '',
focus: '',
diff: { added: '', removed: '' },
},
border: {
@@ -486,7 +486,7 @@ const SessionItem = ({
return (
<Box
flexDirection="row"
backgroundColor={isActive ? theme.background.selection : undefined}
backgroundColor={isActive ? theme.background.focus : undefined}
>
<Text color={textColor()} dimColor={isDisabled}>
{prefix}
@@ -100,7 +100,7 @@ export function SuggestionsDisplay({
<Box
key={`${suggestion.value}-${originalIndex}`}
flexDirection="row"
backgroundColor={isActive ? theme.background.selection : undefined}
backgroundColor={isActive ? theme.background.focus : undefined}
>
<Box
{...(mode === 'slash'
@@ -39,7 +39,7 @@ exports[`Initial Theme Selection > should default to a dark theme when terminal
│ │ #313… backgroun Background for the input │ │
│ │ d.input prompt │ │
│ │ #39… background. Background highlight for │ │
│ │ selection selected/focused items │ │
│ │ focus selected/focused items │ │
│ │ #283… backgrou Background for added lines │ │
│ │ nd.diff. in diffs │ │
│ │ added │ │
@@ -67,8 +67,8 @@ exports[`Initial Theme Selection > should default to a dark theme when terminal
│ │ B and UI icons │ │
│ │ #3d3f5 ui.dark Deeply dimmed color for │ │
│ │ 1 subtle UI elements │ │
│ │ #89B4F ui.focus Color for focused or │ │
│ │ A selected UI elements (e.g. │ │
│ │ #A6E3A ui.focus Color for focused or │ │
│ │ 1 selected UI elements (e.g. │ │
│ │ menu items) │ │
│ │ #F38BA8status.err Color for error messages │ │
│ │ or and critical status │ │
@@ -126,7 +126,7 @@ exports[`Initial Theme Selection > should default to a light theme when terminal
│ │ #e2e… backgroun Background for the input │ │
│ │ d.input prompt │ │
│ │ #d4… background. Background highlight for │ │
│ │ selection selected/focused items │ │
│ │ focus selected/focused items │ │
│ │ #C6E… backgrou Background for added lines │ │
│ │ nd.diff. in diffs │ │
│ │ added │ │
@@ -154,8 +154,8 @@ exports[`Initial Theme Selection > should default to a light theme when terminal
│ │ 4 and UI icons │ │
│ │ #d2d6d ui.dark Deeply dimmed color for │ │
│ │ c subtle UI elements │ │
│ │ #3B82F ui.focus Color for focused or │ │
│ │ 6 selected UI elements (e.g. │ │
│ │ #3CA84 ui.focus Color for focused or │ │
│ │ B selected UI elements (e.g. │ │
│ │ menu items) │ │
│ │ #DD4C4Cstatus.err Color for error messages │ │
│ │ or and critical status │ │
@@ -213,7 +213,7 @@ exports[`Initial Theme Selection > should use the theme from settings even if te
│ │ #313… backgroun Background for the input │ │
│ │ d.input prompt │ │
│ │ #39… background. Background highlight for │ │
│ │ selection selected/focused items │ │
│ │ focus selected/focused items │ │
│ │ #283… backgrou Background for added lines │ │
│ │ nd.diff. in diffs │ │
│ │ added │ │
@@ -241,8 +241,8 @@ exports[`Initial Theme Selection > should use the theme from settings even if te
│ │ B and UI icons │ │
│ │ #3d3f5 ui.dark Deeply dimmed color for │ │
│ │ 1 subtle UI elements │ │
│ │ #89B4F ui.focus Color for focused or │ │
│ │ A selected UI elements (e.g. │ │
│ │ #A6E3A ui.focus Color for focused or │ │
│ │ 1 selected UI elements (e.g. │ │
│ │ menu items) │ │
│ │ #F38BA8status.err Color for error messages │ │
│ │ or and critical status │ │
@@ -313,6 +313,8 @@ exports[`ThemeDialog Snapshots > should render correctly in theme selection mode
│ │ d.message message blocks │ │
│ │ #313… backgroun Background for the input │ │
│ │ d.input prompt │ │
│ │ #39… background. Background highlight for │ │
│ │ focus selected/focused items │ │
│ │ #283… backgrou Background for added lines │ │
│ │ nd.diff. in diffs │ │
│ │ added │ │
@@ -340,8 +342,8 @@ exports[`ThemeDialog Snapshots > should render correctly in theme selection mode
│ │ 6 and UI icons │ │
│ │ #3d3f5 ui.dark Deeply dimmed color for │ │
│ │ 1 subtle UI elements │ │
│ │ #89B4F ui.focus Color for focused or │ │
│ │ A selected UI elements (e.g. │ │
│ │ #A6E3A ui.focus Color for focused or │ │
│ │ 1 selected UI elements (e.g. │ │
│ │ menu items) │ │
│ │ #F38BA8status.err Color for error messages │ │
│ │ or and critical status │ │
@@ -140,9 +140,7 @@ export function BaseSelectionList<
<Box
key={item.key}
alignItems="flex-start"
backgroundColor={
isSelected ? theme.background.selection : undefined
}
backgroundColor={isSelected ? theme.background.focus : undefined}
>
{/* Radio button indicator */}
<Box minWidth={2} flexShrink={0}>
@@ -519,7 +519,7 @@ export function BaseSettingsDialog({
flexDirection="row"
alignItems="flex-start"
backgroundColor={
isActive ? theme.background.selection : undefined
isActive ? theme.background.focus : undefined
}
>
<Box minWidth={2} flexShrink={0}>