Palette Library
Storybook
A playful palette for education with a blue primary and an orange accent. Text reaches 17.83:1 in light mode and 14.91:1 in dark mode.
How to use it
Storybook's roles on a real interface, with the ratios stored for this palette.
- Light mode: page #feffff, cards #eaf0f7, and text #0f1823 at 17.83:1; buttons #2f6fb0 with #feffff labels at 5.21:1; highlights #fb923c with #0f1823 text at 7.89:1.
- Dark mode: page #07090b, cards #111214, and text #dcdfe3 at 14.91:1; buttons #65a5ea with #07090b labels at 7.71:1; highlights #fb923c with #07090b text at 8.81:1.
- Links: #2f6fb0 reaches 5.21:1 on the light page, and #65a5ea reaches 7.71:1 on the dark page.
- The accent as text: In light mode, keep #fb923c for fills and badges, not text: it reaches only 2.25:1 on the page.
Preview
The same palette on a small interface in light and dark.
Light mode
A place for your ideas
Start with colors that work together.
Your next project
A surface for the details that matter.
NewExplore your palette →
Dark mode
A place for your ideas
Start with colors that work together.
Your next project
A surface for the details that matter.
NewExplore your palette →
Roles
Five roles and their two foregrounds. Copy the exact HEX values.
| Role | Light | Dark |
|---|---|---|
| Background | #feffff | #07090b |
| Surface | #eaf0f7 | #111214 |
| Text | #0f1823 | #dcdfe3 |
| Primary | #2f6fb0 | #65a5ea |
| Primary Foreground | #feffff | #07090b |
| Accent | #fb923c | #fb923c |
| Accent Foreground | #0f1823 | #07090b |
Contrast matrix
Five required pairs per mode, judged on the final 8-bit colors.
Light mode
Scroll the table sideways on a small screen.
| Foreground / Background | Background | Surface | Primary | Accent |
|---|---|---|---|---|
| Text | 17.83:1AAArequired | 15.57:1AAArequired | 3.42:1AA large | 7.89:1AAA |
| Primary | 5.21:1AArequired | 4.55:1AA | 1.00:1Fail | 2.30:1Fail |
| Accent | 2.25:1Fail | 1.97:1Fail | 2.30:1Fail | 1.00:1Fail |
| Primary Foreground | 1.00:1Fail | 1.14:1Fail | 5.21:1AArequired | 2.25:1Fail |
| Accent Foreground | 17.83:1AAA | 15.57:1AAA | 3.42:1AA large | 7.89:1AAArequired |
Dark mode
Scroll the table sideways on a small screen.
| Foreground / Background | Background | Surface | Primary | Accent |
|---|---|---|---|---|
| Text | 14.91:1AAArequired | 14.01:1AAArequired | 1.93:1Fail | 1.69:1Fail |
| Primary | 7.71:1AAArequired | 7.25:1AAA | 1.00:1Fail | 1.14:1Fail |
| Accent | 8.81:1AAA | 8.28:1AAA | 1.14:1Fail | 1.00:1Fail |
| Primary Foreground | 1.00:1Fail | 1.06:1Fail | 7.71:1AAArequired | 8.81:1AAA |
| Accent Foreground | 1.00:1Fail | 1.06:1Fail | 7.71:1AAA | 8.81:1AAArequired |
AAA: normal text ≥ 7:1. AA: normal text ≥ 4.5:1. AA large: large text ≥ 3:1 (24 px, or 18.66 px bold). UI: required component contrast ≥ 3:1. Fail: below 3:1. Required marks the five pairs ColorLint checks in each mode. Other pairs are informational.
ColorLint checks color contrast only. Passing pairs do not mean a page is accessible.
Exports
Both modes, with the exact values the Palette Generator exports.
CSS variables
/* ColorLint palette (v1). Light values in :root; dark values in .dark. */
:root {
--background: #feffff;
--surface: #eaf0f7;
--text: #0f1823;
--primary: #2f6fb0;
--primary-foreground: #feffff;
--accent: #fb923c;
--accent-foreground: #0f1823;
}
.dark {
--background: #07090b;
--surface: #111214;
--text: #dcdfe3;
--primary: #65a5ea;
--primary-foreground: #07090b;
--accent: #fb923c;
--accent-foreground: #07090b;
}
Tailwind v4
/* ColorLint palette for Tailwind CSS v4 (palette v1). */
/* Paste after @import "tailwindcss". Add the "dark" class to <html> for dark mode. */
@custom-variant dark (&:where(.dark, .dark *));
:root {
color-scheme: light;
--background: #feffff;
--surface: #eaf0f7;
--text: #0f1823;
--primary: #2f6fb0;
--primary-foreground: #feffff;
--accent: #fb923c;
--accent-foreground: #0f1823;
}
.dark {
color-scheme: dark;
--background: #07090b;
--surface: #111214;
--text: #dcdfe3;
--primary: #65a5ea;
--primary-foreground: #07090b;
--accent: #fb923c;
--accent-foreground: #07090b;
}
@theme inline {
--color-background: var(--background);
--color-surface: var(--surface);
--color-text: var(--text);
--color-primary: var(--primary);
--color-primary-foreground: var(--primary-foreground);
--color-accent: var(--accent);
--color-accent-foreground: var(--accent-foreground);
}
Compared with similar palettes
- Compared with Classroom Pop, which shares the playful style: text reaches 17.83:1 in light mode against 18.07:1, the primary is blue where Classroom Pop's is red, and the accent is orange where Classroom Pop's is blue.
- Compared with Reef Explorer, which shares the playful style: text reaches 17.83:1 in light mode against 15.30:1, both use a blue primary, and both use a orange accent.