@openpresentation/opf 0.35.1 → 0.37.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/browser.js +19 -19
- package/dist/{catalog-refs-BgotJhR5.d.ts → catalog-refs-BeRgtpZS.d.ts} +4 -4
- package/dist/{catalog-schemas-BX-VEc5Q.d.ts → catalog-schemas-CwY-3cCP.d.ts} +1 -1
- package/dist/{chunk-BN36KMXG.js → chunk-3A3PNYNP.js} +77 -15
- package/dist/{chunk-EGXHUIQ5.js → chunk-44IS6ZU2.js} +114 -9
- package/dist/{chunk-ZRTVPUYJ.js → chunk-4FA4ZABY.js} +6 -6
- package/dist/{chunk-OBNSVMNO.js → chunk-56BYOGIF.js} +1 -1
- package/dist/{chunk-MS2LPR7F.js → chunk-6WN6PRCI.js} +1 -1
- package/dist/{chunk-ZHLAMHSS.js → chunk-BHRCWV6B.js} +4 -4
- package/dist/{chunk-PWE6UY3Y.js → chunk-C5ACMFKB.js} +1440 -835
- package/dist/{chunk-PF3TVOMG.js → chunk-CYGQY6HH.js} +6 -6
- package/dist/{chunk-MIHW2IGO.js → chunk-EOMENOKY.js} +26 -7
- package/dist/{chunk-TRGSEXUR.js → chunk-HS2JQ3AO.js} +118 -19
- package/dist/chunk-IW4TXMJY.js +646 -0
- package/dist/{chunk-LLY5BZGF.js → chunk-JTNCBTEH.js} +4 -4
- package/dist/{chunk-3KPTVK77.js → chunk-KANQVJGK.js} +1244 -119
- package/dist/{chunk-VDZXNNZF.js → chunk-M4IPCFDV.js} +1 -1
- package/dist/{chunk-WPUV2223.js → chunk-ORVMHVOS.js} +86 -2
- package/dist/{chunk-B7XWF5RV.js → chunk-QFT4R2IL.js} +5304 -2991
- package/dist/chunk-QQBOI5XI.js +86 -0
- package/dist/{chunk-P6KRAHVG.js → chunk-TIVBO56G.js} +4 -4
- package/dist/{chunk-ZEVLLXSY.js → chunk-VD7WLE3C.js} +2 -2
- package/dist/{chunk-PXJZS4ZF.js → chunk-XJU2X5JM.js} +5 -4
- package/dist/chunk-YESKKKVE.js +1 -0
- package/dist/{chunk-XHWJI4O7.js → chunk-YZ4WMB5C.js} +26 -21
- package/dist/{composition-BmJfljJl.d.ts → composition-DiKC371V.d.ts} +844 -143
- package/dist/composition.d.ts +3 -3
- package/dist/composition.js +1 -1
- package/dist/{conversion-BIooTbt5.d.ts → conversion-DF_HgknQ.d.ts} +8 -6
- package/dist/conversion-XIWN7FMW.js +25 -0
- package/dist/convert.d.ts +5 -5
- package/dist/convert.js +63 -23
- package/dist/data.d.ts +41 -3
- package/dist/data.js +2 -2
- package/dist/{deck-report-BYkbL7uT.d.ts → deck-report-BwgsIRAf.d.ts} +3 -3
- package/dist/deck.d.ts +6 -6
- package/dist/deck.js +11 -11
- package/dist/diff.js +4 -4
- package/dist/docs.js +57 -33
- package/dist/examples.js +5349 -2989
- package/dist/font-policy.js +1 -1
- package/dist/format.js +2 -2
- package/dist/ids.d.ts +17 -4
- package/dist/ids.js +4 -4
- package/dist/index.d.ts +140 -23
- package/dist/index.js +22 -22
- package/dist/markdown.d.ts +2 -2
- package/dist/markdown.js +8 -8
- package/dist/metric-data-B4Q8RFRR.d.ts +382 -0
- package/dist/node-engine.d.ts +6 -6
- package/dist/node-engine.js +21 -21
- package/dist/{pagination-C0FPjO29.d.ts → pagination-C9qnH_n-.d.ts} +5 -5
- package/dist/pagination.d.ts +4 -4
- package/dist/pagination.js +4 -4
- package/dist/patch.js +3 -3
- package/dist/precompiled.js +2 -2
- package/dist/{presentation-Dx-kZC8Y.d.ts → presentation-DmOhusrX.d.ts} +541 -110
- package/dist/repo-readme.js +1 -1
- package/dist/schema-engine-ajv.js +1 -1
- package/dist/schema-engine-precompiled.js +2 -2
- package/dist/schema.d.ts +2 -2
- package/dist/schema.js +3 -3
- package/dist/schemas.d.ts +46 -2
- package/dist/schemas.js +1 -1
- package/dist/shape-engine-eager.js +2 -2
- package/dist/shape-engine-lazy.js +1 -1
- package/dist/{shape-engine-module-N74FCHGY.js → shape-engine-module-YU2XGIQN.js} +2 -2
- package/dist/shape-geometry.js +1 -1
- package/dist/source.js +10 -10
- package/dist/spec/reference/engine-defaults.json +1 -1
- package/dist/spec/reference/engine-vocabularies.json +1 -0
- package/dist/spec/schemas/font-scheme.schema.json +5 -6
- package/dist/spec/schemas/layout.schema.json +5 -4
- package/dist/spec/schemas/narrative.schema.json +1 -0
- package/dist/spec/schemas/opf.schema.json +661 -98
- package/dist/types.d.ts +11 -12
- package/dist/{validation-types-DKIe1RQW.d.ts → validation-types-CV-ngACL.d.ts} +49 -6
- package/dist/validator.d.ts +5 -5
- package/dist/validator.js +3 -3
- package/dist/yaml.d.ts +2 -2
- package/dist/yaml.js +7 -7
- package/package.json +5 -5
- package/dist/chart-data-B_k-WTex.d.ts +0 -194
- package/dist/chunk-6VGLE7C5.js +0 -3983
- package/dist/chunk-SEC4IOOS.js +0 -1
- package/dist/chunk-WCPDN7AY.js +0 -642
- package/dist/conversion-SB5CGD6Q.js +0 -25
|
@@ -323,7 +323,7 @@ type TextRun = (string | {
|
|
|
323
323
|
*/
|
|
324
324
|
color?: (string | ColorTransform);
|
|
325
325
|
/**
|
|
326
|
-
* Run font size in points, the unit presenters know from PowerPoint. One point is 4/3 reference pixels at a 720-pixel short edge, so 12 points corresponds to 16 reference pixels (composition.
|
|
326
|
+
* Run font size in points, the unit presenters know from PowerPoint. One point is 4/3 reference pixels at a 720-pixel short edge, so 12 points corresponds to 16 reference pixels (composition.minFontSizePx: 16). Other fields state their own units, including inches, reference pixels, fractional geometry and chart data-axis values.
|
|
327
327
|
*/
|
|
328
328
|
fontSize?: number;
|
|
329
329
|
/**
|
|
@@ -339,7 +339,7 @@ type TextRun = (string | {
|
|
|
339
339
|
*/
|
|
340
340
|
language?: string;
|
|
341
341
|
/**
|
|
342
|
-
*
|
|
342
|
+
* Link to put on the run text: an http(s) URL, a 'mailto:' address or a 'tel:' number, or 'slide:<id>', a jump to the slide of this deck with that id (the same kind:id spelling as 'asset:' and 'var:'; the slide needs an 'id', which assignIds can add). The text must not contain whitespace. The preview draws it as a link, PDF export writes a link annotation (a go-to-page link for 'slide:'), and PPTX export writes a native hyperlink (a slide jump for 'slide:'); any other scheme is not valid. A link to an unknown slide id is a validation error (opf/slide-link-unknown).
|
|
343
343
|
*/
|
|
344
344
|
link?: string;
|
|
345
345
|
/**
|
|
@@ -366,6 +366,10 @@ type TextRun = (string | {
|
|
|
366
366
|
* via the `definition` "ListItem".
|
|
367
367
|
*/
|
|
368
368
|
type ListItem = (string | TextRun[] | {
|
|
369
|
+
/**
|
|
370
|
+
* Optional stable identifier for this list item, unique among every slide, payload, overlay, item, bullet, event and table-row id in the document (one namespace). An opaque string: readers never parse it. Use it when another system must address the list item across edits (a comment anchor, an `@id` patch token, a merge). Edit, move and reorder keep it; a copy inside the document gets a new one. A document without ids is valid and is addressed by index.
|
|
371
|
+
*/
|
|
372
|
+
id?: string;
|
|
369
373
|
/**
|
|
370
374
|
* Text for the list item. Use a string for plain text or TextRun[] for inline rich text. TextRun items may be plain strings or formatted run objects.
|
|
371
375
|
*/
|
|
@@ -402,6 +406,10 @@ type ListItem = (string | TextRun[] | {
|
|
|
402
406
|
* via the `definition` "BulletItem".
|
|
403
407
|
*/
|
|
404
408
|
type BulletItem = (string | TextRun[] | {
|
|
409
|
+
/**
|
|
410
|
+
* Optional stable identifier for this bullet, unique among every slide, payload, overlay, item, bullet, event and table-row id in the document (one namespace). An opaque string: readers never parse it. Use it when another system must address the bullet across edits (a comment anchor, an `@id` patch token, a merge). Edit, move and reorder keep it; a copy inside the document gets a new one. A document without ids is valid and is addressed by index.
|
|
411
|
+
*/
|
|
412
|
+
id?: string;
|
|
405
413
|
/**
|
|
406
414
|
* Text for the bullet. Use a string for plain text or TextRun[] for inline rich text. TextRun items may be plain strings or formatted run objects.
|
|
407
415
|
*/
|
|
@@ -422,6 +430,13 @@ type BulletItem = (string | TextRun[] | {
|
|
|
422
430
|
* via the `definition` "NumberingStyle".
|
|
423
431
|
*/
|
|
424
432
|
type NumberingStyle = ("arabic" | "roman-upper" | "roman-lower" | "alpha-upper" | "alpha-lower");
|
|
433
|
+
/**
|
|
434
|
+
* An https URL. Any other scheme (http, data, javascript, a relative path) is a schema error.
|
|
435
|
+
*
|
|
436
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
437
|
+
* via the `definition` "EmbedUrl".
|
|
438
|
+
*/
|
|
439
|
+
type EmbedUrl = string;
|
|
425
440
|
/**
|
|
426
441
|
* A cell in inline chart data.
|
|
427
442
|
*
|
|
@@ -429,6 +444,48 @@ type NumberingStyle = ("arabic" | "roman-upper" | "roman-lower" | "alpha-upper"
|
|
|
429
444
|
* via the `definition` "ChartDataCell".
|
|
430
445
|
*/
|
|
431
446
|
type ChartDataCell = (string | number | boolean | null);
|
|
447
|
+
/**
|
|
448
|
+
* Where the data came from: the id of an entry in the top-level datasources map (a string, always an id), or a data source written inline, { "src": "./revenue.csv" }. An unknown id is a 'datasource-unknown' error. Engines never read, fetch or refresh it.
|
|
449
|
+
*
|
|
450
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
451
|
+
* via the `definition` "DataSourceChoice".
|
|
452
|
+
*/
|
|
453
|
+
type DataSourceChoice = (DataSourceId | DataSource);
|
|
454
|
+
/**
|
|
455
|
+
* Id of an entry in the top-level datasources map (the datasets id pattern). A string 'datasource' is only ever such an id; a file or a URL is written as an inline data source object, { "src": "./revenue.csv" }.
|
|
456
|
+
*
|
|
457
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
458
|
+
* via the `definition` "DataSourceId".
|
|
459
|
+
*/
|
|
460
|
+
type DataSourceId = string;
|
|
461
|
+
/**
|
|
462
|
+
* What was taken from the data source, in the data source's own language: a spreadsheet range with its sheet ('FY26!A1:C13'; a sheet name with a space is quoted as spreadsheets do, "'Q3 plan'!A1:B9"), a SQL statement, a path into a document. Engines never run or parse it.
|
|
463
|
+
*
|
|
464
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
465
|
+
* via the `definition` "DataQuery".
|
|
466
|
+
*/
|
|
467
|
+
type DataQuery = string;
|
|
468
|
+
/**
|
|
469
|
+
* When the data was taken from its source: an ISO 8601 date or date-time. Never read from a clock by an engine.
|
|
470
|
+
*
|
|
471
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
472
|
+
* via the `definition` "DataRetrieved".
|
|
473
|
+
*/
|
|
474
|
+
type DataRetrieved = string;
|
|
475
|
+
/**
|
|
476
|
+
* A free string the source system gives the snapshot that was taken: a revision, an etag, a commit.
|
|
477
|
+
*
|
|
478
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
479
|
+
* via the `definition` "DataVersion".
|
|
480
|
+
*/
|
|
481
|
+
type DataVersion = string;
|
|
482
|
+
/**
|
|
483
|
+
* The SHA-256 of the source file's bytes as retrieved, as 64 lowercase hexadecimal digits. It answers 'has the file changed since'. Engines never compute or check it.
|
|
484
|
+
*
|
|
485
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
486
|
+
* via the `definition` "DataSha256".
|
|
487
|
+
*/
|
|
488
|
+
type DataSha256 = string;
|
|
432
489
|
/**
|
|
433
490
|
* The dataset columns to use, by name and in order. Absent uses every column.
|
|
434
491
|
*
|
|
@@ -448,6 +505,22 @@ type DatasetFields = [string, ...(string)[]];
|
|
|
448
505
|
* via the `definition` "ColorRef".
|
|
449
506
|
*/
|
|
450
507
|
type ColorRef = (HexColor | ("accent1" | "accent2" | "accent3" | "accent4" | "accent5" | "accent6" | "dark1" | "dark2" | "light1" | "light2" | "hyperlink" | "followedHyperlink" | "primary" | "secondary" | "accent" | "background" | "surface" | "surfaceAlt" | "text" | "textSecondary") | string | ColorTransform);
|
|
508
|
+
/**
|
|
509
|
+
* One body row of an inline table: an array of cells, or an object that adds an optional id. Position (the cell's index in 'cells' or in the array) is its column either way.
|
|
510
|
+
*
|
|
511
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
512
|
+
* via the `definition` "TableRow".
|
|
513
|
+
*/
|
|
514
|
+
type TableRow = (TableCell[] | {
|
|
515
|
+
/**
|
|
516
|
+
* Optional stable identifier for this table row, unique among every slide, payload, overlay, item, bullet, event and table-row id in the document (one namespace). An opaque string: readers never parse it. Use it when another system must address the table row across edits (a comment anchor, an `@id` patch token, a merge). Edit, move and reorder keep it; a copy inside the document gets a new one. A document without ids is valid and is addressed by index.
|
|
517
|
+
*/
|
|
518
|
+
id?: string;
|
|
519
|
+
/**
|
|
520
|
+
* The row's cells, aligned by index with 'columns' exactly like the array form.
|
|
521
|
+
*/
|
|
522
|
+
cells: TableCell[];
|
|
523
|
+
});
|
|
451
524
|
/**
|
|
452
525
|
* A scalar, rich-run array, or styled/spanning cell object. Existing scalar and rich forms remain valid.
|
|
453
526
|
*
|
|
@@ -468,6 +541,55 @@ type TableCellValue = (string | number | boolean | null | TextRun[]);
|
|
|
468
541
|
* @minItems 1
|
|
469
542
|
*/
|
|
470
543
|
type DatasetFields1 = [string, ...(string)[]];
|
|
544
|
+
/**
|
|
545
|
+
* A color of the effective color scheme, by slot or role, resolved as ColorRef resolves the same names (the hyperlink slots are left out). No hex and no variable: what names it follows the deck's colors.
|
|
546
|
+
*
|
|
547
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
548
|
+
* via the `definition` "SchemeColorName".
|
|
549
|
+
*/
|
|
550
|
+
type SchemeColorName = ("accent1" | "accent2" | "accent3" | "accent4" | "accent5" | "accent6" | "dark1" | "dark2" | "light1" | "light2" | "primary" | "secondary" | "accent" | "background" | "surface" | "surfaceAlt" | "text" | "textSecondary");
|
|
551
|
+
/**
|
|
552
|
+
* Only the rows that meet every condition are used. Absent: every row.
|
|
553
|
+
*
|
|
554
|
+
* @minItems 1
|
|
555
|
+
*/
|
|
556
|
+
type DataFilter = [DataCondition, ...(DataCondition)[]];
|
|
557
|
+
/**
|
|
558
|
+
* How the metric's change is computed. Absent: no change is computed, and a typed 'delta' on the metric is drawn as written.
|
|
559
|
+
*/
|
|
560
|
+
type MetricDelta = ({
|
|
561
|
+
/**
|
|
562
|
+
* What the value is compared with.
|
|
563
|
+
*/
|
|
564
|
+
compare?: ("previous" | {
|
|
565
|
+
filter: DataFilter1;
|
|
566
|
+
} | {
|
|
567
|
+
/**
|
|
568
|
+
* A fixed number to compare with: a plan, a budget, last year's figure typed in.
|
|
569
|
+
*/
|
|
570
|
+
value: number;
|
|
571
|
+
});
|
|
572
|
+
/**
|
|
573
|
+
* A column that holds the change. The change is the metric's aggregate over the same rows of this column. An unknown name is a 'dataset-field-unknown' error.
|
|
574
|
+
*/
|
|
575
|
+
field?: string;
|
|
576
|
+
/**
|
|
577
|
+
* With 'compare': the change as a difference (value minus base) or as a ratio ((value minus base) over the absolute base; 0.12 is 12%). With 'field': what the column holds, which only picks the default format.
|
|
578
|
+
*/
|
|
579
|
+
as?: ("difference" | "percent");
|
|
580
|
+
/**
|
|
581
|
+
* How the change is drawn, usually with sign sections ('+0.0;-0.0;0', '+0%;-0%;0%'). Absent: the value column's format with sign sections built from it ('+#,##0.##;-#,##0.##;0' without one), and '+0%;-0%;0%' for a percent.
|
|
582
|
+
*/
|
|
583
|
+
format?: string;
|
|
584
|
+
} & {
|
|
585
|
+
[k: string]: unknown;
|
|
586
|
+
});
|
|
587
|
+
/**
|
|
588
|
+
* The rows the baseline is computed over. It replaces the metric's own filter instead of adding to it, so it names everything it means.
|
|
589
|
+
*
|
|
590
|
+
* @minItems 1
|
|
591
|
+
*/
|
|
592
|
+
type DataFilter1 = [DataCondition, ...(DataCondition)[]];
|
|
471
593
|
/**
|
|
472
594
|
* A content leaf or recursively composed group. A group contains blocks and optional composition; it cannot mix blocks with leaf payload fields. Groups may nest up to 32 levels.
|
|
473
595
|
*
|
|
@@ -492,7 +614,7 @@ type ContentPayload = {
|
|
|
492
614
|
/**
|
|
493
615
|
* Optional content kind. When omitted, engines infer the kind from the fields present: a block with 'shape' and no 'image', or with 'path', is a shape block.
|
|
494
616
|
*/
|
|
495
|
-
type?: ("text" | "list" | "image" | "chart" | "table" | "video" | "code" | "metric" | "quote" | "timeline" | "diagram" | "shape" | "group");
|
|
617
|
+
type?: ("text" | "list" | "image" | "chart" | "table" | "video" | "embed" | "code" | "metric" | "quote" | "timeline" | "diagram" | "shape" | "group");
|
|
496
618
|
/**
|
|
497
619
|
* Text payload. Use a string for plain text or TextRun[] for inline rich text. TextRun items may be plain strings or formatted run objects.
|
|
498
620
|
*/
|
|
@@ -663,7 +785,7 @@ type ContentPayload = {
|
|
|
663
785
|
*/
|
|
664
786
|
hidden?: boolean;
|
|
665
787
|
/**
|
|
666
|
-
* Shape blocks only.
|
|
788
|
+
* Shape blocks only. Link followed when the shape is clicked in a slide show (a:hlinkClick): an http(s) URL, a 'mailto:' address, a 'tel:' number or 'slide:<id>', a jump to the slide of this deck with that id (ppaction://hlinksldjump). An unknown slide id is a validation error (opf/slide-link-unknown).
|
|
667
789
|
*/
|
|
668
790
|
link?: string;
|
|
669
791
|
/**
|
|
@@ -766,6 +888,27 @@ type ContentPayload = {
|
|
|
766
888
|
*/
|
|
767
889
|
mediaType?: string;
|
|
768
890
|
});
|
|
891
|
+
/**
|
|
892
|
+
* Embed payload: a live web page. Presence of this field infers type 'embed'. Takes a caption and none of the image options (fit, focus, aspectRatio, recolor, ...): the frame's proportions are EmbedPayload.aspectRatio. See EmbedPayload.
|
|
893
|
+
*/
|
|
894
|
+
embed?: (EmbedUrl | {
|
|
895
|
+
/**
|
|
896
|
+
* An https URL. Any other scheme (http, data, javascript, a relative path) is a schema error.
|
|
897
|
+
*/
|
|
898
|
+
src: string;
|
|
899
|
+
/**
|
|
900
|
+
* What the page is: its accessible name, and the heading of the card drawn when there is no 'preview'. Absent: the site name (the host of 'src' without 'www.').
|
|
901
|
+
*/
|
|
902
|
+
title?: string;
|
|
903
|
+
/**
|
|
904
|
+
* Width to height of the frame, as an image block's aspectRatio (1.6 is 16:10). The frame is the largest box of that ratio inside the block's region. Absent: 16:9 (1.7777777777777777).
|
|
905
|
+
*/
|
|
906
|
+
aspectRatio?: number;
|
|
907
|
+
/**
|
|
908
|
+
* An image source in a string shorthand: an 'asset:<id>' reference, an HTTPS URL, a data URI, or a relative path starting with './' or '../' (resolved against the OPF file location).
|
|
909
|
+
*/
|
|
910
|
+
preview?: string;
|
|
911
|
+
});
|
|
769
912
|
chart?: Chart1;
|
|
770
913
|
table?: Table1;
|
|
771
914
|
/**
|
|
@@ -804,7 +947,7 @@ type ContentPayload = {
|
|
|
804
947
|
*/
|
|
805
948
|
diagram?: (string | Diagram);
|
|
806
949
|
/**
|
|
807
|
-
* Caption for an image, chart, table, video or diagram payload, composed inside the block's region (below the media by default). Invalid on other payload kinds and on groups.
|
|
950
|
+
* Caption for an image, chart, table, video, embed or diagram payload, composed inside the block's region (below the media by default). Invalid on other payload kinds and on groups.
|
|
808
951
|
*/
|
|
809
952
|
caption?: (string | TextRun[] | {
|
|
810
953
|
/**
|
|
@@ -899,6 +1042,10 @@ interface Presentation {
|
|
|
899
1042
|
* Optional OPF schema version. When omitted, validators and engines should assume the latest supported OPF schema.
|
|
900
1043
|
*/
|
|
901
1044
|
$schema?: "https://openpresentation.org/schema/opf/v1";
|
|
1045
|
+
/**
|
|
1046
|
+
* Optional identity of the document: an opaque, non-empty string that says 'this is the same deck' across saves, exports, imports and publishes. Core never makes one (it has no clock and no randomness); 'opf create' and hosts do, and a UUID is recommended. Any string is valid, so a host keeps the deck id it already has (such as 'dk_5e8f1a7b3c909d426b1e7c3a'). Kept on save, export, import and publish; a duplicate, a fork or a deck filled from a template is a new deck and gets a new id. PowerPoint round trip: written to the OPF_DOCUMENT_V1 tag and restored on import, and an export with provenance off drops it. The id is a claim, not a credential: a file can carry any id, so a host must check who owns an id before it selects a stored deck.
|
|
1047
|
+
*/
|
|
1048
|
+
id?: string;
|
|
902
1049
|
/**
|
|
903
1050
|
* Display name of the presentation for GUI/TUI lists, library/search indexing, OS-level metadata, and default export filenames. This is deck identity, not slide content. Use slides[].title and slides[].subtitle for text that should appear on presented slides. Also the built-in variable 'deck.name'.
|
|
904
1051
|
*/
|
|
@@ -989,6 +1136,7 @@ interface Presentation {
|
|
|
989
1136
|
*/
|
|
990
1137
|
references?: Reference[];
|
|
991
1138
|
datasets?: Datasets;
|
|
1139
|
+
datasources?: DataSources;
|
|
992
1140
|
assets?: Assets;
|
|
993
1141
|
icons?: Icons;
|
|
994
1142
|
catalogs?: Catalogs;
|
|
@@ -1007,7 +1155,7 @@ interface Presentation {
|
|
|
1007
1155
|
*/
|
|
1008
1156
|
interface Organization {
|
|
1009
1157
|
/**
|
|
1010
|
-
* Stable identifier for the organization, used to reference it from Speaker.
|
|
1158
|
+
* Stable identifier for the organization, used to reference it from Speaker.organization and to address it in built-in variables as 'organization.<id>.<field>'. Must be unique among organizations (a duplicate is a validation error).
|
|
1011
1159
|
*/
|
|
1012
1160
|
id: string;
|
|
1013
1161
|
/**
|
|
@@ -1340,7 +1488,7 @@ interface Speaker {
|
|
|
1340
1488
|
/**
|
|
1341
1489
|
* Reference to an Organization.id in organization; it must name an existing organization (a validation error otherwise). Attribution metadata for hosts: no engine draws it or changes which organization is primary because of it.
|
|
1342
1490
|
*/
|
|
1343
|
-
|
|
1491
|
+
organization?: string;
|
|
1344
1492
|
socials?: Socials1;
|
|
1345
1493
|
}
|
|
1346
1494
|
/**
|
|
@@ -1588,7 +1736,7 @@ interface ColorScheme {
|
|
|
1588
1736
|
textSecondary?: string;
|
|
1589
1737
|
}
|
|
1590
1738
|
/**
|
|
1591
|
-
* Typography selections used by the design system. The pair fields (major, minor) and refinement fields (type, app,
|
|
1739
|
+
* Typography selections used by the design system. The pair fields (major, minor) and refinement fields (type, app, scriptGroup) mirror font-scheme.schema.json (https://openpresentation.org/schema/opf-font-scheme/v1) so library records and inline OPF overrides are interchangeable on those fields.
|
|
1592
1740
|
*
|
|
1593
1741
|
* Two parallel models are supported and may be mixed:
|
|
1594
1742
|
* - OOXML pairs (major, minor) - heading and body family names that round-trip directly to PowerPoint majorFont/minorFont entries.
|
|
@@ -1613,7 +1761,7 @@ interface FontScheme {
|
|
|
1613
1761
|
*/
|
|
1614
1762
|
minor?: string;
|
|
1615
1763
|
/**
|
|
1616
|
-
* East Asian script fonts. Maps to the OOXML a:ea element of majorFont (major) and minorFont (minor), and to run-level a:ea. When set, they fill the eastAsian slot for every language; when omitted, the slot comes from this scheme's own major/minor when
|
|
1764
|
+
* East Asian script fonts. Maps to the OOXML a:ea element of majorFont (major) and minorFont (minor), and to run-level a:ea. When set, they fill the eastAsian slot for every language; when omitted, the slot comes from this scheme's own major/minor when scriptGroup is 'eastAsian' and the scheme's languages list is empty or names the presentation language, then from the presentation language's font scheme for East Asian languages, and otherwise from the latin (major/minor) families. A missing 'major' or 'minor' falls back to the other.
|
|
1617
1765
|
*/
|
|
1618
1766
|
eastAsian?: {
|
|
1619
1767
|
/**
|
|
@@ -1626,7 +1774,7 @@ interface FontScheme {
|
|
|
1626
1774
|
minor?: string;
|
|
1627
1775
|
};
|
|
1628
1776
|
/**
|
|
1629
|
-
* Complex-script fonts (for example Arabic, Hebrew, Indic and Thai). Maps to the OOXML a:cs element of majorFont (major) and minorFont (minor), and to run-level a:cs. When set, they fill the complexScript slot for every language; when omitted, the slot comes from this scheme's own major/minor when
|
|
1777
|
+
* Complex-script fonts (for example Arabic, Hebrew, Indic and Thai). Maps to the OOXML a:cs element of majorFont (major) and minorFont (minor), and to run-level a:cs. When set, they fill the complexScript slot for every language; when omitted, the slot comes from this scheme's own major/minor when scriptGroup is 'complexScript' and the scheme's languages list is empty or names the presentation language, then from the presentation language's font scheme for complex-script languages, and otherwise from the latin (major/minor) families. A missing 'major' or 'minor' falls back to the other.
|
|
1630
1778
|
*/
|
|
1631
1779
|
complexScript?: {
|
|
1632
1780
|
/**
|
|
@@ -1647,9 +1795,9 @@ interface FontScheme {
|
|
|
1647
1795
|
*/
|
|
1648
1796
|
app?: ("powerpoint" | "google-slides");
|
|
1649
1797
|
/**
|
|
1650
|
-
*
|
|
1798
|
+
* The script group this scheme is intended for: 'latin' for Latin-script content and every script outside the other two groups (Cyrillic and Greek too), 'eastAsian' for East Asian scripts, 'complexScript' for Complex Scripts (Arabic, Hebrew, Indic, Thai). The names match the 'eastAsian' and 'complexScript' slot keys. As the design font scheme, an 'eastAsian' or 'complexScript' scheme also fills that script slot with its own major/minor families when its languages list is empty or names the presentation language.
|
|
1651
1799
|
*/
|
|
1652
|
-
|
|
1800
|
+
scriptGroup?: ("latin" | "eastAsian" | "complexScript");
|
|
1653
1801
|
/**
|
|
1654
1802
|
* Abstract role: font family name used for slide titles and headings. Maps onto the OOXML major slot when serializing.
|
|
1655
1803
|
*/
|
|
@@ -1729,9 +1877,9 @@ interface SolidBackground {
|
|
|
1729
1877
|
*/
|
|
1730
1878
|
interface GradientBackground {
|
|
1731
1879
|
/**
|
|
1732
|
-
* Whether the background is dark or light, which picks the color map (dark1 or light1) so text, lines and neutrals read on it. Without
|
|
1880
|
+
* Whether the background is dark or light, which picks the color map (dark1 or light1) so text, lines and neutrals read on it. Without an appearance a picture or gradient takes the deck's variant, else counts as light.
|
|
1733
1881
|
*/
|
|
1734
|
-
|
|
1882
|
+
appearance?: ("dark" | "light");
|
|
1735
1883
|
/**
|
|
1736
1884
|
* Fixed gradient background fill.
|
|
1737
1885
|
*/
|
|
@@ -1797,9 +1945,9 @@ interface GradientBackground {
|
|
|
1797
1945
|
*/
|
|
1798
1946
|
interface ImageBackground {
|
|
1799
1947
|
/**
|
|
1800
|
-
* Whether the background is dark or light, which picks the color map (dark1 or light1) so text, lines and neutrals read on it. Without
|
|
1948
|
+
* Whether the background is dark or light, which picks the color map (dark1 or light1) so text, lines and neutrals read on it. Without an appearance a picture takes the appearance its recolor, opacity and overlay imply (a duotone in dark colors or a dark overlay makes it dark), else the deck's variant, else counts as light.
|
|
1801
1949
|
*/
|
|
1802
|
-
|
|
1950
|
+
appearance?: ("dark" | "light");
|
|
1803
1951
|
/**
|
|
1804
1952
|
* Picture background.
|
|
1805
1953
|
*/
|
|
@@ -1981,7 +2129,7 @@ interface HeaderFooterItem {
|
|
|
1981
2129
|
*/
|
|
1982
2130
|
date?: (boolean | string);
|
|
1983
2131
|
/**
|
|
1984
|
-
* Date pattern for date. Tokens: yyyy (2026), yy (26), MMMM (April), MMM (Apr), MM (04), M (4), dd (09), d (9), EEEE (Thursday), EEE (Thu). Text in single quotes and other non-letter characters are literal. Month and weekday names are
|
|
2132
|
+
* Date pattern for date. Tokens: yyyy (2026), yy (26), MMMM (April), MMM (Apr), MM (04), M (4), dd (09), d (9), EEEE (Thursday), EEE (Thu). Text in single quotes and other non-letter characters are literal. Month and weekday names are those of the language of the slide the date is on (its declared language, else the deck's), from OPF's own table and independent of the host's locale; English when no language is declared. Defaults to "M/d/yyyy" for a current date. PPTX export writes a native current-date field only when its complete value fits within one accepted text line and the pattern matches a PowerPoint en-US date field ('M/d/yyyy'; 'EEEE, MMMM d, yyyy'; 'd MMMM yyyy'; 'MMMM d, yyyy'; 'd-MMM-yy'; 'MMMM yy'; 'MMM-yy'). Other patterns and wrapped fields export as static text with a diagnostic. Full provenance can recover generated-date intent from unchanged supported wrapped dates on OPF reimport; the existing PPTX text remains static.
|
|
1985
2133
|
*/
|
|
1986
2134
|
dateFormat?: string;
|
|
1987
2135
|
/**
|
|
@@ -2027,7 +2175,7 @@ interface HeaderFooterItem1 {
|
|
|
2027
2175
|
*/
|
|
2028
2176
|
date?: (boolean | string);
|
|
2029
2177
|
/**
|
|
2030
|
-
* Date pattern for date. Tokens: yyyy (2026), yy (26), MMMM (April), MMM (Apr), MM (04), M (4), dd (09), d (9), EEEE (Thursday), EEE (Thu). Text in single quotes and other non-letter characters are literal. Month and weekday names are
|
|
2178
|
+
* Date pattern for date. Tokens: yyyy (2026), yy (26), MMMM (April), MMM (Apr), MM (04), M (4), dd (09), d (9), EEEE (Thursday), EEE (Thu). Text in single quotes and other non-letter characters are literal. Month and weekday names are those of the language of the slide the date is on (its declared language, else the deck's), from OPF's own table and independent of the host's locale; English when no language is declared. Defaults to "M/d/yyyy" for a current date. PPTX export writes a native current-date field only when its complete value fits within one accepted text line and the pattern matches a PowerPoint en-US date field ('M/d/yyyy'; 'EEEE, MMMM d, yyyy'; 'd MMMM yyyy'; 'MMMM d, yyyy'; 'd-MMM-yy'; 'MMMM yy'; 'MMM-yy'). Other patterns and wrapped fields export as static text with a diagnostic. Full provenance can recover generated-date intent from unchanged supported wrapped dates on OPF reimport; the existing PPTX text remains static.
|
|
2031
2179
|
*/
|
|
2032
2180
|
dateFormat?: string;
|
|
2033
2181
|
/**
|
|
@@ -2073,7 +2221,7 @@ interface HeaderFooterItem2 {
|
|
|
2073
2221
|
*/
|
|
2074
2222
|
date?: (boolean | string);
|
|
2075
2223
|
/**
|
|
2076
|
-
* Date pattern for date. Tokens: yyyy (2026), yy (26), MMMM (April), MMM (Apr), MM (04), M (4), dd (09), d (9), EEEE (Thursday), EEE (Thu). Text in single quotes and other non-letter characters are literal. Month and weekday names are
|
|
2224
|
+
* Date pattern for date. Tokens: yyyy (2026), yy (26), MMMM (April), MMM (Apr), MM (04), M (4), dd (09), d (9), EEEE (Thursday), EEE (Thu). Text in single quotes and other non-letter characters are literal. Month and weekday names are those of the language of the slide the date is on (its declared language, else the deck's), from OPF's own table and independent of the host's locale; English when no language is declared. Defaults to "M/d/yyyy" for a current date. PPTX export writes a native current-date field only when its complete value fits within one accepted text line and the pattern matches a PowerPoint en-US date field ('M/d/yyyy'; 'EEEE, MMMM d, yyyy'; 'd MMMM yyyy'; 'MMMM d, yyyy'; 'd-MMM-yy'; 'MMMM yy'; 'MMM-yy'). Other patterns and wrapped fields export as static text with a diagnostic. Full provenance can recover generated-date intent from unchanged supported wrapped dates on OPF reimport; the existing PPTX text remains static.
|
|
2077
2225
|
*/
|
|
2078
2226
|
dateFormat?: string;
|
|
2079
2227
|
/**
|
|
@@ -2150,6 +2298,22 @@ interface TextVariable {
|
|
|
2150
2298
|
* Illustrative text shown in fill forms and used when a template is previewed with examples. Never written to output.
|
|
2151
2299
|
*/
|
|
2152
2300
|
example?: (string | TextRun[]);
|
|
2301
|
+
/**
|
|
2302
|
+
* The most characters the value may have, counted as a reader sees them (an accented letter or an emoji counts once, however it is encoded). Checked on the declared value and on a value given to a fill; a longer value is the warning opf/variable-overflow. Fill forms and models read it before writing.
|
|
2303
|
+
*/
|
|
2304
|
+
maxLength?: number;
|
|
2305
|
+
/**
|
|
2306
|
+
* The most lines the value may take where it is drawn. Checked by composition at each place the variable is drawn (a title, a subtitle, a text block or a list entry), because the line count depends on the width of the box; a value that takes more lines is the warning opf/variable-overflow at that place, naming the slide. Inside longer text, the lines are those the variable's own characters occupy.
|
|
2307
|
+
*/
|
|
2308
|
+
maxLines?: number;
|
|
2309
|
+
/**
|
|
2310
|
+
* The text in other languages, keyed by language tag, each entry a 'value' in the same form as the variable's own (a string or TextRun[]). Where the variable is drawn, the slide's declared language (else the deck's) selects an entry: the exact tag, then the tag with its last subtag removed, and so on ('de-AT', then 'de'), compared without regard to case; no match draws 'value'. A language read from the text does not select one. A fill that gives the variable a new value without translations removes them.
|
|
2311
|
+
*/
|
|
2312
|
+
translations?: {
|
|
2313
|
+
[k: string]: {
|
|
2314
|
+
value: (string | TextRun[]);
|
|
2315
|
+
};
|
|
2316
|
+
};
|
|
2153
2317
|
}
|
|
2154
2318
|
/**
|
|
2155
2319
|
* A number. '{{<id>}}' inserts it as text using 'format'; 'var:<id>' as a whole field supplies the number itself (chart values, font sizes).
|
|
@@ -2219,9 +2383,20 @@ interface DateVariable {
|
|
|
2219
2383
|
*/
|
|
2220
2384
|
example?: string;
|
|
2221
2385
|
/**
|
|
2222
|
-
* Date display pattern, the same LDML-style tokens as header/footer dateFormat: yyyy, yy, MMMM, MMM, MM, M, dd, d, EEEE, EEE and quoted literals. English
|
|
2386
|
+
* Date display pattern, the same LDML-style tokens as header/footer dateFormat: yyyy, yy, MMMM, MMM, MM, M, dd, d, EEEE, EEE and quoted literals. The month and weekday names are those of the language where the date is drawn (the slide's declared language, else the deck's; English when none is declared or the table has no data for it); a month after a day token is in its form after a day, else its stand-alone form. Default: the language's long date pattern ('d. MMMM yyyy' in German), 'MMMM d, yyyy' for US English and a deck with no language.
|
|
2223
2387
|
*/
|
|
2224
2388
|
format?: string;
|
|
2389
|
+
/**
|
|
2390
|
+
* How the date is written in other languages, keyed by language tag, each entry a 'format': the date is the same in every language, its pattern is not. Where the variable is drawn, the slide's declared language (else the deck's) selects an entry: the exact tag, then the tag with its last subtag removed, and so on ('de-AT', then 'de'), compared without regard to case; no match uses the variable's own 'format'. A language read from the text does not select one. A fill that gives the variable a new value without translations removes them.
|
|
2391
|
+
*/
|
|
2392
|
+
translations?: {
|
|
2393
|
+
[k: string]: {
|
|
2394
|
+
/**
|
|
2395
|
+
* The date display pattern in this language, in the tokens of the variable's own 'format'.
|
|
2396
|
+
*/
|
|
2397
|
+
format: string;
|
|
2398
|
+
};
|
|
2399
|
+
};
|
|
2225
2400
|
}
|
|
2226
2401
|
/**
|
|
2227
2402
|
* An image source: any Asset (an 'asset:<id>' reference, HTTPS URL, data URI, relative or local path, or an object with src, alt and metadata). Reference it whole as 'var:<id>' in an image, asset or src field; '{{<id>}}' inserts the source string.
|
|
@@ -2296,6 +2471,14 @@ interface ImageVariable {
|
|
|
2296
2471
|
*/
|
|
2297
2472
|
mediaType?: string;
|
|
2298
2473
|
});
|
|
2474
|
+
/**
|
|
2475
|
+
* An image source per language (a localized screenshot), keyed by language tag, each entry a 'value'. Where the variable is drawn, the slide's declared language (else the deck's) selects an entry: the exact tag, then the tag with its last subtag removed, and so on ('de-AT', then 'de'), compared without regard to case; no match draws 'value'. A language read from the text does not select one. A fill that gives the variable a new value without translations removes them.
|
|
2476
|
+
*/
|
|
2477
|
+
translations?: {
|
|
2478
|
+
[k: string]: {
|
|
2479
|
+
value: Asset;
|
|
2480
|
+
};
|
|
2481
|
+
};
|
|
2299
2482
|
}
|
|
2300
2483
|
/**
|
|
2301
2484
|
* A link target (http, https, mailto or tel). Use it as '{{<id>}}' inside a link string or reference it whole as 'var:<id>' in a link field.
|
|
@@ -2328,6 +2511,14 @@ interface UrlVariable {
|
|
|
2328
2511
|
* Illustrative link shown in fill forms and used when a template is previewed with examples. Never written to output.
|
|
2329
2512
|
*/
|
|
2330
2513
|
example?: string;
|
|
2514
|
+
/**
|
|
2515
|
+
* A link target per language (a localized landing page), keyed by language tag, each entry a 'value'. Where the variable is drawn, the slide's declared language (else the deck's) selects an entry: the exact tag, then the tag with its last subtag removed, and so on ('de-AT', then 'de'), compared without regard to case; no match draws 'value'. A language read from the text does not select one. A fill that gives the variable a new value without translations removes them.
|
|
2516
|
+
*/
|
|
2517
|
+
translations?: {
|
|
2518
|
+
[k: string]: {
|
|
2519
|
+
value: string;
|
|
2520
|
+
};
|
|
2521
|
+
};
|
|
2331
2522
|
}
|
|
2332
2523
|
/**
|
|
2333
2524
|
* A list of strings, for bullets and list items. A whole-string array element 'var:<id>' splices every entry into the array in place; a whole field 'var:<id>' becomes the array; '{{<id>}}' joins the entries with ', ' (or the separator after a pipe: '{{<id>|; }}').
|
|
@@ -2360,6 +2551,18 @@ interface ListVariable {
|
|
|
2360
2551
|
* Illustrative entries shown in fill forms and used when a template is previewed with examples. Never written to output.
|
|
2361
2552
|
*/
|
|
2362
2553
|
example?: string[];
|
|
2554
|
+
/**
|
|
2555
|
+
* The most entries the list may have. Checked on the declared value and on a value given to a fill; a longer list is the warning opf/variable-overflow. Fill forms and models read it before writing.
|
|
2556
|
+
*/
|
|
2557
|
+
maxItems?: number;
|
|
2558
|
+
/**
|
|
2559
|
+
* The entries in other languages, keyed by language tag, each entry a 'value' list. Where the variable is drawn, the slide's declared language (else the deck's) selects an entry: the exact tag, then the tag with its last subtag removed, and so on ('de-AT', then 'de'), compared without regard to case; no match draws 'value'. A language read from the text does not select one. A fill that gives the variable a new value without translations removes them.
|
|
2560
|
+
*/
|
|
2561
|
+
translations?: {
|
|
2562
|
+
[k: string]: {
|
|
2563
|
+
value: string[];
|
|
2564
|
+
};
|
|
2565
|
+
};
|
|
2363
2566
|
}
|
|
2364
2567
|
/**
|
|
2365
2568
|
* A single slide. Content is a full-slide root payload or a list of blocks. On a slide without a layout, blocks may name cells of a 3 x 3 grid with their 'region' ('start', 'center+end', 'top:start'): see ContentPayload.region. The columns of that grid are logical: 'start' is the left column in a left-to-right deck and the right column in a right-to-left one. A key on the slide that names a cell is not OPF: validate reports it (opf/schema) with the safe fix that moves its content into a block with 'region'.
|
|
@@ -2379,7 +2582,7 @@ interface Slide {
|
|
|
2379
2582
|
/**
|
|
2380
2583
|
* Optional full-slide content kind. When omitted, engines infer the kind from root payload fields.
|
|
2381
2584
|
*/
|
|
2382
|
-
type?: ("text" | "list" | "image" | "chart" | "table" | "video" | "code" | "metric" | "quote" | "timeline" | "diagram");
|
|
2585
|
+
type?: ("text" | "list" | "image" | "chart" | "table" | "video" | "embed" | "code" | "metric" | "quote" | "timeline" | "diagram");
|
|
2383
2586
|
/**
|
|
2384
2587
|
* Optional reference to one or more beats of the deck's narrative (each value is the id of a beat in the narrative record that the root 'narrative' resolves to). A single string declares the slide's primary beat; an array declares that one slide covers multiple beats. Declares the slide's role in the story arc; does not constrain ordering or structure. Core validate warns about a beat id the resolved narrative does not define, and reports a beat that no slide references. Slides without a beat are valid; multiple slides may share a beat.
|
|
2385
2588
|
*/
|
|
@@ -2470,6 +2673,27 @@ interface Slide {
|
|
|
2470
2673
|
*/
|
|
2471
2674
|
mediaType?: string;
|
|
2472
2675
|
});
|
|
2676
|
+
/**
|
|
2677
|
+
* Full-slide embed: a live web page. Presence of this field infers type 'embed'. A web presenter whose host allows the page shows it live; every other output (PDF, PNG, PowerPoint, print, thumbnails) shows a picture of it linked to its address. Engines never load 'src'. See EmbedPayload.
|
|
2678
|
+
*/
|
|
2679
|
+
embed?: (EmbedUrl | {
|
|
2680
|
+
/**
|
|
2681
|
+
* An https URL. Any other scheme (http, data, javascript, a relative path) is a schema error.
|
|
2682
|
+
*/
|
|
2683
|
+
src: string;
|
|
2684
|
+
/**
|
|
2685
|
+
* What the page is: its accessible name, and the heading of the card drawn when there is no 'preview'. Absent: the site name (the host of 'src' without 'www.').
|
|
2686
|
+
*/
|
|
2687
|
+
title?: string;
|
|
2688
|
+
/**
|
|
2689
|
+
* Width to height of the frame, as an image block's aspectRatio (1.6 is 16:10). The frame is the largest box of that ratio inside the block's region. Absent: 16:9 (1.7777777777777777).
|
|
2690
|
+
*/
|
|
2691
|
+
aspectRatio?: number;
|
|
2692
|
+
/**
|
|
2693
|
+
* An image source in a string shorthand: an 'asset:<id>' reference, an HTTPS URL, a data URI, or a relative path starting with './' or '../' (resolved against the OPF file location).
|
|
2694
|
+
*/
|
|
2695
|
+
preview?: string;
|
|
2696
|
+
});
|
|
2473
2697
|
chart?: Chart;
|
|
2474
2698
|
table?: Table;
|
|
2475
2699
|
/**
|
|
@@ -2508,7 +2732,7 @@ interface Slide {
|
|
|
2508
2732
|
*/
|
|
2509
2733
|
diagram?: (string | Diagram);
|
|
2510
2734
|
/**
|
|
2511
|
-
* Caption for the slide's root image, chart, table, video or diagram payload. Valid only when the slide root holds exactly one of those payloads.
|
|
2735
|
+
* Caption for the slide's root image, chart, table, video, embed or diagram payload. Valid only when the slide root holds exactly one of those payloads.
|
|
2512
2736
|
*/
|
|
2513
2737
|
caption?: (string | TextRun[] | {
|
|
2514
2738
|
/**
|
|
@@ -2607,11 +2831,11 @@ interface ImageCallout {
|
|
|
2607
2831
|
*/
|
|
2608
2832
|
interface Chart {
|
|
2609
2833
|
/**
|
|
2610
|
-
* Chart type, an engine vocabulary validated directly (no catalog lookup): the chart types OPF supports natively in its preview and PPTX export, plus 'combo' (clustered columns with line series, see 'line' and 'secondaryAxis'). Each engine maps a type to its own chart model; labels and picker groups are catalog display metadata.
|
|
2834
|
+
* Chart type, an engine vocabulary validated directly (no catalog lookup): the chart types OPF supports natively in its preview and PPTX export, plus 'combo' (clustered columns with line series, see 'line' and 'secondaryAxis') and 'bullet' (one thin horizontal bar per category against its target tick, over the chart's bands; see 'mapping.target' and 'bands'). Each engine maps a type to its own chart model; labels and picker groups are catalog display metadata.
|
|
2611
2835
|
*/
|
|
2612
|
-
type: ("100pct-stacked-area" | "100pct-stacked-bar" | "100pct-stacked-column" | "area" | "bar" | "box-and-whisker" | "column" | "combo" | "doughnut" | "filled-radar" | "funnel" | "histogram" | "line" | "line-with-markers" | "pareto" | "pie" | "radar" | "radar-with-markers" | "scatter" | "stacked-area" | "stacked-bar" | "stacked-column" | "stacked-line" | "stacked-line-with-markers" | "treemap" | "waterfall" | "world");
|
|
2836
|
+
type: ("100pct-stacked-area" | "100pct-stacked-bar" | "100pct-stacked-column" | "area" | "bar" | "box-and-whisker" | "bullet" | "column" | "combo" | "doughnut" | "filled-radar" | "funnel" | "histogram" | "line" | "line-with-markers" | "pareto" | "pie" | "radar" | "radar-with-markers" | "scatter" | "stacked-area" | "stacked-bar" | "stacked-column" | "stacked-line" | "stacked-line-with-markers" | "treemap" | "waterfall" | "world");
|
|
2613
2837
|
/**
|
|
2614
|
-
* Chart data. Inline data uses a tabular columns/rows shape; renderers convert rows to chart series internally. A DatasetRef ({ "dataset": "<id>" }) plots a top-level dataset instead. Data from a spreadsheet or file is imported into inline columns and rows, and its origin is recorded in data.
|
|
2838
|
+
* Chart data. Inline data uses a tabular columns/rows shape; renderers convert rows to chart series internally. A DatasetRef ({ "dataset": "<id>" }) plots a top-level dataset instead. Data from a spreadsheet or file is imported into inline columns and rows, and its origin is recorded in the data's own 'datasource', 'query', 'retrieved', 'version', 'sha256' and 'generator' keys.
|
|
2615
2839
|
*/
|
|
2616
2840
|
data: (ChartData | DatasetRef);
|
|
2617
2841
|
mapping?: ChartMapping;
|
|
@@ -2620,7 +2844,7 @@ interface Chart {
|
|
|
2620
2844
|
*
|
|
2621
2845
|
* @minItems 1
|
|
2622
2846
|
*/
|
|
2623
|
-
|
|
2847
|
+
lineSeries?: [string, ...(string)[]];
|
|
2624
2848
|
/**
|
|
2625
2849
|
* Combo charts only: line series, by column name, plotted against a secondary value axis at the end of the plot (the right; the left in a right-to-left deck, where the category axis runs from the right). That axis has its own scale, and its tick labels use the number format of the first secondary series' column (DataColumn.format), for example '0%' for a margin. Absent: every series shares the primary value axis at the start of the plot (the left; the right in a right-to-left deck). A name that is not a line series (see 'line') stays on the primary axis with a 'chart-mapping-adapted' warning; an unknown column is a 'chart-mapping-unknown-column' error. On any other chart type it is ignored with a 'chart-option-adapted' warning.
|
|
2626
2850
|
*
|
|
@@ -2631,6 +2855,13 @@ interface Chart {
|
|
|
2631
2855
|
* Explicit numeric references on the chart's value axis, supported on the chart types with one value axis for every series: column, bar, line, line-with-markers, area and combo. A non-empty list on any other type (the stacked and 100% stacked types among them) is the error opf/chart-reference-unsupported-type, located at referenceLines, so a reference is never dropped silently. Absent or [] means none. Authored order, duplicates and values equal to data are preserved. Vertical charts with two or more categories span first-to-last category centers; bars/single-category charts span the full plot. Titles/subtitles never create references or period bands.
|
|
2632
2856
|
*/
|
|
2633
2857
|
referenceLines?: ChartReferenceLine[];
|
|
2858
|
+
/**
|
|
2859
|
+
* Ranges of the value axis shaded behind the data, in increasing order: each band runs from the previous band's 'to' (the first from the axis minimum) to its own 'to'. Colors come from the scheme's neutrals, darkest first, unless a band names its own. Bar, column, line and area charts (and their stacked forms) and the bullet chart draw them; other chart types ignore them with a 'chart-bands-unsupported' warning. In PowerPoint a chart with bands has fixed value-axis bounds, so a value typed beyond them in Edit Data does not rescale the chart.
|
|
2860
|
+
*
|
|
2861
|
+
* @minItems 1
|
|
2862
|
+
* @maxItems 6
|
|
2863
|
+
*/
|
|
2864
|
+
bands?: [ChartBand] | [ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand, ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand, ChartBand, ChartBand, ChartBand];
|
|
2634
2865
|
axisTitles?: ChartAxisTitles;
|
|
2635
2866
|
/**
|
|
2636
2867
|
* Optional legend position. 'none' hides the legend. Absent leaves it to the engines: a line chart of two to four series names its series at the line ends and a pie or one-series doughnut names its slices, with no legend; a column, bar, area or combo chart of two to four series shows its legend in the header row above the plot; other multi-series charts and pie and doughnut charts take a legend at the physical right; a single-series chart takes none. A named position shows the legend there even for a single-series chart; 'left' and 'right' are physical sides in every language. Of the Office 2016 constructs only box-and-whisker takes a legend; histogram, pareto, waterfall, funnel, treemap and world drop the option with a 'chart-option-adapted' diagnostic.
|
|
@@ -2661,65 +2892,105 @@ interface Chart {
|
|
|
2661
2892
|
*/
|
|
2662
2893
|
interface ChartData {
|
|
2663
2894
|
/**
|
|
2664
|
-
* Ordered column labels for the chart data table. A label is a string or a
|
|
2895
|
+
* Ordered column labels for the chart data table. A label is a string or a DatasetColumn ({ "name", "format", "type", "role", "unit" }) whose number format the data labels, value axis and exported workbook use, and which may declare what its cells hold and what the column is for.
|
|
2665
2896
|
*
|
|
2666
2897
|
* @minItems 1
|
|
2667
2898
|
*/
|
|
2668
|
-
columns: [(string |
|
|
2899
|
+
columns: [(string | DatasetColumn), ...((string | DatasetColumn))[]];
|
|
2669
2900
|
/**
|
|
2670
2901
|
* Tabular chart rows. Each row aligns by index with columns.
|
|
2671
2902
|
*
|
|
2672
2903
|
* @minItems 1
|
|
2673
2904
|
*/
|
|
2674
2905
|
rows: [ChartDataCell[], ...(ChartDataCell[])[]];
|
|
2675
|
-
|
|
2906
|
+
datasource?: DataSourceChoice;
|
|
2907
|
+
query?: DataQuery;
|
|
2908
|
+
retrieved?: DataRetrieved;
|
|
2909
|
+
version?: DataVersion;
|
|
2910
|
+
sha256?: DataSha256;
|
|
2911
|
+
generator?: DataGenerator;
|
|
2676
2912
|
}
|
|
2677
2913
|
/**
|
|
2678
|
-
* A named data column
|
|
2914
|
+
* A named data column: a dataset column or an inline chart data column. Adds to DataColumn what its cells hold (type), what it is for (role) and a unit label. The string form is { "name": value } with nothing declared. A table column header keeps DataColumn.
|
|
2679
2915
|
*
|
|
2680
2916
|
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
2681
|
-
* via the `definition` "
|
|
2917
|
+
* via the `definition` "DatasetColumn".
|
|
2682
2918
|
*/
|
|
2683
|
-
interface
|
|
2919
|
+
interface DatasetColumn {
|
|
2684
2920
|
/**
|
|
2685
|
-
* Column label, used as the series name, the table header and the name 'fields'
|
|
2921
|
+
* Column label, used as the series name, the table header and the name 'fields', 'chart.mapping' and data links address.
|
|
2686
2922
|
*/
|
|
2687
2923
|
name: string;
|
|
2688
2924
|
/**
|
|
2689
2925
|
* Number format of the column's number values (data labels, value axis, table cells, exported workbook). Absent: the General form.
|
|
2690
2926
|
*/
|
|
2691
2927
|
format?: string;
|
|
2928
|
+
/**
|
|
2929
|
+
* What the column's cells hold. text: strings. number: finite numbers (a string such as "12" is not one). date: time labels (a year, a period, a month, a week or a date, as the time-order rule reads them, and an ISO 8601 date-time). boolean: true or false. null is a gap in any type. A cell of another kind is a 'data-cell-type' warning. A date category column is drawn as time (the title fallback of the time-order rule is skipped); a text or boolean one never is. Absent: undeclared, read from the cells as before.
|
|
2930
|
+
*/
|
|
2931
|
+
type?: ("text" | "number" | "date" | "boolean");
|
|
2932
|
+
/**
|
|
2933
|
+
* What the column is for. dimension: it labels or groups rows (a region, a product, a month). measure: its values are measured and can be aggregated (revenue, count, rate). Time is type 'date' with role 'dimension'. Absent: undeclared. Engines do not draw differently for a role; tools that pick a chart or aggregate a column read it.
|
|
2934
|
+
*/
|
|
2935
|
+
role?: ("dimension" | "measure");
|
|
2936
|
+
/**
|
|
2937
|
+
* The unit of the column's values, as a label for tools: 'USD', 'ms', 'people'. Engines never print it; 'format' alone decides how a number is drawn.
|
|
2938
|
+
*/
|
|
2939
|
+
unit?: string;
|
|
2692
2940
|
}
|
|
2693
2941
|
/**
|
|
2694
|
-
*
|
|
2942
|
+
* A place data comes from: what it is and on what terms, not what was taken from it or when (that is the dataset's). Engines never read, fetch or refresh it; they keep it through editing, export and re-import. It never holds credentials: no password, token or key in 'src' or anywhere else (opf/datasource-credentials warns about a user and password in 'src' and a key or token in its query string); a host keeps secrets in its own store and names the connection in 'connector' or 'extensions'.
|
|
2943
|
+
*
|
|
2944
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
2945
|
+
* via the `definition` "DataSource".
|
|
2695
2946
|
*/
|
|
2696
|
-
interface
|
|
2947
|
+
interface DataSource {
|
|
2697
2948
|
/**
|
|
2698
|
-
*
|
|
2949
|
+
* Human name of the data source, shown by editors.
|
|
2699
2950
|
*/
|
|
2700
|
-
|
|
2951
|
+
title?: string;
|
|
2701
2952
|
/**
|
|
2702
|
-
*
|
|
2953
|
+
* Free-form note about the data source.
|
|
2703
2954
|
*/
|
|
2704
|
-
|
|
2955
|
+
description?: string;
|
|
2705
2956
|
/**
|
|
2706
|
-
*
|
|
2957
|
+
* The kind of data source, in the host's or the author's words: a name a tool recognizes, such as 'csv', 'xlsx', 'postgres', 'bigquery' or 'rest'. Engines do not interpret it. It also says what language a dataset's 'query' is written in.
|
|
2707
2958
|
*/
|
|
2708
|
-
|
|
2959
|
+
connector?: string;
|
|
2709
2960
|
/**
|
|
2710
|
-
*
|
|
2961
|
+
* Where the data is: an 'asset:<id>' reference, a URL, or a relative or local path. A URL carries no credentials.
|
|
2711
2962
|
*/
|
|
2712
|
-
|
|
2963
|
+
src?: string;
|
|
2713
2964
|
/**
|
|
2714
|
-
*
|
|
2965
|
+
* The terms the data is under: an SPDX license identifier or a short statement. It travels with the data.
|
|
2715
2966
|
*/
|
|
2716
|
-
|
|
2967
|
+
license?: string;
|
|
2968
|
+
/**
|
|
2969
|
+
* How often the data is meant to be taken again, as an ISO 8601 duration. No engine acts on it. A validator given a date warns when a dataset's 'retrieved' is older than this (opf/dataset-stale).
|
|
2970
|
+
*/
|
|
2971
|
+
refreshEvery?: string;
|
|
2972
|
+
/**
|
|
2973
|
+
* Custom data passthrough, for example the connection settings a host owns; ignored by the engine but preserved across read/write round-trips. Never credentials.
|
|
2974
|
+
*/
|
|
2975
|
+
extensions?: {
|
|
2717
2976
|
[k: string]: unknown;
|
|
2718
|
-
}
|
|
2977
|
+
};
|
|
2978
|
+
}
|
|
2979
|
+
/**
|
|
2980
|
+
* Who produced the data: a person or a model, and which. A reviewer of a generated deck can see that a table came from a model, and from which one.
|
|
2981
|
+
*
|
|
2982
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
2983
|
+
* via the `definition` "DataGenerator".
|
|
2984
|
+
*/
|
|
2985
|
+
interface DataGenerator {
|
|
2719
2986
|
/**
|
|
2720
|
-
*
|
|
2987
|
+
* 'human' for a person, 'model' for a language model or another generating program.
|
|
2721
2988
|
*/
|
|
2722
|
-
|
|
2989
|
+
type: ("human" | "model");
|
|
2990
|
+
/**
|
|
2991
|
+
* The person, model or tool, as its owner names it.
|
|
2992
|
+
*/
|
|
2993
|
+
name: string;
|
|
2723
2994
|
}
|
|
2724
2995
|
/**
|
|
2725
2996
|
* Chart data taken from a top-level dataset. Engines inline it before plotting; 'chart.mapping' names columns after the 'fields' selection.
|
|
@@ -2747,14 +3018,18 @@ interface ChartMapping {
|
|
|
2747
3018
|
*/
|
|
2748
3019
|
x?: string;
|
|
2749
3020
|
/**
|
|
2750
|
-
* The plotted columns, in order. Default: every column that is not the category or the X column.
|
|
3021
|
+
* The plotted columns, in order. Default: every column that is not the category or the X column (or, on a bullet chart, the target column).
|
|
2751
3022
|
*
|
|
2752
3023
|
* @minItems 1
|
|
2753
3024
|
*/
|
|
2754
3025
|
series?: [string, ...(string)[]];
|
|
3026
|
+
/**
|
|
3027
|
+
* Bullet charts: the column that holds each category's target, drawn as a tick across the bar. An unknown name is a 'chart-mapping-unknown-column' error. On other chart types it is ignored with a 'chart-mapping-adapted' warning.
|
|
3028
|
+
*/
|
|
3029
|
+
target?: string;
|
|
2755
3030
|
}
|
|
2756
3031
|
/**
|
|
2757
|
-
* One explicit reference on the chart's numeric value axis. Labels and titles never select its value, units or placement. A reference at a category
|
|
3032
|
+
* One explicit reference on the chart's numeric value axis. Labels and titles never select its value, units or placement. A reference at a category is not expressible yet; 'axis' is reserved for it. Ranges of the value axis are the chart's 'bands'.
|
|
2758
3033
|
*
|
|
2759
3034
|
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
2760
3035
|
* via the `definition` "ChartReferenceLine".
|
|
@@ -2789,11 +3064,31 @@ interface ChartReferenceLine {
|
|
|
2789
3064
|
*/
|
|
2790
3065
|
width?: number;
|
|
2791
3066
|
/**
|
|
2792
|
-
*
|
|
3067
|
+
* DrawingML preset dash (a:prstDash), by the names Stroke.dash uses. Default dash.
|
|
2793
3068
|
*/
|
|
2794
|
-
dash?: ("solid" | "dash" | "
|
|
3069
|
+
dash?: ("solid" | "dot" | "dash" | "longDash" | "dashDot" | "longDashDot" | "longDashDotDot" | "sysDot" | "sysDash" | "sysDashDot" | "sysDashDotDot");
|
|
2795
3070
|
});
|
|
2796
3071
|
}
|
|
3072
|
+
/**
|
|
3073
|
+
* One range of a chart's value axis, shaded behind the data (see Chart.bands).
|
|
3074
|
+
*
|
|
3075
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
3076
|
+
* via the `definition` "ChartBand".
|
|
3077
|
+
*/
|
|
3078
|
+
interface ChartBand {
|
|
3079
|
+
/**
|
|
3080
|
+
* The band's upper end, in the value axis's units (with format 0%, 0.8 is 80%). Bands expand automatic axis bounds to the last 'to', as reference lines do.
|
|
3081
|
+
*/
|
|
3082
|
+
to: number;
|
|
3083
|
+
/**
|
|
3084
|
+
* The band's name, such as 'Poor' or 'On target': its legend entry and its text alternative. Absent: the band has no legend entry.
|
|
3085
|
+
*/
|
|
3086
|
+
label?: string;
|
|
3087
|
+
/**
|
|
3088
|
+
* A scheme color instead of the neutral, for ranges that mean good or bad. Drawn as a light tint of that color (25% of it over the chart's surface). Absent: the next neutral.
|
|
3089
|
+
*/
|
|
3090
|
+
color?: ("accent1" | "accent2" | "accent3" | "accent4" | "accent5" | "accent6" | "dark1" | "dark2" | "light1" | "light2" | "primary" | "secondary" | "accent" | "background" | "surface" | "surfaceAlt" | "text" | "textSecondary");
|
|
3091
|
+
}
|
|
2797
3092
|
/**
|
|
2798
3093
|
* Optional axis titles. Absent keeps today's untitled axes. Supported on the chart types that have a category/value (or X/Y) axis pair (column, bar, line, area, scatter, and the histogram, pareto, waterfall and box-and-whisker constructs; the funnel construct takes a category title only; a combo chart also takes 'secondary' when it plots a series on the secondary axis); a title on a type without that axis (pie, doughnut, radar, treemap, world) is dropped with a 'chart-option-adapted' diagnostic by renderers and exporters.
|
|
2799
3094
|
*/
|
|
@@ -2855,9 +3150,9 @@ interface Table {
|
|
|
2855
3150
|
*/
|
|
2856
3151
|
columns?: (string | TextRun[] | StyledTableCell | DataColumn | null)[];
|
|
2857
3152
|
/**
|
|
2858
|
-
* Two-dimensional table row data; each row aligns by index with columns when columns are supplied.
|
|
3153
|
+
* Two-dimensional table row data; each row aligns by index with columns when columns are supplied. A row is an array of cells, or an object { "id", "cells" } when it needs an id; both forms may mix in one table. `tableRows` in the core package returns every row in one form.
|
|
2859
3154
|
*/
|
|
2860
|
-
rows?:
|
|
3155
|
+
rows?: TableRow[];
|
|
2861
3156
|
/**
|
|
2862
3157
|
* Id of a top-level dataset that supplies this table's headers, rows and column formats. Excludes 'rows' and 'columns'. An unknown id is a 'dataset-unknown' error.
|
|
2863
3158
|
*/
|
|
@@ -2876,6 +3171,7 @@ interface Table {
|
|
|
2876
3171
|
*/
|
|
2877
3172
|
rows: string[];
|
|
2878
3173
|
};
|
|
3174
|
+
colorScale?: TableColorScale;
|
|
2879
3175
|
}
|
|
2880
3176
|
/**
|
|
2881
3177
|
* A cell with explicit visual style or merged geometry. Its position remains its array column index; use null placeholders for every covered grid position.
|
|
@@ -2940,7 +3236,7 @@ interface TableCellStyle {
|
|
|
2940
3236
|
/**
|
|
2941
3237
|
* Vertical alignment inside the padded cell box.
|
|
2942
3238
|
*/
|
|
2943
|
-
|
|
3239
|
+
anchor?: ("top" | "middle" | "bottom");
|
|
2944
3240
|
padding?: TableCellPadding;
|
|
2945
3241
|
/**
|
|
2946
3242
|
* Independent cell edges. An omitted edge keeps the table's default rule: a line under every row (and over the first row), none between columns. Width 0 removes an edge.
|
|
@@ -2951,7 +3247,13 @@ interface TableCellStyle {
|
|
|
2951
3247
|
*/
|
|
2952
3248
|
top?: ("none" | {
|
|
2953
3249
|
/**
|
|
2954
|
-
*
|
|
3250
|
+
* A color value or reference, enforced on shape fills and strokes, image strokes, styled table cell fill and text colors, cell border colors, solid background colors, gradient stop colors and pattern foreground and background colors. Four forms:
|
|
3251
|
+
* - Literal hex: '#RGB', '#RRGGBB', or '#RRGGBBAA'.
|
|
3252
|
+
* - Color-scheme name, resolved through the effective color scheme after design resolution: an OOXML slot ('accent1'-'accent6', 'dark1', 'dark2', 'light1', 'light2', 'hyperlink', 'followedHyperlink') or an abstract role ('primary', 'secondary', 'accent', 'background', 'surface', 'surfaceAlt', 'text', 'textSecondary'). Roles resolve through the same role-to-slot mapping engines already apply to color schemes. 'surfaceAlt' has no slot: it is the alternate surface of banded table rows, derived from 'surface' and 'text' (the surface mixed a tenth of the way towards the text color, further when needed, so it always differs visibly from 'surface' and keeps 4.5:1 text contrast; core surfaceAltColor).
|
|
3253
|
+
* - Variable reference: 'var:<id>' into the top-level variables map.
|
|
3254
|
+
* - Lighter or darker: { "color": <ColorRef>, "lighten": 0..1 } or { "color": <ColorRef>, "darken": 0..1 }, PowerPoint's "Lighter 40%" and "Darker 25%": the color's HSL luminance moved that share of the way to white (lighten) or to black (darken). Core resolves it (resolveColorRef); PPTX export writes the base color (a scheme color where it is one) with a:lumMod and a:lumOff.
|
|
3255
|
+
*
|
|
3256
|
+
* Names keep content theme-portable: re-theming the deck updates every named reference, where a literal hex stays frozen. Unknown 'var:' ids produce a validation warning, never an error, and engines fall back to their default text color. TextRun.color documents the same three forms but remains an open string so imported decks with unrecognized run colors stay valid; validators warn there instead of erroring.
|
|
2955
3257
|
*/
|
|
2956
3258
|
color?: (HexColor | ("accent1" | "accent2" | "accent3" | "accent4" | "accent5" | "accent6" | "dark1" | "dark2" | "light1" | "light2" | "hyperlink" | "followedHyperlink" | "primary" | "secondary" | "accent" | "background" | "surface" | "surfaceAlt" | "text" | "textSecondary") | string | ColorTransform);
|
|
2957
3259
|
/**
|
|
@@ -2968,7 +3270,13 @@ interface TableCellStyle {
|
|
|
2968
3270
|
*/
|
|
2969
3271
|
right?: ("none" | {
|
|
2970
3272
|
/**
|
|
2971
|
-
*
|
|
3273
|
+
* A color value or reference, enforced on shape fills and strokes, image strokes, styled table cell fill and text colors, cell border colors, solid background colors, gradient stop colors and pattern foreground and background colors. Four forms:
|
|
3274
|
+
* - Literal hex: '#RGB', '#RRGGBB', or '#RRGGBBAA'.
|
|
3275
|
+
* - Color-scheme name, resolved through the effective color scheme after design resolution: an OOXML slot ('accent1'-'accent6', 'dark1', 'dark2', 'light1', 'light2', 'hyperlink', 'followedHyperlink') or an abstract role ('primary', 'secondary', 'accent', 'background', 'surface', 'surfaceAlt', 'text', 'textSecondary'). Roles resolve through the same role-to-slot mapping engines already apply to color schemes. 'surfaceAlt' has no slot: it is the alternate surface of banded table rows, derived from 'surface' and 'text' (the surface mixed a tenth of the way towards the text color, further when needed, so it always differs visibly from 'surface' and keeps 4.5:1 text contrast; core surfaceAltColor).
|
|
3276
|
+
* - Variable reference: 'var:<id>' into the top-level variables map.
|
|
3277
|
+
* - Lighter or darker: { "color": <ColorRef>, "lighten": 0..1 } or { "color": <ColorRef>, "darken": 0..1 }, PowerPoint's "Lighter 40%" and "Darker 25%": the color's HSL luminance moved that share of the way to white (lighten) or to black (darken). Core resolves it (resolveColorRef); PPTX export writes the base color (a scheme color where it is one) with a:lumMod and a:lumOff.
|
|
3278
|
+
*
|
|
3279
|
+
* Names keep content theme-portable: re-theming the deck updates every named reference, where a literal hex stays frozen. Unknown 'var:' ids produce a validation warning, never an error, and engines fall back to their default text color. TextRun.color documents the same three forms but remains an open string so imported decks with unrecognized run colors stay valid; validators warn there instead of erroring.
|
|
2972
3280
|
*/
|
|
2973
3281
|
color?: (HexColor | ("accent1" | "accent2" | "accent3" | "accent4" | "accent5" | "accent6" | "dark1" | "dark2" | "light1" | "light2" | "hyperlink" | "followedHyperlink" | "primary" | "secondary" | "accent" | "background" | "surface" | "surfaceAlt" | "text" | "textSecondary") | string | ColorTransform);
|
|
2974
3282
|
/**
|
|
@@ -2985,7 +3293,13 @@ interface TableCellStyle {
|
|
|
2985
3293
|
*/
|
|
2986
3294
|
bottom?: ("none" | {
|
|
2987
3295
|
/**
|
|
2988
|
-
*
|
|
3296
|
+
* A color value or reference, enforced on shape fills and strokes, image strokes, styled table cell fill and text colors, cell border colors, solid background colors, gradient stop colors and pattern foreground and background colors. Four forms:
|
|
3297
|
+
* - Literal hex: '#RGB', '#RRGGBB', or '#RRGGBBAA'.
|
|
3298
|
+
* - Color-scheme name, resolved through the effective color scheme after design resolution: an OOXML slot ('accent1'-'accent6', 'dark1', 'dark2', 'light1', 'light2', 'hyperlink', 'followedHyperlink') or an abstract role ('primary', 'secondary', 'accent', 'background', 'surface', 'surfaceAlt', 'text', 'textSecondary'). Roles resolve through the same role-to-slot mapping engines already apply to color schemes. 'surfaceAlt' has no slot: it is the alternate surface of banded table rows, derived from 'surface' and 'text' (the surface mixed a tenth of the way towards the text color, further when needed, so it always differs visibly from 'surface' and keeps 4.5:1 text contrast; core surfaceAltColor).
|
|
3299
|
+
* - Variable reference: 'var:<id>' into the top-level variables map.
|
|
3300
|
+
* - Lighter or darker: { "color": <ColorRef>, "lighten": 0..1 } or { "color": <ColorRef>, "darken": 0..1 }, PowerPoint's "Lighter 40%" and "Darker 25%": the color's HSL luminance moved that share of the way to white (lighten) or to black (darken). Core resolves it (resolveColorRef); PPTX export writes the base color (a scheme color where it is one) with a:lumMod and a:lumOff.
|
|
3301
|
+
*
|
|
3302
|
+
* Names keep content theme-portable: re-theming the deck updates every named reference, where a literal hex stays frozen. Unknown 'var:' ids produce a validation warning, never an error, and engines fall back to their default text color. TextRun.color documents the same three forms but remains an open string so imported decks with unrecognized run colors stay valid; validators warn there instead of erroring.
|
|
2989
3303
|
*/
|
|
2990
3304
|
color?: (HexColor | ("accent1" | "accent2" | "accent3" | "accent4" | "accent5" | "accent6" | "dark1" | "dark2" | "light1" | "light2" | "hyperlink" | "followedHyperlink" | "primary" | "secondary" | "accent" | "background" | "surface" | "surfaceAlt" | "text" | "textSecondary") | string | ColorTransform);
|
|
2991
3305
|
/**
|
|
@@ -3002,7 +3316,13 @@ interface TableCellStyle {
|
|
|
3002
3316
|
*/
|
|
3003
3317
|
left?: ("none" | {
|
|
3004
3318
|
/**
|
|
3005
|
-
*
|
|
3319
|
+
* A color value or reference, enforced on shape fills and strokes, image strokes, styled table cell fill and text colors, cell border colors, solid background colors, gradient stop colors and pattern foreground and background colors. Four forms:
|
|
3320
|
+
* - Literal hex: '#RGB', '#RRGGBB', or '#RRGGBBAA'.
|
|
3321
|
+
* - Color-scheme name, resolved through the effective color scheme after design resolution: an OOXML slot ('accent1'-'accent6', 'dark1', 'dark2', 'light1', 'light2', 'hyperlink', 'followedHyperlink') or an abstract role ('primary', 'secondary', 'accent', 'background', 'surface', 'surfaceAlt', 'text', 'textSecondary'). Roles resolve through the same role-to-slot mapping engines already apply to color schemes. 'surfaceAlt' has no slot: it is the alternate surface of banded table rows, derived from 'surface' and 'text' (the surface mixed a tenth of the way towards the text color, further when needed, so it always differs visibly from 'surface' and keeps 4.5:1 text contrast; core surfaceAltColor).
|
|
3322
|
+
* - Variable reference: 'var:<id>' into the top-level variables map.
|
|
3323
|
+
* - Lighter or darker: { "color": <ColorRef>, "lighten": 0..1 } or { "color": <ColorRef>, "darken": 0..1 }, PowerPoint's "Lighter 40%" and "Darker 25%": the color's HSL luminance moved that share of the way to white (lighten) or to black (darken). Core resolves it (resolveColorRef); PPTX export writes the base color (a scheme color where it is one) with a:lumMod and a:lumOff.
|
|
3324
|
+
*
|
|
3325
|
+
* Names keep content theme-portable: re-theming the deck updates every named reference, where a literal hex stays frozen. Unknown 'var:' ids produce a validation warning, never an error, and engines fall back to their default text color. TextRun.color documents the same three forms but remains an open string so imported decks with unrecognized run colors stay valid; validators warn there instead of erroring.
|
|
3006
3326
|
*/
|
|
3007
3327
|
color?: (HexColor | ("accent1" | "accent2" | "accent3" | "accent4" | "accent5" | "accent6" | "dark1" | "dark2" | "light1" | "light2" | "hyperlink" | "followedHyperlink" | "primary" | "secondary" | "accent" | "background" | "surface" | "surfaceAlt" | "text" | "textSecondary") | string | ColorTransform);
|
|
3008
3328
|
/**
|
|
@@ -3028,6 +3348,52 @@ interface TableCellPadding {
|
|
|
3028
3348
|
bottom?: number;
|
|
3029
3349
|
left?: number;
|
|
3030
3350
|
}
|
|
3351
|
+
/**
|
|
3352
|
+
* A named data column with an optional number format. Anywhere a chart or dataset column is a string it may be a DataColumn; the string form is { "name": value } with no format. A table column header may also be a DataColumn.
|
|
3353
|
+
*
|
|
3354
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
3355
|
+
* via the `definition` "DataColumn".
|
|
3356
|
+
*/
|
|
3357
|
+
interface DataColumn {
|
|
3358
|
+
/**
|
|
3359
|
+
* Column label, used as the series name, the table header and the name 'fields' and 'chart.mapping' address.
|
|
3360
|
+
*/
|
|
3361
|
+
name: string;
|
|
3362
|
+
/**
|
|
3363
|
+
* Number format of the column's number values (data labels, value axis, table cells, exported workbook). Absent: the General form.
|
|
3364
|
+
*/
|
|
3365
|
+
format?: string;
|
|
3366
|
+
}
|
|
3367
|
+
/**
|
|
3368
|
+
* Shades the number cells of the named columns by value, between scheme colors. Engines compute each cell's fill; the text color follows it for contrast.
|
|
3369
|
+
*/
|
|
3370
|
+
interface TableColorScale {
|
|
3371
|
+
/**
|
|
3372
|
+
* The columns to shade, by header text (an inline table) or by dataset column name after 'fields' (a dataset-backed table). A name no column has is a 'table-color-scale-unknown-column' error.
|
|
3373
|
+
*
|
|
3374
|
+
* @minItems 1
|
|
3375
|
+
*/
|
|
3376
|
+
columns: [string, ...(string)[]];
|
|
3377
|
+
/**
|
|
3378
|
+
* The colors of the scale, low to high, as scheme color names. Two colors make a sequential scale (the lowest value in the first, the highest in the second); three make a diverging scale (the middle color is drawn at 'center', the first below it and the last above it). Absent: ['surface', 'primary'].
|
|
3379
|
+
*
|
|
3380
|
+
* @minItems 2
|
|
3381
|
+
* @maxItems 3
|
|
3382
|
+
*/
|
|
3383
|
+
colors?: [SchemeColorName, SchemeColorName] | [SchemeColorName, SchemeColorName, SchemeColorName];
|
|
3384
|
+
/**
|
|
3385
|
+
* The value drawn in the middle color. Only with three 'colors' (a 'center' with two colors, or with no 'colors', is a schema error). Absent: 0 when the values span both signs, else the middle of the range. With no 'min' and no 'max' the scale is symmetric around it.
|
|
3386
|
+
*/
|
|
3387
|
+
center?: number;
|
|
3388
|
+
/**
|
|
3389
|
+
* The value drawn in the first color; lower values draw in it too. Absent: the lowest number in the named columns (a diverging scale with neither 'min' nor 'max' is symmetric around 'center': it runs from center minus d to center plus d, d the largest distance of any value from the center). A given 'min' or 'max' pins that end exactly, and each side of a diverging scale is then on its own span.
|
|
3390
|
+
*/
|
|
3391
|
+
min?: number;
|
|
3392
|
+
/**
|
|
3393
|
+
* The value drawn in the last color; higher values draw in it too. Absent: the highest number in the named columns (see 'min' for a diverging scale).
|
|
3394
|
+
*/
|
|
3395
|
+
max?: number;
|
|
3396
|
+
}
|
|
3031
3397
|
/**
|
|
3032
3398
|
* Code content with optional rendering metadata. Use 'source' for the code text, 'language' for syntax highlighting, 'filename' when the rendered block should show a file label, and 'highlight' to emphasize lines. A string value in a code field is shorthand for { "source": value }.
|
|
3033
3399
|
*
|
|
@@ -3055,7 +3421,7 @@ interface Code {
|
|
|
3055
3421
|
highlight?: [(number | [number, number]), ...((number | [number, number]))[]];
|
|
3056
3422
|
}
|
|
3057
3423
|
/**
|
|
3058
|
-
* Metric content with optional display metadata. Use 'value' for the primary value, 'label' for the metric name, 'description' for supporting context, 'unit' for a suffix/currency marker, 'delta' for change, 'trend' for direction, and 'sentiment' for whether the change is good news. A string or number value in a metric field is shorthand for { "value": value }; numeric values remain numbers and are formatted by renderers.
|
|
3424
|
+
* Metric content with optional display metadata. Use 'value' for the primary value, 'label' for the metric name, 'description' for supporting context, 'unit' for a suffix/currency marker, 'delta' for change, 'trend' for direction, and 'sentiment' for whether the change is good news, 'format' for how a number value is written, 'better' for which direction of change is good news, 'data' to compute the value and the change from a dataset of this deck, and 'gauge' to draw the value on an arc against its range. A string or number value in a metric field is shorthand for { "value": value }; numeric values remain numbers and are formatted by renderers. Only the object form carries 'data'.
|
|
3059
3425
|
*
|
|
3060
3426
|
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
3061
3427
|
* via the `definition` "Metric".
|
|
@@ -3093,6 +3459,79 @@ interface Metric {
|
|
|
3093
3459
|
* An icon drawn on a chip above the metric: "<set>:<name>" ("lucide:users"), a name from the deck's icons, or an SVG source. Decoration only: when the slide has no room for it without setting text smaller, it is not drawn (finding opf/icon-dropped). See docs/icons.md.
|
|
3094
3460
|
*/
|
|
3095
3461
|
icon?: string;
|
|
3462
|
+
/**
|
|
3463
|
+
* How a number 'value' is written, the same pattern language as a number variable, a dataset column and a table cell ('0.0%', '$#,##0.0M'). A string 'value' is drawn as written. Absent: a metric linked to data uses its column's format, and any other metric today's number rules (grouping by the slide's language). It applies to the value only; the change keeps its own format. 'unit' is still printed after the value ('metric-unit-repeated' warning when the format already prints it).
|
|
3464
|
+
*/
|
|
3465
|
+
format?: string;
|
|
3466
|
+
data?: MetricData;
|
|
3467
|
+
/**
|
|
3468
|
+
* Which direction of change is good news. Without 'sentiment', an up trend is positive and a down trend negative when 'better' is "up" (the default), and the reverse when it is "down"; a flat trend is neutral. An explicit 'sentiment' still wins. It also colors a typed 'trend'.
|
|
3469
|
+
*/
|
|
3470
|
+
better?: ("up" | "down");
|
|
3471
|
+
gauge?: MetricGauge;
|
|
3472
|
+
}
|
|
3473
|
+
/**
|
|
3474
|
+
* Computes the value and, optionally, the change from a dataset of this deck. While it resolves, engines draw the computed numbers; 'value' and 'delta' are then the last computed numbers, kept for readers that do not compute, and 'trend' (the sign of the computed change) and 'sentiment' (from 'better') follow unless they are written. When the link does not resolve, the written value and delta are drawn.
|
|
3475
|
+
*/
|
|
3476
|
+
interface MetricData {
|
|
3477
|
+
/**
|
|
3478
|
+
* Id of the dataset. An unknown id is a 'dataset-unknown' error.
|
|
3479
|
+
*/
|
|
3480
|
+
dataset: string;
|
|
3481
|
+
/**
|
|
3482
|
+
* The column whose cells are aggregated. An unknown name is a 'dataset-field-unknown' error.
|
|
3483
|
+
*/
|
|
3484
|
+
field: string;
|
|
3485
|
+
/**
|
|
3486
|
+
* How the cells are combined; see DataLink.
|
|
3487
|
+
*/
|
|
3488
|
+
aggregate: ("sum" | "mean" | "min" | "max" | "count" | "first" | "last");
|
|
3489
|
+
filter?: DataFilter;
|
|
3490
|
+
delta?: MetricDelta;
|
|
3491
|
+
}
|
|
3492
|
+
/**
|
|
3493
|
+
* One condition on a row: the row's cell in 'field' compared with 'value'. Nothing is parsed or evaluated. '=' and '!=' compare the same JSON value (null equals only null, 1 does not equal "1"); '<', '<=', '>' and '>=' compare two numbers as numbers, or two strings by the time order of a 'date' column ("2026-03" before "2026-11", "Q1 2026" before "Q3 2026") and else by code point, and any other pair does not meet the condition; 'in' is equal to one of the listed values.
|
|
3494
|
+
*
|
|
3495
|
+
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
3496
|
+
* via the `definition` "DataCondition".
|
|
3497
|
+
*/
|
|
3498
|
+
interface DataCondition {
|
|
3499
|
+
/**
|
|
3500
|
+
* A column name of the linked dataset. An unknown name is a 'dataset-field-unknown' error.
|
|
3501
|
+
*/
|
|
3502
|
+
field: string;
|
|
3503
|
+
/**
|
|
3504
|
+
* How the row's cell is compared with 'value'.
|
|
3505
|
+
*/
|
|
3506
|
+
op: ("=" | "!=" | "<" | "<=" | ">" | ">=" | "in");
|
|
3507
|
+
/**
|
|
3508
|
+
* The value to compare with. For 'in', a list of values.
|
|
3509
|
+
*/
|
|
3510
|
+
value: (ChartDataCell | [ChartDataCell, ...(ChartDataCell)[]]);
|
|
3511
|
+
}
|
|
3512
|
+
/**
|
|
3513
|
+
* Draws the metric as a gauge: its value on a half-circle arc from 'min' (left) to 'max' (right), over optional bands, with an optional target tick, and the metric's text under the arc (the value inside the arc's bowl when it fits there). Only a number value draws a gauge; any other value draws the metric without it ('metric-gauge-value' warning). A value outside the range keeps printing its real number while its arc stops at the end ('metric-gauge-range' warning). In a region too small for an arc 96 reference pixels wide the metric is drawn without its gauge. PowerPoint export draws native block arcs.
|
|
3514
|
+
*/
|
|
3515
|
+
interface MetricGauge {
|
|
3516
|
+
/**
|
|
3517
|
+
* The value at the arc's start (its left end).
|
|
3518
|
+
*/
|
|
3519
|
+
min?: number;
|
|
3520
|
+
/**
|
|
3521
|
+
* The value at the arc's end (its right end). Must be greater than 'min' ('metric-gauge-range' warning otherwise, and no gauge is drawn).
|
|
3522
|
+
*/
|
|
3523
|
+
max: number;
|
|
3524
|
+
/**
|
|
3525
|
+
* Ranges of the gauge shaded along its arc, as a chart's bands: each from the previous 'to' (the first from 'min') to its own 'to'. A band without a color is a neutral; a band with one is a light tint of it, and the value arc takes the band's full color while the value falls in it.
|
|
3526
|
+
*
|
|
3527
|
+
* @minItems 1
|
|
3528
|
+
* @maxItems 6
|
|
3529
|
+
*/
|
|
3530
|
+
bands?: [ChartBand] | [ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand, ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand, ChartBand, ChartBand, ChartBand];
|
|
3531
|
+
/**
|
|
3532
|
+
* A value marked by a tick across the arc. A target outside 'min' to 'max' is not drawn ('metric-gauge-range' warning).
|
|
3533
|
+
*/
|
|
3534
|
+
target?: number;
|
|
3096
3535
|
}
|
|
3097
3536
|
/**
|
|
3098
3537
|
* Quote content with optional attribution metadata. Use 'text' for the quoted text, 'attribution' for the credited person or organization, 'role' for that person's title and organization, 'photo' for their headshot and 'source' for a citation or URL. A string value in a quote field is shorthand for { "text": value }.
|
|
@@ -3154,6 +3593,10 @@ interface Quote {
|
|
|
3154
3593
|
* via the `definition` "TimelineEvent".
|
|
3155
3594
|
*/
|
|
3156
3595
|
interface TimelineEvent {
|
|
3596
|
+
/**
|
|
3597
|
+
* Optional stable identifier for this timeline event, unique among every slide, payload, overlay, item, bullet, event and table-row id in the document (one namespace). An opaque string: readers never parse it. Use it when another system must address the timeline event across edits (a comment anchor, an `@id` patch token, a merge). Edit, move and reorder keep it; a copy inside the document gets a new one. A document without ids is valid and is addressed by index.
|
|
3598
|
+
*/
|
|
3599
|
+
id?: string;
|
|
3157
3600
|
/**
|
|
3158
3601
|
* Event time, date, or sequence label. Use ISO-like values when possible, but human labels are allowed for quarters, eras, and relative milestones.
|
|
3159
3602
|
*/
|
|
@@ -3531,11 +3974,11 @@ interface ImagePlacement {
|
|
|
3531
3974
|
*/
|
|
3532
3975
|
interface Chart1 {
|
|
3533
3976
|
/**
|
|
3534
|
-
* Chart type, an engine vocabulary validated directly (no catalog lookup): the chart types OPF supports natively in its preview and PPTX export, plus 'combo' (clustered columns with line series, see 'line' and 'secondaryAxis'). Each engine maps a type to its own chart model; labels and picker groups are catalog display metadata.
|
|
3977
|
+
* Chart type, an engine vocabulary validated directly (no catalog lookup): the chart types OPF supports natively in its preview and PPTX export, plus 'combo' (clustered columns with line series, see 'line' and 'secondaryAxis') and 'bullet' (one thin horizontal bar per category against its target tick, over the chart's bands; see 'mapping.target' and 'bands'). Each engine maps a type to its own chart model; labels and picker groups are catalog display metadata.
|
|
3535
3978
|
*/
|
|
3536
|
-
type: ("100pct-stacked-area" | "100pct-stacked-bar" | "100pct-stacked-column" | "area" | "bar" | "box-and-whisker" | "column" | "combo" | "doughnut" | "filled-radar" | "funnel" | "histogram" | "line" | "line-with-markers" | "pareto" | "pie" | "radar" | "radar-with-markers" | "scatter" | "stacked-area" | "stacked-bar" | "stacked-column" | "stacked-line" | "stacked-line-with-markers" | "treemap" | "waterfall" | "world");
|
|
3979
|
+
type: ("100pct-stacked-area" | "100pct-stacked-bar" | "100pct-stacked-column" | "area" | "bar" | "box-and-whisker" | "bullet" | "column" | "combo" | "doughnut" | "filled-radar" | "funnel" | "histogram" | "line" | "line-with-markers" | "pareto" | "pie" | "radar" | "radar-with-markers" | "scatter" | "stacked-area" | "stacked-bar" | "stacked-column" | "stacked-line" | "stacked-line-with-markers" | "treemap" | "waterfall" | "world");
|
|
3537
3980
|
/**
|
|
3538
|
-
* Chart data. Inline data uses a tabular columns/rows shape; renderers convert rows to chart series internally. A DatasetRef ({ "dataset": "<id>" }) plots a top-level dataset instead. Data from a spreadsheet or file is imported into inline columns and rows, and its origin is recorded in data.
|
|
3981
|
+
* Chart data. Inline data uses a tabular columns/rows shape; renderers convert rows to chart series internally. A DatasetRef ({ "dataset": "<id>" }) plots a top-level dataset instead. Data from a spreadsheet or file is imported into inline columns and rows, and its origin is recorded in the data's own 'datasource', 'query', 'retrieved', 'version', 'sha256' and 'generator' keys.
|
|
3539
3982
|
*/
|
|
3540
3983
|
data: (ChartData | DatasetRef);
|
|
3541
3984
|
mapping?: ChartMapping;
|
|
@@ -3544,7 +3987,7 @@ interface Chart1 {
|
|
|
3544
3987
|
*
|
|
3545
3988
|
* @minItems 1
|
|
3546
3989
|
*/
|
|
3547
|
-
|
|
3990
|
+
lineSeries?: [string, ...(string)[]];
|
|
3548
3991
|
/**
|
|
3549
3992
|
* Combo charts only: line series, by column name, plotted against a secondary value axis at the end of the plot (the right; the left in a right-to-left deck, where the category axis runs from the right). That axis has its own scale, and its tick labels use the number format of the first secondary series' column (DataColumn.format), for example '0%' for a margin. Absent: every series shares the primary value axis at the start of the plot (the left; the right in a right-to-left deck). A name that is not a line series (see 'line') stays on the primary axis with a 'chart-mapping-adapted' warning; an unknown column is a 'chart-mapping-unknown-column' error. On any other chart type it is ignored with a 'chart-option-adapted' warning.
|
|
3550
3993
|
*
|
|
@@ -3555,6 +3998,13 @@ interface Chart1 {
|
|
|
3555
3998
|
* Explicit numeric references on the chart's value axis, supported on the chart types with one value axis for every series: column, bar, line, line-with-markers, area and combo. A non-empty list on any other type (the stacked and 100% stacked types among them) is the error opf/chart-reference-unsupported-type, located at referenceLines, so a reference is never dropped silently. Absent or [] means none. Authored order, duplicates and values equal to data are preserved. Vertical charts with two or more categories span first-to-last category centers; bars/single-category charts span the full plot. Titles/subtitles never create references or period bands.
|
|
3556
3999
|
*/
|
|
3557
4000
|
referenceLines?: ChartReferenceLine[];
|
|
4001
|
+
/**
|
|
4002
|
+
* Ranges of the value axis shaded behind the data, in increasing order: each band runs from the previous band's 'to' (the first from the axis minimum) to its own 'to'. Colors come from the scheme's neutrals, darkest first, unless a band names its own. Bar, column, line and area charts (and their stacked forms) and the bullet chart draw them; other chart types ignore them with a 'chart-bands-unsupported' warning. In PowerPoint a chart with bands has fixed value-axis bounds, so a value typed beyond them in Edit Data does not rescale the chart.
|
|
4003
|
+
*
|
|
4004
|
+
* @minItems 1
|
|
4005
|
+
* @maxItems 6
|
|
4006
|
+
*/
|
|
4007
|
+
bands?: [ChartBand] | [ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand, ChartBand, ChartBand] | [ChartBand, ChartBand, ChartBand, ChartBand, ChartBand, ChartBand];
|
|
3558
4008
|
axisTitles?: ChartAxisTitles;
|
|
3559
4009
|
/**
|
|
3560
4010
|
* Optional legend position. 'none' hides the legend. Absent leaves it to the engines: a line chart of two to four series names its series at the line ends and a pie or one-series doughnut names its slices, with no legend; a column, bar, area or combo chart of two to four series shows its legend in the header row above the plot; other multi-series charts and pie and doughnut charts take a legend at the physical right; a single-series chart takes none. A named position shows the legend there even for a single-series chart; 'left' and 'right' are physical sides in every language. Of the Office 2016 constructs only box-and-whisker takes a legend; histogram, pareto, waterfall, funnel, treemap and world drop the option with a 'chart-option-adapted' diagnostic.
|
|
@@ -3586,9 +4036,9 @@ interface Table1 {
|
|
|
3586
4036
|
*/
|
|
3587
4037
|
columns?: (string | TextRun[] | StyledTableCell | DataColumn | null)[];
|
|
3588
4038
|
/**
|
|
3589
|
-
* Two-dimensional table row data; each row aligns by index with columns when columns are supplied.
|
|
4039
|
+
* Two-dimensional table row data; each row aligns by index with columns when columns are supplied. A row is an array of cells, or an object { "id", "cells" } when it needs an id; both forms may mix in one table. `tableRows` in the core package returns every row in one form.
|
|
3590
4040
|
*/
|
|
3591
|
-
rows?:
|
|
4041
|
+
rows?: TableRow[];
|
|
3592
4042
|
/**
|
|
3593
4043
|
* Id of a top-level dataset that supplies this table's headers, rows and column formats. Excludes 'rows' and 'columns'. An unknown id is a 'dataset-unknown' error.
|
|
3594
4044
|
*/
|
|
@@ -3607,9 +4057,10 @@ interface Table1 {
|
|
|
3607
4057
|
*/
|
|
3608
4058
|
rows: string[];
|
|
3609
4059
|
};
|
|
4060
|
+
colorScale?: TableColorScale;
|
|
3610
4061
|
}
|
|
3611
4062
|
/**
|
|
3612
|
-
* Arrangement within this group. Only
|
|
4063
|
+
* Arrangement within this group. Only minFontSizePx, maxFontSizePx and overflow inherit from the parent; strict overflow cannot be weakened.
|
|
3613
4064
|
*/
|
|
3614
4065
|
interface Composition {
|
|
3615
4066
|
/**
|
|
@@ -3638,11 +4089,11 @@ interface Composition {
|
|
|
3638
4089
|
/**
|
|
3639
4090
|
* Minimum readable text size in reference pixels at a 720-pixel canvas short edge. Default 16. Overflow is diagnosed when text cannot fit at this size.
|
|
3640
4091
|
*/
|
|
3641
|
-
|
|
4092
|
+
minFontSizePx?: number;
|
|
3642
4093
|
/**
|
|
3643
|
-
* Largest body text size in reference pixels at a 720-pixel canvas short edge: paragraphs, lists, quotes, metrics and timelines are never set larger, their growth included (headings, tables, code and charts keep their sizes). Never lowers text under
|
|
4094
|
+
* Largest body text size in reference pixels at a 720-pixel canvas short edge: paragraphs, lists, quotes, metrics and timelines are never set larger, their growth included (headings, tables, code and charts keep their sizes). Never lowers text under minFontSizePx. paginate writes it on the pages after the first, so the pages of one slide share its type sizes.
|
|
3644
4095
|
*/
|
|
3645
|
-
|
|
4096
|
+
maxFontSizePx?: number;
|
|
3646
4097
|
/**
|
|
3647
4098
|
* warn returns diagnostics for content that does not fit; error rejects layout. Content is never silently removed. Default warn.
|
|
3648
4099
|
*/
|
|
@@ -3853,7 +4304,7 @@ interface OverlayShape {
|
|
|
3853
4304
|
*/
|
|
3854
4305
|
hidden?: boolean;
|
|
3855
4306
|
/**
|
|
3856
|
-
*
|
|
4307
|
+
* Link followed when the shape is clicked in a slide show (a:hlinkClick): an http(s) URL, a 'mailto:' address, a 'tel:' number or 'slide:<id>', a jump to the slide of this deck with that id (ppaction://hlinksldjump). An unknown slide id is a validation error (opf/slide-link-unknown).
|
|
3857
4308
|
*/
|
|
3858
4309
|
link?: string;
|
|
3859
4310
|
/**
|
|
@@ -4052,7 +4503,7 @@ interface Design1 {
|
|
|
4052
4503
|
mirror?: boolean;
|
|
4053
4504
|
}
|
|
4054
4505
|
/**
|
|
4055
|
-
* Automatic slide and content-group arrangement. Nested content groups arrange their children independently, inheriting only
|
|
4506
|
+
* Automatic slide and content-group arrangement. Nested content groups arrange their children independently, inheriting only minFontSizePx, maxFontSizePx and overflow. Blocks placed in cells (ContentPayload.region on a slide without a layout) retain their positions. A layout defines its grid as one ordered list of regions; its composition supports gap, padding, minFontSizePx, maxFontSizePx and overflow rather than mode, columns or weights.
|
|
4056
4507
|
*
|
|
4057
4508
|
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
4058
4509
|
* via the `definition` "Composition".
|
|
@@ -4084,11 +4535,11 @@ interface Composition1 {
|
|
|
4084
4535
|
/**
|
|
4085
4536
|
* Minimum readable text size in reference pixels at a 720-pixel canvas short edge. Default 16. Overflow is diagnosed when text cannot fit at this size.
|
|
4086
4537
|
*/
|
|
4087
|
-
|
|
4538
|
+
minFontSizePx?: number;
|
|
4088
4539
|
/**
|
|
4089
|
-
* Largest body text size in reference pixels at a 720-pixel canvas short edge: paragraphs, lists, quotes, metrics and timelines are never set larger, their growth included (headings, tables, code and charts keep their sizes). Never lowers text under
|
|
4540
|
+
* Largest body text size in reference pixels at a 720-pixel canvas short edge: paragraphs, lists, quotes, metrics and timelines are never set larger, their growth included (headings, tables, code and charts keep their sizes). Never lowers text under minFontSizePx. paginate writes it on the pages after the first, so the pages of one slide share its type sizes.
|
|
4090
4541
|
*/
|
|
4091
|
-
|
|
4542
|
+
maxFontSizePx?: number;
|
|
4092
4543
|
/**
|
|
4093
4544
|
* warn returns diagnostics for content that does not fit; error rejects layout. Content is never silently removed. Default warn.
|
|
4094
4545
|
*/
|
|
@@ -4110,18 +4561,18 @@ interface Reference {
|
|
|
4110
4561
|
*/
|
|
4111
4562
|
text: (string | TextRun[]);
|
|
4112
4563
|
/**
|
|
4113
|
-
* Optional link for the reference
|
|
4564
|
+
* Optional link for the reference: an http(s) URL, a 'mailto:' address or a 'tel:' number. A references slide links its entry to it.
|
|
4114
4565
|
*/
|
|
4115
|
-
|
|
4566
|
+
link?: string;
|
|
4116
4567
|
}
|
|
4117
4568
|
/**
|
|
4118
|
-
* Optional shared data tables, keyed by id. A chart ('chart.data': { "dataset": "<id>" }) or a table ('table': { "dataset": "<id>" }) references one instead of holding its own copy; engines inline the reference before composing, rendering or exporting. A dataset nothing references is the warning opf/unused-dataset. See docs/chart-table-data.md.
|
|
4569
|
+
* Optional shared data tables, keyed by id. A chart ('chart.data': { "dataset": "<id>" }) or a table ('table': { "dataset": "<id>" }) references one instead of holding its own copy; engines inline the reference before composing, rendering or exporting. A dataset nothing references is the warning opf/unused-dataset. A dataset says where it came from with 'datasource', 'query', 'retrieved', 'version', 'sha256' and 'generator' (see 'datasources'). See docs/chart-table-data.md.
|
|
4119
4570
|
*/
|
|
4120
4571
|
interface Datasets {
|
|
4121
4572
|
[k: string]: Dataset;
|
|
4122
4573
|
}
|
|
4123
4574
|
/**
|
|
4124
|
-
* One shared data table: named columns (strings or
|
|
4575
|
+
* One shared data table: named columns (strings or DatasetColumn objects with a number format, a type, a role and a unit) and rows of scalar cells. Column names are unique ('data-column-duplicate' error). Rich text and styling belong in an inline table.
|
|
4125
4576
|
*
|
|
4126
4577
|
* This interface was referenced by `Presentation`'s JSON-Schema
|
|
4127
4578
|
* via the `definition` "Dataset".
|
|
@@ -4136,47 +4587,27 @@ interface Dataset {
|
|
|
4136
4587
|
*/
|
|
4137
4588
|
description?: string;
|
|
4138
4589
|
/**
|
|
4139
|
-
* Ordered, uniquely named columns.
|
|
4590
|
+
* Ordered, uniquely named columns. A column may declare what its cells hold (type), what it is for (role) and a unit label; a string column declares nothing.
|
|
4140
4591
|
*
|
|
4141
4592
|
* @minItems 1
|
|
4142
4593
|
*/
|
|
4143
|
-
columns: [(string |
|
|
4594
|
+
columns: [(string | DatasetColumn), ...((string | DatasetColumn))[]];
|
|
4144
4595
|
/**
|
|
4145
4596
|
* Rows of scalar cells (string, number, boolean, null); each row aligns by index with columns.
|
|
4146
4597
|
*/
|
|
4147
4598
|
rows: ChartDataCell[][];
|
|
4148
|
-
|
|
4599
|
+
datasource?: DataSourceChoice;
|
|
4600
|
+
query?: DataQuery;
|
|
4601
|
+
retrieved?: DataRetrieved;
|
|
4602
|
+
version?: DataVersion;
|
|
4603
|
+
sha256?: DataSha256;
|
|
4604
|
+
generator?: DataGenerator;
|
|
4149
4605
|
}
|
|
4150
4606
|
/**
|
|
4151
|
-
* Optional
|
|
4607
|
+
* Optional data sources, keyed by id: the places data comes from (a warehouse, a workbook, an API), described once. A dataset or inline chart data names one with 'datasource': "<id>" and records what it took, when and by whom beside its own columns and rows. A data source never holds credentials. Engines never read, fetch or refresh a data source; they keep the entries through editing, export and re-import. An unknown id is the error opf/datasource-unknown. See docs/data-sources.md.
|
|
4152
4608
|
*/
|
|
4153
|
-
interface
|
|
4154
|
-
|
|
4155
|
-
* Where the data came from: an 'asset:<id>' reference, a URL, or a relative or local path.
|
|
4156
|
-
*/
|
|
4157
|
-
src: string;
|
|
4158
|
-
/**
|
|
4159
|
-
* Sheet or table name inside a spreadsheet source.
|
|
4160
|
-
*/
|
|
4161
|
-
sheet?: string;
|
|
4162
|
-
/**
|
|
4163
|
-
* A1-style range inside a spreadsheet source.
|
|
4164
|
-
*/
|
|
4165
|
-
range?: string;
|
|
4166
|
-
/**
|
|
4167
|
-
* The source fields the data was taken from, in order.
|
|
4168
|
-
*/
|
|
4169
|
-
fields?: string[];
|
|
4170
|
-
/**
|
|
4171
|
-
* When the data was taken from the source: an ISO 8601 date or date-time.
|
|
4172
|
-
*/
|
|
4173
|
-
retrieved?: ({
|
|
4174
|
-
[k: string]: unknown;
|
|
4175
|
-
} & string);
|
|
4176
|
-
/**
|
|
4177
|
-
* Free-form note about the source.
|
|
4178
|
-
*/
|
|
4179
|
-
description?: string;
|
|
4609
|
+
interface DataSources {
|
|
4610
|
+
[k: string]: DataSource;
|
|
4180
4611
|
}
|
|
4181
4612
|
/**
|
|
4182
4613
|
* Optional reusable asset registry for images, data files, videos, documents, fonts, and other resources referenced elsewhere in the deck via 'asset:<id>' strings.
|