Canvas is a shadcn/ui theme built around a blue primary color (#3791cd) with orange accents (#cd7337). The light mode uses a neutral background (#f8fafc). Dark mode keeps the blue primary (#3791cd) on a blue-tinted background (#070b0d).
| Token | Light | Dark |
|---|---|---|
| Background | #f8fafcghostwhite | #070b0dblack |
| Foreground | #020608black | #f5f8fawhitesmoke |
| Card | #f8fafcghostwhite | #070b0dblack |
| Card foreground | #020608black | #f5f8fawhitesmoke |
| Popover | #f8fafcghostwhite | #070b0dblack |
| Popover foreground | #020608black | #f5f8fawhitesmoke |
| Primary | #3791cdsteelblue | #3791cdsteelblue |
| Primary foreground | #ffffffwhite | #ffffffwhite |
| Secondary | #cd7337peru | #cd7337peru |
| Secondary foreground | #000000black | #000000black |
| Muted | #f2efedwhitesmoke | #120f0dblack |
| Muted foreground | #544840darkolivegreen | #bfb3abdarkgray |
| Accent | #cd7337peru | #cd7337peru |
| Accent foreground | #000000black | #000000black |
| Destructive | #6b2405maroon | #f5692etomato |
| Destructive foreground | #fbc0a7lightpink | #000000black |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #3791cdsteelblue | #3791cdsteelblue |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.47:1 | AAA |
| Text on card | 19.47:1 | AAA |
| Primary button | 3.44:1 | AA Large |
| Secondary button | 6.10:1 | AA |
| Muted text | 7.72:1 | AAA |
| Accent | 6.10:1 | AA |
| Destructive | 7.02:1 | AAA |
| Text on background | 18.53:1 | AAA |
| Text on card | 18.53:1 | AAA |
| Primary button | 3.44:1 | AA Large |
| Secondary button | 6.10:1 | AA |
| Muted text | 9.33:1 | AAA |
| Accent | 6.10:1 | AA |
| Destructive | 6.96:1 | AA |
Paste this into your globals.css to use Canvas in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.985 0.004 236.492);
--foreground: oklch(0.115 0.013 228.862);
--muted: oklch(0.954 0.004 56.371);
--muted-foreground: oklch(0.411 0.02 55.759);
--popover: oklch(0.985 0.004 236.492);
--popover-foreground: oklch(0.115 0.013 228.862);
--card: oklch(0.985 0.004 236.492);
--card-foreground: oklch(0.115 0.013 228.862);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.63 0.123 241.943);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.646 0.135 51.581);
--secondary-foreground: oklch(0 0 0);
--accent: oklch(0.646 0.135 51.581);
--accent-foreground: oklch(0 0 0);
--destructive: oklch(0.364 0.109 40.014);
--destructive-foreground: oklch(0.855 0.076 44.287);
--ring: oklch(0.63 0.123 241.943);
--chart-1: oklch(0.63 0.123 241.943);
--chart-2: oklch(0.646 0.135 51.581);
--chart-3: oklch(0.646 0.135 51.581);
--chart-4: oklch(0.666 0.127 52.447);
--chart-5: oklch(0.633 0.128 242.365);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.145 0.009 235.223);
--foreground: oklch(0.977 0.004 236.493);
--muted: oklch(0.17 0.007 55.887);
--muted-foreground: oklch(0.775 0.017 56.129);
--popover: oklch(0.145 0.009 235.223);
--popover-foreground: oklch(0.977 0.004 236.493);
--card: oklch(0.145 0.009 235.223);
--card-foreground: oklch(0.977 0.004 236.493);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.63 0.123 241.943);
--primary-foreground: oklch(1 0 180);
--secondary: oklch(0.646 0.135 51.581);
--secondary-foreground: oklch(0 0 0);
--accent: oklch(0.646 0.135 51.581);
--accent-foreground: oklch(0 0 0);
--destructive: oklch(0.687 0.186 41.277);
--destructive-foreground: oklch(0 0 0);
--ring: oklch(0.63 0.123 241.943);
--chart-1: oklch(0.63 0.123 241.943);
--chart-2: oklch(0.646 0.135 51.581);
--chart-3: oklch(0.646 0.135 51.581);
--chart-4: oklch(0.666 0.127 52.447);
--chart-5: oklch(0.633 0.128 242.365);
}