feat: add delete functionality for walls, slabs and other structural elements#193
Open
hellozzm wants to merge 1 commit intopascalorg:mainfrom
Open
feat: add delete functionality for walls, slabs and other structural elements#193hellozzm wants to merge 1 commit intopascalorg:mainfrom
hellozzm wants to merge 1 commit intopascalorg:mainfrom
Conversation
Add DeleteTool component that activates when the editor is in 'delete' mode (shortcut: D). Clicking on any structural element (wall, slab, ceiling, door, window, item, zone, roof) removes it from the scene. - New DeleteTool component with click handlers via event bus - Validates clicked node belongs to a deletable type - Integrates with existing tool-manager and building-local group - Resolves conflicts with upstream's building transform refactor
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
Add ability to delete structural elements (walls, slabs, ceilings, doors, windows, items, zones, roofs) when the editor is in delete mode (shortcut:
D).The delete mode button already existed in the UI toolbar but had no handler — clicking on elements did nothing.
Changes
New
DeleteToolcomponent (packages/editor/src/components/tools/delete-tool.tsx)useScene.deleteNode()to remove the nodeUpdated
ToolManagerto renderDeleteToolwhen mode isdeleteTesting
DFixes #156