> ## Documentation Index
> Fetch the complete documentation index at: https://docs.reducto.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Types: layout and fonts: Other

## `Area`

A rectangle of one sheet, zero-based and inclusive.

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `c0` | `number` | |
| `c1` | `number` | |
| `r0` | `number` | |
| `r1` | `number` | |

## `Box`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `c0` | `number` | |
| `c1` | `number` | |
| `r0` | `number` | |
| `r1` | `number` | |

## `CellAt`

What formulas read. Implementations pull dirty formulas on demand.

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `col` | `number` | |
| `row` | `number` | |
| `sheet` | `number` | |

## `CellMarker`

A cell corner plus an offset into that cell; zero-based, offsets in EMU.

Import from `@reductoai/xlsx`.

| Name | Type | Description |
| - | - | - |
| `col` | `number` | |
| `colOff` | `number` | |
| `row` | `number` | |
| `rowOff` | `number` | |

## `CellPathStep`

One hop from a host cell into a table it holds; `tbl` indexes the cell's own w:tbl children.

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `col` | `number` | |
| `row` | `number` | |
| `tbl` | `number` | |

## `CellSource`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `date1904?` | `boolean` | Serial 0 is 1904-01-01 (`workbookPr date1904`), not the 1900 system's 1900-01-00. |
| `cellInfo()?` | `(type: string, at: CellAt \| null) => Value \| undefined` | CELL's formatting types for a cell, INFO's workbook answers with `at` null; undefined when unknown. |
| `column()?` | `(sheet: number, col: number, r0: number, r1: number) => readonly Scalar[] \| null` | One column's values indexed by row (blank past the end), after pulling rows r0..r1; null when the source keeps none. |
| `custom()?` | `(name: string) => FunctionImpl \| undefined` | A function the workbook's host registered; it comes before a defined name of that name. |
| `extent()` | `(sheet: number) => { cols: number; rows: number }` | Rows and columns in use; nothing outside holds a value. |
| `formulaAst()?` | `(sheet: number, row: number, col: number) => Expr \| null` | The cell's formula, for criteria a database function evaluates once per record. |
| `formulaText()?` | `(sheet: number, row: number, col: number) => string \| null` | Formula text with `=` for FORMULATEXT, or null for a constant. |
| `image()?` | `(address: string) => Uint8Array<ArrayBufferLike> \| XlError` | `IMAGE`'s picture at an https address: #BUSY! while it loads, #CONNECT! when it cannot. |
| `name()` | `(name: string, sheet: number) => Expr \| null` | A defined name's formula, or null when none is in scope. |
| `pivotData()?` | `(at: CellAt, data: string, pairs: [string, Scalar][]) => Value` | GETPIVOTDATA's lookup in the pivot table at `at`. |
| `read()` | `(sheet: number, row: number, col: number) => Scalar` | |
| `rowFiltered()?` | `(sheet: number, row: number) => boolean` | Whether a row is hidden by a filter, for SUBTOTAL 1-11. |
| `rowHidden()?` | `(sheet: number, row: number) => boolean` | Whether a row is hidden, for SUBTOTAL 101-111. |
| `scan()` | `(sheet: number, r0: number, c0: number, r1: number, c1: number, visit: (row: number, col: number, v: Scalar) => void) => void` | Present cells inside the rectangle, row-major; absent cells are blank. |
| `sheetCount()?` | `() => number` | Worksheets in the workbook, for SHEETS. |
| `sheetIndex()?` | `(name: string) => number` | Worksheet index by name for INDIRECT; -1 when there is none. |
| `spill()?` | `(sheet: number, row: number, col: number) => RangeValue \| null` | The range a formula at the cell spills into, or null when it is not a spilling anchor. |

## `CellVisitor`

One sheet's cells. Rows and columns are zero-based. A cell is present when it was
written, even with no value (a styled blank). `value` holds the number, the boolean
as 0/1, or a string-pool id, as `kind` says. `formula` is 0 for none.

Import from `@reductoai/xlsx`.

```ts theme={null}
type CellVisitor = (row: number, col: number, kind: number, value: number, style: number, formula: number) => void
```

## `ColPatch`

Not exported by name. You get it from the API.

```ts theme={null}
type ColPatch = Partial<Pick<ColSpan, "width" | "customWidth" | "style" | "hidden" | "outlineLevel" | "collapsed" | "bestFit">>
```

## `ColSpan`

One `<col>` span; columns are zero-based and inclusive, widths in characters as `width` stores them.

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `bestFit` | `boolean` | |
| `collapsed` | `boolean` | |
| `customWidth` | `boolean` | |
| `extra` | `string` | |
| `hidden` | `boolean` | |
| `max` | `number` | |
| `min` | `number` | |
| `outlineLevel` | `number` | |
| `raw?` | `string` | |
| `style?` | `number` | |
| `width?` | `number` | |

## `Common`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `anchor` | `DrawingAnchor` | |
| `el` | `XElement` | `xdr:sp`, `xdr:pic`, `xdr:graphicFrame`, `xdr:cxnSp` or `xdr:grpSp`. |
| `hidden?` | `true` | |
| `id` | `number` | |
| `link?` | `DrawingLink` | |
| `name` | `string` | |
| `part` | `string` | The drawing part that owns the object; relationship ids resolve against it. |

## `CustomOperator`

Not exported by name. You get it from the API.

```ts theme={null}
type CustomOperator = "equal" | "notEqual" | "lessThan" | "lessThanOrEqual" | "greaterThan" | "greaterThanOrEqual"
```

## `DocProperties`

Package metadata (docProps/core.xml, docProps/app.xml). Text values are
verbatim; dates stay in the W3CDTF form Word wrote. Only present keys are
emitted, so an empty `<dc:title/>` reads as absent.

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `application?` | `string` | |
| `appVersion?` | `string` | |
| `author?` | `string` | |
| `category?` | `string` | |
| `characters?` | `number` | |
| `company?` | `string` | |
| `created?` | `string` | |
| `description?` | `string` | |
| `keywords?` | `string` | |
| `lastModifiedBy?` | `string` | |
| `lastPrinted?` | `string` | |
| `manager?` | `string` | |
| `modified?` | `string` | |
| `pages?` | `number` | Counts as Word last saved them; app.xml, not a layout result. |
| `revision?` | `string` | |
| `subject?` | `string` | |
| `template?` | `string` | |
| `title?` | `string` | |
| `words?` | `number` | |

## `DynamicMetadata`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `cm()` | `() => number` | |
| `has()` | `(cm: number) => boolean` | |
| `picture()` | `(vm: number) => PictureValue \| undefined` | The picture a cell's `vm` points at. |
| `pictureVm()` | `(p: PictureValue, computed: boolean) => number` | The `vm` for a picture in a cell; `computed` marks a formula's result. |
| `vm()` | `(e: RichError) => number` | |

## `EastAsianScript`

Not exported by name. You get it from the API.

```ts theme={null}
type EastAsianScript = "ja" | "zh-hans" | "zh-hant" | "ko"
```

## `FetchProgress`

Not exported by name. You get it from the API.

```ts theme={null}
type FetchProgress = (done: number, total: number, bytes: number) => void
```

## `FieldLayout`

Field Settings > Layout & Print, and the field's caption (`name`, null for the source name).

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `blankRow` | `boolean` | |
| `caption` | `string \| null` | |
| `compact` | `boolean` | |
| `fillDown` | `boolean` | |
| `outline` | `boolean` | |
| `subtotalTop` | `boolean` | |

## `LayoutAnchor`

A floating (wp:anchor) drawing, absolutely positioned on the page.

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `bbox` | `LayoutBBox` | |
| `behind?` | `boolean` | Drawn under all other content (wp:anchor @behindDoc). |
| `cellClip?` | `true` | Cut at the sides of the cell its origin sits in: a wrapping picture wider than its cell. |
| `image` | `LayoutImageRef` | |
| `inCell?` | `true` | Cell-owned `layoutInCell` float: cell borders paint over it. |
| `origin?` | `{ x: number; y: number }` | Page-local point a zero `wp:posOffset` on the anchor's own `relativeFrom` lands the frame at, after cell and column remapping. Provenance for editors that rewrite the offset; painters ignore it. |
| `shapeId?` | `number` | `wp:docPr/@id` of the floating drawing this was laid from. Provenance for editors that must find where an authored shape actually landed; painters ignore it. |
| `story?` | `"header" \| "footer"` | |
| `watermark?` | `true` | Authored as a watermark (Word's `WordPictureWatermark*` / a "watermark" docPr name). Metadata only. |
| `z?` | `number` | Floating paint-layer key (`wp:anchor@relativeHeight`); see `LayoutLine.z`. |

## `LayoutBBox`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `h` | `number` | |
| `w` | `number` | |
| `x` | `number` | |
| `y` | `number` | |

## `LayoutColumnBand`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `bottom` | `number` | Deepest content y the band filled; only meaningful on the last band. |
| `columns` | `{ w: number; x: number }[]` | |
| `top` | `number` | |

## `LayoutDocument`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `blocks` | `({ bidi?: true; bodyIndex: number; headingLevel?: number; kind: "paragraph"; numPr?: { ilvl: number; numId: number }; page: number; preview: string; styleId?: string; title?: true; toc?: true } \| { bodyIndex: number; cols: number; kind: "table"; page: number; rows: number; tableIndex: number })[]` | |
| `bookmarks?` | `{ bodyIndex: number; name: string; textOffset: number }[]` | `w:bookmarkStart` targets in source coordinates (see `model.ts` Bookmark). A consumer resolves one to a page by finding the first run whose `source` has the same `bodyIndex` and covers `textOffset`. |
| `docDefaultFont?` | `string` | docDefaults typeface; the fallback for an unresolvable name (fonts.ts). |
| `drawingGrid?` | `LayoutDrawingGrid` | Absent = Word's default, a 9pt square grid from the margins. |
| `embeddedFonts?` | `EmbeddedFontMap` | Faces extracted from word/fonts, keyed by family (see fonts.ts). |
| `emittedAt` | `string` | |
| `faceManifest?` | `Record<string, { cssFamily: string; file: string; local?: string[]; metrics: { baselineFactor: number; strikePos: number; strikeThickness: number; underlinePos: number; underlineThickness: number; unitsPerEm: number }; synthBold?: true }>` | Resolved physical face per `(requested family, bold, italic)` actually used by runs in this document, keyed `"<requested lowercased>\|<faceKey>"`. Emitted by the demo adapter only. It lets a renderer that cannot run `resolveFace`, read the filesystem, or inspect font tables (the browser) load the exact face the measurer used and reuse its metrics, so both its shaping and its baselines match the PDF backend's. |
| `fontDecls?` | `FontDeclMap` | word/fontTable.xml declarations that drive fallback (see fonts.ts). |
| `fontFallbacks?` | `FontFallback[]` | Families this document asked for that the host could not serve as themselves (see `FontRegistry.fontFallbacks`). Absent when every name resolved exactly. A `script` or `missing` entry means the metrics used are not the document's own, so the pagination is host-dependent. |
| `fonts` | `string[]` | Fonts observed (for |
| `images?` | `Record<string, { data?: Uint8Array; dataB64: string \| null; mime: "png" \| "jpeg" \| "gif" \| "tiff" \| "svg" \| "other"; srcRect?: SrcRect; whole?: true }>` | Image payloads keyed by `LayoutImageRef.id`, base64-encoded so the IR round-trips through JSON. Absent when the document has no inline images. |
| `meta` | `{ engine: "typescript-ooxml" \| "libreoffice-viewcursor"; notes: string[] }` | |
| `pageCount` | `number` | |
| `pages` | `LayoutPage[]` | |
| `properties?` | `DocProperties` | docProps/core.xml + app.xml facts. Absent when the package has neither part. |
| `sourcePath` | `string` | |
| `unit` | `LayoutUnit` | |
| `version` | `1` | |
| `wordPlatform?` | `"mac"` | Laid out to match Word for Mac where it differs from Word for Windows (`WordPlatform`); absent = Windows. |

## `LayoutLine`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `baseHmm?` | `number` | Baseline fixed below the line top by an `exact` line rule when the line carries an inline drawing. Word keeps the box at the rule value, puts the baseline at 4/5 of it and clips the drawing to the band, so a picture taller than the line shows only its bottom. Runs align to this instead of the tallest ink. |
| `behind?` | `boolean` | With `z`: under the body flow (`behindDoc`) vs over it (default). |
| `changeBar?` | `true` | Word inline-review change bar is painted beside this line. |
| `clip?` | `LayoutBBox` | Ink outside this box is cut, as Word cuts a text box's lines between its top and bottom insets. In the line's own UNROTATED frame, so it turns with `rot`; painters push it after the rotation. |
| `editMark?` | `TextStyle` | On an edited story's empty paragraph: the style its mark resolves to, which text typed there takes. Painters never read it; an editor reads it for the caret's format. |
| `editMarker?` | `LayoutRun` | The bullet of an empty paragraph, which PowerPoint shows only while its text is edited. Painters never read it; an editor paints it for the story it edits. |
| `h` | `number` | Vertical advance consumed by this line (includes proportional leading). |
| `highlightBand?` | `{ h: number; top: number }` | Band a highlight fills, from `y`, when the line rule moves it off the runs' own box. |
| `inFrame?` | `true` | With `textbox`: laid in a `w:framePr` frame, so its text belongs to the story around it. |
| `lineEnd?` | `"break" \| "paragraph"` | Why the paragraph's text stops here: an authored `w:br`/`w:cr`, or the paragraph mark. Absent on a soft wrap and on lines that are not paragraph text. Metadata only; painters never read it. |
| `lineNumber?` | `true` | Section line numbering (`w:lnNumType`) in the margin; carets and text readers skip it. |
| `page` | `number` | |
| `rot?` | `{ cx: number; cy: number; deg: number }` | Rotated line (vertical textbox text, `wps:bodyPr` vert/vert270). The line and its runs are stored UNROTATED, in page coords; painters rotate all of the line's ink by `deg` degrees COUNTER-CLOCKWISE on screen (IR is y-down) about the pivot (`cx`,`cy`), also in hmm page coords. |
| `runs` | `LayoutRun[]` | |
| `shapeId?` | `number` | `wp:docPr/@id` of the floating textbox this line was laid inside. Unlike `textbox` it survives a round trip to the authored shape, so an editor can ask where a box's own text ended up. Metadata only. |
| `source?` | `SourceAnchor` | Empty-paragraph lines only: the source paragraph the line was laid for. Lines with runs carry provenance on each run instead. Lets geometry queries resolve a blank paragraph to its laid line box. Metadata only. |
| `story?` | `"header" \| "footer"` | Header/footer mini-flow. Untagged lines are body. Page sketches use this instead of a Y-band heuristic, so body text near the bottom margin keeps its `p:N` address. |
| `storyRel?` | `string` | The story this line was laid from: a header/footer part's relationship id, a note key (`footnote#<id>`) or a textbox key (`textbox#<b>:<n>`). Each story numbers its paragraphs independently, so `source.bodyIndex` alone is ambiguous across them. Metadata only — painters never read it. |
| `textbox?` | `number` | The line was laid inside a floating textbox's inner mini-flow. The value names the box instance (unique per document), so two boxes anchored to the same paragraph stay apart. Metadata only — painters never read it. |
| `textH?` | `number` | |
| `w` | `number` | |
| `watermark?` | `true` | Header VML textpath: above document backgrounds, below all body ink. |
| `wrap?` | `LineWrap` | The band the line breaker filled, as offsets from `x`: `left`/`right` bound this line, `next` is where the paragraph's later lines start. Only on left-to-right lines with no tab and no float beside them, so an editor can tell when a quick refill of the paragraph is safe. Metadata only; painters never read it. |
| `x` | `number` | |
| `y` | `number` | |
| `z?` | `number` | Paint-layer key for content owned by a floating anchor (`wp:anchor@relativeHeight`). Present only for such content: the line leaves the body paint pass and joins the floating layer, interleaved with drawings by `z`. `behind` selects under-body vs over-body (behindDoc). |

## `LayoutRect`

A decoration rectangle (paragraph w:shd fill / w:pBdr borders), drawn under
all text and table content. bbox in hmm from the page's top-left.

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `bbox` | `LayoutBBox` | |
| `behind?` | `boolean` | With `z`: under the body flow (`behindDoc`) vs over it (default). |
| `borders?` | `{ bottom?: LayoutBorderSide; left?: LayoutBorderSide; right?: LayoutBorderSide; top?: LayoutBorderSide }` | Drawable border sides only (zero-width sides were dropped upstream). |
| `fill?` | `string` | Background fill (CSS hex). |
| `frame?` | `true` | The authored frame of a floating text box at its resolved position, kept so an editor can select, drag and resize a box that paints no fill or border. Such a rect has neither `fill` nor `borders` and paints nothing. |
| `origin?` | `{ x: number; y: number }` | Frames only: see `LayoutAnchor.origin`. |
| `paragraphFrame?` | `{ from: number; outset?: { b: number; l: number; r: number; t: number }; storyRel?: string; to: number }` | A `w:framePr` frame's paragraphs, body indices `from` to `to` (exclusive) in story `storyRel` (absent: body). |
| `rotDeg?` | `number` | Frames only: the box's `a:xfrm@rot` in degrees; the bbox stays upright and the ink spins. |
| `shapeId?` | `number` | `wp:docPr/@id` when this rect is a floating shape's chrome; provenance only. |
| `story?` | `"header" \| "footer"` | Header/footer mini-flow; untagged rects are body. See `LayoutLine.story`. |
| `storyRel?` | `string` | The textbox story whose frame this rect paints; an editor claims the box from it. |
| `z?` | `number` | Floating paint-layer key; see `LayoutLine.z`. |

## `LayoutReviewLayer`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `anchorChrome` | `LayoutShapeGeom[]` | Range highlight and end brackets for every anchored comment, in final page coords. Painted under all balloons: a thread shares one decoration, so it cannot hang off an individual balloon. |
| `balloons` | `LayoutCommentBalloon[]` | |
| `contentTransform` | `LayoutReviewTransform` | |
| `gutter` | `LayoutBBox` | |

## `LayoutReviewTransform`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `dx` | `number` | |
| `dy` | `number` | |
| `scale` | `number` | |

## `LayoutRun`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `anchorOf?` | `number` | Zero-width slot that owns the anchor character of a floating drawing; the value is the `LayoutAnchor.shapeId` it was laid from. Painters skip it. |
| `field?` | `LiveField` | The run paints the live result of this field, not typed text. Fields whose saved result is painted as-is (SECTIONPAGES, PAGEREF, DATE) carry no mark. Metadata only. |
| `h` | `number` | Approximate line box height from font size (+ leading fudge). |
| `image?` | `LayoutImageRef` | Present only on image runs (`text` is empty). Consumers that only know about glyphs draw nothing, which is the pre-image behaviour. |
| `link?` | `{ anchor?: string; href?: string; tooltip?: string }` | The run sits inside a `w:hyperlink` (or a HYPERLINK field). Painters that only draw glyphs ignore it; interactive consumers turn it into a link. `anchor` names a bookmark listed in `LayoutDocument.bookmarks`. |
| `logicalOrder?` | `number` | Line-local source-order position paired with `logicalText`. |
| `logicalText?` | `string` | Source-order text when `text` was reordered for visual RTL painting. Text/API consumers use this; painters deliberately ignore it. |
| `marker?` | `true` | The run paints the GENERATED numbering label (marker glyphs, or the tab that separates it from the body), not the paragraph's own text. A text consumer that emits its own list markers must drop these, or the marker appears twice. |
| `math?` | `{ display?: true; latex?: string }` | Office Math provenance. Present on every run an `m:oMath` object emits (glyph pieces and the zero-width rule anchor). The generated LaTeX rides once, on the object's first run; follower runs carry an empty object so a text consumer can fold the whole equation back into one token. `display` marks `m:oMathPara`. |
| `reviewCommentId?` | `string` | Synthetic review-balloon provenance; never set on document-flow runs. |
| `shapes?` | `LayoutShapeGeom[]` | Vector ink anchored to this run's BASELINE origin: `(x, baseline)`, with +y down, unlike `image.shapes`, which hang off the run's top-left box. An equation's fraction bars and radicals ride here, because only the baseline is a fixed point once the line's height is known. |
| `shapingDirection?` | `"ltr" \| "rtl"` | Resolved direction used to shape this visual run. |
| `source` | `SourceAnchor` | |
| `style` | `TextStyle` | |
| `symbolByte?` | `number` | Raw byte for legacy symbol-font runs; canvas hosts choose their cmap encoding. |
| `text` | `string` | |
| `w` | `number` | Advance width of the run (endX - startX). |
| `x` | `number` | |
| `y` | `number` | |

## `LayoutTable`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `anchors?` | `LayoutAnchor[]` | Floating pictures anchored to cell paragraphs. Transient: the engine drains these onto the owning page's `anchors` when the chunk is flushed. |
| `bbox` | `LayoutBBox` | |
| `behind?` | `boolean` | The owning floating textbox sits behind the document body. |
| `bodyIndex` | `number` | |
| `cells` | `LayoutTableCell[]` | |
| `cols` | `number` | |
| `headerRows?` | `number` | Leading rows flagged `w:tblHeader` (repeated on continuation pages). Metadata only. |
| `name` | `string` | |
| `page` | `number` | |
| `rows` | `number` | |
| `story?` | `"header" \| "footer"` | |
| `tableIndex` | `number` | |
| `tbLines?` | `LayoutLine[]` | Ink of floating textboxes anchored to cell paragraphs (inner lines and chrome rects). Transient in the same way as `anchors`: drained onto the page when the chunk is flushed, so no consumer ever sees them here. |
| `tbRects?` | `LayoutRect[]` | |
| `textbox?` | `number` | Laid inside a floating textbox; see `LayoutLine.textbox`. |
| `z?` | `number` | Floating textbox paint order (`wp:anchor@relativeHeight` / VML z-index). |

## `LayoutTableCell`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `bbox` | `LayoutBBox` | |
| `borders?` | `{ bottom?: LayoutBorderSide; left?: LayoutBorderSide; right?: LayoutBorderSide; top?: LayoutBorderSide }` | Effective borders after tcPr-over-tblPr resolution; zero-width sides are omitted. |
| `clipContent?` | `boolean` | |
| `col` | `number` | |
| `colSpan?` | `number` | `w:gridSpan` > 1: grid columns this cell covers. Metadata only. |
| `diagonals?` | `{ down?: LayoutBorderSide; up?: LayoutBorderSide }` | Rules from corner to corner: `down` top-left to bottom-right (w:tl2br), `up` bottom-left to top-right. |
| `lines` | `LayoutLine[]` | |
| `name` | `string` | |
| `page` | `number` | |
| `rects?` | `LayoutRect[]` | Paragraph shading / border boxes of the cell's paragraphs, drawn over the fill and under the lines. |
| `row` | `number` | |
| `rowSpan?` | `number` | `w:vMerge` restart spanning > 1 rows; continue cells are not emitted. Metadata only. |
| `shading?` | `string` | Background fill (CSS hex). Absent = transparent. |
| `source` | `Extract<SourceAnchor, { kind: "table-cell" }>` | |
| `text` | `string` | Plain text (concatenated). |

## `LayoutUnit`

Not exported by name. You get it from the API.

```ts theme={null}
type LayoutUnit = "hmm"
```

## `LigaturePolicy`

The ligature groups a run is shaped with, plus `w14:cntxtAlts` as `+calt`.
Absent means the font's own defaults (fontkit turns liga/clig/calt on).

Not exported by name. You get it from the API.

```ts theme={null}
type LigaturePolicy = LigatureValue | `${LigatureValue}+calt`
```

## `LigatureValue`

Not exported by name. You get it from the API.

```ts theme={null}
type LigatureValue = typeof LIGATURE_VALUES[number]
```

## `LineEndSize`

`a:headEnd`/`a:tailEnd` `@len` and `@w`; absent is `med`.

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `len?` | `"sm" \| "med" \| "lg"` | |
| `w?` | `"sm" \| "med" \| "lg"` | |

## `LineEndType`

`a:headEnd`/`a:tailEnd` `@type`, less `none` (which is simply absent).

Not exported by name. You get it from the API.

```ts theme={null}
type LineEndType = "triangle" | "stealth" | "diamond" | "oval" | "arrow"
```

## `LineWrap`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `align` | `"left" \| "center" \| "right" \| "both" \| "distribute" \| "thaiDistribute"` | |
| `gap?` | `number` | Space Word puts between this paragraph and a copy of itself, as Enter makes one. |
| `left` | `number` | |
| `mark?` | `{ h: number; textH: number }` | Line box of an empty copy of this paragraph, sized by its mark. |
| `next` | `number` | |
| `right` | `number` | |

## `Period`

Not exported by name. You get it from the API.

```ts theme={null}
type Period = "seconds" | "minutes" | "hours" | "days" | "months" | "quarters" | "years"
```

## `Relationship`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `external` | `boolean` | |
| `id` | `string` | |
| `target` | `string` | |
| `type` | `string` | |

## `RichError`

What Excel keeps beside a #SPILL! (8), #CONNECT! (9), #BLOCKED! (10) or #CALC! (13): the `_error` rich value's fields.

Not exported by name. You get it from the API.

```ts theme={null}
type RichError = { propagated: true; type: RichErrorType } | { col: number; row: number; sub: number; type: 8 } | { sub: number; type: 9 | 10 | 13 }
```

## `RichErrorType`

Not exported by name. You get it from the API.

```ts theme={null}
type RichErrorType = 8 | 9 | 10 | 13
```

## `RowPatch`

Not exported by name. You get it from the API.

```ts theme={null}
type RowPatch = Partial<Pick<RowProps, "height" | "customHeight" | "style" | "customFormat" | "hidden" | "outlineLevel" | "collapsed">>
```

## `RowProps`

One `<row>`; zero-based, heights in points as `ht` stores them.

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `collapsed` | `boolean` | |
| `customFormat` | `boolean` | |
| `customHeight` | `boolean` | |
| `extra` | `string` | Attributes the model does not read, kept as written. |
| `height?` | `number` | |
| `hidden` | `boolean` | |
| `outlineLevel` | `number` | |
| `raw?` | `string` | Source attributes; a model edit drops them so the row is written from its fields. |
| `style?` | `number` | Applies to empty cells only when `customFormat` is set. |

## `SessionHost`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `arrays()` | `(part: string) => { col: number; cols: number; row: number; rows: number }[]` | The areas of a sheet's legacy arrays wider than one cell. |
| `begin()` | `() => void` | Computes local edits before a remote change lands: a spill's stored area is current only then. |
| `computed()` | `(part: string, row: number, col: number) => boolean` | Whether an array or spill writes the cell, so it holds a result rather than an input. |
| `files()` | `() => Record<string, Uint8Array>` | Package parts as stored: sheet cells and pending style edits are not written into them. |
| `loadCells()` | `(part: string, cells: readonly (readonly [number, number, string])[]) => void` | Replaces cells with `<c>` elements (`s` an xf index; `<c/>` clears). |
| `model()` | `(part: string) => SheetModel \| undefined` | The loaded cells of a sheet part. |
| `moveCells()` | `(part: string, shift: LineShift) => void` | Moves a sheet's cells past a shift; row and column properties come with its shell. |
| `partText()` | `(part: string) => string` | |
| `prepare()` | `() => void` | Builds the calc layer, all of it dirty when new, so it hears the loads that follow. |
| `settle()` | `() => void` | Recalculates what the writes made stale: all of it when they rebuilt the calc layer. |
| `sheetParts()` | `() => string[]` | |
| `shell()` | `(part: string) => string` | The sheet part with `sheetData` holding row properties only. |
| `stylesDirty()` | `() => boolean` | Style edits not yet written to the styles part; reading the part writes them. |
| `stylesPart()` | `() => string` | |
| `write()` | `(writes: ReadonlyMap<string, string \| Uint8Array<ArrayBufferLike> \| null>) => void` | Writes parts; a sheet part's text is a shell, so the cells it has stay. |

## `SheetMeta`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `cellExtras` | `Map<number, string>` | |
| `cols` | `ColSpan[]` | |
| `dirty` | `Set<"cols" \| "mergeCells" \| "sheetData">` | Worksheet children the model rewrites on save. |
| `extent?` | `{ col: number; row: number }` | Last row and column any `<c>` names, valueless ones included; Excel's used range counts them. |
| `formulas` | `SheetFormula[]` | |
| `merges` | `Rect[]` | |
| `rows` | `Map<number, RowProps>` | |

## `SheetModel`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `changed` | `boolean` | |
| `meta` | `SheetMeta` | |
| `name` | `string` | |
| `store` | `SheetStore` | |

## `SheetStore`

Import from `@reductoai/xlsx`.

| Name | Type | Description |
| - | - | - |
| `onChange` | `((row: number, col: number) => void) \| null` | Called after each `set` or `delete`. |
| `size` | `number` | |
| `bytes()` | `() => number` | Typed-array bytes the store holds; JS object overhead is not counted. |
| `columnVersion()` | `(col: number) => number` | Moves on every `set` or `delete` in the column. |
| `delete()` | `(row: number, col: number) => void` | |
| `forEachInColumn()` | `(col: number, r0: number, r1: number, visit: CellVisitor) => void` | Present cells of one column between two rows, top to bottom. |
| `forEachInRect()` | `(r0: number, c0: number, r1: number, c1: number, visit: CellVisitor) => void` | Present cells inside the rectangle, row-major. |
| `formula()` | `(row: number, col: number) => number` | |
| `kind()` | `(row: number, col: number) => number` | `-1` when the cell is absent. |
| `maxCol()` | `() => number` | |
| `maxRow()` | `() => number` | Highest row and column ever written, or -1 when empty. |
| `set()` | `(row: number, col: number, kind: number, value: number, style: number, formula: number) => void` | |
| `style()` | `(row: number, col: number) => number` | |
| `value()` | `(row: number, col: number) => number` | |

## `SheetVisibility`

Not exported by name. You get it from the API.

```ts theme={null}
type SheetVisibility = "Visible" | "Hidden" | "VeryHidden"
```

## `SourceAnchor`

Not exported by name. You get it from the API.

```ts theme={null}
type SourceAnchor = { bodyIndex: number; kind: "paragraph"; textLength: number; textOffset: number } | { bodyIndex: number; cellName: string; col: number; kind: "table-cell"; path?: CellPathStep[]; row: number; tableIndex: number; tableName: string; textLength: number; textOffset: number }
```

## `StructureEdit`

Insert or delete rows or columns (`shift`), or cut cells and paste them elsewhere (`move`).

Not exported by name. You get it from the API.

```ts theme={null}
type StructureEdit = { at: number; axis: "rows" | "cols"; count: number; hi?: number; kind: "shift"; lo?: number; sheet: number } | { from: Area; kind: "move"; sheet: number; to: Area; toSheet: number }
```

## `WorkbookSnapshot`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `files` | `Readonly<Record<string, Uint8Array>>` | |

## `WorksheetHost`

Not exported by name. You get it from the API.

| Name | Type | Description |
| - | - | - |
| `date1904?` | `boolean` | Serials count days from 1904-01-01. |
| `strings` | `StringPool` | |
| `calc()` | `() => WorkbookCalc` | The calc layer, created on first edit: every sheet loads and every formula registers. |
| `cellEdited()?` | `(index: number, row: number, col: number) => void` | A cell's content changed; a table header renames its column. |
| `markChanged()` | `(index: number) => void` | Marks the sheet for rewrite on save after a style-only edit. |
| `noteStructure()` | `(index: number) => void` | Rows, columns or merges of the sheet changed. |
| `peekCalc()` | `() => WorkbookCalc \| undefined` | The calc layer if it exists; reads do not create it. |
| `pictureOf()?` | `(vm: number) => PictureValue \| undefined` | The picture a cell's value metadata (`vm`) points at. |
| `readCalc()` | `() => WorkbookCalc \| undefined` | The calc layer a value read needs: as `peekCalc`, but a file saved with `fullCalcOnLoad` creates it. |
| `sheetIndexOf()` | `(name: string) => number` | |
| `sheetNameOf()` | `(index: number) => string` | |
| `tableLookup()?` | `(sheet: number \| null) => TableLookup` | |
