Quantity for shadcn/ui

Quantity is a shadcn/ui theme built around a vivid deep green primary color (#123503) with muted light green accents (#dfe5dc). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid deep green primary (#123503) on a green-tinted background (#080f06).

Color palette

TokenLightDark
Background
#ffffffwhite
#080f06black
Foreground
#060b04black
#fcfdfcwhite
Card
#fcfcfcsnow
#0b1207black
Card foreground
#040803black
#ffffffwhite
Popover
#ffffffwhite
#080f06black
Popover foreground
#060b04black
#fcfdfcwhite
Primary
#123503darkgreen
#123503darkgreen
Primary foreground
#55f312lawngreen
#55f312lawngreen
Secondary
#dfe5dcgainsboro
#333432darkslategray
Secondary foreground
#43513ddarkslategray
#cccdcblightgrey
Muted
#e2e4e2gainsboro
#1b1d1bblack
Muted foreground
#3c4936darkslategray
#bbc9b6silver
Accent
#dfe5dcgainsboro
#333432darkslategray
Accent foreground
#43513ddarkslategray
#cccdcblightgrey
Destructive
#95340esaddlebrown
#ee7444coral
Destructive foreground
#fce3damistyrose
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#123503darkgreen
#123503darkgreen

Contrast

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

Light mode
Text on background19.86:1AAA
Text on card19.73:1AAA
Primary button9.22:1AAA
Secondary button6.57:1AA
Muted text7.49:1AAA
Accent6.57:1AA
Destructive6.15:1AA
Dark mode
Text on background19.07:1AAA
Text on card19.00:1AAA
Primary button9.22:1AAA
Secondary button7.88:1AAA
Muted text9.76:1AAA
Accent7.88:1AAA
Destructive7.22:1AAA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.142 0.022 134.627);
  --muted: oklch(0.918 0.004 136.039);
  --muted-foreground: oklch(0.389 0.036 136.392);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.142 0.022 134.627);
  --card: oklch(0.992 0 161.565);
  --card-foreground: oklch(0.124 0.019 134.553);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.293 0.087 138.187);
  --primary-foreground: oklch(0.846 0.267 139.66);
  --secondary: oklch(0.914 0.013 136.074);
  --secondary-foreground: oklch(0.418 0.037 136.374);
  --accent: oklch(0.914 0.013 136.074);
  --accent-foreground: oklch(0.418 0.037 136.374);
  --destructive: oklch(0.462 0.139 38.993);
  --destructive-foreground: oklch(0.934 0.03 42.873);
  --ring: oklch(0.293 0.087 138.187);
  --chart-1: oklch(0.293 0.087 138.187);
  --chart-2: oklch(0.914 0.013 136.074);
  --chart-3: oklch(0.914 0.013 136.074);
  --chart-4: oklch(0.936 0.01 136.06);
  --chart-5: oklch(0.295 0.089 138.221);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.156 0.022 135.379);
  --foreground: oklch(0.993 0.002 136.03);
  --muted: oklch(0.23 0.006 136.119);
  --muted-foreground: oklch(0.82 0.03 136.158);
  --popover: oklch(0.156 0.022 135.379);
  --popover-foreground: oklch(0.993 0.002 136.03);
  --card: oklch(0.171 0.025 136.217);
  --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.293 0.087 138.187);
  --primary-foreground: oklch(0.846 0.267 139.66);
  --secondary: oklch(0.322 0.002 136.045);
  --secondary-foreground: oklch(0.846 0.002 136.029);
  --accent: oklch(0.322 0.002 136.045);
  --accent-foreground: oklch(0.846 0.002 136.029);
  --destructive: oklch(0.694 0.163 41.254);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.293 0.087 138.187);
  --chart-1: oklch(0.293 0.087 138.187);
  --chart-2: oklch(0.322 0.002 136.045);
  --chart-3: oklch(0.322 0.002 136.045);
  --chart-4: oklch(0.352 0.002 136.045);
  --chart-5: oklch(0.295 0.089 138.221);
}