pptx-react-viewer 3.0.1 → 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.
Files changed (99) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/dist/{AiChatPanel-NLIUZ5RI.js → AiChatPanel-235ZZA3Y.js} +23 -23
  3. package/dist/AiChatPanel-235ZZA3Y.js.br +0 -0
  4. package/dist/AiChatPanel-235ZZA3Y.js.gz +0 -0
  5. package/dist/{AiChatPanel-DMBQPAGB.mjs → AiChatPanel-DYOBY6OG.mjs} +3 -3
  6. package/dist/AiChatPanel-DYOBY6OG.mjs.br +0 -0
  7. package/dist/AiChatPanel-DYOBY6OG.mjs.gz +0 -0
  8. package/dist/{Model3DScene-JNZN42TU.js → Model3DScene-5QDYQF55.js} +2 -2
  9. package/dist/Model3DScene-5QDYQF55.js.br +0 -0
  10. package/dist/Model3DScene-5QDYQF55.js.gz +0 -0
  11. package/dist/{Model3DScene-ZO6U7YVU.mjs → Model3DScene-A3652H7T.mjs} +1 -1
  12. package/dist/Model3DScene-A3652H7T.mjs.br +0 -0
  13. package/dist/Model3DScene-A3652H7T.mjs.gz +0 -0
  14. package/dist/{SurfaceChart3DScene-P6CVRWDQ.mjs → SurfaceChart3DScene-N66TY4SW.mjs} +1 -1
  15. package/dist/SurfaceChart3DScene-N66TY4SW.mjs.br +0 -0
  16. package/dist/SurfaceChart3DScene-N66TY4SW.mjs.gz +0 -0
  17. package/dist/{SurfaceChart3DScene-PGD4ZCLI.js → SurfaceChart3DScene-QHENN3AF.js} +2 -2
  18. package/dist/SurfaceChart3DScene-QHENN3AF.js.br +0 -0
  19. package/dist/SurfaceChart3DScene-QHENN3AF.js.gz +0 -0
  20. package/dist/{chunk-SDOQKSKI.js → chunk-35YJ5RLU.js} +10 -10
  21. package/dist/chunk-35YJ5RLU.js.br +0 -0
  22. package/dist/{chunk-SDOQKSKI.js.gz → chunk-35YJ5RLU.js.gz} +0 -0
  23. package/dist/{chunk-VGHEHM66.mjs → chunk-4LHG6ZL7.mjs} +185 -163
  24. package/dist/chunk-4LHG6ZL7.mjs.br +0 -0
  25. package/dist/chunk-4LHG6ZL7.mjs.gz +0 -0
  26. package/dist/{chunk-3MW6F3K7.js → chunk-7HUYHWQS.js} +389 -389
  27. package/dist/chunk-7HUYHWQS.js.br +0 -0
  28. package/dist/chunk-7HUYHWQS.js.gz +0 -0
  29. package/dist/{chunk-OB4PKKIN.mjs → chunk-EVXT7HLY.mjs} +1 -1
  30. package/dist/chunk-EVXT7HLY.mjs.br +0 -0
  31. package/dist/chunk-EVXT7HLY.mjs.gz +0 -0
  32. package/dist/{chunk-WFMSDYVQ.js → chunk-GJ7E44BG.js} +3 -3
  33. package/dist/chunk-GJ7E44BG.js.br +0 -0
  34. package/dist/chunk-GJ7E44BG.js.gz +0 -0
  35. package/dist/{chunk-OXPD2UYI.mjs → chunk-M2TISD4A.mjs} +10 -10
  36. package/dist/chunk-M2TISD4A.mjs.br +0 -0
  37. package/dist/{chunk-OXPD2UYI.mjs.gz → chunk-M2TISD4A.mjs.gz} +0 -0
  38. package/dist/{chunk-S6PFSR7I.mjs → chunk-QG7TXWXP.mjs} +1 -1
  39. package/dist/chunk-QG7TXWXP.mjs.br +0 -0
  40. package/dist/chunk-QG7TXWXP.mjs.gz +0 -0
  41. package/dist/{chunk-54SDLPJY.js → chunk-RYLLTHFD.js} +1218 -1196
  42. package/dist/chunk-RYLLTHFD.js.br +0 -0
  43. package/dist/chunk-RYLLTHFD.js.gz +0 -0
  44. package/dist/{chunk-XMLPTDPM.js → chunk-UU6NFFRR.js} +147 -147
  45. package/dist/chunk-UU6NFFRR.js.br +0 -0
  46. package/dist/chunk-UU6NFFRR.js.gz +0 -0
  47. package/dist/{chunk-BGAJLL4N.mjs → chunk-YISXETNN.mjs} +2 -2
  48. package/dist/chunk-YISXETNN.mjs.br +0 -0
  49. package/dist/chunk-YISXETNN.mjs.gz +0 -0
  50. package/dist/index.d.ts.map +1 -1
  51. package/dist/index.js +45 -45
  52. package/dist/index.js.br +0 -0
  53. package/dist/index.js.gz +0 -0
  54. package/dist/index.mjs +5 -5
  55. package/dist/index.mjs.br +0 -0
  56. package/dist/index.mjs.gz +0 -0
  57. package/dist/internals.js +78 -78
  58. package/dist/internals.js.br +0 -0
  59. package/dist/internals.js.gz +0 -0
  60. package/dist/internals.mjs +3 -3
  61. package/dist/internals.mjs.br +0 -0
  62. package/dist/internals.mjs.gz +0 -0
  63. package/dist/viewer/index.js +26 -26
  64. package/dist/viewer/index.js.br +0 -0
  65. package/dist/viewer/index.js.gz +0 -0
  66. package/dist/viewer/index.mjs +5 -5
  67. package/dist/viewer/index.mjs.br +0 -0
  68. package/dist/viewer/index.mjs.gz +0 -0
  69. package/package.json +2 -2
  70. package/dist/AiChatPanel-DMBQPAGB.mjs.br +0 -0
  71. package/dist/AiChatPanel-DMBQPAGB.mjs.gz +0 -0
  72. package/dist/AiChatPanel-NLIUZ5RI.js.br +0 -0
  73. package/dist/AiChatPanel-NLIUZ5RI.js.gz +0 -0
  74. package/dist/Model3DScene-JNZN42TU.js.br +0 -0
  75. package/dist/Model3DScene-JNZN42TU.js.gz +0 -0
  76. package/dist/Model3DScene-ZO6U7YVU.mjs.br +0 -0
  77. package/dist/Model3DScene-ZO6U7YVU.mjs.gz +0 -0
  78. package/dist/SurfaceChart3DScene-P6CVRWDQ.mjs.br +0 -0
  79. package/dist/SurfaceChart3DScene-P6CVRWDQ.mjs.gz +0 -0
  80. package/dist/SurfaceChart3DScene-PGD4ZCLI.js.br +0 -0
  81. package/dist/SurfaceChart3DScene-PGD4ZCLI.js.gz +0 -0
  82. package/dist/chunk-3MW6F3K7.js.br +0 -0
  83. package/dist/chunk-3MW6F3K7.js.gz +0 -0
  84. package/dist/chunk-54SDLPJY.js.br +0 -0
  85. package/dist/chunk-54SDLPJY.js.gz +0 -0
  86. package/dist/chunk-BGAJLL4N.mjs.br +0 -0
  87. package/dist/chunk-BGAJLL4N.mjs.gz +0 -0
  88. package/dist/chunk-OB4PKKIN.mjs.br +0 -0
  89. package/dist/chunk-OB4PKKIN.mjs.gz +0 -0
  90. package/dist/chunk-OXPD2UYI.mjs.br +0 -0
  91. package/dist/chunk-S6PFSR7I.mjs.br +0 -0
  92. package/dist/chunk-S6PFSR7I.mjs.gz +0 -0
  93. package/dist/chunk-SDOQKSKI.js.br +0 -0
  94. package/dist/chunk-VGHEHM66.mjs.br +0 -0
  95. package/dist/chunk-VGHEHM66.mjs.gz +0 -0
  96. package/dist/chunk-WFMSDYVQ.js.br +0 -0
  97. package/dist/chunk-WFMSDYVQ.js.gz +0 -0
  98. package/dist/chunk-XMLPTDPM.js.br +0 -0
  99. package/dist/chunk-XMLPTDPM.js.gz +0 -0
Binary file
Binary file
@@ -1,4 +1,4 @@
1
- import { ThemePresets, PptxMarkdownConverter } from './chunk-OXPD2UYI.mjs';
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 chunkSDOQKSKI_js = require('./chunk-SDOQKSKI.js');
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 chunkSDOQKSKI_js.PptxMarkdownConverter(
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(chunkSDOQKSKI_js.ThemePresets)
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
@@ -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-OXPD2UYI.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-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