CardGen hero
Beta Started 2026

CardGen

A printable greeting-card studio: a six-step wizard that turns art, message, and style into a fold-ready PDF, entirely in the browser.

  • TypeScript
  • SvelteKit
  • Svelte
  • pdf-lib
  • Tailwind
  • IndexedDB
  • Docker
  • Python
  • ReportLab
Started
2026
Status
beta
Platforms
Web · Docker

CardGen makes real, printable folded greeting cards: one letter-size page, folded down the center, front art on the outside and your message inside. A six-step wizard (Occasion → Front art → Message → Style → Preview → Print) carries you from a blank card to a fold-ready PDF without ever sending your card to a server.

Why it exists

It started as a pair of Python + ReportLab scripts for printing Mother’s Day cards on the family Canon, with fold geometry calibrated against the actual printer. The scripts worked well enough that the idea deserved a real interface, so the same geometry became a full SvelteKit wizard anyone in the family can use.

Highlights

  • Seventeen occasion presets (from birthdays and weddings to Hanukkah and get-well cards) plus a fully custom mode, each seeding sensible art, palette, and message defaults.
  • Four ways to get front art onto one canvas editor: upload with transform tools, generated templates, AI generation (server-proxied so the API key never reaches the browser, and cleanly disabled when unconfigured), and a 65-image curated library.
  • The PDF renders client-side with pdf-lib and embedded fonts: no server round-trip, works offline. Preview and PDF share a single geometry module, so the preview is the PDF.
  • No accounts and no server state: drafts auto-persist to localStorage, with binary art assets in IndexedDB, so a half-finished card survives a closed tab.
  • Output is regression-tested with PDF byte-diff reference fixtures alongside unit and Playwright end-to-end suites.
  • Styled with Aurora Core (v5.4.2 tokens) through a vendored Tailwind preset.

Technical approach

SvelteKit 2 on Svelte 5, with the deployment adapter switched by environment: Vercel serverless or a Dockerized Node build from the same codebase. Card geometry lives in one constants module consumed by both the live preview and the pdf-lib renderer, and text layout runs the same wrap logic in both paths; the overflow warning you see while typing is computed against the real print box. The original Python/ReportLab tool remains in the repo with its printer calibration guide as the reference implementation.