fix(vscode): sidebar top bar regression - #12988
Merged
Merged
Conversation
Contributor
Code Review SummaryStatus: No Issues Found | Recommendation: Merge lgtm — the restoration is byte-for-byte the pre-#12894 shape (verified against the revert commit) with only the Files Reviewed (9 files)
Reviewed by kimi-k3 · Input: 16K · Output: 3.3K · Cached: 294K Review guidance: REVIEW.md from base branch |
…lo-Org/kilocode into fix/sidebar-top-bar-vscode-regression
marius-kilocode
approved these changes
Aug 7, 2026
t7tran
pushed a commit
to t7tran/kilocode
that referenced
this pull request
Aug 14, 2026
…scode-regression fix(vscode): sidebar top bar regression
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Issue
No tracked issue. This addresses feedback on #12976, a full revert of #12894 proposed after the sidebar navigation bar change (which fixed the nav bar disappearing in Cursor's Secondary Side Bar) visually broke the toolbar on real VS Code.
Context
#12894 replaced Kilo's native
view/title/editor/titletoolbar with an in-webview bar everywhere, to work around Cursor's Secondary Side Bar dropping the native toolbar entirely. That fixed Cursor, but regressed VS Code, which never had this bug — colleagues confirmed VS Code renders the native toolbar correctly in both the primary and Secondary Side Bar, and reported two visual issues from the always-on webview bar:Rather than reverting the whole feature, this restores VS Code's native toolbar exactly as it was and scopes the in-webview fallback bar to Cursor only, since that's the only host actually affected by the underlying bug.
Implementation
view/title/editor/titlemenu contributions, thesidebarTitle.*telemetry wrapper commands, and theirtrack()helper inextension.ts— byte-for-byte the same shape they had before fix(vscode/cursor): keep sidebar navigation visible in the secondary side bar #12894 — with one addition: every restoredwhenclause now also requires!kilo-code.new.isCursor.kilo-code.new.isCursoris a context key set once at activation from a newisCursorHost()helper (vscode.env.appName.toLowerCase().includes("cursor")).KiloProvider._getHtmlForWebviewuses the same helper to decide whether to inject the in-webviewSidebarTopBar(topBar: hideTopBar !== true && isCursorHost()).@types/vscode@1.120.0definitions directly:WebviewViewexposes no location field (viewType,webview,title,description,badge,visible,onDidDispose,onDidChangeVisibilityis the complete interface), and there's noViewContainerLocation/auxiliaryBar/secondarySidebarAPI surface at all.appNameis the only reliable signal available."spacer"action that split the row into a tight cluster + a far-right pair, and addsjustify-content: flex-endto right-align the whole group, matching where the native toolbar's icons sit..changeset/fix-secondary-sidebar-nav-bar.md, which previously (inaccurately) said the webview bar always replaces the native toolbar.How to Test
Manual/local verification
bun script/local-bin.ts && bun script/prepare-sdk.ts && bun run --parallel check-types check-types:webview lint bundle:production) and launched it against both real VS Code (1.132.0) and Cursor side by side, each with its own--state-dir/--kilo-storage-dir.isCursorHost()'svscode.env.appNamecheck against both apps' actualproduct.json("Visual Studio Code"vs"Cursor").typecheck,lint,knip,format, andcheck-kilocode-changeinpackages/kilo-vscode— all pass.Reviewer test steps
--app-pathpointing at Cursor's binary) and confirm the in-webview bar renders as a single right-aligned row in both dock positions, and that every button still works.