UNPKG

docx

Version:

Easily generate .docx files with JS/TS with a nice declarative API. Works for Node and on the Browser.

21 lines (20 loc) 780 B
import { FileChild } from '../file-child'; import { XmlComponent } from '../xml-components'; import { ITableOfContentsOptions } from './table-of-contents-properties'; type ToCEntry = { readonly title: string; readonly level: number; readonly page?: number; readonly href?: string; }; export declare class TableOfContents extends FileChild { constructor(alias?: string, { contentChildren, cachedEntries, beginDirty, ...properties }?: ITableOfContentsOptions & { readonly contentChildren?: readonly (XmlComponent | string)[]; readonly cachedEntries?: readonly ToCEntry[]; readonly beginDirty?: boolean; }); private getTabStopsForLevel; private buildCachedContentRun; private buildCachedContentParagraphChild; } export {};