Recursive deploy ladder: Company + Org tiers, mesh mark, two-tier rail
Completes the scale ladder (single → team → company → org). Every tier is a
topology whose nodes are the tier below; running a parent recursively runs each
child's sub-topology down to the leaf claws.
Backend:
- migration 0011: companies/company_teams, orgs/org_companies, topology_runs.tier
- cm-db repos for companies + orgs (mirror teams)
- TurnRequest.attrs (forwarded from node.attrs) for child-id binding
- SubTopologyExecutor (recursive_exec.rs): a parent "turn" runs the child's
sub-topology; durability via parent updated_at keepalive + cancel propagation
+ depth cap; boxed future breaks the org→company recursion
- topology_worker selects executor by job.tier
- routes: /api/companies, /api/orgs (create/list/get/run) + unified
/api/structure/{level}/{id} for the zoom canvas
Frontend:
- MeshMark: node-mesh brand glyph (replaces the claw PNG), tier variants
- TopologyGraphView: optional onNodeClick/nodeMeta + dark-token theming
- StructureCanvas + Breadcrumb: one recursive zoom view for every tier
(drill down on node click, breadcrumb up); TeamRunPanel extracted + shared
- two-tier Discord-style rail: StructureRail (mesh mark + org/company/team
glyphs + tools popover + deploy + user) | RosterColumn (selected group's
children, or your claws); SecondaryNav for cross-cutting tools
- ComposeWizard (company/org) wired into DeployWizard; /companies + /orgs pages
Co-Authored-By: Claude Opus 4.8 <[email protected]>
This commit is contained in:
co-authored by
Claude Opus 4.8
parent
bba18a4687
commit
3eca4ed70c
@@ -0,0 +1,6 @@
|
||||
import { StructureCanvas } from "@/components/structure/StructureCanvas";
|
||||
|
||||
export default async function OrgPage({ params }: { params: Promise<{ id: string }> }) {
|
||||
const { id } = await params;
|
||||
return <StructureCanvas level="org" id={id} />;
|
||||
}
|
||||
@@ -0,0 +1,63 @@
|
||||
"use client";
|
||||
|
||||
import { useEffect, useState } from "react";
|
||||
import Link from "next/link";
|
||||
|
||||
interface GroupSummary {
|
||||
id: string;
|
||||
name: string;
|
||||
kind: string;
|
||||
status: string;
|
||||
}
|
||||
|
||||
export default function OrgsPage() {
|
||||
const [orgs, setOrgs] = useState<GroupSummary[]>([]);
|
||||
|
||||
useEffect(() => {
|
||||
void (async () => {
|
||||
try {
|
||||
const r = await fetch("/api/orgs");
|
||||
if (r.ok) setOrgs((await r.json()) as GroupSummary[]);
|
||||
} catch {
|
||||
/* ignore */
|
||||
}
|
||||
})();
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<div className="mx-auto flex w-full max-w-3xl flex-col gap-4 p-6">
|
||||
<div className="flex items-center justify-between">
|
||||
<h1 className="text-xl font-semibold tracking-tight">Organizations</h1>
|
||||
<Link
|
||||
href="/claws/new"
|
||||
className="rounded-full bg-coral px-4 py-2 text-sm font-medium text-white"
|
||||
>
|
||||
Deploy an org
|
||||
</Link>
|
||||
</div>
|
||||
|
||||
{orgs.length === 0 ? (
|
||||
<p className="text-sm text-muted-foreground">
|
||||
No organizations yet — an org is a topology of companies.
|
||||
</p>
|
||||
) : (
|
||||
<ul className="flex flex-col gap-2">
|
||||
{orgs.map((o) => (
|
||||
<li key={o.id}>
|
||||
<Link
|
||||
href={`/orgs/${o.id}`}
|
||||
className="flex items-center gap-3 rounded-lg border border-border p-3 hover:bg-muted/30"
|
||||
>
|
||||
<span className="text-sm font-medium text-foreground">{o.name}</span>
|
||||
<span className="rounded-full bg-muted px-2 py-0.5 text-xs capitalize text-muted-foreground">
|
||||
{o.kind}
|
||||
</span>
|
||||
<span className="text-xs text-muted-foreground">{o.status}</span>
|
||||
</Link>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
)}
|
||||
</div>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user