Mediocre for shadcn/ui

Mediocre is a shadcn/ui theme built around a deep green primary color (#3c5520) with muted light green accents (#d4dccb). The light mode uses a neutral background (#ffffff). Dark mode keeps the deep green primary (#3c5520) on a neutral background (#030302).

Color palette

TokenLightDark
Background
#ffffffwhite
#030302black
Foreground
#0a1103black
#fafcf8snow
Card
#ffffffwhite
#030302black
Card foreground
#0a1103black
#fafcf8snow
Popover
#ffffffwhite
#030302black
Popover foreground
#0a1103black
#fafcf8snow
Primary
#3c5520darkolivegreen
#3c5520darkolivegreen
Primary foreground
#d4e7c0lightgrey
#d4e7c0lightgrey
Secondary
#d4dccblightgrey
#171717black
Secondary foreground
#3b4630darkslategray
#b0b0b0darkgray
Muted
#dee1dbgainsboro
#241e1eblack
Muted foreground
#616b57dimgray
#a89494rosybrown
Accent
#d4dccblightgrey
#171717black
Accent foreground
#3b4630darkslategray
#b0b0b0darkgray
Destructive
#b0330cfirebrick
#ef4c1aorangered
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#3c5520darkolivegreen
#3c5520darkolivegreen

Contrast

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

Light mode
Text on background19.18:1AAA
Text on card19.18:1AAA
Primary button6.36:1AA
Secondary button7.07:1AAA
Muted text4.23:1AA Large
Accent7.07:1AAA
Destructive6.31:1AA
Dark mode
Text on background19.96:1AAA
Text on card19.96:1AAA
Primary button6.36:1AA
Secondary button8.27:1AAA
Muted text5.71:1AA
Accent8.27:1AAA
Destructive3.67:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.167 0.033 128.308);
  --muted: oklch(0.905 0.009 127.901);
  --muted-foreground: oklch(0.513 0.032 128.541);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.167 0.033 128.308);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.167 0.033 128.308);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.416 0.084 130.836);
  --primary-foreground: oklch(0.904 0.056 128.533);
  --secondary: oklch(0.883 0.024 128.108);
  --secondary-foreground: oklch(0.377 0.039 129.09);
  --accent: oklch(0.883 0.024 128.108);
  --accent-foreground: oklch(0.377 0.039 129.09);
  --destructive: oklch(0.507 0.168 35.515);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.416 0.084 130.836);
  --chart-1: oklch(0.416 0.084 130.836);
  --chart-2: oklch(0.883 0.024 128.108);
  --chart-3: oklch(0.883 0.024 128.108);
  --chart-4: oklch(0.904 0.019 128.044);
  --chart-5: oklch(0.421 0.089 131.042);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.098 0.01 127.051);
  --foreground: oklch(0.988 0.005 127.851);
  --muted: oklch(0.243 0.009 17.807);
  --muted-foreground: oklch(0.685 0.023 17.73);
  --popover: oklch(0.098 0.01 127.051);
  --popover-foreground: oklch(0.988 0.005 127.851);
  --card: oklch(0.098 0.01 127.051);
  --card-foreground: oklch(0.988 0.005 127.851);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.416 0.084 130.836);
  --primary-foreground: oklch(0.904 0.056 128.533);
  --secondary: oklch(0.204 0 180);
  --secondary-foreground: oklch(0.757 0 180);
  --accent: oklch(0.204 0 180);
  --accent-foreground: oklch(0.757 0 180);
  --destructive: oklch(0.641 0.208 35.868);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.416 0.084 130.836);
  --chart-1: oklch(0.416 0.084 130.836);
  --chart-2: oklch(0.204 0 180);
  --chart-3: oklch(0.204 0 180);
  --chart-4: oklch(0.238 0 161.565);
  --chart-5: oklch(0.421 0.089 131.042);
}