From fb0250ef63c88c3696cd0bda5372d021e2757888 Mon Sep 17 00:00:00 2001 From: Brooklyn Nicholson Date: Wed, 3 Jun 2026 21:59:44 -0500 Subject: [PATCH] feat(desktop): add boxless `text` button variant; use for aux-model actions New reusable `text` variant renders a button as inline label text (no bg/border, muted -> foreground, underline-on-hover affordance). Emphasize the actionable word by adding `font-semibold`/`underline` at the call site. Applied to the auxiliary-model "Set to main" (plain), "Change" and "Reset all to main" (bold + underlined) actions, replacing the boxed ghost/outline buttons. --- apps/desktop/src/app/settings/model-settings.tsx | 8 +++++--- apps/desktop/src/components/ui/button.tsx | 6 +++++- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/apps/desktop/src/app/settings/model-settings.tsx b/apps/desktop/src/app/settings/model-settings.tsx index 40474749c..463add4b4 100644 --- a/apps/desktop/src/app/settings/model-settings.tsx +++ b/apps/desktop/src/app/settings/model-settings.tsx @@ -244,10 +244,11 @@ export function ModelSettings({ onMainModelChanged }: ModelSettingsProps) {
@@ -270,15 +271,16 @@ export function ModelSettings({ onMainModelChanged }: ModelSettingsProps) { disabled={!mainModel || applying} onClick={() => void setAuxiliaryToMain(meta.key)} size="sm" - variant="ghost" + variant="text" > Set to main diff --git a/apps/desktop/src/components/ui/button.tsx b/apps/desktop/src/components/ui/button.tsx index a44b6d95e..0fd1166cd 100644 --- a/apps/desktop/src/components/ui/button.tsx +++ b/apps/desktop/src/components/ui/button.tsx @@ -19,7 +19,11 @@ const buttonVariants = cva( 'border bg-background shadow-xs hover:bg-accent hover:text-accent-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50', secondary: 'bg-secondary text-secondary-foreground hover:bg-secondary/80', ghost: 'hover:bg-accent hover:text-accent-foreground dark:hover:bg-accent/50', - link: 'text-primary underline-offset-4 decoration-current/20 hover:underline' + link: 'text-primary underline-offset-4 decoration-current/20 hover:underline', + // Boxless inline-text action (no bg/border). Reads as label text; add + // `font-semibold` and/or `underline` at the call site to emphasize the + // actionable word (e.g. a "Change" affordance next to muted copy). + text: 'text-muted-foreground underline-offset-4 hover:text-foreground hover:underline' }, size: { default: 'px-3 py-1 has-[>svg]:px-2.5',