Skip to content

feat(app): close settings with Escape - #2828

Open
mcowger wants to merge 3 commits into
getpaseo:mainfrom
mcowger:loyal-vulture
Open

feat(app): close settings with Escape#2828
mcowger wants to merge 3 commits into
getpaseo:mainfrom
mcowger:loyal-vulture

Conversation

@mcowger

@mcowger mcowger commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

Linked issue

No issue number was provided.

Type of change

  • Bug fix
  • New feature
  • Enhancement
  • Refactor
  • Docs

Reasoning

On desktop and web, pressing Escape in Settings was routed as an agent-interrupt shortcut and left the Settings screen open. Route Escape to the existing Settings exit path instead.

Goals

  • Close non-compact Settings with Escape and return to the last workspace.
  • Fall back to Open Project when no remembered workspace exists.
  • Let active web overlays keep ownership of Escape.
  • Preserve compact/mobile Settings behavior.

Non-goals

  • Change Escape behavior for other routes or compact layouts.
  • Change existing Settings or agent-interrupt shortcut bindings.

QA

  • npx vitest run packages/app/src/keyboard/route-shortcut.test.ts packages/app/src/keyboard/keyboard-shortcuts.test.ts --bail=1 — 137 tests passed.
  • npm run test:e2e --workspace=@getpaseo/app -- settings-navigation.spec.ts --grep "pressing Escape closes settings" — 1 test passed in the real browser/Metro/daemon harness.
  • npm run typecheck --workspace=@getpaseo/app — passed.
  • npm run lint and targeted format checks — passed.
  • Web browser tested; Electron was not separately exercised.

Checklist

  • One focused change
  • npm run typecheck passes
  • npm run lint passes
  • npm run format passes
  • QA evidence
  • Tests added or updated where it made sense

@greptile-apps

greptile-apps Bot commented Aug 3, 2026

Copy link
Copy Markdown
Contributor

Greptile Summary

Adds desktop/web Escape handling for Settings.

  • Routes Escape through the existing last-workspace navigation path.
  • Falls back to Open Project when no workspace is remembered.
  • Preserves compact-layout behavior and lets active web overlays handle Escape.
  • Adds route-level unit coverage and a browser end-to-end test.

Confidence Score: 5/5

The PR appears safe to merge.

No blocking failure remains.

Important Files Changed

Filename Overview
packages/app/src/hooks/use-keyboard-shortcuts.ts Executes Settings exit navigation, including the Open Project fallback, while deferring Escape to active overlays.
packages/app/src/keyboard/route-shortcut.ts Routes the desktop Settings agent-interrupt shortcut to the existing last-workspace action.
packages/app/src/lib/overlay-root.ts Exposes whether the web overlay registry currently contains an active overlay.
packages/app/src/keyboard/route-shortcut.test.ts Covers desktop Settings routing and preservation of compact-layout behavior.
packages/app/e2e/browser/settings-navigation.spec.ts Verifies that pressing Escape leaves Settings in the browser harness.

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  E[Escape pressed] --> S{Non-compact Settings?}
  S -- No --> I[Keep agent-interrupt behavior]
  S -- Yes --> O{Active web overlay?}
  O -- Yes --> H[Overlay handles Escape]
  O -- No --> W{Remembered workspace?}
  W -- Yes --> N[Navigate to workspace]
  W -- No --> P[Replace route with Open Project]
Loading

Reviews (4): Last reviewed commit: "Merge branch 'main' into loyal-vulture" | Re-trigger Greptile

@boudra boudra added the needs-maintainer-qa Diff is good, waiting on maintainer QA label Aug 6, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

needs-maintainer-qa Diff is good, waiting on maintainer QA

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants