Skip to content

feat(viewer-3d): T/F/R/B/L keyboard shortcuts for ViewCube views#267

Merged
pawellisowski merged 1 commit into
mainfrom
feat/viewer-3d-cube-keyboard-shortcuts
Jun 25, 2026
Merged

feat(viewer-3d): T/F/R/B/L keyboard shortcuts for ViewCube views#267
pawellisowski merged 1 commit into
mainfrom
feat/viewer-3d-cube-keyboard-shortcuts

Conversation

@pawellisowski

Copy link
Copy Markdown
Contributor

What

Adds single-key keyboard shortcuts to the viewer-3d ViewCube:

Key View
T Top
F Front
R Right
B Back
L Left

Keys are case-insensitive (lower- or upper-case), the single-key complement to clicking the cube faces (#258). They reuse the existing applyView/VIEWS path and are skipped when Alt/Ctrl/Meta is held, so browser/app shortcuts (Ctrl+R reload, Alt+Z zoom-selection) keep working.

Verification

  • Local gates green: cargo fmt --check, cargo clippy -D warnings, cargo test (591 + integration).
  • Test assertions added to ships_boxselect_and_viewcube for the new wiring.
  • Real end-to-end: rendered the viewer via aware app install + aware app run in a temp AWARE_HOME, loaded the produced HTML in a headless browser, and dispatched keydowns. Each key rotated the camera to the exact named view; Shift+T also snapped to Top (case-insensitive confirmed); Ctrl+T correctly did not trigger (modifier guard).

Review

Codex reviewed (codex exec review --base main): no findings, no regressions.

Press T/F/R/B/L (any case) to snap to Top/Front/Right/Back/Left — the
single-key complement to clicking the ViewCube faces (#258). Reuses the
existing applyView/VIEWS path; skips when Alt/Ctrl/Meta is held so browser
shortcuts (Ctrl+R reload, Alt+Z zoom-selection) keep working.

Verified end-to-end in a headless browser: each key rotates the camera to
the matching named view, lowercase and uppercase both fire, and modifier
combos are ignored.
@pawellisowski pawellisowski merged commit e27af1f into main Jun 25, 2026
1 check passed
@pawellisowski pawellisowski deleted the feat/viewer-3d-cube-keyboard-shortcuts branch June 25, 2026 11:52
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