[PR #7744] feat(tui): add configurable status line hints #12496

Open
opened 2026-02-16 18:17:24 -05:00 by yindo · 0 comments
Owner

Original Pull Request: https://github.com/anomalyco/opencode/pull/7744

State: open
Merged: No


What does this PR do?

Adds support for customizable status hints in the TUI footer, allowing users to control which keybind hints are displayed.

Features:

  • New tui.status_hints config section with enabled flag and items array
  • Default hints: agent_cycle, variant_cycle (conditional), command_list
  • Conditional hint display (e.g., variant_cycle only shows when variants exist)
  • Users can customize which hints to show and their labels
  • Backwards compatible - uses defaults when not configured

Example Configuration:

{
  "tui": {
    "status_hints": {
      "enabled": true,
      "items": [
        { "keybind": "agent_cycle", "label": "switch agent" },
        { "keybind": "variant_cycle", "label": "switch variants", "when": "hasVariants" },
        { "keybind": "command_list", "label": "commands" }
      ]
    }
  }
}

This implementation follows the design proposed in issue #6240.

Closes #6240

How did you verify your code works?

  1. Built locally: Ran ./packages/opencode/script/build.ts --single to verify build success.
  2. Tested Defaults: Verified that running without config shows the default hints (Agent, Variant (if available), Commands).
  3. Tested Variant Logic: Verified variant_cycle hint appears only when a model with variants (e.g., antigravity-claude-opus-4-5-thinking) is selected, and hides for others.
  4. Tested Custom Config: Verified that OPENCODE_CONFIG with status_hints correctly changes the footer order and labels.
**Original Pull Request:** https://github.com/anomalyco/opencode/pull/7744 **State:** open **Merged:** No --- ### What does this PR do? Adds support for customizable status hints in the TUI footer, allowing users to control which keybind hints are displayed. **Features:** - New `tui.status_hints` config section with `enabled` flag and `items` array - Default hints: `agent_cycle`, `variant_cycle` (conditional), `command_list` - Conditional hint display (e.g., `variant_cycle` only shows when variants exist) - Users can customize which hints to show and their labels - Backwards compatible - uses defaults when not configured **Example Configuration:** ```json { "tui": { "status_hints": { "enabled": true, "items": [ { "keybind": "agent_cycle", "label": "switch agent" }, { "keybind": "variant_cycle", "label": "switch variants", "when": "hasVariants" }, { "keybind": "command_list", "label": "commands" } ] } } } ``` This implementation follows the design proposed in issue #6240. Closes #6240 ### How did you verify your code works? 1. **Built locally:** Ran `./packages/opencode/script/build.ts --single` to verify build success. 2. **Tested Defaults:** Verified that running without config shows the default hints (Agent, Variant (if available), Commands). 3. **Tested Variant Logic:** Verified `variant_cycle` hint appears only when a model with variants (e.g., `antigravity-claude-opus-4-5-thinking`) is selected, and hides for others. 4. **Tested Custom Config:** Verified that `OPENCODE_CONFIG` with `status_hints` correctly changes the footer order and labels.
yindo added the pull-request label 2026-02-16 18:17:24 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: anomalyco/opencode#12496