{}OPF
DocsObject referenceView source

Table

Table content. Columns are optional; rows are the only required field.

Metadata

Definition
#/$defs/Table
Type
object
Source
spec/schemas/opf.schema.json

Field index

FieldTypeReq.Description
columnsarray<string | array<ref:TextRun> | ref:StyledTableCell | null>Optional column labels. Labels may be strings, rich runs or styled cell objects. Null is an empty label or a placeholder covered by a preceding column span.
rowsarray<array<ref:TableCell>>yesTwo-dimensional table row data; each row aligns by index with columns when columns are supplied.

columns

typearray<string | array<ref:TextRun> | ref:StyledTableCell | null>requirednodefault

Optional column labels. Labels may be strings, rich runs or styled cell objects. Null is an empty label or a placeholder covered by a preceding column span.

columns.json
{
  "columns": [
    "Region",
    "Q3 Revenue",
    "Q4 Revenue",
    "YoY %"
  ]
}

rows

typearray<array<ref:TableCell>>requiredyesdefault

Two-dimensional table row data; each row aligns by index with columns when columns are supplied.

rows.json
{
  "rows": [
    [
      "North America",
      12.4,
      18.1,
      "46%"
    ],
    [
      "EMEA",
      8.2,
      11.5,
      "40%"
    ]
  ]
}