import { z } from 'zod'; /** * One block of a document body, in document order: a paragraph, section * break, table, or table of contents, addressed by its UTF-16 index range. * A projection of the REST StructuralElement: paragraphs flatten to their * concatenated run text, tables to their dimensions plus their cell tree * (each cell's content recursing into this same shape, so nested tables * project too); styles, inline objects, and suggestions are deferred * (issue #36). The recursion needs explicit types: zod cannot infer a cycle, * so the three shapes are declared by hand and pinned to their schemas. * * @see https://developers.google.com/workspace/docs/api/reference/rest/v1/documents#StructuralElement */ export type StructuralElement = { startIndex?: number | undefined; endIndex?: number | undefined; type?: 'paragraph' | 'sectionBreak' | 'table' | 'tableOfContents' | undefined; text?: string | undefined; rows?: number | undefined; columns?: number | undefined; tableRows?: TableRowElement[] | undefined; }; /** * One row of a projected table: its index range and its cells. A projection * of the REST TableRow (row styling and suggestions are deferred; issue #36). * * @see https://developers.google.com/workspace/docs/api/reference/rest/v1/documents#TableRow */ export type TableRowElement = { startIndex?: number | undefined; endIndex?: number | undefined; cells: TableCellElement[]; }; /** * One cell of a projected table: its index range and its content as * structural elements, the same shape as the document body, so the text * inside a cell is targetable exactly like body text. A projection of the * REST TableCell (cell styling and suggestions are deferred; issue #36). * * @see https://developers.google.com/workspace/docs/api/reference/rest/v1/documents#TableCell */ export type TableCellElement = { startIndex?: number | undefined; endIndex?: number | undefined; content: StructuralElement[]; }; export declare const TableCellElement: z.ZodType; export declare const TableRowElement: z.ZodType; export declare const StructuralElement: z.ZodType; //# sourceMappingURL=StructuralElement.d.ts.map