From f3e0c0ebc2b02844b8079cc73a28305438014c35 Mon Sep 17 00:00:00 2001 From: LukeGus Date: Fri, 6 Nov 2026 20:03:43 -0600 Subject: [PATCH] fix: one border color for controls, small button icons snap to whole pixels --- CHANGELOG.md | 2 ++ src/ui/components/checkbox.tsx | 2 +- src/ui/components/folder-style.tsx | 2 +- src/ui/components/form-fields.tsx | 4 ++-- src/ui/components/input.tsx | 2 +- src/ui/components/list-kit.tsx | 3 ++- src/ui/components/panel-layout.tsx | 2 +- src/ui/components/select.tsx | 2 +- src/ui/components/select2.tsx | 2 +- src/ui/components/tabs.tsx | 2 +- src/ui/components/textarea.tsx | 2 +- src/ui/index.css | 10 ++++++++++ 12 files changed, 24 insertions(+), 11 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6acfb7e09..235e584ee 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -50,6 +50,8 @@ - Filters, view toggles and small buttons in a toolbar are the same height as the search box next to them - Save and Cancel at the bottom of a form are the same height as other buttons - State badges in tables no longer stretch across the whole column +- Text boxes, dropdowns, checkboxes and button groups share one border color +- Small icons in buttons sit centered instead of half a pixel off ## 26.11.0 diff --git a/src/ui/components/checkbox.tsx b/src/ui/components/checkbox.tsx index 2528f41e1..103f6a9ac 100644 --- a/src/ui/components/checkbox.tsx +++ b/src/ui/components/checkbox.tsx @@ -12,7 +12,7 @@ function Checkbox({ onChange(e.target.value)} - className="h-8 w-10 shrink-0 cursor-pointer rounded-none border border-input bg-transparent p-0.5" + className="h-8 w-10 shrink-0 cursor-pointer rounded-none border border-border bg-transparent p-0.5" /> onChange(e.target.value)} className={cn( - "w-full resize-none border border-input bg-background px-3 py-2 text-xs text-foreground transition-colors placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 dark:bg-input/30", + "w-full resize-none border border-border bg-background px-3 py-2 text-xs text-foreground transition-colors placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 dark:bg-input/30", mono && "font-mono text-[10px]", fill && "min-h-40 flex-1", )} @@ -422,7 +422,7 @@ export function TagInput({ }) { const { t } = useTranslation(); return ( -
+
{tags.map((tag) => ( ) { type={type} data-slot="input" className={cn( - "h-8 w-full min-w-0 rounded-none border border-input bg-transparent px-2.5 py-1 text-xs transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-xs file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-1 aria-invalid:ring-destructive/20 md:text-xs dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40", + "h-8 w-full min-w-0 rounded-none border border-border bg-transparent px-2.5 py-1 text-xs transition-colors outline-none file:inline-flex file:h-6 file:border-0 file:bg-transparent file:text-xs file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring/50 disabled:pointer-events-none disabled:cursor-not-allowed disabled:bg-input/50 disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-1 aria-invalid:ring-destructive/20 md:text-xs dark:bg-input/30 dark:disabled:bg-input/80 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40", type === "number" && "[appearance:textfield] [&::-webkit-outer-spin-button]:appearance-none [&::-webkit-inner-spin-button]:appearance-none", className, diff --git a/src/ui/components/list-kit.tsx b/src/ui/components/list-kit.tsx index 7810eeb31..a98502abe 100644 --- a/src/ui/components/list-kit.tsx +++ b/src/ui/components/list-kit.tsx @@ -394,7 +394,8 @@ export function AddButton({ className, )} > - + {/* Whole pixels so the plus sits centered; the root font is 14px. */} + {!compact && {text}} ); diff --git a/src/ui/components/panel-layout.tsx b/src/ui/components/panel-layout.tsx index 1e2e0a57e..714558c5b 100644 --- a/src/ui/components/panel-layout.tsx +++ b/src/ui/components/panel-layout.tsx @@ -407,7 +407,7 @@ export function PanelSearch({ onEnter(); } }} - className="h-8 w-full min-w-0 border border-input bg-transparent pl-8 pr-7 text-xs outline-none transition-colors placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 dark:bg-input/30" + className="h-8 w-full min-w-0 border border-border bg-transparent pl-8 pr-7 text-xs outline-none transition-colors placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-1 focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 dark:bg-input/30" /> {value && (