pptx-react-viewer 2.16.6 → 2.16.8

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.
Files changed (108) hide show
  1. package/CHANGELOG.md +4 -0
  2. package/dist/{AiChatPanel-NQFSMKIJ.mjs → AiChatPanel-FR55MUQF.mjs} +3 -9
  3. package/dist/AiChatPanel-FR55MUQF.mjs.br +0 -0
  4. package/dist/AiChatPanel-FR55MUQF.mjs.gz +0 -0
  5. package/dist/{AiChatPanel-T6UN6LME.js → AiChatPanel-VNHHHM2S.js} +23 -29
  6. package/dist/AiChatPanel-VNHHHM2S.js.br +0 -0
  7. package/dist/AiChatPanel-VNHHHM2S.js.gz +0 -0
  8. package/dist/{Model3DScene-SIST7CIH.js → Model3DScene-KVYGN53Y.js} +2 -2
  9. package/dist/Model3DScene-KVYGN53Y.js.br +0 -0
  10. package/dist/Model3DScene-KVYGN53Y.js.gz +0 -0
  11. package/dist/{Model3DScene-4D4GSRIB.mjs → Model3DScene-LYWXBJMA.mjs} +1 -1
  12. package/dist/Model3DScene-LYWXBJMA.mjs.br +0 -0
  13. package/dist/Model3DScene-LYWXBJMA.mjs.gz +0 -0
  14. package/dist/{SurfaceChart3DScene-GRM24VBC.js → SurfaceChart3DScene-E2PSO2FF.js} +2 -2
  15. package/dist/SurfaceChart3DScene-E2PSO2FF.js.br +0 -0
  16. package/dist/SurfaceChart3DScene-E2PSO2FF.js.gz +0 -0
  17. package/dist/{SurfaceChart3DScene-ZT7L27U4.mjs → SurfaceChart3DScene-Z4IIOBDM.mjs} +1 -1
  18. package/dist/{SurfaceChart3DScene-ZT7L27U4.mjs.br → SurfaceChart3DScene-Z4IIOBDM.mjs.br} +0 -0
  19. package/dist/SurfaceChart3DScene-Z4IIOBDM.mjs.gz +0 -0
  20. package/dist/{chunk-VDQD3ZOU.mjs → chunk-4OWZJUAI.mjs} +7 -2
  21. package/dist/chunk-4OWZJUAI.mjs.br +0 -0
  22. package/dist/chunk-4OWZJUAI.mjs.gz +0 -0
  23. package/dist/{chunk-6F76GHPE.mjs → chunk-ACCX43JJ.mjs} +15 -1410
  24. package/dist/chunk-ACCX43JJ.mjs.br +0 -0
  25. package/dist/chunk-ACCX43JJ.mjs.gz +0 -0
  26. package/dist/{chunk-YZHBUMVU.mjs → chunk-EPYWIXP7.mjs} +1114 -527
  27. package/dist/chunk-EPYWIXP7.mjs.br +0 -0
  28. package/dist/chunk-EPYWIXP7.mjs.gz +0 -0
  29. package/dist/{chunk-GUDJDY4J.js → chunk-LYOEX3FB.js} +342 -427
  30. package/dist/chunk-LYOEX3FB.js.br +0 -0
  31. package/dist/chunk-LYOEX3FB.js.gz +0 -0
  32. package/dist/{chunk-NI5GSVZU.mjs → chunk-NAMV6PRF.mjs} +6 -91
  33. package/dist/chunk-NAMV6PRF.mjs.br +0 -0
  34. package/dist/chunk-NAMV6PRF.mjs.gz +0 -0
  35. package/dist/{chunk-H36QL5T5.js → chunk-QBRZ3VIC.js} +258 -1683
  36. package/dist/chunk-QBRZ3VIC.js.br +0 -0
  37. package/dist/chunk-QBRZ3VIC.js.gz +0 -0
  38. package/dist/{chunk-RZYOOWZN.js → chunk-SADF35N7.js} +1165 -13
  39. package/dist/chunk-SADF35N7.js.br +0 -0
  40. package/dist/chunk-SADF35N7.js.gz +0 -0
  41. package/dist/{chunk-DYGKE2LY.js → chunk-SGJP2EUI.js} +2128 -1541
  42. package/dist/chunk-SGJP2EUI.js.br +0 -0
  43. package/dist/chunk-SGJP2EUI.js.gz +0 -0
  44. package/dist/{chunk-PUBYHZYJ.mjs → chunk-SKQCLCBF.mjs} +1132 -6
  45. package/dist/chunk-SKQCLCBF.mjs.br +0 -0
  46. package/dist/chunk-SKQCLCBF.mjs.gz +0 -0
  47. package/dist/{chunk-YDYAOW6D.js → chunk-YT25W6IR.js} +9 -3
  48. package/dist/chunk-YT25W6IR.js.br +0 -0
  49. package/dist/chunk-YT25W6IR.js.gz +0 -0
  50. package/dist/index.d.ts +12 -0
  51. package/dist/index.js +39 -39
  52. package/dist/index.js.br +0 -0
  53. package/dist/index.js.gz +0 -0
  54. package/dist/index.mjs +5 -5
  55. package/dist/index.mjs.br +0 -0
  56. package/dist/index.mjs.gz +0 -0
  57. package/dist/internals.d.ts +27 -7
  58. package/dist/internals.d.ts.map +1 -1
  59. package/dist/internals.js +78 -78
  60. package/dist/internals.js.br +0 -0
  61. package/dist/internals.js.gz +0 -0
  62. package/dist/internals.mjs +3 -3
  63. package/dist/internals.mjs.br +0 -0
  64. package/dist/internals.mjs.gz +0 -0
  65. package/dist/pptx-viewer.css +1 -1
  66. package/dist/pptx-viewer.css.br +0 -0
  67. package/dist/pptx-viewer.css.gz +0 -0
  68. package/dist/{useViewerBuildingBlocks-DpzU8NZ_.d.ts → useViewerBuildingBlocks-Xddn6SFj.d.ts} +13 -1
  69. package/dist/useViewerBuildingBlocks-Xddn6SFj.d.ts.map +1 -0
  70. package/dist/viewer/index.js +26 -26
  71. package/dist/viewer/index.js.br +0 -0
  72. package/dist/viewer/index.js.gz +0 -0
  73. package/dist/viewer/index.mjs +5 -5
  74. package/dist/viewer/index.mjs.br +0 -0
  75. package/dist/viewer/index.mjs.gz +0 -0
  76. package/package.json +1 -1
  77. package/dist/AiChatPanel-NQFSMKIJ.mjs.br +0 -0
  78. package/dist/AiChatPanel-NQFSMKIJ.mjs.gz +0 -0
  79. package/dist/AiChatPanel-T6UN6LME.js.br +0 -0
  80. package/dist/AiChatPanel-T6UN6LME.js.gz +0 -0
  81. package/dist/Model3DScene-4D4GSRIB.mjs.br +0 -0
  82. package/dist/Model3DScene-4D4GSRIB.mjs.gz +0 -0
  83. package/dist/Model3DScene-SIST7CIH.js.br +0 -0
  84. package/dist/Model3DScene-SIST7CIH.js.gz +0 -0
  85. package/dist/SurfaceChart3DScene-GRM24VBC.js.br +0 -0
  86. package/dist/SurfaceChart3DScene-GRM24VBC.js.gz +0 -0
  87. package/dist/SurfaceChart3DScene-ZT7L27U4.mjs.gz +0 -0
  88. package/dist/chunk-6F76GHPE.mjs.br +0 -0
  89. package/dist/chunk-6F76GHPE.mjs.gz +0 -0
  90. package/dist/chunk-DYGKE2LY.js.br +0 -0
  91. package/dist/chunk-DYGKE2LY.js.gz +0 -0
  92. package/dist/chunk-GUDJDY4J.js.br +0 -0
  93. package/dist/chunk-GUDJDY4J.js.gz +0 -0
  94. package/dist/chunk-H36QL5T5.js.br +0 -0
  95. package/dist/chunk-H36QL5T5.js.gz +0 -0
  96. package/dist/chunk-NI5GSVZU.mjs.br +0 -0
  97. package/dist/chunk-NI5GSVZU.mjs.gz +0 -0
  98. package/dist/chunk-PUBYHZYJ.mjs.br +0 -0
  99. package/dist/chunk-PUBYHZYJ.mjs.gz +0 -0
  100. package/dist/chunk-RZYOOWZN.js.br +0 -0
  101. package/dist/chunk-RZYOOWZN.js.gz +0 -0
  102. package/dist/chunk-VDQD3ZOU.mjs.br +0 -0
  103. package/dist/chunk-VDQD3ZOU.mjs.gz +0 -0
  104. package/dist/chunk-YDYAOW6D.js.br +0 -0
  105. package/dist/chunk-YDYAOW6D.js.gz +0 -0
  106. package/dist/chunk-YZHBUMVU.mjs.br +0 -0
  107. package/dist/chunk-YZHBUMVU.mjs.gz +0 -0
  108. package/dist/useViewerBuildingBlocks-DpzU8NZ_.d.ts.map +0 -1
@@ -30542,6 +30542,52 @@ function getPresetShapeClipPath(presetName) {
30542
30542
  }
30543
30543
  return PRESET_SHAPE_CLIP_PATHS[presetName.toLowerCase()];
30544
30544
  }
30545
+ function getShapeType(shapeType) {
30546
+ if (!shapeType) {
30547
+ return "rect";
30548
+ }
30549
+ const normalized = shapeType.toLowerCase();
30550
+ if (normalized === "rect") {
30551
+ return "rect";
30552
+ }
30553
+ if (normalized === "roundrect") {
30554
+ return "roundRect";
30555
+ }
30556
+ if (normalized === "ellipse" || normalized === "oval") {
30557
+ return "ellipse";
30558
+ }
30559
+ if (normalized === "cylinder" || normalized === "can") {
30560
+ return "cylinder";
30561
+ }
30562
+ if (normalized === "triangle") {
30563
+ return "triangle";
30564
+ }
30565
+ if (normalized === "diamond") {
30566
+ return "diamond";
30567
+ }
30568
+ if (normalized === "line" || normalized === "lineinv") {
30569
+ return "line";
30570
+ }
30571
+ if (normalized === "rtarrow" || normalized === "rightarrow") {
30572
+ return "rtArrow";
30573
+ }
30574
+ if (normalized === "leftarrow") {
30575
+ return "leftArrow";
30576
+ }
30577
+ if (normalized === "uparrow") {
30578
+ return "upArrow";
30579
+ }
30580
+ if (normalized === "downarrow") {
30581
+ return "downArrow";
30582
+ }
30583
+ if (normalized.includes("connector")) {
30584
+ return "connector";
30585
+ }
30586
+ if (PRESET_SHAPE_CLIP_PATHS[normalized] !== void 0) {
30587
+ return "rect";
30588
+ }
30589
+ return "rect";
30590
+ }
30545
30591
  function getShapeClipPath(shapeType) {
30546
30592
  return getPresetShapeClipPath(shapeType);
30547
30593
  }
@@ -100715,6 +100761,29 @@ function apply3dEffects(base, scene3d, shape3d, fillColorFallback) {
100715
100761
  base.backgroundImage = base.backgroundImage ? `${lightRig.backgroundImage}, ${base.backgroundImage}` : lightRig.backgroundImage;
100716
100762
  }
100717
100763
  }
100764
+ function edgesFromSection(borders, regionTop, regionBottom, regionLeft, regionRight) {
100765
+ if (!borders) {
100766
+ return void 0;
100767
+ }
100768
+ return {
100769
+ top: regionTop ? borders.top ?? borders.insideH : borders.insideH,
100770
+ bottom: regionBottom ? borders.bottom ?? borders.insideH : borders.insideH,
100771
+ left: regionLeft ? borders.left ?? borders.insideV : borders.insideV,
100772
+ right: regionRight ? borders.right ?? borders.insideV : borders.insideV
100773
+ };
100774
+ }
100775
+ function borderToCss(border, resolve2) {
100776
+ if (!border) {
100777
+ return void 0;
100778
+ }
100779
+ if (border.noFill) {
100780
+ return "none";
100781
+ }
100782
+ const width = border.width ?? 1;
100783
+ const dash = ooxmlDashToCssBorderStyle(border.dash);
100784
+ const color2 = border.color ?? resolve2(border.fill) ?? "#000000";
100785
+ return `${width}px ${dash} ${color2}`;
100786
+ }
100718
100787
  function collectSections(entry2, tableData, pos2) {
100719
100788
  const { rowIndex, cellIndex, rowCount, columnCount } = pos2;
100720
100789
  const isTop = rowIndex === 0;
@@ -100766,6 +100835,51 @@ function collectSections(entry2, tableData, pos2) {
100766
100835
  }
100767
100836
  return sections2;
100768
100837
  }
100838
+ function collectLayers(entry2, tableData, pos2) {
100839
+ const layers = [];
100840
+ for (const section of collectSections(entry2, tableData, pos2)) {
100841
+ layers.push(
100842
+ edgesFromSection(
100843
+ section.borders,
100844
+ section.regionTop,
100845
+ section.regionBottom,
100846
+ section.regionLeft,
100847
+ section.regionRight
100848
+ )
100849
+ );
100850
+ }
100851
+ return layers.filter((layer) => layer !== void 0);
100852
+ }
100853
+ function resolveCellBorderCss(entry2, tableData, pos2, resolve2) {
100854
+ if (!entry2) {
100855
+ return void 0;
100856
+ }
100857
+ const layers = collectLayers(entry2, tableData, pos2);
100858
+ if (layers.length === 0) {
100859
+ return void 0;
100860
+ }
100861
+ const pick = (edge) => {
100862
+ let winner;
100863
+ for (const layer of layers) {
100864
+ if (layer[edge]) {
100865
+ winner = layer[edge];
100866
+ }
100867
+ }
100868
+ return winner;
100869
+ };
100870
+ const css = {};
100871
+ let applied = false;
100872
+ const edges = ["top", "bottom", "left", "right"];
100873
+ for (const edge of edges) {
100874
+ const value = borderToCss(pick(edge), resolve2);
100875
+ if (value) {
100876
+ const key = `border${edge[0].toUpperCase()}${edge.slice(1)}`;
100877
+ css[key] = value;
100878
+ applied = true;
100879
+ }
100880
+ }
100881
+ return applied ? css : void 0;
100882
+ }
100769
100883
  function resolveStyleDiagonalBorders(entry2, tableData, pos2, resolve2) {
100770
100884
  if (!entry2) {
100771
100885
  return void 0;
@@ -100848,6 +100962,66 @@ function resolveStyleFillColor(fill, colorScheme) {
100848
100962
  }
100849
100963
  return applyTintShade(base, fill);
100850
100964
  }
100965
+ function clearBackground(css) {
100966
+ delete css.background;
100967
+ delete css.backgroundColor;
100968
+ delete css.backgroundImage;
100969
+ }
100970
+ function gradientCssFromFill(fill, colorScheme) {
100971
+ const gradient = fill.gradient;
100972
+ if (!gradient || gradient.stops.length === 0) {
100973
+ return void 0;
100974
+ }
100975
+ const shapeLike = {
100976
+ fillMode: "gradient",
100977
+ fillGradientType: gradient.type,
100978
+ fillGradientAngle: gradient.angle ?? 90,
100979
+ fillGradientStops: gradient.stops.map((stop) => ({
100980
+ color: resolveStyleFillColor(stop.fill, colorScheme) ?? stop.fill.color ?? "#000000",
100981
+ position: stop.position
100982
+ }))
100983
+ };
100984
+ return buildGradientCss(shapeLike);
100985
+ }
100986
+ function applyStyleFill(fill, colorScheme, css, fallback) {
100987
+ if (fill?.noFill) {
100988
+ clearBackground(css);
100989
+ css.backgroundColor = "transparent";
100990
+ return true;
100991
+ }
100992
+ if (fill?.gradient) {
100993
+ const gradientCss = gradientCssFromFill(fill, colorScheme);
100994
+ if (gradientCss) {
100995
+ clearBackground(css);
100996
+ css.background = gradientCss;
100997
+ return true;
100998
+ }
100999
+ }
101000
+ if (fill?.pattern) {
101001
+ const fg = normalizeHexColor(
101002
+ resolveStyleFillColor(fill.pattern.foreground, colorScheme),
101003
+ "#000000"
101004
+ );
101005
+ const bg = normalizeHexColor(
101006
+ resolveStyleFillColor(fill.pattern.background, colorScheme),
101007
+ "#ffffff"
101008
+ );
101009
+ const svg = getPatternSvg(fill.pattern.preset, fg, bg);
101010
+ clearBackground(css);
101011
+ if (svg) {
101012
+ css.backgroundImage = `url("data:image/svg+xml,${encodeURIComponent(svg)}")`;
101013
+ }
101014
+ css.backgroundColor = bg;
101015
+ return true;
101016
+ }
101017
+ const color2 = resolveStyleFillColor(fill, colorScheme) ?? fallback;
101018
+ if (color2) {
101019
+ clearBackground(css);
101020
+ css.backgroundColor = color2;
101021
+ return true;
101022
+ }
101023
+ return false;
101024
+ }
100851
101025
  function resolveFontRefIdx(idx, fontScheme) {
100852
101026
  if (!idx || !fontScheme) {
100853
101027
  return void 0;
@@ -100860,6 +101034,52 @@ function resolveFontRefIdx(idx, fontScheme) {
100860
101034
  }
100861
101035
  return void 0;
100862
101036
  }
101037
+ function applyStyleText(text2, colorScheme, css, fontScheme) {
101038
+ if (!text2) {
101039
+ return false;
101040
+ }
101041
+ let applied = false;
101042
+ if (text2.bold) {
101043
+ css.fontWeight = 700;
101044
+ applied = true;
101045
+ }
101046
+ if (text2.italic) {
101047
+ css.fontStyle = "italic";
101048
+ applied = true;
101049
+ }
101050
+ if (text2.underline) {
101051
+ css.textDecorationLine = "underline";
101052
+ applied = true;
101053
+ }
101054
+ if (text2.fontFace) {
101055
+ css.fontFamily = text2.fontFace;
101056
+ applied = true;
101057
+ } else {
101058
+ const refFont = resolveFontRefIdx(text2.fontRefIdx, fontScheme);
101059
+ if (refFont) {
101060
+ css.fontFamily = refFont;
101061
+ applied = true;
101062
+ }
101063
+ }
101064
+ if (text2.fontSchemeColor && colorScheme) {
101065
+ const base = colorScheme[text2.fontSchemeColor];
101066
+ if (base) {
101067
+ let color2 = base;
101068
+ if (text2.fontTint !== void 0 && text2.fontTint > 0) {
101069
+ color2 = tintColor(color2, text2.fontTint / 1e5);
101070
+ }
101071
+ if (text2.fontShade !== void 0 && text2.fontShade > 0) {
101072
+ color2 = shadeColor(color2, 1 - text2.fontShade / 1e5);
101073
+ }
101074
+ css.color = color2;
101075
+ applied = true;
101076
+ }
101077
+ } else if (text2.fontColor) {
101078
+ css.color = text2.fontColor;
101079
+ applied = true;
101080
+ }
101081
+ return applied;
101082
+ }
100863
101083
  var BEVEL_LIGHT_OFFSETS = {
100864
101084
  tl: { x: 1, y: 1 },
100865
101085
  t: { x: 0, y: 1 },
@@ -100878,6 +101098,23 @@ function cell3DBevelCss(cell3D) {
100878
101098
  const shadow = `inset ${-off.x * size}px ${-off.y * size}px ${size}px rgba(0,0,0,0.4)`;
100879
101099
  return { boxShadow: `${highlight}, ${shadow}` };
100880
101100
  }
101101
+ function cellPatternFillCss(style) {
101102
+ if (style.fillMode !== "pattern" || !style.patternFillPreset) {
101103
+ return null;
101104
+ }
101105
+ const fg = normalizeHexColor(style.patternFillForeground, "#000000");
101106
+ const bg = normalizeHexColor(style.patternFillBackground, "#ffffff");
101107
+ const svgMarkup = getPatternSvg(style.patternFillPreset, fg, bg);
101108
+ if (svgMarkup) {
101109
+ const encoded = encodeURIComponent(svgMarkup);
101110
+ return {
101111
+ backgroundImage: `url("data:image/svg+xml,${encoded}")`,
101112
+ backgroundColor: bg
101113
+ };
101114
+ }
101115
+ const fallback = style.patternFillBackground ?? style.backgroundColor;
101116
+ return fallback ? { backgroundColor: fallback } : null;
101117
+ }
100881
101118
  function resolveTableStyleEntry(tableStyleId, tableStyleMap) {
100882
101119
  if (!tableStyleId || !tableStyleMap) {
100883
101120
  return void 0;
@@ -100911,6 +101148,146 @@ function ooxmlDashToCssBorderStyle(dashVal) {
100911
101148
  return "solid";
100912
101149
  }
100913
101150
  }
101151
+ function cellStyleToCss(style) {
101152
+ if (!style) {
101153
+ return {};
101154
+ }
101155
+ const css = {};
101156
+ if (style.fontSize) {
101157
+ css.fontSize = `${style.fontSize}px`;
101158
+ }
101159
+ if (style.bold) {
101160
+ css.fontWeight = "bold";
101161
+ }
101162
+ if (style.italic) {
101163
+ css.fontStyle = "italic";
101164
+ }
101165
+ if (style.underline) {
101166
+ css.textDecorationLine = "underline";
101167
+ }
101168
+ if (style.color) {
101169
+ css.color = style.color;
101170
+ }
101171
+ if (style.gradientFillCss) {
101172
+ css.background = style.gradientFillCss;
101173
+ } else if (style.fillMode === "pattern") {
101174
+ const patternResult = cellPatternFillCss(style);
101175
+ if (patternResult) {
101176
+ if (patternResult.backgroundImage) {
101177
+ css.backgroundImage = patternResult.backgroundImage;
101178
+ }
101179
+ if (patternResult.backgroundColor) {
101180
+ css.backgroundColor = patternResult.backgroundColor;
101181
+ }
101182
+ } else {
101183
+ const fallback = style.patternFillBackground ?? style.backgroundColor;
101184
+ if (fallback) {
101185
+ css.backgroundColor = fallback;
101186
+ }
101187
+ }
101188
+ } else if (style.backgroundColor) {
101189
+ css.backgroundColor = style.backgroundColor;
101190
+ }
101191
+ if (style.align) {
101192
+ css.textAlign = style.align;
101193
+ } else if (style.anchorCtr) {
101194
+ css.textAlign = "center";
101195
+ }
101196
+ if (style.vAlign) {
101197
+ css.verticalAlign = style.vAlign;
101198
+ }
101199
+ if (style.horzOverflow === "clip") {
101200
+ css.overflowX = "hidden";
101201
+ } else if (style.horzOverflow === "overflow") {
101202
+ css.overflowX = "visible";
101203
+ }
101204
+ if (style.textDirection) {
101205
+ switch (style.textDirection) {
101206
+ case "vert":
101207
+ case "eaVert":
101208
+ case "wordArtVert":
101209
+ case "wordArtVertRtl":
101210
+ css.writingMode = "vertical-rl";
101211
+ break;
101212
+ case "vert270":
101213
+ case "mongolianVert":
101214
+ css.writingMode = "vertical-lr";
101215
+ break;
101216
+ }
101217
+ if (style.textDirection === "wordArtVert") {
101218
+ css.textOrientation = "upright";
101219
+ } else if (css.writingMode) {
101220
+ css.textOrientation = "mixed";
101221
+ }
101222
+ if (style.textDirection === "wordArtVertRtl") {
101223
+ css.direction = "rtl";
101224
+ }
101225
+ }
101226
+ const borderEdges = [
101227
+ {
101228
+ prefix: "borderTop",
101229
+ width: style.borderTopWidth,
101230
+ color: style.borderTopColor,
101231
+ dash: style.borderTopDash
101232
+ },
101233
+ {
101234
+ prefix: "borderBottom",
101235
+ width: style.borderBottomWidth,
101236
+ color: style.borderBottomColor,
101237
+ dash: style.borderBottomDash
101238
+ },
101239
+ {
101240
+ prefix: "borderLeft",
101241
+ width: style.borderLeftWidth,
101242
+ color: style.borderLeftColor,
101243
+ dash: style.borderLeftDash
101244
+ },
101245
+ {
101246
+ prefix: "borderRight",
101247
+ width: style.borderRightWidth,
101248
+ color: style.borderRightColor,
101249
+ dash: style.borderRightDash
101250
+ }
101251
+ ];
101252
+ for (const edge of borderEdges) {
101253
+ if (edge.width || edge.color) {
101254
+ const w = edge.width ?? 1;
101255
+ const c = edge.color ?? style.borderColor ?? "#000000";
101256
+ const s = ooxmlDashToCssBorderStyle(edge.dash);
101257
+ css[edge.prefix] = `${w}px ${s} ${c}`;
101258
+ }
101259
+ }
101260
+ if (style.marginLeft) {
101261
+ css.paddingLeft = `${style.marginLeft}px`;
101262
+ }
101263
+ if (style.marginRight) {
101264
+ css.paddingRight = `${style.marginRight}px`;
101265
+ }
101266
+ if (style.marginTop) {
101267
+ css.paddingTop = `${style.marginTop}px`;
101268
+ }
101269
+ if (style.marginBottom) {
101270
+ css.paddingBottom = `${style.marginBottom}px`;
101271
+ }
101272
+ const textShadowParts = [];
101273
+ if (style.textShadowColor) {
101274
+ const offX = style.textShadowOffsetX ?? 1;
101275
+ const offY = style.textShadowOffsetY ?? 1;
101276
+ const blur = style.textShadowBlur ?? 0;
101277
+ textShadowParts.push(`${offX}px ${offY}px ${blur}px ${style.textShadowColor}`);
101278
+ }
101279
+ if (style.textGlowColor) {
101280
+ const radius = style.textGlowRadius ?? 2;
101281
+ textShadowParts.push(`0px 0px ${radius}px ${style.textGlowColor}`);
101282
+ }
101283
+ if (textShadowParts.length > 0) {
101284
+ css.textShadow = textShadowParts.join(", ");
101285
+ }
101286
+ if (style.cell3D) {
101287
+ Object.assign(css, cell3DBevelCss(style.cell3D));
101288
+ }
101289
+ return css;
101290
+ }
100914
101291
  function getDiagonalBorders(style, styleDiagonals) {
100915
101292
  const cellHasDown = Boolean(style?.borderDiagDownColor && style?.borderDiagDownWidth);
100916
101293
  const cellHasUp = Boolean(style?.borderDiagUpColor && style?.borderDiagUpWidth);
@@ -100949,6 +101326,138 @@ function getCellDiagonalBorders(style, tableData, pos2, styleCtx) {
100949
101326
  }
100950
101327
  return getDiagonalBorders(style, styleDiagonals);
100951
101328
  }
101329
+ function getTableCellBandStyle(tableData, rowIndex, cellIndex, rowCount, columnCount, styleCtx) {
101330
+ if (!tableData) {
101331
+ return void 0;
101332
+ }
101333
+ const styleEntry = resolveTableStyleEntry(tableData.tableStyleId, styleCtx?.tableStyleMap);
101334
+ const colorScheme = styleCtx?.colorScheme;
101335
+ const fontScheme = styleCtx?.fontScheme;
101336
+ const resolveFill = (fill, fallback) => resolveStyleFillColor(fill, colorScheme) ?? fallback;
101337
+ const style = {};
101338
+ let applied = false;
101339
+ if (styleEntry?.wholeTblFill) {
101340
+ if (applyStyleFill(styleEntry.wholeTblFill, colorScheme, style, "")) {
101341
+ applied = true;
101342
+ }
101343
+ }
101344
+ if (applyStyleText(styleEntry?.wholeTblText, colorScheme, style, fontScheme)) {
101345
+ applied = true;
101346
+ }
101347
+ const bandStartRow = tableData.firstRowHeader ? 1 : 0;
101348
+ const bandEndRow = tableData.lastRow ? rowCount - 1 : rowCount;
101349
+ if (tableData.bandedRows && rowIndex >= bandStartRow && rowIndex < bandEndRow) {
101350
+ const bandIndex = rowIndex - bandStartRow;
101351
+ const rowCycle = Math.max(tableData.bandRowCycle ?? 1, 1);
101352
+ const bandGroup = Math.floor(bandIndex / rowCycle) % 2;
101353
+ if (bandGroup === 0) {
101354
+ applyStyleFill(styleEntry?.band1HFill, colorScheme, style, "rgba(217, 226, 243, 0.5)");
101355
+ applyStyleText(styleEntry?.band1HText, colorScheme, style, fontScheme);
101356
+ applied = true;
101357
+ } else if (styleEntry?.band2HFill) {
101358
+ if (applyStyleFill(styleEntry.band2HFill, colorScheme, style, "")) {
101359
+ applyStyleText(styleEntry.band2HText, colorScheme, style, fontScheme);
101360
+ applied = true;
101361
+ }
101362
+ }
101363
+ }
101364
+ if (tableData.bandedColumns) {
101365
+ const isFirstCol = tableData.firstCol;
101366
+ const isLastCol = tableData.lastCol;
101367
+ const colBandIndex = isFirstCol && cellIndex > 0 ? cellIndex - 1 : cellIndex;
101368
+ const skipCol = isFirstCol && cellIndex === 0 || isLastCol && cellIndex === columnCount - 1;
101369
+ if (!skipCol) {
101370
+ const colCycle = Math.max(tableData.bandColCycle ?? 1, 1);
101371
+ const colBandGroup = Math.floor(colBandIndex / colCycle) % 2;
101372
+ const canOverride = !style.backgroundColor || !tableData.bandedRows;
101373
+ if (colBandGroup === 0) {
101374
+ if (canOverride) {
101375
+ applyStyleFill(styleEntry?.band1VFill, colorScheme, style, "rgba(217, 226, 243, 0.35)");
101376
+ applyStyleText(styleEntry?.band1VText, colorScheme, style, fontScheme);
101377
+ applied = true;
101378
+ }
101379
+ } else if (styleEntry?.band2VFill && canOverride) {
101380
+ if (applyStyleFill(styleEntry.band2VFill, colorScheme, style, "")) {
101381
+ applyStyleText(styleEntry.band2VText, colorScheme, style, fontScheme);
101382
+ applied = true;
101383
+ }
101384
+ }
101385
+ }
101386
+ }
101387
+ if (tableData.firstRowHeader && rowIndex === 0) {
101388
+ style.fontWeight = 700;
101389
+ applyStyleFill(styleEntry?.firstRowFill, colorScheme, style, "rgba(68, 114, 196, 0.85)");
101390
+ if (!styleEntry?.firstRowFill?.noFill) {
101391
+ style.color = "#ffffff";
101392
+ }
101393
+ applyStyleText(styleEntry?.firstRowText, colorScheme, style, fontScheme);
101394
+ applied = true;
101395
+ }
101396
+ if (tableData.lastRow && rowIndex === rowCount - 1) {
101397
+ style.fontWeight = 700;
101398
+ if (styleEntry?.lastRowFill) {
101399
+ applyStyleFill(styleEntry.lastRowFill, colorScheme, style, "");
101400
+ }
101401
+ const borderColor = resolveFill(styleEntry?.firstRowFill, "rgba(68, 114, 196, 0.7)");
101402
+ style.borderTop = `2px solid ${borderColor}`;
101403
+ applyStyleText(styleEntry?.lastRowText, colorScheme, style, fontScheme);
101404
+ applied = true;
101405
+ }
101406
+ if (tableData.firstCol && cellIndex === 0) {
101407
+ style.fontWeight = 700;
101408
+ if (styleEntry?.firstColFill) {
101409
+ applyStyleFill(styleEntry.firstColFill, colorScheme, style, "");
101410
+ }
101411
+ applyStyleText(styleEntry?.firstColText, colorScheme, style, fontScheme);
101412
+ applied = true;
101413
+ }
101414
+ if (tableData.lastCol && cellIndex === columnCount - 1) {
101415
+ style.fontWeight = 700;
101416
+ if (styleEntry?.lastColFill) {
101417
+ applyStyleFill(styleEntry.lastColFill, colorScheme, style, "");
101418
+ }
101419
+ applyStyleText(styleEntry?.lastColText, colorScheme, style, fontScheme);
101420
+ applied = true;
101421
+ }
101422
+ if (styleEntry) {
101423
+ const atTop = Boolean(tableData.firstRowHeader) && rowIndex === 0;
101424
+ const atBottom = Boolean(tableData.lastRow) && rowIndex === rowCount - 1;
101425
+ const atLeft = Boolean(tableData.firstCol) && cellIndex === 0;
101426
+ const atRight = Boolean(tableData.lastCol) && cellIndex === columnCount - 1;
101427
+ let cornerFill;
101428
+ let cornerText = void 0;
101429
+ if (atTop && atLeft) {
101430
+ cornerFill = styleEntry.nwCellFill;
101431
+ cornerText = styleEntry.nwCellText;
101432
+ } else if (atTop && atRight) {
101433
+ cornerFill = styleEntry.neCellFill;
101434
+ cornerText = styleEntry.neCellText;
101435
+ } else if (atBottom && atLeft) {
101436
+ cornerFill = styleEntry.swCellFill;
101437
+ cornerText = styleEntry.swCellText;
101438
+ } else if (atBottom && atRight) {
101439
+ cornerFill = styleEntry.seCellFill;
101440
+ cornerText = styleEntry.seCellText;
101441
+ }
101442
+ if (cornerFill && applyStyleFill(cornerFill, colorScheme, style, "")) {
101443
+ applied = true;
101444
+ }
101445
+ if (applyStyleText(cornerText, colorScheme, style, fontScheme)) {
101446
+ applied = true;
101447
+ }
101448
+ }
101449
+ const borderCss = resolveCellBorderCss(
101450
+ styleEntry,
101451
+ tableData,
101452
+ { rowIndex, cellIndex, rowCount, columnCount },
101453
+ (fill) => resolveStyleFillColor(fill, colorScheme)
101454
+ );
101455
+ if (borderCss) {
101456
+ Object.assign(style, borderCss);
101457
+ applied = true;
101458
+ }
101459
+ return applied ? style : void 0;
101460
+ }
100952
101461
  function computeBoundingRect(cells) {
100953
101462
  if (cells.length === 0) {
100954
101463
  return void 0;
@@ -106933,6 +107442,167 @@ function resolvePictureBullet(info, baseFontSize) {
106933
107442
  ...info.imageRelId ? { imageRelId: info.imageRelId } : {}
106934
107443
  };
106935
107444
  }
107445
+ var DEBOUNCE_MS = 600;
107446
+ var EXPANDED_MAX_HEIGHT = 200;
107447
+ var PX_TO_PT = 0.75;
107448
+ var MAX_INDENT_LEVEL = 4;
107449
+ var INDENT_PX = 24;
107450
+ function escapeHtml2(value) {
107451
+ return value.replace(/&/gu, "&amp;").replace(/</gu, "&lt;").replace(/>/gu, "&gt;").replace(/"/gu, "&quot;").replace(/'/gu, "&#39;");
107452
+ }
107453
+ function createPlainNotesSegments(text2) {
107454
+ const lines = text2.split("\n");
107455
+ const segments = [];
107456
+ lines.forEach((line22, index) => {
107457
+ segments.push({ text: line22, style: {} });
107458
+ if (index < lines.length - 1) {
107459
+ segments.push({ text: "", style: {}, isParagraphBreak: true });
107460
+ }
107461
+ });
107462
+ if (segments.length === 0) {
107463
+ segments.push({ text: "", style: {} });
107464
+ }
107465
+ return segments;
107466
+ }
107467
+ function segmentsToPlainText(segments) {
107468
+ return segments.map((segment) => segment.isParagraphBreak ? "\n" : segment.text).join("");
107469
+ }
107470
+ function normalizeSegments(segments) {
107471
+ const cleaned = segments.filter((segment) => segment.isParagraphBreak || segment.text.length > 0);
107472
+ while (cleaned.length > 0 && cleaned[cleaned.length - 1].isParagraphBreak) {
107473
+ cleaned.pop();
107474
+ }
107475
+ return cleaned.length > 0 ? cleaned : [{ text: "", style: {} }];
107476
+ }
107477
+ function parsePt(value) {
107478
+ if (!value) {
107479
+ return void 0;
107480
+ }
107481
+ const numeric = Number.parseFloat(value);
107482
+ if (Number.isNaN(numeric) || !Number.isFinite(numeric)) {
107483
+ return void 0;
107484
+ }
107485
+ if (value.endsWith("px")) {
107486
+ return numeric * PX_TO_PT;
107487
+ }
107488
+ return numeric;
107489
+ }
107490
+ function buildParagraph(segments) {
107491
+ const first = segments[0];
107492
+ let bulletType = "none";
107493
+ let indentLevel = 0;
107494
+ if (first?.bulletInfo) {
107495
+ if (first.bulletInfo.char) {
107496
+ bulletType = "bullet";
107497
+ } else if (first.bulletInfo.autoNumType) {
107498
+ bulletType = "numbered";
107499
+ }
107500
+ }
107501
+ if (first?.style.paragraphMarginLeft) {
107502
+ indentLevel = Math.min(
107503
+ MAX_INDENT_LEVEL,
107504
+ Math.max(0, Math.round(first.style.paragraphMarginLeft / INDENT_PX))
107505
+ );
107506
+ }
107507
+ return {
107508
+ segments: segments.length > 0 ? segments : [{ text: "", style: {} }],
107509
+ bulletType,
107510
+ indentLevel
107511
+ };
107512
+ }
107513
+ function segmentsToParagraphs(segments) {
107514
+ const normalized = normalizeSegments(segments);
107515
+ const paragraphs = [];
107516
+ let current = [];
107517
+ for (const seg of normalized) {
107518
+ if (seg.isParagraphBreak) {
107519
+ paragraphs.push(buildParagraph(current));
107520
+ current = [];
107521
+ } else {
107522
+ current.push(seg);
107523
+ }
107524
+ }
107525
+ if (current.length > 0) {
107526
+ paragraphs.push(buildParagraph(current));
107527
+ }
107528
+ if (paragraphs.length === 0) {
107529
+ paragraphs.push({
107530
+ segments: [{ text: "", style: {} }],
107531
+ bulletType: "none",
107532
+ indentLevel: 0
107533
+ });
107534
+ }
107535
+ return paragraphs;
107536
+ }
107537
+ function paragraphsToSegments(paragraphs) {
107538
+ const result = [];
107539
+ let numberedCounter = 0;
107540
+ paragraphs.forEach((para, pIdx) => {
107541
+ if (para.bulletType === "numbered") {
107542
+ numberedCounter++;
107543
+ } else {
107544
+ numberedCounter = 0;
107545
+ }
107546
+ para.segments.forEach((seg, sIdx) => {
107547
+ const updated = { ...seg, style: { ...seg.style } };
107548
+ if (para.indentLevel > 0) {
107549
+ updated.style.paragraphMarginLeft = para.indentLevel * INDENT_PX;
107550
+ } else {
107551
+ delete updated.style.paragraphMarginLeft;
107552
+ }
107553
+ if (sIdx === 0) {
107554
+ if (para.bulletType === "bullet") {
107555
+ updated.bulletInfo = { char: "\u2022" };
107556
+ } else if (para.bulletType === "numbered") {
107557
+ updated.bulletInfo = {
107558
+ autoNumType: "arabicPeriod",
107559
+ paragraphIndex: numberedCounter - 1
107560
+ };
107561
+ } else {
107562
+ delete updated.bulletInfo;
107563
+ }
107564
+ }
107565
+ result.push(updated);
107566
+ });
107567
+ if (pIdx < paragraphs.length - 1) {
107568
+ result.push({ text: "", style: {}, isParagraphBreak: true });
107569
+ }
107570
+ });
107571
+ return result;
107572
+ }
107573
+ function getCurrentParagraphIndex(editorEl, segments) {
107574
+ const sel = window.getSelection();
107575
+ if (!sel || sel.rangeCount === 0) {
107576
+ return 0;
107577
+ }
107578
+ const range = sel.getRangeAt(0);
107579
+ let charOffset = 0;
107580
+ const walker = document.createTreeWalker(editorEl, NodeFilter.SHOW_TEXT);
107581
+ let node = walker.nextNode();
107582
+ while (node) {
107583
+ if (range.startContainer === node) {
107584
+ charOffset += range.startOffset;
107585
+ break;
107586
+ }
107587
+ charOffset += (node.textContent ?? "").length;
107588
+ node = walker.nextNode();
107589
+ }
107590
+ let paraIdx = 0;
107591
+ let pos2 = 0;
107592
+ for (const seg of segments) {
107593
+ if (seg.isParagraphBreak) {
107594
+ paraIdx++;
107595
+ pos2++;
107596
+ continue;
107597
+ }
107598
+ const segLen = seg.text.length;
107599
+ if (pos2 + segLen > charOffset) {
107600
+ return paraIdx;
107601
+ }
107602
+ pos2 += segLen;
107603
+ }
107604
+ return paraIdx;
107605
+ }
106936
107606
  var BLOCKED_PROTOCOLS = /* @__PURE__ */ new Set([
106937
107607
  `${"javascript"}:`,
106938
107608
  "data:",
@@ -106999,6 +107669,186 @@ function parsePpactionUrl(url) {
106999
107669
  }
107000
107670
  return { action: url, targetSlideIndex };
107001
107671
  }
107672
+ var CSS_VALUE_SAFE = /^[a-zA-Z0-9 _,.\-+#'%/]{1,100}$/u;
107673
+ function isCssValueSafe(value) {
107674
+ if (value === void 0 || value === null) {
107675
+ return false;
107676
+ }
107677
+ const str = String(value);
107678
+ return str.length > 0 && CSS_VALUE_SAFE.test(str);
107679
+ }
107680
+ function deriveStyleFromElement(element, inheritedStyle) {
107681
+ const style = { ...inheritedStyle };
107682
+ const tagName = element.tagName.toLowerCase();
107683
+ if (tagName === "b" || tagName === "strong") {
107684
+ style.bold = true;
107685
+ }
107686
+ if (tagName === "i" || tagName === "em") {
107687
+ style.italic = true;
107688
+ }
107689
+ if (tagName === "u") {
107690
+ style.underline = true;
107691
+ }
107692
+ if (tagName === "s" || tagName === "strike") {
107693
+ style.strikethrough = true;
107694
+ }
107695
+ if (tagName === "a") {
107696
+ const href = element.getAttribute("href");
107697
+ if (href) {
107698
+ style.hyperlink = href;
107699
+ }
107700
+ style.underline = true;
107701
+ style.color = "#4a9eff";
107702
+ }
107703
+ const inlineStyle = element.style;
107704
+ if (inlineStyle.fontWeight === "bold" || Number(inlineStyle.fontWeight) >= 600) {
107705
+ style.bold = true;
107706
+ }
107707
+ if (inlineStyle.fontStyle === "italic") {
107708
+ style.italic = true;
107709
+ }
107710
+ if (inlineStyle.textDecoration.includes("underline") || inlineStyle.textDecorationLine.includes("underline")) {
107711
+ style.underline = true;
107712
+ }
107713
+ if (inlineStyle.textDecoration.includes("line-through") || inlineStyle.textDecorationLine.includes("line-through")) {
107714
+ style.strikethrough = true;
107715
+ }
107716
+ if (inlineStyle.color) {
107717
+ style.color = inlineStyle.color;
107718
+ }
107719
+ const fontSizePt = parsePt(inlineStyle.fontSize);
107720
+ if (fontSizePt !== void 0) {
107721
+ style.fontSize = fontSizePt;
107722
+ }
107723
+ if (inlineStyle.fontFamily) {
107724
+ style.fontFamily = inlineStyle.fontFamily;
107725
+ }
107726
+ return style;
107727
+ }
107728
+ function parseSegmentsFromRichEditor(root) {
107729
+ const segments = [];
107730
+ const walk2 = (node, inheritedStyle) => {
107731
+ if (node.nodeType === Node.TEXT_NODE) {
107732
+ const value = node.textContent ?? "";
107733
+ if (value.length > 0) {
107734
+ segments.push({ text: value, style: { ...inheritedStyle } });
107735
+ }
107736
+ return;
107737
+ }
107738
+ if (!(node instanceof HTMLElement)) {
107739
+ return;
107740
+ }
107741
+ if (node.tagName.toLowerCase() === "br") {
107742
+ segments.push({ text: "", style: {}, isParagraphBreak: true });
107743
+ return;
107744
+ }
107745
+ const nextStyle = deriveStyleFromElement(node, inheritedStyle);
107746
+ const tag = node.tagName.toLowerCase();
107747
+ const isBlock = ["div", "p", "li"].includes(tag);
107748
+ let bulletInfo;
107749
+ let paraIndent = 0;
107750
+ if (isBlock && node.dataset.bulletType) {
107751
+ const bt = node.dataset.bulletType;
107752
+ if (bt === "bullet") {
107753
+ bulletInfo = { char: "\u2022" };
107754
+ } else if (bt === "numbered") {
107755
+ bulletInfo = { autoNumType: "arabicPeriod" };
107756
+ }
107757
+ }
107758
+ if (isBlock && node.dataset.indentLevel) {
107759
+ paraIndent = Number.parseInt(node.dataset.indentLevel, 10) || 0;
107760
+ }
107761
+ const segStartIdx = segments.length;
107762
+ node.childNodes.forEach((child22) => walk2(child22, nextStyle));
107763
+ if (isBlock && (bulletInfo || paraIndent > 0)) {
107764
+ for (let i = segStartIdx; i < segments.length; i++) {
107765
+ if (!segments[i].isParagraphBreak) {
107766
+ if (bulletInfo) {
107767
+ segments[i].bulletInfo = bulletInfo;
107768
+ }
107769
+ if (paraIndent > 0) {
107770
+ segments[i].style = {
107771
+ ...segments[i].style,
107772
+ paragraphMarginLeft: paraIndent * INDENT_PX
107773
+ };
107774
+ }
107775
+ break;
107776
+ }
107777
+ }
107778
+ }
107779
+ if (isBlock) {
107780
+ segments.push({ text: "", style: {}, isParagraphBreak: true });
107781
+ }
107782
+ };
107783
+ root.childNodes.forEach((child22) => walk2(child22, {}));
107784
+ return normalizeSegments(segments);
107785
+ }
107786
+ function segmentsToEditorHtml(segments) {
107787
+ const paragraphs = segmentsToParagraphs(segments);
107788
+ let numberedCounter = 0;
107789
+ return paragraphs.map((para) => {
107790
+ if (para.bulletType === "numbered") {
107791
+ numberedCounter++;
107792
+ } else {
107793
+ numberedCounter = 0;
107794
+ }
107795
+ const runsHtml = para.segments.map((segment) => {
107796
+ if (segment.isParagraphBreak) {
107797
+ return "";
107798
+ }
107799
+ const inlineStyles = [];
107800
+ if (segment.style.bold) {
107801
+ inlineStyles.push("font-weight:700");
107802
+ }
107803
+ if (segment.style.italic) {
107804
+ inlineStyles.push("font-style:italic");
107805
+ }
107806
+ if (segment.style.underline) {
107807
+ inlineStyles.push("text-decoration:underline");
107808
+ }
107809
+ if (segment.style.strikethrough) {
107810
+ inlineStyles.push("text-decoration:line-through");
107811
+ }
107812
+ if (segment.style.color && isCssValueSafe(segment.style.color)) {
107813
+ inlineStyles.push(`color:${segment.style.color}`);
107814
+ }
107815
+ if (segment.style.fontSize && Number.isFinite(Number(segment.style.fontSize))) {
107816
+ inlineStyles.push(`font-size:${Number(segment.style.fontSize)}pt`);
107817
+ }
107818
+ if (segment.style.fontFamily && isCssValueSafe(segment.style.fontFamily)) {
107819
+ inlineStyles.push(`font-family:${segment.style.fontFamily}`);
107820
+ }
107821
+ const text2 = escapeHtml2(segment.text);
107822
+ if (segment.style.hyperlink && isUrlSafe(segment.style.hyperlink)) {
107823
+ const href = escapeHtml2(segment.style.hyperlink);
107824
+ return `<a href="${href}" style="color:#4a9eff;text-decoration:underline;cursor:pointer" data-hyperlink="${href}">${text2}</a>`;
107825
+ }
107826
+ const styleAttr = inlineStyles.length > 0 ? ` style="${inlineStyles.join(";")}"` : "";
107827
+ return `<span${styleAttr}>${text2}</span>`;
107828
+ }).join("");
107829
+ const attrs3 = [];
107830
+ if (para.bulletType !== "none") {
107831
+ attrs3.push(`data-bullet-type="${para.bulletType}"`);
107832
+ }
107833
+ if (para.indentLevel > 0) {
107834
+ attrs3.push(`data-indent-level="${para.indentLevel}"`);
107835
+ }
107836
+ const indent = para.indentLevel * INDENT_PX;
107837
+ const divStyles = [];
107838
+ if (indent > 0) {
107839
+ divStyles.push(`padding-left:${indent}px`);
107840
+ }
107841
+ let prefix = "";
107842
+ if (para.bulletType === "bullet") {
107843
+ prefix = `<span style="margin-right:6px;color:#9ca3af" contenteditable="false">\u2022</span>`;
107844
+ } else if (para.bulletType === "numbered") {
107845
+ prefix = `<span style="margin-right:6px;color:#9ca3af" contenteditable="false">${numberedCounter}.</span>`;
107846
+ }
107847
+ const styleStr = divStyles.length > 0 ? ` style="${divStyles.join(";")}"` : "";
107848
+ const attrStr = attrs3.length > 0 ? ` ${attrs3.join(" ")}` : "";
107849
+ return `<div${attrStr}${styleStr}>${prefix}${runsHtml || "<br />"}</div>`;
107850
+ }).join("");
107851
+ }
107002
107852
  var MOBILE_BREAKPOINT = 768;
107003
107853
  var TABLET_BREAKPOINT = 1024;
107004
107854
  var MOBILE_LANDSCAPE_MAX_HEIGHT = 500;
@@ -108057,6 +108907,29 @@ function resolveParagraphStrutFontSize(segments, bodyFontSize) {
108057
108907
  }
108058
108908
  return largest;
108059
108909
  }
108910
+ var PT_TO_PX = 96 / 72;
108911
+ function resolveParagraphSpacing(input) {
108912
+ const { paraProps, bodyStyle, isFirst = false, isLast = false, spaceFirstLast = true } = input;
108913
+ const out = {};
108914
+ const before = paraProps?.paragraphSpacingBefore ?? bodyStyle?.paragraphSpacingBefore;
108915
+ if (typeof before === "number" && before > 0 && (!isFirst || spaceFirstLast)) {
108916
+ out.spaceBeforePx = before;
108917
+ }
108918
+ const after = paraProps?.paragraphSpacingAfter ?? bodyStyle?.paragraphSpacingAfter;
108919
+ if (typeof after === "number" && after > 0 && (!isLast || spaceFirstLast)) {
108920
+ out.spaceAfterPx = after;
108921
+ }
108922
+ const hasOwnLineSpacing = paraProps?.lineSpacing !== void 0 || paraProps?.lineSpacingExactPt !== void 0;
108923
+ const lineSource = hasOwnLineSpacing ? paraProps : bodyStyle;
108924
+ const exactPt = lineSource?.lineSpacingExactPt;
108925
+ const multiplier = lineSource?.lineSpacing;
108926
+ if (typeof exactPt === "number" && exactPt > 0) {
108927
+ out.lineHeight = `${exactPt * PT_TO_PX}px`;
108928
+ } else if (typeof multiplier === "number" && multiplier > 0) {
108929
+ out.lineHeight = proportionalLineHeight(multiplier);
108930
+ }
108931
+ return out;
108932
+ }
108060
108933
  function parseHexColor(hex10) {
108061
108934
  if (!hex10 || typeof hex10 !== "string") {
108062
108935
  return null;
@@ -113287,6 +114160,17 @@ function fitFontSize(text2, maxWidth, maxHeight, baseSize) {
113287
114160
  const maxByHeight = maxHeight * 0.5;
113288
114161
  return Math.max(6, Math.min(baseSize, maxByWidth, maxByHeight));
113289
114162
  }
114163
+ function chevronPoints(x, y, w, h) {
114164
+ const depth = Math.min(w * 0.2, h * 0.4);
114165
+ return [
114166
+ `${x},${y}`,
114167
+ `${x + w - depth},${y}`,
114168
+ `${x + w},${y + h / 2}`,
114169
+ `${x + w - depth},${y + h}`,
114170
+ `${x},${y + h}`,
114171
+ `${x + depth},${y + h / 2}`
114172
+ ].join(" ");
114173
+ }
113290
114174
  function strokeFor(sw) {
113291
114175
  return sw > 0 ? "rgba(255,255,255,0.3)" : "none";
113292
114176
  }
@@ -115797,6 +116681,28 @@ function centeredSvgTextLines(text2, fontSize, options = {}) {
115797
116681
  y: blockTop + lineHeight / 2 + index * lineHeight
115798
116682
  }));
115799
116683
  }
116684
+ var PALETTES = {
116685
+ colorful1: ["#3b82f6", "#22c55e", "#f97316", "#eab308", "#a855f7", "#ec4899"],
116686
+ colorful2: ["#6366f1", "#14b8a6", "#f59e0b", "#ef4444", "#8b5cf6", "#06b6d4"],
116687
+ colorful3: ["#0ea5e9", "#84cc16", "#f43e5e", "#a855f7", "#f97316", "#10b981"],
116688
+ monochromatic1: ["#3b82f6", "#60a5fa", "#93c5fd", "#bfdbfe", "#2563eb", "#1d4ed8"],
116689
+ monochromatic2: ["#6366f1", "#818cf8", "#a5b4fc", "#c7d2fe", "#4f46e5", "#4338ca"]
116690
+ };
116691
+ var DEFAULT_PALETTE2 = PALETTES.colorful1;
116692
+ function paletteColour(index, palette) {
116693
+ return palette[index % palette.length];
116694
+ }
116695
+ function resolvePalette(data) {
116696
+ if (!data) {
116697
+ return DEFAULT_PALETTE2;
116698
+ }
116699
+ const ctFills = data.colorTransform?.fillColors;
116700
+ if (ctFills && ctFills.length > 0) {
116701
+ return ctFills;
116702
+ }
116703
+ return PALETTES[data.colorScheme ?? "colorful1"] ?? DEFAULT_PALETTE2;
116704
+ }
116705
+ var TEXT_WIDTH_FRACTION = 0.82;
115800
116706
  function underlyingFill(shape, shapes, index) {
115801
116707
  const centerX = shape.x + shape.width / 2;
115802
116708
  const centerY = shape.y + shape.height / 2;
@@ -115815,6 +116721,117 @@ function drawingShapeLabelColor(shape, shapes, index, resolvedFill) {
115815
116721
  const basis = resolvedFill === "none" || resolvedFill.startsWith("url(") ? underlyingFill(shape, shapes, index) : resolvedFill;
115816
116722
  return basis ? contrastTextColor(basis) : "#1a1a1a";
115817
116723
  }
116724
+ function computeDrawingViewBox(shapes) {
116725
+ let minX = Infinity;
116726
+ let minY = Infinity;
116727
+ let maxX = -Infinity;
116728
+ let maxY = -Infinity;
116729
+ for (const s of shapes) {
116730
+ if (s.x < minX) {
116731
+ minX = s.x;
116732
+ }
116733
+ if (s.y < minY) {
116734
+ minY = s.y;
116735
+ }
116736
+ if (s.x + s.width > maxX) {
116737
+ maxX = s.x + s.width;
116738
+ }
116739
+ if (s.y + s.height > maxY) {
116740
+ maxY = s.y + s.height;
116741
+ }
116742
+ }
116743
+ if (!Number.isFinite(minX)) {
116744
+ return { minX: 0, minY: 0, width: 1, height: 1 };
116745
+ }
116746
+ return {
116747
+ minX,
116748
+ minY,
116749
+ width: maxX - minX || 1,
116750
+ height: maxY - minY || 1
116751
+ };
116752
+ }
116753
+ function resolveGradient(shape, id) {
116754
+ const stops = shape.fillGradientStops;
116755
+ if (!stops || stops.length === 0) {
116756
+ return void 0;
116757
+ }
116758
+ const mapped = stops.map((stop) => ({
116759
+ offset: `${Math.max(0, Math.min(100, stop.position))}%`,
116760
+ color: stop.color,
116761
+ ...stop.opacity !== void 0 ? { opacity: stop.opacity } : {}
116762
+ }));
116763
+ if (shape.fillGradientType === "radial") {
116764
+ return { id, kind: "radial", cx: "50%", cy: "50%", r: "50%", stops: mapped };
116765
+ }
116766
+ const radians = (shape.fillGradientAngle ?? 0) * Math.PI / 180;
116767
+ const dx = Math.cos(radians) / 2;
116768
+ const dy = Math.sin(radians) / 2;
116769
+ return {
116770
+ id,
116771
+ kind: "linear",
116772
+ x1: `${(0.5 - dx) * 100}%`,
116773
+ y1: `${(0.5 - dy) * 100}%`,
116774
+ x2: `${(0.5 + dx) * 100}%`,
116775
+ y2: `${(0.5 + dy) * 100}%`,
116776
+ stops: mapped
116777
+ };
116778
+ }
116779
+ function resolveShapeKind(shape, hasImage) {
116780
+ if (hasImage) {
116781
+ return "image";
116782
+ }
116783
+ const normalized = (shape.shapeType ?? "").trim().toLowerCase();
116784
+ if (normalized === "chevron" || normalized === "homeplate") {
116785
+ return "polygon";
116786
+ }
116787
+ return getShapeType(shape.shapeType) === "ellipse" ? "ellipse" : "rect";
116788
+ }
116789
+ function projectDrawingShapes(elementId, shapes, viewBox, palette, style) {
116790
+ const { minX, minY } = viewBox;
116791
+ const sw = styleStroke(style);
116792
+ return shapes.map((shape, i) => {
116793
+ const gradient = shape.fillNone ? void 0 : resolveGradient(shape, `${elementId}-dspgrad-${shape.id}-${i}`);
116794
+ const fill = shape.fillNone ? "none" : gradient ? `url(#${gradient.id})` : shape.fillPatternForegroundColor ?? shape.fillColor ?? paletteColour(i, palette);
116795
+ const relX = shape.x - minX;
116796
+ const relY = shape.y - minY;
116797
+ const kind = resolveShapeKind(shape, Boolean(shape.fillImageUrl));
116798
+ const rx = getShapeType(shape.shapeType) === "roundRect" ? Math.min(shape.width, shape.height) * 0.1 : 0;
116799
+ const cx = relX + shape.width / 2;
116800
+ const cy = relY + shape.height / 2;
116801
+ const stroke = shape.strokeColor ?? (sw > 0 ? "rgba(255,255,255,0.3)" : "none");
116802
+ const transform = shape.rotation !== void 0 ? `rotate(${shape.rotation} ${cx} ${cy})` : void 0;
116803
+ const fontSize = shape.fontSize ?? Math.max(8, Math.min(14, shape.height * 0.2));
116804
+ return {
116805
+ key: `${elementId}-dsp-${shape.id}-${i}`,
116806
+ kind,
116807
+ ...kind === "polygon" ? { points: chevronPoints(relX, relY, shape.width, shape.height) } : {},
116808
+ ...gradient ? { gradient } : {},
116809
+ x: relX,
116810
+ y: relY,
116811
+ width: shape.width,
116812
+ height: shape.height,
116813
+ rx,
116814
+ cx,
116815
+ cy,
116816
+ fill,
116817
+ stroke,
116818
+ strokeWidth: shape.strokeWidth ?? sw,
116819
+ transform,
116820
+ imageUrl: shape.fillImageUrl,
116821
+ textLines: shape.text ? centeredSvgTextLines(shape.text, fontSize, {
116822
+ maxWidth: shape.width * TEXT_WIDTH_FRACTION,
116823
+ centerY: cy
116824
+ }) : [],
116825
+ textX: cx,
116826
+ textY: cy,
116827
+ fontColor: shape.fontColor ?? drawingShapeLabelColor(shape, shapes, i, fill),
116828
+ fontSize
116829
+ };
116830
+ });
116831
+ }
116832
+ function styleShadowFilter(style) {
116833
+ return styleShadow(style);
116834
+ }
115818
116835
  var FONT_NAME_UNSAFE_CHARS = /["\\\n\r;}<>]/u;
115819
116836
  var FONT_FORMAT_ALLOWED = /* @__PURE__ */ new Set(["truetype", "opentype", "woff", "woff2"]);
115820
116837
  var FONT_DATA_URL_PATTERN = /^data:font\/[a-z0-9+.-]+(?:;charset=[a-z0-9-]+)?;base64,[a-z0-9+/=]+$/iu;
@@ -118797,6 +119814,97 @@ var DUOTONE_PRESETS = [
118797
119814
  highlight: "#F5DEB3"
118798
119815
  }
118799
119816
  ];
119817
+ function findInSlides(slides, query, opts = {}) {
119818
+ if (!query) {
119819
+ return [];
119820
+ }
119821
+ const matchCase = opts.matchCase ?? false;
119822
+ const normalised = matchCase ? query : query.toLowerCase();
119823
+ const results = [];
119824
+ for (let slideIndex = 0; slideIndex < slides.length; slideIndex++) {
119825
+ const slide = slides[slideIndex];
119826
+ for (const element of slide.elements) {
119827
+ if (!hasTextProperties(element)) {
119828
+ continue;
119829
+ }
119830
+ const segments = element.textSegments ?? [];
119831
+ for (let segIndex = 0; segIndex < segments.length; segIndex++) {
119832
+ const raw = segments[segIndex].text ?? "";
119833
+ const haystack = matchCase ? raw : raw.toLowerCase();
119834
+ let offset = 0;
119835
+ while (offset < haystack.length) {
119836
+ const pos2 = haystack.indexOf(normalised, offset);
119837
+ if (pos2 === -1) {
119838
+ break;
119839
+ }
119840
+ results.push({
119841
+ slideIndex,
119842
+ elementId: element.id,
119843
+ segmentIndex: segIndex,
119844
+ startOffset: pos2,
119845
+ length: query.length
119846
+ });
119847
+ offset = pos2 + 1;
119848
+ }
119849
+ }
119850
+ }
119851
+ }
119852
+ return results;
119853
+ }
119854
+ function applyFindReplacements(slides, toReplace, replacement) {
119855
+ if (toReplace.length === 0) {
119856
+ return { slides, replacements: 0 };
119857
+ }
119858
+ const grouped = /* @__PURE__ */ new Map();
119859
+ for (const match of toReplace) {
119860
+ const key = `${match.slideIndex}::${match.elementId}::${match.segmentIndex}`;
119861
+ let bucket = grouped.get(key);
119862
+ if (!bucket) {
119863
+ bucket = [];
119864
+ grouped.set(key, bucket);
119865
+ }
119866
+ bucket.push(match);
119867
+ }
119868
+ const nextSlides = slides.slice();
119869
+ let totalReplacements = 0;
119870
+ for (const [, matches] of grouped) {
119871
+ const sorted = matches.slice().sort((a, b) => b.startOffset - a.startOffset);
119872
+ for (const match of sorted) {
119873
+ const slide = nextSlides[match.slideIndex];
119874
+ if (!slide) {
119875
+ continue;
119876
+ }
119877
+ const elIdx = slide.elements.findIndex((e) => e.id === match.elementId);
119878
+ if (elIdx === -1) {
119879
+ continue;
119880
+ }
119881
+ const element = slide.elements[elIdx];
119882
+ if (!hasTextProperties(element)) {
119883
+ continue;
119884
+ }
119885
+ const segments = element.textSegments ?? [];
119886
+ const seg = segments[match.segmentIndex];
119887
+ if (!seg) {
119888
+ continue;
119889
+ }
119890
+ const before = seg.text.slice(0, match.startOffset);
119891
+ const after = seg.text.slice(match.startOffset + match.length);
119892
+ const newSegText = before + replacement + after;
119893
+ const nextSegments = segments.slice();
119894
+ nextSegments[match.segmentIndex] = { ...seg, text: newSegText };
119895
+ const nextText = nextSegments.map((s) => s.text).join("");
119896
+ const nextElements = slide.elements.slice();
119897
+ nextElements[elIdx] = {
119898
+ ...element,
119899
+ text: nextText,
119900
+ textSegments: nextSegments
119901
+ };
119902
+ nextSlides[match.slideIndex] = { ...slide, elements: nextElements };
119903
+ totalReplacements++;
119904
+ }
119905
+ }
119906
+ return { slides: nextSlides, replacements: totalReplacements };
119907
+ }
118800
119908
  function isElementHidden(element) {
118801
119909
  return element?.hidden === true;
118802
119910
  }
@@ -120488,6 +121596,24 @@ var COMMON_FONTS = [
120488
121596
  "Tw Cen MT",
120489
121597
  "Verdana"
120490
121598
  ];
121599
+ function partitionTemplateElements(slides) {
121600
+ const templateElementsBySlideId = {};
121601
+ const nextSlides = slides.map((slide) => {
121602
+ const template = slide.elements.filter(isTemplateElement);
121603
+ if (template.length === 0) {
121604
+ return slide;
121605
+ }
121606
+ templateElementsBySlideId[slide.id] = template;
121607
+ return { ...slide, elements: slide.elements.filter((element) => !isTemplateElement(element)) };
121608
+ });
121609
+ return { slides: nextSlides, templateElementsBySlideId };
121610
+ }
121611
+ function buildSaveSlides(slides, templateElementsBySlideId) {
121612
+ return slides.map((slide) => {
121613
+ const template = templateElementsBySlideId[slide.id];
121614
+ return template?.length ? { ...slide, elements: [...template, ...slide.elements] } : slide;
121615
+ });
121616
+ }
120491
121617
  var DEFAULT_PREVIEW_ELEMENT_CAP = 500;
120492
121618
  function buildPreviewElements(slide, templateElements = [], options) {
120493
121619
  const cap = options?.cap ?? DEFAULT_PREVIEW_ELEMENT_CAP;
@@ -123771,14 +124897,14 @@ ${xrefPos}
123771
124897
  }
123772
124898
  var NOTE_LINE_COUNT = 8;
123773
124899
  var TRANSPARENT_PNG = "data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mNgAAIAAAUAAen63NgAAAAASUVORK5CYII=";
123774
- function escapeHtml2(value) {
124900
+ function escapeHtml22(value) {
123775
124901
  return value.split("&").join("&amp;").split("<").join("&lt;").split(">").join("&gt;").split('"').join("&quot;").split("'").join("&#39;");
123776
124902
  }
123777
124903
  function safeDataImageSrc(src) {
123778
124904
  if (typeof src !== "string" || !src.startsWith("data:image/")) {
123779
124905
  return TRANSPARENT_PNG;
123780
124906
  }
123781
- return escapeHtml2(src);
124907
+ return escapeHtml22(src);
123782
124908
  }
123783
124909
  function slideTitle(slide, index) {
123784
124910
  const fallback = `Slide ${index + 1}`;
@@ -123804,7 +124930,7 @@ function buildOutlineHtml(slideIndices, slides) {
123804
124930
  }
123805
124931
  const titleText = slideTitle(slide, idx);
123806
124932
  const notes = (slide.notes ?? "").trim();
123807
- return `<h2>${escapeHtml2(titleText)}</h2>${notes ? `<p>${escapeHtml2(notes)}</p>` : ""}`;
124933
+ return `<h2>${escapeHtml22(titleText)}</h2>${notes ? `<p>${escapeHtml22(notes)}</p>` : ""}`;
123808
124934
  }).join("");
123809
124935
  }
123810
124936
  function buildSlidesHtml(slideImages, slideIndices) {
@@ -123818,7 +124944,7 @@ function buildNotesHtml(slideImages, slideIndices, slides) {
123818
124944
  const notes = (slides[idx]?.notes ?? "").trim();
123819
124945
  return `<section class="page notes-page">
123820
124946
  <img class="notes-slide" src="${safeDataImageSrc(img)}" alt="Slide ${idx + 1}" />
123821
- <div class="notes-text">${escapeHtml2(notes)}</div>
124947
+ <div class="notes-text">${escapeHtml22(notes)}</div>
123822
124948
  </section>`;
123823
124949
  }).join("");
123824
124950
  }
@@ -123886,7 +125012,7 @@ function buildPrintHtmlDocument(options) {
123886
125012
  <html>
123887
125013
  <head>
123888
125014
  <meta charset="utf-8" />
123889
- <title>${escapeHtml2(title)}</title>
125015
+ <title>${escapeHtml22(title)}</title>
123890
125016
  <style>
123891
125017
  :root { color-scheme: light; }
123892
125018
  * { box-sizing: border-box; }
@@ -123995,12 +125121,14 @@ exports.CHARACTER_SPACING_OPTIONS = CHARACTER_SPACING_OPTIONS;
123995
125121
  exports.COLOR_MAP_ALIAS_KEYS = COLOR_MAP_ALIAS_KEYS;
123996
125122
  exports.COMMON_FONTS = COMMON_FONTS;
123997
125123
  exports.CONNECTION_TIMEOUT_MS = CONNECTION_TIMEOUT_MS;
125124
+ exports.DEBOUNCE_MS = DEBOUNCE_MS;
123998
125125
  exports.DEFAULT_BROADCAST_SERVER_URL = DEFAULT_BROADCAST_SERVER_URL;
123999
125126
  exports.DEFAULT_COLOR_CHANGE_TOLERANCE = DEFAULT_COLOR_CHANGE_TOLERANCE;
124000
125127
  exports.DEFAULT_COLOR_MAP = DEFAULT_COLOR_MAP;
124001
125128
  exports.DEFAULT_FONT_FAMILY = DEFAULT_FONT_FAMILY;
124002
125129
  exports.DEFAULT_INSERT_CHART_KIND = DEFAULT_INSERT_CHART_KIND;
124003
125130
  exports.DEFAULT_MOTION_PATH_PRESET_ID = DEFAULT_MOTION_PATH_PRESET_ID;
125131
+ exports.DEFAULT_PALETTE2 = DEFAULT_PALETTE2;
124004
125132
  exports.DEFAULT_QUICK_ACCESS_COMMAND_IDS = DEFAULT_QUICK_ACCESS_COMMAND_IDS;
124005
125133
  exports.DEFAULT_ROW_HEIGHT = DEFAULT_ROW_HEIGHT;
124006
125134
  exports.DEFAULT_VIEWER_OPTIONS = DEFAULT_VIEWER_OPTIONS;
@@ -124013,6 +125141,7 @@ exports.EMPHASIS_PRESET_VALUES = EMPHASIS_PRESET_VALUES;
124013
125141
  exports.ENTRANCE_PRESET_VALUES = ENTRANCE_PRESET_VALUES;
124014
125142
  exports.EQUATION_TEMPLATES = EQUATION_TEMPLATES;
124015
125143
  exports.EXIT_PRESET_VALUES = EXIT_PRESET_VALUES;
125144
+ exports.EXPANDED_MAX_HEIGHT = EXPANDED_MAX_HEIGHT;
124016
125145
  exports.EXPORT_ASSEMBLING_PERCENT = EXPORT_ASSEMBLING_PERCENT;
124017
125146
  exports.EXPORT_DONE_PERCENT = EXPORT_DONE_PERCENT;
124018
125147
  exports.EncryptedFileError = EncryptedFileError;
@@ -124023,6 +125152,7 @@ exports.HANDOUT_OPTIONS = HANDOUT_OPTIONS;
124023
125152
  exports.HIDDEN_SLIDE_LABEL_KEY = HIDDEN_SLIDE_LABEL_KEY;
124024
125153
  exports.HIDDEN_SLIDE_SLASH_GRADIENT = HIDDEN_SLIDE_SLASH_GRADIENT;
124025
125154
  exports.HIGHLIGHTER_COLORS = HIGHLIGHTER_COLORS;
125155
+ exports.INDENT_PX = INDENT_PX;
124026
125156
  exports.INK_REPLAY_KEYFRAMES = INK_REPLAY_KEYFRAMES;
124027
125157
  exports.INSERT_CHART_TYPES = INSERT_CHART_TYPES;
124028
125158
  exports.LBL = LBL;
@@ -124033,6 +125163,7 @@ exports.LINK_TOOLTIP_LABEL_CLASS = LINK_TOOLTIP_LABEL_CLASS;
124033
125163
  exports.LINK_TOOLTIP_PANEL_CLASS = LINK_TOOLTIP_PANEL_CLASS;
124034
125164
  exports.LOCAL_SYNC_ORIGIN = LOCAL_SYNC_ORIGIN;
124035
125165
  exports.MATERIAL_PRESETS = MATERIAL_PRESETS;
125166
+ exports.MAX_INDENT_LEVEL = MAX_INDENT_LEVEL;
124036
125167
  exports.MAX_ZOOM_SCALE = MAX_ZOOM_SCALE;
124037
125168
  exports.MEDIA_CHROME_ATTRIBUTE = MEDIA_CHROME_ATTRIBUTE;
124038
125169
  exports.MIN_ZOOM_SCALE = MIN_ZOOM_SCALE;
@@ -124126,6 +125257,7 @@ exports.applyCaseTransformToSegments = applyCaseTransformToSegments;
124126
125257
  exports.applyChartBuildReveal = applyChartBuildReveal;
124127
125258
  exports.applyColorChange = applyColorChange;
124128
125259
  exports.applyDuotone = applyDuotone;
125260
+ exports.applyFindReplacements = applyFindReplacements;
124129
125261
  exports.applyFormatToElement = applyFormatToElement;
124130
125262
  exports.applyMotionPathPreset = applyMotionPathPreset;
124131
125263
  exports.applyOutlineEdit = applyOutlineEdit;
@@ -124176,6 +125308,7 @@ exports.buildPreviewElements = buildPreviewElements;
124176
125308
  exports.buildPrintDocument = buildPrintDocument;
124177
125309
  exports.buildPrintHtmlDocument = buildPrintHtmlDocument;
124178
125310
  exports.buildReflectionCss = buildReflectionCss;
125311
+ exports.buildSaveSlides = buildSaveSlides;
124179
125312
  exports.buildShadowCssFromShapeStyle = buildShadowCssFromShapeStyle;
124180
125313
  exports.buildSlideTemplateContent = buildSlideTemplateContent;
124181
125314
  exports.buildSlideTemplateSlide = buildSlideTemplateSlide;
@@ -124197,12 +125330,13 @@ exports.buildTextRunFilterChain = buildTextRunFilterChain;
124197
125330
  exports.buildTextShadowCss = buildTextShadowCss;
124198
125331
  exports.buildThemeColorGrid = buildThemeColorGrid;
124199
125332
  exports.buildThemeColorMap = buildThemeColorMap;
125333
+ exports.buildTree = buildTree;
124200
125334
  exports.buildUserFontFaceStyles = buildUserFontFaceStyles;
124201
125335
  exports.canCommitActionType = canCommitActionType;
124202
125336
  exports.canGoNext = canGoNext;
124203
125337
  exports.canGoPrevious = canGoPrevious;
124204
125338
  exports.canvasToJpegData = canvasToJpegData;
124205
- exports.cell3DBevelCss = cell3DBevelCss;
125339
+ exports.cellStyleToCss = cellStyleToCss;
124206
125340
  exports.centeredSvgTextLines = centeredSvgTextLines;
124207
125341
  exports.chartAreaFill = chartAreaFill;
124208
125342
  exports.chartDataChangeType = chartDataChangeType;
@@ -124231,6 +125365,7 @@ exports.compileEquationTemplateMathMl = compileEquationTemplateMathMl;
124231
125365
  exports.compileLatexEquation = compileLatexEquation;
124232
125366
  exports.computeAllNotesPages = computeAllNotesPages;
124233
125367
  exports.computeColumnBoundaries = computeColumnBoundaries;
125368
+ exports.computeDrawingViewBox = computeDrawingViewBox;
124234
125369
  exports.computeEntranceAnimationDelay = computeEntranceAnimationDelay;
124235
125370
  exports.computeHandoutLayout = computeHandoutLayout;
124236
125371
  exports.computeInlineEditorRect = computeInlineEditorRect;
@@ -124260,6 +125395,7 @@ exports.createCollaborationLivePatcher = createCollaborationLivePatcher;
124260
125395
  exports.createDefaultChartElement = createDefaultChartElement;
124261
125396
  exports.createDepartureChannel = createDepartureChannel;
124262
125397
  exports.createInitialPresentationSnapshot = createInitialPresentationSnapshot;
125398
+ exports.createPlainNotesSegments = createPlainNotesSegments;
124263
125399
  exports.createPresenceProjector = createPresenceProjector;
124264
125400
  exports.createPresentationKeyBuffer = createPresentationKeyBuffer;
124265
125401
  exports.createPresentationSessionId = createPresentationSessionId;
@@ -124288,21 +125424,23 @@ exports.downloadBlob = downloadBlob;
124288
125424
  exports.downloadDataUrl = downloadDataUrl;
124289
125425
  exports.dragAnchorViewY = dragAnchorViewY;
124290
125426
  exports.dragValueForPart = dragValueForPart;
124291
- exports.drawingShapeLabelColor = drawingShapeLabelColor;
124292
125427
  exports.elementActionToPptxAction = elementActionToPptxAction;
124293
125428
  exports.encodeGif = encodeGif;
124294
125429
  exports.endAudienceDisplay = endAudienceDisplay;
124295
125430
  exports.ensureActionAffordanceStyles = ensureActionAffordanceStyles;
124296
125431
  exports.erasePresentationInkAt = erasePresentationInkAt;
125432
+ exports.escapeHtml2 = escapeHtml22;
124297
125433
  exports.exportDeckJson = exportDeckJson;
124298
125434
  exports.extraQuickAccessCommands = extraQuickAccessCommands;
124299
125435
  exports.extractPathPoints = extractPathPoints;
124300
125436
  exports.filterCommands = filterCommands;
124301
125437
  exports.filterRenderedElements = filterRenderedElements;
124302
125438
  exports.findChartPartTarget = findChartPartTarget;
125439
+ exports.findInSlides = findInSlides;
124303
125440
  exports.findMediaElementByElementId = findMediaElementByElementId;
124304
125441
  exports.findSmartArtNodeText = findSmartArtNodeText;
124305
125442
  exports.firstShowSlideIndex = firstShowSlideIndex;
125443
+ exports.fitFontSize = fitFontSize;
124306
125444
  exports.flattenTagCollections = flattenTagCollections;
124307
125445
  exports.forgetSessionDeck = forgetSessionDeck;
124308
125446
  exports.formatAxisValue = formatAxisValue;
@@ -124343,6 +125481,7 @@ exports.getComputedEffectStyle = getComputedEffectStyle;
124343
125481
  exports.getConnectionSites = getConnectionSites;
124344
125482
  exports.getContentPartReplayStyles = getContentPartReplayStyles;
124345
125483
  exports.getCssBorderDashStyle = getCssBorderDashStyle;
125484
+ exports.getCurrentParagraphIndex = getCurrentParagraphIndex;
124346
125485
  exports.getDisplayUnitLabel = getDisplayUnitLabel;
124347
125486
  exports.getDuotoneCachedResult = getDuotoneCachedResult;
124348
125487
  exports.getEffectDagFilter = getEffectDagFilter;
@@ -124382,6 +125521,7 @@ exports.getSoftEdgeFilterId = getSoftEdgeFilterId;
124382
125521
  exports.getSoftEdgeSvgFilter = getSoftEdgeSvgFilter;
124383
125522
  exports.getSubstituteFontFamily = getSubstituteFontFamily;
124384
125523
  exports.getSvgStrokeDasharray = getSvgStrokeDasharray;
125524
+ exports.getTableCellBandStyle = getTableCellBandStyle;
124385
125525
  exports.getTextAlphaOpacity = getTextAlphaOpacity;
124386
125526
  exports.getTextCompensationTransform = getTextCompensationTransform;
124387
125527
  exports.getWarpPath = getWarpPath;
@@ -124423,7 +125563,6 @@ exports.isPpactionUrl = isPpactionUrl;
124423
125563
  exports.isPresentationAdvanceClick = isPresentationAdvanceClick;
124424
125564
  exports.isPresentationSessionMessage = isPresentationSessionMessage;
124425
125565
  exports.isStrokeOnlyPresetElement = isStrokeOnlyPresetElement;
124426
- exports.isTemplateElement = isTemplateElement;
124427
125566
  exports.isTemplateElementId = isTemplateElementId2;
124428
125567
  exports.isUrlSafe = isUrlSafe;
124429
125568
  exports.lastShowSlideIndex = lastShowSlideIndex;
@@ -124469,13 +125608,14 @@ exports.moveSlidesToSection = moveSlidesToSection;
124469
125608
  exports.newTableElement = newTableElement;
124470
125609
  exports.nextPresentedSlide = nextPresentedSlide;
124471
125610
  exports.nextShowSlideIndex = nextShowSlideIndex;
125611
+ exports.nodeOpacity = nodeOpacity;
124472
125612
  exports.normalizeColorsForCapture = normalizeColorsForCapture;
124473
125613
  exports.normalizeHexColor = normalizeHexColor;
125614
+ exports.normalizeSegments = normalizeSegments;
124474
125615
  exports.normalizeStrokeDashType = normalizeStrokeDashType;
124475
125616
  exports.normalizeValue = normalizeValue;
124476
125617
  exports.notesSegmentsToSpans = notesSegmentsToSpans;
124477
125618
  exports.observeYDocSlides = observeYDocSlides;
124478
- exports.ooxmlDashToCssBorderStyle = ooxmlDashToCssBorderStyle;
124479
125619
  exports.ooxmlGradientAngleToCssDegrees = ooxmlGradientAngleToCssDegrees;
124480
125620
  exports.openNativeEyeDropper = openNativeEyeDropper;
124481
125621
  exports.openPptxFile = openPptxFile;
@@ -124483,10 +125623,14 @@ exports.openReadingView = openReadingView;
124483
125623
  exports.openUrlInNewTab = openUrlInNewTab;
124484
125624
  exports.paintedStrokeWidth = paintedStrokeWidth;
124485
125625
  exports.paletteColor = paletteColor;
125626
+ exports.paletteColour = paletteColour;
125627
+ exports.paragraphsToSegments = paragraphsToSegments;
124486
125628
  exports.parseDrawingColor = parseDrawingColor;
124487
125629
  exports.parseDrawingColorOpacity = parseDrawingColorOpacity;
124488
125630
  exports.parsePanoseString = parsePanoseString;
124489
125631
  exports.parsePpactionUrl = parsePpactionUrl;
125632
+ exports.parseSegmentsFromRichEditor = parseSegmentsFromRichEditor;
125633
+ exports.partitionTemplateElements = partitionTemplateElements;
124490
125634
  exports.pickSupportedMimeType = pickSupportedMimeType;
124491
125635
  exports.pieceLetterSpacing = pieceLetterSpacing;
124492
125636
  exports.placeAudienceWindow = placeAudienceWindow;
@@ -124504,8 +125648,8 @@ exports.pressuresToWidths = pressuresToWidths;
124504
125648
  exports.previousShowSlideIndex = previousShowSlideIndex;
124505
125649
  exports.printPropertiesFrameSlides = printPropertiesFrameSlides;
124506
125650
  exports.printPropertiesSlidesPerPage = printPropertiesSlidesPerPage;
125651
+ exports.projectDrawingShapes = projectDrawingShapes;
124507
125652
  exports.promoteSmartArtNode = promoteSmartArtNode;
124508
- exports.proportionalLineHeight = proportionalLineHeight;
124509
125653
  exports.publishLiveGeometry = publishLiveGeometry;
124510
125654
  exports.publishLiveInlineText = publishLiveInlineText;
124511
125655
  exports.quickStyleSwatchCss = quickStyleSwatchCss;
@@ -124544,15 +125688,16 @@ exports.resolveCssTextAlign = resolveCssTextAlign;
124544
125688
  exports.resolveDrawingShapeNodeId = resolveDrawingShapeNodeId;
124545
125689
  exports.resolveElementActionAffordance = resolveElementActionAffordance;
124546
125690
  exports.resolveFontForScript = resolveFontForScript;
124547
- exports.resolveFontRefIdx = resolveFontRefIdx;
124548
125691
  exports.resolveGroupChildFill = resolveGroupChildFill;
124549
125692
  exports.resolveInkColor = resolveInkColor;
124550
125693
  exports.resolveInkOpacity = resolveInkOpacity;
124551
125694
  exports.resolveInkWidth = resolveInkWidth;
124552
125695
  exports.resolveMetricTrackingPx = resolveMetricTrackingPx;
124553
125696
  exports.resolveOleType = resolveOleType;
125697
+ exports.resolvePalette = resolvePalette;
124554
125698
  exports.resolveParagraphAlign = resolveParagraphAlign;
124555
125699
  exports.resolveParagraphRtl = resolveParagraphRtl;
125700
+ exports.resolveParagraphSpacing = resolveParagraphSpacing;
124556
125701
  exports.resolveParagraphStrutFontSize = resolveParagraphStrutFontSize;
124557
125702
  exports.resolvePictureBullet = resolvePictureBullet;
124558
125703
  exports.resolveProfileInitial = resolveProfileInitial;
@@ -124581,6 +125726,9 @@ exports.scanAvailableFontFamilies = scanAvailableFontFamilies;
124581
125726
  exports.schemaLabel = schemaLabel;
124582
125727
  exports.segmentByScript = segmentByScript;
124583
125728
  exports.segmentFrameCount = segmentFrameCount;
125729
+ exports.segmentsToEditorHtml = segmentsToEditorHtml;
125730
+ exports.segmentsToParagraphs = segmentsToParagraphs;
125731
+ exports.segmentsToPlainText = segmentsToPlainText;
124584
125732
  exports.sendBackward = sendBackward;
124585
125733
  exports.sendToBack = sendToBack;
124586
125734
  exports.sequentialColorScale = sequentialColorScale;
@@ -124603,7 +125751,6 @@ exports.setMotionPathEnd = setMotionPathEnd;
124603
125751
  exports.setPendingSelectionRestore = setPendingSelectionRestore;
124604
125752
  exports.setSmartArtNodeStyle = setSmartArtNodeStyle;
124605
125753
  exports.setTableElementCellText = setTableElementCellText;
124606
- exports.shadeColor2 = shadeColor2;
124607
125754
  exports.shouldAutoFollowBroadcaster = shouldAutoFollowBroadcaster;
124608
125755
  exports.shouldCommitSmartArtNodeText = shouldCommitSmartArtNodeText;
124609
125756
  exports.shouldConfirmExternalHyperlink = shouldConfirmExternalHyperlink;
@@ -124619,6 +125766,9 @@ exports.stepPresenterZoom = stepPresenterZoom;
124619
125766
  exports.stopAllPersistentAudio = stopAllPersistentAudio;
124620
125767
  exports.storeAudienceContent = storeAudienceContent;
124621
125768
  exports.strokeOutlineViewBox = strokeOutlineViewBox;
125769
+ exports.styleShadow = styleShadow;
125770
+ exports.styleShadowFilter = styleShadowFilter;
125771
+ exports.styleStroke = styleStroke;
124622
125772
  exports.substituteFieldText = substituteFieldText;
124623
125773
  exports.suppressesCssBorder = suppressesCssBorder;
124624
125774
  exports.svgGradientFillRef = svgGradientFillRef;
@@ -124633,7 +125783,6 @@ exports.textBuildSpanStyle = textBuildSpanStyle;
124633
125783
  exports.themeColorLabel = themeColorLabel;
124634
125784
  exports.themeColorSchemesEqual = themeColorSchemesEqual;
124635
125785
  exports.themeToCssVars = themeToCssVars;
124636
- exports.tintColor2 = tintColor2;
124637
125786
  exports.toCssTextOrientation = toCssTextOrientation;
124638
125787
  exports.toCssVerticalDirection = toCssVerticalDirection;
124639
125788
  exports.toCssWritingMode = toCssWritingMode;
@@ -124642,6 +125791,9 @@ exports.toggleBlackboard = toggleBlackboard;
124642
125791
  exports.togglePresenterTimer = togglePresenterTimer;
124643
125792
  exports.toggleText3dExtrusion = toggleText3dExtrusion;
124644
125793
  exports.transformTextCase = transformTextCase;
125794
+ exports.treeDepth = treeDepth2;
125795
+ exports.treeWidth = treeWidth2;
125796
+ exports.truncate = truncate;
124645
125797
  exports.updateCellTextInRawXml = updateCellTextInRawXml;
124646
125798
  exports.updateCellTextStyleInRawXml = updateCellTextStyleInRawXml;
124647
125799
  exports.updateMergeAttrsInRawXml = updateMergeAttrsInRawXml;