pptx-react-viewer 3.16.4 → 3.16.6
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 +13 -0
- package/dist/{AiChatPanel-YWYME2RM.mjs → AiChatPanel-6IBPORZC.mjs} +3 -3
- package/dist/AiChatPanel-6IBPORZC.mjs.br +0 -0
- package/dist/AiChatPanel-6IBPORZC.mjs.gz +0 -0
- package/dist/{AiChatPanel-QJKB2BL3.js → AiChatPanel-WDNBYHX7.js} +24 -24
- package/dist/AiChatPanel-WDNBYHX7.js.br +0 -0
- package/dist/AiChatPanel-WDNBYHX7.js.gz +0 -0
- package/dist/{Area3DChartScene-47SQRQTD.mjs → Area3DChartScene-EMOWMHHK.mjs} +1 -1
- package/dist/{Area3DChartScene-47SQRQTD.mjs.br → Area3DChartScene-EMOWMHHK.mjs.br} +0 -0
- package/dist/Area3DChartScene-EMOWMHHK.mjs.gz +0 -0
- package/dist/{Area3DChartScene-DEWKUQUS.js → Area3DChartScene-MRPRTJWY.js} +2 -2
- package/dist/{Area3DChartScene-DEWKUQUS.js.br → Area3DChartScene-MRPRTJWY.js.br} +0 -0
- package/dist/Area3DChartScene-MRPRTJWY.js.gz +0 -0
- package/dist/{Bar3DChartScene-JXXBIKLB.mjs → Bar3DChartScene-J3GJEGDJ.mjs} +1 -1
- package/dist/{Bar3DChartScene-JXXBIKLB.mjs.br → Bar3DChartScene-J3GJEGDJ.mjs.br} +0 -0
- package/dist/Bar3DChartScene-J3GJEGDJ.mjs.gz +0 -0
- package/dist/{Bar3DChartScene-HRCZHDNT.js → Bar3DChartScene-THALZEYK.js} +2 -2
- package/dist/Bar3DChartScene-THALZEYK.js.br +0 -0
- package/dist/Bar3DChartScene-THALZEYK.js.gz +0 -0
- package/dist/{Line3DChartScene-JPHU2WGC.js → Line3DChartScene-B26WZNO3.js} +2 -2
- package/dist/Line3DChartScene-B26WZNO3.js.br +0 -0
- package/dist/Line3DChartScene-B26WZNO3.js.gz +0 -0
- package/dist/{Line3DChartScene-S2SV5HCH.mjs → Line3DChartScene-Y7MODOK2.mjs} +1 -1
- package/dist/{Line3DChartScene-S2SV5HCH.mjs.br → Line3DChartScene-Y7MODOK2.mjs.br} +0 -0
- package/dist/Line3DChartScene-Y7MODOK2.mjs.gz +0 -0
- package/dist/{Model3DScene-JP4ICMLY.js → Model3DScene-27GN3D3U.js} +2 -2
- package/dist/Model3DScene-27GN3D3U.js.br +0 -0
- package/dist/Model3DScene-27GN3D3U.js.gz +0 -0
- package/dist/{Model3DScene-4MOLASW6.mjs → Model3DScene-XM3JN7M6.mjs} +1 -1
- package/dist/Model3DScene-XM3JN7M6.mjs.br +0 -0
- package/dist/Model3DScene-XM3JN7M6.mjs.gz +0 -0
- package/dist/{PieChart3DScene-PV7BN7MS.mjs → PieChart3DScene-4GP2B3PY.mjs} +1 -1
- package/dist/{PieChart3DScene-PV7BN7MS.mjs.br → PieChart3DScene-4GP2B3PY.mjs.br} +0 -0
- package/dist/PieChart3DScene-4GP2B3PY.mjs.gz +0 -0
- package/dist/{PieChart3DScene-QYWGHJGG.js → PieChart3DScene-URSRUABE.js} +2 -2
- package/dist/{PieChart3DScene-QYWGHJGG.js.br → PieChart3DScene-URSRUABE.js.br} +0 -0
- package/dist/PieChart3DScene-URSRUABE.js.gz +0 -0
- package/dist/{SurfaceChart3DScene-KAD2GVBY.js → SurfaceChart3DScene-4OQNB3JY.js} +2 -2
- package/dist/{SurfaceChart3DScene-KAD2GVBY.js.br → SurfaceChart3DScene-4OQNB3JY.js.br} +0 -0
- package/dist/SurfaceChart3DScene-4OQNB3JY.js.gz +0 -0
- package/dist/{SurfaceChart3DScene-7ONY7OIY.mjs → SurfaceChart3DScene-YJ4EYMWQ.mjs} +1 -1
- package/dist/SurfaceChart3DScene-YJ4EYMWQ.mjs.br +0 -0
- package/dist/SurfaceChart3DScene-YJ4EYMWQ.mjs.gz +0 -0
- package/dist/{chunk-NMSZ3NSG.js → chunk-BJL5MJ7A.js} +174 -170
- package/dist/chunk-BJL5MJ7A.js.br +0 -0
- package/dist/chunk-BJL5MJ7A.js.gz +0 -0
- package/dist/{chunk-4WGGCKLD.js → chunk-C7H7NM2W.js} +5 -5
- package/dist/chunk-C7H7NM2W.js.br +0 -0
- package/dist/chunk-C7H7NM2W.js.gz +0 -0
- package/dist/{chunk-ZWZGKJ4E.js → chunk-LTQRC4WB.js} +1321 -1307
- package/dist/chunk-LTQRC4WB.js.br +0 -0
- package/dist/chunk-LTQRC4WB.js.gz +0 -0
- package/dist/{chunk-R5CW64K4.mjs → chunk-PO2PYVHF.mjs} +94 -1
- package/dist/chunk-PO2PYVHF.mjs.br +0 -0
- package/dist/{chunk-R5CW64K4.mjs.gz → chunk-PO2PYVHF.mjs.gz} +0 -0
- package/dist/{chunk-ISXUHV3L.mjs → chunk-QLZHTIH6.mjs} +2 -2
- package/dist/chunk-QLZHTIH6.mjs.br +0 -0
- package/dist/chunk-QLZHTIH6.mjs.gz +0 -0
- package/dist/{chunk-USQGKC4A.mjs → chunk-RWVMSJ7C.mjs} +45 -31
- package/dist/chunk-RWVMSJ7C.mjs.br +0 -0
- package/dist/chunk-RWVMSJ7C.mjs.gz +0 -0
- package/dist/{chunk-EDCU5EK5.js → chunk-TTCWWF47.js} +451 -451
- package/dist/chunk-TTCWWF47.js.br +0 -0
- package/dist/chunk-TTCWWF47.js.gz +0 -0
- package/dist/{chunk-IKQY2ZU2.mjs → chunk-U2H7CQ34.mjs} +6 -2
- package/dist/chunk-U2H7CQ34.mjs.br +0 -0
- package/dist/chunk-U2H7CQ34.mjs.gz +0 -0
- package/dist/{chunk-PABSSYRA.js → chunk-VRMITIZZ.js} +94 -0
- package/dist/chunk-VRMITIZZ.js.br +0 -0
- package/dist/{chunk-PABSSYRA.js.gz → chunk-VRMITIZZ.js.gz} +0 -0
- package/dist/{chunk-6TGJ5RGQ.mjs → chunk-YUIXPWFT.mjs} +1 -1
- package/dist/chunk-YUIXPWFT.mjs.br +0 -0
- package/dist/chunk-YUIXPWFT.mjs.gz +0 -0
- package/dist/index.js +45 -45
- package/dist/index.js.br +0 -0
- package/dist/index.js.gz +0 -0
- package/dist/index.mjs +5 -5
- package/dist/index.mjs.br +0 -0
- package/dist/index.mjs.gz +0 -0
- package/dist/internals.js +78 -78
- package/dist/internals.js.br +0 -0
- package/dist/internals.js.gz +0 -0
- package/dist/internals.mjs +3 -3
- package/dist/internals.mjs.br +0 -0
- package/dist/internals.mjs.gz +0 -0
- package/dist/viewer/index.js +26 -26
- package/dist/viewer/index.js.br +0 -0
- package/dist/viewer/index.js.gz +0 -0
- package/dist/viewer/index.mjs +5 -5
- package/dist/viewer/index.mjs.br +0 -0
- package/dist/viewer/index.mjs.gz +0 -0
- package/package.json +1 -1
- package/dist/AiChatPanel-QJKB2BL3.js.br +0 -0
- package/dist/AiChatPanel-QJKB2BL3.js.gz +0 -0
- package/dist/AiChatPanel-YWYME2RM.mjs.br +0 -0
- package/dist/AiChatPanel-YWYME2RM.mjs.gz +0 -0
- package/dist/Area3DChartScene-47SQRQTD.mjs.gz +0 -0
- package/dist/Area3DChartScene-DEWKUQUS.js.gz +0 -0
- package/dist/Bar3DChartScene-HRCZHDNT.js.br +0 -0
- package/dist/Bar3DChartScene-HRCZHDNT.js.gz +0 -0
- package/dist/Bar3DChartScene-JXXBIKLB.mjs.gz +0 -0
- package/dist/Line3DChartScene-JPHU2WGC.js.br +0 -0
- package/dist/Line3DChartScene-JPHU2WGC.js.gz +0 -0
- package/dist/Line3DChartScene-S2SV5HCH.mjs.gz +0 -0
- package/dist/Model3DScene-4MOLASW6.mjs.br +0 -0
- package/dist/Model3DScene-4MOLASW6.mjs.gz +0 -0
- package/dist/Model3DScene-JP4ICMLY.js.br +0 -0
- package/dist/Model3DScene-JP4ICMLY.js.gz +0 -0
- package/dist/PieChart3DScene-PV7BN7MS.mjs.gz +0 -0
- package/dist/PieChart3DScene-QYWGHJGG.js.gz +0 -0
- package/dist/SurfaceChart3DScene-7ONY7OIY.mjs.br +0 -0
- package/dist/SurfaceChart3DScene-7ONY7OIY.mjs.gz +0 -0
- package/dist/SurfaceChart3DScene-KAD2GVBY.js.gz +0 -0
- package/dist/chunk-4WGGCKLD.js.br +0 -0
- package/dist/chunk-4WGGCKLD.js.gz +0 -0
- package/dist/chunk-6TGJ5RGQ.mjs.br +0 -0
- package/dist/chunk-6TGJ5RGQ.mjs.gz +0 -0
- package/dist/chunk-EDCU5EK5.js.br +0 -0
- package/dist/chunk-EDCU5EK5.js.gz +0 -0
- package/dist/chunk-IKQY2ZU2.mjs.br +0 -0
- package/dist/chunk-IKQY2ZU2.mjs.gz +0 -0
- package/dist/chunk-ISXUHV3L.mjs.br +0 -0
- package/dist/chunk-ISXUHV3L.mjs.gz +0 -0
- package/dist/chunk-NMSZ3NSG.js.br +0 -0
- package/dist/chunk-NMSZ3NSG.js.gz +0 -0
- package/dist/chunk-PABSSYRA.js.br +0 -0
- package/dist/chunk-R5CW64K4.mjs.br +0 -0
- package/dist/chunk-USQGKC4A.mjs.br +0 -0
- package/dist/chunk-USQGKC4A.mjs.gz +0 -0
- package/dist/chunk-ZWZGKJ4E.js.br +0 -0
- package/dist/chunk-ZWZGKJ4E.js.gz +0 -0
|
Binary file
|
|
Binary file
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { SHAPE_PRESET_DEFS, VIEWER_SHORTCUT_REFERENCE, STROKE_DASH_OPTIONS, getAnimationInitialStyle, cloneHistorySnapshot, hasShapeProperties, getImageFitStyle, getComputedFillStyle, isImageLikeElement, getCropShapeClipPath, getImageTilingStyle, mediaPlaybackAttributes, buildTextBlockStyle, hasTextProperties, toCssWritingMode, toCssTextOrientation, toCssVerticalDirection, buildTextBodyLayoutStyle, buildTextBody3DSceneStyle, buildParagraphs, colorWithOpacity, normalizeHexColor, hexToRgbUnit, build3DExtrusionData, getComputedEffectStyle, getComputedStrokeStyle, getAnimationColorBaseStyle, isStrokeOnlyPresetElement, resolveShapeGeometry, normalizeStrokeDashType, getSvgStrokeDasharray, buildSvgGradientDef, buildStrokeOutline, getPresetShapeVectorGeometry, isWedgeCalloutPresetShape, svgGradientFillRef, isCalloutShape, getCalloutLeaderLineGeometry, buildCalloutLeaderLineSvgPath, getCalloutViewBoxBounds, svgLineCap, getCompoundLineOffsets, getCompoundLineWidths, canDrillDown, computeSelectionRect, DEFAULT_FONT_FAMILY, cellStyleToCss, rectToCells, isCellInRect, tableContainerCss, buildChartViewModel, resolveChartKind, chartPreserveAspectRatio, buildNotesPdfBytes, buildTiledSlidesPdfBytes, buildPreviewAnimation, buildMotionPathPreview, mediaFallbackVisual, scheduleMediaTrimAndFade, registerCrossSlideAudio, resolveAutoFitFontScale, resolveFontKerning, getSubstituteFontFamily, parsePanoseString, resolveScriptFontSet, hasDistinctScriptFonts, nestedTextDecorationStyle, pieceLetterSpacing, resolveMetricTrackingPx, hollowTextFillStyle, stripUnderlineDecoration, buildTabContext, TEXT_BUILD_ID_SEP, buildTextBuildSpec, textBuildSpanStyle, apply3dEffects, clampUnitInterval, customGeometryPathsToSvgSubpaths, buildSubpathPaints, computeColumnBoundaries, getTableCellBandStyle, parseDrawingColor, parseDrawingColorOpacity, getCellDiagonalBorders, xmlText, cellRunStyle, getChartStylePalette, computeChartLegendLayout, mediaFallbackIcon, mediaFallbackLabelKey, MEDIA_CHROME_ATTRIBUTE, convertOmmlToMathMl, sanitizeMathMl, tableCellCss, computeResizedColumnWidths, computeResizedRowHeight, DEFAULT_ROW_HEIGHT, ooxmlGradientAngleToCssDegrees, buildRectPathGradient, buildRunTabLines, chartPartToAttrs, splitWordsForUnderline, splitRunForMetrics, splitRunByScriptFont } from './chunk-
|
|
1
|
+
import { SHAPE_PRESET_DEFS, VIEWER_SHORTCUT_REFERENCE, STROKE_DASH_OPTIONS, getAnimationInitialStyle, cloneHistorySnapshot, hasShapeProperties, getImageFitStyle, getComputedFillStyle, isImageLikeElement, getCropShapeClipPath, getImageTilingStyle, mediaPlaybackAttributes, buildTextBlockStyle, hasTextProperties, toCssWritingMode, toCssTextOrientation, toCssVerticalDirection, buildTextBodyLayoutStyle, buildTextBody3DSceneStyle, buildParagraphs, colorWithOpacity, normalizeHexColor, hexToRgbUnit, build3DExtrusionData, getComputedEffectStyle, getComputedStrokeStyle, getAnimationColorBaseStyle, isStrokeOnlyPresetElement, resolveShapeGeometry, normalizeStrokeDashType, getSvgStrokeDasharray, buildSvgGradientDef, buildStrokeOutline, getPresetShapeVectorGeometry, isWedgeCalloutPresetShape, svgGradientFillRef, isCalloutShape, getCalloutLeaderLineGeometry, buildCalloutLeaderLineSvgPath, getCalloutViewBoxBounds, svgLineCap, getCompoundLineOffsets, getCompoundLineWidths, canDrillDown, computeSelectionRect, DEFAULT_FONT_FAMILY, cellStyleToCss, rectToCells, isCellInRect, tableContainerCss, buildChartViewModel, resolveChartKind, chartPreserveAspectRatio, buildNotesPdfBytes, buildTiledSlidesPdfBytes, buildPreviewAnimation, buildMotionPathPreview, mediaFallbackVisual, scheduleMediaTrimAndFade, registerCrossSlideAudio, resolveAutoFitFontScale, resolveFontKerning, getSubstituteFontFamily, parsePanoseString, resolveScriptFontSet, hasDistinctScriptFonts, nestedTextDecorationStyle, pieceLetterSpacing, resolveMetricTrackingPx, hollowTextFillStyle, stripUnderlineDecoration, buildTabContext, TEXT_BUILD_ID_SEP, buildTextBuildSpec, textBuildSpanStyle, apply3dEffects, clampUnitInterval, customGeometryPathsToSvgSubpaths, buildSubpathPaints, computeColumnBoundaries, getTableCellBandStyle, parseDrawingColor, parseDrawingColorOpacity, getCellDiagonalBorders, xmlText, cellRunStyle, getChartStylePalette, computeChartLegendLayout, mediaFallbackIcon, mediaFallbackLabelKey, MEDIA_CHROME_ATTRIBUTE, convertOmmlToMathMl, sanitizeMathMl, tableCellCss, computeResizedColumnWidths, computeResizedRowHeight, DEFAULT_ROW_HEIGHT, ooxmlGradientAngleToCssDegrees, buildRectPathGradient, buildRunTabLines, chartPartToAttrs, splitWordsForUnderline, splitRunForMetrics, splitRunByScriptFont } from './chunk-PO2PYVHF.mjs';
|
|
2
2
|
import { translationsEn } from './chunk-HMX3MQR7.mjs';
|
|
3
3
|
import { clsx } from 'clsx';
|
|
4
4
|
import { twMerge } from 'tailwind-merge';
|
|
@@ -2777,7 +2777,11 @@ function parseTableElementData(element, fallbackTextStyle) {
|
|
|
2777
2777
|
return Number.isFinite(width) && width > 0 ? width : 0;
|
|
2778
2778
|
});
|
|
2779
2779
|
const totalColumnWidth = columnWidths.reduce((sum, width) => sum + width, 0);
|
|
2780
|
-
|
|
2780
|
+
let columnPercentages = totalColumnWidth > 0 ? columnWidths.map((width) => width / totalColumnWidth * 100) : [];
|
|
2781
|
+
const modelWidths = element.type === "table" ? element.tableData?.columnWidths : void 0;
|
|
2782
|
+
if (modelWidths?.length && modelWidths.length === gridColumns.length && modelWidths.every((width) => Number.isFinite(width) && width >= 0) && Math.abs(modelWidths.reduce((sum, width) => sum + width, 0) - 1) <= Number.EPSILON * modelWidths.length * 4) {
|
|
2783
|
+
columnPercentages = modelWidths.map((width) => width * 100);
|
|
2784
|
+
}
|
|
2781
2785
|
const cells = [];
|
|
2782
2786
|
rows.forEach((row, rowIndex) => {
|
|
2783
2787
|
const rowCells = ensureArrayValue(row["a:tc"]);
|
|
Binary file
|
|
Binary file
|
|
@@ -100418,6 +100418,46 @@ var init_save_table_merge_helpers = __esm({
|
|
|
100418
100418
|
];
|
|
100419
100419
|
}
|
|
100420
100420
|
});
|
|
100421
|
+
function writeTableColumnWidths(tbl, columnWidths) {
|
|
100422
|
+
const columns = xmlChildren(xmlChild(tbl, "a:tblGrid"), "a:gridCol");
|
|
100423
|
+
if (!columns.length || columns.length !== columnWidths.length) {
|
|
100424
|
+
return;
|
|
100425
|
+
}
|
|
100426
|
+
const existingWidths = columns.map((column) => {
|
|
100427
|
+
const value = column["@_w"];
|
|
100428
|
+
return typeof value === "number" || typeof value === "string" && value.trim() !== "" ? Number(value) : NaN;
|
|
100429
|
+
});
|
|
100430
|
+
if (existingWidths.some((width) => !Number.isSafeInteger(width) || width < 0)) {
|
|
100431
|
+
return;
|
|
100432
|
+
}
|
|
100433
|
+
const totalWidth = existingWidths.reduce((sum2, width) => sum2 + width, 0);
|
|
100434
|
+
if (!Number.isSafeInteger(totalWidth) || totalWidth <= 0) {
|
|
100435
|
+
return;
|
|
100436
|
+
}
|
|
100437
|
+
if (columnWidths.some((width) => !Number.isFinite(width) || width < 0)) {
|
|
100438
|
+
return;
|
|
100439
|
+
}
|
|
100440
|
+
const sum = columnWidths.reduce((total, width) => total + width, 0);
|
|
100441
|
+
if (Math.abs(sum - 1) > Number.EPSILON * columnWidths.length * 4) {
|
|
100442
|
+
return;
|
|
100443
|
+
}
|
|
100444
|
+
let cumulative = 0;
|
|
100445
|
+
let previousBoundary = 0;
|
|
100446
|
+
for (let index = 0; index < columns.length; index++) {
|
|
100447
|
+
cumulative += columnWidths[index];
|
|
100448
|
+
const boundary = index === columns.length - 1 ? totalWidth : Math.min(totalWidth, Math.round(cumulative * totalWidth));
|
|
100449
|
+
const width = boundary - previousBoundary;
|
|
100450
|
+
if (width !== existingWidths[index]) {
|
|
100451
|
+
columns[index]["@_w"] = String(width);
|
|
100452
|
+
}
|
|
100453
|
+
previousBoundary = boundary;
|
|
100454
|
+
}
|
|
100455
|
+
}
|
|
100456
|
+
var init_table_column_width_save = __esm({
|
|
100457
|
+
"src/core/core/runtime/table-column-width-save.ts"() {
|
|
100458
|
+
init_xml_access();
|
|
100459
|
+
}
|
|
100460
|
+
});
|
|
100421
100461
|
function runTag(run) {
|
|
100422
100462
|
return run.isLineBreak ? "a:br" : run.isField ? "a:fld" : "a:r";
|
|
100423
100463
|
}
|
|
@@ -101303,6 +101343,7 @@ var init_PptxHandlerRuntimeSaveDataSerialization = __esm({
|
|
|
101303
101343
|
init_chart_part_family_switch();
|
|
101304
101344
|
init_PptxHandlerRuntimeChartUserShapes();
|
|
101305
101345
|
init_save_table_merge_helpers();
|
|
101346
|
+
init_table_column_width_save();
|
|
101306
101347
|
init_table_paragraph_save_order();
|
|
101307
101348
|
init_table_structural_ops();
|
|
101308
101349
|
init_table_tblpr_save();
|
|
@@ -101363,6 +101404,7 @@ var init_PptxHandlerRuntimeSaveDataSerialization = __esm({
|
|
|
101363
101404
|
}
|
|
101364
101405
|
return;
|
|
101365
101406
|
}
|
|
101407
|
+
writeTableColumnWidths(tbl, tableData.columnWidths);
|
|
101366
101408
|
for (let rIdx = 0; rIdx < Math.min(tableData.rows.length, xmlRows.length); rIdx++) {
|
|
101367
101409
|
const dataRow = tableData.rows[rIdx];
|
|
101368
101410
|
const xmlRow = xmlRows[rIdx];
|
|
@@ -161461,6 +161503,57 @@ function computeInlineEditorRect(nodeRect, containerRect) {
|
|
|
161461
161503
|
height: nodeRect.height
|
|
161462
161504
|
};
|
|
161463
161505
|
}
|
|
161506
|
+
function measureSvgViewportRect(source) {
|
|
161507
|
+
const graphic = source;
|
|
161508
|
+
if (typeof graphic.getBBox !== "function" || typeof graphic.getCTM !== "function") {
|
|
161509
|
+
return null;
|
|
161510
|
+
}
|
|
161511
|
+
try {
|
|
161512
|
+
let viewport = graphic.ownerSVGElement;
|
|
161513
|
+
if (!viewport) {
|
|
161514
|
+
return null;
|
|
161515
|
+
}
|
|
161516
|
+
let matrix = graphic.getCTM();
|
|
161517
|
+
if (viewport.ownerSVGElement) {
|
|
161518
|
+
while (viewport.ownerSVGElement) {
|
|
161519
|
+
viewport = viewport.ownerSVGElement;
|
|
161520
|
+
}
|
|
161521
|
+
const viewportMatrix = viewport.getCTM();
|
|
161522
|
+
const viewportScreen = viewport.getScreenCTM();
|
|
161523
|
+
const graphicScreen = graphic.getScreenCTM();
|
|
161524
|
+
if (!viewportMatrix || !viewportScreen || !graphicScreen) {
|
|
161525
|
+
return null;
|
|
161526
|
+
}
|
|
161527
|
+
matrix = viewportMatrix.multiply(viewportScreen.inverse()).multiply(graphicScreen);
|
|
161528
|
+
}
|
|
161529
|
+
if (!matrix) {
|
|
161530
|
+
return null;
|
|
161531
|
+
}
|
|
161532
|
+
const box = graphic.getBBox();
|
|
161533
|
+
const points4 = [
|
|
161534
|
+
[box.x, box.y],
|
|
161535
|
+
[box.x + box.width, box.y],
|
|
161536
|
+
[box.x, box.y + box.height],
|
|
161537
|
+
[box.x + box.width, box.y + box.height]
|
|
161538
|
+
].map(([x, y]) => ({
|
|
161539
|
+
x: matrix.a * x + matrix.c * y + matrix.e,
|
|
161540
|
+
y: matrix.b * x + matrix.d * y + matrix.f
|
|
161541
|
+
}));
|
|
161542
|
+
if (box.width < 0 || box.height < 0 || points4.some(({ x, y }) => !Number.isFinite(x) || !Number.isFinite(y))) {
|
|
161543
|
+
return null;
|
|
161544
|
+
}
|
|
161545
|
+
const left = Math.min(...points4.map(({ x }) => x));
|
|
161546
|
+
const top = Math.min(...points4.map(({ y }) => y));
|
|
161547
|
+
return {
|
|
161548
|
+
left,
|
|
161549
|
+
top,
|
|
161550
|
+
width: Math.max(...points4.map(({ x }) => x)) - left,
|
|
161551
|
+
height: Math.max(...points4.map(({ y }) => y)) - top
|
|
161552
|
+
};
|
|
161553
|
+
} catch {
|
|
161554
|
+
return null;
|
|
161555
|
+
}
|
|
161556
|
+
}
|
|
161464
161557
|
function proportionalShapeCount(shownNodes, totalNodes, totalShapes) {
|
|
161465
161558
|
return Math.ceil(shownNodes / Math.max(totalNodes, 1) * totalShapes);
|
|
161466
161559
|
}
|
|
@@ -203545,6 +203638,7 @@ exports.masterViewElements = masterViewElements;
|
|
|
203545
203638
|
exports.masterViewPseudoSlide = masterViewPseudoSlide;
|
|
203546
203639
|
exports.matchCommentMentionAuthors = matchCommentMentionAuthors;
|
|
203547
203640
|
exports.mayLeaveSlideShow = mayLeaveSlideShow;
|
|
203641
|
+
exports.measureSvgViewportRect = measureSvgViewportRect;
|
|
203548
203642
|
exports.mediaFallbackIcon = mediaFallbackIcon;
|
|
203549
203643
|
exports.mediaFallbackLabelKey = mediaFallbackLabelKey;
|
|
203550
203644
|
exports.mediaFallbackVisual = mediaFallbackVisual;
|
|
Binary file
|
|
Binary file
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ThemePresets, PptxMarkdownConverter, hasTextProperties, hasShapeProperties } from './chunk-
|
|
1
|
+
import { ThemePresets, PptxMarkdownConverter, hasTextProperties, hasShapeProperties } from './chunk-PO2PYVHF.mjs';
|
|
2
2
|
import { __export } from './chunk-XGB3TDIC.mjs';
|
|
3
3
|
import * as mcp from 'pptx-viewer-mcp';
|
|
4
4
|
import * as mcpSchemas from 'pptx-viewer-mcp/schemas';
|
|
Binary file
|
|
Binary file
|
package/dist/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
require('./chunk-
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var
|
|
3
|
+
var chunkLTQRC4WB_js = require('./chunk-LTQRC4WB.js');
|
|
4
|
+
require('./chunk-C7H7NM2W.js');
|
|
5
|
+
var chunkTTCWWF47_js = require('./chunk-TTCWWF47.js');
|
|
6
|
+
var chunkBJL5MJ7A_js = require('./chunk-BJL5MJ7A.js');
|
|
7
|
+
var chunkVRMITIZZ_js = require('./chunk-VRMITIZZ.js');
|
|
8
8
|
var chunk3AJ54EAB_js = require('./chunk-3AJ54EAB.js');
|
|
9
9
|
require('./chunk-4VNS5WPM.js');
|
|
10
10
|
|
|
@@ -12,163 +12,163 @@ require('./chunk-4VNS5WPM.js');
|
|
|
12
12
|
|
|
13
13
|
Object.defineProperty(exports, "PowerPointViewer", {
|
|
14
14
|
enumerable: true,
|
|
15
|
-
get: function () { return
|
|
15
|
+
get: function () { return chunkLTQRC4WB_js.PowerPointViewer; }
|
|
16
16
|
});
|
|
17
17
|
Object.defineProperty(exports, "SlideCanvas", {
|
|
18
18
|
enumerable: true,
|
|
19
|
-
get: function () { return
|
|
19
|
+
get: function () { return chunkLTQRC4WB_js.SlideCanvas; }
|
|
20
20
|
});
|
|
21
21
|
Object.defineProperty(exports, "SlideTemplateGalleryDialog", {
|
|
22
22
|
enumerable: true,
|
|
23
|
-
get: function () { return
|
|
23
|
+
get: function () { return chunkLTQRC4WB_js.SlideTemplateGalleryDialog; }
|
|
24
24
|
});
|
|
25
25
|
Object.defineProperty(exports, "SlideTemplatePreview", {
|
|
26
26
|
enumerable: true,
|
|
27
|
-
get: function () { return
|
|
27
|
+
get: function () { return chunkLTQRC4WB_js.SlideTemplatePreview; }
|
|
28
28
|
});
|
|
29
29
|
Object.defineProperty(exports, "Toolbar", {
|
|
30
30
|
enumerable: true,
|
|
31
|
-
get: function () { return
|
|
31
|
+
get: function () { return chunkLTQRC4WB_js.Toolbar; }
|
|
32
32
|
});
|
|
33
33
|
Object.defineProperty(exports, "ViewerThemeProvider", {
|
|
34
34
|
enumerable: true,
|
|
35
|
-
get: function () { return
|
|
35
|
+
get: function () { return chunkLTQRC4WB_js.ViewerThemeProvider; }
|
|
36
36
|
});
|
|
37
37
|
Object.defineProperty(exports, "useViewerTheme", {
|
|
38
38
|
enumerable: true,
|
|
39
|
-
get: function () { return
|
|
39
|
+
get: function () { return chunkLTQRC4WB_js.useViewerTheme; }
|
|
40
40
|
});
|
|
41
41
|
Object.defineProperty(exports, "renderToCanvas", {
|
|
42
42
|
enumerable: true,
|
|
43
|
-
get: function () { return
|
|
43
|
+
get: function () { return chunkTTCWWF47_js.renderToCanvas; }
|
|
44
44
|
});
|
|
45
45
|
Object.defineProperty(exports, "useViewerBuildingBlocks", {
|
|
46
46
|
enumerable: true,
|
|
47
|
-
get: function () { return
|
|
47
|
+
get: function () { return chunkTTCWWF47_js.useViewerBuildingBlocks; }
|
|
48
48
|
});
|
|
49
49
|
Object.defineProperty(exports, "getAnimationInitialStyle", {
|
|
50
50
|
enumerable: true,
|
|
51
|
-
get: function () { return
|
|
51
|
+
get: function () { return chunkBJL5MJ7A_js.getAnimationInitialStyle; }
|
|
52
52
|
});
|
|
53
53
|
Object.defineProperty(exports, "AVATAR_COLOR_SWATCHES", {
|
|
54
54
|
enumerable: true,
|
|
55
|
-
get: function () { return
|
|
55
|
+
get: function () { return chunkVRMITIZZ_js.AVATAR_COLOR_SWATCHES; }
|
|
56
56
|
});
|
|
57
57
|
Object.defineProperty(exports, "DEFAULT_VIEWER_PROFILE", {
|
|
58
58
|
enumerable: true,
|
|
59
|
-
get: function () { return
|
|
59
|
+
get: function () { return chunkVRMITIZZ_js.DEFAULT_VIEWER_PROFILE; }
|
|
60
60
|
});
|
|
61
61
|
Object.defineProperty(exports, "PPTX_OPEN_ACCEPT", {
|
|
62
62
|
enumerable: true,
|
|
63
|
-
get: function () { return
|
|
63
|
+
get: function () { return chunkVRMITIZZ_js.PPTX_OPEN_ACCEPT; }
|
|
64
64
|
});
|
|
65
65
|
Object.defineProperty(exports, "PRESENTATION_OPEN_EXTENSIONS", {
|
|
66
66
|
enumerable: true,
|
|
67
|
-
get: function () { return
|
|
67
|
+
get: function () { return chunkVRMITIZZ_js.PRESENTATION_OPEN_EXTENSIONS; }
|
|
68
68
|
});
|
|
69
69
|
Object.defineProperty(exports, "SLIDE_TEMPLATES", {
|
|
70
70
|
enumerable: true,
|
|
71
|
-
get: function () { return
|
|
71
|
+
get: function () { return chunkVRMITIZZ_js.SLIDE_TEMPLATES; }
|
|
72
72
|
});
|
|
73
73
|
Object.defineProperty(exports, "THEME_CATALOG", {
|
|
74
74
|
enumerable: true,
|
|
75
|
-
get: function () { return
|
|
75
|
+
get: function () { return chunkVRMITIZZ_js.THEME_CATALOG; }
|
|
76
76
|
});
|
|
77
77
|
Object.defineProperty(exports, "VIEWER_PREFS_STORAGE_KEY", {
|
|
78
78
|
enumerable: true,
|
|
79
|
-
get: function () { return
|
|
79
|
+
get: function () { return chunkVRMITIZZ_js.VIEWER_PREFS_STORAGE_KEY; }
|
|
80
80
|
});
|
|
81
81
|
Object.defineProperty(exports, "buildSlideTemplateContent", {
|
|
82
82
|
enumerable: true,
|
|
83
|
-
get: function () { return
|
|
83
|
+
get: function () { return chunkVRMITIZZ_js.buildSlideTemplateContent; }
|
|
84
84
|
});
|
|
85
85
|
Object.defineProperty(exports, "buildSlideTemplateSlide", {
|
|
86
86
|
enumerable: true,
|
|
87
|
-
get: function () { return
|
|
87
|
+
get: function () { return chunkVRMITIZZ_js.buildSlideTemplateSlide; }
|
|
88
88
|
});
|
|
89
89
|
Object.defineProperty(exports, "clearAllLocalViewerData", {
|
|
90
90
|
enumerable: true,
|
|
91
|
-
get: function () { return
|
|
91
|
+
get: function () { return chunkVRMITIZZ_js.clearAllLocalViewerData; }
|
|
92
92
|
});
|
|
93
93
|
Object.defineProperty(exports, "clearStoredViewerPrefs", {
|
|
94
94
|
enumerable: true,
|
|
95
|
-
get: function () { return
|
|
95
|
+
get: function () { return chunkVRMITIZZ_js.clearStoredViewerPrefs; }
|
|
96
96
|
});
|
|
97
97
|
Object.defineProperty(exports, "defaultCssVars", {
|
|
98
98
|
enumerable: true,
|
|
99
|
-
get: function () { return
|
|
99
|
+
get: function () { return chunkVRMITIZZ_js.defaultCssVars; }
|
|
100
100
|
});
|
|
101
101
|
Object.defineProperty(exports, "defaultRadius", {
|
|
102
102
|
enumerable: true,
|
|
103
|
-
get: function () { return
|
|
103
|
+
get: function () { return chunkVRMITIZZ_js.defaultRadius; }
|
|
104
104
|
});
|
|
105
105
|
Object.defineProperty(exports, "defaultThemeColors", {
|
|
106
106
|
enumerable: true,
|
|
107
|
-
get: function () { return
|
|
107
|
+
get: function () { return chunkVRMITIZZ_js.defaultThemeColors; }
|
|
108
108
|
});
|
|
109
109
|
Object.defineProperty(exports, "getLocalStorageUsageSummary", {
|
|
110
110
|
enumerable: true,
|
|
111
|
-
get: function () { return
|
|
111
|
+
get: function () { return chunkVRMITIZZ_js.getLocalStorageUsageSummary; }
|
|
112
112
|
});
|
|
113
113
|
Object.defineProperty(exports, "isLegacyBinaryPresentation", {
|
|
114
114
|
enumerable: true,
|
|
115
|
-
get: function () { return
|
|
115
|
+
get: function () { return chunkVRMITIZZ_js.isLegacyBinaryPresentation; }
|
|
116
116
|
});
|
|
117
117
|
Object.defineProperty(exports, "isSupportedPresentationFile", {
|
|
118
118
|
enumerable: true,
|
|
119
|
-
get: function () { return
|
|
119
|
+
get: function () { return chunkVRMITIZZ_js.isSupportedPresentationFile; }
|
|
120
120
|
});
|
|
121
121
|
Object.defineProperty(exports, "presentationBaseName", {
|
|
122
122
|
enumerable: true,
|
|
123
|
-
get: function () { return
|
|
123
|
+
get: function () { return chunkVRMITIZZ_js.presentationBaseName; }
|
|
124
124
|
});
|
|
125
125
|
Object.defineProperty(exports, "readStoredViewerPrefs", {
|
|
126
126
|
enumerable: true,
|
|
127
|
-
get: function () { return
|
|
127
|
+
get: function () { return chunkVRMITIZZ_js.readStoredViewerPrefs; }
|
|
128
128
|
});
|
|
129
129
|
Object.defineProperty(exports, "resolveProfileInitial", {
|
|
130
130
|
enumerable: true,
|
|
131
|
-
get: function () { return
|
|
131
|
+
get: function () { return chunkVRMITIZZ_js.resolveProfileInitial; }
|
|
132
132
|
});
|
|
133
133
|
Object.defineProperty(exports, "resolveThemeCatalogEntry", {
|
|
134
134
|
enumerable: true,
|
|
135
|
-
get: function () { return
|
|
135
|
+
get: function () { return chunkVRMITIZZ_js.resolveThemeCatalogEntry; }
|
|
136
136
|
});
|
|
137
137
|
Object.defineProperty(exports, "saveViewerProfile", {
|
|
138
138
|
enumerable: true,
|
|
139
|
-
get: function () { return
|
|
139
|
+
get: function () { return chunkVRMITIZZ_js.saveViewerProfile; }
|
|
140
140
|
});
|
|
141
141
|
Object.defineProperty(exports, "savedPresentationFileName", {
|
|
142
142
|
enumerable: true,
|
|
143
|
-
get: function () { return
|
|
143
|
+
get: function () { return chunkVRMITIZZ_js.savedPresentationFileName; }
|
|
144
144
|
});
|
|
145
145
|
Object.defineProperty(exports, "themeToCssVars", {
|
|
146
146
|
enumerable: true,
|
|
147
|
-
get: function () { return
|
|
147
|
+
get: function () { return chunkVRMITIZZ_js.themeToCssVars; }
|
|
148
148
|
});
|
|
149
149
|
Object.defineProperty(exports, "vermilionDarkColors", {
|
|
150
150
|
enumerable: true,
|
|
151
|
-
get: function () { return
|
|
151
|
+
get: function () { return chunkVRMITIZZ_js.vermilionDarkColors; }
|
|
152
152
|
});
|
|
153
153
|
Object.defineProperty(exports, "vermilionDarkTheme", {
|
|
154
154
|
enumerable: true,
|
|
155
|
-
get: function () { return
|
|
155
|
+
get: function () { return chunkVRMITIZZ_js.vermilionDarkTheme; }
|
|
156
156
|
});
|
|
157
157
|
Object.defineProperty(exports, "vermilionLightColors", {
|
|
158
158
|
enumerable: true,
|
|
159
|
-
get: function () { return
|
|
159
|
+
get: function () { return chunkVRMITIZZ_js.vermilionLightColors; }
|
|
160
160
|
});
|
|
161
161
|
Object.defineProperty(exports, "vermilionLightTheme", {
|
|
162
162
|
enumerable: true,
|
|
163
|
-
get: function () { return
|
|
163
|
+
get: function () { return chunkVRMITIZZ_js.vermilionLightTheme; }
|
|
164
164
|
});
|
|
165
165
|
Object.defineProperty(exports, "vermilionRadius", {
|
|
166
166
|
enumerable: true,
|
|
167
|
-
get: function () { return
|
|
167
|
+
get: function () { return chunkVRMITIZZ_js.vermilionRadius; }
|
|
168
168
|
});
|
|
169
169
|
Object.defineProperty(exports, "writeStoredViewerPrefs", {
|
|
170
170
|
enumerable: true,
|
|
171
|
-
get: function () { return
|
|
171
|
+
get: function () { return chunkVRMITIZZ_js.writeStoredViewerPrefs; }
|
|
172
172
|
});
|
|
173
173
|
Object.defineProperty(exports, "LOCALE_CATALOG", {
|
|
174
174
|
enumerable: true,
|
package/dist/index.js.br
CHANGED
|
Binary file
|
package/dist/index.js.gz
CHANGED
|
Binary file
|
package/dist/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { PowerPointViewer, SlideCanvas, SlideTemplateGalleryDialog, SlideTemplatePreview, Toolbar, ViewerThemeProvider, useViewerTheme } from './chunk-
|
|
2
|
-
import './chunk-
|
|
3
|
-
export { renderToCanvas, useViewerBuildingBlocks } from './chunk-
|
|
4
|
-
export { getAnimationInitialStyle } from './chunk-
|
|
5
|
-
export { AVATAR_COLOR_SWATCHES, DEFAULT_VIEWER_PROFILE, PPTX_OPEN_ACCEPT, PRESENTATION_OPEN_EXTENSIONS, SLIDE_TEMPLATES, THEME_CATALOG, VIEWER_PREFS_STORAGE_KEY, buildSlideTemplateContent, buildSlideTemplateSlide, clearAllLocalViewerData, clearStoredViewerPrefs, defaultCssVars, defaultRadius, defaultThemeColors, getLocalStorageUsageSummary, isLegacyBinaryPresentation, isSupportedPresentationFile, presentationBaseName, readStoredViewerPrefs, resolveProfileInitial, resolveThemeCatalogEntry, saveViewerProfile, savedPresentationFileName, themeToCssVars, vermilionDarkColors, vermilionDarkTheme, vermilionLightColors, vermilionLightTheme, vermilionRadius, writeStoredViewerPrefs } from './chunk-
|
|
1
|
+
export { PowerPointViewer, SlideCanvas, SlideTemplateGalleryDialog, SlideTemplatePreview, Toolbar, ViewerThemeProvider, useViewerTheme } from './chunk-RWVMSJ7C.mjs';
|
|
2
|
+
import './chunk-YUIXPWFT.mjs';
|
|
3
|
+
export { renderToCanvas, useViewerBuildingBlocks } from './chunk-QLZHTIH6.mjs';
|
|
4
|
+
export { getAnimationInitialStyle } from './chunk-U2H7CQ34.mjs';
|
|
5
|
+
export { AVATAR_COLOR_SWATCHES, DEFAULT_VIEWER_PROFILE, PPTX_OPEN_ACCEPT, PRESENTATION_OPEN_EXTENSIONS, SLIDE_TEMPLATES, THEME_CATALOG, VIEWER_PREFS_STORAGE_KEY, buildSlideTemplateContent, buildSlideTemplateSlide, clearAllLocalViewerData, clearStoredViewerPrefs, defaultCssVars, defaultRadius, defaultThemeColors, getLocalStorageUsageSummary, isLegacyBinaryPresentation, isSupportedPresentationFile, presentationBaseName, readStoredViewerPrefs, resolveProfileInitial, resolveThemeCatalogEntry, saveViewerProfile, savedPresentationFileName, themeToCssVars, vermilionDarkColors, vermilionDarkTheme, vermilionLightColors, vermilionLightTheme, vermilionRadius, writeStoredViewerPrefs } from './chunk-PO2PYVHF.mjs';
|
|
6
6
|
export { LOCALE_CATALOG } from './chunk-HMX3MQR7.mjs';
|
|
7
7
|
import './chunk-XGB3TDIC.mjs';
|
package/dist/index.mjs.br
CHANGED
|
Binary file
|
package/dist/index.mjs.gz
CHANGED
|
Binary file
|