Yawning for shadcn/ui

Yawning is a shadcn/ui theme built around a violet primary color (#8b5fd3) with purple accents (#c65fd3). The light mode uses a neutral background (#fcfbfe). Dark mode keeps the violet primary (#8b5fd3) on a violet-tinted background (#07040b).

Color palette

TokenLightDark
Background
#fcfbfewhite
#07040bblack
Foreground
#06020dblack
#faf9fbghostwhite
Card
#fcfbfewhite
#07040bblack
Card foreground
#06020dblack
#faf9fbghostwhite
Popover
#fcfbfewhite
#07040bblack
Popover foreground
#06020dblack
#faf9fbghostwhite
Primary
#8b5fd3mediumpurple
#8b5fd3mediumpurple
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#5f6cd3slateblue
#5f6cd3slateblue
Secondary foreground
#ffffffwhite
#ffffffwhite
Muted
#d8dae9gainsboro
#161827black
Muted foreground
#5a5d6cdimgray
#9395a5darkgray
Accent
#c65fd3mediumorchid
#c65fd3mediumorchid
Accent foreground
#000000black
#000000black
Destructive
#773109saddlebrown
#f18241coral
Destructive foreground
#fad0b8peachpuff
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#8b5fd3mediumpurple
#8b5fd3mediumpurple

Contrast

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

Light mode
Text on background19.89:1AAA
Text on card19.89:1AAA
Primary button4.48:1AA Large
Secondary button4.57:1AA
Muted text4.68:1AA
Accent5.96:1AA
Destructive6.64:1AA
Dark mode
Text on background19.41:1AAA
Text on card19.41:1AAA
Primary button4.48:1AA Large
Secondary button4.57:1AA
Muted text5.94:1AA
Accent5.96:1AA
Destructive7.97:1AAA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.989 0.005 303.569);
  --foreground: oklch(0.108 0.035 304.503);
  --muted: oklch(0.89 0.022 279.943);
  --muted-foreground: oklch(0.481 0.025 279.449);
  --popover: oklch(0.989 0.005 303.569);
  --popover-foreground: oklch(0.108 0.035 304.503);
  --card: oklch(0.989 0.005 303.569);
  --card-foreground: oklch(0.108 0.035 304.503);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.587 0.173 298.625);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.573 0.157 274.694);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.653 0.194 322.845);
  --accent-foreground: oklch(0 0 0);
  --destructive: oklch(0.405 0.109 45.135);
  --destructive-foreground: oklch(0.887 0.057 51.759);
  --ring: oklch(0.587 0.173 298.625);
  --chart-1: oklch(0.587 0.173 298.625);
  --chart-2: oklch(0.573 0.157 274.694);
  --chart-3: oklch(0.653 0.194 322.845);
  --chart-4: oklch(0.605 0.144 275.569);
  --chart-5: oklch(0.583 0.181 298.268);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.117 0.022 304.315);
  --foreground: oklch(0.982 0.004 303.586);
  --muted: oklch(0.214 0.031 277.662);
  --muted-foreground: oklch(0.672 0.023 279.766);
  --popover: oklch(0.117 0.022 304.315);
  --popover-foreground: oklch(0.982 0.004 303.586);
  --card: oklch(0.117 0.022 304.315);
  --card-foreground: oklch(0.982 0.004 303.586);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.587 0.173 298.625);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.573 0.157 274.694);
  --secondary-foreground: oklch(1 0 180);
  --accent: oklch(0.653 0.194 322.845);
  --accent-foreground: oklch(0 0 0);
  --destructive: oklch(0.718 0.157 48.286);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.587 0.173 298.625);
  --chart-1: oklch(0.587 0.173 298.625);
  --chart-2: oklch(0.573 0.157 274.694);
  --chart-3: oklch(0.653 0.194 322.845);
  --chart-4: oklch(0.605 0.144 275.569);
  --chart-5: oklch(0.583 0.181 298.268);
}