Skip to content

[feature] Composer: add multiline entry and undo/yank recovery #321

Description

@AetherAI3

Problem and result

In raw TTY mode, both CR and LF submit the draft; Ctrl+J therefore sends it instead of inserting a newline. Editing or killing a long pasted instruction also has no undo or yank recovery. Users must reconstruct a draft or split one task into multiple messages.

Add deliberate newline insertion and bounded recovery to the existing composer. Keep the current single-row rendering, with the existing newline marker and a small line-count hint; a full multiline viewport is outside this slice.

Acceptance checks

  • Ctrl+J inserts LF and Enter/CR submits. Document the terminal ambiguity and provide an explicit LF-as-submit compatibility setting; keep non-TTY line input unchanged.
  • Ctrl+_ undoes bounded edit transactions. A bracketed paste is one transaction, and typing coalesces predictably. Ctrl+Y restores the last killed text. Cursor position is restored with undo.
  • Submission, clearing, and input-owner changes end the recovery scope. Undo cannot restore a previously sent task or change an already reviewed shell attachment.
  • New keys operate only while the composer owns input. They do not intercept PTY input, password fields, approval prompts, or shell review, and they preserve streaming typeahead and queued draft edits.
  • Focused key/buffer/render fixtures cover Unicode, pasted newlines, resizing, clear/submit boundaries, and combinations with history and slash selection. No model request is needed for editing.

Landing boundary

Coordinate with PR #309, which preserves exact shell review and queue authority. No external editor integration, terminal viewport rewrite, or persistent undo history in this issue.

Evidence and planning

Package: Input and discovery. Priority: P1. Rough engineering estimate: 1–2 days, including focused fixtures; this is a planning estimate, not a measured benchmark.

Reviewed against v4.20.0 at 4f1717bc120917e1b04d0baa939855417ef866a4: src/ui/keys.ts, src/ui/input_line.ts, src/ui/input_render.ts, src/commands/chat.ts.

Comparator: Claude Code interactive mode documents newline entry and undo; Hermes CLI documents multiline input. Reuse Aether’s existing input ownership rather than importing a new terminal framework.

Created from the LOOP-19 review of the README, all 23 open issues, four open PRs, and recent shipped work on 2026-10-09. These are proposed changes; the acceptance checks below have not been executed.

Activity

  1. added
    featureNew product capability or integration work
    on Oct 9, 2026
  2. AetherAI3 commented on Oct 9, 2026

    @AetherAI3
    OwnerAuthor

    Landed in PR #329 (squash commit 781c0c149ed90a363f3cac4d30741b14e7a5922d).

    Evidence:

    • npm run docs:check passed, including TypeScript build and six generated documentation checks.
    • Focused composer/config/chat/queue/shell/key/buffer/render tests: 100 passed, 0 failed; four existing shell fixtures were skipped on this host. The raw TTY fixture proves Ctrl+J keeps one draft, CR submits, bracketed paste undoes as one edit, Ctrl+Y yanks, and no model request occurs during editing.
    • git diff --check passed.
    • PR Preserve exact shell review and queue authority on v4.21.0 main #309 coordination: the current draft's src/commands/chat.ts auto-merges with this change. Its generated commands documentation already conflicts with main independently of [feature] Composer: add multiline entry and undo/yank recovery #321.
    • GitHub CI and CodeQL did not start: job annotations report that the account is locked due to a billing issue. PR feat: multiline composer with undo and yank recovery #329 was merged with the admin override on the basis of the local checks above; no CI pass is claimed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    featureNew product capability or integration work

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions