hermes-agent/ui-tui/src
Brooklyn Nicholson 727f0eaf74 refactor(tui): clean up touched files — DRY, KISS, functional
Python (tui_gateway/server.py):
- hoist `_wait_agent` next to `_sess` so `_sess` no longer forward-refs
- simplify `_wait_agent`: `ready.wait()` already returns True when set,
  no separate `.is_set()` check, collapse two returns into one expr
- factor `_sess_nowait` for handlers that don't need the agent (currently
  `terminal.resize` + `input.detect_drop`) — DRY up the duplicated
  `_sessions.get` + "session not found" dance
- inline `session = _sessions[sid]` in the session.create build thread so
  agent/worker writes don't re-look-up the dict each time
- rename inline `ready_event` → `ready` (it's never ambiguous)

TS:
- `useSessionLifecycle.newSession`: hoist `r.info ?? null` into `info`
  so it's one lookup, drop ceremonial `{ … }` blocks around single-line
  bodies
- `createGatewayEventHandler.session.info`: wrap the case in a block,
  hoist `ev.payload` into `info`, tighten comments
- `useMainApp` flush effect: collapse two guard returns into one
- `bootBanner.ts`: lift `TAGLINE` + `FALLBACK` to module constants, make
  `GRADIENT` readonly, one-liner return via template literal
- `theme.ts`: group `selectionBg` inside the status* block (it's a UI
  surface bg, same family), trim the comment
2026-04-16 18:07:23 -05:00
..
__tests__ refactor(tui): store-driven turn state + slash registry + module split 2026-04-16 12:34:45 -05:00
app refactor(tui): clean up touched files — DRY, KISS, functional 2026-04-16 18:07:23 -05:00
components perf(tui): async session.create — sid live in ~250ms instead of ~1350ms 2026-04-16 15:39:19 -05:00
config refactor(tui): store-driven turn state + slash registry + module split 2026-04-16 12:34:45 -05:00
content refactor(tui): store-driven turn state + slash registry + module split 2026-04-16 12:34:45 -05:00
domain refactor(tui): store-driven turn state + slash registry + module split 2026-04-16 12:34:45 -05:00
hooks chore: uptick 2026-04-15 23:29:00 -05:00
lib refactor(tui): store-driven turn state + slash registry + module split 2026-04-16 12:34:45 -05:00
protocol refactor(tui): store-driven turn state + slash registry + module split 2026-04-16 12:34:45 -05:00
types fix: scrolling while selecting 2026-04-14 12:50:22 -05:00
app.tsx refactor(tui): store-driven turn state + slash registry + module split 2026-04-16 12:34:45 -05:00
banner.ts feat: add skin logo support 2026-04-07 23:59:11 -04:00
bootBanner.ts refactor(tui): clean up touched files — DRY, KISS, functional 2026-04-16 18:07:23 -05:00
entry.tsx perf(tui): paint banner to stdout in ~2ms, before Ink loads 2026-04-16 15:48:41 -05:00
gatewayClient.ts feat: just more cleaning 2026-04-15 14:14:01 -05:00
gatewayTypes.ts chore: uptick 2026-04-16 14:48:29 -05:00
theme.ts refactor(tui): clean up touched files — DRY, KISS, functional 2026-04-16 18:07:23 -05:00
types.ts feat: just more cleaning 2026-04-15 14:14:01 -05:00