/** * Configuration for the docs-toc component. */ export interface DocsTocMetadata { /** * Manual TOC items (used when autoGenerate is false). */ items?: DocsTocItem[]; /** * Automatically generate TOC from headings in the content. * @default false */ autoGenerate?: boolean; /** * CSS selector for the content container to scan for headings. * Required when autoGenerate is true. * @default '.docs-layout__content' */ containerSelector?: string; /** * Heading levels to include in auto-generated TOC. * @default [2, 3] */ headingLevels?: number[]; /** * Title displayed above the TOC. * @default 'Contents' */ title?: string; /** * Offset from top for scroll spy calculations (e.g., for sticky headers). * @default 100 */ offsetTop?: number; /** * Custom CSS class. */ cssClass?: string; /** * Hide the title. * @default false */ hideTitle?: boolean; } export interface DocsTocItem { /** * ID of the DOM element (without #). */ id: string; /** * Label to display in the TOC. */ label: string; /** * Heading level for indentation (1, 2, 3). */ level: number; /** * Nested children items. */ children?: DocsTocItem[]; }