/** * The dashboard's pieces, drawn as lines (operator-console/AC-10, * operator-console/AC-14..AC-18, operator-console/AC-21..AC-24, operator-console/AC-54). * * Pure: data and a width in, lines out. Colour comes only through `Paint`, so with * colour off the same lines carry words and markers alone (operator-console/AC-22). * A cell that animates is written as `SPIN`; `layout.ts` finds those cells, puts the * frame's glyph in them and tells the terminal where they are, so the frame clock can * redraw them alone (operator-console/AC-25). * * @module */ import { type Paint } from '../../autopilot/ansi.js'; import { type View } from '../../autopilot/watch-view.js'; import type { FormState } from './model.js'; import { type Harness } from '../harness.js'; import type { AutopilotData, BuildingData, BuildingKind, DrawerState, HeaderData, LineState, PanelRead, RoadmapData, SpendData } from './model.js'; import type { PaletteEntry } from './palette.js'; /** A cell the frame clock animates. Never printed: `layout.ts` replaces it. */ export declare const SPIN = "\0"; /** Ten braille frames: one cell, no flicker, readable at 10 frames a second. */ export declare const SPINNER: string[]; /** What stands in for a spinner when colour is off: still, but still says "running" (operator-console/AC-26). */ export declare const STATIC_RUNNING = "\u25B6"; /** Where the text cursor goes inside a piece, as a marker `layout.ts` removes. */ export declare const CURSOR = "\u0001"; /** A panel's body: its lines, and which of them is the selected row. */ export interface PanelBody { lines: string[]; /** Index into `lines` of the selected row, to keep it in view. */ selectedLine: number | null; /** A message rather than rows: wrapped to the box, never cut. */ wrap?: boolean; } export declare const NO_PROJECT = "No AIDLC project here \u2014 press i to set one up (aidlc init)"; /** * A rounded box `height` lines tall around `body`, the title on its top edge. The * focused panel's title is bracketed and bold, so focus shows without colour. * Body lines past the box are cut, keeping the selected one in view. */ export declare function box(p: Paint, opts: { title: string; number?: number; right?: string; focused: boolean; width: number; height: number; spin?: boolean; }, body: PanelBody): string[]; export declare function headerLine(p: Paint, read: PanelRead, agent: Harness, sessionUsd: number, width: number): string; /** Who builds a row, as a symbol that reads with colour off (building-panel-all-instances/AC-5). */ export declare const SYMBOL: Readonly>; /** BUILDING's top edge: what the running symbols mean, and the layout in use (AC-5, AC-7). */ export declare function buildingLegend(view: View): string; /** * Every instance in flight (building-panel-all-instances/AC-1..AC-10): running rows drawn * by the watch view's own renderer, the merge queue, anything unreadable, then the idle * group, dimmed, one line each. */ export declare function buildingBody(p: Paint, d: { project: boolean; autopilot: PanelRead | null; building: BuildingData; }, o: { selected: number; focused: boolean; width: number; rows: number; view: View; now: number; }): PanelBody; export declare function roadmapBody(p: Paint, read: PanelRead, project: boolean, selected: number, focused: boolean, width: number): PanelBody; /** Seven bars, one a day; a day not measured is `ยท`, never an empty bar that reads as zero. */ export declare function spendBars(days: readonly (number | null)[]): string; export declare function spendBody(p: Paint, read: PanelRead, project: boolean, agent: Harness, sessionUsd: number): PanelBody; /** A line being typed, with the cursor marked for `layout.ts`. */ export declare function inputLine(prompt: string, line: LineState, width: number, focused: boolean): string; /** The chat drawer's body: the conversation scrolled back `offset` lines, then the question or the prompt. */ export declare function drawerBody(p: Paint, d: DrawerState, agent: Harness, width: number, rows: number, focused: boolean): PanelBody; export declare function overlayBody(lines: readonly string[], offset: number, width: number, rows: number): PanelBody; export declare function paletteBody(p: Paint, query: LineState, shown: readonly PaletteEntry[], cursor: number, width: number, rows: number): PanelBody; export declare function formBody(p: Paint, f: FormState, width: number): PanelBody; /** The key bar: what works where you are (operator-console/AC-14). */ export declare function keyBarLine(p: Paint, keys: readonly (readonly [string, string])[], width: number): string; export declare const PROMPT_HINT = "space: ask the agent \u00B7 or press a key"; //# sourceMappingURL=panels.d.ts.map