Past for shadcn/ui

Past is a shadcn/ui theme built around an indigo primary color (#403894) with muted light indigo accents (#d4d3de). The light mode uses a neutral background (#f7f7fd). Dark mode keeps the indigo primary (#403894) on a neutral background (#010104).

Color palette

TokenLightDark
Background
#f7f7fdghostwhite
#010104black
Foreground
#04030cblack
#ffffffwhite
Card
#f3f3fcaliceblue
#030208black
Card foreground
#030208black
#ffffffwhite
Popover
#f7f7fdghostwhite
#010104black
Popover foreground
#04030cblack
#ffffffwhite
Primary
#403894darkslateblue
#403894darkslateblue
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#e7e7e9lavender
#2c2b36darkslategray
Secondary foreground
#4b4a54darkslategray
#c4c3d0silver
Muted
#e7e6ealavender
#161519black
Muted foreground
#51505edimgray
#a3a1afdarkgray
Accent
#d4d3delightgrey
#3a3852darkslategray
Accent foreground
#383649darkslategray
#d9d8e4gainsboro
Destructive
#74260bsaddlebrown
#d54515chocolate
Destructive foreground
#f8c9b9peachpuff
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#403894darkslateblue
#403894darkslateblue

Contrast

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

Light mode
Text on background19.19:1AAA
Text on card18.69:1AAA
Primary button9.49:1AAA
Secondary button7.05:1AAA
Muted text6.37:1AA
Accent7.91:1AAA
Destructive6.95:1AA
Dark mode
Text on background20.83:1AAA
Text on card20.66:1AAA
Primary button9.49:1AAA
Secondary button8.04:1AAA
Muted text7.15:1AAA
Accent7.99:1AAA
Destructive4.45:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(0.977 0.009 290.082);
  --foreground: oklch(0.107 0.027 286.634);
  --muted: oklch(0.927 0.004 290.159);
  --muted-foreground: oklch(0.437 0.023 289.248);
  --popover: oklch(0.977 0.009 290.082);
  --popover-foreground: oklch(0.107 0.027 286.634);
  --card: oklch(0.966 0.013 289.996);
  --card-foreground: oklch(0.094 0.023 286.765);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.405 0.145 281.473);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.928 0.004 290.172);
  --secondary-foreground: oklch(0.415 0.016 289.524);
  --accent: oklch(0.871 0.016 289.906);
  --accent-foreground: oklch(0.343 0.033 288.332);
  --destructive: oklch(0.384 0.116 37.386);
  --destructive-foreground: oklch(0.873 0.058 39.251);
  --ring: oklch(0.405 0.145 281.473);
  --chart-1: oklch(0.405 0.145 281.473);
  --chart-2: oklch(0.928 0.004 290.172);
  --chart-3: oklch(0.871 0.016 289.906);
  --chart-4: oklch(0.952 0.002 290.198);
  --chart-5: oklch(0.4 0.154 280.595);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.075 0.017 287.046);
  --foreground: oklch(1 0 180);
  --muted: oklch(0.199 0.006 289.637);
  --muted-foreground: oklch(0.716 0.02 289.716);
  --popover: oklch(0.075 0.017 287.046);
  --popover-foreground: oklch(1 0 180);
  --card: oklch(0.095 0.022 287.046);
  --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.405 0.145 281.473);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.294 0.021 288.853);
  --secondary-foreground: oklch(0.822 0.018 289.835);
  --accent: oklch(0.354 0.045 287.673);
  --accent-foreground: oklch(0.885 0.017 289.88);
  --destructive: oklch(0.591 0.189 36.689);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.405 0.145 281.473);
  --chart-1: oklch(0.405 0.145 281.473);
  --chart-2: oklch(0.294 0.021 288.853);
  --chart-3: oklch(0.354 0.045 287.673);
  --chart-4: oklch(0.321 0.024 288.804);
  --chart-5: oklch(0.4 0.154 280.595);
}