/** PlantUML extension for named, declarative element interactions. */ export type RoleStyle = import("../draw/theme.mjs").RoleStyle; export type Diagnostics = import("../core/diagnostics.mjs").Diagnostics; export type SourceLine = import("../core/source.mjs").SourceLine; export type Hook = { /** * Internal identity shared across scene primitives. */ name: string; /** * Author-defined ID. */ id?: string; classes: string[]; selector: "alias" | "element"; target: string; /** * Forward descendant clicks to this binding. */ clickFromChildren?: true; /** * Activation behavior. Defaults to toggle. */ clickMode?: "toggle" | "button"; /** * Explicit author-defined parent ID. */ parentId?: string; line: number; hover: RoleStyle; click: RoleStyle; }; export type Tooltip = Pick & { text: string; }; /** @typedef {import("../draw/theme.mjs").RoleStyle} RoleStyle */ /** @typedef {import("../core/diagnostics.mjs").Diagnostics} Diagnostics */ /** @typedef {import("../core/source.mjs").SourceLine} SourceLine */ /** * @typedef {object} Hook * @property {string} name Internal identity shared across scene primitives. * @property {string} [id] Author-defined ID. * @property {string[]} classes * @property {"alias" | "element"} selector * @property {string} target * @property {true} [clickFromChildren] Forward descendant clicks to this binding. * @property {"toggle" | "button"} [clickMode] Activation behavior. Defaults to toggle. * @property {string} [parentId] Explicit author-defined parent ID. * @property {number} line * @property {RoleStyle} hover * @property {RoleStyle} click */ /** @typedef {Pick & { text: string }} Tooltip */ /** @param {Diagnostics} diagnostics @param {number} line @param {string} message */ export declare function reportHookError(diagnostics: Diagnostics, line: number, message: string): void; /** @param {Diagnostics} diagnostics @param {number} line @param {string} message */ export declare function reportTooltipError(diagnostics: Diagnostics, line: number, message: string): void; /** * Remove consecutive hook and tooltip directives in a page's preamble. The first body line * ends the preamble so notes, diagram labels and raw payloads retain their text. * @param {SourceLine[]} lines * @param {Diagnostics} diagnostics * @param {{ raw?: boolean, maxTextLength: number }} options * @returns {{ lines: SourceLine[], hooks: Hook[], tooltips: Tooltip[] }} */ export declare function extractInteractions(lines: SourceLine[], diagnostics: Diagnostics, options: { raw?: boolean; maxTextLength: number; }): { lines: SourceLine[]; hooks: Hook[]; tooltips: Tooltip[]; };