pptx-react-viewer 2.13.1 → 2.14.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.
Files changed (132) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/dist/{AiChatPanel-FXPGFU6H.js → AiChatPanel-BJDFFVJG.js} +23 -23
  3. package/dist/AiChatPanel-BJDFFVJG.js.br +0 -0
  4. package/dist/AiChatPanel-BJDFFVJG.js.gz +0 -0
  5. package/dist/{AiChatPanel-WMGS5TNX.mjs → AiChatPanel-UJUN6HB3.mjs} +4 -4
  6. package/dist/AiChatPanel-UJUN6HB3.mjs.br +0 -0
  7. package/dist/AiChatPanel-UJUN6HB3.mjs.gz +0 -0
  8. package/dist/{Model3DScene-K5FPZTRG.js → Model3DScene-F53NQFY7.js} +2 -2
  9. package/dist/Model3DScene-F53NQFY7.js.br +0 -0
  10. package/dist/Model3DScene-F53NQFY7.js.gz +0 -0
  11. package/dist/{Model3DScene-E2XRQAMR.mjs → Model3DScene-LVFHZUVF.mjs} +1 -1
  12. package/dist/Model3DScene-LVFHZUVF.mjs.br +0 -0
  13. package/dist/Model3DScene-LVFHZUVF.mjs.gz +0 -0
  14. package/dist/{PowerPointViewer-Cjn1RgSz.d.ts → PowerPointViewer-Du7u4INi.d.ts} +2 -2
  15. package/dist/{PowerPointViewer-Cjn1RgSz.d.ts.map → PowerPointViewer-Du7u4INi.d.ts.map} +1 -1
  16. package/dist/{SurfaceChart3DScene-JDCFTXYT.js → SurfaceChart3DScene-IDJDIHVC.js} +2 -2
  17. package/dist/SurfaceChart3DScene-IDJDIHVC.js.br +0 -0
  18. package/dist/SurfaceChart3DScene-IDJDIHVC.js.gz +0 -0
  19. package/dist/{SurfaceChart3DScene-2W2IFPLE.mjs → SurfaceChart3DScene-MVBQTD6J.mjs} +1 -1
  20. package/dist/{SurfaceChart3DScene-2W2IFPLE.mjs.br → SurfaceChart3DScene-MVBQTD6J.mjs.br} +0 -0
  21. package/dist/SurfaceChart3DScene-MVBQTD6J.mjs.gz +0 -0
  22. package/dist/{audience-content-store-BMlth_3U.d.ts → audience-content-store-DaABTAcQ.d.ts} +2 -2
  23. package/dist/{audience-content-store-BMlth_3U.d.ts.map → audience-content-store-DaABTAcQ.d.ts.map} +1 -1
  24. package/dist/{chunk-CQ2CKMG4.mjs → chunk-2KRHLUCG.mjs} +37 -3
  25. package/dist/chunk-2KRHLUCG.mjs.br +0 -0
  26. package/dist/chunk-2KRHLUCG.mjs.gz +0 -0
  27. package/dist/{chunk-BXAK3JFM.js → chunk-3ISYPBSX.js} +74 -2
  28. package/dist/chunk-3ISYPBSX.js.br +0 -0
  29. package/dist/chunk-3ISYPBSX.js.gz +0 -0
  30. package/dist/{chunk-OWGPRVRK.mjs → chunk-5MMC7ZR3.mjs} +8532 -576
  31. package/dist/chunk-5MMC7ZR3.mjs.br +0 -0
  32. package/dist/chunk-5MMC7ZR3.mjs.gz +0 -0
  33. package/dist/{chunk-TEXIGSA6.mjs → chunk-5YV26HMJ.mjs} +74 -2
  34. package/dist/chunk-5YV26HMJ.mjs.br +0 -0
  35. package/dist/chunk-5YV26HMJ.mjs.gz +0 -0
  36. package/dist/{chunk-QFNJCEMS.js → chunk-7TEZJZ2O.js} +572 -427
  37. package/dist/chunk-7TEZJZ2O.js.br +0 -0
  38. package/dist/chunk-7TEZJZ2O.js.gz +0 -0
  39. package/dist/{chunk-3OV4FR6S.mjs → chunk-GROIHKI5.mjs} +11166 -10887
  40. package/dist/chunk-GROIHKI5.mjs.br +0 -0
  41. package/dist/chunk-GROIHKI5.mjs.gz +0 -0
  42. package/dist/{chunk-ZMIFFURL.js → chunk-HOIF5RQI.js} +12315 -12034
  43. package/dist/chunk-HOIF5RQI.js.br +0 -0
  44. package/dist/chunk-HOIF5RQI.js.gz +0 -0
  45. package/dist/{chunk-DD2YRS6Z.js → chunk-PB7KVDNV.js} +8551 -582
  46. package/dist/chunk-PB7KVDNV.js.br +0 -0
  47. package/dist/chunk-PB7KVDNV.js.gz +0 -0
  48. package/dist/{chunk-PTFCMG3A.js → chunk-QVQDC7HZ.js} +39 -5
  49. package/dist/chunk-QVQDC7HZ.js.br +0 -0
  50. package/dist/chunk-QVQDC7HZ.js.gz +0 -0
  51. package/dist/{chunk-GJEH27GD.mjs → chunk-R7MGJCZN.mjs} +285 -325
  52. package/dist/chunk-R7MGJCZN.mjs.br +0 -0
  53. package/dist/chunk-R7MGJCZN.mjs.gz +0 -0
  54. package/dist/{chunk-66ZHD7Y4.js → chunk-SMECSYCT.js} +527 -567
  55. package/dist/chunk-SMECSYCT.js.br +0 -0
  56. package/dist/chunk-SMECSYCT.js.gz +0 -0
  57. package/dist/{chunk-H5H57XMH.mjs → chunk-T4NHPN76.mjs} +249 -104
  58. package/dist/chunk-T4NHPN76.mjs.br +0 -0
  59. package/dist/chunk-T4NHPN76.mjs.gz +0 -0
  60. package/dist/i18n.js +4 -4
  61. package/dist/i18n.js.br +0 -0
  62. package/dist/i18n.js.gz +0 -0
  63. package/dist/i18n.mjs +1 -1
  64. package/dist/i18n.mjs.br +0 -0
  65. package/dist/i18n.mjs.gz +0 -0
  66. package/dist/index.d.ts +139 -5
  67. package/dist/index.d.ts.map +1 -1
  68. package/dist/index.js +56 -36
  69. package/dist/index.js.br +0 -0
  70. package/dist/index.js.gz +0 -0
  71. package/dist/index.mjs +6 -6
  72. package/dist/index.mjs.br +0 -0
  73. package/dist/index.mjs.gz +0 -0
  74. package/dist/internals.d.ts +124 -4
  75. package/dist/internals.d.ts.map +1 -1
  76. package/dist/internals.js +79 -79
  77. package/dist/internals.js.br +0 -0
  78. package/dist/internals.js.gz +0 -0
  79. package/dist/internals.mjs +4 -4
  80. package/dist/internals.mjs.br +0 -0
  81. package/dist/internals.mjs.gz +0 -0
  82. package/dist/pptx-viewer.css +1 -1
  83. package/dist/pptx-viewer.css.br +0 -0
  84. package/dist/pptx-viewer.css.gz +0 -0
  85. package/dist/{types-DciBT90G.d.ts → types-DU35aAJK.d.ts} +2 -2
  86. package/dist/{types-DciBT90G.d.ts.map → types-DU35aAJK.d.ts.map} +1 -1
  87. package/dist/{useViewerBuildingBlocks-YvCYsxa3.d.ts → useViewerBuildingBlocks-CBZrHhxl.d.ts} +10 -5
  88. package/dist/useViewerBuildingBlocks-CBZrHhxl.d.ts.map +1 -0
  89. package/dist/viewer/index.d.ts +44 -2
  90. package/dist/viewer/index.js +22 -22
  91. package/dist/viewer/index.js.br +0 -0
  92. package/dist/viewer/index.js.gz +0 -0
  93. package/dist/viewer/index.mjs +6 -6
  94. package/dist/viewer/index.mjs.br +0 -0
  95. package/dist/viewer/index.mjs.gz +0 -0
  96. package/package.json +1 -1
  97. package/dist/AiChatPanel-FXPGFU6H.js.br +0 -0
  98. package/dist/AiChatPanel-FXPGFU6H.js.gz +0 -0
  99. package/dist/AiChatPanel-WMGS5TNX.mjs.br +0 -0
  100. package/dist/AiChatPanel-WMGS5TNX.mjs.gz +0 -0
  101. package/dist/Model3DScene-E2XRQAMR.mjs.br +0 -0
  102. package/dist/Model3DScene-E2XRQAMR.mjs.gz +0 -0
  103. package/dist/Model3DScene-K5FPZTRG.js.br +0 -0
  104. package/dist/Model3DScene-K5FPZTRG.js.gz +0 -0
  105. package/dist/SurfaceChart3DScene-2W2IFPLE.mjs.gz +0 -0
  106. package/dist/SurfaceChart3DScene-JDCFTXYT.js.br +0 -0
  107. package/dist/SurfaceChart3DScene-JDCFTXYT.js.gz +0 -0
  108. package/dist/chunk-3OV4FR6S.mjs.br +0 -0
  109. package/dist/chunk-3OV4FR6S.mjs.gz +0 -0
  110. package/dist/chunk-66ZHD7Y4.js.br +0 -0
  111. package/dist/chunk-66ZHD7Y4.js.gz +0 -0
  112. package/dist/chunk-BXAK3JFM.js.br +0 -0
  113. package/dist/chunk-BXAK3JFM.js.gz +0 -0
  114. package/dist/chunk-CQ2CKMG4.mjs.br +0 -0
  115. package/dist/chunk-CQ2CKMG4.mjs.gz +0 -0
  116. package/dist/chunk-DD2YRS6Z.js.br +0 -0
  117. package/dist/chunk-DD2YRS6Z.js.gz +0 -0
  118. package/dist/chunk-GJEH27GD.mjs.br +0 -0
  119. package/dist/chunk-GJEH27GD.mjs.gz +0 -0
  120. package/dist/chunk-H5H57XMH.mjs.br +0 -0
  121. package/dist/chunk-H5H57XMH.mjs.gz +0 -0
  122. package/dist/chunk-OWGPRVRK.mjs.br +0 -0
  123. package/dist/chunk-OWGPRVRK.mjs.gz +0 -0
  124. package/dist/chunk-PTFCMG3A.js.br +0 -0
  125. package/dist/chunk-PTFCMG3A.js.gz +0 -0
  126. package/dist/chunk-QFNJCEMS.js.br +0 -0
  127. package/dist/chunk-QFNJCEMS.js.gz +0 -0
  128. package/dist/chunk-TEXIGSA6.mjs.br +0 -0
  129. package/dist/chunk-TEXIGSA6.mjs.gz +0 -0
  130. package/dist/chunk-ZMIFFURL.js.br +0 -0
  131. package/dist/chunk-ZMIFFURL.js.gz +0 -0
  132. package/dist/useViewerBuildingBlocks-YvCYsxa3.d.ts.map +0 -1
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
- var chunkBXAK3JFM_js = require('./chunk-BXAK3JFM.js');
4
- var chunkDD2YRS6Z_js = require('./chunk-DD2YRS6Z.js');
3
+ var chunk3ISYPBSX_js = require('./chunk-3ISYPBSX.js');
4
+ var chunkPB7KVDNV_js = require('./chunk-PB7KVDNV.js');
5
5
  var clsx = require('clsx');
6
6
  var tailwindMerge = require('tailwind-merge');
7
7
  var React6 = require('react');
@@ -15,7 +15,7 @@ var React6__default = /*#__PURE__*/_interopDefault(React6);
15
15
 
16
16
  // src/viewer/utils/animation-effects.ts
17
17
  function getAnimationInitialStyle2(preset, nativeAnimation) {
18
- return chunkDD2YRS6Z_js.getAnimationInitialStyle(preset, nativeAnimation);
18
+ return chunkPB7KVDNV_js.getAnimationInitialStyle(preset, nativeAnimation);
19
19
  }
20
20
  function cn(...inputs) {
21
21
  return tailwindMerge.twMerge(clsx.clsx(inputs));
@@ -23,7 +23,7 @@ function cn(...inputs) {
23
23
 
24
24
  // src/viewer/utils/clone.ts
25
25
  function cloneHistorySnapshot2(snapshot) {
26
- return chunkDD2YRS6Z_js.cloneHistorySnapshot(snapshot);
26
+ return chunkPB7KVDNV_js.cloneHistorySnapshot(snapshot);
27
27
  }
28
28
 
29
29
  // src/viewer/constants/scalar.ts
@@ -35,7 +35,7 @@ var DEFAULT_BODY_INSET_TB_PX = 45720 / 9525;
35
35
  var DEFAULT_TEXT_COLOR = "#111827";
36
36
  var DEFAULT_FILL_COLOR = "#3b82f6";
37
37
  var DEFAULT_STROKE_COLOR = "#1f2937";
38
- var DEFAULT_FONT_FAMILY = '"Segoe UI", "Helvetica Neue", Arial, sans-serif';
38
+ var DEFAULT_FONT_FAMILY2 = '"Segoe UI", "Helvetica Neue", Arial, sans-serif';
39
39
  var DEFAULT_TEXT_FONT_SIZE = 24;
40
40
  var HYPERLINK_COLOR = "#0563C1";
41
41
  var DEFAULT_TABLE_ROWS = 3;
@@ -63,7 +63,7 @@ var TOOLBAR_SECTIONS = [
63
63
  { id: "view", labelKey: "pptx.ribbon.tab.view" },
64
64
  { id: "help", labelKey: "pptx.ribbon.tab.help" }
65
65
  ];
66
- var SHORTCUT_REFERENCE_ITEMS = chunkDD2YRS6Z_js.VIEWER_SHORTCUT_REFERENCE;
66
+ var SHORTCUT_REFERENCE_ITEMS = chunkPB7KVDNV_js.VIEWER_SHORTCUT_REFERENCE;
67
67
 
68
68
  // src/viewer/constants/theme.ts
69
69
  var THEME_COLOR_SWATCHES = [
@@ -107,7 +107,7 @@ var GLYPH_COMPONENTS = {
107
107
  plus: lu.LuPlus,
108
108
  triangle: lu.LuTriangle
109
109
  };
110
- var SHAPE_PRESETS = chunkDD2YRS6Z_js.SHAPE_PRESET_DEFS.map(
110
+ var SHAPE_PRESETS = chunkPB7KVDNV_js.SHAPE_PRESET_DEFS.map(
111
111
  (def) => ({
112
112
  type: def.type,
113
113
  label: def.label,
@@ -266,7 +266,7 @@ function isConnectorOrLineElement(element) {
266
266
  if (element.type === "connector") {
267
267
  return true;
268
268
  }
269
- if (!chunkDD2YRS6Z_js.hasShapeProperties(element)) {
269
+ if (!chunkPB7KVDNV_js.hasShapeProperties(element)) {
270
270
  return false;
271
271
  }
272
272
  const st = getShapeType(element.shapeType);
@@ -277,12 +277,12 @@ function isConnectorOrLineElement(element) {
277
277
  function partitionTemplateElements(slides) {
278
278
  const templateElementsBySlideId = {};
279
279
  const nextSlides = slides.map((slide) => {
280
- const template = slide.elements.filter((el) => chunkDD2YRS6Z_js.isTemplateElement(el));
280
+ const template = slide.elements.filter((el) => chunkPB7KVDNV_js.isTemplateElement(el));
281
281
  if (template.length === 0) {
282
282
  return slide;
283
283
  }
284
284
  templateElementsBySlideId[slide.id] = template;
285
- return { ...slide, elements: slide.elements.filter((el) => !chunkDD2YRS6Z_js.isTemplateElement(el)) };
285
+ return { ...slide, elements: slide.elements.filter((el) => !chunkPB7KVDNV_js.isTemplateElement(el)) };
286
286
  });
287
287
  return { slides: nextSlides, templateElementsBySlideId };
288
288
  }
@@ -298,7 +298,7 @@ function buildSaveSlides(slides, templateElementsBySlideId) {
298
298
 
299
299
  // src/viewer/utils/image-style.ts
300
300
  function getImageMaskStyle(element) {
301
- if (!chunkDD2YRS6Z_js.hasShapeProperties(element)) {
301
+ if (!chunkPB7KVDNV_js.hasShapeProperties(element)) {
302
302
  return void 0;
303
303
  }
304
304
  const shapeType = element.shapeType;
@@ -307,7 +307,7 @@ function getImageMaskStyle(element) {
307
307
  }
308
308
  const normalized = shapeType.toLowerCase();
309
309
  if (normalized === "roundrect" || normalized === "round1rect" || normalized === "round2samerect" || normalized === "round2diagrect" || normalized === "sniproundrect" || normalized === "snip1rect" || normalized === "snip2diagrect") {
310
- const radiusPx = chunkDD2YRS6Z_js.getRoundRectRadiusPx(element);
310
+ const radiusPx = chunkPB7KVDNV_js.getRoundRectRadiusPx(element);
311
311
  if (radiusPx <= 0.01) {
312
312
  return void 0;
313
313
  }
@@ -319,7 +319,7 @@ function getImageMaskStyle(element) {
319
319
  if (normalized === "can" || normalized === "cylinder") {
320
320
  return { borderRadius: "48% / 12%" };
321
321
  }
322
- const clipPath = chunkDD2YRS6Z_js.getResolvedShapeClipPath(element);
322
+ const clipPath = chunkPB7KVDNV_js.getResolvedShapeClipPath(element);
323
323
  if (!clipPath) {
324
324
  return void 0;
325
325
  }
@@ -328,7 +328,7 @@ function getImageMaskStyle(element) {
328
328
  function getImageRenderStyle(element) {
329
329
  return {
330
330
  ...getImageMaskStyle(element) || {},
331
- ...chunkDD2YRS6Z_js.getImageFitStyle(element)
331
+ ...chunkPB7KVDNV_js.getImageFitStyle(element)
332
332
  };
333
333
  }
334
334
  var CROP_SHAPE_CLIP_PATHS = {
@@ -341,7 +341,7 @@ var CROP_SHAPE_CLIP_PATHS = {
341
341
  star: "polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%)"
342
342
  };
343
343
  function getCropShapeClipPath(element) {
344
- if (!chunkDD2YRS6Z_js.isImageLikeElement(element)) {
344
+ if (!chunkPB7KVDNV_js.isImageLikeElement(element)) {
345
345
  return void 0;
346
346
  }
347
347
  const shape = element.cropShape;
@@ -351,7 +351,7 @@ function getCropShapeClipPath(element) {
351
351
  return CROP_SHAPE_CLIP_PATHS[shape];
352
352
  }
353
353
  function isImageTiled(element) {
354
- if (!chunkDD2YRS6Z_js.isImageLikeElement(element)) {
354
+ if (!chunkPB7KVDNV_js.isImageLikeElement(element)) {
355
355
  return false;
356
356
  }
357
357
  return typeof element.tileScaleX === "number" || typeof element.tileScaleY === "number";
@@ -409,7 +409,7 @@ function buildMirrorTiledBackground(src, flip, scaleX, scaleY) {
409
409
  };
410
410
  }
411
411
  function getImageTilingStyle(element) {
412
- if (!chunkDD2YRS6Z_js.isImageLikeElement(element) || !isImageTiled(element)) {
412
+ if (!chunkPB7KVDNV_js.isImageLikeElement(element) || !isImageTiled(element)) {
413
413
  return void 0;
414
414
  }
415
415
  const scaleX = typeof element.tileScaleX === "number" ? element.tileScaleX * 100 : 100;
@@ -659,9 +659,9 @@ function registerMediaElement(elementId, el) {
659
659
  };
660
660
  }
661
661
  function executeMediaCommand(command, frameRoot) {
662
- return chunkDD2YRS6Z_js.runMediaCommand(
662
+ return chunkPB7KVDNV_js.runMediaCommand(
663
663
  command,
664
- (targetId) => registry.get(targetId) ?? chunkDD2YRS6Z_js.findMediaElementByElementId(targetId, frameRoot?.())
664
+ (targetId) => registry.get(targetId) ?? chunkPB7KVDNV_js.findMediaElementByElementId(targetId, frameRoot?.())
665
665
  );
666
666
  }
667
667
  function PresentationMediaController({
@@ -705,7 +705,7 @@ function PresentationMediaController({
705
705
  loop: shouldLoop,
706
706
  volume: playbackVolume,
707
707
  playbackRate
708
- } = chunkDD2YRS6Z_js.mediaPlaybackAttributes({
708
+ } = chunkPB7KVDNV_js.mediaPlaybackAttributes({
709
709
  loop: element.loop,
710
710
  volume: element.volume,
711
711
  playbackSpeed: element.playbackSpeed
@@ -841,7 +841,7 @@ function PresentationMediaController({
841
841
  if (element.playAcrossSlides && element.mediaType === "audio") {
842
842
  const dataUrl = element.mediaData ?? resolvedDataUrl;
843
843
  if (dataUrl) {
844
- chunkDD2YRS6Z_js.registerPersistentAudio(
844
+ chunkPB7KVDNV_js.registerPersistentAudio(
845
845
  element.id,
846
846
  dataUrl,
847
847
  element.mediaMimeType,
@@ -904,7 +904,7 @@ function PresentationMediaController({
904
904
  }
905
905
  function renderMediaElement(element, mediaDataUrls, options) {
906
906
  if (element.type !== "media") {
907
- return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunkBXAK3JFM_js.translationsEn["pptx.media.title"] });
907
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunk3ISYPBSX_js.translationsEn["pptx.media.title"] });
908
908
  }
909
909
  const mediaType = element.mediaType;
910
910
  const mediaPath = element.mediaPath;
@@ -912,7 +912,7 @@ function renderMediaElement(element, mediaDataUrls, options) {
912
912
  const dataUrl = element.mediaData ?? (mediaPath ? mediaDataUrls.get(mediaPath) : void 0);
913
913
  const trimFragment = buildTrimFragment(element);
914
914
  const posterUrl = element.posterFrameData ?? void 0;
915
- const shouldLoop = chunkDD2YRS6Z_js.mediaPlaybackAttributes(element).loop;
915
+ const shouldLoop = chunkPB7KVDNV_js.mediaPlaybackAttributes(element).loop;
916
916
  const shouldAutoPlay = options?.autoPlay === true || element.autoPlay === true;
917
917
  const isFullScreen = options?.fullScreen === true;
918
918
  const isPresentationMode = options?.isPresentationMode === true;
@@ -924,7 +924,7 @@ function renderMediaElement(element, mediaDataUrls, options) {
924
924
  "img",
925
925
  {
926
926
  src: posterUrl,
927
- alt: chunkBXAK3JFM_js.translationsEn["pptx.media.posterAlt"],
927
+ alt: chunk3ISYPBSX_js.translationsEn["pptx.media.posterAlt"],
928
928
  className: "w-full h-full object-contain opacity-50"
929
929
  }
930
930
  ),
@@ -945,7 +945,7 @@ function renderMediaElement(element, mediaDataUrls, options) {
945
945
  ]
946
946
  }
947
947
  ),
948
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] text-white/60", children: chunkBXAK3JFM_js.translationsEn["pptx.media.notFound"] })
948
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] text-white/60", children: chunk3ISYPBSX_js.translationsEn["pptx.media.notFound"] })
949
949
  ] })
950
950
  ] });
951
951
  }
@@ -988,7 +988,7 @@ function renderMediaElement(element, mediaDataUrls, options) {
988
988
  "img",
989
989
  {
990
990
  src: posterUrl,
991
- alt: chunkBXAK3JFM_js.translationsEn["pptx.media.videoPosterAlt"],
991
+ alt: chunk3ISYPBSX_js.translationsEn["pptx.media.videoPosterAlt"],
992
992
  className: "w-full h-full object-contain"
993
993
  }
994
994
  ),
@@ -1078,7 +1078,7 @@ function renderMediaElement(element, mediaDataUrls, options) {
1078
1078
 
1079
1079
  // src/viewer/utils/text-utils.tsx
1080
1080
  function getTextStyleForElement(element, fallbackColor) {
1081
- return chunkDD2YRS6Z_js.buildTextBlockStyle(element, { fallbackColor });
1081
+ return chunkPB7KVDNV_js.buildTextBlockStyle(element, { fallbackColor });
1082
1082
  }
1083
1083
 
1084
1084
  // src/viewer/utils/text-layout.tsx
@@ -1103,13 +1103,13 @@ function computeTabSize(tabStops, defaultTabSize) {
1103
1103
  return avgGap > 0 ? `${Math.round(avgGap)}px` : fromDefault;
1104
1104
  }
1105
1105
  function getTextLayoutStyle(element) {
1106
- if (!chunkDD2YRS6Z_js.hasTextProperties(element)) {
1106
+ if (!chunkPB7KVDNV_js.hasTextProperties(element)) {
1107
1107
  return {};
1108
1108
  }
1109
1109
  const verticalAlign = element.textStyle?.vAlign || "top";
1110
- const writingMode = chunkDD2YRS6Z_js.toCssWritingMode(element.textStyle?.textDirection);
1111
- const textOrientation = chunkDD2YRS6Z_js.toCssTextOrientation(element.textStyle?.textDirection);
1112
- const verticalDirection = chunkDD2YRS6Z_js.toCssVerticalDirection(element.textStyle?.textDirection);
1110
+ const writingMode = chunkPB7KVDNV_js.toCssWritingMode(element.textStyle?.textDirection);
1111
+ const textOrientation = chunkPB7KVDNV_js.toCssTextOrientation(element.textStyle?.textDirection);
1112
+ const verticalDirection = chunkPB7KVDNV_js.toCssVerticalDirection(element.textStyle?.textDirection);
1113
1113
  const parsedColumnCount = Number(element.textStyle?.columnCount);
1114
1114
  const columnCount = Number.isFinite(parsedColumnCount) ? Math.max(1, Math.min(16, Math.round(parsedColumnCount))) : 1;
1115
1115
  const hasColumns = columnCount > 1;
@@ -1117,7 +1117,7 @@ function getTextLayoutStyle(element) {
1117
1117
  const tabStops = element.textStyle?.tabStops;
1118
1118
  const tabSize = computeTabSize(tabStops, element.textStyle?.defaultTabSize);
1119
1119
  const textWrapNone = element.textStyle?.textWrap === "none";
1120
- const hasParagraphIndents = chunkDD2YRS6Z_js.hasTextProperties(element) && element.paragraphIndents && element.paragraphIndents.length > 0;
1120
+ const hasParagraphIndents = chunkPB7KVDNV_js.hasTextProperties(element) && element.paragraphIndents && element.paragraphIndents.length > 0;
1121
1121
  const paragraphMarginLeft = element.textStyle?.paragraphMarginLeft;
1122
1122
  const paragraphIndent = element.textStyle?.paragraphIndent;
1123
1123
  const marginLeft = !hasParagraphIndents && typeof paragraphMarginLeft === "number" && paragraphMarginLeft !== 0 ? paragraphMarginLeft : void 0;
@@ -1126,7 +1126,7 @@ function getTextLayoutStyle(element) {
1126
1126
  const bodyBottom = element.textStyle?.bodyInsetBottom ?? DEFAULT_BODY_INSET_TB_PX;
1127
1127
  const parsedColumnSpacing = Number(element.textStyle?.columnSpacing);
1128
1128
  const columnGap = Number.isFinite(parsedColumnSpacing) && parsedColumnSpacing > 0 ? `${parsedColumnSpacing}px` : "0.75em";
1129
- const kinsokuStyles = chunkDD2YRS6Z_js.getKinsokuLineBreakStyles(element.textStyle);
1129
+ const kinsokuStyles = chunkPB7KVDNV_js.getKinsokuLineBreakStyles(element.textStyle);
1130
1130
  if (hasColumns) {
1131
1131
  return {
1132
1132
  display: "block",
@@ -1173,10 +1173,10 @@ function getTextLayoutStyle(element) {
1173
1173
 
1174
1174
  // src/viewer/utils/text-effects.tsx
1175
1175
  function buildTextFillCss2(style) {
1176
- return chunkDD2YRS6Z_js.buildTextFillCss(style);
1176
+ return chunkPB7KVDNV_js.buildTextFillCss(style);
1177
1177
  }
1178
1178
  function buildTextBody3DSceneStyle2(textStyle) {
1179
- return chunkDD2YRS6Z_js.buildTextBody3DSceneStyle(textStyle);
1179
+ return chunkPB7KVDNV_js.buildTextBody3DSceneStyle(textStyle);
1180
1180
  }
1181
1181
 
1182
1182
  // src/viewer/utils/text-warp-css.tsx
@@ -1361,13 +1361,13 @@ function wrapWithTextBuildAnimation(elementId, paraIndex, renderedSegments, para
1361
1361
  if (!subElementAnimStates || subElementAnimStates.size === 0) {
1362
1362
  return renderedSegments;
1363
1363
  }
1364
- const paraKey = `${elementId}${chunkDD2YRS6Z_js.TEXT_BUILD_ID_SEP}p${paraIndex}`;
1364
+ const paraKey = `${elementId}${chunkPB7KVDNV_js.TEXT_BUILD_ID_SEP}p${paraIndex}`;
1365
1365
  const paraState = subElementAnimStates.get(paraKey);
1366
1366
  if (paraState) {
1367
1367
  const style = buildAnimStyle(paraState);
1368
1368
  return /* @__PURE__ */ jsxRuntime.jsx("span", { "data-anim-id": paraKey, style: { display: "inline", ...style }, children: renderedSegments }, paraKey);
1369
1369
  }
1370
- const spec = chunkDD2YRS6Z_js.buildTextBuildSpec(
1370
+ const spec = chunkPB7KVDNV_js.buildTextBuildSpec(
1371
1371
  elementId,
1372
1372
  paraIndex,
1373
1373
  paraSegments.map((entry) => ({ text: entry.segment.text, style: entry })),
@@ -1385,7 +1385,7 @@ function wrapWithTextBuildAnimation(elementId, paraIndex, renderedSegments, para
1385
1385
  "span",
1386
1386
  {
1387
1387
  "data-anim-id": span.animId,
1388
- style: chunkDD2YRS6Z_js.textBuildSpanStyle(span),
1388
+ style: chunkPB7KVDNV_js.textBuildSpanStyle(span),
1389
1389
  children: content
1390
1390
  },
1391
1391
  span.animId
@@ -1529,10 +1529,10 @@ function renderScriptAwareText(text, needsScriptFonts, scriptFonts, baseFontFami
1529
1529
  if (!needsScriptFonts || !text) {
1530
1530
  return text;
1531
1531
  }
1532
- const runs = chunkDD2YRS6Z_js.segmentByScript(text);
1532
+ const runs = chunkPB7KVDNV_js.segmentByScript(text);
1533
1533
  if (runs.length <= 1) {
1534
1534
  if (runs.length === 1) {
1535
- const font = chunkDD2YRS6Z_js.resolveFontForScript(runs[0].script, scriptFonts);
1535
+ const font = chunkPB7KVDNV_js.resolveFontForScript(runs[0].script, scriptFonts);
1536
1536
  if (font && font !== baseFontFamily) {
1537
1537
  return /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontFamily: font }, children: text });
1538
1538
  }
@@ -1540,7 +1540,7 @@ function renderScriptAwareText(text, needsScriptFonts, scriptFonts, baseFontFami
1540
1540
  return text;
1541
1541
  }
1542
1542
  return runs.map((run, i) => {
1543
- const font = chunkDD2YRS6Z_js.resolveFontForScript(run.script, scriptFonts);
1543
+ const font = chunkPB7KVDNV_js.resolveFontForScript(run.script, scriptFonts);
1544
1544
  if (!font || font === baseFontFamily) {
1545
1545
  return /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Fragment, { children: run.text }, `${keyPrefix}-r${i}`);
1546
1546
  }
@@ -1612,8 +1612,8 @@ function renderSegmentContent(elementId, segmentIndex, textValue, lines, needsSc
1612
1612
  );
1613
1613
  }
1614
1614
  function renderEquationSegment(elementId, segmentIndex, equationXml, equationNumber) {
1615
- const mathml = chunkDD2YRS6Z_js.convertOmmlToMathMl(equationXml);
1616
- const safeMathml = mathml ? chunkDD2YRS6Z_js.sanitizeMathMl(mathml) : "";
1615
+ const mathml = chunkPB7KVDNV_js.convertOmmlToMathMl(equationXml);
1616
+ const safeMathml = mathml ? chunkPB7KVDNV_js.sanitizeMathMl(mathml) : "";
1617
1617
  const equationContent = safeMathml ? /* @__PURE__ */ jsxRuntime.jsx(
1618
1618
  "span",
1619
1619
  {
@@ -1623,7 +1623,7 @@ function renderEquationSegment(elementId, segmentIndex, equationXml, equationNum
1623
1623
  },
1624
1624
  dangerouslySetInnerHTML: { __html: safeMathml }
1625
1625
  }
1626
- ) : /* @__PURE__ */ jsxRuntime.jsx("span", { className: "inline-block px-1 py-0.5 rounded text-xs bg-gray-200/20 text-gray-400 italic", children: chunkBXAK3JFM_js.translationsEn["pptx.textSegment.equationFallback"] });
1626
+ ) : /* @__PURE__ */ jsxRuntime.jsx("span", { className: "inline-block px-1 py-0.5 rounded text-xs bg-gray-200/20 text-gray-400 italic", children: chunk3ISYPBSX_js.translationsEn["pptx.textSegment.equationFallback"] });
1627
1627
  if (equationNumber) {
1628
1628
  return /* @__PURE__ */ jsxRuntime.jsxs(
1629
1629
  "span",
@@ -1663,7 +1663,7 @@ function renderEquationSegment(elementId, segmentIndex, equationXml, equationNum
1663
1663
  return /* @__PURE__ */ jsxRuntime.jsx("span", { children: equationContent }, `${elementId}-seg-${segmentIndex}`);
1664
1664
  }
1665
1665
  function renderPictureBullet(elementId, segmentIndex, bulletInfo, baseFontSize) {
1666
- const picture = chunkDD2YRS6Z_js.resolvePictureBullet(bulletInfo, baseFontSize) ?? {
1666
+ const picture = chunkPB7KVDNV_js.resolvePictureBullet(bulletInfo, baseFontSize) ?? {
1667
1667
  sizePx: baseFontSize,
1668
1668
  fallbackMarker: "\u2022",
1669
1669
  accessibleLabel: "Bullet"
@@ -1714,7 +1714,7 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
1714
1714
  }
1715
1715
  const segmentStyle = segment.style || {};
1716
1716
  const rawText = bulletInfo && typeof bulletHangPx === "number" ? (segment.text || "").trimEnd() : segment.text || "";
1717
- const textValue = chunkDD2YRS6Z_js.substituteFieldText(rawText, segment.fieldType, fieldContext);
1717
+ const textValue = chunkPB7KVDNV_js.substituteFieldText(rawText, segment.fieldType, fieldContext);
1718
1718
  const lines = textValue.split("\n");
1719
1719
  const textDecorationTokens = [];
1720
1720
  if (segmentStyle.underline || segmentStyle.hyperlink) {
@@ -1724,28 +1724,28 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
1724
1724
  textDecorationTokens.push("line-through");
1725
1725
  }
1726
1726
  const isDoubleStrike = segmentStyle.strikethrough && segmentStyle.strikeType === "dblStrike";
1727
- const resolvedSegmentColor = segmentStyle.hyperlink ? chunkDD2YRS6Z_js.normalizeHexColor(segmentStyle.color || element.textStyle?.color, HYPERLINK_COLOR) : chunkDD2YRS6Z_js.normalizeHexColor(segmentStyle.color || element.textStyle?.color, fallbackColor);
1728
- const underlineDecoration = chunkDD2YRS6Z_js.resolveUnderlineDecorationStyle(
1727
+ const resolvedSegmentColor = segmentStyle.hyperlink ? chunkPB7KVDNV_js.normalizeHexColor(segmentStyle.color || element.textStyle?.color, HYPERLINK_COLOR) : chunkPB7KVDNV_js.normalizeHexColor(segmentStyle.color || element.textStyle?.color, fallbackColor);
1728
+ const underlineDecoration = chunkPB7KVDNV_js.resolveUnderlineDecorationStyle(
1729
1729
  Boolean(isDoubleStrike),
1730
1730
  segmentStyle.underlineStyle
1731
1731
  );
1732
1732
  const rawBaseline = typeof segmentStyle.baseline === "number" ? segmentStyle.baseline : 0;
1733
1733
  const baselineFraction = rawBaseline === 0 ? 0 : Math.abs(rawBaseline) >= 1e3 ? rawBaseline / 1e5 : rawBaseline / 100;
1734
1734
  const baselineFontScale = baselineFraction !== 0 ? 0.65 : 1;
1735
- const letterSpacing = typeof segmentStyle.characterSpacing === "number" && segmentStyle.characterSpacing !== 0 ? `calc(${segmentStyle.characterSpacing / 100 * (96 / 72)}px + ${chunkDD2YRS6Z_js.POWERPOINT_METRIC_TRACKING})` : chunkDD2YRS6Z_js.POWERPOINT_METRIC_TRACKING;
1735
+ const letterSpacing = typeof segmentStyle.characterSpacing === "number" && segmentStyle.characterSpacing !== 0 ? `calc(${segmentStyle.characterSpacing / 100 * (96 / 72)}px + ${chunkPB7KVDNV_js.POWERPOINT_METRIC_TRACKING})` : chunkPB7KVDNV_js.POWERPOINT_METRIC_TRACKING;
1736
1736
  const textFillStyles = buildTextFillCss2(segmentStyle);
1737
1737
  const rawFontSize = segmentStyle.fontSize || element.textStyle?.fontSize || DEFAULT_TEXT_FONT_SIZE;
1738
- const autoFitScale = chunkDD2YRS6Z_js.resolveAutoFitFontScale(element.textStyle);
1738
+ const autoFitScale = chunkPB7KVDNV_js.resolveAutoFitFontScale(element.textStyle);
1739
1739
  const baseFontSize = rawFontSize * autoFitScale;
1740
1740
  const baselineShift = baselineFraction !== 0 ? `${baselineFraction * baseFontSize}px` : void 0;
1741
1741
  const baseFontSizePt = baseFontSize * (72 / 96);
1742
1742
  const fontKerning = typeof segmentStyle.kerning === "number" ? segmentStyle.kerning === 0 ? "none" : baseFontSizePt >= segmentStyle.kerning / 100 ? "normal" : "none" : void 0;
1743
1743
  const rawFontFamily = segmentStyle.fontFamily || element.textStyle?.fontFamily;
1744
- const baseFontFamily = rawFontFamily ? chunkDD2YRS6Z_js.getSubstituteFontFamily(
1744
+ const baseFontFamily = rawFontFamily ? chunkPB7KVDNV_js.getSubstituteFontFamily(
1745
1745
  rawFontFamily,
1746
- chunkDD2YRS6Z_js.parsePanoseString(segmentStyle.latinFontPanose ?? element.textStyle?.latinFontPanose)
1747
- ) : DEFAULT_FONT_FAMILY;
1748
- const scriptFont = (name, panose) => name ? chunkDD2YRS6Z_js.getSubstituteFontFamily(name, chunkDD2YRS6Z_js.parsePanoseString(panose)) : baseFontFamily;
1746
+ chunkPB7KVDNV_js.parsePanoseString(segmentStyle.latinFontPanose ?? element.textStyle?.latinFontPanose)
1747
+ ) : DEFAULT_FONT_FAMILY2;
1748
+ const scriptFont = (name, panose) => name ? chunkPB7KVDNV_js.getSubstituteFontFamily(name, chunkPB7KVDNV_js.parsePanoseString(panose)) : baseFontFamily;
1749
1749
  const scriptFonts = {
1750
1750
  latin: baseFontFamily,
1751
1751
  eastAsia: scriptFont(
@@ -1761,7 +1761,7 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
1761
1761
  segmentStyle.symbolFontPanose ?? element.textStyle?.symbolFontPanose
1762
1762
  )
1763
1763
  };
1764
- const needsScriptFonts = chunkDD2YRS6Z_js.hasDistinctScriptFonts(scriptFonts);
1764
+ const needsScriptFonts = chunkPB7KVDNV_js.hasDistinctScriptFonts(scriptFonts);
1765
1765
  const spanStyle = {
1766
1766
  color: resolvedSegmentColor,
1767
1767
  fontSize: baseFontSize * baselineFontScale,
@@ -1779,15 +1779,15 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
1779
1779
  fontVariantCaps: segmentStyle.textCaps === "small" ? "small-caps" : void 0,
1780
1780
  letterSpacing,
1781
1781
  fontKerning,
1782
- backgroundColor: textFillStyles ? void 0 : segmentStyle.highlightColor ? chunkDD2YRS6Z_js.normalizeHexColor(segmentStyle.highlightColor, "transparent") : void 0,
1782
+ backgroundColor: textFillStyles ? void 0 : segmentStyle.highlightColor ? chunkPB7KVDNV_js.normalizeHexColor(segmentStyle.highlightColor, "transparent") : void 0,
1783
1783
  ...textFillStyles,
1784
- textDecorationColor: segmentStyle.underlineColor ? chunkDD2YRS6Z_js.normalizeHexColor(segmentStyle.underlineColor, void 0) : void 0,
1785
- WebkitTextStroke: segmentStyle.textOutlineWidth && segmentStyle.textOutlineColor ? `${segmentStyle.textOutlineWidth}px ${chunkDD2YRS6Z_js.normalizeHexColor(segmentStyle.textOutlineColor, "#000000")}` : segmentStyle.textOutlineWidth ? `${segmentStyle.textOutlineWidth}px currentColor` : void 0,
1784
+ textDecorationColor: segmentStyle.underlineColor ? chunkPB7KVDNV_js.normalizeHexColor(segmentStyle.underlineColor, void 0) : void 0,
1785
+ WebkitTextStroke: segmentStyle.textOutlineWidth && segmentStyle.textOutlineColor ? `${segmentStyle.textOutlineWidth}px ${chunkPB7KVDNV_js.normalizeHexColor(segmentStyle.textOutlineColor, "#000000")}` : segmentStyle.textOutlineWidth ? `${segmentStyle.textOutlineWidth}px currentColor` : void 0,
1786
1786
  paintOrder: segmentStyle.textOutlineWidth ? "stroke fill" : void 0,
1787
- textShadow: chunkDD2YRS6Z_js.buildTextShadowCss(segmentStyle),
1788
- filter: chunkDD2YRS6Z_js.buildTextRunFilterChain(segmentStyle),
1789
- opacity: chunkDD2YRS6Z_js.getTextAlphaOpacity(segmentStyle),
1790
- WebkitBoxReflect: chunkDD2YRS6Z_js.buildTextReflectionCss(segmentStyle)
1787
+ textShadow: chunkPB7KVDNV_js.buildTextShadowCss(segmentStyle),
1788
+ filter: chunkPB7KVDNV_js.buildTextRunFilterChain(segmentStyle),
1789
+ opacity: chunkPB7KVDNV_js.getTextAlphaOpacity(segmentStyle),
1790
+ WebkitBoxReflect: chunkPB7KVDNV_js.buildTextReflectionCss(segmentStyle)
1791
1791
  };
1792
1792
  const runRtl = segmentStyle.rtl;
1793
1793
  if (runRtl !== void 0 && runRtl !== paragraphRtl) {
@@ -1807,7 +1807,7 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
1807
1807
  spanStyle.fontSize = baseFontSize * (bulletInfo.sizePercent / 100) * baselineFontScale;
1808
1808
  }
1809
1809
  if (bulletInfo.color) {
1810
- spanStyle.color = chunkDD2YRS6Z_js.normalizeHexColor(bulletInfo.color, resolvedSegmentColor);
1810
+ spanStyle.color = chunkPB7KVDNV_js.normalizeHexColor(bulletInfo.color, resolvedSegmentColor);
1811
1811
  }
1812
1812
  if (typeof bulletHangPx === "number" && bulletHangPx > 0) {
1813
1813
  spanStyle.display = "inline-block";
@@ -1852,7 +1852,7 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
1852
1852
  textAlign: segment.rubyAlignment === "l" ? "left" : segment.rubyAlignment === "r" ? "right" : segment.rubyAlignment === "dist" || segment.rubyAlignment === "distCat" || segment.rubyAlignment === "distLetter" ? "justify" : "center"
1853
1853
  };
1854
1854
  if (segment.rubyStyle?.color) {
1855
- rubyStyle.color = chunkDD2YRS6Z_js.normalizeHexColor(segment.rubyStyle.color, resolvedSegmentColor);
1855
+ rubyStyle.color = chunkPB7KVDNV_js.normalizeHexColor(segment.rubyStyle.color, resolvedSegmentColor);
1856
1856
  }
1857
1857
  innerContent = /* @__PURE__ */ jsxRuntime.jsxs("ruby", { children: [
1858
1858
  baseContent,
@@ -1925,7 +1925,7 @@ function resolveParagraphSpacing(input) {
1925
1925
  if (typeof exactPt === "number" && exactPt > 0) {
1926
1926
  result.lineHeight = `${exactPt * PT_TO_PX}px`;
1927
1927
  } else if (typeof multiplier === "number" && multiplier > 0) {
1928
- result.lineHeight = chunkDD2YRS6Z_js.proportionalLineHeight(multiplier);
1928
+ result.lineHeight = chunkPB7KVDNV_js.proportionalLineHeight(multiplier);
1929
1929
  }
1930
1930
  return result;
1931
1931
  }
@@ -1947,7 +1947,7 @@ function groupSegmentsIntoParagraphs(segments) {
1947
1947
  return paragraphs;
1948
1948
  }
1949
1949
  function renderTextSegments(element, fallbackColor, emptyFallback, findHighlights, onHyperlinkClick, fieldContext, subElementAnimStates, segmentOverrides, requireCtrlClick) {
1950
- if (!chunkDD2YRS6Z_js.hasTextProperties(element)) {
1950
+ if (!chunkPB7KVDNV_js.hasTextProperties(element)) {
1951
1951
  return emptyFallback || null;
1952
1952
  }
1953
1953
  const effectiveSegments = segmentOverrides ?? element.textSegments;
@@ -1968,10 +1968,10 @@ function renderTextSegments(element, fallbackColor, emptyFallback, findHighlight
1968
1968
  return element.text || emptyFallback || "";
1969
1969
  }
1970
1970
  const paragraphs = groupSegmentsIntoParagraphs(effectiveSegments);
1971
- const paragraphIndents = chunkDD2YRS6Z_js.hasTextProperties(element) ? element.paragraphIndents : void 0;
1972
- const elementRtl = chunkDD2YRS6Z_js.hasTextProperties(element) ? element.textStyle?.rtl : void 0;
1973
- const elementAlign = chunkDD2YRS6Z_js.hasTextProperties(element) ? element.textStyle?.align : void 0;
1974
- const bodyStyle = chunkDD2YRS6Z_js.hasTextProperties(element) ? element.textStyle : void 0;
1971
+ const paragraphIndents = chunkPB7KVDNV_js.hasTextProperties(element) ? element.paragraphIndents : void 0;
1972
+ const elementRtl = chunkPB7KVDNV_js.hasTextProperties(element) ? element.textStyle?.rtl : void 0;
1973
+ const elementAlign = chunkPB7KVDNV_js.hasTextProperties(element) ? element.textStyle?.align : void 0;
1974
+ const bodyStyle = chunkPB7KVDNV_js.hasTextProperties(element) ? element.textStyle : void 0;
1975
1975
  const spaceFirstLast = bodyStyle?.spaceFirstLastParagraph !== false;
1976
1976
  return paragraphs.map(({ entries: paraSegments, terminator }, paraIndex) => {
1977
1977
  const paraIndent = paragraphIndents?.[paraIndex];
@@ -1986,14 +1986,14 @@ function renderTextSegments(element, fallbackColor, emptyFallback, findHighlight
1986
1986
  return Boolean(segment.text) && segment.text.trim().length > 0;
1987
1987
  });
1988
1988
  const hasBullet = bulletInfo && !bulletInfo.none && hasVisibleTextContent;
1989
- const paraRtl = chunkDD2YRS6Z_js.resolveParagraphRtl(paraSegments, elementRtl);
1989
+ const paraRtl = chunkPB7KVDNV_js.resolveParagraphRtl(paraSegments, elementRtl);
1990
1990
  const isRtlParagraph = paraRtl === true;
1991
- const paraAlign = chunkDD2YRS6Z_js.resolveParagraphAlign(paraSegments, elementAlign);
1992
- const cssTextAlign = chunkDD2YRS6Z_js.resolveCssTextAlign(paraAlign, isRtlParagraph);
1991
+ const paraAlign = chunkPB7KVDNV_js.resolveParagraphAlign(paraSegments, elementAlign);
1992
+ const cssTextAlign = chunkPB7KVDNV_js.resolveCssTextAlign(paraAlign, isRtlParagraph);
1993
1993
  const paraMarginLeft = isRtlParagraph ? void 0 : rawMarginLeft;
1994
1994
  const paraMarginRight = isRtlParagraph ? rawMarginLeft : void 0;
1995
1995
  const paraTextIndent = rawTextIndent;
1996
- const paraKinsokuStyle = chunkDD2YRS6Z_js.getKinsokuLineBreakStyles(firstSeg?.segment.style);
1996
+ const paraKinsokuStyle = chunkPB7KVDNV_js.getKinsokuLineBreakStyles(firstSeg?.segment.style);
1997
1997
  const hasParaKinsoku = Object.keys(paraKinsokuStyle).length > 0;
1998
1998
  const paraProps = effectiveSegments[firstSeg?.globalIndex ?? -1]?.paragraphProperties ?? (paraSegments.length === 0 ? terminator?.paragraphProperties : void 0);
1999
1999
  const spacing = resolveParagraphSpacing({
@@ -2003,7 +2003,7 @@ function renderTextSegments(element, fallbackColor, emptyFallback, findHighlight
2003
2003
  isLast: paraIndex === paragraphs.length - 1,
2004
2004
  spaceFirstLast
2005
2005
  });
2006
- const strutFontSize = chunkDD2YRS6Z_js.resolveParagraphStrutFontSize(
2006
+ const strutFontSize = chunkPB7KVDNV_js.resolveParagraphStrutFontSize(
2007
2007
  paraSegments.length > 0 ? paraSegments.map(({ segment }) => segment) : terminator ? [terminator] : [],
2008
2008
  bodyStyle?.fontSize
2009
2009
  );
@@ -2107,13 +2107,13 @@ function hexToRgbUnit(hex) {
2107
2107
  };
2108
2108
  }
2109
2109
  function getDuotoneColors(element) {
2110
- if (!chunkDD2YRS6Z_js.isImageLikeElement(element)) {
2110
+ if (!chunkPB7KVDNV_js.isImageLikeElement(element)) {
2111
2111
  return void 0;
2112
2112
  }
2113
2113
  return element.imageEffects?.duotone;
2114
2114
  }
2115
2115
  function buildLineShadowCss(element) {
2116
- if (!chunkDD2YRS6Z_js.hasShapeProperties(element)) {
2116
+ if (!chunkPB7KVDNV_js.hasShapeProperties(element)) {
2117
2117
  return void 0;
2118
2118
  }
2119
2119
  const ss = element.shapeStyle;
@@ -2124,13 +2124,13 @@ function buildLineShadowCss(element) {
2124
2124
  const offsetY = typeof ss.lineShadowOffsetY === "number" ? ss.lineShadowOffsetY : 2;
2125
2125
  const blur = typeof ss.lineShadowBlur === "number" ? Math.max(0, ss.lineShadowBlur) : 4;
2126
2126
  const opacity = typeof ss.lineShadowOpacity === "number" ? Math.max(0, Math.min(1, ss.lineShadowOpacity)) : 0.35;
2127
- return `${Math.round(offsetX)}px ${Math.round(offsetY)}px ${Math.round(blur)}px ${chunkDD2YRS6Z_js.colorWithOpacity(
2128
- chunkDD2YRS6Z_js.normalizeHexColor(ss.lineShadowColor, "#000000"),
2127
+ return `${Math.round(offsetX)}px ${Math.round(offsetY)}px ${Math.round(blur)}px ${chunkPB7KVDNV_js.colorWithOpacity(
2128
+ chunkPB7KVDNV_js.normalizeHexColor(ss.lineShadowColor, "#000000"),
2129
2129
  opacity
2130
2130
  )}`;
2131
2131
  }
2132
2132
  function buildLineGlowFilter(element) {
2133
- if (!chunkDD2YRS6Z_js.hasShapeProperties(element)) {
2133
+ if (!chunkPB7KVDNV_js.hasShapeProperties(element)) {
2134
2134
  return void 0;
2135
2135
  }
2136
2136
  const ss = element.shapeStyle;
@@ -2139,7 +2139,7 @@ function buildLineGlowFilter(element) {
2139
2139
  }
2140
2140
  const glowOpacity = typeof ss.lineGlowOpacity === "number" ? ss.lineGlowOpacity : 0.75;
2141
2141
  const glowRad = Math.round(Math.max(0, ss.lineGlowRadius));
2142
- const glowCol = chunkDD2YRS6Z_js.colorWithOpacity(chunkDD2YRS6Z_js.normalizeHexColor(ss.lineGlowColor, "#ffff00"), glowOpacity);
2142
+ const glowCol = chunkPB7KVDNV_js.colorWithOpacity(chunkPB7KVDNV_js.normalizeHexColor(ss.lineGlowColor, "#ffff00"), glowOpacity);
2143
2143
  return `drop-shadow(0 0 ${glowRad}px ${glowCol})`;
2144
2144
  }
2145
2145
  function mapDagBlendModeToCss(blend) {
@@ -2163,7 +2163,7 @@ function getDagDuotoneFilterId(elementId) {
2163
2163
  return `dag-duotone-${elementId}`;
2164
2164
  }
2165
2165
  function hasDagDuotoneEffect(element) {
2166
- if (!chunkDD2YRS6Z_js.hasShapeProperties(element)) {
2166
+ if (!chunkPB7KVDNV_js.hasShapeProperties(element)) {
2167
2167
  return false;
2168
2168
  }
2169
2169
  return Boolean(element.shapeStyle?.dagDuotone);
@@ -2226,7 +2226,7 @@ function getRoundRectRadiusPx2(element) {
2226
2226
 
2227
2227
  // src/viewer/utils/shape-visual-3d.ts
2228
2228
  function build3DExtrusionData2(shape3d, scene3d, fillColor, elementWidth, elementHeight) {
2229
- return chunkDD2YRS6Z_js.build3DExtrusionData(
2229
+ return chunkPB7KVDNV_js.build3DExtrusionData(
2230
2230
  shape3d,
2231
2231
  scene3d,
2232
2232
  fillColor,
@@ -2235,68 +2235,7 @@ function build3DExtrusionData2(shape3d, scene3d, fillColor, elementWidth, elemen
2235
2235
  );
2236
2236
  }
2237
2237
  function apply3dEffects2(base, scene3d, shape3d, fillColorFallback) {
2238
- chunkDD2YRS6Z_js.apply3dEffects(base, scene3d, shape3d, fillColorFallback);
2239
- }
2240
-
2241
- // src/viewer/utils/vector-subpath-paint.ts
2242
- function toHexByte(value) {
2243
- const clamped = Math.max(0, Math.min(255, Math.round(value)));
2244
- return clamped.toString(16).padStart(2, "0");
2245
- }
2246
- function shiftHex(hex, factor, towardsWhite) {
2247
- const channels = chunkDD2YRS6Z_js.hexToRgbChannels(hex);
2248
- if (!channels) {
2249
- return hex;
2250
- }
2251
- const shift = (c) => towardsWhite ? c + (255 - c) * factor : c * (1 - factor);
2252
- return `#${toHexByte(shift(channels.r))}${toHexByte(shift(channels.g))}${toHexByte(shift(channels.b))}`;
2253
- }
2254
- function adjustFillForMode(fillHex, mode) {
2255
- switch (mode) {
2256
- case "lighten":
2257
- return shiftHex(fillHex, 0.4, true);
2258
- case "lightenLess":
2259
- return shiftHex(fillHex, 0.2, true);
2260
- case "darken":
2261
- return shiftHex(fillHex, 0.4, false);
2262
- case "darkenLess":
2263
- return shiftHex(fillHex, 0.2, false);
2264
- default:
2265
- return fillHex;
2266
- }
2267
- }
2268
- function buildCustomSubpathPaints(subpaths, hasFill, fillColor, fillOpacity) {
2269
- return subpaths.map((subpath) => {
2270
- const fillOff = subpath.fillMode === "none" || !hasFill;
2271
- return {
2272
- d: subpath.d,
2273
- fill: fillOff ? "none" : chunkDD2YRS6Z_js.colorWithOpacity(adjustFillForMode(fillColor, subpath.fillMode), fillOpacity),
2274
- stroked: subpath.stroke !== false
2275
- };
2276
- });
2277
- }
2278
- function getStrokeOnlyPresetPaths(element) {
2279
- if (element.type !== "shape" || !chunkDD2YRS6Z_js.hasShapeProperties(element)) {
2280
- return void 0;
2281
- }
2282
- const shapeType = element.shapeType;
2283
- if (!shapeType || shapeType === "custom") {
2284
- return void 0;
2285
- }
2286
- if (element.pathData) {
2287
- return void 0;
2288
- }
2289
- const result = chunkDD2YRS6Z_js.evaluatePresetShape(
2290
- shapeType,
2291
- Math.max(element.width, 1),
2292
- Math.max(element.height, 1),
2293
- element.shapeAdjustments
2294
- );
2295
- if (!result || !result.fillNone) {
2296
- return void 0;
2297
- }
2298
- const drawable = result.paths.filter((path) => path.d !== "");
2299
- return drawable.length > 0 ? drawable : void 0;
2238
+ chunkPB7KVDNV_js.apply3dEffects(base, scene3d, shape3d, fillColorFallback);
2300
2239
  }
2301
2240
 
2302
2241
  // src/viewer/utils/shape-visual-style.ts
@@ -2304,43 +2243,43 @@ function getGradientTilingCss(style) {
2304
2243
  if (!style || style.fillMode !== "gradient") {
2305
2244
  return void 0;
2306
2245
  }
2307
- const isStructuredLinear = (style.fillGradientType || "linear") === "linear" && chunkDD2YRS6Z_js.sanitizeGradientStops(style.fillGradientStops).length > 0;
2246
+ const isStructuredLinear = (style.fillGradientType || "linear") === "linear" && chunkPB7KVDNV_js.sanitizeGradientStops(style.fillGradientStops).length > 0;
2308
2247
  if (isStructuredLinear) {
2309
- const flip = chunkDD2YRS6Z_js.getGradientTileFlipCss(style.fillGradientFlip);
2248
+ const flip = chunkPB7KVDNV_js.getGradientTileFlipCss(style.fillGradientFlip);
2310
2249
  if (flip) {
2311
2250
  return flip;
2312
2251
  }
2313
2252
  }
2314
- return chunkDD2YRS6Z_js.getGradientTileRectCss(style.fillGradientTileRect);
2253
+ return chunkPB7KVDNV_js.getGradientTileRectCss(style.fillGradientTileRect);
2315
2254
  }
2316
2255
  function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeColor, animatesFill, animatesStroke) {
2317
- if (!chunkDD2YRS6Z_js.hasShapeProperties(element)) {
2256
+ if (!chunkPB7KVDNV_js.hasShapeProperties(element)) {
2318
2257
  return {};
2319
2258
  }
2320
2259
  const normalizedShapeType = getShapeType(element.shapeType);
2321
- const clipPath = chunkDD2YRS6Z_js.getResolvedShapeClipPath(element);
2260
+ const clipPath = chunkPB7KVDNV_js.getResolvedShapeClipPath(element);
2322
2261
  const rendersCustomVectorPath = (element.type === "shape" || element.type === "image" || element.type === "picture") && Boolean(element.pathData) && typeof element.pathWidth === "number" && element.pathWidth > 0 && typeof element.pathHeight === "number" && element.pathHeight > 0;
2323
- const rendersStrokeOnlyPreset = Boolean(getStrokeOnlyPresetPaths(element));
2262
+ const rendersStrokeOnlyPreset = chunkPB7KVDNV_js.isStrokeOnlyPresetElement(element);
2324
2263
  const fillOpacity = element.shapeStyle?.fillOpacity;
2325
2264
  const strokeOpacity = element.shapeStyle?.strokeOpacity;
2326
- const strokeDash = chunkDD2YRS6Z_js.normalizeStrokeDashType(element.shapeStyle?.strokeDash);
2327
- const fillGradient = chunkDD2YRS6Z_js.buildCssGradientFromShapeStyle(element.shapeStyle, {
2265
+ const strokeDash = chunkPB7KVDNV_js.normalizeStrokeDashType(element.shapeStyle?.strokeDash);
2266
+ const fillGradient = chunkPB7KVDNV_js.buildCssGradientFromShapeStyle(element.shapeStyle, {
2328
2267
  rotation: element.rotation,
2329
2268
  width: element.width,
2330
2269
  height: element.height
2331
2270
  }) || element.shapeStyle?.fillGradient;
2332
- const shadowCss = chunkDD2YRS6Z_js.buildShadowCssFromShapeStyle(element.shapeStyle);
2333
- const innerShadowCss = chunkDD2YRS6Z_js.buildInnerShadowCssFromShapeStyle(element.shapeStyle);
2334
- const resolvedFillColor = chunkDD2YRS6Z_js.colorWithOpacity(fillColor, fillOpacity);
2335
- const resolvedStrokeColor = chunkDD2YRS6Z_js.colorWithOpacity(strokeColor, strokeOpacity);
2271
+ const shadowCss = chunkPB7KVDNV_js.buildShadowCssFromShapeStyle(element.shapeStyle);
2272
+ const innerShadowCss = chunkPB7KVDNV_js.buildInnerShadowCssFromShapeStyle(element.shapeStyle);
2273
+ const resolvedFillColor = chunkPB7KVDNV_js.colorWithOpacity(fillColor, fillOpacity);
2274
+ const resolvedStrokeColor = chunkPB7KVDNV_js.colorWithOpacity(strokeColor, strokeOpacity);
2336
2275
  const ss = element.shapeStyle;
2337
2276
  const gradientTiling = getGradientTilingCss(ss);
2338
- const paintsGradientOutline = chunkDD2YRS6Z_js.suppressesCssBorder(element);
2277
+ const paintsGradientOutline = chunkPB7KVDNV_js.suppressesCssBorder(element);
2339
2278
  const hasFillOverlayColor = Boolean(
2340
2279
  ss?.dagFillOverlayColor && ss.dagFillOverlayColor !== "transparent"
2341
2280
  );
2342
2281
  const combinedShadowParts = [];
2343
- const multiLayerShadow = chunkDD2YRS6Z_js.buildMultiLayerShadowCss(element.shapeStyle);
2282
+ const multiLayerShadow = chunkPB7KVDNV_js.buildMultiLayerShadowCss(element.shapeStyle);
2344
2283
  if (multiLayerShadow) {
2345
2284
  combinedShadowParts.push(multiLayerShadow);
2346
2285
  } else if (shadowCss) {
@@ -2349,7 +2288,7 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
2349
2288
  if (innerShadowCss) {
2350
2289
  combinedShadowParts.push(innerShadowCss);
2351
2290
  }
2352
- const glowBoxShadow = chunkDD2YRS6Z_js.buildGlowBoxShadow(ss?.glowColor, ss?.glowRadius, ss?.glowOpacity);
2291
+ const glowBoxShadow = chunkPB7KVDNV_js.buildGlowBoxShadow(ss?.glowColor, ss?.glowRadius, ss?.glowOpacity);
2353
2292
  if (glowBoxShadow) {
2354
2293
  combinedShadowParts.push(glowBoxShadow);
2355
2294
  }
@@ -2357,7 +2296,7 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
2357
2296
  if (lineShadow) {
2358
2297
  combinedShadowParts.push(lineShadow);
2359
2298
  }
2360
- const compoundLineShadow = chunkDD2YRS6Z_js.getCompoundLineBoxShadow(
2299
+ const compoundLineShadow = chunkPB7KVDNV_js.getCompoundLineBoxShadow(
2361
2300
  element.shapeStyle?.compoundLine,
2362
2301
  strokeWidth,
2363
2302
  resolvedStrokeColor
@@ -2370,11 +2309,11 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
2370
2309
  if (ss?.glowColor && ss.glowColor !== "transparent" && ss.glowRadius) {
2371
2310
  const glowOpacity = typeof ss.glowOpacity === "number" ? ss.glowOpacity : 0.75;
2372
2311
  const glowRad = Math.round(Math.max(0, ss.glowRadius));
2373
- const glowCol = chunkDD2YRS6Z_js.colorWithOpacity(chunkDD2YRS6Z_js.normalizeHexColor(ss.glowColor, "#ffff00"), glowOpacity);
2312
+ const glowCol = chunkPB7KVDNV_js.colorWithOpacity(chunkPB7KVDNV_js.normalizeHexColor(ss.glowColor, "#ffff00"), glowOpacity);
2374
2313
  filterParts.push(`drop-shadow(0 0 ${glowRad}px ${glowCol})`);
2375
2314
  }
2376
2315
  if (typeof ss?.softEdgeRadius === "number" && ss.softEdgeRadius > 0) {
2377
- filterParts.push(`url(#${chunkDD2YRS6Z_js.getSoftEdgeFilterId(element.id)})`);
2316
+ filterParts.push(`url(#${chunkPB7KVDNV_js.getSoftEdgeFilterId(element.id)})`);
2378
2317
  }
2379
2318
  if (typeof ss?.blurRadius === "number" && ss.blurRadius > 0) {
2380
2319
  filterParts.push(`blur(${Math.round(ss.blurRadius)}px)`);
@@ -2383,13 +2322,13 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
2383
2322
  if (lineGlowCss) {
2384
2323
  filterParts.push(lineGlowCss);
2385
2324
  }
2386
- const dagFilter = chunkDD2YRS6Z_js.getEffectDagFilter(ss, element.id);
2325
+ const dagFilter = chunkPB7KVDNV_js.getEffectDagFilter(ss, element.id);
2387
2326
  if (dagFilter) {
2388
2327
  filterParts.push(dagFilter);
2389
2328
  }
2390
2329
  const lineJoinCss = ss?.lineJoin === "round" ? "round" : ss?.lineJoin === "bevel" ? "bevel" : ss?.lineJoin === "miter" ? "miter" : void 0;
2391
2330
  const miterLimitCss = ss?.lineJoin === "miter" && typeof ss?.miterLimit === "number" ? Math.max(ss.miterLimit / 1e5, 1) : void 0;
2392
- const patternFill = chunkDD2YRS6Z_js.buildPatternFillCss(element.shapeStyle);
2331
+ const patternFill = chunkPB7KVDNV_js.buildPatternFillCss(element.shapeStyle);
2393
2332
  const imageFillUrl = ss?.fillMode === "image" && ss.fillImageUrl ? ss.fillImageUrl : void 0;
2394
2333
  const imageFillMode = ss?.fillImageMode || "stretch";
2395
2334
  let reflectCss;
@@ -2401,7 +2340,7 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
2401
2340
  const endOpacity = typeof ss.reflectionEndOpacity === "number" ? ss.reflectionEndOpacity : 0;
2402
2341
  const fadeLength = typeof ss.reflectionEndPosition === "number" ? Math.round(ss.reflectionEndPosition * Math.max(element.height, 1)) : 100;
2403
2342
  const blurRadius = typeof ss.reflectionBlurRadius === "number" ? ss.reflectionBlurRadius : 0;
2404
- reflectCss = chunkDD2YRS6Z_js.buildReflectionCss(distance, startOpacity, endOpacity, fadeLength, blurRadius);
2343
+ reflectCss = chunkPB7KVDNV_js.buildReflectionCss(distance, startOpacity, endOpacity, fadeLength, blurRadius);
2405
2344
  }
2406
2345
  }
2407
2346
  const base = {
@@ -2447,9 +2386,9 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
2447
2386
  // path following the shape's geometry, because a CSS border can only take
2448
2387
  // one colour. Keeping the border too would draw the parser's averaged
2449
2388
  // solid underneath the gradient.
2450
- borderWidth: strokeWidth > 0 && !paintsGradientOutline ? chunkDD2YRS6Z_js.getCompoundLineBorderWidth(ss?.compoundLine, strokeWidth) : 0,
2389
+ borderWidth: strokeWidth > 0 && !paintsGradientOutline ? chunkPB7KVDNV_js.getCompoundLineBorderWidth(ss?.compoundLine, strokeWidth) : 0,
2451
2390
  borderColor: strokeWidth > 0 && !paintsGradientOutline ? resolvedStrokeColor : void 0,
2452
- borderStyle: strokeWidth > 0 && !paintsGradientOutline ? chunkDD2YRS6Z_js.getCssBorderDashStyle(strokeDash, ss?.compoundLine) : void 0,
2391
+ borderStyle: strokeWidth > 0 && !paintsGradientOutline ? chunkPB7KVDNV_js.getCssBorderDashStyle(strokeDash, ss?.compoundLine) : void 0,
2453
2392
  strokeLinejoin: lineJoinCss,
2454
2393
  strokeMiterlimit: miterLimitCss,
2455
2394
  strokeLinecap: ss?.lineCap === "rnd" ? "round" : ss?.lineCap === "sq" ? "square" : ss?.lineCap === "flat" ? "butt" : void 0
@@ -2498,14 +2437,14 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
2498
2437
  clipPath
2499
2438
  };
2500
2439
  }
2501
- if (normalizedShapeType === "line") {
2440
+ if (normalizedShapeType === "line" && !rendersStrokeOnlyPreset) {
2502
2441
  return {
2503
2442
  ...base,
2504
2443
  backgroundColor: "transparent",
2505
2444
  borderWidth: 0,
2506
2445
  borderTopWidth: Math.max(strokeWidth, 2),
2507
2446
  borderTopColor: resolvedStrokeColor,
2508
- borderTopStyle: chunkDD2YRS6Z_js.getCssBorderDashStyle(strokeDash)
2447
+ borderTopStyle: chunkPB7KVDNV_js.getCssBorderDashStyle(strokeDash)
2509
2448
  };
2510
2449
  }
2511
2450
  if (normalizedShapeType === "cylinder") {
@@ -2519,13 +2458,13 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
2519
2458
  function getConnectorAdjustment(element, key, fallback) {
2520
2459
  const direct = element.shapeAdjustments?.[key];
2521
2460
  if (typeof direct === "number" && Number.isFinite(direct)) {
2522
- return chunkDD2YRS6Z_js.clampUnitInterval(direct / 1e5);
2461
+ return chunkPB7KVDNV_js.clampUnitInterval(direct / 1e5);
2523
2462
  }
2524
2463
  const fallbackKey = element.shapeAdjustments?.adj;
2525
2464
  if (typeof fallbackKey === "number" && Number.isFinite(fallbackKey)) {
2526
- return chunkDD2YRS6Z_js.clampUnitInterval(fallbackKey / 1e5);
2465
+ return chunkPB7KVDNV_js.clampUnitInterval(fallbackKey / 1e5);
2527
2466
  }
2528
- return chunkDD2YRS6Z_js.clampUnitInterval(fallback);
2467
+ return chunkPB7KVDNV_js.clampUnitInterval(fallback);
2529
2468
  }
2530
2469
  function getConnectorPathGeometry(element) {
2531
2470
  const width = Math.max(element.width, 0);
@@ -2651,6 +2590,44 @@ function renderConnectorMarker(markerId, arrowType, color, arrowWidth, arrowLeng
2651
2590
  }
2652
2591
  );
2653
2592
  }
2593
+
2594
+ // src/viewer/utils/vector-subpath-paint.ts
2595
+ function toHexByte(value) {
2596
+ const clamped = Math.max(0, Math.min(255, Math.round(value)));
2597
+ return clamped.toString(16).padStart(2, "0");
2598
+ }
2599
+ function shiftHex(hex, factor, towardsWhite) {
2600
+ const channels = chunkPB7KVDNV_js.hexToRgbChannels(hex);
2601
+ if (!channels) {
2602
+ return hex;
2603
+ }
2604
+ const shift = (c) => towardsWhite ? c + (255 - c) * factor : c * (1 - factor);
2605
+ return `#${toHexByte(shift(channels.r))}${toHexByte(shift(channels.g))}${toHexByte(shift(channels.b))}`;
2606
+ }
2607
+ function adjustFillForMode(fillHex, mode) {
2608
+ switch (mode) {
2609
+ case "lighten":
2610
+ return shiftHex(fillHex, 0.4, true);
2611
+ case "lightenLess":
2612
+ return shiftHex(fillHex, 0.2, true);
2613
+ case "darken":
2614
+ return shiftHex(fillHex, 0.4, false);
2615
+ case "darkenLess":
2616
+ return shiftHex(fillHex, 0.2, false);
2617
+ default:
2618
+ return fillHex;
2619
+ }
2620
+ }
2621
+ function buildCustomSubpathPaints(subpaths, hasFill, fillColor, fillOpacity) {
2622
+ return subpaths.map((subpath) => {
2623
+ const fillOff = subpath.fillMode === "none" || !hasFill;
2624
+ return {
2625
+ d: subpath.d,
2626
+ fill: fillOff ? "none" : chunkPB7KVDNV_js.colorWithOpacity(adjustFillForMode(fillColor, subpath.fillMode), fillOpacity),
2627
+ stroked: subpath.stroke !== false
2628
+ };
2629
+ });
2630
+ }
2654
2631
  function joinStyle(shapeStyle) {
2655
2632
  const lineJoin = shapeStyle?.lineJoin === "bevel" ? "bevel" : shapeStyle?.lineJoin === "miter" ? "miter" : "round";
2656
2633
  const miterLimit = lineJoin === "miter" && typeof shapeStyle?.miterLimit === "number" ? Math.max(shapeStyle.miterLimit / 1e5, 1) : void 0;
@@ -2662,11 +2639,11 @@ function strokeContext(shapeStyle, strokePaint, strokeWidth, dashArray) {
2662
2639
  strokePaint,
2663
2640
  strokeWidth,
2664
2641
  dashArray,
2665
- lineCap: chunkDD2YRS6Z_js.svgLineCap(shapeStyle?.lineCap),
2642
+ lineCap: chunkPB7KVDNV_js.svgLineCap(shapeStyle?.lineCap),
2666
2643
  lineJoin,
2667
2644
  miterLimit,
2668
- offsets: chunkDD2YRS6Z_js.getCompoundLineOffsets(shapeStyle?.compoundLine, strokeWidth),
2669
- widths: chunkDD2YRS6Z_js.getCompoundLineWidths(shapeStyle?.compoundLine, strokeWidth)
2645
+ offsets: chunkPB7KVDNV_js.getCompoundLineOffsets(shapeStyle?.compoundLine, strokeWidth),
2646
+ widths: chunkPB7KVDNV_js.getCompoundLineWidths(shapeStyle?.compoundLine, strokeWidth)
2670
2647
  };
2671
2648
  }
2672
2649
  function strokeStrands(d, keyBase, ctx) {
@@ -2714,9 +2691,9 @@ function gradientDefs(gradient) {
2714
2691
  }
2715
2692
  function renderCustomGeometryVector(pathData, pathWidth, pathHeight, structuredPaths, shapeStyle, hasFill, fillColor, fillOpacity, strokePaint, strokeWidth, dashArray, animatesFill = false, gradient) {
2716
2693
  const ctx = strokeContext(shapeStyle, strokePaint, strokeWidth, dashArray);
2717
- const subpaths = structuredPaths && structuredPaths.length > 0 ? chunkDD2YRS6Z_js.customGeometryPathsToSvgSubpaths(structuredPaths, pathWidth, pathHeight) : void 0;
2694
+ const subpaths = structuredPaths && structuredPaths.length > 0 ? chunkPB7KVDNV_js.customGeometryPathsToSvgSubpaths(structuredPaths, pathWidth, pathHeight) : void 0;
2718
2695
  const needsPerSubpath = subpaths !== void 0 && subpaths.some((sp) => sp.fillMode && sp.fillMode !== "norm" || sp.stroke === false);
2719
- const gradientPaint = gradient ? chunkDD2YRS6Z_js.svgGradientFillRef(gradient) : void 0;
2696
+ const gradientPaint = gradient ? chunkPB7KVDNV_js.svgGradientFillRef(gradient) : void 0;
2720
2697
  const nodes = [];
2721
2698
  if (subpaths && needsPerSubpath) {
2722
2699
  const paints = buildCustomSubpathPaints(subpaths, hasFill, fillColor, fillOpacity);
@@ -2748,7 +2725,7 @@ function renderCustomGeometryVector(pathData, pathWidth, pathHeight, structuredP
2748
2725
  "path",
2749
2726
  {
2750
2727
  d: pathData,
2751
- fill: animatesFill ? "inherit" : gradientPaint ?? chunkDD2YRS6Z_js.colorWithOpacity(fillColor, fillOpacity),
2728
+ fill: animatesFill ? "inherit" : gradientPaint ?? chunkPB7KVDNV_js.colorWithOpacity(fillColor, fillOpacity),
2752
2729
  stroke: "none",
2753
2730
  vectorEffect: "non-scaling-stroke"
2754
2731
  },
@@ -2773,34 +2750,15 @@ function renderCustomGeometryVector(pathData, pathWidth, pathHeight, structuredP
2773
2750
  }
2774
2751
  );
2775
2752
  }
2776
- function renderStrokeOnlyPreset(presetPaths, width, height, shapeStyle, strokePaint, strokeWidth, dashArray) {
2777
- const ctx = strokeContext(shapeStyle, strokePaint, Math.max(strokeWidth, 1), dashArray);
2778
- const nodes = [];
2779
- presetPaths.forEach((path, idx) => {
2780
- if (path.stroke === false) {
2781
- return;
2782
- }
2783
- nodes.push(...strokeStrands(path.d, `pre${idx}`, ctx));
2784
- });
2785
- return /* @__PURE__ */ jsxRuntime.jsx(
2786
- "svg",
2787
- {
2788
- viewBox: `0 0 ${Math.max(width, 1)} ${Math.max(height, 1)}`,
2789
- className: "w-full h-full pointer-events-none",
2790
- preserveAspectRatio: "none",
2791
- children: nodes
2792
- }
2793
- );
2794
- }
2795
2753
  function renderVectorShape(element, hasFill, fillColor, strokeWidth, strokeColor, animatesFill, animatesStroke) {
2796
- if (!chunkDD2YRS6Z_js.hasShapeProperties(element)) {
2754
+ if (!chunkPB7KVDNV_js.hasShapeProperties(element)) {
2797
2755
  return null;
2798
2756
  }
2799
2757
  const normalizedType = (element.shapeType || "").toLowerCase();
2800
- const fillPaint = animatesFill ? "inherit" : chunkDD2YRS6Z_js.colorWithOpacity(fillColor, element.shapeStyle?.fillOpacity);
2801
- const strokePaint = animatesStroke ? "inherit" : chunkDD2YRS6Z_js.colorWithOpacity(strokeColor, element.shapeStyle?.strokeOpacity);
2802
- const dashType = chunkDD2YRS6Z_js.normalizeStrokeDashType(element.shapeStyle?.strokeDash);
2803
- const dashArray = chunkDD2YRS6Z_js.getSvgStrokeDasharray(
2758
+ const fillPaint = animatesFill ? "inherit" : chunkPB7KVDNV_js.colorWithOpacity(fillColor, element.shapeStyle?.fillOpacity);
2759
+ const strokePaint = animatesStroke ? "inherit" : chunkPB7KVDNV_js.colorWithOpacity(strokeColor, element.shapeStyle?.strokeOpacity);
2760
+ const dashType = chunkPB7KVDNV_js.normalizeStrokeDashType(element.shapeStyle?.strokeDash);
2761
+ const dashArray = chunkPB7KVDNV_js.getSvgStrokeDasharray(
2804
2762
  dashType,
2805
2763
  Math.max(strokeWidth, 1),
2806
2764
  element.shapeStyle?.customDashSegments
@@ -2881,21 +2839,21 @@ function renderVectorShape(element, hasFill, fillColor, strokeWidth, strokeColor
2881
2839
  // container's `background-image` is suppressed for custom geometry, so
2882
2840
  // without this the shape fell back to the parser's representative solid
2883
2841
  // and lost every fade (issue #132).
2884
- chunkDD2YRS6Z_js.buildSvgGradientDef(element.shapeStyle, element.id)
2842
+ chunkPB7KVDNV_js.buildSvgGradientDef(element.shapeStyle, element.id)
2885
2843
  );
2886
2844
  }
2887
- if (chunkDD2YRS6Z_js.isCalloutShape(normalizedType)) {
2845
+ if (chunkPB7KVDNV_js.isCalloutShape(normalizedType)) {
2888
2846
  const width = Math.max(element.width, 1);
2889
2847
  const height = Math.max(element.height, 1);
2890
- const geometry = chunkDD2YRS6Z_js.getCalloutLeaderLineGeometry(
2848
+ const geometry = chunkPB7KVDNV_js.getCalloutLeaderLineGeometry(
2891
2849
  normalizedType,
2892
2850
  width,
2893
2851
  height,
2894
2852
  element.shapeAdjustments
2895
2853
  );
2896
2854
  if (geometry && geometry.points.length >= 2) {
2897
- const leaderPath = chunkDD2YRS6Z_js.buildCalloutLeaderLineSvgPath(geometry);
2898
- const bounds = chunkDD2YRS6Z_js.getCalloutViewBoxBounds(width, height, geometry);
2855
+ const leaderPath = chunkPB7KVDNV_js.buildCalloutLeaderLineSvgPath(geometry);
2856
+ const bounds = chunkPB7KVDNV_js.getCalloutViewBoxBounds(width, height, geometry);
2899
2857
  const lineStroke = Math.max(strokeWidth, 1);
2900
2858
  const offsetLeft = bounds.minX;
2901
2859
  const offsetTop = bounds.minY;
@@ -2958,10 +2916,10 @@ function renderVectorShape(element, hasFill, fillColor, strokeWidth, strokeColor
2958
2916
  const endArrowW = element.shapeStyle?.connectorEndArrowWidth;
2959
2917
  const endArrowL = element.shapeStyle?.connectorEndArrowLength;
2960
2918
  const compoundLine = element.shapeStyle?.compoundLine;
2961
- const connectorLineCap = chunkDD2YRS6Z_js.svgLineCap(element.shapeStyle?.lineCap);
2919
+ const connectorLineCap = chunkPB7KVDNV_js.svgLineCap(element.shapeStyle?.lineCap);
2962
2920
  const hitTargetWidth = Math.max(strokeWidth * 3, 12);
2963
- const offsets = chunkDD2YRS6Z_js.getCompoundLineOffsets(compoundLine, strokeWidth);
2964
- const widths = chunkDD2YRS6Z_js.getCompoundLineWidths(compoundLine, strokeWidth);
2921
+ const offsets = chunkPB7KVDNV_js.getCompoundLineOffsets(compoundLine, strokeWidth);
2922
+ const widths = chunkPB7KVDNV_js.getCompoundLineWidths(compoundLine, strokeWidth);
2965
2923
  return /* @__PURE__ */ jsxRuntime.jsxs(
2966
2924
  "svg",
2967
2925
  {
@@ -3010,18 +2968,6 @@ function renderVectorShape(element, hasFill, fillColor, strokeWidth, strokeColor
3010
2968
  }
3011
2969
  );
3012
2970
  }
3013
- const strokeOnlyPreset = getStrokeOnlyPresetPaths(element);
3014
- if (strokeOnlyPreset) {
3015
- return renderStrokeOnlyPreset(
3016
- strokeOnlyPreset,
3017
- element.width,
3018
- element.height,
3019
- element.shapeStyle,
3020
- strokePaint,
3021
- strokeWidth,
3022
- dashArray
3023
- );
3024
- }
3025
2971
  return null;
3026
2972
  }
3027
2973
 
@@ -3040,15 +2986,15 @@ function parseGradientFillCss(gradFill) {
3040
2986
  }
3041
2987
  const parsed = stops.map((gs) => {
3042
2988
  const pos = Number.parseInt(String(gs["@_pos"] || "0"), 10) / 1e3;
3043
- const color = chunkDD2YRS6Z_js.parseDrawingColor(gs) ?? "#888888";
3044
- const opacity = chunkDD2YRS6Z_js.parseDrawingColorOpacity(gs);
3045
- return { pos, color: chunkDD2YRS6Z_js.colorWithOpacity(color, opacity) };
2989
+ const color = chunkPB7KVDNV_js.parseDrawingColor(gs) ?? "#888888";
2990
+ const opacity = chunkPB7KVDNV_js.parseDrawingColorOpacity(gs);
2991
+ return { pos, color: chunkPB7KVDNV_js.colorWithOpacity(color, opacity) };
3046
2992
  }).sort((a, b) => a.pos - b.pos);
3047
2993
  const stopStrings = parsed.map((s) => `${s.color} ${s.pos.toFixed(1)}%`).join(", ");
3048
2994
  const lin = gradFill["a:lin"];
3049
2995
  if (lin) {
3050
2996
  const angRaw = Number.parseInt(String(lin["@_ang"] || "0"), 10);
3051
- const angleDeg = Math.round(chunkDD2YRS6Z_js.ooxmlGradientAngleToCssDegrees(angRaw / 6e4));
2997
+ const angleDeg = Math.round(chunkPB7KVDNV_js.ooxmlGradientAngleToCssDegrees(angRaw / 6e4));
3052
2998
  return `linear-gradient(${angleDeg}deg, ${stopStrings})`;
3053
2999
  }
3054
3000
  const path = gradFill["a:path"];
@@ -3083,8 +3029,8 @@ function parsePatternFillCss(pattFill) {
3083
3029
  if (!pattFill) {
3084
3030
  return void 0;
3085
3031
  }
3086
- const fgColor = chunkDD2YRS6Z_js.parseDrawingColor(pattFill["a:fgClr"]) ?? "#000000";
3087
- const bgColor = chunkDD2YRS6Z_js.parseDrawingColor(pattFill["a:bgClr"]) ?? "#ffffff";
3032
+ const fgColor = chunkPB7KVDNV_js.parseDrawingColor(pattFill["a:fgClr"]) ?? "#000000";
3033
+ const bgColor = chunkPB7KVDNV_js.parseDrawingColor(pattFill["a:bgClr"]) ?? "#ffffff";
3088
3034
  const preset = String(pattFill["@_prst"] || "ltDnDiag");
3089
3035
  switch (preset) {
3090
3036
  case "ltHorz":
@@ -3195,11 +3141,11 @@ function parseCellBorders(cellProperties) {
3195
3141
  const prstDash = ln["a:prstDash"];
3196
3142
  const dashVal = prstDash ? String(prstDash["@_val"] || "") : void 0;
3197
3143
  const cssBorderStyle = ooxmlDashToCss(dashVal);
3198
- const color = chunkDD2YRS6Z_js.parseDrawingColor(ln["a:solidFill"]);
3144
+ const color = chunkPB7KVDNV_js.parseDrawingColor(ln["a:solidFill"]);
3199
3145
  if (color) {
3200
- const opacity = chunkDD2YRS6Z_js.parseDrawingColorOpacity(ln["a:solidFill"]);
3146
+ const opacity = chunkPB7KVDNV_js.parseDrawingColorOpacity(ln["a:solidFill"]);
3201
3147
  const key = `${edge.prefix}`;
3202
- borderStyle[key] = `${widthPx}px ${cssBorderStyle} ${chunkDD2YRS6Z_js.colorWithOpacity(color, opacity)}`;
3148
+ borderStyle[key] = `${widthPx}px ${cssBorderStyle} ${chunkPB7KVDNV_js.colorWithOpacity(color, opacity)}`;
3203
3149
  }
3204
3150
  }
3205
3151
  return borderStyle;
@@ -3212,7 +3158,7 @@ function parseCellTextEffects(runProps) {
3212
3158
  const textShadowParts = [];
3213
3159
  const outerShdw = effectLst["a:outerShdw"];
3214
3160
  if (outerShdw) {
3215
- const shdwColor = chunkDD2YRS6Z_js.parseDrawingColor(outerShdw);
3161
+ const shdwColor = chunkPB7KVDNV_js.parseDrawingColor(outerShdw);
3216
3162
  if (shdwColor) {
3217
3163
  const blurRad = Number.parseInt(String(outerShdw["@_blurRad"] || "0"), 10);
3218
3164
  const blurPx = blurRad > 0 ? Math.round(blurRad / 12700) : 0;
@@ -3230,7 +3176,7 @@ function parseCellTextEffects(runProps) {
3230
3176
  }
3231
3177
  const glow = effectLst["a:glow"];
3232
3178
  if (glow) {
3233
- const glowColor = chunkDD2YRS6Z_js.parseDrawingColor(glow);
3179
+ const glowColor = chunkPB7KVDNV_js.parseDrawingColor(glow);
3234
3180
  if (glowColor) {
3235
3181
  const glowRad = Number.parseInt(String(glow["@_rad"] || "0"), 10);
3236
3182
  const glowPx = glowRad > 0 ? Math.round(glowRad / 12700) : 2;
@@ -3309,10 +3255,10 @@ function extractTableCellStyle(cellXml, fallbackStyle, schemeColorOverrides) {
3309
3255
  if (runProps?.["@_u"] !== void 0) {
3310
3256
  cellStyle.textDecorationLine = runProps["@_u"] === "sng" ? "underline" : "none";
3311
3257
  }
3312
- const runColor = chunkDD2YRS6Z_js.parseDrawingColor(runProps?.["a:solidFill"], schemeColorOverrides) || chunkDD2YRS6Z_js.parseDrawingColor(runProps?.["a:highlight"], schemeColorOverrides);
3258
+ const runColor = chunkPB7KVDNV_js.parseDrawingColor(runProps?.["a:solidFill"], schemeColorOverrides) || chunkPB7KVDNV_js.parseDrawingColor(runProps?.["a:highlight"], schemeColorOverrides);
3313
3259
  if (runColor) {
3314
- const opacity = chunkDD2YRS6Z_js.parseDrawingColorOpacity(runProps?.["a:solidFill"]);
3315
- cellStyle.color = chunkDD2YRS6Z_js.colorWithOpacity(runColor, opacity);
3260
+ const opacity = chunkPB7KVDNV_js.parseDrawingColorOpacity(runProps?.["a:solidFill"]);
3261
+ cellStyle.color = chunkPB7KVDNV_js.colorWithOpacity(runColor, opacity);
3316
3262
  }
3317
3263
  const fontFamily = runProps?.["a:latin"]?.["@_typeface"] || runProps?.["a:ea"]?.["@_typeface"] || runProps?.["a:cs"]?.["@_typeface"];
3318
3264
  if (fontFamily) {
@@ -3322,15 +3268,15 @@ function extractTableCellStyle(cellXml, fallbackStyle, schemeColorOverrides) {
3322
3268
  cellStyle.textAlign = parseParagraphAlignment(paragraphProperties["@_algn"]);
3323
3269
  }
3324
3270
  const cellProperties = cellXml["a:tcPr"];
3325
- const cellFill = chunkDD2YRS6Z_js.parseDrawingColor(
3271
+ const cellFill = chunkPB7KVDNV_js.parseDrawingColor(
3326
3272
  cellProperties?.["a:solidFill"],
3327
3273
  schemeColorOverrides
3328
3274
  );
3329
3275
  if (cellFill) {
3330
- const opacity = chunkDD2YRS6Z_js.parseDrawingColorOpacity(
3276
+ const opacity = chunkPB7KVDNV_js.parseDrawingColorOpacity(
3331
3277
  cellProperties?.["a:solidFill"]
3332
3278
  );
3333
- cellStyle.backgroundColor = chunkDD2YRS6Z_js.colorWithOpacity(cellFill, opacity);
3279
+ cellStyle.backgroundColor = chunkPB7KVDNV_js.colorWithOpacity(cellFill, opacity);
3334
3280
  } else {
3335
3281
  const gradCss = parseGradientFillCss(cellProperties?.["a:gradFill"]);
3336
3282
  if (gradCss) {
@@ -3345,16 +3291,16 @@ function extractTableCellStyle(cellXml, fallbackStyle, schemeColorOverrides) {
3345
3291
  const edgeBorders = parseCellBorders(cellProperties);
3346
3292
  Object.assign(cellStyle, edgeBorders);
3347
3293
  if (!cellStyle.borderLeftColor && !cellStyle.borderRightColor && !cellStyle.borderTopColor && !cellStyle.borderBottomColor) {
3348
- const borderColor = chunkDD2YRS6Z_js.parseDrawingColor(
3294
+ const borderColor = chunkPB7KVDNV_js.parseDrawingColor(
3349
3295
  cellProperties?.["a:lnL"]?.["a:solidFill"],
3350
3296
  schemeColorOverrides
3351
- ) || chunkDD2YRS6Z_js.parseDrawingColor(
3297
+ ) || chunkPB7KVDNV_js.parseDrawingColor(
3352
3298
  cellProperties?.["a:lnR"]?.["a:solidFill"],
3353
3299
  schemeColorOverrides
3354
- ) || chunkDD2YRS6Z_js.parseDrawingColor(
3300
+ ) || chunkPB7KVDNV_js.parseDrawingColor(
3355
3301
  cellProperties?.["a:lnT"]?.["a:solidFill"],
3356
3302
  schemeColorOverrides
3357
- ) || chunkDD2YRS6Z_js.parseDrawingColor(
3303
+ ) || chunkPB7KVDNV_js.parseDrawingColor(
3358
3304
  cellProperties?.["a:lnB"]?.["a:solidFill"],
3359
3305
  schemeColorOverrides
3360
3306
  );
@@ -3433,10 +3379,10 @@ function resolveTableStyleFillColor(fill, colorScheme) {
3433
3379
  }
3434
3380
  let color = base;
3435
3381
  if (fill.tint !== void 0 && fill.tint > 0) {
3436
- color = chunkDD2YRS6Z_js.tintColor2(color, fill.tint / 1e5);
3382
+ color = chunkPB7KVDNV_js.tintColor2(color, fill.tint / 1e5);
3437
3383
  }
3438
3384
  if (fill.shade !== void 0 && fill.shade > 0) {
3439
- color = chunkDD2YRS6Z_js.shadeColor2(color, 1 - fill.shade / 1e5);
3385
+ color = chunkPB7KVDNV_js.shadeColor2(color, 1 - fill.shade / 1e5);
3440
3386
  }
3441
3387
  return color;
3442
3388
  }
@@ -3461,7 +3407,7 @@ function applyTableStyleText(text, colorScheme, style, fontScheme) {
3461
3407
  style.fontFamily = text.fontFace;
3462
3408
  applied = true;
3463
3409
  } else {
3464
- const refFont = chunkDD2YRS6Z_js.resolveFontRefIdx(text.fontRefIdx, fontScheme);
3410
+ const refFont = chunkPB7KVDNV_js.resolveFontRefIdx(text.fontRefIdx, fontScheme);
3465
3411
  if (refFont) {
3466
3412
  style.fontFamily = refFont;
3467
3413
  applied = true;
@@ -3472,10 +3418,10 @@ function applyTableStyleText(text, colorScheme, style, fontScheme) {
3472
3418
  if (base) {
3473
3419
  let color = base;
3474
3420
  if (text.fontTint !== void 0 && text.fontTint > 0) {
3475
- color = chunkDD2YRS6Z_js.tintColor2(color, text.fontTint / 1e5);
3421
+ color = chunkPB7KVDNV_js.tintColor2(color, text.fontTint / 1e5);
3476
3422
  }
3477
3423
  if (text.fontShade !== void 0 && text.fontShade > 0) {
3478
- color = chunkDD2YRS6Z_js.shadeColor2(color, 1 - text.fontShade / 1e5);
3424
+ color = chunkPB7KVDNV_js.shadeColor2(color, 1 - text.fontShade / 1e5);
3479
3425
  }
3480
3426
  style.color = color;
3481
3427
  applied = true;
@@ -3664,7 +3610,7 @@ function parseTableElementData(element, fallbackTextStyle) {
3664
3610
  };
3665
3611
  }
3666
3612
  function getCellDiagonalBorders2(style, tableData, pos, styleCtx) {
3667
- return chunkDD2YRS6Z_js.getCellDiagonalBorders(style, tableData, pos, {
3613
+ return chunkPB7KVDNV_js.getCellDiagonalBorders(style, tableData, pos, {
3668
3614
  tableStyleMap: styleCtx?.tableStyleMap,
3669
3615
  colorScheme: styleCtx?.theme?.colorScheme,
3670
3616
  fontScheme: styleCtx?.theme?.fontScheme
@@ -3812,9 +3758,9 @@ function cellStyleToCss(style) {
3812
3758
  if (style.gradientFillCss) {
3813
3759
  css.background = style.gradientFillCss;
3814
3760
  } else if (style.fillMode === "pattern" && style.patternFillPreset) {
3815
- const fg = chunkDD2YRS6Z_js.normalizeHexColor(style.patternFillForeground, "#000000");
3816
- const bg = chunkDD2YRS6Z_js.normalizeHexColor(style.patternFillBackground, "#ffffff");
3817
- const svgPattern = chunkDD2YRS6Z_js.getPatternSvg(style.patternFillPreset, fg, bg);
3761
+ const fg = chunkPB7KVDNV_js.normalizeHexColor(style.patternFillForeground, "#000000");
3762
+ const bg = chunkPB7KVDNV_js.normalizeHexColor(style.patternFillBackground, "#ffffff");
3763
+ const svgPattern = chunkPB7KVDNV_js.getPatternSvg(style.patternFillPreset, fg, bg);
3818
3764
  if (svgPattern) {
3819
3765
  const encoded = encodeURIComponent(svgPattern);
3820
3766
  css.backgroundImage = `url("data:image/svg+xml,${encoded}")`;
@@ -3890,7 +3836,7 @@ function cellStyleToCss(style) {
3890
3836
  if (edge.width || edge.color) {
3891
3837
  const w = edge.width ?? 1;
3892
3838
  const c = edge.color ?? style.borderColor ?? "#000000";
3893
- const s = chunkDD2YRS6Z_js.ooxmlDashToCssBorderStyle(edge.dash);
3839
+ const s = chunkPB7KVDNV_js.ooxmlDashToCssBorderStyle(edge.dash);
3894
3840
  css[edge.prefix] = `${w}px ${s} ${c}`;
3895
3841
  }
3896
3842
  }
@@ -3921,7 +3867,7 @@ function cellStyleToCss(style) {
3921
3867
  css.textShadow = textShadowParts.join(", ");
3922
3868
  }
3923
3869
  if (style.cell3D) {
3924
- Object.assign(css, chunkDD2YRS6Z_js.cell3DBevelCss(style.cell3D));
3870
+ Object.assign(css, chunkPB7KVDNV_js.cell3DBevelCss(style.cell3D));
3925
3871
  }
3926
3872
  return css;
3927
3873
  }
@@ -3935,7 +3881,7 @@ function TableResizeOverlay({
3935
3881
  const containerRef = React6.useRef(null);
3936
3882
  const [rowBounds, setRowBounds] = React6.useState([]);
3937
3883
  const dragRef = React6.useRef(null);
3938
- const colBoundaries = React6.useMemo(() => chunkDD2YRS6Z_js.computeColumnBoundaries(columnWidths), [columnWidths]);
3884
+ const colBoundaries = React6.useMemo(() => chunkPB7KVDNV_js.computeColumnBoundaries(columnWidths), [columnWidths]);
3939
3885
  const measureRows = React6.useCallback(() => {
3940
3886
  const container = containerRef.current;
3941
3887
  if (!container) {
@@ -3982,11 +3928,11 @@ function TableResizeOverlay({
3982
3928
  const rect = containerRef.current.getBoundingClientRect();
3983
3929
  if (drag.type === "col" && drag.initialWidths && onResizeColumns) {
3984
3930
  const deltaProp = (e.clientX - drag.startPos) / rect.width;
3985
- onResizeColumns(chunkDD2YRS6Z_js.computeResizedColumnWidths(drag.initialWidths, drag.index, deltaProp));
3931
+ onResizeColumns(chunkPB7KVDNV_js.computeResizedColumnWidths(drag.initialWidths, drag.index, deltaProp));
3986
3932
  } else if (drag.type === "row" && onResizeRow) {
3987
3933
  const deltaY = e.clientY - drag.startPos;
3988
- const newHeight = chunkDD2YRS6Z_js.computeResizedRowHeight(
3989
- drag.initialRowHeight ?? chunkDD2YRS6Z_js.DEFAULT_ROW_HEIGHT,
3934
+ const newHeight = chunkPB7KVDNV_js.computeResizedRowHeight(
3935
+ drag.initialRowHeight ?? chunkPB7KVDNV_js.DEFAULT_ROW_HEIGHT,
3990
3936
  deltaY
3991
3937
  );
3992
3938
  onResizeRow(drag.index, newHeight);
@@ -4024,7 +3970,7 @@ function TableResizeOverlay({
4024
3970
  e.stopPropagation();
4025
3971
  const table = containerRef.current?.querySelector("table");
4026
3972
  const tr = table?.querySelectorAll("tbody > tr")[index];
4027
- const actualHeight = tr?.offsetHeight ?? chunkDD2YRS6Z_js.DEFAULT_ROW_HEIGHT;
3973
+ const actualHeight = tr?.offsetHeight ?? chunkPB7KVDNV_js.DEFAULT_ROW_HEIGHT;
4028
3974
  document.body.style.cursor = "row-resize";
4029
3975
  document.body.style.userSelect = "none";
4030
3976
  dragRef.current = {
@@ -4072,7 +4018,7 @@ function renderTableFromTableData(element, textStyle, options) {
4072
4018
  }
4073
4019
  const first = selectedCell.selectedCells[0];
4074
4020
  const last = selectedCell.selectedCells[selectedCell.selectedCells.length - 1];
4075
- return chunkDD2YRS6Z_js.computeSelectionRect(first.row, first.col, last.row, last.col, tableData);
4021
+ return chunkPB7KVDNV_js.computeSelectionRect(first.row, first.col, last.row, last.col, tableData);
4076
4022
  })();
4077
4023
  return /* @__PURE__ */ jsxRuntime.jsx(
4078
4024
  TableResizeOverlay,
@@ -4088,113 +4034,120 @@ function renderTableFromTableData(element, textStyle, options) {
4088
4034
  "w-full h-full overflow-hidden",
4089
4035
  isEditable && hasCellSelectionHandler ? "pointer-events-auto" : "pointer-events-none"
4090
4036
  ),
4091
- children: /* @__PURE__ */ jsxRuntime.jsxs("table", { className: "w-full h-full border-collapse table-fixed", children: [
4092
- tableData.columnWidths.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("colgroup", { children: tableData.columnWidths.map((w, ci) => /* @__PURE__ */ jsxRuntime.jsx(
4093
- "col",
4094
- {
4095
- style: { width: `${(w * 100).toFixed(2)}%` }
4096
- },
4097
- `${element.id}-col-${ci}`
4098
- )) }),
4099
- /* @__PURE__ */ jsxRuntime.jsx("tbody", { children: tableData.rows.map((row, rowIndex) => /* @__PURE__ */ jsxRuntime.jsx(
4100
- "tr",
4101
- {
4102
- style: row.height ? { height: row.height } : void 0,
4103
- children: row.cells.map((cell, cellIndex) => {
4104
- if (cell.hMerge || cell.vMerge) {
4105
- return null;
4106
- }
4107
- const isCellSelected = selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex;
4108
- const isInMultiSelection = chunkDD2YRS6Z_js.isCellInRect(rowIndex, cellIndex, selectionRect);
4109
- const isCellEditing = isCellSelected && selectedCell?.isEditing;
4110
- const diag = getCellDiagonalBorders2(
4111
- cell.style,
4112
- tableData,
4113
- { rowIndex, cellIndex, rowCount, columnCount },
4114
- options?.styleCtx
4115
- );
4116
- return /* @__PURE__ */ jsxRuntime.jsxs(
4117
- "td",
4118
- {
4119
- className: cn(
4120
- "border px-1 py-0.5 align-top",
4121
- isEditable && hasCellSelectionHandler ? "border-blue-200/70 cursor-cell" : "border-gray-400/50",
4122
- isCellSelected ? "ring-1 ring-inset ring-blue-500" : null,
4123
- isInMultiSelection && !isCellSelected ? "bg-blue-500/15 ring-1 ring-inset ring-blue-400/50" : null
4124
- ),
4125
- colSpan: cell.gridSpan && cell.gridSpan > 1 ? cell.gridSpan : void 0,
4126
- rowSpan: cell.rowSpan && cell.rowSpan > 1 ? cell.rowSpan : void 0,
4127
- style: {
4128
- ...textStyle,
4129
- ...cellStyleToCss(cell.style),
4130
- ...diag ? { position: "relative" } : void 0
4131
- },
4132
- onClick: (event) => {
4133
- if (!isEditable || !hasCellSelectionHandler) {
4134
- return;
4135
- }
4136
- event.stopPropagation();
4137
- if (event.shiftKey && selectedCell) {
4138
- const rect = chunkDD2YRS6Z_js.computeSelectionRect(
4139
- selectedCell.rowIndex,
4140
- selectedCell.columnIndex,
4141
- rowIndex,
4142
- cellIndex,
4143
- tableData
4144
- );
4145
- options?.onSelectCell?.({
4146
- rowIndex: selectedCell.rowIndex,
4147
- columnIndex: selectedCell.columnIndex,
4148
- selectedCells: chunkDD2YRS6Z_js.rectToCells(rect)
4149
- });
4150
- } else {
4151
- options?.onSelectCell?.({
4152
- rowIndex,
4153
- columnIndex: cellIndex
4154
- });
4155
- }
4156
- },
4157
- onDoubleClick: (event) => {
4158
- if (!isEditable || !hasCellSelectionHandler) {
4159
- return;
4160
- }
4161
- event.stopPropagation();
4162
- options?.onSelectCell?.({
4163
- rowIndex,
4164
- columnIndex: cellIndex,
4165
- isEditing: true
4166
- });
4167
- },
4168
- children: [
4169
- diag ? /* @__PURE__ */ jsxRuntime.jsx(TableCellDiagonalBorders, { diag }) : null,
4170
- isCellEditing ? /* @__PURE__ */ jsxRuntime.jsx(
4171
- TableCellInput,
4172
- {
4173
- initialText: cell.text ?? "",
4174
- style: {
4175
- ...textStyle,
4176
- ...cellStyleToCss(cell.style)
4177
- },
4178
- onCommit: (text) => {
4179
- options?.onCommitCellEdit?.(rowIndex, cellIndex, text);
4180
- },
4181
- onCancel: () => {
4037
+ children: /* @__PURE__ */ jsxRuntime.jsxs(
4038
+ "table",
4039
+ {
4040
+ className: "w-full h-full border-collapse table-fixed",
4041
+ style: { fontFamily: chunkPB7KVDNV_js.DEFAULT_FONT_FAMILY },
4042
+ children: [
4043
+ tableData.columnWidths.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("colgroup", { children: tableData.columnWidths.map((w, ci) => /* @__PURE__ */ jsxRuntime.jsx(
4044
+ "col",
4045
+ {
4046
+ style: { width: `${(w * 100).toFixed(2)}%` }
4047
+ },
4048
+ `${element.id}-col-${ci}`
4049
+ )) }),
4050
+ /* @__PURE__ */ jsxRuntime.jsx("tbody", { children: tableData.rows.map((row, rowIndex) => /* @__PURE__ */ jsxRuntime.jsx(
4051
+ "tr",
4052
+ {
4053
+ style: row.height ? { height: row.height } : void 0,
4054
+ children: row.cells.map((cell, cellIndex) => {
4055
+ if (cell.hMerge || cell.vMerge) {
4056
+ return null;
4057
+ }
4058
+ const isCellSelected = selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex;
4059
+ const isInMultiSelection = chunkPB7KVDNV_js.isCellInRect(rowIndex, cellIndex, selectionRect);
4060
+ const isCellEditing = isCellSelected && selectedCell?.isEditing;
4061
+ const diag = getCellDiagonalBorders2(
4062
+ cell.style,
4063
+ tableData,
4064
+ { rowIndex, cellIndex, rowCount, columnCount },
4065
+ options?.styleCtx
4066
+ );
4067
+ return /* @__PURE__ */ jsxRuntime.jsxs(
4068
+ "td",
4069
+ {
4070
+ className: cn(
4071
+ "border px-1 py-0.5 align-top",
4072
+ isEditable && hasCellSelectionHandler ? "border-blue-200/70 cursor-cell" : "border-gray-400/50",
4073
+ isCellSelected ? "ring-1 ring-inset ring-blue-500" : null,
4074
+ isInMultiSelection && !isCellSelected ? "bg-blue-500/15 ring-1 ring-inset ring-blue-400/50" : null
4075
+ ),
4076
+ colSpan: cell.gridSpan && cell.gridSpan > 1 ? cell.gridSpan : void 0,
4077
+ rowSpan: cell.rowSpan && cell.rowSpan > 1 ? cell.rowSpan : void 0,
4078
+ style: {
4079
+ ...textStyle,
4080
+ ...cellStyleToCss(cell.style),
4081
+ ...diag ? { position: "relative" } : void 0
4082
+ },
4083
+ onClick: (event) => {
4084
+ if (!isEditable || !hasCellSelectionHandler) {
4085
+ return;
4086
+ }
4087
+ event.stopPropagation();
4088
+ if (event.shiftKey && selectedCell) {
4089
+ const rect = chunkPB7KVDNV_js.computeSelectionRect(
4090
+ selectedCell.rowIndex,
4091
+ selectedCell.columnIndex,
4092
+ rowIndex,
4093
+ cellIndex,
4094
+ tableData
4095
+ );
4096
+ options?.onSelectCell?.({
4097
+ rowIndex: selectedCell.rowIndex,
4098
+ columnIndex: selectedCell.columnIndex,
4099
+ selectedCells: chunkPB7KVDNV_js.rectToCells(rect)
4100
+ });
4101
+ } else {
4182
4102
  options?.onSelectCell?.({
4183
4103
  rowIndex,
4184
4104
  columnIndex: cellIndex
4185
4105
  });
4186
4106
  }
4187
- }
4188
- ) : cell.text || "\xA0"
4189
- ]
4190
- },
4191
- `${element.id}-cell-${rowIndex}-${cellIndex}`
4192
- );
4193
- })
4194
- },
4195
- `${element.id}-row-${rowIndex}`
4196
- )) })
4197
- ] })
4107
+ },
4108
+ onDoubleClick: (event) => {
4109
+ if (!isEditable || !hasCellSelectionHandler) {
4110
+ return;
4111
+ }
4112
+ event.stopPropagation();
4113
+ options?.onSelectCell?.({
4114
+ rowIndex,
4115
+ columnIndex: cellIndex,
4116
+ isEditing: true
4117
+ });
4118
+ },
4119
+ children: [
4120
+ diag ? /* @__PURE__ */ jsxRuntime.jsx(TableCellDiagonalBorders, { diag }) : null,
4121
+ isCellEditing ? /* @__PURE__ */ jsxRuntime.jsx(
4122
+ TableCellInput,
4123
+ {
4124
+ initialText: cell.text ?? "",
4125
+ style: {
4126
+ ...textStyle,
4127
+ ...cellStyleToCss(cell.style)
4128
+ },
4129
+ onCommit: (text) => {
4130
+ options?.onCommitCellEdit?.(rowIndex, cellIndex, text);
4131
+ },
4132
+ onCancel: () => {
4133
+ options?.onSelectCell?.({
4134
+ rowIndex,
4135
+ columnIndex: cellIndex
4136
+ });
4137
+ }
4138
+ }
4139
+ ) : cell.text || "\xA0"
4140
+ ]
4141
+ },
4142
+ `${element.id}-cell-${rowIndex}-${cellIndex}`
4143
+ );
4144
+ })
4145
+ },
4146
+ `${element.id}-row-${rowIndex}`
4147
+ )) })
4148
+ ]
4149
+ }
4150
+ )
4198
4151
  }
4199
4152
  )
4200
4153
  }
@@ -4207,7 +4160,7 @@ function renderTableElement(element, textStyle, options) {
4207
4160
  if (tableEl2.tableData && tableEl2.tableData.rows.length > 0) {
4208
4161
  return renderTableFromTableData(tableEl2, textStyle, options);
4209
4162
  }
4210
- return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunkBXAK3JFM_js.translationsEn["pptx.table.title"] });
4163
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunk3ISYPBSX_js.translationsEn["pptx.table.title"] });
4211
4164
  }
4212
4165
  const selectedCell = options?.selectedCell || null;
4213
4166
  const isEditable = Boolean(options?.editable);
@@ -4222,7 +4175,7 @@ function renderTableElement(element, textStyle, options) {
4222
4175
  }
4223
4176
  const first = selectedCell.selectedCells[0];
4224
4177
  const last = selectedCell.selectedCells[selectedCell.selectedCells.length - 1];
4225
- return chunkDD2YRS6Z_js.computeSelectionRect(first.row, first.col, last.row, last.col, tableEl.tableData);
4178
+ return chunkPB7KVDNV_js.computeSelectionRect(first.row, first.col, last.row, last.col, tableEl.tableData);
4226
4179
  })();
4227
4180
  const schemeOverrides = options?.styleCtx?.theme?.colorScheme ? options.styleCtx.theme.colorScheme : void 0;
4228
4181
  return /* @__PURE__ */ jsxRuntime.jsx(
@@ -4239,135 +4192,142 @@ function renderTableElement(element, textStyle, options) {
4239
4192
  "w-full h-full overflow-hidden",
4240
4193
  isEditable && hasCellSelectionHandler ? "pointer-events-auto" : "pointer-events-none"
4241
4194
  ),
4242
- children: /* @__PURE__ */ jsxRuntime.jsxs("table", { className: "w-full h-full border-collapse table-fixed", children: [
4243
- parsedTable.columnPercentages.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx("colgroup", { children: parsedTable.columnPercentages.map((percentage, columnIndex) => /* @__PURE__ */ jsxRuntime.jsx(
4244
- "col",
4245
- {
4246
- style: { width: `${percentage.toFixed(2)}%` }
4247
- },
4248
- `${element.id}-col-${columnIndex}`
4249
- )) }) : null,
4250
- /* @__PURE__ */ jsxRuntime.jsx("tbody", { children: parsedTable.rows.map((row, rowIndex) => {
4251
- const cells = ensureArrayValue(row["a:tc"]);
4252
- const rowHeightRaw = Number.parseInt(String(row["@_h"] || ""), 10);
4253
- const rowHeight = Number.isFinite(rowHeightRaw) && rowHeightRaw > 0 ? Math.max(16, rowHeightRaw / EMU_PER_PX) : void 0;
4254
- return /* @__PURE__ */ jsxRuntime.jsx(
4255
- "tr",
4256
- {
4257
- style: rowHeight ? { height: rowHeight } : void 0,
4258
- children: cells.map((cell, cellIndex) => {
4259
- const isHMerged = cell["@_hMerge"] === "1";
4260
- const isVMerged = cell["@_vMerge"] === "1";
4261
- if (isHMerged || isVMerged) {
4262
- return null;
4263
- }
4264
- const gridSpanRaw = Number.parseInt(String(cell["@_gridSpan"] || ""), 10);
4265
- const colSpan = Number.isFinite(gridSpanRaw) && gridSpanRaw > 1 ? gridSpanRaw : void 0;
4266
- const rowSpanRaw = Number.parseInt(String(cell["@_rowSpan"] || ""), 10);
4267
- const rSpan = Number.isFinite(rowSpanRaw) && rowSpanRaw > 1 ? rowSpanRaw : void 0;
4268
- const bandStyle = getTableCellBandStyle(
4269
- element,
4270
- rowIndex,
4271
- cellIndex,
4272
- parsedTable.rowCount,
4273
- parsedTable.columnCount,
4274
- options?.styleCtx
4275
- );
4276
- const xmlCellStyle = extractTableCellStyle(cell, textStyle, schemeOverrides);
4277
- const tdCellOverride = tableEl.tableData?.rows[rowIndex]?.cells[cellIndex]?.style;
4278
- const diag = getCellDiagonalBorders2(
4279
- tdCellOverride,
4280
- tableEl.tableData,
4281
- {
4282
- rowIndex,
4283
- cellIndex,
4284
- rowCount: parsedTable.rowCount,
4285
- columnCount: parsedTable.columnCount
4286
- },
4287
- options?.styleCtx
4288
- );
4289
- const mergedStyle = {
4290
- ...bandStyle,
4291
- ...xmlCellStyle,
4292
- ...tdCellOverride ? cellStyleToCss(tdCellOverride) : void 0,
4293
- ...diag ? { position: "relative" } : void 0
4294
- };
4295
- return /* @__PURE__ */ jsxRuntime.jsxs(
4296
- "td",
4297
- {
4298
- className: cn(
4299
- "border px-1 py-0.5 align-top",
4300
- isEditable && hasCellSelectionHandler ? "border-blue-200/70 cursor-cell" : "border-white/30",
4301
- selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex ? "ring-1 ring-inset ring-blue-500" : null,
4302
- chunkDD2YRS6Z_js.isCellInRect(rowIndex, cellIndex, xmlSelectionRect) && !(selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex) ? "bg-blue-500/15 ring-1 ring-inset ring-blue-400/50" : null
4303
- ),
4304
- colSpan,
4305
- rowSpan: rSpan,
4306
- style: mergedStyle,
4307
- onClick: (event) => {
4308
- if (!isEditable || !hasCellSelectionHandler) {
4309
- return;
4310
- }
4311
- event.stopPropagation();
4312
- if (event.shiftKey && selectedCell && tableEl.tableData) {
4313
- const rect = chunkDD2YRS6Z_js.computeSelectionRect(
4314
- selectedCell.rowIndex,
4315
- selectedCell.columnIndex,
4316
- rowIndex,
4317
- cellIndex,
4318
- tableEl.tableData
4319
- );
4320
- options?.onSelectCell?.({
4321
- rowIndex: selectedCell.rowIndex,
4322
- columnIndex: selectedCell.columnIndex,
4323
- selectedCells: chunkDD2YRS6Z_js.rectToCells(rect)
4324
- });
4325
- } else {
4326
- options?.onSelectCell?.({
4327
- rowIndex,
4328
- columnIndex: cellIndex
4329
- });
4330
- }
4331
- },
4332
- onDoubleClick: (event) => {
4333
- if (!isEditable || !hasCellSelectionHandler) {
4334
- return;
4335
- }
4336
- event.stopPropagation();
4337
- options?.onSelectCell?.({
4195
+ children: /* @__PURE__ */ jsxRuntime.jsxs(
4196
+ "table",
4197
+ {
4198
+ className: "w-full h-full border-collapse table-fixed",
4199
+ style: { fontFamily: chunkPB7KVDNV_js.DEFAULT_FONT_FAMILY },
4200
+ children: [
4201
+ parsedTable.columnPercentages.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx("colgroup", { children: parsedTable.columnPercentages.map((percentage, columnIndex) => /* @__PURE__ */ jsxRuntime.jsx(
4202
+ "col",
4203
+ {
4204
+ style: { width: `${percentage.toFixed(2)}%` }
4205
+ },
4206
+ `${element.id}-col-${columnIndex}`
4207
+ )) }) : null,
4208
+ /* @__PURE__ */ jsxRuntime.jsx("tbody", { children: parsedTable.rows.map((row, rowIndex) => {
4209
+ const cells = ensureArrayValue(row["a:tc"]);
4210
+ const rowHeightRaw = Number.parseInt(String(row["@_h"] || ""), 10);
4211
+ const rowHeight = Number.isFinite(rowHeightRaw) && rowHeightRaw > 0 ? Math.max(16, rowHeightRaw / EMU_PER_PX) : void 0;
4212
+ return /* @__PURE__ */ jsxRuntime.jsx(
4213
+ "tr",
4214
+ {
4215
+ style: rowHeight ? { height: rowHeight } : void 0,
4216
+ children: cells.map((cell, cellIndex) => {
4217
+ const isHMerged = cell["@_hMerge"] === "1";
4218
+ const isVMerged = cell["@_vMerge"] === "1";
4219
+ if (isHMerged || isVMerged) {
4220
+ return null;
4221
+ }
4222
+ const gridSpanRaw = Number.parseInt(String(cell["@_gridSpan"] || ""), 10);
4223
+ const colSpan = Number.isFinite(gridSpanRaw) && gridSpanRaw > 1 ? gridSpanRaw : void 0;
4224
+ const rowSpanRaw = Number.parseInt(String(cell["@_rowSpan"] || ""), 10);
4225
+ const rSpan = Number.isFinite(rowSpanRaw) && rowSpanRaw > 1 ? rowSpanRaw : void 0;
4226
+ const bandStyle = getTableCellBandStyle(
4227
+ element,
4228
+ rowIndex,
4229
+ cellIndex,
4230
+ parsedTable.rowCount,
4231
+ parsedTable.columnCount,
4232
+ options?.styleCtx
4233
+ );
4234
+ const xmlCellStyle = extractTableCellStyle(cell, textStyle, schemeOverrides);
4235
+ const tdCellOverride = tableEl.tableData?.rows[rowIndex]?.cells[cellIndex]?.style;
4236
+ const diag = getCellDiagonalBorders2(
4237
+ tdCellOverride,
4238
+ tableEl.tableData,
4239
+ {
4338
4240
  rowIndex,
4339
- columnIndex: cellIndex,
4340
- isEditing: true
4341
- });
4342
- },
4343
- children: [
4344
- diag ? /* @__PURE__ */ jsxRuntime.jsx(TableCellDiagonalBorders, { diag }) : null,
4345
- selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex && selectedCell?.isEditing ? /* @__PURE__ */ jsxRuntime.jsx(
4346
- TableCellInput,
4347
- {
4348
- initialText: extractCellText(cell) ?? "",
4349
- style: mergedStyle,
4350
- onCommit: (text) => {
4351
- options?.onCommitCellEdit?.(rowIndex, cellIndex, text);
4352
- },
4353
- onCancel: () => {
4241
+ cellIndex,
4242
+ rowCount: parsedTable.rowCount,
4243
+ columnCount: parsedTable.columnCount
4244
+ },
4245
+ options?.styleCtx
4246
+ );
4247
+ const mergedStyle = {
4248
+ ...bandStyle,
4249
+ ...xmlCellStyle,
4250
+ ...tdCellOverride ? cellStyleToCss(tdCellOverride) : void 0,
4251
+ ...diag ? { position: "relative" } : void 0
4252
+ };
4253
+ return /* @__PURE__ */ jsxRuntime.jsxs(
4254
+ "td",
4255
+ {
4256
+ className: cn(
4257
+ "border px-1 py-0.5 align-top",
4258
+ isEditable && hasCellSelectionHandler ? "border-blue-200/70 cursor-cell" : "border-white/30",
4259
+ selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex ? "ring-1 ring-inset ring-blue-500" : null,
4260
+ chunkPB7KVDNV_js.isCellInRect(rowIndex, cellIndex, xmlSelectionRect) && !(selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex) ? "bg-blue-500/15 ring-1 ring-inset ring-blue-400/50" : null
4261
+ ),
4262
+ colSpan,
4263
+ rowSpan: rSpan,
4264
+ style: mergedStyle,
4265
+ onClick: (event) => {
4266
+ if (!isEditable || !hasCellSelectionHandler) {
4267
+ return;
4268
+ }
4269
+ event.stopPropagation();
4270
+ if (event.shiftKey && selectedCell && tableEl.tableData) {
4271
+ const rect = chunkPB7KVDNV_js.computeSelectionRect(
4272
+ selectedCell.rowIndex,
4273
+ selectedCell.columnIndex,
4274
+ rowIndex,
4275
+ cellIndex,
4276
+ tableEl.tableData
4277
+ );
4278
+ options?.onSelectCell?.({
4279
+ rowIndex: selectedCell.rowIndex,
4280
+ columnIndex: selectedCell.columnIndex,
4281
+ selectedCells: chunkPB7KVDNV_js.rectToCells(rect)
4282
+ });
4283
+ } else {
4354
4284
  options?.onSelectCell?.({
4355
4285
  rowIndex,
4356
4286
  columnIndex: cellIndex
4357
4287
  });
4358
4288
  }
4359
- }
4360
- ) : extractCellText(cell) || "\xA0"
4361
- ]
4362
- },
4363
- `${element.id}-cell-${rowIndex}-${cellIndex}`
4364
- );
4365
- })
4366
- },
4367
- `${element.id}-row-${rowIndex}`
4368
- );
4369
- }) })
4370
- ] })
4289
+ },
4290
+ onDoubleClick: (event) => {
4291
+ if (!isEditable || !hasCellSelectionHandler) {
4292
+ return;
4293
+ }
4294
+ event.stopPropagation();
4295
+ options?.onSelectCell?.({
4296
+ rowIndex,
4297
+ columnIndex: cellIndex,
4298
+ isEditing: true
4299
+ });
4300
+ },
4301
+ children: [
4302
+ diag ? /* @__PURE__ */ jsxRuntime.jsx(TableCellDiagonalBorders, { diag }) : null,
4303
+ selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex && selectedCell?.isEditing ? /* @__PURE__ */ jsxRuntime.jsx(
4304
+ TableCellInput,
4305
+ {
4306
+ initialText: extractCellText(cell) ?? "",
4307
+ style: mergedStyle,
4308
+ onCommit: (text) => {
4309
+ options?.onCommitCellEdit?.(rowIndex, cellIndex, text);
4310
+ },
4311
+ onCancel: () => {
4312
+ options?.onSelectCell?.({
4313
+ rowIndex,
4314
+ columnIndex: cellIndex
4315
+ });
4316
+ }
4317
+ }
4318
+ ) : extractCellText(cell) || "\xA0"
4319
+ ]
4320
+ },
4321
+ `${element.id}-cell-${rowIndex}-${cellIndex}`
4322
+ );
4323
+ })
4324
+ },
4325
+ `${element.id}-row-${rowIndex}`
4326
+ );
4327
+ }) })
4328
+ ]
4329
+ }
4330
+ )
4371
4331
  }
4372
4332
  )
4373
4333
  }
@@ -4375,24 +4335,24 @@ function renderTableElement(element, textStyle, options) {
4375
4335
  }
4376
4336
  var LEGEND_ITEM_WIDTH = 80;
4377
4337
  function partAttrs(part) {
4378
- return part ? chunkDD2YRS6Z_js.chartPartToAttrs(part) : void 0;
4338
+ return part ? chunkPB7KVDNV_js.chartPartToAttrs(part) : void 0;
4379
4339
  }
4380
4340
  function resolveReactPalette(chartData) {
4381
4341
  if (chartData.colorPalette && chartData.colorPalette.length > 0) {
4382
4342
  return chartData.colorPalette;
4383
4343
  }
4384
- return [...chunkDD2YRS6Z_js.getChartStylePalette(chartData.style?.styleId)];
4344
+ return [...chunkPB7KVDNV_js.getChartStylePalette(chartData.style?.styleId)];
4385
4345
  }
4386
4346
  function buildReactChartViewModel(element) {
4387
4347
  if (element.type !== "chart" || !element.chartData) {
4388
- return chunkDD2YRS6Z_js.buildChartViewModel(element);
4348
+ return chunkPB7KVDNV_js.buildChartViewModel(element);
4389
4349
  }
4390
4350
  const palette = resolveReactPalette(element.chartData);
4391
4351
  const themedElement = {
4392
4352
  ...element,
4393
4353
  chartData: { ...element.chartData, colorPalette: palette }
4394
4354
  };
4395
- return chunkDD2YRS6Z_js.buildChartViewModel(themedElement);
4355
+ return chunkPB7KVDNV_js.buildChartViewModel(themedElement);
4396
4356
  }
4397
4357
  function renderPrimitive(prim, key) {
4398
4358
  switch (prim.kind) {
@@ -4781,7 +4741,7 @@ function renderMapChart(element, chartData, categoryLabels) {
4781
4741
  const unmatchedRows = [];
4782
4742
  categories.forEach((cat, i) => {
4783
4743
  const value = values[i] ?? 0;
4784
- const code = chunkDD2YRS6Z_js.resolveRegionCode(cat);
4744
+ const code = chunkPB7KVDNV_js.resolveRegionCode(cat);
4785
4745
  if (code) {
4786
4746
  regionValueMap.set(code, { value, label: cat });
4787
4747
  } else {
@@ -4819,8 +4779,8 @@ function renderMapChart(element, chartData, categoryLabels) {
4819
4779
  let fill = "#e2e8f0";
4820
4780
  let dataLabel = null;
4821
4781
  if (entry) {
4822
- const t = chunkDD2YRS6Z_js.normalizeValue(entry.value, minVal, maxVal);
4823
- fill = chunkDD2YRS6Z_js.sequentialColorScale(t);
4782
+ const t = chunkPB7KVDNV_js.normalizeValue(entry.value, minVal, maxVal);
4783
+ fill = chunkPB7KVDNV_js.sequentialColorScale(t);
4824
4784
  dataLabel = /* @__PURE__ */ jsxRuntime.jsx(
4825
4785
  "text",
4826
4786
  {
@@ -4831,7 +4791,7 @@ function renderMapChart(element, chartData, categoryLabels) {
4831
4791
  fontWeight: 600,
4832
4792
  fill: "#1e293b",
4833
4793
  style: { pointerEvents: "none" },
4834
- children: chunkDD2YRS6Z_js.formatAxisValue(entry.value)
4794
+ children: chunkPB7KVDNV_js.formatAxisValue(entry.value)
4835
4795
  },
4836
4796
  `${element.id}-map-dl-${region.code}`
4837
4797
  );
@@ -4849,7 +4809,7 @@ function renderMapChart(element, chartData, categoryLabels) {
4849
4809
  opacity: 0.9,
4850
4810
  children: /* @__PURE__ */ jsxRuntime.jsxs("title", { children: [
4851
4811
  region.name,
4852
- entry ? `: ${chunkDD2YRS6Z_js.formatAxisValue(entry.value)}` : ""
4812
+ entry ? `: ${chunkPB7KVDNV_js.formatAxisValue(entry.value)}` : ""
4853
4813
  ] })
4854
4814
  }
4855
4815
  ),
@@ -4887,7 +4847,7 @@ function renderMapChart(element, chartData, categoryLabels) {
4887
4847
  fontSize: 7,
4888
4848
  fill: "#64748b",
4889
4849
  textAnchor: "middle",
4890
- children: chunkDD2YRS6Z_js.formatAxisValue(minVal)
4850
+ children: chunkPB7KVDNV_js.formatAxisValue(minVal)
4891
4851
  },
4892
4852
  `${element.id}-map-legend-min`
4893
4853
  ),
@@ -4899,7 +4859,7 @@ function renderMapChart(element, chartData, categoryLabels) {
4899
4859
  fontSize: 7,
4900
4860
  fill: "#64748b",
4901
4861
  textAnchor: "middle",
4902
- children: chunkDD2YRS6Z_js.formatAxisValue(maxVal)
4862
+ children: chunkPB7KVDNV_js.formatAxisValue(maxVal)
4903
4863
  },
4904
4864
  `${element.id}-map-legend-max`
4905
4865
  )
@@ -4918,7 +4878,7 @@ function renderMapChart(element, chartData, categoryLabels) {
4918
4878
  textAnchor: "middle",
4919
4879
  fontSize: 7,
4920
4880
  fill: "#94a3b8",
4921
- children: chunkBXAK3JFM_js.translationsEn["pptx.chart.additionalRegionsFallback"]
4881
+ children: chunk3ISYPBSX_js.translationsEn["pptx.chart.additionalRegionsFallback"]
4922
4882
  },
4923
4883
  `${element.id}-map-ft-hdr`
4924
4884
  )
@@ -4965,7 +4925,7 @@ function renderMapChart(element, chartData, categoryLabels) {
4965
4925
  y,
4966
4926
  fontSize,
4967
4927
  fill: "#475569",
4968
- children: chunkDD2YRS6Z_js.formatAxisValue(row.value)
4928
+ children: chunkPB7KVDNV_js.formatAxisValue(row.value)
4969
4929
  },
4970
4930
  `${element.id}-map-ft-val-${i}`
4971
4931
  )
@@ -5036,7 +4996,7 @@ function renderStackedBarChart(element, _chartData, _categoryLabels) {
5036
4996
 
5037
4997
  // src/viewer/utils/chart-overlay-utils.ts
5038
4998
  function sColor(series, idx) {
5039
- return chunkDD2YRS6Z_js.seriesColor(series, idx);
4999
+ return chunkPB7KVDNV_js.seriesColor(series, idx);
5040
5000
  }
5041
5001
  function valToY(val, range, topY, bottomY) {
5042
5002
  const usable = bottomY - topY;
@@ -5575,7 +5535,7 @@ function renderLegend(id, style, series, layout, colorPalette) {
5575
5535
  width: 10,
5576
5536
  height: 10,
5577
5537
  rx: 2,
5578
- fill: chunkDD2YRS6Z_js.seriesColor(s, i, style?.styleId, colorPalette)
5538
+ fill: chunkPB7KVDNV_js.seriesColor(s, i, style?.styleId, colorPalette)
5579
5539
  },
5580
5540
  `${id}-leg-r-${i}`
5581
5541
  )
@@ -5599,7 +5559,7 @@ function renderLegend(id, style, series, layout, colorPalette) {
5599
5559
  width: 10,
5600
5560
  height: 10,
5601
5561
  rx: 2,
5602
- fill: chunkDD2YRS6Z_js.seriesColor(s, i, style?.styleId, colorPalette)
5562
+ fill: chunkPB7KVDNV_js.seriesColor(s, i, style?.styleId, colorPalette)
5603
5563
  }
5604
5564
  ),
5605
5565
  /* @__PURE__ */ jsxRuntime.jsx("text", { x: x + 14, y: cy + 8, fontSize: 9, fill: "#475569", children: s.name || `Series ${i + 1}` })
@@ -5612,9 +5572,9 @@ function renderGridlines(id, style, range, layout) {
5612
5572
  }
5613
5573
  const lines = [];
5614
5574
  if (range.logScale && range.logBase) {
5615
- const ticks = chunkDD2YRS6Z_js.generateLogTicks(range);
5575
+ const ticks = chunkPB7KVDNV_js.generateLogTicks(range);
5616
5576
  ticks.forEach((tickVal, i) => {
5617
- const y = chunkDD2YRS6Z_js.valueToY(tickVal, range, layout.plotTop, layout.plotBottom);
5577
+ const y = chunkPB7KVDNV_js.valueToY(tickVal, range, layout.plotTop, layout.plotBottom);
5618
5578
  lines.push(
5619
5579
  /* @__PURE__ */ jsxRuntime.jsx(
5620
5580
  "line",
@@ -5635,7 +5595,7 @@ function renderGridlines(id, style, range, layout) {
5635
5595
  const steps = 4;
5636
5596
  for (let i = 0; i <= steps; i++) {
5637
5597
  const val = range.min + range.span * i / steps;
5638
- const y = chunkDD2YRS6Z_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
5598
+ const y = chunkPB7KVDNV_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
5639
5599
  lines.push(
5640
5600
  /* @__PURE__ */ jsxRuntime.jsx(
5641
5601
  "line",
@@ -5659,9 +5619,9 @@ function renderValueAxis(id, range, layout, axisFormatting) {
5659
5619
  const labels = [];
5660
5620
  const hasDisplayUnits = Boolean(axisFormatting?.displayUnits);
5661
5621
  if (range.logScale && range.logBase) {
5662
- const ticks = chunkDD2YRS6Z_js.generateLogTicks(range);
5622
+ const ticks = chunkPB7KVDNV_js.generateLogTicks(range);
5663
5623
  ticks.forEach((tickVal, i) => {
5664
- const y = chunkDD2YRS6Z_js.valueToY(tickVal, range, layout.plotTop, layout.plotBottom);
5624
+ const y = chunkPB7KVDNV_js.valueToY(tickVal, range, layout.plotTop, layout.plotBottom);
5665
5625
  labels.push(
5666
5626
  /* @__PURE__ */ jsxRuntime.jsx(
5667
5627
  "text",
@@ -5671,7 +5631,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
5671
5631
  textAnchor: "end",
5672
5632
  fontSize: 8,
5673
5633
  fill: "#64748b",
5674
- children: hasDisplayUnits ? chunkDD2YRS6Z_js.formatAxisValueWithUnits(tickVal, axisFormatting) : chunkDD2YRS6Z_js.formatAxisValue(tickVal)
5634
+ children: hasDisplayUnits ? chunkPB7KVDNV_js.formatAxisValueWithUnits(tickVal, axisFormatting) : chunkPB7KVDNV_js.formatAxisValue(tickVal)
5675
5635
  },
5676
5636
  `${id}-vaxis-log-${i}`
5677
5637
  )
@@ -5681,7 +5641,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
5681
5641
  const steps = 4;
5682
5642
  for (let i = 0; i <= steps; i++) {
5683
5643
  const val = range.min + range.span * i / steps;
5684
- const y = chunkDD2YRS6Z_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
5644
+ const y = chunkPB7KVDNV_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
5685
5645
  labels.push(
5686
5646
  /* @__PURE__ */ jsxRuntime.jsx(
5687
5647
  "text",
@@ -5691,7 +5651,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
5691
5651
  textAnchor: "end",
5692
5652
  fontSize: 8,
5693
5653
  fill: "#64748b",
5694
- children: hasDisplayUnits ? chunkDD2YRS6Z_js.formatAxisValueWithUnits(val, axisFormatting) : chunkDD2YRS6Z_js.formatAxisValue(val)
5654
+ children: hasDisplayUnits ? chunkPB7KVDNV_js.formatAxisValueWithUnits(val, axisFormatting) : chunkPB7KVDNV_js.formatAxisValue(val)
5695
5655
  },
5696
5656
  `${id}-vaxis-${i}`
5697
5657
  )
@@ -5699,7 +5659,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
5699
5659
  }
5700
5660
  }
5701
5661
  if (hasDisplayUnits) {
5702
- const unitLabel = chunkDD2YRS6Z_js.getDisplayUnitLabel(
5662
+ const unitLabel = chunkPB7KVDNV_js.getDisplayUnitLabel(
5703
5663
  axisFormatting.displayUnits,
5704
5664
  axisFormatting.displayUnitsLabel
5705
5665
  );
@@ -5774,7 +5734,7 @@ function renderZeroLine(id, range, layout) {
5774
5734
  if (range.min >= 0) {
5775
5735
  return null;
5776
5736
  }
5777
- const y = chunkDD2YRS6Z_js.valueToY(0, range, layout.plotTop, layout.plotBottom);
5737
+ const y = chunkPB7KVDNV_js.valueToY(0, range, layout.plotTop, layout.plotBottom);
5778
5738
  return /* @__PURE__ */ jsxRuntime.jsx(
5779
5739
  "line",
5780
5740
  {
@@ -5798,7 +5758,7 @@ function renderSecondaryValueAxis(id, range, layout, axisFormatting) {
5798
5758
  const hasDisplayUnits = Boolean(axisFormatting?.displayUnits);
5799
5759
  for (let i = 0; i <= steps; i++) {
5800
5760
  const val = range.min + range.span * i / steps;
5801
- const y = chunkDD2YRS6Z_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
5761
+ const y = chunkPB7KVDNV_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
5802
5762
  labels.push(
5803
5763
  /* @__PURE__ */ jsxRuntime.jsx(
5804
5764
  "text",
@@ -5810,7 +5770,7 @@ function renderSecondaryValueAxis(id, range, layout, axisFormatting) {
5810
5770
  fontFamily,
5811
5771
  fontWeight,
5812
5772
  fill: fontColor,
5813
- children: hasDisplayUnits ? chunkDD2YRS6Z_js.formatAxisValueWithUnits(val, axisFormatting) : chunkDD2YRS6Z_js.formatAxisValue(val)
5773
+ children: hasDisplayUnits ? chunkPB7KVDNV_js.formatAxisValueWithUnits(val, axisFormatting) : chunkPB7KVDNV_js.formatAxisValue(val)
5814
5774
  },
5815
5775
  `${id}-sec-vaxis-${i}`
5816
5776
  )
@@ -5834,7 +5794,7 @@ function renderSecondaryValueAxis(id, range, layout, axisFormatting) {
5834
5794
  );
5835
5795
  }
5836
5796
  if (hasDisplayUnits) {
5837
- const unitLabel = chunkDD2YRS6Z_js.getDisplayUnitLabel(
5797
+ const unitLabel = chunkPB7KVDNV_js.getDisplayUnitLabel(
5838
5798
  axisFormatting.displayUnits,
5839
5799
  axisFormatting.displayUnitsLabel
5840
5800
  );
@@ -5865,7 +5825,7 @@ function renderSecondaryAxisTicks(id, range, layout) {
5865
5825
  const ticks = [];
5866
5826
  for (let i = 0; i <= steps; i++) {
5867
5827
  const val = range.min + range.span * i / steps;
5868
- const y = chunkDD2YRS6Z_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
5828
+ const y = chunkPB7KVDNV_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
5869
5829
  ticks.push(
5870
5830
  /* @__PURE__ */ jsxRuntime.jsx(
5871
5831
  "line",
@@ -5892,7 +5852,7 @@ function renderSecondaryGridlines(id, range, layout, axisFormatting) {
5892
5852
  const gridColor = axisFormatting.majorGridlinesSpPr?.strokeColor ?? "#e2e8f0";
5893
5853
  for (let i = 0; i <= steps; i++) {
5894
5854
  const val = range.min + range.span * i / steps;
5895
- const y = chunkDD2YRS6Z_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
5855
+ const y = chunkPB7KVDNV_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
5896
5856
  lines.push(
5897
5857
  /* @__PURE__ */ jsxRuntime.jsx(
5898
5858
  "line",
@@ -6010,7 +5970,7 @@ function renderChartDataTable(elementId, chartData, svgWidth) {
6010
5970
  showK && /* @__PURE__ */ jsxRuntime.jsx(
6011
5971
  "th",
6012
5972
  {
6013
- "aria-label": chunkBXAK3JFM_js.translationsEn["pptx.chart.rowLabelsAria"],
5973
+ "aria-label": chunk3ISYPBSX_js.translationsEn["pptx.chart.rowLabelsAria"],
6014
5974
  style: {
6015
5975
  padding: "1px 4px",
6016
5976
  fontWeight: 400,
@@ -6054,7 +6014,7 @@ function renderChartDataTable(elementId, chartData, svgWidth) {
6054
6014
  width: 8,
6055
6015
  height: 8,
6056
6016
  borderRadius: 2,
6057
- backgroundColor: chunkDD2YRS6Z_js.seriesColor(
6017
+ backgroundColor: chunkPB7KVDNV_js.seriesColor(
6058
6018
  s,
6059
6019
  si,
6060
6020
  chartData.style?.styleId,
@@ -6092,10 +6052,10 @@ function renderChartDataTable(elementId, chartData, svgWidth) {
6092
6052
  }
6093
6053
  function renderStockChart(element, chartData, categoryLabels) {
6094
6054
  const style = chartData.style;
6095
- const areaFill = chunkDD2YRS6Z_js.chartAreaFill(chartData);
6055
+ const areaFill = chunkPB7KVDNV_js.chartAreaFill(chartData);
6096
6056
  const legendPos = style?.legendPosition || "b";
6097
- const range = chunkDD2YRS6Z_js.computeValueRangeForChart(chartData.series, chartData.axes);
6098
- const layout = chunkDD2YRS6Z_js.computeLayout(element.width, element.height, style, true, legendPos);
6057
+ const range = chunkPB7KVDNV_js.computeValueRangeForChart(chartData.series, chartData.axes);
6058
+ const layout = chunkPB7KVDNV_js.computeLayout(element.width, element.height, style, true, legendPos);
6099
6059
  const catCount = Math.max(categoryLabels.length, 1);
6100
6060
  const barGroupWidth = layout.plotWidth / catCount;
6101
6061
  const candleWidth = barGroupWidth * 0.5;
@@ -6116,10 +6076,10 @@ function renderStockChart(element, chartData, categoryLabels) {
6116
6076
  const close = closeSeries.values[ci] ?? high;
6117
6077
  const isUp = close >= open;
6118
6078
  const cx = layout.plotLeft + barGroupWidth * ci + barGroupWidth / 2;
6119
- const highY = chunkDD2YRS6Z_js.valueToY(high, range, layout.plotTop, layout.plotBottom);
6120
- const lowY = chunkDD2YRS6Z_js.valueToY(low, range, layout.plotTop, layout.plotBottom);
6121
- const openY = chunkDD2YRS6Z_js.valueToY(open, range, layout.plotTop, layout.plotBottom);
6122
- const closeY = chunkDD2YRS6Z_js.valueToY(close, range, layout.plotTop, layout.plotBottom);
6079
+ const highY = chunkPB7KVDNV_js.valueToY(high, range, layout.plotTop, layout.plotBottom);
6080
+ const lowY = chunkPB7KVDNV_js.valueToY(low, range, layout.plotTop, layout.plotBottom);
6081
+ const openY = chunkPB7KVDNV_js.valueToY(open, range, layout.plotTop, layout.plotBottom);
6082
+ const closeY = chunkPB7KVDNV_js.valueToY(close, range, layout.plotTop, layout.plotBottom);
6123
6083
  elements.push(
6124
6084
  /* @__PURE__ */ jsxRuntime.jsx(
6125
6085
  "line",
@@ -6162,7 +6122,7 @@ function renderStockChart(element, chartData, categoryLabels) {
6162
6122
  textAnchor: "middle",
6163
6123
  fontSize: 7,
6164
6124
  fill: "#334155",
6165
- children: chunkDD2YRS6Z_js.formatAxisValue(close)
6125
+ children: chunkPB7KVDNV_js.formatAxisValue(close)
6166
6126
  },
6167
6127
  `${element.id}-stock-dl-${ci}`
6168
6128
  )
@@ -6204,7 +6164,7 @@ function FailedToLoad() {
6204
6164
  var LazySurfaceChart3DScene = React6__default.default.lazy(
6205
6165
  async () => {
6206
6166
  try {
6207
- return await import('./SurfaceChart3DScene-JDCFTXYT.js');
6167
+ return await import('./SurfaceChart3DScene-IDJDIHVC.js');
6208
6168
  } catch {
6209
6169
  return { default: FailedToLoad };
6210
6170
  }
@@ -6228,7 +6188,7 @@ var SurfaceChart3DErrorBoundary = class extends React6__default.default.Componen
6228
6188
  function buildSurfaceData(chartData, categoryLabels) {
6229
6189
  const rows = chartData.series.length;
6230
6190
  const cols = Math.max(categoryLabels.length, 1);
6231
- const range = chunkDD2YRS6Z_js.computeValueRangeForChart(chartData.series, chartData.axes);
6191
+ const range = chunkPB7KVDNV_js.computeValueRangeForChart(chartData.series, chartData.axes);
6232
6192
  const heightMap = new Float32Array(rows * cols);
6233
6193
  const colorMap = new Float32Array(rows * cols * 3);
6234
6194
  for (let r = 0; r < rows; r++) {
@@ -6347,10 +6307,10 @@ function darkenRgb(r, g, b, factor) {
6347
6307
  }
6348
6308
  function renderIsometricSurfaceChart(element, chartData, categoryLabels) {
6349
6309
  const style = chartData.style;
6350
- const areaFill = chunkDD2YRS6Z_js.chartAreaFill(chartData);
6310
+ const areaFill = chunkPB7KVDNV_js.chartAreaFill(chartData);
6351
6311
  const legendPos = style?.legendPosition || "b";
6352
- const layout = chunkDD2YRS6Z_js.computeLayout(element.width, element.height, style, false, legendPos);
6353
- const range = chunkDD2YRS6Z_js.computeValueRangeForChart(chartData.series, chartData.axes);
6312
+ const layout = chunkPB7KVDNV_js.computeLayout(element.width, element.height, style, false, legendPos);
6313
+ const range = chunkPB7KVDNV_js.computeValueRangeForChart(chartData.series, chartData.axes);
6354
6314
  const catCount = Math.max(categoryLabels.length, 1);
6355
6315
  const seriesCount = chartData.series.length;
6356
6316
  const cols = catCount - 1;
@@ -6439,10 +6399,10 @@ function renderIsometricSurfaceChart(element, chartData, categoryLabels) {
6439
6399
  }
6440
6400
  function renderFlatSurfaceChart(element, chartData, categoryLabels) {
6441
6401
  const style = chartData.style;
6442
- const areaFill = chunkDD2YRS6Z_js.chartAreaFill(chartData);
6402
+ const areaFill = chunkPB7KVDNV_js.chartAreaFill(chartData);
6443
6403
  const legendPos = style?.legendPosition || "b";
6444
- const layout = chunkDD2YRS6Z_js.computeLayout(element.width, element.height, style, true, legendPos);
6445
- const range = chunkDD2YRS6Z_js.computeValueRangeForChart(chartData.series, chartData.axes);
6404
+ const layout = chunkPB7KVDNV_js.computeLayout(element.width, element.height, style, true, legendPos);
6405
+ const range = chunkPB7KVDNV_js.computeValueRangeForChart(chartData.series, chartData.axes);
6446
6406
  const catCount = Math.max(categoryLabels.length, 1);
6447
6407
  const seriesCount = chartData.series.length;
6448
6408
  const cellW = layout.plotWidth / Math.max(catCount - 1, 1);
@@ -6504,9 +6464,9 @@ function renderSurfaceChart(element, chartData, categoryLabels) {
6504
6464
  }
6505
6465
  function renderTreemapChart(element, chartData, categoryLabels) {
6506
6466
  const style = chartData.style;
6507
- const areaFill = chunkDD2YRS6Z_js.chartAreaFill(chartData);
6467
+ const areaFill = chunkPB7KVDNV_js.chartAreaFill(chartData);
6508
6468
  const legendPos = style?.legendPosition || "b";
6509
- const layout = chunkDD2YRS6Z_js.computeLayout(element.width, element.height, style, false, legendPos);
6469
+ const layout = chunkPB7KVDNV_js.computeLayout(element.width, element.height, style, false, legendPos);
6510
6470
  const allValues = chartData.series.flatMap((s) => s.values);
6511
6471
  const totalAbs = allValues.reduce((sum, v) => sum + Math.abs(v), 0) || 1;
6512
6472
  const rects = [];
@@ -6529,7 +6489,7 @@ function renderTreemapChart(element, chartData, categoryLabels) {
6529
6489
  y: curY,
6530
6490
  width: Math.max(w - 1, 1),
6531
6491
  height: Math.max(h - 1, 1),
6532
- fill: chunkDD2YRS6Z_js.paletteColor(item.index, chartData.style?.styleId, chartData.colorPalette),
6492
+ fill: chunkPB7KVDNV_js.paletteColor(item.index, chartData.style?.styleId, chartData.colorPalette),
6533
6493
  rx: 2,
6534
6494
  opacity: 0.85
6535
6495
  },
@@ -6580,11 +6540,11 @@ function renderTreemapChart(element, chartData, categoryLabels) {
6580
6540
  }
6581
6541
  function renderWaterfallChart(element, chartData, categoryLabels) {
6582
6542
  const style = chartData.style;
6583
- const areaFill = chunkDD2YRS6Z_js.chartAreaFill(chartData);
6543
+ const areaFill = chunkPB7KVDNV_js.chartAreaFill(chartData);
6584
6544
  const legendPos = style?.legendPosition || "b";
6585
6545
  const values = chartData.series[0]?.values ?? [];
6586
- const range = chunkDD2YRS6Z_js.computeValueRangeForChart(chartData.series, chartData.axes);
6587
- const layout = chunkDD2YRS6Z_js.computeLayout(element.width, element.height, style, true, legendPos);
6546
+ const range = chunkPB7KVDNV_js.computeValueRangeForChart(chartData.series, chartData.axes);
6547
+ const layout = chunkPB7KVDNV_js.computeLayout(element.width, element.height, style, true, legendPos);
6588
6548
  const catCount = Math.max(categoryLabels.length, values.length, 1);
6589
6549
  const barWidth = layout.plotWidth / catCount * 0.6;
6590
6550
  const gap = layout.plotWidth / catCount * 0.2;
@@ -6595,8 +6555,8 @@ function renderWaterfallChart(element, chartData, categoryLabels) {
6595
6555
  const isLast = i === values.length - 1;
6596
6556
  const startVal = isLast ? 0 : runningTotal;
6597
6557
  const endVal = isLast ? runningTotal + val : runningTotal + val;
6598
- const barStartY = chunkDD2YRS6Z_js.valueToY(startVal, range, layout.plotTop, layout.plotBottom);
6599
- const barEndY = chunkDD2YRS6Z_js.valueToY(endVal, range, layout.plotTop, layout.plotBottom);
6558
+ const barStartY = chunkPB7KVDNV_js.valueToY(startVal, range, layout.plotTop, layout.plotBottom);
6559
+ const barEndY = chunkPB7KVDNV_js.valueToY(endVal, range, layout.plotTop, layout.plotBottom);
6600
6560
  const x = layout.plotLeft + layout.plotWidth / catCount * i + gap;
6601
6561
  const y = Math.min(barStartY, barEndY);
6602
6562
  const h = Math.max(Math.abs(barEndY - barStartY), 1);
@@ -6625,7 +6585,7 @@ function renderWaterfallChart(element, chartData, categoryLabels) {
6625
6585
  textAnchor: "middle",
6626
6586
  fontSize: 7,
6627
6587
  fill: "#334155",
6628
- children: chunkDD2YRS6Z_js.formatAxisValue(isLast ? endVal : val)
6588
+ children: chunkPB7KVDNV_js.formatAxisValue(isLast ? endVal : val)
6629
6589
  },
6630
6590
  `${element.id}-wf-dl-${i}`
6631
6591
  )
@@ -6672,20 +6632,20 @@ function renderWaterfallChart(element, chartData, categoryLabels) {
6672
6632
  }
6673
6633
  function renderComboChart(element, chartData, categoryLabels) {
6674
6634
  const style = chartData.style;
6675
- const areaFill = chunkDD2YRS6Z_js.chartAreaFill(chartData);
6635
+ const areaFill = chunkPB7KVDNV_js.chartAreaFill(chartData);
6676
6636
  const legendPos = style?.legendPosition || "b";
6677
- const layoutOpts = chunkDD2YRS6Z_js.computeLayoutOptions(
6637
+ const layoutOpts = chunkPB7KVDNV_js.computeLayoutOptions(
6678
6638
  chartData.axes,
6679
6639
  chartData.dataTable,
6680
6640
  chartData.series.length
6681
6641
  );
6682
- const layout = chunkDD2YRS6Z_js.computeLayout(element.width, element.height, style, true, legendPos, layoutOpts);
6683
- const { primary, secondary } = chunkDD2YRS6Z_js.splitSeriesByAxis(chartData.series, chartData.axes);
6642
+ const layout = chunkPB7KVDNV_js.computeLayout(element.width, element.height, style, true, legendPos, layoutOpts);
6643
+ const { primary, secondary } = chunkPB7KVDNV_js.splitSeriesByAxis(chartData.series, chartData.axes);
6684
6644
  const primarySeries = primary.length > 0 ? primary.map((e) => e.series) : chartData.series;
6685
6645
  const secondarySeries = secondary.map((e) => e.series);
6686
- const range = chunkDD2YRS6Z_js.computeValueRangeForChart(primarySeries, chartData.axes);
6687
- const secondaryRange = secondarySeries.length > 0 ? chunkDD2YRS6Z_js.computeValueRange(secondarySeries) : void 0;
6688
- const secondaryAxisFmt = chunkDD2YRS6Z_js.getSecondaryValueAxis(chartData.axes);
6646
+ const range = chunkPB7KVDNV_js.computeValueRangeForChart(primarySeries, chartData.axes);
6647
+ const secondaryRange = secondarySeries.length > 0 ? chunkPB7KVDNV_js.computeValueRange(secondarySeries) : void 0;
6648
+ const secondaryAxisFmt = chunkPB7KVDNV_js.getSecondaryValueAxis(chartData.axes);
6689
6649
  const catCount = Math.max(categoryLabels.length, 1);
6690
6650
  const barSeriesCount = 1;
6691
6651
  const barGroupWidth = layout.plotWidth / catCount;
@@ -6701,8 +6661,8 @@ function renderComboChart(element, chartData, categoryLabels) {
6701
6661
  const barRange = isBarSecondary && secondaryRange ? secondaryRange : range;
6702
6662
  barSeries.values.forEach((val, vi) => {
6703
6663
  const x = layout.plotLeft + barGroupWidth * vi + barOffset;
6704
- const zeroY = chunkDD2YRS6Z_js.valueToY(0, barRange, layout.plotTop, layout.plotBottom);
6705
- const valY = chunkDD2YRS6Z_js.valueToY(val, barRange, layout.plotTop, layout.plotBottom);
6664
+ const zeroY = chunkPB7KVDNV_js.valueToY(0, barRange, layout.plotTop, layout.plotBottom);
6665
+ const valY = chunkPB7KVDNV_js.valueToY(val, barRange, layout.plotTop, layout.plotBottom);
6706
6666
  const y = Math.min(zeroY, valY);
6707
6667
  const h = Math.max(Math.abs(zeroY - valY), 1);
6708
6668
  barElements.push(
@@ -6713,7 +6673,7 @@ function renderComboChart(element, chartData, categoryLabels) {
6713
6673
  y,
6714
6674
  width: barWidth,
6715
6675
  height: h,
6716
- fill: chunkDD2YRS6Z_js.seriesColor(barSeries, 0, chartData.style?.styleId, chartData.colorPalette),
6676
+ fill: chunkPB7KVDNV_js.seriesColor(barSeries, 0, chartData.style?.styleId, chartData.colorPalette),
6717
6677
  rx: 1
6718
6678
  },
6719
6679
  `${element.id}-combo-bar-${vi}`
@@ -6729,7 +6689,7 @@ function renderComboChart(element, chartData, categoryLabels) {
6729
6689
  textAnchor: "middle",
6730
6690
  fontSize: 7,
6731
6691
  fill: "#334155",
6732
- children: chunkDD2YRS6Z_js.formatAxisValue(val)
6692
+ children: chunkPB7KVDNV_js.formatAxisValue(val)
6733
6693
  },
6734
6694
  `${element.id}-combo-bar-dl-${vi}`
6735
6695
  )
@@ -6746,10 +6706,10 @@ function renderComboChart(element, chartData, categoryLabels) {
6746
6706
  const activeRange = isSecondary && secondaryRange ? secondaryRange : range;
6747
6707
  const points = series.values.map((val, vi) => {
6748
6708
  const x = layout.plotLeft + barGroupWidth * vi + barGroupWidth / 2;
6749
- const y = chunkDD2YRS6Z_js.valueToY(val, activeRange, layout.plotTop, layout.plotBottom);
6709
+ const y = chunkPB7KVDNV_js.valueToY(val, activeRange, layout.plotTop, layout.plotBottom);
6750
6710
  return { x, y, val };
6751
6711
  });
6752
- const c = chunkDD2YRS6Z_js.seriesColor(series, seriesIdx, chartData.style?.styleId, chartData.colorPalette);
6712
+ const c = chunkPB7KVDNV_js.seriesColor(series, seriesIdx, chartData.style?.styleId, chartData.colorPalette);
6753
6713
  lineElements.push(
6754
6714
  /* @__PURE__ */ jsxRuntime.jsx(
6755
6715
  "polyline",
@@ -6776,7 +6736,7 @@ function renderComboChart(element, chartData, categoryLabels) {
6776
6736
  textAnchor: "middle",
6777
6737
  fontSize: 7,
6778
6738
  fill: "#334155",
6779
- children: chunkDD2YRS6Z_js.formatAxisValue(p.val)
6739
+ children: chunkPB7KVDNV_js.formatAxisValue(p.val)
6780
6740
  },
6781
6741
  `${element.id}-combo-line-dl-${si}-${vi}`
6782
6742
  )
@@ -6814,11 +6774,11 @@ function renderComboChart(element, chartData, categoryLabels) {
6814
6774
  }
6815
6775
  function renderChartElement(element) {
6816
6776
  if (element.type !== "chart") {
6817
- return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunkBXAK3JFM_js.translationsEn["pptx.chart.heading"] });
6777
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunk3ISYPBSX_js.translationsEn["pptx.chart.heading"] });
6818
6778
  }
6819
6779
  const chartData = element.chartData;
6820
6780
  if (!chartData || chartData.series.length === 0) {
6821
- return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunkBXAK3JFM_js.translationsEn["pptx.chart.heading"] });
6781
+ return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunk3ISYPBSX_js.translationsEn["pptx.chart.heading"] });
6822
6782
  }
6823
6783
  const longestSeriesLength = chartData.series.reduce(
6824
6784
  (maxLength, series) => Math.max(maxLength, series.values.length),
@@ -7922,14 +7882,14 @@ function buildNotesPdf(pages) {
7922
7882
  notes: page.notes,
7923
7883
  slideNumber: page.slideNumber
7924
7884
  }));
7925
- const bytes = chunkDD2YRS6Z_js.buildNotesPdfBytes(images, meta);
7885
+ const bytes = chunkPB7KVDNV_js.buildNotesPdfBytes(images, meta);
7926
7886
  const blob = new Blob([bytes], { type: "application/pdf" });
7927
7887
  return URL.createObjectURL(blob);
7928
7888
  }
7929
7889
 
7930
7890
  // src/viewer/utils/pdf-builder-slides.ts
7931
7891
  function buildPdfFromImageData(images) {
7932
- const bytes = chunkDD2YRS6Z_js.buildSlidesPdfBytes(images);
7892
+ const bytes = chunkPB7KVDNV_js.buildSlidesPdfBytes(images);
7933
7893
  const blob = new Blob([bytes], { type: "application/pdf" });
7934
7894
  return URL.createObjectURL(blob);
7935
7895
  }
@@ -7938,7 +7898,7 @@ function buildPdfFromImageData(images) {
7938
7898
  var activePreview = null;
7939
7899
  function startPreviewAnimation(elementId, preset, options) {
7940
7900
  stopPreviewAnimation();
7941
- const descriptor = chunkDD2YRS6Z_js.buildPreviewAnimation(preset, options);
7901
+ const descriptor = chunkPB7KVDNV_js.buildPreviewAnimation(preset, options);
7942
7902
  if (!descriptor) {
7943
7903
  return;
7944
7904
  }
@@ -7951,7 +7911,7 @@ function startMotionPathPreview(elementId, path, options) {
7951
7911
  return;
7952
7912
  }
7953
7913
  const stage = domEl.offsetParent;
7954
- const descriptor = chunkDD2YRS6Z_js.buildMotionPathPreview({
7914
+ const descriptor = chunkPB7KVDNV_js.buildMotionPathPreview({
7955
7915
  path,
7956
7916
  slideWidth: stage?.offsetWidth || DEFAULT_PREVIEW_SLIDE_WIDTH,
7957
7917
  slideHeight: stage?.offsetHeight || DEFAULT_PREVIEW_SLIDE_HEIGHT,
@@ -8016,7 +7976,7 @@ exports.CONNECTOR_ARROW_OPTIONS = CONNECTOR_ARROW_OPTIONS;
8016
7976
  exports.DEFAULT_CANVAS_HEIGHT = DEFAULT_CANVAS_HEIGHT;
8017
7977
  exports.DEFAULT_CANVAS_WIDTH = DEFAULT_CANVAS_WIDTH;
8018
7978
  exports.DEFAULT_FILL_COLOR = DEFAULT_FILL_COLOR;
8019
- exports.DEFAULT_FONT_FAMILY = DEFAULT_FONT_FAMILY;
7979
+ exports.DEFAULT_FONT_FAMILY = DEFAULT_FONT_FAMILY2;
8020
7980
  exports.DEFAULT_STROKE_COLOR = DEFAULT_STROKE_COLOR;
8021
7981
  exports.DEFAULT_TABLE_COLUMNS = DEFAULT_TABLE_COLUMNS;
8022
7982
  exports.DEFAULT_TABLE_ROWS = DEFAULT_TABLE_ROWS;