Skip to content

feat(app): put the bottom panel on the right of the terminal - #158

Merged
TooonyChen merged 2 commits into
mainfrom
feature/bottom-panel-right
Nov 9, 2026
Merged

TooonyChen merged 2 commits into
mainfrom
feature/bottom-panel-right

Conversation

@TooonyChen

@TooonyChen TooonyChen commented Nov 9, 2026 •

Copy link
Copy Markdown
Owner

Summary

The bottom panel can now sit in a column on the right of the terminal, for wide screens where the terminal needs the height more than the width.

  • The tab row's context menu (bottomPanelMenu) gets "Move panel to right side" / "Move panel to bottom", after a separator under Hide/Show panel.
  • On the right, the main area is a horizontal split: the terminal with its command bar on the left, the panel on the right, full height. The column is rightPanelWidth wide: 460 DIPs by default, at least 410 (what the Processes details' fields-and-environment split needs, 200 + 200 + the divider, so the inner dividers keep working), and the terminal keeps at least 320. It is dragged, a double click resets it, and it is saved through saveLayout/restoreLayout.
  • The column's width stays fixed from the right edge when the window is resized. ui.Split sizes its first pane, so withRightColumn lays the split out in the opposite direction (its first pane is then the end one, which is the column) and sets each pane back to the window's own direction. Dragging, the arrow keys and SplitReset all work in column DIPs with no per-frame arithmetic. The other option, a left-to-right split sized to width - rightWidth from last frame's bounds, lags one frame on resize and makes the reset value depend on the window.
  • withRightColumn(c, main, top, bottom) / rightColumn(c, top, bottom) in internal/app/rightcolumn.go are written for feat(app): put the server monitor on the right of the terminal #152: the monitor goes in as top, the panel as bottom. When both are there they split with SplitVerticalPercent on a.rightMonitorPct (default 45, rightMonitorLimits). Only the panel goes in for now. The rightMonitorPercent settings key is left to feat(app): put the server monitor on the right of the terminal #152.
  • Hidden on the right: the column goes away, and a thin strip at the terminal's right edge holds the "Show panel" button (chevron left; new chevron-left.svg from Lucide) and the panel's context menu. The hide button in the tab row is a chevron right. The shortcut, and anything that calls openBottomTab (such as the monitor's process list), show it again.
  • Narrow column:
    • The panel's tabs are in a ScrollHorizontal with hidden scrollbars, tracked by a ui.ScrollState. Its HandleInput hook (tabsWheel) turns a plain vertical wheel, or a vertical touchpad swipe, over the tab row into sideways scrolling while the tabs do not fit (down goes toward the last tab). When they fit, or the scroll is sideways or has Ctrl, the event goes on as before.
    • The Files table already scrolls its columns sideways.
    • The Processes and Network filter fields can shrink to 120 DIPs, and the process count no longer shrinks to "7 pr…".
    • At the bottom in a normal window nothing changes: go run ./tools/screenshots produced identical README images.
  • A panel row ignores the side. Full screen is unchanged.
  • Settings: bottomPanelSide ("" / "right") and rightPanelWidth are added to config.Settings and localSettings. Docs: features.md (Window layout; Layout and split dividers) and configuration.md (the table and the local-keys list), English and Simplified Chinese.

Closes #151
Refs #143

Testing

  • New tests in internal/app/rightcolumn_test.go:
    • TestPanelOnRight: move right and back with the menu; side saved and read back; the terminal gets more rows and fewer columns.
    • TestRightPanelWidth: drag the divider; width saved and read back; terminal and column limits; double-click reset; the width stays fixed when the window grows.
    • TestPanelHiddenOnRight: hide and show with the button and the shortcut; the monitor's process click shows it; the strip's menu moves it back to the bottom, still collapsed; a panel row is unaffected; full screen.
    • TestPanelOnRightTabDividers: the Processes list/fields and Network list dividers drag, save, restore and reset at 460 and 410 DIPs.
    • TestPanelTabsWheel: at 410 DIPs the Commands tab is cut off. A vertical wheel over the tab row brings all of it into view without moving the buttons, the wheel back up returns to Files, and a wheel over the terminal leaves the tabs alone. The test fails with the hook removed.
  • gofmt -l . (go.mod toolchain) prints nothing. go build ./..., go vet ./..., GOOS=windows go vet ., GOOS=darwin go vet . and go tool mygo vet pass.
  • go test -race ./... passes except TestArchiveTreeMenu, which also fails on main in this sandbox (it tars the real /tmp).
  • Screenshots were looked at but not committed: panel on the right on Files and on Processes, and hidden on the right, in English and Simplified Chinese; Processes details and Network at 460 and 410 DIPs; the tab row before and after the wheel.
  • Not tested: a real window on macOS, Windows or Linux; real mouse wheels and touchpads; a right-to-left window direction (the app has no RTL language, but the code reads c.Direction()).

🤖 Generated with Claude Code

https://claude.ai/code/session_015nMqJHsqtndDSqJDPp1qYv

The bottom panel's tab row context menu gets "Move panel to right side"
and "Move panel to bottom". On the right the panel is a full-height
column beside the terminal and its command bar, rightPanelWidth wide
(420 DIPs by default, at least 410), kept from the window's right edge,
dragged, reset by a double click and saved with the other pane sizes.
Hidden on the right, the column goes away and a thin strip at the
terminal's right edge keeps the "Show panel" button. The side is
bottomPanelSide in settings.json, kept on this computer.

The right column is a function that takes an optional top (the monitor,
for #152) and bottom (the panel). The panel's tabs now scroll sideways
where they do not fit, and the Processes and Network filter fields
shrink, so the toolbar buttons stay in the narrow column.

Closes #151
Refs #143

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015nMqJHsqtndDSqJDPp1qYv
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 9, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-09T21:46:03.289544Z ce081f9 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

The right column is 460 DIPs wide by default (the minimum stays 410).
A plain vertical wheel, or a vertical touchpad swipe, over the bottom
panel's tab row scrolls the tabs sideways while they do not fit, so the
last tabs can be reached in the narrow column without Shift.

Refs #151

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_015nMqJHsqtndDSqJDPp1qYv
@TooonyChen
TooonyChen merged commit a92056b into main Nov 9, 2026
1 check passed
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.

feat(app): put the bottom panel on the right of the terminal

2 participants