Skip to content

listing: rebuild unbaked projects live from the published graph - #3

Merged
wass08 merged 1 commit into
mainfrom
listing/live-rebuild
Nov 10, 2026
Merged

wass08 merged 1 commit into
mainfrom
listing/live-rebuild

Conversation

@wass08

@wass08 wass08 commented Nov 10, 2026

Copy link
Copy Markdown
Contributor

Unbaked projects now render in the listing template by rebuilding the building live from the published scene graph, using the published @pascal-app/core, viewer and nodes 1.1.0.

  • PASCAL_SOURCE (VITE_PASCAL_SOURCE) takes one of three values:
    • auto (the default) shows the bake when it's ready and live otherwise.
    • baked keeps the previous "no 3D file yet" state.
    • live always rebuilds from the graph.
  • In auto mode, while a bake is running the template shows live, polls every 30 s, then switches to the GLB once it's ready. Polls and credential renewals that return the same revision keep the mounted scene instead of rebuilding it.
  • src/viewer/LiveViewer.tsx mirrors the packed fixture from viewer: render live scenes in any browser app, proven by a packed fixture editor#1250: render plugin, read-only lease, library materials, readiness callback. It keeps the listing's room hover, floor picker cutaway and door/window toggles.
  • The live path is code-split, so visitors to baked projects don't download the Pascal runtime. Main entry: 73 kB gzip. Live runtime: about 1.1 MB gzip, loaded only when needed.
  • CSP: connect-src allows the default Draco/Basis decoder hosts, plus data:/blob: for embedded glTF buffers.

Verification:

  • npm run typecheck, npm run build and Playwright pass, 27/27. New tests cover live rendering for bake statuses none, failed, baking and ready-without-LODs, and the switch from live to baked.
  • A production build pointed at editor.pascal.app rendered 3 never-baked public projects live with no console errors (project_2b41L7l0eYE7kK0p, project_4PrkF4SgUcFsy207, project_6mDJNGmVXE2nAKNY).

Stacked on #2.

🤖 Generated with Claude Code

@wass08
wass08 changed the base branch from listing/pascal-handoff to main November 10, 2026 15:06
PASCAL_SOURCE (auto by default) shows the bake when ready and otherwise
renders the graph with the published @pascal-app/core, viewer and nodes
1.1.0. The live path is code-split; while a bake runs it polls and switches
to the GLB once ready, keeping the mounted scene across unchanged re-reads.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@wass08
wass08 force-pushed the listing/live-rebuild branch from f83e39f to e38dff0 Compare November 10, 2026 15:06
@wass08
wass08 merged commit 85460a3 into main Nov 10, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant