Dirndl for shadcn/ui

Dirndl is a shadcn/ui theme built around a neutral gray primary color (#9d9d95) with muted yellow accents (#c1c1b3). The light mode uses a neutral background (#fefefb). Dark mode keeps the neutral gray primary (#9d9d95) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#fefefbwhite
#000000black
Foreground
#080902black
#fafaf5whitesmoke
Card
#fefefbwhite
#000000black
Card foreground
#080902black
#fafaf5whitesmoke
Popover
#fefefbwhite
#000000black
Popover foreground
#080902black
#fafaf5whitesmoke
Primary
#9d9d95darkgray
#9d9d95darkgray
Primary foreground
#000000black
#000000black
Secondary
#d3d3cflightgrey
#35352cdarkslategray
Secondary foreground
#3a3a36darkslategray
#cecfc4lightgrey
Muted
#ecece9linen
#161613black
Muted foreground
#585856dimgray
#a9a9a7darkgray
Accent
#c1c1b3silver
#53543bdarkolivegreen
Accent foreground
#24241eblack
#e5e6dbgainsboro
Destructive
#8f260fsaddlebrown
#e23d18orangered
Destructive foreground
#fbdcd5mistyrose
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#9d9d95darkgray
#9d9d95darkgray

Contrast

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

Light mode
Text on background19.77:1AAA
Text on card19.77:1AAA
Primary button7.69:1AAA
Secondary button7.60:1AAA
Muted text6.04:1AA
Accent8.57:1AAA
Destructive6.62:1AA
Dark mode
Text on background20.05:1AAA
Text on card20.05:1AAA
Primary button7.69:1AAA
Secondary button7.84:1AAA
Muted text7.68:1AAA
Accent6.21:1AA
Destructive4.27:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.996 0.004 108.013);
  --foreground: oklch(0.134 0.022 110.194);
  --muted: oklch(0.943 0.005 108.035);
  --muted-foreground: oklch(0.458 0.003 108.05);
  --popover: oklch(0.996 0.004 108.013);
  --popover-foreground: oklch(0.134 0.022 110.194);
  --card: oklch(0.996 0.004 108.013);
  --card-foreground: oklch(0.134 0.022 110.194);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.694 0.012 108.247);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.866 0.005 108.046);
  --secondary-foreground: oklch(0.348 0.008 108.339);
  --accent: oklch(0.807 0.019 108.367);
  --accent-foreground: oklch(0.26 0.012 108.77);
  --destructive: oklch(0.434 0.144 33.733);
  --destructive-foreground: oklch(0.919 0.035 32.717);
  --ring: oklch(0.694 0.012 108.247);
  --chart-1: oklch(0.694 0.012 108.247);
  --chart-2: oklch(0.866 0.005 108.046);
  --chart-3: oklch(0.807 0.019 108.367);
  --chart-4: oklch(0.888 0.004 108.025);
  --chart-5: oklch(0.702 0.02 108.465);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(0.983 0.006 108.056);
  --muted: oklch(0.2 0.007 108.585);
  --muted-foreground: oklch(0.735 0.002 108.001);
  --popover: oklch(0 0 0);
  --popover-foreground: oklch(0.983 0.006 108.056);
  --card: oklch(0 0 0);
  --card-foreground: oklch(0.983 0.006 108.056);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.694 0.012 108.247);
  --primary-foreground: oklch(0 0 0);
  --secondary: oklch(0.327 0.017 108.847);
  --secondary-foreground: oklch(0.851 0.015 108.253);
  --accent: oklch(0.436 0.038 109.462);
  --accent-foreground: oklch(0.921 0.014 108.216);
  --destructive: oklch(0.604 0.207 33.483);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.694 0.012 108.247);
  --chart-1: oklch(0.694 0.012 108.247);
  --chart-2: oklch(0.327 0.017 108.847);
  --chart-3: oklch(0.436 0.038 109.462);
  --chart-4: oklch(0.359 0.019 108.873);
  --chart-5: oklch(0.702 0.02 108.465);
}