Quilt for shadcn/ui

Quilt is a shadcn/ui theme built around a near-black primary color (#000305) with muted light blue accents (#cad0d3). The light mode uses a neutral background (#fbfdfe). Dark mode keeps the near-black primary (#000305) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#fbfdfewhite
#000000black
Foreground
#000000black
#fcfdfdwhite
Card
#f7fbfdghostwhite
#030303black
Card foreground
#000000black
#ffffffwhite
Popover
#f7fbfdghostwhite
#030303black
Popover foreground
#000000black
#ffffffwhite
Primary
#000305black
#000305black
Primary foreground
#3cb5fbdodgerblue
#3cb5fbdodgerblue
Secondary
#e0e0e1gainsboro
#1f282edarkslategray
Secondary foreground
#474848darkslategray
#b3c3ccsilver
Muted
#d8e3e8gainsboro
#172127black
Muted foreground
#3b474edarkslategray
#b1bdc4silver
Accent
#cad0d3lightgrey
#283c48darkslategray
Accent foreground
#31373adarkslategray
#c4d5delightgrey
Destructive
#841f01maroon
#fe5420orangered
Destructive foreground
#ffc8b8peachpuff
#000000black
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#000305black
#000305black

Contrast

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

Light mode
Text on background20.56:1AAA
Text on card20.12:1AAA
Primary button9.04:1AAA
Secondary button6.97:1AA
Muted text7.29:1AAA
Accent7.73:1AAA
Destructive6.51:1AA
Dark mode
Text on background20.60:1AAA
Text on card20.67:1AAA
Primary button9.04:1AAA
Secondary button8.25:1AAA
Muted text8.55:1AAA
Accent7.57:1AAA
Destructive6.48:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.992 0.002 232.613);
  --foreground: oklch(0 0 0);
  --muted: oklch(0.908 0.013 232.792);
  --muted-foreground: oklch(0.391 0.02 233.389);
  --popover: oklch(0.985 0.005 232.647);
  --popover-foreground: oklch(0 0 0);
  --card: oklch(0.985 0.005 232.647);
  --card-foreground: oklch(0 0 0);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.092 0.016 222.052);
  --primary-foreground: oklch(0.738 0.145 239.145);
  --secondary: oklch(0.908 0.001 232.588);
  --secondary-foreground: oklch(0.399 0.001 232.632);
  --accent: oklch(0.853 0.008 232.704);
  --accent-foreground: oklch(0.332 0.01 233.051);
  --destructive: oklch(0.405 0.14 35.339);
  --destructive-foreground: oklch(0.878 0.066 37.594);
  --ring: oklch(0.092 0.016 222.052);
  --chart-1: oklch(0.092 0.016 222.052);
  --chart-2: oklch(0.908 0.001 232.588);
  --chart-3: oklch(0.853 0.008 232.704);
  --chart-4: oklch(0.931 0 232.586);
  --chart-5: oklch(0.092 0.017 221.774);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(0.992 0.001 232.587);
  --muted: oklch(0.24 0.018 233.916);
  --muted-foreground: oklch(0.79 0.017 232.891);
  --popover: oklch(0.092 0 180);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.092 0 180);
  --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.092 0.016 222.052);
  --primary-foreground: oklch(0.738 0.145 239.145);
  --secondary: oklch(0.271 0.017 233.634);
  --secondary-foreground: oklch(0.807 0.022 232.987);
  --accent: oklch(0.345 0.032 234.357);
  --accent-foreground: oklch(0.862 0.022 232.955);
  --destructive: oklch(0.674 0.215 36.059);
  --destructive-foreground: oklch(0 0 0);
  --ring: oklch(0.092 0.016 222.052);
  --chart-1: oklch(0.092 0.016 222.052);
  --chart-2: oklch(0.271 0.017 233.634);
  --chart-3: oklch(0.345 0.032 234.357);
  --chart-4: oklch(0.303 0.02 233.693);
  --chart-5: oklch(0.092 0.017 221.774);
}