Browser-only React + TypeScript app that builds mathematically valid Dobble/Spot-It decks (finite projective planes of prime order). Upload your own PNG symbols, generate random layouts, tweak placements by dragging on the preview canvas, then export PNGs, a PDF, or JSON metadata.
Example symbols for quick tries live in
./examples(enough for order 2 or 3).
- Node.js 18+ and npm (or pnpm/yarn if you prefer)
- A modern browser
# Linux / macOS (npm)
npm install
npm run dev
# open the shown localhost URL# Windows (PowerShell, npm)
npm install
npm run dev
# open the shown localhost URLIf you want a one-liner helper, use the install scripts below.
./install.shThis installs dependencies and starts the dev server.
.\install.batThis installs dependencies and starts the dev server.
- Install Node.js 18+ (via your package manager or https://nodejs.org/).
- Clone the repo and
cdinto it. npm installnpm run dev- Open the printed localhost URL in your browser.
- Install Node.js 18+ from https://nodejs.org/.
- Open PowerShell or Command Prompt.
- Navigate to the repo folder.
npm installnpm run dev- Open the printed localhost URL in your browser.
- Pick order q (2, 3, 5, 7, or 11). Derived counts are shown.
- Upload images: at least
q^2 + q + 1PNGs. Extras are ignored for now. Example assets:./examples(enough for order 2 or 3). - Layout settings: adjust card size, scales, margins, overlap, circle/square, border, optional seed.
- Generate layouts: creates a randomized layout per card (centered distribution to reduce lopsided cards).
- Preview: scrub through cards; drag symbols directly on the canvas to fine-tune placements; regenerate one or all cards if desired.
- Export:
- PNGs ZIP (one file per card)
- PDF (1-per-page or 2×2 grid toggle)
- JSON metadata (symbols + placements)
Notes:
- Changing the order resets layouts and requires enough images for the new size.
- Layout generation enforces the mathematical property: each pair of cards shares exactly one symbol.
- Drag edits persist in exports.
npm run dev– start dev servernpm run build– production buildnpm run preview– preview production build locallynpm run typecheck– TypeScript project check