Repository navigation
Navigate and select CAD model-tree nodes from the keyboard - #6
Conversation
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 83a6467caa
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| event.preventDefault(); | ||
| event.stopPropagation(); |
There was a problem hiding this comment.
Preserve command confirmation while a picker is active
When a command is awaiting selection and keyboard focus is in the tree, Enter/Space now selects the row but never confirms the command. For example, Move started without a preselection awaits the multi-node picker in TransformedCommand.ensureSelectedModels(). Its confirmation is handled by SelectionHandler.keyDown() through the window listener in HotkeyService, but this handler unconditionally stops propagation, so the picker never receives confirmation. The same interception silently consumes Enter/Space when canSelect() is false during point picking. Preserve a way for these keys to reach the active command handler rather than swallowing them throughout command execution.
Useful? React with 👍 / 👎.
| default: | ||
| return; |
There was a problem hiding this comment.
Allow Tab to leave the newly focusable tree
With a document active under the normal selection handler, Tab and Shift+Tab cannot move focus out of the tree. These keys take this default branch and bubble to HotkeyService.eventHandlerKeyDown(), which forwards them to SelectionHandler.keyDown(); its Tab branch unconditionally calls preventDefault() to cycle viewport highlights. The default ShowPropertyEventHandler inherits that behavior, so entering the new roving tab stop creates a keyboard trap even when no command is running. Handle Tab by stopping propagation without preventing its browser default, allowing users to reach the surrounding controls.
Useful? React with 👍 / 👎.
Make the model tree operable from the keyboard: one roving tab stop, arrow/Home/End navigation, explicit Enter/Space selection, modifier selection, group expansion and visible focus. Keep focus separate from model selection so inspecting the tree does not silently change the active part.
Preserve global shortcut ownership. In particular, the existing Revit M,V sequence still starts Move; the tree does not claim V as a visibility shortcut. Keep document ownership, pointer controls and the CAD ribbon intact.
Validation: 97 focused tree/hotkey tests independently passed, including a negative control for the intercepted Revit sequence; actual Revit Move activation/cancellation and modifier selection passed in a real browser. TypeScript and production build passed. Scoped project lint command exited 0 with 10 warnings and 26 informational diagnostics, no fixes. Prior real dimension/edit/undo/save/reopen/export checks remain separately documented; a complete geometry-verified STEP roundtrip and screen-reader audit are not claimed.
Seven files change; all other 1,181 source leaves, licenses, dependencies and workflows remain exact.