Skip to content

feat(shortcuts): chord-drag window move, a zen-mode key, and a don't-fire-while-typing guard#2575

Open
100mountains wants to merge 1 commit into
Floorp-Projects:mainfrom
100mountains:feat/window-drag-and-zen-key
Open

feat(shortcuts): chord-drag window move, a zen-mode key, and a don't-fire-while-typing guard#2575
100mountains wants to merge 1 commit into
Floorp-Projects:mainfrom
100mountains:feat/window-drag-and-zen-key

Conversation

@100mountains

Copy link
Copy Markdown
Contributor

Part of the final derp-fork contribution batch (#2569). Three related pieces on one chord family — Cmd+Alt on macOS, Ctrl+Alt everywhere else (meta on Windows is the Windows key, which nobody wants in a chord):

  • window-drag (new self-contained feature dir): hold the chord and drag anywhere — toolbars, tab strip, or web content — to move the window. Most useful in zen mode and multirow tabs, where the draggable titlebar is hidden or crowded. Bare-Cmd drags are deliberately not used: Cmd+click opens links and toggles multi-selection, and web apps (Figma, Miro, maps) use Cmd+drag for canvas panning. The chord is re-verified on every mousemove, so a mouseup lost outside the window can never leave the window glued to the pointer.
  • A default shortcut: chord+Z toggles zen mode via the existing floorp-toggle-zen-mode action. Saved configs are merged over defaults so the new entry reaches existing profiles (caveat noted in-code: a default the user deleted comes back until configs carry a schema version — deleted-vs-rebound isn't distinguishable today).
  • Typing guard in the shortcut controller: bare printable single-key shortcuts no longer fire while typing — input/textarea/contenteditable, the shadow-DOM urlbar/searchbar/findbar hosts, and remote content via browser.isInputFocused. Chorded shortcuts are unaffected.

Validation honesty: daily-driven in derp on macOS (FF152 runtime); the guard's remote-content branch matches how derp shipped it. Not exercised on Windows/Linux beyond the chord choice logic.

🤖 Generated with Claude Code

… guard

Three related pieces on one chord family (Cmd+Alt on macOS, Ctrl+Alt
elsewhere - meta on Windows is the Windows key, which nobody wants in a
chord):

- window-drag (new self-contained feature dir): hold the chord and drag
  anywhere - toolbars, tab strip, or web content - to move the window.
  Most useful in zen mode and multirow tabs, where the draggable
  titlebar is hidden or crowded. Bare-Cmd drags are deliberately not
  used: Cmd+click opens links/toggles multiselection, and web apps use
  Cmd+drag for canvas panning.
- A default shortcut: chord+Z toggles zen mode via the existing
  floorp-toggle-zen-mode action. Saved configs are merged over defaults
  so the new entry reaches existing profiles.
- Typing guard in the shortcut controller: bare printable single-key
  shortcuts (like a plain "Z") no longer fire while the user is typing -
  input/textarea/contenteditable, the shadow-DOM urlbar/searchbar/
  findbar hosts, and remote content via browser.isInputFocused.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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