Legacy for shadcn/ui

Legacy is a shadcn/ui theme built around a vivid light violet primary color (#e1bafd) with vivid light green accents (#d6fdba). The light mode uses a neutral background (#faf7fd). Dark mode keeps the vivid light violet primary (#e1bafd) on a neutral background (#030204).

Color palette

TokenLightDark
Background
#faf7fdghostwhite
#030204black
Foreground
#060208black
#ffffffwhite
Card
#f8f3fbghostwhite
#050307black
Card foreground
#030104black
#ffffffwhite
Popover
#faf7fdghostwhite
#030204black
Popover foreground
#060208black
#ffffffwhite
Primary
#e1bafdthistle
#e1bafdthistle
Primary foreground
#4d0580indigo
#4d0580indigo
Secondary
#d6fdbapalegoldenrod
#d6fdbapalegoldenrod
Secondary foreground
#0d1e01black
#0d1e01black
Muted
#eaefe6beige
#141910black
Muted foreground
#535d4bdarkolivegreen
#a9b4a2darkgray
Accent
#d6fdbapalegoldenrod
#d6fdbapalegoldenrod
Accent foreground
#0d1e01black
#0d1e01black
Destructive
#812909saddlebrown
#e54910orangered
Destructive foreground
#fbd0c1peachpuff
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#e1bafdthistle
#e1bafdthistle

Contrast

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

Light mode
Text on background19.43:1AAA
Text on card19.06:1AAA
Primary button7.66:1AAA
Secondary button15.41:1AAA
Muted text5.94:1AA
Accent15.41:1AAA
Destructive6.62:1AA
Dark mode
Text on background20.75:1AAA
Text on card20.51:1AAA
Primary button7.66:1AAA
Secondary button15.41:1AAA
Muted text8.26:1AAA
Accent15.41:1AAA
Destructive3.97:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.981 0.008 311.661);
  --foreground: oklch(0.104 0.021 313.391);
  --muted: oklch(0.947 0.014 131.848);
  --muted-foreground: oklch(0.465 0.032 132.312);
  --popover: oklch(0.981 0.008 311.661);
  --popover-foreground: oklch(0.104 0.021 313.391);
  --card: oklch(0.971 0.012 311.628);
  --card-foreground: oklch(0.083 0.017 313.391);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.845 0.099 310.771);
  --primary-foreground: oklch(0.342 0.175 303.018);
  --secondary: oklch(0.949 0.096 132.611);
  --secondary-foreground: oklch(0.21 0.057 133.395);
  --accent: oklch(0.949 0.096 132.611);
  --accent-foreground: oklch(0.21 0.057 133.395);
  --destructive: oklch(0.411 0.127 37.773);
  --destructive-foreground: oklch(0.891 0.052 40.973);
  --ring: oklch(0.845 0.099 310.771);
  --chart-1: oklch(0.845 0.099 310.771);
  --chart-2: oklch(0.949 0.096 132.611);
  --chart-3: oklch(0.949 0.096 132.611);
  --chart-4: oklch(0.959 0.075 132.399);
  --chart-5: oklch(0.844 0.103 310.738);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.085 0.012 312.926);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.205 0.021 132.611);
  --muted-foreground: oklch(0.757 0.029 132.038);
  --popover: oklch(0.085 0.012 312.926);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.107 0.015 312.926);
  --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.845 0.099 310.771);
  --primary-foreground: oklch(0.342 0.175 303.018);
  --secondary: oklch(0.949 0.096 132.611);
  --secondary-foreground: oklch(0.21 0.057 133.395);
  --accent: oklch(0.949 0.096 132.611);
  --accent-foreground: oklch(0.21 0.057 133.395);
  --destructive: oklch(0.62 0.201 36.946);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.845 0.099 310.771);
  --chart-1: oklch(0.845 0.099 310.771);
  --chart-2: oklch(0.949 0.096 132.611);
  --chart-3: oklch(0.949 0.096 132.611);
  --chart-4: oklch(0.959 0.075 132.399);
  --chart-5: oklch(0.844 0.103 310.738);
}