Skip to content

The open source coding agent.

TypeScript

add color scheme preview on hover in appearance dropdown

David Hilldbc15d4816bd
diff --git a/packages/app/src/components/settings-general.tsx b/packages/app/src/components/settings-general.tsx
index 29e8ae77aee..4e0fa765ff9 100644
--- a/packages/app/src/components/settings-general.tsx
+++ b/packages/app/src/components/settings-general.tsx
@@ -62,6 +62,11 @@ export const SettingsGeneral: Component = () => {
value={(o) => o.value}
label={(o) => o.label}
onSelect={(option) => option && theme.setColorScheme(option.value)}
+ onHighlight={(option) => {
+ if (!option) return
+ theme.previewColorScheme(option.value)
+ return () => theme.cancelPreview()
+ }}
variant="secondary"
size="small"
/>