Saucer for shadcn/ui

Saucer is a shadcn/ui theme built around a deep green primary color (#1d4715) with deep green accents (#154726). The light mode uses a neutral background (#ffffff). Dark mode keeps the deep green primary (#1d4715) on a neutral background (#020402).

Color palette

TokenLightDark
Background
#ffffffwhite
#020402black
Foreground
#000000black
#ffffffwhite
Card
#ffffffwhite
#020402black
Card foreground
#000000black
#ffffffwhite
Popover
#ffffffwhite
#020402black
Popover foreground
#000000black
#ffffffwhite
Primary
#1d4715darkgreen
#1d4715darkgreen
Primary foreground
#b2e5a9palegreen
#b2e5a9palegreen
Secondary
#354715darkolivegreen
#354715darkolivegreen
Secondary foreground
#d0e5a9palegoldenrod
#d0e5a9palegoldenrod
Muted
#eff3e7linen
#14180cblack
Muted foreground
#434440darkslategray
#bdbfbbsilver
Accent
#154726darkslategray
#154726darkslategray
Accent foreground
#a9e5bepowderblue
#a9e5bepowderblue
Destructive
#ba4603firebrick
#fb6813orangered
Destructive foreground
#ffffffwhite
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#1d4715darkgreen
#1d4715darkgreen

Contrast

WCAG 2 contrast ratios between each background and its foreground color.

Light mode
Text on background21.00:1AAA
Text on card21.00:1AAA
Primary button7.50:1AAA
Secondary button7.51:1AAA
Muted text8.72:1AAA
Accent7.49:1AAA
Destructive5.30:1AA
Dark mode
Text on background20.62:1AAA
Text on card20.62:1AAA
Primary button7.50:1AAA
Secondary button7.51:1AAA
Muted text9.73:1AAA
Accent7.49:1AAA
Destructive7.11:1AAA

CSS variables

Paste this into your globals.css to use Saucer in your shadcn/ui project.

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0 0 0);
  --muted: oklch(0.958 0.017 122.487);
  --muted-foreground: oklch(0.385 0.007 122.494);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0 0 0);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0 0 0);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.354 0.091 140.797);
  --primary-foreground: oklch(0.871 0.098 140.832);
  --secondary: oklch(0.37 0.076 126.288);
  --secondary-foreground: oklch(0.892 0.083 123.729);
  --accent: oklch(0.354 0.077 151.786);
  --accent-foreground: oklch(0.871 0.082 155.804);
  --destructive: oklch(0.546 0.163 42.272);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.354 0.091 140.797);
  --chart-1: oklch(0.354 0.091 140.797);
  --chart-2: oklch(0.37 0.076 126.288);
  --chart-3: oklch(0.354 0.077 151.786);
  --chart-4: oklch(0.41 0.086 126.419);
  --chart-5: oklch(0.358 0.095 140.825);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.096 0.012 139.887);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.2 0.024 124.202);
  --muted-foreground: oklch(0.801 0.006 122.325);
  --popover: oklch(0.096 0.012 139.887);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.096 0.012 139.887);
  --card-foreground: oklch(1 0 180);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.354 0.091 140.797);
  --primary-foreground: oklch(0.871 0.098 140.832);
  --secondary: oklch(0.37 0.076 126.288);
  --secondary-foreground: oklch(0.892 0.083 123.729);
  --accent: oklch(0.354 0.077 151.786);
  --accent-foreground: oklch(0.871 0.082 155.804);
  --destructive: oklch(0.694 0.198 43.559);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.354 0.091 140.797);
  --chart-1: oklch(0.354 0.091 140.797);
  --chart-2: oklch(0.37 0.076 126.288);
  --chart-3: oklch(0.354 0.077 151.786);
  --chart-4: oklch(0.41 0.086 126.419);
  --chart-5: oklch(0.358 0.095 140.825);
}