pptx-react-viewer 2.16.2 → 2.16.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +14 -0
- package/dist/{AiChatPanel-WJXPCHQK.mjs → AiChatPanel-7DDN4QUA.mjs} +4 -4
- package/dist/AiChatPanel-7DDN4QUA.mjs.br +0 -0
- package/dist/AiChatPanel-7DDN4QUA.mjs.gz +0 -0
- package/dist/{AiChatPanel-MCGNCS7Q.js → AiChatPanel-KEORKCTT.js} +23 -23
- package/dist/AiChatPanel-KEORKCTT.js.br +0 -0
- package/dist/AiChatPanel-KEORKCTT.js.gz +0 -0
- package/dist/{Model3DScene-IXW2AKAU.mjs → Model3DScene-DEAQMMUS.mjs} +1 -1
- package/dist/{Model3DScene-IXW2AKAU.mjs.br → Model3DScene-DEAQMMUS.mjs.br} +0 -0
- package/dist/Model3DScene-DEAQMMUS.mjs.gz +0 -0
- package/dist/{Model3DScene-Q2DTGVQ7.js → Model3DScene-SBUYEWHL.js} +2 -2
- package/dist/Model3DScene-SBUYEWHL.js.br +0 -0
- package/dist/Model3DScene-SBUYEWHL.js.gz +0 -0
- package/dist/{SurfaceChart3DScene-AD43LAOO.js → SurfaceChart3DScene-I5D54YQ3.js} +2 -2
- package/dist/SurfaceChart3DScene-I5D54YQ3.js.br +0 -0
- package/dist/SurfaceChart3DScene-I5D54YQ3.js.gz +0 -0
- package/dist/{SurfaceChart3DScene-MODEHQ6G.mjs → SurfaceChart3DScene-TXGS2PBK.mjs} +1 -1
- package/dist/{SurfaceChart3DScene-MODEHQ6G.mjs.br → SurfaceChart3DScene-TXGS2PBK.mjs.br} +0 -0
- package/dist/SurfaceChart3DScene-TXGS2PBK.mjs.gz +0 -0
- package/dist/{audience-content-store-DaABTAcQ.d.ts → audience-content-store-BvqKy7Hf.d.ts} +2 -2
- package/dist/{audience-content-store-DaABTAcQ.d.ts.map → audience-content-store-BvqKy7Hf.d.ts.map} +1 -1
- package/dist/{chunk-MDFCBYEM.mjs → chunk-23WSCMWN.mjs} +133 -68
- package/dist/chunk-23WSCMWN.mjs.br +0 -0
- package/dist/chunk-23WSCMWN.mjs.gz +0 -0
- package/dist/{chunk-5YV26HMJ.mjs → chunk-5IUEPQTK.mjs} +1 -0
- package/dist/chunk-5IUEPQTK.mjs.br +0 -0
- package/dist/chunk-5IUEPQTK.mjs.gz +0 -0
- package/dist/{chunk-3ISYPBSX.js → chunk-DVZF4ARG.js} +1 -0
- package/dist/chunk-DVZF4ARG.js.br +0 -0
- package/dist/chunk-DVZF4ARG.js.gz +0 -0
- package/dist/{chunk-OYF6ISXZ.mjs → chunk-DWIIYEOG.mjs} +4 -4
- package/dist/chunk-DWIIYEOG.mjs.br +0 -0
- package/dist/{chunk-OYF6ISXZ.mjs.gz → chunk-DWIIYEOG.mjs.gz} +0 -0
- package/dist/{chunk-JV6DI7AK.js → chunk-FQ3FTNKV.js} +1062 -1062
- package/dist/chunk-FQ3FTNKV.js.br +0 -0
- package/dist/chunk-FQ3FTNKV.js.gz +0 -0
- package/dist/{chunk-3OYWYONZ.mjs → chunk-FXGO5KLU.mjs} +3 -3
- package/dist/chunk-FXGO5KLU.mjs.br +0 -0
- package/dist/chunk-FXGO5KLU.mjs.gz +0 -0
- package/dist/{chunk-LDD2UVCV.mjs → chunk-GSAOP4Z4.mjs} +10 -10
- package/dist/chunk-GSAOP4Z4.mjs.br +0 -0
- package/dist/chunk-GSAOP4Z4.mjs.gz +0 -0
- package/dist/{chunk-CIK6XUOH.js → chunk-GZ2V3PWN.js} +3 -3
- package/dist/chunk-GZ2V3PWN.js.br +0 -0
- package/dist/chunk-GZ2V3PWN.js.gz +0 -0
- package/dist/{chunk-P6KM7RO5.js → chunk-HAQDKQ52.js} +266 -266
- package/dist/chunk-HAQDKQ52.js.br +0 -0
- package/dist/chunk-HAQDKQ52.js.gz +0 -0
- package/dist/{chunk-QI2JCXTH.mjs → chunk-J4QZVO3S.mjs} +1 -1
- package/dist/chunk-J4QZVO3S.mjs.br +0 -0
- package/dist/chunk-J4QZVO3S.mjs.gz +0 -0
- package/dist/{chunk-UWYHBCLM.mjs → chunk-LLTUDPRE.mjs} +18 -8
- package/dist/chunk-LLTUDPRE.mjs.br +0 -0
- package/dist/chunk-LLTUDPRE.mjs.gz +0 -0
- package/dist/{chunk-4GX347MG.js → chunk-MZ47MV52.js} +133 -68
- package/dist/chunk-MZ47MV52.js.br +0 -0
- package/dist/chunk-MZ47MV52.js.gz +0 -0
- package/dist/{chunk-PYV6FIYK.js → chunk-NB7M4XBG.js} +38 -38
- package/dist/chunk-NB7M4XBG.js.br +0 -0
- package/dist/chunk-NB7M4XBG.js.gz +0 -0
- package/dist/{chunk-Z4CS2ZYN.mjs → chunk-PLBS7OL2.mjs} +3 -3
- package/dist/chunk-PLBS7OL2.mjs.br +0 -0
- package/dist/chunk-PLBS7OL2.mjs.gz +0 -0
- package/dist/{chunk-NKE64XVV.js → chunk-RBQUSVYR.js} +361 -351
- package/dist/chunk-RBQUSVYR.js.br +0 -0
- package/dist/chunk-RBQUSVYR.js.gz +0 -0
- package/dist/{chunk-MMFM7JRT.js → chunk-ZYQT7I5C.js} +4 -4
- package/dist/chunk-ZYQT7I5C.js.br +0 -0
- package/dist/chunk-ZYQT7I5C.js.gz +0 -0
- package/dist/i18n.js +4 -4
- package/dist/i18n.js.br +0 -0
- package/dist/i18n.js.gz +0 -0
- package/dist/i18n.mjs +1 -1
- package/dist/i18n.mjs.br +0 -0
- package/dist/i18n.mjs.gz +0 -0
- package/dist/index.js +41 -41
- package/dist/index.js.br +0 -0
- package/dist/index.js.gz +0 -0
- package/dist/index.mjs +6 -6
- package/dist/index.mjs.br +0 -0
- package/dist/index.mjs.gz +0 -0
- package/dist/internals.d.ts +30 -1
- package/dist/internals.d.ts.map +1 -1
- package/dist/internals.js +79 -79
- package/dist/internals.js.br +0 -0
- package/dist/internals.js.gz +0 -0
- package/dist/internals.mjs +4 -4
- package/dist/internals.mjs.br +0 -0
- package/dist/internals.mjs.gz +0 -0
- package/dist/viewer/index.d.ts +1 -1
- package/dist/viewer/index.js +27 -27
- package/dist/viewer/index.js.br +0 -0
- package/dist/viewer/index.js.gz +0 -0
- package/dist/viewer/index.mjs +6 -6
- package/dist/viewer/index.mjs.br +0 -0
- package/dist/viewer/index.mjs.gz +0 -0
- package/dist/{y-webrtc-DGVURJIF.mjs → y-webrtc-7DLWG3LJ.mjs} +5 -5
- package/dist/y-webrtc-7DLWG3LJ.mjs.br +0 -0
- package/dist/y-webrtc-7DLWG3LJ.mjs.gz +0 -0
- package/dist/{y-webrtc-YN53KW3J.js → y-webrtc-TAJBJIKH.js} +107 -107
- package/dist/y-webrtc-TAJBJIKH.js.br +0 -0
- package/dist/y-webrtc-TAJBJIKH.js.gz +0 -0
- package/dist/{y-websocket-P5LTAJ5T.mjs → y-websocket-DCTJ76B7.mjs} +4 -4
- package/dist/y-websocket-DCTJ76B7.mjs.br +0 -0
- package/dist/y-websocket-DCTJ76B7.mjs.gz +0 -0
- package/dist/{y-websocket-HZCIQLM6.js → y-websocket-DQLOWGV6.js} +81 -81
- package/dist/y-websocket-DQLOWGV6.js.br +0 -0
- package/dist/y-websocket-DQLOWGV6.js.gz +0 -0
- package/dist/{yjs-FKGX4QHS.mjs → yjs-4ED7E5CZ.mjs} +1 -1
- package/dist/yjs-4ED7E5CZ.mjs.br +0 -0
- package/dist/yjs-4ED7E5CZ.mjs.gz +0 -0
- package/dist/{yjs-HBLSEMHP.js → yjs-OWUA3UHD.js} +104 -104
- package/dist/yjs-OWUA3UHD.js.br +0 -0
- package/dist/yjs-OWUA3UHD.js.gz +0 -0
- package/package.json +7 -7
- package/dist/AiChatPanel-MCGNCS7Q.js.br +0 -0
- package/dist/AiChatPanel-MCGNCS7Q.js.gz +0 -0
- package/dist/AiChatPanel-WJXPCHQK.mjs.br +0 -0
- package/dist/AiChatPanel-WJXPCHQK.mjs.gz +0 -0
- package/dist/Model3DScene-IXW2AKAU.mjs.gz +0 -0
- package/dist/Model3DScene-Q2DTGVQ7.js.br +0 -0
- package/dist/Model3DScene-Q2DTGVQ7.js.gz +0 -0
- package/dist/SurfaceChart3DScene-AD43LAOO.js.br +0 -0
- package/dist/SurfaceChart3DScene-AD43LAOO.js.gz +0 -0
- package/dist/SurfaceChart3DScene-MODEHQ6G.mjs.gz +0 -0
- package/dist/chunk-3ISYPBSX.js.br +0 -0
- package/dist/chunk-3ISYPBSX.js.gz +0 -0
- package/dist/chunk-3OYWYONZ.mjs.br +0 -0
- package/dist/chunk-3OYWYONZ.mjs.gz +0 -0
- package/dist/chunk-4GX347MG.js.br +0 -0
- package/dist/chunk-4GX347MG.js.gz +0 -0
- package/dist/chunk-5YV26HMJ.mjs.br +0 -0
- package/dist/chunk-5YV26HMJ.mjs.gz +0 -0
- package/dist/chunk-CIK6XUOH.js.br +0 -0
- package/dist/chunk-CIK6XUOH.js.gz +0 -0
- package/dist/chunk-JV6DI7AK.js.br +0 -0
- package/dist/chunk-JV6DI7AK.js.gz +0 -0
- package/dist/chunk-LDD2UVCV.mjs.br +0 -0
- package/dist/chunk-LDD2UVCV.mjs.gz +0 -0
- package/dist/chunk-MDFCBYEM.mjs.br +0 -0
- package/dist/chunk-MDFCBYEM.mjs.gz +0 -0
- package/dist/chunk-MMFM7JRT.js.br +0 -0
- package/dist/chunk-MMFM7JRT.js.gz +0 -0
- package/dist/chunk-NKE64XVV.js.br +0 -0
- package/dist/chunk-NKE64XVV.js.gz +0 -0
- package/dist/chunk-OYF6ISXZ.mjs.br +0 -0
- package/dist/chunk-P6KM7RO5.js.br +0 -0
- package/dist/chunk-P6KM7RO5.js.gz +0 -0
- package/dist/chunk-PYV6FIYK.js.br +0 -0
- package/dist/chunk-PYV6FIYK.js.gz +0 -0
- package/dist/chunk-QI2JCXTH.mjs.br +0 -0
- package/dist/chunk-QI2JCXTH.mjs.gz +0 -0
- package/dist/chunk-UWYHBCLM.mjs.br +0 -0
- package/dist/chunk-UWYHBCLM.mjs.gz +0 -0
- package/dist/chunk-Z4CS2ZYN.mjs.br +0 -0
- package/dist/chunk-Z4CS2ZYN.mjs.gz +0 -0
- package/dist/y-webrtc-DGVURJIF.mjs.br +0 -0
- package/dist/y-webrtc-DGVURJIF.mjs.gz +0 -0
- package/dist/y-webrtc-YN53KW3J.js.br +0 -0
- package/dist/y-webrtc-YN53KW3J.js.gz +0 -0
- package/dist/y-websocket-HZCIQLM6.js.br +0 -0
- package/dist/y-websocket-HZCIQLM6.js.gz +0 -0
- package/dist/y-websocket-P5LTAJ5T.mjs.br +0 -0
- package/dist/y-websocket-P5LTAJ5T.mjs.gz +0 -0
- package/dist/yjs-FKGX4QHS.mjs.br +0 -0
- package/dist/yjs-FKGX4QHS.mjs.gz +0 -0
- package/dist/yjs-HBLSEMHP.js.br +0 -0
- package/dist/yjs-HBLSEMHP.js.gz +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
3
|
+
var chunkDVZF4ARG_js = require('./chunk-DVZF4ARG.js');
|
|
4
|
+
var chunkMZ47MV52_js = require('./chunk-MZ47MV52.js');
|
|
5
5
|
var clsx = require('clsx');
|
|
6
6
|
var tailwindMerge = require('tailwind-merge');
|
|
7
7
|
var React6 = require('react');
|
|
@@ -15,7 +15,7 @@ var React6__default = /*#__PURE__*/_interopDefault(React6);
|
|
|
15
15
|
|
|
16
16
|
// src/viewer/utils/animation-effects.ts
|
|
17
17
|
function getAnimationInitialStyle2(preset, nativeAnimation) {
|
|
18
|
-
return
|
|
18
|
+
return chunkMZ47MV52_js.getAnimationInitialStyle(preset, nativeAnimation);
|
|
19
19
|
}
|
|
20
20
|
function cn(...inputs) {
|
|
21
21
|
return tailwindMerge.twMerge(clsx.clsx(inputs));
|
|
@@ -23,7 +23,7 @@ function cn(...inputs) {
|
|
|
23
23
|
|
|
24
24
|
// src/viewer/utils/clone.ts
|
|
25
25
|
function cloneHistorySnapshot2(snapshot) {
|
|
26
|
-
return
|
|
26
|
+
return chunkMZ47MV52_js.cloneHistorySnapshot(snapshot);
|
|
27
27
|
}
|
|
28
28
|
|
|
29
29
|
// src/viewer/constants/scalar.ts
|
|
@@ -63,7 +63,7 @@ var TOOLBAR_SECTIONS = [
|
|
|
63
63
|
{ id: "view", labelKey: "pptx.ribbon.tab.view" },
|
|
64
64
|
{ id: "help", labelKey: "pptx.ribbon.tab.help" }
|
|
65
65
|
];
|
|
66
|
-
var SHORTCUT_REFERENCE_ITEMS =
|
|
66
|
+
var SHORTCUT_REFERENCE_ITEMS = chunkMZ47MV52_js.VIEWER_SHORTCUT_REFERENCE;
|
|
67
67
|
|
|
68
68
|
// src/viewer/constants/theme.ts
|
|
69
69
|
var THEME_COLOR_SWATCHES = [
|
|
@@ -107,7 +107,7 @@ var GLYPH_COMPONENTS = {
|
|
|
107
107
|
plus: lu.LuPlus,
|
|
108
108
|
triangle: lu.LuTriangle
|
|
109
109
|
};
|
|
110
|
-
var SHAPE_PRESETS =
|
|
110
|
+
var SHAPE_PRESETS = chunkMZ47MV52_js.SHAPE_PRESET_DEFS.map(
|
|
111
111
|
(def) => ({
|
|
112
112
|
type: def.type,
|
|
113
113
|
label: def.label,
|
|
@@ -266,7 +266,7 @@ function isConnectorOrLineElement(element) {
|
|
|
266
266
|
if (element.type === "connector") {
|
|
267
267
|
return true;
|
|
268
268
|
}
|
|
269
|
-
if (!
|
|
269
|
+
if (!chunkMZ47MV52_js.hasShapeProperties(element)) {
|
|
270
270
|
return false;
|
|
271
271
|
}
|
|
272
272
|
const st = getShapeType(element.shapeType);
|
|
@@ -277,12 +277,12 @@ function isConnectorOrLineElement(element) {
|
|
|
277
277
|
function partitionTemplateElements(slides) {
|
|
278
278
|
const templateElementsBySlideId = {};
|
|
279
279
|
const nextSlides = slides.map((slide) => {
|
|
280
|
-
const template = slide.elements.filter((el) =>
|
|
280
|
+
const template = slide.elements.filter((el) => chunkMZ47MV52_js.isTemplateElement(el));
|
|
281
281
|
if (template.length === 0) {
|
|
282
282
|
return slide;
|
|
283
283
|
}
|
|
284
284
|
templateElementsBySlideId[slide.id] = template;
|
|
285
|
-
return { ...slide, elements: slide.elements.filter((el) => !
|
|
285
|
+
return { ...slide, elements: slide.elements.filter((el) => !chunkMZ47MV52_js.isTemplateElement(el)) };
|
|
286
286
|
});
|
|
287
287
|
return { slides: nextSlides, templateElementsBySlideId };
|
|
288
288
|
}
|
|
@@ -298,7 +298,7 @@ function buildSaveSlides(slides, templateElementsBySlideId) {
|
|
|
298
298
|
|
|
299
299
|
// src/viewer/utils/image-style.ts
|
|
300
300
|
function getImageMaskStyle(element) {
|
|
301
|
-
if (!
|
|
301
|
+
if (!chunkMZ47MV52_js.hasShapeProperties(element)) {
|
|
302
302
|
return void 0;
|
|
303
303
|
}
|
|
304
304
|
const shapeType = element.shapeType;
|
|
@@ -307,7 +307,7 @@ function getImageMaskStyle(element) {
|
|
|
307
307
|
}
|
|
308
308
|
const normalized = shapeType.toLowerCase();
|
|
309
309
|
if (normalized === "roundrect" || normalized === "round1rect" || normalized === "round2samerect" || normalized === "round2diagrect" || normalized === "sniproundrect" || normalized === "snip1rect" || normalized === "snip2diagrect") {
|
|
310
|
-
const radiusPx =
|
|
310
|
+
const radiusPx = chunkMZ47MV52_js.getRoundRectRadiusPx2(element);
|
|
311
311
|
if (radiusPx <= 0.01) {
|
|
312
312
|
return void 0;
|
|
313
313
|
}
|
|
@@ -319,7 +319,7 @@ function getImageMaskStyle(element) {
|
|
|
319
319
|
if (normalized === "can" || normalized === "cylinder") {
|
|
320
320
|
return { borderRadius: "48% / 12%" };
|
|
321
321
|
}
|
|
322
|
-
const clipPath =
|
|
322
|
+
const clipPath = chunkMZ47MV52_js.getResolvedShapeClipPath(element);
|
|
323
323
|
if (!clipPath) {
|
|
324
324
|
return void 0;
|
|
325
325
|
}
|
|
@@ -328,7 +328,7 @@ function getImageMaskStyle(element) {
|
|
|
328
328
|
function getImageRenderStyle(element) {
|
|
329
329
|
return {
|
|
330
330
|
...getImageMaskStyle(element) || {},
|
|
331
|
-
...
|
|
331
|
+
...chunkMZ47MV52_js.getImageFitStyle(element)
|
|
332
332
|
};
|
|
333
333
|
}
|
|
334
334
|
var CROP_SHAPE_CLIP_PATHS = {
|
|
@@ -341,7 +341,7 @@ var CROP_SHAPE_CLIP_PATHS = {
|
|
|
341
341
|
star: "polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%)"
|
|
342
342
|
};
|
|
343
343
|
function getCropShapeClipPath(element) {
|
|
344
|
-
if (!
|
|
344
|
+
if (!chunkMZ47MV52_js.isImageLikeElement(element)) {
|
|
345
345
|
return void 0;
|
|
346
346
|
}
|
|
347
347
|
const shape = element.cropShape;
|
|
@@ -351,7 +351,7 @@ function getCropShapeClipPath(element) {
|
|
|
351
351
|
return CROP_SHAPE_CLIP_PATHS[shape];
|
|
352
352
|
}
|
|
353
353
|
function isImageTiled(element) {
|
|
354
|
-
if (!
|
|
354
|
+
if (!chunkMZ47MV52_js.isImageLikeElement(element)) {
|
|
355
355
|
return false;
|
|
356
356
|
}
|
|
357
357
|
return typeof element.tileScaleX === "number" || typeof element.tileScaleY === "number";
|
|
@@ -409,7 +409,7 @@ function buildMirrorTiledBackground(src, flip, scaleX, scaleY) {
|
|
|
409
409
|
};
|
|
410
410
|
}
|
|
411
411
|
function getImageTilingStyle(element) {
|
|
412
|
-
if (!
|
|
412
|
+
if (!chunkMZ47MV52_js.isImageLikeElement(element) || !isImageTiled(element)) {
|
|
413
413
|
return void 0;
|
|
414
414
|
}
|
|
415
415
|
const scaleX = typeof element.tileScaleX === "number" ? element.tileScaleX * 100 : 100;
|
|
@@ -629,9 +629,9 @@ function registerMediaElement(elementId, el) {
|
|
|
629
629
|
};
|
|
630
630
|
}
|
|
631
631
|
function executeMediaCommand(command, frameRoot) {
|
|
632
|
-
return
|
|
632
|
+
return chunkMZ47MV52_js.runMediaCommand(
|
|
633
633
|
command,
|
|
634
|
-
(targetId) => registry.get(targetId) ??
|
|
634
|
+
(targetId) => registry.get(targetId) ?? chunkMZ47MV52_js.findMediaElementByElementId(targetId, frameRoot?.())
|
|
635
635
|
);
|
|
636
636
|
}
|
|
637
637
|
function PresentationMediaController({
|
|
@@ -675,7 +675,7 @@ function PresentationMediaController({
|
|
|
675
675
|
loop: shouldLoop,
|
|
676
676
|
volume: playbackVolume,
|
|
677
677
|
playbackRate
|
|
678
|
-
} =
|
|
678
|
+
} = chunkMZ47MV52_js.mediaPlaybackAttributes({
|
|
679
679
|
loop: element.loop,
|
|
680
680
|
volume: element.volume,
|
|
681
681
|
playbackSpeed: element.playbackSpeed
|
|
@@ -811,7 +811,7 @@ function PresentationMediaController({
|
|
|
811
811
|
if (element.playAcrossSlides && element.mediaType === "audio") {
|
|
812
812
|
const dataUrl = element.mediaData ?? resolvedDataUrl;
|
|
813
813
|
if (dataUrl) {
|
|
814
|
-
|
|
814
|
+
chunkMZ47MV52_js.registerPersistentAudio(
|
|
815
815
|
element.id,
|
|
816
816
|
dataUrl,
|
|
817
817
|
element.mediaMimeType,
|
|
@@ -873,7 +873,7 @@ function PresentationMediaController({
|
|
|
873
873
|
] });
|
|
874
874
|
}
|
|
875
875
|
function label(key) {
|
|
876
|
-
return key === void 0 ? void 0 :
|
|
876
|
+
return key === void 0 ? void 0 : chunkDVZF4ARG_js.translationsEn[key];
|
|
877
877
|
}
|
|
878
878
|
function FallbackIcon({
|
|
879
879
|
paths,
|
|
@@ -909,17 +909,17 @@ function Badge({
|
|
|
909
909
|
"div",
|
|
910
910
|
{
|
|
911
911
|
className: `absolute inset-0 flex flex-col items-center justify-center ${isMissing ? "gap-1" : ""}`,
|
|
912
|
-
...{ [
|
|
912
|
+
...{ [chunkMZ47MV52_js.MEDIA_CHROME_ATTRIBUTE]: visual.badge },
|
|
913
913
|
children: [
|
|
914
914
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
915
915
|
FallbackIcon,
|
|
916
916
|
{
|
|
917
|
-
paths:
|
|
917
|
+
paths: chunkMZ47MV52_js.mediaFallbackIcon(visual, element.mediaType),
|
|
918
918
|
size: isMissing ? 32 : 48,
|
|
919
919
|
className: isMissing ? "text-white/60" : "text-white/80 drop-shadow-md"
|
|
920
920
|
}
|
|
921
921
|
),
|
|
922
|
-
isMissing && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] text-white/60", children: label(
|
|
922
|
+
isMissing && /* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] text-white/60", children: label(chunkMZ47MV52_js.mediaFallbackLabelKey(visual, element.mediaType)) })
|
|
923
923
|
]
|
|
924
924
|
}
|
|
925
925
|
);
|
|
@@ -936,17 +936,17 @@ function Placeholder({
|
|
|
936
936
|
"div",
|
|
937
937
|
{
|
|
938
938
|
className: `w-full h-full flex flex-col items-center justify-center gap-1 pointer-events-none rounded ${isMissing ? "bg-black/30 border border-dashed border-white/20" : element.mediaType === "audio" ? "bg-black/10" : "bg-black/20"}`,
|
|
939
|
-
...{ [
|
|
939
|
+
...{ [chunkMZ47MV52_js.MEDIA_CHROME_ATTRIBUTE]: visual.placeholder },
|
|
940
940
|
children: [
|
|
941
941
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
942
942
|
FallbackIcon,
|
|
943
943
|
{
|
|
944
|
-
paths:
|
|
944
|
+
paths: chunkMZ47MV52_js.mediaFallbackIcon(visual, element.mediaType),
|
|
945
945
|
size: isMissing ? 36 : element.mediaType === "audio" ? 24 : 32,
|
|
946
946
|
className: isMissing ? "text-white/50" : "text-white/70"
|
|
947
947
|
}
|
|
948
948
|
),
|
|
949
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: `text-[10px] ${isMissing ? "text-white/50" : "text-white/70"}`, children: label(
|
|
949
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: `text-[10px] ${isMissing ? "text-white/50" : "text-white/70"}`, children: label(chunkMZ47MV52_js.mediaFallbackLabelKey(visual, element.mediaType)) })
|
|
950
950
|
]
|
|
951
951
|
}
|
|
952
952
|
);
|
|
@@ -956,7 +956,7 @@ function renderMediaFallback({
|
|
|
956
956
|
posterUrl,
|
|
957
957
|
surface
|
|
958
958
|
}) {
|
|
959
|
-
const visual =
|
|
959
|
+
const visual = chunkMZ47MV52_js.mediaFallbackVisual(surface, {
|
|
960
960
|
hasPoster: Boolean(posterUrl),
|
|
961
961
|
missing: element.mediaMissing === true
|
|
962
962
|
});
|
|
@@ -966,7 +966,7 @@ function renderMediaFallback({
|
|
|
966
966
|
"img",
|
|
967
967
|
{
|
|
968
968
|
src: posterUrl,
|
|
969
|
-
alt: visual.dimPoster ?
|
|
969
|
+
alt: visual.dimPoster ? chunkDVZF4ARG_js.translationsEn["pptx.media.posterAlt"] : chunkDVZF4ARG_js.translationsEn["pptx.media.videoPosterAlt"],
|
|
970
970
|
className: `w-full h-full object-contain${visual.dimPoster ? " opacity-50" : ""}`
|
|
971
971
|
}
|
|
972
972
|
),
|
|
@@ -977,7 +977,7 @@ function renderMediaFallback({
|
|
|
977
977
|
}
|
|
978
978
|
function renderMediaElement(element, mediaDataUrls, options) {
|
|
979
979
|
if (element.type !== "media") {
|
|
980
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children:
|
|
980
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunkDVZF4ARG_js.translationsEn["pptx.media.title"] });
|
|
981
981
|
}
|
|
982
982
|
const mediaType = element.mediaType;
|
|
983
983
|
const mediaPath = element.mediaPath;
|
|
@@ -985,7 +985,7 @@ function renderMediaElement(element, mediaDataUrls, options) {
|
|
|
985
985
|
const dataUrl = element.mediaData ?? (mediaPath ? mediaDataUrls.get(mediaPath) : void 0);
|
|
986
986
|
const trimFragment = buildTrimFragment(element);
|
|
987
987
|
const posterUrl = element.posterFrameData ?? void 0;
|
|
988
|
-
const shouldLoop =
|
|
988
|
+
const shouldLoop = chunkMZ47MV52_js.mediaPlaybackAttributes(element).loop;
|
|
989
989
|
const shouldAutoPlay = options?.autoPlay === true || element.autoPlay === true;
|
|
990
990
|
const isFullScreen = options?.fullScreen === true;
|
|
991
991
|
const isPresentationMode = options?.isPresentationMode === true;
|
|
@@ -1063,12 +1063,12 @@ function renderMediaElement(element, mediaDataUrls, options) {
|
|
|
1063
1063
|
if (surface.presenting || surface.preview) {
|
|
1064
1064
|
return null;
|
|
1065
1065
|
}
|
|
1066
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children:
|
|
1066
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunkDVZF4ARG_js.translationsEn["pptx.media.title"] });
|
|
1067
1067
|
}
|
|
1068
1068
|
|
|
1069
1069
|
// src/viewer/utils/text-utils.tsx
|
|
1070
1070
|
function getTextStyleForElement(element, fallbackColor) {
|
|
1071
|
-
return
|
|
1071
|
+
return chunkMZ47MV52_js.buildTextBlockStyle(element, { fallbackColor });
|
|
1072
1072
|
}
|
|
1073
1073
|
|
|
1074
1074
|
// src/viewer/utils/text-layout.tsx
|
|
@@ -1093,13 +1093,13 @@ function computeTabSize(tabStops, defaultTabSize) {
|
|
|
1093
1093
|
return avgGap > 0 ? `${Math.round(avgGap)}px` : fromDefault;
|
|
1094
1094
|
}
|
|
1095
1095
|
function getTextLayoutStyle(element) {
|
|
1096
|
-
if (!
|
|
1096
|
+
if (!chunkMZ47MV52_js.hasTextProperties(element)) {
|
|
1097
1097
|
return {};
|
|
1098
1098
|
}
|
|
1099
1099
|
const verticalAlign = element.textStyle?.vAlign || "top";
|
|
1100
|
-
const writingMode =
|
|
1101
|
-
const textOrientation =
|
|
1102
|
-
const verticalDirection =
|
|
1100
|
+
const writingMode = chunkMZ47MV52_js.toCssWritingMode(element.textStyle?.textDirection);
|
|
1101
|
+
const textOrientation = chunkMZ47MV52_js.toCssTextOrientation(element.textStyle?.textDirection);
|
|
1102
|
+
const verticalDirection = chunkMZ47MV52_js.toCssVerticalDirection(element.textStyle?.textDirection);
|
|
1103
1103
|
const parsedColumnCount = Number(element.textStyle?.columnCount);
|
|
1104
1104
|
const columnCount = Number.isFinite(parsedColumnCount) ? Math.max(1, Math.min(16, Math.round(parsedColumnCount))) : 1;
|
|
1105
1105
|
const hasColumns = columnCount > 1;
|
|
@@ -1107,7 +1107,7 @@ function getTextLayoutStyle(element) {
|
|
|
1107
1107
|
const tabStops = element.textStyle?.tabStops;
|
|
1108
1108
|
const tabSize = computeTabSize(tabStops, element.textStyle?.defaultTabSize);
|
|
1109
1109
|
const textWrapNone = element.textStyle?.textWrap === "none";
|
|
1110
|
-
const hasParagraphIndents =
|
|
1110
|
+
const hasParagraphIndents = chunkMZ47MV52_js.hasTextProperties(element) && element.paragraphIndents && element.paragraphIndents.length > 0;
|
|
1111
1111
|
const paragraphMarginLeft = element.textStyle?.paragraphMarginLeft;
|
|
1112
1112
|
const paragraphIndent = element.textStyle?.paragraphIndent;
|
|
1113
1113
|
const marginLeft = !hasParagraphIndents && typeof paragraphMarginLeft === "number" && paragraphMarginLeft !== 0 ? paragraphMarginLeft : void 0;
|
|
@@ -1116,7 +1116,7 @@ function getTextLayoutStyle(element) {
|
|
|
1116
1116
|
const bodyBottom = element.textStyle?.bodyInsetBottom ?? DEFAULT_BODY_INSET_TB_PX;
|
|
1117
1117
|
const parsedColumnSpacing = Number(element.textStyle?.columnSpacing);
|
|
1118
1118
|
const columnGap = Number.isFinite(parsedColumnSpacing) && parsedColumnSpacing > 0 ? `${parsedColumnSpacing}px` : "0.75em";
|
|
1119
|
-
const kinsokuStyles =
|
|
1119
|
+
const kinsokuStyles = chunkMZ47MV52_js.getKinsokuLineBreakStyles(element.textStyle);
|
|
1120
1120
|
if (hasColumns) {
|
|
1121
1121
|
return {
|
|
1122
1122
|
display: "block",
|
|
@@ -1163,10 +1163,10 @@ function getTextLayoutStyle(element) {
|
|
|
1163
1163
|
|
|
1164
1164
|
// src/viewer/utils/text-effects.tsx
|
|
1165
1165
|
function buildTextFillCss2(style) {
|
|
1166
|
-
return
|
|
1166
|
+
return chunkMZ47MV52_js.buildTextFillCss(style);
|
|
1167
1167
|
}
|
|
1168
1168
|
function buildTextBody3DSceneStyle2(textStyle) {
|
|
1169
|
-
return
|
|
1169
|
+
return chunkMZ47MV52_js.buildTextBody3DSceneStyle(textStyle);
|
|
1170
1170
|
}
|
|
1171
1171
|
|
|
1172
1172
|
// src/viewer/utils/text-warp-css.tsx
|
|
@@ -1351,13 +1351,13 @@ function wrapWithTextBuildAnimation(elementId, paraIndex, renderedSegments, para
|
|
|
1351
1351
|
if (!subElementAnimStates || subElementAnimStates.size === 0) {
|
|
1352
1352
|
return renderedSegments;
|
|
1353
1353
|
}
|
|
1354
|
-
const paraKey = `${elementId}${
|
|
1354
|
+
const paraKey = `${elementId}${chunkMZ47MV52_js.TEXT_BUILD_ID_SEP}p${paraIndex}`;
|
|
1355
1355
|
const paraState = subElementAnimStates.get(paraKey);
|
|
1356
1356
|
if (paraState) {
|
|
1357
1357
|
const style = buildAnimStyle(paraState);
|
|
1358
1358
|
return /* @__PURE__ */ jsxRuntime.jsx("span", { "data-anim-id": paraKey, style: { display: "inline", ...style }, children: renderedSegments }, paraKey);
|
|
1359
1359
|
}
|
|
1360
|
-
const spec =
|
|
1360
|
+
const spec = chunkMZ47MV52_js.buildTextBuildSpec(
|
|
1361
1361
|
elementId,
|
|
1362
1362
|
paraIndex,
|
|
1363
1363
|
paraSegments.map((entry) => ({ text: entry.segment.text, style: entry })),
|
|
@@ -1375,7 +1375,7 @@ function wrapWithTextBuildAnimation(elementId, paraIndex, renderedSegments, para
|
|
|
1375
1375
|
"span",
|
|
1376
1376
|
{
|
|
1377
1377
|
"data-anim-id": span.animId,
|
|
1378
|
-
style:
|
|
1378
|
+
style: chunkMZ47MV52_js.textBuildSpanStyle(span),
|
|
1379
1379
|
children: content
|
|
1380
1380
|
},
|
|
1381
1381
|
span.animId
|
|
@@ -1519,10 +1519,10 @@ function renderScriptAwareText(text, needsScriptFonts, scriptFonts, baseFontFami
|
|
|
1519
1519
|
if (!needsScriptFonts || !text) {
|
|
1520
1520
|
return text;
|
|
1521
1521
|
}
|
|
1522
|
-
const runs =
|
|
1522
|
+
const runs = chunkMZ47MV52_js.segmentByScript(text);
|
|
1523
1523
|
if (runs.length <= 1) {
|
|
1524
1524
|
if (runs.length === 1) {
|
|
1525
|
-
const font =
|
|
1525
|
+
const font = chunkMZ47MV52_js.resolveFontForScript(runs[0].script, scriptFonts);
|
|
1526
1526
|
if (font && font !== baseFontFamily) {
|
|
1527
1527
|
return /* @__PURE__ */ jsxRuntime.jsx("span", { style: { fontFamily: font }, children: text });
|
|
1528
1528
|
}
|
|
@@ -1530,7 +1530,7 @@ function renderScriptAwareText(text, needsScriptFonts, scriptFonts, baseFontFami
|
|
|
1530
1530
|
return text;
|
|
1531
1531
|
}
|
|
1532
1532
|
return runs.map((run, i) => {
|
|
1533
|
-
const font =
|
|
1533
|
+
const font = chunkMZ47MV52_js.resolveFontForScript(run.script, scriptFonts);
|
|
1534
1534
|
if (!font || font === baseFontFamily) {
|
|
1535
1535
|
return /* @__PURE__ */ jsxRuntime.jsx(React6__default.default.Fragment, { children: run.text }, `${keyPrefix}-r${i}`);
|
|
1536
1536
|
}
|
|
@@ -1541,14 +1541,14 @@ function renderMetricPieces(text, metric, keyPrefix, inner) {
|
|
|
1541
1541
|
if (!metric || !text) {
|
|
1542
1542
|
return inner(text, keyPrefix);
|
|
1543
1543
|
}
|
|
1544
|
-
const pieces =
|
|
1544
|
+
const pieces = chunkMZ47MV52_js.splitRunForMetrics(text, metric.font);
|
|
1545
1545
|
if (pieces.length <= 1) {
|
|
1546
1546
|
return inner(text, keyPrefix);
|
|
1547
1547
|
}
|
|
1548
1548
|
return pieces.map((piece, i) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1549
1549
|
"span",
|
|
1550
1550
|
{
|
|
1551
|
-
style: { letterSpacing:
|
|
1551
|
+
style: { letterSpacing: chunkMZ47MV52_js.pieceLetterSpacing(metric.authoredPx, piece.tracking) },
|
|
1552
1552
|
children: inner(piece.text, `${keyPrefix}-w${i}`)
|
|
1553
1553
|
},
|
|
1554
1554
|
`${keyPrefix}-w${i}`
|
|
@@ -1619,8 +1619,8 @@ function renderSegmentContent(elementId, segmentIndex, textValue, lines, needsSc
|
|
|
1619
1619
|
});
|
|
1620
1620
|
}
|
|
1621
1621
|
function renderEquationSegment(elementId, segmentIndex, equationXml, equationNumber) {
|
|
1622
|
-
const mathml =
|
|
1623
|
-
const safeMathml = mathml ?
|
|
1622
|
+
const mathml = chunkMZ47MV52_js.convertOmmlToMathMl(equationXml);
|
|
1623
|
+
const safeMathml = mathml ? chunkMZ47MV52_js.sanitizeMathMl(mathml) : "";
|
|
1624
1624
|
const equationContent = safeMathml ? /* @__PURE__ */ jsxRuntime.jsx(
|
|
1625
1625
|
"span",
|
|
1626
1626
|
{
|
|
@@ -1630,7 +1630,7 @@ function renderEquationSegment(elementId, segmentIndex, equationXml, equationNum
|
|
|
1630
1630
|
},
|
|
1631
1631
|
dangerouslySetInnerHTML: { __html: safeMathml }
|
|
1632
1632
|
}
|
|
1633
|
-
) : /* @__PURE__ */ jsxRuntime.jsx("span", { className: "inline-block px-1 py-0.5 rounded text-xs bg-gray-200/20 text-gray-400 italic", children:
|
|
1633
|
+
) : /* @__PURE__ */ jsxRuntime.jsx("span", { className: "inline-block px-1 py-0.5 rounded text-xs bg-gray-200/20 text-gray-400 italic", children: chunkDVZF4ARG_js.translationsEn["pptx.textSegment.equationFallback"] });
|
|
1634
1634
|
if (equationNumber) {
|
|
1635
1635
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
1636
1636
|
"span",
|
|
@@ -1670,7 +1670,7 @@ function renderEquationSegment(elementId, segmentIndex, equationXml, equationNum
|
|
|
1670
1670
|
return /* @__PURE__ */ jsxRuntime.jsx("span", { children: equationContent }, `${elementId}-seg-${segmentIndex}`);
|
|
1671
1671
|
}
|
|
1672
1672
|
function renderPictureBullet(elementId, segmentIndex, bulletInfo, baseFontSize) {
|
|
1673
|
-
const picture =
|
|
1673
|
+
const picture = chunkMZ47MV52_js.resolvePictureBullet(bulletInfo, baseFontSize) ?? {
|
|
1674
1674
|
sizePx: baseFontSize,
|
|
1675
1675
|
fallbackMarker: "\u2022",
|
|
1676
1676
|
accessibleLabel: "Bullet"
|
|
@@ -1721,7 +1721,7 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
|
|
|
1721
1721
|
}
|
|
1722
1722
|
const segmentStyle = segment.style || {};
|
|
1723
1723
|
const rawText = bulletInfo && typeof bulletHangPx === "number" ? (segment.text || "").trimEnd() : segment.text || "";
|
|
1724
|
-
const textValue =
|
|
1724
|
+
const textValue = chunkMZ47MV52_js.substituteFieldText(rawText, segment.fieldType, fieldContext);
|
|
1725
1725
|
const lines = textValue.split("\n");
|
|
1726
1726
|
const textDecorationTokens = [];
|
|
1727
1727
|
if (segmentStyle.underline || segmentStyle.hyperlink) {
|
|
@@ -1731,8 +1731,8 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
|
|
|
1731
1731
|
textDecorationTokens.push("line-through");
|
|
1732
1732
|
}
|
|
1733
1733
|
const isDoubleStrike = segmentStyle.strikethrough && segmentStyle.strikeType === "dblStrike";
|
|
1734
|
-
const resolvedSegmentColor = segmentStyle.hyperlink ?
|
|
1735
|
-
const underlineDecoration =
|
|
1734
|
+
const resolvedSegmentColor = segmentStyle.hyperlink ? chunkMZ47MV52_js.normalizeHexColor(segmentStyle.color || element.textStyle?.color, HYPERLINK_COLOR) : chunkMZ47MV52_js.normalizeHexColor(segmentStyle.color || element.textStyle?.color, fallbackColor);
|
|
1735
|
+
const underlineDecoration = chunkMZ47MV52_js.resolveUnderlineDecorationStyle(
|
|
1736
1736
|
Boolean(isDoubleStrike),
|
|
1737
1737
|
segmentStyle.underlineStyle
|
|
1738
1738
|
);
|
|
@@ -1742,17 +1742,17 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
|
|
|
1742
1742
|
const authoredLetterSpacing = typeof segmentStyle.characterSpacing === "number" && segmentStyle.characterSpacing !== 0 ? segmentStyle.characterSpacing / 100 * (96 / 72) : 0;
|
|
1743
1743
|
const textFillStyles = buildTextFillCss2(segmentStyle);
|
|
1744
1744
|
const rawFontSize = segmentStyle.fontSize || element.textStyle?.fontSize || DEFAULT_TEXT_FONT_SIZE;
|
|
1745
|
-
const autoFitScale =
|
|
1745
|
+
const autoFitScale = chunkMZ47MV52_js.resolveAutoFitFontScale(element.textStyle);
|
|
1746
1746
|
const baseFontSize = rawFontSize * autoFitScale;
|
|
1747
1747
|
const baselineShift = baselineFraction !== 0 ? `${baselineFraction * baseFontSize}px` : void 0;
|
|
1748
1748
|
const baseFontSizePt = baseFontSize * (72 / 96);
|
|
1749
1749
|
const fontKerning = typeof segmentStyle.kerning === "number" ? segmentStyle.kerning === 0 ? "none" : baseFontSizePt >= segmentStyle.kerning / 100 ? "normal" : "none" : void 0;
|
|
1750
1750
|
const rawFontFamily = segmentStyle.fontFamily || element.textStyle?.fontFamily;
|
|
1751
|
-
const baseFontFamily = rawFontFamily ?
|
|
1751
|
+
const baseFontFamily = rawFontFamily ? chunkMZ47MV52_js.getSubstituteFontFamily(
|
|
1752
1752
|
rawFontFamily,
|
|
1753
|
-
|
|
1753
|
+
chunkMZ47MV52_js.parsePanoseString(segmentStyle.latinFontPanose ?? element.textStyle?.latinFontPanose)
|
|
1754
1754
|
) : DEFAULT_FONT_FAMILY2;
|
|
1755
|
-
const scriptFont = (name, panose) => name ?
|
|
1755
|
+
const scriptFont = (name, panose) => name ? chunkMZ47MV52_js.getSubstituteFontFamily(name, chunkMZ47MV52_js.parsePanoseString(panose)) : baseFontFamily;
|
|
1756
1756
|
const scriptFonts = {
|
|
1757
1757
|
latin: baseFontFamily,
|
|
1758
1758
|
eastAsia: scriptFont(
|
|
@@ -1768,7 +1768,7 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
|
|
|
1768
1768
|
segmentStyle.symbolFontPanose ?? element.textStyle?.symbolFontPanose
|
|
1769
1769
|
)
|
|
1770
1770
|
};
|
|
1771
|
-
const needsScriptFonts =
|
|
1771
|
+
const needsScriptFonts = chunkMZ47MV52_js.hasDistinctScriptFonts(scriptFonts);
|
|
1772
1772
|
const metricFont = {
|
|
1773
1773
|
fontFamily: baseFontFamily,
|
|
1774
1774
|
fontSizePx: baseFontSize * baselineFontScale,
|
|
@@ -1776,9 +1776,9 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
|
|
|
1776
1776
|
italic: Boolean(segmentStyle.italic)
|
|
1777
1777
|
};
|
|
1778
1778
|
const metricContext = { font: metricFont, authoredPx: authoredLetterSpacing };
|
|
1779
|
-
const letterSpacing =
|
|
1779
|
+
const letterSpacing = chunkMZ47MV52_js.pieceLetterSpacing(
|
|
1780
1780
|
authoredLetterSpacing,
|
|
1781
|
-
|
|
1781
|
+
chunkMZ47MV52_js.resolveMetricTrackingPx(textValue, metricFont)
|
|
1782
1782
|
);
|
|
1783
1783
|
const spanStyle = {
|
|
1784
1784
|
color: resolvedSegmentColor,
|
|
@@ -1797,15 +1797,15 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
|
|
|
1797
1797
|
fontVariantCaps: segmentStyle.textCaps === "small" ? "small-caps" : void 0,
|
|
1798
1798
|
letterSpacing,
|
|
1799
1799
|
fontKerning,
|
|
1800
|
-
backgroundColor: textFillStyles ? void 0 : segmentStyle.highlightColor ?
|
|
1800
|
+
backgroundColor: textFillStyles ? void 0 : segmentStyle.highlightColor ? chunkMZ47MV52_js.normalizeHexColor(segmentStyle.highlightColor, "transparent") : void 0,
|
|
1801
1801
|
...textFillStyles,
|
|
1802
|
-
textDecorationColor: segmentStyle.underlineColor ?
|
|
1803
|
-
WebkitTextStroke: segmentStyle.textOutlineWidth && segmentStyle.textOutlineColor ? `${segmentStyle.textOutlineWidth}px ${
|
|
1802
|
+
textDecorationColor: segmentStyle.underlineColor ? chunkMZ47MV52_js.normalizeHexColor(segmentStyle.underlineColor, void 0) : void 0,
|
|
1803
|
+
WebkitTextStroke: segmentStyle.textOutlineWidth && segmentStyle.textOutlineColor ? `${segmentStyle.textOutlineWidth}px ${chunkMZ47MV52_js.normalizeHexColor(segmentStyle.textOutlineColor, "#000000")}` : segmentStyle.textOutlineWidth ? `${segmentStyle.textOutlineWidth}px currentColor` : void 0,
|
|
1804
1804
|
paintOrder: segmentStyle.textOutlineWidth ? "stroke fill" : void 0,
|
|
1805
|
-
textShadow:
|
|
1806
|
-
filter:
|
|
1807
|
-
opacity:
|
|
1808
|
-
WebkitBoxReflect:
|
|
1805
|
+
textShadow: chunkMZ47MV52_js.buildTextShadowCss(segmentStyle),
|
|
1806
|
+
filter: chunkMZ47MV52_js.buildTextRunFilterChain(segmentStyle),
|
|
1807
|
+
opacity: chunkMZ47MV52_js.getTextAlphaOpacity(segmentStyle),
|
|
1808
|
+
WebkitBoxReflect: chunkMZ47MV52_js.buildTextReflectionCss(segmentStyle)
|
|
1809
1809
|
};
|
|
1810
1810
|
const runRtl = segmentStyle.rtl;
|
|
1811
1811
|
if (runRtl !== void 0 && runRtl !== paragraphRtl) {
|
|
@@ -1825,7 +1825,7 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
|
|
|
1825
1825
|
spanStyle.fontSize = baseFontSize * (bulletInfo.sizePercent / 100) * baselineFontScale;
|
|
1826
1826
|
}
|
|
1827
1827
|
if (bulletInfo.color) {
|
|
1828
|
-
spanStyle.color =
|
|
1828
|
+
spanStyle.color = chunkMZ47MV52_js.normalizeHexColor(bulletInfo.color, resolvedSegmentColor);
|
|
1829
1829
|
}
|
|
1830
1830
|
if (typeof bulletHangPx === "number" && bulletHangPx > 0) {
|
|
1831
1831
|
spanStyle.display = "inline-block";
|
|
@@ -1871,7 +1871,7 @@ function renderSingleSegment(element, segment, segmentIndex, fallbackColor, find
|
|
|
1871
1871
|
textAlign: segment.rubyAlignment === "l" ? "left" : segment.rubyAlignment === "r" ? "right" : segment.rubyAlignment === "dist" || segment.rubyAlignment === "distCat" || segment.rubyAlignment === "distLetter" ? "justify" : "center"
|
|
1872
1872
|
};
|
|
1873
1873
|
if (segment.rubyStyle?.color) {
|
|
1874
|
-
rubyStyle.color =
|
|
1874
|
+
rubyStyle.color = chunkMZ47MV52_js.normalizeHexColor(segment.rubyStyle.color, resolvedSegmentColor);
|
|
1875
1875
|
}
|
|
1876
1876
|
innerContent = /* @__PURE__ */ jsxRuntime.jsxs("ruby", { children: [
|
|
1877
1877
|
baseContent,
|
|
@@ -1944,7 +1944,7 @@ function resolveParagraphSpacing(input) {
|
|
|
1944
1944
|
if (typeof exactPt === "number" && exactPt > 0) {
|
|
1945
1945
|
result.lineHeight = `${exactPt * PT_TO_PX}px`;
|
|
1946
1946
|
} else if (typeof multiplier === "number" && multiplier > 0) {
|
|
1947
|
-
result.lineHeight =
|
|
1947
|
+
result.lineHeight = chunkMZ47MV52_js.proportionalLineHeight(multiplier);
|
|
1948
1948
|
}
|
|
1949
1949
|
return result;
|
|
1950
1950
|
}
|
|
@@ -1966,7 +1966,7 @@ function groupSegmentsIntoParagraphs(segments) {
|
|
|
1966
1966
|
return paragraphs;
|
|
1967
1967
|
}
|
|
1968
1968
|
function renderTextSegments(element, fallbackColor, emptyFallback, findHighlights, onHyperlinkClick, fieldContext, subElementAnimStates, segmentOverrides, requireCtrlClick) {
|
|
1969
|
-
if (!
|
|
1969
|
+
if (!chunkMZ47MV52_js.hasTextProperties(element)) {
|
|
1970
1970
|
return emptyFallback || null;
|
|
1971
1971
|
}
|
|
1972
1972
|
const effectiveSegments = segmentOverrides ?? element.textSegments;
|
|
@@ -1987,10 +1987,10 @@ function renderTextSegments(element, fallbackColor, emptyFallback, findHighlight
|
|
|
1987
1987
|
return element.text || emptyFallback || "";
|
|
1988
1988
|
}
|
|
1989
1989
|
const paragraphs = groupSegmentsIntoParagraphs(effectiveSegments);
|
|
1990
|
-
const paragraphIndents =
|
|
1991
|
-
const elementRtl =
|
|
1992
|
-
const elementAlign =
|
|
1993
|
-
const bodyStyle =
|
|
1990
|
+
const paragraphIndents = chunkMZ47MV52_js.hasTextProperties(element) ? element.paragraphIndents : void 0;
|
|
1991
|
+
const elementRtl = chunkMZ47MV52_js.hasTextProperties(element) ? element.textStyle?.rtl : void 0;
|
|
1992
|
+
const elementAlign = chunkMZ47MV52_js.hasTextProperties(element) ? element.textStyle?.align : void 0;
|
|
1993
|
+
const bodyStyle = chunkMZ47MV52_js.hasTextProperties(element) ? element.textStyle : void 0;
|
|
1994
1994
|
const spaceFirstLast = bodyStyle?.spaceFirstLastParagraph !== false;
|
|
1995
1995
|
return paragraphs.map(({ entries: paraSegments, terminator }, paraIndex) => {
|
|
1996
1996
|
const paraIndent = paragraphIndents?.[paraIndex];
|
|
@@ -2005,14 +2005,14 @@ function renderTextSegments(element, fallbackColor, emptyFallback, findHighlight
|
|
|
2005
2005
|
return Boolean(segment.text) && segment.text.trim().length > 0;
|
|
2006
2006
|
});
|
|
2007
2007
|
const hasBullet = bulletInfo && !bulletInfo.none && hasVisibleTextContent;
|
|
2008
|
-
const paraRtl =
|
|
2008
|
+
const paraRtl = chunkMZ47MV52_js.resolveParagraphRtl(paraSegments, elementRtl);
|
|
2009
2009
|
const isRtlParagraph = paraRtl === true;
|
|
2010
|
-
const paraAlign =
|
|
2011
|
-
const cssTextAlign =
|
|
2010
|
+
const paraAlign = chunkMZ47MV52_js.resolveParagraphAlign(paraSegments, elementAlign);
|
|
2011
|
+
const cssTextAlign = chunkMZ47MV52_js.resolveCssTextAlign(paraAlign, isRtlParagraph);
|
|
2012
2012
|
const paraMarginLeft = isRtlParagraph ? void 0 : rawMarginLeft;
|
|
2013
2013
|
const paraMarginRight = isRtlParagraph ? rawMarginLeft : void 0;
|
|
2014
2014
|
const paraTextIndent = rawTextIndent;
|
|
2015
|
-
const paraKinsokuStyle =
|
|
2015
|
+
const paraKinsokuStyle = chunkMZ47MV52_js.getKinsokuLineBreakStyles(firstSeg?.segment.style);
|
|
2016
2016
|
const hasParaKinsoku = Object.keys(paraKinsokuStyle).length > 0;
|
|
2017
2017
|
const paraProps = effectiveSegments[firstSeg?.globalIndex ?? -1]?.paragraphProperties ?? (paraSegments.length === 0 ? terminator?.paragraphProperties : void 0);
|
|
2018
2018
|
const spacing = resolveParagraphSpacing({
|
|
@@ -2022,7 +2022,7 @@ function renderTextSegments(element, fallbackColor, emptyFallback, findHighlight
|
|
|
2022
2022
|
isLast: paraIndex === paragraphs.length - 1,
|
|
2023
2023
|
spaceFirstLast
|
|
2024
2024
|
});
|
|
2025
|
-
const strutFontSize =
|
|
2025
|
+
const strutFontSize = chunkMZ47MV52_js.resolveParagraphStrutFontSize(
|
|
2026
2026
|
paraSegments.length > 0 ? paraSegments.map(({ segment }) => segment) : terminator ? [terminator] : [],
|
|
2027
2027
|
bodyStyle?.fontSize
|
|
2028
2028
|
);
|
|
@@ -2126,13 +2126,13 @@ function hexToRgbUnit(hex) {
|
|
|
2126
2126
|
};
|
|
2127
2127
|
}
|
|
2128
2128
|
function getDuotoneColors(element) {
|
|
2129
|
-
if (!
|
|
2129
|
+
if (!chunkMZ47MV52_js.isImageLikeElement(element)) {
|
|
2130
2130
|
return void 0;
|
|
2131
2131
|
}
|
|
2132
2132
|
return element.imageEffects?.duotone;
|
|
2133
2133
|
}
|
|
2134
2134
|
function buildLineShadowCss(element) {
|
|
2135
|
-
if (!
|
|
2135
|
+
if (!chunkMZ47MV52_js.hasShapeProperties(element)) {
|
|
2136
2136
|
return void 0;
|
|
2137
2137
|
}
|
|
2138
2138
|
const ss = element.shapeStyle;
|
|
@@ -2143,13 +2143,13 @@ function buildLineShadowCss(element) {
|
|
|
2143
2143
|
const offsetY = typeof ss.lineShadowOffsetY === "number" ? ss.lineShadowOffsetY : 2;
|
|
2144
2144
|
const blur = typeof ss.lineShadowBlur === "number" ? Math.max(0, ss.lineShadowBlur) : 4;
|
|
2145
2145
|
const opacity = typeof ss.lineShadowOpacity === "number" ? Math.max(0, Math.min(1, ss.lineShadowOpacity)) : 0.35;
|
|
2146
|
-
return `${Math.round(offsetX)}px ${Math.round(offsetY)}px ${Math.round(blur)}px ${
|
|
2147
|
-
|
|
2146
|
+
return `${Math.round(offsetX)}px ${Math.round(offsetY)}px ${Math.round(blur)}px ${chunkMZ47MV52_js.colorWithOpacity(
|
|
2147
|
+
chunkMZ47MV52_js.normalizeHexColor(ss.lineShadowColor, "#000000"),
|
|
2148
2148
|
opacity
|
|
2149
2149
|
)}`;
|
|
2150
2150
|
}
|
|
2151
2151
|
function buildLineGlowFilter(element) {
|
|
2152
|
-
if (!
|
|
2152
|
+
if (!chunkMZ47MV52_js.hasShapeProperties(element)) {
|
|
2153
2153
|
return void 0;
|
|
2154
2154
|
}
|
|
2155
2155
|
const ss = element.shapeStyle;
|
|
@@ -2158,7 +2158,7 @@ function buildLineGlowFilter(element) {
|
|
|
2158
2158
|
}
|
|
2159
2159
|
const glowOpacity = typeof ss.lineGlowOpacity === "number" ? ss.lineGlowOpacity : 0.75;
|
|
2160
2160
|
const glowRad = Math.round(Math.max(0, ss.lineGlowRadius));
|
|
2161
|
-
const glowCol =
|
|
2161
|
+
const glowCol = chunkMZ47MV52_js.colorWithOpacity(chunkMZ47MV52_js.normalizeHexColor(ss.lineGlowColor, "#ffff00"), glowOpacity);
|
|
2162
2162
|
return `drop-shadow(0 0 ${glowRad}px ${glowCol})`;
|
|
2163
2163
|
}
|
|
2164
2164
|
function mapDagBlendModeToCss(blend) {
|
|
@@ -2182,7 +2182,7 @@ function getDagDuotoneFilterId(elementId) {
|
|
|
2182
2182
|
return `dag-duotone-${elementId}`;
|
|
2183
2183
|
}
|
|
2184
2184
|
function hasDagDuotoneEffect(element) {
|
|
2185
|
-
if (!
|
|
2185
|
+
if (!chunkMZ47MV52_js.hasShapeProperties(element)) {
|
|
2186
2186
|
return false;
|
|
2187
2187
|
}
|
|
2188
2188
|
return Boolean(element.shapeStyle?.dagDuotone);
|
|
@@ -2245,7 +2245,7 @@ function getRoundRectRadiusPx(element) {
|
|
|
2245
2245
|
|
|
2246
2246
|
// src/viewer/utils/shape-visual-3d.ts
|
|
2247
2247
|
function build3DExtrusionData2(shape3d, scene3d, fillColor, elementWidth, elementHeight) {
|
|
2248
|
-
return
|
|
2248
|
+
return chunkMZ47MV52_js.build3DExtrusionData(
|
|
2249
2249
|
shape3d,
|
|
2250
2250
|
scene3d,
|
|
2251
2251
|
fillColor,
|
|
@@ -2254,7 +2254,7 @@ function build3DExtrusionData2(shape3d, scene3d, fillColor, elementWidth, elemen
|
|
|
2254
2254
|
);
|
|
2255
2255
|
}
|
|
2256
2256
|
function apply3dEffects2(base, scene3d, shape3d, fillColorFallback) {
|
|
2257
|
-
|
|
2257
|
+
chunkMZ47MV52_js.apply3dEffects(base, scene3d, shape3d, fillColorFallback);
|
|
2258
2258
|
}
|
|
2259
2259
|
|
|
2260
2260
|
// src/viewer/utils/shape-visual-style.ts
|
|
@@ -2262,43 +2262,43 @@ function getGradientTilingCss(style) {
|
|
|
2262
2262
|
if (!style || style.fillMode !== "gradient") {
|
|
2263
2263
|
return void 0;
|
|
2264
2264
|
}
|
|
2265
|
-
const isStructuredLinear = (style.fillGradientType || "linear") === "linear" &&
|
|
2265
|
+
const isStructuredLinear = (style.fillGradientType || "linear") === "linear" && chunkMZ47MV52_js.sanitizeGradientStops(style.fillGradientStops).length > 0;
|
|
2266
2266
|
if (isStructuredLinear) {
|
|
2267
|
-
const flip =
|
|
2267
|
+
const flip = chunkMZ47MV52_js.getGradientTileFlipCss(style.fillGradientFlip);
|
|
2268
2268
|
if (flip) {
|
|
2269
2269
|
return flip;
|
|
2270
2270
|
}
|
|
2271
2271
|
}
|
|
2272
|
-
return
|
|
2272
|
+
return chunkMZ47MV52_js.getGradientTileRectCss(style.fillGradientTileRect);
|
|
2273
2273
|
}
|
|
2274
2274
|
function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeColor, animatesFill, animatesStroke) {
|
|
2275
|
-
if (!
|
|
2275
|
+
if (!chunkMZ47MV52_js.hasShapeProperties(element)) {
|
|
2276
2276
|
return {};
|
|
2277
2277
|
}
|
|
2278
2278
|
const normalizedShapeType = getShapeType(element.shapeType);
|
|
2279
|
-
const clipPath =
|
|
2279
|
+
const clipPath = chunkMZ47MV52_js.isIdentityRectClip(element) ? void 0 : chunkMZ47MV52_js.getResolvedShapeClipPath(element);
|
|
2280
2280
|
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;
|
|
2281
|
-
const rendersStrokeOnlyPreset =
|
|
2281
|
+
const rendersStrokeOnlyPreset = chunkMZ47MV52_js.isStrokeOnlyPresetElement(element);
|
|
2282
2282
|
const fillOpacity = element.shapeStyle?.fillOpacity;
|
|
2283
2283
|
const strokeOpacity = element.shapeStyle?.strokeOpacity;
|
|
2284
|
-
const strokeDash =
|
|
2285
|
-
const fillGradient =
|
|
2284
|
+
const strokeDash = chunkMZ47MV52_js.normalizeStrokeDashType(element.shapeStyle?.strokeDash);
|
|
2285
|
+
const fillGradient = chunkMZ47MV52_js.buildCssGradientFromShapeStyle(element.shapeStyle, {
|
|
2286
2286
|
rotation: element.rotation,
|
|
2287
2287
|
width: element.width,
|
|
2288
2288
|
height: element.height
|
|
2289
2289
|
}) || element.shapeStyle?.fillGradient;
|
|
2290
|
-
const shadowCss =
|
|
2291
|
-
const innerShadowCss =
|
|
2292
|
-
const resolvedFillColor =
|
|
2293
|
-
const resolvedStrokeColor =
|
|
2290
|
+
const shadowCss = chunkMZ47MV52_js.buildShadowCssFromShapeStyle(element.shapeStyle);
|
|
2291
|
+
const innerShadowCss = chunkMZ47MV52_js.buildInnerShadowCssFromShapeStyle(element.shapeStyle);
|
|
2292
|
+
const resolvedFillColor = chunkMZ47MV52_js.colorWithOpacity(fillColor, fillOpacity);
|
|
2293
|
+
const resolvedStrokeColor = chunkMZ47MV52_js.colorWithOpacity(strokeColor, strokeOpacity);
|
|
2294
2294
|
const ss = element.shapeStyle;
|
|
2295
2295
|
const gradientTiling = getGradientTilingCss(ss);
|
|
2296
|
-
const paintsGradientOutline =
|
|
2296
|
+
const paintsGradientOutline = chunkMZ47MV52_js.suppressesCssBorder(element);
|
|
2297
2297
|
const hasFillOverlayColor = Boolean(
|
|
2298
2298
|
ss?.dagFillOverlayColor && ss.dagFillOverlayColor !== "transparent"
|
|
2299
2299
|
);
|
|
2300
2300
|
const combinedShadowParts = [];
|
|
2301
|
-
const multiLayerShadow =
|
|
2301
|
+
const multiLayerShadow = chunkMZ47MV52_js.buildMultiLayerShadowCss(element.shapeStyle);
|
|
2302
2302
|
if (multiLayerShadow) {
|
|
2303
2303
|
combinedShadowParts.push(multiLayerShadow);
|
|
2304
2304
|
} else if (shadowCss) {
|
|
@@ -2307,7 +2307,7 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
|
|
|
2307
2307
|
if (innerShadowCss) {
|
|
2308
2308
|
combinedShadowParts.push(innerShadowCss);
|
|
2309
2309
|
}
|
|
2310
|
-
const glowBoxShadow =
|
|
2310
|
+
const glowBoxShadow = chunkMZ47MV52_js.buildGlowBoxShadow(ss?.glowColor, ss?.glowRadius, ss?.glowOpacity);
|
|
2311
2311
|
if (glowBoxShadow) {
|
|
2312
2312
|
combinedShadowParts.push(glowBoxShadow);
|
|
2313
2313
|
}
|
|
@@ -2315,7 +2315,7 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
|
|
|
2315
2315
|
if (lineShadow) {
|
|
2316
2316
|
combinedShadowParts.push(lineShadow);
|
|
2317
2317
|
}
|
|
2318
|
-
const compoundLineShadow =
|
|
2318
|
+
const compoundLineShadow = chunkMZ47MV52_js.getCompoundLineBoxShadow(
|
|
2319
2319
|
element.shapeStyle?.compoundLine,
|
|
2320
2320
|
strokeWidth,
|
|
2321
2321
|
resolvedStrokeColor
|
|
@@ -2328,11 +2328,11 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
|
|
|
2328
2328
|
if (ss?.glowColor && ss.glowColor !== "transparent" && ss.glowRadius) {
|
|
2329
2329
|
const glowOpacity = typeof ss.glowOpacity === "number" ? ss.glowOpacity : 0.75;
|
|
2330
2330
|
const glowRad = Math.round(Math.max(0, ss.glowRadius));
|
|
2331
|
-
const glowCol =
|
|
2331
|
+
const glowCol = chunkMZ47MV52_js.colorWithOpacity(chunkMZ47MV52_js.normalizeHexColor(ss.glowColor, "#ffff00"), glowOpacity);
|
|
2332
2332
|
filterParts.push(`drop-shadow(0 0 ${glowRad}px ${glowCol})`);
|
|
2333
2333
|
}
|
|
2334
2334
|
if (typeof ss?.softEdgeRadius === "number" && ss.softEdgeRadius > 0) {
|
|
2335
|
-
filterParts.push(`url(#${
|
|
2335
|
+
filterParts.push(`url(#${chunkMZ47MV52_js.getSoftEdgeFilterId(element.id)})`);
|
|
2336
2336
|
}
|
|
2337
2337
|
if (typeof ss?.blurRadius === "number" && ss.blurRadius > 0) {
|
|
2338
2338
|
filterParts.push(`blur(${Math.round(ss.blurRadius)}px)`);
|
|
@@ -2341,13 +2341,13 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
|
|
|
2341
2341
|
if (lineGlowCss) {
|
|
2342
2342
|
filterParts.push(lineGlowCss);
|
|
2343
2343
|
}
|
|
2344
|
-
const dagFilter =
|
|
2344
|
+
const dagFilter = chunkMZ47MV52_js.getEffectDagFilter(ss, element.id);
|
|
2345
2345
|
if (dagFilter) {
|
|
2346
2346
|
filterParts.push(dagFilter);
|
|
2347
2347
|
}
|
|
2348
2348
|
const lineJoinCss = ss?.lineJoin === "round" ? "round" : ss?.lineJoin === "bevel" ? "bevel" : ss?.lineJoin === "miter" ? "miter" : void 0;
|
|
2349
2349
|
const miterLimitCss = ss?.lineJoin === "miter" && typeof ss?.miterLimit === "number" ? Math.max(ss.miterLimit / 1e5, 1) : void 0;
|
|
2350
|
-
const patternFill =
|
|
2350
|
+
const patternFill = chunkMZ47MV52_js.buildPatternFillCss(element.shapeStyle);
|
|
2351
2351
|
const imageFillUrl = ss?.fillMode === "image" && ss.fillImageUrl ? ss.fillImageUrl : void 0;
|
|
2352
2352
|
const imageFillMode = ss?.fillImageMode || "stretch";
|
|
2353
2353
|
let reflectCss;
|
|
@@ -2359,7 +2359,7 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
|
|
|
2359
2359
|
const endOpacity = typeof ss.reflectionEndOpacity === "number" ? ss.reflectionEndOpacity : 0;
|
|
2360
2360
|
const fadeLength = typeof ss.reflectionEndPosition === "number" ? Math.round(ss.reflectionEndPosition * Math.max(element.height, 1)) : 100;
|
|
2361
2361
|
const blurRadius = typeof ss.reflectionBlurRadius === "number" ? ss.reflectionBlurRadius : 0;
|
|
2362
|
-
reflectCss =
|
|
2362
|
+
reflectCss = chunkMZ47MV52_js.buildReflectionCss(distance, startOpacity, endOpacity, fadeLength, blurRadius);
|
|
2363
2363
|
}
|
|
2364
2364
|
}
|
|
2365
2365
|
const base = {
|
|
@@ -2405,9 +2405,9 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
|
|
|
2405
2405
|
// path following the shape's geometry, because a CSS border can only take
|
|
2406
2406
|
// one colour. Keeping the border too would draw the parser's averaged
|
|
2407
2407
|
// solid underneath the gradient.
|
|
2408
|
-
borderWidth: strokeWidth > 0 && !paintsGradientOutline ?
|
|
2408
|
+
borderWidth: strokeWidth > 0 && !paintsGradientOutline ? chunkMZ47MV52_js.getCompoundLineBorderWidth(ss?.compoundLine, strokeWidth) : 0,
|
|
2409
2409
|
borderColor: strokeWidth > 0 && !paintsGradientOutline ? resolvedStrokeColor : void 0,
|
|
2410
|
-
borderStyle: strokeWidth > 0 && !paintsGradientOutline ?
|
|
2410
|
+
borderStyle: strokeWidth > 0 && !paintsGradientOutline ? chunkMZ47MV52_js.getCssBorderDashStyle(strokeDash, ss?.compoundLine) : void 0,
|
|
2411
2411
|
strokeLinejoin: lineJoinCss,
|
|
2412
2412
|
strokeMiterlimit: miterLimitCss,
|
|
2413
2413
|
strokeLinecap: ss?.lineCap === "rnd" ? "round" : ss?.lineCap === "sq" ? "square" : ss?.lineCap === "flat" ? "butt" : void 0
|
|
@@ -2467,7 +2467,7 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
|
|
|
2467
2467
|
borderWidth: 0,
|
|
2468
2468
|
borderTopWidth: Math.max(strokeWidth, 2),
|
|
2469
2469
|
borderTopColor: resolvedStrokeColor,
|
|
2470
|
-
borderTopStyle:
|
|
2470
|
+
borderTopStyle: chunkMZ47MV52_js.getCssBorderDashStyle(strokeDash)
|
|
2471
2471
|
};
|
|
2472
2472
|
}
|
|
2473
2473
|
if (normalizedShapeType === "cylinder") {
|
|
@@ -2481,13 +2481,13 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
|
|
|
2481
2481
|
function getConnectorAdjustment(element, key, fallback) {
|
|
2482
2482
|
const direct = element.shapeAdjustments?.[key];
|
|
2483
2483
|
if (typeof direct === "number" && Number.isFinite(direct)) {
|
|
2484
|
-
return
|
|
2484
|
+
return chunkMZ47MV52_js.clampUnitInterval(direct / 1e5);
|
|
2485
2485
|
}
|
|
2486
2486
|
const fallbackKey = element.shapeAdjustments?.adj;
|
|
2487
2487
|
if (typeof fallbackKey === "number" && Number.isFinite(fallbackKey)) {
|
|
2488
|
-
return
|
|
2488
|
+
return chunkMZ47MV52_js.clampUnitInterval(fallbackKey / 1e5);
|
|
2489
2489
|
}
|
|
2490
|
-
return
|
|
2490
|
+
return chunkMZ47MV52_js.clampUnitInterval(fallback);
|
|
2491
2491
|
}
|
|
2492
2492
|
function getConnectorPathGeometry(element) {
|
|
2493
2493
|
const width = Math.max(element.width, 0);
|
|
@@ -2620,7 +2620,7 @@ function toHexByte(value) {
|
|
|
2620
2620
|
return clamped.toString(16).padStart(2, "0");
|
|
2621
2621
|
}
|
|
2622
2622
|
function shiftHex(hex, factor, towardsWhite) {
|
|
2623
|
-
const channels =
|
|
2623
|
+
const channels = chunkMZ47MV52_js.hexToRgbChannels(hex);
|
|
2624
2624
|
if (!channels) {
|
|
2625
2625
|
return hex;
|
|
2626
2626
|
}
|
|
@@ -2646,7 +2646,7 @@ function buildCustomSubpathPaints(subpaths, hasFill, fillColor, fillOpacity) {
|
|
|
2646
2646
|
const fillOff = subpath.fillMode === "none" || !hasFill;
|
|
2647
2647
|
return {
|
|
2648
2648
|
d: subpath.d,
|
|
2649
|
-
fill: fillOff ? "none" :
|
|
2649
|
+
fill: fillOff ? "none" : chunkMZ47MV52_js.colorWithOpacity(adjustFillForMode(fillColor, subpath.fillMode), fillOpacity),
|
|
2650
2650
|
stroked: subpath.stroke !== false
|
|
2651
2651
|
};
|
|
2652
2652
|
});
|
|
@@ -2662,11 +2662,11 @@ function strokeContext(shapeStyle, strokePaint, strokeWidth, dashArray) {
|
|
|
2662
2662
|
strokePaint,
|
|
2663
2663
|
strokeWidth,
|
|
2664
2664
|
dashArray,
|
|
2665
|
-
lineCap:
|
|
2665
|
+
lineCap: chunkMZ47MV52_js.svgLineCap(shapeStyle?.lineCap),
|
|
2666
2666
|
lineJoin,
|
|
2667
2667
|
miterLimit,
|
|
2668
|
-
offsets:
|
|
2669
|
-
widths:
|
|
2668
|
+
offsets: chunkMZ47MV52_js.getCompoundLineOffsets(shapeStyle?.compoundLine, strokeWidth),
|
|
2669
|
+
widths: chunkMZ47MV52_js.getCompoundLineWidths(shapeStyle?.compoundLine, strokeWidth)
|
|
2670
2670
|
};
|
|
2671
2671
|
}
|
|
2672
2672
|
function strokeStrands(d, keyBase, ctx) {
|
|
@@ -2714,9 +2714,9 @@ function gradientDefs(gradient) {
|
|
|
2714
2714
|
}
|
|
2715
2715
|
function renderCustomGeometryVector(pathData, pathWidth, pathHeight, structuredPaths, shapeStyle, hasFill, fillColor, fillOpacity, strokePaint, strokeWidth, dashArray, animatesFill = false, gradient) {
|
|
2716
2716
|
const ctx = strokeContext(shapeStyle, strokePaint, strokeWidth, dashArray);
|
|
2717
|
-
const subpaths = structuredPaths && structuredPaths.length > 0 ?
|
|
2717
|
+
const subpaths = structuredPaths && structuredPaths.length > 0 ? chunkMZ47MV52_js.customGeometryPathsToSvgSubpaths(structuredPaths, pathWidth, pathHeight) : void 0;
|
|
2718
2718
|
const needsPerSubpath = subpaths !== void 0 && subpaths.some((sp) => sp.fillMode && sp.fillMode !== "norm" || sp.stroke === false);
|
|
2719
|
-
const gradientPaint = gradient ?
|
|
2719
|
+
const gradientPaint = gradient ? chunkMZ47MV52_js.svgGradientFillRef(gradient) : void 0;
|
|
2720
2720
|
const nodes = [];
|
|
2721
2721
|
if (subpaths && needsPerSubpath) {
|
|
2722
2722
|
const paints = buildCustomSubpathPaints(subpaths, hasFill, fillColor, fillOpacity);
|
|
@@ -2748,7 +2748,7 @@ function renderCustomGeometryVector(pathData, pathWidth, pathHeight, structuredP
|
|
|
2748
2748
|
"path",
|
|
2749
2749
|
{
|
|
2750
2750
|
d: pathData,
|
|
2751
|
-
fill: animatesFill ? "inherit" : gradientPaint ??
|
|
2751
|
+
fill: animatesFill ? "inherit" : gradientPaint ?? chunkMZ47MV52_js.colorWithOpacity(fillColor, fillOpacity),
|
|
2752
2752
|
stroke: "none",
|
|
2753
2753
|
vectorEffect: "non-scaling-stroke"
|
|
2754
2754
|
},
|
|
@@ -2774,14 +2774,14 @@ function renderCustomGeometryVector(pathData, pathWidth, pathHeight, structuredP
|
|
|
2774
2774
|
);
|
|
2775
2775
|
}
|
|
2776
2776
|
function renderVectorShape(element, hasFill, fillColor, strokeWidth, strokeColor, animatesFill, animatesStroke) {
|
|
2777
|
-
if (!
|
|
2777
|
+
if (!chunkMZ47MV52_js.hasShapeProperties(element)) {
|
|
2778
2778
|
return null;
|
|
2779
2779
|
}
|
|
2780
2780
|
const normalizedType = (element.shapeType || "").toLowerCase();
|
|
2781
|
-
const fillPaint = animatesFill ? "inherit" :
|
|
2782
|
-
const strokePaint = animatesStroke ? "inherit" :
|
|
2783
|
-
const dashType =
|
|
2784
|
-
const dashArray =
|
|
2781
|
+
const fillPaint = animatesFill ? "inherit" : chunkMZ47MV52_js.colorWithOpacity(fillColor, element.shapeStyle?.fillOpacity);
|
|
2782
|
+
const strokePaint = animatesStroke ? "inherit" : chunkMZ47MV52_js.colorWithOpacity(strokeColor, element.shapeStyle?.strokeOpacity);
|
|
2783
|
+
const dashType = chunkMZ47MV52_js.normalizeStrokeDashType(element.shapeStyle?.strokeDash);
|
|
2784
|
+
const dashArray = chunkMZ47MV52_js.getSvgStrokeDasharray(
|
|
2785
2785
|
dashType,
|
|
2786
2786
|
Math.max(strokeWidth, 1),
|
|
2787
2787
|
element.shapeStyle?.customDashSegments
|
|
@@ -2862,21 +2862,21 @@ function renderVectorShape(element, hasFill, fillColor, strokeWidth, strokeColor
|
|
|
2862
2862
|
// container's `background-image` is suppressed for custom geometry, so
|
|
2863
2863
|
// without this the shape fell back to the parser's representative solid
|
|
2864
2864
|
// and lost every fade (issue #132).
|
|
2865
|
-
|
|
2865
|
+
chunkMZ47MV52_js.buildSvgGradientDef(element.shapeStyle, element.id)
|
|
2866
2866
|
);
|
|
2867
2867
|
}
|
|
2868
|
-
if (
|
|
2868
|
+
if (chunkMZ47MV52_js.isCalloutShape(normalizedType)) {
|
|
2869
2869
|
const width = Math.max(element.width, 1);
|
|
2870
2870
|
const height = Math.max(element.height, 1);
|
|
2871
|
-
const geometry =
|
|
2871
|
+
const geometry = chunkMZ47MV52_js.getCalloutLeaderLineGeometry(
|
|
2872
2872
|
normalizedType,
|
|
2873
2873
|
width,
|
|
2874
2874
|
height,
|
|
2875
2875
|
element.shapeAdjustments
|
|
2876
2876
|
);
|
|
2877
2877
|
if (geometry && geometry.points.length >= 2) {
|
|
2878
|
-
const leaderPath =
|
|
2879
|
-
const bounds =
|
|
2878
|
+
const leaderPath = chunkMZ47MV52_js.buildCalloutLeaderLineSvgPath(geometry);
|
|
2879
|
+
const bounds = chunkMZ47MV52_js.getCalloutViewBoxBounds(width, height, geometry);
|
|
2880
2880
|
const lineStroke = Math.max(strokeWidth, 1);
|
|
2881
2881
|
const offsetLeft = bounds.minX;
|
|
2882
2882
|
const offsetTop = bounds.minY;
|
|
@@ -2939,10 +2939,10 @@ function renderVectorShape(element, hasFill, fillColor, strokeWidth, strokeColor
|
|
|
2939
2939
|
const endArrowW = element.shapeStyle?.connectorEndArrowWidth;
|
|
2940
2940
|
const endArrowL = element.shapeStyle?.connectorEndArrowLength;
|
|
2941
2941
|
const compoundLine = element.shapeStyle?.compoundLine;
|
|
2942
|
-
const connectorLineCap =
|
|
2942
|
+
const connectorLineCap = chunkMZ47MV52_js.svgLineCap(element.shapeStyle?.lineCap);
|
|
2943
2943
|
const hitTargetWidth = Math.max(strokeWidth * 3, 12);
|
|
2944
|
-
const offsets =
|
|
2945
|
-
const widths =
|
|
2944
|
+
const offsets = chunkMZ47MV52_js.getCompoundLineOffsets(compoundLine, strokeWidth);
|
|
2945
|
+
const widths = chunkMZ47MV52_js.getCompoundLineWidths(compoundLine, strokeWidth);
|
|
2946
2946
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
2947
2947
|
"svg",
|
|
2948
2948
|
{
|
|
@@ -3009,15 +3009,15 @@ function parseGradientFillCss(gradFill) {
|
|
|
3009
3009
|
}
|
|
3010
3010
|
const parsed = stops.map((gs) => {
|
|
3011
3011
|
const pos = Number.parseInt(String(gs["@_pos"] || "0"), 10) / 1e3;
|
|
3012
|
-
const color =
|
|
3013
|
-
const opacity =
|
|
3014
|
-
return { pos, color:
|
|
3012
|
+
const color = chunkMZ47MV52_js.parseDrawingColor(gs) ?? "#888888";
|
|
3013
|
+
const opacity = chunkMZ47MV52_js.parseDrawingColorOpacity(gs);
|
|
3014
|
+
return { pos, color: chunkMZ47MV52_js.colorWithOpacity(color, opacity) };
|
|
3015
3015
|
}).sort((a, b) => a.pos - b.pos);
|
|
3016
3016
|
const stopStrings = parsed.map((s) => `${s.color} ${s.pos.toFixed(1)}%`).join(", ");
|
|
3017
3017
|
const lin = gradFill["a:lin"];
|
|
3018
3018
|
if (lin) {
|
|
3019
3019
|
const angRaw = Number.parseInt(String(lin["@_ang"] || "0"), 10);
|
|
3020
|
-
const angleDeg = Math.round(
|
|
3020
|
+
const angleDeg = Math.round(chunkMZ47MV52_js.ooxmlGradientAngleToCssDegrees(angRaw / 6e4));
|
|
3021
3021
|
return `linear-gradient(${angleDeg}deg, ${stopStrings})`;
|
|
3022
3022
|
}
|
|
3023
3023
|
const path = gradFill["a:path"];
|
|
@@ -3052,8 +3052,8 @@ function parsePatternFillCss(pattFill) {
|
|
|
3052
3052
|
if (!pattFill) {
|
|
3053
3053
|
return void 0;
|
|
3054
3054
|
}
|
|
3055
|
-
const fgColor =
|
|
3056
|
-
const bgColor =
|
|
3055
|
+
const fgColor = chunkMZ47MV52_js.parseDrawingColor(pattFill["a:fgClr"]) ?? "#000000";
|
|
3056
|
+
const bgColor = chunkMZ47MV52_js.parseDrawingColor(pattFill["a:bgClr"]) ?? "#ffffff";
|
|
3057
3057
|
const preset = String(pattFill["@_prst"] || "ltDnDiag");
|
|
3058
3058
|
switch (preset) {
|
|
3059
3059
|
case "ltHorz":
|
|
@@ -3164,11 +3164,11 @@ function parseCellBorders(cellProperties) {
|
|
|
3164
3164
|
const prstDash = ln["a:prstDash"];
|
|
3165
3165
|
const dashVal = prstDash ? String(prstDash["@_val"] || "") : void 0;
|
|
3166
3166
|
const cssBorderStyle = ooxmlDashToCss(dashVal);
|
|
3167
|
-
const color =
|
|
3167
|
+
const color = chunkMZ47MV52_js.parseDrawingColor(ln["a:solidFill"]);
|
|
3168
3168
|
if (color) {
|
|
3169
|
-
const opacity =
|
|
3169
|
+
const opacity = chunkMZ47MV52_js.parseDrawingColorOpacity(ln["a:solidFill"]);
|
|
3170
3170
|
const key = `${edge.prefix}`;
|
|
3171
|
-
borderStyle[key] = `${widthPx}px ${cssBorderStyle} ${
|
|
3171
|
+
borderStyle[key] = `${widthPx}px ${cssBorderStyle} ${chunkMZ47MV52_js.colorWithOpacity(color, opacity)}`;
|
|
3172
3172
|
}
|
|
3173
3173
|
}
|
|
3174
3174
|
return borderStyle;
|
|
@@ -3181,7 +3181,7 @@ function parseCellTextEffects(runProps) {
|
|
|
3181
3181
|
const textShadowParts = [];
|
|
3182
3182
|
const outerShdw = effectLst["a:outerShdw"];
|
|
3183
3183
|
if (outerShdw) {
|
|
3184
|
-
const shdwColor =
|
|
3184
|
+
const shdwColor = chunkMZ47MV52_js.parseDrawingColor(outerShdw);
|
|
3185
3185
|
if (shdwColor) {
|
|
3186
3186
|
const blurRad = Number.parseInt(String(outerShdw["@_blurRad"] || "0"), 10);
|
|
3187
3187
|
const blurPx = blurRad > 0 ? Math.round(blurRad / 12700) : 0;
|
|
@@ -3199,7 +3199,7 @@ function parseCellTextEffects(runProps) {
|
|
|
3199
3199
|
}
|
|
3200
3200
|
const glow = effectLst["a:glow"];
|
|
3201
3201
|
if (glow) {
|
|
3202
|
-
const glowColor =
|
|
3202
|
+
const glowColor = chunkMZ47MV52_js.parseDrawingColor(glow);
|
|
3203
3203
|
if (glowColor) {
|
|
3204
3204
|
const glowRad = Number.parseInt(String(glow["@_rad"] || "0"), 10);
|
|
3205
3205
|
const glowPx = glowRad > 0 ? Math.round(glowRad / 12700) : 2;
|
|
@@ -3278,10 +3278,10 @@ function extractTableCellStyle(cellXml, fallbackStyle, schemeColorOverrides) {
|
|
|
3278
3278
|
if (runProps?.["@_u"] !== void 0) {
|
|
3279
3279
|
cellStyle.textDecorationLine = runProps["@_u"] === "sng" ? "underline" : "none";
|
|
3280
3280
|
}
|
|
3281
|
-
const runColor =
|
|
3281
|
+
const runColor = chunkMZ47MV52_js.parseDrawingColor(runProps?.["a:solidFill"], schemeColorOverrides) || chunkMZ47MV52_js.parseDrawingColor(runProps?.["a:highlight"], schemeColorOverrides);
|
|
3282
3282
|
if (runColor) {
|
|
3283
|
-
const opacity =
|
|
3284
|
-
cellStyle.color =
|
|
3283
|
+
const opacity = chunkMZ47MV52_js.parseDrawingColorOpacity(runProps?.["a:solidFill"]);
|
|
3284
|
+
cellStyle.color = chunkMZ47MV52_js.colorWithOpacity(runColor, opacity);
|
|
3285
3285
|
}
|
|
3286
3286
|
const fontFamily = runProps?.["a:latin"]?.["@_typeface"] || runProps?.["a:ea"]?.["@_typeface"] || runProps?.["a:cs"]?.["@_typeface"];
|
|
3287
3287
|
if (fontFamily) {
|
|
@@ -3291,15 +3291,15 @@ function extractTableCellStyle(cellXml, fallbackStyle, schemeColorOverrides) {
|
|
|
3291
3291
|
cellStyle.textAlign = parseParagraphAlignment(paragraphProperties["@_algn"]);
|
|
3292
3292
|
}
|
|
3293
3293
|
const cellProperties = cellXml["a:tcPr"];
|
|
3294
|
-
const cellFill =
|
|
3294
|
+
const cellFill = chunkMZ47MV52_js.parseDrawingColor(
|
|
3295
3295
|
cellProperties?.["a:solidFill"],
|
|
3296
3296
|
schemeColorOverrides
|
|
3297
3297
|
);
|
|
3298
3298
|
if (cellFill) {
|
|
3299
|
-
const opacity =
|
|
3299
|
+
const opacity = chunkMZ47MV52_js.parseDrawingColorOpacity(
|
|
3300
3300
|
cellProperties?.["a:solidFill"]
|
|
3301
3301
|
);
|
|
3302
|
-
cellStyle.backgroundColor =
|
|
3302
|
+
cellStyle.backgroundColor = chunkMZ47MV52_js.colorWithOpacity(cellFill, opacity);
|
|
3303
3303
|
} else {
|
|
3304
3304
|
const gradCss = parseGradientFillCss(cellProperties?.["a:gradFill"]);
|
|
3305
3305
|
if (gradCss) {
|
|
@@ -3314,16 +3314,16 @@ function extractTableCellStyle(cellXml, fallbackStyle, schemeColorOverrides) {
|
|
|
3314
3314
|
const edgeBorders = parseCellBorders(cellProperties);
|
|
3315
3315
|
Object.assign(cellStyle, edgeBorders);
|
|
3316
3316
|
if (!cellStyle.borderLeftColor && !cellStyle.borderRightColor && !cellStyle.borderTopColor && !cellStyle.borderBottomColor) {
|
|
3317
|
-
const borderColor =
|
|
3317
|
+
const borderColor = chunkMZ47MV52_js.parseDrawingColor(
|
|
3318
3318
|
cellProperties?.["a:lnL"]?.["a:solidFill"],
|
|
3319
3319
|
schemeColorOverrides
|
|
3320
|
-
) ||
|
|
3320
|
+
) || chunkMZ47MV52_js.parseDrawingColor(
|
|
3321
3321
|
cellProperties?.["a:lnR"]?.["a:solidFill"],
|
|
3322
3322
|
schemeColorOverrides
|
|
3323
|
-
) ||
|
|
3323
|
+
) || chunkMZ47MV52_js.parseDrawingColor(
|
|
3324
3324
|
cellProperties?.["a:lnT"]?.["a:solidFill"],
|
|
3325
3325
|
schemeColorOverrides
|
|
3326
|
-
) ||
|
|
3326
|
+
) || chunkMZ47MV52_js.parseDrawingColor(
|
|
3327
3327
|
cellProperties?.["a:lnB"]?.["a:solidFill"],
|
|
3328
3328
|
schemeColorOverrides
|
|
3329
3329
|
);
|
|
@@ -3402,10 +3402,10 @@ function resolveTableStyleFillColor(fill, colorScheme) {
|
|
|
3402
3402
|
}
|
|
3403
3403
|
let color = base;
|
|
3404
3404
|
if (fill.tint !== void 0 && fill.tint > 0) {
|
|
3405
|
-
color =
|
|
3405
|
+
color = chunkMZ47MV52_js.tintColor2(color, fill.tint / 1e5);
|
|
3406
3406
|
}
|
|
3407
3407
|
if (fill.shade !== void 0 && fill.shade > 0) {
|
|
3408
|
-
color =
|
|
3408
|
+
color = chunkMZ47MV52_js.shadeColor2(color, 1 - fill.shade / 1e5);
|
|
3409
3409
|
}
|
|
3410
3410
|
return color;
|
|
3411
3411
|
}
|
|
@@ -3430,7 +3430,7 @@ function applyTableStyleText(text, colorScheme, style, fontScheme) {
|
|
|
3430
3430
|
style.fontFamily = text.fontFace;
|
|
3431
3431
|
applied = true;
|
|
3432
3432
|
} else {
|
|
3433
|
-
const refFont =
|
|
3433
|
+
const refFont = chunkMZ47MV52_js.resolveFontRefIdx(text.fontRefIdx, fontScheme);
|
|
3434
3434
|
if (refFont) {
|
|
3435
3435
|
style.fontFamily = refFont;
|
|
3436
3436
|
applied = true;
|
|
@@ -3441,10 +3441,10 @@ function applyTableStyleText(text, colorScheme, style, fontScheme) {
|
|
|
3441
3441
|
if (base) {
|
|
3442
3442
|
let color = base;
|
|
3443
3443
|
if (text.fontTint !== void 0 && text.fontTint > 0) {
|
|
3444
|
-
color =
|
|
3444
|
+
color = chunkMZ47MV52_js.tintColor2(color, text.fontTint / 1e5);
|
|
3445
3445
|
}
|
|
3446
3446
|
if (text.fontShade !== void 0 && text.fontShade > 0) {
|
|
3447
|
-
color =
|
|
3447
|
+
color = chunkMZ47MV52_js.shadeColor2(color, 1 - text.fontShade / 1e5);
|
|
3448
3448
|
}
|
|
3449
3449
|
style.color = color;
|
|
3450
3450
|
applied = true;
|
|
@@ -3633,7 +3633,7 @@ function parseTableElementData(element, fallbackTextStyle) {
|
|
|
3633
3633
|
};
|
|
3634
3634
|
}
|
|
3635
3635
|
function getCellDiagonalBorders2(style, tableData, pos, styleCtx) {
|
|
3636
|
-
return
|
|
3636
|
+
return chunkMZ47MV52_js.getCellDiagonalBorders(style, tableData, pos, {
|
|
3637
3637
|
tableStyleMap: styleCtx?.tableStyleMap,
|
|
3638
3638
|
colorScheme: styleCtx?.theme?.colorScheme,
|
|
3639
3639
|
fontScheme: styleCtx?.theme?.fontScheme
|
|
@@ -3781,9 +3781,9 @@ function cellStyleToCss(style) {
|
|
|
3781
3781
|
if (style.gradientFillCss) {
|
|
3782
3782
|
css.background = style.gradientFillCss;
|
|
3783
3783
|
} else if (style.fillMode === "pattern" && style.patternFillPreset) {
|
|
3784
|
-
const fg =
|
|
3785
|
-
const bg =
|
|
3786
|
-
const svgPattern =
|
|
3784
|
+
const fg = chunkMZ47MV52_js.normalizeHexColor(style.patternFillForeground, "#000000");
|
|
3785
|
+
const bg = chunkMZ47MV52_js.normalizeHexColor(style.patternFillBackground, "#ffffff");
|
|
3786
|
+
const svgPattern = chunkMZ47MV52_js.getPatternSvg(style.patternFillPreset, fg, bg);
|
|
3787
3787
|
if (svgPattern) {
|
|
3788
3788
|
const encoded = encodeURIComponent(svgPattern);
|
|
3789
3789
|
css.backgroundImage = `url("data:image/svg+xml,${encoded}")`;
|
|
@@ -3859,7 +3859,7 @@ function cellStyleToCss(style) {
|
|
|
3859
3859
|
if (edge.width || edge.color) {
|
|
3860
3860
|
const w = edge.width ?? 1;
|
|
3861
3861
|
const c = edge.color ?? style.borderColor ?? "#000000";
|
|
3862
|
-
const s =
|
|
3862
|
+
const s = chunkMZ47MV52_js.ooxmlDashToCssBorderStyle(edge.dash);
|
|
3863
3863
|
css[edge.prefix] = `${w}px ${s} ${c}`;
|
|
3864
3864
|
}
|
|
3865
3865
|
}
|
|
@@ -3890,7 +3890,7 @@ function cellStyleToCss(style) {
|
|
|
3890
3890
|
css.textShadow = textShadowParts.join(", ");
|
|
3891
3891
|
}
|
|
3892
3892
|
if (style.cell3D) {
|
|
3893
|
-
Object.assign(css,
|
|
3893
|
+
Object.assign(css, chunkMZ47MV52_js.cell3DBevelCss(style.cell3D));
|
|
3894
3894
|
}
|
|
3895
3895
|
return css;
|
|
3896
3896
|
}
|
|
@@ -3904,7 +3904,7 @@ function TableResizeOverlay({
|
|
|
3904
3904
|
const containerRef = React6.useRef(null);
|
|
3905
3905
|
const [rowBounds, setRowBounds] = React6.useState([]);
|
|
3906
3906
|
const dragRef = React6.useRef(null);
|
|
3907
|
-
const colBoundaries = React6.useMemo(() =>
|
|
3907
|
+
const colBoundaries = React6.useMemo(() => chunkMZ47MV52_js.computeColumnBoundaries(columnWidths), [columnWidths]);
|
|
3908
3908
|
const measureRows = React6.useCallback(() => {
|
|
3909
3909
|
const container = containerRef.current;
|
|
3910
3910
|
if (!container) {
|
|
@@ -3951,11 +3951,11 @@ function TableResizeOverlay({
|
|
|
3951
3951
|
const rect = containerRef.current.getBoundingClientRect();
|
|
3952
3952
|
if (drag.type === "col" && drag.initialWidths && onResizeColumns) {
|
|
3953
3953
|
const deltaProp = (e.clientX - drag.startPos) / rect.width;
|
|
3954
|
-
onResizeColumns(
|
|
3954
|
+
onResizeColumns(chunkMZ47MV52_js.computeResizedColumnWidths(drag.initialWidths, drag.index, deltaProp));
|
|
3955
3955
|
} else if (drag.type === "row" && onResizeRow) {
|
|
3956
3956
|
const deltaY = e.clientY - drag.startPos;
|
|
3957
|
-
const newHeight =
|
|
3958
|
-
drag.initialRowHeight ??
|
|
3957
|
+
const newHeight = chunkMZ47MV52_js.computeResizedRowHeight(
|
|
3958
|
+
drag.initialRowHeight ?? chunkMZ47MV52_js.DEFAULT_ROW_HEIGHT,
|
|
3959
3959
|
deltaY
|
|
3960
3960
|
);
|
|
3961
3961
|
onResizeRow(drag.index, newHeight);
|
|
@@ -3993,7 +3993,7 @@ function TableResizeOverlay({
|
|
|
3993
3993
|
e.stopPropagation();
|
|
3994
3994
|
const table = containerRef.current?.querySelector("table");
|
|
3995
3995
|
const tr = table?.querySelectorAll("tbody > tr")[index];
|
|
3996
|
-
const actualHeight = tr?.offsetHeight ??
|
|
3996
|
+
const actualHeight = tr?.offsetHeight ?? chunkMZ47MV52_js.DEFAULT_ROW_HEIGHT;
|
|
3997
3997
|
document.body.style.cursor = "row-resize";
|
|
3998
3998
|
document.body.style.userSelect = "none";
|
|
3999
3999
|
dragRef.current = {
|
|
@@ -4041,7 +4041,7 @@ function renderTableFromTableData(element, textStyle, options) {
|
|
|
4041
4041
|
}
|
|
4042
4042
|
const first = selectedCell.selectedCells[0];
|
|
4043
4043
|
const last = selectedCell.selectedCells[selectedCell.selectedCells.length - 1];
|
|
4044
|
-
return
|
|
4044
|
+
return chunkMZ47MV52_js.computeSelectionRect(first.row, first.col, last.row, last.col, tableData);
|
|
4045
4045
|
})();
|
|
4046
4046
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
4047
4047
|
TableResizeOverlay,
|
|
@@ -4061,7 +4061,7 @@ function renderTableFromTableData(element, textStyle, options) {
|
|
|
4061
4061
|
"table",
|
|
4062
4062
|
{
|
|
4063
4063
|
className: "w-full h-full border-collapse table-fixed",
|
|
4064
|
-
style: { fontFamily:
|
|
4064
|
+
style: { fontFamily: chunkMZ47MV52_js.DEFAULT_FONT_FAMILY },
|
|
4065
4065
|
children: [
|
|
4066
4066
|
tableData.columnWidths.length > 0 && /* @__PURE__ */ jsxRuntime.jsx("colgroup", { children: tableData.columnWidths.map((w, ci) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
4067
4067
|
"col",
|
|
@@ -4079,7 +4079,7 @@ function renderTableFromTableData(element, textStyle, options) {
|
|
|
4079
4079
|
return null;
|
|
4080
4080
|
}
|
|
4081
4081
|
const isCellSelected = selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex;
|
|
4082
|
-
const isInMultiSelection =
|
|
4082
|
+
const isInMultiSelection = chunkMZ47MV52_js.isCellInRect(rowIndex, cellIndex, selectionRect);
|
|
4083
4083
|
const isCellEditing = isCellSelected && selectedCell?.isEditing;
|
|
4084
4084
|
const diag = getCellDiagonalBorders2(
|
|
4085
4085
|
cell.style,
|
|
@@ -4109,7 +4109,7 @@ function renderTableFromTableData(element, textStyle, options) {
|
|
|
4109
4109
|
}
|
|
4110
4110
|
event.stopPropagation();
|
|
4111
4111
|
if (event.shiftKey && selectedCell) {
|
|
4112
|
-
const rect =
|
|
4112
|
+
const rect = chunkMZ47MV52_js.computeSelectionRect(
|
|
4113
4113
|
selectedCell.rowIndex,
|
|
4114
4114
|
selectedCell.columnIndex,
|
|
4115
4115
|
rowIndex,
|
|
@@ -4119,7 +4119,7 @@ function renderTableFromTableData(element, textStyle, options) {
|
|
|
4119
4119
|
options?.onSelectCell?.({
|
|
4120
4120
|
rowIndex: selectedCell.rowIndex,
|
|
4121
4121
|
columnIndex: selectedCell.columnIndex,
|
|
4122
|
-
selectedCells:
|
|
4122
|
+
selectedCells: chunkMZ47MV52_js.rectToCells(rect)
|
|
4123
4123
|
});
|
|
4124
4124
|
} else {
|
|
4125
4125
|
options?.onSelectCell?.({
|
|
@@ -4183,7 +4183,7 @@ function renderTableElement(element, textStyle, options) {
|
|
|
4183
4183
|
if (tableEl2.tableData && tableEl2.tableData.rows.length > 0) {
|
|
4184
4184
|
return renderTableFromTableData(tableEl2, textStyle, options);
|
|
4185
4185
|
}
|
|
4186
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children:
|
|
4186
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunkDVZF4ARG_js.translationsEn["pptx.table.title"] });
|
|
4187
4187
|
}
|
|
4188
4188
|
const selectedCell = options?.selectedCell || null;
|
|
4189
4189
|
const isEditable = Boolean(options?.editable);
|
|
@@ -4198,7 +4198,7 @@ function renderTableElement(element, textStyle, options) {
|
|
|
4198
4198
|
}
|
|
4199
4199
|
const first = selectedCell.selectedCells[0];
|
|
4200
4200
|
const last = selectedCell.selectedCells[selectedCell.selectedCells.length - 1];
|
|
4201
|
-
return
|
|
4201
|
+
return chunkMZ47MV52_js.computeSelectionRect(first.row, first.col, last.row, last.col, tableEl.tableData);
|
|
4202
4202
|
})();
|
|
4203
4203
|
const schemeOverrides = options?.styleCtx?.theme?.colorScheme ? options.styleCtx.theme.colorScheme : void 0;
|
|
4204
4204
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -4219,7 +4219,7 @@ function renderTableElement(element, textStyle, options) {
|
|
|
4219
4219
|
"table",
|
|
4220
4220
|
{
|
|
4221
4221
|
className: "w-full h-full border-collapse table-fixed",
|
|
4222
|
-
style: { fontFamily:
|
|
4222
|
+
style: { fontFamily: chunkMZ47MV52_js.DEFAULT_FONT_FAMILY },
|
|
4223
4223
|
children: [
|
|
4224
4224
|
parsedTable.columnPercentages.length > 0 ? /* @__PURE__ */ jsxRuntime.jsx("colgroup", { children: parsedTable.columnPercentages.map((percentage, columnIndex) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
4225
4225
|
"col",
|
|
@@ -4280,7 +4280,7 @@ function renderTableElement(element, textStyle, options) {
|
|
|
4280
4280
|
"border px-1 py-0.5 align-top",
|
|
4281
4281
|
isEditable && hasCellSelectionHandler ? "border-blue-200/70 cursor-cell" : "border-white/30",
|
|
4282
4282
|
selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex ? "ring-1 ring-inset ring-blue-500" : null,
|
|
4283
|
-
|
|
4283
|
+
chunkMZ47MV52_js.isCellInRect(rowIndex, cellIndex, xmlSelectionRect) && !(selectedCell?.rowIndex === rowIndex && selectedCell?.columnIndex === cellIndex) ? "bg-blue-500/15 ring-1 ring-inset ring-blue-400/50" : null
|
|
4284
4284
|
),
|
|
4285
4285
|
colSpan,
|
|
4286
4286
|
rowSpan: rSpan,
|
|
@@ -4291,7 +4291,7 @@ function renderTableElement(element, textStyle, options) {
|
|
|
4291
4291
|
}
|
|
4292
4292
|
event.stopPropagation();
|
|
4293
4293
|
if (event.shiftKey && selectedCell && tableEl.tableData) {
|
|
4294
|
-
const rect =
|
|
4294
|
+
const rect = chunkMZ47MV52_js.computeSelectionRect(
|
|
4295
4295
|
selectedCell.rowIndex,
|
|
4296
4296
|
selectedCell.columnIndex,
|
|
4297
4297
|
rowIndex,
|
|
@@ -4301,7 +4301,7 @@ function renderTableElement(element, textStyle, options) {
|
|
|
4301
4301
|
options?.onSelectCell?.({
|
|
4302
4302
|
rowIndex: selectedCell.rowIndex,
|
|
4303
4303
|
columnIndex: selectedCell.columnIndex,
|
|
4304
|
-
selectedCells:
|
|
4304
|
+
selectedCells: chunkMZ47MV52_js.rectToCells(rect)
|
|
4305
4305
|
});
|
|
4306
4306
|
} else {
|
|
4307
4307
|
options?.onSelectCell?.({
|
|
@@ -4358,24 +4358,24 @@ function renderTableElement(element, textStyle, options) {
|
|
|
4358
4358
|
}
|
|
4359
4359
|
var LEGEND_ITEM_WIDTH = 80;
|
|
4360
4360
|
function partAttrs(part) {
|
|
4361
|
-
return part ?
|
|
4361
|
+
return part ? chunkMZ47MV52_js.chartPartToAttrs(part) : void 0;
|
|
4362
4362
|
}
|
|
4363
4363
|
function resolveReactPalette(chartData) {
|
|
4364
4364
|
if (chartData.colorPalette && chartData.colorPalette.length > 0) {
|
|
4365
4365
|
return chartData.colorPalette;
|
|
4366
4366
|
}
|
|
4367
|
-
return [...
|
|
4367
|
+
return [...chunkMZ47MV52_js.getChartStylePalette(chartData.style?.styleId)];
|
|
4368
4368
|
}
|
|
4369
4369
|
function buildReactChartViewModel(element) {
|
|
4370
4370
|
if (element.type !== "chart" || !element.chartData) {
|
|
4371
|
-
return
|
|
4371
|
+
return chunkMZ47MV52_js.buildChartViewModel(element);
|
|
4372
4372
|
}
|
|
4373
4373
|
const palette = resolveReactPalette(element.chartData);
|
|
4374
4374
|
const themedElement = {
|
|
4375
4375
|
...element,
|
|
4376
4376
|
chartData: { ...element.chartData, colorPalette: palette }
|
|
4377
4377
|
};
|
|
4378
|
-
return
|
|
4378
|
+
return chunkMZ47MV52_js.buildChartViewModel(themedElement);
|
|
4379
4379
|
}
|
|
4380
4380
|
function renderPrimitive(prim, key) {
|
|
4381
4381
|
switch (prim.kind) {
|
|
@@ -4764,7 +4764,7 @@ function renderMapChart(element, chartData, categoryLabels) {
|
|
|
4764
4764
|
const unmatchedRows = [];
|
|
4765
4765
|
categories.forEach((cat, i) => {
|
|
4766
4766
|
const value = values[i] ?? 0;
|
|
4767
|
-
const code =
|
|
4767
|
+
const code = chunkMZ47MV52_js.resolveRegionCode(cat);
|
|
4768
4768
|
if (code) {
|
|
4769
4769
|
regionValueMap.set(code, { value, label: cat });
|
|
4770
4770
|
} else {
|
|
@@ -4802,8 +4802,8 @@ function renderMapChart(element, chartData, categoryLabels) {
|
|
|
4802
4802
|
let fill = "#e2e8f0";
|
|
4803
4803
|
let dataLabel = null;
|
|
4804
4804
|
if (entry) {
|
|
4805
|
-
const t =
|
|
4806
|
-
fill =
|
|
4805
|
+
const t = chunkMZ47MV52_js.normalizeValue(entry.value, minVal, maxVal);
|
|
4806
|
+
fill = chunkMZ47MV52_js.sequentialColorScale(t);
|
|
4807
4807
|
dataLabel = /* @__PURE__ */ jsxRuntime.jsx(
|
|
4808
4808
|
"text",
|
|
4809
4809
|
{
|
|
@@ -4814,7 +4814,7 @@ function renderMapChart(element, chartData, categoryLabels) {
|
|
|
4814
4814
|
fontWeight: 600,
|
|
4815
4815
|
fill: "#1e293b",
|
|
4816
4816
|
style: { pointerEvents: "none" },
|
|
4817
|
-
children:
|
|
4817
|
+
children: chunkMZ47MV52_js.formatAxisValue(entry.value)
|
|
4818
4818
|
},
|
|
4819
4819
|
`${element.id}-map-dl-${region.code}`
|
|
4820
4820
|
);
|
|
@@ -4832,7 +4832,7 @@ function renderMapChart(element, chartData, categoryLabels) {
|
|
|
4832
4832
|
opacity: 0.9,
|
|
4833
4833
|
children: /* @__PURE__ */ jsxRuntime.jsxs("title", { children: [
|
|
4834
4834
|
region.name,
|
|
4835
|
-
entry ? `: ${
|
|
4835
|
+
entry ? `: ${chunkMZ47MV52_js.formatAxisValue(entry.value)}` : ""
|
|
4836
4836
|
] })
|
|
4837
4837
|
}
|
|
4838
4838
|
),
|
|
@@ -4870,7 +4870,7 @@ function renderMapChart(element, chartData, categoryLabels) {
|
|
|
4870
4870
|
fontSize: 7,
|
|
4871
4871
|
fill: "#64748b",
|
|
4872
4872
|
textAnchor: "middle",
|
|
4873
|
-
children:
|
|
4873
|
+
children: chunkMZ47MV52_js.formatAxisValue(minVal)
|
|
4874
4874
|
},
|
|
4875
4875
|
`${element.id}-map-legend-min`
|
|
4876
4876
|
),
|
|
@@ -4882,7 +4882,7 @@ function renderMapChart(element, chartData, categoryLabels) {
|
|
|
4882
4882
|
fontSize: 7,
|
|
4883
4883
|
fill: "#64748b",
|
|
4884
4884
|
textAnchor: "middle",
|
|
4885
|
-
children:
|
|
4885
|
+
children: chunkMZ47MV52_js.formatAxisValue(maxVal)
|
|
4886
4886
|
},
|
|
4887
4887
|
`${element.id}-map-legend-max`
|
|
4888
4888
|
)
|
|
@@ -4901,7 +4901,7 @@ function renderMapChart(element, chartData, categoryLabels) {
|
|
|
4901
4901
|
textAnchor: "middle",
|
|
4902
4902
|
fontSize: 7,
|
|
4903
4903
|
fill: "#94a3b8",
|
|
4904
|
-
children:
|
|
4904
|
+
children: chunkDVZF4ARG_js.translationsEn["pptx.chart.additionalRegionsFallback"]
|
|
4905
4905
|
},
|
|
4906
4906
|
`${element.id}-map-ft-hdr`
|
|
4907
4907
|
)
|
|
@@ -4948,7 +4948,7 @@ function renderMapChart(element, chartData, categoryLabels) {
|
|
|
4948
4948
|
y,
|
|
4949
4949
|
fontSize,
|
|
4950
4950
|
fill: "#475569",
|
|
4951
|
-
children:
|
|
4951
|
+
children: chunkMZ47MV52_js.formatAxisValue(row.value)
|
|
4952
4952
|
},
|
|
4953
4953
|
`${element.id}-map-ft-val-${i}`
|
|
4954
4954
|
)
|
|
@@ -5019,7 +5019,7 @@ function renderStackedBarChart(element, _chartData, _categoryLabels) {
|
|
|
5019
5019
|
|
|
5020
5020
|
// src/viewer/utils/chart-overlay-utils.ts
|
|
5021
5021
|
function sColor(series, idx) {
|
|
5022
|
-
return
|
|
5022
|
+
return chunkMZ47MV52_js.seriesColor(series, idx);
|
|
5023
5023
|
}
|
|
5024
5024
|
function valToY(val, range, topY, bottomY) {
|
|
5025
5025
|
const usable = bottomY - topY;
|
|
@@ -5558,7 +5558,7 @@ function renderLegend(id, style, series, layout, colorPalette) {
|
|
|
5558
5558
|
width: 10,
|
|
5559
5559
|
height: 10,
|
|
5560
5560
|
rx: 2,
|
|
5561
|
-
fill:
|
|
5561
|
+
fill: chunkMZ47MV52_js.seriesColor(s, i, style?.styleId, colorPalette)
|
|
5562
5562
|
},
|
|
5563
5563
|
`${id}-leg-r-${i}`
|
|
5564
5564
|
)
|
|
@@ -5582,7 +5582,7 @@ function renderLegend(id, style, series, layout, colorPalette) {
|
|
|
5582
5582
|
width: 10,
|
|
5583
5583
|
height: 10,
|
|
5584
5584
|
rx: 2,
|
|
5585
|
-
fill:
|
|
5585
|
+
fill: chunkMZ47MV52_js.seriesColor(s, i, style?.styleId, colorPalette)
|
|
5586
5586
|
}
|
|
5587
5587
|
),
|
|
5588
5588
|
/* @__PURE__ */ jsxRuntime.jsx("text", { x: x + 14, y: cy + 8, fontSize: 9, fill: "#475569", children: s.name || `Series ${i + 1}` })
|
|
@@ -5595,9 +5595,9 @@ function renderGridlines(id, style, range, layout) {
|
|
|
5595
5595
|
}
|
|
5596
5596
|
const lines = [];
|
|
5597
5597
|
if (range.logScale && range.logBase) {
|
|
5598
|
-
const ticks =
|
|
5598
|
+
const ticks = chunkMZ47MV52_js.generateLogTicks(range);
|
|
5599
5599
|
ticks.forEach((tickVal, i) => {
|
|
5600
|
-
const y =
|
|
5600
|
+
const y = chunkMZ47MV52_js.valueToY(tickVal, range, layout.plotTop, layout.plotBottom);
|
|
5601
5601
|
lines.push(
|
|
5602
5602
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5603
5603
|
"line",
|
|
@@ -5618,7 +5618,7 @@ function renderGridlines(id, style, range, layout) {
|
|
|
5618
5618
|
const steps = 4;
|
|
5619
5619
|
for (let i = 0; i <= steps; i++) {
|
|
5620
5620
|
const val = range.min + range.span * i / steps;
|
|
5621
|
-
const y =
|
|
5621
|
+
const y = chunkMZ47MV52_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
|
|
5622
5622
|
lines.push(
|
|
5623
5623
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5624
5624
|
"line",
|
|
@@ -5642,9 +5642,9 @@ function renderValueAxis(id, range, layout, axisFormatting) {
|
|
|
5642
5642
|
const labels = [];
|
|
5643
5643
|
const hasDisplayUnits = Boolean(axisFormatting?.displayUnits);
|
|
5644
5644
|
if (range.logScale && range.logBase) {
|
|
5645
|
-
const ticks =
|
|
5645
|
+
const ticks = chunkMZ47MV52_js.generateLogTicks(range);
|
|
5646
5646
|
ticks.forEach((tickVal, i) => {
|
|
5647
|
-
const y =
|
|
5647
|
+
const y = chunkMZ47MV52_js.valueToY(tickVal, range, layout.plotTop, layout.plotBottom);
|
|
5648
5648
|
labels.push(
|
|
5649
5649
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5650
5650
|
"text",
|
|
@@ -5654,7 +5654,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
|
|
|
5654
5654
|
textAnchor: "end",
|
|
5655
5655
|
fontSize: 8,
|
|
5656
5656
|
fill: "#64748b",
|
|
5657
|
-
children: hasDisplayUnits ?
|
|
5657
|
+
children: hasDisplayUnits ? chunkMZ47MV52_js.formatAxisValueWithUnits(tickVal, axisFormatting) : chunkMZ47MV52_js.formatAxisValue(tickVal)
|
|
5658
5658
|
},
|
|
5659
5659
|
`${id}-vaxis-log-${i}`
|
|
5660
5660
|
)
|
|
@@ -5664,7 +5664,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
|
|
|
5664
5664
|
const steps = 4;
|
|
5665
5665
|
for (let i = 0; i <= steps; i++) {
|
|
5666
5666
|
const val = range.min + range.span * i / steps;
|
|
5667
|
-
const y =
|
|
5667
|
+
const y = chunkMZ47MV52_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
|
|
5668
5668
|
labels.push(
|
|
5669
5669
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5670
5670
|
"text",
|
|
@@ -5674,7 +5674,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
|
|
|
5674
5674
|
textAnchor: "end",
|
|
5675
5675
|
fontSize: 8,
|
|
5676
5676
|
fill: "#64748b",
|
|
5677
|
-
children: hasDisplayUnits ?
|
|
5677
|
+
children: hasDisplayUnits ? chunkMZ47MV52_js.formatAxisValueWithUnits(val, axisFormatting) : chunkMZ47MV52_js.formatAxisValue(val)
|
|
5678
5678
|
},
|
|
5679
5679
|
`${id}-vaxis-${i}`
|
|
5680
5680
|
)
|
|
@@ -5682,7 +5682,7 @@ function renderValueAxis(id, range, layout, axisFormatting) {
|
|
|
5682
5682
|
}
|
|
5683
5683
|
}
|
|
5684
5684
|
if (hasDisplayUnits) {
|
|
5685
|
-
const unitLabel =
|
|
5685
|
+
const unitLabel = chunkMZ47MV52_js.getDisplayUnitLabel(
|
|
5686
5686
|
axisFormatting.displayUnits,
|
|
5687
5687
|
axisFormatting.displayUnitsLabel
|
|
5688
5688
|
);
|
|
@@ -5757,7 +5757,7 @@ function renderZeroLine(id, range, layout) {
|
|
|
5757
5757
|
if (range.min >= 0) {
|
|
5758
5758
|
return null;
|
|
5759
5759
|
}
|
|
5760
|
-
const y =
|
|
5760
|
+
const y = chunkMZ47MV52_js.valueToY(0, range, layout.plotTop, layout.plotBottom);
|
|
5761
5761
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
5762
5762
|
"line",
|
|
5763
5763
|
{
|
|
@@ -5781,7 +5781,7 @@ function renderSecondaryValueAxis(id, range, layout, axisFormatting) {
|
|
|
5781
5781
|
const hasDisplayUnits = Boolean(axisFormatting?.displayUnits);
|
|
5782
5782
|
for (let i = 0; i <= steps; i++) {
|
|
5783
5783
|
const val = range.min + range.span * i / steps;
|
|
5784
|
-
const y =
|
|
5784
|
+
const y = chunkMZ47MV52_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
|
|
5785
5785
|
labels.push(
|
|
5786
5786
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5787
5787
|
"text",
|
|
@@ -5793,7 +5793,7 @@ function renderSecondaryValueAxis(id, range, layout, axisFormatting) {
|
|
|
5793
5793
|
fontFamily,
|
|
5794
5794
|
fontWeight,
|
|
5795
5795
|
fill: fontColor,
|
|
5796
|
-
children: hasDisplayUnits ?
|
|
5796
|
+
children: hasDisplayUnits ? chunkMZ47MV52_js.formatAxisValueWithUnits(val, axisFormatting) : chunkMZ47MV52_js.formatAxisValue(val)
|
|
5797
5797
|
},
|
|
5798
5798
|
`${id}-sec-vaxis-${i}`
|
|
5799
5799
|
)
|
|
@@ -5817,7 +5817,7 @@ function renderSecondaryValueAxis(id, range, layout, axisFormatting) {
|
|
|
5817
5817
|
);
|
|
5818
5818
|
}
|
|
5819
5819
|
if (hasDisplayUnits) {
|
|
5820
|
-
const unitLabel =
|
|
5820
|
+
const unitLabel = chunkMZ47MV52_js.getDisplayUnitLabel(
|
|
5821
5821
|
axisFormatting.displayUnits,
|
|
5822
5822
|
axisFormatting.displayUnitsLabel
|
|
5823
5823
|
);
|
|
@@ -5848,7 +5848,7 @@ function renderSecondaryAxisTicks(id, range, layout) {
|
|
|
5848
5848
|
const ticks = [];
|
|
5849
5849
|
for (let i = 0; i <= steps; i++) {
|
|
5850
5850
|
const val = range.min + range.span * i / steps;
|
|
5851
|
-
const y =
|
|
5851
|
+
const y = chunkMZ47MV52_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
|
|
5852
5852
|
ticks.push(
|
|
5853
5853
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5854
5854
|
"line",
|
|
@@ -5875,7 +5875,7 @@ function renderSecondaryGridlines(id, range, layout, axisFormatting) {
|
|
|
5875
5875
|
const gridColor = axisFormatting.majorGridlinesSpPr?.strokeColor ?? "#e2e8f0";
|
|
5876
5876
|
for (let i = 0; i <= steps; i++) {
|
|
5877
5877
|
const val = range.min + range.span * i / steps;
|
|
5878
|
-
const y =
|
|
5878
|
+
const y = chunkMZ47MV52_js.valueToY(val, range, layout.plotTop, layout.plotBottom);
|
|
5879
5879
|
lines.push(
|
|
5880
5880
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
5881
5881
|
"line",
|
|
@@ -5993,7 +5993,7 @@ function renderChartDataTable(elementId, chartData, svgWidth) {
|
|
|
5993
5993
|
showK && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5994
5994
|
"th",
|
|
5995
5995
|
{
|
|
5996
|
-
"aria-label":
|
|
5996
|
+
"aria-label": chunkDVZF4ARG_js.translationsEn["pptx.chart.rowLabelsAria"],
|
|
5997
5997
|
style: {
|
|
5998
5998
|
padding: "1px 4px",
|
|
5999
5999
|
fontWeight: 400,
|
|
@@ -6037,7 +6037,7 @@ function renderChartDataTable(elementId, chartData, svgWidth) {
|
|
|
6037
6037
|
width: 8,
|
|
6038
6038
|
height: 8,
|
|
6039
6039
|
borderRadius: 2,
|
|
6040
|
-
backgroundColor:
|
|
6040
|
+
backgroundColor: chunkMZ47MV52_js.seriesColor(
|
|
6041
6041
|
s,
|
|
6042
6042
|
si,
|
|
6043
6043
|
chartData.style?.styleId,
|
|
@@ -6075,10 +6075,10 @@ function renderChartDataTable(elementId, chartData, svgWidth) {
|
|
|
6075
6075
|
}
|
|
6076
6076
|
function renderStockChart(element, chartData, categoryLabels) {
|
|
6077
6077
|
const style = chartData.style;
|
|
6078
|
-
const areaFill =
|
|
6078
|
+
const areaFill = chunkMZ47MV52_js.chartAreaFill(chartData);
|
|
6079
6079
|
const legendPos = style?.legendPosition || "b";
|
|
6080
|
-
const range =
|
|
6081
|
-
const layout =
|
|
6080
|
+
const range = chunkMZ47MV52_js.computeValueRangeForChart(chartData.series, chartData.axes);
|
|
6081
|
+
const layout = chunkMZ47MV52_js.computeLayout(element.width, element.height, style, true, legendPos);
|
|
6082
6082
|
const catCount = Math.max(categoryLabels.length, 1);
|
|
6083
6083
|
const barGroupWidth = layout.plotWidth / catCount;
|
|
6084
6084
|
const candleWidth = barGroupWidth * 0.5;
|
|
@@ -6099,10 +6099,10 @@ function renderStockChart(element, chartData, categoryLabels) {
|
|
|
6099
6099
|
const close = closeSeries.values[ci] ?? high;
|
|
6100
6100
|
const isUp = close >= open;
|
|
6101
6101
|
const cx = layout.plotLeft + barGroupWidth * ci + barGroupWidth / 2;
|
|
6102
|
-
const highY =
|
|
6103
|
-
const lowY =
|
|
6104
|
-
const openY =
|
|
6105
|
-
const closeY =
|
|
6102
|
+
const highY = chunkMZ47MV52_js.valueToY(high, range, layout.plotTop, layout.plotBottom);
|
|
6103
|
+
const lowY = chunkMZ47MV52_js.valueToY(low, range, layout.plotTop, layout.plotBottom);
|
|
6104
|
+
const openY = chunkMZ47MV52_js.valueToY(open, range, layout.plotTop, layout.plotBottom);
|
|
6105
|
+
const closeY = chunkMZ47MV52_js.valueToY(close, range, layout.plotTop, layout.plotBottom);
|
|
6106
6106
|
elements.push(
|
|
6107
6107
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6108
6108
|
"line",
|
|
@@ -6145,7 +6145,7 @@ function renderStockChart(element, chartData, categoryLabels) {
|
|
|
6145
6145
|
textAnchor: "middle",
|
|
6146
6146
|
fontSize: 7,
|
|
6147
6147
|
fill: "#334155",
|
|
6148
|
-
children:
|
|
6148
|
+
children: chunkMZ47MV52_js.formatAxisValue(close)
|
|
6149
6149
|
},
|
|
6150
6150
|
`${element.id}-stock-dl-${ci}`
|
|
6151
6151
|
)
|
|
@@ -6187,7 +6187,7 @@ function FailedToLoad() {
|
|
|
6187
6187
|
var LazySurfaceChart3DScene = React6__default.default.lazy(
|
|
6188
6188
|
async () => {
|
|
6189
6189
|
try {
|
|
6190
|
-
return await import('./SurfaceChart3DScene-
|
|
6190
|
+
return await import('./SurfaceChart3DScene-I5D54YQ3.js');
|
|
6191
6191
|
} catch {
|
|
6192
6192
|
return { default: FailedToLoad };
|
|
6193
6193
|
}
|
|
@@ -6211,7 +6211,7 @@ var SurfaceChart3DErrorBoundary = class extends React6__default.default.Componen
|
|
|
6211
6211
|
function buildSurfaceData(chartData, categoryLabels) {
|
|
6212
6212
|
const rows = chartData.series.length;
|
|
6213
6213
|
const cols = Math.max(categoryLabels.length, 1);
|
|
6214
|
-
const range =
|
|
6214
|
+
const range = chunkMZ47MV52_js.computeValueRangeForChart(chartData.series, chartData.axes);
|
|
6215
6215
|
const heightMap = new Float32Array(rows * cols);
|
|
6216
6216
|
const colorMap = new Float32Array(rows * cols * 3);
|
|
6217
6217
|
for (let r = 0; r < rows; r++) {
|
|
@@ -6330,10 +6330,10 @@ function darkenRgb(r, g, b, factor) {
|
|
|
6330
6330
|
}
|
|
6331
6331
|
function renderIsometricSurfaceChart(element, chartData, categoryLabels) {
|
|
6332
6332
|
const style = chartData.style;
|
|
6333
|
-
const areaFill =
|
|
6333
|
+
const areaFill = chunkMZ47MV52_js.chartAreaFill(chartData);
|
|
6334
6334
|
const legendPos = style?.legendPosition || "b";
|
|
6335
|
-
const layout =
|
|
6336
|
-
const range =
|
|
6335
|
+
const layout = chunkMZ47MV52_js.computeLayout(element.width, element.height, style, false, legendPos);
|
|
6336
|
+
const range = chunkMZ47MV52_js.computeValueRangeForChart(chartData.series, chartData.axes);
|
|
6337
6337
|
const catCount = Math.max(categoryLabels.length, 1);
|
|
6338
6338
|
const seriesCount = chartData.series.length;
|
|
6339
6339
|
const cols = catCount - 1;
|
|
@@ -6422,10 +6422,10 @@ function renderIsometricSurfaceChart(element, chartData, categoryLabels) {
|
|
|
6422
6422
|
}
|
|
6423
6423
|
function renderFlatSurfaceChart(element, chartData, categoryLabels) {
|
|
6424
6424
|
const style = chartData.style;
|
|
6425
|
-
const areaFill =
|
|
6425
|
+
const areaFill = chunkMZ47MV52_js.chartAreaFill(chartData);
|
|
6426
6426
|
const legendPos = style?.legendPosition || "b";
|
|
6427
|
-
const layout =
|
|
6428
|
-
const range =
|
|
6427
|
+
const layout = chunkMZ47MV52_js.computeLayout(element.width, element.height, style, true, legendPos);
|
|
6428
|
+
const range = chunkMZ47MV52_js.computeValueRangeForChart(chartData.series, chartData.axes);
|
|
6429
6429
|
const catCount = Math.max(categoryLabels.length, 1);
|
|
6430
6430
|
const seriesCount = chartData.series.length;
|
|
6431
6431
|
const cellW = layout.plotWidth / Math.max(catCount - 1, 1);
|
|
@@ -6487,9 +6487,9 @@ function renderSurfaceChart(element, chartData, categoryLabels) {
|
|
|
6487
6487
|
}
|
|
6488
6488
|
function renderTreemapChart(element, chartData, categoryLabels) {
|
|
6489
6489
|
const style = chartData.style;
|
|
6490
|
-
const areaFill =
|
|
6490
|
+
const areaFill = chunkMZ47MV52_js.chartAreaFill(chartData);
|
|
6491
6491
|
const legendPos = style?.legendPosition || "b";
|
|
6492
|
-
const layout =
|
|
6492
|
+
const layout = chunkMZ47MV52_js.computeLayout(element.width, element.height, style, false, legendPos);
|
|
6493
6493
|
const allValues = chartData.series.flatMap((s) => s.values);
|
|
6494
6494
|
const totalAbs = allValues.reduce((sum, v) => sum + Math.abs(v), 0) || 1;
|
|
6495
6495
|
const rects = [];
|
|
@@ -6512,7 +6512,7 @@ function renderTreemapChart(element, chartData, categoryLabels) {
|
|
|
6512
6512
|
y: curY,
|
|
6513
6513
|
width: Math.max(w - 1, 1),
|
|
6514
6514
|
height: Math.max(h - 1, 1),
|
|
6515
|
-
fill:
|
|
6515
|
+
fill: chunkMZ47MV52_js.paletteColor(item.index, chartData.style?.styleId, chartData.colorPalette),
|
|
6516
6516
|
rx: 2,
|
|
6517
6517
|
opacity: 0.85
|
|
6518
6518
|
},
|
|
@@ -6563,11 +6563,11 @@ function renderTreemapChart(element, chartData, categoryLabels) {
|
|
|
6563
6563
|
}
|
|
6564
6564
|
function renderWaterfallChart(element, chartData, categoryLabels) {
|
|
6565
6565
|
const style = chartData.style;
|
|
6566
|
-
const areaFill =
|
|
6566
|
+
const areaFill = chunkMZ47MV52_js.chartAreaFill(chartData);
|
|
6567
6567
|
const legendPos = style?.legendPosition || "b";
|
|
6568
6568
|
const values = chartData.series[0]?.values ?? [];
|
|
6569
|
-
const range =
|
|
6570
|
-
const layout =
|
|
6569
|
+
const range = chunkMZ47MV52_js.computeValueRangeForChart(chartData.series, chartData.axes);
|
|
6570
|
+
const layout = chunkMZ47MV52_js.computeLayout(element.width, element.height, style, true, legendPos);
|
|
6571
6571
|
const catCount = Math.max(categoryLabels.length, values.length, 1);
|
|
6572
6572
|
const barWidth = layout.plotWidth / catCount * 0.6;
|
|
6573
6573
|
const gap = layout.plotWidth / catCount * 0.2;
|
|
@@ -6578,8 +6578,8 @@ function renderWaterfallChart(element, chartData, categoryLabels) {
|
|
|
6578
6578
|
const isLast = i === values.length - 1;
|
|
6579
6579
|
const startVal = isLast ? 0 : runningTotal;
|
|
6580
6580
|
const endVal = isLast ? runningTotal + val : runningTotal + val;
|
|
6581
|
-
const barStartY =
|
|
6582
|
-
const barEndY =
|
|
6581
|
+
const barStartY = chunkMZ47MV52_js.valueToY(startVal, range, layout.plotTop, layout.plotBottom);
|
|
6582
|
+
const barEndY = chunkMZ47MV52_js.valueToY(endVal, range, layout.plotTop, layout.plotBottom);
|
|
6583
6583
|
const x = layout.plotLeft + layout.plotWidth / catCount * i + gap;
|
|
6584
6584
|
const y = Math.min(barStartY, barEndY);
|
|
6585
6585
|
const h = Math.max(Math.abs(barEndY - barStartY), 1);
|
|
@@ -6608,7 +6608,7 @@ function renderWaterfallChart(element, chartData, categoryLabels) {
|
|
|
6608
6608
|
textAnchor: "middle",
|
|
6609
6609
|
fontSize: 7,
|
|
6610
6610
|
fill: "#334155",
|
|
6611
|
-
children:
|
|
6611
|
+
children: chunkMZ47MV52_js.formatAxisValue(isLast ? endVal : val)
|
|
6612
6612
|
},
|
|
6613
6613
|
`${element.id}-wf-dl-${i}`
|
|
6614
6614
|
)
|
|
@@ -6655,20 +6655,20 @@ function renderWaterfallChart(element, chartData, categoryLabels) {
|
|
|
6655
6655
|
}
|
|
6656
6656
|
function renderComboChart(element, chartData, categoryLabels) {
|
|
6657
6657
|
const style = chartData.style;
|
|
6658
|
-
const areaFill =
|
|
6658
|
+
const areaFill = chunkMZ47MV52_js.chartAreaFill(chartData);
|
|
6659
6659
|
const legendPos = style?.legendPosition || "b";
|
|
6660
|
-
const layoutOpts =
|
|
6660
|
+
const layoutOpts = chunkMZ47MV52_js.computeLayoutOptions(
|
|
6661
6661
|
chartData.axes,
|
|
6662
6662
|
chartData.dataTable,
|
|
6663
6663
|
chartData.series.length
|
|
6664
6664
|
);
|
|
6665
|
-
const layout =
|
|
6666
|
-
const { primary, secondary } =
|
|
6665
|
+
const layout = chunkMZ47MV52_js.computeLayout(element.width, element.height, style, true, legendPos, layoutOpts);
|
|
6666
|
+
const { primary, secondary } = chunkMZ47MV52_js.splitSeriesByAxis(chartData.series, chartData.axes);
|
|
6667
6667
|
const primarySeries = primary.length > 0 ? primary.map((e) => e.series) : chartData.series;
|
|
6668
6668
|
const secondarySeries = secondary.map((e) => e.series);
|
|
6669
|
-
const range =
|
|
6670
|
-
const secondaryRange = secondarySeries.length > 0 ?
|
|
6671
|
-
const secondaryAxisFmt =
|
|
6669
|
+
const range = chunkMZ47MV52_js.computeValueRangeForChart(primarySeries, chartData.axes);
|
|
6670
|
+
const secondaryRange = secondarySeries.length > 0 ? chunkMZ47MV52_js.computeValueRange(secondarySeries) : void 0;
|
|
6671
|
+
const secondaryAxisFmt = chunkMZ47MV52_js.getSecondaryValueAxis(chartData.axes);
|
|
6672
6672
|
const catCount = Math.max(categoryLabels.length, 1);
|
|
6673
6673
|
const barSeriesCount = 1;
|
|
6674
6674
|
const barGroupWidth = layout.plotWidth / catCount;
|
|
@@ -6684,8 +6684,8 @@ function renderComboChart(element, chartData, categoryLabels) {
|
|
|
6684
6684
|
const barRange = isBarSecondary && secondaryRange ? secondaryRange : range;
|
|
6685
6685
|
barSeries.values.forEach((val, vi) => {
|
|
6686
6686
|
const x = layout.plotLeft + barGroupWidth * vi + barOffset;
|
|
6687
|
-
const zeroY =
|
|
6688
|
-
const valY =
|
|
6687
|
+
const zeroY = chunkMZ47MV52_js.valueToY(0, barRange, layout.plotTop, layout.plotBottom);
|
|
6688
|
+
const valY = chunkMZ47MV52_js.valueToY(val, barRange, layout.plotTop, layout.plotBottom);
|
|
6689
6689
|
const y = Math.min(zeroY, valY);
|
|
6690
6690
|
const h = Math.max(Math.abs(zeroY - valY), 1);
|
|
6691
6691
|
barElements.push(
|
|
@@ -6696,7 +6696,7 @@ function renderComboChart(element, chartData, categoryLabels) {
|
|
|
6696
6696
|
y,
|
|
6697
6697
|
width: barWidth,
|
|
6698
6698
|
height: h,
|
|
6699
|
-
fill:
|
|
6699
|
+
fill: chunkMZ47MV52_js.seriesColor(barSeries, 0, chartData.style?.styleId, chartData.colorPalette),
|
|
6700
6700
|
rx: 1
|
|
6701
6701
|
},
|
|
6702
6702
|
`${element.id}-combo-bar-${vi}`
|
|
@@ -6712,7 +6712,7 @@ function renderComboChart(element, chartData, categoryLabels) {
|
|
|
6712
6712
|
textAnchor: "middle",
|
|
6713
6713
|
fontSize: 7,
|
|
6714
6714
|
fill: "#334155",
|
|
6715
|
-
children:
|
|
6715
|
+
children: chunkMZ47MV52_js.formatAxisValue(val)
|
|
6716
6716
|
},
|
|
6717
6717
|
`${element.id}-combo-bar-dl-${vi}`
|
|
6718
6718
|
)
|
|
@@ -6729,10 +6729,10 @@ function renderComboChart(element, chartData, categoryLabels) {
|
|
|
6729
6729
|
const activeRange = isSecondary && secondaryRange ? secondaryRange : range;
|
|
6730
6730
|
const points = series.values.map((val, vi) => {
|
|
6731
6731
|
const x = layout.plotLeft + barGroupWidth * vi + barGroupWidth / 2;
|
|
6732
|
-
const y =
|
|
6732
|
+
const y = chunkMZ47MV52_js.valueToY(val, activeRange, layout.plotTop, layout.plotBottom);
|
|
6733
6733
|
return { x, y, val };
|
|
6734
6734
|
});
|
|
6735
|
-
const c =
|
|
6735
|
+
const c = chunkMZ47MV52_js.seriesColor(series, seriesIdx, chartData.style?.styleId, chartData.colorPalette);
|
|
6736
6736
|
lineElements.push(
|
|
6737
6737
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
6738
6738
|
"polyline",
|
|
@@ -6759,7 +6759,7 @@ function renderComboChart(element, chartData, categoryLabels) {
|
|
|
6759
6759
|
textAnchor: "middle",
|
|
6760
6760
|
fontSize: 7,
|
|
6761
6761
|
fill: "#334155",
|
|
6762
|
-
children:
|
|
6762
|
+
children: chunkMZ47MV52_js.formatAxisValue(p.val)
|
|
6763
6763
|
},
|
|
6764
6764
|
`${element.id}-combo-line-dl-${si}-${vi}`
|
|
6765
6765
|
)
|
|
@@ -6797,11 +6797,11 @@ function renderComboChart(element, chartData, categoryLabels) {
|
|
|
6797
6797
|
}
|
|
6798
6798
|
function renderChartElement(element) {
|
|
6799
6799
|
if (element.type !== "chart") {
|
|
6800
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children:
|
|
6800
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunkDVZF4ARG_js.translationsEn["pptx.chart.heading"] });
|
|
6801
6801
|
}
|
|
6802
6802
|
const chartData = element.chartData;
|
|
6803
6803
|
if (!chartData || chartData.series.length === 0) {
|
|
6804
|
-
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children:
|
|
6804
|
+
return /* @__PURE__ */ jsxRuntime.jsx("div", { className: "w-full h-full flex items-center justify-center text-[11px] text-white/80 pointer-events-none", children: chunkDVZF4ARG_js.translationsEn["pptx.chart.heading"] });
|
|
6805
6805
|
}
|
|
6806
6806
|
const longestSeriesLength = chartData.series.reduce(
|
|
6807
6807
|
(maxLength, series) => Math.max(maxLength, series.values.length),
|
|
@@ -7905,14 +7905,14 @@ function buildNotesPdf(pages) {
|
|
|
7905
7905
|
notes: page.notes,
|
|
7906
7906
|
slideNumber: page.slideNumber
|
|
7907
7907
|
}));
|
|
7908
|
-
const bytes =
|
|
7908
|
+
const bytes = chunkMZ47MV52_js.buildNotesPdfBytes(images, meta);
|
|
7909
7909
|
const blob = new Blob([bytes], { type: "application/pdf" });
|
|
7910
7910
|
return URL.createObjectURL(blob);
|
|
7911
7911
|
}
|
|
7912
7912
|
|
|
7913
7913
|
// src/viewer/utils/pdf-builder-slides.ts
|
|
7914
7914
|
function buildPdfFromImageData(images) {
|
|
7915
|
-
const bytes =
|
|
7915
|
+
const bytes = chunkMZ47MV52_js.buildSlidesPdfBytes(images);
|
|
7916
7916
|
const blob = new Blob([bytes], { type: "application/pdf" });
|
|
7917
7917
|
return URL.createObjectURL(blob);
|
|
7918
7918
|
}
|
|
@@ -7921,7 +7921,7 @@ function buildPdfFromImageData(images) {
|
|
|
7921
7921
|
var activePreview = null;
|
|
7922
7922
|
function startPreviewAnimation(elementId, preset, options) {
|
|
7923
7923
|
stopPreviewAnimation();
|
|
7924
|
-
const descriptor =
|
|
7924
|
+
const descriptor = chunkMZ47MV52_js.buildPreviewAnimation(preset, options);
|
|
7925
7925
|
if (!descriptor) {
|
|
7926
7926
|
return;
|
|
7927
7927
|
}
|
|
@@ -7934,7 +7934,7 @@ function startMotionPathPreview(elementId, path, options) {
|
|
|
7934
7934
|
return;
|
|
7935
7935
|
}
|
|
7936
7936
|
const stage = domEl.offsetParent;
|
|
7937
|
-
const descriptor =
|
|
7937
|
+
const descriptor = chunkMZ47MV52_js.buildMotionPathPreview({
|
|
7938
7938
|
path,
|
|
7939
7939
|
slideWidth: stage?.offsetWidth || DEFAULT_PREVIEW_SLIDE_WIDTH,
|
|
7940
7940
|
slideHeight: stage?.offsetHeight || DEFAULT_PREVIEW_SLIDE_HEIGHT,
|