@office-kit/pptx 0.18.5 → 0.21.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/CHANGELOG.md CHANGED
@@ -1,5 +1,53 @@
1
1
  # @office-kit/pptx
2
2
 
3
+ ## 0.21.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 28731c2: feat(charts): `ChartSpec` is now a union over `kind`, so a chart cannot be given a field it has no element for
8
+
9
+ Every chart kind carries only the fields its OOXML element defines. A
10
+ `scatterStyle` on a column chart, an axis title on a pie, `bar3DShape`
11
+ without `view3D`, a scatter series with no `xValues` — each of these used to
12
+ either throw at save time or serialize into nothing. They are now type errors
13
+ at the call site.
14
+
15
+ `getShapeChartSpec` and `SlideChartData.spec` return the new `ReadChartSpec`,
16
+ which keeps every field optional: a deck authored elsewhere can combine
17
+ fields no kind draws, and dropping them on read would lose data. Narrow one
18
+ back to the write side with `isChartSpec` before passing it to
19
+ `addSlideChart` / `setChartSpec`.
20
+
21
+ Two behaviour fixes came out of the change:
22
+
23
+ - A 3-D line chart no longer reports `lineMarkers: false` on read.
24
+ `<c:line3DChart>` has no `<c:marker>` element, so the value was meaningless.
25
+ - Pie and doughnut charts no longer get the deck's body-text colour written
26
+ onto axis-label styles they have no axes to show.
27
+
28
+ ## 0.20.0
29
+
30
+ ### Minor Changes
31
+
32
+ - 04eda82: Colors are now a type, not a string. `Color` (`#RRGGBB`, the `#RGB` shorthand, a theme token such as `accent1`, or the `scheme:`-prefixed form) replaces `string` on every authoring call that takes one — shape and table fills, slide backgrounds, strokes, shadows, glows, gradient stops, connectors and run formats — so `'reddish'` or a mistyped `'accnet1'` is a compile error instead of a run-time throw. Chart colors take `HexColor`, which enforces what the docs already said: a chart series must resolve to a concrete sRGB value and cannot carry a theme token.
33
+
34
+ The `#` is now required. Bare `RRGGBB` was one of four accepted spellings of the same thing, and admitting it collapsed the union back to `string`, taking every other color check down with it. The runtime parser still accepts it, so untyped JavaScript callers are unaffected.
35
+
36
+ `@office-kit/pptx-dsl` picks this up too: `fill`, `stroke`, `background`, `stripeFill` and cell borders are typed the same way, so a bad color in a TSX deck fails `npm run check` rather than the export.
37
+
38
+ Reading stays permissive, since a deck authored elsewhere can carry a scheme token outside its theme. `getShapeRunFormat` and friends now return `ReadTextFormat`, and the gradient readers return `ReadGradientFill` / `ReadGradientStop` — same shapes, with colors as `string`. To write a color you read back, pass it through the new `asColor`, which returns `null` when the value is not one this library can emit.
39
+
40
+ ## 0.19.0
41
+
42
+ ### Minor Changes
43
+
44
+ - 3eecc92: Rename `setShapeBullets` to `setShapeBulletStyle`. The old plural name read like it set the list's _content_, so calls meant to create a bulleted list reached for it and silently got back an unchanged, text-less shape. The new name says what the function actually does: it restyles the bullet glyph on paragraphs that already exist. Bulleted text is still authored in one call — `setShapeText(shape, 'A\nB\nC', { bullets: 'bullet' })`.
45
+ - cb702c1: Placeholder lookups and slide transitions now reject an unknown token at compile time instead of at runtime.
46
+
47
+ `findSlidePlaceholder`, `findSlidePlaceholders` and `findLayoutsWithPlaceholderType` take the closed `ST_PlaceholderType` set (exported as `PlaceholderType`) rather than `string`, so a shape's display name or a typo no longer type-checks and then silently finds nothing. `setSlidePlaceholders` keys its `byType` record the same way, so a misspelled key is no longer skipped in silence.
48
+
49
+ `TransitionEffect` gains the five spec effects it was missing — `comb`, `pull`, `random`, `strips` and `wheel` — and `TransitionOptions.effect` drops its `| string` escape, so a mistyped effect is a type error rather than a runtime throw. Reading stays permissive: `getSlideTransition` returns the new `SlideTransition` type, whose `effect` is still `string`, because a deck authored elsewhere can carry an effect this library does not model.
50
+
3
51
  ## 0.18.5
4
52
 
5
53
  ### Patch Changes
package/README.md CHANGED
@@ -7,6 +7,7 @@
7
7
  Read, edit, and write `.pptx` (PowerPoint / Office Open XML Presentation) files
8
8
  from TypeScript, in **Node.js and the browser**, from a single ESM bundle.
9
9
 
10
+ **[Create slides with AI](#create-slides-with-ai-and-live-preview)** ·
10
11
  **[Documentation](https://office-kit.github.io/pptx/)** ·
11
12
  **[Playground](https://office-kit.github.io/pptx/playground)** (inspect a deck in your browser) ·
12
13
  **[REPL](https://office-kit.github.io/pptx/repl)** (write code, watch the deck redraw)
@@ -26,17 +27,48 @@ const out: Uint8Array = await savePresentation(pres);
26
27
  > not frozen: a breaking change can land in a minor (`0.x`) release, so pin a
27
28
  > version or an exact range.
28
29
 
29
- ## Why this library
30
+ ## Create slides with AI and live preview
31
+
32
+ Create presentations in TSX with a live browser preview and Claude Code or Codex
33
+ beside the slide. Select an area and ask the agent to change it, edit text
34
+ directly, and export an editable PowerPoint file. Changes are saved in the TSX
35
+ source; saving a source file also updates the preview.
36
+
37
+ Requires Node.js 22.18 or later. Create a project and start the preview in one
38
+ command (macOS/Linux):
30
39
 
31
- For declarative TSX authoring, use the companion
32
- [`@office-kit/pptx-dsl`](packages/dsl) and
33
- [`@office-kit/pptx-dev`](packages/dev) packages. They provide typed elements,
34
- template editing, a local watch preview and PPTX export, with no React or Vue
35
- runtime. The dev package initializes a project with VSCode tasks and a
36
- `CLAUDE.md` authoring guide. Start with the
37
- [authoring guide](https://office-kit.github.io/pptx/docs/authoring): install the
38
- Claude Code skill and describe your presentation. The agent handles project
39
- setup, preview and export using the published npm packages.
40
+ ```sh
41
+ npx --yes @office-kit/pptx-dev@latest init my-slides && cd my-slides && npm install && npm run dev
42
+ ```
43
+
44
+ Open the local URL printed by the server. The generated project includes
45
+ `deck.tsx`, individual slides, a shared theme and a `CLAUDE.md` authoring guide.
46
+ For later sessions, run this inside the project:
47
+
48
+ ```sh
49
+ npx office-pptx dev deck.tsx
50
+ ```
51
+
52
+ `npm run dev` starts the same preview. To update an existing project's dev tools,
53
+ stop the server, then run:
54
+
55
+ ```sh
56
+ npm install -D @office-kit/pptx-dev@latest
57
+ npm run dev
58
+ ```
59
+
60
+ Run `npm run check` to type-check the deck and `npm run build` to export
61
+ `deck.pptx`. AI editing uses your locally installed and authenticated Claude Code
62
+ or Codex CLI. After edits, changed-slide screenshots are supplied to the agent
63
+ for design review; capture requires Chrome or Playwright Chromium.
64
+
65
+ See the [preview and agent setup](packages/dev/README.md),
66
+ [selection, text editing and visual review](packages/dev/README.md#edit-from-the-slide),
67
+ and [TSX element reference](packages/dsl/README.md). To let Claude Code handle
68
+ project setup as well, follow the
69
+ [skill installation guide](https://office-kit.github.io/pptx/docs/authoring).
70
+
71
+ ## Why this library
40
72
 
41
73
  - **It reads as well as it writes.** Open a deck made in PowerPoint, Keynote,
42
74
  or Google Slides, change it, and save it. Every setter has a getter, and
@@ -591,7 +623,7 @@ shown together.
591
623
  | Comments | `addSlideComment`, `getSlideComments`, `removeSlideComment`, `getCommentAuthors`, `getCommentText` / `getCommentAuthor` / `getCommentPosition` |
592
624
  | Shape authoring | `addSlideTextBox`, `addSlideShape`, `addSlideLine`, `addSlideTable`, `addSlideImage`, `addSlideMedia`, `addSlideChart` |
593
625
  | Shape lookup | `findShapeByName`, `findShapesByName`, `findShapesByKind`, `findShapeInPresentation`, `getAllShapes`, `getSlideShapes` |
594
- | Shape text | `setShapeText`, `setShapeParagraphs`, `setShapeBullets`, `setShapeAlignment`, `setShapeTextFormat`, `setShapeHyperlink` / `getShapeHyperlink` |
626
+ | Shape text | `setShapeText`, `setShapeParagraphs`, `setShapeBulletStyle`, `setShapeAlignment`, `setShapeTextFormat`, `setShapeHyperlink` / `getShapeHyperlink` |
595
627
  | Per-paragraph | `setParagraphAlignment` / `getParagraphAlignment`, `setParagraphLevel` / `getParagraphLevel`, `setParagraphBullet` / `getParagraphBullet`, `setParagraphSpacing` / `getParagraphSpacing`, `setParagraphLineSpacing` / `getParagraphLineSpacing`, `getParagraphEndFormat` |
596
628
  | Per-run text | `setShapeRunText` / `getShapeRunText`, `setShapeRunFormat` / `getShapeRunFormat`, `getShapeParagraphCount`, `getShapeRunCount` |
597
629
  | Text frame | `setShapeTextAnchor` / `getShapeTextAnchor`, `setShapeTextMargins` / `getShapeTextMargins` |
@@ -2071,6 +2071,16 @@ const buildColorElement = (value) => {
2071
2071
  if (parsed === null) throw new Error(`unrecognized color: ${value}`);
2072
2072
  return parsed.kind === "srgb" ? elem(NAME_SRGB_CLR$4, { attrs: [attr(ATTR_VAL$9, parsed.hex)] }) : elem(NAME_SCHEME_CLR$2, { attrs: [attr(ATTR_VAL$9, parsed.token)] });
2073
2073
  };
2074
+ /**
2075
+ * Narrows a color read back from a deck to one that can be written again,
2076
+ * or `null` when it is not a color this library can emit.
2077
+ *
2078
+ * The readers surface `<a:schemeClr val>` verbatim, so a round-trip
2079
+ * (`setX(getX(...))`) has to pass through a check somewhere; doing it here
2080
+ * keeps that single `Color` assertion backed by the same parser that
2081
+ * `buildColorElement` uses.
2082
+ */
2083
+ const asColor = (value) => parseColor(value) === null ? null : value;
2074
2084
  //#endregion
2075
2085
  //#region src/internal/drawingml/text-format.ts
2076
2086
  NS.dml;
@@ -2512,7 +2522,7 @@ const applyBulletToParagraph = (paragraph, style) => {
2512
2522
  applyNormalizedBullet(paragraph, normalizeBulletStyle(style, "setParagraphBullet"));
2513
2523
  };
2514
2524
  const applyBulletToAllParagraphs = (txBody, style) => {
2515
- const normalized = normalizeBulletStyle(style, "setShapeBullets");
2525
+ const normalized = normalizeBulletStyle(style, "setShapeBulletStyle");
2516
2526
  for (const p of txBody.children) {
2517
2527
  if (p.kind !== "element" || p.name.namespaceURI !== NAME_P_FOR_BULLET.namespaceURI || p.name.localName !== "p") continue;
2518
2528
  applyNormalizedBullet(p, normalized);
@@ -4488,6 +4498,35 @@ const ATTR_ADV_TM = qname("", "advTm", "");
4488
4498
  const ATTR_DIR = qname("", "dir", "");
4489
4499
  const ATTR_ORIENT = qname("", "orient", "");
4490
4500
  const ATTR_THRU_BLK = qname("", "thruBlk", "");
4501
+ /**
4502
+ * Every transition effect element name in `CT_SlideTransition`'s choice
4503
+ * (ECMA-376 pml.xsd). The token is emitted verbatim as `<p:{token}/>`, so this
4504
+ * list is both the type's domain and the write-time validation domain —
4505
+ * keeping them one declaration stops them drifting apart.
4506
+ */
4507
+ const TRANSITION_EFFECTS = [
4508
+ "blinds",
4509
+ "checker",
4510
+ "circle",
4511
+ "dissolve",
4512
+ "comb",
4513
+ "cover",
4514
+ "cut",
4515
+ "diamond",
4516
+ "fade",
4517
+ "newsflash",
4518
+ "plus",
4519
+ "pull",
4520
+ "push",
4521
+ "random",
4522
+ "randomBar",
4523
+ "split",
4524
+ "strips",
4525
+ "wedge",
4526
+ "wheel",
4527
+ "wipe",
4528
+ "zoom"
4529
+ ];
4491
4530
  const DIR_ORIENT = new Set(["horz", "vert"]);
4492
4531
  const DIR_SIDE = new Set([
4493
4532
  "l",
@@ -4517,29 +4556,6 @@ const DIR_DOMAINS = {
4517
4556
  split: DIR_IN_OUT
4518
4557
  };
4519
4558
  const THRU_BLK_EFFECTS = new Set(["fade", "cut"]);
4520
- const TRANSITION_EFFECTS = [
4521
- "blinds",
4522
- "checker",
4523
- "circle",
4524
- "dissolve",
4525
- "comb",
4526
- "cover",
4527
- "cut",
4528
- "diamond",
4529
- "fade",
4530
- "newsflash",
4531
- "plus",
4532
- "pull",
4533
- "push",
4534
- "random",
4535
- "randomBar",
4536
- "split",
4537
- "strips",
4538
- "wedge",
4539
- "wheel",
4540
- "wipe",
4541
- "zoom"
4542
- ];
4543
4559
  const buildEffectElement = (opts) => {
4544
4560
  if (opts.effect === "none") return null;
4545
4561
  const name = qname("p", oneOf(opts.effect, TRANSITION_EFFECTS, "setSlideTransition: effect"), NS.pml);
@@ -6083,6 +6099,244 @@ const validateChartSpecEnums = (spec, caller) => {
6083
6099
  }
6084
6100
  };
6085
6101
  //#endregion
6102
+ //#region src/internal/chartml/chart-spec.ts
6103
+ /** Fields every chart kind carries. */
6104
+ const COMMON_FIELDS = [
6105
+ "categories",
6106
+ "title",
6107
+ "titleStyle",
6108
+ "titleOverlay",
6109
+ "titleLayout",
6110
+ "dataLabels",
6111
+ "legend",
6112
+ "plotAreaLayout",
6113
+ "plotAreaFill",
6114
+ "plotAreaStrokeColor",
6115
+ "chartAreaFill",
6116
+ "chartAreaStrokeColor",
6117
+ "plotVisibleCellsOnly",
6118
+ "dispBlanksAs",
6119
+ "date1904",
6120
+ "language",
6121
+ "roundedCorners",
6122
+ "chartStyle",
6123
+ "varyColors"
6124
+ ];
6125
+ /** `<c:valAx>` — on every kind but the axis-less pie / doughnut. */
6126
+ const VALUE_AXIS_FIELDS = [
6127
+ "valueAxis",
6128
+ "valueAxisTitle",
6129
+ "valueAxisTitleStyle",
6130
+ "valueAxisTitleRotationDeg",
6131
+ "valueAxisLabelStyle",
6132
+ "valueAxisLabelRotationDeg",
6133
+ "valueAxisHidden",
6134
+ "valueAxisMajorGridlines",
6135
+ "valueAxisMinorGridlines",
6136
+ "valueAxisMajorGridlineColor",
6137
+ "valueAxisMinorGridlineColor",
6138
+ "valueAxisMajorGridlineWidthEmu",
6139
+ "valueAxisMinorGridlineWidthEmu",
6140
+ "valueAxisMajorTickMark",
6141
+ "valueAxisMinorTickMark",
6142
+ "valueAxisTickLabelPos",
6143
+ "valueAxisLineColor",
6144
+ "valueAxisLineWidthEmu",
6145
+ "valueAxisLineHidden",
6146
+ "valueAxisOrientation",
6147
+ "valueAxisCrosses",
6148
+ "valueAxisCrossBetween"
6149
+ ];
6150
+ /**
6151
+ * The horizontal axis. One set of fields drives `<c:catAx>` on a category
6152
+ * chart and the x-channel `<c:valAx>` of a scatter / bubble chart.
6153
+ */
6154
+ const HORIZONTAL_AXIS_FIELDS = [
6155
+ "categoryAxisTitle",
6156
+ "categoryAxisTitleStyle",
6157
+ "categoryAxisTitleRotationDeg",
6158
+ "categoryAxisLabelStyle",
6159
+ "categoryAxisLabelRotationDeg",
6160
+ "categoryAxisHidden",
6161
+ "categoryAxisMajorGridlines",
6162
+ "categoryAxisMinorGridlines",
6163
+ "categoryAxisMajorGridlineColor",
6164
+ "categoryAxisMinorGridlineColor",
6165
+ "categoryAxisMajorGridlineWidthEmu",
6166
+ "categoryAxisMinorGridlineWidthEmu",
6167
+ "categoryAxisMajorTickMark",
6168
+ "categoryAxisMinorTickMark",
6169
+ "categoryAxisTickLabelPos",
6170
+ "categoryAxisLineColor",
6171
+ "categoryAxisLineWidthEmu",
6172
+ "categoryAxisLineHidden",
6173
+ "categoryAxisOrientation",
6174
+ "categoryAxisNumberFormat"
6175
+ ];
6176
+ /** Tick and label controls only a discrete category axis has. */
6177
+ const CATEGORY_AXIS_FIELDS = [
6178
+ "categoryAxisTickLabelSkip",
6179
+ "categoryAxisTickMarkSkip",
6180
+ "categoryAxisLabelOffset",
6181
+ "categoryAxisLabelAlign",
6182
+ "categoryAxisNoMultiLevelLabel"
6183
+ ];
6184
+ /** The three fields {@link CategoryAxisMode} arbitrates between. */
6185
+ const CATEGORY_MODE_FIELDS = [
6186
+ "categoryAxisDate",
6187
+ "categoryAxisScaling",
6188
+ "categoryGroupLevels"
6189
+ ];
6190
+ /** Every field of a chart that has axes. */
6191
+ const AXIS_CHART_FIELDS = [
6192
+ ...COMMON_FIELDS,
6193
+ ...VALUE_AXIS_FIELDS,
6194
+ ...HORIZONTAL_AXIS_FIELDS
6195
+ ];
6196
+ /** Every field of a chart drawn against a discrete category axis. */
6197
+ const CATEGORY_CHART_FIELDS = [
6198
+ ...AXIS_CHART_FIELDS,
6199
+ ...CATEGORY_AXIS_FIELDS,
6200
+ ...CATEGORY_MODE_FIELDS,
6201
+ "dataTable"
6202
+ ];
6203
+ /** Per-variant field sets; the variant types below are derived from these. */
6204
+ const VARIANT_FIELDS = {
6205
+ combo: [
6206
+ ...CATEGORY_CHART_FIELDS,
6207
+ "grouping",
6208
+ "gapWidthPct",
6209
+ "overlapPct",
6210
+ "dropLines",
6211
+ "hiLowLines",
6212
+ "lineMarkers",
6213
+ "upDownBars",
6214
+ "secondaryValueAxis"
6215
+ ],
6216
+ bar3D: [
6217
+ ...CATEGORY_CHART_FIELDS,
6218
+ "grouping",
6219
+ "gapWidthPct",
6220
+ "gapDepthPct",
6221
+ "bar3DShape",
6222
+ "seriesAxis",
6223
+ "view3D"
6224
+ ],
6225
+ lineArea3D: [
6226
+ ...CATEGORY_CHART_FIELDS,
6227
+ "grouping",
6228
+ "dropLines",
6229
+ "gapDepthPct",
6230
+ "seriesAxis",
6231
+ "view3D"
6232
+ ],
6233
+ pie: [...COMMON_FIELDS, "firstSliceAngleDeg"],
6234
+ ofPie: [...COMMON_FIELDS, "ofPie"],
6235
+ pie3D: [...COMMON_FIELDS, "view3D"],
6236
+ doughnut: [
6237
+ ...COMMON_FIELDS,
6238
+ "firstSliceAngleDeg",
6239
+ "holeSizePct"
6240
+ ],
6241
+ scatter: [
6242
+ ...AXIS_CHART_FIELDS,
6243
+ "categoryAxisScaling",
6244
+ "scatterStyle"
6245
+ ],
6246
+ bubble: [
6247
+ ...AXIS_CHART_FIELDS,
6248
+ "categoryAxisScaling",
6249
+ "bubbleScale",
6250
+ "bubbleSizeRepresents",
6251
+ "bubble3D",
6252
+ "showNegativeBubbles"
6253
+ ],
6254
+ radar: [...CATEGORY_CHART_FIELDS, "radarStyle"],
6255
+ stock: [
6256
+ ...CATEGORY_CHART_FIELDS,
6257
+ "dropLines",
6258
+ "hiLowLines"
6259
+ ],
6260
+ candlestick: [
6261
+ ...CATEGORY_CHART_FIELDS,
6262
+ "dropLines",
6263
+ "hiLowLines",
6264
+ "upDownBars"
6265
+ ],
6266
+ surface: [
6267
+ ...CATEGORY_CHART_FIELDS,
6268
+ "surfaceContour",
6269
+ "surfaceWireframe",
6270
+ "view3D",
6271
+ "seriesAxis"
6272
+ ]
6273
+ };
6274
+ const fieldSet = (fields) => new Set(fields);
6275
+ const VARIANT_FIELD_SETS = {
6276
+ combo: fieldSet(VARIANT_FIELDS.combo),
6277
+ bar3D: fieldSet(VARIANT_FIELDS.bar3D),
6278
+ lineArea3D: fieldSet(VARIANT_FIELDS.lineArea3D),
6279
+ pie: fieldSet(VARIANT_FIELDS.pie),
6280
+ ofPie: fieldSet(VARIANT_FIELDS.ofPie),
6281
+ pie3D: fieldSet(VARIANT_FIELDS.pie3D),
6282
+ doughnut: fieldSet(VARIANT_FIELDS.doughnut),
6283
+ scatter: fieldSet(VARIANT_FIELDS.scatter),
6284
+ bubble: fieldSet(VARIANT_FIELDS.bubble),
6285
+ radar: fieldSet(VARIANT_FIELDS.radar),
6286
+ stock: fieldSet(VARIANT_FIELDS.stock),
6287
+ candlestick: fieldSet(VARIANT_FIELDS.candlestick),
6288
+ surface: fieldSet(VARIANT_FIELDS.surface)
6289
+ };
6290
+ /**
6291
+ * Which arm of {@link ChartSpec} a spec would inhabit, from the fields that
6292
+ * pick the OOXML element. It says nothing about whether the rest of the
6293
+ * spec fits — {@link isChartSpec} decides that.
6294
+ */
6295
+ const chartVariant = (spec) => {
6296
+ switch (spec.kind) {
6297
+ case "bar":
6298
+ case "column": return spec.view3D !== void 0 ? "bar3D" : "combo";
6299
+ case "line":
6300
+ case "area": return spec.view3D !== void 0 ? "lineArea3D" : "combo";
6301
+ case "pie":
6302
+ if (spec.view3D !== void 0) return "pie3D";
6303
+ return spec.ofPie !== void 0 ? "ofPie" : "pie";
6304
+ case "stock": return spec.series.length === 4 ? "candlestick" : "stock";
6305
+ default: return spec.kind;
6306
+ }
6307
+ };
6308
+ const SINGLE_SERIES_VARIANTS = new Set([
6309
+ "pie",
6310
+ "ofPie",
6311
+ "pie3D",
6312
+ "doughnut"
6313
+ ]);
6314
+ const seriesFits = (spec, variant) => {
6315
+ if (SINGLE_SERIES_VARIANTS.has(variant) && spec.series.length !== 1) return false;
6316
+ if (variant === "stock" && spec.series.length !== 3) return false;
6317
+ if (variant === "candlestick" && spec.series.length !== 4) return false;
6318
+ const wantsX = variant === "scatter" || variant === "bubble";
6319
+ return spec.series.every((series) => series.xValues !== void 0 === wantsX && series.bubbleSizes !== void 0 === (variant === "bubble") && (variant === "combo" || series.chartKind === void 0 && series.secondaryAxis === void 0));
6320
+ };
6321
+ /**
6322
+ * Whether a spec read back from a deck also inhabits the write-side
6323
+ * {@link ChartSpec}. A deck authored elsewhere can combine fields no kind
6324
+ * draws, so a read-modify-write pass has to narrow before it writes.
6325
+ */
6326
+ const isChartSpec = (spec) => {
6327
+ const variant = chartVariant(spec);
6328
+ const allowed = VARIANT_FIELD_SETS[variant];
6329
+ for (const [field, value] of Object.entries(spec)) {
6330
+ if (field === "kind" || field === "series" || value === void 0) continue;
6331
+ if (!allowed.has(field)) return false;
6332
+ }
6333
+ if (spec.categoryAxisDate === void 0) {
6334
+ if (spec.categoryAxisScaling !== void 0 && spec.kind !== "scatter" && spec.kind !== "bubble") return false;
6335
+ } else if (spec.categoryGroupLevels !== void 0) return false;
6336
+ return seriesFits(spec, variant);
6337
+ };
6338
+ new Set(Object.values(VARIANT_FIELDS).flat());
6339
+ //#endregion
6086
6340
  //#region src/internal/chartml/embedded-xlsx.ts
6087
6341
  const TEXT_ENCODER = new TextEncoder();
6088
6342
  const encode = (s) => TEXT_ENCODER.encode(s);
@@ -6869,17 +7123,15 @@ const buildRadarChart = (g) => elem(c("radarChart"), { children: [
6869
7123
  ...groupDLbls(g),
6870
7124
  ...axIdNodes(g)
6871
7125
  ] });
6872
- const STOCK_SERIES_WITH_OPEN = 4;
6873
- const STOCK_SERIES_WITHOUT_OPEN = 3;
6874
7126
  const buildStockChart = (g) => {
6875
7127
  const { spec } = g;
6876
7128
  const count = spec.series.length;
6877
- if (count !== STOCK_SERIES_WITHOUT_OPEN && count !== STOCK_SERIES_WITH_OPEN) throw new Error(`stock chart requires 3 series (high, low, close) or 4 (open, high, low, close); got ${count}`);
7129
+ if (count !== 3 && count !== 4) throw new Error(`stock chart requires 3 series (high, low, close) or 4 (open, high, low, close); got ${count}`);
6878
7130
  const children = [...groupSeries(g), ...groupDLbls(g)];
6879
7131
  if (spec.dropLines) children.push(elem(c("dropLines")));
6880
7132
  if (spec.hiLowLines !== false) children.push(elem(c("hiLowLines")));
6881
- if (spec.upDownBars !== void 0 && count !== STOCK_SERIES_WITH_OPEN) throw new Error("stock chart: upDownBars require the 4-series form (open, high, low, close)");
6882
- if (count === STOCK_SERIES_WITH_OPEN) children.push(upDownBarsElement(spec.upDownBars ?? {}));
7133
+ if (spec.upDownBars !== void 0 && count !== 4) throw new Error("stock chart: upDownBars require the 4-series form (open, high, low, close)");
7134
+ if (count === 4) children.push(upDownBarsElement(spec.upDownBars ?? {}));
6883
7135
  children.push(...axIdNodes(g));
6884
7136
  return elem(c("stockChart"), { children });
6885
7137
  };
@@ -8141,7 +8393,7 @@ const readCategoryGroupLevels = (cat) => {
8141
8393
  return outer.length > 0 ? outer : void 0;
8142
8394
  };
8143
8395
  /**
8144
- * Parses a `<c:chartSpace>` element into a typed `ChartSpec`. Throws if
8396
+ * Parses a `<c:chartSpace>` element into a typed `ReadChartSpec`. Throws if
8145
8397
  * the root or any required child is missing. Returns `null` only when
8146
8398
  * the chart is structurally well-formed but uses a kind we don't model
8147
8399
  * (so callers can fall through to pass-through).
@@ -8309,7 +8561,7 @@ const readChartSpec = (root) => {
8309
8561
  const dropLines = dropLinesEl !== null ? true : void 0;
8310
8562
  const hiLowLines = hiLowLinesEl !== null ? true : void 0;
8311
8563
  let lineMarkers;
8312
- if (kind === "line") {
8564
+ if (plotted.name.localName === "lineChart") {
8313
8565
  const markerEl = firstChildElement(plotted, qname("c", "marker", NS_C));
8314
8566
  if (markerEl === null) lineMarkers = false;
8315
8567
  else {
@@ -9946,17 +10198,7 @@ const withChartDefaultTextColor = (spec, color) => {
9946
10198
  ...style,
9947
10199
  color
9948
10200
  } : style;
9949
- const hasSecondary = spec.series.some((series) => series.secondaryAxis === true);
9950
- const secondary = spec.secondaryValueAxis ?? {};
9951
- return {
9952
- ...spec,
9953
- categoryAxisLabelStyle: withColor(spec.categoryAxisLabelStyle),
9954
- valueAxisLabelStyle: withColor(spec.valueAxisLabelStyle),
9955
- ...hasSecondary ? { secondaryValueAxis: {
9956
- ...secondary,
9957
- labelStyle: withColor(secondary.labelStyle),
9958
- ...secondary.title !== void 0 ? { titleStyle: withColor(secondary.titleStyle) } : {}
9959
- } } : {},
10201
+ const shared = {
9960
10202
  ...spec.title !== void 0 ? { titleStyle: withColor(spec.titleStyle) } : {},
9961
10203
  ...spec.legend !== void 0 ? { legend: {
9962
10204
  ...spec.legend,
@@ -9967,6 +10209,31 @@ const withChartDefaultTextColor = (spec, color) => {
9967
10209
  textStyle: withColor(spec.dataLabels.textStyle)
9968
10210
  } } : {}
9969
10211
  };
10212
+ if (spec.kind === "pie" || spec.kind === "doughnut") return {
10213
+ ...spec,
10214
+ ...shared
10215
+ };
10216
+ const axisLabels = {
10217
+ categoryAxisLabelStyle: withColor(spec.categoryAxisLabelStyle),
10218
+ valueAxisLabelStyle: withColor(spec.valueAxisLabelStyle)
10219
+ };
10220
+ if (!(spec.view3D === void 0 && (spec.kind === "bar" || spec.kind === "column" || spec.kind === "line" || spec.kind === "area"))) return {
10221
+ ...spec,
10222
+ ...shared,
10223
+ ...axisLabels
10224
+ };
10225
+ const hasSecondary = spec.series.some((series) => series.secondaryAxis === true);
10226
+ const secondary = spec.secondaryValueAxis ?? {};
10227
+ return {
10228
+ ...spec,
10229
+ ...shared,
10230
+ ...axisLabels,
10231
+ ...hasSecondary ? { secondaryValueAxis: {
10232
+ ...secondary,
10233
+ labelStyle: withColor(secondary.labelStyle),
10234
+ ...secondary.title !== void 0 ? { titleStyle: withColor(secondary.titleStyle) } : {}
10235
+ } } : {}
10236
+ };
9970
10237
  };
9971
10238
  const addSlideChart = (slide, opts) => {
9972
10239
  validateChartSpecEnums(opts.spec, "addSlideChart");
@@ -14483,7 +14750,7 @@ const setParagraphAlignment = (shape, paragraphIndex, align) => {
14483
14750
  * Used in tandem with bullets to author nested lists:
14484
14751
  *
14485
14752
  * setShapeText(shape, 'Item 1\nNested\nItem 2');
14486
- * setShapeBullets(shape, 'bullet');
14753
+ * setShapeBulletStyle(shape, 'bullet');
14487
14754
  * setParagraphLevel(shape, 1, 1); // indent the second line
14488
14755
  */
14489
14756
  const setParagraphLevel = (shape, paragraphIndex, level) => {
@@ -14814,7 +15081,7 @@ const getParagraphBulletStyle = (pres, shape, paragraphIndex) => {
14814
15081
  };
14815
15082
  /**
14816
15083
  * Sets the bullet style on a single paragraph. Same `BulletStyle` shape
14817
- * as `setShapeBullets` — pass `'bullet'` / `'number'` / `'none'` or an
15084
+ * as `setShapeBulletStyle` — pass `'bullet'` / `'number'` / `'none'` or an
14818
15085
  * object like `{ char: '◆' }` / `{ autoNum: 'romanLcPeriod' }`.
14819
15086
  */
14820
15087
  const setParagraphBullet = (shape, paragraphIndex, style) => {
@@ -17627,7 +17894,7 @@ const setShapeTextMargins = (shape, margins) => {
17627
17894
  commitAndRefresh(shape);
17628
17895
  };
17629
17896
  /** Sets the bullet style on every paragraph in the shape's text body. */
17630
- const setShapeBullets = (shape, style) => {
17897
+ const setShapeBulletStyle = (shape, style) => {
17631
17898
  applyBulletToAllParagraphs(requireTxBody(shape), style);
17632
17899
  commitAndRefresh(shape);
17633
17900
  };
@@ -19602,8 +19869,8 @@ const getShapeMedia = (shape) => {
19602
19869
  const findShapesWithMedia = (slide) => slide[SLIDE_SHAPES].filter((shape) => getShapeMedia(shape) !== null);
19603
19870
  //#endregion
19604
19871
  //#region src/api/index.ts
19605
- const VERSION = "0.18.5";
19872
+ const VERSION = "0.21.0";
19606
19873
  //#endregion
19607
- export { replaceTokensInPresentation as $, getTableCellAnchor as $a, appendSlideNotes as $i, getShapePreset as $n, getSlideLayoutType as $o, getShapeParagraphCount as $r, findCommentsByAuthor as $s, getShapeStroke as $t, getOutlineText as A, removeSlideNotes as Aa, getShapeImageBiLevelThreshold as Ai, setSlideLayout as An, setTableCellTextFormat as Ao, setShapePatternFill as Ar, getSlideColorMapOverride as As, setShapeText as At, getSlideLayoutCount as B, getPackageSize as Ba, getShapeImagePartName as Bi, getShapeAltTitle as Bn, getPresentationCreated as Bo, getShapeRunFormat as Br, getSlideMasterBackgroundPatternFill as Bs, findShapesByEffect as Bt, setSlideSections as C, getSlidesWithHyperlinks as Ca, emu as Cc, findFlippedShapes as Ci, getShapeSlide as Cn, setTableCellAnchor as Co, setShapeAdjustValues as Cr, getEffectiveColorMap as Cs, getShapeTextColumns as Ct, findSlidesByNotes as D, getSlidesWithTables as Da, findSlidesByLayoutPartName as Di, getSlideShapes as Dn, setTableCellParagraphs as Do, setShapeImageFill as Dr, getSlideBackgroundGradientFill as Ds, setShapeAlignment as Dt, findSlideByTitle as E, getSlidesWithOverlap as Ea, pt as Ec, findSlidesByLayoutName as Ei, getSlideLayout as En, setTableCellMargins as Eo, setShapeGradientFill as Er, getSlideBackground as Es, getShapeTextWrap as Et, getShapeAt as F, setSlideTransition as Fa, getShapeImageDuotone as Fi, getGroupChildren as Fn, getThumbnail as Fo, setShapeStrokeArrow as Fr, getSlideLayoutBackgroundShapes as Fs, setShapeTextDirection as Ft, getSlideXmlString as G, setMediaPartBytes as Ga, setShapeImageContrast as Gi, getShapeDescription as Gn, touchModified as Go, getParagraphBulletImageBytes as Gr, setShapeClickAction as Gs, setShapeShadow as Gt, getSlidePartName as H, getSlideMediaPartNames as Ha, hasShapeText as Hi, getShapeBoundsResolved as Hn, incrementRevision as Ho, resolveDrawingColorOpacity as Hr, setSlideBackground as Hs, getShapeEffects as Ht, getSlideAt as I, _internalPackageOf as Ia, getShapeImageFillBytes as Ii, getGroupTransform as In, removeThumbnail as Io, setShapeStrokeCap as Ir, getSlideLayoutShapes as Is, setShapeTextFormat as It, isSlideHidden as J, clearTableCellFill as Ja, SLIDE_SIZE_16_10 as Ji, getShapeKind as Jn, findSlideLayoutByPartName as Jo, getParagraphIndent as Jr, clearAllSlideComments as Js, getShapeFill as Jt, getSlides as K, slidesUsingMediaPart as Ka, setShapeImageCrop as Ki, getShapeFlip as Kn, findLayoutsWithPlaceholderType as Ko, getParagraphBulletStyle as Kr, setShapeImage as Ks, getShapeGradientFill as Kt, getSlideCount as L, compactPackage as La, getShapeImageFormat as Li, getMaxShapeId as Ln, setThumbnail as Lo, setShapeStrokeCompound as Lr, getSlideMasterBackground as Ls, setShapeTextMargins as Lt, getPresentationText as M, setSlideNotes as Ma, getShapeImageBytes as Mi, centerShapeOnSlide as Mn, setTableRowHeight as Mo, setShapeRotation as Mr, getSlideLayoutBackgroundGradientFill as Ms, setShapeTextAutoFit as Mt, getPresentationTextLength as N, clearSlideTransition as Na, getShapeImageContrast as Ni, findShapesAtPoint as Nn, setTableStyleFlags as No, setShapeSize as Nr, getSlideLayoutBackgroundImageBytes as Ns, setShapeTextBodyRotationDeg as Nt, findSlidesByText as O, getVisibleSlides as Oa, findSlidesByLayoutType as Oi, getSlidesWithEmptyPlaceholders as On, setTableCellText as Oo, setShapeNoFill as Or, getSlideBackgroundImageBytes as Os, setShapeBullets as Ot, getPresentationTextLengthsBySlide as P, getSlideTransition as Pa, getShapeImageCrop as Pi, findShapesInRect as Pn, setTableStyleId as Po, setShapeStroke as Pr, getSlideLayoutBackgroundPatternFill as Ps, setShapeTextColumns as Pt, replaceTextInSlideNotes as Q, getTableCellAlignment as Qa, setSlideSize as Qi, getShapePosition as Qn, getSlideLayoutPlaceholders as Qo, getShapeHyperlinkTooltip as Qr, findCommentsBefore as Qs, getShapeFillOpacity as Qt, getSlideIndex as R, getMediaParts as Ra, getShapeImageLinkUrl as Ri, getMaxShapeIdInPresentation as Rn, getCoreProperties as Ro, setShapeStrokeDash as Rr, getSlideMasterBackgroundGradientFill as Rs, setShapeTextWrap as Rt, getSlideSections as S, getSlidesWithComments as Sa, cm as Sc, setShapeAnimation as Si, getShapeIndex as Sn, setTableCellAlignment as So, getShapeStrokeDash as Sr, setChartSpec as Ss, getShapeTextBodyRotationDeg as St, findSlideByText as T, getSlidesWithNotes as Ta, mm as Tc, findShapesOutsideCanvas as Ti, getShapesBounds as Tn, setTableCellFill as To, setShapeFlip as Tr, clearSlideBackground as Ts, getShapeTextMargins as Tt, getSlideText as U, listPackageParts as Ua, isShapeImageGrayscale as Ui, getShapeCenter as Un, setCoreProperties as Uo, getParagraphAlignment as Ur, setSlideBackgroundImage as Us, getShapeEffectsEffective as Ut, getSlideOutline as V, getPresentationSummary as Va, hasShapeImage as Vi, getShapeBounds as Vn, getPresentationModified as Vo, resolveDrawingColor as Vr, getSlideMasterShapes as Vs, getShapeEffect as Vt, getSlideTextLength as W, readPackagePart as Wa, setShapeImageBrightness as Wi, getShapeCustomGeometry as Wn, setExtendedProperties as Wo, getParagraphBullet as Wr, getShapeClickAction as Ws, setShapeGlow as Wt, replaceTextInPresentation as X, getSlideTables as Xa, SLIDE_SIZE_4_3 as Xi, getShapePlaceholderIdx as Xn, getSlideLayoutName as Xo, getParagraphLineSpacing as Xr, findCommentAuthorByName as Xs, getShapeFillColorResolved as Xt, replaceTextInNotes as Y, getPresentationTableCountsBySlide as Ya, SLIDE_SIZE_16_9 as Yi, getShapeName as Yn, findSlideLayoutByType as Yo, getParagraphLevel as Yr, clearSlideComments as Ys, getShapeFillColor as Yt, replaceTextInSlide as Z, getTableCell as Za, getSlideSize as Zi, getShapePlaceholderType as Zn, getSlideLayoutPartName as Zo, getParagraphSpacing as Zr, findCommentsAfter as Zs, getShapeFillEffective as Zt, moveSlide as _, getPresentationNotesLengthsBySlide as _a, setPresentationFonts as _c, setSlidePlaceholders as _i, findShapesByText as _n, isChartShape as _o, shapesOverlap as _r, getShapeChartKind as _s, appendShapeText as _t, groupShapes as a, findSlidesWithChartTrendlines as aa, getCommentPosition as ac, getShapeRunText as ai, getShapeStrokeJoin as an, getTableCellSpan as ao, getSlideMasterPartNames as ar, getShapeHyperlink as as, addSlideShape as at, sortSlides as b, getSlideNotesLength as ba, loadPresentation as bc, findShapesWithAnimation as bi, findSlidePlaceholderByIdx as bn, removeTableColumn as bo, getShapePatternFill as br, getShapeChartSpec as bs, getShapeTextAutoFit as bt, addContentSlide as c, getAllHyperlinks as ca, getCommentsSortedByDate as cc, setParagraphBullet as ci, findEmptyPlaceholders as cn, getTableCells as co, isShapeHidden as cr, setShapeRunFormat as cs, bringShapeForward as ct, addSlideAt as d, getAllTables as da, getPresentationCommenters as dc, setParagraphSpacing as di, findShapeByText as dn, getTableRowHeights as do, pointInShape as dr, findChartsBySeriesName as ds, copyShape as dt, clearAllHyperlinks as ea, findCommentsByText as ec, getShapeParagraphElements as ei, getShapeStrokeCap as en, getTableCellBorders as eo, getShapeRotation as er, getSlideLayoutUsageCounts as es, searchSlides as et, addTitleSlide as f, getDistinctHyperlinkUrls as fa, getSlideCommentAuthors as fc, setShapeRunHyperlink as fi, findShapeInPresentation as fn, getTableSize as fo, renameShape as fr, findChartsWithDataLabels as fs, getShapeZIndex as ft, mergePresentations as g, getPresentationNotesLength as ga, getPresentationTheme as gc, setSlideBody as gi, findShapesByPreset as gn, insertTableRow as go, setShapeHidden as gr, getShapeChartCategories as gs, setShapeZIndex as gt, importSlide as h, getPresentationHyperlinkCountsBySlide as ha, getPresentationFonts as hc, getSlideTitle as hi, findShapesByName as hn, insertTableColumn as ho, setShapeDescription as hr, getPresentationChartKindCounts as hs, sendShapeToBack as ht, getShapeMedia as i, findSlidesWithChartKind as ia, getCommentDate as ic, getShapeRunHyperlinkTooltip as ii, getShapeStrokeEffective as in, getTableCellPosition as io, getSlideMasterPartName as ir, getParagraphPropertiesEffective as is, addSlideLine as it, getPresentationShapeCountsBySlide as j, replaceHyperlink as ja, getShapeImageBrightness as ji, translateShapes as jn, setTableColumnWidth as jo, setShapePosition as jr, getSlideLayoutBackground as js, setShapeTextAnchor as jt, getAllShapes as k, hasSlideNotes as ka, getPresentationImageCountsBySlide as ki, replaceTokensInSlide as kn, setTableCellTextDirection as ko, setShapeNoStroke as kr, getSlideBackgroundPatternFill as ks, setShapeParagraphs as kt, addSectionHeaderSlide as l, getAllImages as la, getPresentationCommentCountsByAuthor as lc, setParagraphLevel as li, findShapeById as ln, getTableColumnWidths as lo, isShapePlaceholder as lr, addSlideChart as ls, bringShapeToFront as lt, duplicateSlideAt as m, getHiddenSlides as ma, removeSlideComment as mc, getSlideBody as mi, findShapesByKind as mn, getTableStyleId as mo, setShapeBounds as mr, getPresentationChartCountsBySlide as ms, sendShapeBackward as mt, addSlideMedia as n, clearSlideHyperlinks as na, getCommentAuthor as nc, getShapeRunCount as ni, getShapeStrokeColorResolved as nn, getTableCellMargins as no, getShapeText as nr, getSlideLayouts as ns, slideHasAnimations as nt, ungroupShapes as o, getAllCharts as oa, getCommentSlide as oc, isParagraphBulletPicture as oi, getShapeStrokeOpacity as on, getTableCellText as oo, getSlideMasterUsageCounts as or, getShapeRunFormatEffective as os, addSlideTable as ot, duplicateSlide as p, getEmptySlides as pa, getSlideComments as pc, setShapeRunText as pi, findShapesByHyperlink as pn, getTableStyleFlags as po, setShapeAltTitle as pr, findChartsWithTrendlines as ps, removeShape as pt, getSlidesByLayout as q, validatePresentation as qa, setShapeImageOpacity as qi, getShapeId as qn, findSlideLayout as qo, getParagraphEndFormat as qr, addSlideComment as qs, getShapeGradientFillEffective as qt, findShapesWithMedia as r, findSlidesByHyperlink as ra, getCommentAuthors as rc, getShapeRunHyperlink as ri, getShapeStrokeCompound as rn, getTableCellParagraphs as ro, getSlideMasterCount as rr, getUnusedSlideLayouts as rs, addSlideImage as rt, addBlankSlide as s, getAllComments as sa, getCommentText as sc, setParagraphAlignment as si, getShapeStrokeWidth as sn, getTableCellTextDirection as so, getUnusedSlideMasters as sr, setShapeHyperlink as ss, addSlideTextBox as st, VERSION as t, clearAllSlideNotes as ta, findSlidesWithCommentsByAuthor as tc, getShapeRunClickAction as ti, getShapeStrokeColor as tn, getTableCellFill as to, getShapeSize as tr, getSlideLayoutUsageCountsByType as ts, setSlideHidden as tt, addSlide as u, getAllNotes as ua, getPresentationCommentCountsBySlide as uc, setParagraphLineSpacing as ui, findShapeByName as un, getTableDimensions as uo, isShapeTextBox as ur, findChartByKind as us, clearSlideShapes as ut, removeSlide as v, getPresentationNotesText as va, setPresentationTheme as vc, setSlideTitle as vi, findShapesWithHyperlinks as vn, isTableShape as vo, clearShapeFill as vr, getShapeChartSeriesNames as vs, getShapeBodyPrEffective as vt, findSlideByPartName as w, getSlidesWithImages as wa, inches as wc, findOverlappingShapePairs as wi, getShapeXmlString as wn, setTableCellBorders as wo, setShapeFill as wr, resolveDeckBodyTextColor as ws, getShapeTextDirection as wt, swapSlides as x, getSlidesWithCharts as xa, savePresentation as xc, getShapeAnimation as xi, findSlidePlaceholders as xn, removeTableRow as xo, getShapeStrokeArrow as xr, getSlideCharts as xs, getShapeTextAutoFitParams as xt, reverseSlides as y, getSlideNotes as ya, createPresentation as yc, clearSlideAnimations as yi, findSlidePlaceholder as yn, mergeTableCells as yo, clearShapeStroke as yr, getShapeChartSeriesValues as ys, getShapeTextAnchor as yt, getSlideInfo as z, getOrphanMediaPartNames as za, getShapeImageOpacity as zi, getShapeAdjustValues as zn, getExtendedProperties as zo, setShapeStrokeJoin as zr, getSlideMasterBackgroundImageBytes as zs, clearShapeEffects as zt };
19874
+ export { replaceTokensInPresentation as $, getTableCellAnchor as $a, appendSlideNotes as $i, getShapePreset as $n, getSlideLayoutType as $o, getShapeParagraphCount as $r, findCommentsBefore as $s, getShapeStroke as $t, getOutlineText as A, removeSlideNotes as Aa, getShapeImageBiLevelThreshold as Ai, setSlideLayout as An, setTableCellTextFormat as Ao, setShapePatternFill as Ar, getSlideColorMapOverride as As, setShapeText as At, getSlideLayoutCount as B, getPackageSize as Ba, getShapeImagePartName as Bi, getShapeAltTitle as Bn, getPresentationCreated as Bo, getShapeRunFormat as Br, getSlideMasterBackgroundPatternFill as Bs, findShapesByEffect as Bt, setSlideSections as C, getSlidesWithHyperlinks as Ca, savePresentation as Cc, findFlippedShapes as Ci, getShapeSlide as Cn, setTableCellAnchor as Co, setShapeAdjustValues as Cr, getEffectiveColorMap as Cs, getShapeTextColumns as Ct, findSlidesByNotes as D, getSlidesWithTables as Da, mm as Dc, findSlidesByLayoutPartName as Di, getSlideShapes as Dn, setTableCellParagraphs as Do, setShapeImageFill as Dr, getSlideBackgroundGradientFill as Ds, setShapeAlignment as Dt, findSlideByTitle as E, getSlidesWithOverlap as Ea, inches as Ec, findSlidesByLayoutName as Ei, getSlideLayout as En, setTableCellMargins as Eo, setShapeGradientFill as Er, getSlideBackground as Es, getShapeTextWrap as Et, getShapeAt as F, setSlideTransition as Fa, getShapeImageDuotone as Fi, getGroupChildren as Fn, getThumbnail as Fo, setShapeStrokeArrow as Fr, getSlideLayoutBackgroundShapes as Fs, setShapeTextDirection as Ft, getSlideXmlString as G, setMediaPartBytes as Ga, setShapeImageContrast as Gi, getShapeDescription as Gn, touchModified as Go, getParagraphBulletImageBytes as Gr, getShapeClickAction as Gs, setShapeShadow as Gt, getSlidePartName as H, getSlideMediaPartNames as Ha, hasShapeText as Hi, getShapeBoundsResolved as Hn, incrementRevision as Ho, resolveDrawingColorOpacity as Hr, setSlideBackground as Hs, getShapeEffects as Ht, getSlideAt as I, _internalPackageOf as Ia, getShapeImageFillBytes as Ii, getGroupTransform as In, removeThumbnail as Io, setShapeStrokeCap as Ir, getSlideLayoutShapes as Is, setShapeTextFormat as It, isSlideHidden as J, clearTableCellFill as Ja, SLIDE_SIZE_16_10 as Ji, getShapeKind as Jn, findSlideLayoutByPartName as Jo, getParagraphIndent as Jr, addSlideComment as Js, getShapeFill as Jt, getSlides as K, slidesUsingMediaPart as Ka, setShapeImageCrop as Ki, getShapeFlip as Kn, findLayoutsWithPlaceholderType as Ko, getParagraphBulletStyle as Kr, setShapeClickAction as Ks, getShapeGradientFill as Kt, getSlideCount as L, compactPackage as La, getShapeImageFormat as Li, getMaxShapeId as Ln, setThumbnail as Lo, setShapeStrokeCompound as Lr, getSlideMasterBackground as Ls, setShapeTextMargins as Lt, getPresentationText as M, setSlideNotes as Ma, getShapeImageBytes as Mi, centerShapeOnSlide as Mn, setTableRowHeight as Mo, setShapeRotation as Mr, getSlideLayoutBackgroundGradientFill as Ms, setShapeTextAutoFit as Mt, getPresentationTextLength as N, clearSlideTransition as Na, getShapeImageContrast as Ni, findShapesAtPoint as Nn, setTableStyleFlags as No, setShapeSize as Nr, getSlideLayoutBackgroundImageBytes as Ns, setShapeTextBodyRotationDeg as Nt, findSlidesByText as O, getVisibleSlides as Oa, pt as Oc, findSlidesByLayoutType as Oi, getSlidesWithEmptyPlaceholders as On, setTableCellText as Oo, setShapeNoFill as Or, getSlideBackgroundImageBytes as Os, setShapeBulletStyle as Ot, getPresentationTextLengthsBySlide as P, getSlideTransition as Pa, getShapeImageCrop as Pi, findShapesInRect as Pn, setTableStyleId as Po, setShapeStroke as Pr, getSlideLayoutBackgroundPatternFill as Ps, setShapeTextColumns as Pt, replaceTextInSlideNotes as Q, getTableCellAlignment as Qa, setSlideSize as Qi, getShapePosition as Qn, getSlideLayoutPlaceholders as Qo, getShapeHyperlinkTooltip as Qr, findCommentsAfter as Qs, getShapeFillOpacity as Qt, getSlideIndex as R, getMediaParts as Ra, getShapeImageLinkUrl as Ri, getMaxShapeIdInPresentation as Rn, getCoreProperties as Ro, setShapeStrokeDash as Rr, getSlideMasterBackgroundGradientFill as Rs, setShapeTextWrap as Rt, getSlideSections as S, getSlidesWithComments as Sa, loadPresentation as Sc, setShapeAnimation as Si, getShapeIndex as Sn, setTableCellAlignment as So, getShapeStrokeDash as Sr, setChartSpec as Ss, getShapeTextBodyRotationDeg as St, findSlideByText as T, getSlidesWithNotes as Ta, emu as Tc, findShapesOutsideCanvas as Ti, getShapesBounds as Tn, setTableCellFill as To, setShapeFlip as Tr, clearSlideBackground as Ts, getShapeTextMargins as Tt, getSlideText as U, listPackageParts as Ua, isShapeImageGrayscale as Ui, getShapeCenter as Un, setCoreProperties as Uo, getParagraphAlignment as Ur, setSlideBackgroundImage as Us, getShapeEffectsEffective as Ut, getSlideOutline as V, getPresentationSummary as Va, hasShapeImage as Vi, getShapeBounds as Vn, getPresentationModified as Vo, resolveDrawingColor as Vr, getSlideMasterShapes as Vs, getShapeEffect as Vt, getSlideTextLength as W, readPackagePart as Wa, setShapeImageBrightness as Wi, getShapeCustomGeometry as Wn, setExtendedProperties as Wo, getParagraphBullet as Wr, isChartSpec as Ws, setShapeGlow as Wt, replaceTextInPresentation as X, getSlideTables as Xa, SLIDE_SIZE_4_3 as Xi, getShapePlaceholderIdx as Xn, getSlideLayoutName as Xo, getParagraphLineSpacing as Xr, clearSlideComments as Xs, getShapeFillColorResolved as Xt, replaceTextInNotes as Y, getPresentationTableCountsBySlide as Ya, SLIDE_SIZE_16_9 as Yi, getShapeName as Yn, findSlideLayoutByType as Yo, getParagraphLevel as Yr, clearAllSlideComments as Ys, getShapeFillColor as Yt, replaceTextInSlide as Z, getTableCell as Za, getSlideSize as Zi, getShapePlaceholderType as Zn, getSlideLayoutPartName as Zo, getParagraphSpacing as Zr, findCommentAuthorByName as Zs, getShapeFillEffective as Zt, moveSlide as _, getPresentationNotesLengthsBySlide as _a, getPresentationTheme as _c, setSlidePlaceholders as _i, findShapesByText as _n, isChartShape as _o, shapesOverlap as _r, getShapeChartKind as _s, appendShapeText as _t, groupShapes as a, findSlidesWithChartTrendlines as aa, getCommentDate as ac, getShapeRunText as ai, getShapeStrokeJoin as an, getTableCellSpan as ao, getSlideMasterPartNames as ar, getShapeHyperlink as as, addSlideShape as at, sortSlides as b, getSlideNotesLength as ba, asColor as bc, findShapesWithAnimation as bi, findSlidePlaceholderByIdx as bn, removeTableColumn as bo, getShapePatternFill as br, getShapeChartSpec as bs, getShapeTextAutoFit as bt, addContentSlide as c, getAllHyperlinks as ca, getCommentText as cc, setParagraphBullet as ci, findEmptyPlaceholders as cn, getTableCells as co, isShapeHidden as cr, setShapeRunFormat as cs, bringShapeForward as ct, addSlideAt as d, getAllTables as da, getPresentationCommentCountsBySlide as dc, setParagraphSpacing as di, findShapeByText as dn, getTableRowHeights as do, pointInShape as dr, findChartsBySeriesName as ds, copyShape as dt, clearAllHyperlinks as ea, findCommentsByAuthor as ec, getShapeParagraphElements as ei, getShapeStrokeCap as en, getTableCellBorders as eo, getShapeRotation as er, getSlideLayoutUsageCounts as es, searchSlides as et, addTitleSlide as f, getDistinctHyperlinkUrls as fa, getPresentationCommenters as fc, setShapeRunHyperlink as fi, findShapeInPresentation as fn, getTableSize as fo, renameShape as fr, findChartsWithDataLabels as fs, getShapeZIndex as ft, mergePresentations as g, getPresentationNotesLength as ga, getPresentationFonts as gc, setSlideBody as gi, findShapesByPreset as gn, insertTableRow as go, setShapeHidden as gr, getShapeChartCategories as gs, setShapeZIndex as gt, importSlide as h, getPresentationHyperlinkCountsBySlide as ha, removeSlideComment as hc, getSlideTitle as hi, findShapesByName as hn, insertTableColumn as ho, setShapeDescription as hr, getPresentationChartKindCounts as hs, sendShapeToBack as ht, getShapeMedia as i, findSlidesWithChartKind as ia, getCommentAuthors as ic, getShapeRunHyperlinkTooltip as ii, getShapeStrokeEffective as in, getTableCellPosition as io, getSlideMasterPartName as ir, getParagraphPropertiesEffective as is, addSlideLine as it, getPresentationShapeCountsBySlide as j, replaceHyperlink as ja, getShapeImageBrightness as ji, translateShapes as jn, setTableColumnWidth as jo, setShapePosition as jr, getSlideLayoutBackground as js, setShapeTextAnchor as jt, getAllShapes as k, hasSlideNotes as ka, getPresentationImageCountsBySlide as ki, replaceTokensInSlide as kn, setTableCellTextDirection as ko, setShapeNoStroke as kr, getSlideBackgroundPatternFill as ks, setShapeParagraphs as kt, addSectionHeaderSlide as l, getAllImages as la, getCommentsSortedByDate as lc, setParagraphLevel as li, findShapeById as ln, getTableColumnWidths as lo, isShapePlaceholder as lr, addSlideChart as ls, bringShapeToFront as lt, duplicateSlideAt as m, getHiddenSlides as ma, getSlideComments as mc, getSlideBody as mi, findShapesByKind as mn, getTableStyleId as mo, setShapeBounds as mr, getPresentationChartCountsBySlide as ms, sendShapeBackward as mt, addSlideMedia as n, clearSlideHyperlinks as na, findSlidesWithCommentsByAuthor as nc, getShapeRunCount as ni, getShapeStrokeColorResolved as nn, getTableCellMargins as no, getShapeText as nr, getSlideLayouts as ns, slideHasAnimations as nt, ungroupShapes as o, getAllCharts as oa, getCommentPosition as oc, isParagraphBulletPicture as oi, getShapeStrokeOpacity as on, getTableCellText as oo, getSlideMasterUsageCounts as or, getShapeRunFormatEffective as os, addSlideTable as ot, duplicateSlide as p, getEmptySlides as pa, getSlideCommentAuthors as pc, setShapeRunText as pi, findShapesByHyperlink as pn, getTableStyleFlags as po, setShapeAltTitle as pr, findChartsWithTrendlines as ps, removeShape as pt, getSlidesByLayout as q, validatePresentation as qa, setShapeImageOpacity as qi, getShapeId as qn, findSlideLayout as qo, getParagraphEndFormat as qr, setShapeImage as qs, getShapeGradientFillEffective as qt, findShapesWithMedia as r, findSlidesByHyperlink as ra, getCommentAuthor as rc, getShapeRunHyperlink as ri, getShapeStrokeCompound as rn, getTableCellParagraphs as ro, getSlideMasterCount as rr, getUnusedSlideLayouts as rs, addSlideImage as rt, addBlankSlide as s, getAllComments as sa, getCommentSlide as sc, setParagraphAlignment as si, getShapeStrokeWidth as sn, getTableCellTextDirection as so, getUnusedSlideMasters as sr, setShapeHyperlink as ss, addSlideTextBox as st, VERSION as t, clearAllSlideNotes as ta, findCommentsByText as tc, getShapeRunClickAction as ti, getShapeStrokeColor as tn, getTableCellFill as to, getShapeSize as tr, getSlideLayoutUsageCountsByType as ts, setSlideHidden as tt, addSlide as u, getAllNotes as ua, getPresentationCommentCountsByAuthor as uc, setParagraphLineSpacing as ui, findShapeByName as un, getTableDimensions as uo, isShapeTextBox as ur, findChartByKind as us, clearSlideShapes as ut, removeSlide as v, getPresentationNotesText as va, setPresentationFonts as vc, setSlideTitle as vi, findShapesWithHyperlinks as vn, isTableShape as vo, clearShapeFill as vr, getShapeChartSeriesNames as vs, getShapeBodyPrEffective as vt, findSlideByPartName as w, getSlidesWithImages as wa, cm as wc, findOverlappingShapePairs as wi, getShapeXmlString as wn, setTableCellBorders as wo, setShapeFill as wr, resolveDeckBodyTextColor as ws, getShapeTextDirection as wt, swapSlides as x, getSlidesWithCharts as xa, createPresentation as xc, getShapeAnimation as xi, findSlidePlaceholders as xn, removeTableRow as xo, getShapeStrokeArrow as xr, getSlideCharts as xs, getShapeTextAutoFitParams as xt, reverseSlides as y, getSlideNotes as ya, setPresentationTheme as yc, clearSlideAnimations as yi, findSlidePlaceholder as yn, mergeTableCells as yo, clearShapeStroke as yr, getShapeChartSeriesValues as ys, getShapeTextAnchor as yt, getSlideInfo as z, getOrphanMediaPartNames as za, getShapeImageOpacity as zi, getShapeAdjustValues as zn, getExtendedProperties as zo, setShapeStrokeJoin as zr, getSlideMasterBackgroundImageBytes as zs, clearShapeEffects as zt };
19608
19875
 
19609
- //# sourceMappingURL=api-C-0kjwO_.js.map
19876
+ //# sourceMappingURL=api-On7UeTT-.js.map