-
Notifications
You must be signed in to change notification settings - Fork 65
Open
Description
Problem
src/daemon/handlers/interaction.ts is currently ~830 LOC and carries multiple concerns: command routing, selector resolution, @ref handling, coordinate parsing, snapshot capture, and interaction recording.
Goal
Refactor interaction handler into focused internal modules while preserving interaction command behavior and replay selector-chain recording.
Proposed split
src/daemon/handlers/interaction-targeting.ts- coordinate target parsing + @ref target resolution + rect normalization
src/daemon/handlers/interaction-snapshot.ts- session snapshot capture and related helpers
src/daemon/handlers/interaction-flags.ts- ref snapshot flag guard + validation helpers
- Keep
src/daemon/handlers/interaction.tsas command-level orchestration.
Acceptance criteria
- Selector +
@refbehavior remains unchanged. - Recorded actions still contain expected
selectorChainmetadata. - No command routing moved into
src/daemon.ts. - New files target <=300 LOC when practical.
- Existing interaction and replay-heal tests pass unchanged.
Validation
pnpm typecheckpnpm test:unitpnpm test:smoke
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels