Bis for shadcn/ui

Bis is a shadcn/ui theme built around a blue primary color (#4d7cdb) with muted light blue accents (#cbcfd7). The light mode uses a neutral background (#ffffff). Dark mode keeps the blue primary (#4d7cdb) on a blue-tinted background (#06090f).

Color palette

TokenLightDark
Background
#ffffffwhite
#06090fblack
Foreground
#000000black
#fcfcfdwhite
Card
#fcfcfcsnow
#070b12black
Card foreground
#000000black
#ffffffwhite
Popover
#ffffffwhite
#06090fblack
Popover foreground
#000000black
#fcfcfdwhite
Primary
#4d7cdbroyalblue
#4d7cdbroyalblue
Primary foreground
#ffffffwhite
#ffffffwhite
Secondary
#e6e8ealavender
#151619black
Secondary foreground
#4a4d55darkslategray
#aaaeb5darkgray
Muted
#e3e8f3lavender
#0c121cblack
Muted foreground
#3c424edarkslategray
#b1b7c3silver
Accent
#cbcfd7lightgrey
#23272edarkslategray
Accent foreground
#31363fdarkslategray
#babfcasilver
Destructive
#d51010firebrick
#e81111red
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#ededeewhitesmoke
#202122black
Input
#ededeewhitesmoke
#202122black
Ring
#4d7cdbroyalblue
#4d7cdbroyalblue

Contrast

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

Light mode
Text on background21.00:1AAA
Text on card20.54:1AAA
Primary button4.01:1AA Large
Secondary button6.86:1AA
Muted text8.20:1AAA
Accent7.78:1AAA
Destructive5.35:1AA
Dark mode
Text on background19.46:1AAA
Text on card19.70:1AAA
Primary button4.01:1AA Large
Secondary button8.10:1AAA
Muted text9.32:1AAA
Accent8.11:1AAA
Destructive4.62:1AA

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0 0 0);
  --muted: oklch(0.93 0.015 264.492);
  --muted-foreground: oklch(0.378 0.022 264.268);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0 0 0);
  --card: oklch(0.992 0 161.565);
  --card-foreground: oklch(0 0 0);
  --border: oklch(0.946 0.001 264.549);
  --input: oklch(0.946 0.001 264.549);
  --primary: oklch(0.601 0.153 262.676);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.929 0.003 264.541);
  --secondary-foreground: oklch(0.42 0.013 264.424);
  --accent: oklch(0.854 0.012 264.504);
  --accent-foreground: oklch(0.331 0.018 264.282);
  --destructive: oklch(0.553 0.221 28.621);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.601 0.153 262.676);
  --chart-1: oklch(0.601 0.153 262.676);
  --chart-2: oklch(0.929 0.003 264.541);
  --chart-3: oklch(0.854 0.012 264.504);
  --chart-4: oklch(0.953 0.002 264.544);
  --chart-5: oklch(0.599 0.159 262.59);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0.138 0.014 260.449);
  --foreground: oklch(0.992 0.001 264.549);
  --muted: oklch(0.181 0.024 263.719);
  --muted-foreground: oklch(0.779 0.018 264.463);
  --popover: oklch(0.138 0.014 260.449);
  --popover-foreground: oklch(0.992 0.001 264.549);
  --card: oklch(0.149 0.017 262.622);
  --card-foreground: oklch(1 0 180);
  --border: oklch(0.247 0.002 264.528);
  --input: oklch(0.247 0.002 264.528);
  --primary: oklch(0.601 0.153 262.676);
  --primary-foreground: oklch(1 0 180);
  --secondary: oklch(0.202 0.005 264.466);
  --secondary-foreground: oklch(0.75 0.011 264.499);
  --accent: oklch(0.272 0.014 264.308);
  --accent-foreground: oklch(0.804 0.016 264.478);
  --destructive: oklch(0.59 0.236 28.667);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.601 0.153 262.676);
  --chart-1: oklch(0.601 0.153 262.676);
  --chart-2: oklch(0.202 0.005 264.466);
  --chart-3: oklch(0.272 0.014 264.308);
  --chart-4: oklch(0.234 0.006 264.454);
  --chart-5: oklch(0.599 0.159 262.59);
}