pptx-vue-viewer 1.1.69 → 1.1.71
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/dist/{dist-6OajfxoW.cjs → dist-BcurUiEs.cjs} +274 -255
- package/dist/dist-BcurUiEs.cjs.br +0 -0
- package/dist/dist-BcurUiEs.cjs.gz +0 -0
- package/dist/{dist-CU9pFdH4.js → dist-mkpy7NLf.js} +274 -255
- package/dist/dist-mkpy7NLf.js.br +0 -0
- package/dist/{dist-CU9pFdH4.js.gz → dist-mkpy7NLf.js.gz} +0 -0
- package/dist/gif-encoder-CQ7KRbYX.cjs +2 -0
- package/dist/gif-encoder-CQ7KRbYX.cjs.br +0 -0
- package/dist/gif-encoder-CQ7KRbYX.cjs.gz +0 -0
- package/dist/gif-encoder-Ceew9lIy.js +2 -0
- package/dist/gif-encoder-Ceew9lIy.js.br +0 -0
- package/dist/gif-encoder-Ceew9lIy.js.gz +0 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.br +0 -0
- package/dist/index.cjs.gz +0 -0
- package/dist/index.js +1 -1
- package/dist/index.js.br +0 -0
- package/dist/index.js.gz +0 -0
- package/dist/pptx-vue-viewer.css +1 -1
- package/dist/pptx-vue-viewer.css.br +0 -0
- package/dist/pptx-vue-viewer.css.gz +0 -0
- package/dist/viewer/PowerPointViewer.vue.d.ts.map +1 -1
- package/dist/viewer/components/EditorToolbar.vue.d.ts.map +1 -1
- package/dist/viewer/index.cjs +1 -1
- package/dist/viewer/index.cjs.br +0 -0
- package/dist/viewer/index.cjs.gz +0 -0
- package/dist/viewer/index.js +1 -1
- package/dist/viewer/index.js.br +0 -0
- package/dist/viewer/index.js.gz +0 -0
- package/dist/{viewer-Dac8kaTM.cjs → viewer-DOunRUGo.cjs} +24 -16
- package/dist/viewer-DOunRUGo.cjs.br +0 -0
- package/dist/viewer-DOunRUGo.cjs.gz +0 -0
- package/dist/{viewer-d0B2dKIA.js → viewer-DmgY4B0A.js} +24 -16
- package/dist/viewer-DmgY4B0A.js.br +0 -0
- package/dist/viewer-DmgY4B0A.js.gz +0 -0
- package/package.json +1 -1
- package/dist/dist-6OajfxoW.cjs.br +0 -0
- package/dist/dist-6OajfxoW.cjs.gz +0 -0
- package/dist/dist-CU9pFdH4.js.br +0 -0
- package/dist/gif-encoder-BTI7udFr.cjs +0 -2
- package/dist/gif-encoder-BTI7udFr.cjs.br +0 -0
- package/dist/gif-encoder-BTI7udFr.cjs.gz +0 -0
- package/dist/gif-encoder-CqfWy9MI.js +0 -2
- package/dist/gif-encoder-CqfWy9MI.js.br +0 -3
- package/dist/gif-encoder-CqfWy9MI.js.gz +0 -0
- package/dist/viewer-Dac8kaTM.cjs.br +0 -0
- package/dist/viewer-Dac8kaTM.cjs.gz +0 -0
- package/dist/viewer-d0B2dKIA.js.br +0 -0
- package/dist/viewer-d0B2dKIA.js.gz +0 -0
|
@@ -4029,8 +4029,8 @@ var zt = a({
|
|
|
4029
4029
|
COLOR_MAP_ALIAS_KEYS: () => tl,
|
|
4030
4030
|
CONNECTOR_ARROW_OPTIONS: () => Un,
|
|
4031
4031
|
CONNECTOR_GEOMETRY_OPTIONS: () => $n,
|
|
4032
|
-
ChartBuilder: () =>
|
|
4033
|
-
ConnectorBuilder: () =>
|
|
4032
|
+
ChartBuilder: () => lw,
|
|
4033
|
+
ConnectorBuilder: () => cw,
|
|
4034
4034
|
ConnectorXmlFactory: () => Ve,
|
|
4035
4035
|
DEFAULT_CANVAS_HEIGHT: () => 720,
|
|
4036
4036
|
DEFAULT_CANVAS_WIDTH: () => Dn,
|
|
@@ -4047,12 +4047,12 @@ var zt = a({
|
|
|
4047
4047
|
DIGITAL_SIGNATURE_ORIGIN_REL_TYPE: () => Zo,
|
|
4048
4048
|
DIGITAL_SIGNATURE_REL_TYPE: () => Jo,
|
|
4049
4049
|
DataIntegrityError: () => Xc,
|
|
4050
|
-
DocumentConverter: () =>
|
|
4050
|
+
DocumentConverter: () => Ew,
|
|
4051
4051
|
EFFECT_LST_ORDER: () => hn,
|
|
4052
4052
|
EMPHASIS_PRESETS: () => Wp,
|
|
4053
|
-
EMU_PER_INCH: () =>
|
|
4054
|
-
EMU_PER_PIXEL: () =>
|
|
4055
|
-
EMU_PER_POINT: () =>
|
|
4053
|
+
EMU_PER_INCH: () => fw,
|
|
4054
|
+
EMU_PER_PIXEL: () => mw,
|
|
4055
|
+
EMU_PER_POINT: () => gw,
|
|
4056
4056
|
EMU_PER_PX: () => Ln,
|
|
4057
4057
|
ENTERPRISE_FAIL_ON_REVOCATION_UNKNOWN_ENV: () => sa,
|
|
4058
4058
|
ENTERPRISE_REQUIRE_REVOCATION_ENV: () => aa,
|
|
@@ -4064,16 +4064,16 @@ var zt = a({
|
|
|
4064
4064
|
EncryptedFileError: () => Bc,
|
|
4065
4065
|
FONT_SUBSTITUTION_MAP: () => bh,
|
|
4066
4066
|
FreeformPathBuilder: () => Vb,
|
|
4067
|
-
GroupBuilder: () =>
|
|
4068
|
-
ImageBuilder: () =>
|
|
4067
|
+
GroupBuilder: () => hw,
|
|
4068
|
+
ImageBuilder: () => aw,
|
|
4069
4069
|
IncorrectPasswordError: () => Uc,
|
|
4070
4070
|
MAX_TABLE_DIMENSION: () => 100,
|
|
4071
4071
|
MAX_ZIP_ENTRY_COUNT: () => Sa,
|
|
4072
4072
|
MIN_ELEMENT_SIZE: () => 12,
|
|
4073
4073
|
MIN_TABLE_DIMENSION: () => 1,
|
|
4074
4074
|
MOTION_PATH_PRESETS: () => Hp,
|
|
4075
|
-
MediaBuilder: () =>
|
|
4076
|
-
MediaContext: () =>
|
|
4075
|
+
MediaBuilder: () => dw,
|
|
4076
|
+
MediaContext: () => Fw,
|
|
4077
4077
|
MediaGraphicFrameXmlFactory: () => Ye,
|
|
4078
4078
|
OOXML_TO_PRESET_EMPH: () => Zi,
|
|
4079
4079
|
OOXML_TO_PRESET_ENTR: () => qi,
|
|
@@ -4111,7 +4111,7 @@ var zt = a({
|
|
|
4111
4111
|
PptxHandlerRuntime: () => Zg,
|
|
4112
4112
|
PptxHandlerRuntimeFactory: () => Jg,
|
|
4113
4113
|
PptxLoadDataBuilder: () => Wr,
|
|
4114
|
-
PptxMarkdownConverter: () =>
|
|
4114
|
+
PptxMarkdownConverter: () => mT,
|
|
4115
4115
|
PptxMediaDataParser: () => Lr,
|
|
4116
4116
|
PptxNativeAnimationService: () => Xi,
|
|
4117
4117
|
PptxPresentationSaveBuilder: () => nn,
|
|
@@ -4148,19 +4148,19 @@ var zt = a({
|
|
|
4148
4148
|
SUPPORTED_XML_CANON_TRANSFORMS: () => ra,
|
|
4149
4149
|
SWITCHABLE_LAYOUT_TYPES: () => Nd,
|
|
4150
4150
|
SYSTEM_COLOR_MAP: () => Fn,
|
|
4151
|
-
ShapeBuilder: () =>
|
|
4151
|
+
ShapeBuilder: () => ow,
|
|
4152
4152
|
SlideBuilder: () => Ee,
|
|
4153
|
-
SlideProcessor: () =>
|
|
4154
|
-
SlideSizes: () =>
|
|
4155
|
-
SvgExporter: () =>
|
|
4153
|
+
SlideProcessor: () => lT,
|
|
4154
|
+
SlideSizes: () => kw,
|
|
4155
|
+
SvgExporter: () => _T,
|
|
4156
4156
|
TC_PR_BORDERS_ORDER: () => un,
|
|
4157
4157
|
THEME_COLOR_SCHEME_KEYS: () => Qt,
|
|
4158
4158
|
THEME_PRESETS: () => te,
|
|
4159
4159
|
TRANSITION_VALID_DIRECTIONS: () => Gt,
|
|
4160
|
-
TableBuilder: () =>
|
|
4161
|
-
TextBuilder: () =>
|
|
4160
|
+
TableBuilder: () => sw,
|
|
4161
|
+
TextBuilder: () => iw,
|
|
4162
4162
|
TextShapeXmlFactory: () => Ke,
|
|
4163
|
-
ThemePresets: () =>
|
|
4163
|
+
ThemePresets: () => _w,
|
|
4164
4164
|
VML_SHAPE_TAGS: () => Is,
|
|
4165
4165
|
XMLDSIG_NS: () => ta,
|
|
4166
4166
|
XML_TRANSFORM_ENVELOPED_SIGNATURE: () => na,
|
|
@@ -4207,8 +4207,8 @@ var zt = a({
|
|
|
4207
4207
|
cloneTemplateElementsBySlideId: () => hl,
|
|
4208
4208
|
cloneTextStyle: () => sl,
|
|
4209
4209
|
cloneXmlObject: () => pl,
|
|
4210
|
-
cm: () =>
|
|
4211
|
-
cmToEmu: () =>
|
|
4210
|
+
cm: () => xw,
|
|
4211
|
+
cmToEmu: () => Cw,
|
|
4212
4212
|
colorWithOpacity: () => Sn,
|
|
4213
4213
|
colorsEqual: () => kr,
|
|
4214
4214
|
combineShapes: () => Rb,
|
|
@@ -4233,8 +4233,8 @@ var zt = a({
|
|
|
4233
4233
|
createFreeformElement: () => Ne,
|
|
4234
4234
|
createGroupElement: () => Re,
|
|
4235
4235
|
createImageElement: () => Fe,
|
|
4236
|
-
createLayout: () =>
|
|
4237
|
-
createLayouts: () =>
|
|
4236
|
+
createLayout: () => Gv,
|
|
4237
|
+
createLayouts: () => Wv,
|
|
4238
4238
|
createMediaElement: () => Be,
|
|
4239
4239
|
createModifyVerifier: () => gd,
|
|
4240
4240
|
createPptxSaveConstants: () => ko,
|
|
@@ -4246,14 +4246,14 @@ var zt = a({
|
|
|
4246
4246
|
createTemplateShapeRawXml: () => Ml,
|
|
4247
4247
|
createTextElement: () => Me,
|
|
4248
4248
|
createUniformTextSegments: () => xl,
|
|
4249
|
-
dataUrlToMediaBytes: () =>
|
|
4249
|
+
dataUrlToMediaBytes: () => Aw,
|
|
4250
4250
|
decodeOle10Native: () => qo,
|
|
4251
4251
|
decodeXmlEntities: () => So,
|
|
4252
4252
|
decomposeSmartArt: () => fc,
|
|
4253
4253
|
decryptPptx: () => ad,
|
|
4254
4254
|
demoteSmartArtNode: () => kc,
|
|
4255
4255
|
deobfuscateFont: () => La,
|
|
4256
|
-
deriveOutputPath: () =>
|
|
4256
|
+
deriveOutputPath: () => Nw,
|
|
4257
4257
|
detectDigitalSignatures: () => pa,
|
|
4258
4258
|
detectFileFormat: () => Dc,
|
|
4259
4259
|
detectFontFormat: () => Ra,
|
|
@@ -4267,7 +4267,7 @@ var zt = a({
|
|
|
4267
4267
|
duplicateSlide: () => rv,
|
|
4268
4268
|
elementActionToPptxAction: () => Ll,
|
|
4269
4269
|
elementHasAction: () => Dl,
|
|
4270
|
-
emuToPixels: () =>
|
|
4270
|
+
emuToPixels: () => vw,
|
|
4271
4271
|
encryptPptx: () => sd,
|
|
4272
4272
|
ensureArrayValue: () => vl,
|
|
4273
4273
|
escapeXmlAttr: () => yd,
|
|
@@ -4284,15 +4284,15 @@ var zt = a({
|
|
|
4284
4284
|
extractTagAttribute: () => Sd,
|
|
4285
4285
|
fetchUrlToBytes: () => El,
|
|
4286
4286
|
findCustomShow: () => Pp,
|
|
4287
|
-
findLayoutByName: () =>
|
|
4288
|
-
findLayoutByType: () =>
|
|
4287
|
+
findLayoutByName: () => Hv,
|
|
4288
|
+
findLayoutByType: () => Vv,
|
|
4289
4289
|
findPlaceholders: () => WS,
|
|
4290
4290
|
findText: () => KS,
|
|
4291
4291
|
formatCommentTimestamp: () => wl,
|
|
4292
4292
|
fragmentShapes: () => Bb,
|
|
4293
4293
|
generateFontGuid: () => Ba,
|
|
4294
|
-
generateLayoutXml: () =>
|
|
4295
|
-
generateMediaFilename: () =>
|
|
4294
|
+
generateLayoutXml: () => Ov,
|
|
4295
|
+
generateMediaFilename: () => Iw,
|
|
4296
4296
|
getAdjustmentAwareClipPath: () => vy,
|
|
4297
4297
|
getAdjustmentAwareShapeClipPath: () => tb,
|
|
4298
4298
|
getAnimationPresetInfo: () => Yp,
|
|
@@ -4308,7 +4308,7 @@ var zt = a({
|
|
|
4308
4308
|
getCssBorderDashStyle: () => _l,
|
|
4309
4309
|
getCustomShowNames: () => Ap,
|
|
4310
4310
|
getCustomShowPositionLabel: () => Fp,
|
|
4311
|
-
getDirectory: () =>
|
|
4311
|
+
getDirectory: () => Rw,
|
|
4312
4312
|
getElementLabel: () => fl,
|
|
4313
4313
|
getElementTextContent: () => yl,
|
|
4314
4314
|
getElementTransform: () => sb,
|
|
@@ -4331,7 +4331,7 @@ var zt = a({
|
|
|
4331
4331
|
getSupportedNamespaces: () => Us,
|
|
4332
4332
|
getSvgStrokeDasharray: () => Pl,
|
|
4333
4333
|
getTextCompensationTransform: () => lb,
|
|
4334
|
-
getThemePreset: () =>
|
|
4334
|
+
getThemePreset: () => Pw,
|
|
4335
4335
|
getZoomElements: () => uh,
|
|
4336
4336
|
getZoomTargetSlideIndexes: () => gh,
|
|
4337
4337
|
guidToKey: () => Fa,
|
|
@@ -4343,10 +4343,10 @@ var zt = a({
|
|
|
4343
4343
|
hasTextProperties: () => Zt,
|
|
4344
4344
|
hexToRgbChannels: () => bn,
|
|
4345
4345
|
hslToRgb: () => Cn,
|
|
4346
|
-
inches: () =>
|
|
4347
|
-
inchesToEmu: () =>
|
|
4346
|
+
inches: () => yw,
|
|
4347
|
+
inchesToEmu: () => Tw,
|
|
4348
4348
|
inferOleExtensionFromTarget: () => Nr,
|
|
4349
|
-
interpolateShapeGeometry: () =>
|
|
4349
|
+
interpolateShapeGeometry: () => tw,
|
|
4350
4350
|
intersectPolygons: () => jb,
|
|
4351
4351
|
intersectShapes: () => Lb,
|
|
4352
4352
|
intersectSvgPaths: () => Ub,
|
|
@@ -4376,13 +4376,13 @@ var zt = a({
|
|
|
4376
4376
|
mergeStyleParts: () => Dp,
|
|
4377
4377
|
mergeThemeColorOverride: () => rl,
|
|
4378
4378
|
mimeTypeForOleFile: () => jr,
|
|
4379
|
-
mm: () =>
|
|
4379
|
+
mm: () => bw,
|
|
4380
4380
|
moveSlidesToSection: () => PS,
|
|
4381
4381
|
navigateCustomShow: () => Ip,
|
|
4382
4382
|
normalizeHexColor: () => xn,
|
|
4383
4383
|
normalizeNamespaceUri: () => qd,
|
|
4384
4384
|
normalizePartPath: () => Td,
|
|
4385
|
-
normalizePath: () =>
|
|
4385
|
+
normalizePath: () => Bw,
|
|
4386
4386
|
normalizeStrictXml: () => Jd,
|
|
4387
4387
|
normalizeStrokeDashType: () => kl,
|
|
4388
4388
|
obfuscateFont: () => Da,
|
|
@@ -4424,14 +4424,14 @@ var zt = a({
|
|
|
4424
4424
|
parseShapeProps: () => Va,
|
|
4425
4425
|
parseSignatureXml: () => ga,
|
|
4426
4426
|
parseSlideDrawingGuides: () => li,
|
|
4427
|
-
parseSvgPath: () =>
|
|
4427
|
+
parseSvgPath: () => nw,
|
|
4428
4428
|
parseVmlElement: () => Fs,
|
|
4429
4429
|
parseVmlElements: () => Ls,
|
|
4430
|
-
pixelsToEmu: () =>
|
|
4430
|
+
pixelsToEmu: () => ww,
|
|
4431
4431
|
polygonsToSvgPath: () => vb,
|
|
4432
4432
|
pptxActionToElementAction: () => Fl,
|
|
4433
4433
|
promoteSmartArtNode: () => Cc,
|
|
4434
|
-
pt: () =>
|
|
4434
|
+
pt: () => Sw,
|
|
4435
4435
|
reResolveSlideColors: () => sp,
|
|
4436
4436
|
readFileAsDataUrl: () => Cl,
|
|
4437
4437
|
rebuildTableStructureInRawXml: () => Qm,
|
|
@@ -4447,10 +4447,10 @@ var zt = a({
|
|
|
4447
4447
|
reorderSmartArtNode: () => Tc,
|
|
4448
4448
|
reorderSmartArtNodeToIndex: () => Pc,
|
|
4449
4449
|
repairPptx: () => Qh,
|
|
4450
|
-
replaceShapeGeometry: () =>
|
|
4450
|
+
replaceShapeGeometry: () => Jv,
|
|
4451
4451
|
replaceText: () => JS,
|
|
4452
4452
|
replaceTextInSlide: () => ZS,
|
|
4453
|
-
replaceWithCustomGeometry: () =>
|
|
4453
|
+
replaceWithCustomGeometry: () => Qv,
|
|
4454
4454
|
resetCloneIdCounter: () => ev,
|
|
4455
4455
|
resetDecomposeCounter: () => zl,
|
|
4456
4456
|
resetIdCounter: () => Se,
|
|
@@ -4467,7 +4467,7 @@ var zt = a({
|
|
|
4467
4467
|
serializeColorChoice: () => Pr,
|
|
4468
4468
|
serializeCondition: () => Ri,
|
|
4469
4469
|
serializeConditionList: () => Ni,
|
|
4470
|
-
serializeSvgPath: () =>
|
|
4470
|
+
serializeSvgPath: () => rw,
|
|
4471
4471
|
setChartAxis: () => Sv,
|
|
4472
4472
|
setChartAxisGridlineStyle: () => Mv,
|
|
4473
4473
|
setChartAxisLogScale: () => _v,
|
|
@@ -4476,7 +4476,8 @@ var zt = a({
|
|
|
4476
4476
|
setChartDataLabels: () => yv,
|
|
4477
4477
|
setChartDataPointExplosion: () => Dv,
|
|
4478
4478
|
setChartDataPointFill: () => Lv,
|
|
4479
|
-
setChartDataPointLabel: () =>
|
|
4479
|
+
setChartDataPointLabel: () => Rv,
|
|
4480
|
+
setChartDataPointMarker: () => Bv,
|
|
4480
4481
|
setChartGrouping: () => fv,
|
|
4481
4482
|
setChartLegend: () => gv,
|
|
4482
4483
|
setChartSeriesChartType: () => Iv,
|
|
@@ -47504,7 +47505,7 @@ function Lv(t, e, n, r) {
|
|
|
47504
47505
|
t.spPr && (t.spPr = {
|
|
47505
47506
|
...t.spPr,
|
|
47506
47507
|
fillColor: void 0
|
|
47507
|
-
}, void 0 === t.spPr.fillColor && void 0 === t.spPr.strokeColor && void 0 === t.spPr.strokeWidth && void 0 === t.spPr.strokeDashStyle && (t.spPr = void 0)),
|
|
47508
|
+
}, void 0 === t.spPr.fillColor && void 0 === t.spPr.strokeColor && void 0 === t.spPr.strokeWidth && void 0 === t.spPr.strokeDashStyle && (t.spPr = void 0)), Nv(i, n);
|
|
47508
47509
|
return;
|
|
47509
47510
|
}
|
|
47510
47511
|
const o = Fv(i, n);
|
|
@@ -47518,12 +47519,30 @@ function Dv(t, e, n, r) {
|
|
|
47518
47519
|
const i = t.chartData.series[e];
|
|
47519
47520
|
if (null === r) {
|
|
47520
47521
|
const t = i.dataPoints?.find((t) => t.idx === n);
|
|
47521
|
-
t && (t.explosion = void 0,
|
|
47522
|
+
t && (t.explosion = void 0, Nv(i, n));
|
|
47522
47523
|
return;
|
|
47523
47524
|
}
|
|
47524
47525
|
Fv(i, n).explosion = r;
|
|
47525
47526
|
}
|
|
47526
47527
|
function Bv(t, e, n, r) {
|
|
47528
|
+
lv(t, e);
|
|
47529
|
+
const i = t.chartData.series[e];
|
|
47530
|
+
if (null === r) {
|
|
47531
|
+
const t = i.dataPoints?.find((t) => t.idx === n);
|
|
47532
|
+
t && (t.marker = void 0, Nv(i, n));
|
|
47533
|
+
return;
|
|
47534
|
+
}
|
|
47535
|
+
const o = Fv(i, n), a = o.marker, s = {
|
|
47536
|
+
symbol: r.symbol ?? a?.symbol ?? "circle",
|
|
47537
|
+
size: r.size ?? a?.size,
|
|
47538
|
+
spPr: a?.spPr ? { ...a.spPr } : void 0
|
|
47539
|
+
};
|
|
47540
|
+
void 0 !== r.fillColor && (s.spPr = {
|
|
47541
|
+
...s.spPr ?? {},
|
|
47542
|
+
fillColor: r.fillColor
|
|
47543
|
+
}), o.marker = s;
|
|
47544
|
+
}
|
|
47545
|
+
function Rv(t, e, n, r) {
|
|
47527
47546
|
lv(t, e);
|
|
47528
47547
|
const i = t.chartData.series[e];
|
|
47529
47548
|
if (null === r) {
|
|
@@ -47537,35 +47556,35 @@ function Bv(t, e, n, r) {
|
|
|
47537
47556
|
void 0 !== e.showValue && (t.showVal = e.showValue), void 0 !== e.showCategory && (t.showCatName = e.showCategory), void 0 !== e.showSeriesName && (t.showSerName = e.showSeriesName), void 0 !== e.showPercent && (t.showPercent = e.showPercent), void 0 !== e.showLegendKey && (t.showLegendKey = e.showLegendKey), void 0 !== e.position && (t.position = e.position), void 0 !== e.text && (t.text = "" === e.text ? void 0 : e.text);
|
|
47538
47557
|
}(a, r);
|
|
47539
47558
|
}
|
|
47540
|
-
function
|
|
47559
|
+
function Nv(t, e) {
|
|
47541
47560
|
if (!t.dataPoints) return;
|
|
47542
47561
|
const n = t.dataPoints.find((t) => t.idx === e);
|
|
47543
47562
|
if (!n) return;
|
|
47544
47563
|
void 0 === n.spPr && void 0 === n.explosion && void 0 === n.invertIfNegative && void 0 === n.marker && (t.dataPoints = t.dataPoints.filter((t) => t.idx !== e), 0 === t.dataPoints.length && (t.dataPoints = void 0));
|
|
47545
47564
|
}
|
|
47546
|
-
var
|
|
47547
|
-
function Ev(t) {
|
|
47548
|
-
return Math.round(t * Nv);
|
|
47549
|
-
}
|
|
47565
|
+
var Ev = 9525;
|
|
47550
47566
|
function jv(t) {
|
|
47567
|
+
return Math.round(t * Ev);
|
|
47568
|
+
}
|
|
47569
|
+
function Ov(t) {
|
|
47551
47570
|
const e = t.type ?? "obj", n = (t.placeholders ?? []).map((t, e) => function(t, e) {
|
|
47552
|
-
const n = t.name ?? `${t.type.charAt(0).toUpperCase() + t.type.slice(1)} Placeholder ${e - 1}`, r =
|
|
47571
|
+
const n = t.name ?? `${t.type.charAt(0).toUpperCase() + t.type.slice(1)} Placeholder ${e - 1}`, r = jv(t.x), i = jv(t.y), o = jv(t.width), a = jv(t.height), s = void 0 !== t.idx ? ` idx="${t.idx}"` : "";
|
|
47553
47572
|
return ` <p:sp>\n <p:nvSpPr>\n <p:cNvPr id="${e}" name="${n}"/>\n <p:cNvSpPr><a:spLocks noGrp="1"/></p:cNvSpPr>\n <p:nvPr><p:ph type="${t.type}"${s}/></p:nvPr>\n </p:nvSpPr>\n <p:spPr>\n <a:xfrm><a:off x="${r}" y="${i}"/><a:ext cx="${o}" cy="${a}"/></a:xfrm>\n </p:spPr>\n <p:txBody>\n <a:bodyPr/>\n <a:lstStyle/>\n <a:p><a:endParaRPr lang="en-US"/></a:p>\n </p:txBody>\n </p:sp>`;
|
|
47554
47573
|
}(t, e + 2)).join("\n");
|
|
47555
47574
|
let r = "";
|
|
47556
47575
|
if (t.backgroundColor) r = ` <p:bg><p:bgPr><a:solidFill><a:srgbClr val="${t.backgroundColor.replace(/^#/, "").toUpperCase()}"/></a:solidFill><a:effectLst/></p:bgPr></p:bg>\n`;
|
|
47557
47576
|
return `<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<p:sldLayout xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main"\n xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships"\n xmlns:p="http://schemas.openxmlformats.org/presentationml/2006/main"\n type="${e}" preserve="1">\n <p:cSld name="${t.name}">\n${r} <p:spTree>\n <p:nvGrpSpPr><p:cNvPr id="1" name=""/><p:cNvGrpSpPr/><p:nvPr/></p:nvGrpSpPr>\n <p:grpSpPr><a:xfrm><a:off x="0" y="0"/><a:ext cx="0" cy="0"/><a:chOff x="0" y="0"/><a:chExt cx="0" cy="0"/></a:xfrm></p:grpSpPr>\n${n}\n </p:spTree>\n </p:cSld>\n <p:clrMapOvr><a:masterClrMapping/></p:clrMapOvr>\n</p:sldLayout>`;
|
|
47558
47577
|
}
|
|
47559
|
-
function
|
|
47578
|
+
function $v(t = 1) {
|
|
47560
47579
|
return `<?xml version="1.0" encoding="UTF-8" standalone="yes"?>\n<Relationships xmlns="http://schemas.openxmlformats.org/package/2006/relationships">\n <Relationship Id="rId1" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideMaster" Target="../slideMasters/slideMaster${t}.xml"/>\n</Relationships>`;
|
|
47561
47580
|
}
|
|
47562
|
-
function
|
|
47581
|
+
function Uv(t) {
|
|
47563
47582
|
let e = 0;
|
|
47564
47583
|
return t.forEach((t) => {
|
|
47565
47584
|
/^ppt\/slideLayouts\/slideLayout\d+\.xml$/.test(t) && e++;
|
|
47566
47585
|
}), e;
|
|
47567
47586
|
}
|
|
47568
|
-
async function
|
|
47587
|
+
async function Xv(t, e, n = 1) {
|
|
47569
47588
|
const r = `ppt/slideMasters/_rels/slideMaster${n}.xml.rels`, i = await t.file(r)?.async("string");
|
|
47570
47589
|
if (!i) throw new Error(`Slide master rels not found at ${r}`);
|
|
47571
47590
|
const o = `rId${[...i.matchAll(/rId(\d+)/g)].reduce((t, e) => Math.max(t, parseInt(e[1], 10)), 0) + 1}`, a = ` <Relationship Id="${o}" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/slideLayout" Target="../slideLayouts/slideLayout${e}.xml"/>`, s = i.replace("</Relationships>", `${a}\n</Relationships>`);
|
|
@@ -47575,15 +47594,15 @@ async function Uv(t, e, n = 1) {
|
|
|
47575
47594
|
const d = ` <p:sldLayoutId id="${[...c.matchAll(/sldLayoutId\s+id="(\d+)"/g)].reduce((t, e) => Math.max(t, parseInt(e[1], 10)), 2147483648) + 1}" r:id="${o}"/>`, h = c.replace("</p:sldLayoutIdLst>", `${d}\n </p:sldLayoutIdLst>`);
|
|
47576
47595
|
t.file(l, h);
|
|
47577
47596
|
}
|
|
47578
|
-
async function
|
|
47597
|
+
async function zv(t, e) {
|
|
47579
47598
|
const n = "[Content_Types].xml", r = await t.file(n)?.async("string");
|
|
47580
47599
|
if (!r) throw new Error("Content types file not found");
|
|
47581
47600
|
const i = ` <Override PartName="/ppt/slideLayouts/slideLayout${e}.xml" ContentType="application/vnd.openxmlformats-officedocument.presentationml.slideLayout+xml"/>`, o = r.replace("</Types>", `${i}\n</Types>`);
|
|
47582
47601
|
t.file(n, o);
|
|
47583
47602
|
}
|
|
47584
|
-
async function
|
|
47585
|
-
const i = await t.save(e.slides), o = await l.default.loadAsync(i), a =
|
|
47586
|
-
o.file(s,
|
|
47603
|
+
async function Gv(t, e, n, r = 1) {
|
|
47604
|
+
const i = await t.save(e.slides), o = await l.default.loadAsync(i), a = Uv(o) + 1, s = `ppt/slideLayouts/slideLayout${a}.xml`;
|
|
47605
|
+
o.file(s, Ov(n)), o.file(`ppt/slideLayouts/_rels/slideLayout${a}.xml.rels`, $v(r)), await Xv(o, a, r), await zv(o, a);
|
|
47587
47606
|
const c = await o.generateAsync({ type: "arraybuffer" }), d = new ey(), h = await d.load(c);
|
|
47588
47607
|
return {
|
|
47589
47608
|
layoutPath: s,
|
|
@@ -47592,16 +47611,16 @@ async function zv(t, e, n, r = 1) {
|
|
|
47592
47611
|
data: h
|
|
47593
47612
|
};
|
|
47594
47613
|
}
|
|
47595
|
-
async function
|
|
47614
|
+
async function Wv(t, e, n, r = 1) {
|
|
47596
47615
|
if (0 === n.length) return {
|
|
47597
47616
|
layoutPaths: [],
|
|
47598
47617
|
handler: t,
|
|
47599
47618
|
data: e
|
|
47600
47619
|
};
|
|
47601
|
-
const i = await t.save(e.slides), o = await l.default.loadAsync(i), a =
|
|
47620
|
+
const i = await t.save(e.slides), o = await l.default.loadAsync(i), a = Uv(o), s = [];
|
|
47602
47621
|
for (let t = 0; t < n.length; t++) {
|
|
47603
47622
|
const e = n[t], i = a + t + 1, l = `ppt/slideLayouts/slideLayout${i}.xml`;
|
|
47604
|
-
o.file(l,
|
|
47623
|
+
o.file(l, Ov(e)), o.file(`ppt/slideLayouts/_rels/slideLayout${i}.xml.rels`, $v(r)), await Xv(o, i, r), await zv(o, i), s.push(l);
|
|
47605
47624
|
}
|
|
47606
47625
|
const c = await o.generateAsync({ type: "arraybuffer" }), d = new ey();
|
|
47607
47626
|
return {
|
|
@@ -47610,7 +47629,7 @@ async function Gv(t, e, n, r = 1) {
|
|
|
47610
47629
|
data: await d.load(c)
|
|
47611
47630
|
};
|
|
47612
47631
|
}
|
|
47613
|
-
function
|
|
47632
|
+
function Hv(t, e) {
|
|
47614
47633
|
const n = e.toLowerCase(), r = t.layoutOptions?.find((t) => t.name.toLowerCase() === n);
|
|
47615
47634
|
if (r) return r;
|
|
47616
47635
|
if (t.slideMasters) for (const r of t.slideMasters) {
|
|
@@ -47621,11 +47640,11 @@ function Wv(t, e) {
|
|
|
47621
47640
|
};
|
|
47622
47641
|
}
|
|
47623
47642
|
}
|
|
47624
|
-
function
|
|
47643
|
+
function Vv(t, e) {
|
|
47625
47644
|
const n = t.layoutOptions?.find((t) => t.type === e);
|
|
47626
47645
|
if (n) return n;
|
|
47627
47646
|
}
|
|
47628
|
-
function
|
|
47647
|
+
function Yv(t) {
|
|
47629
47648
|
if (!t || "" === t.trim()) return [];
|
|
47630
47649
|
const e = [], n = /([MmLlHhVvCcSsQqTtAaZz])([^MmLlHhVvCcSsQqTtAaZz]*)/g;
|
|
47631
47650
|
let r;
|
|
@@ -47653,14 +47672,14 @@ function Vv(t) {
|
|
|
47653
47672
|
}
|
|
47654
47673
|
return e;
|
|
47655
47674
|
}
|
|
47656
|
-
function
|
|
47675
|
+
function qv(t) {
|
|
47657
47676
|
return t.map((t) => {
|
|
47658
47677
|
if ("Z" === t.type) return "Z";
|
|
47659
47678
|
const e = t.args.map((t) => Number.isInteger(t) ? t.toString() : t.toFixed(4)).join(" ");
|
|
47660
47679
|
return `${t.type} ${e}`;
|
|
47661
47680
|
}).join(" ");
|
|
47662
47681
|
}
|
|
47663
|
-
function
|
|
47682
|
+
function Kv(t) {
|
|
47664
47683
|
switch (t) {
|
|
47665
47684
|
case "M":
|
|
47666
47685
|
case "L":
|
|
@@ -47674,10 +47693,10 @@ function qv(t) {
|
|
|
47674
47693
|
default: return 0;
|
|
47675
47694
|
}
|
|
47676
47695
|
}
|
|
47677
|
-
function
|
|
47696
|
+
function Zv(t) {
|
|
47678
47697
|
const e = [];
|
|
47679
47698
|
for (const n of t) {
|
|
47680
|
-
const t =
|
|
47699
|
+
const t = Kv(n.type);
|
|
47681
47700
|
if (0 === t || n.args.length <= t) {
|
|
47682
47701
|
e.push({
|
|
47683
47702
|
type: n.type,
|
|
@@ -47696,19 +47715,19 @@ function Kv(t) {
|
|
|
47696
47715
|
}
|
|
47697
47716
|
return e;
|
|
47698
47717
|
}
|
|
47699
|
-
function
|
|
47718
|
+
function Jv(t, e, n) {
|
|
47700
47719
|
if (!e || "" === e.trim()) throw new Error("newShapeType must be a non-empty string");
|
|
47701
47720
|
t.shapeType = e, t.shapeAdjustments = void 0 !== n ? { ...n } : void 0, t.pathData = void 0, t.pathWidth = void 0, t.pathHeight = void 0, t.customGeometryPaths = void 0, t.adjustmentHandles = void 0;
|
|
47702
47721
|
}
|
|
47703
|
-
function
|
|
47722
|
+
function Qv(t, e, n, r) {
|
|
47704
47723
|
if (!e || "" === e.trim()) throw new Error("svgPath must be a non-empty string");
|
|
47705
47724
|
t.shapeType = void 0, t.shapeAdjustments = void 0, t.adjustmentHandles = void 0, t.pathData = e, t.pathWidth = n, t.pathHeight = r, t.customGeometryPaths = void 0;
|
|
47706
47725
|
}
|
|
47707
|
-
function
|
|
47726
|
+
function tw(t, e, n) {
|
|
47708
47727
|
const r = Math.max(0, Math.min(1, n));
|
|
47709
47728
|
if (0 === r) return t;
|
|
47710
47729
|
if (1 === r) return e;
|
|
47711
|
-
const i =
|
|
47730
|
+
const i = Zv(Yv(t)), o = Zv(Yv(e));
|
|
47712
47731
|
if (0 === i.length && 0 === o.length) return "";
|
|
47713
47732
|
if (0 === i.length) return e;
|
|
47714
47733
|
if (0 === o.length) return t;
|
|
@@ -47719,7 +47738,7 @@ function Qv(t, e, n) {
|
|
|
47719
47738
|
const t = Array.from({ length: n.args.length }).fill(0);
|
|
47720
47739
|
s.push({
|
|
47721
47740
|
type: n.type,
|
|
47722
|
-
args: n.args.map((e, n) =>
|
|
47741
|
+
args: n.args.map((e, n) => ew(t[n], e, r))
|
|
47723
47742
|
});
|
|
47724
47743
|
continue;
|
|
47725
47744
|
}
|
|
@@ -47727,7 +47746,7 @@ function Qv(t, e, n) {
|
|
|
47727
47746
|
const t = Array.from({ length: e.args.length }).fill(0);
|
|
47728
47747
|
s.push({
|
|
47729
47748
|
type: e.type,
|
|
47730
|
-
args: e.args.map((e, n) =>
|
|
47749
|
+
args: e.args.map((e, n) => ew(e, t[n], r))
|
|
47731
47750
|
});
|
|
47732
47751
|
continue;
|
|
47733
47752
|
}
|
|
@@ -47743,7 +47762,7 @@ function Qv(t, e, n) {
|
|
|
47743
47762
|
const t = "Z" !== e.type ? e : n, i = "Z" === e.type, o = Array.from({ length: t.args.length }).fill(0);
|
|
47744
47763
|
s.push({
|
|
47745
47764
|
type: t.type,
|
|
47746
|
-
args: t.args.map((t, e) => i ?
|
|
47765
|
+
args: t.args.map((t, e) => i ? ew(o[e], t, r) : ew(t, o[e], r))
|
|
47747
47766
|
});
|
|
47748
47767
|
continue;
|
|
47749
47768
|
}
|
|
@@ -47751,7 +47770,7 @@ function Qv(t, e, n) {
|
|
|
47751
47770
|
const t = Math.max(e.args.length, n.args.length), i = [];
|
|
47752
47771
|
for (let o = 0; o < t; o++) {
|
|
47753
47772
|
const t = o < e.args.length ? e.args[o] : 0, a = o < n.args.length ? n.args[o] : 0;
|
|
47754
|
-
i.push(
|
|
47773
|
+
i.push(ew(t, a, r));
|
|
47755
47774
|
}
|
|
47756
47775
|
s.push({
|
|
47757
47776
|
type: e.type,
|
|
@@ -47762,25 +47781,25 @@ function Qv(t, e, n) {
|
|
|
47762
47781
|
const a = r < .5 ? e.type : n.type, l = Math.max(e.args.length, n.args.length), c = [];
|
|
47763
47782
|
for (let t = 0; t < l; t++) {
|
|
47764
47783
|
const i = t < e.args.length ? e.args[t] : 0, o = t < n.args.length ? n.args[t] : 0;
|
|
47765
|
-
c.push(
|
|
47784
|
+
c.push(ew(i, o, r));
|
|
47766
47785
|
}
|
|
47767
47786
|
s.push({
|
|
47768
47787
|
type: a,
|
|
47769
47788
|
args: c
|
|
47770
47789
|
});
|
|
47771
47790
|
}
|
|
47772
|
-
return
|
|
47791
|
+
return qv(s);
|
|
47773
47792
|
}
|
|
47774
|
-
function
|
|
47793
|
+
function ew(t, e, n) {
|
|
47775
47794
|
return t + (e - t) * n;
|
|
47776
47795
|
}
|
|
47777
|
-
function ew(t) {
|
|
47778
|
-
return Kv(Vv(t));
|
|
47779
|
-
}
|
|
47780
47796
|
function nw(t) {
|
|
47781
|
-
return Yv(t);
|
|
47797
|
+
return Zv(Yv(t));
|
|
47798
|
+
}
|
|
47799
|
+
function rw(t) {
|
|
47800
|
+
return qv(t);
|
|
47782
47801
|
}
|
|
47783
|
-
var
|
|
47802
|
+
var iw = class t {
|
|
47784
47803
|
_text;
|
|
47785
47804
|
_options = {};
|
|
47786
47805
|
constructor(t) {
|
|
@@ -47846,7 +47865,7 @@ var rw = class t {
|
|
|
47846
47865
|
build() {
|
|
47847
47866
|
return Me(this._text, this._options);
|
|
47848
47867
|
}
|
|
47849
|
-
},
|
|
47868
|
+
}, ow = class t {
|
|
47850
47869
|
_shapeType;
|
|
47851
47870
|
_options = {};
|
|
47852
47871
|
constructor(t) {
|
|
@@ -47908,7 +47927,7 @@ var rw = class t {
|
|
|
47908
47927
|
build() {
|
|
47909
47928
|
return Ae(this._shapeType, this._options);
|
|
47910
47929
|
}
|
|
47911
|
-
},
|
|
47930
|
+
}, aw = class t {
|
|
47912
47931
|
_source;
|
|
47913
47932
|
_options = {};
|
|
47914
47933
|
constructor(t) {
|
|
@@ -47941,7 +47960,7 @@ var rw = class t {
|
|
|
47941
47960
|
build() {
|
|
47942
47961
|
return Fe(this._source, this._options);
|
|
47943
47962
|
}
|
|
47944
|
-
},
|
|
47963
|
+
}, sw = class t {
|
|
47945
47964
|
_input;
|
|
47946
47965
|
_options = {};
|
|
47947
47966
|
constructor() {
|
|
@@ -47989,7 +48008,7 @@ var rw = class t {
|
|
|
47989
48008
|
build() {
|
|
47990
48009
|
return Le(this._input, this._options);
|
|
47991
48010
|
}
|
|
47992
|
-
},
|
|
48011
|
+
}, lw = class t {
|
|
47993
48012
|
_chartType;
|
|
47994
48013
|
_input;
|
|
47995
48014
|
_options = {};
|
|
@@ -48033,7 +48052,7 @@ var rw = class t {
|
|
|
48033
48052
|
build() {
|
|
48034
48053
|
return De(this._chartType, this._input, this._options);
|
|
48035
48054
|
}
|
|
48036
|
-
},
|
|
48055
|
+
}, cw = class t {
|
|
48037
48056
|
_options = {};
|
|
48038
48057
|
constructor() {}
|
|
48039
48058
|
static create() {
|
|
@@ -48078,7 +48097,7 @@ var rw = class t {
|
|
|
48078
48097
|
build() {
|
|
48079
48098
|
return Ie(this._options);
|
|
48080
48099
|
}
|
|
48081
|
-
},
|
|
48100
|
+
}, dw = class t {
|
|
48082
48101
|
_mediaType;
|
|
48083
48102
|
_source;
|
|
48084
48103
|
_options = {};
|
|
@@ -48124,7 +48143,7 @@ var rw = class t {
|
|
|
48124
48143
|
build() {
|
|
48125
48144
|
return Be(this._mediaType, this._source, this._options);
|
|
48126
48145
|
}
|
|
48127
|
-
},
|
|
48146
|
+
}, hw = class t {
|
|
48128
48147
|
_children = [];
|
|
48129
48148
|
_options = {};
|
|
48130
48149
|
constructor() {}
|
|
@@ -48155,32 +48174,32 @@ var rw = class t {
|
|
|
48155
48174
|
build() {
|
|
48156
48175
|
return Re(this._children, this._options);
|
|
48157
48176
|
}
|
|
48158
|
-
},
|
|
48159
|
-
function gw(t) {
|
|
48160
|
-
return Math.round(t * hw);
|
|
48161
|
-
}
|
|
48177
|
+
}, pw = 96, uw = 72, mw = 9525, fw = 914400, gw = 12700;
|
|
48162
48178
|
function yw(t) {
|
|
48163
|
-
return Math.round(t
|
|
48179
|
+
return Math.round(t * pw);
|
|
48164
48180
|
}
|
|
48165
48181
|
function xw(t) {
|
|
48166
|
-
return Math.round(t /
|
|
48182
|
+
return Math.round(t / 2.54 * pw);
|
|
48167
48183
|
}
|
|
48168
48184
|
function bw(t) {
|
|
48169
|
-
return Math.round(t /
|
|
48185
|
+
return Math.round(t / 25.4 * pw);
|
|
48170
48186
|
}
|
|
48171
48187
|
function Sw(t) {
|
|
48172
|
-
return Math.round(t / uw);
|
|
48188
|
+
return Math.round(t / uw * pw);
|
|
48173
48189
|
}
|
|
48174
48190
|
function vw(t) {
|
|
48175
|
-
return Math.round(t
|
|
48191
|
+
return Math.round(t / mw);
|
|
48176
48192
|
}
|
|
48177
48193
|
function ww(t) {
|
|
48178
48194
|
return Math.round(t * mw);
|
|
48179
48195
|
}
|
|
48180
48196
|
function Tw(t) {
|
|
48181
|
-
return Math.round(t
|
|
48197
|
+
return Math.round(t * fw);
|
|
48182
48198
|
}
|
|
48183
|
-
|
|
48199
|
+
function Cw(t) {
|
|
48200
|
+
return Math.round(t / 2.54 * fw);
|
|
48201
|
+
}
|
|
48202
|
+
var kw = {
|
|
48184
48203
|
WIDESCREEN_16_9: {
|
|
48185
48204
|
width: 12192e3,
|
|
48186
48205
|
height: 6858e3
|
|
@@ -48209,7 +48228,7 @@ var Cw = {
|
|
|
48209
48228
|
width: 7772400,
|
|
48210
48229
|
height: 10058400
|
|
48211
48230
|
}
|
|
48212
|
-
},
|
|
48231
|
+
}, _w = {
|
|
48213
48232
|
OFFICE: {
|
|
48214
48233
|
name: "Office Theme",
|
|
48215
48234
|
colors: {
|
|
@@ -48379,10 +48398,10 @@ var Cw = {
|
|
|
48379
48398
|
}
|
|
48380
48399
|
}
|
|
48381
48400
|
};
|
|
48382
|
-
function
|
|
48383
|
-
return
|
|
48401
|
+
function Pw(t) {
|
|
48402
|
+
return _w[t];
|
|
48384
48403
|
}
|
|
48385
|
-
var
|
|
48404
|
+
var Mw = {
|
|
48386
48405
|
"image/png": "png",
|
|
48387
48406
|
"image/jpeg": "jpg",
|
|
48388
48407
|
"image/jpg": "jpg",
|
|
@@ -48392,10 +48411,10 @@ var Pw = {
|
|
|
48392
48411
|
"image/bmp": "bmp",
|
|
48393
48412
|
"image/tiff": "tiff"
|
|
48394
48413
|
};
|
|
48395
|
-
function
|
|
48414
|
+
function Aw(t) {
|
|
48396
48415
|
const e = t.match(/^data:([^;]+);base64,(.+)$/s);
|
|
48397
48416
|
if (!e) throw new Error("Invalid data URL format");
|
|
48398
|
-
const n = e[1].toLowerCase(), r =
|
|
48417
|
+
const n = e[1].toLowerCase(), r = Mw[n] ?? function(t) {
|
|
48399
48418
|
const e = t.split("/");
|
|
48400
48419
|
return 2 === e.length ? e[1].replace(/[^a-z0-9]/g, "") : "bin";
|
|
48401
48420
|
}(n), i = e[2], o = atob(i), a = new Uint8Array(o.length);
|
|
@@ -48405,10 +48424,10 @@ function Mw(t) {
|
|
|
48405
48424
|
ext: r
|
|
48406
48425
|
};
|
|
48407
48426
|
}
|
|
48408
|
-
function
|
|
48427
|
+
function Iw(t, e) {
|
|
48409
48428
|
return `image-${String(t).padStart(3, "0")}.${e.startsWith(".") ? e.slice(1) : e}`;
|
|
48410
48429
|
}
|
|
48411
|
-
var
|
|
48430
|
+
var Fw = class {
|
|
48412
48431
|
constructor(t, e, n) {
|
|
48413
48432
|
this.folderName = e, this.fs = n, this.resolvedMediaDir = `${t}/${this.folderName}`;
|
|
48414
48433
|
}
|
|
@@ -48422,12 +48441,12 @@ var Iw = class {
|
|
|
48422
48441
|
return this.resolvedMediaDir;
|
|
48423
48442
|
}
|
|
48424
48443
|
async saveImage(t, e) {
|
|
48425
|
-
const n =
|
|
48444
|
+
const n = Aw(t);
|
|
48426
48445
|
return this.saveImageBytes(n.bytes, n.ext, e);
|
|
48427
48446
|
}
|
|
48428
48447
|
async saveImageBytes(t, e, n) {
|
|
48429
48448
|
await this.ensureInitialized(), this.imageIndex += 1;
|
|
48430
|
-
const r =
|
|
48449
|
+
const r = Iw(this.imageIndex, e), i = n ? `${n}-${r}` : r;
|
|
48431
48450
|
if (this.fs) {
|
|
48432
48451
|
const e = `${this.resolvedMediaDir}/${i}`;
|
|
48433
48452
|
await this.fs.writeBinaryFile(e, t);
|
|
@@ -48438,32 +48457,32 @@ var Iw = class {
|
|
|
48438
48457
|
this.initialized || (this.fs && await this.fs.createFolder(this.resolvedMediaDir), this.initialized = !0);
|
|
48439
48458
|
}
|
|
48440
48459
|
};
|
|
48441
|
-
function
|
|
48460
|
+
function Lw(t) {
|
|
48442
48461
|
return null == t ? "" : String(t).replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
48443
48462
|
}
|
|
48444
|
-
var
|
|
48463
|
+
var Dw = [
|
|
48445
48464
|
"http://",
|
|
48446
48465
|
"https://",
|
|
48447
48466
|
"mailto:",
|
|
48448
48467
|
"tel:",
|
|
48449
48468
|
"#"
|
|
48450
48469
|
];
|
|
48451
|
-
function
|
|
48470
|
+
function Bw(t) {
|
|
48452
48471
|
return t.trim().replace(/\\/g, "/");
|
|
48453
48472
|
}
|
|
48454
|
-
function
|
|
48455
|
-
const e =
|
|
48473
|
+
function Rw(t) {
|
|
48474
|
+
const e = Bw(t), n = e.lastIndexOf("/");
|
|
48456
48475
|
return n < 0 ? "." : 0 === n ? "/" : e.slice(0, n);
|
|
48457
48476
|
}
|
|
48458
|
-
function
|
|
48477
|
+
function Nw(t, e) {
|
|
48459
48478
|
if (e) return e;
|
|
48460
48479
|
if (!t) return;
|
|
48461
|
-
const n =
|
|
48480
|
+
const n = Bw(t), r = n.lastIndexOf(".");
|
|
48462
48481
|
return r < 0 ? `${n}.md` : `${n.slice(0, r)}.md`;
|
|
48463
48482
|
}
|
|
48464
|
-
var
|
|
48483
|
+
var Ew = class {
|
|
48465
48484
|
constructor(t, e, n) {
|
|
48466
|
-
this.outputDir = t, this.options = e, this.fs = n, this.mediaContext = new
|
|
48485
|
+
this.outputDir = t, this.options = e, this.fs = n, this.mediaContext = new Fw(t, e.mediaFolderName, n);
|
|
48467
48486
|
}
|
|
48468
48487
|
mediaContext;
|
|
48469
48488
|
buildFrontMatter(t) {
|
|
@@ -48478,7 +48497,7 @@ var Nw = class {
|
|
|
48478
48497
|
if (!this.fs) throw new Error("FileSystemAdapter is required for writing output files. Provide one via the constructor or use convert() without outputPath.");
|
|
48479
48498
|
await this.fs.writeFile(e, t);
|
|
48480
48499
|
}
|
|
48481
|
-
},
|
|
48500
|
+
}, jw = class {
|
|
48482
48501
|
supportedTypes = ["chart"];
|
|
48483
48502
|
async process(t, e) {
|
|
48484
48503
|
if ("chart" !== t.type) return null;
|
|
@@ -48582,7 +48601,7 @@ var Nw = class {
|
|
|
48582
48601
|
humanizeType(t) {
|
|
48583
48602
|
return t.replace(/([a-z])([A-Z0-9])/g, "$1 $2").replace(/^./, (t) => t.toUpperCase());
|
|
48584
48603
|
}
|
|
48585
|
-
},
|
|
48604
|
+
}, Ow = class {
|
|
48586
48605
|
processors = /* @__PURE__ */ new Map();
|
|
48587
48606
|
register(t) {
|
|
48588
48607
|
for (const e of t.supportedTypes) this.processors.set(e, t);
|
|
@@ -48604,7 +48623,7 @@ var Nw = class {
|
|
|
48604
48623
|
if (void 0 !== t.targetSlideIndex) return `\n\n*${`Jump to slide ${t.targetSlideIndex + 1}`}*`;
|
|
48605
48624
|
return t.action ? `\n\n*${t.action}*` : "";
|
|
48606
48625
|
}
|
|
48607
|
-
},
|
|
48626
|
+
}, $w = class {
|
|
48608
48627
|
supportedTypes = [
|
|
48609
48628
|
"zoom",
|
|
48610
48629
|
"contentPart",
|
|
@@ -48635,7 +48654,7 @@ var Nw = class {
|
|
|
48635
48654
|
renderContentPart(t) {
|
|
48636
48655
|
return t.inkStrokes && t.inkStrokes.length > 0 ? `*[Ink Content: ${t.inkStrokes.length} stroke${1 === t.inkStrokes.length ? "" : "s"}]*` : "*[Content Part]*";
|
|
48637
48656
|
}
|
|
48638
|
-
},
|
|
48657
|
+
}, Uw = class {
|
|
48639
48658
|
supportedTypes = ["group"];
|
|
48640
48659
|
async process(t, e) {
|
|
48641
48660
|
if ("group" !== t.type) return null;
|
|
@@ -48644,7 +48663,7 @@ var Nw = class {
|
|
|
48644
48663
|
const r = await e.processElements(n.children);
|
|
48645
48664
|
return 0 === r.length ? null : r.join("\n\n");
|
|
48646
48665
|
}
|
|
48647
|
-
},
|
|
48666
|
+
}, Xw = class {
|
|
48648
48667
|
supportedTypes = ["image", "picture"];
|
|
48649
48668
|
async process(t, e) {
|
|
48650
48669
|
if (!Yt(t)) return null;
|
|
@@ -48653,7 +48672,7 @@ var Nw = class {
|
|
|
48653
48672
|
const t = Boolean(n.imageData), r = n.imageData ? n.imageData.substring(0, 80) : "undefined", i = `Image extraction failed on slide ${e.slideNumber}: id="${n.id}", imagePath="${n.imagePath ?? "unknown"}", hasImageData=${t}, imageDataPreview="${r}", hasSvgData=${Boolean(n.svgData)}`;
|
|
48654
48673
|
return console.error(`[image-processor] ${i}`), `> **[Image extraction failed]** ${n.id} (slide ${e.slideNumber})`;
|
|
48655
48674
|
}
|
|
48656
|
-
const o =
|
|
48675
|
+
const o = Lw(r), a = Lw(i);
|
|
48657
48676
|
if (e.semanticMode) return ``;
|
|
48658
48677
|
if (e.layoutScale) return `<img src="${a}" alt="${o}" style="max-width:100%;height:auto">`;
|
|
48659
48678
|
const s = this.computeDisplaySize(t.width, t.height);
|
|
@@ -48682,7 +48701,7 @@ var Nw = class {
|
|
|
48682
48701
|
const e = t.replace(/&#x[0-9A-Fa-f]+;/g, " ").replace(/&#\d+;/g, " ").replace(/&[a-zA-Z]+;/g, " ").replace(/[\r\n]+/g, " ").replace(/\s+/g, " ").trim();
|
|
48683
48702
|
return e.length <= 100 ? e : `${e.slice(0, 100).trimEnd()}…`;
|
|
48684
48703
|
}
|
|
48685
|
-
},
|
|
48704
|
+
}, zw = class {
|
|
48686
48705
|
supportedTypes = ["ink"];
|
|
48687
48706
|
async process(t, e) {
|
|
48688
48707
|
if ("ink" !== t.type) return null;
|
|
@@ -48697,7 +48716,7 @@ var Nw = class {
|
|
|
48697
48716
|
}
|
|
48698
48717
|
return `*[Ink Drawing: ${r.join(" | ")}]*`;
|
|
48699
48718
|
}
|
|
48700
|
-
},
|
|
48719
|
+
}, Gw = class {
|
|
48701
48720
|
supportedTypes = ["media"];
|
|
48702
48721
|
async process(t, e) {
|
|
48703
48722
|
if ("media" !== t.type) return null;
|
|
@@ -48724,7 +48743,7 @@ var Nw = class {
|
|
|
48724
48743
|
const e = Math.floor(t / 60), n = Math.round(t % 60);
|
|
48725
48744
|
return `${e}:${String(n).padStart(2, "0")}`;
|
|
48726
48745
|
}
|
|
48727
|
-
},
|
|
48746
|
+
}, Ww = class {
|
|
48728
48747
|
supportedTypes = ["ole"];
|
|
48729
48748
|
async process(t, e) {
|
|
48730
48749
|
if ("ole" !== t.type) return null;
|
|
@@ -48737,27 +48756,27 @@ var Nw = class {
|
|
|
48737
48756
|
} catch {}
|
|
48738
48757
|
return i.join("\n\n");
|
|
48739
48758
|
}
|
|
48740
|
-
},
|
|
48759
|
+
}, Hw = new Set([
|
|
48741
48760
|
"process",
|
|
48742
48761
|
"cycle",
|
|
48743
48762
|
"timeline"
|
|
48744
|
-
]),
|
|
48763
|
+
]), Vw = new Set([
|
|
48745
48764
|
"hierarchy",
|
|
48746
48765
|
"pyramid",
|
|
48747
48766
|
"funnel"
|
|
48748
|
-
]),
|
|
48767
|
+
]), Yw = new Set([
|
|
48749
48768
|
"list",
|
|
48750
48769
|
"matrix",
|
|
48751
48770
|
"gear",
|
|
48752
48771
|
"target"
|
|
48753
|
-
]),
|
|
48772
|
+
]), qw = class {
|
|
48754
48773
|
supportedTypes = ["smartArt"];
|
|
48755
48774
|
async process(t, e) {
|
|
48756
48775
|
if ("smartArt" !== t.type) return null;
|
|
48757
48776
|
const n = t.smartArtData;
|
|
48758
48777
|
if (!n || 0 === n.nodes.length) return "*[SmartArt: no nodes]*";
|
|
48759
48778
|
const r = this.resolveRoots(n.nodes), i = n.resolvedLayoutType ?? "unknown", o = [`*[SmartArt: ${i}]*`];
|
|
48760
|
-
return
|
|
48779
|
+
return Vw.has(i) ? o.push(this.renderNestedList(r, 0)) : Hw.has(i) ? o.push(this.renderOrderedSequence(r)) : Yw.has(i) ? o.push(this.renderBulletList(r)) : "relationship" === i ? o.push(this.renderRelationshipText(r)) : o.push(this.renderBulletList(r)), o.join("\n\n");
|
|
48761
48780
|
}
|
|
48762
48781
|
resolveRoots(t) {
|
|
48763
48782
|
if (t.some((t) => Array.isArray(t.children) && t.children.length > 0)) return t;
|
|
@@ -48795,7 +48814,7 @@ var Nw = class {
|
|
|
48795
48814
|
for (const n of t) e.push(n), n.children && n.children.length > 0 && e.push(...this.flattenNodes(n.children));
|
|
48796
48815
|
return e;
|
|
48797
48816
|
}
|
|
48798
|
-
},
|
|
48817
|
+
}, Kw = new Set([
|
|
48799
48818
|
"black",
|
|
48800
48819
|
"silver",
|
|
48801
48820
|
"gray",
|
|
@@ -48819,12 +48838,12 @@ var Nw = class {
|
|
|
48819
48838
|
"initial",
|
|
48820
48839
|
"unset"
|
|
48821
48840
|
]);
|
|
48822
|
-
function
|
|
48841
|
+
function Zw(t) {
|
|
48823
48842
|
if ("string" != typeof t) return;
|
|
48824
48843
|
const e = t.trim();
|
|
48825
|
-
return 0 !== e.length && (/^#[0-9a-f]{3,8}$/i.test(e) ||
|
|
48844
|
+
return 0 !== e.length && (/^#[0-9a-f]{3,8}$/i.test(e) || Kw.has(e.toLowerCase())) ? e : void 0;
|
|
48826
48845
|
}
|
|
48827
|
-
var
|
|
48846
|
+
var Jw = class {
|
|
48828
48847
|
supportedTypes = ["table"];
|
|
48829
48848
|
async process(t, e) {
|
|
48830
48849
|
if ("table" !== t.type) return null;
|
|
@@ -48855,12 +48874,12 @@ var Zw = class {
|
|
|
48855
48874
|
const i = [];
|
|
48856
48875
|
e > 1 && i.push(` colspan="${e}"`), n > 1 && i.push(` rowspan="${n}"`);
|
|
48857
48876
|
const o = this.buildCellCss(t.style, r);
|
|
48858
|
-
return o && i.push(` style="${
|
|
48877
|
+
return o && i.push(` style="${Lw(o)}"`), i.join("");
|
|
48859
48878
|
}
|
|
48860
48879
|
buildCellCss(t, e) {
|
|
48861
|
-
const n = [], r =
|
|
48880
|
+
const n = [], r = Zw(t?.backgroundColor);
|
|
48862
48881
|
r && n.push(`background:${r}`), t?.align && /^[a-zA-Z]+$/.test(t.align) && n.push(`text-align:${t.align}`), t?.vAlign && /^[a-zA-Z]+$/.test(t.vAlign) && n.push(`vertical-align:${t.vAlign}`), t?.fontSize && n.push(`font-size:${Math.round(t.fontSize)}px`);
|
|
48863
|
-
const i =
|
|
48882
|
+
const i = Zw(t?.color);
|
|
48864
48883
|
i && n.push(`color:${i}`), (t?.bold || e) && n.push("font-weight:bold"), t?.italic && n.push("font-style:italic");
|
|
48865
48884
|
const o = this.buildBorderCss(t);
|
|
48866
48885
|
o && n.push(o);
|
|
@@ -48869,15 +48888,15 @@ var Zw = class {
|
|
|
48869
48888
|
}
|
|
48870
48889
|
buildBorderCss(t) {
|
|
48871
48890
|
if (!t) return "";
|
|
48872
|
-
const e = [], n =
|
|
48891
|
+
const e = [], n = Zw(t.borderTopColor);
|
|
48873
48892
|
t.borderTopWidth && n && e.push(`border-top:${Math.round(t.borderTopWidth)}px solid ${n}`);
|
|
48874
|
-
const r =
|
|
48893
|
+
const r = Zw(t.borderBottomColor);
|
|
48875
48894
|
t.borderBottomWidth && r && e.push(`border-bottom:${Math.round(t.borderBottomWidth)}px solid ${r}`);
|
|
48876
|
-
const i =
|
|
48895
|
+
const i = Zw(t.borderLeftColor);
|
|
48877
48896
|
t.borderLeftWidth && i && e.push(`border-left:${Math.round(t.borderLeftWidth)}px solid ${i}`);
|
|
48878
|
-
const o =
|
|
48897
|
+
const o = Zw(t.borderRightColor);
|
|
48879
48898
|
t.borderRightWidth && o && e.push(`border-right:${Math.round(t.borderRightWidth)}px solid ${o}`);
|
|
48880
|
-
const a =
|
|
48899
|
+
const a = Zw(t.borderColor);
|
|
48881
48900
|
return 0 === e.length && a ? `border:1px solid ${a}` : e.join(";");
|
|
48882
48901
|
}
|
|
48883
48902
|
buildPaddingCss(t) {
|
|
@@ -48897,7 +48916,7 @@ var Zw = class {
|
|
|
48897
48916
|
const e = this.escapeHtml(r.text);
|
|
48898
48917
|
if (!e) continue;
|
|
48899
48918
|
const i = this.buildRunCss(r, t.style);
|
|
48900
|
-
i ? n.push(`<span style="${
|
|
48919
|
+
i ? n.push(`<span style="${Lw(i)}">${e}</span>`) : n.push(e);
|
|
48901
48920
|
}
|
|
48902
48921
|
return n.join("");
|
|
48903
48922
|
}
|
|
@@ -48912,7 +48931,7 @@ var Zw = class {
|
|
|
48912
48931
|
t && r.push(`font-family:${t}`);
|
|
48913
48932
|
}
|
|
48914
48933
|
if (n.fontSize && n.fontSize !== e?.fontSize && r.push(`font-size:${Math.round(n.fontSize)}px`), n.color && n.color !== e?.color) {
|
|
48915
|
-
const t =
|
|
48934
|
+
const t = Zw(n.color);
|
|
48916
48935
|
t && r.push(`color:${t}`);
|
|
48917
48936
|
}
|
|
48918
48937
|
return n.bold && !e?.bold && r.push("font-weight:bold"), n.italic && !e?.italic && r.push("font-style:italic"), n.underline && r.push("text-decoration:underline"), n.strikethrough && r.push("text-decoration:line-through"), r.join(";");
|
|
@@ -48977,9 +48996,9 @@ var Zw = class {
|
|
|
48977
48996
|
escapeMarkdownTableCell(t) {
|
|
48978
48997
|
return t.replace(/\|/g, "\\|").replace(/\n+/g, " ").trim();
|
|
48979
48998
|
}
|
|
48980
|
-
},
|
|
48981
|
-
function
|
|
48982
|
-
const a = n?.bodyInsetLeft ? n.bodyInsetLeft * o : Math.round(r *
|
|
48999
|
+
}, Qw = .06;
|
|
49000
|
+
function tT(t, e, n, r, i, o = 1) {
|
|
49001
|
+
const a = n?.bodyInsetLeft ? n.bodyInsetLeft * o : Math.round(r * Qw), s = n?.bodyInsetRight ? n.bodyInsetRight * o : Math.round(r * Qw), l = n?.bodyInsetTop ? n.bodyInsetTop * o : Math.round(i * Qw), c = n?.bodyInsetBottom ? n.bodyInsetBottom * o : Math.round(i * Qw), d = r - a - s;
|
|
48983
49002
|
if (d <= 0) return;
|
|
48984
49003
|
const p = function(t, e, n, r) {
|
|
48985
49004
|
const i = [];
|
|
@@ -48987,7 +49006,7 @@ function Qw(t, e, n, r, i, o = 1) {
|
|
|
48987
49006
|
const e = o[0]?.style?.align;
|
|
48988
49007
|
let a = [], s = 0, l = 0;
|
|
48989
49008
|
for (const c of o) {
|
|
48990
|
-
t.font =
|
|
49009
|
+
t.font = eT(c.style, r);
|
|
48991
49010
|
const o = 1.2 * ((c.style.fontSize ?? 18) * r), d = c.text.split(/(?<=\s)(?=\S)|(?<=\S)(?=\s)/);
|
|
48992
49011
|
for (const r of d) {
|
|
48993
49012
|
if (!r) continue;
|
|
@@ -49041,15 +49060,15 @@ function Qw(t, e, n, r, i, o = 1) {
|
|
|
49041
49060
|
const r = e.align ?? n?.align ?? "left";
|
|
49042
49061
|
let i;
|
|
49043
49062
|
i = "center" === r ? a + (d - e.width) / 2 : "right" === r ? a + d - e.width : a;
|
|
49044
|
-
for (const n of e.runs) t.font =
|
|
49063
|
+
for (const n of e.runs) t.font = eT(n.style, o), t.fillStyle = n.style.color ?? "#000000", t.fillText(n.text, i, g), i += n.measuredWidth;
|
|
49045
49064
|
g += .3 * e.height;
|
|
49046
49065
|
}
|
|
49047
49066
|
}
|
|
49048
|
-
function
|
|
49067
|
+
function eT(t, e) {
|
|
49049
49068
|
const n = (t.fontSize ?? 18) * e, r = t.bold ? "bold" : "normal";
|
|
49050
49069
|
return `${t.italic ? "italic" : "normal"} ${r} ${n}px ${t.fontFamily ? Mh(t.fontFamily) : "sans-serif"}`;
|
|
49051
49070
|
}
|
|
49052
|
-
function
|
|
49071
|
+
function nT(t) {
|
|
49053
49072
|
const e = t.shapeStyle;
|
|
49054
49073
|
if (!e) return null;
|
|
49055
49074
|
if (!function(t) {
|
|
@@ -49059,7 +49078,7 @@ function eT(t) {
|
|
|
49059
49078
|
if ("image" === t.fillMode) return Boolean(t.fillImageUrl);
|
|
49060
49079
|
if (t.fillColor && "transparent" !== t.fillColor) return !0;
|
|
49061
49080
|
return !1;
|
|
49062
|
-
}(e) && !
|
|
49081
|
+
}(e) && !oT(e)) return null;
|
|
49063
49082
|
let n = Math.round(t.width), r = Math.round(t.height);
|
|
49064
49083
|
if (n < 4 || r < 4) return null;
|
|
49065
49084
|
const i = (t.textSegments?.length ?? 0) > 0 ? 800 : 400;
|
|
@@ -49091,11 +49110,11 @@ function eT(t) {
|
|
|
49091
49110
|
void 0 !== e.fillOpacity && e.fillOpacity < 1 && (t.globalAlpha = e.fillOpacity);
|
|
49092
49111
|
}(s, e, n, r), t.pathData) {
|
|
49093
49112
|
const i = n / ((t.pathWidth ?? n) || 1), o = r / ((t.pathHeight ?? r) || 1), a = new Path2D(t.pathData);
|
|
49094
|
-
s.save(), s.scale(i, o), s.fill(a),
|
|
49095
|
-
} else
|
|
49096
|
-
return s.globalAlpha = 1, t.textSegments?.length &&
|
|
49113
|
+
s.save(), s.scale(i, o), s.fill(a), oT(e) && (iT(s, e), s.stroke(a)), s.restore();
|
|
49114
|
+
} else rT(s, t.shapeType, n, r), s.fill(), oT(e) && (iT(s, e), rT(s, t.shapeType, n, r), s.stroke());
|
|
49115
|
+
return s.globalAlpha = 1, t.textSegments?.length && tT(s, t.textSegments, t.textStyle, n, r, o), a.toDataURL("image/png");
|
|
49097
49116
|
}
|
|
49098
|
-
function
|
|
49117
|
+
function rT(t, e, n, r) {
|
|
49099
49118
|
t.beginPath();
|
|
49100
49119
|
switch (e ?? "rect") {
|
|
49101
49120
|
case "ellipse":
|
|
@@ -49109,13 +49128,13 @@ function nT(t, e, n, r) {
|
|
|
49109
49128
|
default: t.rect(0, 0, n, r);
|
|
49110
49129
|
}
|
|
49111
49130
|
}
|
|
49112
|
-
function
|
|
49131
|
+
function iT(t, e) {
|
|
49113
49132
|
t.strokeStyle = e.strokeColor ?? "#000000", t.lineWidth = e.strokeWidth ?? 1, void 0 !== e.strokeOpacity && e.strokeOpacity < 1 && (t.globalAlpha = e.strokeOpacity);
|
|
49114
49133
|
}
|
|
49115
|
-
function
|
|
49134
|
+
function oT(t) {
|
|
49116
49135
|
return Boolean(t.strokeColor) && "transparent" !== t.strokeColor && (t.strokeWidth ?? 0) > 0;
|
|
49117
49136
|
}
|
|
49118
|
-
var
|
|
49137
|
+
var aT = class {
|
|
49119
49138
|
constructor(t) {
|
|
49120
49139
|
this.textRenderer = t;
|
|
49121
49140
|
}
|
|
@@ -49152,7 +49171,7 @@ var oT = class {
|
|
|
49152
49171
|
const t = n.text?.trim();
|
|
49153
49172
|
if (t) {
|
|
49154
49173
|
const e = n.textStyle?.align;
|
|
49155
|
-
e && "left" !== e ? r.push(`<p align="${
|
|
49174
|
+
e && "left" !== e ? r.push(`<p align="${Lw(e)}">${Lw(t)}</p>`) : r.push(t);
|
|
49156
49175
|
}
|
|
49157
49176
|
}
|
|
49158
49177
|
const a = n.textStyle?.textWarpPreset;
|
|
@@ -49170,7 +49189,7 @@ var oT = class {
|
|
|
49170
49189
|
r.add(t);
|
|
49171
49190
|
try {
|
|
49172
49191
|
const r = await e.mediaContext.saveImage(t, `slide${e.slideNumber}-bullet`);
|
|
49173
|
-
n.push(`<img src="${
|
|
49192
|
+
n.push(`<img src="${Lw(r)}" alt="Bullet image">`);
|
|
49174
49193
|
} catch {}
|
|
49175
49194
|
}
|
|
49176
49195
|
}
|
|
@@ -49183,7 +49202,7 @@ var oT = class {
|
|
|
49183
49202
|
if (!n.fillImageUrl.startsWith("data:")) return null;
|
|
49184
49203
|
try {
|
|
49185
49204
|
const t = await e.mediaContext.saveImage(n.fillImageUrl, `slide${e.slideNumber}-shapefill`);
|
|
49186
|
-
return e.semanticMode ? `` : `<img src="${
|
|
49205
|
+
return e.semanticMode ? `` : `<img src="${Lw(t)}" alt="Shape fill">`;
|
|
49187
49206
|
} catch {
|
|
49188
49207
|
return null;
|
|
49189
49208
|
}
|
|
@@ -49192,7 +49211,7 @@ var oT = class {
|
|
|
49192
49211
|
const i = t;
|
|
49193
49212
|
if (!i.shapeStyle || !i.width || !i.height) return null;
|
|
49194
49213
|
try {
|
|
49195
|
-
const t =
|
|
49214
|
+
const t = nT({
|
|
49196
49215
|
width: i.width,
|
|
49197
49216
|
height: i.height,
|
|
49198
49217
|
shapeType: i.shapeType,
|
|
@@ -49206,9 +49225,9 @@ var oT = class {
|
|
|
49206
49225
|
if (!t) return null;
|
|
49207
49226
|
const o = await e.mediaContext.saveImage(t, `slide${e.slideNumber}-shape`);
|
|
49208
49227
|
if (e.semanticMode) return ``;
|
|
49209
|
-
if (e.layoutScale) return `<img src="${
|
|
49228
|
+
if (e.layoutScale) return `<img src="${Lw(o)}" alt="Shape" style="max-width:100%;height:auto">`;
|
|
49210
49229
|
const a = this.computeDisplaySize(i.width, i.height);
|
|
49211
|
-
return `<img src="${
|
|
49230
|
+
return `<img src="${Lw(o)}" alt="Shape" width="${a.w}" height="${a.h}">`;
|
|
49212
49231
|
} catch {
|
|
49213
49232
|
return null;
|
|
49214
49233
|
}
|
|
@@ -49232,7 +49251,7 @@ var oT = class {
|
|
|
49232
49251
|
h: Math.round(e * r)
|
|
49233
49252
|
};
|
|
49234
49253
|
}
|
|
49235
|
-
},
|
|
49254
|
+
}, sT = class {
|
|
49236
49255
|
constructor(t) {
|
|
49237
49256
|
this.textRenderer = t;
|
|
49238
49257
|
}
|
|
@@ -49305,9 +49324,9 @@ var oT = class {
|
|
|
49305
49324
|
"onClick" !== i && r.push(i.replace(/([A-Z])/g, " $1").trim().toLowerCase()), "number" == typeof t.repeatCount && t.repeatCount > 1 && r.push(`repeat: ${t.repeatCount}x`), t.autoReverse && r.push("auto-reverse"), t.buildType && r.push(`build: ${t.buildType}`);
|
|
49306
49325
|
return `${e}: ${n}${r.length > 0 ? ` (${r.join(", ")})` : ""}`;
|
|
49307
49326
|
}
|
|
49308
|
-
},
|
|
49327
|
+
}, lT = class {
|
|
49309
49328
|
constructor(t, e, n) {
|
|
49310
|
-
this.registry = t, this.mediaContext = e, this.textRenderer = n, this.metadataRenderer = new
|
|
49329
|
+
this.registry = t, this.mediaContext = e, this.textRenderer = n, this.metadataRenderer = new sT(n);
|
|
49311
49330
|
}
|
|
49312
49331
|
metadataRenderer;
|
|
49313
49332
|
async processSlide(t, e) {
|
|
@@ -49352,7 +49371,7 @@ var oT = class {
|
|
|
49352
49371
|
}
|
|
49353
49372
|
async renderBackgroundHtml(t, e) {
|
|
49354
49373
|
if (t.backgroundImage && t.backgroundImage.startsWith("data:")) try {
|
|
49355
|
-
return `<img src="${
|
|
49374
|
+
return `<img src="${Lw(await e.mediaContext.saveImage(t.backgroundImage, `slide${t.slideNumber}-bg`))}" alt="Slide background" style="width:100%;height:100%;object-fit:cover">`;
|
|
49356
49375
|
} catch {
|
|
49357
49376
|
return;
|
|
49358
49377
|
}
|
|
@@ -49412,7 +49431,7 @@ var oT = class {
|
|
|
49412
49431
|
});
|
|
49413
49432
|
}
|
|
49414
49433
|
};
|
|
49415
|
-
function
|
|
49434
|
+
function cT(t, e, n) {
|
|
49416
49435
|
const r = function(t, e) {
|
|
49417
49436
|
if (!t || "object" != typeof t) return;
|
|
49418
49437
|
const n = t[e];
|
|
@@ -49423,7 +49442,7 @@ function lT(t, e, n) {
|
|
|
49423
49442
|
const i = n?.[e], o = i?.marginLeft ?? 0, a = i?.indent ?? 0, s = Math.max(0, o + Math.max(a, 0));
|
|
49424
49443
|
return s <= 0 ? 0 : Math.max(0, Math.round(s / 24));
|
|
49425
49444
|
}
|
|
49426
|
-
function
|
|
49445
|
+
function dT(t, e) {
|
|
49427
49446
|
if (t.autoNumType) {
|
|
49428
49447
|
const n = t.autoNumStartAt ?? 1, r = t.paragraphIndex ?? e;
|
|
49429
49448
|
return function(t, e) {
|
|
@@ -49467,7 +49486,7 @@ function cT(t, e) {
|
|
|
49467
49486
|
}
|
|
49468
49487
|
return "-";
|
|
49469
49488
|
}
|
|
49470
|
-
var
|
|
49489
|
+
var hT = [
|
|
49471
49490
|
"mono",
|
|
49472
49491
|
"courier",
|
|
49473
49492
|
"consolas",
|
|
@@ -49491,7 +49510,7 @@ var dT = [
|
|
|
49491
49510
|
"lucida console",
|
|
49492
49511
|
"fixedsys"
|
|
49493
49512
|
];
|
|
49494
|
-
var
|
|
49513
|
+
var pT = class {
|
|
49495
49514
|
convert(t) {
|
|
49496
49515
|
return this.renderNode(t).replace(/\s+/g, " ").trim() || this.collectText(t).replace(/\s+/g, " ").trim();
|
|
49497
49516
|
}
|
|
@@ -49666,8 +49685,8 @@ var hT = class {
|
|
|
49666
49685
|
const r = t[e];
|
|
49667
49686
|
return "string" == typeof r ? r : null;
|
|
49668
49687
|
}
|
|
49669
|
-
},
|
|
49670
|
-
ommlConverter = new
|
|
49688
|
+
}, uT = class {
|
|
49689
|
+
ommlConverter = new pT();
|
|
49671
49690
|
render(t, e = {}) {
|
|
49672
49691
|
if (0 === t.length) return "";
|
|
49673
49692
|
const n = this.groupParagraphs(t).map((t) => this.renderParagraph(t, e)).filter((t) => t.text.length > 0);
|
|
@@ -49719,7 +49738,7 @@ var hT = class {
|
|
|
49719
49738
|
if (!e.disableLists && !e.inlineMode) {
|
|
49720
49739
|
const r = t.segments.find((t) => Boolean(t.bulletInfo))?.bulletInfo;
|
|
49721
49740
|
if (r && !r.none) {
|
|
49722
|
-
const i =
|
|
49741
|
+
const i = cT(r, t.index, e.paragraphIndents), o = dT(r, t.index), a = r.autoNumType && /^\d+[.)]\s/.test(n) ? "" : `${o} `;
|
|
49723
49742
|
if (e.htmlFormatting) return {
|
|
49724
49743
|
text: `<div style="padding-left:${1.5 * i}em">${a}${n}</div>`,
|
|
49725
49744
|
isListItem: !0
|
|
@@ -49752,13 +49771,13 @@ var hT = class {
|
|
|
49752
49771
|
if ("all" === t.style.textCaps && (i = i.toUpperCase()), !r && function(t) {
|
|
49753
49772
|
if (t.style.hyperlink) return !1;
|
|
49754
49773
|
const e = t.style.fontFamily?.toLowerCase() ?? "";
|
|
49755
|
-
return
|
|
49756
|
-
}(t) && (i = this.wrapCode(i)), t.style.strikethrough && (i = r ? `<s>${i}</s>` : `~~${i}~~`), t.style.bold && t.style.italic ? i = r ? `<strong><em>${i}</em></strong>` : `***${i}***` : (t.style.bold && (i = r ? `<strong>${i}</strong>` : `**${i}**`), t.style.italic && (i = r ? `<em>${i}</em>` : `*${i}*`)), t.style.underline && (i = `<u>${i}</u>`), t.style.baseline && t.style.baseline > 0 && (i = `<sup>${i}</sup>`), t.style.baseline && t.style.baseline < 0 && (i = `<sub>${i}</sub>`), "small" === t.style.textCaps && (i = `<span style="font-variant:small-caps">${i}</span>`), t.style.hyperlink) if (r) i = `<a href="${
|
|
49774
|
+
return hT.some((t) => e.includes(t));
|
|
49775
|
+
}(t) && (i = this.wrapCode(i)), t.style.strikethrough && (i = r ? `<s>${i}</s>` : `~~${i}~~`), t.style.bold && t.style.italic ? i = r ? `<strong><em>${i}</em></strong>` : `***${i}***` : (t.style.bold && (i = r ? `<strong>${i}</strong>` : `**${i}**`), t.style.italic && (i = r ? `<em>${i}</em>` : `*${i}*`)), t.style.underline && (i = `<u>${i}</u>`), t.style.baseline && t.style.baseline > 0 && (i = `<sup>${i}</sup>`), t.style.baseline && t.style.baseline < 0 && (i = `<sub>${i}</sub>`), "small" === t.style.textCaps && (i = `<span style="font-variant:small-caps">${i}</span>`), t.style.hyperlink) if (r) i = `<a href="${Lw(function(t) {
|
|
49757
49776
|
if ("string" != typeof t) return "#";
|
|
49758
49777
|
const e = t.trim();
|
|
49759
49778
|
if (0 === e.length) return "#";
|
|
49760
49779
|
const n = e.toLowerCase();
|
|
49761
|
-
for (const t of
|
|
49780
|
+
for (const t of Dw) if (n.startsWith(t)) return e;
|
|
49762
49781
|
return "#";
|
|
49763
49782
|
}(t.style.hyperlink))}">${i}</a>`;
|
|
49764
49783
|
else i = `[${i}](${this.renderLinkDestination(t.style.hyperlink)}${t.style.hyperlinkTooltip ? ` "${this.escapeLinkTitle(t.style.hyperlinkTooltip)}"` : ""})`;
|
|
@@ -49789,14 +49808,14 @@ var hT = class {
|
|
|
49789
49808
|
escapeHtml(t) {
|
|
49790
49809
|
return t.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """);
|
|
49791
49810
|
}
|
|
49792
|
-
},
|
|
49811
|
+
}, mT = class extends Ew {
|
|
49793
49812
|
textRenderer;
|
|
49794
49813
|
registry;
|
|
49795
49814
|
slideProcessor;
|
|
49796
49815
|
convertedSlides = 0;
|
|
49797
49816
|
totalSlides = 0;
|
|
49798
49817
|
constructor(t, e, n) {
|
|
49799
|
-
super(t, e, n), this.textRenderer = new
|
|
49818
|
+
super(t, e, n), this.textRenderer = new uT(), this.registry = new Ow(), this.registerProcessors(), this.slideProcessor = new lT(this.registry, this.mediaContext, this.textRenderer);
|
|
49800
49819
|
}
|
|
49801
49820
|
get imagesExtracted() {
|
|
49802
49821
|
return this.mediaContext.totalImages;
|
|
@@ -49831,7 +49850,7 @@ var hT = class {
|
|
|
49831
49850
|
return s && (a = `${a}\n\n---\n\n${s}`), a = a.endsWith("\n") ? a : `${a}\n`, this.options.outputPath && await this.writeOutput(a, this.options.outputPath), a;
|
|
49832
49851
|
}
|
|
49833
49852
|
registerProcessors() {
|
|
49834
|
-
this.registry.register(new
|
|
49853
|
+
this.registry.register(new aT(this.textRenderer)), this.registry.register(new Xw()), this.registry.register(new Jw()), this.registry.register(new jw()), this.registry.register(new qw()), this.registry.register(new Uw()), this.registry.register(new Gw()), this.registry.register(new Ww()), this.registry.register(new zw()), this.registry.register(new $w());
|
|
49835
49854
|
}
|
|
49836
49855
|
buildPptxFrontMatter(t) {
|
|
49837
49856
|
const e = {
|
|
@@ -49873,56 +49892,56 @@ var hT = class {
|
|
|
49873
49892
|
return this.options;
|
|
49874
49893
|
}
|
|
49875
49894
|
};
|
|
49876
|
-
function
|
|
49895
|
+
function fT(t, e) {
|
|
49877
49896
|
if (!t) return null;
|
|
49878
49897
|
const n = [];
|
|
49879
49898
|
let r = "SourceGraphic";
|
|
49880
49899
|
const i = (t, e) => {
|
|
49881
49900
|
n.push(e.replace("__IN__", r).replace("__OUT__", t)), r = t;
|
|
49882
49901
|
};
|
|
49883
|
-
if (t.grayscale && i("p1", "<feColorMatrix in=\"__IN__\" type=\"saturate\" values=\"0\" result=\"__OUT__\"/>"), "number" == typeof t.saturation) i("p2", `<feColorMatrix in="__IN__" type="saturate" values="${
|
|
49884
|
-
return
|
|
49902
|
+
if (t.grayscale && i("p1", "<feColorMatrix in=\"__IN__\" type=\"saturate\" values=\"0\" result=\"__OUT__\"/>"), "number" == typeof t.saturation) i("p2", `<feColorMatrix in="__IN__" type="saturate" values="${yT(function(t) {
|
|
49903
|
+
return gT(t, 0, 2);
|
|
49885
49904
|
}(1 + t.saturation / 100))}" result="__OUT__"/>`);
|
|
49886
|
-
if ("number" == typeof t.hsl?.hue && i("p3", `<feColorMatrix in="__IN__" type="hueRotate" values="${
|
|
49905
|
+
if ("number" == typeof t.hsl?.hue && i("p3", `<feColorMatrix in="__IN__" type="hueRotate" values="${yT(t.hsl.hue)}" result="__OUT__"/>`), "number" == typeof t.brightness || "number" == typeof t.contrast) {
|
|
49887
49906
|
const e = (t.brightness ?? 0) / 100, n = 1 + (t.contrast ?? 0) / 100, r = n, o = e + (1 - n) / 2;
|
|
49888
|
-
i("p4", `<feComponentTransfer in="__IN__" result="__OUT__"><feFuncR type="linear" slope="${
|
|
49907
|
+
i("p4", `<feComponentTransfer in="__IN__" result="__OUT__"><feFuncR type="linear" slope="${yT(r)}" intercept="${yT(o)}"/><feFuncG type="linear" slope="${yT(r)}" intercept="${yT(o)}"/><feFuncB type="linear" slope="${yT(r)}" intercept="${yT(o)}"/></feComponentTransfer>`);
|
|
49889
49908
|
}
|
|
49890
49909
|
if (t.lum && ("number" == typeof t.lum.bright || "number" == typeof t.lum.contrast)) {
|
|
49891
49910
|
const e = (t.lum.bright ?? 0) / 100, n = 1 + (t.lum.contrast ?? 0) / 100, r = n, o = e + (1 - n) / 2;
|
|
49892
|
-
i("p5", `<feComponentTransfer in="__IN__" result="__OUT__"><feFuncR type="linear" slope="${
|
|
49911
|
+
i("p5", `<feComponentTransfer in="__IN__" result="__OUT__"><feFuncR type="linear" slope="${yT(r)}" intercept="${yT(o)}"/><feFuncG type="linear" slope="${yT(r)}" intercept="${yT(o)}"/><feFuncB type="linear" slope="${yT(r)}" intercept="${yT(o)}"/></feComponentTransfer>`);
|
|
49893
49912
|
}
|
|
49894
49913
|
if ("number" == typeof t.biLevel) {
|
|
49895
49914
|
i("p6a", "<feColorMatrix in=\"__IN__\" type=\"saturate\" values=\"0\" result=\"__OUT__\"/>");
|
|
49896
|
-
const e =
|
|
49897
|
-
i("p6b", `<feComponentTransfer in="__IN__" result="__OUT__"><feFuncR type="discrete" tableValues="${0 === e ? "1 1" : `0 ${
|
|
49915
|
+
const e = gT(t.biLevel / 100, 0, 1);
|
|
49916
|
+
i("p6b", `<feComponentTransfer in="__IN__" result="__OUT__"><feFuncR type="discrete" tableValues="${0 === e ? "1 1" : `0 ${xT(e)}`}"/><feFuncG type="discrete" tableValues="${0 === e ? "1 1" : `0 ${xT(e)}`}"/><feFuncB type="discrete" tableValues="${0 === e ? "1 1" : `0 ${xT(e)}`}"/></feComponentTransfer>`);
|
|
49898
49917
|
}
|
|
49899
49918
|
if (t.duotone) {
|
|
49900
|
-
const e =
|
|
49901
|
-
i("p7a", "<feColorMatrix in=\"__IN__\" type=\"saturate\" values=\"0\" result=\"__OUT__\"/>"), i("p7b", `<feComponentTransfer in="__IN__" result="__OUT__"><feFuncR type="linear" slope="${
|
|
49919
|
+
const e = bT(t.duotone.color1), n = bT(t.duotone.color2);
|
|
49920
|
+
i("p7a", "<feColorMatrix in=\"__IN__\" type=\"saturate\" values=\"0\" result=\"__OUT__\"/>"), i("p7b", `<feComponentTransfer in="__IN__" result="__OUT__"><feFuncR type="linear" slope="${yT(n.r - e.r)}" intercept="${yT(e.r)}"/><feFuncG type="linear" slope="${yT(n.g - e.g)}" intercept="${yT(e.g)}"/><feFuncB type="linear" slope="${yT(n.b - e.b)}" intercept="${yT(e.b)}"/></feComponentTransfer>`);
|
|
49902
49921
|
}
|
|
49903
49922
|
if (t.tint && "number" == typeof t.tint.amt) {
|
|
49904
|
-
const e =
|
|
49905
|
-
e < 0 && i("p8", `<feColorMatrix in="__IN__" type="saturate" values="${
|
|
49923
|
+
const e = gT(t.tint.amt / 100, -1, 1);
|
|
49924
|
+
e < 0 && i("p8", `<feColorMatrix in="__IN__" type="saturate" values="${yT(1 + e)}" result="__OUT__"/>`), "number" == typeof t.tint.hue && i("p8h", `<feColorMatrix in="__IN__" type="hueRotate" values="${yT(t.tint.hue)}" result="__OUT__"/>`);
|
|
49906
49925
|
}
|
|
49907
49926
|
if (t.clrRepl) {
|
|
49908
|
-
const e =
|
|
49909
|
-
i("p9", `<feColorMatrix in="__IN__" type="matrix" result="__OUT__" values="0 0 0 0 ${
|
|
49927
|
+
const e = bT(t.clrRepl.color);
|
|
49928
|
+
i("p9", `<feColorMatrix in="__IN__" type="matrix" result="__OUT__" values="0 0 0 0 ${yT(e.r)} 0 0 0 0 ${yT(e.g)} 0 0 0 0 ${yT(e.b)} 0 0 0 1 0"/>`);
|
|
49910
49929
|
}
|
|
49911
49930
|
if (t.colorWash) {
|
|
49912
|
-
|
|
49913
|
-
const e =
|
|
49914
|
-
n.push(`<feFlood flood-color="${t.colorWash.color}" flood-opacity="${
|
|
49931
|
+
bT(t.colorWash.color);
|
|
49932
|
+
const e = gT((t.colorWash.opacity ?? 50) / 100, 0, 1);
|
|
49933
|
+
n.push(`<feFlood flood-color="${t.colorWash.color}" flood-opacity="${yT(e)}" result="wash"/><feComposite in="wash" in2="${r}" operator="in" result="washmasked"/><feBlend in="washmasked" in2="${r}" mode="normal" result="washed"/>`), r = "washed";
|
|
49915
49934
|
}
|
|
49916
|
-
if (t.clrChange && t.clrChange.clrToTransparent &&
|
|
49917
|
-
if (t.alphaInv && i("pa2", "<feComponentTransfer in=\"__IN__\" result=\"__OUT__\"><feFuncA type=\"linear\" slope=\"-1\" intercept=\"1\"/></feComponentTransfer>"), t.alphaCeiling && i("pa3", "<feComponentTransfer in=\"__IN__\" result=\"__OUT__\"><feFuncA type=\"discrete\" tableValues=\"0 1 1 1 1 1 1 1 1 1\"/></feComponentTransfer>"), t.alphaFloor && i("pa4", "<feComponentTransfer in=\"__IN__\" result=\"__OUT__\"><feFuncA type=\"discrete\" tableValues=\"0 0 0 0 0 0 0 0 0 1\"/></feComponentTransfer>"), "number" == typeof t.alphaRepl) i("pa5", `<feComponentTransfer in="__IN__" result="__OUT__"><feFuncA type="linear" slope="0" intercept="${gT(
|
|
49935
|
+
if (t.clrChange && t.clrChange.clrToTransparent && bT(t.clrChange.clrFrom), "number" == typeof t.alphaModFix) i("pa1", `<feColorMatrix in="__IN__" type="matrix" result="__OUT__" values="1 0 0 0 0 0 1 0 0 0 0 0 1 0 0 0 0 0 ${yT(gT(t.alphaModFix / 100, 0, 1))} 0"/>`);
|
|
49936
|
+
if (t.alphaInv && i("pa2", "<feComponentTransfer in=\"__IN__\" result=\"__OUT__\"><feFuncA type=\"linear\" slope=\"-1\" intercept=\"1\"/></feComponentTransfer>"), t.alphaCeiling && i("pa3", "<feComponentTransfer in=\"__IN__\" result=\"__OUT__\"><feFuncA type=\"discrete\" tableValues=\"0 1 1 1 1 1 1 1 1 1\"/></feComponentTransfer>"), t.alphaFloor && i("pa4", "<feComponentTransfer in=\"__IN__\" result=\"__OUT__\"><feFuncA type=\"discrete\" tableValues=\"0 0 0 0 0 0 0 0 0 1\"/></feComponentTransfer>"), "number" == typeof t.alphaRepl) i("pa5", `<feComponentTransfer in="__IN__" result="__OUT__"><feFuncA type="linear" slope="0" intercept="${yT(gT(t.alphaRepl / 100, 0, 1))}"/></feComponentTransfer>`);
|
|
49918
49937
|
if ("number" == typeof t.alphaBiLevel) i("pa6", `<feComponentTransfer in="__IN__" result="__OUT__"><feFuncA type="discrete" tableValues="${function(t) {
|
|
49919
49938
|
const e = [];
|
|
49920
49939
|
for (let n = 0; n < 10; n++) e.push(n / 10 >= t ? "1" : "0");
|
|
49921
49940
|
return e.join(" ");
|
|
49922
|
-
}(
|
|
49941
|
+
}(gT(t.alphaBiLevel / 100, 0, 1))}"/></feComponentTransfer>`);
|
|
49923
49942
|
if ("string" == typeof t.artisticEffect && /blur/i.test(t.artisticEffect)) {
|
|
49924
49943
|
const e = Math.max(0, (t.artisticRadius ?? 0) / 12700);
|
|
49925
|
-
e > 0 && i("pb", `<feGaussianBlur in="__IN__" stdDeviation="${
|
|
49944
|
+
e > 0 && i("pb", `<feGaussianBlur in="__IN__" stdDeviation="${yT(e)}" result="__OUT__"/>`);
|
|
49926
49945
|
}
|
|
49927
49946
|
if (0 === n.length) return null;
|
|
49928
49947
|
const o = `imgfx-${e}`;
|
|
@@ -49931,16 +49950,16 @@ function mT(t, e) {
|
|
|
49931
49950
|
filterId: o
|
|
49932
49951
|
};
|
|
49933
49952
|
}
|
|
49934
|
-
function
|
|
49953
|
+
function gT(t, e, n) {
|
|
49935
49954
|
return t < e ? e : t > n ? n : t;
|
|
49936
49955
|
}
|
|
49937
|
-
function
|
|
49956
|
+
function yT(t) {
|
|
49938
49957
|
return Number.isFinite(t) ? Number(t.toFixed(4)).toString() : "0";
|
|
49939
49958
|
}
|
|
49940
|
-
function
|
|
49959
|
+
function xT(t) {
|
|
49941
49960
|
return "1";
|
|
49942
49961
|
}
|
|
49943
|
-
function
|
|
49962
|
+
function bT(t) {
|
|
49944
49963
|
const e = /^#?([0-9a-f]{6})/i.exec(t.trim());
|
|
49945
49964
|
if (!e) return {
|
|
49946
49965
|
r: 0,
|
|
@@ -49954,21 +49973,21 @@ function xT(t) {
|
|
|
49954
49973
|
b: (255 & n) / 255
|
|
49955
49974
|
};
|
|
49956
49975
|
}
|
|
49957
|
-
function
|
|
49976
|
+
function ST(t) {
|
|
49958
49977
|
return t.replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
49959
49978
|
}
|
|
49960
|
-
function
|
|
49979
|
+
function vT(t) {
|
|
49961
49980
|
let e = "";
|
|
49962
|
-
for (const [n, r] of Object.entries(t)) void 0 !== r && "" !== r && (e += ` ${n}="${
|
|
49981
|
+
for (const [n, r] of Object.entries(t)) void 0 !== r && "" !== r && (e += ` ${n}="${ST(String(r))}"`);
|
|
49963
49982
|
return e;
|
|
49964
49983
|
}
|
|
49965
|
-
function
|
|
49984
|
+
function wT(t, e) {
|
|
49966
49985
|
const n = e, r = t.markerCache.get(n);
|
|
49967
49986
|
if (r) return r;
|
|
49968
|
-
const i = "arrow_" + ++t.markerIdCounter, o = `<marker id="${i}" markerWidth="10" markerHeight="7" refX="10" refY="3.5" orient="auto" markerUnits="strokeWidth"><polygon points="0 0, 10 3.5, 0 7" fill="${
|
|
49987
|
+
const i = "arrow_" + ++t.markerIdCounter, o = `<marker id="${i}" markerWidth="10" markerHeight="7" refX="10" refY="3.5" orient="auto" markerUnits="strokeWidth"><polygon points="0 0, 10 3.5, 0 7" fill="${ST(e)}" /></marker>`;
|
|
49969
49988
|
return t.defs.push(o), t.markerCache.set(n, i), i;
|
|
49970
49989
|
}
|
|
49971
|
-
function
|
|
49990
|
+
function TT(t, e) {
|
|
49972
49991
|
if ("text" !== t.type && "shape" !== t.type && "connector" !== t.type) return "";
|
|
49973
49992
|
const n = t.text;
|
|
49974
49993
|
if (!n) return "";
|
|
@@ -49976,7 +49995,7 @@ function wT(t, e) {
|
|
|
49976
49995
|
let c = "start", d = 4;
|
|
49977
49996
|
if ("center" === l ? (c = "middle", d = t.width / 2) : "right" === l && (c = "end", d = t.width - 4), r && r.length > 0) {
|
|
49978
49997
|
const t = [];
|
|
49979
|
-
t.push(`<text${
|
|
49998
|
+
t.push(`<text${vT({
|
|
49980
49999
|
x: d,
|
|
49981
50000
|
"text-anchor": c,
|
|
49982
50001
|
"font-family": o,
|
|
@@ -49991,12 +50010,12 @@ function wT(t, e) {
|
|
|
49991
50010
|
}
|
|
49992
50011
|
if (!i.text) continue;
|
|
49993
50012
|
const r = i.style, l = {};
|
|
49994
|
-
n && (l.x = d, l.dy = e, n = !1), r.fontFamily && r.fontFamily !== o && (l["font-family"] = r.fontFamily), r.fontSize && r.fontSize !== a && (l["font-size"] = r.fontSize), r.color && r.color !== s && (l.fill = r.color), r.bold && (l["font-weight"] = "bold"), r.italic && (l["font-style"] = "italic"), r.underline && (l["text-decoration"] = "underline"), t.push(`<tspan${
|
|
50013
|
+
n && (l.x = d, l.dy = e, n = !1), r.fontFamily && r.fontFamily !== o && (l["font-family"] = r.fontFamily), r.fontSize && r.fontSize !== a && (l["font-size"] = r.fontSize), r.color && r.color !== s && (l.fill = r.color), r.bold && (l["font-weight"] = "bold"), r.italic && (l["font-style"] = "italic"), r.underline && (l["text-decoration"] = "underline"), t.push(`<tspan${vT(l)}>${ST(i.text)}</tspan>`);
|
|
49995
50014
|
}
|
|
49996
50015
|
return t.push("</text>"), t.join("");
|
|
49997
50016
|
}
|
|
49998
50017
|
const h = i?.bold, p = i?.italic, u = n.split("\n"), m = [];
|
|
49999
|
-
m.push(`<text${
|
|
50018
|
+
m.push(`<text${vT({
|
|
50000
50019
|
x: d,
|
|
50001
50020
|
"text-anchor": c,
|
|
50002
50021
|
"font-family": o,
|
|
@@ -50005,13 +50024,13 @@ function wT(t, e) {
|
|
|
50005
50024
|
"font-weight": h ? "bold" : void 0,
|
|
50006
50025
|
"font-style": p ? "italic" : void 0
|
|
50007
50026
|
})}>`);
|
|
50008
|
-
for (let t = 0; t < u.length; t++) m.push(`<tspan${
|
|
50027
|
+
for (let t = 0; t < u.length; t++) m.push(`<tspan${vT({
|
|
50009
50028
|
x: d,
|
|
50010
50029
|
dy: 1.2 * a
|
|
50011
|
-
})}>${
|
|
50030
|
+
})}>${ST(u[t])}</tspan>`);
|
|
50012
50031
|
return m.push("</text>"), m.join("");
|
|
50013
50032
|
}
|
|
50014
|
-
function
|
|
50033
|
+
function CT(t) {
|
|
50015
50034
|
if ("shape" !== t.type && "text" !== t.type) return "";
|
|
50016
50035
|
const e = "shapeStyle" in t ? t.shapeStyle : void 0, n = "shapeType" in t ? t.shapeType : void 0, r = e?.fillColor ?? "none", i = e?.strokeColor ?? "none", o = e?.strokeWidth ?? ("none" !== i ? 1 : 0), a = e?.fillMode;
|
|
50017
50036
|
let s = r;
|
|
@@ -50023,13 +50042,13 @@ function TT(t) {
|
|
|
50023
50042
|
"fill-opacity": void 0 !== l ? l : void 0,
|
|
50024
50043
|
"stroke-opacity": void 0 !== c ? c : void 0
|
|
50025
50044
|
}, h = "pathData" in t ? t.pathData : void 0;
|
|
50026
|
-
if (h) return `<path${
|
|
50045
|
+
if (h) return `<path${vT({
|
|
50027
50046
|
...d,
|
|
50028
50047
|
d: h
|
|
50029
50048
|
})} />`;
|
|
50030
50049
|
switch (n) {
|
|
50031
50050
|
case "ellipse":
|
|
50032
|
-
case "oval": return `<ellipse${
|
|
50051
|
+
case "oval": return `<ellipse${vT({
|
|
50033
50052
|
...d,
|
|
50034
50053
|
cx: t.width / 2,
|
|
50035
50054
|
cy: t.height / 2,
|
|
@@ -50037,15 +50056,15 @@ function TT(t) {
|
|
|
50037
50056
|
ry: t.height / 2
|
|
50038
50057
|
})} />`;
|
|
50039
50058
|
case "triangle":
|
|
50040
|
-
case "isoTriangle": return `<polygon${
|
|
50059
|
+
case "isoTriangle": return `<polygon${vT({
|
|
50041
50060
|
...d,
|
|
50042
50061
|
points: `${t.width / 2},0 ${t.width},${t.height} 0,${t.height}`
|
|
50043
50062
|
})} />`;
|
|
50044
|
-
case "diamond": return `<polygon${
|
|
50063
|
+
case "diamond": return `<polygon${vT({
|
|
50045
50064
|
...d,
|
|
50046
50065
|
points: `${t.width / 2},0 ${t.width},${t.height / 2} ${t.width / 2},${t.height} 0,${t.height / 2}`
|
|
50047
50066
|
})} />`;
|
|
50048
|
-
default: return `<rect${
|
|
50067
|
+
default: return `<rect${vT({
|
|
50049
50068
|
...d,
|
|
50050
50069
|
width: t.width,
|
|
50051
50070
|
height: t.height,
|
|
@@ -50053,7 +50072,7 @@ function TT(t) {
|
|
|
50053
50072
|
})} />`;
|
|
50054
50073
|
}
|
|
50055
50074
|
}
|
|
50056
|
-
function
|
|
50075
|
+
function kT(t, e, n) {
|
|
50057
50076
|
if (t.hidden) return "";
|
|
50058
50077
|
const r = function(t) {
|
|
50059
50078
|
const e = [];
|
|
@@ -50065,16 +50084,16 @@ function CT(t, e, n) {
|
|
|
50065
50084
|
switch (t.type) {
|
|
50066
50085
|
case "text":
|
|
50067
50086
|
case "shape":
|
|
50068
|
-
o =
|
|
50087
|
+
o = CT(t) + TT(t, e);
|
|
50069
50088
|
break;
|
|
50070
50089
|
case "connector":
|
|
50071
50090
|
o = function(t, e) {
|
|
50072
50091
|
if ("connector" !== t.type) return "";
|
|
50073
50092
|
const n = t.shapeStyle, r = n?.strokeColor ?? "#000000", i = n?.strokeWidth ?? 1;
|
|
50074
50093
|
let o, a;
|
|
50075
|
-
n?.connectorStartArrow && "none" !== n.connectorStartArrow && (o = `url(#${
|
|
50076
|
-
n?.connectorEndArrow && "none" !== n.connectorEndArrow && (a = `url(#${
|
|
50077
|
-
return `<line${
|
|
50094
|
+
n?.connectorStartArrow && "none" !== n.connectorStartArrow && (o = `url(#${wT(e, r)})`);
|
|
50095
|
+
n?.connectorEndArrow && "none" !== n.connectorEndArrow && (a = `url(#${wT(e, r)})`);
|
|
50096
|
+
return `<line${vT({
|
|
50078
50097
|
x1: 0,
|
|
50079
50098
|
y1: 0,
|
|
50080
50099
|
x2: t.width,
|
|
@@ -50091,35 +50110,35 @@ function CT(t, e, n) {
|
|
|
50091
50110
|
o = function(t, e) {
|
|
50092
50111
|
if ("image" !== t.type && "picture" !== t.type) return "";
|
|
50093
50112
|
const n = t.imageData;
|
|
50094
|
-
if (!n) return `<rect${
|
|
50113
|
+
if (!n) return `<rect${vT({
|
|
50095
50114
|
width: t.width,
|
|
50096
50115
|
height: t.height,
|
|
50097
50116
|
fill: "#E0E0E0",
|
|
50098
50117
|
stroke: "#999",
|
|
50099
50118
|
"stroke-width": 1
|
|
50100
|
-
})} /><text${
|
|
50119
|
+
})} /><text${vT({
|
|
50101
50120
|
x: t.width / 2,
|
|
50102
50121
|
y: t.height / 2,
|
|
50103
50122
|
"text-anchor": "middle",
|
|
50104
50123
|
"font-size": 12,
|
|
50105
50124
|
fill: "#666"
|
|
50106
50125
|
})}>image</text>`;
|
|
50107
|
-
const r = t.imageEffects ?
|
|
50126
|
+
const r = t.imageEffects ? fT(t.imageEffects, function(t) {
|
|
50108
50127
|
const e = t.filterCounter++;
|
|
50109
50128
|
return `${t.slideIndex}-${e}`;
|
|
50110
50129
|
}(e)) : null, i = r ? ` filter="url(#${r.filterId})"` : "";
|
|
50111
|
-
return r && e.defs.push(r.defsXml), `<image${
|
|
50130
|
+
return r && e.defs.push(r.defsXml), `<image${vT({
|
|
50112
50131
|
width: t.width,
|
|
50113
50132
|
height: t.height,
|
|
50114
50133
|
preserveAspectRatio: "none"
|
|
50115
|
-
})} href="${
|
|
50134
|
+
})} href="${ST(n)}"${i} />`;
|
|
50116
50135
|
}(t, n);
|
|
50117
50136
|
break;
|
|
50118
50137
|
case "table":
|
|
50119
50138
|
o = function(t, e) {
|
|
50120
50139
|
if ("table" !== t.type) return "";
|
|
50121
50140
|
const n = t.tableData;
|
|
50122
|
-
if (!n || !n.rows.length) return `<rect${
|
|
50141
|
+
if (!n || !n.rows.length) return `<rect${vT({
|
|
50123
50142
|
width: t.width,
|
|
50124
50143
|
height: t.height,
|
|
50125
50144
|
fill: "#F0F0F0",
|
|
@@ -50138,7 +50157,7 @@ function CT(t, e, n) {
|
|
|
50138
50157
|
continue;
|
|
50139
50158
|
}
|
|
50140
50159
|
const d = (r[o] ?? 1 / i.cells.length) * t.width * (c.gridSpan ?? 1), h = c.style?.backgroundColor ?? "none", p = c.style?.borderColor ?? "#CCCCCC", u = c.style?.color ?? "#000000", m = c.style?.fontSize ?? e.defaultFontSize, f = c.style?.bold;
|
|
50141
|
-
a.push(`<rect${
|
|
50160
|
+
a.push(`<rect${vT({
|
|
50142
50161
|
x: l,
|
|
50143
50162
|
y: s,
|
|
50144
50163
|
width: d,
|
|
@@ -50146,7 +50165,7 @@ function CT(t, e, n) {
|
|
|
50146
50165
|
fill: h,
|
|
50147
50166
|
stroke: p,
|
|
50148
50167
|
"stroke-width": .5
|
|
50149
|
-
})} />`), c.text && a.push(`<text${
|
|
50168
|
+
})} />`), c.text && a.push(`<text${vT({
|
|
50150
50169
|
x: l + 4,
|
|
50151
50170
|
y: s + n / 2,
|
|
50152
50171
|
"dominant-baseline": "central",
|
|
@@ -50154,7 +50173,7 @@ function CT(t, e, n) {
|
|
|
50154
50173
|
"font-size": m,
|
|
50155
50174
|
fill: u,
|
|
50156
50175
|
"font-weight": f ? "bold" : void 0
|
|
50157
|
-
})}>${
|
|
50176
|
+
})}>${ST(c.text)}</text>`), l += d;
|
|
50158
50177
|
}
|
|
50159
50178
|
s += n;
|
|
50160
50179
|
}
|
|
@@ -50165,7 +50184,7 @@ function CT(t, e, n) {
|
|
|
50165
50184
|
o = function(t, e, n) {
|
|
50166
50185
|
if ("group" !== t.type) return "";
|
|
50167
50186
|
const r = [];
|
|
50168
|
-
for (const i of t.children) r.push(
|
|
50187
|
+
for (const i of t.children) r.push(kT(i, e, n));
|
|
50169
50188
|
return r.join("");
|
|
50170
50189
|
}(t, e, n);
|
|
50171
50190
|
break;
|
|
@@ -50175,7 +50194,7 @@ function CT(t, e, n) {
|
|
|
50175
50194
|
const e = [];
|
|
50176
50195
|
for (let n = 0; n < t.inkPaths.length; n++) {
|
|
50177
50196
|
const r = t.inkPaths[n], i = t.inkColors?.[n] ?? "#000000", o = t.inkWidths?.[n] ?? 1, a = t.inkOpacities?.[n];
|
|
50178
|
-
e.push(`<path${
|
|
50197
|
+
e.push(`<path${vT({
|
|
50179
50198
|
d: r,
|
|
50180
50199
|
fill: "none",
|
|
50181
50200
|
stroke: i,
|
|
@@ -50195,14 +50214,14 @@ function CT(t, e, n) {
|
|
|
50195
50214
|
case "zoom":
|
|
50196
50215
|
case "model3d":
|
|
50197
50216
|
case "unknown": o = function(t) {
|
|
50198
|
-
return `<rect${
|
|
50217
|
+
return `<rect${vT({
|
|
50199
50218
|
width: t.width,
|
|
50200
50219
|
height: t.height,
|
|
50201
50220
|
fill: "#F5F5F5",
|
|
50202
50221
|
stroke: "#CCCCCC",
|
|
50203
50222
|
"stroke-width": 1,
|
|
50204
50223
|
"stroke-dasharray": "4 2"
|
|
50205
|
-
})} /><text${
|
|
50224
|
+
})} /><text${vT({
|
|
50206
50225
|
x: t.width / 2,
|
|
50207
50226
|
y: t.height / 2,
|
|
50208
50227
|
"text-anchor": "middle",
|
|
@@ -50210,15 +50229,15 @@ function CT(t, e, n) {
|
|
|
50210
50229
|
"font-family": "Arial",
|
|
50211
50230
|
"font-size": 11,
|
|
50212
50231
|
fill: "#999999"
|
|
50213
|
-
})}>${
|
|
50232
|
+
})}>${ST(t.type)}</text>`;
|
|
50214
50233
|
}(t);
|
|
50215
50234
|
}
|
|
50216
|
-
return o ? `<g${
|
|
50235
|
+
return o ? `<g${vT({
|
|
50217
50236
|
transform: r,
|
|
50218
50237
|
opacity: void 0 !== i && i < 1 ? i : void 0
|
|
50219
50238
|
})}>${o}</g>` : "";
|
|
50220
50239
|
}
|
|
50221
|
-
var
|
|
50240
|
+
var _T = class t {
|
|
50222
50241
|
static exportSlide(t, e, n, r) {
|
|
50223
50242
|
const i = (o = r, {
|
|
50224
50243
|
defaultFontFamily: o?.defaultFontFamily ?? "Arial",
|
|
@@ -50235,23 +50254,23 @@ var kT = class t {
|
|
|
50235
50254
|
};
|
|
50236
50255
|
}(t.elements.length), s = [];
|
|
50237
50256
|
s.push(function(t, e, n) {
|
|
50238
|
-
return t.backgroundImage ? `<rect${
|
|
50257
|
+
return t.backgroundImage ? `<rect${vT({
|
|
50239
50258
|
width: e,
|
|
50240
50259
|
height: n,
|
|
50241
50260
|
fill: "#FFFFFF"
|
|
50242
|
-
})} /><image${
|
|
50261
|
+
})} /><image${vT({
|
|
50243
50262
|
width: e,
|
|
50244
50263
|
height: n,
|
|
50245
50264
|
preserveAspectRatio: "xMidYMid slice"
|
|
50246
|
-
})} href="${
|
|
50265
|
+
})} href="${ST(t.backgroundImage)}" />` : `<rect${vT({
|
|
50247
50266
|
width: e,
|
|
50248
50267
|
height: n,
|
|
50249
50268
|
fill: t.backgroundColor ?? "#FFFFFF"
|
|
50250
50269
|
})} />`;
|
|
50251
50270
|
}(t, e, n));
|
|
50252
|
-
for (const e of t.elements) s.push(
|
|
50271
|
+
for (const e of t.elements) s.push(kT(e, i, a));
|
|
50253
50272
|
const l = a.defs.length ? `<defs>${a.defs.join("")}</defs>` : "";
|
|
50254
|
-
return `<svg${
|
|
50273
|
+
return `<svg${vT({
|
|
50255
50274
|
xmlns: "http://www.w3.org/2000/svg",
|
|
50256
50275
|
"xmlns:xlink": "http://www.w3.org/1999/xlink",
|
|
50257
50276
|
viewBox: `0 0 ${e} ${n}`,
|