Hometown is a shadcn/ui theme built around a light purple primary color (#f0dcf4) with light pink accents (#f4dcec). The light mode uses a neutral background (#fdfbfe). Dark mode keeps the light purple primary (#f0dcf4) on a purple-tinted background (#0e0410).
| Token | Light | Dark |
|---|---|---|
| Background | #fdfbfewhite | #0e0410black |
| Foreground | #0b030cblack | #fdfcfdwhite |
| Card | #fdfbfewhite | #0e0410black |
| Card foreground | #0b030cblack | #fdfcfdwhite |
| Popover | #fdfbfewhite | #0e0410black |
| Popover foreground | #0b030cblack | #fdfcfdwhite |
| Primary | #f0dcf4lavender | #f0dcf4lavender |
| Primary foreground | #6a2777rebeccapurple | #6a2777rebeccapurple |
| Secondary | #e4dcf4lavender | #e4dcf4lavender |
| Secondary foreground | #422777darkslateblue | #422777darkslateblue |
| Muted | #e2e2e4gainsboro | #1c1b1dblack |
| Muted foreground | #514b5ddarkslategray | #a8a2b4darkgray |
| Accent | #f4dcecmistyrose | #f4dcecmistyrose |
| Accent foreground | #77275cpurple | #77275cpurple |
| Destructive | #ae1c09firebrick | #f44a34tomato |
| Destructive foreground | #feeeecseashell | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #f0dcf4lavender | #f0dcf4lavender |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.77:1 | AAA |
| Text on card | 19.77:1 | AAA |
| Primary button | 7.50:1 | AAA |
| Secondary button | 8.88:1 | AAA |
| Muted text | 6.44:1 | AA |
| Accent | 7.32:1 | AAA |
| Destructive | 6.25:1 | AA |
| Text on background | 19.62:1 | AAA |
| Text on card | 19.62:1 | AAA |
| Primary button | 7.50:1 | AAA |
| Secondary button | 8.88:1 | AAA |
| Muted text | 6.96:1 | AA |
| Accent | 7.32:1 | AAA |
| Destructive | 3.56:1 | AA Large |
Paste this into your globals.css to use Hometown in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.991 0.005 320.539);
--foreground: oklch(0.122 0.029 322.132);
--muted: oklch(0.913 0.004 301.424);
--muted-foreground: oklch(0.426 0.031 300.306);
--popover: oklch(0.991 0.005 320.539);
--popover-foreground: oklch(0.122 0.029 322.132);
--card: oklch(0.991 0.005 320.539);
--card-foreground: oklch(0.122 0.029 322.132);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.918 0.038 320.594);
--primary-foreground: oklch(0.406 0.143 320.579);
--secondary: oklch(0.909 0.033 300.915);
--secondary-foreground: oklch(0.354 0.131 294.006);
--accent: oklch(0.919 0.033 337.97);
--accent-foreground: oklch(0.412 0.129 343.358);
--destructive: oklch(0.484 0.182 30.914);
--destructive-foreground: oklch(0.961 0.018 26.572);
--ring: oklch(0.918 0.038 320.594);
--chart-1: oklch(0.918 0.038 320.594);
--chart-2: oklch(0.909 0.033 300.915);
--chart-3: oklch(0.919 0.033 337.97);
--chart-4: oklch(0.939 0.022 301.124);
--chart-5: oklch(0.917 0.04 320.598);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.135 0.032 321.455);
--foreground: oklch(0.992 0.002 320.535);
--muted: oklch(0.223 0.006 301.092);
--muted-foreground: oklch(0.722 0.027 300.883);
--popover: oklch(0.135 0.032 321.455);
--popover-foreground: oklch(0.992 0.002 320.535);
--card: oklch(0.135 0.032 321.455);
--card-foreground: oklch(0.992 0.002 320.535);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.918 0.038 320.594);
--primary-foreground: oklch(0.406 0.143 320.579);
--secondary: oklch(0.909 0.033 300.915);
--secondary-foreground: oklch(0.354 0.131 294.006);
--accent: oklch(0.919 0.033 337.97);
--accent-foreground: oklch(0.412 0.129 343.358);
--destructive: oklch(0.65 0.21 30.837);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.918 0.038 320.594);
--chart-1: oklch(0.918 0.038 320.594);
--chart-2: oklch(0.909 0.033 300.915);
--chart-3: oklch(0.919 0.033 337.97);
--chart-4: oklch(0.939 0.022 301.124);
--chart-5: oklch(0.917 0.04 320.598);
}