Whole for shadcn/ui

Whole is a shadcn/ui theme built around a vivid violet primary color (#b382f7) with vivid purple accents (#ed82f7). The light mode uses a neutral background (#f9f7fc). Dark mode keeps the vivid violet primary (#b382f7) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#f9f7fcghostwhite
#000000black
Foreground
#07020dblack
#faf8fbghostwhite
Card
#f9f7fcghostwhite
#000000black
Card foreground
#07020dblack
#faf8fbghostwhite
Popover
#f9f7fcghostwhite
#000000black
Popover foreground
#07020dblack
#faf8fbghostwhite
Primary
#b382f7mediumpurple
#b382f7mediumpurple
Primary foreground
#1e0443midnightblue
#1e0443midnightblue
Secondary
#828cf7cornflowerblue
#828cf7cornflowerblue
Secondary foreground
#040a43midnightblue
#040a43midnightblue
Muted
#ebecf4lavender
#0b0c14black
Muted foreground
#54566ddimgray
#9294abdarkgray
Accent
#ed82f7violet
#ed82f7violet
Accent foreground
#3e0443midnightblue
#3e0443midnightblue
Destructive
#792901saddlebrown
#f25202orangered
Destructive foreground
#fec9aepeachpuff
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#b382f7mediumpurple
#b382f7mediumpurple

Contrast

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

Light mode
Text on background19.34:1AAA
Text on card19.34:1AAA
Primary button6.47:1AA
Secondary button6.24:1AA
Muted text6.09:1AA
Accent7.03:1AAA
Destructive6.63:1AA
Dark mode
Text on background19.88:1AAA
Text on card19.88:1AAA
Primary button6.47:1AA
Secondary button6.24:1AA
Muted text6.55:1AA
Accent7.03:1AAA
Destructive3.49:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.98 0.007 304.945);
  --foreground: oklch(0.108 0.036 306.222);
  --muted: oklch(0.945 0.011 282.026);
  --muted-foreground: oklch(0.462 0.038 280.748);
  --popover: oklch(0.98 0.007 304.945);
  --popover-foreground: oklch(0.108 0.036 306.222);
  --card: oklch(0.98 0.007 304.945);
  --card-foreground: oklch(0.108 0.036 306.222);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.704 0.17 301.401);
  --primary-foreground: oklch(0.212 0.106 294.412);
  --secondary: oklch(0.681 0.157 277.46);
  --secondary-foreground: oklch(0.195 0.105 267.637);
  --accent: oklch(0.766 0.193 324.113);
  --accent-foreground: oklch(0.263 0.116 324.268);
  --destructive: oklch(0.397 0.12 41.333);
  --destructive-foreground: oklch(0.876 0.071 47.893);
  --ring: oklch(0.704 0.17 301.401);
  --chart-1: oklch(0.704 0.17 301.401);
  --chart-2: oklch(0.681 0.157 277.46);
  --chart-3: oklch(0.766 0.193 324.113);
  --chart-4: oklch(0.717 0.137 278.381);
  --chart-5: oklch(0.701 0.176 301.243);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(0.982 0.004 304.989);
  --muted: oklch(0.156 0.017 280.232);
  --muted-foreground: oklch(0.671 0.034 281.326);
  --popover: oklch(0 0 0);
  --popover-foreground: oklch(0.982 0.004 304.989);
  --card: oklch(0 0 0);
  --card-foreground: oklch(0.982 0.004 304.989);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.704 0.17 301.401);
  --primary-foreground: oklch(0.212 0.106 294.412);
  --secondary: oklch(0.681 0.157 277.46);
  --secondary-foreground: oklch(0.195 0.105 267.637);
  --accent: oklch(0.766 0.193 324.113);
  --accent-foreground: oklch(0.263 0.116 324.268);
  --destructive: oklch(0.653 0.207 39.191);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.704 0.17 301.401);
  --chart-1: oklch(0.704 0.17 301.401);
  --chart-2: oklch(0.681 0.157 277.46);
  --chart-3: oklch(0.766 0.193 324.113);
  --chart-4: oklch(0.717 0.137 278.381);
  --chart-5: oklch(0.701 0.176 301.243);
}