Semiconductor for shadcn/ui

Semiconductor is a shadcn/ui theme built around a neutral gray primary color (#e4e7e5) with neutral gray accents (#e4e7e7). The light mode uses a neutral background (#ffffff). Dark mode keeps the neutral gray primary (#e4e7e5) on a neutral background (#000000).

Color palette

TokenLightDark
Background
#ffffffwhite
#000000black
Foreground
#010403black
#fcfdfcwhite
Card
#ffffffwhite
#000000black
Card foreground
#010403black
#fcfdfcwhite
Popover
#ffffffwhite
#000000black
Popover foreground
#010403black
#fcfdfcwhite
Primary
#e4e7e5gainsboro
#e4e7e5gainsboro
Primary foreground
#48514ddarkslategray
#48514ddarkslategray
Secondary
#e4e7e4gainsboro
#e4e7e4gainsboro
Secondary foreground
#485148darkslategray
#485148darkslategray
Muted
#dae2dagainsboro
#1d251dblack
Muted foreground
#3c443cdarkslategray
#bbc3bbsilver
Accent
#e4e7e7gainsboro
#e4e7e7gainsboro
Accent foreground
#485151darkslategray
#485151darkslategray
Destructive
#cc0505firebrick
#fa3333crimson
Destructive foreground
#ffffffwhite
#ffffffwhite
Border
#e5e7eblavender
#1f2937darkslategray
Input
#e5e7eblavender
#1f2937darkslategray
Ring
#e4e7e5gainsboro
#e4e7e5gainsboro

Contrast

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

Light mode
Text on background20.58:1AAA
Text on card20.58:1AAA
Primary button6.59:1AA
Secondary button6.61:1AA
Muted text7.61:1AAA
Accent6.56:1AA
Destructive5.85:1AA
Dark mode
Text on background20.59:1AAA
Text on card20.59:1AAA
Primary button6.59:1AA
Secondary button6.61:1AA
Muted text8.68:1AAA
Accent6.56:1AA
Destructive3.76:1AA Large

CSS variables

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

:root {
  --radius: 0.5rem;
  --background: oklch(1 0 180);
  --foreground: oklch(0.099 0.014 165.297);
  --muted: oklch(0.904 0.015 145.452);
  --muted-foreground: oklch(0.375 0.016 145.241);
  --popover: oklch(1 0 180);
  --popover-foreground: oklch(0.099 0.014 165.297);
  --card: oklch(1 0 180);
  --card-foreground: oklch(0.099 0.014 165.297);
  --border: oklch(0.928 0.006 264.531);
  --input: oklch(0.928 0.006 264.531);
  --primary: oklch(0.925 0.004 165.034);
  --primary-foreground: oklch(0.426 0.014 164.257);
  --secondary: oklch(0.925 0.005 145.533);
  --secondary-foreground: oklch(0.424 0.019 145.23);
  --accent: oklch(0.926 0.003 197.1);
  --accent-foreground: oklch(0.427 0.012 196.721);
  --destructive: oklch(0.532 0.216 29.02);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.925 0.004 165.034);
  --chart-1: oklch(0.925 0.004 165.034);
  --chart-2: oklch(0.925 0.005 145.533);
  --chart-3: oklch(0.926 0.003 197.1);
  --chart-4: oklch(0.948 0.004 145.547);
  --chart-5: oklch(0.926 0.006 164.979);
}

.dark {
  --radius: 0.5rem;
  --background: oklch(0 0 0);
  --foreground: oklch(0.994 0.002 165.082);
  --muted: oklch(0.255 0.02 144.955);
  --muted-foreground: oklch(0.809 0.014 145.449);
  --popover: oklch(0 0 0);
  --popover-foreground: oklch(0.994 0.002 165.082);
  --card: oklch(0 0 0);
  --card-foreground: oklch(0.994 0.002 165.082);
  --border: oklch(0.278 0.03 256.848);
  --input: oklch(0.278 0.03 256.848);
  --primary: oklch(0.925 0.004 165.034);
  --primary-foreground: oklch(0.426 0.014 164.257);
  --secondary: oklch(0.925 0.005 145.533);
  --secondary-foreground: oklch(0.424 0.019 145.23);
  --accent: oklch(0.926 0.003 197.1);
  --accent-foreground: oklch(0.427 0.012 196.721);
  --destructive: oklch(0.64 0.232 26.874);
  --destructive-foreground: oklch(1 0 180);
  --ring: oklch(0.925 0.004 165.034);
  --chart-1: oklch(0.925 0.004 165.034);
  --chart-2: oklch(0.925 0.005 145.533);
  --chart-3: oklch(0.926 0.003 197.1);
  --chart-4: oklch(0.948 0.004 145.547);
  --chart-5: oklch(0.926 0.006 164.979);
}