pptx-react-viewer 4.31.1 → 4.33.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 (118) hide show
  1. package/CHANGELOG.md +41 -0
  2. package/README.md +3 -2
  3. package/dist/{AiChatPanel-I3D2C4YR.mjs → AiChatPanel-47A5ONVT.mjs} +2 -2
  4. package/dist/AiChatPanel-47A5ONVT.mjs.br +0 -0
  5. package/dist/AiChatPanel-47A5ONVT.mjs.gz +0 -0
  6. package/dist/{AiChatPanel-JKF3V3IM.js → AiChatPanel-FV5ECOV5.js} +10 -10
  7. package/dist/AiChatPanel-FV5ECOV5.js.br +0 -0
  8. package/dist/AiChatPanel-FV5ECOV5.js.gz +0 -0
  9. package/dist/{Model3DScene-KYIYYLMY.js → Model3DScene-5HLXSIIK.js} +1 -1
  10. package/dist/Model3DScene-5HLXSIIK.js.br +0 -0
  11. package/dist/Model3DScene-5HLXSIIK.js.gz +0 -0
  12. package/dist/{Model3DScene-EZDCI7TT.mjs → Model3DScene-MSC4LEKG.mjs} +1 -1
  13. package/dist/Model3DScene-MSC4LEKG.mjs.br +0 -0
  14. package/dist/Model3DScene-MSC4LEKG.mjs.gz +0 -0
  15. package/dist/{chunk-TUYNK3GE.js → chunk-552NAFTD.js} +250 -249
  16. package/dist/chunk-552NAFTD.js.br +0 -0
  17. package/dist/chunk-552NAFTD.js.gz +0 -0
  18. package/dist/{chunk-7EFQBIJG.mjs → chunk-DD3ARHEW.mjs} +6 -5
  19. package/dist/chunk-DD3ARHEW.mjs.br +0 -0
  20. package/dist/{chunk-7EFQBIJG.mjs.gz → chunk-DD3ARHEW.mjs.gz} +0 -0
  21. package/dist/{chunk-VLZXLGG5.js → chunk-JL7A7NDD.js} +1355 -1294
  22. package/dist/chunk-JL7A7NDD.js.br +0 -0
  23. package/dist/chunk-JL7A7NDD.js.gz +0 -0
  24. package/dist/{chunk-CBR27PI3.mjs → chunk-LOBNIIFQ.mjs} +99 -38
  25. package/dist/chunk-LOBNIIFQ.mjs.br +0 -0
  26. package/dist/chunk-LOBNIIFQ.mjs.gz +0 -0
  27. package/dist/{chunk-GDQSMJQZ.mjs → chunk-Q3DHYOLK.mjs} +5 -1
  28. package/dist/chunk-Q3DHYOLK.mjs.br +0 -0
  29. package/dist/chunk-Q3DHYOLK.mjs.gz +0 -0
  30. package/dist/{chunk-POPGQIVR.js → chunk-SQUVXHAE.js} +5 -3
  31. package/dist/chunk-SQUVXHAE.js.br +0 -0
  32. package/dist/chunk-SQUVXHAE.js.gz +0 -0
  33. package/dist/{chunk-DFFCFNK2.js → chunk-W2IMY5SY.js} +5 -1
  34. package/dist/chunk-W2IMY5SY.js.br +0 -0
  35. package/dist/chunk-W2IMY5SY.js.gz +0 -0
  36. package/dist/{chunk-FBG42UO3.mjs → chunk-WEPZYAB6.mjs} +4 -2
  37. package/dist/chunk-WEPZYAB6.mjs.br +0 -0
  38. package/dist/chunk-WEPZYAB6.mjs.gz +0 -0
  39. package/dist/i18n.js +1 -1
  40. package/dist/i18n.js.br +2 -2
  41. package/dist/i18n.js.gz +0 -0
  42. package/dist/i18n.mjs +1 -1
  43. package/dist/i18n.mjs.br +1 -1
  44. package/dist/i18n.mjs.gz +0 -0
  45. package/dist/index.d.ts +19 -1
  46. package/dist/index.js +25 -25
  47. package/dist/index.js.br +0 -0
  48. package/dist/index.js.gz +0 -0
  49. package/dist/index.mjs +4 -4
  50. package/dist/index.mjs.br +0 -0
  51. package/dist/index.mjs.gz +0 -0
  52. package/dist/internals.js +82 -82
  53. package/dist/internals.js.br +0 -0
  54. package/dist/internals.js.gz +0 -0
  55. package/dist/internals.mjs +3 -3
  56. package/dist/internals.mjs.br +0 -0
  57. package/dist/internals.mjs.gz +0 -0
  58. package/dist/{three.module-2R4ADL7W.mjs → three.module-JPZUM7AI.mjs} +1 -1
  59. package/dist/three.module-JPZUM7AI.mjs.br +0 -0
  60. package/dist/three.module-JPZUM7AI.mjs.gz +0 -0
  61. package/dist/{three.module-LS32MK23.js → three.module-RIUI7P3J.js} +1 -1
  62. package/dist/three.module-RIUI7P3J.js.br +0 -0
  63. package/dist/three.module-RIUI7P3J.js.gz +0 -0
  64. package/dist/viewer/index.d.ts +19 -1
  65. package/dist/viewer/index.js +20 -20
  66. package/dist/viewer/index.js.br +0 -0
  67. package/dist/viewer/index.js.gz +0 -0
  68. package/dist/viewer/index.mjs +4 -4
  69. package/dist/viewer/index.mjs.br +0 -0
  70. package/dist/viewer/index.mjs.gz +0 -0
  71. package/dist/{y-webrtc-6DZI5KUK.mjs → y-webrtc-CCA4HVZZ.mjs} +1 -1
  72. package/dist/y-webrtc-CCA4HVZZ.mjs.br +0 -0
  73. package/dist/y-webrtc-CCA4HVZZ.mjs.gz +0 -0
  74. package/dist/{y-webrtc-OTRGEYOH.js → y-webrtc-MB5ZXFBA.js} +5 -5
  75. package/dist/y-webrtc-MB5ZXFBA.js.br +0 -0
  76. package/dist/y-webrtc-MB5ZXFBA.js.gz +0 -0
  77. package/dist/{y-websocket-AWBYMAHL.js → y-websocket-JQQZVAMX.js} +1 -1
  78. package/dist/y-websocket-JQQZVAMX.js.br +0 -0
  79. package/dist/y-websocket-JQQZVAMX.js.gz +0 -0
  80. package/dist/{y-websocket-VAKUVRQT.mjs → y-websocket-SCLLNICY.mjs} +1 -1
  81. package/dist/y-websocket-SCLLNICY.mjs.br +0 -0
  82. package/dist/y-websocket-SCLLNICY.mjs.gz +0 -0
  83. package/package.json +3 -3
  84. package/dist/AiChatPanel-I3D2C4YR.mjs.br +0 -0
  85. package/dist/AiChatPanel-I3D2C4YR.mjs.gz +0 -0
  86. package/dist/AiChatPanel-JKF3V3IM.js.br +0 -0
  87. package/dist/AiChatPanel-JKF3V3IM.js.gz +0 -0
  88. package/dist/Model3DScene-EZDCI7TT.mjs.br +0 -0
  89. package/dist/Model3DScene-EZDCI7TT.mjs.gz +0 -0
  90. package/dist/Model3DScene-KYIYYLMY.js.br +0 -0
  91. package/dist/Model3DScene-KYIYYLMY.js.gz +0 -0
  92. package/dist/chunk-7EFQBIJG.mjs.br +0 -0
  93. package/dist/chunk-CBR27PI3.mjs.br +0 -0
  94. package/dist/chunk-CBR27PI3.mjs.gz +0 -0
  95. package/dist/chunk-DFFCFNK2.js.br +0 -0
  96. package/dist/chunk-DFFCFNK2.js.gz +0 -0
  97. package/dist/chunk-FBG42UO3.mjs.br +0 -0
  98. package/dist/chunk-FBG42UO3.mjs.gz +0 -0
  99. package/dist/chunk-GDQSMJQZ.mjs.br +0 -0
  100. package/dist/chunk-GDQSMJQZ.mjs.gz +0 -0
  101. package/dist/chunk-POPGQIVR.js.br +0 -0
  102. package/dist/chunk-POPGQIVR.js.gz +0 -0
  103. package/dist/chunk-TUYNK3GE.js.br +0 -0
  104. package/dist/chunk-TUYNK3GE.js.gz +0 -0
  105. package/dist/chunk-VLZXLGG5.js.br +0 -0
  106. package/dist/chunk-VLZXLGG5.js.gz +0 -0
  107. package/dist/three.module-2R4ADL7W.mjs.br +0 -0
  108. package/dist/three.module-2R4ADL7W.mjs.gz +0 -0
  109. package/dist/three.module-LS32MK23.js.br +0 -0
  110. package/dist/three.module-LS32MK23.js.gz +0 -0
  111. package/dist/y-webrtc-6DZI5KUK.mjs.br +0 -0
  112. package/dist/y-webrtc-6DZI5KUK.mjs.gz +0 -0
  113. package/dist/y-webrtc-OTRGEYOH.js.br +0 -0
  114. package/dist/y-webrtc-OTRGEYOH.js.gz +0 -0
  115. package/dist/y-websocket-AWBYMAHL.js.br +0 -0
  116. package/dist/y-websocket-AWBYMAHL.js.gz +0 -0
  117. package/dist/y-websocket-VAKUVRQT.mjs.br +0 -0
  118. package/dist/y-websocket-VAKUVRQT.mjs.gz +0 -0
package/CHANGELOG.md CHANGED
@@ -7,6 +7,47 @@ A release listed with no entries carried no Conventional Commit in this package'
7
7
  scope: scripts/release-plan.mjs releases whenever any published file changes, not only on
8
8
  conventional commits.
9
9
 
10
+ ## [4.33.0](https://github.com/ChristopherVR/ooxml/releases/tag/pptx-react-viewer@4.33.0) - 2026-10-10
11
+
12
+ ### Features
13
+
14
+ - **color:** Add the Office theme colour palette to the color area ([646b6b5](https://github.com/ChristopherVR/ooxml/commit/646b6b532a304013f0c8783801ab3401de8a1950))
15
+ - **pptx:** Add host ribbon tabs to all five PowerPoint bindings ([2089f62](https://github.com/ChristopherVR/ooxml/commit/2089f620d736c867dbd383f2fe4dd39eff7e6cc3))
16
+ - **text:** Add the fonts' design advance widths, regular and bold ([15f7eeb](https://github.com/ChristopherVR/ooxml/commit/15f7eebb692c4cf43d8febdd49070e583daef22a))
17
+ - **visio:** Pick theme colours that follow the page theme ([d29c9c7](https://github.com/ChristopherVR/ooxml/commit/d29c9c7b8ae343821db3461ca55af2283d6a19ef))
18
+
19
+ ### Bug Fixes
20
+
21
+ - **pptx:** Verify certificate chains with node:crypto, not node-forge ([51e6312](https://github.com/ChristopherVR/ooxml/commit/51e6312aa152a47ac11a6beced49b373adf0fb68))
22
+ - **pptx:** Keep the browser's image drag out of picture moves ([817a36a](https://github.com/ChristopherVR/ooxml/commit/817a36a1eae21a48e149ee5459597577dd2cdf22))
23
+
24
+ ### Refactor
25
+
26
+ - **geometry:** Move the orthogonal connector router out of pptx ([7628894](https://github.com/ChristopherVR/ooxml/commit/7628894c847d098846b7250e8cf7cfee0b8e1ecd))
27
+ - **ui:** Move Excel and Word colour pickers onto the shared grid ([ab332b6](https://github.com/ChristopherVR/ooxml/commit/ab332b6ed7a4b80bc5016de05efb3fad694c85de))
28
+
29
+ ### Styling
30
+
31
+ - Apply oxfmt to files drifted from the formatter ([daeabf2](https://github.com/ChristopherVR/ooxml/commit/daeabf26125af866f90359ac8a5716234d5b8b36))
32
+
33
+ ## [4.32.0](https://github.com/ChristopherVR/ooxml/releases/tag/pptx-react-viewer@4.32.0) - 2026-10-10
34
+
35
+ ### Features
36
+
37
+ - **geometry:** Share arrow-key nudges and Shift angle snapping ([a839871](https://github.com/ChristopherVR/ooxml/commit/a8398713b97bcc9a193e6bd85aba51c55066eba8))
38
+
39
+ ### Testing
40
+
41
+ - **core:** Fuzz the xml, formula, number format and hyperlink parsers ([c6911a0](https://github.com/ChristopherVR/ooxml/commit/c6911a00f79fb07eab294d885b760452b4bdaf72))
42
+
43
+ ### Dependencies
44
+
45
+ - **deps:** Bump the production-minor-and-patch group with 5 updates ([#42](https://github.com/ChristopherVR/ooxml/issues/42)) ([fda493e](https://github.com/ChristopherVR/ooxml/commit/fda493e2697908c477ce845019d9c2fe8b591ab2))
46
+
47
+ ### Chores
48
+
49
+ - **deps-dev:** Bump the development-minor-and-patch group across 1 directory with 6 updates ([#43](https://github.com/ChristopherVR/ooxml/issues/43)) ([e3a4861](https://github.com/ChristopherVR/ooxml/commit/e3a4861279b8d2bbf3b869617329eddb953b7838))
50
+
10
51
  ## [4.31.1](https://github.com/ChristopherVR/ooxml/releases/tag/pptx-react-viewer@4.31.1) - 2026-10-09
11
52
 
12
53
  ### Bug Fixes
package/README.md CHANGED
@@ -34,8 +34,8 @@ npm install react react-dom framer-motion lucide-react react-icons jspdf jszip f
34
34
  ## Quick start
35
35
 
36
36
  ```tsx
37
- import { useState } from 'react';
38
37
  import { PowerPointViewer } from 'pptx-react-viewer';
38
+ import { useState } from 'react';
39
39
  // Not using Tailwind? Import the bundled stylesheet once at your app entry:
40
40
  import 'pptx-react-viewer/styles';
41
41
 
@@ -63,8 +63,8 @@ The component fills its parent, so give the parent a height. That's the whole se
63
63
  To read the edited presentation back out as bytes, pass a `ref` and call `getContent()`:
64
64
 
65
65
  ```tsx
66
- import { useRef } from 'react';
67
66
  import { PowerPointViewer, type PowerPointViewerHandle } from 'pptx-react-viewer';
67
+ import { useRef } from 'react';
68
68
 
69
69
  const viewerRef = useRef<PowerPointViewerHandle>(null);
70
70
 
@@ -123,6 +123,7 @@ const bytes = await viewerRef.current?.getContent(); // Uint8Array of a valid .p
123
123
  | `onStopCollaboration` | `() => void` | n/a | Called when the collaboration session stops |
124
124
  | `theme` | `ViewerTheme` | n/a | Theme configuration for customising colours, radius, and CSS vars |
125
125
  | `hiddenActions` | `ToolbarActionId[]` | n/a | Hide individual toolbar buttons and/or ribbon tabs (e.g. `['share', 'broadcast']`) instead of the whole toolbar; omitted hides nothing |
126
+ | `ribbonAddIns` | `RibbonAddInTab[]` | n/a | Ribbon tabs the host adds after Help; a command runs its `run` callback and raises `office-ribbon-add-in` (see the customization guide) |
126
127
  | `customization` | `ViewerCustomization` | - | Hide, lock or remap any part of the UI (ribbon tabs/buttons, File > Options pages/sections/settings, File tab, context menus, shortcuts, panels, AI/collaboration, dialogs); the same helpers (`hideRibbonTab`, `lockSetting`, ...) are on the `ref` handle. See the [UI Customization guide](https://christophervr.github.io/ooxml/pptx/guide/customization). |
127
128
  | `defaultThemeKey` | `string` | n/a | Initial File > Options > Appearance selection when no persisted preference exists |
128
129
  | `availableThemes` | `ThemeCatalogEntry[]` | n/a | Theme choices offered by File > Options > Appearance (defaults to the built-in catalog) |
@@ -1,5 +1,5 @@
1
- import { cn } from './chunk-FBG42UO3.mjs';
2
- import './chunk-GDQSMJQZ.mjs';
1
+ import { cn } from './chunk-WEPZYAB6.mjs';
2
+ import './chunk-Q3DHYOLK.mjs';
3
3
  import { useMemo, useRef, useState, useEffect, useReducer, useCallback } from 'react';
4
4
  import { useTranslation } from 'react-i18next';
5
5
  import { LuSparkles, LuX, LuLoaderCircle, LuTriangleAlert, LuHistory, LuMessageSquarePlus, LuTrash2, LuPlus, LuGitMerge, LuCrosshair, LuPinOff, LuPin, LuUser, LuBot, LuCheck, LuSquare, LuSend, LuMessageSquare, LuPalette, LuUndo2, LuWrench, LuStickyNote, LuFilm, LuNavigation, LuSearch, LuMove, LuChartColumn, LuLayoutTemplate, LuTable, LuShapes, LuType, LuEye } from 'react-icons/lu';
Binary file
Binary file
@@ -1,7 +1,7 @@
1
1
  'use strict';
2
2
 
3
- var chunkPOPGQIVR_js = require('./chunk-POPGQIVR.js');
4
- require('./chunk-DFFCFNK2.js');
3
+ var chunkSQUVXHAE_js = require('./chunk-SQUVXHAE.js');
4
+ require('./chunk-W2IMY5SY.js');
5
5
  var react = require('react');
6
6
  var reactI18next = require('react-i18next');
7
7
  var lu = require('react-icons/lu');
@@ -365,7 +365,7 @@ function AiComposer({
365
365
  disabled: value.trim().length === 0,
366
366
  title: t("pptx.ai.send"),
367
367
  "aria-label": t("pptx.ai.send"),
368
- className: chunkPOPGQIVR_js.cn(
368
+ className: chunkSQUVXHAE_js.cn(
369
369
  "shrink-0 rounded-sm p-1.5 transition-colors",
370
370
  value.trim().length === 0 ? "text-muted-foreground/50" : "bg-primary text-primary-foreground hover:bg-primary/90"
371
371
  ),
@@ -396,7 +396,7 @@ function AiFocusBar({
396
396
  chips.map((chip) => /* @__PURE__ */ jsxRuntime.jsx(
397
397
  "span",
398
398
  {
399
- className: chunkPOPGQIVR_js.cn(
399
+ className: chunkSQUVXHAE_js.cn(
400
400
  "inline-flex max-w-[10rem] items-center rounded-full px-2 py-0.5 text-[11px]",
401
401
  hasPicks || isPinned ? "bg-primary/15 text-primary" : "bg-muted text-muted-foreground"
402
402
  ),
@@ -433,7 +433,7 @@ function AiFocusBar({
433
433
  title: t("pptx.ai.pickElement"),
434
434
  "aria-label": t("pptx.ai.pickAria"),
435
435
  "aria-pressed": pickMode,
436
- className: chunkPOPGQIVR_js.cn(
436
+ className: chunkSQUVXHAE_js.cn(
437
437
  "rounded-sm p-1 max-md:min-w-[44px]! max-md:min-h-[44px]! flex items-center justify-center",
438
438
  pickMode ? "bg-primary text-primary-foreground" : "text-muted-foreground hover:bg-accent"
439
439
  ),
@@ -512,7 +512,7 @@ function AiHistoryList({ chats, activeChatId, onResume, onDelete }) {
512
512
  {
513
513
  type: "button",
514
514
  onClick: () => onResume(chat.id),
515
- className: chunkPOPGQIVR_js.cn(
515
+ className: chunkSQUVXHAE_js.cn(
516
516
  "flex min-w-0 flex-1 items-start gap-2 rounded-sm px-2 py-1.5 text-left hover:bg-accent",
517
517
  chat.id === activeChatId && "bg-accent/60"
518
518
  ),
@@ -676,17 +676,17 @@ function AiToolCallCard({ part }) {
676
676
  /* @__PURE__ */ jsxRuntime.jsx(
677
677
  Icon,
678
678
  {
679
- className: chunkPOPGQIVR_js.cn(
679
+ className: chunkSQUVXHAE_js.cn(
680
680
  "w-3.5 h-3.5 shrink-0",
681
681
  failed ? "text-destructive" : "text-muted-foreground"
682
682
  )
683
683
  }
684
684
  ),
685
- /* @__PURE__ */ jsxRuntime.jsx("span", { className: chunkPOPGQIVR_js.cn("truncate", failed ? "text-destructive" : "text-foreground"), children: activity.label }),
685
+ /* @__PURE__ */ jsxRuntime.jsx("span", { className: chunkSQUVXHAE_js.cn("truncate", failed ? "text-destructive" : "text-foreground"), children: activity.label }),
686
686
  /* @__PURE__ */ jsxRuntime.jsxs(
687
687
  "span",
688
688
  {
689
- className: chunkPOPGQIVR_js.cn(
689
+ className: chunkSQUVXHAE_js.cn(
690
690
  "ml-auto inline-flex items-center gap-1 rounded-sm px-1.5 py-0.5 text-[10px]",
691
691
  failed ? "bg-destructive/15 text-destructive" : done ? "bg-primary/10 text-primary" : "bg-muted text-muted-foreground"
692
692
  ),
@@ -734,7 +734,7 @@ function AiMessageList({ messages, isStreaming, bridge }) {
734
734
  /* @__PURE__ */ jsxRuntime.jsx(
735
735
  "div",
736
736
  {
737
- className: chunkPOPGQIVR_js.cn(
737
+ className: chunkSQUVXHAE_js.cn(
738
738
  "mt-0.5 flex h-6 w-6 shrink-0 items-center justify-center rounded-full",
739
739
  isUser ? "bg-secondary text-muted-foreground" : "bg-primary/15 text-primary"
740
740
  ),
Binary file
Binary file
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- require('./chunk-DFFCFNK2.js');
3
+ require('./chunk-W2IMY5SY.js');
4
4
  var pptx = require('ooxml-ui/pptx');
5
5
  var react = require('react');
6
6
  var jsxRuntime = require('react/jsx-runtime');
Binary file
Binary file
@@ -1,4 +1,4 @@
1
- import './chunk-GDQSMJQZ.mjs';
1
+ import './chunk-Q3DHYOLK.mjs';
2
2
  import { mountModel3D } from 'ooxml-ui/pptx';
3
3
  import { useRef, useEffect } from 'react';
4
4
  import { jsx } from 'react/jsx-runtime';