@aixa-transformation/pptx-viewer 2.0.37 → 2.0.39

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.
@@ -1,8 +1,8 @@
1
1
  'use strict';
2
2
 
3
- var chunk7OK75CPY_js = require('./chunk-7OK75CPY.js');
3
+ var chunkR47PKWUJ_js = require('./chunk-R47PKWUJ.js');
4
4
  var chunkCUUYYYC5_js = require('./chunk-CUUYYYC5.js');
5
- var chunkZWG6IN7E_js = require('./chunk-ZWG6IN7E.js');
5
+ var chunkRVKY3KGH_js = require('./chunk-RVKY3KGH.js');
6
6
  var React4 = require('react');
7
7
  var lu = require('react-icons/lu');
8
8
  var clsx = require('clsx');
@@ -18,12 +18,12 @@ var JSZip__default = /*#__PURE__*/_interopDefault(JSZip);
18
18
 
19
19
  // src/viewer/utils/animation-effects.ts
20
20
  function getAnimationInitialStyle2(preset, nativeAnimation) {
21
- return chunk7OK75CPY_js.getAnimationInitialStyle(preset, nativeAnimation);
21
+ return chunkR47PKWUJ_js.getAnimationInitialStyle(preset, nativeAnimation);
22
22
  }
23
23
  function useVirtualizedSlides({
24
24
  totalItems,
25
25
  itemHeight,
26
- overscan = chunk7OK75CPY_js.DEFAULT_VIRTUAL_OVERSCAN
26
+ overscan = chunkR47PKWUJ_js.DEFAULT_VIRTUAL_OVERSCAN
27
27
  }) {
28
28
  const scrollContainerRef = React4.useRef(null);
29
29
  const [scrollTop, setScrollTop] = React4.useState(0);
@@ -53,7 +53,7 @@ function useVirtualizedSlides({
53
53
  resizeObserver?.disconnect();
54
54
  };
55
55
  }, []);
56
- const range = chunk7OK75CPY_js.computeVirtualRange(totalItems, itemHeight, scrollTop, viewportHeight, overscan);
56
+ const range = chunkR47PKWUJ_js.computeVirtualRange(totalItems, itemHeight, scrollTop, viewportHeight, overscan);
57
57
  const safeItemHeight = Math.max(itemHeight, 1);
58
58
  const scrollToIndex = React4.useCallback(
59
59
  (index, behavior = "smooth") => {
@@ -116,7 +116,7 @@ function usePresenceTracking({
116
116
  awareness.setLocalStateField("presence", state);
117
117
  lastBroadcastRef.current = Date.now();
118
118
  };
119
- if (elapsed >= chunk7OK75CPY_js.BROADCAST_THROTTLE_MS) {
119
+ if (elapsed >= chunkR47PKWUJ_js.BROADCAST_THROTTLE_MS) {
120
120
  if (pendingBroadcastRef.current) {
121
121
  clearTimeout(pendingBroadcastRef.current);
122
122
  pendingBroadcastRef.current = null;
@@ -126,7 +126,7 @@ function usePresenceTracking({
126
126
  pendingBroadcastRef.current = setTimeout(() => {
127
127
  pendingBroadcastRef.current = null;
128
128
  flush();
129
- }, chunk7OK75CPY_js.BROADCAST_THROTTLE_MS - elapsed);
129
+ }, chunkR47PKWUJ_js.BROADCAST_THROTTLE_MS - elapsed);
130
130
  }
131
131
  },
132
132
  [awareness, userName, userColor, userAvatar, role]
@@ -151,7 +151,7 @@ function usePresenceTracking({
151
151
  return;
152
152
  }
153
153
  const handleChange = () => {
154
- const users = chunk7OK75CPY_js.derivePresenceList(
154
+ const users = chunkR47PKWUJ_js.derivePresenceList(
155
155
  awareness.getStates(),
156
156
  localClientId,
157
157
  canvasWidth,
@@ -202,7 +202,7 @@ function useYjsProvider({ config }) {
202
202
  const timeoutRef = React4.useRef(null);
203
203
  const gateRef = React4.useRef(null);
204
204
  if (!gateRef.current) {
205
- gateRef.current = chunk7OK75CPY_js.createSyncGate(() => setSynced(true));
205
+ gateRef.current = chunkR47PKWUJ_js.createSyncGate(() => setSynced(true));
206
206
  }
207
207
  const teardown = React4.useCallback(() => {
208
208
  if (timeoutRef.current) {
@@ -240,7 +240,7 @@ function useYjsProvider({ config }) {
240
240
  if (config.authToken) {
241
241
  opts.password = config.authToken;
242
242
  }
243
- const provider = new WebrtcProvider(chunk7OK75CPY_js.validateRoomId(config.roomId), yDoc, opts);
243
+ const provider = new WebrtcProvider(chunkR47PKWUJ_js.validateRoomId(config.roomId), yDoc, opts);
244
244
  setDoc(yDoc);
245
245
  setAwareness(provider.awareness);
246
246
  setClientId(provider.awareness.clientID);
@@ -282,13 +282,13 @@ function useYjsProvider({ config }) {
282
282
  if (!config) {
283
283
  return;
284
284
  }
285
- const roomId = chunk7OK75CPY_js.validateRoomId(config.roomId);
286
- const transport = config.transport ?? chunk7OK75CPY_js.resolveTransportForServerUrl(config.serverUrl);
285
+ const roomId = chunkR47PKWUJ_js.validateRoomId(config.roomId);
286
+ const transport = config.transport ?? chunkR47PKWUJ_js.resolveTransportForServerUrl(config.serverUrl);
287
287
  if (transport === "webrtc") {
288
288
  await initWebrtc();
289
289
  return;
290
290
  }
291
- if (chunk7OK75CPY_js.isMixedContentBlocked(config.serverUrl)) {
291
+ if (chunkR47PKWUJ_js.isMixedContentBlocked(config.serverUrl)) {
292
292
  console.warn(
293
293
  `[pptx-viewer] Refusing to connect: insecure ws:// server "${config.serverUrl}" is blocked from a secure (https) page. Use a wss:// URL.`
294
294
  );
@@ -348,7 +348,7 @@ function useYjsProvider({ config }) {
348
348
  cleanupRef.current = null;
349
349
  setStatus("error");
350
350
  }
351
- }, chunk7OK75CPY_js.CONNECTION_TIMEOUT_MS);
351
+ }, chunkR47PKWUJ_js.CONNECTION_TIMEOUT_MS);
352
352
  }
353
353
  setDoc(yDoc);
354
354
  setAwareness(provider.awareness);
@@ -394,7 +394,7 @@ function useCollaborativeState({
394
394
  canvasWidth,
395
395
  canvasHeight
396
396
  }) {
397
- const userColor = chunk7OK75CPY_js.sanitizeColor(config?.userColor, "#6366f1");
397
+ const userColor = chunkR47PKWUJ_js.sanitizeColor(config?.userColor, "#6366f1");
398
398
  const { status, awareness, doc, clientId, synced, retry } = useYjsProvider({ config });
399
399
  const { remoteUsers, broadcastPresence } = usePresenceTracking({
400
400
  awareness,
@@ -461,7 +461,7 @@ function useSheetDismissDrag(onClose, threshold = 120) {
461
461
 
462
462
  // src/viewer/utils/clone.ts
463
463
  function cloneHistorySnapshot2(snapshot) {
464
- return chunk7OK75CPY_js.cloneHistorySnapshot(snapshot);
464
+ return chunkR47PKWUJ_js.cloneHistorySnapshot(snapshot);
465
465
  }
466
466
 
467
467
  // src/viewer/hooks/useEditorHistory.ts
@@ -510,8 +510,8 @@ function useEditorHistory(input) {
510
510
  width: canvasSize.width,
511
511
  height: canvasSize.height,
512
512
  activeSlideIndex,
513
- slides: slides.map(chunk7OK75CPY_js.cloneSlide),
514
- templateElementsBySlideId: chunk7OK75CPY_js.cloneTemplateElementsBySlideId(templateElementsBySlideId),
513
+ slides: slides.map(chunkR47PKWUJ_js.cloneSlide),
514
+ templateElementsBySlideId: chunkR47PKWUJ_js.cloneTemplateElementsBySlideId(templateElementsBySlideId),
515
515
  ...actionLabel ? { actionLabel } : {}
516
516
  };
517
517
  },
@@ -524,9 +524,9 @@ function useEditorHistory(input) {
524
524
  width: snapshot.width,
525
525
  height: snapshot.height
526
526
  });
527
- setSlides(snapshot.slides.map(chunk7OK75CPY_js.cloneSlide));
527
+ setSlides(snapshot.slides.map(chunkR47PKWUJ_js.cloneSlide));
528
528
  setTemplateElementsBySlideId(
529
- chunk7OK75CPY_js.cloneTemplateElementsBySlideId(snapshot.templateElementsBySlideId)
529
+ chunkR47PKWUJ_js.cloneTemplateElementsBySlideId(snapshot.templateElementsBySlideId)
530
530
  );
531
531
  setActiveSlideIndex(Math.min(snapshot.activeSlideIndex, maxSlideIndex));
532
532
  setSelectedElementIds([]);
@@ -790,7 +790,7 @@ var GLYPH_COMPONENTS = {
790
790
  plus: lu.LuPlus,
791
791
  triangle: lu.LuTriangle
792
792
  };
793
- var SHAPE_PRESETS = chunk7OK75CPY_js.SHAPE_PRESET_DEFS.map(
793
+ var SHAPE_PRESETS = chunkR47PKWUJ_js.SHAPE_PRESET_DEFS.map(
794
794
  (def) => ({
795
795
  type: def.type,
796
796
  label: def.label,
@@ -1035,7 +1035,7 @@ function executeMediaCommand(command) {
1035
1035
  if (!el) {
1036
1036
  return false;
1037
1037
  }
1038
- const parsed = chunk7OK75CPY_js.parseMediaCommand(command.command);
1038
+ const parsed = chunkR47PKWUJ_js.parseMediaCommand(command.command);
1039
1039
  if (!parsed) {
1040
1040
  return false;
1041
1041
  }
@@ -1198,7 +1198,7 @@ function useAnimationPlayback(input) {
1198
1198
  (controller, group) => {
1199
1199
  driveBuildReveal(
1200
1200
  controller,
1201
- chunk7OK75CPY_js.PresentationAnimationController.collectBuildStepIds(group),
1201
+ chunkR47PKWUJ_js.PresentationAnimationController.collectBuildStepIds(group),
1202
1202
  setPresentationElementStates,
1203
1203
  buildRafRef
1204
1204
  );
@@ -1261,7 +1261,7 @@ function useAnimationPlayback(input) {
1261
1261
  setHoverTriggerShapeIds(/* @__PURE__ */ new Set());
1262
1262
  return;
1263
1263
  }
1264
- const controller = chunk7OK75CPY_js.PresentationAnimationController.fromSlide(slide);
1264
+ const controller = chunkR47PKWUJ_js.PresentationAnimationController.fromSlide(slide);
1265
1265
  controllerRef.current = controller;
1266
1266
  setPresentationKeyframesCss(controller.keyframesCss);
1267
1267
  setInteractiveTriggerShapeIds(controller.interactiveTriggerShapeIds);
@@ -1398,7 +1398,7 @@ function useAnimationPlayback(input) {
1398
1398
  }))
1399
1399
  );
1400
1400
  entranceAnimations.forEach((animation, animationIndex) => {
1401
- const delay = chunk7OK75CPY_js.computeEntranceAnimationDelay(animation.delayMs, animationIndex);
1401
+ const delay = chunkR47PKWUJ_js.computeEntranceAnimationDelay(animation.delayMs, animationIndex);
1402
1402
  const timer = window.setTimeout(() => {
1403
1403
  setPresentationAnimations(
1404
1404
  (previousAnimations) => previousAnimations.map(
@@ -1434,12 +1434,12 @@ function useAnimationPlayback(input) {
1434
1434
  presentationTimersRef
1435
1435
  };
1436
1436
  }
1437
- var PRESENTER_CHANNEL_NAME = chunk7OK75CPY_js.PRESENTATION_CHANNEL_NAME;
1438
- var AUDIENCE_HASH = chunk7OK75CPY_js.PRESENTATION_HASH;
1439
- var PRESENTER_MSG_ORIGIN = chunk7OK75CPY_js.PRESENTATION_MESSAGE_ORIGIN;
1440
- var AUDIENCE_NONCE_KEY = chunk7OK75CPY_js.PRESENTATION_NONCE_KEY;
1437
+ var PRESENTER_CHANNEL_NAME = chunkR47PKWUJ_js.PRESENTATION_CHANNEL_NAME;
1438
+ var AUDIENCE_HASH = chunkR47PKWUJ_js.PRESENTATION_HASH;
1439
+ var PRESENTER_MSG_ORIGIN = chunkR47PKWUJ_js.PRESENTATION_MESSAGE_ORIGIN;
1440
+ var AUDIENCE_NONCE_KEY = chunkR47PKWUJ_js.PRESENTATION_NONCE_KEY;
1441
1441
  function generateSessionId() {
1442
- return chunk7OK75CPY_js.createPresentationSessionId();
1442
+ return chunkR47PKWUJ_js.createPresentationSessionId();
1443
1443
  }
1444
1444
  function parseAudienceNonce() {
1445
1445
  const hash = window.location.hash;
@@ -1475,7 +1475,7 @@ function usePresenterWindow(input) {
1475
1475
  }, []);
1476
1476
  const swapDisplays = React4.useCallback(async () => {
1477
1477
  const audience = audienceWindowRef.current;
1478
- return audience && !audience.closed ? chunk7OK75CPY_js.swapPresentationWindows(window, audience) : false;
1478
+ return audience && !audience.closed ? chunkR47PKWUJ_js.swapPresentationWindows(window, audience) : false;
1479
1479
  }, []);
1480
1480
  const syncSlideToAudience = React4.useCallback(
1481
1481
  (slideIndex) => {
@@ -1539,7 +1539,7 @@ function usePresenterWindow(input) {
1539
1539
  pollTimerRef.current = null;
1540
1540
  }
1541
1541
  if (closingSessionId) {
1542
- void chunk7OK75CPY_js.clearAudienceContent(closingSessionId);
1542
+ void chunkR47PKWUJ_js.clearAudienceContent(closingSessionId);
1543
1543
  }
1544
1544
  }, [getChannel]);
1545
1545
  const openAudienceWindow = React4.useCallback(() => {
@@ -1557,10 +1557,10 @@ function usePresenterWindow(input) {
1557
1557
  audienceWindowRef.current = blankWin;
1558
1558
  const sessionId = generateSessionId();
1559
1559
  sessionIdRef.current = sessionId;
1560
- const audienceUrl = chunk7OK75CPY_js.buildPresentationAudienceUrl(window.location.href, sessionId);
1561
- void chunk7OK75CPY_js.resolveAudienceScreenPlacement(window).then((placement) => {
1560
+ const audienceUrl = chunkR47PKWUJ_js.buildPresentationAudienceUrl(window.location.href, sessionId);
1561
+ void chunkR47PKWUJ_js.resolveAudienceScreenPlacement(window).then((placement) => {
1562
1562
  if (placement && audienceWindowRef.current === blankWin && !blankWin.closed) {
1563
- chunk7OK75CPY_js.placeAudienceWindow(blankWin, placement);
1563
+ chunkR47PKWUJ_js.placeAudienceWindow(blankWin, placement);
1564
1564
  }
1565
1565
  return void 0;
1566
1566
  });
@@ -1590,7 +1590,7 @@ function usePresenterWindow(input) {
1590
1590
  }
1591
1591
  };
1592
1592
  if (content) {
1593
- void chunk7OK75CPY_js.storeAudienceContent(content, sessionId).then(() => navigateOrClose(true)).catch(() => navigateOrClose(false));
1593
+ void chunkR47PKWUJ_js.storeAudienceContent(content, sessionId).then(() => navigateOrClose(true)).catch(() => navigateOrClose(false));
1594
1594
  } else {
1595
1595
  navigateOrClose(true);
1596
1596
  }
@@ -1616,7 +1616,7 @@ function usePresenterWindow(input) {
1616
1616
  }
1617
1617
  const handleMessage = (event) => {
1618
1618
  const message = event.data;
1619
- if (chunk7OK75CPY_js.isPresentationSessionMessage(message) && message.type === "audience-ready" && message.sessionId === sessionIdRef.current) {
1619
+ if (chunkR47PKWUJ_js.isPresentationSessionMessage(message) && message.type === "audience-ready" && message.sessionId === sessionIdRef.current) {
1620
1620
  syncStateToAudience(snapshotRef.current);
1621
1621
  }
1622
1622
  };
@@ -1645,7 +1645,7 @@ function usePresenterWindow(input) {
1645
1645
  React4.useEffect(() => {
1646
1646
  const handleBeforeUnload = () => {
1647
1647
  if (sessionIdRef.current) {
1648
- void chunk7OK75CPY_js.clearAudienceContent(sessionIdRef.current);
1648
+ void chunkR47PKWUJ_js.clearAudienceContent(sessionIdRef.current);
1649
1649
  }
1650
1650
  };
1651
1651
  window.addEventListener("beforeunload", handleBeforeUnload);
@@ -1698,7 +1698,7 @@ function useAudienceMode(input) {
1698
1698
  }
1699
1699
  channel.onmessage = (event) => {
1700
1700
  const data = event.data;
1701
- if (!chunk7OK75CPY_js.isPresentationSessionMessage(data) || data.origin !== PRESENTER_MSG_ORIGIN) {
1701
+ if (!chunkR47PKWUJ_js.isPresentationSessionMessage(data) || data.origin !== PRESENTER_MSG_ORIGIN) {
1702
1702
  return;
1703
1703
  }
1704
1704
  if (expectedSessionId && data.sessionId !== expectedSessionId) {
@@ -1713,7 +1713,7 @@ function useAudienceMode(input) {
1713
1713
  }
1714
1714
  if (data.type === "presenter-exit") {
1715
1715
  if (expectedSessionId) {
1716
- void chunk7OK75CPY_js.clearAudienceContent(expectedSessionId);
1716
+ void chunkR47PKWUJ_js.clearAudienceContent(expectedSessionId);
1717
1717
  }
1718
1718
  onSetMode("edit");
1719
1719
  try {
@@ -1724,7 +1724,7 @@ function useAudienceMode(input) {
1724
1724
  };
1725
1725
  if (expectedSessionId) {
1726
1726
  channel.postMessage({
1727
- origin: chunk7OK75CPY_js.PRESENTATION_MESSAGE_ORIGIN,
1727
+ origin: chunkR47PKWUJ_js.PRESENTATION_MESSAGE_ORIGIN,
1728
1728
  type: "audience-ready",
1729
1729
  sessionId: expectedSessionId
1730
1730
  });
@@ -1989,7 +1989,7 @@ function handlePresentationActionImpl(action, deps) {
1989
1989
  return;
1990
1990
  }
1991
1991
  if (action.url && !actionStr.includes("hlinksldjump")) {
1992
- if (chunk7OK75CPY_js.isUrlSafe(action.url)) {
1992
+ if (chunkR47PKWUJ_js.isUrlSafe(action.url)) {
1993
1993
  window.open(action.url, "_blank", "noopener,noreferrer");
1994
1994
  }
1995
1995
  }
@@ -1999,7 +1999,7 @@ function handlePresentationActionImpl(action, deps) {
1999
1999
  function executeSlideTransition(nextSlideIndex, deps) {
2000
2000
  const incomingSlide = deps.slides[nextSlideIndex];
2001
2001
  const transition = incomingSlide?.transition;
2002
- const durationMs = deps.playTransition ? chunk7OK75CPY_js.resolveTransitionDurationMs(transition) : 0;
2002
+ const durationMs = deps.playTransition ? chunkR47PKWUJ_js.resolveTransitionDurationMs(transition) : 0;
2003
2003
  deps.clearPresentationTimers();
2004
2004
  deps.setPresentationSlideIndex(nextSlideIndex);
2005
2005
  deps.onSetActiveSlideIndex(nextSlideIndex);
@@ -2245,17 +2245,17 @@ function useZoomNavigation(input) {
2245
2245
  };
2246
2246
  }
2247
2247
  function usePresenterConsole(slideIndex) {
2248
- const timerRef = React4.useRef(chunk7OK75CPY_js.createPresenterTimer());
2249
- const [snapshot, setSnapshot] = React4.useState(() => chunk7OK75CPY_js.createInitialPresentationSnapshot(slideIndex));
2248
+ const timerRef = React4.useRef(chunkR47PKWUJ_js.createPresenterTimer());
2249
+ const [snapshot, setSnapshot] = React4.useState(() => chunkR47PKWUJ_js.createInitialPresentationSnapshot(slideIndex));
2250
2250
  const patch = React4.useCallback((value) => {
2251
- setSnapshot((current) => chunk7OK75CPY_js.mergePresentationSnapshot(current, value));
2251
+ setSnapshot((current) => chunkR47PKWUJ_js.mergePresentationSnapshot(current, value));
2252
2252
  }, []);
2253
2253
  React4.useEffect(() => patch({ slideIndex }), [patch, slideIndex]);
2254
2254
  React4.useEffect(() => {
2255
2255
  const timer = window.setInterval(() => {
2256
2256
  patch({
2257
2257
  paused: timerRef.current.paused,
2258
- elapsedMs: chunk7OK75CPY_js.presenterElapsed(timerRef.current)
2258
+ elapsedMs: chunkR47PKWUJ_js.presenterElapsed(timerRef.current)
2259
2259
  });
2260
2260
  }, 1e3);
2261
2261
  return () => window.clearInterval(timer);
@@ -2265,19 +2265,19 @@ function usePresenterConsole(slideIndex) {
2265
2265
  applyAudienceSnapshot: setSnapshot,
2266
2266
  setBlackout: (blackout) => patch({ blackout }),
2267
2267
  toggleTimer: () => {
2268
- timerRef.current = chunk7OK75CPY_js.togglePresenterTimer(timerRef.current);
2268
+ timerRef.current = chunkR47PKWUJ_js.togglePresenterTimer(timerRef.current);
2269
2269
  patch({
2270
2270
  paused: timerRef.current.paused,
2271
- elapsedMs: chunk7OK75CPY_js.presenterElapsed(timerRef.current)
2271
+ elapsedMs: chunkR47PKWUJ_js.presenterElapsed(timerRef.current)
2272
2272
  });
2273
2273
  },
2274
2274
  resetTimer: () => {
2275
- timerRef.current = chunk7OK75CPY_js.resetPresenterTimer();
2275
+ timerRef.current = chunkR47PKWUJ_js.resetPresenterTimer();
2276
2276
  patch({ paused: false, elapsedMs: 0 });
2277
2277
  },
2278
2278
  stepZoom: (direction) => setSnapshot(
2279
- (current) => chunk7OK75CPY_js.mergePresentationSnapshot(current, {
2280
- zoom: chunk7OK75CPY_js.stepPresenterZoom(
2279
+ (current) => chunkR47PKWUJ_js.mergePresentationSnapshot(current, {
2280
+ zoom: chunkR47PKWUJ_js.stepPresenterZoom(
2281
2281
  current.zoom ?? { scale: 1, originX: 0.5, originY: 0.5 },
2282
2282
  direction
2283
2283
  )
@@ -2845,7 +2845,7 @@ function findInSlides(slides, findQuery, findMatchCase) {
2845
2845
  const normalised = findMatchCase ? findQuery : findQuery.toLowerCase();
2846
2846
  slides.forEach((slide, slideIndex) => {
2847
2847
  for (const element of slide.elements || []) {
2848
- if (!chunkZWG6IN7E_js.hasTextProperties(element)) {
2848
+ if (!chunkRVKY3KGH_js.hasTextProperties(element)) {
2849
2849
  continue;
2850
2850
  }
2851
2851
  const segments = element.textSegments ?? [];
@@ -2896,7 +2896,7 @@ function applyFindReplacements(slides, toReplace, replaceQuery) {
2896
2896
  continue;
2897
2897
  }
2898
2898
  const element = slide.elements[elIdx];
2899
- if (!chunkZWG6IN7E_js.hasTextProperties(element)) {
2899
+ if (!chunkRVKY3KGH_js.hasTextProperties(element)) {
2900
2900
  continue;
2901
2901
  }
2902
2902
  const segments = [...element.textSegments ?? []];
@@ -3784,12 +3784,12 @@ function useViewerState(input) {
3784
3784
  function partitionTemplateElements(slides) {
3785
3785
  const templateElementsBySlideId = {};
3786
3786
  const nextSlides = slides.map((slide) => {
3787
- const template = slide.elements.filter((el) => chunk7OK75CPY_js.isTemplateElement(el));
3787
+ const template = slide.elements.filter((el) => chunkR47PKWUJ_js.isTemplateElement(el));
3788
3788
  if (template.length === 0) {
3789
3789
  return slide;
3790
3790
  }
3791
3791
  templateElementsBySlideId[slide.id] = template;
3792
- return { ...slide, elements: slide.elements.filter((el) => !chunk7OK75CPY_js.isTemplateElement(el)) };
3792
+ return { ...slide, elements: slide.elements.filter((el) => !chunkR47PKWUJ_js.isTemplateElement(el)) };
3793
3793
  });
3794
3794
  return { slides: nextSlides, templateElementsBySlideId };
3795
3795
  }
@@ -3863,7 +3863,7 @@ function useLoadContent({
3863
3863
  );
3864
3864
  }
3865
3865
  const previousHandler = handlerRef.current;
3866
- const handler = new chunkZWG6IN7E_js.PptxHandler();
3866
+ const handler = new chunkRVKY3KGH_js.PptxHandler();
3867
3867
  const parsed = await handler.load(buffer, {
3868
3868
  // PowerPoint supports externally linked pictures. The project upload is
3869
3869
  // already security-scanned; allow the browser viewer to retain those
@@ -3880,7 +3880,7 @@ function useLoadContent({
3880
3880
  handlerRef.current = null;
3881
3881
  const mediaElements = [];
3882
3882
  for (const slide of parsed.slides) {
3883
- chunk7OK75CPY_js.collectMediaElements(slide.elements, mediaElements);
3883
+ chunkR47PKWUJ_js.collectMediaElements(slide.elements, mediaElements);
3884
3884
  }
3885
3885
  for (const url of mediaDataUrls.values()) {
3886
3886
  if (url.startsWith("blob:")) {
@@ -3921,7 +3921,7 @@ function useLoadContent({
3921
3921
  }
3922
3922
  })
3923
3923
  );
3924
- const { paths: imagePaths, refs: imageRefs } = chunk7OK75CPY_js.collectImagePaths(parsed.slides);
3924
+ const { paths: imagePaths, refs: imageRefs } = chunkR47PKWUJ_js.collectImagePaths(parsed.slides);
3925
3925
  let nextSlides = parsed.slides;
3926
3926
  if (imagePaths.size > 0) {
3927
3927
  const resolvedMap = /* @__PURE__ */ new Map();
@@ -4010,7 +4010,7 @@ function useLoadContent({
4010
4010
  setHasMacros(parsed.hasMacros === true);
4011
4011
  setHasDigitalSignatures(parsed.hasDigitalSignatures === true);
4012
4012
  setDigitalSignatureCount(parsed.digitalSignatureCount ?? 0);
4013
- setGuides(chunk7OK75CPY_js.buildInitialGuides(parsed.presentationGuides, parsed.slides[0]?.guides));
4013
+ setGuides(chunkR47PKWUJ_js.buildInitialGuides(parsed.presentationGuides, parsed.slides[0]?.guides));
4014
4014
  setActiveSlideIndex(0);
4015
4015
  clearSelection();
4016
4016
  setIsDirty(false);
@@ -4018,7 +4018,7 @@ function useLoadContent({
4018
4018
  onContentApplied?.();
4019
4019
  } catch (err) {
4020
4020
  if (!cancelled && token === renderTokenRef.current) {
4021
- if (err instanceof chunkZWG6IN7E_js.EncryptedFileError) {
4021
+ if (err instanceof chunkRVKY3KGH_js.EncryptedFileError) {
4022
4022
  setIsEncrypted(true);
4023
4023
  } else {
4024
4024
  setError(err instanceof Error ? err.message : String(err));
@@ -4095,7 +4095,7 @@ function useAutosave(input) {
4095
4095
  isSavingRef.current = false;
4096
4096
  return;
4097
4097
  }
4098
- await chunk7OK75CPY_js.saveAutosaveSnapshot(filePathRef.current, data);
4098
+ await chunkR47PKWUJ_js.saveAutosaveSnapshot(filePathRef.current, data);
4099
4099
  setAutosaveStatus({ state: "saved", timestamp: Date.now() });
4100
4100
  } catch (err) {
4101
4101
  setAutosaveStatus({
@@ -4136,7 +4136,7 @@ function cn(...inputs) {
4136
4136
 
4137
4137
  // src/viewer/utils/text-utils.tsx
4138
4138
  function getTextStyleForElement(element, fallbackColor) {
4139
- if (!chunkZWG6IN7E_js.hasTextProperties(element)) {
4139
+ if (!chunkRVKY3KGH_js.hasTextProperties(element)) {
4140
4140
  return { color: fallbackColor };
4141
4141
  }
4142
4142
  const textDecorationTokens = [];
@@ -4150,7 +4150,7 @@ function getTextStyleForElement(element, fallbackColor) {
4150
4150
  const textDecorationStyle = isDoubleStrike ? "double" : void 0;
4151
4151
  const hasItalicRuns = element.textStyle?.italic || Boolean(element.textSegments?.some((segment) => segment.style?.italic));
4152
4152
  const isRtl = element.textStyle?.rtl === true;
4153
- const resolvedTextColor = element.textStyle?.hyperlink ? chunk7OK75CPY_js.normalizeHexColor(element.textStyle?.color, HYPERLINK_COLOR) : chunk7OK75CPY_js.normalizeHexColor(element.textStyle?.color, fallbackColor);
4153
+ const resolvedTextColor = element.textStyle?.hyperlink ? chunkR47PKWUJ_js.normalizeHexColor(element.textStyle?.color, HYPERLINK_COLOR) : chunkR47PKWUJ_js.normalizeHexColor(element.textStyle?.color, fallbackColor);
4154
4154
  const bodyTop = element.textStyle?.bodyInsetTop ?? DEFAULT_BODY_INSET_TB_PX;
4155
4155
  const bodyBottom = element.textStyle?.bodyInsetBottom ?? DEFAULT_BODY_INSET_TB_PX;
4156
4156
  const bodyLeft = element.textStyle?.bodyInsetLeft ?? DEFAULT_BODY_INSET_LR_PX;
@@ -4159,15 +4159,15 @@ function getTextStyleForElement(element, fallbackColor) {
4159
4159
  const bodyParagraphMarginLeft = hasParagraphIndents ? 0 : element.textStyle?.paragraphMarginLeft ?? 0;
4160
4160
  const bodyParagraphMarginRight = hasParagraphIndents ? 0 : element.textStyle?.paragraphMarginRight ?? 0;
4161
4161
  const bodyParagraphIndent = hasParagraphIndents ? 0 : element.textStyle?.paragraphIndent ?? 0;
4162
- const writingMode = chunk7OK75CPY_js.toCssWritingMode(element.textStyle?.textDirection);
4163
- const textOrientation = chunk7OK75CPY_js.toCssTextOrientation(element.textStyle?.textDirection);
4164
- const verticalDirection = chunk7OK75CPY_js.toCssVerticalDirection(element.textStyle?.textDirection);
4162
+ const writingMode = chunkR47PKWUJ_js.toCssWritingMode(element.textStyle?.textDirection);
4163
+ const textOrientation = chunkR47PKWUJ_js.toCssTextOrientation(element.textStyle?.textDirection);
4164
+ const verticalDirection = chunkR47PKWUJ_js.toCssVerticalDirection(element.textStyle?.textDirection);
4165
4165
  const resolvedDirection = verticalDirection || (isRtl ? "rtl" : "ltr");
4166
4166
  const resolvedUnicodeBidi = isRtl ? "plaintext" : void 0;
4167
4167
  const hasSegments = (element.textSegments?.length ?? 0) > 0;
4168
4168
  return {
4169
4169
  color: resolvedTextColor,
4170
- backgroundColor: !hasSegments && element.textStyle?.highlightColor ? chunk7OK75CPY_js.normalizeHexColor(element.textStyle.highlightColor, void 0) : void 0,
4170
+ backgroundColor: !hasSegments && element.textStyle?.highlightColor ? chunkR47PKWUJ_js.normalizeHexColor(element.textStyle.highlightColor, void 0) : void 0,
4171
4171
  textAlign: (() => {
4172
4172
  const a = element.textStyle?.align;
4173
4173
  if (a === "justLow" || a === "dist" || a === "thaiDist") {
@@ -4183,7 +4183,7 @@ function getTextStyleForElement(element, fallbackColor) {
4183
4183
  textDecorationLine: textDecorationTokens.length > 0 ? textDecorationTokens.join(" ") : "none",
4184
4184
  textDecorationStyle,
4185
4185
  fontFamily: element.textStyle?.fontFamily || DEFAULT_FONT_FAMILY,
4186
- lineHeight: chunk7OK75CPY_js.resolveLineHeight(element.textStyle, hasItalicRuns),
4186
+ lineHeight: chunkR47PKWUJ_js.resolveLineHeight(element.textStyle, hasItalicRuns),
4187
4187
  paddingTop: bodyTop + (hasItalicRuns ? 1 : 0),
4188
4188
  paddingBottom: bodyBottom + (hasItalicRuns ? 1 : 0),
4189
4189
  paddingLeft: bodyLeft + bodyParagraphMarginLeft,
@@ -4196,7 +4196,7 @@ function getTextStyleForElement(element, fallbackColor) {
4196
4196
  // Auto-fit: use OOXML-provided fontScale/lnSpcReduction when available,
4197
4197
  // otherwise fall back to heuristic estimation. The pure font-scale maths
4198
4198
  // now lives in pptx-viewer-shared (computeAutoFitTextStyle).
4199
- ...chunk7OK75CPY_js.computeAutoFitTextStyle({
4199
+ ...chunkR47PKWUJ_js.computeAutoFitTextStyle({
4200
4200
  textStyle: element.textStyle,
4201
4201
  text: element.text ?? "",
4202
4202
  width: element.width,
@@ -4230,13 +4230,13 @@ function computeTabSize(tabStops, defaultTabSize) {
4230
4230
  return avgGap > 0 ? `${Math.round(avgGap)}px` : fromDefault;
4231
4231
  }
4232
4232
  function getTextLayoutStyle(element) {
4233
- if (!chunkZWG6IN7E_js.hasTextProperties(element)) {
4233
+ if (!chunkRVKY3KGH_js.hasTextProperties(element)) {
4234
4234
  return {};
4235
4235
  }
4236
4236
  const verticalAlign = element.textStyle?.vAlign || "top";
4237
- const writingMode = chunk7OK75CPY_js.toCssWritingMode(element.textStyle?.textDirection);
4238
- const textOrientation = chunk7OK75CPY_js.toCssTextOrientation(element.textStyle?.textDirection);
4239
- const verticalDirection = chunk7OK75CPY_js.toCssVerticalDirection(element.textStyle?.textDirection);
4237
+ const writingMode = chunkR47PKWUJ_js.toCssWritingMode(element.textStyle?.textDirection);
4238
+ const textOrientation = chunkR47PKWUJ_js.toCssTextOrientation(element.textStyle?.textDirection);
4239
+ const verticalDirection = chunkR47PKWUJ_js.toCssVerticalDirection(element.textStyle?.textDirection);
4240
4240
  const parsedColumnCount = Number(element.textStyle?.columnCount);
4241
4241
  const columnCount = Number.isFinite(parsedColumnCount) ? Math.max(1, Math.min(16, Math.round(parsedColumnCount))) : 1;
4242
4242
  const hasColumns = columnCount > 1;
@@ -4244,7 +4244,7 @@ function getTextLayoutStyle(element) {
4244
4244
  const tabStops = element.textStyle?.tabStops;
4245
4245
  const tabSize = computeTabSize(tabStops, element.textStyle?.defaultTabSize);
4246
4246
  const textWrapNone = element.textStyle?.textWrap === "none";
4247
- const hasParagraphIndents = chunkZWG6IN7E_js.hasTextProperties(element) && element.paragraphIndents && element.paragraphIndents.length > 0;
4247
+ const hasParagraphIndents = chunkRVKY3KGH_js.hasTextProperties(element) && element.paragraphIndents && element.paragraphIndents.length > 0;
4248
4248
  const paragraphMarginLeft = element.textStyle?.paragraphMarginLeft;
4249
4249
  const paragraphIndent = element.textStyle?.paragraphIndent;
4250
4250
  const marginLeft = !hasParagraphIndents && typeof paragraphMarginLeft === "number" && paragraphMarginLeft !== 0 ? paragraphMarginLeft : void 0;
@@ -4253,7 +4253,7 @@ function getTextLayoutStyle(element) {
4253
4253
  const bodyBottom = element.textStyle?.bodyInsetBottom ?? DEFAULT_BODY_INSET_TB_PX;
4254
4254
  const parsedColumnSpacing = Number(element.textStyle?.columnSpacing);
4255
4255
  const columnGap = Number.isFinite(parsedColumnSpacing) && parsedColumnSpacing > 0 ? `${parsedColumnSpacing}px` : "0.75em";
4256
- const kinsokuStyles = chunk7OK75CPY_js.getKinsokuLineBreakStyles(element.textStyle);
4256
+ const kinsokuStyles = chunkR47PKWUJ_js.getKinsokuLineBreakStyles(element.textStyle);
4257
4257
  if (hasColumns) {
4258
4258
  return {
4259
4259
  display: "block",
@@ -4300,10 +4300,10 @@ function getTextLayoutStyle(element) {
4300
4300
 
4301
4301
  // src/viewer/utils/text-effects.tsx
4302
4302
  function buildTextFillCss2(style) {
4303
- return chunk7OK75CPY_js.buildTextFillCss(style);
4303
+ return chunkR47PKWUJ_js.buildTextFillCss(style);
4304
4304
  }
4305
4305
  function buildTextBody3DSceneStyle2(textStyle) {
4306
- return chunk7OK75CPY_js.buildTextBody3DSceneStyle(textStyle);
4306
+ return chunkR47PKWUJ_js.buildTextBody3DSceneStyle(textStyle);
4307
4307
  }
4308
4308
 
4309
4309
  // src/viewer/utils/text-warp-css.tsx
@@ -4488,17 +4488,17 @@ function wrapWithTextBuildAnimation(elementId, paraIndex, renderedSegments, para
4488
4488
  if (!subElementAnimStates || subElementAnimStates.size === 0) {
4489
4489
  return renderedSegments;
4490
4490
  }
4491
- const paraKey = `${elementId}${chunk7OK75CPY_js.TEXT_BUILD_ID_SEP}p${paraIndex}`;
4491
+ const paraKey = `${elementId}${chunkR47PKWUJ_js.TEXT_BUILD_ID_SEP}p${paraIndex}`;
4492
4492
  const paraState = subElementAnimStates.get(paraKey);
4493
4493
  if (paraState) {
4494
4494
  const style = buildAnimStyle(paraState);
4495
4495
  return /* @__PURE__ */ jsxRuntime.jsx("span", { "data-anim-id": paraKey, style: { display: "inline", ...style }, children: renderedSegments }, paraKey);
4496
4496
  }
4497
- const firstWordKey = `${elementId}${chunk7OK75CPY_js.TEXT_BUILD_ID_SEP}w${paraIndex}-0`;
4497
+ const firstWordKey = `${elementId}${chunkR47PKWUJ_js.TEXT_BUILD_ID_SEP}w${paraIndex}-0`;
4498
4498
  if (subElementAnimStates.has(firstWordKey)) {
4499
4499
  return wrapByWord(elementId, paraIndex, paraSegments, subElementAnimStates);
4500
4500
  }
4501
- const firstCharKey = `${elementId}${chunk7OK75CPY_js.TEXT_BUILD_ID_SEP}c${paraIndex}-0`;
4501
+ const firstCharKey = `${elementId}${chunkR47PKWUJ_js.TEXT_BUILD_ID_SEP}c${paraIndex}-0`;
4502
4502
  if (subElementAnimStates.has(firstCharKey)) {
4503
4503
  return wrapByChar(elementId, paraIndex, paraSegments, subElementAnimStates);
4504
4504
  }
@@ -4519,7 +4519,7 @@ function wrapByWord(elementId, paraIndex, paraSegments, states) {
4519
4519
  nodes.push(/* @__PURE__ */ jsxRuntime.jsx(React4__default.default.Fragment, { children: w }, `ws-${i}`));
4520
4520
  continue;
4521
4521
  }
4522
- const key = `${elementId}${chunk7OK75CPY_js.TEXT_BUILD_ID_SEP}w${paraIndex}-${wordIdx}`;
4522
+ const key = `${elementId}${chunkR47PKWUJ_js.TEXT_BUILD_ID_SEP}w${paraIndex}-${wordIdx}`;
4523
4523
  const state = states.get(key);
4524
4524
  const style = buildAnimStyle(state);
4525
4525
  nodes.push(
@@ -4533,7 +4533,7 @@ function wrapByChar(elementId, paraIndex, paraSegments, states) {
4533
4533
  const fullText = paraSegments.map((e) => e.segment.text).join("");
4534
4534
  const nodes = [];
4535
4535
  for (let i = 0; i < fullText.length; i++) {
4536
- const key = `${elementId}${chunk7OK75CPY_js.TEXT_BUILD_ID_SEP}c${paraIndex}-${i}`;
4536
+ const key = `${elementId}${chunkR47PKWUJ_js.TEXT_BUILD_ID_SEP}c${paraIndex}-${i}`;
4537
4537
  const state = states.get(key);
4538
4538
  const style = buildAnimStyle(state);
4539
4539
  nodes.push(
@@ -4679,10 +4679,10 @@ function renderScriptAwareText(text, needsScriptFonts, scriptFonts, baseFontFami
4679
4679
  if (!needsScriptFonts || !text) {
4680
4680
  return text;
4681
4681
  }
4682
- const runs = chunk7OK75CPY_js.segmentByScript(text);
4682
+ const runs = chunkR47PKWUJ_js.segmentByScript(text);
4683
4683
  if (runs.length <= 1) {
4684
4684
  if (runs.length === 1) {
4685
- const font = chunk7OK75CPY_js.resolveFontForScript(runs[0].script, scriptFonts);
4685
+ const font = chunkR47PKWUJ_js.resolveFontForScript(runs[0].script, scriptFonts);
4686
4686
  if (font && font !== baseFontFamily) {
4687
4687
  return /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontFamily: font }, children: text });
4688
4688
  }
@@ -4690,7 +4690,7 @@ function renderScriptAwareText(text, needsScriptFonts, scriptFonts, baseFontFami
4690
4690
  return text;
4691
4691
  }
4692
4692
  return runs.map((run, i) => {
4693
- const font = chunk7OK75CPY_js.resolveFontForScript(run.script, scriptFonts);
4693
+ const font = chunkR47PKWUJ_js.resolveFontForScript(run.script, scriptFonts);
4694
4694
  if (!font || font === baseFontFamily) {
4695
4695
  return /* @__PURE__ */ jsxRuntime.jsx(React4__default.default.Fragment, { children: run.text }, `${keyPrefix}-r${i}`);
4696
4696
  }
@@ -4762,8 +4762,8 @@ function renderSegmentContent(elementId, segmentIndex, textValue, lines, needsSc
4762
4762
  );
4763
4763
  }
4764
4764
  function renderEquationSegment(elementId, segmentIndex, equationXml, equationNumber) {
4765
- const mathml = chunk7OK75CPY_js.convertOmmlToMathMl(equationXml);
4766
- const safeMathml = mathml ? chunk7OK75CPY_js.sanitizeMathMl(mathml) : "";
4765
+ const mathml = chunkR47PKWUJ_js.convertOmmlToMathMl(equationXml);
4766
+ const safeMathml = mathml ? chunkR47PKWUJ_js.sanitizeMathMl(mathml) : "";
4767
4767
  const equationContent = safeMathml ? /* @__PURE__ */ jsxRuntime.jsx(
4768
4768
  "span",
4769
4769
  {
@@ -4813,7 +4813,7 @@ function renderEquationSegment(elementId, segmentIndex, equationXml, equationNum
4813
4813
  return /* @__PURE__ */ jsxRuntime.jsx("span", { children: equationContent }, `${elementId}-seg-${segmentIndex}`);
4814
4814
  }
4815
4815
  function renderPictureBullet(elementId, segmentIndex, bulletInfo, baseFontSize) {
4816
- const picture = chunk7OK75CPY_js.resolvePictureBullet(bulletInfo, baseFontSize) ?? {
4816
+ const picture = chunkR47PKWUJ_js.resolvePictureBullet(bulletInfo, baseFontSize) ?? {
4817
4817
  sizePx: baseFontSize,
4818
4818
  fallbackMarker: "\u2022",
4819
4819
  accessibleLabel: "Bullet"
@@ -4863,7 +4863,7 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
4863
4863
  );
4864
4864
  }
4865
4865
  const segmentStyle = segment.style || {};
4866
- const textValue = chunk7OK75CPY_js.substituteFieldText(segment.text || "", segment.fieldType, fieldContext);
4866
+ const textValue = chunkR47PKWUJ_js.substituteFieldText(segment.text || "", segment.fieldType, fieldContext);
4867
4867
  const lines = textValue.split("\n");
4868
4868
  const textDecorationTokens = [];
4869
4869
  if (segmentStyle.underline || segmentStyle.hyperlink) {
@@ -4873,8 +4873,8 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
4873
4873
  textDecorationTokens.push("line-through");
4874
4874
  }
4875
4875
  const isDoubleStrike = segmentStyle.strikethrough && segmentStyle.strikeType === "dblStrike";
4876
- const resolvedSegmentColor = segmentStyle.hyperlink ? chunk7OK75CPY_js.normalizeHexColor(segmentStyle.color || element.textStyle?.color, HYPERLINK_COLOR) : chunk7OK75CPY_js.normalizeHexColor(segmentStyle.color || element.textStyle?.color, fallbackColor);
4877
- const underlineDecoration = chunk7OK75CPY_js.resolveUnderlineDecorationStyle(
4876
+ const resolvedSegmentColor = segmentStyle.hyperlink ? chunkR47PKWUJ_js.normalizeHexColor(segmentStyle.color || element.textStyle?.color, HYPERLINK_COLOR) : chunkR47PKWUJ_js.normalizeHexColor(segmentStyle.color || element.textStyle?.color, fallbackColor);
4877
+ const underlineDecoration = chunkR47PKWUJ_js.resolveUnderlineDecorationStyle(
4878
4878
  Boolean(isDoubleStrike),
4879
4879
  segmentStyle.underlineStyle
4880
4880
  );
@@ -4890,14 +4890,14 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
4890
4890
  const baseFontSizePt = baseFontSize * (72 / 96);
4891
4891
  const fontKerning = typeof segmentStyle.kerning === "number" ? segmentStyle.kerning === 0 ? "none" : baseFontSizePt >= segmentStyle.kerning / 100 ? "normal" : "none" : void 0;
4892
4892
  const rawFontFamily = segmentStyle.fontFamily || element.textStyle?.fontFamily;
4893
- const baseFontFamily = rawFontFamily ? chunkZWG6IN7E_js.getSubstituteFontFamily(rawFontFamily) : DEFAULT_FONT_FAMILY;
4893
+ const baseFontFamily = rawFontFamily ? chunkRVKY3KGH_js.getSubstituteFontFamily(rawFontFamily) : DEFAULT_FONT_FAMILY;
4894
4894
  const scriptFonts = {
4895
4895
  latin: baseFontFamily,
4896
4896
  eastAsia: segmentStyle.eastAsiaFont || element.textStyle?.eastAsiaFont || baseFontFamily,
4897
4897
  complexScript: segmentStyle.complexScriptFont || element.textStyle?.complexScriptFont || baseFontFamily,
4898
4898
  symbol: segmentStyle.symbolFont || element.textStyle?.symbolFont || baseFontFamily
4899
4899
  };
4900
- const needsScriptFonts = chunk7OK75CPY_js.hasDistinctScriptFonts(scriptFonts);
4900
+ const needsScriptFonts = chunkR47PKWUJ_js.hasDistinctScriptFonts(scriptFonts);
4901
4901
  const spanStyle = {
4902
4902
  color: resolvedSegmentColor,
4903
4903
  fontSize: baseFontSize * baselineFontScale,
@@ -4915,15 +4915,15 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
4915
4915
  fontVariantCaps: segmentStyle.textCaps === "small" ? "small-caps" : void 0,
4916
4916
  letterSpacing,
4917
4917
  fontKerning,
4918
- backgroundColor: textFillStyles ? void 0 : segmentStyle.highlightColor ? chunk7OK75CPY_js.normalizeHexColor(segmentStyle.highlightColor, "transparent") : void 0,
4918
+ backgroundColor: textFillStyles ? void 0 : segmentStyle.highlightColor ? chunkR47PKWUJ_js.normalizeHexColor(segmentStyle.highlightColor, "transparent") : void 0,
4919
4919
  ...textFillStyles,
4920
- textDecorationColor: segmentStyle.underlineColor ? chunk7OK75CPY_js.normalizeHexColor(segmentStyle.underlineColor, void 0) : void 0,
4921
- WebkitTextStroke: segmentStyle.textOutlineWidth && segmentStyle.textOutlineColor ? `${segmentStyle.textOutlineWidth}px ${chunk7OK75CPY_js.normalizeHexColor(segmentStyle.textOutlineColor, "#000000")}` : segmentStyle.textOutlineWidth ? `${segmentStyle.textOutlineWidth}px currentColor` : void 0,
4920
+ textDecorationColor: segmentStyle.underlineColor ? chunkR47PKWUJ_js.normalizeHexColor(segmentStyle.underlineColor, void 0) : void 0,
4921
+ WebkitTextStroke: segmentStyle.textOutlineWidth && segmentStyle.textOutlineColor ? `${segmentStyle.textOutlineWidth}px ${chunkR47PKWUJ_js.normalizeHexColor(segmentStyle.textOutlineColor, "#000000")}` : segmentStyle.textOutlineWidth ? `${segmentStyle.textOutlineWidth}px currentColor` : void 0,
4922
4922
  paintOrder: segmentStyle.textOutlineWidth ? "stroke fill" : void 0,
4923
- textShadow: chunk7OK75CPY_js.buildTextShadowCss(segmentStyle),
4924
- filter: chunk7OK75CPY_js.buildTextRunFilterChain(segmentStyle),
4925
- opacity: chunk7OK75CPY_js.getTextAlphaOpacity(segmentStyle),
4926
- WebkitBoxReflect: chunk7OK75CPY_js.buildTextReflectionCss(segmentStyle)
4923
+ textShadow: chunkR47PKWUJ_js.buildTextShadowCss(segmentStyle),
4924
+ filter: chunkR47PKWUJ_js.buildTextRunFilterChain(segmentStyle),
4925
+ opacity: chunkR47PKWUJ_js.getTextAlphaOpacity(segmentStyle),
4926
+ WebkitBoxReflect: chunkR47PKWUJ_js.buildTextReflectionCss(segmentStyle)
4927
4927
  };
4928
4928
  const runRtl = segmentStyle.rtl;
4929
4929
  if (runRtl !== void 0 && runRtl !== paragraphRtl) {
@@ -4949,7 +4949,7 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
4949
4949
  spanStyle.fontSize = baseFontSize * (bulletInfo.sizePercent / 100) * baselineFontScale;
4950
4950
  }
4951
4951
  if (bulletInfo.color) {
4952
- spanStyle.color = chunk7OK75CPY_js.normalizeHexColor(bulletInfo.color, resolvedSegmentColor);
4952
+ spanStyle.color = chunkR47PKWUJ_js.normalizeHexColor(bulletInfo.color, resolvedSegmentColor);
4953
4953
  }
4954
4954
  }
4955
4955
  if (bulletInfo?.imageDataUrl || bulletInfo?.imageRelId) {
@@ -4989,7 +4989,7 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
4989
4989
  textAlign: segment.rubyAlignment === "l" ? "left" : segment.rubyAlignment === "r" ? "right" : segment.rubyAlignment === "dist" || segment.rubyAlignment === "distCat" || segment.rubyAlignment === "distLetter" ? "justify" : "center"
4990
4990
  };
4991
4991
  if (segment.rubyStyle?.color) {
4992
- rubyStyle.color = chunk7OK75CPY_js.normalizeHexColor(segment.rubyStyle.color, resolvedSegmentColor);
4992
+ rubyStyle.color = chunkR47PKWUJ_js.normalizeHexColor(segment.rubyStyle.color, resolvedSegmentColor);
4993
4993
  }
4994
4994
  innerContent = /* @__PURE__ */ jsxRuntime.jsxs("ruby", { children: [
4995
4995
  baseContent,
@@ -5105,7 +5105,7 @@ function groupSegmentsIntoParagraphs(segments) {
5105
5105
  return paragraphs;
5106
5106
  }
5107
5107
  function renderTextSegments(element, fallbackColor, emptyFallback, findHighlights, onHyperlinkClick, fieldContext, subElementAnimStates, segmentOverrides, requireCtrlClick) {
5108
- if (!chunkZWG6IN7E_js.hasTextProperties(element)) {
5108
+ if (!chunkRVKY3KGH_js.hasTextProperties(element)) {
5109
5109
  return emptyFallback || null;
5110
5110
  }
5111
5111
  const effectiveSegments = segmentOverrides ?? element.textSegments;
@@ -5126,10 +5126,10 @@ function renderTextSegments(element, fallbackColor, emptyFallback, findHighlight
5126
5126
  return element.text || emptyFallback || "";
5127
5127
  }
5128
5128
  const paragraphs = groupSegmentsIntoParagraphs(effectiveSegments);
5129
- const paragraphIndents = chunkZWG6IN7E_js.hasTextProperties(element) ? element.paragraphIndents : void 0;
5130
- const elementRtl = chunkZWG6IN7E_js.hasTextProperties(element) ? element.textStyle?.rtl : void 0;
5131
- const elementAlign = chunkZWG6IN7E_js.hasTextProperties(element) ? element.textStyle?.align : void 0;
5132
- const bodyStyle = chunkZWG6IN7E_js.hasTextProperties(element) ? element.textStyle : void 0;
5129
+ const paragraphIndents = chunkRVKY3KGH_js.hasTextProperties(element) ? element.paragraphIndents : void 0;
5130
+ const elementRtl = chunkRVKY3KGH_js.hasTextProperties(element) ? element.textStyle?.rtl : void 0;
5131
+ const elementAlign = chunkRVKY3KGH_js.hasTextProperties(element) ? element.textStyle?.align : void 0;
5132
+ const bodyStyle = chunkRVKY3KGH_js.hasTextProperties(element) ? element.textStyle : void 0;
5133
5133
  const spaceFirstLast = bodyStyle?.spaceFirstLastParagraph === true;
5134
5134
  return paragraphs.map((paraSegments, paraIndex) => {
5135
5135
  const paraIndent = paragraphIndents?.[paraIndex];
@@ -5149,14 +5149,14 @@ function renderTextSegments(element, fallbackColor, emptyFallback, findHighlight
5149
5149
  return Boolean(segment.text) && segment.text.trim().length > 0;
5150
5150
  });
5151
5151
  const hasBullet = bulletInfo && !bulletInfo.none && hasVisibleTextContent && !hasDuplicateAuthoredAutoNumber;
5152
- const paraRtl = chunk7OK75CPY_js.resolveParagraphRtl(paraSegments, elementRtl);
5152
+ const paraRtl = chunkR47PKWUJ_js.resolveParagraphRtl(paraSegments, elementRtl);
5153
5153
  const isRtlParagraph = paraRtl === true;
5154
- const paraAlign = chunk7OK75CPY_js.resolveParagraphAlign(paraSegments, elementAlign);
5155
- const cssTextAlign = chunk7OK75CPY_js.resolveCssTextAlign(paraAlign, isRtlParagraph);
5154
+ const paraAlign = chunkR47PKWUJ_js.resolveParagraphAlign(paraSegments, elementAlign);
5155
+ const cssTextAlign = chunkR47PKWUJ_js.resolveCssTextAlign(paraAlign, isRtlParagraph);
5156
5156
  const paraMarginLeft = isRtlParagraph ? void 0 : rawMarginLeft;
5157
5157
  const paraMarginRight = isRtlParagraph ? rawMarginLeft : void 0;
5158
5158
  const paraTextIndent = rawTextIndent;
5159
- const paraKinsokuStyle = chunk7OK75CPY_js.getKinsokuLineBreakStyles(firstSeg?.segment.style);
5159
+ const paraKinsokuStyle = chunkR47PKWUJ_js.getKinsokuLineBreakStyles(firstSeg?.segment.style);
5160
5160
  const hasParaKinsoku = Object.keys(paraKinsokuStyle).length > 0;
5161
5161
  const paraProps = effectiveSegments[firstSeg?.globalIndex ?? -1]?.paragraphProperties;
5162
5162
  const effectiveParaProps = {
@@ -5364,7 +5364,7 @@ function isConnectorOrLineElement(element) {
5364
5364
  if (element.type === "connector") {
5365
5365
  return true;
5366
5366
  }
5367
- if (!chunkZWG6IN7E_js.hasShapeProperties(element)) {
5367
+ if (!chunkRVKY3KGH_js.hasShapeProperties(element)) {
5368
5368
  return false;
5369
5369
  }
5370
5370
  const st = getShapeType(element.shapeType);
@@ -5382,13 +5382,13 @@ function hexToRgbUnit(hex) {
5382
5382
  };
5383
5383
  }
5384
5384
  function getDuotoneColors(element) {
5385
- if (!chunkZWG6IN7E_js.isImageLikeElement(element)) {
5385
+ if (!chunkRVKY3KGH_js.isImageLikeElement(element)) {
5386
5386
  return void 0;
5387
5387
  }
5388
5388
  return element.imageEffects?.duotone;
5389
5389
  }
5390
5390
  function buildLineShadowCss(element) {
5391
- if (!chunkZWG6IN7E_js.hasShapeProperties(element)) {
5391
+ if (!chunkRVKY3KGH_js.hasShapeProperties(element)) {
5392
5392
  return void 0;
5393
5393
  }
5394
5394
  const ss = element.shapeStyle;
@@ -5399,13 +5399,13 @@ function buildLineShadowCss(element) {
5399
5399
  const offsetY = typeof ss.lineShadowOffsetY === "number" ? ss.lineShadowOffsetY : 2;
5400
5400
  const blur = typeof ss.lineShadowBlur === "number" ? Math.max(0, ss.lineShadowBlur) : 4;
5401
5401
  const opacity = typeof ss.lineShadowOpacity === "number" ? Math.max(0, Math.min(1, ss.lineShadowOpacity)) : 0.35;
5402
- return `${Math.round(offsetX)}px ${Math.round(offsetY)}px ${Math.round(blur)}px ${chunk7OK75CPY_js.colorWithOpacity(
5403
- chunk7OK75CPY_js.normalizeHexColor(ss.lineShadowColor, "#000000"),
5402
+ return `${Math.round(offsetX)}px ${Math.round(offsetY)}px ${Math.round(blur)}px ${chunkR47PKWUJ_js.colorWithOpacity(
5403
+ chunkR47PKWUJ_js.normalizeHexColor(ss.lineShadowColor, "#000000"),
5404
5404
  opacity
5405
5405
  )}`;
5406
5406
  }
5407
5407
  function buildLineGlowFilter(element) {
5408
- if (!chunkZWG6IN7E_js.hasShapeProperties(element)) {
5408
+ if (!chunkRVKY3KGH_js.hasShapeProperties(element)) {
5409
5409
  return void 0;
5410
5410
  }
5411
5411
  const ss = element.shapeStyle;
@@ -5414,7 +5414,7 @@ function buildLineGlowFilter(element) {
5414
5414
  }
5415
5415
  const glowOpacity = typeof ss.lineGlowOpacity === "number" ? ss.lineGlowOpacity : 0.75;
5416
5416
  const glowRad = Math.round(Math.max(0, ss.lineGlowRadius));
5417
- const glowCol = chunk7OK75CPY_js.colorWithOpacity(chunk7OK75CPY_js.normalizeHexColor(ss.lineGlowColor, "#ffff00"), glowOpacity);
5417
+ const glowCol = chunkR47PKWUJ_js.colorWithOpacity(chunkR47PKWUJ_js.normalizeHexColor(ss.lineGlowColor, "#ffff00"), glowOpacity);
5418
5418
  return `drop-shadow(0 0 ${glowRad}px ${glowCol})`;
5419
5419
  }
5420
5420
  function mapDagBlendModeToCss(blend) {
@@ -5438,7 +5438,7 @@ function getDagDuotoneFilterId(elementId) {
5438
5438
  return `dag-duotone-${elementId}`;
5439
5439
  }
5440
5440
  function hasDagDuotoneEffect(element) {
5441
- if (!chunkZWG6IN7E_js.hasShapeProperties(element)) {
5441
+ if (!chunkRVKY3KGH_js.hasShapeProperties(element)) {
5442
5442
  return false;
5443
5443
  }
5444
5444
  return Boolean(element.shapeStyle?.dagDuotone);
@@ -5501,7 +5501,7 @@ function getRoundRectRadiusPx2(element) {
5501
5501
 
5502
5502
  // src/viewer/utils/shape-visual-3d.ts
5503
5503
  function build3DExtrusionData2(shape3d, scene3d, fillColor, elementWidth, elementHeight) {
5504
- return chunk7OK75CPY_js.build3DExtrusionData(
5504
+ return chunkR47PKWUJ_js.build3DExtrusionData(
5505
5505
  shape3d,
5506
5506
  scene3d,
5507
5507
  fillColor,
@@ -5510,7 +5510,7 @@ function build3DExtrusionData2(shape3d, scene3d, fillColor, elementWidth, elemen
5510
5510
  );
5511
5511
  }
5512
5512
  function apply3dEffects2(base, scene3d, shape3d, fillColorFallback) {
5513
- chunk7OK75CPY_js.apply3dEffects(base, scene3d, shape3d, fillColorFallback);
5513
+ chunkR47PKWUJ_js.apply3dEffects(base, scene3d, shape3d, fillColorFallback);
5514
5514
  }
5515
5515
 
5516
5516
  // src/viewer/utils/vector-subpath-paint.ts
@@ -5519,7 +5519,7 @@ function toHexByte(value) {
5519
5519
  return clamped.toString(16).padStart(2, "0");
5520
5520
  }
5521
5521
  function shiftHex(hex, factor, towardsWhite) {
5522
- const channels = chunk7OK75CPY_js.hexToRgbChannels(hex);
5522
+ const channels = chunkR47PKWUJ_js.hexToRgbChannels(hex);
5523
5523
  if (!channels) {
5524
5524
  return hex;
5525
5525
  }
@@ -5545,13 +5545,13 @@ function buildCustomSubpathPaints(subpaths, hasFill, fillColor, fillOpacity) {
5545
5545
  const fillOff = subpath.fillMode === "none" || !hasFill;
5546
5546
  return {
5547
5547
  d: subpath.d,
5548
- fill: fillOff ? "none" : chunk7OK75CPY_js.colorWithOpacity(adjustFillForMode(fillColor, subpath.fillMode), fillOpacity),
5548
+ fill: fillOff ? "none" : chunkR47PKWUJ_js.colorWithOpacity(adjustFillForMode(fillColor, subpath.fillMode), fillOpacity),
5549
5549
  stroked: subpath.stroke !== false
5550
5550
  };
5551
5551
  });
5552
5552
  }
5553
5553
  function getStrokeOnlyPresetPaths(element) {
5554
- if (element.type !== "shape" || !chunkZWG6IN7E_js.hasShapeProperties(element)) {
5554
+ if (element.type !== "shape" || !chunkRVKY3KGH_js.hasShapeProperties(element)) {
5555
5555
  return void 0;
5556
5556
  }
5557
5557
  const shapeType = element.shapeType;
@@ -5561,7 +5561,7 @@ function getStrokeOnlyPresetPaths(element) {
5561
5561
  if (element.pathData) {
5562
5562
  return void 0;
5563
5563
  }
5564
- const result = chunkZWG6IN7E_js.evaluatePresetShape(
5564
+ const result = chunkRVKY3KGH_js.evaluatePresetShape(
5565
5565
  shapeType,
5566
5566
  Math.max(element.width, 1),
5567
5567
  Math.max(element.height, 1),
@@ -5576,27 +5576,27 @@ function getStrokeOnlyPresetPaths(element) {
5576
5576
 
5577
5577
  // src/viewer/utils/shape-visual-style.ts
5578
5578
  function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeColor, animatesFill, animatesStroke) {
5579
- if (!chunkZWG6IN7E_js.hasShapeProperties(element)) {
5579
+ if (!chunkRVKY3KGH_js.hasShapeProperties(element)) {
5580
5580
  return {};
5581
5581
  }
5582
5582
  const normalizedShapeType = getShapeType(element.shapeType);
5583
- const clipPath = chunk7OK75CPY_js.getResolvedShapeClipPath(element);
5583
+ const clipPath = chunkR47PKWUJ_js.getResolvedShapeClipPath(element);
5584
5584
  const rendersCustomVectorPath = (element.type === "shape" || element.type === "image" || element.type === "picture") && Boolean(element.pathData) && typeof element.pathWidth === "number" && element.pathWidth > 0 && typeof element.pathHeight === "number" && element.pathHeight > 0;
5585
5585
  const rendersStrokeOnlyPreset = Boolean(getStrokeOnlyPresetPaths(element));
5586
5586
  const fillOpacity = element.shapeStyle?.fillOpacity;
5587
5587
  const strokeOpacity = element.shapeStyle?.strokeOpacity;
5588
- const strokeDash = chunk7OK75CPY_js.normalizeStrokeDashType(element.shapeStyle?.strokeDash);
5589
- const fillGradient = chunk7OK75CPY_js.buildCssGradientFromShapeStyle(element.shapeStyle) || element.shapeStyle?.fillGradient;
5590
- const shadowCss = chunk7OK75CPY_js.buildShadowCssFromShapeStyle(element.shapeStyle);
5591
- const innerShadowCss = chunk7OK75CPY_js.buildInnerShadowCssFromShapeStyle(element.shapeStyle);
5592
- const resolvedFillColor = chunk7OK75CPY_js.colorWithOpacity(fillColor, fillOpacity);
5593
- const resolvedStrokeColor = chunk7OK75CPY_js.colorWithOpacity(strokeColor, strokeOpacity);
5588
+ const strokeDash = chunkR47PKWUJ_js.normalizeStrokeDashType(element.shapeStyle?.strokeDash);
5589
+ const fillGradient = chunkR47PKWUJ_js.buildCssGradientFromShapeStyle(element.shapeStyle) || element.shapeStyle?.fillGradient;
5590
+ const shadowCss = chunkR47PKWUJ_js.buildShadowCssFromShapeStyle(element.shapeStyle);
5591
+ const innerShadowCss = chunkR47PKWUJ_js.buildInnerShadowCssFromShapeStyle(element.shapeStyle);
5592
+ const resolvedFillColor = chunkR47PKWUJ_js.colorWithOpacity(fillColor, fillOpacity);
5593
+ const resolvedStrokeColor = chunkR47PKWUJ_js.colorWithOpacity(strokeColor, strokeOpacity);
5594
5594
  const ss = element.shapeStyle;
5595
5595
  const hasFillOverlayColor = Boolean(
5596
5596
  ss?.dagFillOverlayColor && ss.dagFillOverlayColor !== "transparent"
5597
5597
  );
5598
5598
  const combinedShadowParts = [];
5599
- const multiLayerShadow = chunk7OK75CPY_js.buildMultiLayerShadowCss(element.shapeStyle);
5599
+ const multiLayerShadow = chunkR47PKWUJ_js.buildMultiLayerShadowCss(element.shapeStyle);
5600
5600
  if (multiLayerShadow) {
5601
5601
  combinedShadowParts.push(multiLayerShadow);
5602
5602
  } else if (shadowCss) {
@@ -5605,7 +5605,7 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
5605
5605
  if (innerShadowCss) {
5606
5606
  combinedShadowParts.push(innerShadowCss);
5607
5607
  }
5608
- const glowBoxShadow = chunk7OK75CPY_js.buildGlowBoxShadow(ss?.glowColor, ss?.glowRadius, ss?.glowOpacity);
5608
+ const glowBoxShadow = chunkR47PKWUJ_js.buildGlowBoxShadow(ss?.glowColor, ss?.glowRadius, ss?.glowOpacity);
5609
5609
  if (glowBoxShadow) {
5610
5610
  combinedShadowParts.push(glowBoxShadow);
5611
5611
  }
@@ -5613,7 +5613,7 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
5613
5613
  if (lineShadow) {
5614
5614
  combinedShadowParts.push(lineShadow);
5615
5615
  }
5616
- const compoundLineShadow = chunk7OK75CPY_js.getCompoundLineBoxShadow(
5616
+ const compoundLineShadow = chunkR47PKWUJ_js.getCompoundLineBoxShadow(
5617
5617
  element.shapeStyle?.compoundLine,
5618
5618
  strokeWidth,
5619
5619
  resolvedStrokeColor
@@ -5626,11 +5626,11 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
5626
5626
  if (ss?.glowColor && ss.glowColor !== "transparent" && ss.glowRadius) {
5627
5627
  const glowOpacity = typeof ss.glowOpacity === "number" ? ss.glowOpacity : 0.75;
5628
5628
  const glowRad = Math.round(Math.max(0, ss.glowRadius));
5629
- const glowCol = chunk7OK75CPY_js.colorWithOpacity(chunk7OK75CPY_js.normalizeHexColor(ss.glowColor, "#ffff00"), glowOpacity);
5629
+ const glowCol = chunkR47PKWUJ_js.colorWithOpacity(chunkR47PKWUJ_js.normalizeHexColor(ss.glowColor, "#ffff00"), glowOpacity);
5630
5630
  filterParts.push(`drop-shadow(0 0 ${glowRad}px ${glowCol})`);
5631
5631
  }
5632
5632
  if (typeof ss?.softEdgeRadius === "number" && ss.softEdgeRadius > 0) {
5633
- filterParts.push(`url(#${chunk7OK75CPY_js.getSoftEdgeFilterId(element.id)})`);
5633
+ filterParts.push(`url(#${chunkR47PKWUJ_js.getSoftEdgeFilterId(element.id)})`);
5634
5634
  }
5635
5635
  if (typeof ss?.blurRadius === "number" && ss.blurRadius > 0) {
5636
5636
  filterParts.push(`blur(${Math.round(ss.blurRadius)}px)`);
@@ -5639,13 +5639,13 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
5639
5639
  if (lineGlowCss) {
5640
5640
  filterParts.push(lineGlowCss);
5641
5641
  }
5642
- const dagFilter = chunk7OK75CPY_js.getEffectDagFilter(ss, element.id);
5642
+ const dagFilter = chunkR47PKWUJ_js.getEffectDagFilter(ss, element.id);
5643
5643
  if (dagFilter) {
5644
5644
  filterParts.push(dagFilter);
5645
5645
  }
5646
5646
  const lineJoinCss = ss?.lineJoin === "round" ? "round" : ss?.lineJoin === "bevel" ? "bevel" : ss?.lineJoin === "miter" ? "miter" : void 0;
5647
5647
  const miterLimitCss = ss?.lineJoin === "miter" && typeof ss?.miterLimit === "number" ? Math.max(ss.miterLimit / 1e5, 1) : void 0;
5648
- const patternFill = chunk7OK75CPY_js.buildPatternFillCss(element.shapeStyle);
5648
+ const patternFill = chunkR47PKWUJ_js.buildPatternFillCss(element.shapeStyle);
5649
5649
  const imageFillUrl = ss?.fillMode === "image" && ss.fillImageUrl ? ss.fillImageUrl : void 0;
5650
5650
  const imageFillMode = ss?.fillImageMode || "stretch";
5651
5651
  let reflectCss;
@@ -5657,7 +5657,7 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
5657
5657
  const endOpacity = typeof ss.reflectionEndOpacity === "number" ? ss.reflectionEndOpacity : 0;
5658
5658
  const fadeLength = typeof ss.reflectionEndPosition === "number" ? Math.round(ss.reflectionEndPosition * Math.max(element.height, 1)) : 100;
5659
5659
  const blurRadius = typeof ss.reflectionBlurRadius === "number" ? ss.reflectionBlurRadius : 0;
5660
- reflectCss = chunk7OK75CPY_js.buildReflectionCss(distance, startOpacity, endOpacity, fadeLength, blurRadius);
5660
+ reflectCss = chunkR47PKWUJ_js.buildReflectionCss(distance, startOpacity, endOpacity, fadeLength, blurRadius);
5661
5661
  }
5662
5662
  }
5663
5663
  const base = {
@@ -5675,9 +5675,9 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
5675
5675
  // is present, `ShapeEffectOverlay` paints a separate blended tint layer so
5676
5676
  // the colour is actually rendered (and text/children are not tinted).
5677
5677
  mixBlendMode: hasFillOverlayColor ? void 0 : mapDagBlendModeToCss(ss?.dagFillOverlayBlend),
5678
- borderWidth: strokeWidth > 0 ? chunk7OK75CPY_js.getCompoundLineBorderWidth(ss?.compoundLine, strokeWidth) : void 0,
5678
+ borderWidth: strokeWidth > 0 ? chunkR47PKWUJ_js.getCompoundLineBorderWidth(ss?.compoundLine, strokeWidth) : void 0,
5679
5679
  borderColor: strokeWidth > 0 ? resolvedStrokeColor : void 0,
5680
- borderStyle: strokeWidth > 0 ? chunk7OK75CPY_js.getCssBorderDashStyle(strokeDash, ss?.compoundLine) : void 0,
5680
+ borderStyle: strokeWidth > 0 ? chunkR47PKWUJ_js.getCssBorderDashStyle(strokeDash, ss?.compoundLine) : void 0,
5681
5681
  strokeLinejoin: lineJoinCss,
5682
5682
  strokeMiterlimit: miterLimitCss,
5683
5683
  strokeLinecap: ss?.lineCap === "rnd" ? "round" : ss?.lineCap === "sq" ? "square" : ss?.lineCap === "flat" ? "butt" : void 0
@@ -5733,7 +5733,7 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
5733
5733
  borderWidth: 0,
5734
5734
  borderTopWidth: Math.max(strokeWidth, 2),
5735
5735
  borderTopColor: resolvedStrokeColor,
5736
- borderTopStyle: chunk7OK75CPY_js.getCssBorderDashStyle(strokeDash)
5736
+ borderTopStyle: chunkR47PKWUJ_js.getCssBorderDashStyle(strokeDash)
5737
5737
  };
5738
5738
  }
5739
5739
  if (normalizedShapeType === "cylinder") {
@@ -5747,13 +5747,13 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
5747
5747
  function getConnectorAdjustment(element, key, fallback) {
5748
5748
  const direct = element.shapeAdjustments?.[key];
5749
5749
  if (typeof direct === "number" && Number.isFinite(direct)) {
5750
- return chunk7OK75CPY_js.clampUnitInterval(direct / 1e5);
5750
+ return chunkR47PKWUJ_js.clampUnitInterval(direct / 1e5);
5751
5751
  }
5752
5752
  const fallbackKey = element.shapeAdjustments?.adj;
5753
5753
  if (typeof fallbackKey === "number" && Number.isFinite(fallbackKey)) {
5754
- return chunk7OK75CPY_js.clampUnitInterval(fallbackKey / 1e5);
5754
+ return chunkR47PKWUJ_js.clampUnitInterval(fallbackKey / 1e5);
5755
5755
  }
5756
- return chunk7OK75CPY_js.clampUnitInterval(fallback);
5756
+ return chunkR47PKWUJ_js.clampUnitInterval(fallback);
5757
5757
  }
5758
5758
  function getConnectorPathGeometry(element) {
5759
5759
  const width = Math.max(element.width, 1);
@@ -5890,11 +5890,11 @@ function strokeContext(shapeStyle, strokePaint, strokeWidth, dashArray) {
5890
5890
  strokePaint,
5891
5891
  strokeWidth,
5892
5892
  dashArray,
5893
- lineCap: chunk7OK75CPY_js.svgLineCap(shapeStyle?.lineCap),
5893
+ lineCap: chunkR47PKWUJ_js.svgLineCap(shapeStyle?.lineCap),
5894
5894
  lineJoin,
5895
5895
  miterLimit,
5896
- offsets: chunk7OK75CPY_js.getCompoundLineOffsets(shapeStyle?.compoundLine, strokeWidth),
5897
- widths: chunk7OK75CPY_js.getCompoundLineWidths(shapeStyle?.compoundLine, strokeWidth)
5896
+ offsets: chunkR47PKWUJ_js.getCompoundLineOffsets(shapeStyle?.compoundLine, strokeWidth),
5897
+ widths: chunkR47PKWUJ_js.getCompoundLineWidths(shapeStyle?.compoundLine, strokeWidth)
5898
5898
  };
5899
5899
  }
5900
5900
  function strokeStrands(d, keyBase, ctx) {
@@ -5952,7 +5952,7 @@ function renderCustomGeometryVector(pathData, pathWidth, pathHeight, structuredP
5952
5952
  ) });
5953
5953
  }
5954
5954
  const customFillPaint = gradientId ? `url(#${gradientId})` : void 0;
5955
- const subpaths = structuredPaths && structuredPaths.length > 0 ? chunkZWG6IN7E_js.customGeometryPathsToSvgSubpaths(structuredPaths, pathWidth, pathHeight) : void 0;
5955
+ const subpaths = structuredPaths && structuredPaths.length > 0 ? chunkRVKY3KGH_js.customGeometryPathsToSvgSubpaths(structuredPaths, pathWidth, pathHeight) : void 0;
5956
5956
  const needsPerSubpath = subpaths !== void 0 && subpaths.some((sp) => sp.fillMode && sp.fillMode !== "norm" || sp.stroke === false);
5957
5957
  const nodes = [];
5958
5958
  if (subpaths && needsPerSubpath) {
@@ -5983,7 +5983,7 @@ function renderCustomGeometryVector(pathData, pathWidth, pathHeight, structuredP
5983
5983
  "path",
5984
5984
  {
5985
5985
  d: pathData,
5986
- fill: animatesFill ? "inherit" : customFillPaint ?? chunk7OK75CPY_js.colorWithOpacity(fillColor, fillOpacity),
5986
+ fill: animatesFill ? "inherit" : customFillPaint ?? chunkR47PKWUJ_js.colorWithOpacity(fillColor, fillOpacity),
5987
5987
  stroke: "none",
5988
5988
  vectorEffect: "non-scaling-stroke"
5989
5989
  },
@@ -6028,14 +6028,14 @@ function renderStrokeOnlyPreset(presetPaths, width, height, shapeStyle, strokePa
6028
6028
  );
6029
6029
  }
6030
6030
  function renderVectorShape(element, hasFill, fillColor, strokeWidth, strokeColor, animatesFill, animatesStroke) {
6031
- if (!chunkZWG6IN7E_js.hasShapeProperties(element)) {
6031
+ if (!chunkRVKY3KGH_js.hasShapeProperties(element)) {
6032
6032
  return null;
6033
6033
  }
6034
6034
  const normalizedType = (element.shapeType || "").toLowerCase();
6035
- const fillPaint = animatesFill ? "inherit" : chunk7OK75CPY_js.colorWithOpacity(fillColor, element.shapeStyle?.fillOpacity);
6036
- const strokePaint = animatesStroke ? "inherit" : chunk7OK75CPY_js.colorWithOpacity(strokeColor, element.shapeStyle?.strokeOpacity);
6037
- const dashType = chunk7OK75CPY_js.normalizeStrokeDashType(element.shapeStyle?.strokeDash);
6038
- const dashArray = chunk7OK75CPY_js.getSvgStrokeDasharray(
6035
+ const fillPaint = animatesFill ? "inherit" : chunkR47PKWUJ_js.colorWithOpacity(fillColor, element.shapeStyle?.fillOpacity);
6036
+ const strokePaint = animatesStroke ? "inherit" : chunkR47PKWUJ_js.colorWithOpacity(strokeColor, element.shapeStyle?.strokeOpacity);
6037
+ const dashType = chunkR47PKWUJ_js.normalizeStrokeDashType(element.shapeStyle?.strokeDash);
6038
+ const dashArray = chunkR47PKWUJ_js.getSvgStrokeDasharray(
6039
6039
  dashType,
6040
6040
  Math.max(strokeWidth, 1),
6041
6041
  element.shapeStyle?.customDashSegments
@@ -6114,18 +6114,18 @@ function renderVectorShape(element, hasFill, fillColor, strokeWidth, strokeColor
6114
6114
  Boolean(animatesFill)
6115
6115
  );
6116
6116
  }
6117
- if (chunkZWG6IN7E_js.isCalloutShape(normalizedType)) {
6117
+ if (chunkRVKY3KGH_js.isCalloutShape(normalizedType)) {
6118
6118
  const width = Math.max(element.width, 1);
6119
6119
  const height = Math.max(element.height, 1);
6120
- const geometry = chunkZWG6IN7E_js.getCalloutLeaderLineGeometry(
6120
+ const geometry = chunkRVKY3KGH_js.getCalloutLeaderLineGeometry(
6121
6121
  normalizedType,
6122
6122
  width,
6123
6123
  height,
6124
6124
  element.shapeAdjustments
6125
6125
  );
6126
6126
  if (geometry && geometry.points.length >= 2) {
6127
- const leaderPath = chunkZWG6IN7E_js.buildCalloutLeaderLineSvgPath(geometry);
6128
- const bounds = chunkZWG6IN7E_js.getCalloutViewBoxBounds(width, height, geometry);
6127
+ const leaderPath = chunkRVKY3KGH_js.buildCalloutLeaderLineSvgPath(geometry);
6128
+ const bounds = chunkRVKY3KGH_js.getCalloutViewBoxBounds(width, height, geometry);
6129
6129
  const lineStroke = Math.max(strokeWidth, 1);
6130
6130
  const offsetLeft = bounds.minX;
6131
6131
  const offsetTop = bounds.minY;
@@ -6188,10 +6188,10 @@ function renderVectorShape(element, hasFill, fillColor, strokeWidth, strokeColor
6188
6188
  const endArrowW = element.shapeStyle?.connectorEndArrowWidth;
6189
6189
  const endArrowL = element.shapeStyle?.connectorEndArrowLength;
6190
6190
  const compoundLine = element.shapeStyle?.compoundLine;
6191
- const connectorLineCap = chunk7OK75CPY_js.svgLineCap(element.shapeStyle?.lineCap);
6191
+ const connectorLineCap = chunkR47PKWUJ_js.svgLineCap(element.shapeStyle?.lineCap);
6192
6192
  const hitTargetWidth = Math.max(strokeWidth * 3, 12);
6193
- const offsets = chunk7OK75CPY_js.getCompoundLineOffsets(compoundLine, strokeWidth);
6194
- const widths = chunk7OK75CPY_js.getCompoundLineWidths(compoundLine, strokeWidth);
6193
+ const offsets = chunkR47PKWUJ_js.getCompoundLineOffsets(compoundLine, strokeWidth);
6194
+ const widths = chunkR47PKWUJ_js.getCompoundLineWidths(compoundLine, strokeWidth);
6195
6195
  return /* @__PURE__ */ jsxRuntime.jsxs(
6196
6196
  "svg",
6197
6197
  {
@@ -6257,7 +6257,7 @@ function renderVectorShape(element, hasFill, fillColor, strokeWidth, strokeColor
6257
6257
 
6258
6258
  // src/viewer/utils/image-style.ts
6259
6259
  function getImageMaskStyle(element) {
6260
- if (!chunkZWG6IN7E_js.hasShapeProperties(element)) {
6260
+ if (!chunkRVKY3KGH_js.hasShapeProperties(element)) {
6261
6261
  return void 0;
6262
6262
  }
6263
6263
  const shapeType = element.shapeType;
@@ -6266,7 +6266,7 @@ function getImageMaskStyle(element) {
6266
6266
  }
6267
6267
  const normalized = shapeType.toLowerCase();
6268
6268
  if (normalized === "roundrect" || normalized === "round1rect" || normalized === "round2samerect" || normalized === "round2diagrect" || normalized === "sniproundrect" || normalized === "snip1rect" || normalized === "snip2diagrect") {
6269
- const radiusPx = chunk7OK75CPY_js.getRoundRectRadiusPx(element);
6269
+ const radiusPx = chunkR47PKWUJ_js.getRoundRectRadiusPx(element);
6270
6270
  if (radiusPx <= 0.01) {
6271
6271
  return void 0;
6272
6272
  }
@@ -6278,7 +6278,7 @@ function getImageMaskStyle(element) {
6278
6278
  if (normalized === "can" || normalized === "cylinder") {
6279
6279
  return { borderRadius: "48% / 12%" };
6280
6280
  }
6281
- const clipPath = chunk7OK75CPY_js.getResolvedShapeClipPath(element);
6281
+ const clipPath = chunkR47PKWUJ_js.getResolvedShapeClipPath(element);
6282
6282
  if (!clipPath) {
6283
6283
  return void 0;
6284
6284
  }
@@ -6286,7 +6286,7 @@ function getImageMaskStyle(element) {
6286
6286
  }
6287
6287
  function getImageRenderStyle(element) {
6288
6288
  const maskStyle = getImageMaskStyle(element) || {};
6289
- if (!chunkZWG6IN7E_js.isImageLikeElement(element)) {
6289
+ if (!chunkRVKY3KGH_js.isImageLikeElement(element)) {
6290
6290
  return {
6291
6291
  ...maskStyle,
6292
6292
  width: "100%",
@@ -6294,10 +6294,10 @@ function getImageRenderStyle(element) {
6294
6294
  objectFit: "cover"
6295
6295
  };
6296
6296
  }
6297
- const cropLeft = chunk7OK75CPY_js.clampCropValue(element.cropLeft);
6298
- const cropTop = chunk7OK75CPY_js.clampCropValue(element.cropTop);
6299
- const cropRight = chunk7OK75CPY_js.clampCropValue(element.cropRight);
6300
- const cropBottom = chunk7OK75CPY_js.clampCropValue(element.cropBottom);
6297
+ const cropLeft = chunkR47PKWUJ_js.clampCropValue(element.cropLeft);
6298
+ const cropTop = chunkR47PKWUJ_js.clampCropValue(element.cropTop);
6299
+ const cropRight = chunkR47PKWUJ_js.clampCropValue(element.cropRight);
6300
+ const cropBottom = chunkR47PKWUJ_js.clampCropValue(element.cropBottom);
6301
6301
  const hasCrop = cropLeft + cropRight > 1e-4 || cropTop + cropBottom > 1e-4;
6302
6302
  if (!hasCrop) {
6303
6303
  return {
@@ -6313,10 +6313,10 @@ function getImageRenderStyle(element) {
6313
6313
  }
6314
6314
  const safeHorizontalScale = cropLeft + cropRight >= 0.99 ? 0.99 / (cropLeft + cropRight) : 1;
6315
6315
  const safeVerticalScale = cropTop + cropBottom >= 0.99 ? 0.99 / (cropTop + cropBottom) : 1;
6316
- const normalizedLeft = chunk7OK75CPY_js.clampCropValue(cropLeft * safeHorizontalScale);
6317
- const normalizedRight = chunk7OK75CPY_js.clampCropValue(cropRight * safeHorizontalScale);
6318
- const normalizedTop = chunk7OK75CPY_js.clampCropValue(cropTop * safeVerticalScale);
6319
- const normalizedBottom = chunk7OK75CPY_js.clampCropValue(cropBottom * safeVerticalScale);
6316
+ const normalizedLeft = chunkR47PKWUJ_js.clampCropValue(cropLeft * safeHorizontalScale);
6317
+ const normalizedRight = chunkR47PKWUJ_js.clampCropValue(cropRight * safeHorizontalScale);
6318
+ const normalizedTop = chunkR47PKWUJ_js.clampCropValue(cropTop * safeVerticalScale);
6319
+ const normalizedBottom = chunkR47PKWUJ_js.clampCropValue(cropBottom * safeVerticalScale);
6320
6320
  const remainingWidth = Math.max(0.01, 1 - normalizedLeft - normalizedRight);
6321
6321
  const remainingHeight = Math.max(0.01, 1 - normalizedTop - normalizedBottom);
6322
6322
  const tx = Math.round(-normalizedLeft / remainingWidth * 1e4) / 100;
@@ -6345,7 +6345,7 @@ var CROP_SHAPE_CLIP_PATHS = {
6345
6345
  star: "polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%)"
6346
6346
  };
6347
6347
  function getCropShapeClipPath(element) {
6348
- if (!chunkZWG6IN7E_js.isImageLikeElement(element)) {
6348
+ if (!chunkRVKY3KGH_js.isImageLikeElement(element)) {
6349
6349
  return void 0;
6350
6350
  }
6351
6351
  const shape = element.cropShape;
@@ -6355,7 +6355,7 @@ function getCropShapeClipPath(element) {
6355
6355
  return CROP_SHAPE_CLIP_PATHS[shape];
6356
6356
  }
6357
6357
  function isImageTiled(element) {
6358
- if (!chunkZWG6IN7E_js.isImageLikeElement(element)) {
6358
+ if (!chunkRVKY3KGH_js.isImageLikeElement(element)) {
6359
6359
  return false;
6360
6360
  }
6361
6361
  return typeof element.tileScaleX === "number" || typeof element.tileScaleY === "number";
@@ -6413,7 +6413,7 @@ function buildMirrorTiledBackground(src, flip, scaleX, scaleY) {
6413
6413
  };
6414
6414
  }
6415
6415
  function getImageTilingStyle(element) {
6416
- if (!chunkZWG6IN7E_js.isImageLikeElement(element) || !isImageTiled(element)) {
6416
+ if (!chunkRVKY3KGH_js.isImageLikeElement(element) || !isImageTiled(element)) {
6417
6417
  return void 0;
6418
6418
  }
6419
6419
  const scaleX = typeof element.tileScaleX === "number" ? element.tileScaleX * 100 : 100;
@@ -6487,9 +6487,9 @@ function parseGradientFillCss(gradFill) {
6487
6487
  }
6488
6488
  const parsed = stops.map((gs) => {
6489
6489
  const pos = Number.parseInt(String(gs["@_pos"] || "0"), 10) / 1e3;
6490
- const color = chunk7OK75CPY_js.parseDrawingColor(gs) ?? "#888888";
6491
- const opacity = chunk7OK75CPY_js.parseDrawingColorOpacity(gs);
6492
- return { pos, color: chunk7OK75CPY_js.colorWithOpacity(color, opacity) };
6490
+ const color = chunkR47PKWUJ_js.parseDrawingColor(gs) ?? "#888888";
6491
+ const opacity = chunkR47PKWUJ_js.parseDrawingColorOpacity(gs);
6492
+ return { pos, color: chunkR47PKWUJ_js.colorWithOpacity(color, opacity) };
6493
6493
  }).sort((a, b) => a.pos - b.pos);
6494
6494
  const stopStrings = parsed.map((s) => `${s.color} ${s.pos.toFixed(1)}%`).join(", ");
6495
6495
  const lin = gradFill["a:lin"];
@@ -6530,8 +6530,8 @@ function parsePatternFillCss(pattFill) {
6530
6530
  if (!pattFill) {
6531
6531
  return void 0;
6532
6532
  }
6533
- const fgColor = chunk7OK75CPY_js.parseDrawingColor(pattFill["a:fgClr"]) ?? "#000000";
6534
- const bgColor = chunk7OK75CPY_js.parseDrawingColor(pattFill["a:bgClr"]) ?? "#ffffff";
6533
+ const fgColor = chunkR47PKWUJ_js.parseDrawingColor(pattFill["a:fgClr"]) ?? "#000000";
6534
+ const bgColor = chunkR47PKWUJ_js.parseDrawingColor(pattFill["a:bgClr"]) ?? "#ffffff";
6535
6535
  const preset = String(pattFill["@_prst"] || "ltDnDiag");
6536
6536
  switch (preset) {
6537
6537
  case "ltHorz":
@@ -6642,11 +6642,11 @@ function parseCellBorders(cellProperties) {
6642
6642
  const prstDash = ln["a:prstDash"];
6643
6643
  const dashVal = prstDash ? String(prstDash["@_val"] || "") : void 0;
6644
6644
  const cssBorderStyle = ooxmlDashToCss(dashVal);
6645
- const color = chunk7OK75CPY_js.parseDrawingColor(ln["a:solidFill"]);
6645
+ const color = chunkR47PKWUJ_js.parseDrawingColor(ln["a:solidFill"]);
6646
6646
  if (color) {
6647
- const opacity = chunk7OK75CPY_js.parseDrawingColorOpacity(ln["a:solidFill"]);
6647
+ const opacity = chunkR47PKWUJ_js.parseDrawingColorOpacity(ln["a:solidFill"]);
6648
6648
  const key = `${edge.prefix}`;
6649
- borderStyle[key] = `${widthPx}px ${cssBorderStyle} ${chunk7OK75CPY_js.colorWithOpacity(color, opacity)}`;
6649
+ borderStyle[key] = `${widthPx}px ${cssBorderStyle} ${chunkR47PKWUJ_js.colorWithOpacity(color, opacity)}`;
6650
6650
  }
6651
6651
  }
6652
6652
  return borderStyle;
@@ -6659,7 +6659,7 @@ function parseCellTextEffects(runProps) {
6659
6659
  const textShadowParts = [];
6660
6660
  const outerShdw = effectLst["a:outerShdw"];
6661
6661
  if (outerShdw) {
6662
- const shdwColor = chunk7OK75CPY_js.parseDrawingColor(outerShdw);
6662
+ const shdwColor = chunkR47PKWUJ_js.parseDrawingColor(outerShdw);
6663
6663
  if (shdwColor) {
6664
6664
  const blurRad = Number.parseInt(String(outerShdw["@_blurRad"] || "0"), 10);
6665
6665
  const blurPx = blurRad > 0 ? Math.round(blurRad / 12700) : 0;
@@ -6677,7 +6677,7 @@ function parseCellTextEffects(runProps) {
6677
6677
  }
6678
6678
  const glow = effectLst["a:glow"];
6679
6679
  if (glow) {
6680
- const glowColor = chunk7OK75CPY_js.parseDrawingColor(glow);
6680
+ const glowColor = chunkR47PKWUJ_js.parseDrawingColor(glow);
6681
6681
  if (glowColor) {
6682
6682
  const glowRad = Number.parseInt(String(glow["@_rad"] || "0"), 10);
6683
6683
  const glowPx = glowRad > 0 ? Math.round(glowRad / 12700) : 2;
@@ -6756,10 +6756,10 @@ function extractTableCellStyle(cellXml, fallbackStyle, schemeColorOverrides, inc
6756
6756
  if (runProps?.["@_u"] !== void 0) {
6757
6757
  cellStyle.textDecorationLine = runProps["@_u"] === "sng" ? "underline" : "none";
6758
6758
  }
6759
- const runColor = chunk7OK75CPY_js.parseDrawingColor(runProps?.["a:solidFill"], schemeColorOverrides) || chunk7OK75CPY_js.parseDrawingColor(runProps?.["a:highlight"], schemeColorOverrides);
6759
+ const runColor = chunkR47PKWUJ_js.parseDrawingColor(runProps?.["a:solidFill"], schemeColorOverrides) || chunkR47PKWUJ_js.parseDrawingColor(runProps?.["a:highlight"], schemeColorOverrides);
6760
6760
  if (runColor) {
6761
- const opacity = chunk7OK75CPY_js.parseDrawingColorOpacity(runProps?.["a:solidFill"]);
6762
- cellStyle.color = chunk7OK75CPY_js.colorWithOpacity(runColor, opacity);
6761
+ const opacity = chunkR47PKWUJ_js.parseDrawingColorOpacity(runProps?.["a:solidFill"]);
6762
+ cellStyle.color = chunkR47PKWUJ_js.colorWithOpacity(runColor, opacity);
6763
6763
  }
6764
6764
  const fontFamily = runProps?.["a:latin"]?.["@_typeface"] || runProps?.["a:ea"]?.["@_typeface"] || runProps?.["a:cs"]?.["@_typeface"];
6765
6765
  if (fontFamily) {
@@ -6769,15 +6769,15 @@ function extractTableCellStyle(cellXml, fallbackStyle, schemeColorOverrides, inc
6769
6769
  cellStyle.textAlign = parseParagraphAlignment(paragraphProperties["@_algn"]);
6770
6770
  }
6771
6771
  const cellProperties = cellXml["a:tcPr"];
6772
- const cellFill = chunk7OK75CPY_js.parseDrawingColor(
6772
+ const cellFill = chunkR47PKWUJ_js.parseDrawingColor(
6773
6773
  cellProperties?.["a:solidFill"],
6774
6774
  schemeColorOverrides
6775
6775
  );
6776
6776
  if (cellFill) {
6777
- const opacity = chunk7OK75CPY_js.parseDrawingColorOpacity(
6777
+ const opacity = chunkR47PKWUJ_js.parseDrawingColorOpacity(
6778
6778
  cellProperties?.["a:solidFill"]
6779
6779
  );
6780
- cellStyle.backgroundColor = chunk7OK75CPY_js.colorWithOpacity(cellFill, opacity);
6780
+ cellStyle.backgroundColor = chunkR47PKWUJ_js.colorWithOpacity(cellFill, opacity);
6781
6781
  } else {
6782
6782
  const gradCss = parseGradientFillCss(cellProperties?.["a:gradFill"]);
6783
6783
  if (gradCss) {
@@ -6792,16 +6792,16 @@ function extractTableCellStyle(cellXml, fallbackStyle, schemeColorOverrides, inc
6792
6792
  const edgeBorders = parseCellBorders(cellProperties);
6793
6793
  Object.assign(cellStyle, edgeBorders);
6794
6794
  if (!cellStyle.borderLeftColor && !cellStyle.borderRightColor && !cellStyle.borderTopColor && !cellStyle.borderBottomColor) {
6795
- const borderColor = chunk7OK75CPY_js.parseDrawingColor(
6795
+ const borderColor = chunkR47PKWUJ_js.parseDrawingColor(
6796
6796
  cellProperties?.["a:lnL"]?.["a:solidFill"],
6797
6797
  schemeColorOverrides
6798
- ) || chunk7OK75CPY_js.parseDrawingColor(
6798
+ ) || chunkR47PKWUJ_js.parseDrawingColor(
6799
6799
  cellProperties?.["a:lnR"]?.["a:solidFill"],
6800
6800
  schemeColorOverrides
6801
- ) || chunk7OK75CPY_js.parseDrawingColor(
6801
+ ) || chunkR47PKWUJ_js.parseDrawingColor(
6802
6802
  cellProperties?.["a:lnT"]?.["a:solidFill"],
6803
6803
  schemeColorOverrides
6804
- ) || chunk7OK75CPY_js.parseDrawingColor(
6804
+ ) || chunkR47PKWUJ_js.parseDrawingColor(
6805
6805
  cellProperties?.["a:lnB"]?.["a:solidFill"],
6806
6806
  schemeColorOverrides
6807
6807
  );
@@ -6880,10 +6880,10 @@ function resolveTableStyleFillColor(fill, colorScheme) {
6880
6880
  }
6881
6881
  let color = base;
6882
6882
  if (fill.tint !== void 0 && fill.tint > 0) {
6883
- color = chunk7OK75CPY_js.tintColor2(color, 1 - fill.tint / 1e5);
6883
+ color = chunkR47PKWUJ_js.tintColor2(color, 1 - fill.tint / 1e5);
6884
6884
  }
6885
6885
  if (fill.shade !== void 0 && fill.shade > 0) {
6886
- color = chunk7OK75CPY_js.shadeColor2(color, 1 - fill.shade / 1e5);
6886
+ color = chunkR47PKWUJ_js.shadeColor2(color, 1 - fill.shade / 1e5);
6887
6887
  }
6888
6888
  return color;
6889
6889
  }
@@ -6908,7 +6908,7 @@ function applyTableStyleText(text, colorScheme, style, fontScheme) {
6908
6908
  style.fontFamily = text.fontFace;
6909
6909
  applied = true;
6910
6910
  } else {
6911
- const refFont = chunk7OK75CPY_js.resolveFontRefIdx(text.fontRefIdx, fontScheme);
6911
+ const refFont = chunkR47PKWUJ_js.resolveFontRefIdx(text.fontRefIdx, fontScheme);
6912
6912
  if (refFont) {
6913
6913
  style.fontFamily = refFont;
6914
6914
  applied = true;
@@ -6919,10 +6919,10 @@ function applyTableStyleText(text, colorScheme, style, fontScheme) {
6919
6919
  if (base) {
6920
6920
  let color = base;
6921
6921
  if (text.fontTint !== void 0 && text.fontTint > 0) {
6922
- color = chunk7OK75CPY_js.tintColor2(color, 1 - text.fontTint / 1e5);
6922
+ color = chunkR47PKWUJ_js.tintColor2(color, 1 - text.fontTint / 1e5);
6923
6923
  }
6924
6924
  if (text.fontShade !== void 0 && text.fontShade > 0) {
6925
- color = chunk7OK75CPY_js.shadeColor2(color, 1 - text.fontShade / 1e5);
6925
+ color = chunkR47PKWUJ_js.shadeColor2(color, 1 - text.fontShade / 1e5);
6926
6926
  }
6927
6927
  style.color = color;
6928
6928
  applied = true;
@@ -7114,7 +7114,7 @@ function parseTableElementData(element, fallbackTextStyle) {
7114
7114
  };
7115
7115
  }
7116
7116
  function getCellDiagonalBorders2(style, tableData, pos, styleCtx) {
7117
- return chunk7OK75CPY_js.getCellDiagonalBorders(style, tableData, pos, {
7117
+ return chunkR47PKWUJ_js.getCellDiagonalBorders(style, tableData, pos, {
7118
7118
  tableStyleMap: styleCtx?.tableStyleMap,
7119
7119
  colorScheme: styleCtx?.theme?.colorScheme,
7120
7120
  fontScheme: styleCtx?.theme?.fontScheme
@@ -7262,9 +7262,9 @@ function cellStyleToCss(style) {
7262
7262
  if (style.gradientFillCss) {
7263
7263
  css.background = style.gradientFillCss;
7264
7264
  } else if (style.fillMode === "pattern" && style.patternFillPreset) {
7265
- const fg = chunk7OK75CPY_js.normalizeHexColor(style.patternFillForeground, "#000000");
7266
- const bg = chunk7OK75CPY_js.normalizeHexColor(style.patternFillBackground, "#ffffff");
7267
- const svgPattern = chunk7OK75CPY_js.getPatternSvg(style.patternFillPreset, fg, bg);
7265
+ const fg = chunkR47PKWUJ_js.normalizeHexColor(style.patternFillForeground, "#000000");
7266
+ const bg = chunkR47PKWUJ_js.normalizeHexColor(style.patternFillBackground, "#ffffff");
7267
+ const svgPattern = chunkR47PKWUJ_js.getPatternSvg(style.patternFillPreset, fg, bg);
7268
7268
  if (svgPattern) {
7269
7269
  const encoded = encodeURIComponent(svgPattern);
7270
7270
  css.backgroundImage = `url("data:image/svg+xml,${encoded}")`;
@@ -7340,7 +7340,7 @@ function cellStyleToCss(style) {
7340
7340
  if (edge.width || edge.color) {
7341
7341
  const w = edge.width ?? 1;
7342
7342
  const c = edge.color ?? style.borderColor ?? "#000000";
7343
- const s = chunk7OK75CPY_js.ooxmlDashToCssBorderStyle(edge.dash);
7343
+ const s = chunkR47PKWUJ_js.ooxmlDashToCssBorderStyle(edge.dash);
7344
7344
  css[edge.prefix] = `${w}px ${s} ${c}`;
7345
7345
  }
7346
7346
  }
@@ -7371,7 +7371,7 @@ function cellStyleToCss(style) {
7371
7371
  css.textShadow = textShadowParts.join(", ");
7372
7372
  }
7373
7373
  if (style.cell3D) {
7374
- Object.assign(css, chunk7OK75CPY_js.cell3DBevelCss(style.cell3D));
7374
+ Object.assign(css, chunkR47PKWUJ_js.cell3DBevelCss(style.cell3D));
7375
7375
  }
7376
7376
  return css;
7377
7377
  }
@@ -7385,7 +7385,7 @@ function TableResizeOverlay({
7385
7385
  const containerRef = React4.useRef(null);
7386
7386
  const [rowBounds, setRowBounds] = React4.useState([]);
7387
7387
  const dragRef = React4.useRef(null);
7388
- const colBoundaries = React4.useMemo(() => chunk7OK75CPY_js.computeColumnBoundaries(columnWidths), [columnWidths]);
7388
+ const colBoundaries = React4.useMemo(() => chunkR47PKWUJ_js.computeColumnBoundaries(columnWidths), [columnWidths]);
7389
7389
  const measureRows = React4.useCallback(() => {
7390
7390
  const container = containerRef.current;
7391
7391
  if (!container) {
@@ -7432,11 +7432,11 @@ function TableResizeOverlay({
7432
7432
  const rect = containerRef.current.getBoundingClientRect();
7433
7433
  if (drag.type === "col" && drag.initialWidths && onResizeColumns) {
7434
7434
  const deltaProp = (e.clientX - drag.startPos) / rect.width;
7435
- onResizeColumns(chunk7OK75CPY_js.computeResizedColumnWidths(drag.initialWidths, drag.index, deltaProp));
7435
+ onResizeColumns(chunkR47PKWUJ_js.computeResizedColumnWidths(drag.initialWidths, drag.index, deltaProp));
7436
7436
  } else if (drag.type === "row" && onResizeRow) {
7437
7437
  const deltaY = e.clientY - drag.startPos;
7438
- const newHeight = chunk7OK75CPY_js.computeResizedRowHeight(
7439
- drag.initialRowHeight ?? chunk7OK75CPY_js.DEFAULT_ROW_HEIGHT,
7438
+ const newHeight = chunkR47PKWUJ_js.computeResizedRowHeight(
7439
+ drag.initialRowHeight ?? chunkR47PKWUJ_js.DEFAULT_ROW_HEIGHT,
7440
7440
  deltaY
7441
7441
  );
7442
7442
  onResizeRow(drag.index, newHeight);
@@ -7474,7 +7474,7 @@ function TableResizeOverlay({
7474
7474
  e.stopPropagation();
7475
7475
  const table = containerRef.current?.querySelector("table");
7476
7476
  const tr = table?.querySelectorAll("tbody > tr")[index];
7477
- const actualHeight = tr?.offsetHeight ?? chunk7OK75CPY_js.DEFAULT_ROW_HEIGHT;
7477
+ const actualHeight = tr?.offsetHeight ?? chunkR47PKWUJ_js.DEFAULT_ROW_HEIGHT;
7478
7478
  document.body.style.cursor = "row-resize";
7479
7479
  document.body.style.userSelect = "none";
7480
7480
  dragRef.current = {
@@ -7522,7 +7522,7 @@ function renderTableFromTableData(element, textStyle, options) {
7522
7522
  }
7523
7523
  const first = selectedCell.selectedCells[0];
7524
7524
  const last = selectedCell.selectedCells[selectedCell.selectedCells.length - 1];
7525
- return chunk7OK75CPY_js.computeSelectionRect(first.row, first.col, last.row, last.col, tableData);
7525
+ return chunkR47PKWUJ_js.computeSelectionRect(first.row, first.col, last.row, last.col, tableData);
7526
7526
  })();
7527
7527
  return /* @__PURE__ */ jsxRuntime.jsx(
7528
7528
  TableResizeOverlay,
@@ -7555,7 +7555,7 @@ function renderTableFromTableData(element, textStyle, options) {
7555
7555
  return null;
7556
7556
  }
7557
7557
  const isCellSelected = selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex;
7558
- const isInMultiSelection = chunk7OK75CPY_js.isCellInRect(rowIndex, cellIndex, selectionRect);
7558
+ const isInMultiSelection = chunkR47PKWUJ_js.isCellInRect(rowIndex, cellIndex, selectionRect);
7559
7559
  const isCellEditing = isCellSelected && selectedCell?.isEditing;
7560
7560
  const diag = getCellDiagonalBorders2(
7561
7561
  cell.style,
@@ -7585,7 +7585,7 @@ function renderTableFromTableData(element, textStyle, options) {
7585
7585
  }
7586
7586
  event.stopPropagation();
7587
7587
  if (event.shiftKey && selectedCell) {
7588
- const rect = chunk7OK75CPY_js.computeSelectionRect(
7588
+ const rect = chunkR47PKWUJ_js.computeSelectionRect(
7589
7589
  selectedCell.rowIndex,
7590
7590
  selectedCell.columnIndex,
7591
7591
  rowIndex,
@@ -7595,7 +7595,7 @@ function renderTableFromTableData(element, textStyle, options) {
7595
7595
  options?.onSelectCell?.({
7596
7596
  rowIndex: selectedCell.rowIndex,
7597
7597
  columnIndex: selectedCell.columnIndex,
7598
- selectedCells: chunk7OK75CPY_js.rectToCells(rect)
7598
+ selectedCells: chunkR47PKWUJ_js.rectToCells(rect)
7599
7599
  });
7600
7600
  } else {
7601
7601
  options?.onSelectCell?.({
@@ -7672,7 +7672,7 @@ function renderTableElement(element, textStyle, options) {
7672
7672
  }
7673
7673
  const first = selectedCell.selectedCells[0];
7674
7674
  const last = selectedCell.selectedCells[selectedCell.selectedCells.length - 1];
7675
- return chunk7OK75CPY_js.computeSelectionRect(first.row, first.col, last.row, last.col, tableEl.tableData);
7675
+ return chunkR47PKWUJ_js.computeSelectionRect(first.row, first.col, last.row, last.col, tableEl.tableData);
7676
7676
  })();
7677
7677
  const schemeOverrides = options?.styleCtx?.theme?.colorScheme ? options.styleCtx.theme.colorScheme : void 0;
7678
7678
  return /* @__PURE__ */ jsxRuntime.jsx(
@@ -7755,7 +7755,7 @@ function renderTableElement(element, textStyle, options) {
7755
7755
  "border px-1 py-0.5 align-top",
7756
7756
  isEditable2 && hasCellSelectionHandler ? "border-blue-200/70 cursor-cell" : "border-white/30",
7757
7757
  selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex ? "ring-1 ring-inset ring-blue-500" : null,
7758
- chunk7OK75CPY_js.isCellInRect(rowIndex, cellIndex, xmlSelectionRect) && !(selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex) ? "bg-blue-500/15 ring-1 ring-inset ring-blue-400/50" : null
7758
+ chunkR47PKWUJ_js.isCellInRect(rowIndex, cellIndex, xmlSelectionRect) && !(selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex) ? "bg-blue-500/15 ring-1 ring-inset ring-blue-400/50" : null
7759
7759
  ),
7760
7760
  colSpan,
7761
7761
  rowSpan: rSpan,
@@ -7766,7 +7766,7 @@ function renderTableElement(element, textStyle, options) {
7766
7766
  }
7767
7767
  event.stopPropagation();
7768
7768
  if (event.shiftKey && selectedCell && tableEl.tableData) {
7769
- const rect = chunk7OK75CPY_js.computeSelectionRect(
7769
+ const rect = chunkR47PKWUJ_js.computeSelectionRect(
7770
7770
  selectedCell.rowIndex,
7771
7771
  selectedCell.columnIndex,
7772
7772
  rowIndex,
@@ -7776,7 +7776,7 @@ function renderTableElement(element, textStyle, options) {
7776
7776
  options?.onSelectCell?.({
7777
7777
  rowIndex: selectedCell.rowIndex,
7778
7778
  columnIndex: selectedCell.columnIndex,
7779
- selectedCells: chunk7OK75CPY_js.rectToCells(rect)
7779
+ selectedCells: chunkR47PKWUJ_js.rectToCells(rect)
7780
7780
  });
7781
7781
  } else {
7782
7782
  options?.onSelectCell?.({
@@ -7831,24 +7831,24 @@ function renderTableElement(element, textStyle, options) {
7831
7831
  }
7832
7832
  var LEGEND_ITEM_WIDTH = 80;
7833
7833
  function partAttrs(part) {
7834
- return part ? chunk7OK75CPY_js.chartPartToAttrs(part) : void 0;
7834
+ return part ? chunkR47PKWUJ_js.chartPartToAttrs(part) : void 0;
7835
7835
  }
7836
7836
  function resolveReactPalette(chartData) {
7837
7837
  if (chartData.colorPalette && chartData.colorPalette.length > 0) {
7838
7838
  return chartData.colorPalette;
7839
7839
  }
7840
- return [...chunk7OK75CPY_js.getChartStylePalette(chartData.style?.styleId)];
7840
+ return [...chunkR47PKWUJ_js.getChartStylePalette(chartData.style?.styleId)];
7841
7841
  }
7842
7842
  function buildReactChartViewModel(element) {
7843
7843
  if (element.type !== "chart" || !element.chartData) {
7844
- return chunk7OK75CPY_js.buildChartViewModel(element);
7844
+ return chunkR47PKWUJ_js.buildChartViewModel(element);
7845
7845
  }
7846
7846
  const palette = resolveReactPalette(element.chartData);
7847
7847
  const themedElement = {
7848
7848
  ...element,
7849
7849
  chartData: { ...element.chartData, colorPalette: palette }
7850
7850
  };
7851
- return chunk7OK75CPY_js.buildChartViewModel(themedElement);
7851
+ return chunkR47PKWUJ_js.buildChartViewModel(themedElement);
7852
7852
  }
7853
7853
  function renderPrimitive(prim, key) {
7854
7854
  switch (prim.kind) {
@@ -8237,7 +8237,7 @@ function renderMapChart(element, chartData, categoryLabels) {
8237
8237
  const unmatchedRows = [];
8238
8238
  categories.forEach((cat, i) => {
8239
8239
  const value = values[i] ?? 0;
8240
- const code = chunk7OK75CPY_js.resolveRegionCode(cat);
8240
+ const code = chunkR47PKWUJ_js.resolveRegionCode(cat);
8241
8241
  if (code) {
8242
8242
  regionValueMap.set(code, { value, label: cat });
8243
8243
  } else {
@@ -8275,8 +8275,8 @@ function renderMapChart(element, chartData, categoryLabels) {
8275
8275
  let fill = "#e2e8f0";
8276
8276
  let dataLabel = null;
8277
8277
  if (entry) {
8278
- const t = chunk7OK75CPY_js.normalizeValue(entry.value, minVal, maxVal);
8279
- fill = chunk7OK75CPY_js.sequentialColorScale(t);
8278
+ const t = chunkR47PKWUJ_js.normalizeValue(entry.value, minVal, maxVal);
8279
+ fill = chunkR47PKWUJ_js.sequentialColorScale(t);
8280
8280
  dataLabel = /* @__PURE__ */ jsxRuntime.jsx(
8281
8281
  "text",
8282
8282
  {
@@ -8287,7 +8287,7 @@ function renderMapChart(element, chartData, categoryLabels) {
8287
8287
  fontWeight: 600,
8288
8288
  fill: "#1e293b",
8289
8289
  style: { pointerEvents: "none" },
8290
- children: chunk7OK75CPY_js.formatAxisValue(entry.value)
8290
+ children: chunkR47PKWUJ_js.formatAxisValue(entry.value)
8291
8291
  },
8292
8292
  `${element.id}-map-dl-${region.code}`
8293
8293
  );
@@ -8305,7 +8305,7 @@ function renderMapChart(element, chartData, categoryLabels) {
8305
8305
  opacity: 0.9,
8306
8306
  children: /* @__PURE__ */ jsxRuntime.jsxs("title", { children: [
8307
8307
  region.name,
8308
- entry ? `: ${chunk7OK75CPY_js.formatAxisValue(entry.value)}` : ""
8308
+ entry ? `: ${chunkR47PKWUJ_js.formatAxisValue(entry.value)}` : ""
8309
8309
  ] })
8310
8310
  }
8311
8311
  ),
@@ -8343,7 +8343,7 @@ function renderMapChart(element, chartData, categoryLabels) {
8343
8343
  fontSize: 7,
8344
8344
  fill: "#64748b",
8345
8345
  textAnchor: "middle",
8346
- children: chunk7OK75CPY_js.formatAxisValue(minVal)
8346
+ children: chunkR47PKWUJ_js.formatAxisValue(minVal)
8347
8347
  },
8348
8348
  `${element.id}-map-legend-min`
8349
8349
  ),
@@ -8355,7 +8355,7 @@ function renderMapChart(element, chartData, categoryLabels) {
8355
8355
  fontSize: 7,
8356
8356
  fill: "#64748b",
8357
8357
  textAnchor: "middle",
8358
- children: chunk7OK75CPY_js.formatAxisValue(maxVal)
8358
+ children: chunkR47PKWUJ_js.formatAxisValue(maxVal)
8359
8359
  },
8360
8360
  `${element.id}-map-legend-max`
8361
8361
  )
@@ -8421,7 +8421,7 @@ function renderMapChart(element, chartData, categoryLabels) {
8421
8421
  y,
8422
8422
  fontSize,
8423
8423
  fill: "#475569",
8424
- children: chunk7OK75CPY_js.formatAxisValue(row.value)
8424
+ children: chunkR47PKWUJ_js.formatAxisValue(row.value)
8425
8425
  },
8426
8426
  `${element.id}-map-ft-val-${i}`
8427
8427
  )
@@ -8492,7 +8492,7 @@ function renderStackedBarChart(element, _chartData, _categoryLabels) {
8492
8492
 
8493
8493
  // src/viewer/utils/chart-overlay-utils.ts
8494
8494
  function sColor(series, idx) {
8495
- return chunk7OK75CPY_js.seriesColor(series, idx);
8495
+ return chunkR47PKWUJ_js.seriesColor(series, idx);
8496
8496
  }
8497
8497
  function valToY(val, range, topY, bottomY) {
8498
8498
  const usable = bottomY - topY;
@@ -9031,7 +9031,7 @@ function renderLegend(id, style, series, layout, colorPalette) {
9031
9031
  width: 10,
9032
9032
  height: 10,
9033
9033
  rx: 2,
9034
- fill: chunk7OK75CPY_js.seriesColor(s, i, style?.styleId, colorPalette)
9034
+ fill: chunkR47PKWUJ_js.seriesColor(s, i, style?.styleId, colorPalette)
9035
9035
  },
9036
9036
  `${id}-leg-r-${i}`
9037
9037
  )
@@ -9055,7 +9055,7 @@ function renderLegend(id, style, series, layout, colorPalette) {
9055
9055
  width: 10,
9056
9056
  height: 10,
9057
9057
  rx: 2,
9058
- fill: chunk7OK75CPY_js.seriesColor(s, i, style?.styleId, colorPalette)
9058
+ fill: chunkR47PKWUJ_js.seriesColor(s, i, style?.styleId, colorPalette)
9059
9059
  }
9060
9060
  ),
9061
9061
  /* @__PURE__ */ jsxRuntime.jsx("text", { x: x + 14, y: cy + 8, fontSize: 9, fill: "#475569", children: s.name || `Series ${i + 1}` })
@@ -9068,9 +9068,9 @@ function renderGridlines(id, style, range, layout) {
9068
9068
  }
9069
9069
  const lines = [];
9070
9070
  if (range.logScale && range.logBase) {
9071
- const ticks = chunk7OK75CPY_js.generateLogTicks(range);
9071
+ const ticks = chunkR47PKWUJ_js.generateLogTicks(range);
9072
9072
  ticks.forEach((tickVal, i) => {
9073
- const y = chunk7OK75CPY_js.valueToY(tickVal, range, layout.plotTop, layout.plotBottom);
9073
+ const y = chunkR47PKWUJ_js.valueToY(tickVal, range, layout.plotTop, layout.plotBottom);
9074
9074
  lines.push(
9075
9075
  /* @__PURE__ */ jsxRuntime.jsx(
9076
9076
  "line",
@@ -9091,7 +9091,7 @@ function renderGridlines(id, style, range, layout) {
9091
9091
  const steps = 4;
9092
9092
  for (let i = 0; i <= steps; i++) {
9093
9093
  const val = range.min + range.span * i / steps;
9094
- const y = chunk7OK75CPY_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
9094
+ const y = chunkR47PKWUJ_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
9095
9095
  lines.push(
9096
9096
  /* @__PURE__ */ jsxRuntime.jsx(
9097
9097
  "line",
@@ -9115,9 +9115,9 @@ function renderValueAxis(id, range, layout, axisFormatting) {
9115
9115
  const labels = [];
9116
9116
  const hasDisplayUnits = Boolean(axisFormatting?.displayUnits);
9117
9117
  if (range.logScale && range.logBase) {
9118
- const ticks = chunk7OK75CPY_js.generateLogTicks(range);
9118
+ const ticks = chunkR47PKWUJ_js.generateLogTicks(range);
9119
9119
  ticks.forEach((tickVal, i) => {
9120
- const y = chunk7OK75CPY_js.valueToY(tickVal, range, layout.plotTop, layout.plotBottom);
9120
+ const y = chunkR47PKWUJ_js.valueToY(tickVal, range, layout.plotTop, layout.plotBottom);
9121
9121
  labels.push(
9122
9122
  /* @__PURE__ */ jsxRuntime.jsx(
9123
9123
  "text",
@@ -9127,7 +9127,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
9127
9127
  textAnchor: "end",
9128
9128
  fontSize: 8,
9129
9129
  fill: "#64748b",
9130
- children: hasDisplayUnits ? chunk7OK75CPY_js.formatAxisValueWithUnits(tickVal, axisFormatting) : chunk7OK75CPY_js.formatAxisValue(tickVal)
9130
+ children: hasDisplayUnits ? chunkR47PKWUJ_js.formatAxisValueWithUnits(tickVal, axisFormatting) : chunkR47PKWUJ_js.formatAxisValue(tickVal)
9131
9131
  },
9132
9132
  `${id}-vaxis-log-${i}`
9133
9133
  )
@@ -9137,7 +9137,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
9137
9137
  const steps = 4;
9138
9138
  for (let i = 0; i <= steps; i++) {
9139
9139
  const val = range.min + range.span * i / steps;
9140
- const y = chunk7OK75CPY_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
9140
+ const y = chunkR47PKWUJ_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
9141
9141
  labels.push(
9142
9142
  /* @__PURE__ */ jsxRuntime.jsx(
9143
9143
  "text",
@@ -9147,7 +9147,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
9147
9147
  textAnchor: "end",
9148
9148
  fontSize: 8,
9149
9149
  fill: "#64748b",
9150
- children: hasDisplayUnits ? chunk7OK75CPY_js.formatAxisValueWithUnits(val, axisFormatting) : chunk7OK75CPY_js.formatAxisValue(val)
9150
+ children: hasDisplayUnits ? chunkR47PKWUJ_js.formatAxisValueWithUnits(val, axisFormatting) : chunkR47PKWUJ_js.formatAxisValue(val)
9151
9151
  },
9152
9152
  `${id}-vaxis-${i}`
9153
9153
  )
@@ -9155,7 +9155,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
9155
9155
  }
9156
9156
  }
9157
9157
  if (hasDisplayUnits) {
9158
- const unitLabel = chunk7OK75CPY_js.getDisplayUnitLabel(
9158
+ const unitLabel = chunkR47PKWUJ_js.getDisplayUnitLabel(
9159
9159
  axisFormatting.displayUnits,
9160
9160
  axisFormatting.displayUnitsLabel
9161
9161
  );
@@ -9230,7 +9230,7 @@ function renderZeroLine(id, range, layout) {
9230
9230
  if (range.min >= 0) {
9231
9231
  return null;
9232
9232
  }
9233
- const y = chunk7OK75CPY_js.valueToY(0, range, layout.plotTop, layout.plotBottom);
9233
+ const y = chunkR47PKWUJ_js.valueToY(0, range, layout.plotTop, layout.plotBottom);
9234
9234
  return /* @__PURE__ */ jsxRuntime.jsx(
9235
9235
  "line",
9236
9236
  {
@@ -9254,7 +9254,7 @@ function renderSecondaryValueAxis(id, range, layout, axisFormatting) {
9254
9254
  const hasDisplayUnits = Boolean(axisFormatting?.displayUnits);
9255
9255
  for (let i = 0; i <= steps; i++) {
9256
9256
  const val = range.min + range.span * i / steps;
9257
- const y = chunk7OK75CPY_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
9257
+ const y = chunkR47PKWUJ_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
9258
9258
  labels.push(
9259
9259
  /* @__PURE__ */ jsxRuntime.jsx(
9260
9260
  "text",
@@ -9266,7 +9266,7 @@ function renderSecondaryValueAxis(id, range, layout, axisFormatting) {
9266
9266
  fontFamily,
9267
9267
  fontWeight,
9268
9268
  fill: fontColor,
9269
- children: hasDisplayUnits ? chunk7OK75CPY_js.formatAxisValueWithUnits(val, axisFormatting) : chunk7OK75CPY_js.formatAxisValue(val)
9269
+ children: hasDisplayUnits ? chunkR47PKWUJ_js.formatAxisValueWithUnits(val, axisFormatting) : chunkR47PKWUJ_js.formatAxisValue(val)
9270
9270
  },
9271
9271
  `${id}-sec-vaxis-${i}`
9272
9272
  )
@@ -9290,7 +9290,7 @@ function renderSecondaryValueAxis(id, range, layout, axisFormatting) {
9290
9290
  );
9291
9291
  }
9292
9292
  if (hasDisplayUnits) {
9293
- const unitLabel = chunk7OK75CPY_js.getDisplayUnitLabel(
9293
+ const unitLabel = chunkR47PKWUJ_js.getDisplayUnitLabel(
9294
9294
  axisFormatting.displayUnits,
9295
9295
  axisFormatting.displayUnitsLabel
9296
9296
  );
@@ -9321,7 +9321,7 @@ function renderSecondaryAxisTicks(id, range, layout) {
9321
9321
  const ticks = [];
9322
9322
  for (let i = 0; i <= steps; i++) {
9323
9323
  const val = range.min + range.span * i / steps;
9324
- const y = chunk7OK75CPY_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
9324
+ const y = chunkR47PKWUJ_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
9325
9325
  ticks.push(
9326
9326
  /* @__PURE__ */ jsxRuntime.jsx(
9327
9327
  "line",
@@ -9348,7 +9348,7 @@ function renderSecondaryGridlines(id, range, layout, axisFormatting) {
9348
9348
  const gridColor = axisFormatting.majorGridlinesSpPr?.strokeColor ?? "#e2e8f0";
9349
9349
  for (let i = 0; i <= steps; i++) {
9350
9350
  const val = range.min + range.span * i / steps;
9351
- const y = chunk7OK75CPY_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
9351
+ const y = chunkR47PKWUJ_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
9352
9352
  lines.push(
9353
9353
  /* @__PURE__ */ jsxRuntime.jsx(
9354
9354
  "line",
@@ -9510,7 +9510,7 @@ function renderChartDataTable(elementId, chartData, svgWidth) {
9510
9510
  width: 8,
9511
9511
  height: 8,
9512
9512
  borderRadius: 2,
9513
- backgroundColor: chunk7OK75CPY_js.seriesColor(
9513
+ backgroundColor: chunkR47PKWUJ_js.seriesColor(
9514
9514
  s,
9515
9515
  si,
9516
9516
  chartData.style?.styleId,
@@ -9549,8 +9549,8 @@ function renderChartDataTable(elementId, chartData, svgWidth) {
9549
9549
  function renderStockChart(element, chartData, categoryLabels) {
9550
9550
  const style = chartData.style;
9551
9551
  const legendPos = style?.legendPosition || "b";
9552
- const range = chunk7OK75CPY_js.computeValueRangeForChart(chartData.series, chartData.axes);
9553
- const layout = chunk7OK75CPY_js.computeLayout(element.width, element.height, style, true, legendPos);
9552
+ const range = chunkR47PKWUJ_js.computeValueRangeForChart(chartData.series, chartData.axes);
9553
+ const layout = chunkR47PKWUJ_js.computeLayout(element.width, element.height, style, true, legendPos);
9554
9554
  const catCount = Math.max(categoryLabels.length, 1);
9555
9555
  const barGroupWidth = layout.plotWidth / catCount;
9556
9556
  const candleWidth = barGroupWidth * 0.5;
@@ -9571,10 +9571,10 @@ function renderStockChart(element, chartData, categoryLabels) {
9571
9571
  const close = closeSeries.values[ci] ?? high;
9572
9572
  const isUp = close >= open;
9573
9573
  const cx = layout.plotLeft + barGroupWidth * ci + barGroupWidth / 2;
9574
- const highY = chunk7OK75CPY_js.valueToY(high, range, layout.plotTop, layout.plotBottom);
9575
- const lowY = chunk7OK75CPY_js.valueToY(low, range, layout.plotTop, layout.plotBottom);
9576
- const openY = chunk7OK75CPY_js.valueToY(open, range, layout.plotTop, layout.plotBottom);
9577
- const closeY = chunk7OK75CPY_js.valueToY(close, range, layout.plotTop, layout.plotBottom);
9574
+ const highY = chunkR47PKWUJ_js.valueToY(high, range, layout.plotTop, layout.plotBottom);
9575
+ const lowY = chunkR47PKWUJ_js.valueToY(low, range, layout.plotTop, layout.plotBottom);
9576
+ const openY = chunkR47PKWUJ_js.valueToY(open, range, layout.plotTop, layout.plotBottom);
9577
+ const closeY = chunkR47PKWUJ_js.valueToY(close, range, layout.plotTop, layout.plotBottom);
9578
9578
  elements.push(
9579
9579
  /* @__PURE__ */ jsxRuntime.jsx(
9580
9580
  "line",
@@ -9617,7 +9617,7 @@ function renderStockChart(element, chartData, categoryLabels) {
9617
9617
  textAnchor: "middle",
9618
9618
  fontSize: 7,
9619
9619
  fill: "#334155",
9620
- children: chunk7OK75CPY_js.formatAxisValue(close)
9620
+ children: chunkR47PKWUJ_js.formatAxisValue(close)
9621
9621
  },
9622
9622
  `${element.id}-stock-dl-${ci}`
9623
9623
  )
@@ -9659,7 +9659,7 @@ function FailedToLoad() {
9659
9659
  var LazySurfaceChart3DScene = React4__default.default.lazy(
9660
9660
  async () => {
9661
9661
  try {
9662
- return await import('./SurfaceChart3DScene-2CB3DEDZ.js');
9662
+ return await import('./SurfaceChart3DScene-VABT6UY4.js');
9663
9663
  } catch {
9664
9664
  return { default: FailedToLoad };
9665
9665
  }
@@ -9683,7 +9683,7 @@ var SurfaceChart3DErrorBoundary = class extends React4__default.default.Componen
9683
9683
  function buildSurfaceData(chartData, categoryLabels) {
9684
9684
  const rows = chartData.series.length;
9685
9685
  const cols = Math.max(categoryLabels.length, 1);
9686
- const range = chunk7OK75CPY_js.computeValueRangeForChart(chartData.series, chartData.axes);
9686
+ const range = chunkR47PKWUJ_js.computeValueRangeForChart(chartData.series, chartData.axes);
9687
9687
  const heightMap = new Float32Array(rows * cols);
9688
9688
  const colorMap = new Float32Array(rows * cols * 3);
9689
9689
  for (let r = 0; r < rows; r++) {
@@ -9803,8 +9803,8 @@ function darkenRgb(r, g, b, factor) {
9803
9803
  function renderIsometricSurfaceChart(element, chartData, categoryLabels) {
9804
9804
  const style = chartData.style;
9805
9805
  const legendPos = style?.legendPosition || "b";
9806
- const layout = chunk7OK75CPY_js.computeLayout(element.width, element.height, style, false, legendPos);
9807
- const range = chunk7OK75CPY_js.computeValueRangeForChart(chartData.series, chartData.axes);
9806
+ const layout = chunkR47PKWUJ_js.computeLayout(element.width, element.height, style, false, legendPos);
9807
+ const range = chunkR47PKWUJ_js.computeValueRangeForChart(chartData.series, chartData.axes);
9808
9808
  const catCount = Math.max(categoryLabels.length, 1);
9809
9809
  const seriesCount = chartData.series.length;
9810
9810
  const cols = catCount - 1;
@@ -9894,8 +9894,8 @@ function renderIsometricSurfaceChart(element, chartData, categoryLabels) {
9894
9894
  function renderFlatSurfaceChart(element, chartData, categoryLabels) {
9895
9895
  const style = chartData.style;
9896
9896
  const legendPos = style?.legendPosition || "b";
9897
- const layout = chunk7OK75CPY_js.computeLayout(element.width, element.height, style, true, legendPos);
9898
- const range = chunk7OK75CPY_js.computeValueRangeForChart(chartData.series, chartData.axes);
9897
+ const layout = chunkR47PKWUJ_js.computeLayout(element.width, element.height, style, true, legendPos);
9898
+ const range = chunkR47PKWUJ_js.computeValueRangeForChart(chartData.series, chartData.axes);
9899
9899
  const catCount = Math.max(categoryLabels.length, 1);
9900
9900
  const seriesCount = chartData.series.length;
9901
9901
  const cellW = layout.plotWidth / Math.max(catCount - 1, 1);
@@ -9958,7 +9958,7 @@ function renderSurfaceChart(element, chartData, categoryLabels) {
9958
9958
  function renderTreemapChart(element, chartData, categoryLabels) {
9959
9959
  const style = chartData.style;
9960
9960
  const legendPos = style?.legendPosition || "b";
9961
- const layout = chunk7OK75CPY_js.computeLayout(element.width, element.height, style, false, legendPos);
9961
+ const layout = chunkR47PKWUJ_js.computeLayout(element.width, element.height, style, false, legendPos);
9962
9962
  const allValues = chartData.series.flatMap((s) => s.values);
9963
9963
  const totalAbs = allValues.reduce((sum, v) => sum + Math.abs(v), 0) || 1;
9964
9964
  const rects = [];
@@ -9981,7 +9981,7 @@ function renderTreemapChart(element, chartData, categoryLabels) {
9981
9981
  y: curY,
9982
9982
  width: Math.max(w - 1, 1),
9983
9983
  height: Math.max(h - 1, 1),
9984
- fill: chunk7OK75CPY_js.paletteColor(item.index, chartData.style?.styleId, chartData.colorPalette),
9984
+ fill: chunkR47PKWUJ_js.paletteColor(item.index, chartData.style?.styleId, chartData.colorPalette),
9985
9985
  rx: 2,
9986
9986
  opacity: 0.85
9987
9987
  },
@@ -10034,8 +10034,8 @@ function renderWaterfallChart(element, chartData, categoryLabels) {
10034
10034
  const style = chartData.style;
10035
10035
  const legendPos = style?.legendPosition || "b";
10036
10036
  const values = chartData.series[0]?.values ?? [];
10037
- const range = chunk7OK75CPY_js.computeValueRangeForChart(chartData.series, chartData.axes);
10038
- const layout = chunk7OK75CPY_js.computeLayout(element.width, element.height, style, true, legendPos);
10037
+ const range = chunkR47PKWUJ_js.computeValueRangeForChart(chartData.series, chartData.axes);
10038
+ const layout = chunkR47PKWUJ_js.computeLayout(element.width, element.height, style, true, legendPos);
10039
10039
  const catCount = Math.max(categoryLabels.length, values.length, 1);
10040
10040
  const barWidth = layout.plotWidth / catCount * 0.6;
10041
10041
  const gap = layout.plotWidth / catCount * 0.2;
@@ -10046,8 +10046,8 @@ function renderWaterfallChart(element, chartData, categoryLabels) {
10046
10046
  const isLast = i === values.length - 1;
10047
10047
  const startVal = isLast ? 0 : runningTotal;
10048
10048
  const endVal = isLast ? runningTotal + val : runningTotal + val;
10049
- const barStartY = chunk7OK75CPY_js.valueToY(startVal, range, layout.plotTop, layout.plotBottom);
10050
- const barEndY = chunk7OK75CPY_js.valueToY(endVal, range, layout.plotTop, layout.plotBottom);
10049
+ const barStartY = chunkR47PKWUJ_js.valueToY(startVal, range, layout.plotTop, layout.plotBottom);
10050
+ const barEndY = chunkR47PKWUJ_js.valueToY(endVal, range, layout.plotTop, layout.plotBottom);
10051
10051
  const x = layout.plotLeft + layout.plotWidth / catCount * i + gap;
10052
10052
  const y = Math.min(barStartY, barEndY);
10053
10053
  const h = Math.max(Math.abs(barEndY - barStartY), 1);
@@ -10076,7 +10076,7 @@ function renderWaterfallChart(element, chartData, categoryLabels) {
10076
10076
  textAnchor: "middle",
10077
10077
  fontSize: 7,
10078
10078
  fill: "#334155",
10079
- children: chunk7OK75CPY_js.formatAxisValue(isLast ? endVal : val)
10079
+ children: chunkR47PKWUJ_js.formatAxisValue(isLast ? endVal : val)
10080
10080
  },
10081
10081
  `${element.id}-wf-dl-${i}`
10082
10082
  )
@@ -10124,18 +10124,18 @@ function renderWaterfallChart(element, chartData, categoryLabels) {
10124
10124
  function renderComboChart(element, chartData, categoryLabels) {
10125
10125
  const style = chartData.style;
10126
10126
  const legendPos = style?.legendPosition || "b";
10127
- const layoutOpts = chunk7OK75CPY_js.computeLayoutOptions(
10127
+ const layoutOpts = chunkR47PKWUJ_js.computeLayoutOptions(
10128
10128
  chartData.axes,
10129
10129
  chartData.dataTable,
10130
10130
  chartData.series.length
10131
10131
  );
10132
- const layout = chunk7OK75CPY_js.computeLayout(element.width, element.height, style, true, legendPos, layoutOpts);
10133
- const { primary, secondary } = chunk7OK75CPY_js.splitSeriesByAxis(chartData.series, chartData.axes);
10132
+ const layout = chunkR47PKWUJ_js.computeLayout(element.width, element.height, style, true, legendPos, layoutOpts);
10133
+ const { primary, secondary } = chunkR47PKWUJ_js.splitSeriesByAxis(chartData.series, chartData.axes);
10134
10134
  const primarySeries = primary.length > 0 ? primary.map((e) => e.series) : chartData.series;
10135
10135
  const secondarySeries = secondary.map((e) => e.series);
10136
- const range = chunk7OK75CPY_js.computeValueRangeForChart(primarySeries, chartData.axes);
10137
- const secondaryRange = secondarySeries.length > 0 ? chunk7OK75CPY_js.computeValueRange(secondarySeries) : void 0;
10138
- const secondaryAxisFmt = chunk7OK75CPY_js.getSecondaryValueAxis(chartData.axes);
10136
+ const range = chunkR47PKWUJ_js.computeValueRangeForChart(primarySeries, chartData.axes);
10137
+ const secondaryRange = secondarySeries.length > 0 ? chunkR47PKWUJ_js.computeValueRange(secondarySeries) : void 0;
10138
+ const secondaryAxisFmt = chunkR47PKWUJ_js.getSecondaryValueAxis(chartData.axes);
10139
10139
  const catCount = Math.max(categoryLabels.length, 1);
10140
10140
  const barSeriesCount = 1;
10141
10141
  const barGroupWidth = layout.plotWidth / catCount;
@@ -10151,8 +10151,8 @@ function renderComboChart(element, chartData, categoryLabels) {
10151
10151
  const barRange = isBarSecondary && secondaryRange ? secondaryRange : range;
10152
10152
  barSeries.values.forEach((val, vi) => {
10153
10153
  const x = layout.plotLeft + barGroupWidth * vi + barOffset;
10154
- const zeroY = chunk7OK75CPY_js.valueToY(0, barRange, layout.plotTop, layout.plotBottom);
10155
- const valY = chunk7OK75CPY_js.valueToY(val, barRange, layout.plotTop, layout.plotBottom);
10154
+ const zeroY = chunkR47PKWUJ_js.valueToY(0, barRange, layout.plotTop, layout.plotBottom);
10155
+ const valY = chunkR47PKWUJ_js.valueToY(val, barRange, layout.plotTop, layout.plotBottom);
10156
10156
  const y = Math.min(zeroY, valY);
10157
10157
  const h = Math.max(Math.abs(zeroY - valY), 1);
10158
10158
  barElements.push(
@@ -10163,7 +10163,7 @@ function renderComboChart(element, chartData, categoryLabels) {
10163
10163
  y,
10164
10164
  width: barWidth,
10165
10165
  height: h,
10166
- fill: chunk7OK75CPY_js.seriesColor(barSeries, 0, chartData.style?.styleId, chartData.colorPalette),
10166
+ fill: chunkR47PKWUJ_js.seriesColor(barSeries, 0, chartData.style?.styleId, chartData.colorPalette),
10167
10167
  rx: 1
10168
10168
  },
10169
10169
  `${element.id}-combo-bar-${vi}`
@@ -10179,7 +10179,7 @@ function renderComboChart(element, chartData, categoryLabels) {
10179
10179
  textAnchor: "middle",
10180
10180
  fontSize: 7,
10181
10181
  fill: "#334155",
10182
- children: chunk7OK75CPY_js.formatAxisValue(val)
10182
+ children: chunkR47PKWUJ_js.formatAxisValue(val)
10183
10183
  },
10184
10184
  `${element.id}-combo-bar-dl-${vi}`
10185
10185
  )
@@ -10196,10 +10196,10 @@ function renderComboChart(element, chartData, categoryLabels) {
10196
10196
  const activeRange = isSecondary && secondaryRange ? secondaryRange : range;
10197
10197
  const points = series.values.map((val, vi) => {
10198
10198
  const x = layout.plotLeft + barGroupWidth * vi + barGroupWidth / 2;
10199
- const y = chunk7OK75CPY_js.valueToY(val, activeRange, layout.plotTop, layout.plotBottom);
10199
+ const y = chunkR47PKWUJ_js.valueToY(val, activeRange, layout.plotTop, layout.plotBottom);
10200
10200
  return { x, y, val };
10201
10201
  });
10202
- const c = chunk7OK75CPY_js.seriesColor(series, seriesIdx, chartData.style?.styleId, chartData.colorPalette);
10202
+ const c = chunkR47PKWUJ_js.seriesColor(series, seriesIdx, chartData.style?.styleId, chartData.colorPalette);
10203
10203
  lineElements.push(
10204
10204
  /* @__PURE__ */ jsxRuntime.jsx(
10205
10205
  "polyline",
@@ -10226,7 +10226,7 @@ function renderComboChart(element, chartData, categoryLabels) {
10226
10226
  textAnchor: "middle",
10227
10227
  fontSize: 7,
10228
10228
  fill: "#334155",
10229
- children: chunk7OK75CPY_js.formatAxisValue(p.val)
10229
+ children: chunkR47PKWUJ_js.formatAxisValue(p.val)
10230
10230
  },
10231
10231
  `${element.id}-combo-line-dl-${si}-${vi}`
10232
10232
  )
@@ -12037,14 +12037,14 @@ function buildNotesPdf(pages) {
12037
12037
  notes: page.notes,
12038
12038
  slideNumber: page.slideNumber
12039
12039
  }));
12040
- const bytes = chunk7OK75CPY_js.buildNotesPdfBytes(images, meta);
12040
+ const bytes = chunkR47PKWUJ_js.buildNotesPdfBytes(images, meta);
12041
12041
  const blob = new Blob([bytes], { type: "application/pdf" });
12042
12042
  return URL.createObjectURL(blob);
12043
12043
  }
12044
12044
 
12045
12045
  // src/viewer/utils/pdf-builder-slides.ts
12046
12046
  function buildPdfFromImageData(images) {
12047
- const bytes = chunk7OK75CPY_js.buildSlidesPdfBytes(images);
12047
+ const bytes = chunkR47PKWUJ_js.buildSlidesPdfBytes(images);
12048
12048
  const blob = new Blob([bytes], { type: "application/pdf" });
12049
12049
  return URL.createObjectURL(blob);
12050
12050
  }
@@ -12053,7 +12053,7 @@ function buildPdfFromImageData(images) {
12053
12053
  var activePreview = null;
12054
12054
  function startPreviewAnimation(elementId, preset, options) {
12055
12055
  stopPreviewAnimation();
12056
- const descriptor = chunk7OK75CPY_js.buildPreviewAnimation(preset, options);
12056
+ const descriptor = chunkR47PKWUJ_js.buildPreviewAnimation(preset, options);
12057
12057
  if (!descriptor) {
12058
12058
  return;
12059
12059
  }
@@ -12131,7 +12131,7 @@ function useElementOperations(input) {
12131
12131
  }, [applySelection, setInlineEditingElementId, setContextMenuState]);
12132
12132
  const updateElementById = React4.useCallback(
12133
12133
  (elementId, updates) => {
12134
- if (chunk7OK75CPY_js.isTemplateElementId(elementId)) {
12134
+ if (chunkR47PKWUJ_js.isTemplateElementId(elementId)) {
12135
12135
  const slideId = activeSlide?.id;
12136
12136
  if (slideId) {
12137
12137
  setTemplateElementsBySlideId((prev) => ({
@@ -12171,7 +12171,7 @@ function useElementOperations(input) {
12171
12171
  );
12172
12172
  const updateSelectedShapeStyle = React4.useCallback(
12173
12173
  (updates) => {
12174
- if (!selectedElement || !chunkZWG6IN7E_js.hasShapeProperties(selectedElement)) {
12174
+ if (!selectedElement || !chunkRVKY3KGH_js.hasShapeProperties(selectedElement)) {
12175
12175
  return;
12176
12176
  }
12177
12177
  updateSelectedElement({
@@ -12182,17 +12182,17 @@ function useElementOperations(input) {
12182
12182
  );
12183
12183
  const updateSelectedTextStyle = React4.useCallback(
12184
12184
  (updates) => {
12185
- if (!selectedElement || !chunkZWG6IN7E_js.hasTextProperties(selectedElement)) {
12185
+ if (!selectedElement || !chunkRVKY3KGH_js.hasTextProperties(selectedElement)) {
12186
12186
  return;
12187
12187
  }
12188
- const inlineSel = chunk7OK75CPY_js.getInlineEditorSelection(selectedElement.textSegments);
12188
+ const inlineSel = chunkR47PKWUJ_js.getInlineEditorSelection(selectedElement.textSegments);
12189
12189
  if (inlineSel && selectedElement.textSegments) {
12190
- const { newSegments: newSegments2, newSelection } = chunk7OK75CPY_js.applyStyleToSelectedSegments(
12190
+ const { newSegments: newSegments2, newSelection } = chunkR47PKWUJ_js.applyStyleToSelectedSegments(
12191
12191
  selectedElement.textSegments,
12192
12192
  inlineSel,
12193
12193
  updates
12194
12194
  );
12195
- chunk7OK75CPY_js.setPendingSelectionRestore(newSelection);
12195
+ chunkR47PKWUJ_js.setPendingSelectionRestore(newSelection);
12196
12196
  updateSelectedElement({
12197
12197
  textSegments: newSegments2
12198
12198
  });
@@ -12212,12 +12212,12 @@ function useElementOperations(input) {
12212
12212
  );
12213
12213
  const updateSelectedTextCase = React4.useCallback(
12214
12214
  (mode) => {
12215
- if (!selectedElement || !chunkZWG6IN7E_js.hasTextProperties(selectedElement)) {
12215
+ if (!selectedElement || !chunkRVKY3KGH_js.hasTextProperties(selectedElement)) {
12216
12216
  return;
12217
12217
  }
12218
- const inlineSel = chunk7OK75CPY_js.getInlineEditorSelection(selectedElement.textSegments);
12218
+ const inlineSel = chunkR47PKWUJ_js.getInlineEditorSelection(selectedElement.textSegments);
12219
12219
  if (inlineSel && selectedElement.textSegments) {
12220
- const newSegments = chunk7OK75CPY_js.applyCaseTransformToSegments(
12220
+ const newSegments = chunkR47PKWUJ_js.applyCaseTransformToSegments(
12221
12221
  selectedElement.textSegments,
12222
12222
  inlineSel,
12223
12223
  mode
@@ -12227,14 +12227,14 @@ function useElementOperations(input) {
12227
12227
  }
12228
12228
  const updates = {};
12229
12229
  if (selectedElement.textSegments && selectedElement.textSegments.length > 0) {
12230
- updates.textSegments = chunk7OK75CPY_js.applyCaseTransformToSegments(
12230
+ updates.textSegments = chunkR47PKWUJ_js.applyCaseTransformToSegments(
12231
12231
  selectedElement.textSegments,
12232
12232
  null,
12233
12233
  mode
12234
12234
  );
12235
12235
  }
12236
12236
  if (typeof selectedElement.text === "string") {
12237
- updates.text = chunk7OK75CPY_js.transformTextCase(selectedElement.text, mode);
12237
+ updates.text = chunkR47PKWUJ_js.transformTextCase(selectedElement.text, mode);
12238
12238
  }
12239
12239
  updateSelectedElement(updates);
12240
12240
  },
@@ -12289,7 +12289,7 @@ function useSectionOperations(input) {
12289
12289
  const { sections, setSections, slides, setSlides, markDirty } = input;
12290
12290
  const addSection2 = React4.useCallback(
12291
12291
  (name, afterSlideIndex) => {
12292
- const result = chunk7OK75CPY_js.addSection(sections, slides, name, afterSlideIndex);
12292
+ const result = chunkR47PKWUJ_js.addSection(sections, slides, name, afterSlideIndex);
12293
12293
  setSlides(result.slides);
12294
12294
  setSections(result.sections);
12295
12295
  markDirty();
@@ -12298,7 +12298,7 @@ function useSectionOperations(input) {
12298
12298
  );
12299
12299
  const renameSection2 = React4.useCallback(
12300
12300
  (sectionId, newName) => {
12301
- const result = chunk7OK75CPY_js.renameSection(sections, slides, sectionId, newName);
12301
+ const result = chunkR47PKWUJ_js.renameSection(sections, slides, sectionId, newName);
12302
12302
  setSections(result.sections);
12303
12303
  setSlides(result.slides);
12304
12304
  markDirty();
@@ -12307,7 +12307,7 @@ function useSectionOperations(input) {
12307
12307
  );
12308
12308
  const deleteSection2 = React4.useCallback(
12309
12309
  (sectionId) => {
12310
- const result = chunk7OK75CPY_js.deleteSection(sections, slides, sectionId);
12310
+ const result = chunkR47PKWUJ_js.deleteSection(sections, slides, sectionId);
12311
12311
  setSections(result.sections);
12312
12312
  setSlides(result.slides);
12313
12313
  markDirty();
@@ -12316,21 +12316,21 @@ function useSectionOperations(input) {
12316
12316
  );
12317
12317
  const moveSectionUp2 = React4.useCallback(
12318
12318
  (sectionId) => {
12319
- setSections(chunk7OK75CPY_js.moveSectionUp(sections, sectionId));
12319
+ setSections(chunkR47PKWUJ_js.moveSectionUp(sections, sectionId));
12320
12320
  markDirty();
12321
12321
  },
12322
12322
  [sections, setSections, markDirty]
12323
12323
  );
12324
12324
  const moveSectionDown2 = React4.useCallback(
12325
12325
  (sectionId) => {
12326
- setSections(chunk7OK75CPY_js.moveSectionDown(sections, sectionId));
12326
+ setSections(chunkR47PKWUJ_js.moveSectionDown(sections, sectionId));
12327
12327
  markDirty();
12328
12328
  },
12329
12329
  [sections, setSections, markDirty]
12330
12330
  );
12331
12331
  const moveSlidesToSection2 = React4.useCallback(
12332
12332
  (slideIndexes, targetSectionId) => {
12333
- const result = chunk7OK75CPY_js.moveSlidesToSection(sections, slides, slideIndexes, targetSectionId);
12333
+ const result = chunkR47PKWUJ_js.moveSlidesToSection(sections, slides, slideIndexes, targetSectionId);
12334
12334
  setSlides(result.slides);
12335
12335
  setSections(result.sections);
12336
12336
  markDirty();
@@ -12349,7 +12349,7 @@ function useSectionOperations(input) {
12349
12349
 
12350
12350
  // src/viewer/hooks/pointer-move-handlers.ts
12351
12351
  function computeResizeGeometry(handle, startX, startY, startWidth, startHeight, dx, dy, snapToGrid, gridSpacingPx) {
12352
- const resized = chunk7OK75CPY_js.applyResize(
12352
+ const resized = chunkR47PKWUJ_js.applyResize(
12353
12353
  { x: startX, y: startY, width: startWidth, height: startHeight },
12354
12354
  handle,
12355
12355
  dx,
@@ -12361,7 +12361,7 @@ function computeResizeGeometry(handle, startX, startY, startWidth, startHeight,
12361
12361
  if (!snapToGrid) {
12362
12362
  return box;
12363
12363
  }
12364
- return chunk7OK75CPY_js.snapBoxToGrid(box, handle, gridSpacingPx, MIN_ELEMENT_SIZE);
12364
+ return chunkR47PKWUJ_js.snapBoxToGrid(box, handle, gridSpacingPx, MIN_ELEMENT_SIZE);
12365
12365
  }
12366
12366
  function computeAdjustmentValue(startAdjustment, dx, startWidth) {
12367
12367
  const range = startWidth || 200;
@@ -12471,7 +12471,7 @@ function processDragMove(e, drag, editorScale, snapToGrid, snapToShape, gridSpac
12471
12471
  width: el.width,
12472
12472
  height: el.height
12473
12473
  }));
12474
- const snapResult = chunk7OK75CPY_js.computeSnapToShape(
12474
+ const snapResult = chunkR47PKWUJ_js.computeSnapToShape(
12475
12475
  targetX,
12476
12476
  targetY,
12477
12477
  primaryEl.width,
@@ -12614,13 +12614,13 @@ function processPointerUp(input) {
12614
12614
  if (i !== activeSlideIndex) {
12615
12615
  return s;
12616
12616
  }
12617
- const rerouted = chunk7OK75CPY_js.rerouteConnectorsForMovedElements(s.elements, movedIds);
12617
+ const rerouted = chunkR47PKWUJ_js.rerouteConnectorsForMovedElements(s.elements, movedIds);
12618
12618
  if (rerouted.length === 0) {
12619
12619
  return s;
12620
12620
  }
12621
12621
  return {
12622
12622
  ...s,
12623
- elements: chunk7OK75CPY_js.applyReroutedConnectors(s.elements, rerouted)
12623
+ elements: chunkR47PKWUJ_js.applyReroutedConnectors(s.elements, rerouted)
12624
12624
  };
12625
12625
  })
12626
12626
  );
@@ -12639,9 +12639,9 @@ function processPointerUp(input) {
12639
12639
  }
12640
12640
  function commitMarquee(marquee, editTemplateMode, templateElements, activeSlide, applySelection, clearSelection) {
12641
12641
  const sourceElements = editTemplateMode ? templateElements : activeSlide?.elements ?? [];
12642
- const hitIds = chunk7OK75CPY_js.computeMarqueeHitIds(marquee, sourceElements);
12642
+ const hitIds = chunkR47PKWUJ_js.computeMarqueeHitIds(marquee, sourceElements);
12643
12643
  if (marquee.additive) {
12644
- const merged = chunk7OK75CPY_js.mergeAdditiveSelection(marquee.baseSelectionIds, hitIds);
12644
+ const merged = chunkR47PKWUJ_js.mergeAdditiveSelection(marquee.baseSelectionIds, hitIds);
12645
12645
  if (merged.length > 0) {
12646
12646
  applySelection(merged[0], merged);
12647
12647
  } else {
@@ -12664,8 +12664,8 @@ function commitDrag(drag, editTemplateMode, activeSlide, activeSlideIndex, setTe
12664
12664
  }
12665
12665
  return { ...el, x: start.x + dx, y: start.y + dy };
12666
12666
  });
12667
- const rerouted = chunk7OK75CPY_js.rerouteConnectorsForMovedElements(movedElements, movedIds);
12668
- return chunk7OK75CPY_js.applyReroutedConnectors(movedElements, rerouted);
12667
+ const rerouted = chunkR47PKWUJ_js.rerouteConnectorsForMovedElements(movedElements, movedIds);
12668
+ return chunkR47PKWUJ_js.applyReroutedConnectors(movedElements, rerouted);
12669
12669
  };
12670
12670
  if (editTemplateMode) {
12671
12671
  const slideId = activeSlide?.id;
@@ -12816,9 +12816,9 @@ function useCanvasInteractions(input) {
12816
12816
  return;
12817
12817
  }
12818
12818
  const el = elementLookup.get(editId);
12819
- if (el && chunkZWG6IN7E_js.hasTextProperties(el)) {
12819
+ if (el && chunkRVKY3KGH_js.hasTextProperties(el)) {
12820
12820
  const committedText = transformCommittedText ? transformCommittedText(inlineEditingText) : inlineEditingText;
12821
- const newSegments = chunk7OK75CPY_js.remapTextToSegments(committedText, el.textSegments, el.textStyle);
12821
+ const newSegments = chunkR47PKWUJ_js.remapTextToSegments(committedText, el.textSegments, el.textStyle);
12822
12822
  ops.updateElementById(editId, {
12823
12823
  text: committedText,
12824
12824
  textSegments: newSegments
@@ -12829,7 +12829,7 @@ function useCanvasInteractions(input) {
12829
12829
  setInlineEditingText("");
12830
12830
  };
12831
12831
  const openEquationEditorForElement = (el) => {
12832
- if (!chunkZWG6IN7E_js.hasTextProperties(el)) {
12832
+ if (!chunkRVKY3KGH_js.hasTextProperties(el)) {
12833
12833
  return false;
12834
12834
  }
12835
12835
  const eqSeg = el.textSegments?.find((seg) => seg.equationXml);
@@ -12858,7 +12858,7 @@ function useCanvasInteractions(input) {
12858
12858
  justSelectedRef.current = false;
12859
12859
  } else {
12860
12860
  const el = elementLookup.get(elementId);
12861
- if (el && chunkZWG6IN7E_js.hasTextProperties(el) && !el.locks?.noTextEdit) {
12861
+ if (el && chunkRVKY3KGH_js.hasTextProperties(el) && !el.locks?.noTextEdit) {
12862
12862
  if (!openEquationEditorForElement(el)) {
12863
12863
  setInlineEditingElementId(elementId);
12864
12864
  setInlineEditingText(el.text ?? "");
@@ -12877,7 +12877,7 @@ function useCanvasInteractions(input) {
12877
12877
  if (openEquationEditorForElement(el)) {
12878
12878
  return;
12879
12879
  }
12880
- if (chunkZWG6IN7E_js.hasTextProperties(el)) {
12880
+ if (chunkRVKY3KGH_js.hasTextProperties(el)) {
12881
12881
  setInlineEditingElementId(elementId);
12882
12882
  setInlineEditingText(el.text ?? "");
12883
12883
  }
@@ -13067,7 +13067,7 @@ function createFileHandlers(deps) {
13067
13067
  h = Math.round(h * scale);
13068
13068
  }
13069
13069
  addElement({
13070
- id: chunk7OK75CPY_js.generateElementId(),
13070
+ id: chunkR47PKWUJ_js.generateElementId(),
13071
13071
  type: "image",
13072
13072
  x: Math.round((canvasSize.width - w) / 2),
13073
13073
  y: Math.round((canvasSize.height - h) / 2),
@@ -13078,7 +13078,7 @@ function createFileHandlers(deps) {
13078
13078
  };
13079
13079
  img.onerror = () => {
13080
13080
  addElement({
13081
- id: chunk7OK75CPY_js.generateElementId(),
13081
+ id: chunkR47PKWUJ_js.generateElementId(),
13082
13082
  type: "image",
13083
13083
  x: 100,
13084
13084
  y: 100,
@@ -13104,7 +13104,7 @@ function createFileHandlers(deps) {
13104
13104
  const elFilePath = file.path;
13105
13105
  const insertMediaElement = (mediaSourceUrl, width, height) => {
13106
13106
  addElement({
13107
- id: chunk7OK75CPY_js.generateElementId(),
13107
+ id: chunkR47PKWUJ_js.generateElementId(),
13108
13108
  type: "media",
13109
13109
  mediaType,
13110
13110
  mediaMimeType: file.type || void 0,
@@ -13279,13 +13279,13 @@ function createStructuredElementHandlers(deps) {
13279
13279
  return;
13280
13280
  }
13281
13281
  addElement({
13282
- id: chunk7OK75CPY_js.generateElementId(),
13282
+ id: chunkR47PKWUJ_js.generateElementId(),
13283
13283
  type: "smartArt",
13284
13284
  x: 100,
13285
13285
  y: 120,
13286
13286
  width: 600,
13287
13287
  height: 340,
13288
- smartArtData: chunk7OK75CPY_js.buildSmartArtPresetData(
13288
+ smartArtData: chunkR47PKWUJ_js.buildSmartArtPresetData(
13289
13289
  layout,
13290
13290
  defaultItems,
13291
13291
  (i) => `node-${Date.now()}-${i}-${Math.random().toString(36).slice(2, 8)}`
@@ -13297,7 +13297,7 @@ function createStructuredElementHandlers(deps) {
13297
13297
  return;
13298
13298
  }
13299
13299
  addElement({
13300
- id: chunk7OK75CPY_js.generateElementId(),
13300
+ id: chunkR47PKWUJ_js.generateElementId(),
13301
13301
  type: "shape",
13302
13302
  x: 120,
13303
13303
  y: 200,
@@ -13356,7 +13356,7 @@ function createStructuredElementHandlers(deps) {
13356
13356
  const displayText = value || fieldTexts[fieldType] || fieldType;
13357
13357
  const fieldGuid = `{${crypto.randomUUID().toUpperCase()}}`;
13358
13358
  addElement({
13359
- id: chunk7OK75CPY_js.generateElementId(),
13359
+ id: chunkR47PKWUJ_js.generateElementId(),
13360
13360
  type: "shape",
13361
13361
  x: 120,
13362
13362
  y: 200,
@@ -13378,11 +13378,11 @@ function createStructuredElementHandlers(deps) {
13378
13378
  if (!activeSlide) {
13379
13379
  return;
13380
13380
  }
13381
- const preset = chunk7OK75CPY_js.ACTION_BUTTON_PRESETS.find((p) => p.shapeType === shapeType);
13381
+ const preset = chunkR47PKWUJ_js.ACTION_BUTTON_PRESETS.find((p) => p.shapeType === shapeType);
13382
13382
  if (!preset) {
13383
13383
  return;
13384
13384
  }
13385
- const defaultPptxAction = chunkZWG6IN7E_js.elementActionToPptxAction({
13385
+ const defaultPptxAction = chunkRVKY3KGH_js.elementActionToPptxAction({
13386
13386
  trigger: "click",
13387
13387
  type: preset.defaultAction
13388
13388
  });
@@ -13391,7 +13391,7 @@ function createStructuredElementHandlers(deps) {
13391
13391
  defaultPptxAction.highlightClick = true;
13392
13392
  }
13393
13393
  addElement({
13394
- id: chunk7OK75CPY_js.generateElementId(),
13394
+ id: chunkR47PKWUJ_js.generateElementId(),
13395
13395
  type: "shape",
13396
13396
  x: 150,
13397
13397
  y: 150,
@@ -13458,7 +13458,7 @@ function useInsertElements(input) {
13458
13458
  return;
13459
13459
  }
13460
13460
  addElement({
13461
- id: chunk7OK75CPY_js.generateElementId(),
13461
+ id: chunkR47PKWUJ_js.generateElementId(),
13462
13462
  type: "text",
13463
13463
  x: 100,
13464
13464
  y: 100,
@@ -13473,7 +13473,7 @@ function useInsertElements(input) {
13473
13473
  return;
13474
13474
  }
13475
13475
  addElement({
13476
- id: chunk7OK75CPY_js.generateElementId(),
13476
+ id: chunkR47PKWUJ_js.generateElementId(),
13477
13477
  type: "shape",
13478
13478
  x: 150,
13479
13479
  y: 150,
@@ -13492,15 +13492,15 @@ function useInsertElements(input) {
13492
13492
  return;
13493
13493
  }
13494
13494
  addElement({
13495
- ...chunk7OK75CPY_js.newTableElement(DEFAULT_TABLE_ROWS, DEFAULT_TABLE_COLUMNS, 100, 200),
13496
- id: chunk7OK75CPY_js.generateElementId()
13495
+ ...chunkR47PKWUJ_js.newTableElement(DEFAULT_TABLE_ROWS, DEFAULT_TABLE_COLUMNS, 100, 200),
13496
+ id: chunkR47PKWUJ_js.generateElementId()
13497
13497
  });
13498
13498
  };
13499
13499
  const handleAddChart = (chartType) => {
13500
13500
  if (!activeSlide) {
13501
13501
  return;
13502
13502
  }
13503
- addElement(chunk7OK75CPY_js.createDefaultChartElement(chartType));
13503
+ addElement(chunkR47PKWUJ_js.createDefaultChartElement(chartType));
13504
13504
  };
13505
13505
  const structured = createStructuredElementHandlers({
13506
13506
  activeSlide,
@@ -13570,7 +13570,7 @@ function useClipboardHandlers(input) {
13570
13570
  if (!selectedElement) {
13571
13571
  return;
13572
13572
  }
13573
- setClipboardPayload(chunk7OK75CPY_js.buildElementClipboardPayload(selectedElement, editTemplateMode));
13573
+ setClipboardPayload(chunkR47PKWUJ_js.buildElementClipboardPayload(selectedElement, editTemplateMode));
13574
13574
  };
13575
13575
  const handleDelete = () => {
13576
13576
  const idsToDelete = effectiveSelectedIds;
@@ -13587,7 +13587,7 @@ function useClipboardHandlers(input) {
13587
13587
  handleDelete();
13588
13588
  };
13589
13589
  const insertClone = (source) => {
13590
- const clone = chunk7OK75CPY_js.cloneElementForPaste(source, { intoTemplate: editTemplateMode });
13590
+ const clone = chunkR47PKWUJ_js.cloneElementForPaste(source, { intoTemplate: editTemplateMode });
13591
13591
  ops.updateActiveElements((els) => [...els, clone]);
13592
13592
  ops.applySelection(clone.id);
13593
13593
  history.markDirty();
@@ -13622,7 +13622,7 @@ function resolveShapePath(el) {
13622
13622
  return el.pathData;
13623
13623
  }
13624
13624
  if ("shapeType" in el && typeof el.shapeType === "string") {
13625
- const clipPath = chunkZWG6IN7E_js.getPresetShapeClipPath(el.shapeType);
13625
+ const clipPath = chunkRVKY3KGH_js.getPresetShapeClipPath(el.shapeType);
13626
13626
  if (clipPath) {
13627
13627
  const svgPath = clipPathToSvgPath(clipPath, el.width, el.height);
13628
13628
  if (svgPath) {
@@ -13673,7 +13673,7 @@ function clipPathToSvgPath(clipPath, width, height) {
13673
13673
  return parts.join(" ");
13674
13674
  }
13675
13675
  function transformPathToGlobal(pathData, el) {
13676
- const polys = chunkZWG6IN7E_js.svgPathToPolygons(pathData);
13676
+ const polys = chunkRVKY3KGH_js.svgPathToPolygons(pathData);
13677
13677
  if (polys.length === 0) {
13678
13678
  return pathData;
13679
13679
  }
@@ -13693,10 +13693,10 @@ function transformPathToGlobal(pathData, el) {
13693
13693
  y: pt.y * scaleY + el.y
13694
13694
  }))
13695
13695
  );
13696
- return chunkZWG6IN7E_js.polygonsToSvgPath(transformed);
13696
+ return chunkRVKY3KGH_js.polygonsToSvgPath(transformed);
13697
13697
  }
13698
13698
  function transformPathToLocal(pathData, x, y, _width, _height) {
13699
- const polys = chunkZWG6IN7E_js.svgPathToPolygons(pathData);
13699
+ const polys = chunkRVKY3KGH_js.svgPathToPolygons(pathData);
13700
13700
  if (polys.length === 0) {
13701
13701
  return pathData;
13702
13702
  }
@@ -13706,10 +13706,10 @@ function transformPathToLocal(pathData, x, y, _width, _height) {
13706
13706
  y: pt.y - y
13707
13707
  }))
13708
13708
  );
13709
- return chunkZWG6IN7E_js.polygonsToSvgPath(transformed);
13709
+ return chunkRVKY3KGH_js.polygonsToSvgPath(transformed);
13710
13710
  }
13711
13711
  function pathBounds(pathData) {
13712
- const polys = chunkZWG6IN7E_js.svgPathToPolygons(pathData);
13712
+ const polys = chunkRVKY3KGH_js.svgPathToPolygons(pathData);
13713
13713
  let minX = Infinity;
13714
13714
  let minY = Infinity;
13715
13715
  let maxX = -Infinity;
@@ -13768,7 +13768,7 @@ function useMergeShapesHandler(input) {
13768
13768
  let allFragments = [];
13769
13769
  let remaining = globalPaths[0];
13770
13770
  for (let i = 1; i < globalPaths.length; i++) {
13771
- const frags = chunkZWG6IN7E_js.mergeShapes("fragment", remaining, globalPaths[i]);
13771
+ const frags = chunkRVKY3KGH_js.mergeShapes("fragment", remaining, globalPaths[i]);
13772
13772
  if (Array.isArray(frags)) {
13773
13773
  allFragments = frags;
13774
13774
  }
@@ -13797,7 +13797,7 @@ function useMergeShapesHandler(input) {
13797
13797
  bounds.height
13798
13798
  );
13799
13799
  const newEl = {
13800
- id: chunk7OK75CPY_js.generateElementId(),
13800
+ id: chunkR47PKWUJ_js.generateElementId(),
13801
13801
  type: "shape",
13802
13802
  x: bounds.x,
13803
13803
  y: bounds.y,
@@ -13835,7 +13835,7 @@ function useMergeShapesHandler(input) {
13835
13835
  } else {
13836
13836
  let resultPath = globalPaths[0];
13837
13837
  for (let i = 1; i < globalPaths.length; i++) {
13838
- const result = chunkZWG6IN7E_js.mergeShapes(operation, resultPath, globalPaths[i]);
13838
+ const result = chunkRVKY3KGH_js.mergeShapes(operation, resultPath, globalPaths[i]);
13839
13839
  if (typeof result === "string") {
13840
13840
  resultPath = result;
13841
13841
  }
@@ -13856,7 +13856,7 @@ function useMergeShapesHandler(input) {
13856
13856
  );
13857
13857
  const primary = targets[0];
13858
13858
  const newEl = {
13859
- id: chunk7OK75CPY_js.generateElementId(),
13859
+ id: chunkR47PKWUJ_js.generateElementId(),
13860
13860
  type: "shape",
13861
13861
  x: bounds.x,
13862
13862
  y: bounds.y,
@@ -13919,7 +13919,7 @@ function useGroupAlignLayerHandlers(input) {
13919
13919
  if (ids.length < 2 || !activeSlide) {
13920
13920
  return;
13921
13921
  }
13922
- const { elements, groupId } = chunk7OK75CPY_js.groupElements(ops.activeElements, ids, chunk7OK75CPY_js.generateElementId());
13922
+ const { elements, groupId } = chunkR47PKWUJ_js.groupElements(ops.activeElements, ids, chunkR47PKWUJ_js.generateElementId());
13923
13923
  if (groupId === null) {
13924
13924
  return;
13925
13925
  }
@@ -13932,12 +13932,12 @@ function useGroupAlignLayerHandlers(input) {
13932
13932
  return;
13933
13933
  }
13934
13934
  const group = selectedElement;
13935
- const intoTemplate = chunk7OK75CPY_js.isTemplateElementId(group.id);
13935
+ const intoTemplate = chunkR47PKWUJ_js.isTemplateElementId(group.id);
13936
13936
  const ungrouped = group.children.map((child) => ({
13937
13937
  ...structuredClone(child),
13938
13938
  // Keep child ids in the same store as the group so later edits route
13939
13939
  // correctly: template groups yield template-prefixed child ids.
13940
- id: intoTemplate ? chunk7OK75CPY_js.makeCloneId(true, child.id || group.id) : child.id || chunk7OK75CPY_js.generateElementId(),
13940
+ id: intoTemplate ? chunkR47PKWUJ_js.makeCloneId(true, child.id || group.id) : child.id || chunkR47PKWUJ_js.generateElementId(),
13941
13941
  x: child.x + group.x,
13942
13942
  y: child.y + group.y
13943
13943
  }));
@@ -13961,7 +13961,7 @@ function useGroupAlignLayerHandlers(input) {
13961
13961
  if (!edge) {
13962
13962
  return;
13963
13963
  }
13964
- const positions = chunk7OK75CPY_js.alignElements(selectedElements, edge);
13964
+ const positions = chunkR47PKWUJ_js.alignElements(selectedElements, edge);
13965
13965
  for (const [id, pos] of positions) {
13966
13966
  const el = elementLookup.get(id);
13967
13967
  if (!el) {
@@ -13979,7 +13979,7 @@ function useGroupAlignLayerHandlers(input) {
13979
13979
  if (!distAxis) {
13980
13980
  return;
13981
13981
  }
13982
- const positions = chunk7OK75CPY_js.distributeElements(selectedElements, distAxis);
13982
+ const positions = chunkR47PKWUJ_js.distributeElements(selectedElements, distAxis);
13983
13983
  for (const [id, pos] of positions) {
13984
13984
  const el = elementLookup.get(id);
13985
13985
  if (!el) {
@@ -13996,7 +13996,7 @@ function useGroupAlignLayerHandlers(input) {
13996
13996
  }
13997
13997
  const id = selectedElement.id;
13998
13998
  ops.updateActiveElements(
13999
- (els) => direction === "forward" ? chunk7OK75CPY_js.bringForward(els, id) : direction === "backward" ? chunk7OK75CPY_js.sendBackward(els, id) : els
13999
+ (els) => direction === "forward" ? chunkR47PKWUJ_js.bringForward(els, id) : direction === "backward" ? chunkR47PKWUJ_js.sendBackward(els, id) : els
14000
14000
  );
14001
14001
  history.markDirty();
14002
14002
  };
@@ -14006,7 +14006,7 @@ function useGroupAlignLayerHandlers(input) {
14006
14006
  }
14007
14007
  const id = selectedElement.id;
14008
14008
  ops.updateActiveElements(
14009
- (els) => direction === "front" ? chunk7OK75CPY_js.bringToFront(els, id) : chunk7OK75CPY_js.sendToBack(els, id)
14009
+ (els) => direction === "front" ? chunkR47PKWUJ_js.bringToFront(els, id) : chunkR47PKWUJ_js.sendToBack(els, id)
14010
14010
  );
14011
14011
  history.markDirty();
14012
14012
  };
@@ -14128,7 +14128,7 @@ function insertSlideFromLayoutUpdater(slides, activeIndex, draft) {
14128
14128
  function useSlideManagement(input) {
14129
14129
  const { slides, activeSlideIndex, setActiveSlideIndex, ops, history, handlerRef } = input;
14130
14130
  const handleAddSlide = () => {
14131
- const newSlide = chunk7OK75CPY_js.createBlankSlide(slides.length + 1);
14131
+ const newSlide = chunkR47PKWUJ_js.createBlankSlide(slides.length + 1);
14132
14132
  ops.updateSlides((prev) => {
14133
14133
  const next = [...prev];
14134
14134
  next.splice(activeSlideIndex + 1, 0, newSlide);
@@ -14191,7 +14191,7 @@ function useSlideManagement(input) {
14191
14191
  }
14192
14192
  const clone = {
14193
14193
  ...src,
14194
- id: chunk7OK75CPY_js.makeSlideId(),
14194
+ id: chunkR47PKWUJ_js.makeSlideId(),
14195
14195
  rId: "",
14196
14196
  // Unlike a new blank slide, a duplicate must explicitly copy the
14197
14197
  // source slide's relationship part (images, charts, notes, etc.).
@@ -14227,7 +14227,7 @@ function useSlideManagement(input) {
14227
14227
  const handleInsertSlideFromLayout = (layoutPath, layoutName) => {
14228
14228
  const insertAt = activeSlideIndex + 1;
14229
14229
  const draft = {
14230
- ...chunk7OK75CPY_js.createBlankSlide(slides.length + 1),
14230
+ ...chunkR47PKWUJ_js.createBlankSlide(slides.length + 1),
14231
14231
  layoutPath,
14232
14232
  ...layoutName ? { layoutName } : {}
14233
14233
  };
@@ -14288,7 +14288,7 @@ function createTableMergeHandlers(input) {
14288
14288
  if (!nextCell || nextCell.hMerge || nextCell.vMerge) {
14289
14289
  return;
14290
14290
  }
14291
- const newTableData = chunk7OK75CPY_js.mergeCells(
14291
+ const newTableData = chunkR47PKWUJ_js.mergeCells(
14292
14292
  [
14293
14293
  { row: rowIndex, col: columnIndex },
14294
14294
  { row: rowIndex, col: nextColIdx }
@@ -14296,7 +14296,7 @@ function createTableMergeHandlers(input) {
14296
14296
  td
14297
14297
  );
14298
14298
  const updates = { tableData: newTableData };
14299
- const newRawXml = chunkZWG6IN7E_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
14299
+ const newRawXml = chunkRVKY3KGH_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
14300
14300
  if (newRawXml) {
14301
14301
  updates.rawXml = newRawXml;
14302
14302
  }
@@ -14322,7 +14322,7 @@ function createTableMergeHandlers(input) {
14322
14322
  if (!targetNextCell || targetNextCell.hMerge || targetNextCell.vMerge) {
14323
14323
  return;
14324
14324
  }
14325
- const newTableData = chunk7OK75CPY_js.mergeCells(
14325
+ const newTableData = chunkR47PKWUJ_js.mergeCells(
14326
14326
  [
14327
14327
  { row: rowIndex, col: columnIndex },
14328
14328
  { row: targetNextRowIdx, col: columnIndex }
@@ -14330,7 +14330,7 @@ function createTableMergeHandlers(input) {
14330
14330
  td
14331
14331
  );
14332
14332
  const updates = { tableData: newTableData };
14333
- const newRawXml = chunkZWG6IN7E_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
14333
+ const newRawXml = chunkRVKY3KGH_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
14334
14334
  if (newRawXml) {
14335
14335
  updates.rawXml = newRawXml;
14336
14336
  }
@@ -14345,9 +14345,9 @@ function createTableMergeHandlers(input) {
14345
14345
  return;
14346
14346
  }
14347
14347
  const td = selectedElement.tableData;
14348
- const newTableData = chunk7OK75CPY_js.mergeCells(ts.selectedCells, td);
14348
+ const newTableData = chunkR47PKWUJ_js.mergeCells(ts.selectedCells, td);
14349
14349
  const updates = { tableData: newTableData };
14350
- const newRawXml = chunkZWG6IN7E_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
14350
+ const newRawXml = chunkRVKY3KGH_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
14351
14351
  if (newRawXml) {
14352
14352
  updates.rawXml = newRawXml;
14353
14353
  }
@@ -14364,9 +14364,9 @@ function createTableMergeHandlers(input) {
14364
14364
  }
14365
14365
  const { rowIndex, columnIndex } = ts;
14366
14366
  const td = selectedElement.tableData;
14367
- const newTableData = chunk7OK75CPY_js.splitCell(rowIndex, columnIndex, td);
14367
+ const newTableData = chunkR47PKWUJ_js.splitCell(rowIndex, columnIndex, td);
14368
14368
  const updates = { tableData: newTableData };
14369
- const newRawXml = chunkZWG6IN7E_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
14369
+ const newRawXml = chunkRVKY3KGH_js.updateMergeAttrsInRawXml(selectedElement, newTableData);
14370
14370
  if (newRawXml) {
14371
14371
  updates.rawXml = newRawXml;
14372
14372
  }
@@ -14410,7 +14410,7 @@ function createTableStructHandlers(input) {
14410
14410
  updates.tableData = { ...el.tableData, rows: newRows };
14411
14411
  }
14412
14412
  if (el.rawXml) {
14413
- const newRawXml = chunkZWG6IN7E_js.updateCellTextInRawXml(el, rowIndex, colIndex, text);
14413
+ const newRawXml = chunkRVKY3KGH_js.updateCellTextInRawXml(el, rowIndex, colIndex, text);
14414
14414
  if (newRawXml) {
14415
14415
  updates.rawXml = newRawXml;
14416
14416
  }
@@ -14434,7 +14434,7 @@ function createTableStructHandlers(input) {
14434
14434
  const { rowIndex, columnIndex: colIndex } = ts;
14435
14435
  const updates = {};
14436
14436
  if (selectedElement.rawXml) {
14437
- const newRawXml = chunkZWG6IN7E_js.updateCellTextStyleInRawXml(
14437
+ const newRawXml = chunkRVKY3KGH_js.updateCellTextStyleInRawXml(
14438
14438
  selectedElement,
14439
14439
  rowIndex,
14440
14440
  colIndex,
@@ -14498,9 +14498,9 @@ function createTableStructHandlers(input) {
14498
14498
  return;
14499
14499
  }
14500
14500
  const rowIdx = ts?.rowIndex ?? 0;
14501
- const newTableData = chunk7OK75CPY_js.insertTableRow(selectedElement.tableData, rowIdx, position);
14501
+ const newTableData = chunkR47PKWUJ_js.insertTableRow(selectedElement.tableData, rowIdx, position);
14502
14502
  const updates = { tableData: newTableData };
14503
- const newRawXml = chunkZWG6IN7E_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
14503
+ const newRawXml = chunkRVKY3KGH_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
14504
14504
  if (newRawXml) {
14505
14505
  updates.rawXml = newRawXml;
14506
14506
  }
@@ -14513,12 +14513,12 @@ function createTableStructHandlers(input) {
14513
14513
  }
14514
14514
  const td = selectedElement.tableData;
14515
14515
  const rowIdx = ts?.rowIndex ?? 0;
14516
- const newTableData = chunk7OK75CPY_js.deleteTableRow(td, rowIdx);
14516
+ const newTableData = chunkR47PKWUJ_js.deleteTableRow(td, rowIdx);
14517
14517
  if (newTableData === td) {
14518
14518
  return;
14519
14519
  }
14520
14520
  const updates = { tableData: newTableData };
14521
- const newRawXml = chunkZWG6IN7E_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
14521
+ const newRawXml = chunkRVKY3KGH_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
14522
14522
  if (newRawXml) {
14523
14523
  updates.rawXml = newRawXml;
14524
14524
  }
@@ -14530,9 +14530,9 @@ function createTableStructHandlers(input) {
14530
14530
  return;
14531
14531
  }
14532
14532
  const colIdx = ts?.columnIndex ?? 0;
14533
- const newTableData = chunk7OK75CPY_js.insertTableColumn(selectedElement.tableData, colIdx, position);
14533
+ const newTableData = chunkR47PKWUJ_js.insertTableColumn(selectedElement.tableData, colIdx, position);
14534
14534
  const updates = { tableData: newTableData };
14535
- const newRawXml = chunkZWG6IN7E_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
14535
+ const newRawXml = chunkRVKY3KGH_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
14536
14536
  if (newRawXml) {
14537
14537
  updates.rawXml = newRawXml;
14538
14538
  }
@@ -14545,12 +14545,12 @@ function createTableStructHandlers(input) {
14545
14545
  }
14546
14546
  const td = selectedElement.tableData;
14547
14547
  const colIdx = ts?.columnIndex ?? 0;
14548
- const newTableData = chunk7OK75CPY_js.deleteTableColumn(td, colIdx);
14548
+ const newTableData = chunkR47PKWUJ_js.deleteTableColumn(td, colIdx);
14549
14549
  if (newTableData === td) {
14550
14550
  return;
14551
14551
  }
14552
14552
  const updates = { tableData: newTableData };
14553
- const newRawXml = chunkZWG6IN7E_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
14553
+ const newRawXml = chunkRVKY3KGH_js.rebuildTableStructureInRawXml(selectedElement, newTableData);
14554
14554
  if (newRawXml) {
14555
14555
  updates.rawXml = newRawXml;
14556
14556
  }
@@ -14586,8 +14586,8 @@ async function renderToCanvas(element, options = {}) {
14586
14586
  return html2canvasPro(element, {
14587
14587
  ...options,
14588
14588
  onclone: async (doc, clonedEl) => {
14589
- await chunk7OK75CPY_js.normalizeColorsForCapture(doc, clonedEl);
14590
- chunk7OK75CPY_js.preprocessCssForCapture(clonedEl);
14589
+ await chunkR47PKWUJ_js.normalizeColorsForCapture(doc, clonedEl);
14590
+ chunkR47PKWUJ_js.preprocessCssForCapture(clonedEl);
14591
14591
  if (typeof userOnClone === "function") {
14592
14592
  userOnClone(doc, clonedEl);
14593
14593
  }
@@ -14643,7 +14643,7 @@ async function exportSlideToPngBlob(slideElement, options = {}) {
14643
14643
  }
14644
14644
  async function exportSlideAsPng(slideElement, slideIndex, options = {}) {
14645
14645
  const blob = await exportSlideToPngBlob(slideElement, options);
14646
- chunk7OK75CPY_js.downloadBlob(blob, `slide-${slideIndex + 1}.png`);
14646
+ chunkR47PKWUJ_js.downloadBlob(blob, `slide-${slideIndex + 1}.png`);
14647
14647
  }
14648
14648
  async function copySlideToClipboard(slideElement, options = {}) {
14649
14649
  const blob = await exportSlideToPngBlob(slideElement, options);
@@ -14665,7 +14665,7 @@ async function exportAllSlidesAsPdf(slideStageRef, totalSlides, setActiveSlide,
14665
14665
  continue;
14666
14666
  }
14667
14667
  const canvas = await renderElementToCanvas(stageEl, scale);
14668
- images.push(chunk7OK75CPY_js.canvasToJpegData(canvas));
14668
+ images.push(chunkR47PKWUJ_js.canvasToJpegData(canvas));
14669
14669
  }
14670
14670
  onProgress?.(totalSlides, totalSlides);
14671
14671
  setActiveSlide(currentSlideIndex);
@@ -14673,7 +14673,7 @@ async function exportAllSlidesAsPdf(slideStageRef, totalSlides, setActiveSlide,
14673
14673
  throw new Error(chunkCUUYYYC5_js.translationsEn["pptx.export.errorNoSlidesPdf"]);
14674
14674
  }
14675
14675
  const pdfBlobUrl = buildPdfFromImageData(images);
14676
- chunk7OK75CPY_js.downloadDataUrl(pdfBlobUrl, filename);
14676
+ chunkR47PKWUJ_js.downloadDataUrl(pdfBlobUrl, filename);
14677
14677
  }
14678
14678
  async function captureAllSlidesAsPngDataUrls(slideStageRef, totalSlides, setActiveSlide, currentSlideIndex, options = {}) {
14679
14679
  const { scale = 2, onProgress } = options;
@@ -14722,7 +14722,7 @@ async function exportAllSlidesAsNotesPdf(slideStageRef, totalSlides, setActiveSl
14722
14722
  throw new Error(chunkCUUYYYC5_js.translationsEn["pptx.export.errorNoSlidesNotesPdf"]);
14723
14723
  }
14724
14724
  const pdfDataUrl = buildNotesPdf(pages);
14725
- chunk7OK75CPY_js.downloadDataUrl(pdfDataUrl, filename);
14725
+ chunkR47PKWUJ_js.downloadDataUrl(pdfDataUrl, filename);
14726
14726
  }
14727
14727
 
14728
14728
  // src/viewer/utils/export-video.ts
@@ -14766,7 +14766,7 @@ async function exportAllSlidesAsVideo(slideStageRef, totalSlides, setActiveSlide
14766
14766
  const fps = 30;
14767
14767
  const stream = recordingCanvas.captureStream(fps);
14768
14768
  const recorder = new MediaRecorder(stream, {
14769
- mimeType: chunk7OK75CPY_js.pickSupportedMimeType([...chunk7OK75CPY_js.WEBM_MIME_CANDIDATES]),
14769
+ mimeType: chunkR47PKWUJ_js.pickSupportedMimeType([...chunkR47PKWUJ_js.WEBM_MIME_CANDIDATES]),
14770
14770
  videoBitsPerSecond: 5e6
14771
14771
  });
14772
14772
  const chunks = [];
@@ -14789,8 +14789,8 @@ async function exportAllSlidesAsVideo(slideStageRef, totalSlides, setActiveSlide
14789
14789
  const duration = slideTimingsMs?.[i] ?? slideDurationMs;
14790
14790
  ctx.clearRect(0, 0, recordingCanvas.width, recordingCanvas.height);
14791
14791
  ctx.drawImage(slideCanvases[i], 0, 0);
14792
- const frameInterval = chunk7OK75CPY_js.fpsToFrameIntervalMs(fps);
14793
- const framesNeeded = chunk7OK75CPY_js.segmentFrameCount(duration, fps);
14792
+ const frameInterval = chunkR47PKWUJ_js.fpsToFrameIntervalMs(fps);
14793
+ const framesNeeded = chunkR47PKWUJ_js.segmentFrameCount(duration, fps);
14794
14794
  for (let f = 0; f < framesNeeded; f++) {
14795
14795
  if (signal?.aborted) {
14796
14796
  recorder.stop();
@@ -14839,7 +14839,7 @@ async function exportAllSlidesAsGif(slideStageRef, totalSlides, setActiveSlide,
14839
14839
  if (frames.length === 0) {
14840
14840
  throw new Error(chunkCUUYYYC5_js.translationsEn["pptx.export.errorNoSlidesGif"]);
14841
14841
  }
14842
- const gifBytes = chunk7OK75CPY_js.encodeGif(frames, Math.round(slideDurationMs / 10));
14842
+ const gifBytes = chunkR47PKWUJ_js.encodeGif(frames, Math.round(slideDurationMs / 10));
14843
14843
  onProgress?.(totalSlides, totalSlides);
14844
14844
  const buf = new ArrayBuffer(gifBytes.length);
14845
14845
  new Uint8Array(buf).set(gifBytes);
@@ -14893,7 +14893,7 @@ function exportAllSlidesToSvg(data, options = {}) {
14893
14893
  continue;
14894
14894
  }
14895
14895
  onProgress?.(processedCount, data.slides.length);
14896
- let svg = chunkZWG6IN7E_js.SvgExporter.exportSlide(slide, data.width, data.height, svgOptions);
14896
+ let svg = chunkRVKY3KGH_js.SvgExporter.exportSlide(slide, data.width, data.height, svgOptions);
14897
14897
  if (embedFonts && fontFaces?.length) {
14898
14898
  svg = injectFontFaces(svg, fontFaces);
14899
14899
  }
@@ -14953,7 +14953,7 @@ function useExportSaveAs(input) {
14953
14953
  }
14954
14954
  setExportProgress(70);
14955
14955
  setExportStatusMessage("Writing README...");
14956
- const readme = chunk7OK75CPY_js.generatePackageReadme(pptxFilename);
14956
+ const readme = chunkR47PKWUJ_js.generatePackageReadme(pptxFilename);
14957
14957
  pkgFolder.file("README.txt", readme);
14958
14958
  if (abortCtrl.signal.aborted) {
14959
14959
  throw new DOMException("Export cancelled", "AbortError");
@@ -14964,7 +14964,7 @@ function useExportSaveAs(input) {
14964
14964
  setExportProgress(95);
14965
14965
  setExportStatusMessage("Downloading...");
14966
14966
  const baseName = pptxFilename.replace(/\.[^.]+$/u, "");
14967
- chunk7OK75CPY_js.downloadBlob(zipBlob, `${baseName}-package.zip`);
14967
+ chunkR47PKWUJ_js.downloadBlob(zipBlob, `${baseName}-package.zip`);
14968
14968
  setExportProgress(100);
14969
14969
  } catch (err) {
14970
14970
  if (err.name !== "AbortError") {
@@ -14987,7 +14987,7 @@ function useExportSaveAs(input) {
14987
14987
  const blob = new Blob([data], {
14988
14988
  type: "application/vnd.openxmlformats-officedocument.presentationml.presentation"
14989
14989
  });
14990
- chunk7OK75CPY_js.downloadBlob(blob, `${baseName}.${ext}`);
14990
+ chunkR47PKWUJ_js.downloadBlob(blob, `${baseName}.${ext}`);
14991
14991
  } catch (err) {
14992
14992
  console.error(`[PowerPointViewer] Save as .${ext} failed:`, err);
14993
14993
  }
@@ -15000,7 +15000,7 @@ function useExportSaveAs(input) {
15000
15000
  const pptxGuides = guides.map((g) => ({
15001
15001
  id: g.id,
15002
15002
  orientation: g.axis === "h" ? "horz" : "vert",
15003
- positionEmu: chunkZWG6IN7E_js.guidePxToEmu(g.position)
15003
+ positionEmu: chunkRVKY3KGH_js.guidePxToEmu(g.position)
15004
15004
  }));
15005
15005
  return {
15006
15006
  ...slide,
@@ -15064,7 +15064,7 @@ function safeConfirm(message) {
15064
15064
  }
15065
15065
  }
15066
15066
  function downloadBlob2(blob, filename) {
15067
- chunk7OK75CPY_js.downloadBlob(blob, chunk7OK75CPY_js.sanitizeDownloadFilename(filename));
15067
+ chunkR47PKWUJ_js.downloadBlob(blob, chunkR47PKWUJ_js.sanitizeDownloadFilename(filename));
15068
15068
  }
15069
15069
 
15070
15070
  // src/viewer/hooks/useExportHandlers.ts
@@ -15165,21 +15165,21 @@ function useExportHandlers(input) {
15165
15165
  {
15166
15166
  scale: 2,
15167
15167
  onProgress: (current, total) => {
15168
- setExportProgress(chunk7OK75CPY_js.slideProgressPercent(current, total));
15169
- setExportStatusMessage(chunk7OK75CPY_js.slideStatusLabel("Rendering", current, total));
15168
+ setExportProgress(chunkR47PKWUJ_js.slideProgressPercent(current, total));
15169
+ setExportStatusMessage(chunkR47PKWUJ_js.slideStatusLabel("Rendering", current, total));
15170
15170
  },
15171
15171
  signal: abortCtrl.signal
15172
15172
  }
15173
15173
  );
15174
- setExportProgress(chunk7OK75CPY_js.EXPORT_ASSEMBLING_PERCENT);
15174
+ setExportProgress(chunkR47PKWUJ_js.EXPORT_ASSEMBLING_PERCENT);
15175
15175
  setExportStatusMessage("Building PDF...");
15176
15176
  await new Promise((r) => {
15177
15177
  setTimeout(r, 100);
15178
15178
  });
15179
- setExportProgress(chunk7OK75CPY_js.EXPORT_DONE_PERCENT);
15179
+ setExportProgress(chunkR47PKWUJ_js.EXPORT_DONE_PERCENT);
15180
15180
  setExportStatusMessage("Done!");
15181
15181
  } catch (err) {
15182
- if (!chunk7OK75CPY_js.isExportAbortError(err)) {
15182
+ if (!chunkR47PKWUJ_js.isExportAbortError(err)) {
15183
15183
  console.error("[PowerPointViewer] PDF export failed:", err);
15184
15184
  }
15185
15185
  } finally {
@@ -15209,21 +15209,21 @@ function useExportHandlers(input) {
15209
15209
  {
15210
15210
  scale: 2,
15211
15211
  onProgress: (current, total) => {
15212
- setExportProgress(chunk7OK75CPY_js.slideProgressPercent(current, total));
15213
- setExportStatusMessage(chunk7OK75CPY_js.slideStatusLabel("Rendering", current, total));
15212
+ setExportProgress(chunkR47PKWUJ_js.slideProgressPercent(current, total));
15213
+ setExportStatusMessage(chunkR47PKWUJ_js.slideStatusLabel("Rendering", current, total));
15214
15214
  },
15215
15215
  signal: abortCtrl.signal
15216
15216
  }
15217
15217
  );
15218
- setExportProgress(chunk7OK75CPY_js.EXPORT_ASSEMBLING_PERCENT);
15218
+ setExportProgress(chunkR47PKWUJ_js.EXPORT_ASSEMBLING_PERCENT);
15219
15219
  setExportStatusMessage("Building PDF...");
15220
15220
  await new Promise((r) => {
15221
15221
  setTimeout(r, 100);
15222
15222
  });
15223
- setExportProgress(chunk7OK75CPY_js.EXPORT_DONE_PERCENT);
15223
+ setExportProgress(chunkR47PKWUJ_js.EXPORT_DONE_PERCENT);
15224
15224
  setExportStatusMessage("Done!");
15225
15225
  } catch (err) {
15226
- if (!chunk7OK75CPY_js.isExportAbortError(err)) {
15226
+ if (!chunkR47PKWUJ_js.isExportAbortError(err)) {
15227
15227
  console.error("[PowerPointViewer] Notes PDF export failed:", err);
15228
15228
  }
15229
15229
  } finally {
@@ -15264,22 +15264,22 @@ function useExportHandlers(input) {
15264
15264
  scale: 1,
15265
15265
  slideDurationMs: 3e3,
15266
15266
  onProgress: (current, total) => {
15267
- setExportProgress(chunk7OK75CPY_js.slideProgressPercent(current, total, 45));
15268
- setExportStatusMessage(chunk7OK75CPY_js.slideStatusLabel("Capturing", current, total));
15267
+ setExportProgress(chunkR47PKWUJ_js.slideProgressPercent(current, total, 45));
15268
+ setExportStatusMessage(chunkR47PKWUJ_js.slideStatusLabel("Capturing", current, total));
15269
15269
  },
15270
15270
  onRecordProgress: (current, total) => {
15271
- setExportProgress(chunk7OK75CPY_js.recordProgressPercent(current, total));
15272
- setExportStatusMessage(chunk7OK75CPY_js.slideStatusLabel("Recording", current, total));
15271
+ setExportProgress(chunkR47PKWUJ_js.recordProgressPercent(current, total));
15272
+ setExportStatusMessage(chunkR47PKWUJ_js.slideStatusLabel("Recording", current, total));
15273
15273
  },
15274
15274
  signal: abortCtrl.signal
15275
15275
  }
15276
15276
  );
15277
- setExportProgress(chunk7OK75CPY_js.EXPORT_ASSEMBLING_PERCENT);
15277
+ setExportProgress(chunkR47PKWUJ_js.EXPORT_ASSEMBLING_PERCENT);
15278
15278
  setExportStatusMessage("Saving file...");
15279
15279
  downloadBlob2(blob, "presentation.webm");
15280
- setExportProgress(chunk7OK75CPY_js.EXPORT_DONE_PERCENT);
15280
+ setExportProgress(chunkR47PKWUJ_js.EXPORT_DONE_PERCENT);
15281
15281
  } catch (err) {
15282
- if (!chunk7OK75CPY_js.isExportAbortError(err)) {
15282
+ if (!chunkR47PKWUJ_js.isExportAbortError(err)) {
15283
15283
  console.error("[PowerPointViewer] Video export failed:", err);
15284
15284
  }
15285
15285
  } finally {
@@ -15307,18 +15307,18 @@ function useExportHandlers(input) {
15307
15307
  scale: 0.5,
15308
15308
  slideDurationMs: 2e3,
15309
15309
  onProgress: (current, total) => {
15310
- setExportProgress(chunk7OK75CPY_js.slideProgressPercent(current, total));
15311
- setExportStatusMessage(chunk7OK75CPY_js.slideStatusLabel("Encoding", current, total));
15310
+ setExportProgress(chunkR47PKWUJ_js.slideProgressPercent(current, total));
15311
+ setExportStatusMessage(chunkR47PKWUJ_js.slideStatusLabel("Encoding", current, total));
15312
15312
  },
15313
15313
  signal: abortCtrl.signal
15314
15314
  }
15315
15315
  );
15316
- setExportProgress(chunk7OK75CPY_js.EXPORT_ASSEMBLING_PERCENT);
15316
+ setExportProgress(chunkR47PKWUJ_js.EXPORT_ASSEMBLING_PERCENT);
15317
15317
  setExportStatusMessage("Saving file...");
15318
15318
  downloadBlob2(blob, "presentation.gif");
15319
- setExportProgress(chunk7OK75CPY_js.EXPORT_DONE_PERCENT);
15319
+ setExportProgress(chunkR47PKWUJ_js.EXPORT_DONE_PERCENT);
15320
15320
  } catch (err) {
15321
- if (!chunk7OK75CPY_js.isExportAbortError(err)) {
15321
+ if (!chunkR47PKWUJ_js.isExportAbortError(err)) {
15322
15322
  console.error("[PowerPointViewer] GIF export failed:", err);
15323
15323
  }
15324
15324
  } finally {
@@ -15358,7 +15358,7 @@ function openPrintWindow(title, bodyHtml, orientation, colorFilter, frameSlides)
15358
15358
  }
15359
15359
  printWindow.document.open();
15360
15360
  printWindow.document.write(
15361
- chunk7OK75CPY_js.buildPrintHtmlDocument({ title, bodyHtml, orientation, colorFilter, frameSlides })
15361
+ chunkR47PKWUJ_js.buildPrintHtmlDocument({ title, bodyHtml, orientation, colorFilter, frameSlides })
15362
15362
  );
15363
15363
  printWindow.document.close();
15364
15364
  printWindow.focus();
@@ -15419,7 +15419,7 @@ function usePrintHandlers(input) {
15419
15419
  if (svgs.length === 0) {
15420
15420
  return;
15421
15421
  }
15422
- const printDoc = chunk7OK75CPY_js.buildPrintDocument(svgs, pptxData.width, pptxData.height, {
15422
+ const printDoc = chunkR47PKWUJ_js.buildPrintDocument(svgs, pptxData.width, pptxData.height, {
15423
15423
  title: "Slides (Vector)",
15424
15424
  orientation: settings.orientation,
15425
15425
  colorFilter
@@ -15455,7 +15455,7 @@ function usePrintHandlers(input) {
15455
15455
  if (settings.printWhat === "outline") {
15456
15456
  openPrintWindow(
15457
15457
  "Outline",
15458
- `<div class="outline-page">${chunk7OK75CPY_js.buildOutlineHtml(slideIndices, slides)}</div>`,
15458
+ `<div class="outline-page">${chunkR47PKWUJ_js.buildOutlineHtml(slideIndices, slides)}</div>`,
15459
15459
  settings.orientation,
15460
15460
  colorFilter,
15461
15461
  settings.frameSlides
@@ -15480,7 +15480,7 @@ function usePrintHandlers(input) {
15480
15480
  if (settings.printWhat === "slides") {
15481
15481
  openPrintWindow(
15482
15482
  "Slides",
15483
- chunk7OK75CPY_js.buildSlidesHtml(slideImages, slideIndices),
15483
+ chunkR47PKWUJ_js.buildSlidesHtml(slideImages, slideIndices),
15484
15484
  settings.orientation,
15485
15485
  colorFilter,
15486
15486
  settings.frameSlides
@@ -15490,7 +15490,7 @@ function usePrintHandlers(input) {
15490
15490
  if (settings.printWhat === "notes") {
15491
15491
  openPrintWindow(
15492
15492
  "Notes Pages",
15493
- chunk7OK75CPY_js.buildNotesHtml(slideImages, slideIndices, slides),
15493
+ chunkR47PKWUJ_js.buildNotesHtml(slideImages, slideIndices, slides),
15494
15494
  "portrait",
15495
15495
  colorFilter,
15496
15496
  settings.frameSlides
@@ -15501,7 +15501,7 @@ function usePrintHandlers(input) {
15501
15501
  const spp = settings.slidesPerPage;
15502
15502
  openPrintWindow(
15503
15503
  `Handout ${spp} per page`,
15504
- chunk7OK75CPY_js.buildHandoutsHtml(slideImages, slideIndices, spp),
15504
+ chunkR47PKWUJ_js.buildHandoutsHtml(slideImages, slideIndices, spp),
15505
15505
  "portrait",
15506
15506
  colorFilter,
15507
15507
  settings.frameSlides
@@ -15565,8 +15565,8 @@ function useThemeHandlers(input) {
15565
15565
  return;
15566
15566
  }
15567
15567
  await handler.updateThemeColorScheme(colorScheme);
15568
- const previousMap = theme?.colorScheme ? chunkZWG6IN7E_js.buildThemeColorMap(theme.colorScheme) : {};
15569
- setSlides((prev) => chunkZWG6IN7E_js.reResolveSlideColors(prev, previousMap, colorScheme));
15568
+ const previousMap = theme?.colorScheme ? chunkRVKY3KGH_js.buildThemeColorMap(theme.colorScheme) : {};
15569
+ setSlides((prev) => chunkRVKY3KGH_js.reResolveSlideColors(prev, previousMap, colorScheme));
15570
15570
  setTheme((prev) => prev ? { ...prev, colorScheme } : { colorScheme });
15571
15571
  bumpHistory();
15572
15572
  history.markDirty();
@@ -15671,7 +15671,7 @@ function useThemeSwitching(input) {
15671
15671
  }
15672
15672
  try {
15673
15673
  await handler.applyTheme(preset.colorScheme, preset.fontScheme, preset.name);
15674
- const newData = chunkZWG6IN7E_js.applyThemeToData(data, preset.colorScheme, preset.fontScheme, preset.name);
15674
+ const newData = chunkRVKY3KGH_js.applyThemeToData(data, preset.colorScheme, preset.fontScheme, preset.name);
15675
15675
  onDataChange(newData);
15676
15676
  onThemeChanged?.(preset);
15677
15677
  } catch (error) {
@@ -15688,7 +15688,7 @@ function useThemeSwitching(input) {
15688
15688
  }
15689
15689
  try {
15690
15690
  await handler.applyTheme(colorScheme, fontScheme ?? {}, themeName);
15691
- const newData = chunkZWG6IN7E_js.applyThemeToData(data, colorScheme, fontScheme, themeName);
15691
+ const newData = chunkRVKY3KGH_js.applyThemeToData(data, colorScheme, fontScheme, themeName);
15692
15692
  onDataChange(newData);
15693
15693
  } catch (error) {
15694
15694
  console.error("Failed to switch to custom theme:", error);
@@ -15700,12 +15700,12 @@ function useThemeSwitching(input) {
15700
15700
  if (!data?.theme?.colorScheme) {
15701
15701
  return void 0;
15702
15702
  }
15703
- return chunkZWG6IN7E_js.THEME_PRESETS.find(
15704
- (p) => chunkZWG6IN7E_js.themeColorSchemesEqual(data.theme?.colorScheme, p.colorScheme)
15703
+ return chunkRVKY3KGH_js.THEME_PRESETS.find(
15704
+ (p) => chunkRVKY3KGH_js.themeColorSchemesEqual(data.theme?.colorScheme, p.colorScheme)
15705
15705
  );
15706
15706
  }, [data?.theme?.colorScheme]);
15707
15707
  return {
15708
- presets: chunkZWG6IN7E_js.THEME_PRESETS,
15708
+ presets: chunkRVKY3KGH_js.THEME_PRESETS,
15709
15709
  switchToPreset,
15710
15710
  switchToCustom,
15711
15711
  currentPreset
@@ -15780,7 +15780,7 @@ function usePropertyHandlers(input) {
15780
15780
  }
15781
15781
  try {
15782
15782
  const ab = await file.arrayBuffer();
15783
- const h = new chunkZWG6IN7E_js.PptxHandler();
15783
+ const h = new chunkRVKY3KGH_js.PptxHandler();
15784
15784
  const other = await h.load(ab);
15785
15785
  if (!other) {
15786
15786
  return;
@@ -15790,7 +15790,7 @@ function usePropertyHandlers(input) {
15790
15790
  width: canvasSize.width,
15791
15791
  height: canvasSize.height
15792
15792
  };
15793
- setCompareResult(chunk7OK75CPY_js.comparePresentation(cur, other));
15793
+ setCompareResult(chunkR47PKWUJ_js.comparePresentation(cur, other));
15794
15794
  setIsComparePanelOpen(true);
15795
15795
  } catch (err) {
15796
15796
  console.warn("Compare failed:", err);
@@ -15807,7 +15807,7 @@ function usePropertyHandlers(input) {
15807
15807
  if (!diff || diff.status === "unchanged") {
15808
15808
  return;
15809
15809
  }
15810
- setSlides((prev) => chunk7OK75CPY_js.applyAcceptSlide(prev, diff));
15810
+ setSlides((prev) => chunkR47PKWUJ_js.applyAcceptSlide(prev, diff));
15811
15811
  setIsDirty(true);
15812
15812
  },
15813
15813
  [compareResult, setSlides, setIsDirty]
@@ -15818,10 +15818,10 @@ function usePropertyHandlers(input) {
15818
15818
  if (!compareResult) {
15819
15819
  return;
15820
15820
  }
15821
- setSlides((prev) => chunk7OK75CPY_js.applyAcceptAllSlides(prev, compareResult));
15821
+ setSlides((prev) => chunkR47PKWUJ_js.applyAcceptAllSlides(prev, compareResult));
15822
15822
  setIsDirty(true);
15823
15823
  }, [compareResult, setSlides, setIsDirty]);
15824
- const usedFontFamilies = React4.useMemo(() => chunk7OK75CPY_js.collectUsedFonts(slides), [slides]);
15824
+ const usedFontFamilies = React4.useMemo(() => chunkR47PKWUJ_js.collectUsedFonts(slides), [slides]);
15825
15825
  return {
15826
15826
  handleUpdateNotes,
15827
15827
  handleUpdateSlide,
@@ -15940,7 +15940,7 @@ function useIsMobile(input) {
15940
15940
  const containerRef = input?.containerRef;
15941
15941
  const isTouchDevice = React4.useSyncExternalStore(
15942
15942
  subscribeTouchCapability,
15943
- chunk7OK75CPY_js.detectTouchDevice,
15943
+ chunkR47PKWUJ_js.detectTouchDevice,
15944
15944
  () => false
15945
15945
  // server snapshot
15946
15946
  );
@@ -15956,7 +15956,7 @@ function useIsMobile(input) {
15956
15956
  }
15957
15957
  return containerRef?.current?.clientHeight ?? window.innerHeight;
15958
15958
  });
15959
- const [orientation, setOrientation] = React4.useState(chunk7OK75CPY_js.detectOrientation);
15959
+ const [orientation, setOrientation] = React4.useState(chunkR47PKWUJ_js.detectOrientation);
15960
15960
  const [isVirtualKeyboardOpen, setIsVirtualKeyboardOpen] = React4.useState(false);
15961
15961
  const [initialViewportHeight] = React4.useState(
15962
15962
  () => typeof window !== "undefined" ? window.innerHeight : 800
@@ -16000,7 +16000,7 @@ function useIsMobile(input) {
16000
16000
  return;
16001
16001
  }
16002
16002
  const handleOrientationChange = () => {
16003
- setOrientation(chunk7OK75CPY_js.detectOrientation());
16003
+ setOrientation(chunkR47PKWUJ_js.detectOrientation());
16004
16004
  };
16005
16005
  if (screen.orientation) {
16006
16006
  screen.orientation.addEventListener("change", handleOrientationChange);
@@ -16030,9 +16030,9 @@ function useIsMobile(input) {
16030
16030
  window.addEventListener("resize", handleResize);
16031
16031
  return () => window.removeEventListener("resize", handleResize);
16032
16032
  }, [isTouchDevice, initialViewportHeight]);
16033
- const isMobile = chunk7OK75CPY_js.isMobileViewport(containerWidth, containerHeight, isTouchDevice);
16034
- const isTablet = !isMobile && containerWidth >= chunk7OK75CPY_js.MOBILE_BREAKPOINT && containerWidth < chunk7OK75CPY_js.TABLET_BREAKPOINT;
16035
- const isDesktop = !isMobile && containerWidth >= chunk7OK75CPY_js.TABLET_BREAKPOINT;
16033
+ const isMobile = chunkR47PKWUJ_js.isMobileViewport(containerWidth, containerHeight, isTouchDevice);
16034
+ const isTablet = !isMobile && containerWidth >= chunkR47PKWUJ_js.MOBILE_BREAKPOINT && containerWidth < chunkR47PKWUJ_js.TABLET_BREAKPOINT;
16035
+ const isDesktop = !isMobile && containerWidth >= chunkR47PKWUJ_js.TABLET_BREAKPOINT;
16036
16036
  return {
16037
16037
  isMobile,
16038
16038
  isTablet,
@@ -16093,11 +16093,11 @@ function useViewerDialogs(input) {
16093
16093
  );
16094
16094
  const [embedFontsEnabled, setEmbedFontsEnabled] = React4.useState(false);
16095
16095
  const [isNarrowViewport, setIsNarrowViewport] = React4.useState(
16096
- () => typeof window !== "undefined" ? chunk7OK75CPY_js.isMobileViewport(window.innerWidth, window.innerHeight, viewportIsTouch()) : false
16096
+ () => typeof window !== "undefined" ? chunkR47PKWUJ_js.isMobileViewport(window.innerWidth, window.innerHeight, viewportIsTouch()) : false
16097
16097
  );
16098
16098
  React4.useEffect(() => {
16099
16099
  const handleWindow = () => setIsNarrowViewport(
16100
- chunk7OK75CPY_js.isMobileViewport(window.innerWidth, window.innerHeight, viewportIsTouch())
16100
+ chunkR47PKWUJ_js.isMobileViewport(window.innerWidth, window.innerHeight, viewportIsTouch())
16101
16101
  );
16102
16102
  let observer = null;
16103
16103
  let raf = 0;
@@ -16111,12 +16111,12 @@ function useViewerDialogs(input) {
16111
16111
  const entry = entries[0];
16112
16112
  if (entry) {
16113
16113
  setIsNarrowViewport(
16114
- chunk7OK75CPY_js.isMobileViewport(entry.contentRect.width, entry.contentRect.height, viewportIsTouch())
16114
+ chunkR47PKWUJ_js.isMobileViewport(entry.contentRect.width, entry.contentRect.height, viewportIsTouch())
16115
16115
  );
16116
16116
  }
16117
16117
  });
16118
16118
  observer.observe(el);
16119
- setIsNarrowViewport(chunk7OK75CPY_js.isMobileViewport(el.clientWidth, el.clientHeight, viewportIsTouch()));
16119
+ setIsNarrowViewport(chunkR47PKWUJ_js.isMobileViewport(el.clientWidth, el.clientHeight, viewportIsTouch()));
16120
16120
  };
16121
16121
  attach();
16122
16122
  window.addEventListener("resize", handleWindow);
@@ -16293,7 +16293,7 @@ function computeVisibleSlideIndexes(slides, activeCustomShowId, customShows) {
16293
16293
  return slides.map((_, i) => i).filter((i) => !slides[i]?.hidden);
16294
16294
  }
16295
16295
  function computeSlideSectionGroups(slides, sections) {
16296
- return chunk7OK75CPY_js.groupSlidesBySection(sections, slides).map((group) => ({
16296
+ return chunkR47PKWUJ_js.groupSlidesBySection(sections, slides).map((group) => ({
16297
16297
  id: group.section?.id ?? (sections.length > 0 ? UNGROUPED_SECTION_ID : "default"),
16298
16298
  label: group.section?.name ?? (sections.length > 0 ? "Ungrouped Slides" : "Slides"),
16299
16299
  slideIndexes: group.slideIndexes,
@@ -16531,13 +16531,13 @@ function useSerialize(input) {
16531
16531
  let processedSlide = slide;
16532
16532
  if (pendingEditId) {
16533
16533
  const updatedElements = slide.elements.map((el) => {
16534
- if (el.id !== pendingEditId || !chunkZWG6IN7E_js.hasTextProperties(el)) {
16534
+ if (el.id !== pendingEditId || !chunkRVKY3KGH_js.hasTextProperties(el)) {
16535
16535
  return el;
16536
16536
  }
16537
16537
  return {
16538
16538
  ...el,
16539
16539
  text: pendingEditText,
16540
- textSegments: chunk7OK75CPY_js.remapTextToSegments(pendingEditText, el.textSegments, el.textStyle)
16540
+ textSegments: chunkR47PKWUJ_js.remapTextToSegments(pendingEditText, el.textSegments, el.textStyle)
16541
16541
  };
16542
16542
  });
16543
16543
  if (updatedElements.some((el, i) => el !== slide.elements[i])) {
@@ -16550,7 +16550,7 @@ function useSerialize(input) {
16550
16550
  const pptxGuides = guides.map((g) => ({
16551
16551
  id: g.id,
16552
16552
  orientation: g.axis === "h" ? "horz" : "vert",
16553
- positionEmu: chunkZWG6IN7E_js.guidePxToEmu(g.position)
16553
+ positionEmu: chunkRVKY3KGH_js.guidePxToEmu(g.position)
16554
16554
  }));
16555
16555
  return {
16556
16556
  ...processedSlide,
@@ -16786,10 +16786,10 @@ function usePresentationSetup(input) {
16786
16786
  onToggleEraser: () => annotations.setPresentationTool("eraser"),
16787
16787
  onToggleToolbar: () => annotations.setToolbarVisible(!annotations.toolbarVisible),
16788
16788
  onSaveRehearsalTimings: (timings) => {
16789
- setSlides((prev) => chunk7OK75CPY_js.applyRehearsalTimings(prev, timings));
16789
+ setSlides((prev) => chunkR47PKWUJ_js.applyRehearsalTimings(prev, timings));
16790
16790
  history.markDirty();
16791
16791
  },
16792
- loopContinuously: chunk7OK75CPY_js.shouldLoopContinuously(presentationProperties),
16792
+ loopContinuously: chunkR47PKWUJ_js.shouldLoopContinuously(presentationProperties),
16793
16793
  showWithAnimation: presentationProperties.showWithAnimation,
16794
16794
  useTimings: presentationProperties.advanceMode !== "manual",
16795
16795
  endWithBlackSlide
@@ -16951,7 +16951,7 @@ function useEditorOperations(input) {
16951
16951
  const { formatPainterActive, setFormatPainterActive, elementLookup } = state;
16952
16952
  React4.useEffect(() => {
16953
16953
  if (formatPainterActive && !prevFormatPainterRef.current && selectedElement) {
16954
- copiedFormatRef.current = chunk7OK75CPY_js.copyFormatFromElement(selectedElement);
16954
+ copiedFormatRef.current = chunkR47PKWUJ_js.copyFormatFromElement(selectedElement);
16955
16955
  } else if (!formatPainterActive) {
16956
16956
  copiedFormatRef.current = null;
16957
16957
  }
@@ -16977,12 +16977,12 @@ function useEditorOperations(input) {
16977
16977
  e.stopPropagation();
16978
16978
  const element = elementLookup.get(elementId);
16979
16979
  if (element) {
16980
- const updated = chunk7OK75CPY_js.applyFormatToElement(element, copiedFormatRef.current);
16980
+ const updated = chunkR47PKWUJ_js.applyFormatToElement(element, copiedFormatRef.current);
16981
16981
  const updates = {};
16982
- if (chunkZWG6IN7E_js.hasShapeProperties(updated)) {
16982
+ if (chunkRVKY3KGH_js.hasShapeProperties(updated)) {
16983
16983
  updates.shapeStyle = updated.shapeStyle;
16984
16984
  }
16985
- if (chunkZWG6IN7E_js.hasTextProperties(updated)) {
16985
+ if (chunkRVKY3KGH_js.hasTextProperties(updated)) {
16986
16986
  updates.textStyle = updated.textStyle;
16987
16987
  }
16988
16988
  ops.updateElementById(elementId, updates);
@@ -17129,7 +17129,7 @@ function collectReferencedFontFamilies(slides) {
17129
17129
  const families = /* @__PURE__ */ new Set();
17130
17130
  for (const slide of slides) {
17131
17131
  for (const el of slide.elements) {
17132
- if (chunkZWG6IN7E_js.hasTextProperties(el) && el.textSegments) {
17132
+ if (chunkRVKY3KGH_js.hasTextProperties(el) && el.textSegments) {
17133
17133
  for (const seg of el.textSegments) {
17134
17134
  if (seg.style.fontFamily) {
17135
17135
  families.add(seg.style.fontFamily);
@@ -17913,7 +17913,7 @@ function useReducedMotion() {
17913
17913
  }
17914
17914
  function useViewerOptions() {
17915
17915
  const storeRef = React4.useRef(null);
17916
- storeRef.current ??= chunk7OK75CPY_js.createViewerOptionsStore();
17916
+ storeRef.current ??= chunkR47PKWUJ_js.createViewerOptionsStore();
17917
17917
  const store = storeRef.current;
17918
17918
  const options = React4.useSyncExternalStore(
17919
17919
  (onStoreChange) => store.subscribe(onStoreChange),
@@ -17922,9 +17922,9 @@ function useViewerOptions() {
17922
17922
  );
17923
17923
  return { optionsStore: store, options };
17924
17924
  }
17925
- var KNOWN_TAB_IDS = new Set(chunk7OK75CPY_js.TOOLBAR_TABS.map((tab) => tab.id));
17925
+ var KNOWN_TAB_IDS = new Set(chunkR47PKWUJ_js.TOOLBAR_TABS.map((tab) => tab.id));
17926
17926
  function computeToolbarVisibility(hiddenActions) {
17927
- const isHidden = (id) => chunk7OK75CPY_js.isActionHidden(id, hiddenActions);
17927
+ const isHidden = (id) => chunkR47PKWUJ_js.isActionHidden(id, hiddenActions);
17928
17928
  const isTabVisible = (id) => !KNOWN_TAB_IDS.has(id) || !isHidden(id);
17929
17929
  return { isHidden, isTabVisible };
17930
17930
  }
@@ -18009,10 +18009,10 @@ function useYjsDocumentSync({
18009
18009
  return;
18010
18010
  }
18011
18011
  try {
18012
- const { PptxHandler: PptxHandler2 } = await import('./dist-QBE2HCT7.js');
18012
+ const { PptxHandler: PptxHandler2 } = await import('./dist-PSZVXCOM.js');
18013
18013
  const handler = new PptxHandler2();
18014
18014
  await handler.load(sourceBytes.buffer);
18015
- const currentSlides = chunk7OK75CPY_js.readSlidesFromYDoc(
18015
+ const currentSlides = chunkR47PKWUJ_js.readSlidesFromYDoc(
18016
18016
  doc
18017
18017
  );
18018
18018
  const slidesToSave = buildSaveSlides(currentSlides, templateElementsBySlideId);
@@ -18030,7 +18030,7 @@ function useYjsDocumentSync({
18030
18030
  if (!doc || !isConnected) {
18031
18031
  return;
18032
18032
  }
18033
- const docSlides = chunk7OK75CPY_js.readSlidesFromYDoc(
18033
+ const docSlides = chunkR47PKWUJ_js.readSlidesFromYDoc(
18034
18034
  doc
18035
18035
  );
18036
18036
  if (docSlides.length === 0) {
@@ -18052,11 +18052,11 @@ function useYjsDocumentSync({
18052
18052
  lastSyncedRef.current = serialized;
18053
18053
  void (async () => {
18054
18054
  const factories = await getFactories();
18055
- chunk7OK75CPY_js.reconcileSlidesInYDoc(
18055
+ chunkR47PKWUJ_js.reconcileSlidesInYDoc(
18056
18056
  slides,
18057
18057
  doc,
18058
18058
  factories,
18059
- chunk7OK75CPY_js.LOCAL_SYNC_ORIGIN
18059
+ chunkR47PKWUJ_js.LOCAL_SYNC_ORIGIN
18060
18060
  );
18061
18061
  scheduleWriteBack();
18062
18062
  })();
@@ -18070,10 +18070,10 @@ function useYjsDocumentSync({
18070
18070
  return;
18071
18071
  }
18072
18072
  const handleChange = (_events, transaction) => {
18073
- if (transaction?.origin === chunk7OK75CPY_js.LOCAL_SYNC_ORIGIN) {
18073
+ if (transaction?.origin === chunkR47PKWUJ_js.LOCAL_SYNC_ORIGIN) {
18074
18074
  return;
18075
18075
  }
18076
- const remoteSlides = chunk7OK75CPY_js.readSlidesFromYDoc(
18076
+ const remoteSlides = chunkR47PKWUJ_js.readSlidesFromYDoc(
18077
18077
  doc
18078
18078
  );
18079
18079
  if (remoteSlides.length === 0) {
@@ -18089,7 +18089,7 @@ function useYjsDocumentSync({
18089
18089
  isApplyingRemoteRef.current = false;
18090
18090
  scheduleWriteBack();
18091
18091
  };
18092
- const unobserve = chunk7OK75CPY_js.observeYDocSlides(
18092
+ const unobserve = chunkR47PKWUJ_js.observeYDocSlides(
18093
18093
  doc,
18094
18094
  handleChange
18095
18095
  );
@@ -18127,7 +18127,7 @@ function useBroadcastFollower({
18127
18127
  if (!broadcaster) {
18128
18128
  return;
18129
18129
  }
18130
- if (!chunk7OK75CPY_js.shouldAutoFollowBroadcaster({
18130
+ if (!chunkR47PKWUJ_js.shouldAutoFollowBroadcaster({
18131
18131
  localRole: collab.config.role,
18132
18132
  broadcasterRole: broadcaster.role
18133
18133
  })) {
@@ -18262,7 +18262,7 @@ function useTouchGestures(input) {
18262
18262
  if (!el || !enabled) {
18263
18263
  return;
18264
18264
  }
18265
- const recognizer = chunk7OK75CPY_js.createTouchGestureRecognizer({
18265
+ const recognizer = chunkR47PKWUJ_js.createTouchGestureRecognizer({
18266
18266
  getScale: () => scaleRef.current,
18267
18267
  minScale: MIN_ZOOM_SCALE,
18268
18268
  maxScale: MAX_ZOOM_SCALE,
@@ -18305,7 +18305,7 @@ function scrollFocusedIntoView(keyboardInset) {
18305
18305
  return;
18306
18306
  }
18307
18307
  const rect = active.getBoundingClientRect();
18308
- const delta = chunk7OK75CPY_js.computeScrollDelta(
18308
+ const delta = chunkR47PKWUJ_js.computeScrollDelta(
18309
18309
  { top: rect.top, bottom: rect.bottom },
18310
18310
  window.innerHeight,
18311
18311
  keyboardInset
@@ -18325,8 +18325,8 @@ function useKeyboardInsets(enabled = true) {
18325
18325
  return;
18326
18326
  }
18327
18327
  const update = () => {
18328
- const metrics = chunk7OK75CPY_js.readViewportMetrics(window);
18329
- const inset = metrics ? chunk7OK75CPY_js.computeKeyboardInset(metrics) : 0;
18328
+ const metrics = chunkR47PKWUJ_js.readViewportMetrics(window);
18329
+ const inset = metrics ? chunkR47PKWUJ_js.computeKeyboardInset(metrics) : 0;
18330
18330
  setKeyboardInset(inset);
18331
18331
  if (inset > 0) {
18332
18332
  window.requestAnimationFrame(() => scrollFocusedIntoView(inset));
@@ -18337,8 +18337,8 @@ function useKeyboardInsets(enabled = true) {
18337
18337
  vv.addEventListener("scroll", update);
18338
18338
  const onFocusIn = () => {
18339
18339
  window.requestAnimationFrame(() => {
18340
- const metrics = chunk7OK75CPY_js.readViewportMetrics(window);
18341
- const inset = metrics ? chunk7OK75CPY_js.computeKeyboardInset(metrics) : 0;
18340
+ const metrics = chunkR47PKWUJ_js.readViewportMetrics(window);
18341
+ const inset = metrics ? chunkR47PKWUJ_js.computeKeyboardInset(metrics) : 0;
18342
18342
  if (inset > 0) {
18343
18343
  scrollFocusedIntoView(inset);
18344
18344
  }
@@ -18351,7 +18351,7 @@ function useKeyboardInsets(enabled = true) {
18351
18351
  document.removeEventListener("focusin", onFocusIn);
18352
18352
  };
18353
18353
  }, [enabled]);
18354
- return { keyboardInset, isKeyboardOpen: chunk7OK75CPY_js.isKeyboardOpen(keyboardInset) };
18354
+ return { keyboardInset, isKeyboardOpen: chunkR47PKWUJ_js.isKeyboardOpen(keyboardInset) };
18355
18355
  }
18356
18356
 
18357
18357
  // src/viewer/hooks/useViewerBuildingBlocks-canvas-props.ts
@@ -18406,13 +18406,13 @@ function buildCanvasProps(input) {
18406
18406
  if (mode === "present") {
18407
18407
  presentation.handlePresentationAction(action);
18408
18408
  } else if (action.url) {
18409
- chunk7OK75CPY_js.safeOpenUrl(action.url);
18409
+ chunkR47PKWUJ_js.safeOpenUrl(action.url);
18410
18410
  }
18411
18411
  };
18412
18412
  const handleHyperlinkClick = (url) => {
18413
- if (chunk7OK75CPY_js.isPpactionUrl(url)) {
18413
+ if (chunkR47PKWUJ_js.isPpactionUrl(url)) {
18414
18414
  if (mode === "present") {
18415
- const parsed = chunk7OK75CPY_js.parsePpactionUrl(url);
18415
+ const parsed = chunkR47PKWUJ_js.parsePpactionUrl(url);
18416
18416
  if (parsed) {
18417
18417
  presentation.handlePresentationAction({
18418
18418
  action: parsed.action,
@@ -18422,7 +18422,7 @@ function buildCanvasProps(input) {
18422
18422
  }
18423
18423
  return;
18424
18424
  }
18425
- chunk7OK75CPY_js.safeOpenUrl(url);
18425
+ chunkR47PKWUJ_js.safeOpenUrl(url);
18426
18426
  };
18427
18427
  return {
18428
18428
  activeSlide: effectiveSlide,
@@ -18742,7 +18742,7 @@ function buildToolbarProps(input) {
18742
18742
  onOpenFile,
18743
18743
  onOpenRecentFile,
18744
18744
  onCreatePresentation: (templateId) => {
18745
- s.setSlides(chunk7OK75CPY_js.createBackstagePresentation(templateId));
18745
+ s.setSlides(chunkR47PKWUJ_js.createBackstagePresentation(templateId));
18746
18746
  s.setActiveSlideIndex(0);
18747
18747
  s.setSelectedElementId(null);
18748
18748
  s.setSelectedElementIds([]);
@@ -18803,7 +18803,7 @@ function buildToolbarProps(input) {
18803
18803
  isCommentsPanelOpen: s.isInspectorPaneOpen,
18804
18804
  slideCommentCount: activeSlide?.comments?.length ?? 0,
18805
18805
  formatPainterActive: s.formatPainterActive,
18806
- canActivateFormatPainter: chunk7OK75CPY_js.hasCopyableFormat(selectedElement),
18806
+ canActivateFormatPainter: chunkR47PKWUJ_js.hasCopyableFormat(selectedElement),
18807
18807
  onToggleFormatPainter: () => s.setFormatPainterActive((p) => !p),
18808
18808
  isSelectionPaneOpen: s.isSelectionPaneOpen,
18809
18809
  onToggleSelectionPane: () => s.setIsSelectionPaneOpen((p) => !p),
@@ -19066,7 +19066,7 @@ function useViewerBuildingBlocks(input) {
19066
19066
  }, [incomingContent]);
19067
19067
  const onOpenFile = React4.useCallback(() => {
19068
19068
  void (async () => {
19069
- const picked = await chunk7OK75CPY_js.openPptxFile();
19069
+ const picked = await chunkR47PKWUJ_js.openPptxFile();
19070
19070
  if (picked) {
19071
19071
  setContent(picked.buffer);
19072
19072
  }
@@ -19074,7 +19074,7 @@ function useViewerBuildingBlocks(input) {
19074
19074
  }, []);
19075
19075
  const onOpenRecentFile = React4.useCallback((key) => {
19076
19076
  void (async () => {
19077
- const bytes = await chunk7OK75CPY_js.readBackstageRecentFile(key);
19077
+ const bytes = await chunkR47PKWUJ_js.readBackstageRecentFile(key);
19078
19078
  if (bytes) {
19079
19079
  setContent(bytes);
19080
19080
  }