Vicinity for shadcn/ui

Vicinity is a shadcn/ui theme built around a vivid yellow primary color (#fde468) with muted light yellow accents (#d4d2c9). The light mode uses a neutral background (#ffffff). Dark mode keeps the vivid yellow primary (#fde468) on a neutral background (#070603).

Color palette

TokenLightDark
Background
#ffffffwhite
#070603black
Foreground
#080703black
#fdfdfcwhite
Card
#ffffffwhite
#070603black
Card foreground
#080703black
#fdfdfcwhite
Popover
#ffffffwhite
#070603black
Popover foreground
#080703black
#fdfdfcwhite
Primary
#fde468khaki
#fde468khaki
Primary foreground
#322a01black
#322a01black
Secondary
#dcdcdagainsboro
#211f17black
Secondary foreground
#444440darkslategray
#c2bea8silver
Muted
#e8e6degainsboro
#211f17black
Muted foreground
#636363dimgray
#9c9c9cdarkgray
Accent
#d4d2c9lightgrey
#3f3b27darkslategray
Accent foreground
#3c3a2fdarkslategray
#d8d4c0lightgrey
Destructive
#721109maroon
#e42311crimson
Destructive foreground
#f9b9b3lightpink
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#fde468khaki
#fde468khaki

Contrast

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

Light mode
Text on background20.15:1AAA
Text on card20.15:1AAA
Primary button11.27:1AAA
Secondary button7.13:1AAA
Muted text4.81:1AA
Accent7.56:1AAA
Destructive7.01:1AAA
Dark mode
Text on background19.88:1AAA
Text on card19.88:1AAA
Primary button11.27:1AAA
Secondary button8.78:1AAA
Muted text5.98:1AA
Accent7.57:1AAA
Destructive4.63:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.126 0.014 100.796);
  --muted: oklch(0.925 0.011 97.422);
  --muted-foreground: oklch(0.501 0 180);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.126 0.014 100.796);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.126 0.014 100.796);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.917 0.146 98.084);
  --primary-foreground: oklch(0.286 0.059 97.41);
  --secondary: oklch(0.894 0.002 97.296);
  --secondary-foreground: oklch(0.385 0.006 97.45);
  --accent: oklch(0.864 0.013 97.462);
  --accent-foreground: oklch(0.346 0.018 97.883);
  --destructive: oklch(0.357 0.131 30.013);
  --destructive-foreground: oklch(0.843 0.076 24.682);
  --ring: oklch(0.917 0.146 98.084);
  --chart-1: oklch(0.917 0.146 98.084);
  --chart-2: oklch(0.894 0.002 97.296);
  --chart-3: oklch(0.864 0.013 97.462);
  --chart-4: oklch(0.917 0.002 97.287);
  --chart-5: oklch(0.922 0.149 98.043);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.123 0.01 99.934);
  --foreground: oklch(0.994 0.002 97.283);
  --muted: oklch(0.24 0.016 97.998);
  --muted-foreground: oklch(0.691 0 180);
  --popover: oklch(0.123 0.01 99.934);
  --popover-foreground: oklch(0.994 0.002 97.283);
  --card: oklch(0.123 0.01 99.934);
  --card-foreground: oklch(0.994 0.002 97.283);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.917 0.146 98.084);
  --primary-foreground: oklch(0.286 0.059 97.41);
  --secondary: oklch(0.24 0.016 97.998);
  --secondary-foreground: oklch(0.799 0.031 97.737);
  --accent: oklch(0.35 0.032 98.197);
  --accent-foreground: oklch(0.867 0.027 97.648);
  --destructive: oklch(0.588 0.225 30.093);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.917 0.146 98.084);
  --chart-1: oklch(0.917 0.146 98.084);
  --chart-2: oklch(0.24 0.016 97.998);
  --chart-3: oklch(0.35 0.032 98.197);
  --chart-4: oklch(0.276 0.019 98.036);
  --chart-5: oklch(0.922 0.149 98.043);
}