Skip to content

Conversation

@ryanwyler
Copy link
Contributor

Summary

Keeps vital tool output compact but fully accessible with a mouse click to quickly view the entire output. Click anywhere on the tool block to expand/collapse making navigating more efficient and easier to follow instead of pages of tool outputs speeding by.

Features

  • Tool outputs are compact showing first 15 lines
  • Click anywhere to easily expand/collapse
  • Configurable threshold via tui.dynamic_details_max_lines (default: 15)
  • Configurable arrow indicators via tui.dynamic_details_show_arrows (default: true)
  • Toggle via Ctrl+P -> "Enable/Disable dynamic details"
  • Persisted in KV store as dynamic_details (default: disabled)

Configuration

{
  "tui": {
    "dynamic_details_max_lines": 15,
    "dynamic_details_show_arrows": true
  }
}

Applies To

Block-container tools (bash, write, edit, patch) when:

  • Output exceeds configured line threshold
  • Tool has completed (not pending/error states)

Changes

  • packages/opencode/src/cli/cmd/tui/routes/session/index.tsx - Add dynamicDetails state, toggle command, and collapse logic in ToolPart
  • packages/opencode/src/config/config.ts - Add tui.dynamic_details_max_lines and tui.dynamic_details_show_arrows config options

…ncing navigation and workflow

Keeps vital tool output compact but fully accessible with a mouse click to quickly
view the entire output. Click anywhere on the tool block to expand/collapse making
navigating more efficient and easier to follow instead of pages of tool outputs
speeding by.

Features:
- Tool outputs are compact showing first 15 lines
- Click anywhere to easily expand/collapse
- Configurable threshold via tui.dynamic_details_max_lines (default: 15)
- Configurable arrow indicators via tui.dynamic_details_show_arrows (default: true)
- Toggle via Ctrl+P -> 'Enable/Disable dynamic details'
- Persisted in KV store as dynamic_details (default: disabled)

Applies to block-container tools (bash, write, edit, patch) when:
- Output exceeds configured line threshold
- Tool has completed (not pending/error states)
@ryanwyler
Copy link
Contributor Author

dynamic-details-collapsed dynamic-details-expanded

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant