Fix custom right-sidebar groups context
Summary
Custom sidebars opened in the right sidebar received an empty data.groups() list even when the window contained workspace groups. The right-sidebar context now projects the same workspace-group snapshots used by pane and left-sidebar hosts, so data.groups() exposes each group’s identity, name, collapse/pin state, anchor, color, and icon.
Fixes #20281.
Testing
- Added
RightSidebarCommandPaletteTests.testCustomSidebarDataContextIncludesWorkspaceGroups, covering the produced interpretergroupspayload. python3 scripts/verify-local.py --affected origin/main— 4/4 affected checks passed../scripts/lint-pbxproj-test-wiring.sh— passed../scripts/localize-changes --base origin/main— 0 changed keys; catalog parity passed.- CI run 38497149053 passed the macOS compile admission and changed app-host unit-test suite, including
RightSidebarCommandPaletteTests. - The local checkout is Linux without
xcodebuild; native compilation and focused test execution were verified by the macOS CI run above.
Changelog
Fixed: Custom sidebars opened in the right sidebar now receive workspace groups.
Proof
No screenshot: this checkout has no macOS runtime. The regression test asserts the exact interpreter payload consumed by custom sidebars.
Checklist
- Behavior changes have added or updated tests.
- Localization audit completed; no user-facing strings changed.
Need help on this PR? Tag @codesmith-bot with what you need.
Summary by cubic
Fixes custom sidebars opened in the right sidebar receiving an empty data.groups() list even when the window contained workspace groups.
The right-sidebar context now projects the same workspace-group snapshots as the pane and left-sidebar hosts, so data.groups() exposes each group's identity, name, collapse/pin state, anchor, color, and icon. The duplicated group-snapshot mapping was extracted into a shared ContentView.customSidebarDataContext helper used by all three sidebar hosts, with a regression test asserting the produced groups payload.
Fixes #20281.
Summary by CodeRabbit
- New Features
- Custom sidebar data now includes workspace group details, including group names, collapsed and pinned states, anchor workspaces, colors, and icons. This gives custom sidebar views access to richer information about how workspaces are organized.
- Tests
- Added coverage to verify that workspace group details are included in custom sidebar data.