import { type DecorationMap } from "./graph-canvas.js"; import { type Branding } from "../branding.js"; import type { EditorHost } from "./editor-host.js"; import type { VisualQuestionDelegatePayload } from "../adapters/visual/protocol-contract.js"; import { type EditorPointer, type RightSectionId } from "./workspace-state.js"; /** * The editor. * * It takes a HOST rather than opening a session of its own (#252): the same * component runs against the session server over a websocket and against an * embedder's own store with no server at all. `sections` is what the host * wants shown - a product with no agent behind it leaves `chat` out, and the * section and the session button go with it. * * `readOnly` is one flag, threaded once (#298, ADR 0117): a viewer keeps * everything that reads - the canvas, the tree, the query fields, the facts, * the questions - and every affordance that stages or commits is absent * rather than disabled. A UI posture only: whatever this shell draws, the * host still answers for its own store. */ export declare const App: ({ host, sections, readOnly, decorations: initialDecorations, onDelegateQuestion, onReady, initialView, onFirstModel, branding, }: { readonly host: EditorHost; readonly sections?: readonly RightSectionId[]; readonly readOnly?: boolean; /** The host's branding (#546, ADR 0158). See `MountOptions.branding`. */ readonly branding?: Branding; /** * The view to open on once the model arrives (#523, ADR 0152): applied * once, through the same navigation the rail runs, and ignored when the * model lists no such view - the editor then opens where it always has. */ readonly initialView?: string; /** Called once when the first model lands (#532, ADR 0155). */ readonly onFirstModel?: () => void; /** * Where a delegated question goes when the host has no agent on the socket * (#515, ADR 0151). See `MountOptions.onDelegateQuestion`. */ readonly onDelegateQuestion?: (question: VisualQuestionDelegatePayload) => void; /** * The host's per-subject marks at mount time (#314, ADR 0119) - the * initial value only, the way React means an initial value: later * hand-overs travel through the pointer's `setDecorations`, each one * replacing the map wholesale. Client state like selection, so it rides a * prop rather than the `EditorHost` seam. */ readonly decorations?: DecorationMap; /** * How the mount layer's handle reaches this shell's reducer (#297, * ADR 0118). Called once, after the first render, with the pointer the * handle delegates to - which is what makes the handle's pre-ready * false-return window real. Selection and dialog state are client state, * so this rides a prop rather than the `EditorHost` seam: the protocol * carries documents, not gestures. */ readonly onReady?: (pointer: EditorPointer) => void; }) => import("react").JSX.Element;