From fde858fda3d26601827d6ebe217ae519f70b40be Mon Sep 17 00:00:00 2001 From: amosblomqvist Date: Mon, 5 Oct 2026 07:09:16 +0300 Subject: [PATCH] ui: the drafts go chrome-less; serif titles name sessions, always (owner round 11) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Both /chat/new drafts lose their TopBar — home's register now: drag mask first in the DOM, floating sidebar-reopen toggle as the only pointer-events-auto spot, the empty state carrying the orientation. The chain picker's own bar then sits at the very top of the column, exactly like the graph view — no stacked bars, no special-casing. The chain table drops its 'Chains' title with it: the serif title register is RESERVED — it always names a session; the table names nothing, so its bar carries counts + search + close only. --- components/chain-table.tsx | 14 ++++++++------ components/new-session.tsx | 32 ++++++++++++++++++++----------- components/top-bar.tsx | 5 ++++- tests/render-chain-table.test.tsx | 7 ++++--- 4 files changed, 37 insertions(+), 21 deletions(-) diff --git a/components/chain-table.tsx b/components/chain-table.tsx index ff268f2..d1d7554 100644 --- a/components/chain-table.tsx +++ b/components/chain-table.tsx @@ -237,13 +237,15 @@ export function ChainTableBody({ return (
- {/* THE shared top bar (standardization ruling): title at the standard - size, drag mechanics, sidebar reopen, traffic-light gutter — the - same element as every chat surface. Search + close - carve out with lh-no-drag (the mask law: later in the DOM). */} + {/* THE shared top bar (standardization ruling): drag mechanics, + sidebar reopen, traffic-light gutter — the same element as every + chat surface. NO TITLE (owner round 11, 2026-10-05): the serif + title register is RESERVED — it always names a session; the + chain table names nothing, so its bar carries counts + search + + close only. Search + close carve out with lh-no-drag (the mask + law: later in the DOM). */} - Chains - + {chains.length} {chains.length === 1 ? "chain" : "chains"} · {nodes.length} {nodes.length === 1 ? "node" : "nodes"}
diff --git a/components/new-session.tsx b/components/new-session.tsx index fdeb468..a7b19d0 100644 --- a/components/new-session.tsx +++ b/components/new-session.tsx @@ -5,7 +5,7 @@ import { useRouter } from "next/navigation"; import { Conversation, ConversationContent, ConversationEmptyState } from "@/components/ai-elements/conversation"; import { Composer } from "@/components/composer"; import { DictationBar, joinDictation, useDictation } from "@/components/dictation"; -import { TopBar } from "@/components/top-bar"; +import { SidebarToggle } from "@/components/sidebar"; import { SetupDialog } from "@/components/setup-dialog"; import { useStrongKeyless, useZeroKeys, ZeroKeysPill } from "@/components/setup-cta"; import { StatsBar } from "@/components/stats-bar"; @@ -144,17 +144,19 @@ export function DraftShell({ } }, [dictation.active]); return ( -
+ /* CHROME-LESS CREATION SURFACE (owner round 11, 2026-10-05): the + * drafts join home's register — no TopBar, no title (the serif title + * always names a session; a draft has none). Home's proven pattern + * verbatim: a drag mask first in the DOM, a floating reopen toggle + * (the only pointer-events-auto spot), the empty state carrying the + * orientation. The chain picker then owns the column top exactly + * like the graph view's — no stacked bars. */ +
+ {/* Window-drag strip — deliberately FIRST in the DOM (the mask + law: no-drag subtraction resolves by DOM order, so every + carved control later in the tree subtracts correctly). */} + ); } diff --git a/components/top-bar.tsx b/components/top-bar.tsx index 7ac13ed..ec4a18b 100644 --- a/components/top-bar.tsx +++ b/components/top-bar.tsx @@ -23,7 +23,10 @@ * - border-b border-border px-3, gap-3 rhythm. * * The consumer brings the title (font-title text-3xl tracking-tight) and - * any right-side controls. `drag={false}` is the one escape hatch — + * any right-side controls. THE TITLE LAW (owner round 11, 2026-10-05): + * the serif title ALWAYS names a session — chrome-less creation surfaces + * (home, both /chat/new drafts) and the chain table render NO title. + * `drag={false}` is the one escape hatch — * chat's rename mode (app-region:drag would eat the mousedown that * exits the input; owner ask). * diff --git a/tests/render-chain-table.test.tsx b/tests/render-chain-table.test.tsx index c1ec76e..60ad1aa 100644 --- a/tests/render-chain-table.test.tsx +++ b/tests/render-chain-table.test.tsx @@ -125,12 +125,13 @@ describe("ChainTableBody — clusters (the outermost layer)", () => { }); describe("ChainTableBody — THE shared TopBar + the lines law (owner, round 2)", () => { - it("the body renders the standardized top bar: h-15, lh-drag, select-none, standard title size, close X", () => { + it("the body renders the standardized top bar: h-15, lh-drag, select-none, NO title (serif = session name, always), close X", () => { const html = render(); assert.ok(html.includes("lh-drag"), "the window-drag band"); - assert.ok(html.includes("select-none"), "dragging never highlights the title"); + assert.ok(html.includes("select-none"), "dragging never highlights the bar"); assert.ok(html.includes("h-15"), "the standard height"); - assert.ok(html.includes('font-title text-3xl tracking-tight">Chains<'), "the standard title size"); + assert.ok(!html.includes(">Chains<"), "NO title (owner round 11): the serif register always names a session"); + assert.ok(html.includes("chain"), "the counts remain"); assert.ok(html.includes('data-testid="chain-table-close"'), "the close X"); assert.ok(html.includes('data-testid="chain-table-search"'), "the search input"); });