pptx-react-viewer 2.2.1 → 2.3.0

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 (120) hide show
  1. package/CHANGELOG.md +2 -0
  2. package/dist/{AiChatPanel-O4NYWO3D.js → AiChatPanel-HC3CE3TL.js} +23 -23
  3. package/dist/AiChatPanel-HC3CE3TL.js.br +0 -0
  4. package/dist/AiChatPanel-HC3CE3TL.js.gz +0 -0
  5. package/dist/{AiChatPanel-XRKEPXAM.mjs → AiChatPanel-PXZYHJUB.mjs} +4 -4
  6. package/dist/AiChatPanel-PXZYHJUB.mjs.br +0 -0
  7. package/dist/AiChatPanel-PXZYHJUB.mjs.gz +0 -0
  8. package/dist/{Model3DScene-HYE6HA2C.js → Model3DScene-37QZRHV5.js} +3 -3
  9. package/dist/{Model3DScene-HYE6HA2C.js.br → Model3DScene-37QZRHV5.js.br} +0 -0
  10. package/dist/Model3DScene-37QZRHV5.js.gz +0 -0
  11. package/dist/{Model3DScene-JN5F5C4Z.mjs → Model3DScene-ZG4HTMPX.mjs} +2 -2
  12. package/dist/{Model3DScene-JN5F5C4Z.mjs.br → Model3DScene-ZG4HTMPX.mjs.br} +0 -0
  13. package/dist/Model3DScene-ZG4HTMPX.mjs.gz +0 -0
  14. package/dist/{SurfaceChart3DScene-FDJ6LC4E.js → SurfaceChart3DScene-QIREQ66D.js} +3 -3
  15. package/dist/SurfaceChart3DScene-QIREQ66D.js.br +0 -0
  16. package/dist/SurfaceChart3DScene-QIREQ66D.js.gz +0 -0
  17. package/dist/{SurfaceChart3DScene-V7P3LQVV.mjs → SurfaceChart3DScene-Z7R6DZXN.mjs} +2 -2
  18. package/dist/{SurfaceChart3DScene-V7P3LQVV.mjs.br → SurfaceChart3DScene-Z7R6DZXN.mjs.br} +0 -0
  19. package/dist/SurfaceChart3DScene-Z7R6DZXN.mjs.gz +0 -0
  20. package/dist/{chunk-R2H3FHK6.js → chunk-3TB45PVK.js} +42 -99
  21. package/dist/chunk-3TB45PVK.js.br +0 -0
  22. package/dist/chunk-3TB45PVK.js.gz +0 -0
  23. package/dist/{chunk-6G6S7PEI.mjs → chunk-4AAFZFGH.mjs} +36 -7
  24. package/dist/chunk-4AAFZFGH.mjs.br +0 -0
  25. package/dist/chunk-4AAFZFGH.mjs.gz +0 -0
  26. package/dist/{chunk-XJTWUXXC.js → chunk-EUIFPDXZ.js} +3 -3
  27. package/dist/chunk-EUIFPDXZ.js.br +0 -0
  28. package/dist/chunk-EUIFPDXZ.js.gz +0 -0
  29. package/dist/{chunk-7NSLKNCT.mjs → chunk-I5LEMC5C.mjs} +4 -4
  30. package/dist/chunk-I5LEMC5C.mjs.br +0 -0
  31. package/dist/chunk-I5LEMC5C.mjs.gz +0 -0
  32. package/dist/{chunk-RYHBWTPI.mjs → chunk-J5A22DZ7.mjs} +63 -38
  33. package/dist/chunk-J5A22DZ7.mjs.br +0 -0
  34. package/dist/chunk-J5A22DZ7.mjs.gz +0 -0
  35. package/dist/{chunk-PE2I5L6R.mjs → chunk-JFNMD6TM.mjs} +41 -100
  36. package/dist/chunk-JFNMD6TM.mjs.br +0 -0
  37. package/dist/chunk-JFNMD6TM.mjs.gz +0 -0
  38. package/dist/{chunk-2QHCOESN.js → chunk-KDW3LLG5.js} +77 -47
  39. package/dist/chunk-KDW3LLG5.js.br +0 -0
  40. package/dist/chunk-KDW3LLG5.js.gz +0 -0
  41. package/dist/{chunk-K2AW5UXT.js → chunk-L7JNCVTF.js} +309 -309
  42. package/dist/chunk-L7JNCVTF.js.br +0 -0
  43. package/dist/chunk-L7JNCVTF.js.gz +0 -0
  44. package/dist/{chunk-I2HF7ZPO.mjs → chunk-M5YR3QSB.mjs} +1 -1
  45. package/dist/chunk-M5YR3QSB.mjs.br +0 -0
  46. package/dist/chunk-M5YR3QSB.mjs.gz +0 -0
  47. package/dist/{chunk-2U243ZEP.js → chunk-P7UVBRFO.js} +257 -241
  48. package/dist/chunk-P7UVBRFO.js.br +0 -0
  49. package/dist/chunk-P7UVBRFO.js.gz +0 -0
  50. package/dist/{chunk-O75FHZQJ.mjs → chunk-VOHTAUN4.mjs} +23 -7
  51. package/dist/chunk-VOHTAUN4.mjs.br +0 -0
  52. package/dist/chunk-VOHTAUN4.mjs.gz +0 -0
  53. package/dist/{chunk-QULJW7LU.js → chunk-ZLSVW5GP.js} +898 -873
  54. package/dist/chunk-ZLSVW5GP.js.br +0 -0
  55. package/dist/chunk-ZLSVW5GP.js.gz +0 -0
  56. package/dist/{dist-ZCJLIRYG.js → dist-FTEVZZPM.js} +576 -568
  57. package/dist/dist-FTEVZZPM.js.br +0 -0
  58. package/dist/dist-FTEVZZPM.js.gz +0 -0
  59. package/dist/{dist-VEWYRBTB.mjs → dist-L7GZVBMG.mjs} +1 -1
  60. package/dist/dist-L7GZVBMG.mjs.br +0 -0
  61. package/dist/dist-L7GZVBMG.mjs.gz +0 -0
  62. package/dist/index.d.ts +13 -0
  63. package/dist/index.js +35 -35
  64. package/dist/index.js.br +0 -0
  65. package/dist/index.js.gz +0 -0
  66. package/dist/index.mjs +6 -6
  67. package/dist/index.mjs.br +0 -0
  68. package/dist/index.mjs.gz +0 -0
  69. package/dist/internals.d.ts +13 -0
  70. package/dist/internals.js +79 -79
  71. package/dist/internals.js.br +0 -0
  72. package/dist/internals.js.gz +0 -0
  73. package/dist/internals.mjs +4 -4
  74. package/dist/internals.mjs.br +0 -0
  75. package/dist/internals.mjs.gz +0 -0
  76. package/dist/viewer/index.d.ts +13 -0
  77. package/dist/viewer/index.js +22 -22
  78. package/dist/viewer/index.js.br +0 -0
  79. package/dist/viewer/index.js.gz +0 -0
  80. package/dist/viewer/index.mjs +6 -6
  81. package/dist/viewer/index.mjs.br +0 -0
  82. package/dist/viewer/index.mjs.gz +0 -0
  83. package/package.json +1 -1
  84. package/dist/AiChatPanel-O4NYWO3D.js.br +0 -0
  85. package/dist/AiChatPanel-O4NYWO3D.js.gz +0 -0
  86. package/dist/AiChatPanel-XRKEPXAM.mjs.br +0 -0
  87. package/dist/AiChatPanel-XRKEPXAM.mjs.gz +0 -0
  88. package/dist/Model3DScene-HYE6HA2C.js.gz +0 -0
  89. package/dist/Model3DScene-JN5F5C4Z.mjs.gz +0 -0
  90. package/dist/SurfaceChart3DScene-FDJ6LC4E.js.br +0 -0
  91. package/dist/SurfaceChart3DScene-FDJ6LC4E.js.gz +0 -0
  92. package/dist/SurfaceChart3DScene-V7P3LQVV.mjs.gz +0 -0
  93. package/dist/chunk-2QHCOESN.js.br +0 -0
  94. package/dist/chunk-2QHCOESN.js.gz +0 -0
  95. package/dist/chunk-2U243ZEP.js.br +0 -0
  96. package/dist/chunk-2U243ZEP.js.gz +0 -0
  97. package/dist/chunk-6G6S7PEI.mjs.br +0 -0
  98. package/dist/chunk-6G6S7PEI.mjs.gz +0 -0
  99. package/dist/chunk-7NSLKNCT.mjs.br +0 -0
  100. package/dist/chunk-7NSLKNCT.mjs.gz +0 -0
  101. package/dist/chunk-I2HF7ZPO.mjs.br +0 -0
  102. package/dist/chunk-I2HF7ZPO.mjs.gz +0 -0
  103. package/dist/chunk-K2AW5UXT.js.br +0 -0
  104. package/dist/chunk-K2AW5UXT.js.gz +0 -0
  105. package/dist/chunk-O75FHZQJ.mjs.br +0 -0
  106. package/dist/chunk-O75FHZQJ.mjs.gz +0 -0
  107. package/dist/chunk-PE2I5L6R.mjs.br +0 -0
  108. package/dist/chunk-PE2I5L6R.mjs.gz +0 -0
  109. package/dist/chunk-QULJW7LU.js.br +0 -0
  110. package/dist/chunk-QULJW7LU.js.gz +0 -0
  111. package/dist/chunk-R2H3FHK6.js.br +0 -0
  112. package/dist/chunk-R2H3FHK6.js.gz +0 -0
  113. package/dist/chunk-RYHBWTPI.mjs.br +0 -0
  114. package/dist/chunk-RYHBWTPI.mjs.gz +0 -0
  115. package/dist/chunk-XJTWUXXC.js.br +0 -0
  116. package/dist/chunk-XJTWUXXC.js.gz +0 -0
  117. package/dist/dist-VEWYRBTB.mjs.br +0 -0
  118. package/dist/dist-VEWYRBTB.mjs.gz +0 -0
  119. package/dist/dist-ZCJLIRYG.js.br +0 -0
  120. package/dist/dist-ZCJLIRYG.js.gz +0 -0
Binary file
Binary file
@@ -1,6 +1,6 @@
1
- import { SHAPE_PRESET_DEFS, computeValueRangeForChart, getAnimationInitialStyle, cloneHistorySnapshot, isTemplateElement, clampCropValue, parseMediaCommand, normalizeHexColor, toCssWritingMode, toCssTextOrientation, toCssVerticalDirection, computeAutoFitTextStyle, resolveLineHeight, getKinsokuLineBreakStyles, buildTextBody3DSceneStyle, resolveParagraphRtl, resolveParagraphAlign, resolveCssTextAlign, colorWithOpacity, build3DExtrusionData, getResolvedShapeClipPath, normalizeStrokeDashType, buildCssGradientFromShapeStyle, buildShadowCssFromShapeStyle, buildInnerShadowCssFromShapeStyle, buildMultiLayerShadowCss, buildGlowBoxShadow, getCompoundLineBoxShadow, getSoftEdgeFilterId, getEffectDagFilter, buildPatternFillCss, buildReflectionCss, getCssBorderDashStyle, getCompoundLineBorderWidth, getSvgStrokeDasharray, svgLineCap, getCompoundLineOffsets, getCompoundLineWidths, computeSelectionRect, rectToCells, isCellInRect, buildChartViewModel, buildNotesPdfBytes, buildSlidesPdfBytes, buildPreviewAnimation, getRoundRectRadiusPx, substituteFieldText, resolveUnderlineDecorationStyle, hasDistinctScriptFonts, buildTextReflectionCss, getTextAlphaOpacity, buildTextRunFilterChain, buildTextShadowCss, TEXT_BUILD_ID_SEP, apply3dEffects, clampUnitInterval, computeColumnBoundaries, parseDrawingColor, parseDrawingColorOpacity, getCellDiagonalBorders, getPatternSvg, ooxmlDashToCssBorderStyle, cell3DBevelCss, getChartStylePalette, computeLayout, valueToY, formatAxisValue, computeLayoutOptions, splitSeriesByAxis, computeValueRange, getSecondaryValueAxis, seriesColor, paletteColor, resolveRegionCode, normalizeValue, sequentialColorScale, convertOmmlToMathMl, sanitizeMathMl, buildTextFillCss, resolvePictureBullet, computeResizedColumnWidths, computeResizedRowHeight, DEFAULT_ROW_HEIGHT, resolveFontRefIdx, tintColor2, shadeColor2, segmentByScript, resolveFontForScript, generateLogTicks, formatAxisValueWithUnits, getDisplayUnitLabel, hexToRgbChannels, chartPartToAttrs } from './chunk-6G6S7PEI.mjs';
1
+ import { SHAPE_PRESET_DEFS, computeValueRangeForChart, getAnimationInitialStyle, cloneHistorySnapshot, isTemplateElement, clampCropValue, parseMediaCommand, normalizeHexColor, toCssWritingMode, toCssTextOrientation, toCssVerticalDirection, computeAutoFitTextStyle, resolveLineHeight, getKinsokuLineBreakStyles, buildTextBody3DSceneStyle, resolveParagraphRtl, resolveParagraphAlign, resolveCssTextAlign, colorWithOpacity, build3DExtrusionData, getResolvedShapeClipPath, normalizeStrokeDashType, buildCssGradientFromShapeStyle, buildShadowCssFromShapeStyle, buildInnerShadowCssFromShapeStyle, buildMultiLayerShadowCss, buildGlowBoxShadow, getCompoundLineBoxShadow, getSoftEdgeFilterId, getEffectDagFilter, buildPatternFillCss, buildReflectionCss, getCssBorderDashStyle, getCompoundLineBorderWidth, getSvgStrokeDasharray, svgLineCap, getCompoundLineOffsets, getCompoundLineWidths, computeSelectionRect, rectToCells, isCellInRect, buildChartViewModel, buildNotesPdfBytes, buildSlidesPdfBytes, buildPreviewAnimation, getRoundRectRadiusPx, substituteFieldText, resolveUnderlineDecorationStyle, hasDistinctScriptFonts, buildTextReflectionCss, getTextAlphaOpacity, buildTextRunFilterChain, buildTextShadowCss, TEXT_BUILD_ID_SEP, apply3dEffects, clampUnitInterval, computeColumnBoundaries, parseDrawingColor, parseDrawingColorOpacity, getCellDiagonalBorders, getPatternSvg, ooxmlDashToCssBorderStyle, cell3DBevelCss, getChartStylePalette, computeLayout, valueToY, formatAxisValue, computeLayoutOptions, splitSeriesByAxis, computeValueRange, getSecondaryValueAxis, seriesColor, paletteColor, resolveRegionCode, normalizeValue, sequentialColorScale, convertOmmlToMathMl, sanitizeMathMl, buildTextFillCss, resolvePictureBullet, computeResizedColumnWidths, computeResizedRowHeight, DEFAULT_ROW_HEIGHT, resolveFontRefIdx, tintColor2, shadeColor2, segmentByScript, resolveFontForScript, generateLogTicks, formatAxisValueWithUnits, getDisplayUnitLabel, hexToRgbChannels, chartPartToAttrs } from './chunk-4AAFZFGH.mjs';
2
2
  import { translationsEn } from './chunk-PZTPX3HK.mjs';
3
- import { hasShapeProperties, isImageLikeElement, hasTextProperties, isCalloutShape, getCalloutLeaderLineGeometry, buildCalloutLeaderLineSvgPath, getCalloutViewBoxBounds, getSubstituteFontFamily, evaluatePresetShape, customGeometryPathsToSvgSubpaths } from './chunk-PE2I5L6R.mjs';
3
+ import { hasShapeProperties, isImageLikeElement, hasTextProperties, isCalloutShape, getCalloutLeaderLineGeometry, buildCalloutLeaderLineSvgPath, getCalloutViewBoxBounds, getSubstituteFontFamily, evaluatePresetShape, customGeometryPathsToSvgSubpaths, ooxmlGradientAngleToCssDegrees } from './chunk-JFNMD6TM.mjs';
4
4
  import { clsx } from 'clsx';
5
5
  import { twMerge } from 'tailwind-merge';
6
6
  import React6, { useState, useEffect, useMemo, Suspense, useRef, useCallback, useLayoutEffect } from 'react';
@@ -2516,10 +2516,26 @@ function getShapeVisualStyle(element, hasFill, fillColor, strokeWidth, strokeCol
2516
2516
  }
2517
2517
  }
2518
2518
  const base = {
2519
- backgroundColor: imageFillUrl ? "transparent" : patternFill ? patternFill.backgroundColor : hasFill ? resolvedFillColor : "transparent",
2519
+ // A gradient fill REPLACES the solid fill, it does not sit on top of it.
2520
+ // The parser also records a representative `fillColor`/`fillOpacity` for a
2521
+ // `a:gradFill` (used by thumbnails and the inspector), and painting that as
2522
+ // a `backgroundColor` under the gradient washed the whole shape: wherever
2523
+ // the gradient's own stops were transparent the solid still showed, so a
2524
+ // fade-to-transparent overlay dimmed everything behind it and its edge read
2525
+ // as a hard line. Mirrors the fill precedence in shared's
2526
+ // `getComputedFillStyle` (image -> gradient -> pattern -> solid).
2527
+ backgroundColor: imageFillUrl ? "transparent" : patternFill ? patternFill.backgroundColor : hasFill && !fillGradient ? resolvedFillColor : "transparent",
2520
2528
  backgroundImage: imageFillUrl ? `url(${imageFillUrl})` : patternFill ? patternFill.backgroundImage : hasFill && fillGradient ? fillGradient : void 0,
2521
- backgroundRepeat: imageFillUrl ? imageFillMode === "tile" ? "repeat" : "no-repeat" : patternFill ? "repeat" : void 0,
2522
- backgroundSize: imageFillUrl ? imageFillMode === "tile" ? "auto" : "100% 100%" : patternFill ? "auto" : void 0,
2529
+ backgroundRepeat: imageFillUrl ? imageFillMode === "tile" ? "repeat" : "no-repeat" : patternFill ? "repeat" : hasFill && fillGradient ? "no-repeat" : void 0,
2530
+ backgroundSize: imageFillUrl ? imageFillMode === "tile" ? "auto" : "100% 100%" : patternFill ? "auto" : hasFill && fillGradient ? "100% 100%" : void 0,
2531
+ // The container always carries a 1px border (transparent unless the shape
2532
+ // has a stroke or is hovered) and `box-sizing: border-box`, so the default
2533
+ // `background-origin: padding-box` sizes the paint 2px smaller than the
2534
+ // shape. Combined with the default `background-repeat: repeat` that made a
2535
+ // gradient tile wrap, painting a 1px sliver of its opposite end along the
2536
+ // edge - a fade-to-transparent overlay grew a hard opaque line down its
2537
+ // side. Paint from the border box so the fill matches the shape outline.
2538
+ backgroundOrigin: "border-box",
2523
2539
  backgroundPosition: imageFillUrl ? "center" : void 0,
2524
2540
  boxShadow: combinedBoxShadow,
2525
2541
  WebkitBoxReflect: reflectCss,
@@ -3095,7 +3111,7 @@ function parseGradientFillCss(gradFill) {
3095
3111
  const lin = gradFill["a:lin"];
3096
3112
  if (lin) {
3097
3113
  const angRaw = Number.parseInt(String(lin["@_ang"] || "0"), 10);
3098
- const angleDeg = Math.round(angRaw / 6e4);
3114
+ const angleDeg = Math.round(ooxmlGradientAngleToCssDegrees(angRaw / 6e4));
3099
3115
  return `linear-gradient(${angleDeg}deg, ${stopStrings})`;
3100
3116
  }
3101
3117
  const path = gradFill["a:path"];
@@ -6250,7 +6266,7 @@ function FailedToLoad() {
6250
6266
  var LazySurfaceChart3DScene = React6.lazy(
6251
6267
  async () => {
6252
6268
  try {
6253
- return await import('./SurfaceChart3DScene-V7P3LQVV.mjs');
6269
+ return await import('./SurfaceChart3DScene-Z7R6DZXN.mjs');
6254
6270
  } catch {
6255
6271
  return { default: FailedToLoad };
6256
6272
  }
Binary file
Binary file