feat(miner-ui): add the persistent collapsible chat rail shell - #6564
Conversation
…ored#6513) Mounts a persistent chat rail once in the root route so it survives client-side navigation across the four routes. - apps/loopover-miner-ui/src/components/chat-rail.tsx — a pure structural shell. Wide viewports dock a ~380px complementary panel beside the routed content; below the ui-kit useIsMobile breakpoint it collapses to the same Sheet-based slide-over sidebar.tsx uses on mobile (imported from @loopover/ui-kit, not a second bespoke mobile-collapse mechanism). A visible toggle expands/collapses it; collapsing only hides the docked panel (never unmounts it), so future in-rail state is preserved across an expand/collapse cycle. Static placeholder content only — no composer, message list, streaming, or backend call. - apps/loopover-miner-ui/src/routes/__root.tsx — restructured into a row that holds the routed <main> and the rail side by side without changing the four routes' own content (and preserving the existing active-route nav highlighting). The rail open/collapsed state lives in the exported RootShell that the root route mounts once, so it persists across route navigation. No @loopover/ui-kit change, no route-tree change, no scroll-area/avatar/ state-views usage, no config flag. This app's files are outside Codecov's coverage.include; the local vitest gate stays green. Tests — apps/loopover-miner-ui/src/chat-rail.test.tsx: - Wide viewport docks a complementary panel (not the sheet); collapsed hides it from the a11y tree while the toggle stays visible; the toggle requests the open/close change. - Below the mobile breakpoint the rail renders via the ui-kit Sheet slide-over, not the docked panel. - RootShell mounts exactly one rail and keeps its open state across a simulated client-side navigation (the Outlet content swaps while the shell stays mounted). Closes JSONbored#6513
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
|
Tip ✅ LoopOver review result - approve/merge recommendedReview updated: 2026-07-16 13:58:24 UTC
Review summary Nits — 5 non-blocking
Decision drivers
Context & advisory signals — never blocks the verdict
Linked issue satisfactionAddressed Review context
Contributor next steps
Signal definitions
🧪 Chat with LoopOverAsk LoopOver a question about this PR directly in a comment — grounded only in the same cached, public-safe facts shown above, never a new claim.
Full command reference: https://loopover.ai/docs/loopover-commands 🧪 Experimental — new and may change. Visual preview
Click any thumbnail to open the full-size screenshot. Before = production · After = this PR's preview deploy. 🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by LoopOver, a quiet PR intelligence layer for OSS maintainers.
|

What
Mounts a persistent, collapsible chat rail once in the root route so it survives client-side navigation across all four routes. Pure structural shell — no chat content yet.
Resolves #6513.
apps/loopover-miner-ui/src/components/chat-rail.tsx— the rail shell.apps/loopover-miner-ui/src/routes/__root.tsx— mounts it once, beside the routed content.Behavior (per the issue's requirements)
<main>, not overlapping it.__root.tsx's container is restructured into a row holding the main content and the rail side by side, without changing the four routes' own content (and preserving the existing active-route nav highlighting).useIsMobilebreakpoint: collapses to the sameSheet-based slide-oversidebar.tsxalready uses on mobile — imported from@loopover/ui-kit/components/sheet+@loopover/ui-kit/hooks/use-mobile, not a second bespoke mobile-collapse mechanism or a new breakpoint constant.hidden) — it never unmounts the rail, so future in-rail state is preserved across an expand/collapse cycle.RootShellthat the root route mounts once, so it survives client-side navigation (in-memory; nolocalStorage, per the issue).Scope / non-goals (explicit "do NOT" list honored)
matchMedia/ CSS-only breakpoint for the mobile mode — reusessidebar.tsx'sSheet+use-mobile.tsxexactly.@loopover/ui-kitchange; noscroll-area/avatar/state-viewsusage; no route-tree change; no config flag; no composer/message-list/streaming/fetch.Tests —
apps/loopover-miner-ui/src/chat-rail.test.tsxSheetslide-over (asserted by roledialog), not the docked panel.RootShellmounts exactly one rail and keeps its open state across a simulated client-side navigation (theOutletcontent swaps while the shell stays mounted).apps/**is outside Codecov'scoverage.include, so no patch-coverage gate applies. Locally green: miner-uinpm run test(--coverage) — full suite 155/155 pass, coverage 87.04% stmts / 86.39% branch / 79.79% funcs / 89.08% lines (above the app floor);tsc --noEmitclean;eslintclean (no new warnings).