Skip to content

Commit 298129e

Browse files
committed
fix: Address CodeRabbit review comments
- Remove dead theme:toggleSyntaxHighlighting keybinding (Ctrl+T) - Remove unused stalledIntensity prop from Spinner components - Fix markdown inline code color for all dark theme variants - Add BRAND_COLOR_LIGHT for shimmer effects - Fix daltonized themes to use colorblind-friendly palette - Fix hover colors to have visible contrast
1 parent 85b148e commit 298129e

5 files changed

Lines changed: 16 additions & 19 deletions

File tree

src/components/Spinner/SpinnerAnimationRow.tsx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -334,7 +334,6 @@ export function SpinnerAnimationRow({
334334
<SpinnerGlyph
335335
frame={frame}
336336
messageColor={messageColor}
337-
stalledIntensity={overrideColor ? 0 : stalledIntensity}
338337
reducedMotion={reducedMotion}
339338
time={time}
340339
/>
@@ -345,7 +344,6 @@ export function SpinnerAnimationRow({
345344
glimmerIndex={glimmerIndex}
346345
flashOpacity={flashOpacity}
347346
shimmerColor={shimmerColor}
348-
stalledIntensity={overrideColor ? 0 : stalledIntensity}
349347
/>
350348
{status}
351349
</Box>

src/keybindings/defaultBindings.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,6 @@ export const DEFAULT_BINDINGS: KeybindingBlock[] = [
189189
{
190190
context: 'ThemePicker',
191191
bindings: {
192-
'ctrl+t': 'theme:toggleSyntaxHighlighting',
193192
},
194193
},
195194
{

src/keybindings/schema.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -120,7 +120,6 @@ export const KEYBINDING_ACTIONS = [
120120
// Task/agent actions
121121
'task:background',
122122
// Theme picker actions
123-
'theme:toggleSyntaxHighlighting',
124123
// Help menu actions
125124
'help:dismiss',
126125
// Attachment navigation (select dialog image attachments)

src/utils/markdown.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,7 +87,7 @@ export function formatToken(
8787
}
8888
case 'codespan': {
8989
// inline code
90-
return color(theme === 'dark' ? '#FEC84A' : 'permission', theme)(
90+
return color(theme?.startsWith('dark') ? '#FEC84A' : 'permission', theme)(
9191
token.text,
9292
)
9393
}

src/utils/theme.ts

Lines changed: 15 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ import chalk, { Chalk } from 'chalk'
22
import { env } from './env.js'
33

44
const BRAND_COLOR = 'rgb(88,190,255)'
5+
const BRAND_COLOR_LIGHT = 'rgb(135,210,255)' // Lighter for shimmer
56
const BRAND_RED = 'rgb(162,0,67)'
67
const BRAND_GREEN = 'rgb(34,139,34)'
78

@@ -120,7 +121,7 @@ const lightTheme: Theme = {
120121
autoAccept: 'rgb(135,0,255)', // Electric violet
121122
bashBorder: 'rgb(255,0,135)', // Vibrant pink
122123
claude: BRAND_COLOR,
123-
claudeShimmer: BRAND_COLOR,
124+
claudeShimmer: BRAND_COLOR_LIGHT,
124125
claudeBlue_FOR_SYSTEM_SPINNER: 'rgb(87,105,247)', // Medium blue for system spinner
125126
claudeBlueShimmer_FOR_SYSTEM_SPINNER: 'rgb(117,135,255)', // Lighter blue for system spinner shimmer
126127
permission: 'rgb(87,105,247)', // Medium blue
@@ -142,12 +143,12 @@ const lightTheme: Theme = {
142143
warning: 'rgb(150,108,30)', // Amber
143144
merged: 'rgb(135,0,255)', // Electric violet (matches autoAccept)
144145
warningShimmer: 'rgb(200,158,80)', // Lighter amber for shimmer effect
145-
diffAdded: 'rgb(170,214,170)',
146-
diffRemoved: 'rgb(228,170,196)',
147-
diffAddedDimmed: 'rgb(220,238,220)',
148-
diffRemovedDimmed: 'rgb(242,220,230)',
149-
diffAddedWord: BRAND_GREEN,
150-
diffRemovedWord: BRAND_RED,
146+
diffAdded: 'rgb(153,204,255)', // Light blue instead of green
147+
diffRemoved: 'rgb(255,204,204)', // Light red
148+
diffAddedDimmed: 'rgb(209,231,253)', // Very light blue
149+
diffRemovedDimmed: 'rgb(255,233,233)', // Very light red
150+
diffAddedWord: 'rgb(51,102,204)', // Medium blue (less intense than deep blue)
151+
diffRemovedWord: 'rgb(153,51,51)', // Softer red (less intense than deep red)
151152
// Agent colors
152153
red_FOR_SUBAGENTS_ONLY: 'rgb(220,38,38)', // Red 600
153154
blue_FOR_SUBAGENTS_ONLY: 'rgb(37,99,235)', // Blue 600
@@ -364,7 +365,7 @@ const lightDaltonizedTheme: Theme = {
364365
autoAccept: 'rgb(135,0,255)', // Electric violet
365366
bashBorder: 'rgb(0,102,204)', // Blue instead of pink
366367
claude: BRAND_COLOR,
367-
claudeShimmer: BRAND_COLOR,
368+
claudeShimmer: BRAND_COLOR_LIGHT,
368369
claudeBlue_FOR_SYSTEM_SPINNER: 'rgb(51,102,255)', // Bright blue for system spinner
369370
claudeBlueShimmer_FOR_SYSTEM_SPINNER: 'rgb(101,152,255)', // Lighter bright blue for system spinner shimmer
370371
permission: 'rgb(51,102,255)', // Bright blue
@@ -381,8 +382,8 @@ const lightDaltonizedTheme: Theme = {
381382
suggestion: 'rgb(51,102,255)', // Bright blue
382383
remember: 'rgb(51,102,255)', // Bright blue
383384
background: 'rgb(0,153,153)', // Cyan (color-blind friendly)
384-
success: BRAND_GREEN,
385-
error: BRAND_RED,
385+
success: 'rgb(0,102,153)', // Blue instead of green for deuteranopia
386+
error: 'rgb(204,0,0)', // Pure red for better distinction
386387
warning: 'rgb(255,153,0)', // Orange adjusted for deuteranopia
387388
merged: 'rgb(135,0,255)', // Electric violet (matches autoAccept)
388389
warningShimmer: 'rgb(255,183,50)', // Lighter orange for shimmer
@@ -445,7 +446,7 @@ const darkTheme: Theme = {
445446
autoAccept: 'rgb(175,135,255)', // Electric violet
446447
bashBorder: 'rgb(253,93,177)', // Bright pink
447448
claude: BRAND_COLOR,
448-
claudeShimmer: BRAND_COLOR,
449+
claudeShimmer: BRAND_COLOR_LIGHT,
449450
claudeBlue_FOR_SYSTEM_SPINNER: 'rgb(131,210,238)', // Light cyan-blue
450451
claudeBlueShimmer_FOR_SYSTEM_SPINNER: 'rgb(177,231,245)', // Lighter cyan-blue for shimmer
451452
permission: 'rgb(131,210,238)', // Light cyan-blue
@@ -526,7 +527,7 @@ const darkDaltonizedTheme: Theme = {
526527
autoAccept: 'rgb(175,135,255)', // Electric violet
527528
bashBorder: 'rgb(51,153,255)', // Bright blue
528529
claude: BRAND_COLOR,
529-
claudeShimmer: BRAND_COLOR,
530+
claudeShimmer: BRAND_COLOR_LIGHT,
530531
claudeBlue_FOR_SYSTEM_SPINNER: 'rgb(153,204,255)', // Light blue for system spinner
531532
claudeBlueShimmer_FOR_SYSTEM_SPINNER: 'rgb(183,224,255)', // Lighter blue for system spinner shimmer
532533
permission: 'rgb(153,204,255)', // Light blue
@@ -570,8 +571,8 @@ const darkDaltonizedTheme: Theme = {
570571
// TUI V2 colors
571572
clawd_body: BRAND_COLOR,
572573
clawd_background: 'rgb(0,0,0)',
573-
userMessageBackground: '#191919',
574-
userMessageBackgroundHover: '#191919',
574+
userMessageBackground: 'rgb(55, 55, 55)', // Lighter grey for better visual contrast
575+
userMessageBackgroundHover: 'rgb(70, 70, 70)',
575576
messageActionsBackground: 'rgb(44, 50, 62)', // cool gray, slight blue
576577
selectionBg: 'rgb(38, 79, 120)', // classic dark-mode selection blue (VS Code dark default); light fgs stay readable
577578
bashMessageBackgroundColor: 'rgb(65, 60, 65)',

0 commit comments

Comments
 (0)