/**
* Built-in HTML overlay toolbar for diagrams: flow play/pause/replay + zoom/fit.
* Mounts on the App host container (sibling to canvas / HTML / SVG surface).
*/
import type { App } from '../App';
import type { Group } from '../shapes/Group';
import type { DiagramFlowChrome } from './flow';
export interface DiagramToolbarOptions {
/** Show play / pause / replay. Default: true when flow is enabled. */
flow?: boolean;
/** Show zoom − / % / + / Fit. Default true. */
zoom?: boolean;
/** Override mount host (defaults to App container). */
mount?: HTMLElement;
}
export interface DiagramToolbarHandle {
root: Group;
el: HTMLElement;
opts: {
flow: boolean;
zoom: boolean;
};
sync: () => void;
destroy: () => void;
}
/** Normalize `flow.chrome` into concrete flags. */
export declare function resolveDiagramChrome(chrome: DiagramFlowChrome | undefined, flowEnabled: boolean): {
enabled: boolean;
flow: boolean;
zoom: boolean;
};
/**
* Install (or replace) the built-in diagram toolbar on the App host.
*/
export declare function installDiagramToolbar(app: App, root: Group, options?: DiagramToolbarOptions): DiagramToolbarHandle;
/** Remove toolbar DOM + metadata for a diagram root. */
export declare function uninstallDiagramToolbar(root: Group): void;
/**
* Keep toolbar in sync with `diagramState.flow.chrome`.
* Called from apply / pause / resume / stop.
*/
export declare function syncDiagramToolbar(app: App, root: Group): void;