An independent Three.js editorial bookshelf. The included demo catalog features nineteen Stripe Press titles, while the application is designed to be forked and filled with books of your own.
This project is not affiliated with or endorsed by Stripe. “Stripe” and “Stripe Press” are trademarks of their respective owner.
- Drag, scroll, use arrow keys, or select a shelf tick to browse.
- Pull a volume forward, then orbit, pan, zoom, and reset the inspection view.
- Generate a deterministic procedural hardcover from catalog metadata.
- Optionally replace a generated front cover with contributor-owned artwork.
- Preserve a working shelf when optional images or edition assets are absent.
- Respect reduced-motion preferences and keyboard navigation.
Requires Node.js 22.13 or newer.
npm ci
npm run devBefore submitting a change, run:
npm run check
npm run security:auditThe short version:
- Add an object to
app/catalog.ts. - Optionally put a cover image at
public/books/<book-id>/cover.webpand setcoverImage: "/books/<book-id>/cover.webp". - Edit
app/site-config.tsif you are replacing the demo collection or branding. - Run
npm run check.
No cover image is required. The title, author, palette, and motif in the catalog are enough to produce a complete procedural hardcover.
See Adding books for the full field reference, a copy-paste example, image guidance, ordering behavior, and troubleshooting.
The open-source distribution intentionally excludes downloaded Stripe Press
geometry, cover textures, compiled site JavaScript, page captures, PDFs, and
archives. The optional local adapter still works for a checkout whose owner has
separately obtained the necessary rights, but public/assets/stripe-press/ is
gitignored and is not required by the application.
Contributor-owned cover images belong under public/books/. Only commit art,
quotes, descriptions, and other material that you created or are authorized to
redistribute. Public availability is not the same as an open-source license.
See Third-party notices for details.
app/catalog.ts— book metadata, palette, dimensions, and optional coversapp/site-config.ts— collection-level title, labels, and metadataapp/ShelfEngine.ts— renderer, shelf layout, input, animation, and assetsapp/cover-art.ts— deterministic procedural cover generatorapp/book-motion.ts— collision-safe browse and focus posespublic/books/— contributor-owned cover imagestests/— server-render and shelf-motion regression tests
For a detailed explanation of the object hierarchy, state machine, easing, damping, collision safety, camera framing, performance decisions, and tuning knobs, read Motion, objects, and animation feel.
The package remains marked "private": true to prevent accidental publication
to npm. This does not prevent the source repository from being public.
Local development does not require a deployment account. If you connect the
checkout to OpenAI Sites, the integration creates .openai/hosting.json.
That machine-specific project association is gitignored so forks select their
own deployment target. See the local deployment note.
The repository includes two optional pieces for Mint-assisted 3D work:
.codex/config.tomlregisters the production Mint MCP server as a repo-scoped OAuth connection..agents/skills/mint-threejs-skillsvendors the official Mint Three.js Skills suite at upstream commite563354.
Mint is not required to run or customize the shelf. Contributors who want it
can trust the repository in Codex and run codex mcp login mint; OAuth
credentials remain outside the repository.
Read CONTRIBUTING.md before opening a pull request. Report security issues using the private process in SECURITY.md.