pptx-react-viewer 2.16.7 → 2.16.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (94) hide show
  1. package/CHANGELOG.md +2 -0
  2. package/dist/{AiChatPanel-2YYL6AKX.mjs → AiChatPanel-FR55MUQF.mjs} +3 -3
  3. package/dist/AiChatPanel-FR55MUQF.mjs.br +0 -0
  4. package/dist/AiChatPanel-FR55MUQF.mjs.gz +0 -0
  5. package/dist/{AiChatPanel-XSXMU2Q5.js → AiChatPanel-VNHHHM2S.js} +23 -23
  6. package/dist/AiChatPanel-VNHHHM2S.js.br +0 -0
  7. package/dist/AiChatPanel-VNHHHM2S.js.gz +0 -0
  8. package/dist/{Model3DScene-36UJZLCO.js → Model3DScene-KVYGN53Y.js} +2 -2
  9. package/dist/Model3DScene-KVYGN53Y.js.br +0 -0
  10. package/dist/Model3DScene-KVYGN53Y.js.gz +0 -0
  11. package/dist/{Model3DScene-NVFP3JBJ.mjs → Model3DScene-LYWXBJMA.mjs} +1 -1
  12. package/dist/Model3DScene-LYWXBJMA.mjs.br +0 -0
  13. package/dist/Model3DScene-LYWXBJMA.mjs.gz +0 -0
  14. package/dist/{SurfaceChart3DScene-W6I255VU.js → SurfaceChart3DScene-E2PSO2FF.js} +2 -2
  15. package/dist/SurfaceChart3DScene-E2PSO2FF.js.br +0 -0
  16. package/dist/SurfaceChart3DScene-E2PSO2FF.js.gz +0 -0
  17. package/dist/{SurfaceChart3DScene-BMFEDBLF.mjs → SurfaceChart3DScene-Z4IIOBDM.mjs} +1 -1
  18. package/dist/{SurfaceChart3DScene-BMFEDBLF.mjs.br → SurfaceChart3DScene-Z4IIOBDM.mjs.br} +0 -0
  19. package/dist/SurfaceChart3DScene-Z4IIOBDM.mjs.gz +0 -0
  20. package/dist/{chunk-QNKJUUKD.mjs → chunk-4OWZJUAI.mjs} +1 -1
  21. package/dist/chunk-4OWZJUAI.mjs.br +0 -0
  22. package/dist/chunk-4OWZJUAI.mjs.gz +0 -0
  23. package/dist/{chunk-J5V7UCD2.mjs → chunk-ACCX43JJ.mjs} +2 -2
  24. package/dist/chunk-ACCX43JJ.mjs.br +0 -0
  25. package/dist/chunk-ACCX43JJ.mjs.gz +0 -0
  26. package/dist/{chunk-J56KVWI5.mjs → chunk-EPYWIXP7.mjs} +7 -7
  27. package/dist/chunk-EPYWIXP7.mjs.br +0 -0
  28. package/dist/chunk-EPYWIXP7.mjs.gz +0 -0
  29. package/dist/{chunk-S7HPAJRX.js → chunk-LYOEX3FB.js} +340 -340
  30. package/dist/chunk-LYOEX3FB.js.br +0 -0
  31. package/dist/chunk-LYOEX3FB.js.gz +0 -0
  32. package/dist/{chunk-KVNZGR3L.mjs → chunk-NAMV6PRF.mjs} +2 -2
  33. package/dist/chunk-NAMV6PRF.mjs.br +0 -0
  34. package/dist/chunk-NAMV6PRF.mjs.gz +0 -0
  35. package/dist/{chunk-NFJLF7TX.js → chunk-QBRZ3VIC.js} +247 -247
  36. package/dist/chunk-QBRZ3VIC.js.br +0 -0
  37. package/dist/chunk-QBRZ3VIC.js.gz +0 -0
  38. package/dist/{chunk-77TMRPDU.js → chunk-SGJP2EUI.js} +977 -977
  39. package/dist/chunk-SGJP2EUI.js.br +0 -0
  40. package/dist/chunk-SGJP2EUI.js.gz +0 -0
  41. package/dist/{chunk-JSJZWA43.js → chunk-YT25W6IR.js} +3 -3
  42. package/dist/chunk-YT25W6IR.js.br +0 -0
  43. package/dist/{chunk-JSJZWA43.js.gz → chunk-YT25W6IR.js.gz} +0 -0
  44. package/dist/index.js +39 -39
  45. package/dist/index.js.br +0 -0
  46. package/dist/index.js.gz +0 -0
  47. package/dist/index.mjs +5 -5
  48. package/dist/index.mjs.br +0 -0
  49. package/dist/index.mjs.gz +0 -0
  50. package/dist/internals.js +78 -78
  51. package/dist/internals.js.br +4 -5
  52. package/dist/internals.js.gz +0 -0
  53. package/dist/internals.mjs +3 -3
  54. package/dist/internals.mjs.br +0 -0
  55. package/dist/internals.mjs.gz +0 -0
  56. package/dist/viewer/index.js +26 -26
  57. package/dist/viewer/index.js.br +0 -0
  58. package/dist/viewer/index.js.gz +0 -0
  59. package/dist/viewer/index.mjs +5 -5
  60. package/dist/viewer/index.mjs.br +0 -0
  61. package/dist/viewer/index.mjs.gz +0 -0
  62. package/package.json +1 -1
  63. package/dist/AiChatPanel-2YYL6AKX.mjs.br +0 -0
  64. package/dist/AiChatPanel-2YYL6AKX.mjs.gz +0 -0
  65. package/dist/AiChatPanel-XSXMU2Q5.js.br +0 -0
  66. package/dist/AiChatPanel-XSXMU2Q5.js.gz +0 -0
  67. package/dist/Model3DScene-36UJZLCO.js.br +0 -0
  68. package/dist/Model3DScene-36UJZLCO.js.gz +0 -0
  69. package/dist/Model3DScene-NVFP3JBJ.mjs.br +0 -0
  70. package/dist/Model3DScene-NVFP3JBJ.mjs.gz +0 -0
  71. package/dist/SurfaceChart3DScene-BMFEDBLF.mjs.gz +0 -0
  72. package/dist/SurfaceChart3DScene-W6I255VU.js.br +0 -0
  73. package/dist/SurfaceChart3DScene-W6I255VU.js.gz +0 -0
  74. package/dist/chunk-77TMRPDU.js.br +0 -0
  75. package/dist/chunk-77TMRPDU.js.gz +0 -0
  76. package/dist/chunk-J56KVWI5.mjs.br +0 -0
  77. package/dist/chunk-J56KVWI5.mjs.gz +0 -0
  78. package/dist/chunk-J5V7UCD2.mjs.br +0 -0
  79. package/dist/chunk-J5V7UCD2.mjs.gz +0 -0
  80. package/dist/chunk-JSJZWA43.js.br +0 -0
  81. package/dist/chunk-KVNZGR3L.mjs.br +0 -0
  82. package/dist/chunk-KVNZGR3L.mjs.gz +0 -0
  83. package/dist/chunk-NFJLF7TX.js.br +0 -0
  84. package/dist/chunk-NFJLF7TX.js.gz +0 -0
  85. package/dist/chunk-QNKJUUKD.mjs.br +0 -0
  86. package/dist/chunk-QNKJUUKD.mjs.gz +0 -0
  87. package/dist/chunk-S7HPAJRX.js.br +0 -0
  88. package/dist/chunk-S7HPAJRX.js.gz +0 -0
  89. /package/dist/{chunk-USAJMMF2.js → chunk-SADF35N7.js} +0 -0
  90. /package/dist/{chunk-USAJMMF2.js.br → chunk-SADF35N7.js.br} +0 -0
  91. /package/dist/{chunk-USAJMMF2.js.gz → chunk-SADF35N7.js.gz} +0 -0
  92. /package/dist/{chunk-D5TAZ5NL.mjs → chunk-SKQCLCBF.mjs} +0 -0
  93. /package/dist/{chunk-D5TAZ5NL.mjs.br → chunk-SKQCLCBF.mjs.br} +0 -0
  94. /package/dist/{chunk-D5TAZ5NL.mjs.gz → chunk-SKQCLCBF.mjs.gz} +0 -0
@@ -1,8 +1,8 @@
1
1
  'use strict';
2
2
 
3
- var chunkNFJLF7TX_js = require('./chunk-NFJLF7TX.js');
3
+ var chunkQBRZ3VIC_js = require('./chunk-QBRZ3VIC.js');
4
4
  var chunkDVZF4ARG_js = require('./chunk-DVZF4ARG.js');
5
- var chunkUSAJMMF2_js = require('./chunk-USAJMMF2.js');
5
+ var chunkSADF35N7_js = require('./chunk-SADF35N7.js');
6
6
  var react = require('react');
7
7
  var JSZip = require('jszip');
8
8
  var reactI18next = require('react-i18next');
@@ -14,7 +14,7 @@ var JSZip__default = /*#__PURE__*/_interopDefault(JSZip);
14
14
  function useVirtualizedSlides({
15
15
  totalItems,
16
16
  itemHeight,
17
- overscan = chunkUSAJMMF2_js.DEFAULT_VIRTUAL_OVERSCAN
17
+ overscan = chunkSADF35N7_js.DEFAULT_VIRTUAL_OVERSCAN
18
18
  }) {
19
19
  const scrollContainerRef = react.useRef(null);
20
20
  const [scrollTop, setScrollTop] = react.useState(0);
@@ -44,7 +44,7 @@ function useVirtualizedSlides({
44
44
  resizeObserver?.disconnect();
45
45
  };
46
46
  }, []);
47
- const range = chunkUSAJMMF2_js.computeVirtualRange(totalItems, itemHeight, scrollTop, viewportHeight, overscan);
47
+ const range = chunkSADF35N7_js.computeVirtualRange(totalItems, itemHeight, scrollTop, viewportHeight, overscan);
48
48
  const safeItemHeight = Math.max(itemHeight, 1);
49
49
  const scrollToIndex = react.useCallback(
50
50
  (index, behavior = "smooth") => {
@@ -85,7 +85,7 @@ function usePresenceTracking({
85
85
  }) {
86
86
  const [remoteUsers, setRemoteUsers] = react.useState([]);
87
87
  const projectorRef = react.useRef(null);
88
- projectorRef.current ??= chunkUSAJMMF2_js.createPresenceProjector();
88
+ projectorRef.current ??= chunkSADF35N7_js.createPresenceProjector();
89
89
  const projector = projectorRef.current;
90
90
  const lastBroadcastRef = react.useRef(0);
91
91
  const pendingBroadcastRef = react.useRef(null);
@@ -110,7 +110,7 @@ function usePresenceTracking({
110
110
  awareness.setLocalStateField("presence", state);
111
111
  lastBroadcastRef.current = Date.now();
112
112
  };
113
- if (elapsed >= chunkUSAJMMF2_js.BROADCAST_THROTTLE_MS) {
113
+ if (elapsed >= chunkSADF35N7_js.BROADCAST_THROTTLE_MS) {
114
114
  if (pendingBroadcastRef.current) {
115
115
  clearTimeout(pendingBroadcastRef.current);
116
116
  pendingBroadcastRef.current = null;
@@ -120,7 +120,7 @@ function usePresenceTracking({
120
120
  pendingBroadcastRef.current = setTimeout(() => {
121
121
  pendingBroadcastRef.current = null;
122
122
  flush();
123
- }, chunkUSAJMMF2_js.BROADCAST_THROTTLE_MS - elapsed);
123
+ }, chunkSADF35N7_js.BROADCAST_THROTTLE_MS - elapsed);
124
124
  }
125
125
  },
126
126
  [awareness, userName, userColor, userAvatar, role]
@@ -200,7 +200,7 @@ function useYjsProvider({ config }) {
200
200
  const departureRef = react.useRef(null);
201
201
  const gateRef = react.useRef(null);
202
202
  if (!gateRef.current) {
203
- gateRef.current = chunkUSAJMMF2_js.createSyncGate(() => setSynced(true));
203
+ gateRef.current = chunkSADF35N7_js.createSyncGate(() => setSynced(true));
204
204
  }
205
205
  const teardown = react.useCallback(() => {
206
206
  if (timeoutRef.current) {
@@ -220,7 +220,7 @@ function useYjsProvider({ config }) {
220
220
  const buildCleanup = react.useCallback(
221
221
  (provider, yDoc) => () => {
222
222
  announceDeparture();
223
- chunkUSAJMMF2_js.clearLocalAwareness(provider.awareness);
223
+ chunkSADF35N7_js.clearLocalAwareness(provider.awareness);
224
224
  provider.destroy();
225
225
  yDoc.destroy();
226
226
  setDoc(null);
@@ -245,9 +245,9 @@ function useYjsProvider({ config }) {
245
245
  if (config.authToken) {
246
246
  opts.password = config.authToken;
247
247
  }
248
- const roomId = chunkUSAJMMF2_js.validateRoomId(config.roomId);
248
+ const roomId = chunkSADF35N7_js.validateRoomId(config.roomId);
249
249
  const provider = new WebrtcProvider(roomId, yDoc, opts);
250
- departureRef.current = chunkUSAJMMF2_js.createDepartureChannel(roomId, provider.awareness);
250
+ departureRef.current = chunkSADF35N7_js.createDepartureChannel(roomId, provider.awareness);
251
251
  setDoc(yDoc);
252
252
  setAwareness(provider.awareness);
253
253
  setClientId(provider.awareness.clientID);
@@ -289,13 +289,13 @@ function useYjsProvider({ config }) {
289
289
  if (!config) {
290
290
  return;
291
291
  }
292
- const roomId = chunkUSAJMMF2_js.validateRoomId(config.roomId);
293
- const transport = config.transport ?? chunkUSAJMMF2_js.resolveTransportForServerUrl(config.serverUrl);
292
+ const roomId = chunkSADF35N7_js.validateRoomId(config.roomId);
293
+ const transport = config.transport ?? chunkSADF35N7_js.resolveTransportForServerUrl(config.serverUrl);
294
294
  if (transport === "webrtc") {
295
295
  await initWebrtc();
296
296
  return;
297
297
  }
298
- if (chunkUSAJMMF2_js.isMixedContentBlocked(config.serverUrl)) {
298
+ if (chunkSADF35N7_js.isMixedContentBlocked(config.serverUrl)) {
299
299
  console.warn(
300
300
  `[pptx-viewer] Refusing to connect: insecure ws:// server "${config.serverUrl}" is blocked from a secure (https) page. Use a wss:// URL.`
301
301
  );
@@ -309,7 +309,7 @@ function useYjsProvider({ config }) {
309
309
  const provider = new WebsocketProvider(config.serverUrl, roomId, yDoc, {
310
310
  params: config.authToken ? { token: config.authToken } : void 0
311
311
  });
312
- departureRef.current = chunkUSAJMMF2_js.createDepartureChannel(roomId, provider.awareness);
312
+ departureRef.current = chunkSADF35N7_js.createDepartureChannel(roomId, provider.awareness);
313
313
  let connected = false;
314
314
  const handleStatus = (event) => {
315
315
  if (event.status === "connected") {
@@ -349,7 +349,7 @@ function useYjsProvider({ config }) {
349
349
  provider.off("status", handleStatus);
350
350
  provider.off("sync", handleSynced);
351
351
  announceDeparture();
352
- chunkUSAJMMF2_js.clearLocalAwareness(provider.awareness);
352
+ chunkSADF35N7_js.clearLocalAwareness(provider.awareness);
353
353
  provider.destroy();
354
354
  yDoc.destroy();
355
355
  setDoc(null);
@@ -358,7 +358,7 @@ function useYjsProvider({ config }) {
358
358
  cleanupRef.current = null;
359
359
  setStatus("error");
360
360
  }
361
- }, chunkUSAJMMF2_js.CONNECTION_TIMEOUT_MS);
361
+ }, chunkSADF35N7_js.CONNECTION_TIMEOUT_MS);
362
362
  }
363
363
  setDoc(yDoc);
364
364
  setAwareness(provider.awareness);
@@ -367,7 +367,7 @@ function useYjsProvider({ config }) {
367
367
  provider.off("status", handleStatus);
368
368
  provider.off("sync", handleSynced);
369
369
  announceDeparture();
370
- chunkUSAJMMF2_js.clearLocalAwareness(provider.awareness);
370
+ chunkSADF35N7_js.clearLocalAwareness(provider.awareness);
371
371
  provider.destroy();
372
372
  yDoc.destroy();
373
373
  setDoc(null);
@@ -393,7 +393,7 @@ function useYjsProvider({ config }) {
393
393
  ]);
394
394
  react.useEffect(() => {
395
395
  init();
396
- const disposeTeardown = chunkUSAJMMF2_js.registerCollaborationTeardown({
396
+ const disposeTeardown = chunkSADF35N7_js.registerCollaborationTeardown({
397
397
  leave: teardown,
398
398
  rejoin: init
399
399
  });
@@ -414,7 +414,7 @@ function useCollaborativeState({
414
414
  canvasWidth,
415
415
  canvasHeight
416
416
  }) {
417
- const userColor = chunkUSAJMMF2_js.sanitizeColor(config?.userColor, "#6366f1");
417
+ const userColor = chunkSADF35N7_js.sanitizeColor(config?.userColor, "#6366f1");
418
418
  const { status, awareness, doc, clientId, synced, retry } = useYjsProvider({ config });
419
419
  const { remoteUsers, broadcastPresence } = usePresenceTracking({
420
420
  awareness,
@@ -523,8 +523,8 @@ function useEditorHistory(input) {
523
523
  width: canvasSize.width,
524
524
  height: canvasSize.height,
525
525
  activeSlideIndex,
526
- slides: slides.map(chunkUSAJMMF2_js.cloneSlide),
527
- templateElementsBySlideId: chunkUSAJMMF2_js.cloneTemplateElementsBySlideId(templateElementsBySlideId),
526
+ slides: slides.map(chunkSADF35N7_js.cloneSlide),
527
+ templateElementsBySlideId: chunkSADF35N7_js.cloneTemplateElementsBySlideId(templateElementsBySlideId),
528
528
  ...actionLabel ? { actionLabel } : {}
529
529
  };
530
530
  },
@@ -537,9 +537,9 @@ function useEditorHistory(input) {
537
537
  width: snapshot.width,
538
538
  height: snapshot.height
539
539
  });
540
- setSlides(snapshot.slides.map(chunkUSAJMMF2_js.cloneSlide));
540
+ setSlides(snapshot.slides.map(chunkSADF35N7_js.cloneSlide));
541
541
  setTemplateElementsBySlideId(
542
- chunkUSAJMMF2_js.cloneTemplateElementsBySlideId(snapshot.templateElementsBySlideId)
542
+ chunkSADF35N7_js.cloneTemplateElementsBySlideId(snapshot.templateElementsBySlideId)
543
543
  );
544
544
  setActiveSlideIndex(Math.min(snapshot.activeSlideIndex, maxSlideIndex));
545
545
  setSelectedElementIds([]);
@@ -573,8 +573,8 @@ function useEditorHistory(input) {
573
573
  const currentSnapshot = buildHistorySnapshot();
574
574
  historyFutureRef.current.push(currentSnapshot);
575
575
  isApplyingHistoryRef.current = true;
576
- const nextSnapshot = chunkNFJLF7TX_js.cloneHistorySnapshot(previousSnapshot);
577
- lastHistorySnapshotRef.current = chunkNFJLF7TX_js.cloneHistorySnapshot(nextSnapshot);
576
+ const nextSnapshot = chunkQBRZ3VIC_js.cloneHistorySnapshot(previousSnapshot);
577
+ lastHistorySnapshotRef.current = chunkQBRZ3VIC_js.cloneHistorySnapshot(nextSnapshot);
578
578
  lastHistorySerializedRef.current = JSON.stringify(nextSnapshot);
579
579
  applyHistorySnapshot(nextSnapshot);
580
580
  updateHistoryAvailability();
@@ -595,8 +595,8 @@ function useEditorHistory(input) {
595
595
  const currentSnapshot = buildHistorySnapshot();
596
596
  historyPastRef.current.push(currentSnapshot);
597
597
  isApplyingHistoryRef.current = true;
598
- const targetSnapshot = chunkNFJLF7TX_js.cloneHistorySnapshot(nextSnapshot);
599
- lastHistorySnapshotRef.current = chunkNFJLF7TX_js.cloneHistorySnapshot(targetSnapshot);
598
+ const targetSnapshot = chunkQBRZ3VIC_js.cloneHistorySnapshot(nextSnapshot);
599
+ lastHistorySnapshotRef.current = chunkQBRZ3VIC_js.cloneHistorySnapshot(targetSnapshot);
600
600
  lastHistorySerializedRef.current = JSON.stringify(targetSnapshot);
601
601
  applyHistorySnapshot(targetSnapshot);
602
602
  updateHistoryAvailability();
@@ -614,7 +614,7 @@ function useEditorHistory(input) {
614
614
  historyPastRef.current = [];
615
615
  historyFutureRef.current = [];
616
616
  if (initialSnapshot) {
617
- const clonedInitial = chunkNFJLF7TX_js.cloneHistorySnapshot(initialSnapshot);
617
+ const clonedInitial = chunkQBRZ3VIC_js.cloneHistorySnapshot(initialSnapshot);
618
618
  lastHistorySnapshotRef.current = clonedInitial;
619
619
  lastHistorySerializedRef.current = JSON.stringify(clonedInitial);
620
620
  } else {
@@ -655,18 +655,18 @@ function useEditorHistory(input) {
655
655
  }
656
656
  const previousSnapshot = lastHistorySnapshotRef.current;
657
657
  if (!previousSnapshot) {
658
- lastHistorySnapshotRef.current = chunkNFJLF7TX_js.cloneHistorySnapshot(snapshot);
658
+ lastHistorySnapshotRef.current = chunkQBRZ3VIC_js.cloneHistorySnapshot(snapshot);
659
659
  lastHistorySerializedRef.current = serialized;
660
660
  lastCheapHashRef.current = cheapHash;
661
661
  updateHistoryAvailability();
662
662
  return;
663
663
  }
664
- historyPastRef.current.push(chunkNFJLF7TX_js.cloneHistorySnapshot(previousSnapshot));
664
+ historyPastRef.current.push(chunkQBRZ3VIC_js.cloneHistorySnapshot(previousSnapshot));
665
665
  while (historyPastRef.current.length > Math.max(1, maxHistoryEntries)) {
666
666
  historyPastRef.current.shift();
667
667
  }
668
668
  historyFutureRef.current = [];
669
- lastHistorySnapshotRef.current = chunkNFJLF7TX_js.cloneHistorySnapshot(snapshot);
669
+ lastHistorySnapshotRef.current = chunkQBRZ3VIC_js.cloneHistorySnapshot(snapshot);
670
670
  lastHistorySerializedRef.current = serialized;
671
671
  lastCheapHashRef.current = cheapHash;
672
672
  updateHistoryAvailability();
@@ -726,9 +726,9 @@ function useZoomViewport({
726
726
  const canvasStageRef = react.useRef(null);
727
727
  const canvasViewportRef = react.useRef(null);
728
728
  const renderScaleRef = react.useRef(1);
729
- const wheelBufferRef = react.useRef(chunkUSAJMMF2_js.createWheelStepBuffer());
729
+ const wheelBufferRef = react.useRef(chunkSADF35N7_js.createWheelStepBuffer());
730
730
  const storeRef = react.useRef(null);
731
- storeRef.current ??= chunkUSAJMMF2_js.createViewerZoomStore();
731
+ storeRef.current ??= chunkSADF35N7_js.createViewerZoomStore();
732
732
  const store = storeRef.current;
733
733
  const scale = useViewerStore(store, selectZoom);
734
734
  const setScale = react.useCallback(
@@ -789,7 +789,7 @@ function useZoomViewport({
789
789
  if (!wrapper || !canvasViewport) {
790
790
  return;
791
791
  }
792
- const boundedScale = chunkUSAJMMF2_js.clampZoomScale(nextScale);
792
+ const boundedScale = chunkSADF35N7_js.clampZoomScale(nextScale);
793
793
  const nextEditorScale = fitScale * boundedScale;
794
794
  const centerX = (bounds.minX + bounds.maxX) / 2;
795
795
  const centerY = (bounds.minY + bounds.maxY) / 2;
@@ -826,29 +826,29 @@ function useZoomViewport({
826
826
  selectedElements.forEach((element) => {
827
827
  minX = Math.min(minX, element.x);
828
828
  minY = Math.min(minY, element.y);
829
- maxX = Math.max(maxX, element.x + Math.max(element.width, chunkNFJLF7TX_js.MIN_ELEMENT_SIZE));
830
- maxY = Math.max(maxY, element.y + Math.max(element.height, chunkNFJLF7TX_js.MIN_ELEMENT_SIZE));
829
+ maxX = Math.max(maxX, element.x + Math.max(element.width, chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE));
830
+ maxY = Math.max(maxY, element.y + Math.max(element.height, chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE));
831
831
  });
832
832
  if (!Number.isFinite(minX) || !Number.isFinite(minY) || !Number.isFinite(maxX) || !Number.isFinite(maxY)) {
833
833
  return;
834
834
  }
835
835
  const selectionBounds = { minX, minY, maxX, maxY };
836
- const boundsWidth = Math.max(selectionBounds.maxX - selectionBounds.minX, chunkNFJLF7TX_js.MIN_ELEMENT_SIZE);
837
- const boundsHeight = Math.max(selectionBounds.maxY - selectionBounds.minY, chunkNFJLF7TX_js.MIN_ELEMENT_SIZE);
836
+ const boundsWidth = Math.max(selectionBounds.maxX - selectionBounds.minX, chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE);
837
+ const boundsHeight = Math.max(selectionBounds.maxY - selectionBounds.minY, chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE);
838
838
  const availableWidth = Math.max(
839
- effectiveEditorDimensions.width - chunkNFJLF7TX_js.ZOOM_TO_SELECTION_PADDING,
840
- chunkNFJLF7TX_js.MIN_ELEMENT_SIZE
839
+ effectiveEditorDimensions.width - chunkQBRZ3VIC_js.ZOOM_TO_SELECTION_PADDING,
840
+ chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE
841
841
  );
842
842
  const availableHeight = Math.max(
843
- effectiveEditorDimensions.height - chunkNFJLF7TX_js.ZOOM_TO_SELECTION_PADDING,
844
- chunkNFJLF7TX_js.MIN_ELEMENT_SIZE
843
+ effectiveEditorDimensions.height - chunkQBRZ3VIC_js.ZOOM_TO_SELECTION_PADDING,
844
+ chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE
845
845
  );
846
846
  const targetEditorScale = Math.min(
847
847
  availableWidth / boundsWidth,
848
848
  availableHeight / boundsHeight
849
849
  );
850
850
  const safeFitScale = fitScale > Number.EPSILON ? fitScale : Number.EPSILON;
851
- const nextScale = chunkUSAJMMF2_js.clampZoomScale(targetEditorScale / safeFitScale);
851
+ const nextScale = chunkSADF35N7_js.clampZoomScale(targetEditorScale / safeFitScale);
852
852
  setScale(nextScale);
853
853
  window.requestAnimationFrame(() => {
854
854
  window.requestAnimationFrame(() => {
@@ -865,14 +865,14 @@ function useZoomViewport({
865
865
  ]);
866
866
  const handleWheel = react.useCallback(
867
867
  (event) => {
868
- const mapped = chunkUSAJMMF2_js.mapEditingWheel(event, wheelBufferRef.current, true);
868
+ const mapped = chunkSADF35N7_js.mapEditingWheel(event, wheelBufferRef.current, true);
869
869
  if (mapped.intent !== "zoom") {
870
870
  return;
871
871
  }
872
872
  event.preventDefault();
873
873
  store.dispatch({
874
874
  type: "set-zoom",
875
- zoom: chunkUSAJMMF2_js.clampZoomScale(store.getState().zoom + mapped.deltaScale)
875
+ zoom: chunkSADF35N7_js.clampZoomScale(store.getState().zoom + mapped.deltaScale)
876
876
  });
877
877
  },
878
878
  [store]
@@ -960,7 +960,7 @@ function applyAnimationGroupSteps(group, onPlayActionSound, setPresentationEleme
960
960
  const command = step.command;
961
961
  const timer = window.setTimeout(
962
962
  () => {
963
- chunkNFJLF7TX_js.executeMediaCommand(command);
963
+ chunkQBRZ3VIC_js.executeMediaCommand(command);
964
964
  },
965
965
  Math.max(0, step.delayMs)
966
966
  );
@@ -1097,7 +1097,7 @@ function scheduleEntranceAnimationTimers(slide, setPresentationAnimations, prese
1097
1097
  }))
1098
1098
  );
1099
1099
  entranceAnimations.forEach((animation, animationIndex) => {
1100
- const delay = chunkUSAJMMF2_js.computeEntranceAnimationDelay(animation.delayMs, animationIndex);
1100
+ const delay = chunkSADF35N7_js.computeEntranceAnimationDelay(animation.delayMs, animationIndex);
1101
1101
  const timer = window.setTimeout(() => {
1102
1102
  setPresentationAnimations(
1103
1103
  (previousAnimations) => previousAnimations.map(
@@ -1129,7 +1129,7 @@ function useAnimationPlayback(input) {
1129
1129
  (controller, group) => {
1130
1130
  driveBuildReveal(
1131
1131
  controller,
1132
- chunkUSAJMMF2_js.PresentationAnimationController.collectBuildStepIds(group),
1132
+ chunkSADF35N7_js.PresentationAnimationController.collectBuildStepIds(group),
1133
1133
  setPresentationElementStates,
1134
1134
  buildRafRef
1135
1135
  );
@@ -1192,7 +1192,7 @@ function useAnimationPlayback(input) {
1192
1192
  setHoverTriggerShapeIds(/* @__PURE__ */ new Set());
1193
1193
  return;
1194
1194
  }
1195
- const controller = chunkUSAJMMF2_js.PresentationAnimationController.fromSlide(slide);
1195
+ const controller = chunkSADF35N7_js.PresentationAnimationController.fromSlide(slide);
1196
1196
  controllerRef.current = controller;
1197
1197
  setPresentationKeyframesCss(controller.keyframesCss);
1198
1198
  setInteractiveTriggerShapeIds(controller.interactiveTriggerShapeIds);
@@ -1350,12 +1350,12 @@ function useAnimationPlayback(input) {
1350
1350
  presentationTimersRef
1351
1351
  };
1352
1352
  }
1353
- var PRESENTER_CHANNEL_NAME = chunkUSAJMMF2_js.PRESENTATION_CHANNEL_NAME;
1354
- var AUDIENCE_HASH = chunkUSAJMMF2_js.PRESENTATION_HASH;
1355
- var PRESENTER_MSG_ORIGIN = chunkUSAJMMF2_js.PRESENTATION_MESSAGE_ORIGIN;
1356
- var AUDIENCE_NONCE_KEY = chunkUSAJMMF2_js.PRESENTATION_NONCE_KEY;
1353
+ var PRESENTER_CHANNEL_NAME = chunkSADF35N7_js.PRESENTATION_CHANNEL_NAME;
1354
+ var AUDIENCE_HASH = chunkSADF35N7_js.PRESENTATION_HASH;
1355
+ var PRESENTER_MSG_ORIGIN = chunkSADF35N7_js.PRESENTATION_MESSAGE_ORIGIN;
1356
+ var AUDIENCE_NONCE_KEY = chunkSADF35N7_js.PRESENTATION_NONCE_KEY;
1357
1357
  function generateSessionId() {
1358
- return chunkUSAJMMF2_js.createPresentationSessionId();
1358
+ return chunkSADF35N7_js.createPresentationSessionId();
1359
1359
  }
1360
1360
  function parseAudienceNonce() {
1361
1361
  const hash = window.location.hash;
@@ -1391,7 +1391,7 @@ function usePresenterWindow(input) {
1391
1391
  }, []);
1392
1392
  const swapDisplays = react.useCallback(async () => {
1393
1393
  const audience = audienceWindowRef.current;
1394
- return audience && !audience.closed ? chunkUSAJMMF2_js.swapPresentationWindows(window, audience) : false;
1394
+ return audience && !audience.closed ? chunkSADF35N7_js.swapPresentationWindows(window, audience) : false;
1395
1395
  }, []);
1396
1396
  const syncSlideToAudience = react.useCallback(
1397
1397
  (slideIndex) => {
@@ -1455,7 +1455,7 @@ function usePresenterWindow(input) {
1455
1455
  pollTimerRef.current = null;
1456
1456
  }
1457
1457
  if (closingSessionId) {
1458
- void chunkUSAJMMF2_js.clearAudienceContent(closingSessionId);
1458
+ void chunkSADF35N7_js.clearAudienceContent(closingSessionId);
1459
1459
  }
1460
1460
  }, [getChannel]);
1461
1461
  const openAudienceWindow = react.useCallback(() => {
@@ -1473,10 +1473,10 @@ function usePresenterWindow(input) {
1473
1473
  audienceWindowRef.current = blankWin;
1474
1474
  const sessionId = generateSessionId();
1475
1475
  sessionIdRef.current = sessionId;
1476
- const audienceUrl = chunkUSAJMMF2_js.buildPresentationAudienceUrl(window.location.href, sessionId);
1477
- void chunkUSAJMMF2_js.resolveAudienceScreenPlacement(window).then((placement) => {
1476
+ const audienceUrl = chunkSADF35N7_js.buildPresentationAudienceUrl(window.location.href, sessionId);
1477
+ void chunkSADF35N7_js.resolveAudienceScreenPlacement(window).then((placement) => {
1478
1478
  if (placement && audienceWindowRef.current === blankWin && !blankWin.closed) {
1479
- chunkUSAJMMF2_js.placeAudienceWindow(blankWin, placement);
1479
+ chunkSADF35N7_js.placeAudienceWindow(blankWin, placement);
1480
1480
  }
1481
1481
  return void 0;
1482
1482
  });
@@ -1506,7 +1506,7 @@ function usePresenterWindow(input) {
1506
1506
  }
1507
1507
  };
1508
1508
  if (content) {
1509
- void chunkUSAJMMF2_js.storeAudienceContent(content, sessionId).then(() => navigateOrClose(true)).catch(() => navigateOrClose(false));
1509
+ void chunkSADF35N7_js.storeAudienceContent(content, sessionId).then(() => navigateOrClose(true)).catch(() => navigateOrClose(false));
1510
1510
  } else {
1511
1511
  navigateOrClose(true);
1512
1512
  }
@@ -1532,7 +1532,7 @@ function usePresenterWindow(input) {
1532
1532
  }
1533
1533
  const handleMessage = (event) => {
1534
1534
  const message = event.data;
1535
- if (chunkUSAJMMF2_js.isPresentationSessionMessage(message) && message.type === "audience-ready" && message.sessionId === sessionIdRef.current) {
1535
+ if (chunkSADF35N7_js.isPresentationSessionMessage(message) && message.type === "audience-ready" && message.sessionId === sessionIdRef.current) {
1536
1536
  syncStateToAudience(snapshotRef.current);
1537
1537
  }
1538
1538
  };
@@ -1561,7 +1561,7 @@ function usePresenterWindow(input) {
1561
1561
  react.useEffect(() => {
1562
1562
  const handleBeforeUnload = () => {
1563
1563
  if (sessionIdRef.current) {
1564
- void chunkUSAJMMF2_js.clearAudienceContent(sessionIdRef.current);
1564
+ void chunkSADF35N7_js.clearAudienceContent(sessionIdRef.current);
1565
1565
  }
1566
1566
  };
1567
1567
  window.addEventListener("beforeunload", handleBeforeUnload);
@@ -1623,7 +1623,7 @@ function useAudienceMode(input) {
1623
1623
  }
1624
1624
  channel.onmessage = (event) => {
1625
1625
  const data = event.data;
1626
- if (!chunkUSAJMMF2_js.isPresentationSessionMessage(data) || data.origin !== PRESENTER_MSG_ORIGIN) {
1626
+ if (!chunkSADF35N7_js.isPresentationSessionMessage(data) || data.origin !== PRESENTER_MSG_ORIGIN) {
1627
1627
  return;
1628
1628
  }
1629
1629
  if (expectedSessionId && data.sessionId !== expectedSessionId) {
@@ -1639,16 +1639,16 @@ function useAudienceMode(input) {
1639
1639
  }
1640
1640
  if (data.type === "presenter-exit") {
1641
1641
  if (expectedSessionId) {
1642
- void chunkUSAJMMF2_js.clearAudienceContent(expectedSessionId);
1642
+ void chunkSADF35N7_js.clearAudienceContent(expectedSessionId);
1643
1643
  }
1644
- if (chunkUSAJMMF2_js.endAudienceDisplay(window)) {
1644
+ if (chunkSADF35N7_js.endAudienceDisplay(window)) {
1645
1645
  handlers.onPresenterEnded?.();
1646
1646
  }
1647
1647
  }
1648
1648
  };
1649
1649
  if (expectedSessionId) {
1650
1650
  channel.postMessage({
1651
- origin: chunkUSAJMMF2_js.PRESENTATION_MESSAGE_ORIGIN,
1651
+ origin: chunkSADF35N7_js.PRESENTATION_MESSAGE_ORIGIN,
1652
1652
  type: "audience-ready",
1653
1653
  sessionId: expectedSessionId
1654
1654
  });
@@ -1662,7 +1662,7 @@ function useAudienceMode(input) {
1662
1662
  }, []);
1663
1663
  }
1664
1664
  function usePresentationKeyboard(input) {
1665
- const wheelBufferRef = react.useRef(chunkUSAJMMF2_js.createWheelStepBuffer());
1665
+ const wheelBufferRef = react.useRef(chunkSADF35N7_js.createWheelStepBuffer());
1666
1666
  const {
1667
1667
  mode,
1668
1668
  movePresentationSlide,
@@ -1682,14 +1682,14 @@ function usePresentationKeyboard(input) {
1682
1682
  presentationSlideIndex,
1683
1683
  setShowRehearsalSummary
1684
1684
  } = input;
1685
- const keyBufferRef = react.useRef(chunkUSAJMMF2_js.createPresentationKeyBuffer());
1685
+ const keyBufferRef = react.useRef(chunkSADF35N7_js.createPresentationKeyBuffer());
1686
1686
  react.useEffect(() => {
1687
- if (mode !== "present" || !chunkUSAJMMF2_js.acceptsPresentationInput()) {
1688
- keyBufferRef.current = chunkUSAJMMF2_js.createPresentationKeyBuffer();
1687
+ if (mode !== "present" || !chunkSADF35N7_js.acceptsPresentationInput()) {
1688
+ keyBufferRef.current = chunkSADF35N7_js.createPresentationKeyBuffer();
1689
1689
  return;
1690
1690
  }
1691
1691
  const handleKeyDown = (event) => {
1692
- const mapped = chunkUSAJMMF2_js.mapPresentationKey(event, keyBufferRef.current);
1692
+ const mapped = chunkSADF35N7_js.mapPresentationKey(event, keyBufferRef.current);
1693
1693
  if (mapped.action === "none") {
1694
1694
  return;
1695
1695
  }
@@ -1709,12 +1709,12 @@ function usePresentationKeyboard(input) {
1709
1709
  movePresentationSlide(-1);
1710
1710
  return;
1711
1711
  case "first": {
1712
- const first = chunkUSAJMMF2_js.firstShowSlideIndex(showSlideIndexes);
1712
+ const first = chunkSADF35N7_js.firstShowSlideIndex(showSlideIndexes);
1713
1713
  navigateToSlide(first ?? 0);
1714
1714
  return;
1715
1715
  }
1716
1716
  case "last": {
1717
- const last = chunkUSAJMMF2_js.lastShowSlideIndex(showSlideIndexes);
1717
+ const last = chunkSADF35N7_js.lastShowSlideIndex(showSlideIndexes);
1718
1718
  navigateToSlide(last ?? Math.max(0, slideCount - 1));
1719
1719
  return;
1720
1720
  }
@@ -1749,10 +1749,10 @@ function usePresentationKeyboard(input) {
1749
1749
  }
1750
1750
  };
1751
1751
  const handleWheel = (event) => {
1752
- if (mode !== "present" || !chunkUSAJMMF2_js.acceptsPresentationInput()) {
1752
+ if (mode !== "present" || !chunkSADF35N7_js.acceptsPresentationInput()) {
1753
1753
  return;
1754
1754
  }
1755
- const mapped = chunkUSAJMMF2_js.mapPresentationWheel(event, wheelBufferRef.current);
1755
+ const mapped = chunkSADF35N7_js.mapPresentationWheel(event, wheelBufferRef.current);
1756
1756
  if (mapped.intent === "next-slide") {
1757
1757
  event.preventDefault();
1758
1758
  movePresentationSlide(1);
@@ -1884,7 +1884,7 @@ function useRehearsalTimings(input) {
1884
1884
 
1885
1885
  // src/viewer/hooks/presentation-mode/presentation-actions.ts
1886
1886
  function handlePresentationActionImpl(action, deps) {
1887
- chunkUSAJMMF2_js.runPresentationAction(
1887
+ chunkSADF35N7_js.runPresentationAction(
1888
1888
  action,
1889
1889
  { slideCount: deps.slidesLength },
1890
1890
  {
@@ -1906,7 +1906,7 @@ function handlePresentationActionImpl(action, deps) {
1906
1906
  function executeSlideTransition(nextSlideIndex, deps) {
1907
1907
  const incomingSlide = deps.slides[nextSlideIndex];
1908
1908
  const transition = incomingSlide?.transition;
1909
- const durationMs = deps.playTransition ? chunkUSAJMMF2_js.resolveTransitionDurationMs(transition) : 0;
1909
+ const durationMs = deps.playTransition ? chunkSADF35N7_js.resolveTransitionDurationMs(transition) : 0;
1910
1910
  deps.clearPresentationTimers();
1911
1911
  deps.setPresentationSlideIndex(nextSlideIndex);
1912
1912
  deps.onSetActiveSlideIndex(nextSlideIndex);
@@ -1965,7 +1965,7 @@ function useSlideNavigation(input) {
1965
1965
  });
1966
1966
  const scheduleAutoAdvanceForSlide = react.useCallback(
1967
1967
  (slideIndex) => {
1968
- const delayMs = chunkUSAJMMF2_js.resolveAutoAdvanceDelayMs(slides[slideIndex], { useTimings });
1968
+ const delayMs = chunkSADF35N7_js.resolveAutoAdvanceDelayMs(slides[slideIndex], { useTimings });
1969
1969
  if (delayMs === void 0) {
1970
1970
  return;
1971
1971
  }
@@ -1988,7 +1988,7 @@ function useSlideNavigation(input) {
1988
1988
  if (availableSlideIndexes.length === 0) {
1989
1989
  return;
1990
1990
  }
1991
- const pastLastSlide = direction === 1 && !chunkUSAJMMF2_js.hasShowSlideAfter(presentationSlideIndex, availableSlideIndexes);
1991
+ const pastLastSlide = direction === 1 && !chunkSADF35N7_js.hasShowSlideAfter(presentationSlideIndex, availableSlideIndexes);
1992
1992
  if (rehearsing && pastLastSlide) {
1993
1993
  recordCurrentSlideTime(presentationSlideIndex);
1994
1994
  try {
@@ -2006,9 +2006,9 @@ function useSlideNavigation(input) {
2006
2006
  onAdvancePastLastSlide();
2007
2007
  return;
2008
2008
  }
2009
- const nextSlideIndex = direction === 1 ? chunkUSAJMMF2_js.nextShowSlideIndex(presentationSlideIndex, availableSlideIndexes, {
2009
+ const nextSlideIndex = direction === 1 ? chunkSADF35N7_js.nextShowSlideIndex(presentationSlideIndex, availableSlideIndexes, {
2010
2010
  loop: Boolean(loopContinuously) && !rehearsing
2011
- }) : chunkUSAJMMF2_js.previousShowSlideIndex(presentationSlideIndex, availableSlideIndexes);
2011
+ }) : chunkSADF35N7_js.previousShowSlideIndex(presentationSlideIndex, availableSlideIndexes);
2012
2012
  if (nextSlideIndex === void 0 || nextSlideIndex === presentationSlideIndex) {
2013
2013
  return;
2014
2014
  }
@@ -2153,22 +2153,22 @@ function useZoomNavigation(input) {
2153
2153
  };
2154
2154
  }
2155
2155
  function usePresenterConsole(slideIndex, active) {
2156
- const timerRef = react.useRef(chunkUSAJMMF2_js.createPresenterTimer());
2157
- const [snapshot, setSnapshot] = react.useState(() => chunkUSAJMMF2_js.createInitialPresentationSnapshot(slideIndex));
2156
+ const timerRef = react.useRef(chunkSADF35N7_js.createPresenterTimer());
2157
+ const [snapshot, setSnapshot] = react.useState(() => chunkSADF35N7_js.createInitialPresentationSnapshot(slideIndex));
2158
2158
  const patch = react.useCallback((value) => {
2159
- setSnapshot((current) => chunkUSAJMMF2_js.mergePresentationSnapshot(current, value));
2159
+ setSnapshot((current) => chunkSADF35N7_js.mergePresentationSnapshot(current, value));
2160
2160
  }, []);
2161
2161
  react.useEffect(() => patch({ slideIndex }), [patch, slideIndex]);
2162
2162
  react.useEffect(() => {
2163
2163
  if (!active) {
2164
2164
  return;
2165
2165
  }
2166
- timerRef.current = chunkUSAJMMF2_js.resetPresenterTimer();
2166
+ timerRef.current = chunkSADF35N7_js.resetPresenterTimer();
2167
2167
  patch({ paused: false, elapsedMs: 0 });
2168
2168
  const timer = window.setInterval(() => {
2169
2169
  patch({
2170
2170
  paused: timerRef.current.paused,
2171
- elapsedMs: chunkUSAJMMF2_js.presenterElapsed(timerRef.current)
2171
+ elapsedMs: chunkSADF35N7_js.presenterElapsed(timerRef.current)
2172
2172
  });
2173
2173
  }, 1e3);
2174
2174
  return () => window.clearInterval(timer);
@@ -2178,19 +2178,19 @@ function usePresenterConsole(slideIndex, active) {
2178
2178
  applyAudienceSnapshot: setSnapshot,
2179
2179
  setBlackout: (blackout) => patch({ blackout }),
2180
2180
  toggleTimer: () => {
2181
- timerRef.current = chunkUSAJMMF2_js.togglePresenterTimer(timerRef.current);
2181
+ timerRef.current = chunkSADF35N7_js.togglePresenterTimer(timerRef.current);
2182
2182
  patch({
2183
2183
  paused: timerRef.current.paused,
2184
- elapsedMs: chunkUSAJMMF2_js.presenterElapsed(timerRef.current)
2184
+ elapsedMs: chunkSADF35N7_js.presenterElapsed(timerRef.current)
2185
2185
  });
2186
2186
  },
2187
2187
  resetTimer: () => {
2188
- timerRef.current = chunkUSAJMMF2_js.resetPresenterTimer();
2188
+ timerRef.current = chunkSADF35N7_js.resetPresenterTimer();
2189
2189
  patch({ paused: false, elapsedMs: 0 });
2190
2190
  },
2191
2191
  stepZoom: (direction) => setSnapshot(
2192
- (current) => chunkUSAJMMF2_js.mergePresentationSnapshot(current, {
2193
- zoom: chunkUSAJMMF2_js.stepPresenterZoom(
2192
+ (current) => chunkSADF35N7_js.mergePresentationSnapshot(current, {
2193
+ zoom: chunkSADF35N7_js.stepPresenterZoom(
2194
2194
  current.zoom ?? { scale: 1, originX: 0.5, originY: 0.5 },
2195
2195
  direction
2196
2196
  )
@@ -2235,7 +2235,7 @@ function usePresentationMode(input) {
2235
2235
  const [allSlidesOpen, setAllSlidesOpen] = react.useState(false);
2236
2236
  const [endOfShowVisible, setEndOfShowVisible] = react.useState(false);
2237
2237
  const [presentationStartTime, setPresentationStartTime] = react.useState(null);
2238
- const showGuard = react.useMemo(() => chunkUSAJMMF2_js.createPresenterShowGuard(), []);
2238
+ const showGuard = react.useMemo(() => chunkSADF35N7_js.createPresenterShowGuard(), []);
2239
2239
  const {
2240
2240
  presentationAnimations,
2241
2241
  presentationElementStates,
@@ -2314,7 +2314,7 @@ function usePresentationMode(input) {
2314
2314
  });
2315
2315
  const movePresentationSlide = react.useCallback(
2316
2316
  (direction, trigger = "explicit") => {
2317
- if (!chunkUSAJMMF2_js.acceptsPresentationInput()) {
2317
+ if (!chunkSADF35N7_js.acceptsPresentationInput()) {
2318
2318
  return;
2319
2319
  }
2320
2320
  if (endOfShowVisible) {
@@ -2451,7 +2451,7 @@ function usePresentationMode(input) {
2451
2451
  if (mode !== "present") {
2452
2452
  return;
2453
2453
  }
2454
- return chunkUSAJMMF2_js.attachPresentationVisibilityPause({
2454
+ return chunkSADF35N7_js.attachPresentationVisibilityPause({
2455
2455
  root: containerRef.current ?? void 0,
2456
2456
  onHidden: () => clearPresentationTimersRef.current(),
2457
2457
  onVisible: () => scheduleAutoAdvanceRef.current(presentationSlideIndexRef.current)
@@ -2531,11 +2531,11 @@ function usePresentationMode(input) {
2531
2531
  if (!transitionOverlay || transitionOverlay.transition.type !== "morph") {
2532
2532
  return void 0;
2533
2533
  }
2534
- return chunkUSAJMMF2_js.buildMorphTransitionPlan(
2534
+ return chunkSADF35N7_js.buildMorphTransitionPlan(
2535
2535
  slides[transitionOverlay.outgoingSlideIndex],
2536
2536
  slides[transitionOverlay.incomingSlideIndex],
2537
2537
  transitionOverlay.durationMs,
2538
- chunkUSAJMMF2_js.morphOptionToMode(transitionOverlay.transition.morphOption)
2538
+ chunkSADF35N7_js.morphOptionToMode(transitionOverlay.transition.morphOption)
2539
2539
  );
2540
2540
  }, [transitionOverlay, slides]);
2541
2541
  const morphedElementStates = react.useMemo(() => {
@@ -2556,7 +2556,7 @@ function usePresentationMode(input) {
2556
2556
  if (!morphPlan) {
2557
2557
  return presentationKeyframesCss;
2558
2558
  }
2559
- const imageRules = chunkUSAJMMF2_js.buildMorphAnimationRules(morphPlan, "", "incoming", "image");
2559
+ const imageRules = chunkSADF35N7_js.buildMorphAnimationRules(morphPlan, "", "incoming", "image");
2560
2560
  return `${presentationKeyframesCss ?? ""}
2561
2561
  ${morphPlan.keyframesCss}
2562
2562
  ${imageRules}`;
@@ -2852,7 +2852,7 @@ function useFindReplace({
2852
2852
  const [findResults, setFindResults] = react.useState([]);
2853
2853
  const [findResultIndex, setFindResultIndex] = react.useState(-1);
2854
2854
  const performFind = react.useCallback(() => {
2855
- const results = chunkUSAJMMF2_js.findInSlides(slides, findQuery, { matchCase: findMatchCase });
2855
+ const results = chunkSADF35N7_js.findInSlides(slides, findQuery, { matchCase: findMatchCase });
2856
2856
  if (!findQuery) {
2857
2857
  setFindResults([]);
2858
2858
  setFindResultIndex(-1);
@@ -2886,7 +2886,7 @@ function useFindReplace({
2886
2886
  return;
2887
2887
  }
2888
2888
  onUpdateSlides(
2889
- (prevSlides) => chunkUSAJMMF2_js.applyFindReplacements(prevSlides, toReplace, replaceQuery).slides
2889
+ (prevSlides) => chunkSADF35N7_js.applyFindReplacements(prevSlides, toReplace, replaceQuery).slides
2890
2890
  );
2891
2891
  onMarkDirty();
2892
2892
  },
@@ -3410,7 +3410,7 @@ function useViewerCoreState(_input) {
3410
3410
  const marqueeStateRef = react.useRef(null);
3411
3411
  const isDrawingRef = react.useRef(false);
3412
3412
  const justInteractedRef = react.useRef(false);
3413
- const livePatcher = react.useMemo(() => chunkUSAJMMF2_js.createCollaborationLivePatcher(), []);
3413
+ const livePatcher = react.useMemo(() => chunkSADF35N7_js.createCollaborationLivePatcher(), []);
3414
3414
  react.useEffect(() => () => livePatcher.dispose(), [livePatcher]);
3415
3415
  const slidesRef = react.useRef([]);
3416
3416
  const [mode, setMode] = react.useState("edit");
@@ -3419,8 +3419,8 @@ function useViewerCoreState(_input) {
3419
3419
  const [slides, setSlides] = react.useState([]);
3420
3420
  const [templateElementsBySlideId, setTemplateElementsBySlideId] = react.useState({});
3421
3421
  const [canvasSize, setCanvasSize] = react.useState({
3422
- width: chunkNFJLF7TX_js.DEFAULT_CANVAS_WIDTH,
3423
- height: chunkNFJLF7TX_js.DEFAULT_CANVAS_HEIGHT
3422
+ width: chunkQBRZ3VIC_js.DEFAULT_CANVAS_WIDTH,
3423
+ height: chunkQBRZ3VIC_js.DEFAULT_CANVAS_HEIGHT
3424
3424
  });
3425
3425
  const [activeSlideIndex, setActiveSlideIndex] = react.useState(0);
3426
3426
  const [selectedElementId, setSelectedElementId] = react.useState(null);
@@ -3440,7 +3440,7 @@ function useViewerCoreState(_input) {
3440
3440
  const resolved = typeof value === "function" ? value(inlineEditingTextRef.current) : value;
3441
3441
  inlineEditingTextRef.current = resolved;
3442
3442
  setInlineEditingTextBase(value);
3443
- chunkUSAJMMF2_js.publishLiveInlineText(
3443
+ chunkSADF35N7_js.publishLiveInlineText(
3444
3444
  livePatcher,
3445
3445
  slidesRef.current[activeSlideIndexRef.current],
3446
3446
  inlineEditingElementIdRef.current,
@@ -3775,7 +3775,7 @@ function useLoadContent({
3775
3775
  );
3776
3776
  }
3777
3777
  const previousHandler = handlerRef.current;
3778
- const handler = new chunkUSAJMMF2_js.PptxHandler();
3778
+ const handler = new chunkSADF35N7_js.PptxHandler();
3779
3779
  const parsed = await handler.load(buffer);
3780
3780
  if (cancelled || token !== renderTokenRef.current) {
3781
3781
  handler.dispose();
@@ -3787,7 +3787,7 @@ function useLoadContent({
3787
3787
  handlerRef.current = null;
3788
3788
  const mediaElements = [];
3789
3789
  for (const slide of parsed.slides) {
3790
- chunkUSAJMMF2_js.collectMediaElements(slide.elements, mediaElements);
3790
+ chunkSADF35N7_js.collectMediaElements(slide.elements, mediaElements);
3791
3791
  }
3792
3792
  for (const url of mediaDataUrls.values()) {
3793
3793
  if (url.startsWith("blob:")) {
@@ -3828,7 +3828,7 @@ function useLoadContent({
3828
3828
  }
3829
3829
  })
3830
3830
  );
3831
- const { paths: imagePaths, refs: imageRefs } = chunkUSAJMMF2_js.collectImagePaths(parsed.slides);
3831
+ const { paths: imagePaths, refs: imageRefs } = chunkSADF35N7_js.collectImagePaths(parsed.slides);
3832
3832
  let nextSlides = parsed.slides;
3833
3833
  if (imagePaths.size > 0) {
3834
3834
  const resolvedMap = /* @__PURE__ */ new Map();
@@ -3883,12 +3883,12 @@ function useLoadContent({
3883
3883
  }
3884
3884
  }
3885
3885
  handlerRef.current = handler;
3886
- const partition = chunkUSAJMMF2_js.partitionTemplateElements(nextSlides);
3886
+ const partition = chunkSADF35N7_js.partitionTemplateElements(nextSlides);
3887
3887
  setSlides(partition.slides);
3888
3888
  setTemplateElementsBySlideId(partition.templateElementsBySlideId);
3889
3889
  setCanvasSize({
3890
- width: parsed.width ?? chunkNFJLF7TX_js.DEFAULT_CANVAS_WIDTH,
3891
- height: parsed.height ?? chunkNFJLF7TX_js.DEFAULT_CANVAS_HEIGHT
3890
+ width: parsed.width ?? chunkQBRZ3VIC_js.DEFAULT_CANVAS_WIDTH,
3891
+ height: parsed.height ?? chunkQBRZ3VIC_js.DEFAULT_CANVAS_HEIGHT
3892
3892
  });
3893
3893
  setHeaderFooter(parsed.headerFooter ?? {});
3894
3894
  setLayoutOptions(parsed.layoutOptions ?? []);
@@ -3917,7 +3917,7 @@ function useLoadContent({
3917
3917
  setHasMacros(parsed.hasMacros === true);
3918
3918
  setHasDigitalSignatures(parsed.hasDigitalSignatures === true);
3919
3919
  setDigitalSignatureCount(parsed.digitalSignatureCount ?? 0);
3920
- setGuides(chunkUSAJMMF2_js.buildInitialGuides(parsed.presentationGuides, parsed.slides[0]?.guides));
3920
+ setGuides(chunkSADF35N7_js.buildInitialGuides(parsed.presentationGuides, parsed.slides[0]?.guides));
3921
3921
  setActiveSlideIndex(0);
3922
3922
  clearSelection();
3923
3923
  setIsDirty(false);
@@ -3925,7 +3925,7 @@ function useLoadContent({
3925
3925
  onContentApplied?.();
3926
3926
  } catch (err) {
3927
3927
  if (!cancelled && token === renderTokenRef.current) {
3928
- if (err instanceof chunkUSAJMMF2_js.EncryptedFileError) {
3928
+ if (err instanceof chunkSADF35N7_js.EncryptedFileError) {
3929
3929
  setIsEncrypted(true);
3930
3930
  } else {
3931
3931
  setError(err instanceof Error ? err.message : String(err));
@@ -4002,7 +4002,7 @@ function useAutosave(input) {
4002
4002
  isSavingRef.current = false;
4003
4003
  return;
4004
4004
  }
4005
- await chunkUSAJMMF2_js.saveAutosaveSnapshot(filePathRef.current, data);
4005
+ await chunkSADF35N7_js.saveAutosaveSnapshot(filePathRef.current, data);
4006
4006
  setAutosaveStatus({ state: "saved", timestamp: Date.now() });
4007
4007
  } catch (err) {
4008
4008
  setAutosaveStatus({
@@ -4067,7 +4067,7 @@ function useElementOperations(input) {
4067
4067
  }, [applySelection, setInlineEditingElementId, setContextMenuState]);
4068
4068
  const updateElementById = react.useCallback(
4069
4069
  (elementId, updates) => {
4070
- if (chunkUSAJMMF2_js.isTemplateElementId(elementId)) {
4070
+ if (chunkSADF35N7_js.isTemplateElementId(elementId)) {
4071
4071
  const slideId = activeSlide?.id;
4072
4072
  if (slideId) {
4073
4073
  setTemplateElementsBySlideId((prev) => ({
@@ -4107,7 +4107,7 @@ function useElementOperations(input) {
4107
4107
  );
4108
4108
  const updateSelectedShapeStyle = react.useCallback(
4109
4109
  (updates) => {
4110
- if (!selectedElement || !chunkUSAJMMF2_js.hasShapeProperties(selectedElement)) {
4110
+ if (!selectedElement || !chunkSADF35N7_js.hasShapeProperties(selectedElement)) {
4111
4111
  return;
4112
4112
  }
4113
4113
  updateSelectedElement({
@@ -4118,17 +4118,17 @@ function useElementOperations(input) {
4118
4118
  );
4119
4119
  const updateSelectedTextStyle = react.useCallback(
4120
4120
  (updates) => {
4121
- if (!selectedElement || !chunkUSAJMMF2_js.hasTextProperties(selectedElement)) {
4121
+ if (!selectedElement || !chunkSADF35N7_js.hasTextProperties(selectedElement)) {
4122
4122
  return;
4123
4123
  }
4124
- const inlineSel = chunkUSAJMMF2_js.getInlineEditorSelection(selectedElement.textSegments);
4124
+ const inlineSel = chunkSADF35N7_js.getInlineEditorSelection(selectedElement.textSegments);
4125
4125
  if (inlineSel && selectedElement.textSegments) {
4126
- const { newSegments: newSegments2, newSelection } = chunkUSAJMMF2_js.applyStyleToSelectedSegments(
4126
+ const { newSegments: newSegments2, newSelection } = chunkSADF35N7_js.applyStyleToSelectedSegments(
4127
4127
  selectedElement.textSegments,
4128
4128
  inlineSel,
4129
4129
  updates
4130
4130
  );
4131
- chunkUSAJMMF2_js.setPendingSelectionRestore(newSelection);
4131
+ chunkSADF35N7_js.setPendingSelectionRestore(newSelection);
4132
4132
  updateSelectedElement({
4133
4133
  textSegments: newSegments2
4134
4134
  });
@@ -4148,12 +4148,12 @@ function useElementOperations(input) {
4148
4148
  );
4149
4149
  const updateSelectedTextCase = react.useCallback(
4150
4150
  (mode) => {
4151
- if (!selectedElement || !chunkUSAJMMF2_js.hasTextProperties(selectedElement)) {
4151
+ if (!selectedElement || !chunkSADF35N7_js.hasTextProperties(selectedElement)) {
4152
4152
  return;
4153
4153
  }
4154
- const inlineSel = chunkUSAJMMF2_js.getInlineEditorSelection(selectedElement.textSegments);
4154
+ const inlineSel = chunkSADF35N7_js.getInlineEditorSelection(selectedElement.textSegments);
4155
4155
  if (inlineSel && selectedElement.textSegments) {
4156
- const newSegments = chunkUSAJMMF2_js.applyCaseTransformToSegments(
4156
+ const newSegments = chunkSADF35N7_js.applyCaseTransformToSegments(
4157
4157
  selectedElement.textSegments,
4158
4158
  inlineSel,
4159
4159
  mode
@@ -4163,14 +4163,14 @@ function useElementOperations(input) {
4163
4163
  }
4164
4164
  const updates = {};
4165
4165
  if (selectedElement.textSegments && selectedElement.textSegments.length > 0) {
4166
- updates.textSegments = chunkUSAJMMF2_js.applyCaseTransformToSegments(
4166
+ updates.textSegments = chunkSADF35N7_js.applyCaseTransformToSegments(
4167
4167
  selectedElement.textSegments,
4168
4168
  null,
4169
4169
  mode
4170
4170
  );
4171
4171
  }
4172
4172
  if (typeof selectedElement.text === "string") {
4173
- updates.text = chunkUSAJMMF2_js.transformTextCase(selectedElement.text, mode);
4173
+ updates.text = chunkSADF35N7_js.transformTextCase(selectedElement.text, mode);
4174
4174
  }
4175
4175
  updateSelectedElement(updates);
4176
4176
  },
@@ -4225,7 +4225,7 @@ function useSectionOperations(input) {
4225
4225
  const { sections, setSections, slides, setSlides, markDirty } = input;
4226
4226
  const addSection2 = react.useCallback(
4227
4227
  (name, afterSlideIndex) => {
4228
- const result = chunkUSAJMMF2_js.addSection(sections, slides, name, afterSlideIndex);
4228
+ const result = chunkSADF35N7_js.addSection(sections, slides, name, afterSlideIndex);
4229
4229
  setSlides(result.slides);
4230
4230
  setSections(result.sections);
4231
4231
  markDirty();
@@ -4234,7 +4234,7 @@ function useSectionOperations(input) {
4234
4234
  );
4235
4235
  const renameSection2 = react.useCallback(
4236
4236
  (sectionId, newName) => {
4237
- const result = chunkUSAJMMF2_js.renameSection(sections, slides, sectionId, newName);
4237
+ const result = chunkSADF35N7_js.renameSection(sections, slides, sectionId, newName);
4238
4238
  setSections(result.sections);
4239
4239
  setSlides(result.slides);
4240
4240
  markDirty();
@@ -4243,7 +4243,7 @@ function useSectionOperations(input) {
4243
4243
  );
4244
4244
  const deleteSection2 = react.useCallback(
4245
4245
  (sectionId) => {
4246
- const result = chunkUSAJMMF2_js.deleteSection(sections, slides, sectionId);
4246
+ const result = chunkSADF35N7_js.deleteSection(sections, slides, sectionId);
4247
4247
  setSections(result.sections);
4248
4248
  setSlides(result.slides);
4249
4249
  markDirty();
@@ -4252,21 +4252,21 @@ function useSectionOperations(input) {
4252
4252
  );
4253
4253
  const moveSectionUp2 = react.useCallback(
4254
4254
  (sectionId) => {
4255
- setSections(chunkUSAJMMF2_js.moveSectionUp(sections, sectionId));
4255
+ setSections(chunkSADF35N7_js.moveSectionUp(sections, sectionId));
4256
4256
  markDirty();
4257
4257
  },
4258
4258
  [sections, setSections, markDirty]
4259
4259
  );
4260
4260
  const moveSectionDown2 = react.useCallback(
4261
4261
  (sectionId) => {
4262
- setSections(chunkUSAJMMF2_js.moveSectionDown(sections, sectionId));
4262
+ setSections(chunkSADF35N7_js.moveSectionDown(sections, sectionId));
4263
4263
  markDirty();
4264
4264
  },
4265
4265
  [sections, setSections, markDirty]
4266
4266
  );
4267
4267
  const moveSlidesToSection2 = react.useCallback(
4268
4268
  (slideIndexes, targetSectionId) => {
4269
- const result = chunkUSAJMMF2_js.moveSlidesToSection(sections, slides, slideIndexes, targetSectionId);
4269
+ const result = chunkSADF35N7_js.moveSlidesToSection(sections, slides, slideIndexes, targetSectionId);
4270
4270
  setSlides(result.slides);
4271
4271
  setSections(result.sections);
4272
4272
  markDirty();
@@ -4285,19 +4285,19 @@ function useSectionOperations(input) {
4285
4285
 
4286
4286
  // src/viewer/hooks/pointer-move-handlers.ts
4287
4287
  function computeResizeGeometry(handle, startX, startY, startWidth, startHeight, dx, dy, snapToGrid, gridSpacingPx) {
4288
- const resized = chunkUSAJMMF2_js.applyResize(
4288
+ const resized = chunkSADF35N7_js.applyResize(
4289
4289
  { x: startX, y: startY, width: startWidth, height: startHeight },
4290
4290
  handle,
4291
4291
  dx,
4292
4292
  dy,
4293
4293
  1,
4294
- { minSize: chunkNFJLF7TX_js.MIN_ELEMENT_SIZE }
4294
+ { minSize: chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE }
4295
4295
  );
4296
4296
  const box = { x: resized.x, y: resized.y, width: resized.width, height: resized.height };
4297
4297
  if (!snapToGrid) {
4298
4298
  return box;
4299
4299
  }
4300
- return chunkUSAJMMF2_js.snapBoxToGrid(box, handle, gridSpacingPx, chunkNFJLF7TX_js.MIN_ELEMENT_SIZE);
4300
+ return chunkSADF35N7_js.snapBoxToGrid(box, handle, gridSpacingPx, chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE);
4301
4301
  }
4302
4302
  function computeAdjustmentValue(startAdjustment, dx, startWidth) {
4303
4303
  const range = startWidth || 200;
@@ -4415,7 +4415,7 @@ function processDragMove(e, drag, editorScale, snapToGrid, snapToShape, gridSpac
4415
4415
  width: el.width,
4416
4416
  height: el.height
4417
4417
  }));
4418
- const snapResult = chunkUSAJMMF2_js.computeSnapToShape(
4418
+ const snapResult = chunkSADF35N7_js.computeSnapToShape(
4419
4419
  targetX,
4420
4420
  targetY,
4421
4421
  primaryEl.width,
@@ -4454,7 +4454,7 @@ function processDragMove(e, drag, editorScale, snapToGrid, snapToShape, gridSpac
4454
4454
  if (live) {
4455
4455
  for (const id of Object.keys(drag.startPositionsById)) {
4456
4456
  const start = drag.startPositionsById[id];
4457
- chunkUSAJMMF2_js.publishLiveGeometry(live.patcher, live.slideId, id, {
4457
+ chunkSADF35N7_js.publishLiveGeometry(live.patcher, live.slideId, id, {
4458
4458
  x: start.x + appliedDx,
4459
4459
  y: start.y + appliedDy
4460
4460
  });
@@ -4488,15 +4488,15 @@ function processResizeMove(e, rs, editorScale, snapToGrid, gridSpacingPx, live)
4488
4488
  if (rs.domEl) {
4489
4489
  rs.domEl.style.left = `${geo.x}px`;
4490
4490
  rs.domEl.style.top = `${geo.y}px`;
4491
- rs.domEl.style.width = `${Math.max(geo.width, chunkNFJLF7TX_js.MIN_ELEMENT_SIZE)}px`;
4492
- rs.domEl.style.height = `${Math.max(geo.height, chunkNFJLF7TX_js.MIN_ELEMENT_SIZE)}px`;
4491
+ rs.domEl.style.width = `${Math.max(geo.width, chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE)}px`;
4492
+ rs.domEl.style.height = `${Math.max(geo.height, chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE)}px`;
4493
4493
  }
4494
4494
  if (live) {
4495
- chunkUSAJMMF2_js.publishLiveGeometry(live.patcher, live.slideId, rs.elementId, {
4495
+ chunkSADF35N7_js.publishLiveGeometry(live.patcher, live.slideId, rs.elementId, {
4496
4496
  x: geo.x,
4497
4497
  y: geo.y,
4498
- width: Math.max(geo.width, chunkNFJLF7TX_js.MIN_ELEMENT_SIZE),
4499
- height: Math.max(geo.height, chunkNFJLF7TX_js.MIN_ELEMENT_SIZE)
4498
+ width: Math.max(geo.width, chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE),
4499
+ height: Math.max(geo.height, chunkQBRZ3VIC_js.MIN_ELEMENT_SIZE)
4500
4500
  });
4501
4501
  }
4502
4502
  }
@@ -4577,13 +4577,13 @@ function processPointerUp(input) {
4577
4577
  if (i !== activeSlideIndex) {
4578
4578
  return s;
4579
4579
  }
4580
- const rerouted = chunkUSAJMMF2_js.rerouteConnectorsForMovedElements(s.elements, movedIds);
4580
+ const rerouted = chunkSADF35N7_js.rerouteConnectorsForMovedElements(s.elements, movedIds);
4581
4581
  if (rerouted.length === 0) {
4582
4582
  return s;
4583
4583
  }
4584
4584
  return {
4585
4585
  ...s,
4586
- elements: chunkUSAJMMF2_js.applyReroutedConnectors(s.elements, rerouted)
4586
+ elements: chunkSADF35N7_js.applyReroutedConnectors(s.elements, rerouted)
4587
4587
  };
4588
4588
  })
4589
4589
  );
@@ -4608,9 +4608,9 @@ function processPointerUp(input) {
4608
4608
  }
4609
4609
  function commitMarquee(marquee, editTemplateMode, templateElements, activeSlide, applySelection, clearSelection) {
4610
4610
  const sourceElements = editTemplateMode ? templateElements : activeSlide?.elements ?? [];
4611
- const hitIds = chunkUSAJMMF2_js.computeMarqueeHitIds(marquee, sourceElements);
4611
+ const hitIds = chunkSADF35N7_js.computeMarqueeHitIds(marquee, sourceElements);
4612
4612
  if (marquee.additive) {
4613
- const merged = chunkUSAJMMF2_js.mergeAdditiveSelection(marquee.baseSelectionIds, hitIds);
4613
+ const merged = chunkSADF35N7_js.mergeAdditiveSelection(marquee.baseSelectionIds, hitIds);
4614
4614
  if (merged.length > 0) {
4615
4615
  applySelection(merged[0], merged);
4616
4616
  } else {
@@ -4633,8 +4633,8 @@ function commitDrag(drag, editTemplateMode, activeSlide, activeSlideIndex, setTe
4633
4633
  }
4634
4634
  return { ...el, x: start.x + dx, y: start.y + dy };
4635
4635
  });
4636
- const rerouted = chunkUSAJMMF2_js.rerouteConnectorsForMovedElements(movedElements, movedIds);
4637
- return chunkUSAJMMF2_js.applyReroutedConnectors(movedElements, rerouted);
4636
+ const rerouted = chunkSADF35N7_js.rerouteConnectorsForMovedElements(movedElements, movedIds);
4637
+ return chunkSADF35N7_js.applyReroutedConnectors(movedElements, rerouted);
4638
4638
  };
4639
4639
  if (editTemplateMode) {
4640
4640
  const slideId = activeSlide?.id;
@@ -4791,9 +4791,9 @@ function useCanvasInteractions(input) {
4791
4791
  return;
4792
4792
  }
4793
4793
  const el = elementLookup.get(editId);
4794
- if (el && chunkUSAJMMF2_js.hasTextProperties(el)) {
4794
+ if (el && chunkSADF35N7_js.hasTextProperties(el)) {
4795
4795
  const committedText = transformCommittedText ? transformCommittedText(inlineEditingText) : inlineEditingText;
4796
- const newSegments = chunkUSAJMMF2_js.remapTextToSegments(committedText, el.textSegments, el.textStyle);
4796
+ const newSegments = chunkSADF35N7_js.remapTextToSegments(committedText, el.textSegments, el.textStyle);
4797
4797
  ops.updateElementById(editId, {
4798
4798
  text: committedText,
4799
4799
  textSegments: newSegments
@@ -4804,7 +4804,7 @@ function useCanvasInteractions(input) {
4804
4804
  setInlineEditingText("");
4805
4805
  };
4806
4806
  const openEquationEditorForElement = (el) => {
4807
- if (!chunkUSAJMMF2_js.hasTextProperties(el)) {
4807
+ if (!chunkSADF35N7_js.hasTextProperties(el)) {
4808
4808
  return false;
4809
4809
  }
4810
4810
  const eqSeg = el.textSegments?.find((seg) => seg.equationXml);
@@ -4834,7 +4834,7 @@ function useCanvasInteractions(input) {
4834
4834
  justInteractedRef.current = false;
4835
4835
  } else {
4836
4836
  const el = elementLookup.get(elementId);
4837
- if (el && chunkUSAJMMF2_js.hasTextProperties(el) && !el.locks?.noTextEdit) {
4837
+ if (el && chunkSADF35N7_js.hasTextProperties(el) && !el.locks?.noTextEdit) {
4838
4838
  if (!openEquationEditorForElement(el)) {
4839
4839
  setInlineEditingElementId(elementId);
4840
4840
  setInlineEditingText(el.text ?? "");
@@ -4853,7 +4853,7 @@ function useCanvasInteractions(input) {
4853
4853
  if (openEquationEditorForElement(el)) {
4854
4854
  return;
4855
4855
  }
4856
- if (chunkUSAJMMF2_js.hasTextProperties(el)) {
4856
+ if (chunkSADF35N7_js.hasTextProperties(el)) {
4857
4857
  setInlineEditingElementId(elementId);
4858
4858
  setInlineEditingText(el.text ?? "");
4859
4859
  }
@@ -5046,7 +5046,7 @@ function createFileHandlers(deps) {
5046
5046
  h = Math.round(h * scale);
5047
5047
  }
5048
5048
  addElement({
5049
- id: chunkUSAJMMF2_js.generateElementId(),
5049
+ id: chunkSADF35N7_js.generateElementId(),
5050
5050
  type: "image",
5051
5051
  x: Math.round((canvasSize.width - w) / 2),
5052
5052
  y: Math.round((canvasSize.height - h) / 2),
@@ -5057,7 +5057,7 @@ function createFileHandlers(deps) {
5057
5057
  };
5058
5058
  img.onerror = () => {
5059
5059
  addElement({
5060
- id: chunkUSAJMMF2_js.generateElementId(),
5060
+ id: chunkSADF35N7_js.generateElementId(),
5061
5061
  type: "image",
5062
5062
  x: 100,
5063
5063
  y: 100,
@@ -5083,7 +5083,7 @@ function createFileHandlers(deps) {
5083
5083
  const elFilePath = file.path;
5084
5084
  const insertMediaElement = (mediaSourceUrl, width, height) => {
5085
5085
  addElement({
5086
- id: chunkUSAJMMF2_js.generateElementId(),
5086
+ id: chunkSADF35N7_js.generateElementId(),
5087
5087
  type: "media",
5088
5088
  mediaType,
5089
5089
  mediaMimeType: file.type || void 0,
@@ -5258,13 +5258,13 @@ function createStructuredElementHandlers(deps) {
5258
5258
  return;
5259
5259
  }
5260
5260
  addElement({
5261
- id: chunkUSAJMMF2_js.generateElementId(),
5261
+ id: chunkSADF35N7_js.generateElementId(),
5262
5262
  type: "smartArt",
5263
5263
  x: 100,
5264
5264
  y: 120,
5265
5265
  width: 600,
5266
5266
  height: 340,
5267
- smartArtData: chunkUSAJMMF2_js.buildSmartArtPresetData(
5267
+ smartArtData: chunkSADF35N7_js.buildSmartArtPresetData(
5268
5268
  layout,
5269
5269
  defaultItems,
5270
5270
  (i) => `node-${Date.now()}-${i}-${Math.random().toString(36).slice(2, 8)}`
@@ -5276,7 +5276,7 @@ function createStructuredElementHandlers(deps) {
5276
5276
  return;
5277
5277
  }
5278
5278
  addElement({
5279
- id: chunkUSAJMMF2_js.generateElementId(),
5279
+ id: chunkSADF35N7_js.generateElementId(),
5280
5280
  type: "shape",
5281
5281
  x: 120,
5282
5282
  y: 200,
@@ -5335,7 +5335,7 @@ function createStructuredElementHandlers(deps) {
5335
5335
  const displayText = value || fieldTexts[fieldType] || fieldType;
5336
5336
  const fieldGuid = `{${crypto.randomUUID().toUpperCase()}}`;
5337
5337
  addElement({
5338
- id: chunkUSAJMMF2_js.generateElementId(),
5338
+ id: chunkSADF35N7_js.generateElementId(),
5339
5339
  type: "shape",
5340
5340
  x: 120,
5341
5341
  y: 200,
@@ -5357,11 +5357,11 @@ function createStructuredElementHandlers(deps) {
5357
5357
  if (!activeSlide) {
5358
5358
  return;
5359
5359
  }
5360
- const preset = chunkUSAJMMF2_js.ACTION_BUTTON_PRESETS.find((p) => p.shapeType === shapeType);
5360
+ const preset = chunkSADF35N7_js.ACTION_BUTTON_PRESETS.find((p) => p.shapeType === shapeType);
5361
5361
  if (!preset) {
5362
5362
  return;
5363
5363
  }
5364
- const defaultPptxAction = chunkUSAJMMF2_js.elementActionToPptxAction({
5364
+ const defaultPptxAction = chunkSADF35N7_js.elementActionToPptxAction({
5365
5365
  trigger: "click",
5366
5366
  type: preset.defaultAction
5367
5367
  });
@@ -5370,7 +5370,7 @@ function createStructuredElementHandlers(deps) {
5370
5370
  defaultPptxAction.highlightClick = true;
5371
5371
  }
5372
5372
  addElement({
5373
- id: chunkUSAJMMF2_js.generateElementId(),
5373
+ id: chunkSADF35N7_js.generateElementId(),
5374
5374
  type: "shape",
5375
5375
  x: 150,
5376
5376
  y: 150,
@@ -5437,14 +5437,14 @@ function useInsertElements(input) {
5437
5437
  return;
5438
5438
  }
5439
5439
  addElement({
5440
- id: chunkUSAJMMF2_js.generateElementId(),
5440
+ id: chunkSADF35N7_js.generateElementId(),
5441
5441
  type: "text",
5442
5442
  x: 100,
5443
5443
  y: 100,
5444
5444
  width: 300,
5445
5445
  height: 60,
5446
5446
  text: "",
5447
- textStyle: { fontSize: chunkNFJLF7TX_js.DEFAULT_TEXT_FONT_SIZE }
5447
+ textStyle: { fontSize: chunkQBRZ3VIC_js.DEFAULT_TEXT_FONT_SIZE }
5448
5448
  });
5449
5449
  };
5450
5450
  const handleAddShape = () => {
@@ -5452,7 +5452,7 @@ function useInsertElements(input) {
5452
5452
  return;
5453
5453
  }
5454
5454
  addElement({
5455
- id: chunkUSAJMMF2_js.generateElementId(),
5455
+ id: chunkSADF35N7_js.generateElementId(),
5456
5456
  type: "shape",
5457
5457
  x: 150,
5458
5458
  y: 150,
@@ -5471,15 +5471,15 @@ function useInsertElements(input) {
5471
5471
  return;
5472
5472
  }
5473
5473
  addElement({
5474
- ...chunkUSAJMMF2_js.newTableElement(chunkNFJLF7TX_js.DEFAULT_TABLE_ROWS, chunkNFJLF7TX_js.DEFAULT_TABLE_COLUMNS, 100, 200),
5475
- id: chunkUSAJMMF2_js.generateElementId()
5474
+ ...chunkSADF35N7_js.newTableElement(chunkQBRZ3VIC_js.DEFAULT_TABLE_ROWS, chunkQBRZ3VIC_js.DEFAULT_TABLE_COLUMNS, 100, 200),
5475
+ id: chunkSADF35N7_js.generateElementId()
5476
5476
  });
5477
5477
  };
5478
5478
  const handleAddChart = (chartKind) => {
5479
5479
  if (!activeSlide) {
5480
5480
  return;
5481
5481
  }
5482
- addElement(chunkUSAJMMF2_js.createDefaultChartElement(chartKind));
5482
+ addElement(chunkSADF35N7_js.createDefaultChartElement(chartKind));
5483
5483
  };
5484
5484
  const structured = createStructuredElementHandlers({
5485
5485
  activeSlide,
@@ -5549,7 +5549,7 @@ function useClipboardHandlers(input) {
5549
5549
  if (!selectedElement) {
5550
5550
  return;
5551
5551
  }
5552
- setClipboardPayload(chunkUSAJMMF2_js.buildElementClipboardPayload(selectedElement, editTemplateMode));
5552
+ setClipboardPayload(chunkSADF35N7_js.buildElementClipboardPayload(selectedElement, editTemplateMode));
5553
5553
  };
5554
5554
  const handleDelete = () => {
5555
5555
  const idsToDelete = effectiveSelectedIds;
@@ -5566,7 +5566,7 @@ function useClipboardHandlers(input) {
5566
5566
  handleDelete();
5567
5567
  };
5568
5568
  const insertClone = (source) => {
5569
- const clone = chunkUSAJMMF2_js.cloneElementForPaste(source, { intoTemplate: editTemplateMode });
5569
+ const clone = chunkSADF35N7_js.cloneElementForPaste(source, { intoTemplate: editTemplateMode });
5570
5570
  ops.updateActiveElements((els) => [...els, clone]);
5571
5571
  ops.applySelection(clone.id);
5572
5572
  history.markDirty();
@@ -5601,7 +5601,7 @@ function resolveShapePath(el) {
5601
5601
  return el.pathData;
5602
5602
  }
5603
5603
  if ("shapeType" in el && typeof el.shapeType === "string") {
5604
- const clipPath = chunkUSAJMMF2_js.getPresetShapeClipPath(el.shapeType);
5604
+ const clipPath = chunkSADF35N7_js.getPresetShapeClipPath(el.shapeType);
5605
5605
  if (clipPath) {
5606
5606
  const svgPath = clipPathToSvgPath(clipPath, el.width, el.height);
5607
5607
  if (svgPath) {
@@ -5652,7 +5652,7 @@ function clipPathToSvgPath(clipPath, width, height) {
5652
5652
  return parts.join(" ");
5653
5653
  }
5654
5654
  function transformPathToGlobal(pathData, el) {
5655
- const polys = chunkUSAJMMF2_js.svgPathToPolygons(pathData);
5655
+ const polys = chunkSADF35N7_js.svgPathToPolygons(pathData);
5656
5656
  if (polys.length === 0) {
5657
5657
  return pathData;
5658
5658
  }
@@ -5672,10 +5672,10 @@ function transformPathToGlobal(pathData, el) {
5672
5672
  y: pt.y * scaleY + el.y
5673
5673
  }))
5674
5674
  );
5675
- return chunkUSAJMMF2_js.polygonsToSvgPath(transformed);
5675
+ return chunkSADF35N7_js.polygonsToSvgPath(transformed);
5676
5676
  }
5677
5677
  function transformPathToLocal(pathData, x, y, _width, _height) {
5678
- const polys = chunkUSAJMMF2_js.svgPathToPolygons(pathData);
5678
+ const polys = chunkSADF35N7_js.svgPathToPolygons(pathData);
5679
5679
  if (polys.length === 0) {
5680
5680
  return pathData;
5681
5681
  }
@@ -5685,10 +5685,10 @@ function transformPathToLocal(pathData, x, y, _width, _height) {
5685
5685
  y: pt.y - y
5686
5686
  }))
5687
5687
  );
5688
- return chunkUSAJMMF2_js.polygonsToSvgPath(transformed);
5688
+ return chunkSADF35N7_js.polygonsToSvgPath(transformed);
5689
5689
  }
5690
5690
  function pathBounds(pathData) {
5691
- const polys = chunkUSAJMMF2_js.svgPathToPolygons(pathData);
5691
+ const polys = chunkSADF35N7_js.svgPathToPolygons(pathData);
5692
5692
  let minX = Infinity;
5693
5693
  let minY = Infinity;
5694
5694
  let maxX = -Infinity;
@@ -5747,7 +5747,7 @@ function useMergeShapesHandler(input) {
5747
5747
  let allFragments = [];
5748
5748
  let remaining = globalPaths[0];
5749
5749
  for (let i = 1; i < globalPaths.length; i++) {
5750
- const frags = chunkUSAJMMF2_js.mergeShapes("fragment", remaining, globalPaths[i]);
5750
+ const frags = chunkSADF35N7_js.mergeShapes("fragment", remaining, globalPaths[i]);
5751
5751
  if (Array.isArray(frags)) {
5752
5752
  allFragments = frags;
5753
5753
  }
@@ -5776,7 +5776,7 @@ function useMergeShapesHandler(input) {
5776
5776
  bounds.height
5777
5777
  );
5778
5778
  const newEl = {
5779
- id: chunkUSAJMMF2_js.generateElementId(),
5779
+ id: chunkSADF35N7_js.generateElementId(),
5780
5780
  type: "shape",
5781
5781
  x: bounds.x,
5782
5782
  y: bounds.y,
@@ -5814,7 +5814,7 @@ function useMergeShapesHandler(input) {
5814
5814
  } else {
5815
5815
  let resultPath = globalPaths[0];
5816
5816
  for (let i = 1; i < globalPaths.length; i++) {
5817
- const result = chunkUSAJMMF2_js.mergeShapes(operation, resultPath, globalPaths[i]);
5817
+ const result = chunkSADF35N7_js.mergeShapes(operation, resultPath, globalPaths[i]);
5818
5818
  if (typeof result === "string") {
5819
5819
  resultPath = result;
5820
5820
  }
@@ -5835,7 +5835,7 @@ function useMergeShapesHandler(input) {
5835
5835
  );
5836
5836
  const primary = targets[0];
5837
5837
  const newEl = {
5838
- id: chunkUSAJMMF2_js.generateElementId(),
5838
+ id: chunkSADF35N7_js.generateElementId(),
5839
5839
  type: "shape",
5840
5840
  x: bounds.x,
5841
5841
  y: bounds.y,
@@ -5898,7 +5898,7 @@ function useGroupAlignLayerHandlers(input) {
5898
5898
  if (ids.length < 2 || !activeSlide) {
5899
5899
  return;
5900
5900
  }
5901
- const { elements, groupId } = chunkUSAJMMF2_js.groupElements(ops.activeElements, ids, chunkUSAJMMF2_js.generateElementId());
5901
+ const { elements, groupId } = chunkSADF35N7_js.groupElements(ops.activeElements, ids, chunkSADF35N7_js.generateElementId());
5902
5902
  if (groupId === null) {
5903
5903
  return;
5904
5904
  }
@@ -5911,12 +5911,12 @@ function useGroupAlignLayerHandlers(input) {
5911
5911
  return;
5912
5912
  }
5913
5913
  const group = selectedElement;
5914
- const intoTemplate = chunkUSAJMMF2_js.isTemplateElementId(group.id);
5914
+ const intoTemplate = chunkSADF35N7_js.isTemplateElementId(group.id);
5915
5915
  const ungrouped = group.children.map((child) => ({
5916
5916
  ...structuredClone(child),
5917
5917
  // Keep child ids in the same store as the group so later edits route
5918
5918
  // correctly: template groups yield template-prefixed child ids.
5919
- id: intoTemplate ? chunkUSAJMMF2_js.makeCloneId(true, child.id || group.id) : child.id || chunkUSAJMMF2_js.generateElementId(),
5919
+ id: intoTemplate ? chunkSADF35N7_js.makeCloneId(true, child.id || group.id) : child.id || chunkSADF35N7_js.generateElementId(),
5920
5920
  x: child.x + group.x,
5921
5921
  y: child.y + group.y
5922
5922
  }));
@@ -5940,7 +5940,7 @@ function useGroupAlignLayerHandlers(input) {
5940
5940
  if (!edge) {
5941
5941
  return;
5942
5942
  }
5943
- const positions = chunkUSAJMMF2_js.alignElements(selectedElements, edge);
5943
+ const positions = chunkSADF35N7_js.alignElements(selectedElements, edge);
5944
5944
  for (const [id, pos] of positions) {
5945
5945
  const el = elementLookup.get(id);
5946
5946
  if (!el) {
@@ -5958,7 +5958,7 @@ function useGroupAlignLayerHandlers(input) {
5958
5958
  if (!distAxis) {
5959
5959
  return;
5960
5960
  }
5961
- const positions = chunkUSAJMMF2_js.distributeElements(selectedElements, distAxis);
5961
+ const positions = chunkSADF35N7_js.distributeElements(selectedElements, distAxis);
5962
5962
  for (const [id, pos] of positions) {
5963
5963
  const el = elementLookup.get(id);
5964
5964
  if (!el) {
@@ -5975,7 +5975,7 @@ function useGroupAlignLayerHandlers(input) {
5975
5975
  }
5976
5976
  const id = selectedElement.id;
5977
5977
  ops.updateActiveElements(
5978
- (els) => direction === "forward" ? chunkUSAJMMF2_js.bringForward(els, id) : direction === "backward" ? chunkUSAJMMF2_js.sendBackward(els, id) : els
5978
+ (els) => direction === "forward" ? chunkSADF35N7_js.bringForward(els, id) : direction === "backward" ? chunkSADF35N7_js.sendBackward(els, id) : els
5979
5979
  );
5980
5980
  history.markDirty();
5981
5981
  };
@@ -5985,7 +5985,7 @@ function useGroupAlignLayerHandlers(input) {
5985
5985
  }
5986
5986
  const id = selectedElement.id;
5987
5987
  ops.updateActiveElements(
5988
- (els) => direction === "front" ? chunkUSAJMMF2_js.bringToFront(els, id) : chunkUSAJMMF2_js.sendToBack(els, id)
5988
+ (els) => direction === "front" ? chunkSADF35N7_js.bringToFront(els, id) : chunkSADF35N7_js.sendToBack(els, id)
5989
5989
  );
5990
5990
  history.markDirty();
5991
5991
  };
@@ -6116,7 +6116,7 @@ function useSlideManagement(input) {
6116
6116
  theme
6117
6117
  } = input;
6118
6118
  const handleAddSlide = () => {
6119
- const newSlide = chunkUSAJMMF2_js.createBlankSlide(slides.length + 1);
6119
+ const newSlide = chunkSADF35N7_js.createBlankSlide(slides.length + 1);
6120
6120
  ops.updateSlides((prev) => {
6121
6121
  const next = [...prev];
6122
6122
  next.splice(activeSlideIndex + 1, 0, newSlide);
@@ -6179,7 +6179,7 @@ function useSlideManagement(input) {
6179
6179
  }
6180
6180
  const clone = {
6181
6181
  ...src,
6182
- id: chunkUSAJMMF2_js.makeSlideId(),
6182
+ id: chunkSADF35N7_js.makeSlideId(),
6183
6183
  elements: src.elements.map((el) => ({
6184
6184
  ...el,
6185
6185
  id: `${el.id}-dup-${Math.random().toString(36).slice(2, 6)}`
@@ -6211,7 +6211,7 @@ function useSlideManagement(input) {
6211
6211
  const handleInsertSlideFromLayout = (layoutPath, layoutName) => {
6212
6212
  const insertAt = activeSlideIndex + 1;
6213
6213
  const draft = {
6214
- ...chunkUSAJMMF2_js.createBlankSlide(slides.length + 1),
6214
+ ...chunkSADF35N7_js.createBlankSlide(slides.length + 1),
6215
6215
  layoutPath,
6216
6216
  ...layoutName ? { layoutName } : {}
6217
6217
  };
@@ -6244,9 +6244,9 @@ function useSlideManagement(input) {
6244
6244
  };
6245
6245
  const handleInsertSlideFromTemplate = (templateId) => {
6246
6246
  const insertAt = activeSlideIndex + 1;
6247
- const draft = chunkUSAJMMF2_js.buildSlideTemplateSlide(templateId, chunkUSAJMMF2_js.makeSlideId(), slides.length + 1, {
6247
+ const draft = chunkSADF35N7_js.buildSlideTemplateSlide(templateId, chunkSADF35N7_js.makeSlideId(), slides.length + 1, {
6248
6248
  ...canvasSize ? { slideWidth: canvasSize.width, slideHeight: canvasSize.height } : {},
6249
- scheme: chunkUSAJMMF2_js.templateSchemeFromTheme(theme?.colorScheme)
6249
+ scheme: chunkSADF35N7_js.templateSchemeFromTheme(theme?.colorScheme)
6250
6250
  });
6251
6251
  ops.updateSlides((prev) => insertSlideFromLayoutUpdater(prev, activeSlideIndex, draft));
6252
6252
  setActiveSlideIndex(insertAt);
@@ -6283,7 +6283,7 @@ function createTableMergeHandlers(input) {
6283
6283
  if (!nextCell || nextCell.hMerge || nextCell.vMerge) {
6284
6284
  return;
6285
6285
  }
6286
- const newTableData = chunkUSAJMMF2_js.mergeCells(
6286
+ const newTableData = chunkSADF35N7_js.mergeCells(
6287
6287
  [
6288
6288
  { row: rowIndex, col: columnIndex },
6289
6289
  { row: rowIndex, col: nextColIdx }
@@ -6291,7 +6291,7 @@ function createTableMergeHandlers(input) {
6291
6291
  td
6292
6292
  );
6293
6293
  const updates = { tableData: newTableData };
6294
- const newRawXml = chunkUSAJMMF2_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
6294
+ const newRawXml = chunkSADF35N7_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
6295
6295
  if (newRawXml) {
6296
6296
  updates.rawXml = newRawXml;
6297
6297
  }
@@ -6317,7 +6317,7 @@ function createTableMergeHandlers(input) {
6317
6317
  if (!targetNextCell || targetNextCell.hMerge || targetNextCell.vMerge) {
6318
6318
  return;
6319
6319
  }
6320
- const newTableData = chunkUSAJMMF2_js.mergeCells(
6320
+ const newTableData = chunkSADF35N7_js.mergeCells(
6321
6321
  [
6322
6322
  { row: rowIndex, col: columnIndex },
6323
6323
  { row: targetNextRowIdx, col: columnIndex }
@@ -6325,7 +6325,7 @@ function createTableMergeHandlers(input) {
6325
6325
  td
6326
6326
  );
6327
6327
  const updates = { tableData: newTableData };
6328
- const newRawXml = chunkUSAJMMF2_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
6328
+ const newRawXml = chunkSADF35N7_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
6329
6329
  if (newRawXml) {
6330
6330
  updates.rawXml = newRawXml;
6331
6331
  }
@@ -6340,9 +6340,9 @@ function createTableMergeHandlers(input) {
6340
6340
  return;
6341
6341
  }
6342
6342
  const td = selectedElement.tableData;
6343
- const newTableData = chunkUSAJMMF2_js.mergeCells(ts.selectedCells, td);
6343
+ const newTableData = chunkSADF35N7_js.mergeCells(ts.selectedCells, td);
6344
6344
  const updates = { tableData: newTableData };
6345
- const newRawXml = chunkUSAJMMF2_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
6345
+ const newRawXml = chunkSADF35N7_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
6346
6346
  if (newRawXml) {
6347
6347
  updates.rawXml = newRawXml;
6348
6348
  }
@@ -6359,9 +6359,9 @@ function createTableMergeHandlers(input) {
6359
6359
  }
6360
6360
  const { rowIndex, columnIndex } = ts;
6361
6361
  const td = selectedElement.tableData;
6362
- const newTableData = chunkUSAJMMF2_js.splitCell(rowIndex, columnIndex, td);
6362
+ const newTableData = chunkSADF35N7_js.splitCell(rowIndex, columnIndex, td);
6363
6363
  const updates = { tableData: newTableData };
6364
- const newRawXml = chunkUSAJMMF2_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
6364
+ const newRawXml = chunkSADF35N7_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
6365
6365
  if (newRawXml) {
6366
6366
  updates.rawXml = newRawXml;
6367
6367
  }
@@ -6405,7 +6405,7 @@ function createTableStructHandlers(input) {
6405
6405
  updates.tableData = { ...el.tableData, rows: newRows };
6406
6406
  }
6407
6407
  if (el.rawXml) {
6408
- const newRawXml = chunkUSAJMMF2_js.updateCellTextInRawXml(el, rowIndex, colIndex, text);
6408
+ const newRawXml = chunkSADF35N7_js.updateCellTextInRawXml(el, rowIndex, colIndex, text);
6409
6409
  if (newRawXml) {
6410
6410
  updates.rawXml = newRawXml;
6411
6411
  }
@@ -6429,7 +6429,7 @@ function createTableStructHandlers(input) {
6429
6429
  const { rowIndex, columnIndex: colIndex } = ts;
6430
6430
  const updates = {};
6431
6431
  if (selectedElement.rawXml) {
6432
- const newRawXml = chunkUSAJMMF2_js.updateCellTextStyleInRawXml(
6432
+ const newRawXml = chunkSADF35N7_js.updateCellTextStyleInRawXml(
6433
6433
  selectedElement,
6434
6434
  rowIndex,
6435
6435
  colIndex,
@@ -6493,9 +6493,9 @@ function createTableStructHandlers(input) {
6493
6493
  return;
6494
6494
  }
6495
6495
  const rowIdx = ts?.rowIndex ?? 0;
6496
- const newTableData = chunkUSAJMMF2_js.insertTableRow(selectedElement.tableData, rowIdx, position);
6496
+ const newTableData = chunkSADF35N7_js.insertTableRow(selectedElement.tableData, rowIdx, position);
6497
6497
  const updates = { tableData: newTableData };
6498
- const newRawXml = chunkUSAJMMF2_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
6498
+ const newRawXml = chunkSADF35N7_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
6499
6499
  if (newRawXml) {
6500
6500
  updates.rawXml = newRawXml;
6501
6501
  }
@@ -6508,12 +6508,12 @@ function createTableStructHandlers(input) {
6508
6508
  }
6509
6509
  const td = selectedElement.tableData;
6510
6510
  const rowIdx = ts?.rowIndex ?? 0;
6511
- const newTableData = chunkUSAJMMF2_js.deleteTableRow(td, rowIdx);
6511
+ const newTableData = chunkSADF35N7_js.deleteTableRow(td, rowIdx);
6512
6512
  if (newTableData === td) {
6513
6513
  return;
6514
6514
  }
6515
6515
  const updates = { tableData: newTableData };
6516
- const newRawXml = chunkUSAJMMF2_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
6516
+ const newRawXml = chunkSADF35N7_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
6517
6517
  if (newRawXml) {
6518
6518
  updates.rawXml = newRawXml;
6519
6519
  }
@@ -6525,9 +6525,9 @@ function createTableStructHandlers(input) {
6525
6525
  return;
6526
6526
  }
6527
6527
  const colIdx = ts?.columnIndex ?? 0;
6528
- const newTableData = chunkUSAJMMF2_js.insertTableColumn(selectedElement.tableData, colIdx, position);
6528
+ const newTableData = chunkSADF35N7_js.insertTableColumn(selectedElement.tableData, colIdx, position);
6529
6529
  const updates = { tableData: newTableData };
6530
- const newRawXml = chunkUSAJMMF2_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
6530
+ const newRawXml = chunkSADF35N7_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
6531
6531
  if (newRawXml) {
6532
6532
  updates.rawXml = newRawXml;
6533
6533
  }
@@ -6540,12 +6540,12 @@ function createTableStructHandlers(input) {
6540
6540
  }
6541
6541
  const td = selectedElement.tableData;
6542
6542
  const colIdx = ts?.columnIndex ?? 0;
6543
- const newTableData = chunkUSAJMMF2_js.deleteTableColumn(td, colIdx);
6543
+ const newTableData = chunkSADF35N7_js.deleteTableColumn(td, colIdx);
6544
6544
  if (newTableData === td) {
6545
6545
  return;
6546
6546
  }
6547
6547
  const updates = { tableData: newTableData };
6548
- const newRawXml = chunkUSAJMMF2_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
6548
+ const newRawXml = chunkSADF35N7_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
6549
6549
  if (newRawXml) {
6550
6550
  updates.rawXml = newRawXml;
6551
6551
  }
@@ -6581,8 +6581,8 @@ async function renderToCanvas(element, options = {}) {
6581
6581
  return html2canvasPro(element, {
6582
6582
  ...options,
6583
6583
  onclone: async (doc, clonedEl) => {
6584
- await chunkUSAJMMF2_js.normalizeColorsForCapture(doc, clonedEl);
6585
- chunkUSAJMMF2_js.preprocessCssForCapture(clonedEl);
6584
+ await chunkSADF35N7_js.normalizeColorsForCapture(doc, clonedEl);
6585
+ chunkSADF35N7_js.preprocessCssForCapture(clonedEl);
6586
6586
  if (typeof userOnClone === "function") {
6587
6587
  userOnClone(doc, clonedEl);
6588
6588
  }
@@ -6638,7 +6638,7 @@ async function exportSlideToPngBlob(slideElement, options = {}) {
6638
6638
  }
6639
6639
  async function exportSlideAsPng(slideElement, slideIndex, options = {}) {
6640
6640
  const blob = await exportSlideToPngBlob(slideElement, options);
6641
- chunkUSAJMMF2_js.downloadBlob(blob, `slide-${slideIndex + 1}.png`);
6641
+ chunkSADF35N7_js.downloadBlob(blob, `slide-${slideIndex + 1}.png`);
6642
6642
  }
6643
6643
  async function copySlideToClipboard(slideElement, options = {}) {
6644
6644
  const blob = await exportSlideToPngBlob(slideElement, options);
@@ -6660,15 +6660,15 @@ async function exportAllSlidesAsPdf(slideStageRef, totalSlides, setActiveSlide,
6660
6660
  continue;
6661
6661
  }
6662
6662
  const canvas = await renderElementToCanvas(stageEl, scale);
6663
- images.push(chunkUSAJMMF2_js.canvasToJpegData(canvas));
6663
+ images.push(chunkSADF35N7_js.canvasToJpegData(canvas));
6664
6664
  }
6665
6665
  onProgress?.(totalSlides, totalSlides);
6666
6666
  setActiveSlide(currentSlideIndex);
6667
6667
  if (images.length === 0) {
6668
6668
  throw new Error(chunkDVZF4ARG_js.translationsEn["pptx.export.errorNoSlidesPdf"]);
6669
6669
  }
6670
- const pdfBlobUrl = chunkNFJLF7TX_js.buildPdfFromImageData(images);
6671
- chunkUSAJMMF2_js.downloadDataUrl(pdfBlobUrl, filename);
6670
+ const pdfBlobUrl = chunkQBRZ3VIC_js.buildPdfFromImageData(images);
6671
+ chunkSADF35N7_js.downloadDataUrl(pdfBlobUrl, filename);
6672
6672
  }
6673
6673
  async function captureAllSlidesAsPngDataUrls(slideStageRef, totalSlides, setActiveSlide, currentSlideIndex, options = {}) {
6674
6674
  const { scale = 2, onProgress } = options;
@@ -6716,8 +6716,8 @@ async function exportAllSlidesAsNotesPdf(slideStageRef, totalSlides, setActiveSl
6716
6716
  if (pages.length === 0) {
6717
6717
  throw new Error(chunkDVZF4ARG_js.translationsEn["pptx.export.errorNoSlidesNotesPdf"]);
6718
6718
  }
6719
- const pdfDataUrl = chunkNFJLF7TX_js.buildNotesPdf(pages);
6720
- chunkUSAJMMF2_js.downloadDataUrl(pdfDataUrl, filename);
6719
+ const pdfDataUrl = chunkQBRZ3VIC_js.buildNotesPdf(pages);
6720
+ chunkSADF35N7_js.downloadDataUrl(pdfDataUrl, filename);
6721
6721
  }
6722
6722
 
6723
6723
  // src/viewer/utils/export-video.ts
@@ -6761,7 +6761,7 @@ async function exportAllSlidesAsVideo(slideStageRef, totalSlides, setActiveSlide
6761
6761
  const fps = 30;
6762
6762
  const stream = recordingCanvas.captureStream(fps);
6763
6763
  const recorder = new MediaRecorder(stream, {
6764
- mimeType: chunkUSAJMMF2_js.pickSupportedMimeType([...chunkUSAJMMF2_js.WEBM_MIME_CANDIDATES]),
6764
+ mimeType: chunkSADF35N7_js.pickSupportedMimeType([...chunkSADF35N7_js.WEBM_MIME_CANDIDATES]),
6765
6765
  videoBitsPerSecond: 5e6
6766
6766
  });
6767
6767
  const chunks = [];
@@ -6784,8 +6784,8 @@ async function exportAllSlidesAsVideo(slideStageRef, totalSlides, setActiveSlide
6784
6784
  const duration = slideTimingsMs?.[i] ?? slideDurationMs;
6785
6785
  ctx.clearRect(0, 0, recordingCanvas.width, recordingCanvas.height);
6786
6786
  ctx.drawImage(slideCanvases[i], 0, 0);
6787
- const frameInterval = chunkUSAJMMF2_js.fpsToFrameIntervalMs(fps);
6788
- const framesNeeded = chunkUSAJMMF2_js.segmentFrameCount(duration, fps);
6787
+ const frameInterval = chunkSADF35N7_js.fpsToFrameIntervalMs(fps);
6788
+ const framesNeeded = chunkSADF35N7_js.segmentFrameCount(duration, fps);
6789
6789
  for (let f = 0; f < framesNeeded; f++) {
6790
6790
  if (signal?.aborted) {
6791
6791
  recorder.stop();
@@ -6834,7 +6834,7 @@ async function exportAllSlidesAsGif(slideStageRef, totalSlides, setActiveSlide,
6834
6834
  if (frames.length === 0) {
6835
6835
  throw new Error(chunkDVZF4ARG_js.translationsEn["pptx.export.errorNoSlidesGif"]);
6836
6836
  }
6837
- const gifBytes = chunkUSAJMMF2_js.encodeGif(frames, Math.round(slideDurationMs / 10));
6837
+ const gifBytes = chunkSADF35N7_js.encodeGif(frames, Math.round(slideDurationMs / 10));
6838
6838
  onProgress?.(totalSlides, totalSlides);
6839
6839
  const buf = new ArrayBuffer(gifBytes.length);
6840
6840
  new Uint8Array(buf).set(gifBytes);
@@ -6888,7 +6888,7 @@ function exportAllSlidesToSvg(data, options = {}) {
6888
6888
  continue;
6889
6889
  }
6890
6890
  onProgress?.(processedCount, data.slides.length);
6891
- let svg = chunkUSAJMMF2_js.SvgExporter.exportSlide(slide, data.width, data.height, svgOptions);
6891
+ let svg = chunkSADF35N7_js.SvgExporter.exportSlide(slide, data.width, data.height, svgOptions);
6892
6892
  if (embedFonts && fontFaces?.length) {
6893
6893
  svg = injectFontFaces(svg, fontFaces);
6894
6894
  }
@@ -6950,7 +6950,7 @@ function useExportSaveAs(input) {
6950
6950
  }
6951
6951
  setExportProgress(70);
6952
6952
  setExportStatusMessage("Writing README...");
6953
- const readme = chunkUSAJMMF2_js.generatePackageReadme(pptxFilename);
6953
+ const readme = chunkSADF35N7_js.generatePackageReadme(pptxFilename);
6954
6954
  pkgFolder.file("README.txt", readme);
6955
6955
  if (abortCtrl.signal.aborted) {
6956
6956
  throw new DOMException("Export cancelled", "AbortError");
@@ -6961,7 +6961,7 @@ function useExportSaveAs(input) {
6961
6961
  setExportProgress(95);
6962
6962
  setExportStatusMessage("Downloading...");
6963
6963
  const baseName = pptxFilename.replace(/\.[^.]+$/u, "");
6964
- chunkUSAJMMF2_js.downloadBlob(zipBlob, `${baseName}-package.zip`);
6964
+ chunkSADF35N7_js.downloadBlob(zipBlob, `${baseName}-package.zip`);
6965
6965
  setExportProgress(100);
6966
6966
  } catch (err) {
6967
6967
  if (err.name !== "AbortError") {
@@ -6984,7 +6984,7 @@ function useExportSaveAs(input) {
6984
6984
  const blob = new Blob([data], {
6985
6985
  type: "application/vnd.openxmlformats-officedocument.presentationml.presentation"
6986
6986
  });
6987
- chunkUSAJMMF2_js.downloadBlob(blob, `${baseName}.${ext}`);
6987
+ chunkSADF35N7_js.downloadBlob(blob, `${baseName}.${ext}`);
6988
6988
  } catch (err) {
6989
6989
  console.error(`[PowerPointViewer] Save as .${ext} failed:`, err);
6990
6990
  }
@@ -6997,14 +6997,14 @@ function useExportSaveAs(input) {
6997
6997
  const pptxGuides = guides.map((g) => ({
6998
6998
  id: g.id,
6999
6999
  orientation: g.axis === "h" ? "horz" : "vert",
7000
- positionEmu: chunkUSAJMMF2_js.guidePxToEmu(g.position)
7000
+ positionEmu: chunkSADF35N7_js.guidePxToEmu(g.position)
7001
7001
  }));
7002
7002
  return {
7003
7003
  ...slide,
7004
7004
  guides: pptxGuides.length > 0 ? pptxGuides : void 0
7005
7005
  };
7006
7006
  });
7007
- const slidesToSave = chunkUSAJMMF2_js.buildSaveSlides(slidesWithGuides, templateElementsBySlideId);
7007
+ const slidesToSave = chunkSADF35N7_js.buildSaveSlides(slidesWithGuides, templateElementsBySlideId);
7008
7008
  const saveOptions = {
7009
7009
  headerFooter,
7010
7010
  presentationProperties,
@@ -7030,11 +7030,11 @@ function useExportSaveAs(input) {
7030
7030
  const handleExportJson = () => {
7031
7031
  const sourceName = filePath ? filePath.replace(/\\/gu, "/").split("/").pop() : void 0;
7032
7032
  const data = {
7033
- slides: chunkUSAJMMF2_js.buildSaveSlides(slides, templateElementsBySlideId),
7033
+ slides: chunkSADF35N7_js.buildSaveSlides(slides, templateElementsBySlideId),
7034
7034
  width: canvasSize.width,
7035
7035
  height: canvasSize.height,
7036
- widthEmu: chunkUSAJMMF2_js.guidePxToEmu(canvasSize.width),
7037
- heightEmu: chunkUSAJMMF2_js.guidePxToEmu(canvasSize.height),
7036
+ widthEmu: chunkSADF35N7_js.guidePxToEmu(canvasSize.width),
7037
+ heightEmu: chunkSADF35N7_js.guidePxToEmu(canvasSize.height),
7038
7038
  theme,
7039
7039
  headerFooter,
7040
7040
  presentationProperties,
@@ -7048,7 +7048,7 @@ function useExportSaveAs(input) {
7048
7048
  handoutMaster
7049
7049
  };
7050
7050
  try {
7051
- chunkUSAJMMF2_js.exportDeckJson(data, sourceName);
7051
+ chunkSADF35N7_js.exportDeckJson(data, sourceName);
7052
7052
  } catch (err) {
7053
7053
  console.error("[PowerPointViewer] JSON export failed:", err);
7054
7054
  }
@@ -7088,7 +7088,7 @@ function safeConfirm(message) {
7088
7088
  }
7089
7089
  }
7090
7090
  function downloadBlob2(blob, filename) {
7091
- chunkUSAJMMF2_js.downloadBlob(blob, chunkUSAJMMF2_js.sanitizeDownloadFilename(filename));
7091
+ chunkSADF35N7_js.downloadBlob(blob, chunkSADF35N7_js.sanitizeDownloadFilename(filename));
7092
7092
  }
7093
7093
 
7094
7094
  // src/viewer/hooks/useExportHandlers.ts
@@ -7194,21 +7194,21 @@ function useExportHandlers(input) {
7194
7194
  {
7195
7195
  scale: 2,
7196
7196
  onProgress: (current, total) => {
7197
- setExportProgress(chunkUSAJMMF2_js.slideProgressPercent(current, total));
7198
- setExportStatusMessage(chunkUSAJMMF2_js.slideStatusLabel("Rendering", current, total));
7197
+ setExportProgress(chunkSADF35N7_js.slideProgressPercent(current, total));
7198
+ setExportStatusMessage(chunkSADF35N7_js.slideStatusLabel("Rendering", current, total));
7199
7199
  },
7200
7200
  signal: abortCtrl.signal
7201
7201
  }
7202
7202
  );
7203
- setExportProgress(chunkUSAJMMF2_js.EXPORT_ASSEMBLING_PERCENT);
7203
+ setExportProgress(chunkSADF35N7_js.EXPORT_ASSEMBLING_PERCENT);
7204
7204
  setExportStatusMessage("Building PDF...");
7205
7205
  await new Promise((r) => {
7206
7206
  setTimeout(r, 100);
7207
7207
  });
7208
- setExportProgress(chunkUSAJMMF2_js.EXPORT_DONE_PERCENT);
7208
+ setExportProgress(chunkSADF35N7_js.EXPORT_DONE_PERCENT);
7209
7209
  setExportStatusMessage("Done!");
7210
7210
  } catch (err) {
7211
- if (!chunkUSAJMMF2_js.isExportAbortError(err)) {
7211
+ if (!chunkSADF35N7_js.isExportAbortError(err)) {
7212
7212
  console.error("[PowerPointViewer] PDF export failed:", err);
7213
7213
  }
7214
7214
  } finally {
@@ -7238,21 +7238,21 @@ function useExportHandlers(input) {
7238
7238
  {
7239
7239
  scale: 2,
7240
7240
  onProgress: (current, total) => {
7241
- setExportProgress(chunkUSAJMMF2_js.slideProgressPercent(current, total));
7242
- setExportStatusMessage(chunkUSAJMMF2_js.slideStatusLabel("Rendering", current, total));
7241
+ setExportProgress(chunkSADF35N7_js.slideProgressPercent(current, total));
7242
+ setExportStatusMessage(chunkSADF35N7_js.slideStatusLabel("Rendering", current, total));
7243
7243
  },
7244
7244
  signal: abortCtrl.signal
7245
7245
  }
7246
7246
  );
7247
- setExportProgress(chunkUSAJMMF2_js.EXPORT_ASSEMBLING_PERCENT);
7247
+ setExportProgress(chunkSADF35N7_js.EXPORT_ASSEMBLING_PERCENT);
7248
7248
  setExportStatusMessage("Building PDF...");
7249
7249
  await new Promise((r) => {
7250
7250
  setTimeout(r, 100);
7251
7251
  });
7252
- setExportProgress(chunkUSAJMMF2_js.EXPORT_DONE_PERCENT);
7252
+ setExportProgress(chunkSADF35N7_js.EXPORT_DONE_PERCENT);
7253
7253
  setExportStatusMessage("Done!");
7254
7254
  } catch (err) {
7255
- if (!chunkUSAJMMF2_js.isExportAbortError(err)) {
7255
+ if (!chunkSADF35N7_js.isExportAbortError(err)) {
7256
7256
  console.error("[PowerPointViewer] Notes PDF export failed:", err);
7257
7257
  }
7258
7258
  } finally {
@@ -7293,22 +7293,22 @@ function useExportHandlers(input) {
7293
7293
  scale: 1,
7294
7294
  slideDurationMs: 3e3,
7295
7295
  onProgress: (current, total) => {
7296
- setExportProgress(chunkUSAJMMF2_js.slideProgressPercent(current, total, 45));
7297
- setExportStatusMessage(chunkUSAJMMF2_js.slideStatusLabel("Capturing", current, total));
7296
+ setExportProgress(chunkSADF35N7_js.slideProgressPercent(current, total, 45));
7297
+ setExportStatusMessage(chunkSADF35N7_js.slideStatusLabel("Capturing", current, total));
7298
7298
  },
7299
7299
  onRecordProgress: (current, total) => {
7300
- setExportProgress(chunkUSAJMMF2_js.recordProgressPercent(current, total));
7301
- setExportStatusMessage(chunkUSAJMMF2_js.slideStatusLabel("Recording", current, total));
7300
+ setExportProgress(chunkSADF35N7_js.recordProgressPercent(current, total));
7301
+ setExportStatusMessage(chunkSADF35N7_js.slideStatusLabel("Recording", current, total));
7302
7302
  },
7303
7303
  signal: abortCtrl.signal
7304
7304
  }
7305
7305
  );
7306
- setExportProgress(chunkUSAJMMF2_js.EXPORT_ASSEMBLING_PERCENT);
7306
+ setExportProgress(chunkSADF35N7_js.EXPORT_ASSEMBLING_PERCENT);
7307
7307
  setExportStatusMessage("Saving file...");
7308
7308
  downloadBlob2(blob, "presentation.webm");
7309
- setExportProgress(chunkUSAJMMF2_js.EXPORT_DONE_PERCENT);
7309
+ setExportProgress(chunkSADF35N7_js.EXPORT_DONE_PERCENT);
7310
7310
  } catch (err) {
7311
- if (!chunkUSAJMMF2_js.isExportAbortError(err)) {
7311
+ if (!chunkSADF35N7_js.isExportAbortError(err)) {
7312
7312
  console.error("[PowerPointViewer] Video export failed:", err);
7313
7313
  }
7314
7314
  } finally {
@@ -7336,18 +7336,18 @@ function useExportHandlers(input) {
7336
7336
  scale: 0.5,
7337
7337
  slideDurationMs: 2e3,
7338
7338
  onProgress: (current, total) => {
7339
- setExportProgress(chunkUSAJMMF2_js.slideProgressPercent(current, total));
7340
- setExportStatusMessage(chunkUSAJMMF2_js.slideStatusLabel("Encoding", current, total));
7339
+ setExportProgress(chunkSADF35N7_js.slideProgressPercent(current, total));
7340
+ setExportStatusMessage(chunkSADF35N7_js.slideStatusLabel("Encoding", current, total));
7341
7341
  },
7342
7342
  signal: abortCtrl.signal
7343
7343
  }
7344
7344
  );
7345
- setExportProgress(chunkUSAJMMF2_js.EXPORT_ASSEMBLING_PERCENT);
7345
+ setExportProgress(chunkSADF35N7_js.EXPORT_ASSEMBLING_PERCENT);
7346
7346
  setExportStatusMessage("Saving file...");
7347
7347
  downloadBlob2(blob, "presentation.gif");
7348
- setExportProgress(chunkUSAJMMF2_js.EXPORT_DONE_PERCENT);
7348
+ setExportProgress(chunkSADF35N7_js.EXPORT_DONE_PERCENT);
7349
7349
  } catch (err) {
7350
- if (!chunkUSAJMMF2_js.isExportAbortError(err)) {
7350
+ if (!chunkSADF35N7_js.isExportAbortError(err)) {
7351
7351
  console.error("[PowerPointViewer] GIF export failed:", err);
7352
7352
  }
7353
7353
  } finally {
@@ -7388,7 +7388,7 @@ function openPrintWindow(title, bodyHtml, orientation, colorFilter, frameSlides)
7388
7388
  }
7389
7389
  printWindow.document.open();
7390
7390
  printWindow.document.write(
7391
- chunkUSAJMMF2_js.buildPrintHtmlDocument({ title, bodyHtml, orientation, colorFilter, frameSlides })
7391
+ chunkSADF35N7_js.buildPrintHtmlDocument({ title, bodyHtml, orientation, colorFilter, frameSlides })
7392
7392
  );
7393
7393
  printWindow.document.close();
7394
7394
  printWindow.focus();
@@ -7449,7 +7449,7 @@ function usePrintHandlers(input) {
7449
7449
  if (svgs.length === 0) {
7450
7450
  return;
7451
7451
  }
7452
- const printDoc = chunkUSAJMMF2_js.buildPrintDocument(svgs, pptxData.width, pptxData.height, {
7452
+ const printDoc = chunkSADF35N7_js.buildPrintDocument(svgs, pptxData.width, pptxData.height, {
7453
7453
  title: "Slides (Vector)",
7454
7454
  orientation: settings.orientation,
7455
7455
  colorFilter
@@ -7485,7 +7485,7 @@ function usePrintHandlers(input) {
7485
7485
  if (settings.printWhat === "outline") {
7486
7486
  openPrintWindow(
7487
7487
  "Outline",
7488
- `<div class="outline-page">${chunkUSAJMMF2_js.buildOutlineHtml(slideIndices, slides)}</div>`,
7488
+ `<div class="outline-page">${chunkSADF35N7_js.buildOutlineHtml(slideIndices, slides)}</div>`,
7489
7489
  settings.orientation,
7490
7490
  colorFilter,
7491
7491
  settings.frameSlides
@@ -7510,7 +7510,7 @@ function usePrintHandlers(input) {
7510
7510
  if (settings.printWhat === "slides") {
7511
7511
  openPrintWindow(
7512
7512
  "Slides",
7513
- chunkUSAJMMF2_js.buildSlidesHtml(slideImages, slideIndices),
7513
+ chunkSADF35N7_js.buildSlidesHtml(slideImages, slideIndices),
7514
7514
  settings.orientation,
7515
7515
  colorFilter,
7516
7516
  settings.frameSlides
@@ -7520,7 +7520,7 @@ function usePrintHandlers(input) {
7520
7520
  if (settings.printWhat === "notes") {
7521
7521
  openPrintWindow(
7522
7522
  "Notes Pages",
7523
- chunkUSAJMMF2_js.buildNotesHtml(slideImages, slideIndices, slides),
7523
+ chunkSADF35N7_js.buildNotesHtml(slideImages, slideIndices, slides),
7524
7524
  "portrait",
7525
7525
  colorFilter,
7526
7526
  settings.frameSlides
@@ -7531,7 +7531,7 @@ function usePrintHandlers(input) {
7531
7531
  const spp = settings.slidesPerPage;
7532
7532
  openPrintWindow(
7533
7533
  `Handout ${spp} per page`,
7534
- chunkUSAJMMF2_js.buildHandoutsHtml(slideImages, slideIndices, spp),
7534
+ chunkSADF35N7_js.buildHandoutsHtml(slideImages, slideIndices, spp),
7535
7535
  "portrait",
7536
7536
  colorFilter,
7537
7537
  settings.frameSlides
@@ -7595,8 +7595,8 @@ function useThemeHandlers(input) {
7595
7595
  return;
7596
7596
  }
7597
7597
  await handler.updateThemeColorScheme(colorScheme);
7598
- const previousMap = theme?.colorScheme ? chunkUSAJMMF2_js.buildThemeColorMap(theme.colorScheme) : {};
7599
- setSlides((prev) => chunkUSAJMMF2_js.reResolveSlideColors(prev, previousMap, colorScheme));
7598
+ const previousMap = theme?.colorScheme ? chunkSADF35N7_js.buildThemeColorMap(theme.colorScheme) : {};
7599
+ setSlides((prev) => chunkSADF35N7_js.reResolveSlideColors(prev, previousMap, colorScheme));
7600
7600
  setTheme((prev) => prev ? { ...prev, colorScheme } : { colorScheme });
7601
7601
  bumpHistory();
7602
7602
  history.markDirty();
@@ -7701,7 +7701,7 @@ function useThemeSwitching(input) {
7701
7701
  }
7702
7702
  try {
7703
7703
  await handler.applyTheme(preset.colorScheme, preset.fontScheme, preset.name);
7704
- const newData = chunkUSAJMMF2_js.applyThemeToData(data, preset.colorScheme, preset.fontScheme, preset.name);
7704
+ const newData = chunkSADF35N7_js.applyThemeToData(data, preset.colorScheme, preset.fontScheme, preset.name);
7705
7705
  onDataChange(newData);
7706
7706
  onThemeChanged?.(preset);
7707
7707
  } catch (error) {
@@ -7718,7 +7718,7 @@ function useThemeSwitching(input) {
7718
7718
  }
7719
7719
  try {
7720
7720
  await handler.applyTheme(colorScheme, fontScheme ?? {}, themeName);
7721
- const newData = chunkUSAJMMF2_js.applyThemeToData(data, colorScheme, fontScheme, themeName);
7721
+ const newData = chunkSADF35N7_js.applyThemeToData(data, colorScheme, fontScheme, themeName);
7722
7722
  onDataChange(newData);
7723
7723
  } catch (error) {
7724
7724
  console.error("Failed to switch to custom theme:", error);
@@ -7730,12 +7730,12 @@ function useThemeSwitching(input) {
7730
7730
  if (!data?.theme?.colorScheme) {
7731
7731
  return void 0;
7732
7732
  }
7733
- return chunkUSAJMMF2_js.THEME_PRESETS.find(
7734
- (p) => chunkUSAJMMF2_js.themeColorSchemesEqual(data.theme?.colorScheme, p.colorScheme)
7733
+ return chunkSADF35N7_js.THEME_PRESETS.find(
7734
+ (p) => chunkSADF35N7_js.themeColorSchemesEqual(data.theme?.colorScheme, p.colorScheme)
7735
7735
  );
7736
7736
  }, [data?.theme?.colorScheme]);
7737
7737
  return {
7738
- presets: chunkUSAJMMF2_js.THEME_PRESETS,
7738
+ presets: chunkSADF35N7_js.THEME_PRESETS,
7739
7739
  switchToPreset,
7740
7740
  switchToCustom,
7741
7741
  currentPreset
@@ -7810,7 +7810,7 @@ function usePropertyHandlers(input) {
7810
7810
  }
7811
7811
  try {
7812
7812
  const ab = await file.arrayBuffer();
7813
- const h = new chunkUSAJMMF2_js.PptxHandler();
7813
+ const h = new chunkSADF35N7_js.PptxHandler();
7814
7814
  const other = await h.load(ab);
7815
7815
  if (!other) {
7816
7816
  return;
@@ -7820,7 +7820,7 @@ function usePropertyHandlers(input) {
7820
7820
  width: canvasSize.width,
7821
7821
  height: canvasSize.height
7822
7822
  };
7823
- setCompareResult(chunkUSAJMMF2_js.comparePresentation(cur, other));
7823
+ setCompareResult(chunkSADF35N7_js.comparePresentation(cur, other));
7824
7824
  setIsComparePanelOpen(true);
7825
7825
  } catch (err) {
7826
7826
  console.warn("Compare failed:", err);
@@ -7837,7 +7837,7 @@ function usePropertyHandlers(input) {
7837
7837
  if (!diff || diff.status === "unchanged") {
7838
7838
  return;
7839
7839
  }
7840
- setSlides((prev) => chunkUSAJMMF2_js.applyAcceptSlide(prev, diff));
7840
+ setSlides((prev) => chunkSADF35N7_js.applyAcceptSlide(prev, diff));
7841
7841
  setIsDirty(true);
7842
7842
  },
7843
7843
  [compareResult, setSlides, setIsDirty]
@@ -7848,10 +7848,10 @@ function usePropertyHandlers(input) {
7848
7848
  if (!compareResult) {
7849
7849
  return;
7850
7850
  }
7851
- setSlides((prev) => chunkUSAJMMF2_js.applyAcceptAllSlides(prev, compareResult));
7851
+ setSlides((prev) => chunkSADF35N7_js.applyAcceptAllSlides(prev, compareResult));
7852
7852
  setIsDirty(true);
7853
7853
  }, [compareResult, setSlides, setIsDirty]);
7854
- const usedFontFamilies = react.useMemo(() => chunkUSAJMMF2_js.collectUsedFonts(slides), [slides]);
7854
+ const usedFontFamilies = react.useMemo(() => chunkSADF35N7_js.collectUsedFonts(slides), [slides]);
7855
7855
  return {
7856
7856
  handleUpdateNotes,
7857
7857
  handleUpdateSlide,
@@ -7970,7 +7970,7 @@ function useIsMobile(input) {
7970
7970
  const containerRef = input?.containerRef;
7971
7971
  const isTouchDevice = react.useSyncExternalStore(
7972
7972
  subscribeTouchCapability,
7973
- chunkUSAJMMF2_js.detectTouchDevice,
7973
+ chunkSADF35N7_js.detectTouchDevice,
7974
7974
  () => false
7975
7975
  // server snapshot
7976
7976
  );
@@ -7986,7 +7986,7 @@ function useIsMobile(input) {
7986
7986
  }
7987
7987
  return containerRef?.current?.clientHeight ?? window.innerHeight;
7988
7988
  });
7989
- const [orientation, setOrientation] = react.useState(chunkUSAJMMF2_js.detectOrientation);
7989
+ const [orientation, setOrientation] = react.useState(chunkSADF35N7_js.detectOrientation);
7990
7990
  const [isVirtualKeyboardOpen, setIsVirtualKeyboardOpen] = react.useState(false);
7991
7991
  const [initialViewportHeight] = react.useState(
7992
7992
  () => typeof window !== "undefined" ? window.innerHeight : 800
@@ -8030,7 +8030,7 @@ function useIsMobile(input) {
8030
8030
  return;
8031
8031
  }
8032
8032
  const handleOrientationChange = () => {
8033
- setOrientation(chunkUSAJMMF2_js.detectOrientation());
8033
+ setOrientation(chunkSADF35N7_js.detectOrientation());
8034
8034
  };
8035
8035
  if (screen.orientation) {
8036
8036
  screen.orientation.addEventListener("change", handleOrientationChange);
@@ -8060,9 +8060,9 @@ function useIsMobile(input) {
8060
8060
  window.addEventListener("resize", handleResize);
8061
8061
  return () => window.removeEventListener("resize", handleResize);
8062
8062
  }, [isTouchDevice, initialViewportHeight]);
8063
- const isMobile = chunkUSAJMMF2_js.isMobileViewport(containerWidth, containerHeight, isTouchDevice);
8064
- const isTablet = !isMobile && containerWidth >= chunkUSAJMMF2_js.MOBILE_BREAKPOINT && containerWidth < chunkUSAJMMF2_js.TABLET_BREAKPOINT;
8065
- const isDesktop = !isMobile && containerWidth >= chunkUSAJMMF2_js.TABLET_BREAKPOINT;
8063
+ const isMobile = chunkSADF35N7_js.isMobileViewport(containerWidth, containerHeight, isTouchDevice);
8064
+ const isTablet = !isMobile && containerWidth >= chunkSADF35N7_js.MOBILE_BREAKPOINT && containerWidth < chunkSADF35N7_js.TABLET_BREAKPOINT;
8065
+ const isDesktop = !isMobile && containerWidth >= chunkSADF35N7_js.TABLET_BREAKPOINT;
8066
8066
  return {
8067
8067
  isMobile,
8068
8068
  isTablet,
@@ -8123,11 +8123,11 @@ function useViewerDialogs(input) {
8123
8123
  );
8124
8124
  const [embedFontsEnabled, setEmbedFontsEnabled] = react.useState(false);
8125
8125
  const [isNarrowViewport, setIsNarrowViewport] = react.useState(
8126
- () => typeof window !== "undefined" ? chunkUSAJMMF2_js.isMobileViewport(window.innerWidth, window.innerHeight, viewportIsTouch()) : false
8126
+ () => typeof window !== "undefined" ? chunkSADF35N7_js.isMobileViewport(window.innerWidth, window.innerHeight, viewportIsTouch()) : false
8127
8127
  );
8128
8128
  react.useEffect(() => {
8129
8129
  const handleWindow = () => setIsNarrowViewport(
8130
- chunkUSAJMMF2_js.isMobileViewport(window.innerWidth, window.innerHeight, viewportIsTouch())
8130
+ chunkSADF35N7_js.isMobileViewport(window.innerWidth, window.innerHeight, viewportIsTouch())
8131
8131
  );
8132
8132
  let observer = null;
8133
8133
  let raf = 0;
@@ -8141,12 +8141,12 @@ function useViewerDialogs(input) {
8141
8141
  const entry = entries[0];
8142
8142
  if (entry) {
8143
8143
  setIsNarrowViewport(
8144
- chunkUSAJMMF2_js.isMobileViewport(entry.contentRect.width, entry.contentRect.height, viewportIsTouch())
8144
+ chunkSADF35N7_js.isMobileViewport(entry.contentRect.width, entry.contentRect.height, viewportIsTouch())
8145
8145
  );
8146
8146
  }
8147
8147
  });
8148
8148
  observer.observe(el);
8149
- setIsNarrowViewport(chunkUSAJMMF2_js.isMobileViewport(el.clientWidth, el.clientHeight, viewportIsTouch()));
8149
+ setIsNarrowViewport(chunkSADF35N7_js.isMobileViewport(el.clientWidth, el.clientHeight, viewportIsTouch()));
8150
8150
  };
8151
8151
  attach();
8152
8152
  window.addEventListener("resize", handleWindow);
@@ -8304,20 +8304,20 @@ function useViewerDialogs(input) {
8304
8304
  }
8305
8305
  function computeGridSpacingPx(presentationGridSpacing) {
8306
8306
  if (presentationGridSpacing) {
8307
- const px = Math.round(presentationGridSpacing.cx / chunkNFJLF7TX_js.EMU_PER_PX);
8307
+ const px = Math.round(presentationGridSpacing.cx / chunkQBRZ3VIC_js.EMU_PER_PX);
8308
8308
  if (px > 0) {
8309
8309
  return px;
8310
8310
  }
8311
8311
  }
8312
- return chunkNFJLF7TX_js.GRID_SIZE;
8312
+ return chunkQBRZ3VIC_js.GRID_SIZE;
8313
8313
  }
8314
8314
  function computeVisibleSlideIndexes(slides, activeCustomShowId, customShows) {
8315
8315
  const activeShow = activeCustomShowId ? customShows.find((show) => show.id === activeCustomShowId) : void 0;
8316
- return chunkUSAJMMF2_js.resolveShowSlideIndexes(slides, activeShow);
8316
+ return chunkSADF35N7_js.resolveShowSlideIndexes(slides, activeShow);
8317
8317
  }
8318
8318
  function computeSlideSectionGroups(slides, sections) {
8319
- return chunkUSAJMMF2_js.groupSlidesBySection(sections, slides).map((group) => ({
8320
- id: group.section?.id ?? (sections.length > 0 ? chunkNFJLF7TX_js.UNGROUPED_SECTION_ID : "default"),
8319
+ return chunkSADF35N7_js.groupSlidesBySection(sections, slides).map((group) => ({
8320
+ id: group.section?.id ?? (sections.length > 0 ? chunkQBRZ3VIC_js.UNGROUPED_SECTION_ID : "default"),
8321
8321
  label: group.section?.name ?? (sections.length > 0 ? "Ungrouped Slides" : "Slides"),
8322
8322
  slideIndexes: group.slideIndexes,
8323
8323
  ...group.section?.color !== void 0 ? { color: group.section.color } : {},
@@ -8372,7 +8372,7 @@ function useDerivedSlideState(input) {
8372
8372
  );
8373
8373
  const slideSectionGroups = react.useMemo(
8374
8374
  () => computeSlideSectionGroups(slides, sections).map((group) => {
8375
- if (group.id === chunkNFJLF7TX_js.UNGROUPED_SECTION_ID && group.label === "Ungrouped Slides") {
8375
+ if (group.id === chunkQBRZ3VIC_js.UNGROUPED_SECTION_ID && group.label === "Ungrouped Slides") {
8376
8376
  return { ...group, label: t("pptx.slides.ungroupedSlides") };
8377
8377
  }
8378
8378
  if (group.id === "default" && group.label === "Slides") {
@@ -8475,13 +8475,13 @@ function useAnnotationHandlers(input) {
8475
8475
  }, [annotations, setMode, setSlides, history]);
8476
8476
  const handleSetMode = react.useCallback(
8477
8477
  (nextMode) => {
8478
- if (mode === "present" && nextMode !== "present" && !chunkUSAJMMF2_js.mayLeaveSlideShow()) {
8478
+ if (mode === "present" && nextMode !== "present" && !chunkSADF35N7_js.mayLeaveSlideShow()) {
8479
8479
  return;
8480
8480
  }
8481
8481
  if (nextMode === "present") {
8482
8482
  presentation.enterPresentMode();
8483
8483
  } else if (mode === "present" && annotations.hasAnyAnnotations) {
8484
- chunkUSAJMMF2_js.stopAllPersistentAudio();
8484
+ chunkSADF35N7_js.stopAllPersistentAudio();
8485
8485
  pendingModeAfterAnnotationsRef.current = nextMode;
8486
8486
  if (promptKeepInkAnnotations) {
8487
8487
  setShowKeepAnnotationsDialog(true);
@@ -8490,7 +8490,7 @@ function useAnnotationHandlers(input) {
8490
8490
  }
8491
8491
  } else {
8492
8492
  if (mode === "present") {
8493
- chunkUSAJMMF2_js.stopAllPersistentAudio();
8493
+ chunkSADF35N7_js.stopAllPersistentAudio();
8494
8494
  }
8495
8495
  setMode(nextMode);
8496
8496
  }
@@ -8556,13 +8556,13 @@ function useSerialize(input) {
8556
8556
  let processedSlide = slide;
8557
8557
  if (pendingEditId) {
8558
8558
  const updatedElements = slide.elements.map((el) => {
8559
- if (el.id !== pendingEditId || !chunkUSAJMMF2_js.hasTextProperties(el)) {
8559
+ if (el.id !== pendingEditId || !chunkSADF35N7_js.hasTextProperties(el)) {
8560
8560
  return el;
8561
8561
  }
8562
8562
  return {
8563
8563
  ...el,
8564
8564
  text: pendingEditText,
8565
- textSegments: chunkUSAJMMF2_js.remapTextToSegments(pendingEditText, el.textSegments, el.textStyle)
8565
+ textSegments: chunkSADF35N7_js.remapTextToSegments(pendingEditText, el.textSegments, el.textStyle)
8566
8566
  };
8567
8567
  });
8568
8568
  if (updatedElements.some((el, i) => el !== slide.elements[i])) {
@@ -8575,14 +8575,14 @@ function useSerialize(input) {
8575
8575
  const pptxGuides = guides.map((g) => ({
8576
8576
  id: g.id,
8577
8577
  orientation: g.axis === "h" ? "horz" : "vert",
8578
- positionEmu: chunkUSAJMMF2_js.guidePxToEmu(g.position)
8578
+ positionEmu: chunkSADF35N7_js.guidePxToEmu(g.position)
8579
8579
  }));
8580
8580
  return {
8581
8581
  ...processedSlide,
8582
8582
  guides: pptxGuides.length > 0 ? pptxGuides : void 0
8583
8583
  };
8584
8584
  });
8585
- const slidesToSave = chunkUSAJMMF2_js.buildSaveSlides(slidesWithGuides, templateElementsBySlideId);
8585
+ const slidesToSave = chunkSADF35N7_js.buildSaveSlides(slidesWithGuides, templateElementsBySlideId);
8586
8586
  const saveOptions = {
8587
8587
  headerFooter,
8588
8588
  presentationProperties,
@@ -8751,7 +8751,7 @@ function usePresentationSetup(input) {
8751
8751
  containerRef,
8752
8752
  content,
8753
8753
  onSetMode: (nextMode) => {
8754
- if (mode === "present" && nextMode !== "present" && !chunkUSAJMMF2_js.mayLeaveSlideShow()) {
8754
+ if (mode === "present" && nextMode !== "present" && !chunkSADF35N7_js.mayLeaveSlideShow()) {
8755
8755
  return;
8756
8756
  }
8757
8757
  if (mode === "present" && nextMode !== "present" && annotations.hasAnyAnnotations && promptKeepInkAnnotations) {
@@ -8759,7 +8759,7 @@ function usePresentationSetup(input) {
8759
8759
  setShowKeepAnnotationsDialog(true);
8760
8760
  } else {
8761
8761
  if (mode === "present" && nextMode !== "present") {
8762
- chunkUSAJMMF2_js.stopAllPersistentAudio();
8762
+ chunkSADF35N7_js.stopAllPersistentAudio();
8763
8763
  stopAnimationSound();
8764
8764
  }
8765
8765
  setMode(nextMode);
@@ -8813,10 +8813,10 @@ function usePresentationSetup(input) {
8813
8813
  onToggleInkMarkup: () => annotations.setInkMarkupVisible(!annotations.inkMarkupVisible),
8814
8814
  onToggleToolbar: () => annotations.setToolbarVisible(!annotations.toolbarVisible),
8815
8815
  onSaveRehearsalTimings: (timings) => {
8816
- setSlides((prev) => chunkUSAJMMF2_js.applyRehearsalTimings(prev, timings));
8816
+ setSlides((prev) => chunkSADF35N7_js.applyRehearsalTimings(prev, timings));
8817
8817
  history.markDirty();
8818
8818
  },
8819
- loopContinuously: chunkUSAJMMF2_js.shouldLoopContinuously(presentationProperties),
8819
+ loopContinuously: chunkSADF35N7_js.shouldLoopContinuously(presentationProperties),
8820
8820
  showWithAnimation: presentationProperties.showWithAnimation,
8821
8821
  useTimings: presentationProperties.advanceMode !== "manual",
8822
8822
  endWithBlackSlide
@@ -8981,7 +8981,7 @@ function useEditorOperations(input) {
8981
8981
  const { formatPainterActive, setFormatPainterActive, elementLookup } = state;
8982
8982
  react.useEffect(() => {
8983
8983
  if (formatPainterActive && !prevFormatPainterRef.current && selectedElement) {
8984
- copiedFormatRef.current = chunkUSAJMMF2_js.copyFormatFromElement(selectedElement);
8984
+ copiedFormatRef.current = chunkSADF35N7_js.copyFormatFromElement(selectedElement);
8985
8985
  } else if (!formatPainterActive) {
8986
8986
  copiedFormatRef.current = null;
8987
8987
  }
@@ -9007,12 +9007,12 @@ function useEditorOperations(input) {
9007
9007
  e.stopPropagation();
9008
9008
  const element = elementLookup.get(elementId);
9009
9009
  if (element) {
9010
- const updated = chunkUSAJMMF2_js.applyFormatToElement(element, copiedFormatRef.current);
9010
+ const updated = chunkSADF35N7_js.applyFormatToElement(element, copiedFormatRef.current);
9011
9011
  const updates = {};
9012
- if (chunkUSAJMMF2_js.hasShapeProperties(updated)) {
9012
+ if (chunkSADF35N7_js.hasShapeProperties(updated)) {
9013
9013
  updates.shapeStyle = updated.shapeStyle;
9014
9014
  }
9015
- if (chunkUSAJMMF2_js.hasTextProperties(updated)) {
9015
+ if (chunkSADF35N7_js.hasTextProperties(updated)) {
9016
9016
  updates.textStyle = updated.textStyle;
9017
9017
  }
9018
9018
  ops.updateElementById(elementId, updates);
@@ -9161,7 +9161,7 @@ function collectReferencedFontFamilies(slides) {
9161
9161
  const families = /* @__PURE__ */ new Set();
9162
9162
  for (const slide of slides) {
9163
9163
  for (const el of slide.elements) {
9164
- if (chunkUSAJMMF2_js.hasTextProperties(el) && el.textSegments) {
9164
+ if (chunkSADF35N7_js.hasTextProperties(el) && el.textSegments) {
9165
9165
  for (const seg of el.textSegments) {
9166
9166
  if (seg.style.fontFamily) {
9167
9167
  families.add(seg.style.fontFamily);
@@ -9373,13 +9373,13 @@ function useKeyboardShortcuts(input) {
9373
9373
  inputRef.current = input;
9374
9374
  const handleKeyDown = react.useCallback((e) => {
9375
9375
  const current = inputRef.current;
9376
- const { action, dx, dy } = chunkUSAJMMF2_js.mapEditorKey(e, {
9376
+ const { action, dx, dy } = chunkSADF35N7_js.mapEditorKey(e, {
9377
9377
  canEdit: current.canEdit,
9378
9378
  isPresenting: current.mode !== "edit",
9379
9379
  hasSelection: current.hasSelection,
9380
9380
  isEditingText: Boolean(current.inlineEditingElementId || current.tableEditorState?.isEditing),
9381
9381
  isDrawing: current.activeTool !== "select",
9382
- isTextInputTarget: chunkUSAJMMF2_js.isEditorTextInputTarget(e.target)
9382
+ isTextInputTarget: chunkSADF35N7_js.isEditorTextInputTarget(e.target)
9383
9383
  });
9384
9384
  if (action === null) {
9385
9385
  return;
@@ -9673,7 +9673,7 @@ function useViewerIntegration(input) {
9673
9673
  return zoom.scale;
9674
9674
  },
9675
9675
  setZoom(level) {
9676
- zoom.setScale(chunkUSAJMMF2_js.clampZoomScale(level));
9676
+ zoom.setScale(chunkSADF35N7_js.clampZoomScale(level));
9677
9677
  },
9678
9678
  zoomIn() {
9679
9679
  zoom.handleZoomIn();
@@ -9888,7 +9888,7 @@ function useReducedMotion() {
9888
9888
  }
9889
9889
  function useViewerOptions() {
9890
9890
  const storeRef = react.useRef(null);
9891
- storeRef.current ??= chunkUSAJMMF2_js.createViewerOptionsStore();
9891
+ storeRef.current ??= chunkSADF35N7_js.createViewerOptionsStore();
9892
9892
  const store = storeRef.current;
9893
9893
  const options = react.useSyncExternalStore(
9894
9894
  (onStoreChange) => store.subscribe(onStoreChange),
@@ -9897,9 +9897,9 @@ function useViewerOptions() {
9897
9897
  );
9898
9898
  return { optionsStore: store, options };
9899
9899
  }
9900
- var KNOWN_TAB_IDS = new Set(chunkUSAJMMF2_js.TOOLBAR_TABS.map((tab) => tab.id));
9900
+ var KNOWN_TAB_IDS = new Set(chunkSADF35N7_js.TOOLBAR_TABS.map((tab) => tab.id));
9901
9901
  function computeToolbarVisibility(hiddenActions) {
9902
- const isHidden = (id) => chunkUSAJMMF2_js.isActionHidden(id, hiddenActions);
9902
+ const isHidden = (id) => chunkSADF35N7_js.isActionHidden(id, hiddenActions);
9903
9903
  const isTabVisible = (id) => !KNOWN_TAB_IDS.has(id) || !isHidden(id);
9904
9904
  return { isHidden, isTabVisible };
9905
9905
  }
@@ -9984,12 +9984,12 @@ function useYjsDocumentSync({
9984
9984
  return;
9985
9985
  }
9986
9986
  try {
9987
- const handler = new chunkUSAJMMF2_js.PptxHandler();
9987
+ const handler = new chunkSADF35N7_js.PptxHandler();
9988
9988
  await handler.load(sourceBytes.buffer);
9989
- const currentSlides = chunkUSAJMMF2_js.readSlidesFromYDoc(
9989
+ const currentSlides = chunkSADF35N7_js.readSlidesFromYDoc(
9990
9990
  doc
9991
9991
  );
9992
- const slidesToSave = chunkUSAJMMF2_js.buildSaveSlides(currentSlides, templateElementsBySlideId);
9992
+ const slidesToSave = chunkSADF35N7_js.buildSaveSlides(currentSlides, templateElementsBySlideId);
9993
9993
  const bytes = await handler.save(slidesToSave);
9994
9994
  config.onWriteBack(bytes);
9995
9995
  } catch {
@@ -10004,7 +10004,7 @@ function useYjsDocumentSync({
10004
10004
  if (!doc || !isConnected) {
10005
10005
  return;
10006
10006
  }
10007
- const docSlides = chunkUSAJMMF2_js.readSlidesFromYDoc(
10007
+ const docSlides = chunkSADF35N7_js.readSlidesFromYDoc(
10008
10008
  doc
10009
10009
  );
10010
10010
  if (docSlides.length === 0) {
@@ -10026,11 +10026,11 @@ function useYjsDocumentSync({
10026
10026
  lastSyncedRef.current = serialized;
10027
10027
  void (async () => {
10028
10028
  const factories = await getFactories();
10029
- chunkUSAJMMF2_js.reconcileSlidesInYDoc(
10029
+ chunkSADF35N7_js.reconcileSlidesInYDoc(
10030
10030
  slides,
10031
10031
  doc,
10032
10032
  factories,
10033
- chunkUSAJMMF2_js.LOCAL_SYNC_ORIGIN
10033
+ chunkSADF35N7_js.LOCAL_SYNC_ORIGIN
10034
10034
  );
10035
10035
  scheduleWriteBack();
10036
10036
  })();
@@ -10044,10 +10044,10 @@ function useYjsDocumentSync({
10044
10044
  return;
10045
10045
  }
10046
10046
  const handleChange = (_events, transaction) => {
10047
- if (transaction?.origin === chunkUSAJMMF2_js.LOCAL_SYNC_ORIGIN) {
10047
+ if (transaction?.origin === chunkSADF35N7_js.LOCAL_SYNC_ORIGIN) {
10048
10048
  return;
10049
10049
  }
10050
- const remoteSlides = chunkUSAJMMF2_js.readSlidesFromYDoc(
10050
+ const remoteSlides = chunkSADF35N7_js.readSlidesFromYDoc(
10051
10051
  doc
10052
10052
  );
10053
10053
  if (remoteSlides.length === 0) {
@@ -10063,7 +10063,7 @@ function useYjsDocumentSync({
10063
10063
  isApplyingRemoteRef.current = false;
10064
10064
  scheduleWriteBack();
10065
10065
  };
10066
- const unobserve = chunkUSAJMMF2_js.observeYDocSlides(
10066
+ const unobserve = chunkSADF35N7_js.observeYDocSlides(
10067
10067
  doc,
10068
10068
  handleChange
10069
10069
  );
@@ -10101,7 +10101,7 @@ function useBroadcastFollower({
10101
10101
  if (!broadcaster) {
10102
10102
  return;
10103
10103
  }
10104
- if (!chunkUSAJMMF2_js.shouldAutoFollowBroadcaster({
10104
+ if (!chunkSADF35N7_js.shouldAutoFollowBroadcaster({
10105
10105
  localRole: collab.config.role,
10106
10106
  broadcasterRole: broadcaster.role
10107
10107
  })) {
@@ -10267,10 +10267,10 @@ function useTouchGestures(input) {
10267
10267
  if (!el || !enabled) {
10268
10268
  return;
10269
10269
  }
10270
- const recognizer = chunkUSAJMMF2_js.createTouchGestureRecognizer({
10270
+ const recognizer = chunkSADF35N7_js.createTouchGestureRecognizer({
10271
10271
  getScale: () => scaleRef.current,
10272
- minScale: chunkUSAJMMF2_js.MIN_ZOOM_SCALE,
10273
- maxScale: chunkUSAJMMF2_js.MAX_ZOOM_SCALE,
10272
+ minScale: chunkSADF35N7_js.MIN_ZOOM_SCALE,
10273
+ maxScale: chunkSADF35N7_js.MAX_ZOOM_SCALE,
10274
10274
  callbacks: {
10275
10275
  onPinchZoom: (newScale) => callbacksRef.current.onPinchZoom?.(newScale),
10276
10276
  onSwipe: (direction) => callbacksRef.current.onSwipe?.(direction),
@@ -10310,7 +10310,7 @@ function scrollFocusedIntoView(keyboardInset) {
10310
10310
  return;
10311
10311
  }
10312
10312
  const rect = active.getBoundingClientRect();
10313
- const delta = chunkUSAJMMF2_js.computeScrollDelta(
10313
+ const delta = chunkSADF35N7_js.computeScrollDelta(
10314
10314
  { top: rect.top, bottom: rect.bottom },
10315
10315
  window.innerHeight,
10316
10316
  keyboardInset
@@ -10330,8 +10330,8 @@ function useKeyboardInsets(enabled = true) {
10330
10330
  return;
10331
10331
  }
10332
10332
  const update = () => {
10333
- const metrics = chunkUSAJMMF2_js.readViewportMetrics(window);
10334
- const inset = metrics ? chunkUSAJMMF2_js.computeKeyboardInset(metrics) : 0;
10333
+ const metrics = chunkSADF35N7_js.readViewportMetrics(window);
10334
+ const inset = metrics ? chunkSADF35N7_js.computeKeyboardInset(metrics) : 0;
10335
10335
  setKeyboardInset(inset);
10336
10336
  if (inset > 0) {
10337
10337
  window.requestAnimationFrame(() => scrollFocusedIntoView(inset));
@@ -10342,8 +10342,8 @@ function useKeyboardInsets(enabled = true) {
10342
10342
  vv.addEventListener("scroll", update);
10343
10343
  const onFocusIn = () => {
10344
10344
  window.requestAnimationFrame(() => {
10345
- const metrics = chunkUSAJMMF2_js.readViewportMetrics(window);
10346
- const inset = metrics ? chunkUSAJMMF2_js.computeKeyboardInset(metrics) : 0;
10345
+ const metrics = chunkSADF35N7_js.readViewportMetrics(window);
10346
+ const inset = metrics ? chunkSADF35N7_js.computeKeyboardInset(metrics) : 0;
10347
10347
  if (inset > 0) {
10348
10348
  scrollFocusedIntoView(inset);
10349
10349
  }
@@ -10356,7 +10356,7 @@ function useKeyboardInsets(enabled = true) {
10356
10356
  document.removeEventListener("focusin", onFocusIn);
10357
10357
  };
10358
10358
  }, [enabled]);
10359
- return { keyboardInset, isKeyboardOpen: chunkUSAJMMF2_js.isKeyboardOpen(keyboardInset) };
10359
+ return { keyboardInset, isKeyboardOpen: chunkSADF35N7_js.isKeyboardOpen(keyboardInset) };
10360
10360
  }
10361
10361
 
10362
10362
  // src/viewer/hooks/useViewerBuildingBlocks-canvas-props.ts
@@ -10383,7 +10383,7 @@ function buildCanvasProps(input) {
10383
10383
  } = input;
10384
10384
  const effectiveSlide = mode === "master" ? masterPseudoSlide : activeSlide;
10385
10385
  const effectiveTemplateElements = mode === "master" ? s.activeLayout ? s.activeMaster?.elements ?? [] : [] : templateElements;
10386
- const fieldContext = chunkUSAJMMF2_js.buildFieldSubstitutionContext({
10386
+ const fieldContext = chunkSADF35N7_js.buildFieldSubstitutionContext({
10387
10387
  headerFooter: s.headerFooter,
10388
10388
  customProperties: s.customProperties,
10389
10389
  slide: activeSlide
@@ -10393,13 +10393,13 @@ function buildCanvasProps(input) {
10393
10393
  if (mode === "present") {
10394
10394
  presentation.handlePresentationAction(action);
10395
10395
  } else if (action.url) {
10396
- chunkUSAJMMF2_js.safeOpenUrl(action.url);
10396
+ chunkSADF35N7_js.safeOpenUrl(action.url);
10397
10397
  }
10398
10398
  };
10399
10399
  const handleHyperlinkClick = (url) => {
10400
- if (chunkUSAJMMF2_js.isPpactionUrl(url)) {
10400
+ if (chunkSADF35N7_js.isPpactionUrl(url)) {
10401
10401
  if (mode === "present") {
10402
- const parsed = chunkUSAJMMF2_js.parsePpactionUrl(url);
10402
+ const parsed = chunkSADF35N7_js.parsePpactionUrl(url);
10403
10403
  if (parsed) {
10404
10404
  presentation.handlePresentationAction({
10405
10405
  action: parsed.action,
@@ -10409,7 +10409,7 @@ function buildCanvasProps(input) {
10409
10409
  }
10410
10410
  return;
10411
10411
  }
10412
- chunkUSAJMMF2_js.safeOpenUrl(url);
10412
+ chunkSADF35N7_js.safeOpenUrl(url);
10413
10413
  };
10414
10414
  return {
10415
10415
  activeSlide: effectiveSlide,
@@ -10552,7 +10552,7 @@ function buildToolbarAnimationHandlers(input) {
10552
10552
  const current = activeSlide.animations ?? [];
10553
10553
  if (group === "motionPath") {
10554
10554
  propertyHandlers.handleUpdateSlide({
10555
- animations: chunkUSAJMMF2_js.applyMotionPathPreset(current, selectedElement.id, preset)
10555
+ animations: chunkSADF35N7_js.applyMotionPathPreset(current, selectedElement.id, preset)
10556
10556
  });
10557
10557
  return;
10558
10558
  }
@@ -10747,7 +10747,7 @@ function buildToolbarProps(input) {
10747
10747
  onOpenFile,
10748
10748
  onOpenRecentFile,
10749
10749
  onCreatePresentation: (templateId) => {
10750
- s.setSlides(chunkUSAJMMF2_js.createBackstagePresentation(templateId));
10750
+ s.setSlides(chunkSADF35N7_js.createBackstagePresentation(templateId));
10751
10751
  s.setActiveSlideIndex(0);
10752
10752
  s.setSelectedElementId(null);
10753
10753
  s.setSelectedElementIds([]);
@@ -10774,7 +10774,7 @@ function buildToolbarProps(input) {
10774
10774
  layoutOptions: scopedLayoutOptions,
10775
10775
  onInsertSlideFromLayout: slideOps.handleInsertSlideFromLayout,
10776
10776
  onInsertSlideFromTemplate: slideOps.handleInsertSlideFromTemplate,
10777
- templateScheme: chunkUSAJMMF2_js.templateSchemeFromTheme(s.theme?.colorScheme),
10777
+ templateScheme: chunkSADF35N7_js.templateSchemeFromTheme(s.theme?.colorScheme),
10778
10778
  customShows: s.customShows,
10779
10779
  activeCustomShowId: s.activeCustomShowId,
10780
10780
  onSetActiveCustomShowId: s.setActiveCustomShowId,
@@ -10806,7 +10806,7 @@ function buildToolbarProps(input) {
10806
10806
  isCommentsPanelOpen: s.isInspectorPaneOpen,
10807
10807
  slideCommentCount: activeSlide?.comments?.length ?? 0,
10808
10808
  formatPainterActive: s.formatPainterActive,
10809
- canActivateFormatPainter: chunkUSAJMMF2_js.hasCopyableFormat(selectedElement),
10809
+ canActivateFormatPainter: chunkSADF35N7_js.hasCopyableFormat(selectedElement),
10810
10810
  onToggleFormatPainter: () => s.setFormatPainterActive((p) => !p),
10811
10811
  isSelectionPaneOpen: s.isSelectionPaneOpen,
10812
10812
  onToggleSelectionPane: () => s.setIsSelectionPaneOpen((p) => !p),
@@ -11075,7 +11075,7 @@ function useViewerBuildingBlocks(input) {
11075
11075
  }, [incomingContent]);
11076
11076
  const onOpenFile = react.useCallback(() => {
11077
11077
  void (async () => {
11078
- const picked = await chunkUSAJMMF2_js.openPptxFile();
11078
+ const picked = await chunkSADF35N7_js.openPptxFile();
11079
11079
  if (picked) {
11080
11080
  setContent(picked.buffer);
11081
11081
  }
@@ -11083,7 +11083,7 @@ function useViewerBuildingBlocks(input) {
11083
11083
  }, []);
11084
11084
  const onOpenRecentFile = react.useCallback((key) => {
11085
11085
  void (async () => {
11086
- const bytes = await chunkUSAJMMF2_js.readBackstageRecentFile(key);
11086
+ const bytes = await chunkSADF35N7_js.readBackstageRecentFile(key);
11087
11087
  if (bytes) {
11088
11088
  setContent(bytes);
11089
11089
  }