Attachment is a shadcn/ui theme built around a violet primary color (#9c81c5) with muted light violet accents (#c9beda). The light mode uses a neutral background (#faf8fc). Dark mode keeps the violet primary (#9c81c5) on a neutral background (#050208).
| Token | Light | Dark |
|---|---|---|
| Background | #faf8fcghostwhite | #050208black |
| Foreground | #020104black | #f7f4fawhitesmoke |
| Card | #faf8fcghostwhite | #050208black |
| Card foreground | #020104black | #f7f4fawhitesmoke |
| Popover | #faf8fcghostwhite | #050208black |
| Popover foreground | #020104black | #f7f4fawhitesmoke |
| Primary | #9c81c5mediumpurple | #9c81c5mediumpurple |
| Primary foreground | #09060eblack | #09060eblack |
| Secondary | #dad5e2gainsboro | #28262bdarkslategray |
| Secondary foreground | #40364fdarkslategray | #c1bec5silver |
| Muted | #dbd8dfgainsboro | #232027black |
| Muted foreground | #3e3649darkslategray | #bdb6c9silver |
| Accent | #c9bedathistle | #3c3545darkslategray |
| Accent foreground | #302541darkslategray | #d5d1dclightgrey |
| Destructive | #aa4513sienna | #e65d1achocolate |
| Destructive foreground | #ffffffwhite | #ffffffwhite |
| Border | #e5e7eblavender | #1f2937darkslategray |
| Input | #e5e7eblavender | #1f2937darkslategray |
| Ring | #9c81c5mediumpurple | #9c81c5mediumpurple |
WCAG 2 contrast ratios between each background and its foreground color.
| Text on background | 19.70:1 | AAA |
| Text on card | 19.70:1 | AAA |
| Primary button | 6.11:1 | AA |
| Secondary button | 7.82:1 | AAA |
| Muted text | 8.14:1 | AAA |
| Accent | 8.10:1 | AAA |
| Destructive | 5.88:1 | AA |
| Text on background | 18.90:1 | AAA |
| Text on card | 18.90:1 | AAA |
| Primary button | 6.11:1 | AA |
| Secondary button | 8.12:1 | AAA |
| Muted text | 8.14:1 | AAA |
| Accent | 7.81:1 | AAA |
| Destructive | 3.53:1 | AA Large |
Paste this into your globals.css to use Attachment in your shadcn/ui project.
:root {
--radius: 0.5rem;
--background: oklch(0.981 0.005 304.266);
--foreground: oklch(0.078 0.02 305.641);
--muted: oklch(0.886 0.009 304.197);
--muted-foreground: oklch(0.35 0.034 302.933);
--popover: oklch(0.981 0.005 304.266);
--popover-foreground: oklch(0.078 0.02 305.641);
--card: oklch(0.981 0.005 304.266);
--card-foreground: oklch(0.078 0.02 305.641);
--border: oklch(0.928 0.006 264.531);
--input: oklch(0.928 0.006 264.531);
--primary: oklch(0.655 0.103 302.025);
--primary-foreground: oklch(0.134 0.018 303.927);
--secondary: oklch(0.88 0.019 304.031);
--secondary-foreground: oklch(0.353 0.045 302.498);
--accent: oklch(0.82 0.04 303.648);
--accent-foreground: oklch(0.291 0.051 301.739);
--destructive: oklch(0.519 0.145 42.661);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.655 0.103 302.025);
--chart-1: oklch(0.655 0.103 302.025);
--chart-2: oklch(0.88 0.019 304.031);
--chart-3: oklch(0.82 0.04 303.648);
--chart-4: oklch(0.906 0.015 304.107);
--chart-5: oklch(0.651 0.111 301.805);
}
.dark {
--radius: 0.5rem;
--background: oklch(0.102 0.02 305.332);
--foreground: oklch(0.972 0.008 304.226);
--muted: oklch(0.251 0.013 303.632);
--muted-foreground: oklch(0.787 0.028 303.836);
--popover: oklch(0.102 0.02 305.332);
--popover-foreground: oklch(0.972 0.008 304.226);
--card: oklch(0.102 0.02 305.332);
--card-foreground: oklch(0.972 0.008 304.226);
--border: oklch(0.278 0.03 256.848);
--input: oklch(0.278 0.03 256.848);
--primary: oklch(0.655 0.103 302.025);
--primary-foreground: oklch(0.134 0.018 303.927);
--secondary: oklch(0.274 0.009 303.858);
--secondary-foreground: oklch(0.806 0.011 304.155);
--accent: oklch(0.343 0.029 303.145);
--accent-foreground: oklch(0.867 0.015 304.095);
--destructive: oklch(0.647 0.184 42.222);
--destructive-foreground: oklch(1 0 180);
--ring: oklch(0.655 0.103 302.025);
--chart-1: oklch(0.655 0.103 302.025);
--chart-2: oklch(0.274 0.009 303.858);
--chart-3: oklch(0.343 0.029 303.145);
--chart-4: oklch(0.304 0.011 303.837);
--chart-5: oklch(0.651 0.111 301.805);
}