Dashboard: integrated post-login screen + service-worker auto-update
Login landed on an empty "Pick a claw" stub — the integrated dashboard from the design comp was never assembled as the home. Now `/` IS the dashboard. - public/sw.js: cache v2→v3; RegisterServiceWorker reloads once when a new worker activates, so deploys are picked up without a manual hard-refresh - (workspace)/layout: ShellChrome renders the dashboard bare on "/" (it's self-contained) and the shared TopBar/LeftRail/StatusBar on every other route - components/dashboard: Dashboard (state machine + data) — top bar w/ breadcrumb, ORG/CO/TEAM/CLAW tier rail, tier-aware context list, TopologyCanvas (6-mode view-as selector, generalized layouts), and the agent "computer" slide-out (cm-fade) wrapping the existing ComputerPanel; status bar - motion.css: cm-fade keyframe Wired to existing endpoints (/api/teams|companies|orgs, /api/structure/*, /api/team/claws, /api/structure/stats, + ComputerPanel's apps/runtime-config/ routines). Defaults to the most-recent team; claw click opens the slide-out. Co-Authored-By: Claude Opus 4.8 <[email protected]>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
d2354e1f72
commit
bd6f48c2b7
@@ -1,9 +1,7 @@
|
||||
import { redirect } from "next/navigation";
|
||||
import { z } from "zod";
|
||||
|
||||
import { LeftRail } from "@/components/shell/LeftRail";
|
||||
import { StatusBar } from "@/components/shell/StatusBar";
|
||||
import { TopBar } from "@/components/shell/TopBar";
|
||||
import { ShellChrome } from "@/components/shell/ShellChrome";
|
||||
import { ApiAuthError, apiFetch } from "@/lib/api/http";
|
||||
import { fetchClaws, fetchCredits, fetchMe } from "@/lib/api/team";
|
||||
import {
|
||||
@@ -53,19 +51,17 @@ export default async function WorkspaceLayout({
|
||||
throw error;
|
||||
}
|
||||
return (
|
||||
<div className="flex h-dvh flex-col">
|
||||
<TopBar user={user} stats={stats} />
|
||||
<div className="flex min-h-0 flex-1">
|
||||
<LeftRail
|
||||
roster={roster}
|
||||
orgs={orgs}
|
||||
companies={companies}
|
||||
teams={teams}
|
||||
creditsBalance={credits.available}
|
||||
/>
|
||||
<main className="min-w-0 flex-1 overflow-y-auto">{children}</main>
|
||||
</div>
|
||||
<StatusBar stats={stats} doors={doors} />
|
||||
</div>
|
||||
<ShellChrome
|
||||
user={user}
|
||||
roster={roster}
|
||||
orgs={orgs}
|
||||
companies={companies}
|
||||
teams={teams}
|
||||
creditsBalance={credits.available}
|
||||
stats={stats}
|
||||
doors={doors}
|
||||
>
|
||||
{children}
|
||||
</ShellChrome>
|
||||
);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user