From 7a55f35b76c70e9d0d91b82db91f1a864bd99b15 Mon Sep 17 00:00:00 2001 From: zetaloop Date: Wed, 25 Feb 2026 14:21:18 +0800 Subject: [PATCH] style(ui): adjust primitives, card shadow and header nav --- app/globals.css | 2 +- components/header.tsx | 34 +++++++++++++++++----------------- components/ui/button.tsx | 8 ++++---- components/ui/card.tsx | 2 +- components/ui/input.tsx | 2 +- 5 files changed, 24 insertions(+), 24 deletions(-) diff --git a/app/globals.css b/app/globals.css index 67343bf..8f8d6e5 100644 --- a/app/globals.css +++ b/app/globals.css @@ -49,7 +49,7 @@ } :root { - --radius: 0.5rem; + --radius: 0.625rem; --background: oklch(0.99 0 0); --foreground: oklch(0.14 0 0); --card: oklch(1 0 0); diff --git a/components/header.tsx b/components/header.tsx index 6902208..31c1cc0 100644 --- a/components/header.tsx +++ b/components/header.tsx @@ -100,20 +100,20 @@ export function Header() {
@@ -227,11 +227,11 @@ export function Header() { ) : ( -
- -
diff --git a/components/ui/button.tsx b/components/ui/button.tsx index 8658cf8..cd020c8 100644 --- a/components/ui/button.tsx +++ b/components/ui/button.tsx @@ -20,13 +20,13 @@ const buttonVariants = cva( }, size: { default: "h-9 px-4 py-2 has-[>svg]:px-3", - xs: "h-6 gap-1 rounded-sm px-2 text-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3", + xs: "h-6 gap-1 rounded-md px-2 text-xs has-[>svg]:px-1.5 [&_svg:not([class*='size-'])]:size-3", sm: "h-8 rounded-md gap-1.5 px-3 has-[>svg]:px-2.5", lg: "h-10 rounded-md px-6 has-[>svg]:px-4", icon: "size-9", - "icon-xs": "size-6 rounded-sm [&_svg:not([class*='size-'])]:size-3", - "icon-sm": "size-8 rounded-md", - "icon-lg": "size-10 rounded-md", + "icon-xs": "size-6 rounded-md [&_svg:not([class*='size-'])]:size-3", + "icon-sm": "size-8", + "icon-lg": "size-10", }, }, defaultVariants: { diff --git a/components/ui/card.tsx b/components/ui/card.tsx index 190b757..0ab2c15 100644 --- a/components/ui/card.tsx +++ b/components/ui/card.tsx @@ -7,7 +7,7 @@ function Card({ className, ...props }: React.ComponentProps<"div">) {
) { type={type} data-slot="input" className={cn( - "file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-sm transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm", + "file:text-foreground placeholder:text-muted-foreground selection:bg-primary selection:text-primary-foreground dark:bg-input/30 border-input h-9 w-full min-w-0 rounded-md border bg-transparent px-3 py-1 text-base shadow-xs transition-[color,box-shadow] outline-none file:inline-flex file:h-7 file:border-0 file:bg-transparent file:text-sm file:font-medium disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm", "focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background", "aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive", className,