Skip to content

feat: improve Kilo Console worktree review - #11147

Merged
catrielmuller merged 5 commits into
mainfrom
catrielmuller/kilo-console-ui-improvements
Jun 12, 2026
Merged

feat: improve Kilo Console worktree review#11147
catrielmuller merged 5 commits into
mainfrom
catrielmuller/kilo-console-ui-improvements

Conversation

@catrielmuller

@catrielmuller catrielmuller commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Issue

No linked issue; this is a scoped Kilo Console UI improvement.

Context

Improve project worktree management and review inside Kilo Console. Native browser prompts and raw patch output made routine worktree actions feel disconnected from the rest of the console and made larger diffs difficult to inspect.

Implementation

Worktree create, rename, reset, and delete actions now use accessible console dialogs. The project details area uses the shared session review UI with lazy per-file diff loading, syntax highlighting, unified/split layouts, and a resizable sidebar. Global Console UI settings persist the default sidebar width and diff layout through the CLI config schema and generated SDK.

Screenshots / Video

Pasted image Pasted image (2) Pasted image (3) Pasted image (4) Pasted image (5) Pasted image (6) Pasted image (7) Pasted image (8) Pasted image (9)

How to Test

Manual/local verification

  • Agent: bun run typecheck in packages/kilo-console passed.
  • Agent: bun test src/routes/config/state/console.test.ts in packages/kilo-console passed (3 tests).
  • Agent: bun run typecheck in packages/opencode passed.
  • Agent: bun test test/kilocode/config/console-ui.test.ts in packages/opencode passed (2 tests).
  • Agent: the pre-push hook ran bun turbo typecheck successfully across 17 tasks.
  • Agent: bun run script/check-opencode-annotations.ts passed.

Reviewer test steps

  1. Run bun dev -- console and open Global Settings > Console > UI.
  2. Change the project context sidebar width and diff layout, save, and confirm the values persist after reload.
  3. Open a project worktree with changed files, expand files in Changes, and confirm syntax-highlighted unified and split diffs render correctly.
  4. Drag the context sidebar edge and confirm its width persists.
  5. Create, rename, reset, and delete a worktree and confirm each action uses the in-app dialog flow.

Checklist

  • Issue linked above, or exception explained
  • Tests/verification described
  • Screenshots/video included for visual changes, or marked N/A
  • Changeset considered for user-facing changes
  • I personally reviewed the diff and can explain the changes, including any AI-assisted work.

window.addEventListener("resize", updateViewport)

onCleanup(() => {
if (events.timer) window.clearTimeout(events.timer)

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

WARNING: resize.timer is not cleared in onCleanup, but events.timer is. If the component unmounts while a resize debounce is in flight, the setTimeout callback will fire after cleanup and call patchConfig with stale closure data.

Add if (resize.timer) window.clearTimeout(resize.timer) here alongside the events.timer cleanup.

* Width of the Kilo Console project context sidebar in pixels
*/
context_sidebar_width?: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN"
diff_style?: "unified" | "split"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SUGGESTION: The generated type includes duplicate and semantically misleading string literals: number | "NaN" | "Infinity" | "-Infinity" | "Infinity" | "-Infinity" | "NaN". The duplicates ("Infinity", "-Infinity", "NaN" appear twice each) are a code-gen artifact from Effect's Schema.Number union with its special-value serialization.

Since Config.Info uses Schema.Number.check(isGreaterThanOrEqualTo(250), isLessThanOrEqualTo(800)) which effectively rejects NaN and Infinity at runtime anyway, consider wrapping the schema with Schema.Int or Schema.Finite so the codegen produces a clean number type here. Otherwise this is cosmetic — it won't cause a runtime bug.

@kilo-code-bot

kilo-code-bot Bot commented Jun 12, 2026

Copy link
Copy Markdown
Contributor

Code Review Summary

Status: No Issues Found | Recommendation: Merge

All previous issues remain resolved. The sole change since eb4d2e6 (refactor: fix kilo marker) adds a // kilocode_change annotation to the getSharedHighlighter import in packages/ui/src/context/marked.tsx — a correct marker for a Kilo-specific import in a shared upstream file. No logic was altered.

Files Reviewed (1 file, incremental)
  • packages/ui/src/context/marked.tsx — marker annotation only, no issues

Reviewed by claude-4.6-sonnet-20260217 · 176,856 tokens

Review guidance: REVIEW.md from base branch main

Comment thread packages/kilo-console/src/index.tsx Outdated
@marius-kilocode

Copy link
Copy Markdown
Collaborator

I wonder if we should rather have a common kilo diff logic that is being reused here. This primarily uses the OpenCode components. What is the reasoning behind this?

@catrielmuller

Copy link
Copy Markdown
Contributor Author

I wonder if we should rather have a common kilo diff logic that is being reused here. This primarily uses the OpenCode components. What is the reasoning behind this?

Hey @marius-kilocode , I'm utilizing the shared components as-is. I am unclear about the diff logic you mentioned, because the diff comes from the SDK and the UI comes from the UI library

@catrielmuller
catrielmuller merged commit 0edfcf3 into main Jun 12, 2026
22 checks passed
@catrielmuller
catrielmuller deleted the catrielmuller/kilo-console-ui-improvements branch June 12, 2026 13:34
t7tran pushed a commit to t7tran/kilocode that referenced this pull request Aug 14, 2026
…nsole-ui-improvements

feat: improve Kilo Console worktree review
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