feat: editor layout redesign v2 + 3D box select#207
Open
open-pascal wants to merge 4 commits intomainfrom
Open
feat: editor layout redesign v2 + 3D box select#207open-pascal wants to merge 4 commits intomainfrom
open-pascal wants to merge 4 commits intomainfrom
Conversation
New v2 layout with navbar + two-column structure: - Resizable left sidebar with horizontal tab bar - Right viewer panel with floating toolbar slots - Floating level selector on viewer panel - 3D box select tool with marquee selection - View mode system (3D/2D/Split) replacing old floorplan toggle - Fixed 5-button control bar: Select, Box Select, Site Edit, Build, Delete - Simplified view toggles (scans/guides only) - Always-mounted viewers (display:none) to preserve WebGL context - Floorplan top toolbar removed, controls moved to viewer toolbar - Site edit as permanent peer in ControlModes (phase='site' is sole signal) - Site edge labels respect metric/imperial unit toggle
Add ViewerToolbarLeft and ViewerToolbarRight components: - 3D/2D/Split view mode segmented control - Collapse sidebar button - Level mode toggle (stacked/exploded/solo) - Wall mode toggle (cutaway/full height/low) - Measurement unit toggle (metric/imperial) - Day/night theme toggle - Perspective/orthographic camera toggle - Walkthrough (first-person) mode - Preview mode button Wire up toolbar in the v2 layout app page.
- Add isCollapsed/setIsCollapsed to useSidebarStore (was missing from editor repo, present in upstream) — fixes CollapseSidebarButton crash - Add collapse threshold logic to setWidth - Restore isFirstPersonMode/setFirstPersonMode to editor store — was removed when syncing use-editor.tsx but still needed by custom-camera-controls and viewer toolbar walkthrough button - Forces perspective camera + full-height walls when entering first-person mode
- Import and render FirstPersonControls inside the Viewer scene - Add FirstPersonOverlay with exit button when in first-person mode - Switch Viewer to selectionManager='default' during first-person mode - Conditionally hide editor tools (selection, box select, grid, tool manager, site edge labels) during walkthrough - Show ViewerZoneSystem + InteractiveSystem during first-person mode - Hide camera controls hint during walkthrough - V2 layout enters full-screen walkthrough view (same as preview mode but with FirstPersonControls instead of orbit)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Major layout redesign introducing v2 editor layout with a modern two-column structure.
New Features
Layout Changes
siteis the sole signal)Technical
layoutVersionprop on Editor:'v1'(default, backward compat) or'v2'display:noneinstead of unmount — preserves WebGL context across view switchesFloatingLevelSelector,SettingsPanel,SidebarTab,ViewMode,SplitOrientation,FloorplanSelectionTool,useSidebarStoreFiles Changed
17 files, +2821/-1896
Built and verified:
bun run buildpasses cleanly (all 3 turbo tasks successful, 0 errors).