feat(web): split sidebar sessions into My sessions / Shared with me tabs - #2156
Conversation
|
|
UI Preview for this PR has been removed. |
Sessions shared with the viewer previously sat in an inline collapsible "Shared with me" section below the owned-session list. Move them to a dedicated tab so the two scopes are visually distinct and the shared list gets its own space (flat, headerless, with its own infinite scroll). The "My sessions" tab keeps the full Pinned / Projects / Sessions structure; "Shared with me" is a flat list of every non-archived session the viewer doesn't own (computed from notArchived, so a pinned/filed shared session never drops off it). New session snaps back to My sessions. The tab strip only renders on a multi-user server — gated on !isCurrentServerLocal(), the same predicate AppShell uses to disable the Share affordance. A loopback-only local server has a single user and can't share sessions, so the split is meaningless there; the list falls back to the owned sessions. Keyboard nav and shift-select are tab-aware and, on the shared tab, ignore the collapsed set (the list always renders expanded), so a stale persisted "Shared with me" collapse can't empty them. Co-authored-by: Isaac
00a81fb to
4f9e9ec
Compare
|
/review |
|
… empty tabs Address two issues in the sidebar tab split: - Pinned and project folders drew from all non-archived sessions, so a shared session the viewer pinned (localStorage is ownership-agnostic) or filed into a project (editable share) rendered under Pinned / a project folder on My sessions AND on the Shared tab. Build both from owned-only sessions so non-owned sessions stay on the Shared tab exclusively. - The list is one paginated stream (owned + shared mixed, updated_at desc), so a tab can be empty on the loaded window while its sessions live on a later page. The pagination sentinel lived inside the non-empty render branch, so an empty tab stopped fetching and stranded the user on a false "empty" state (e.g. Shared tab when page 1 is all owned). Keep the sentinel mounted in the empty branch when more pages exist. Co-authored-by: Isaac
|
Thanks Polly — both blocking findings were valid and are fixed in ce5e7df: (a) False-empty + stalled pagination — the pagination sentinel lived inside the non-empty render branch, so an empty tab (Shared tab when page 1 is all-owned, or vice versa) stopped fetching. Now the sentinel stays mounted in the (b) Pinned/filed shared sessions leaking onto My sessions — Added 3 regression tests (pinned-shared stays off Pinned, filed-shared stays off Projects, empty Shared tab keeps paginating). 63 Sidebar tests pass, tsc clean. Count badge (non-blocking note) — already removed in an earlier commit; the description was stale. Dropped the badge claim from the PR body. |
…ebar tabs Rather than rendering the Shared tab as a bespoke flat list, scope the section-building to the active tab's conversations and render the same Pinned / Projects / Sessions tree for both tabs. "mine" is the sessions the viewer owns; "shared" is the ones others shared with them. - Pins are localStorage and ownership-agnostic, so a pinned shared session now floats to a Pinned section on the Shared tab, matching My sessions. - Projects stay a My-sessions-only tool: filing into a project is now gated on ownership (the row's "Add to project" / "Move session" menu item is hidden for non-owned sessions), and the Shared tab renders no Projects group. A shared session that already carries a project label just lands in the flat Sessions list there. - Collapses the special-case `showShared` render branch and the shared special cases in keyboard-nav / shift-select ordering, since `sections` is now tab-scoped. Co-authored-by: Isaac
|
/review |
|
|
🏷️ Doc impact: The sidebar now splits sessions into "My sessions" and "Shared with me" tabs (hidden on single-user servers), changing how users navigate and see their sessions in the web UI, which affects the core user-journey docs. Drafting a docs PR to Auto-classified on merge. Set the label manually before merging to override. · run |
* docs: document omnigent-ai/omnigent#2156 * Apply suggestion from @serena-ruan * Apply suggestions from code review Co-authored-by: Serena Ruan <82044803+serena-ruan@users.noreply.github.com> --------- Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> Co-authored-by: Serena Ruan <82044803+serena-ruan@users.noreply.github.com>
* docs: document omnigent-ai/omnigent#1722 (#261) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#2018 (#265) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#1386 (#272) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#2156 (#278) * docs: document omnigent-ai/omnigent#2156 * Apply suggestion from @serena-ruan * Apply suggestions from code review Co-authored-by: Serena Ruan <82044803+serena-ruan@users.noreply.github.com> --------- Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> Co-authored-by: Serena Ruan <82044803+serena-ruan@users.noreply.github.com> * docs: document omnigent-ai/omnigent#2022 (#268) * docs: document omnigent-ai/omnigent#2022 * docs: add steering gif and simplify message queue section Co-authored-by: Isaac --------- Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> Co-authored-by: Serena Ruan <serena.rxy@gmail.com> * chore(api): sync openapi.json from omnigent@3c7a558 (#274) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#526 (#279) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: rename hindsight extra to memory (omnigent[memory]) (#282) The memory tools ship under the `memory` extra (omnigent[memory]), not `hindsight`. Update the install instruction and extra name to match. The Hindsight product name and the hindsight_* tool names are unchanged. * docs: document default base branch for new worktrees (#284) * docs: document default base branch for new worktrees * docs: condense worktree branches section and add setting demo gif Co-authored-by: Isaac --------- Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> Co-authored-by: Serena Ruan <serena.rxy@gmail.com> * chore(api): sync openapi.json from omnigent@7fb779f (#281) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * chore(api): sync openapi.json from omnigent@60e775a (#288) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#2152 (#280) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#1859 (#277) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#2135 (#276) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> --------- Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> Co-authored-by: Serena Ruan <82044803+serena-ruan@users.noreply.github.com> Co-authored-by: Serena Ruan <serena.rxy@gmail.com> Co-authored-by: Pat Sukprasert <pattara.sk127@gmail.com> Co-authored-by: Dhruv Gupta <dhruv.gupta@databricks.com>
…abs (omnigent-ai#2156) * feat(web): split sidebar sessions into My sessions / Shared with me tabs Sessions shared with the viewer previously sat in an inline collapsible "Shared with me" section below the owned-session list. Move them to a dedicated tab so the two scopes are visually distinct and the shared list gets its own space (flat, headerless, with its own infinite scroll). The "My sessions" tab keeps the full Pinned / Projects / Sessions structure; "Shared with me" is a flat list of every non-archived session the viewer doesn't own (computed from notArchived, so a pinned/filed shared session never drops off it). New session snaps back to My sessions. The tab strip only renders on a multi-user server — gated on !isCurrentServerLocal(), the same predicate AppShell uses to disable the Share affordance. A loopback-only local server has a single user and can't share sessions, so the split is meaningless there; the list falls back to the owned sessions. Keyboard nav and shift-select are tab-aware and, on the shared tab, ignore the collapsed set (the list always renders expanded), so a stale persisted "Shared with me" collapse can't empty them. Co-authored-by: Isaac * fix(web): keep pinned/filed shared sessions off My sessions; paginate empty tabs Address two issues in the sidebar tab split: - Pinned and project folders drew from all non-archived sessions, so a shared session the viewer pinned (localStorage is ownership-agnostic) or filed into a project (editable share) rendered under Pinned / a project folder on My sessions AND on the Shared tab. Build both from owned-only sessions so non-owned sessions stay on the Shared tab exclusively. - The list is one paginated stream (owned + shared mixed, updated_at desc), so a tab can be empty on the loaded window while its sessions live on a later page. The pagination sentinel lived inside the non-empty render branch, so an empty tab stopped fetching and stranded the user on a false "empty" state (e.g. Shared tab when page 1 is all owned). Keep the sentinel mounted in the empty branch when more pages exist. Co-authored-by: Isaac * refactor(web): reuse Pinned / Projects / Sessions layout for both sidebar tabs Rather than rendering the Shared tab as a bespoke flat list, scope the section-building to the active tab's conversations and render the same Pinned / Projects / Sessions tree for both tabs. "mine" is the sessions the viewer owns; "shared" is the ones others shared with them. - Pins are localStorage and ownership-agnostic, so a pinned shared session now floats to a Pinned section on the Shared tab, matching My sessions. - Projects stay a My-sessions-only tool: filing into a project is now gated on ownership (the row's "Add to project" / "Move session" menu item is hidden for non-owned sessions), and the Shared tab renders no Projects group. A shared session that already carries a project label just lands in the flat Sessions list there. - Collapses the special-case `showShared` render branch and the shared special cases in keyboard-nav / shift-select ordering, since `sections` is now tab-scoped. Co-authored-by: Isaac Signed-off-by: Aditya Devarapalli <adityareddyd2@gmail.com>
* docs: document omnigent-ai/omnigent#1722 (#261) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#2018 (#265) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#1386 (#272) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#2156 (#278) * docs: document omnigent-ai/omnigent#2156 * Apply suggestion from @serena-ruan * Apply suggestions from code review Co-authored-by: Serena Ruan <82044803+serena-ruan@users.noreply.github.com> --------- Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> Co-authored-by: Serena Ruan <82044803+serena-ruan@users.noreply.github.com> * docs: document omnigent-ai/omnigent#2022 (#268) * docs: document omnigent-ai/omnigent#2022 * docs: add steering gif and simplify message queue section Co-authored-by: Isaac --------- Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> Co-authored-by: Serena Ruan <serena.rxy@gmail.com> * chore(api): sync openapi.json from omnigent@3c7a558 (#274) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#526 (#279) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: rename hindsight extra to memory (omnigent[memory]) (#282) The memory tools ship under the `memory` extra (omnigent[memory]), not `hindsight`. Update the install instruction and extra name to match. The Hindsight product name and the hindsight_* tool names are unchanged. * docs: document default base branch for new worktrees (#284) * docs: document default base branch for new worktrees * docs: condense worktree branches section and add setting demo gif Co-authored-by: Isaac --------- Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> Co-authored-by: Serena Ruan <serena.rxy@gmail.com> * chore(api): sync openapi.json from omnigent@7fb779f (#281) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * chore(api): sync openapi.json from omnigent@60e775a (#288) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#2152 (#280) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#1859 (#277) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document omnigent-ai/omnigent#2135 (#276) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> * docs: document official kubernetes server image variant (#285) Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> --------- Co-authored-by: omnigent-ci[bot] <294685417+omnigent-ci[bot]@users.noreply.github.com> Co-authored-by: Serena Ruan <82044803+serena-ruan@users.noreply.github.com> Co-authored-by: Serena Ruan <serena.rxy@gmail.com> Co-authored-by: Pat Sukprasert <pattara.sk127@gmail.com> Co-authored-by: Dhruv Gupta <dhruv.gupta@databricks.com> Co-authored-by: Daniel Lok <daniel.lok@databricks.com>
Related issue
N/A
Summary
Splits the web sidebar's session list into two tabs — My sessions and Shared with me — instead of stacking sessions-shared-with-you in an inline collapsible section under the owned list.
notArchived(notrest), so a shared session isn't dropped by the owned tab's pin/file filtering.!isCurrentServerLocal(), the same predicateAppShelluses to disable the Share affordance (serverOrigin.ts: "Sharing a session from a loopback-only server produces links nobody else can open"). A loopback-only local server has a single user and can't share sessions, so the split is meaningless there and the list falls back to the owned sessions.updated_at desc); the sentinel stays mounted even when the current tab is empty on the loaded window but more pages exist, so a tab whose sessions live on a later page keeps loading instead of showing a false "empty" state.Test Plan
cd web && npm test— full suite green.cd web && npm run build—tsc -b && vite buildclean.npx tsc --noEmit— clean.Demo
Screen.Recording.2026-07-08.at.5.30.22.PM.mov
Type of change
Test coverage
Coverage notes
Manual verification: unit-level via the Sidebar suites (mocking
@/lib/serverOriginto toggle multi-user vs local). ThemultiUsergate, per-tab keyboard-nav/shift-select ordering, owned-only pin/project construction, and empty-tab pagination are exercised by the tests. The e2e-ui runner has no workspace so the tab UI isn't covered there.Changelog
Sessions shared with you now live in a dedicated "Shared with me" sidebar tab (multi-user servers only)
This pull request and its description were written by Isaac.