Skip to content

[FEATURE]: Add hints toggle to declutter UI #6240

@tuanhqv123

Description

@tuanhqv123

Problem

The TUI UI displays several persistent hints that can feel cluttered:

  • /share copy link text in header
  • [Tab] switch agent hint in prompt footer
  • [Ctrl+P] commands hint in prompt footer

These hints take up screen real estate and become redundant once users are familiar with keyboard shortcuts.

Proposed Solution

Add a single toggle command "Hide hints" (KV key: hints_visible, default: true) that hides all UI hints:

  1. Header: Hide /share copy link (but keep URL display when already shared)
  2. Prompt footer: Hide [switch agent] and [commands] hints

Layout Behavior

Show hints = true (default) - Current layout:

Header:
  # Session Title           1,234 tokens (12%)
  /share copy link

Prompt:
  [Agent Name | Model | Provider]
  [Spinner|Esc] ........................ [Tab] switch agent  [Ctrl+P] commands

Show hints = false - Compact layout:

Header:
  # Session Title           1,234 tokens (12%)

Prompt:
  [Agent Name | Model | Provider] ... [Spinner|Esc]

Note: When hints are hidden, the spinner and esc interrupt move to the right side of the same row as the agent/model/provider info.

Implementation Details

  • Added hints_visible KV setting (default: true)
  • Added command session.toggle.hints in command palette
  • Modified Header.tsx, Prompt.tsx, and session/index.tsx
  • Replaced 3 separate toggle signals with single showHints signal
  • Preserved existing behavior for spinner/interrupt display during active operations

Alternatives Considered

  1. Separate toggles for each hint - rejected: too granular, increases config surface
  2. Per-hint keybind toggles - rejected: would require more keybinds, harder to discover
  3. Auto-hide after X sessions - rejected: doesn't allow user control

Questions for Maintainers

  • Is this something that aligns with OpenCode's design philosophy?
  • Should we also hide other hints (like /status, LSP/MCP counts) in footer?
  • Any naming preferences for the command/setting?

Code

I have implemented this change. Branch: feature/hints-toggle
Fork: https://github.com/tuanhqv123/opencode/tree/feature/hints-toggle

Waiting for design review approval before opening PR.

Metadata

Metadata

Assignees

Labels

opentuiThis relates to changes in v1.0, now that opencode uses opentui

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions