Skip to content

TUI v2 2.2: Command box + slash-command parser (MVP) #183

Description

@tomdps

Summary

Implement Issue 2.2 from the TUI v2 plan: add a global command/input box and slash-command parser, with MVP command set and UI feedback.

Scope

  • Global input component available from any view.
  • Parse rules:
    • /... => command
    • otherwise => plain-text task description (stubbed for now)
  • Implement MVP commands:
    • /help
    • /monitor
    • /issue <ref> (stubbed; full orchestration in Milestone 3)
    • /provider <name>
    • /quit
  • Display command output in a status/toast area.

Non-scope

  • No cluster execution (Milestone 3).
  • No full CLI parity (Issue 2.3).
  • No visual polish beyond basic layout for input + output area.

Implementation Plan

  1. Add a shared input component at the app shell level and wire it to current view state.
  2. Implement a simple parser that classifies input as command vs plain text.
  3. Add a command dispatcher with handlers for the MVP commands.
  4. Wire provider switching to session state and reflect it in the UI indicator.
  5. Add a lightweight output/toast area to show command results/errors.

Tests

  • Parser unit tests for / commands and plain text.
  • Command handler tests for /provider, /monitor, /help, /quit.
  • Smoke test: input renders and dispatches from multiple views (Ink testing if available).

Acceptance Criteria

  • Commands work from any view.
  • Provider switches update a session state indicator.
  • Command output is visible in the UI (toast/status).
  • /issue <ref> is stubbed with a clear placeholder message (until Milestone 3).

Dependencies

  • Depends on Issue 2.1 (view router + view stack).

References

  • docs/tui-v2/IMPLEMENTATION_PLAN.md (Issue 2.2)
  • docs/tui-v2/PRD.md (Commands / input model)

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions