Repository navigation
feat(macos): add native sidebar filtering and grouping - #163164
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
|
Codex review: needs maintainer review before merge. Reviewed October 1, 2026, 11:20 PM ET / October 2, 2026, 03:20 UTC (Revision 5). ClawSweeper reviewWhat this changesAdds a persistent macOS thread-filter panel, owner and archive filters, grouping and sorting choices, saved display preferences, and owner attribution. Merge readiness✅ Ready for maintainer review This PR remains useful: current main lacks the requested native controls, and the reviewed patch has no actionable correctness findings. The inspected before/after screenshots support the visual change. Priority: P2 Review scores
Verification
How this fits togetherThe native macOS sidebar presents sessions received from the Gateway through its existing roster owner. Local view preferences control which threads appear and how they are grouped without changing session ownership or authorization. flowchart TD
A[Gateway sessions and owner facets] --> B[Canonical session roster]
C[Profile view preferences] --> D[Filter and grouping projection]
B --> D
D --> E[Native thread sidebar]
E --> F[Selected conversation]
Before mergeNone. Agent review detailsSecurityNone. PR surfaceDocs +9, Other +1123. Total +1132 across 18 files. View PR surface stats
Review metrics
Technical reviewBest possible solution: Keep filtering and grouping as profile-scoped projections of the canonical roster, preserving existing preferences and shared-client defaults. Do we have a high-confidence way to reproduce the issue? Not applicable as a feature proposal; current-main source establishes the missing native controls, and inspected screenshots show the added panel. Is this the best way to solve the issue? Yes: extending the existing roster projection and replacing its options menu avoids a competing session owner while preserving shared-client defaults. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 64fbbe87c10a. LabelsLabel changes: No label changes. Label justifications:
EvidenceWhat I checked:
Likely related people:
Rating scale
Overall follows the weaker of proof and patch quality. Workflow
HistoryReview history (4 earlier review cycles)
|
ce16bc5 to
1f7d1e1
Compare
Add a persistent Filters panel with owner and archive controls, grouping, People sort, empty-group choices, and row attribution. Keep profile-scoped preferences and the existing canonical roster; iOS and palette defaults remain unchanged. Publish owner facets from browsing and search after generation fencing. Preserve loaded descendant summaries while filtering owner navigation. Replace the old options menu and inline section rendering, and document the native controls. Validation: 85 focused shared-kit tests; native/plain macOS builds; native test compilation; iOS simulator shared-kit compile; changed-file SwiftLint, SwiftFormat, localization verification, and independent Codex review with its P2 descendant-summary finding reproduced and corrected.
1f7d1e1 to
fc9b45b
Compare
|
Final reviewed head: Local proof is complete: 114 tests in 8 sidebar/hovercard suites pass; native/plain macOS builds, native test compilation, iOS shared-kit compilation, changed-file lint/format, and localization verification pass. The independent P2 owner-summary finding was reproduced and repaired at the canonical query/tree boundary. ClawSweeper reviewed this exact head with no findings or before-merge/rank-up actions (readiness 4/6, proof 5/6). The first CI run failed strict iOS lint; those six-file style corrections were pushed once. Subsequent head replacements resolved two actual GitHub conflicts after the group-defaults and hovercard lanes landed. Both conflicts were confined to generated localization; the source hooks merged cleanly, the inventory was regenerated, and affected checks passed again. No CI job was rerun. Current-head CI: passed — https://github.com/openclaw/openclaw/actions/runs/36959245759 (exact head above). Commands run from the repository root, with swift build --package-path apps/macos --build-system native --product OpenClaw
swift build --package-path apps/macos --product OpenClaw
swift build --package-path apps/macos --build-system native --build-tests
swift test --package-path apps/shared/OpenClawKit --filter 'ChatSession(Sidebar(Filters|FiltersModel|Query|Model)|HoverCard|HoverCardProjection|HoverInteraction)Tests'
pnpm native:i18n:baseline
pnpm native:i18n:verify
node_modules/.bin/oxfmt --check docs/platforms/mac/webchat.md
git diff --check 81f65e98ad4ec5270c864d641950eb2067f84802 HEADShared-kit iOS compile, from xcodebuild -scheme OpenClawChatUI -destination 'generic/platform=iOS Simulator' -derivedDataPath .build-ios-filters CODE_SIGNING_ALLOWED=NO buildChanged-file checks used explicit Swift paths (zsh): base=81f65e98ad4ec5270c864d641950eb2067f84802
files=(${(f)"$(git diff --name-only --diff-filter=AM "$base" HEAD -- '*.swift')"})
prod_files=(${(f)"$(git diff --name-only --diff-filter=AM "$base" HEAD -- 'apps/shared/OpenClawKit/Sources/**/*.swift')"})
swiftlint lint --no-cache --config config/swiftlint.yml --quiet "${files[@]}"
GITHUB_ACTIONS=true node scripts/run-swiftlint.mts --strict --no-cache --config apps/ios/.swiftlint.yml --quiet "${prod_files[@]}"
swiftformat --cache ignore --lint --config config/swiftformat "${files[@]}"The two embedded synthetic screenshots were inspected in full. Both uploaded links return |
|
Merged via squash.
|
* feat(macos): add native sidebar filtering and grouping Add a persistent Filters panel with owner and archive controls, grouping, People sort, empty-group choices, and row attribution. Keep profile-scoped preferences and the existing canonical roster; iOS and palette defaults remain unchanged. Publish owner facets from browsing and search after generation fencing. Preserve loaded descendant summaries while filtering owner navigation. Replace the old options menu and inline section rendering, and document the native controls. Validation: 85 focused shared-kit tests; native/plain macOS builds; native test compilation; iOS simulator shared-kit compile; changed-file SwiftLint, SwiftFormat, localization verification, and independent Codex review with its P2 descendant-summary finding reproduced and corrected. * style(apple): satisfy strict shared-kit Swift lint
What Problem This Solves
The native macOS sidebar lacks the Control UI's owner and archive filters, grouping choices, and persistent filter panel, making larger shared session rosters harder to navigate.
User Impact
Open View options beside Threads for a persistent Filters panel with searchable owners, Involving me, Active / Archived / All, automation/system toggles, Group by, People sort, empty-group choices, and message previews. Active membership filters show a count and can be reset. Owner/participant attribution and archived-by labels follow the selected view.
Preferences remain scoped to the app profile. Existing iOS and command-palette projection defaults are unchanged; no Gateway configuration or database migration is required.
Why This Change Was Made
The sidebar keeps the existing canonical roster and query owner. View options control projection and presentation rather than creating a second session cache. Grouping preserves pin order, curated child placement, archived-parent suppression, server section ordering, and the existing group route lease. During integration, search was found to discard its received owner facet; both browsing and search now publish that facet through the query owner after generation fencing, and scope changes clear it. Explicit owner filters preserve summaries from already-loaded linked children while hiding those navigation rows; search and involving-me membership remain unchanged.
Production: +819/-107 (net +712). Tests: +395/-7. Generated localization inventory: +42/-19. Docs: +10/-1. The production growth implements the new panel, grouping projection, and row attribution; it replaces the former options menu and inline section renderer rather than retaining parallel UI paths. Superseded public initializers are removed.
Evidence
ChatSessionSidebarFiltersTests,ChatSessionSidebarFiltersModelTests,ChatSessionSidebarModelTests, andChatSessionSidebarQueryTests. The latest run also includes the existing hovercard data, decoding, projection, and interaction suites after their row integration landed. The final command took 62.97s including incremental compilation; tests executed in 0.134s.resultAPI; all now consume the canonical owner facet.OpenClawChatUIiOS simulator compile: passed, 20.88s after the integration repair.pnpm native:i18n:baseline;pnpm native:i18n:verifypassed, 2.57s. No interpolatedString(localized:)additions. Docs formatting passed, 0.84s;git diff --checkpassed.Remaining scope: catalog-renderer suppression belongs to its separate integration lane. Native Coding grouping uses available Gateway metadata and ACP keys; the web's provisional prepared-work marker has no native counterpart. A pre-existing native heartbeat-classification difference remains a separate follow-up; this change preserves its existing visibility classification. The captures prove the rendered panel; they do not independently prove every profile-reopen or catalog interaction.
CI and review follow-through
The first exact-head CI run failed strict iOS SwiftLint and was then cancelled by fail-fast. The earlier direct, non-strict changed-file check had allowed those warnings. The corrective commit fixes the six affected source files; the exact CI-mode strict iOS lint now passes (0.27s, complexity remains advisory), and all 85 focused tests, both macOS builds, native test compilation, the shared-kit iOS simulator compile, formatting, and i18n checks were repeated successfully. No CI job was rerun.
ClawSweeper's completed review found no actionable defect, rated readiness 4/6, accepted the inspected screenshot proof, and listed no before-merge or rank-up actions. The later review of the strict-lint head likewise found no findings, with proof confidence 5/6 and overall readiness 4/6. No re-review was requested.
GitHub subsequently reported a real conflict after the group-defaults lane landed. The first conflict rebase onto
31d7ba1c7a2e72681c54664e3b096c817fca184aresolved onlyapps/.i18n/native-source.jsonby regeneration. Source merged cleanly and preserves main's new group-defaults sheet integration;git range-diffshows the same FILTERS patch plus generated-inventory context. All affected local checks were rerun successfully; the timings above describe this rebased candidate. The pre-rebase CI run was replaced because of that conflict, not to obtain green.A second real conflict followed the hovercard merge. Its only conflict was again the generated localization inventory; the source row hook and response additions merged cleanly. The final rebase is based on
81f65e98ad4ec5270c864d641950eb2067f84802, with main's hovercard and group-defaults behavior preserved. All affected checks passed again, including 114 tests across the sidebar and hovercard suites. The previous-head CI run was superseded for this actual conflict. No CI job was rerun or branch refreshed merely to obtain green.Screenshots