From f829b5e44c4b6fff4e62ac1bbff967ac6b870b97 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pavla=20Novotna=CC=81?= Date: Tue, 5 Nov 2024 13:37:14 +0100 Subject: [PATCH 1/2] callout styling --- sites/docs/src/lib/components/callout.svelte | 18 +++--------------- .../docs/src/lib/components/ui/alert/index.ts | 8 ++++---- 2 files changed, 7 insertions(+), 19 deletions(-) diff --git a/sites/docs/src/lib/components/callout.svelte b/sites/docs/src/lib/components/callout.svelte index c1deba82a..e8fc9ed56 100644 --- a/sites/docs/src/lib/components/callout.svelte +++ b/sites/docs/src/lib/components/callout.svelte @@ -1,8 +1,4 @@ - {@const Icon = iconMap[type]} - + {#if title} - + {title} {/if} - + {@render children?.()} diff --git a/sites/docs/src/lib/components/ui/alert/index.ts b/sites/docs/src/lib/components/ui/alert/index.ts index f38972274..43fb2cf81 100644 --- a/sites/docs/src/lib/components/ui/alert/index.ts +++ b/sites/docs/src/lib/components/ui/alert/index.ts @@ -5,15 +5,15 @@ import Description from "./alert-description.svelte"; import Title from "./alert-title.svelte"; export const alertVariants = tv({ - base: "relative w-full rounded-br-lg rounded-tr-lg border-l-4 px-4 pb-4 pt-[22px] [&>h5]:tracking-normal [&>svg+div]:translate-y-[-3px] [&>svg]:absolute [&>svg]:left-4 [&>svg]:top-6 [&>svg]:text-foreground", + base: "relative w-full rounded-[16px] px-5 pb-[30px] pt-5 [&>h5]:tracking-normal ", variants: { variant: { - note: "border-sky-200 bg-sky-50 text-foreground dark:border-sky-600 dark:bg-sky-500/15 [&>h5]:text-sky-600 dark:[&>h5]:text-sky-400 [&>svg]:text-sky-600 dark:[&>svg]:text-sky-400", + note: "dark:[&>h5]:[#363661] bg-[#E0F2FE] text-[#363661] dark:bg-[#E0F2FE] [&>.dot]:bg-[#363661] [&>h5]:text-[#363661] [&>svg]:text-sky-600 dark:[&>svg]:text-sky-400", danger: "border-rose-200 bg-rose-50 text-foreground dark:border-rose-600 dark:bg-rose-500/20 [&>h5]:text-red-600 dark:[&>h5]:text-red-300 [&>svg]:text-red-800 dark:[&>svg]:text-red-300", - tip: "border-fuchsia-200 bg-fuchsia-50 text-foreground dark:border-fuchsia-700 dark:bg-fuchsia-500/15 [&>h5]:text-fuchsia-500 dark:[&>h5]:text-fuchsia-500 [&>svg]:text-fuchsia-500 dark:[&>svg]:text-fuchsia-500", + tip: "dark:[&>h5]:[#0040A7] bg-[#FFDFDA] text-[#0040A7] dark:bg-[#FFDFDA] [&>.dot]:bg-[#0040A7] [&>h5]:text-[#0040A7]", warning: - "border-amber-200 bg-amber-50 text-foreground dark:border-amber-600 dark:bg-amber-500/15 [&>h5]:text-amber-500 dark:[&>h5]:text-amber-400 [&>svg]:text-amber-500 dark:[&>svg]:text-amber-400", + "bg-[#FEFCE8] text-foreground-alt dark:bg-[#FEFCE8] [&>.dot]:bg-foreground-alt [&>h5]:text-foreground-alt dark:[&>h5]:text-foreground-alt", }, }, defaultVariants: { From 93260862a67d4fd1aa1bdf4253b1f301e07b52ce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pavla=20Novotna=CC=81?= Date: Wed, 6 Nov 2024 09:45:52 +0100 Subject: [PATCH 2/2] fix text color in warning note --- sites/docs/src/lib/components/ui/alert/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sites/docs/src/lib/components/ui/alert/index.ts b/sites/docs/src/lib/components/ui/alert/index.ts index 43fb2cf81..89c3d88b8 100644 --- a/sites/docs/src/lib/components/ui/alert/index.ts +++ b/sites/docs/src/lib/components/ui/alert/index.ts @@ -5,7 +5,7 @@ import Description from "./alert-description.svelte"; import Title from "./alert-title.svelte"; export const alertVariants = tv({ - base: "relative w-full rounded-[16px] px-5 pb-[30px] pt-5 [&>h5]:tracking-normal ", + base: "relative w-full rounded-[16px] p-5 [&>h5]:tracking-normal ", variants: { variant: { @@ -13,7 +13,7 @@ export const alertVariants = tv({ danger: "border-rose-200 bg-rose-50 text-foreground dark:border-rose-600 dark:bg-rose-500/20 [&>h5]:text-red-600 dark:[&>h5]:text-red-300 [&>svg]:text-red-800 dark:[&>svg]:text-red-300", tip: "dark:[&>h5]:[#0040A7] bg-[#FFDFDA] text-[#0040A7] dark:bg-[#FFDFDA] [&>.dot]:bg-[#0040A7] [&>h5]:text-[#0040A7]", warning: - "bg-[#FEFCE8] text-foreground-alt dark:bg-[#FEFCE8] [&>.dot]:bg-foreground-alt [&>h5]:text-foreground-alt dark:[&>h5]:text-foreground-alt", + "bg-[#FEFCE8] text-[#525252] dark:bg-[#FEFCE8] [&>.dot]:bg-[#525252] [&>h5]:text-[#525252] dark:[&>h5]:text-[#525252]", }, }, defaultVariants: {