pptx-react-viewer 3.0.0 → 3.0.2
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 +51 -0
- package/dist/{AiChatPanel-NLIUZ5RI.js → AiChatPanel-235ZZA3Y.js} +23 -23
- package/dist/AiChatPanel-235ZZA3Y.js.br +0 -0
- package/dist/AiChatPanel-235ZZA3Y.js.gz +0 -0
- package/dist/{AiChatPanel-DMBQPAGB.mjs → AiChatPanel-DYOBY6OG.mjs} +3 -3
- package/dist/AiChatPanel-DYOBY6OG.mjs.br +0 -0
- package/dist/AiChatPanel-DYOBY6OG.mjs.gz +0 -0
- package/dist/{Model3DScene-JNZN42TU.js → Model3DScene-5QDYQF55.js} +2 -2
- package/dist/Model3DScene-5QDYQF55.js.br +0 -0
- package/dist/Model3DScene-5QDYQF55.js.gz +0 -0
- package/dist/{Model3DScene-ZO6U7YVU.mjs → Model3DScene-A3652H7T.mjs} +1 -1
- package/dist/Model3DScene-A3652H7T.mjs.br +0 -0
- package/dist/Model3DScene-A3652H7T.mjs.gz +0 -0
- package/dist/{SurfaceChart3DScene-P6CVRWDQ.mjs → SurfaceChart3DScene-N66TY4SW.mjs} +1 -1
- package/dist/SurfaceChart3DScene-N66TY4SW.mjs.br +0 -0
- package/dist/SurfaceChart3DScene-N66TY4SW.mjs.gz +0 -0
- package/dist/{SurfaceChart3DScene-PGD4ZCLI.js → SurfaceChart3DScene-QHENN3AF.js} +2 -2
- package/dist/SurfaceChart3DScene-QHENN3AF.js.br +0 -0
- package/dist/SurfaceChart3DScene-QHENN3AF.js.gz +0 -0
- package/dist/{chunk-SDOQKSKI.js → chunk-35YJ5RLU.js} +10 -10
- package/dist/chunk-35YJ5RLU.js.br +0 -0
- package/dist/{chunk-SDOQKSKI.js.gz → chunk-35YJ5RLU.js.gz} +0 -0
- package/dist/{chunk-H2ONCGFZ.mjs → chunk-4LHG6ZL7.mjs} +71 -23
- package/dist/chunk-4LHG6ZL7.mjs.br +0 -0
- package/dist/chunk-4LHG6ZL7.mjs.gz +0 -0
- package/dist/{chunk-3MW6F3K7.js → chunk-7HUYHWQS.js} +389 -389
- package/dist/chunk-7HUYHWQS.js.br +0 -0
- package/dist/chunk-7HUYHWQS.js.gz +0 -0
- package/dist/{chunk-OB4PKKIN.mjs → chunk-EVXT7HLY.mjs} +1 -1
- package/dist/chunk-EVXT7HLY.mjs.br +0 -0
- package/dist/chunk-EVXT7HLY.mjs.gz +0 -0
- package/dist/{chunk-WFMSDYVQ.js → chunk-GJ7E44BG.js} +3 -3
- package/dist/chunk-GJ7E44BG.js.br +0 -0
- package/dist/chunk-GJ7E44BG.js.gz +0 -0
- package/dist/{chunk-OXPD2UYI.mjs → chunk-M2TISD4A.mjs} +10 -10
- package/dist/chunk-M2TISD4A.mjs.br +0 -0
- package/dist/{chunk-OXPD2UYI.mjs.gz → chunk-M2TISD4A.mjs.gz} +0 -0
- package/dist/{chunk-S6PFSR7I.mjs → chunk-QG7TXWXP.mjs} +1 -1
- package/dist/chunk-QG7TXWXP.mjs.br +0 -0
- package/dist/chunk-QG7TXWXP.mjs.gz +0 -0
- package/dist/{chunk-RSEZYBKT.js → chunk-RYLLTHFD.js} +1112 -1064
- package/dist/chunk-RYLLTHFD.js.br +0 -0
- package/dist/chunk-RYLLTHFD.js.gz +0 -0
- package/dist/{chunk-XMLPTDPM.js → chunk-UU6NFFRR.js} +147 -147
- package/dist/chunk-UU6NFFRR.js.br +0 -0
- package/dist/chunk-UU6NFFRR.js.gz +0 -0
- package/dist/{chunk-BGAJLL4N.mjs → chunk-YISXETNN.mjs} +2 -2
- package/dist/chunk-YISXETNN.mjs.br +0 -0
- package/dist/chunk-YISXETNN.mjs.gz +0 -0
- package/dist/index.d.ts.map +1 -1
- 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 +2 -2
- package/dist/AiChatPanel-DMBQPAGB.mjs.br +0 -0
- package/dist/AiChatPanel-DMBQPAGB.mjs.gz +0 -0
- package/dist/AiChatPanel-NLIUZ5RI.js.br +0 -0
- package/dist/AiChatPanel-NLIUZ5RI.js.gz +0 -0
- package/dist/Model3DScene-JNZN42TU.js.br +0 -0
- package/dist/Model3DScene-JNZN42TU.js.gz +0 -0
- package/dist/Model3DScene-ZO6U7YVU.mjs.br +0 -0
- package/dist/Model3DScene-ZO6U7YVU.mjs.gz +0 -0
- package/dist/SurfaceChart3DScene-P6CVRWDQ.mjs.br +0 -0
- package/dist/SurfaceChart3DScene-P6CVRWDQ.mjs.gz +0 -0
- package/dist/SurfaceChart3DScene-PGD4ZCLI.js.br +0 -0
- package/dist/SurfaceChart3DScene-PGD4ZCLI.js.gz +0 -0
- package/dist/chunk-3MW6F3K7.js.br +0 -0
- package/dist/chunk-3MW6F3K7.js.gz +0 -0
- package/dist/chunk-BGAJLL4N.mjs.br +0 -0
- package/dist/chunk-BGAJLL4N.mjs.gz +0 -0
- package/dist/chunk-H2ONCGFZ.mjs.br +0 -0
- package/dist/chunk-H2ONCGFZ.mjs.gz +0 -0
- package/dist/chunk-OB4PKKIN.mjs.br +0 -0
- package/dist/chunk-OB4PKKIN.mjs.gz +0 -0
- package/dist/chunk-OXPD2UYI.mjs.br +0 -0
- package/dist/chunk-RSEZYBKT.js.br +0 -0
- package/dist/chunk-RSEZYBKT.js.gz +0 -0
- package/dist/chunk-S6PFSR7I.mjs.br +0 -0
- package/dist/chunk-S6PFSR7I.mjs.gz +0 -0
- package/dist/chunk-SDOQKSKI.js.br +0 -0
- package/dist/chunk-WFMSDYVQ.js.br +0 -0
- package/dist/chunk-WFMSDYVQ.js.gz +0 -0
- package/dist/chunk-XMLPTDPM.js.br +0 -0
- package/dist/chunk-XMLPTDPM.js.gz +0 -0
|
Binary file
|
|
Binary file
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ThemePresets, PptxMarkdownConverter } from './chunk-
|
|
1
|
+
import { ThemePresets, PptxMarkdownConverter } from './chunk-M2TISD4A.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
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunk35YJ5RLU_js = require('./chunk-35YJ5RLU.js');
|
|
4
4
|
var chunk4VNS5WPM_js = require('./chunk-4VNS5WPM.js');
|
|
5
5
|
var mcp = require('pptx-viewer-mcp');
|
|
6
6
|
var mcpSchemas = require('pptx-viewer-mcp/schemas');
|
|
@@ -14879,7 +14879,7 @@ async function buildSlideMarkdown(slides, slideIndex2, meta3, options = {}) {
|
|
|
14879
14879
|
};
|
|
14880
14880
|
let markdown;
|
|
14881
14881
|
try {
|
|
14882
|
-
const converter = new
|
|
14882
|
+
const converter = new chunk35YJ5RLU_js.PptxMarkdownConverter(
|
|
14883
14883
|
"",
|
|
14884
14884
|
{
|
|
14885
14885
|
sourceName: meta3.title ?? "deck.pptx",
|
|
@@ -15471,7 +15471,7 @@ var getTheme = (ctx) => {
|
|
|
15471
15471
|
name: theme?.name,
|
|
15472
15472
|
colorScheme: theme?.colorScheme,
|
|
15473
15473
|
fontScheme: theme?.fontScheme,
|
|
15474
|
-
availablePresets: Object.keys(
|
|
15474
|
+
availablePresets: Object.keys(chunk35YJ5RLU_js.ThemePresets)
|
|
15475
15475
|
};
|
|
15476
15476
|
};
|
|
15477
15477
|
var readExecutors = {
|
|
Binary file
|
|
Binary file
|
|
@@ -99811,6 +99811,15 @@ function strokeOnlyPresetPathData(element) {
|
|
|
99811
99811
|
const stroked = paths.filter((path) => path.stroke !== false).map((path) => path.d);
|
|
99812
99812
|
return stroked.length > 0 ? stroked.join(" ") : void 0;
|
|
99813
99813
|
}
|
|
99814
|
+
function hasStrokePaint(style) {
|
|
99815
|
+
if (!style || Math.max(0, style.strokeWidth ?? 0) <= 0) {
|
|
99816
|
+
return false;
|
|
99817
|
+
}
|
|
99818
|
+
return style.strokeColor !== void 0 || style.strokeFillMode !== void 0;
|
|
99819
|
+
}
|
|
99820
|
+
function paintedStrokeWidth(style) {
|
|
99821
|
+
return hasStrokePaint(style) ? Math.max(0, style?.strokeWidth ?? 0) : 0;
|
|
99822
|
+
}
|
|
99814
99823
|
function clampUnit(value) {
|
|
99815
99824
|
return value < 0 ? 0 : value > 1 ? 1 : value;
|
|
99816
99825
|
}
|
|
@@ -100384,7 +100393,7 @@ function outlineStrands(compoundLine, strokeWidth) {
|
|
|
100384
100393
|
return offsets.map((offset, idx) => ({ strokeWidth: widths[idx] ?? strokeWidth, offset }));
|
|
100385
100394
|
}
|
|
100386
100395
|
function needsCenteredStrokeOverlay(element, style, declaredWidth) {
|
|
100387
|
-
if (!style || declaredWidth <= 0 || element.type === "connector") {
|
|
100396
|
+
if (!style || declaredWidth <= 0 || element.type === "connector" || !hasStrokePaint(style)) {
|
|
100388
100397
|
return false;
|
|
100389
100398
|
}
|
|
100390
100399
|
const shapeType = getShapeType(element.shapeType);
|
|
@@ -100535,15 +100544,6 @@ function resolveShapeGeometry(element) {
|
|
|
100535
100544
|
}
|
|
100536
100545
|
return { kind: "none" };
|
|
100537
100546
|
}
|
|
100538
|
-
function hasStrokePaint(style) {
|
|
100539
|
-
if (!style || Math.max(0, style.strokeWidth ?? 0) <= 0) {
|
|
100540
|
-
return false;
|
|
100541
|
-
}
|
|
100542
|
-
return style.strokeColor !== void 0 || style.strokeFillMode !== void 0;
|
|
100543
|
-
}
|
|
100544
|
-
function paintedStrokeWidth(style) {
|
|
100545
|
-
return hasStrokePaint(style) ? Math.max(0, style?.strokeWidth ?? 0) : 0;
|
|
100546
|
-
}
|
|
100547
100547
|
var NO_STROKE = {
|
|
100548
100548
|
borderWidth: 0,
|
|
100549
100549
|
borderStyle: void 0,
|
|
Binary file
|
|
Binary file
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { translationsEn } from './chunk-L5MNLIQF.mjs';
|
|
2
|
-
import { SHAPE_PRESET_DEFS, VIEWER_SHORTCUT_REFERENCE, getAnimationInitialStyle, cloneHistorySnapshot, hasShapeProperties, getImageFitStyle, isImageLikeElement, getImageTilingStyle, runMediaCommand, findMediaElementByElementId, mediaPlaybackAttributes, buildTextBlockStyle, hasTextProperties, toCssWritingMode, toCssTextOrientation, toCssVerticalDirection, buildTextBodyLayoutStyle, buildTextBody3DSceneStyle, buildParagraphs, colorWithOpacity, normalizeHexColor, build3DExtrusionData, getComputedFillStyle, getComputedEffectStyle, getComputedStrokeStyle, isStrokeOnlyPresetElement, resolveShapeGeometry, normalizeStrokeDashType, getSvgStrokeDasharray, buildSvgGradientDef, isCalloutShape, getCalloutLeaderLineGeometry, buildCalloutLeaderLineSvgPath, getCalloutViewBoxBounds, svgLineCap, getCompoundLineOffsets, getCompoundLineWidths, computeSelectionRect, DEFAULT_FONT_FAMILY, cellStyleToCss, rectToCells, isCellInRect, tableContainerCss, buildChartViewModel, resolveChartKind, chartPreserveAspectRatio, buildNotesPdfBytes, buildSlidesPdfBytes, buildPreviewAnimation, buildMotionPathPreview, getRoundRectRadiusPx2, getResolvedShapeClipPath, mediaFallbackVisual, registerPersistentAudio, resolveAutoFitFontScale, resolveFontKerning, getSubstituteFontFamily, parsePanoseString, resolveScriptFontSet, hasDistinctScriptFonts, nestedTextDecorationStyle, pieceLetterSpacing, resolveMetricTrackingPx, hollowTextFillStyle, buildTabContext, TEXT_BUILD_ID_SEP, buildTextBuildSpec, textBuildSpanStyle, apply3dEffects, clampUnitInterval, customGeometryPathsToSvgSubpaths, svgGradientFillRef, buildSubpathPaints, computeColumnBoundaries, getTableCellBandStyle, parseDrawingColor, parseDrawingColorOpacity, getCellDiagonalBorders, cellRunStyle, getChartStylePalette, computeChartLegendLayout, mediaFallbackIcon, mediaFallbackLabelKey, MEDIA_CHROME_ATTRIBUTE, convertOmmlToMathMl, sanitizeMathMl, tableCellCss, computeResizedColumnWidths, computeResizedRowHeight, DEFAULT_ROW_HEIGHT, ooxmlGradientAngleToCssDegrees, buildRunTabLines, chartPartToAttrs, splitRunForMetrics, splitRunByScriptFont } from './chunk-
|
|
2
|
+
import { SHAPE_PRESET_DEFS, VIEWER_SHORTCUT_REFERENCE, getAnimationInitialStyle, cloneHistorySnapshot, hasShapeProperties, getImageFitStyle, isImageLikeElement, getImageTilingStyle, runMediaCommand, findMediaElementByElementId, mediaPlaybackAttributes, buildTextBlockStyle, hasTextProperties, toCssWritingMode, toCssTextOrientation, toCssVerticalDirection, buildTextBodyLayoutStyle, buildTextBody3DSceneStyle, buildParagraphs, colorWithOpacity, normalizeHexColor, build3DExtrusionData, getComputedFillStyle, getComputedEffectStyle, getComputedStrokeStyle, isStrokeOnlyPresetElement, resolveShapeGeometry, normalizeStrokeDashType, getSvgStrokeDasharray, buildSvgGradientDef, isCalloutShape, getCalloutLeaderLineGeometry, buildCalloutLeaderLineSvgPath, getCalloutViewBoxBounds, svgLineCap, getCompoundLineOffsets, getCompoundLineWidths, computeSelectionRect, DEFAULT_FONT_FAMILY, cellStyleToCss, rectToCells, isCellInRect, tableContainerCss, buildChartViewModel, resolveChartKind, chartPreserveAspectRatio, buildNotesPdfBytes, buildSlidesPdfBytes, buildPreviewAnimation, buildMotionPathPreview, getRoundRectRadiusPx2, getResolvedShapeClipPath, mediaFallbackVisual, registerPersistentAudio, resolveAutoFitFontScale, resolveFontKerning, getSubstituteFontFamily, parsePanoseString, resolveScriptFontSet, hasDistinctScriptFonts, nestedTextDecorationStyle, pieceLetterSpacing, resolveMetricTrackingPx, hollowTextFillStyle, buildTabContext, TEXT_BUILD_ID_SEP, buildTextBuildSpec, textBuildSpanStyle, apply3dEffects, clampUnitInterval, customGeometryPathsToSvgSubpaths, svgGradientFillRef, buildSubpathPaints, computeColumnBoundaries, getTableCellBandStyle, parseDrawingColor, parseDrawingColorOpacity, getCellDiagonalBorders, cellRunStyle, getChartStylePalette, computeChartLegendLayout, mediaFallbackIcon, mediaFallbackLabelKey, MEDIA_CHROME_ATTRIBUTE, convertOmmlToMathMl, sanitizeMathMl, tableCellCss, computeResizedColumnWidths, computeResizedRowHeight, DEFAULT_ROW_HEIGHT, ooxmlGradientAngleToCssDegrees, buildRunTabLines, chartPartToAttrs, splitRunForMetrics, splitRunByScriptFont } from './chunk-M2TISD4A.mjs';
|
|
3
3
|
import { clsx } from 'clsx';
|
|
4
4
|
import { twMerge } from 'tailwind-merge';
|
|
5
5
|
import React6, { useRef, useState, useEffect, useCallback, useMemo, useLayoutEffect } from 'react';
|
|
Binary file
|
|
Binary file
|