Components built for Puzzle
PUZZLE PIECES
Over 100 accessible components for Puzzle apps. No lock-in. Real code, one command away.
Quick start
From zero to interface in three steps
Add the piece
$ puzzle add piece buttonThe CLI drops the
.pzlfile and any lib helpers it needs into your app, and copies the default theme on the first add. It prints the stylesheet import and any npm install command for you to run.Import it
import Button from '@/components/ui/Button.pzl';A normal import of a normal file. Your compiler sees it, Tailwind scans it, your editor jumps straight to the source.
Use it
<Button variant="primary" @press={ save }>Save</Button>Config flows in through props, values flow back through callbacks, and the parent keeps the state. Then change whatever you like. It's your file now.
Charts, calendars, command menus
Over 100 pieces
Dashboard
Revenue
$128,430
Active users
8,912
| week | Desktop | Mobile | Tablet |
|---|---|---|---|
| W1 | 3.2k | 4.1k | 700 |
| W2 | 3.4k | 4.3k | 650 |
| W3 | 3.3k | 4.6k | 720 |
| W4 | 3.6k | 4.8k | 680 |
| W5 | 3.5k | 5.1k | 640 |
| W6 | 3.8k | 5.3k | 700 |
| W7 | 3.7k | 5.6k | 660 |
| W8 | 3.9k | 5.9k | 690 |
Invoices
| Invoice | Client | Status | Amount | |
|---|---|---|---|---|
| INV-1042 | Acme Inc. | Paid | 1200 | |
| INV-1043 | Globex | Pending | 980 | |
| INV-1044 | Initech | Paid | 3450 | |
| INV-1045 | Umbrella Co. | Overdue | 540 | |
| INV-1046 | Soylent | Draft | 120 |
Click a header to sort. Selection survives the re-sort.
Make it yours
Four themes in the registry
Every component styles itself only through semantic tokens, so switching data-scheme restyles everything at once. All four palettes support dark, dim, mixed, and light styles, for sixteen appearances.
Default
Balanced cool neutrals, indigo accent
Warm
Warm neutrals, terracotta accent
Void
Monochrome, very black, high contrast
Cool
A little more blue — blue-black grounds and periwinkle type, a lit-blue accent.
Built for everyone
Accessible by default.
Native dialog overlays
Dialogs and the command palette use the native dialog element with showModal(), so the browser provides focus trapping, Escape handling, and an inert page.
Keyboard first
The command palette supports arrow navigation and Enter; tabs and sliders add Home/End movement.
ARIA wired in
Labels, roles, and state attributes ship in the markup, not left as an exercise.