ooxml-ui 0.27.2 → 0.28.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 (424) hide show
  1. package/dist/chunk-A56QI2OA.js +57 -0
  2. package/dist/{chunk-LE4FTRWB.js → chunk-AJ2J734X.js} +619 -3
  3. package/dist/{chunk-4PBFBPOH.js → chunk-G4ZGQYBH.js} +2 -1
  4. package/dist/controls.js +1 -1
  5. package/dist/docx/backstage-home.d.ts +3 -0
  6. package/dist/docx/backstage-options.d.ts +13 -0
  7. package/dist/docx/backstage-pages.d.ts +41 -0
  8. package/dist/docx/backstage.d.ts +18 -0
  9. package/dist/docx/binding-labels.d.ts +9 -0
  10. package/dist/docx/bookmark-commands.d.ts +20 -0
  11. package/dist/docx/bookmark-dialog.d.ts +4 -0
  12. package/dist/docx/borders-dialog.d.ts +4 -0
  13. package/dist/docx/canvas-measurer.d.ts +7 -0
  14. package/dist/docx/caption-commands.d.ts +31 -0
  15. package/dist/docx/caption-dialog.d.ts +5 -0
  16. package/dist/docx/change-case.d.ts +5 -0
  17. package/dist/docx/character-style-picker.d.ts +12 -0
  18. package/dist/docx/chrome-icons.d.ts +25 -0
  19. package/dist/docx/collaboration-model.d.ts +4 -0
  20. package/dist/docx/collaboration-session.d.ts +18 -0
  21. package/dist/docx/columns-dialog.d.ts +10 -0
  22. package/dist/docx/comment-commands.d.ts +21 -0
  23. package/dist/docx/comments-panel.d.ts +19 -0
  24. package/dist/docx/component.d.ts +70 -0
  25. package/dist/docx/context-menu-actions.d.ts +10 -0
  26. package/dist/docx/context-menu-items.d.ts +36 -0
  27. package/dist/docx/context-menu.d.ts +25 -0
  28. package/dist/docx/contextual-tabs.d.ts +8 -0
  29. package/dist/docx/cover-page.d.ts +14 -0
  30. package/dist/docx/cross-reference-commands.d.ts +30 -0
  31. package/dist/docx/cross-reference-dialog.d.ts +5 -0
  32. package/dist/docx/dialog-fields.d.ts +22 -0
  33. package/dist/docx/dialog-shell.d.ts +19 -0
  34. package/dist/docx/drop-cap-command.d.ts +20 -0
  35. package/dist/docx/drop-cap-dialog.d.ts +4 -0
  36. package/dist/docx/editor-attributes.d.ts +26 -0
  37. package/dist/docx/editor-chrome.d.ts +59 -0
  38. package/dist/docx/editor-commands.d.ts +7 -0
  39. package/dist/docx/editor-controls.d.ts +10 -0
  40. package/dist/docx/editor-core.d.ts +78 -0
  41. package/dist/docx/editor-host.d.ts +19 -0
  42. package/dist/docx/editor-interactions.d.ts +2 -0
  43. package/dist/docx/editor-plugins.d.ts +16 -0
  44. package/dist/docx/editor-presence.d.ts +20 -0
  45. package/dist/docx/editor-render.d.ts +3 -0
  46. package/dist/docx/editor-shell.d.ts +11 -0
  47. package/dist/docx/element-api.d.ts +35 -0
  48. package/dist/docx/equation-schema.d.ts +4 -0
  49. package/dist/docx/events.d.ts +45 -0
  50. package/dist/docx/field-update.d.ts +16 -0
  51. package/dist/docx/file-commands.d.ts +15 -0
  52. package/dist/docx/focus-view.d.ts +3 -0
  53. package/dist/docx/font-advanced.d.ts +18 -0
  54. package/dist/docx/font-dialog-tabs.d.ts +8 -0
  55. package/dist/docx/font-dialog.d.ts +11 -0
  56. package/dist/docx/font-format-batch.d.ts +3 -0
  57. package/dist/docx/font-format.d.ts +38 -0
  58. package/dist/docx/font-step.d.ts +5 -0
  59. package/dist/docx/font-sync.d.ts +9 -0
  60. package/dist/docx/format-dialogs.d.ts +37 -0
  61. package/dist/docx/format-painter.d.ts +12 -0
  62. package/dist/docx/go-to-panel.d.ts +4 -0
  63. package/dist/docx/go-to.d.ts +23 -0
  64. package/dist/docx/hard-break-command.d.ts +3 -0
  65. package/dist/docx/header-footer-commands.d.ts +19 -0
  66. package/dist/docx/header-footer-editor.d.ts +40 -0
  67. package/dist/docx/header-footer-link.d.ts +6 -0
  68. package/dist/docx/header-footer-navigation.d.ts +6 -0
  69. package/dist/docx/header-footer-position.d.ts +3 -0
  70. package/dist/docx/header-footer-ribbon.d.ts +9 -0
  71. package/dist/docx/header-footer-view.d.ts +5 -0
  72. package/dist/docx/heading-commands.d.ts +11 -0
  73. package/dist/docx/heading-navigator.d.ts +33 -0
  74. package/dist/docx/image-media.d.ts +29 -0
  75. package/dist/docx/indent-commands.d.ts +9 -0
  76. package/dist/docx/index.d.ts +23 -0
  77. package/dist/docx/inline-commands.d.ts +4 -0
  78. package/dist/docx/insert-controller.d.ts +46 -0
  79. package/dist/docx/insert-text-commands.d.ts +8 -0
  80. package/dist/docx/keyboard.d.ts +68 -0
  81. package/dist/docx/line-number-dialog.d.ts +11 -0
  82. package/dist/docx/link-commands.d.ts +31 -0
  83. package/dist/docx/link-dialog.d.ts +15 -0
  84. package/dist/docx/list-commands.d.ts +35 -0
  85. package/dist/docx/list-marker-display.d.ts +8 -0
  86. package/dist/docx/locales/columns.d.ts +15 -0
  87. package/dist/docx/locales/de-app.d.ts +8 -0
  88. package/dist/docx/locales/de-ribbon.d.ts +8 -0
  89. package/dist/docx/locales/de.d.ts +2 -0
  90. package/dist/docx/locales/drop-cap.d.ts +10 -0
  91. package/dist/docx/locales/en-app.d.ts +247 -0
  92. package/dist/docx/locales/en-ribbon.d.ts +394 -0
  93. package/dist/docx/locales/en.d.ts +746 -0
  94. package/dist/docx/locales/es-app.d.ts +8 -0
  95. package/dist/docx/locales/es-ribbon.d.ts +8 -0
  96. package/dist/docx/locales/es.d.ts +2 -0
  97. package/dist/docx/locales/font-advanced.d.ts +14 -0
  98. package/dist/docx/locales/fr-app.d.ts +2 -0
  99. package/dist/docx/locales/fr-ribbon.d.ts +2 -0
  100. package/dist/docx/locales/fr.d.ts +2 -0
  101. package/dist/docx/locales/ligatures.d.ts +5 -0
  102. package/dist/docx/locales/line-numbers.d.ts +16 -0
  103. package/dist/docx/locales/multilevel-list.d.ts +5 -0
  104. package/dist/docx/locales/navigation.d.ts +13 -0
  105. package/dist/docx/locales/table-properties.d.ts +29 -0
  106. package/dist/docx/locales/zh-CN-app.d.ts +8 -0
  107. package/dist/docx/locales/zh-CN-ribbon.d.ts +8 -0
  108. package/dist/docx/locales/zh-CN.d.ts +2 -0
  109. package/dist/docx/localization-strings.d.ts +745 -0
  110. package/dist/docx/localization.d.ts +24 -0
  111. package/dist/docx/model-adapter.d.ts +6 -0
  112. package/dist/docx/multilevel-list-dialog.d.ts +5 -0
  113. package/dist/docx/multilingual-commands.d.ts +14 -0
  114. package/dist/docx/multilingual-ribbon.d.ts +6 -0
  115. package/dist/docx/note-commands.d.ts +17 -0
  116. package/dist/docx/note-editor.d.ts +10 -0
  117. package/dist/docx/notes-view.d.ts +3 -0
  118. package/dist/docx/page-borders-dialog.d.ts +16 -0
  119. package/dist/docx/page-break-command.d.ts +5 -0
  120. package/dist/docx/page-controller.d.ts +66 -0
  121. package/dist/docx/page-navigator.d.ts +64 -0
  122. package/dist/docx/page-setup-change.d.ts +7 -0
  123. package/dist/docx/page-setup-dialog.d.ts +12 -0
  124. package/dist/docx/page-sync.d.ts +22 -0
  125. package/dist/docx/paragraph-decoration.d.ts +29 -0
  126. package/dist/docx/paragraph-dialog.d.ts +5 -0
  127. package/dist/docx/paragraph-format.d.ts +37 -0
  128. package/dist/docx/paragraph-styles.d.ts +5 -0
  129. package/dist/docx/paragraph-toggle-sync.d.ts +8 -0
  130. package/dist/docx/parts-controller.d.ts +52 -0
  131. package/dist/docx/picture-commands.d.ts +35 -0
  132. package/dist/docx/picture-dialog.d.ts +11 -0
  133. package/dist/docx/presence-decorations.d.ts +6 -0
  134. package/dist/docx/presence.d.ts +63 -0
  135. package/dist/docx/preview-run-styles.d.ts +4 -0
  136. package/dist/docx/preview-scale-fonts.d.ts +3 -0
  137. package/dist/docx/print-fragment-hit.d.ts +7 -0
  138. package/dist/docx/print-header-footer.d.ts +28 -0
  139. package/dist/docx/print-layout-cursor.d.ts +9 -0
  140. package/dist/docx/print-layout-view.d.ts +38 -0
  141. package/dist/docx/print-layout.d.ts +32 -0
  142. package/dist/docx/print-line-numbers.d.ts +13 -0
  143. package/dist/docx/print-page-borders.d.ts +18 -0
  144. package/dist/docx/print-table.d.ts +8 -0
  145. package/dist/docx/read-aloud.d.ts +11 -0
  146. package/dist/docx/review-commands.d.ts +24 -0
  147. package/dist/docx/review-controller.d.ts +30 -0
  148. package/dist/docx/review-display.d.ts +11 -0
  149. package/dist/docx/review-ribbon.d.ts +2 -0
  150. package/dist/docx/ribbon-action.d.ts +183 -0
  151. package/dist/docx/ribbon-behavior.d.ts +7 -0
  152. package/dist/docx/ribbon-color-grid.d.ts +11 -0
  153. package/dist/docx/ribbon-combo.d.ts +23 -0
  154. package/dist/docx/ribbon-commands.d.ts +13 -0
  155. package/dist/docx/ribbon-controls.d.ts +4 -0
  156. package/dist/docx/ribbon-gallery-menu.d.ts +26 -0
  157. package/dist/docx/ribbon-home.d.ts +4 -0
  158. package/dist/docx/ribbon-icons.d.ts +126 -0
  159. package/dist/docx/ribbon-keytips.d.ts +11 -0
  160. package/dist/docx/ribbon-overflow.d.ts +3 -0
  161. package/dist/docx/ribbon-parts.d.ts +53 -0
  162. package/dist/docx/ribbon-popover.d.ts +16 -0
  163. package/dist/docx/ribbon-router.d.ts +4 -0
  164. package/dist/docx/ribbon-tab-api.d.ts +29 -0
  165. package/dist/docx/ribbon-tabs.d.ts +2 -0
  166. package/dist/docx/ribbon-visibility.d.ts +8 -0
  167. package/dist/docx/ribbon.d.ts +5 -0
  168. package/dist/docx/ruler-sync.d.ts +7 -0
  169. package/dist/docx/ruler.d.ts +36 -0
  170. package/dist/docx/run-adapter.d.ts +9 -0
  171. package/dist/docx/run-marks.d.ts +4 -0
  172. package/dist/docx/run-scale.d.ts +11 -0
  173. package/dist/docx/run-styles.d.ts +19 -0
  174. package/dist/docx/scaled-paragraph-breaks.d.ts +7 -0
  175. package/dist/docx/schema.d.ts +6 -0
  176. package/dist/docx/script-state.d.ts +4 -0
  177. package/dist/docx/search-controller.d.ts +32 -0
  178. package/dist/docx/search-panel.d.ts +14 -0
  179. package/dist/docx/section-commands.d.ts +14 -0
  180. package/dist/docx/shell-labels.d.ts +3 -0
  181. package/dist/docx/shortcut-help.d.ts +16 -0
  182. package/dist/docx/smartart-node-view.d.ts +26 -0
  183. package/dist/docx/sort-commands.d.ts +9 -0
  184. package/dist/docx/spelling.d.ts +6 -0
  185. package/dist/docx/status-bar.d.ts +23 -0
  186. package/dist/docx/style-gallery.d.ts +22 -0
  187. package/dist/docx/styles/index.d.ts +6 -0
  188. package/dist/docx/styles-group.d.ts +7 -0
  189. package/dist/docx/styles-pane.d.ts +15 -0
  190. package/dist/docx/styles-popover.d.ts +24 -0
  191. package/dist/docx/tab-stops-view.d.ts +8 -0
  192. package/dist/docx/table-border-commands.d.ts +51 -0
  193. package/dist/docx/table-cell-alignment-dialog.d.ts +8 -0
  194. package/dist/docx/table-cell-margins-dialog.d.ts +9 -0
  195. package/dist/docx/table-commands.d.ts +6 -0
  196. package/dist/docx/table-model-adapter.d.ts +15 -0
  197. package/dist/docx/table-picker.d.ts +10 -0
  198. package/dist/docx/table-properties-dialog.d.ts +3 -0
  199. package/dist/docx/table-properties.d.ts +28 -0
  200. package/dist/docx/table-shading.d.ts +6 -0
  201. package/dist/docx/test-support.d.ts +24 -0
  202. package/dist/docx/text-box-commands.d.ts +17 -0
  203. package/dist/docx/text-box-dialog.d.ts +4 -0
  204. package/dist/docx/title-bar.d.ts +25 -0
  205. package/dist/docx/toc-commands.d.ts +17 -0
  206. package/dist/docx/toggle-commands.d.ts +8 -0
  207. package/dist/docx/track-changes-mode.d.ts +20 -0
  208. package/dist/docx/view-options.d.ts +10 -0
  209. package/dist/docx/watermark-commands.d.ts +9 -0
  210. package/dist/docx/watermark-dialog.d.ts +11 -0
  211. package/dist/docx/word-count-panel.d.ts +12 -0
  212. package/dist/docx/zoom-dialog.d.ts +16 -0
  213. package/dist/docx.js +21371 -0
  214. package/dist/edit-worker.js +18 -0
  215. package/dist/index.js +4 -60
  216. package/dist/parse-worker.js +16 -0
  217. package/dist/teams/app/bind.d.ts +28 -0
  218. package/dist/teams/app/controller.d.ts +13 -0
  219. package/dist/teams/app/index.d.ts +6 -0
  220. package/dist/teams/app/storage.d.ts +11 -0
  221. package/dist/teams/app/store.d.ts +4 -0
  222. package/dist/teams/app/teams-app.d.ts +110 -0
  223. package/dist/teams/app/teams-settings.d.ts +34 -0
  224. package/dist/teams/index.d.ts +1 -0
  225. package/dist/teams.js +3 -1
  226. package/dist/visio/arrowheads.d.ts +3 -0
  227. package/dist/visio/backstage.d.ts +15 -0
  228. package/dist/visio/binding.d.ts +27 -0
  229. package/dist/visio/controller.d.ts +71 -0
  230. package/dist/visio/edit-worker.d.ts +1 -0
  231. package/dist/visio/export-svg.d.ts +25 -0
  232. package/dist/visio/index.d.ts +14 -0
  233. package/dist/visio/office-ui.d.ts +2 -0
  234. package/dist/visio/paragraph-layout.d.ts +18 -0
  235. package/dist/visio/parse-worker.d.ts +1 -0
  236. package/dist/visio/print-snapshot.d.ts +87 -0
  237. package/dist/visio/render-fill.d.ts +2 -0
  238. package/dist/visio/render-foreign-vector-shape.d.ts +4 -0
  239. package/dist/visio/render-foreign-vector.d.ts +3 -0
  240. package/dist/visio/render-image.d.ts +4 -0
  241. package/dist/visio/render-resources.d.ts +10 -0
  242. package/dist/visio/render-svg.d.ts +17 -0
  243. package/dist/visio/render-text.d.ts +4 -0
  244. package/dist/visio/ribbon-action.d.ts +41 -0
  245. package/dist/visio/ribbon-home-format.d.ts +2 -0
  246. package/dist/visio/ribbon-home.d.ts +6 -0
  247. package/dist/visio/ribbon-keytips.d.ts +2 -0
  248. package/dist/visio/ribbon-other-tabs.d.ts +12 -0
  249. package/dist/visio/ribbon-parts.d.ts +60 -0
  250. package/dist/visio/ribbon-router.d.ts +19 -0
  251. package/dist/visio/ribbon-view.d.ts +5 -0
  252. package/dist/visio/ribbon.d.ts +13 -0
  253. package/dist/visio/shape-inspector.d.ts +5 -0
  254. package/dist/visio/shapes-window.d.ts +28 -0
  255. package/dist/visio/status-bar.d.ts +10 -0
  256. package/dist/visio/styles/index.d.ts +5 -0
  257. package/dist/visio/styles.d.ts +2 -0
  258. package/dist/visio/text-layout.d.ts +45 -0
  259. package/dist/visio/viewer-backstage.d.ts +33 -0
  260. package/dist/visio/viewer-canvas.d.ts +21 -0
  261. package/dist/visio/viewer-chrome.d.ts +22 -0
  262. package/dist/visio/viewer-commands.d.ts +34 -0
  263. package/dist/visio/viewer-context-menu.d.ts +8 -0
  264. package/dist/visio/viewer-draw-tool.d.ts +33 -0
  265. package/dist/visio/viewer-edit-controls.d.ts +12 -0
  266. package/dist/visio/viewer-element.d.ts +51 -0
  267. package/dist/visio/viewer-fit.d.ts +6 -0
  268. package/dist/visio/viewer-geometry-controls.d.ts +14 -0
  269. package/dist/visio/viewer-input.d.ts +10 -0
  270. package/dist/visio/viewer-layer-controls.d.ts +5 -0
  271. package/dist/visio/viewer-layers.d.ts +22 -0
  272. package/dist/visio/viewer-options.d.ts +22 -0
  273. package/dist/visio/viewer-pan-zoom.d.ts +19 -0
  274. package/dist/visio/viewer-ruler.d.ts +13 -0
  275. package/dist/visio/viewer-search.d.ts +18 -0
  276. package/dist/visio/viewer-share.d.ts +20 -0
  277. package/dist/visio/viewer-stencil.d.ts +6 -0
  278. package/dist/visio/viewer-tell-me.d.ts +4 -0
  279. package/dist/visio/worker-editor.d.ts +23 -0
  280. package/dist/visio/worker-parser.d.ts +13 -0
  281. package/dist/visio.js +6618 -0
  282. package/dist/xlsx/backstage/index.d.ts +14 -0
  283. package/dist/xlsx/backstage/pages-file.d.ts +6 -0
  284. package/dist/xlsx/backstage/pages-info.d.ts +10 -0
  285. package/dist/xlsx/backstage/pages-options.d.ts +7 -0
  286. package/dist/xlsx/backstage/parts.d.ts +53 -0
  287. package/dist/xlsx/backstage/properties-custom.d.ts +4 -0
  288. package/dist/xlsx/clipboard.d.ts +26 -0
  289. package/dist/xlsx/commands/index.d.ts +11 -0
  290. package/dist/xlsx/commands/insert-now.d.ts +4 -0
  291. package/dist/xlsx/commands/insert.d.ts +7 -0
  292. package/dist/xlsx/commands/register-icons.d.ts +2 -0
  293. package/dist/xlsx/commands/review.d.ts +6 -0
  294. package/dist/xlsx/commands/styles.d.ts +17 -0
  295. package/dist/xlsx/commands/test-support.d.ts +25 -0
  296. package/dist/xlsx/commands/view.d.ts +7 -0
  297. package/dist/xlsx/component.d.ts +66 -0
  298. package/dist/xlsx/context-menu/index.d.ts +2 -0
  299. package/dist/xlsx/context-menu/menu.d.ts +14 -0
  300. package/dist/xlsx/dialogs/cell-shift.d.ts +5 -0
  301. package/dist/xlsx/dialogs/cf-common.d.ts +29 -0
  302. package/dist/xlsx/dialogs/cf-manager.d.ts +8 -0
  303. package/dist/xlsx/dialogs/cf-quick.d.ts +10 -0
  304. package/dist/xlsx/dialogs/cf-rule-panels.d.ts +20 -0
  305. package/dist/xlsx/dialogs/cf-rule-scale.d.ts +3 -0
  306. package/dist/xlsx/dialogs/cf-rule.d.ts +13 -0
  307. package/dist/xlsx/dialogs/comments-list.d.ts +2 -0
  308. package/dist/xlsx/dialogs/create-names.d.ts +8 -0
  309. package/dist/xlsx/dialogs/create-table.d.ts +6 -0
  310. package/dist/xlsx/dialogs/data-validation.d.ts +3 -0
  311. package/dist/xlsx/dialogs/define-name.d.ts +9 -0
  312. package/dist/xlsx/dialogs/fields.d.ts +47 -0
  313. package/dist/xlsx/dialogs/fill-series.d.ts +10 -0
  314. package/dist/xlsx/dialogs/find-replace.d.ts +8 -0
  315. package/dist/xlsx/dialogs/format-cells/alignment-tab.d.ts +5 -0
  316. package/dist/xlsx/dialogs/format-cells/border-tab.d.ts +4 -0
  317. package/dist/xlsx/dialogs/format-cells/color-swatches.d.ts +10 -0
  318. package/dist/xlsx/dialogs/format-cells/fill-tab.d.ts +11 -0
  319. package/dist/xlsx/dialogs/format-cells/font-tab.d.ts +2 -0
  320. package/dist/xlsx/dialogs/format-cells/index.d.ts +6 -0
  321. package/dist/xlsx/dialogs/format-cells/number-tab.d.ts +7 -0
  322. package/dist/xlsx/dialogs/format-cells/protection-tab.d.ts +2 -0
  323. package/dist/xlsx/dialogs/format-cells/tab-color.d.ts +6 -0
  324. package/dist/xlsx/dialogs/frame.d.ts +27 -0
  325. package/dist/xlsx/dialogs/go-to.d.ts +12 -0
  326. package/dist/xlsx/dialogs/help-dialogs.d.ts +5 -0
  327. package/dist/xlsx/dialogs/host.d.ts +6 -0
  328. package/dist/xlsx/dialogs/hyperlink.d.ts +16 -0
  329. package/dist/xlsx/dialogs/index.d.ts +2 -0
  330. package/dist/xlsx/dialogs/insert-chart.d.ts +7 -0
  331. package/dist/xlsx/dialogs/insert-function.d.ts +10 -0
  332. package/dist/xlsx/dialogs/move-copy-sheet.d.ts +5 -0
  333. package/dist/xlsx/dialogs/name-manager.d.ts +9 -0
  334. package/dist/xlsx/dialogs/package-password.d.ts +3 -0
  335. package/dist/xlsx/dialogs/page-setup-tabs.d.ts +23 -0
  336. package/dist/xlsx/dialogs/page-setup.d.ts +6 -0
  337. package/dist/xlsx/dialogs/paste-special.d.ts +3 -0
  338. package/dist/xlsx/dialogs/prompts.d.ts +42 -0
  339. package/dist/xlsx/dialogs/protect-sheet.d.ts +8 -0
  340. package/dist/xlsx/dialogs/register-navigation.d.ts +2 -0
  341. package/dist/xlsx/dialogs/register-rules.d.ts +2 -0
  342. package/dist/xlsx/dialogs/register-tools.d.ts +2 -0
  343. package/dist/xlsx/dialogs/remove-duplicates.d.ts +2 -0
  344. package/dist/xlsx/dialogs/simple.d.ts +2 -0
  345. package/dist/xlsx/dialogs/sort-dialog.d.ts +6 -0
  346. package/dist/xlsx/dialogs/statistics.d.ts +12 -0
  347. package/dist/xlsx/dialogs/styles.d.ts +1 -0
  348. package/dist/xlsx/dialogs/symbol.d.ts +6 -0
  349. package/dist/xlsx/dialogs/text-to-columns.d.ts +9 -0
  350. package/dist/xlsx/dialogs/zoom.d.ts +2 -0
  351. package/dist/xlsx/editor-attributes.d.ts +26 -0
  352. package/dist/xlsx/editor-core.d.ts +91 -0
  353. package/dist/xlsx/editor-files.d.ts +28 -0
  354. package/dist/xlsx/editor-shell.d.ts +29 -0
  355. package/dist/xlsx/element-api.d.ts +34 -0
  356. package/dist/xlsx/events.d.ts +64 -0
  357. package/dist/xlsx/file-commands.d.ts +24 -0
  358. package/dist/xlsx/formula-bar/formula-input.d.ts +11 -0
  359. package/dist/xlsx/formula-bar/index.d.ts +3 -0
  360. package/dist/xlsx/formula-bar/name-box.d.ts +10 -0
  361. package/dist/xlsx/formula-bar/styles.d.ts +1 -0
  362. package/dist/xlsx/grid/alert.d.ts +4 -0
  363. package/dist/xlsx/grid/cell-editor.d.ts +29 -0
  364. package/dist/xlsx/grid/cell-layer.d.ts +14 -0
  365. package/dist/xlsx/grid/dom.d.ts +19 -0
  366. package/dist/xlsx/grid/drawing-keys.d.ts +7 -0
  367. package/dist/xlsx/grid/drawings.d.ts +12 -0
  368. package/dist/xlsx/grid/formula-field.d.ts +11 -0
  369. package/dist/xlsx/grid/function-assist.d.ts +16 -0
  370. package/dist/xlsx/grid/grid-a11y.d.ts +12 -0
  371. package/dist/xlsx/grid/grid-commands.d.ts +19 -0
  372. package/dist/xlsx/grid/grid-keys.d.ts +19 -0
  373. package/dist/xlsx/grid/grid-menus.d.ts +8 -0
  374. package/dist/xlsx/grid/grid-pointer.d.ts +16 -0
  375. package/dist/xlsx/grid/grid-selection.d.ts +22 -0
  376. package/dist/xlsx/grid/grid-view.d.ts +75 -0
  377. package/dist/xlsx/grid/gridlines.d.ts +7 -0
  378. package/dist/xlsx/grid/header-resize.d.ts +8 -0
  379. package/dist/xlsx/grid/headers.d.ts +9 -0
  380. package/dist/xlsx/grid/index.d.ts +8 -0
  381. package/dist/xlsx/grid/indicators.d.ts +5 -0
  382. package/dist/xlsx/grid/measure.d.ts +9 -0
  383. package/dist/xlsx/grid/pane-chrome.d.ts +22 -0
  384. package/dist/xlsx/grid/point-mode.d.ts +27 -0
  385. package/dist/xlsx/grid/selection-layer.d.ts +32 -0
  386. package/dist/xlsx/grid/smartart.d.ts +10 -0
  387. package/dist/xlsx/grid/styles.d.ts +1 -0
  388. package/dist/xlsx/grid/test-context.d.ts +14 -0
  389. package/dist/xlsx/grid/validation-list.d.ts +13 -0
  390. package/dist/xlsx/index.d.ts +10 -0
  391. package/dist/xlsx/keyboard.d.ts +41 -0
  392. package/dist/xlsx/modules.d.ts +4 -0
  393. package/dist/xlsx/print.d.ts +22 -0
  394. package/dist/xlsx/ribbon/caption.d.ts +4 -0
  395. package/dist/xlsx/ribbon/color-grid.d.ts +18 -0
  396. package/dist/xlsx/ribbon/controls-input.d.ts +22 -0
  397. package/dist/xlsx/ribbon/controls.d.ts +28 -0
  398. package/dist/xlsx/ribbon/icons.d.ts +8 -0
  399. package/dist/xlsx/ribbon/keytips.d.ts +12 -0
  400. package/dist/xlsx/ribbon/overflow.d.ts +3 -0
  401. package/dist/xlsx/ribbon/popover.d.ts +30 -0
  402. package/dist/xlsx/ribbon/ribbon.d.ts +24 -0
  403. package/dist/xlsx/ribbon/tabs/contextual.d.ts +3 -0
  404. package/dist/xlsx/ribbon/tabs/formulas-data.d.ts +3 -0
  405. package/dist/xlsx/ribbon/tabs/home-groups.d.ts +6 -0
  406. package/dist/xlsx/ribbon/tabs/home.d.ts +3 -0
  407. package/dist/xlsx/ribbon/tabs/index.d.ts +2 -0
  408. package/dist/xlsx/ribbon/tabs/insert-layout.d.ts +3 -0
  409. package/dist/xlsx/ribbon/visibility.d.ts +1 -0
  410. package/dist/xlsx/sheet-tabs/drag.d.ts +12 -0
  411. package/dist/xlsx/sheet-tabs/index.d.ts +4 -0
  412. package/dist/xlsx/sheet-tabs/rename.d.ts +8 -0
  413. package/dist/xlsx/sheet-tabs/render.d.ts +15 -0
  414. package/dist/xlsx/sheet-tabs/styles.d.ts +1 -0
  415. package/dist/xlsx/shell-commands.d.ts +13 -0
  416. package/dist/xlsx/shortcut-help.d.ts +15 -0
  417. package/dist/xlsx/status-bar.d.ts +26 -0
  418. package/dist/xlsx/test-support/shell.d.ts +19 -0
  419. package/dist/xlsx/theme/index.d.ts +5 -0
  420. package/dist/xlsx/theme/styles.d.ts +7 -0
  421. package/dist/xlsx/title-bar.d.ts +17 -0
  422. package/dist/xlsx/toast.d.ts +8 -0
  423. package/dist/xlsx.js +14188 -0
  424. package/package.json +27 -2
@@ -0,0 +1,12 @@
1
+ import { type CellRange } from 'ooxml-core/xlsx';
2
+ import { type SpecialKind } from 'ooxml-core/xlsx/ui';
3
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
4
+ /** Selects a range on a sheet, switching sheets when needed. */
5
+ export declare function selectOn(ctx: EditorContext, sheet: number, range: CellRange): void;
6
+ /** Resolves `A1`, `A1:B2`, `Sheet!A1`, `'My Sheet'!$A$1` or a defined name to a sheet and range. */
7
+ export declare function resolveReference(ctx: EditorContext, input: string, depth?: number): {
8
+ sheet: number;
9
+ range: CellRange;
10
+ } | undefined;
11
+ export declare function openGoTo(ctx: EditorContext): Promise<string | undefined>;
12
+ export declare function openGoToSpecial(ctx: EditorContext): Promise<SpecialKind | undefined>;
@@ -0,0 +1,5 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export declare function openShortcutHelp(ctx: EditorContext): Promise<undefined>;
3
+ export declare const SUPPORTED_FEATURES: readonly ['Cell editing with undo and redo', 'Formulas calculated by the built-in calculation engine', 'Number formats', 'Conditional formatting display', 'Tables', 'Charts (display and basic editing)', 'Comments and notes', 'Hyperlinks', 'Data validation', 'Sort and filter', 'Freeze panes'];
4
+ export declare const UNSUPPORTED_FEATURES: readonly ['Pivot tables and sparklines (kept in the file but not shown)', 'Show Formulas', 'Manual calculation', 'Outline (grouping) for columns', 'Password protection hashes', 'Editing threaded comment replies', 'Macros (VBA is kept in the file but never run)', 'Changing the workbook theme', 'Page Layout view'];
5
+ export declare function openFeatureStatus(ctx: EditorContext): Promise<undefined>;
@@ -0,0 +1,6 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ /**
3
+ * The dialog host: the element in the shadow root dialogs append their `office-ui-dialog` to, so
4
+ * dialog code does not need to know the shell layout.
5
+ */
6
+ export declare function dialogHost(ctx: EditorContext): HTMLElement;
@@ -0,0 +1,16 @@
1
+ import { type Hyperlink } from 'ooxml-core/xlsx';
2
+ import { type HyperlinkRejection } from 'ooxml-core/opc';
3
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
4
+ /** The English message shown when the policy refuses to store an address, by reason. */
5
+ export declare const HYPERLINK_REJECTIONS: Readonly<Record<HyperlinkRejection, string>>;
6
+ /**
7
+ * The address to store (`www.` gains `https://`), or the reason it may not be stored
8
+ * (javascript:, data:, a disguised scheme, ...).
9
+ */
10
+ export declare function checkAddress(text: string): {
11
+ href: string;
12
+ } | {
13
+ reason: HyperlinkRejection;
14
+ };
15
+ export declare function safeAddress(text: string): string | undefined;
16
+ export declare function hyperlinkDialog(ctx: EditorContext): Promise<Omit<Hyperlink, 'range'> | null | undefined>;
@@ -0,0 +1,2 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export declare function registerDialogs(ctx: EditorContext): void;
@@ -0,0 +1,7 @@
1
+ import { type ChartObject, type ChartType } from 'ooxml-core/xlsx';
2
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
3
+ export interface InsertChartProps {
4
+ type?: ChartType;
5
+ change?: boolean;
6
+ }
7
+ export declare function openInsertChart(ctx: EditorContext, props?: InsertChartProps): Promise<ChartObject | undefined>;
@@ -0,0 +1,10 @@
1
+ import { type FunctionInfo } from 'ooxml-core/xlsx';
2
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
3
+ export interface InsertFunctionProps {
4
+ category?: string;
5
+ fn?: string;
6
+ }
7
+ export declare const FUNCTION_CATEGORIES: () => string[];
8
+ /** Functions matching a search (name first, then description words), like Excel's Go. */
9
+ export declare function searchFunctions(query: string): FunctionInfo[];
10
+ export declare function openInsertFunction(ctx: EditorContext, props?: InsertFunctionProps): Promise<string | undefined>;
@@ -0,0 +1,5 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export declare const END = "end";
3
+ /** The index a sheet ends up at when moved before `before` (sheet count = move to end). */
4
+ export declare function moveTarget(from: number, before: number): number;
5
+ export declare function openMoveCopySheet(ctx: EditorContext): Promise<number | undefined>;
@@ -0,0 +1,9 @@
1
+ import { type DefinedName } from 'ooxml-core/xlsx';
2
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
3
+ /** A name's current value as the Name Manager shows it (errors as `#REF!` etc.). */
4
+ export declare function nameValue(ctx: EditorContext, name: DefinedName): {
5
+ text: string;
6
+ error: boolean;
7
+ };
8
+ export declare const visibleNames: (names: readonly DefinedName[]) => DefinedName[];
9
+ export declare function openNameManager(ctx: EditorContext): Promise<undefined>;
@@ -0,0 +1,3 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ /** Passwords stay in memory for the current workbook and are never persisted in settings. */
3
+ export declare function packagePassword(ctx: EditorContext, saving?: boolean): Promise<string | undefined>;
@@ -0,0 +1,23 @@
1
+ import { type PageSetup, type Worksheet } from 'ooxml-core/xlsx';
2
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
3
+ export interface SetupTab {
4
+ panel: HTMLElement;
5
+ read(): Partial<PageSetup> | string;
6
+ }
7
+ /** Header / footer text without SpreadsheetML section codes (`&L`, `&C`, `&R`). */
8
+ export declare const plainHeader: (value: string | undefined) => string;
9
+ export declare function pageTab(ctx: EditorContext, setup: PageSetup): SetupTab;
10
+ export interface MarginsTab extends SetupTab {
11
+ /** Center on page: horizontally and vertically. */
12
+ centered(): {
13
+ horizontalCentered: boolean;
14
+ verticalCentered: boolean;
15
+ };
16
+ }
17
+ export declare function marginsTab(ctx: EditorContext, setup: PageSetup, ws: Worksheet): MarginsTab;
18
+ export declare function headerTab(ctx: EditorContext, setup: PageSetup): SetupTab;
19
+ export interface SheetTab extends SetupTab {
20
+ gridlines(): boolean;
21
+ headings(): boolean;
22
+ }
23
+ export declare function sheetTab(ctx: EditorContext, setup: PageSetup, ws: Worksheet): SheetTab;
@@ -0,0 +1,6 @@
1
+ import type { PageSetup } from 'ooxml-core/xlsx';
2
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
3
+ export interface PageSetupProps {
4
+ tab?: 'page' | 'margins' | 'header' | 'sheet';
5
+ }
6
+ export declare function openPageSetup(ctx: EditorContext, props?: PageSetupProps): Promise<Partial<PageSetup> | undefined>;
@@ -0,0 +1,3 @@
1
+ import type { PasteMode } from 'ooxml-core/xlsx';
2
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
3
+ export declare function openPasteSpecial(ctx: EditorContext): Promise<PasteMode | undefined>;
@@ -0,0 +1,42 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export interface ConfirmProps {
3
+ heading: string;
4
+ message: string;
5
+ okLabel?: string;
6
+ vars?: Record<string, string | number>;
7
+ }
8
+ /** Resolves true when confirmed. */
9
+ export declare function confirmDialog(ctx: EditorContext, props: ConfirmProps): Promise<boolean | undefined>;
10
+ export interface TextPromptProps {
11
+ name: string;
12
+ heading: string;
13
+ label: string;
14
+ value: string;
15
+ note?: string;
16
+ multiline?: boolean;
17
+ /** Returns an English error message, or undefined when the text is acceptable. */
18
+ validate?(value: string): string | undefined;
19
+ apply(value: string): void;
20
+ }
21
+ export declare function textPrompt(ctx: EditorContext, props: TextPromptProps): Promise<string | undefined>;
22
+ export interface NumberPromptProps {
23
+ name: string;
24
+ heading: string;
25
+ label: string;
26
+ value: number;
27
+ min: number;
28
+ max: number;
29
+ step?: number;
30
+ apply(value: number): void;
31
+ }
32
+ export declare function numberPrompt(ctx: EditorContext, props: NumberPromptProps): Promise<number | undefined>;
33
+ export interface PickProps {
34
+ name: string;
35
+ heading: string;
36
+ label: string;
37
+ items: ReadonlyArray<readonly [value: string, label: string]>;
38
+ okLabel?: string;
39
+ apply(value: string): void;
40
+ }
41
+ /** A list picker (Unhide sheet, Paste Name). */
42
+ export declare function pickDialog(ctx: EditorContext, props: PickProps): Promise<string | undefined>;
@@ -0,0 +1,8 @@
1
+ import { type SheetProtection } from 'ooxml-core/xlsx';
2
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
3
+ export declare const PROTECT_ACTIONS: ReadonlyArray<readonly [allow: string, label: string, on: boolean]>;
4
+ export declare function openProtectSheet(ctx: EditorContext): Promise<SheetProtection | undefined>;
5
+ /** Review > Unprotect Sheet: asks for the password when the sheet has one. */
6
+ export declare function unprotectSheet(ctx: EditorContext): Promise<boolean>;
7
+ /** Review > Protect Workbook: locks the structure with an optional password, or unlocks it. */
8
+ export declare function toggleWorkbookProtection(ctx: EditorContext): Promise<boolean>;
@@ -0,0 +1,2 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export declare function registerNavigationDialogs(ctx: EditorContext): void;
@@ -0,0 +1,2 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export declare function registerRuleDialogs(ctx: EditorContext): void;
@@ -0,0 +1,2 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export declare function registerToolDialogs(ctx: EditorContext): void;
@@ -0,0 +1,2 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export declare function openRemoveDuplicates(ctx: EditorContext): Promise<number | undefined>;
@@ -0,0 +1,2 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export declare function registerSimpleDialogs(ctx: EditorContext): void;
@@ -0,0 +1,6 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export interface SortKeySpec {
3
+ col: number;
4
+ descending: boolean;
5
+ }
6
+ export declare function sortDialog(ctx: EditorContext): Promise<SortKeySpec[] | undefined>;
@@ -0,0 +1,12 @@
1
+ import { type Worksheet } from 'ooxml-core/xlsx';
2
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
3
+ export interface SheetStats {
4
+ cells: number;
5
+ formulas: number;
6
+ tables: number;
7
+ charts: number;
8
+ images: number;
9
+ comments: number;
10
+ }
11
+ export declare function sheetStats(ws: Worksheet): SheetStats;
12
+ export declare function openStatistics(ctx: EditorContext): Promise<undefined>;
@@ -0,0 +1 @@
1
+ export declare const DIALOG_CSS = "\n.xve-cmd-dialog { --office-background: var(--xve-popover, var(--xve-background, #fff));\n\t--office-foreground: var(--xve-popover-foreground, var(--xve-foreground, #1f2937));\n\t--office-border: var(--xve-border, #d1d5db); --office-ring: var(--xve-ring, #217346); }\n.xve-dialog-body { display: flex; flex-direction: column; gap: 10px; min-width: min(360px, 86vw);\n\tfont: 13px/1.4 var(--xve-font, system-ui, \"Segoe UI\", sans-serif); color: var(--office-foreground); }\n.xve-cmd-dialog-wide .xve-dialog-body { min-width: min(560px, 90vw); }\n.xve-dialog-footer { display: flex; gap: 8px; justify-content: flex-end; flex-wrap: wrap; }\n.xve-btn { min-height: 28px; padding: 3px 14px; border-radius: var(--xve-radius, 4px); cursor: pointer;\n\tborder: 1px solid var(--xve-border, #c8c6c4); background: var(--xve-secondary, #fff); color: inherit; font: inherit; }\n.xve-btn:hover:not(:disabled) { background: var(--xve-accent, #f3f2f1); }\n.xve-btn:focus-visible, .xve-input:focus-visible, .xve-tab:focus-visible, .xve-listbox:focus-visible,\n\t.xve-swatch:focus-visible, .xve-tile:focus-visible { outline: 2px solid var(--xve-ring, #217346); outline-offset: 1px; }\n.xve-btn-primary { background: var(--xve-primary, #217346); color: var(--xve-primary-foreground, #fff);\n\tborder-color: var(--xve-primary, #217346); }\n.xve-btn-primary:hover:not(:disabled) { background: var(--xve-primary, #1b5e38); filter: brightness(.95); }\n.xve-btn:disabled { opacity: .5; cursor: default; }\n.xve-field { display: grid; grid-template-columns: minmax(110px, auto) 1fr; align-items: center; gap: 8px; }\n.xve-field-label { color: var(--xve-muted-foreground, #605e5c); }\n.xve-input { box-sizing: border-box; min-height: 28px; padding: 3px 6px; border-radius: var(--xve-radius, 4px);\n\tborder: 1px solid var(--xve-input, #c8c6c4); background: var(--xve-background, #fff); color: inherit; font: inherit; min-width: 0; }\ntextarea.xve-input { resize: vertical; }\n.xve-input[aria-invalid=\"true\"] { border-color: var(--xve-destructive, #c50f1f); }\n.xve-check { display: flex; align-items: center; gap: 6px; }\n.xve-fieldset { border: 1px solid var(--xve-border, #e1dfdd); border-radius: var(--xve-radius, 4px);\n\tpadding: 8px 10px; margin: 0; display: flex; flex-direction: column; gap: 6px; min-width: 0; }\n.xve-fieldset legend { padding: 0 4px; font-weight: 600; }\n.xve-row { display: flex; gap: 10px; align-items: flex-start; flex-wrap: wrap; }\n.xve-row > * { flex: 1 1 160px; }\n.xve-note { margin: 0; color: var(--xve-muted-foreground, #605e5c); font-size: 12px; }\n.xve-tablist { display: flex; gap: 2px; border-bottom: 1px solid var(--xve-border, #e1dfdd); flex-wrap: wrap; }\n.xve-tab { border: 0; background: transparent; color: inherit; font: inherit; padding: 6px 10px; cursor: pointer;\n\tborder-bottom: 2px solid transparent; }\n.xve-tab[aria-selected=\"true\"] { border-bottom-color: var(--xve-primary, #217346); font-weight: 600; }\n.xve-tabpanel { padding-top: 10px; display: flex; flex-direction: column; gap: 10px; }\n.xve-tabpanel[hidden] { display: none; }\n.xve-listbox { border: 1px solid var(--xve-input, #c8c6c4); border-radius: var(--xve-radius, 4px);\n\tmin-height: 120px; max-height: 220px; overflow: auto; background: var(--xve-background, #fff); }\n.xve-option { padding: 3px 8px; cursor: default; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }\n.xve-option[aria-selected=\"true\"] { background: var(--xve-selection, #cce8d6); color: inherit; }\n.xve-sample { min-height: 40px; display: flex; align-items: center; justify-content: center; padding: 6px;\n\tborder: 1px solid var(--xve-border, #e1dfdd); background: var(--xve-sheet-bg, #fff); color: #000; overflow: hidden; }\n.xve-swatches { display: grid; grid-template-columns: repeat(10, 18px); gap: 3px; }\n.xve-swatch { width: 18px; height: 18px; border: 1px solid #c8c6c4; padding: 0; cursor: pointer; border-radius: 2px; }\n.xve-swatch[aria-pressed=\"true\"] { outline: 2px solid var(--xve-primary, #217346); outline-offset: 1px; }\n.xve-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 6px; }\n.xve-tile { display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 6px; cursor: pointer;\n\tborder: 1px solid var(--xve-border, #e1dfdd); border-radius: var(--xve-radius, 4px); background: transparent; color: inherit; font: inherit; }\n.xve-tile[aria-pressed=\"true\"] { border-color: var(--xve-primary, #217346); background: var(--xve-selection, #e6f2ea); }\n.xve-symbols { display: grid; grid-template-columns: repeat(16, 28px); gap: 2px; max-height: 240px; overflow: auto; }\n.xve-symbols button { width: 28px; height: 28px; padding: 0; font-size: 16px; }\n.xve-preview { border: 1px solid var(--xve-border, #e1dfdd); background: #fff; min-height: 160px; display: flex;\n\talign-items: center; justify-content: center; }\n.xve-preview svg { max-width: 100%; height: auto; }\n.xve-results { max-height: 160px; overflow: auto; border: 1px solid var(--xve-border, #e1dfdd); }\n.xve-results table { border-collapse: collapse; width: 100%; font-size: 12px; }\n.xve-results th, .xve-results td { text-align: left; padding: 2px 6px; border-bottom: 1px solid var(--xve-border, #f3f2f1); }\n.xve-results tr[aria-selected=\"true\"] td { background: var(--xve-selection, #cce8d6); }\n.xve-border-box { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }\n.xve-border-preview { width: 120px; height: 80px; position: relative; background: #fff; border: 1px dashed #c8c6c4; }\n@media (max-width: 600px) { .xve-field { grid-template-columns: 1fr; } .xve-symbols { grid-template-columns: repeat(8, 28px); } }\n";
@@ -0,0 +1,6 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export declare const SYMBOL_SUBSETS: ReadonlyArray<readonly [id: string, label: string, chars: string[]]>;
3
+ export declare const codeOf: (ch: string) => string;
4
+ /** Inserts `symbol` into the active cell. */
5
+ export declare function insertSymbol(ctx: EditorContext, symbol: string): void;
6
+ export declare function openSymbol(ctx: EditorContext): Promise<string | undefined>;
@@ -0,0 +1,9 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export interface SplitOptions {
3
+ delimiters: string[];
4
+ consecutive: boolean;
5
+ qualifier: string;
6
+ }
7
+ /** Splits one line at any of the delimiters, honouring a text qualifier (`"a,b",c`). */
8
+ export declare function splitLine(line: string, options: SplitOptions): string[];
9
+ export declare function openTextToColumns(ctx: EditorContext): Promise<number | undefined>;
@@ -0,0 +1,2 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export declare function openZoom(ctx: EditorContext): Promise<number | undefined>;
@@ -0,0 +1,26 @@
1
+ import { type EditorThemeMode } from './theme';
2
+ /**
3
+ * Attribute <-> property mapping for `<xlsx-editor>`. Properties are the source of truth: an
4
+ * attribute change goes through the property setter only when it would change the value, and a
5
+ * property change is written back only when the attribute would differ, so the two directions
6
+ * cannot ping-pong (the docx editor's scheme).
7
+ */
8
+ export declare const XLSX_EDITOR_ATTRIBUTES: readonly ['locale', 'read-only', 'file-name', 'author-name', 'theme', 'show-toolbar', 'show-formula-bar'];
9
+ export type XlsxEditorAttribute = (typeof XLSX_EDITOR_ATTRIBUTES)[number];
10
+ export declare const DEFAULT_FILE_NAME = "Book1.xlsx";
11
+ export declare const DEFAULT_AUTHOR_NAME = "Author";
12
+ /** The element properties the attributes drive. */
13
+ export interface AttributeProperties {
14
+ locale: string;
15
+ readOnly: boolean;
16
+ fileName: string;
17
+ authorName: string;
18
+ theme: EditorThemeMode;
19
+ showToolbar: boolean;
20
+ showFormulaBar: boolean;
21
+ }
22
+ export declare function isXlsxEditorAttribute(name: string): name is XlsxEditorAttribute;
23
+ /** attributeChangedCallback body: attribute -> property. */
24
+ export declare function applyAttribute(target: AttributeProperties, name: XlsxEditorAttribute, value: string | null): void;
25
+ /** Property setter tail: property -> attribute. A no-op where the element has no DOM (SSR). */
26
+ export declare function reflectAttribute(element: Element, name: XlsxEditorAttribute, value: string | boolean): void;
@@ -0,0 +1,91 @@
1
+ /**
2
+ * The editor's state and the `EditorContext` every UI module receives: the workbook and its edit
3
+ * session, the active sheet and selection, the command and dialog registries, and the public
4
+ * event plumbing. The element (component.ts) owns one EditorCore; the shell (editor-shell.ts)
5
+ * builds the DOM around it.
6
+ */
7
+ import { type EditSession, type Workbook } from 'ooxml-core/xlsx';
8
+ import { type CommandRegistry } from 'ooxml-core/xlsx/ui';
9
+ import type { EditorContext, SelectionModel } from 'ooxml-core/xlsx/ui';
10
+ import { type DialogRegistry } from 'ooxml-core/xlsx/ui';
11
+ import { DirtyState } from 'ooxml-core/xlsx/ui';
12
+ import { type EditorLocale } from 'ooxml-core/xlsx/ui';
13
+ import type { CalculationMode } from './backstage';
14
+ import type { EditorThemeMode, XlsxTheme } from './theme';
15
+ /** What the shell exposes back to the core (filled in when the element connects). */
16
+ export interface ShellHooks {
17
+ render(): void;
18
+ toast(message: string, kind?: 'info' | 'warning' | 'error'): void;
19
+ relocalize(): void;
20
+ }
21
+ export declare class EditorCore {
22
+ readonly host: HTMLElement;
23
+ workbook: Workbook | undefined;
24
+ session: EditSession | undefined;
25
+ activeSheet: number;
26
+ readOnly: boolean;
27
+ locale: EditorLocale;
28
+ authorName: string;
29
+ fileName: string;
30
+ theme: EditorThemeMode;
31
+ showToolbar: boolean;
32
+ showFormulaBar: boolean;
33
+ themeColors: Partial<XlsxTheme>;
34
+ appliedThemeVars: string[];
35
+ hiddenActions: string[];
36
+ loadGeneration: number;
37
+ savePassword: string | undefined;
38
+ shell: ShellHooks | undefined;
39
+ readonly selection: SelectionModel;
40
+ readonly commands: CommandRegistry;
41
+ readonly dialogs: DialogRegistry;
42
+ readonly dirty: DirtyState;
43
+ readonly ctx: EditorContext;
44
+ private gridController;
45
+ private readonly modelListeners;
46
+ private stopSession;
47
+ private renderQueued;
48
+ private lastSelection;
49
+ private readonly sheetSelections;
50
+ /** The worksheet object on screen, to notice sheets inserted, moved or deleted around it. */
51
+ private shownSheet;
52
+ /** Automatic or manual calculation: the workbook's own mode (`calcPr calcMode`). */
53
+ get calculation(): CalculationMode;
54
+ constructor(host: HTMLElement);
55
+ private createContext;
56
+ /** Debounced refresh of the ribbon, title bar and status bar. */
57
+ requestRender(): void;
58
+ notifyModel(change: unknown): void;
59
+ /** Replaces the workbook (load, new, template, property), with a fresh edit session. */
60
+ setWorkbook(workbook: Workbook | undefined): void;
61
+ private createSession;
62
+ private onSessionChange;
63
+ setActiveSheet(index: number, force?: boolean): void;
64
+ /**
65
+ * After an edit that inserted, moved or deleted sheets: keep showing the same worksheet at its
66
+ * new index, or, when it was deleted, switch to the nearest visible sheet (always announcing
67
+ * `sheet-change` and restoring that sheet's selection, even when the index is unchanged).
68
+ */
69
+ private followShownSheet;
70
+ /** Text width for the core's automatic row heights, from the grid's canvas measurer. */
71
+ private measureText;
72
+ /** Iterative calculation as the workbook stores it (`calcPr iterate`); undefined when off. */
73
+ get iteration(): {
74
+ count: number;
75
+ delta: number;
76
+ } | undefined;
77
+ /**
78
+ * Turns iterative calculation on (with its maximum iterations and maximum change) or off
79
+ * (`undefined`) and recalculates, so circular references settle or are reported again. The core
80
+ * session has no undoable setter for this yet, so it is not an undo step; it marks the workbook
81
+ * as changed so it is saved.
82
+ */
83
+ setIterativeCalculation(next: {
84
+ count: number;
85
+ delta: number;
86
+ } | undefined): void;
87
+ /** Switches automatic or manual calculation on the live session (one undo step, saved). */
88
+ setCalculation(mode: CalculationMode): void;
89
+ setLocale(value: string): void;
90
+ setReadOnly(readOnly: boolean): boolean;
91
+ }
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Workbook I/O for the element: load (xlsx, xlsm, xls, csv through the core's `loadWorkbook`),
3
+ * new, save, download, and the default handlers of the File commands.
4
+ */
5
+ import { type Workbook } from 'ooxml-core/xlsx';
6
+ import { type TemplateId } from './backstage';
7
+ import type { EditorCore } from './editor-core';
8
+ import { type FileCommand } from './events';
9
+ import type { SaveState } from './title-bar';
10
+ /** Chrome callbacks the file actions report to (title bar save state, backstage). */
11
+ export interface FileChrome {
12
+ setSaveState(state: SaveState): void;
13
+ fileNameChanged(): void;
14
+ }
15
+ export declare function reportError(core: EditorCore, cause: unknown): Error;
16
+ /** Shows a new workbook model: fresh session, clean state, `workbook-change`. */
17
+ export declare function showWorkbook(core: EditorCore, workbook: Workbook, fileName: string, chrome?: FileChrome): void;
18
+ export declare function loadInto(core: EditorCore, bytes: Uint8Array | ArrayBuffer, fileName: string | undefined, chrome?: FileChrome): Promise<void>;
19
+ export declare function newInto(core: EditorCore, chrome?: FileChrome): void;
20
+ export declare function templateInto(core: EditorCore, id: TemplateId, chrome?: FileChrome): void;
21
+ export declare function saveBytes(core: EditorCore, format?: 'xlsx' | 'csv'): Promise<Uint8Array>;
22
+ export declare function saveBlob(core: EditorCore): Promise<Blob>;
23
+ export interface FileCommandOptions {
24
+ chrome?: FileChrome;
25
+ openBackstage?(page: 'saveAs'): void;
26
+ }
27
+ /** Runs a File command unless a host cancels the `file-command` event to handle it itself. */
28
+ export declare function runFileCommand(core: EditorCore, command: FileCommand, fileName: string | undefined, options?: FileCommandOptions): Promise<void>;
@@ -0,0 +1,29 @@
1
+ /**
2
+ * Builds the shadow-DOM shell once: title bar, ribbon, formula bar row, grid, sheet tabs, status
3
+ * bar, backstage, shortcut help and toasts; installs the commands and mounts the grid modules.
4
+ * Mirrors docx-viewer's editor-shell.ts.
5
+ */
6
+ import { type Backstage } from './backstage';
7
+ import type { EditorCore } from './editor-core';
8
+ import { type FileChrome } from './editor-files';
9
+ import { type FileCommand } from './events';
10
+ import { type Ribbon } from './ribbon/ribbon';
11
+ import { type SaveState, type TitleBar } from './title-bar';
12
+ /** Element properties the shell's options and customize pages change. */
13
+ export interface ShellElement extends HTMLElement {
14
+ locale: string;
15
+ theme: 'light' | 'dark' | 'auto';
16
+ authorName: string;
17
+ readOnly: boolean;
18
+ showFormulaBar: boolean;
19
+ hiddenActions: string[];
20
+ }
21
+ export interface Shell {
22
+ readonly ribbon: Ribbon;
23
+ readonly titleBar: TitleBar;
24
+ readonly backstage: Backstage;
25
+ readonly chrome: FileChrome;
26
+ saveState(): SaveState;
27
+ fileCommand(command: FileCommand, fileName?: string): Promise<void>;
28
+ }
29
+ export declare function buildShell(core: EditorCore): Shell;
@@ -0,0 +1,34 @@
1
+ /**
2
+ * The public methods of `<xlsx-editor>` (load, newWorkbook, save, saveBytes, download, markClean,
3
+ * select, getSelection, setActiveSheet, undo, redo, focusGrid). The properties and lifecycle are
4
+ * in component.ts; the state is the EditorCore.
5
+ */
6
+ import { EditorCore } from './editor-core';
7
+ import { type FileChrome } from './editor-files';
8
+ /** Server rendering has no HTMLElement; the class still has to be definable there. */
9
+ export declare const HTMLElementBase: typeof HTMLElement;
10
+ export declare class XlsxEditorApi extends HTMLElementBase {
11
+ protected readonly core: EditorCore;
12
+ /** Set by the shell once connected. */
13
+ protected chrome: FileChrome | undefined;
14
+ /** Opens .xlsx, .xlsm, .xltx, .xls or .csv bytes; `fileName` helps detection and names the file. */
15
+ load(bytes: Uint8Array | ArrayBuffer, fileName?: string): Promise<void>;
16
+ /** Starts a blank workbook named Book1.xlsx. */
17
+ newWorkbook(): void;
18
+ /** The workbook as .xlsx bytes (or the active sheet as CSV). Does not clear `dirty`. */
19
+ saveBytes(format?: 'xlsx' | 'csv'): Promise<Uint8Array>;
20
+ /** The workbook as an .xlsx Blob. Does not clear `dirty`; call `markClean()` after persisting. */
21
+ save(): Promise<Blob>;
22
+ /** Saves and downloads in the browser, then marks the workbook clean. */
23
+ download(name?: string): Promise<void>;
24
+ /** Clears the unsaved-changes flag (after the host persisted the bytes). */
25
+ markClean(): void;
26
+ /** Selects `B2`, `B2:C5`, `A:A`, `B2:C5,E1` or `'Sheet 2'!A1` and scrolls it into view. */
27
+ select(ref: string): void;
28
+ /** The selection as A1 text (`B2:C5`, several ranges joined by commas). */
29
+ getSelection(): string;
30
+ setActiveSheet(index: number): void;
31
+ undo(): void;
32
+ redo(): void;
33
+ focusGrid(): void;
34
+ }
@@ -0,0 +1,64 @@
1
+ import type { Workbook } from 'ooxml-core/xlsx';
2
+ export type FileCommand = 'new' | 'open' | 'save' | 'saveAs' | 'export' | 'exportCsv' | 'print';
3
+ export interface FileCommandDetail {
4
+ command: FileCommand;
5
+ /** Save As: the name the user chose. */
6
+ fileName?: string;
7
+ }
8
+ export interface SelectionChangeDetail {
9
+ sheet: number;
10
+ /** The selection as A1 text (`B2:C5`, or `A1:B2,D4` for several ranges). */
11
+ ref: string;
12
+ /** The active cell (`B2`). */
13
+ active: string;
14
+ }
15
+ /** Every public event of `<xlsx-editor>` and its detail. All bubble and are composed. */
16
+ export interface XlsxEditorEventMap {
17
+ /** The workbook was loaded, created or edited. */
18
+ 'workbook-change': {
19
+ workbook: Workbook;
20
+ };
21
+ /** Loading, saving, printing or a command failed. */
22
+ 'workbook-error': {
23
+ error: Error;
24
+ message: string;
25
+ };
26
+ /** Non-fatal notes from the loader (unsupported features, compatibility). */
27
+ 'workbook-warning': {
28
+ warnings: string[];
29
+ };
30
+ /** The user toggled Editing / Viewing, or the host changed `readOnly`. */
31
+ 'readonly-change': {
32
+ readOnly: boolean;
33
+ };
34
+ /** A command ran from the ribbon, a menu, Tell me or a shortcut. */
35
+ 'ribbon-action': {
36
+ id: string;
37
+ };
38
+ /** The user changed which ribbon commands are shown (File > Options > Customize Ribbon). */
39
+ 'ribbon-customize': {
40
+ hiddenActions: string[];
41
+ };
42
+ /** Cancelable: call `preventDefault()` to handle a File command yourself. */
43
+ 'file-command': FileCommandDetail;
44
+ 'selection-change': SelectionChangeDetail;
45
+ 'sheet-change': {
46
+ index: number;
47
+ name: string;
48
+ };
49
+ /** Unsaved-changes state flipped: true after an edit, false after save, load or `markClean()`. */
50
+ 'dirty-change': {
51
+ dirty: boolean;
52
+ };
53
+ }
54
+ export type XlsxEditorEventName = keyof XlsxEditorEventMap;
55
+ export type XlsxEditorEventDetail<K extends XlsxEditorEventName> = XlsxEditorEventMap[K];
56
+ /** Runtime list of every event name; the `satisfies` check keeps it a subset of the map. */
57
+ export declare const XLSX_EDITOR_EVENTS: readonly ["workbook-change", "workbook-error", "workbook-warning", "readonly-change", "ribbon-action", "ribbon-customize", "file-command", "selection-change", "sheet-change", "dirty-change"];
58
+ /**
59
+ * Dispatches a bubbling, composed CustomEvent. Returns false when a cancelable event was canceled
60
+ * (the `EventTarget.dispatchEvent` contract).
61
+ */
62
+ export declare function emitEvent(target: EventTarget, type: string, detail: unknown): boolean;
63
+ /** Typed form of `emitEvent` for the public events. */
64
+ export declare function emit<K extends XlsxEditorEventName>(target: EventTarget, type: K, detail: XlsxEditorEventDetail<K>): boolean;
@@ -0,0 +1,24 @@
1
+ /**
2
+ * File commands raised by the title bar, the File backstage and shortcuts. Each is first announced
3
+ * as a cancelable `file-command` event so hosts can take over file I/O; when no host cancels it the
4
+ * editor runs a browser-only default (file picker, download, print).
5
+ */
6
+ import { type FileCommand } from './events';
7
+ export declare const XLSX_TYPE = "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet";
8
+ /** File types the Open picker accepts. */
9
+ export declare const OPEN_ACCEPT = ".xlsx,.xlsm,.xltx,.xls,.csv,.tsv,.txt";
10
+ /** Dispatches `file-command`; false when a host canceled it. */
11
+ export declare function announceFileCommand(host: HTMLElement, command: FileCommand, fileName?: string): boolean;
12
+ export declare const extensionOf: (fileName: string) => string;
13
+ /** Replaces the extension of `fileName` (or appends one). */
14
+ export declare function withExtension(fileName: string, extension: string): string;
15
+ /** The extension a save writes: macro workbooks keep .xlsm, everything else (.xls, .csv) is .xlsx. */
16
+ export declare function saveExtension(fileName: string): 'xlsx' | 'xlsm';
17
+ export declare function blobFor(bytes: Uint8Array, fileName: string): Blob;
18
+ /** Starts a browser download of `bytes` named `fileName`. */
19
+ export declare function downloadBytes(doc: Document, bytes: Uint8Array, fileName: string): void;
20
+ /** Opens the browser file picker; resolves with the chosen file's bytes and name. */
21
+ export declare function pickFile(root: ShadowRoot | HTMLElement, accept?: string): Promise<{
22
+ bytes: Uint8Array;
23
+ name: string;
24
+ } | undefined>;
@@ -0,0 +1,11 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ import { type FormulaField } from '../grid/formula-field.js';
3
+ import { type FunctionAssist } from '../grid/function-assist.js';
4
+ export interface FormulaInput {
5
+ readonly field: FormulaField;
6
+ readonly assist: FunctionAssist;
7
+ /** Shows the active cell's content (when not editing). */
8
+ refresh(): void;
9
+ destroy(): void;
10
+ }
11
+ export declare function createFormulaInput(ctx: EditorContext, doc: Document, bar: HTMLElement): FormulaInput;
@@ -0,0 +1,3 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export { absoluteReference, nameForRange, parseSheetReference, resolveNameBox, } from 'ooxml-core/xlsx/ui';
3
+ export declare function mountFormulaBar(ctx: EditorContext, container: HTMLElement): () => void;
@@ -0,0 +1,10 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export interface NameBox {
3
+ readonly root: HTMLElement;
4
+ readonly input: HTMLInputElement;
5
+ refresh(): void;
6
+ destroy(): void;
7
+ }
8
+ /** Focus check that also works inside a shadow root. */
9
+ export declare const isFocused: (node: HTMLElement) => boolean;
10
+ export declare function createNameBox(ctx: EditorContext, doc: Document): NameBox;
@@ -0,0 +1 @@
1
+ export declare const FORMULA_BAR_CSS = "\n.xfb{position:relative;display:flex;align-items:stretch;gap:0;min-height:26px;padding:3px 6px;box-sizing:border-box;background:var(--xve-background,#fff);border-bottom:1px solid var(--xve-border,#e1dfdd);font:12px/1.4 'Segoe UI',system-ui,sans-serif;color:var(--xve-foreground,#252423)}\n.xfb-namebox{position:relative;display:flex;align-items:center;width:110px;flex:none;border:1px solid var(--xve-input,#c8c6c4);border-radius:var(--xve-radius,2px);background:var(--xve-background,#fff)}\n.xfb-name{flex:1;min-width:0;border:0;outline:0;background:transparent;color:inherit;font:inherit;padding:0 4px;height:20px}\n.xfb-namebox:focus-within{border-color:var(--xve-ring,#217346)}\n.xfb-name-toggle{border:0;background:transparent;color:inherit;width:16px;height:20px;padding:0;display:flex;align-items:center;justify-content:center;cursor:pointer}\n.xfb-name-list{position:absolute;left:-1px;top:100%;z-index:50;min-width:100%;max-height:240px;overflow:auto;margin:2px 0 0;padding:2px 0;list-style:none;background:var(--xve-popover,#fff);border:1px solid var(--xve-border,#c8c6c4);box-shadow:0 4px 12px rgba(0,0,0,.16)}\n.xfb-name-item{padding:3px 8px;cursor:default;white-space:nowrap}\n.xfb-name-item:hover{background:var(--xve-accent,#e1dfdd)}\n.xfb-name-empty{padding:3px 8px;color:var(--xve-muted-foreground,#605e5c)}\n.xfb-actions{display:flex;align-items:center;flex:none;padding:0 4px;margin-left:4px;border-left:1px solid var(--xve-border,#e1dfdd)}\n.xfb-btn{border:0;background:transparent;color:inherit;width:24px;height:22px;padding:0;display:flex;align-items:center;justify-content:center;border-radius:var(--xve-radius,2px);cursor:pointer}\n.xfb-btn:hover:not(:disabled){background:var(--xve-accent,#edebe9)}\n.xfb-btn:disabled{opacity:.45;cursor:default}\n.xfb-cancel,.xfb-enter{display:none}\n.xfb-editing .xfb-cancel,.xfb-editing .xfb-enter{display:flex}\n.xfb-fx i{font-family:Cambria,'Times New Roman',serif;font-size:13px}\n.xfb-input{flex:1;min-width:0;height:20px;border:1px solid transparent;border-radius:var(--xve-radius,2px)}\n.xfb-input:focus-within{border-color:var(--xve-input,#c8c6c4)}\n.xfb-expanded .xfb-input{height:76px}\n.xfb-expand{align-self:flex-start;flex:none;margin-left:2px}\n.xfb-expanded .xfb-expand svg{transform:rotate(180deg)}\n.xfb .xg-field{position:relative;overflow:hidden}\n.xfb .xg-field-backdrop,.xfb .xg-field-input{position:absolute;inset:0;box-sizing:border-box;margin:0;border:0;padding:1px 4px;font:13px/18px Calibri,Carlito,'Segoe UI',sans-serif;white-space:pre-wrap;word-wrap:break-word;overflow:hidden}\n.xfb .xg-field-backdrop{color:var(--xve-foreground,#252423);pointer-events:none;visibility:hidden}\n.xfb .xg-field-input{resize:none;outline:0;background:transparent;color:inherit}\n.xfb-expanded .xg-field-input{overflow:auto}\n.xfb .xg-formula .xg-field-backdrop{visibility:visible}\n.xfb .xg-formula .xg-field-input{color:transparent;caret-color:var(--xve-foreground,#252423)}\n.xfb .xg-assist{top:100%}\n";
@@ -0,0 +1,4 @@
1
+ import type { EditorContext } from 'ooxml-core/xlsx/ui';
2
+ export type AlertStyle = 'stop' | 'warning' | 'information';
3
+ export type AlertAnswer = 'retry' | 'cancel' | 'yes' | 'no' | 'ok';
4
+ export declare function showValidationAlert(ctx: EditorContext, style: AlertStyle, message: string, title?: string): Promise<AlertAnswer>;