Skip to content

fix(vscode): sync Agent Manager inspector width - #12858

Merged
marius-kilocode merged 2 commits into
mainfrom
sync-terminal-diff-viewer-dimensions
Aug 4, 2026
Merged

fix(vscode): sync Agent Manager inspector width#12858
marius-kilocode merged 2 commits into
mainfrom
sync-terminal-diff-viewer-dimensions

Conversation

@marius-kilocode

@marius-kilocode marius-kilocode commented Aug 4, 2026

Copy link
Copy Markdown
Collaborator

The Agent Manager terminal and diff viewer currently maintain separate inspector widths, so switching between them moves the divider and produces inconsistent layouts. The divider position is also lost when the webview is recreated.

This change gives both views one shared inspector width, restores it from webview state, and constrains the saved value to the available viewport. Resizing either view now keeps the same position for the other view and across panel reloads. The shared minimum stays 360px on normal layouts; on narrow viewports the effective bounds scale down so the inspector cannot consume the entire editor.

Agent Manager diff inspector using the shared width

Agent Manager terminal inspector using the shared width

Comment thread packages/kilo-vscode/webview-ui/agent-manager/AgentManagerApp.tsx Outdated
@kilo-code-bot

kilo-code-bot Bot commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Incremental review of commits since e227378. The previous suggestion is resolved: minPanelWidth(viewport) now scales the minimum down on narrow viewports (50% of viewport, capped at 360px), maxPanelWidth floors at the dynamic minimum instead of 360px, and the PR description explicitly documents the shared 360px minimum on normal layouts. Bounds stay consistent (min <= max for all viewport sizes), the new tests exercise the real implementation, and no memory-leak surface was introduced (pure functions only, no new listeners or subscriptions).

Files Reviewed (3 files)
  • packages/kilo-vscode/tests/unit/agent-manager-terminal-layout.test.ts
  • packages/kilo-vscode/webview-ui/agent-manager/AgentManagerApp.tsx
  • packages/kilo-vscode/webview-ui/agent-manager/side-panel-layout.ts
Previous Review Summary (commit e227378)

Current summary above is authoritative. Previous snapshots are kept for context only.

Previous review (commit e227378)

Status: 1 Issue Found | Recommendation: Address before merge

Overview

Severity Count
CRITICAL 0
WARNING 0
SUGGESTION 1
Issue Details (click to expand)

SUGGESTION

File Line Issue
packages/kilo-vscode/webview-ui/agent-manager/AgentManagerApp.tsx 2639 Shared width raises the diff inspector minimum from 200px to 360px, and the maxPanelWidth floor locks the panel at 360px on viewports narrower than ~450px
Files Reviewed (5 files)
  • .changeset/sync-inspector-width.md
  • packages/kilo-vscode/tests/unit/agent-manager-terminal-layout.test.ts
  • packages/kilo-vscode/webview-ui/agent-manager/AgentManagerApp.tsx - 1 issue
  • packages/kilo-vscode/webview-ui/agent-manager/project/local-tabs.ts
  • packages/kilo-vscode/webview-ui/agent-manager/side-panel-layout.ts

The width unification itself is clean: removed identifiers have no leftover references, the persisted value is clamped against the current viewport on restore, persistence is debounced and cleaned up, and the changeset is present with user-facing wording. No memory-leak surface introduced.

Fix these issues in Kilo Cloud


Reviewed by kimi-k3 · Input: 32.6K · Output: 6K · Cached: 200.5K

Review guidance: REVIEW.md from base branch main

@marius-kilocode
marius-kilocode merged commit c10d5ae into main Aug 4, 2026
24 checks passed
@marius-kilocode
marius-kilocode deleted the sync-terminal-diff-viewer-dimensions branch August 4, 2026 13:07
t7tran pushed a commit to t7tran/kilocode that referenced this pull request Aug 14, 2026
…ewer-dimensions

fix(vscode): sync Agent Manager inspector width
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.

2 participants