Skip to content

refactor(desktop): remove the old workspace layout - #9052

Open
saddlepaddle wants to merge 1 commit into
mainfrom
superset/remove-old-workspace-layout
Open

saddlepaddle wants to merge 1 commit into
mainfrom
superset/remove-old-workspace-layout

Conversation

@saddlepaddle

@saddlepaddle saddlepaddle commented Oct 29, 2026 •

Copy link
Copy Markdown
Collaborator

What & why

The right pane area has been on for everyone since #9008. useRightPaneAreaEnabled() always returned true, so every branch for the old layout (everything in the center plus a right WorkspaceSidebar with Changes/Files/Review tabs) was dead code. This removes it, so the right pane area is the only layout. It is the first step of making the right pane the default model for workspace view state.

No behaviour change is intended for anyone: every removed branch was unreachable.

Deleted

  • The old right sidebar: WorkspaceSidebar with its SidebarHeader and PRActionHeader.
  • Sidebar tab state: setWorkspaceSidebarTab, rowlessSidebarTabStore, sidebarState.activeTab and WORKSPACE_SIDEBAR_TABS.
  • The center Changes pane: openChangesPane / toggleChangesPane in useWorkspacePaneOpeners, and the "pane" mode of openChangesPaneInStore.
  • The changesOpenTarget setting, with its Behavior settings row and settings-search entry.
  • ChangesControl, with ShipControl and PRStatusGroup. It was only rendered by the old tab bar; the new toolbar and activity menu cover it.
  • V2WorkspaceOpenInButton and V2WorkspaceRunButton.
  • AddTabMenu's Browser / Changes / Desktop items (the right pane options replace them).
  • stores/right-pane-area.ts. Its key is already in DEAD_KEYS.
  • The flag === false effect in useRightPaneAreaLifecycle that moved tabs back to the center, and SIDEBAR_PANE_KINDS.
  • The pinned org pages section of the activity menu (old layout only), and selectMenuPages' orgPages / favoritePageIds.
  • File pane UI for files in the center area: the header Save and Open in buttons, the tab dirty dot, and showTree / inRightPane. moveViewerPanesToRight keeps files out of the center.
  • useWorkspaceFileNavigation's selectedFilePath / pendingReveal, which only the old FilesTab read.

Flag parameters removed from:

  • hooks: useWorkspaceRightPane, useRightPaneMode (canExpand; full screen itself now lives in stores/right-pane-full-screen.ts since feat(cli): let agents drive the right sidebar with superset panes #9204), useRightPaneAreaLifecycle, usePaneAreaMoveActions;
  • components: WorkspaceSplitLayout / SidebarSlide (keepMounted), WorkspaceActivityMenu (changes is now required), V2NotificationController, LinkTierMapper;
  • the registry: usePaneRegistry (rightStore).

Saved state. The user preference fields rightSidebarOpen, rightSidebarTab and rightSidebarWidth (with their setters), sidebarState.activeTab, and settings.changesOpenTarget are removed from the schemas.

  • These are fields inside existing collection or zustand blobs, not separate localStorage keys, so no new DEAD_KEYS entries are needed.
  • The heal logic spreads the stored row, so rows saved before this keep the old fields as harmless extras.
  • An older build reading these rows falls back to its own defaults.

Kept on purpose

  • WorkspaceSidebar/hooks/useChangesTab, useReviewTab, components/FilesTab, utils and types.ts. The right-pane tabs import them. Moving them under the panes that use them is a follow-up.
  • RightPaneLinkTarget stays nullable. PullRequestCodeTab and DiffPane render on the pull-requests page too, where null means "not in a workspace".
  • splitWithViewer's same-store branch: it still splits inside the right pane from the right pane's own context menu.

Existing gap, not changed here. Revealing a path in the file tree from a terminal link opens the right pane but reveals nothing: only the old sidebar's FilesTab read pendingReveal. That was already the case before this PR.

How I tested it

  • bun run typecheck in apps/desktop, bun run lint, and the full desktop bun test (9,039 pass, 0 fail), re-run after rebasing on main (feat(cli): let agents drive the right sidebar with superset panes #9204, the new uk locale).
  • bun run check:i18n: the catalogs only lose 15 messages that belonged to removed UI. No new messages, and every locale, including the new uk, is still fully translated.
  • Tests updated: SidebarSlide, WorkspaceSplitLayout, useRightPaneMode, openChangesPaneInStore, selectMenuPages, the schema/heal tests, and the PR-link surfaces test (drops the deleted PRStatusGroup). Deleted: the sidebar-tab tests.
  • Not verified in the running app. I have not driven the workspace page over CDP.

Checklist

  • PR title follows conventional commits (type(scope): subject)
  • bun run lint and bun run typecheck pass (CI fails on lint warnings too)
  • "Allow edits from maintainers" is checked on fork PRs
  • I have signed the CLA (the bot asks on your first PR)

Summary by CodeRabbit

  • Workspace experience
    • Workspaces now use the right-pane layout; the previous Files, Changes, and Review sidebar is no longer available.
    • The Changes action focuses an existing diff pane or opens one in a new tab. The setting for choosing where Changes opens has been removed.
    • The activity menu no longer includes organization-pinned pages, and the center-pane add menu no longer offers Browser, Changes, or Desktop options.
    • Workspace sidebar controls for pull-request status, shipping, running, saving, and opening files in another app are no longer available.
  • Settings
    • Right-sidebar preferences and workspace sidebar-tab selections are no longer available.

@coderabbitai

coderabbitai Bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent review info
Run configuration
  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: defaults
  • Review profile: CHILL
  • Plan: Advanced
  • Run ID: 5357c4cd-4cdd-40b9-92bf-be5dba744732
Commits

Reviewing files that changed from the base of the PR and between fde9059 and b4f9493.

Files selected for processing: 27
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/components/SidebarSlide/SidebarSlide.test.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/components/SidebarSlide/SidebarSlide.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/components/WorkspaceActivityMenu/WorkspaceActivityMenu.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/hooks/usePaneRegistry/usePaneRegistry.tsx
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/hooks/useV2WorkspacePaneLayout/useV2WorkspacePaneLayout.ts
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/hooks/useWorkspacePaneOpeners/useWorkspacePaneOpeners.ts
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/hooks/useWorkspaceRightPane/hooks/useRightPaneMode/useRightPaneMode.ts
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/page.tsx
  • apps/desktop/src/renderer/routes/_authenticated/settings/utils/settings-search/settings-search.ts
  • packages/i18n/locales/cs/messages.po
  • packages/i18n/locales/de/messages.po
  • packages/i18n/locales/en/messages.po
  • packages/i18n/locales/es/messages.po
  • packages/i18n/locales/fr/messages.po
  • packages/i18n/locales/id/messages.po
  • packages/i18n/locales/it/messages.po
  • packages/i18n/locales/ja/messages.po
  • packages/i18n/locales/ko/messages.po
  • packages/i18n/locales/nl/messages.po
  • packages/i18n/locales/pl/messages.po
  • packages/i18n/locales/pt-BR/messages.po
  • packages/i18n/locales/ru/messages.po
  • packages/i18n/locales/tr/messages.po
  • packages/i18n/locales/uk/messages.po
  • packages/i18n/locales/vi/messages.po
  • packages/i18n/locales/zh-CN/messages.po
  • packages/i18n/locales/zh-TW/messages.po
Files with no reviewable changes: 22
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/components/SidebarSlide/SidebarSlide.tsx
  • apps/desktop/src/renderer/routes/_authenticated/settings/utils/settings-search/settings-search.ts
  • packages/i18n/locales/vi/messages.po
  • packages/i18n/locales/zh-CN/messages.po
  • packages/i18n/locales/nl/messages.po
  • packages/i18n/locales/id/messages.po
  • packages/i18n/locales/ru/messages.po
  • packages/i18n/locales/it/messages.po
  • packages/i18n/locales/cs/messages.po
  • packages/i18n/locales/es/messages.po
  • packages/i18n/locales/de/messages.po
  • packages/i18n/locales/pt-BR/messages.po
  • packages/i18n/locales/pl/messages.po
  • packages/i18n/locales/en/messages.po
  • packages/i18n/locales/tr/messages.po
  • packages/i18n/locales/fr/messages.po
  • packages/i18n/locales/ko/messages.po
  • packages/i18n/locales/uk/messages.po
  • packages/i18n/locales/zh-TW/messages.po
  • packages/i18n/locales/ja/messages.po
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/hooks/useWorkspacePaneOpeners/useWorkspacePaneOpeners.ts
  • apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/hooks/usePaneRegistry/usePaneRegistry.tsx

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 4 remain after this review.

Walkthrough

The workspace page now uses the right pane area without the former feature-flag branches. The change removes the legacy sidebar, related Changes and pull-request controls, sidebar and Changes preferences, and obsolete translations. Workspace activity and file navigation behavior were also updated.

Changes: Workspace pane consolidation

Layer / File(s) Summary
Route workspace interactions through the right pane
apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/page.tsx, .../components/AddTabMenu/AddTabMenu.tsx, .../components/SidebarSlide/*, .../components/WorkspaceSplitLayout/*, .../hooks/usePaneAreaMoveActions/*, .../hooks/usePaneRegistry/*, .../hooks/useRightPaneAreaLifecycle/*, .../hooks/useWorkspaceFileNavigation/*, .../hooks/useWorkspaceHotkeys/*, .../hooks/useWorkspacePaneOpeners/*, .../hooks/useWorkspaceRightPane/*, .../hooks/useV2WorkspacePaneLayout/*
The workspace page now routes viewer and Changes-pane interactions through the right store. Pane hooks and rendering no longer use the legacy sidebar branches or pane-location flags. SidebarSlide no longer accepts keepMounted; it remains mounted after it first opens.
Remove legacy sidebar and Changes controls
apps/desktop/src/renderer/routes/_authenticated/_dashboard/v2-workspace/$workspaceId/components/ChangesControl/*, .../components/WorkspaceSidebar/*, .../components/V2WorkspaceOpenInButton/*, .../components/V2WorkspaceRunButton/*, .../components/WorkspaceActivityMenu/*, .../state/rowlessSidebarTabStore/*, .../utils/openChangesPaneInStore/*, apps/desktop/src/renderer/lib/github/openPullRequestLink/pullRequestLinkSurfaces.test.ts
The legacy sidebar, shipping and pull-request controls, and rowless sidebar-tab store were removed. The activity menu no longer displays pinned pages. openChangesPaneInStore now focuses the first diff pane in tab order or adds a diff tab.
Retire sidebar and Changes preferences
apps/desktop/src/renderer/hooks/useV2UserPreferences/*, apps/desktop/src/renderer/routes/_authenticated/providers/CollectionsProvider/*, .../routes/_authenticated/components/V2NotificationController/*, .../routes/_authenticated/settings/*, apps/desktop/src/renderer/stores/*, apps/desktop/src/renderer/stores/workspace-creates/*, packages/i18n/locales/*/messages.po
The workspace sidebar-tab and global right-sidebar preferences, and the Changes open-target setting, were removed from schemas, stores, and settings UI. Notification filtering now uses workspace-local sidebar state. Obsolete message entries were removed from locale catalogs.

Estimated code review effort: 4 (Complex) | ~60 minutes

Change: Refactor

Possibly related issues

Suggested reviewers: kitenite, harshithmullapudi

Merge Risk: Minimal · up to b4f94

No actionable issue remains from the reviewed changes; the workspace can proceed through normal merge checks.

Pre-merge checks: Passed 4 · Failed 1

Failed Failed checks: 1 warning

Check name Status Explanation Resolution
Docstring Coverage Warning Docstring coverage is 13.33% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documenta… Write docstrings for the functions missing them to satisfy the coverage threshold.
Passed Passed checks: 4 passed
Check name Status Explanation
Title check Passed The title "refactor(desktop): remove the old workspace layout" follows conventional commit format and matches the main change. The PR removes the legacy center-pane layout and right WorkspaceSidebar, …
Description check Passed The description follows the repository template. It has the 'What & why' section, which explains the removed dead code and lists deletions and flag parameter removals. It has the 'How I tested it' sec…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Title check

Explanation

The title "refactor(desktop): remove the old workspace layout" follows conventional commit format and matches the main change. The PR removes the legacy center-pane layout and right WorkspaceSidebar, leaving the right pane area as the only workspace layout. The title is specific and concise, and it names the scope (desktop).

Full details: Description check

Explanation

The description follows the repository template. It has the 'What & why' section, which explains the removed dead code and lists deletions and flag parameter removals. It has the 'How I tested it' section, which lists typecheck, lint, and test runs, plus an i18n check and an explicit note that the running app was not verified. The checklist is present. Two checklist items are unchecked: 'Allow edits from maintainers' and the CLA signature. These items are optional for this internal change and do not block the check. No linked issue is given in the 'What & why' section, but the template only says to link one if it exists, and the PR cites #9008 and #9204 as context.

Full details: Docstring Coverage

Explanation

Docstring coverage is 13.33% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 15 functions across 23 files.

Resolution

Write docstrings for the functions missing them to satisfy the coverage threshold.

Finishing Touches
Generate docstrings
  • Commit to this branch
  • Create a new PR
Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@expo

expo Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

Preview update published for development build eca66a32 (fingerprint e65ce637d4ee). Open the build on your phone and scan:

Update group 909a69bd

@github-actions

Copy link
Copy Markdown
Contributor

🚀 Preview Deployment

🔗 Preview Links

Service Status Link
Neon Database (Neon) ✅ View Branch
Vercel API (Vercel) ✅ Open Preview
Vercel Web (Vercel) ✅ Open Preview
Vercel Marketing (Vercel) ✅ Open Preview
Vercel Docs (Vercel) ✅ Open Preview

Preview updates automatically with new commits

@greptile-apps

greptile-apps Bot commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Medium impact] The PR appears safe to merge; the removed layout branches were unreachable.

Summary

Removes the old workspace layout and keeps the right pane as the only layout.

  • Every workspace uses the right pane layout.

No actionable issues were found. This review used source checks; it did not verify the running app.

Acknowledged scope: saddlepaddle explicitly identified terminal-link reveal in the file tree as an existing gap and deferred moving the retained WorkspaceSidebar helpers. Neither is reported here.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart LR
  Navigation[Workspace navigation] --> Center[Center: terminals and chats]
  Navigation --> Viewer[Viewer actions]
  Viewer --> Right[Right pane: files, changes, browser and review]
  Center -->|Move viewer panes| Right
  Center --> CenterSaved[Saved paneLayout]
  Right --> RightSaved[Saved rightPaneLayout]
Loading

Reviews (1) · Last reviewed commit: "refactor(desktop): remove the old worksp..." · Reviewed by Greptile

The right pane area is on for everyone (#9008) and useRightPaneAreaEnabled
always returned true, so every branch for the old layout was dead code.

Remove the old right sidebar (WorkspaceSidebar, its header and PR
header), the sidebar tab state (setWorkspaceSidebarTab,
rowlessSidebarTabStore, sidebarState.activeTab), the center Changes pane
and its changesOpenTarget setting, ChangesControl with ShipControl and
PRStatusGroup, V2WorkspaceOpenInButton, V2WorkspaceRunButton, the old
AddTabMenu items, the right-pane-area flag store, the user preference
fields rightSidebarOpen, rightSidebarTab and rightSidebarWidth, and the
file pane branches for files in the center area.

Hooks and components lose the flag parameters: useWorkspaceRightPane,
useRightPaneMode, useRightPaneAreaLifecycle, usePaneAreaMoveActions,
WorkspaceSplitLayout, SidebarSlide, WorkspaceActivityMenu,
V2NotificationController and LinkTierMapper.

The tab hooks and FilesTab under WorkspaceSidebar/ stay: the right pane
tabs still import them.

This branch was previously deployed

1 inactive deployment
preview — b4f94932 Deployed Nov 1, 2026 by saddlepaddle via Deploy Web #13526
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