Hipster is a shadcn/ui theme built around a near-white primary color (#ededed) with muted blue accents (#476380). The light mode uses a blue-tinted background (#2b3d4f). Dark mode keeps the near-white primary (#ededed) on a blue-tinted background (#2b3d4f).
| Token | Light | Dark |
|---|---|---|
| Background | #2b3d4fdarkslategray | #2b3d4fdarkslategray |
| Foreground | #edf1f2whitesmoke | #edf1f2whitesmoke |
| Card | #283848darkslategray | #283848darkslategray |
| Card foreground | #fcfdfdwhite | #fcfdfdwhite |
| Popover | #263645darkslategray | #263645darkslategray |
| Popover foreground | #ffffffwhite | #ffffffwhite |
| Primary | #edededwhitesmoke | #edededwhitesmoke |
| Primary foreground | #545454dimgray | #545454dimgray |
| Secondary | #404040darkslategray | #404040darkslategray |
| Secondary foreground | #d9d9d9gainsboro | #d9d9d9gainsboro |
| Muted | #3f4750darkslategray | #3f4750darkslategray |
| Muted foreground | #c0c7cesilver | #c0c7cesilver |
| Accent | #476380darkslateblue | #476380darkslateblue |
| Accent foreground | #fcfcfdwhite | #fcfcfdwhite |
| Destructive | #f14232tomato | #f14232tomato |
| Destructive foreground | #ffffffwhite | #ffffffwhite |
| Border | #3c4a58darkslategray | #3c4a58darkslategray |
| Input | #425261darkslategray | #425261darkslategray |
| Ring | #edededwhitesmoke | #edededwhitesmoke |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 9.77:1 | AAA |
| Text on card | 11.76:1 | AAA |
| Primary button | 6.47:1 | AA |
| Secondary button | 7.37:1 | AAA |
| Muted text | 5.49:1 | AA |
| Accent | 6.05:1 | AA |
| Destructive | 3.78:1 | AA Large |
| Text on background | 9.77:1 | AAA |
| Text on card | 11.76:1 | AAA |
| Primary button | 6.47:1 | AA |
| Secondary button | 7.37:1 | AAA |
| Muted text | 5.49:1 | AA |
| Accent | 6.05:1 | AA |
| Destructive | 3.78:1 | AA Large |
Paste this into your globals.css to use Hipster in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.353 0.039 248.97);
--foreground: oklch(0.956 0.004 214.328);
--muted: oklch(0.395 0.018 248.291);
--muted-foreground: oklch(0.826 0.012 247.973);
--popover: oklch(0.324 0.035 248.936);
--popover-foreground: oklch(1 0 180);
--card: oklch(0.334 0.036 248.948);
--card-foreground: oklch(0.993 0.001 214.319);
--border: oklch(0.402 0.03 248.572);
--input: oklch(0.43 0.032 248.584);
--primary: oklch(0.947 0 180);
--primary-foreground: oklch(0.446 0 180);
--secondary: oklch(0.371 0 168.69);
--secondary-foreground: oklch(0.885 0 180);
--accent: oklch(0.491 0.058 249.074);
--accent-foreground: oklch(0.992 0.001 247.834);
--destructive: oklch(0.636 0.214 29.497);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.947 0 180);
--chart-1: oklch(0.947 0 180);
--chart-2: oklch(0.371 0 168.69);
--chart-3: oklch(0.491 0.058 249.074);
--chart-4: oklch(0.399 0 180);
--chart-5: oklch(0.946 0.001 17.178);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.353 0.039 248.97);
--foreground: oklch(0.956 0.004 214.328);
--muted: oklch(0.395 0.018 248.291);
--muted-foreground: oklch(0.826 0.012 247.973);
--popover: oklch(0.324 0.035 248.936);
--popover-foreground: oklch(1 0 180);
--card: oklch(0.334 0.036 248.948);
--card-foreground: oklch(0.993 0.001 214.319);
--border: oklch(0.402 0.03 248.572);
--input: oklch(0.43 0.032 248.584);
--primary: oklch(0.947 0 180);
--primary-foreground: oklch(0.446 0 180);
--secondary: oklch(0.371 0 168.69);
--secondary-foreground: oklch(0.885 0 180);
--accent: oklch(0.491 0.058 249.074);
--accent-foreground: oklch(0.992 0.001 247.834);
--destructive: oklch(0.636 0.214 29.497);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.947 0 180);
--chart-1: oklch(0.947 0 180);
--chart-2: oklch(0.371 0 168.69);
--chart-3: oklch(0.491 0.058 249.074);
--chart-4: oklch(0.399 0 180);
--chart-5: oklch(0.946 0.001 17.178);
}