Tense for shadcn/ui

Tense is a shadcn/ui theme built around a near-black primary color (#080808) with near-black accents (#080808). The light mode uses a neutral background (#ffffff). Dark mode keeps the near-black primary (#080808) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#ffffffwhite
#000000black
Foreground
#080202black
#faf5f5whitesmoke
Card
#ffffffwhite
#000000black
Card foreground
#080202black
#faf5f5whitesmoke
Popover
#ffffffwhite
#000000black
Popover foreground
#080202black
#faf5f5whitesmoke
Primary
#080808black
#080808black
Primary foreground
#a1a1a1darkgray
#a1a1a1darkgray
Secondary
#080808black
#080808black
Secondary foreground
#a1a1a1darkgray
#a1a1a1darkgray
Muted
#ebdbdbgainsboro
#241414black
Muted foreground
#4e4141darkslategray
#beb1b1silver
Accent
#080808black
#080808black
Accent foreground
#a1a1a1darkgray
#a1a1a1darkgray
Destructive
#a20702darkred
#fd3c35tomato
Destructive foreground
#ffd8d7mistyrose
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#080808black
#080808black

Contrast

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

Light mode
Text on background20.59:1AAA
Text on card20.59:1AAA
Primary button7.76:1AAA
Secondary button7.76:1AAA
Muted text7.26:1AAA
Accent7.76:1AAA
Destructive6.27:1AA
Dark mode
Text on background19.44:1AAA
Text on card19.44:1AAA
Primary button7.76:1AAA
Secondary button7.76:1AAA
Muted text8.53:1AAA
Accent7.76:1AAA
Destructive3.57:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.102 0.02 21.216);
  --muted: oklch(0.904 0.018 17.49);
  --muted-foreground: oklch(0.389 0.018 17.944);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.102 0.02 21.216);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.102 0.02 21.216);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.132 0 165.964);
  --primary-foreground: oklch(0.708 0 158.199);
  --secondary: oklch(0.132 0 165.964);
  --secondary-foreground: oklch(0.708 0 158.199);
  --accent: oklch(0.132 0 165.964);
  --accent-foreground: oklch(0.708 0 158.199);
  --destructive: oklch(0.449 0.181 29.574);
  --destructive-foreground: oklch(0.914 0.043 20.313);
  --ring: oklch(0.132 0 165.964);
  --chart-1: oklch(0.132 0 165.964);
  --chart-2: oklch(0.132 0 165.964);
  --chart-3: oklch(0.132 0 165.964);
  --chart-4: oklch(0.17 0 180);
  --chart-5: oklch(0.132 0.001 17.277);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(0.973 0.006 17.261);
  --muted: oklch(0.213 0.027 19.537);
  --muted-foreground: oklch(0.772 0.015 17.477);
  --popover: oklch(0 0 0);
  --popover-foreground: oklch(0.973 0.006 17.261);
  --card: oklch(0 0 0);
  --card-foreground: oklch(0.973 0.006 17.261);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.132 0 165.964);
  --primary-foreground: oklch(0.708 0 158.199);
  --secondary: oklch(0.132 0 165.964);
  --secondary-foreground: oklch(0.708 0 158.199);
  --accent: oklch(0.132 0 165.964);
  --accent-foreground: oklch(0.708 0 158.199);
  --destructive: oklch(0.652 0.229 27.764);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.132 0 165.964);
  --chart-1: oklch(0.132 0 165.964);
  --chart-2: oklch(0.132 0 165.964);
  --chart-3: oklch(0.132 0 165.964);
  --chart-4: oklch(0.17 0 180);
  --chart-5: oklch(0.132 0.001 17.277);
}