Loving is a shadcn/ui theme built around a near-black primary color (#010104) with near-black accents (#030104). The light mode uses a neutral background (#f8f8fc). Dark mode keeps the near-black primary (#010104) on an indigo-tinted background (#060410).
| Token | Light | Dark |
|---|---|---|
| Background | #f8f8fcghostwhite | #060410black |
| Foreground | #010104black | #ffffffwhite |
| Card | #f5f4fbwhitesmoke | #080514black |
| Card foreground | #000000black | #ffffffwhite |
| Popover | #f5f4fbwhitesmoke | #080514black |
| Popover foreground | #000000black | #ffffffwhite |
| Primary | #010104black | #010104black |
| Primary foreground | #b8aeeflightsteelblue | #b8aeeflightsteelblue |
| Secondary | #010204black | #010204black |
| Secondary foreground | #aec5eflightsteelblue | #aec5eflightsteelblue |
| Muted | #cbd5e6lightgrey | #192234darkslategray |
| Muted foreground | #494f5bdarkslategray | #a4abb6darkgray |
| Accent | #030104black | #030104black |
| Accent foreground | #d8aeefplum | #d8aeefplum |
| Destructive | #810d09maroon | #f13832crimson |
| Destructive foreground | #fbc3c1pink | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #010104black | #010104black |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.62:1 | AAA |
| Text on card | 19.17:1 | AAA |
| Primary button | 10.26:1 | AAA |
| Secondary button | 11.89:1 | AAA |
| Muted text | 5.55:1 | AA |
| Accent | 11.11:1 | AAA |
| Destructive | 6.87:1 | AA |
| Text on background | 20.30:1 | AAA |
| Text on card | 20.11:1 | AAA |
| Primary button | 10.26:1 | AAA |
| Secondary button | 11.89:1 | AAA |
| Muted text | 6.87:1 | AA |
| Accent | 11.11:1 | AAA |
| Destructive | 3.92:1 | AA Large |
Paste this into your globals.css to use Loving in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.98 0.006 293.184);
--foreground: oklch(0.074 0.02 290.965);
--muted: oklch(0.87 0.026 262.975);
--muted-foreground: oklch(0.426 0.021 262.894);
--popover: oklch(0.969 0.01 293.12);
--popover-foreground: oklch(0 0 0);
--card: oklch(0.969 0.01 293.12);
--card-foreground: oklch(0 0 0);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.073 0.021 290.903);
--primary-foreground: oklch(0.782 0.092 290.991);
--secondary: oklch(0.084 0.013 253.085);
--secondary-foreground: oklch(0.82 0.065 262.738);
--accent: oklch(0.081 0.022 316.572);
--accent-foreground: oklch(0.81 0.1 313.532);
--destructive: oklch(0.385 0.148 28.886);
--destructive-foreground: oklch(0.866 0.064 20.759);
--ring: oklch(0.073 0.021 290.903);
--chart-1: oklch(0.073 0.021 290.903);
--chart-2: oklch(0.084 0.013 253.085);
--chart-3: oklch(0.081 0.022 316.572);
--chart-4: oklch(0.134 0.023 255.813);
--chart-5: oklch(0.072 0.022 290.708);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.122 0.029 290.532);
--foreground: oklch(1 0 180);
--muted: oklch(0.253 0.036 262.331);
--muted-foreground: oklch(0.739 0.018 262.993);
--popover: oklch(0.133 0.033 289.49);
--popover-foreground: oklch(1 0 180);
--card: oklch(0.133 0.033 289.49);
--card-foreground: oklch(1 0 180);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.073 0.021 290.903);
--primary-foreground: oklch(0.782 0.092 290.991);
--secondary: oklch(0.084 0.013 253.085);
--secondary-foreground: oklch(0.82 0.065 262.738);
--accent: oklch(0.081 0.022 316.572);
--accent-foreground: oklch(0.81 0.1 313.532);
--destructive: oklch(0.628 0.221 27.765);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.073 0.021 290.903);
--chart-1: oklch(0.073 0.021 290.903);
--chart-2: oklch(0.084 0.013 253.085);
--chart-3: oklch(0.081 0.022 316.572);
--chart-4: oklch(0.134 0.023 255.813);
--chart-5: oklch(0.072 0.022 290.708);
}