Leading for shadcn/ui

Leading is a shadcn/ui theme built around a green primary color (#16981e) with red accents (#981e16). The light mode uses a neutral background (#f7fdf8). Dark mode keeps the green primary (#16981e) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#f7fdf8mintcream
#000000black
Foreground
#020902black
#fcfdfcwhite
Card
#f3fbf4whitesmoke
#030303black
Card foreground
#010401black
#ffffffwhite
Popover
#f3fbf4whitesmoke
#030303black
Popover foreground
#010401black
#ffffffwhite
Primary
#16981eforestgreen
#16981eforestgreen
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#1e1698darkblue
#1e1698darkblue
Secondary foreground
#e6e4fblavender
#e6e4fblavender
Muted
#dbdbe6gainsboro
#1a1924black
Muted foreground
#3a3946darkslategray
#bab9c6silver
Accent
#981e16brown
#981e16brown
Accent foreground
#fbe6e4mistyrose
#fbe6e4mistyrose
Destructive
#c52a16firebrick
#e8422cchocolate
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#16981eforestgreen
#16981eforestgreen

Contrast

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

Light mode
Text on background19.48:1AAA
Text on card19.60:1AAA
Primary button3.80:1AA Large
Secondary button10.40:1AAA
Muted text8.23:1AAA
Accent6.93:1AA
Destructive5.62:1AA
Dark mode
Text on background20.59:1AAA
Text on card20.67:1AAA
Primary button3.80:1AA Large
Secondary button10.40:1AAA
Muted text8.99:1AAA
Accent6.93:1AA
Destructive4.01:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.987 0.009 147.457);
  --foreground: oklch(0.123 0.028 145.82);
  --muted: oklch(0.894 0.016 289.145);
  --muted-foreground: oklch(0.352 0.022 288.27);
  --popover: oklch(0.981 0.013 147.411);
  --popover-foreground: oklch(0.098 0.022 145.82);
  --card: oklch(0.981 0.013 147.411);
  --card-foreground: oklch(0.098 0.022 145.82);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.591 0.188 143.301);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.335 0.194 271.594);
  --secondary-foreground: oklch(0.928 0.031 288.843);
  --accent: oklch(0.443 0.158 29.239);
  --accent-foreground: oklch(0.941 0.024 22.51);
  --destructive: oklch(0.538 0.194 31.038);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.591 0.188 143.301);
  --chart-1: oklch(0.591 0.188 143.301);
  --chart-2: oklch(0.335 0.194 271.594);
  --chart-3: oklch(0.443 0.158 29.239);
  --chart-4: oklch(0.355 0.207 271.337);
  --chart-5: oklch(0.598 0.192 143.215);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(0.993 0.001 147.531);
  --muted: oklch(0.219 0.023 287.427);
  --muted-foreground: oklch(0.79 0.018 289.05);
  --popover: oklch(0.092 0 180);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.092 0 180);
  --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.591 0.188 143.301);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.335 0.194 271.594);
  --secondary-foreground: oklch(0.928 0.031 288.843);
  --accent: oklch(0.443 0.158 29.239);
  --accent-foreground: oklch(0.941 0.024 22.51);
  --destructive: oklch(0.62 0.206 30.92);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.591 0.188 143.301);
  --chart-1: oklch(0.591 0.188 143.301);
  --chart-2: oklch(0.335 0.194 271.594);
  --chart-3: oklch(0.443 0.158 29.239);
  --chart-4: oklch(0.355 0.207 271.337);
  --chart-5: oklch(0.598 0.192 143.215);
}