hermes-agent/web/src
wesleysimplicio 8e3cfdfb61 fix(webui): allow native text selection in chat via xterm.js bypass (#25720)
The chat panel renders via xterm.js, and when the inner Hermes TUI
enables mouse-events mode (CSI ?1000h family — used for nav inside
Ink overlays/pickers) every drag/double-click/triple-click in the
canvas is consumed by the terminal instead of producing a native
text selection. The reporter (macOS, Brave) confirmed:

- click-and-drag selects nothing
- Cmd+C with no selection copies the entire visible buffer
- existing CSS overrides and event handlers at the document layer
  have no effect — the issue is at xterm.js's mouse layer, not the
  DOM

Fix: two xterm.js options the user can opt into without disabling
mouse-events mode for the inner TUI:

- `macOptionClickForcesSelection: true` — holding Option (macOS)
  or Alt (Linux/Windows) during a click-and-drag bypasses mouse-events
  mode and produces a native xterm selection. This is the documented
  xterm.js path for this exact scenario. Selected text is copyable
  via Cmd+C / Ctrl+C through the existing OSC 52 + manual handlers.
- `rightClickSelectsWord: true` — right-click highlights the word
  under the pointer. Single-action path on top of the modifier-based
  bypass.

The two options coexist with the existing `macOptionIsMeta: true`
(which only affects keyboard, not mouse). No other code change
needed.

Fixes #25720.
2026-05-17 02:31:18 -07:00
..
components fix(dashboard): UI polish — modals, layout, consistency, test fixes 2026-05-12 13:59:22 -04:00
contexts fix: mobile chat in new layout 2026-04-24 12:07:46 -04:00
hooks fix(dashboard): UI polish — modals, layout, consistency, test fixes 2026-05-12 13:59:22 -04:00
i18n fix(dashboard): align Ukrainian Kanban Ready column help 2026-05-15 23:39:29 -04:00
lib fix(dashboard): UI polish — modals, layout, consistency, test fixes 2026-05-12 13:59:22 -04:00
pages fix(webui): allow native text selection in chat via xterm.js bypass (#25720) 2026-05-17 02:31:18 -07:00
plugins feat(dashboard): support serving under URL prefix via X-Forwarded-Prefix 2026-05-07 06:39:18 -07:00
themes feat(dashboard): add 'default-large' built-in theme with 18px base size (#20820) 2026-05-06 09:10:44 -07:00
App.tsx feat(dashboard): hide token/cost analytics behind config flag (default off) (#25438) 2026-05-13 22:20:25 -07:00
index.css feat(web): add /api/pty WebSocket bridge to embed TUI in dashboard 2026-04-24 10:51:49 -04:00
main.tsx feat(dashboard): support serving under URL prefix via X-Forwarded-Prefix 2026-05-07 06:39:18 -07:00