Rutabaga for shadcn/ui

Rutabaga is a shadcn/ui theme built around a light violet primary color (#c7b8e5) with muted light violet accents (#ccc8d5). The light mode uses a neutral background (#f9f8fc). Dark mode keeps the light violet primary (#c7b8e5) on a violet-tinted background (#09070e).

Color palette

TokenLightDark
Background
#f9f8fcghostwhite
#09070eblack
Foreground
#06030cblack
#fcfbfdsnow
Card
#f9f8fcghostwhite
#09070eblack
Card foreground
#06030cblack
#fcfbfdsnow
Popover
#f9f8fcghostwhite
#09070eblack
Popover foreground
#06030cblack
#fcfbfdsnow
Primary
#c7b8e5thistle
#c7b8e5thistle
Primary foreground
#2d1c4fmidnightblue
#2d1c4fmidnightblue
Secondary
#ccc8d5lightgrey
#2a292edarkslategray
Secondary foreground
#332e3ddarkslategray
#c3c1c8silver
Muted
#e8e2f3lavender
#120c1dblack
Muted foreground
#494158darkslategray
#afa7bedarkgray
Accent
#ccc8d5lightgrey
#2a292edarkslategray
Accent foreground
#332e3ddarkslategray
#c3c1c8silver
Destructive
#940c05darkred
#f11409red
Destructive foreground
#fdd0cepink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#c7b8e5thistle
#c7b8e5thistle

Contrast

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

Light mode
Text on background19.36:1AAA
Text on card19.36:1AAA
Primary button8.19:1AAA
Secondary button7.99:1AAA
Muted text7.63:1AAA
Accent7.99:1AAA
Destructive6.53:1AA
Dark mode
Text on background19.43:1AAA
Text on card19.43:1AAA
Primary button8.19:1AAA
Secondary button8.10:1AAA
Muted text8.29:1AAA
Accent8.10:1AAA
Destructive4.32:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.981 0.005 301.408);
  --foreground: oklch(0.113 0.027 301.821);
  --muted: oklch(0.923 0.023 301.098);
  --muted-foreground: oklch(0.392 0.039 299.855);
  --popover: oklch(0.981 0.005 301.408);
  --popover-foreground: oklch(0.113 0.027 301.821);
  --card: oklch(0.981 0.005 301.408);
  --card-foreground: oklch(0.113 0.027 301.821);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.81 0.065 300.184);
  --primary-foreground: oklch(0.279 0.089 295.434);
  --secondary: oklch(0.84 0.019 301.124);
  --secondary-foreground: oklch(0.313 0.027 300.078);
  --accent: oklch(0.84 0.019 301.124);
  --accent-foreground: oklch(0.313 0.027 300.078);
  --destructive: oklch(0.423 0.166 29.556);
  --destructive-foreground: oklch(0.896 0.051 21.685);
  --ring: oklch(0.81 0.065 300.184);
  --chart-1: oklch(0.81 0.065 300.184);
  --chart-2: oklch(0.84 0.019 301.124);
  --chart-3: oklch(0.84 0.019 301.124);
  --chart-4: oklch(0.866 0.016 301.194);
  --chart-5: oklch(0.807 0.069 300.093);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.135 0.016 300.94);
  --foreground: oklch(0.991 0.003 301.45);
  --muted: oklch(0.172 0.034 298.115);
  --muted-foreground: oklch(0.742 0.034 300.762);
  --popover: oklch(0.135 0.016 300.94);
  --popover-foreground: oklch(0.991 0.003 301.45);
  --card: oklch(0.135 0.016 300.94);
  --card-foreground: oklch(0.991 0.003 301.45);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.81 0.065 300.184);
  --primary-foreground: oklch(0.279 0.089 295.434);
  --secondary: oklch(0.284 0.01 300.943);
  --secondary-foreground: oklch(0.814 0.01 301.294);
  --accent: oklch(0.284 0.01 300.943);
  --accent-foreground: oklch(0.814 0.01 301.294);
  --destructive: oklch(0.607 0.242 29.508);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.81 0.065 300.184);
  --chart-1: oklch(0.81 0.065 300.184);
  --chart-2: oklch(0.284 0.01 300.943);
  --chart-3: oklch(0.284 0.01 300.943);
  --chart-4: oklch(0.313 0.011 300.921);
  --chart-5: oklch(0.807 0.069 300.093);
}