48 Commits

Author SHA1 Message Date
Wassim SAMAD
36c48b7fc9 chore: biome auto-format pass (resolve persistent dirty-tree noise)
These files had been showing as modified in every dev session — biome's
canonical formatting (line-length collapses, import sort, type-modifier
placement) didn't match the committed state. No semantic changes.
Committing now so the working tree stays clean across sessions.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-15 18:19:15 -04:00
sudhir
564bfa229e Merge remote-tracking branch 'origin/main' into fix/fri-8-may
# Conflicts:
#	packages/editor/src/components/tools/fence/move-fence-endpoint-tool.tsx
#	packages/editor/src/components/tools/select/box-select-tool.tsx
#	packages/editor/src/components/tools/wall/move-wall-tool.tsx
#	packages/editor/src/components/ui/panels/column-panel.tsx
#	packages/editor/src/components/ui/panels/door-panel.tsx
#	packages/editor/src/components/ui/panels/window-panel.tsx
#	packages/viewer/src/components/renderers/column/column-renderer.tsx
#	packages/viewer/src/components/viewer/index.tsx
#	packages/viewer/src/systems/slab/slab-system.tsx
2026-05-12 00:27:06 +05:30
sudhir
be41511474 Fix wall move junction ownership 2026-05-11 23:46:57 +05:30
Wawa
e618175bba Reset core/viewer/editor/mcp packages and apps/editor from private-editor
Wholesale swap of packages/{core,viewer,editor,mcp} and apps/editor with the
versions from the private editor repo, which is the production source of truth.

Setup changes:
- packages/{core,viewer,editor} versions held at 0.7.0 baseline (matching
  the most recent published release) so a bump=minor publishes 0.8.0
- packages/mcp held at 0.1.1 (never published; first publish will go through
  the new release.yml flow)
- peerDependencies and devDependencies for inter-package @pascal-app/*
  references pinned to ^0.7.0 instead of '*' / 'workspace:*' so they are
  valid for npm consumers
- Root package.json: TypeScript bumped to 6.0.2, added overrides for
  @types/react, @types/react-dom, @types/three to prevent JSX namespace
  fragmentation across the workspace
- release.yml extended to also publish editor and mcp; 'both' option renamed
  to 'all'; added a sync step that updates inter-package peerDeps/devDeps to
  match the new versions on every bump (so viewer/editor/mcp tarballs always
  reference the version of core they were built against)
- Root scripts gained release:editor and release:mcp shortcuts

Verification:
- bun install --frozen-lockfile is consistent
- packages/{core,viewer,mcp} build cleanly, dist/index.d.ts emitted
- packages/editor check-types reports 21 pre-existing errors, identical to
  what private-editor currently reports

Open PRs against editor-v2 will need rebasing/conflict resolution.
2026-05-09 20:52:26 +00:00
sudhir
23eec44714 Move render systems out of core 2026-05-01 15:07:47 +05:30
sudhir
b3f7957076 Refactor editor selection and viewer integration 2026-05-01 13:54:23 +05:30
sudhir
09bfb0b484 Add frameless door openings and first-person collider support 2026-05-01 11:35:26 +05:30
sudhir
8ae217502c Add curved fence support 2026-04-21 11:26:49 +05:30
sudhir
71ddb7052b Add two-sided wall material targeting 2026-04-20 11:18:20 +05:30
Sudhir Yadav
b1709de44a
feat: curved wall and fixes (#236)
* feat: add polygon movement support to editor and implement dedicated move tools for walls, slabs, and ceilings

* feat: add uv2 attribute to ceiling and slab geometries for lightmap support

* Fix curved wall miters and align roof position sliders

* Fix wall measurement label and extension anchors

* Fix WebGPU renderer initialization order

* fix(editor): scope wall movement to the selected level

---------

Co-authored-by: Pascal <open@pascal.app>
2026-04-15 12:41:16 -04:00
Sudhir Yadav
57df224948
feat: Add catalog-based material presets across structural nodes (#231)
* Add catalog-based material presets across structural nodes

* Fix material picker fallback and wall visible highlights

* Preserve wall materials in selection highlights
2026-04-15 12:16:35 -04:00
Pascal
0a46a9deb4
sync: comprehensive monorepo → editor parity (2D/3D decoupling, UX polish, crash fixes)
Squash merge of 3 commits:
1. useLiveTransforms store for 2D/3D decoupling + floorplan overhaul + Sentry crash fixes
2. Comprehensive 59-file sync bringing editor to full monorepo parity (selection highlights, delete tool, furnish/zone modes, keyboard shortcuts, all panels)
3. Missing files fix (materials.ts, merged-outline-node.ts, type fix)

75 files changed, ~6K additions.
2026-04-07 19:21:10 -04:00
Qiaochu Hu
7d4c8b6bd4
fix: resolve state management issues and memory leaks (#152)
This commit fixes several issues in the core state management:

1. Fix deleteNodesAction recursive call issue
   - Previously, the function recursively called get().deleteNodes()
     inside the set() callback, which could cause state inconsistencies.
   - Now collects all descendant IDs first in a separate pass, then
     deletes them all in a single batch operation.

2. Fix memory leak in use-scene temporal tracking
   - Module-level variables (prevPastLength, prevFutureLength,
     prevNodesSnapshot) persisted across store re-creations.
   - Now cleared in unloadScene() to release stale node references.
   - Added clearTemporalTracking() helper function.

3. Remove unused variable in wall-system
   - Removed debug variable 'useFrameNb' that was declared but never used.

4. Fix requestAnimationFrame in updateNodesAction
   - Previously used RAF without cleanup, causing multiple queued
     callbacks when updates happened rapidly.
   - Now uses a single tracked RAF with cancellation support.

Co-authored-by: hobostay <hobostay@users.noreply.github.com>
Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-26 00:30:16 -04:00
Anton
f06f2fa1b1
feat: 2D editing — floorplan panel, measurements, command palette (v0.3.0)
* sync: port 2D editing features from monorepo (v0.3.0)

## New Features

### Floorplan Panel (7.5K LOC)
- Full 2D editing interface with wall drawing, measurement, and unit display
- Interactive floorplan view with pan/zoom, grid snapping
- Wall thickness visualization, door/window placement
- Zone and slab polygon editing
- Guide image overlay support
- Metric/imperial unit toggle

### Command Palette Overhaul
- Complete rewrite with new command registry system
- Keyboard shortcuts UI with ShortcutToken component
- Editor-specific commands (floorplan, measurements, camera focus)
- Improved search and action organization

### Wall Measurements
- Real-time wall length labels in 3D view
- Metric/imperial conversion
- Wall measurement UI component

### Enhanced Tools
- Wall drafting utilities (grid snapping, validation)
- Node action menu for quick operations
- Improved polygon editing for zones/slabs/sites
- Roof segment panel for granular roof control

## Package Changes

### @pascal-app/core@0.3.0
- New wall-footprint.ts: 2D wall footprint calculation
- Wall mitering exports for floorplan view
- camera-controls:focus event
- Space detection undo pause/resume
- Mark sibling nodes dirty on deletion (miter recalc)

### @pascal-app/viewer@0.3.0
- ErrorBoundary component for robust item rendering
- Broken item fallback UI
- Wall renderer: mark dirty on mount
- Ground occluder: only lowest level punches through
- Unit state (metric/imperial) in viewer store

### @pascal-app/editor@0.1.0
- 48 file changes (16 new, 32 modified)
- New stores: useCommandRegistry, usePaletteViewRegistry
- Tree node drag-and-drop system
- Level selection utilities
- Enhanced scene graph operations

## Apps/Editor
- GeistPixelSquare font for pixel-perfect UI
- Blueprint icon asset
- Updated layout and globals for font support

## Security
- Zero AI imports or internal package refs
- All monorepo-specific code excluded
- Clean audit: no API keys or secrets

## Testing
- Security audit passed ✅
- All AI/internal code excluded ✅
- Version bumps applied ✅

79 files modified, 16 files added
~2600 insertions, ~1400 deletions

* fix: lint cleanup — suppress intentional dep warnings, fix missing dep, remove stale ignores

- Add biome-ignore for 3 intentional useEffect reset patterns (levelId, selectedGuide, selectedId)
- Fix actual missing dependency: currentBuildingId in handleSiteEditShortcutSelect callback
- Remove 3 stale biome-ignore comments in r3f.d.ts (rule not active)

Build and lint pass clean.

* fix: type errors — polygon area guards, selection cast, readonly keywords, door guard

- ceiling-panel, slab-panel, ceiling-tree-node, slab-tree-node, zone-tree-node:
  guard polygon[i]/polygon[j] array access before arithmetic (TS2532)
- scene.ts: introduce toViewerSelection() helper to cast persisted string IDs
  to branded template literal types expected by useViewer.setSelection (TS2345)
- door-panel: guard early return when node is undefined in setSegmentHeightRatio (TS18048)
- editor-commands: remove 'as const' from inline command object, keywords is mutable string[] (TS2322)

All type checks pass. Build and lint clean.

---------

Co-authored-by: Anton Pascal <anton-pascal@users.noreply.github.com>
2026-03-24 19:48:11 +00:00
Aymeric Rabot
1d28e4208f
sync: update core and viewer from monorepo (#143)
Major changes:
- Roof system rewrite with roof-segment support
- Scene store refactor
- Spatial grid improvements
- Item light system
- Post-processing and selection manager updates
- Perf monitor component

Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-20 23:18:30 -04:00
wass08
f2501be2bf remove community 2026-03-13 09:07:46 +01:00
wass08
27e4afb757 draft custom door 2026-02-25 13:28:42 +09:00
wass08
3894d7c8bf fixing system orders for ensuring level calculation comes last 2026-02-23 09:08:15 +09:00
wass08
47373eadef adjusting wall system + adding panel 2026-02-18 13:35:12 +09:00
wass08
dd5f63df64 wall tool draft 2026-02-17 16:22:45 +09:00
wass08
1467325475 reduce warning csg lib 2026-02-10 14:20:40 +09:00
wass08
b4375792ab fix extra rebuild 2026-02-10 14:07:56 +09:00
wass08
7b999b0952 remove log 2026-02-09 11:59:37 +09:00
wass08
a15952055a wall sides feed with floo fill algorithm 2026-02-03 12:03:03 +09:00
wass08
5392d66bd6 handle better slab polygon detection 2026-02-02 11:35:44 +09:00
wass08
72a0e3952a slab panel 2026-02-02 11:17:47 +09:00
wass08
0613f846ef correct system for not triggering unwanted rerenders 2026-02-02 10:35:00 +09:00
wass08
ff4e2fc2fe fix entire rebuild on updates 2026-02-02 09:40:11 +09:00
wass08
07dee4aefc rename items 2026-01-29 15:37:51 +09:00
wass08
9c185c4d33 fix slab detection for wall 2026-01-29 15:08:57 +09:00
wass08
10ef50f186 fix attach items 2026-01-29 07:17:25 +09:00
wass08
2f0e976878 fix init code 2026-01-29 06:44:39 +09:00
wass08
1a5bd11009 slab outset + wall pushing up 2026-01-27 19:33:30 +09:00
wass08
54dd5d0541 fix wall mitering (three-mesh-csg) 2026-01-26 19:52:53 +09:00
wass08
f244f864ba remove logs 2026-01-26 18:20:18 +09:00
wass08
d4c3fe2afb perfect wall mitering 2026-01-26 18:17:46 +09:00
wass08
abd8e327fe fix wall mitering 2026-01-26 18:06:39 +09:00
wass08
e13005dcda fixed wall mitering 2026-01-26 17:23:42 +09:00
wass08
43226c3dd0 walls mitering on a part of a wall 2026-01-26 10:33:04 +09:00
wass08
dc3f1a6898 wip wall-mitering 2026-01-26 10:08:57 +09:00
wass08
5de0818633 biome 2026-01-21 10:03:29 +09:00
wass08
dabaefc57a different level edition + fix 2026-01-20 08:26:47 +09:00
wass08
a217d0d3a6 drafting wall attach system 2026-01-19 07:59:06 +09:00
wass08
8bf933ed36 draft spatial grid 2026-01-18 10:54:02 +09:00
wass08
162c70552c item catalog draft 2026-01-17 15:40:04 +09:00
wass08
60cb60fdaa code organization 2026-01-16 09:46:19 +09:00
wass08
c0626662a8 event systems 2026-01-15 11:24:41 +09:00
wass08
0c07c482a5 registry / systems / renderer 2026-01-15 10:43:32 +09:00