@eigenpal/docx-editor-core 0.0.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 (419) hide show
  1. package/LICENSE +204 -0
  2. package/README.md +54 -0
  3. package/dist/ImageExtension-BN327PNe.d.mts +38 -0
  4. package/dist/ImageExtension-BlI5afZD.d.ts +38 -0
  5. package/dist/Subscribable-DOz6Ohoo.d.mts +33 -0
  6. package/dist/Subscribable-DOz6Ohoo.d.ts +33 -0
  7. package/dist/agent/index.d.mts +169 -0
  8. package/dist/agent/index.d.ts +169 -0
  9. package/dist/agent/index.js +1 -0
  10. package/dist/agent/index.mjs +1 -0
  11. package/dist/borders-BH_GoYU3.d.mts +58 -0
  12. package/dist/borders-Z9hPno2u.d.ts +58 -0
  13. package/dist/chunk-23CP3TOP.js +1 -0
  14. package/dist/chunk-2KHWHVTA.js +1 -0
  15. package/dist/chunk-36VIYQHD.mjs +9 -0
  16. package/dist/chunk-3COGZG7O.mjs +1 -0
  17. package/dist/chunk-3NRMSZX2.mjs +1 -0
  18. package/dist/chunk-3SXJPJSV.mjs +1 -0
  19. package/dist/chunk-44RUAQA2.js +1 -0
  20. package/dist/chunk-4AJYHCPB.js +2 -0
  21. package/dist/chunk-4BFNWPKW.js +1 -0
  22. package/dist/chunk-4EHBV73E.mjs +59 -0
  23. package/dist/chunk-4G6AJ4ZM.js +1 -0
  24. package/dist/chunk-4GER4JLW.js +1 -0
  25. package/dist/chunk-4Q2IP5FW.js +1 -0
  26. package/dist/chunk-5N5DBQJV.mjs +1 -0
  27. package/dist/chunk-62NPHRTF.js +1 -0
  28. package/dist/chunk-67LVRQIR.mjs +1 -0
  29. package/dist/chunk-6ILFFGGS.js +2 -0
  30. package/dist/chunk-6LOYA7G5.mjs +2 -0
  31. package/dist/chunk-6LVPRTB6.js +1 -0
  32. package/dist/chunk-6NQSIC27.mjs +1 -0
  33. package/dist/chunk-6VUYFDHY.mjs +1 -0
  34. package/dist/chunk-7E5VBRDL.mjs +1 -0
  35. package/dist/chunk-7GHQ4YCJ.mjs +1 -0
  36. package/dist/chunk-7RDCZLTU.js +1 -0
  37. package/dist/chunk-7VCMJCBY.js +2 -0
  38. package/dist/chunk-AAPBAMD7.js +1 -0
  39. package/dist/chunk-AMENZY5F.mjs +1 -0
  40. package/dist/chunk-ARHPXIBJ.mjs +1 -0
  41. package/dist/chunk-BGC7QKP5.mjs +1 -0
  42. package/dist/chunk-BGY3CB37.mjs +1 -0
  43. package/dist/chunk-BHBOAP6Z.js +3 -0
  44. package/dist/chunk-BWHUD2XC.mjs +4 -0
  45. package/dist/chunk-CCWOLPZE.js +3 -0
  46. package/dist/chunk-CGJ6S3AH.mjs +1 -0
  47. package/dist/chunk-CKKO4JWE.mjs +1 -0
  48. package/dist/chunk-CKXAHSJQ.js +10 -0
  49. package/dist/chunk-CP5OSG5Z.mjs +1 -0
  50. package/dist/chunk-CUY2THAO.mjs +1 -0
  51. package/dist/chunk-CWAP26GB.js +4 -0
  52. package/dist/chunk-D4RPOJC7.js +1 -0
  53. package/dist/chunk-D6GO7UGD.mjs +1 -0
  54. package/dist/chunk-DC7S76ZX.js +1 -0
  55. package/dist/chunk-DFZTUQ7O.js +2 -0
  56. package/dist/chunk-DROCYKAR.js +1 -0
  57. package/dist/chunk-DWFWYHM5.mjs +1 -0
  58. package/dist/chunk-DY2MJCSV.js +1 -0
  59. package/dist/chunk-ESI4BSBF.js +1 -0
  60. package/dist/chunk-FC6QL3E6.js +1 -0
  61. package/dist/chunk-FWTP7BN7.mjs +4 -0
  62. package/dist/chunk-G6Y4UZMJ.mjs +1 -0
  63. package/dist/chunk-GGPKPXON.js +1 -0
  64. package/dist/chunk-GXW7YSFL.mjs +1 -0
  65. package/dist/chunk-I6PMX4BO.js +1 -0
  66. package/dist/chunk-IBNUQL57.mjs +2 -0
  67. package/dist/chunk-ILJUDEZ5.mjs +1 -0
  68. package/dist/chunk-IP2VXNWG.js +1 -0
  69. package/dist/chunk-J7ULKGU2.mjs +10 -0
  70. package/dist/chunk-JFZIXFRC.js +1 -0
  71. package/dist/chunk-JHZ3HLSR.mjs +1 -0
  72. package/dist/chunk-JKVXID22.mjs +1 -0
  73. package/dist/chunk-JY5EFI4D.js +1 -0
  74. package/dist/chunk-KBU6QQFU.js +9 -0
  75. package/dist/chunk-KESNGXGO.js +1 -0
  76. package/dist/chunk-KQTB5Y7P.mjs +1 -0
  77. package/dist/chunk-LBKMYD3M.mjs +1 -0
  78. package/dist/chunk-LMF2ELOB.js +1 -0
  79. package/dist/chunk-LVD6HXRF.mjs +2 -0
  80. package/dist/chunk-MJ5FQX7Q.js +1 -0
  81. package/dist/chunk-MOKKS75W.mjs +3 -0
  82. package/dist/chunk-MVZOTKNL.mjs +1 -0
  83. package/dist/chunk-MZ7LW5CH.js +1 -0
  84. package/dist/chunk-MZOVDLYL.js +1 -0
  85. package/dist/chunk-N27FJQTG.js +1 -0
  86. package/dist/chunk-N3Y5BUKV.js +1 -0
  87. package/dist/chunk-NBLJPT54.mjs +1 -0
  88. package/dist/chunk-NERY274X.js +1 -0
  89. package/dist/chunk-NNQWQOC5.mjs +1 -0
  90. package/dist/chunk-NXLJVVVE.js +1 -0
  91. package/dist/chunk-O5X22KZ6.mjs +1 -0
  92. package/dist/chunk-OBMN4VSM.mjs +1 -0
  93. package/dist/chunk-OCAX2KJQ.js +4 -0
  94. package/dist/chunk-OZMNIX6U.mjs +1 -0
  95. package/dist/chunk-PRRM64JO.mjs +1 -0
  96. package/dist/chunk-Q4CKLXWA.js +1 -0
  97. package/dist/chunk-Q5QOBZWT.mjs +1 -0
  98. package/dist/chunk-QPFJJPIC.mjs +1 -0
  99. package/dist/chunk-QYUPLKLP.mjs +1 -0
  100. package/dist/chunk-RNOXNNSD.mjs +0 -0
  101. package/dist/chunk-RPIQG46O.mjs +1 -0
  102. package/dist/chunk-S7IKPRC3.js +9 -0
  103. package/dist/chunk-SUXJX72X.js +1 -0
  104. package/dist/chunk-SYJAAHUK.js +1 -0
  105. package/dist/chunk-T4CPTPRP.js +1 -0
  106. package/dist/chunk-TE2AF7FM.js +1 -0
  107. package/dist/chunk-TE2VQJZG.js +1 -0
  108. package/dist/chunk-TRJWRZZD.js +1 -0
  109. package/dist/chunk-U4UCHBZ7.js +1 -0
  110. package/dist/chunk-UDPROEUK.js +1 -0
  111. package/dist/chunk-UIROUI5I.mjs +1 -0
  112. package/dist/chunk-UOFQYE2L.mjs +1 -0
  113. package/dist/chunk-UQ6WNWXX.js +1 -0
  114. package/dist/chunk-V7BKPX67.mjs +2 -0
  115. package/dist/chunk-VKTCTMIO.mjs +2 -0
  116. package/dist/chunk-VQWZHPWI.mjs +1 -0
  117. package/dist/chunk-VW22RZ6C.mjs +1 -0
  118. package/dist/chunk-WLKRUBY4.js +1 -0
  119. package/dist/chunk-WLQEPVDR.js +1 -0
  120. package/dist/chunk-WNTT4MGC.js +59 -0
  121. package/dist/chunk-WTFLNYAT.mjs +1 -0
  122. package/dist/chunk-XXU7YQVV.js +1 -0
  123. package/dist/chunk-Y5HZAMND.mjs +9 -0
  124. package/dist/chunk-Y74ANBPV.js +1 -0
  125. package/dist/chunk-Y7JZPBBW.js +1 -0
  126. package/dist/chunk-YGHHSCPR.js +2 -0
  127. package/dist/chunk-YMZ3F2FZ.mjs +1 -0
  128. package/dist/chunk-YUKBAAB5.mjs +1 -0
  129. package/dist/chunk-ZRZ2VRQQ.mjs +1 -0
  130. package/dist/chunk-ZYESB4KC.mjs +3 -0
  131. package/dist/colorResolver-C3q7MLLD.d.mts +390 -0
  132. package/dist/colorResolver-CVsPLsw1.d.ts +390 -0
  133. package/dist/colors-C3vA7HUU.d.mts +70 -0
  134. package/dist/colors-C3vA7HUU.d.ts +70 -0
  135. package/dist/core-plugins.d.mts +64 -0
  136. package/dist/core-plugins.d.ts +64 -0
  137. package/dist/core-plugins.js +1 -0
  138. package/dist/core-plugins.mjs +1 -0
  139. package/dist/core.d.mts +399 -0
  140. package/dist/core.d.ts +399 -0
  141. package/dist/core.js +1 -0
  142. package/dist/core.mjs +1 -0
  143. package/dist/documentSerializer-C1ueey5d.d.mts +36 -0
  144. package/dist/documentSerializer-Chn7J1WG.d.ts +36 -0
  145. package/dist/docx/index.d.mts +1124 -0
  146. package/dist/docx/index.d.ts +1124 -0
  147. package/dist/docx/index.js +1 -0
  148. package/dist/docx/index.mjs +1 -0
  149. package/dist/docx/parser.d.mts +109 -0
  150. package/dist/docx/parser.d.ts +109 -0
  151. package/dist/docx/parser.js +1 -0
  152. package/dist/docx/parser.mjs +1 -0
  153. package/dist/docx/rezip.d.mts +313 -0
  154. package/dist/docx/rezip.d.ts +313 -0
  155. package/dist/docx/rezip.js +1 -0
  156. package/dist/docx/rezip.mjs +1 -0
  157. package/dist/docx/serializer/index.d.mts +126 -0
  158. package/dist/docx/serializer/index.d.ts +126 -0
  159. package/dist/docx/serializer/index.js +1 -0
  160. package/dist/docx/serializer/index.mjs +1 -0
  161. package/dist/docx/wrapTypes.d.mts +19 -0
  162. package/dist/docx/wrapTypes.d.ts +19 -0
  163. package/dist/docx/wrapTypes.js +1 -0
  164. package/dist/docx/wrapTypes.mjs +1 -0
  165. package/dist/docxInput-DTbCa48g.d.mts +21 -0
  166. package/dist/docxInput-DTbCa48g.d.ts +21 -0
  167. package/dist/executor-DZAMMQ35.js +1 -0
  168. package/dist/executor-ZCJRLT3Z.mjs +1 -0
  169. package/dist/findParagraphByParaId-Maw_8M5D.d.mts +28 -0
  170. package/dist/findParagraphByParaId-Maw_8M5D.d.ts +28 -0
  171. package/dist/fontLoader-BOt95Jtf.d.mts +223 -0
  172. package/dist/fontLoader-QPwbcX5j.d.ts +223 -0
  173. package/dist/footnotes-lCH_P3N3.d.mts +78 -0
  174. package/dist/footnotes-skVvEHvZ.d.ts +78 -0
  175. package/dist/formatting-BwpZWdGi.d.ts +410 -0
  176. package/dist/formatting-D9I-lFS4.d.mts +410 -0
  177. package/dist/headerFooterLayout-B3QVg556.d.ts +201 -0
  178. package/dist/headerFooterLayout-DkclHZ0Z.d.mts +201 -0
  179. package/dist/headless.d.mts +110 -0
  180. package/dist/headless.d.ts +110 -0
  181. package/dist/headless.js +1 -0
  182. package/dist/headless.mjs +1 -0
  183. package/dist/layout-bridge/clickToPositionDom.d.mts +56 -0
  184. package/dist/layout-bridge/clickToPositionDom.d.ts +56 -0
  185. package/dist/layout-bridge/clickToPositionDom.js +1 -0
  186. package/dist/layout-bridge/clickToPositionDom.mjs +1 -0
  187. package/dist/layout-bridge/index.d.mts +462 -0
  188. package/dist/layout-bridge/index.d.ts +462 -0
  189. package/dist/layout-bridge/index.js +1 -0
  190. package/dist/layout-bridge/index.mjs +1 -0
  191. package/dist/layout-bridge/measuring/index.d.mts +320 -0
  192. package/dist/layout-bridge/measuring/index.d.ts +320 -0
  193. package/dist/layout-bridge/measuring/index.js +1 -0
  194. package/dist/layout-bridge/measuring/index.mjs +1 -0
  195. package/dist/layout-bridge/tableInsertHover.d.mts +45 -0
  196. package/dist/layout-bridge/tableInsertHover.d.ts +45 -0
  197. package/dist/layout-bridge/tableInsertHover.js +1 -0
  198. package/dist/layout-bridge/tableInsertHover.mjs +1 -0
  199. package/dist/layout-bridge/toFlowBlocks.d.mts +122 -0
  200. package/dist/layout-bridge/toFlowBlocks.d.ts +122 -0
  201. package/dist/layout-bridge/toFlowBlocks.js +1 -0
  202. package/dist/layout-bridge/toFlowBlocks.mjs +1 -0
  203. package/dist/layout-engine/index.d.mts +322 -0
  204. package/dist/layout-engine/index.d.ts +322 -0
  205. package/dist/layout-engine/index.js +1 -0
  206. package/dist/layout-engine/index.mjs +1 -0
  207. package/dist/layout-engine/types.d.mts +903 -0
  208. package/dist/layout-engine/types.d.ts +903 -0
  209. package/dist/layout-engine/types.js +1 -0
  210. package/dist/layout-engine/types.mjs +1 -0
  211. package/dist/layout-painter/index.d.mts +23 -0
  212. package/dist/layout-painter/index.d.ts +23 -0
  213. package/dist/layout-painter/index.js +1 -0
  214. package/dist/layout-painter/index.mjs +1 -0
  215. package/dist/layout-painter/renderPage.d.mts +674 -0
  216. package/dist/layout-painter/renderPage.d.ts +674 -0
  217. package/dist/layout-painter/renderPage.js +1 -0
  218. package/dist/layout-painter/renderPage.mjs +1 -0
  219. package/dist/lists-CdiIk_c1.d.ts +142 -0
  220. package/dist/lists-JDB80qyP.d.mts +142 -0
  221. package/dist/managers/AutoSaveManager.d.mts +96 -0
  222. package/dist/managers/AutoSaveManager.d.ts +96 -0
  223. package/dist/managers/AutoSaveManager.js +1 -0
  224. package/dist/managers/AutoSaveManager.mjs +1 -0
  225. package/dist/managers/TableSelectionManager.d.mts +95 -0
  226. package/dist/managers/TableSelectionManager.d.ts +95 -0
  227. package/dist/managers/TableSelectionManager.js +1 -0
  228. package/dist/managers/TableSelectionManager.mjs +1 -0
  229. package/dist/managers/types.d.mts +122 -0
  230. package/dist/managers/types.d.ts +122 -0
  231. package/dist/managers/types.js +1 -0
  232. package/dist/managers/types.mjs +0 -0
  233. package/dist/marks-BujVxYP4.d.ts +56 -0
  234. package/dist/marks-CCPVlQzL.d.mts +56 -0
  235. package/dist/mcp-cli.mjs +137 -0
  236. package/dist/mcp.d.mts +184 -0
  237. package/dist/mcp.d.ts +184 -0
  238. package/dist/mcp.js +16 -0
  239. package/dist/mcp.mjs +16 -0
  240. package/dist/nodes-BXi1Uu3e.d.mts +257 -0
  241. package/dist/nodes-DfKj9kUA.d.ts +257 -0
  242. package/dist/plugin-api/RenderedDomContext.d.mts +74 -0
  243. package/dist/plugin-api/RenderedDomContext.d.ts +74 -0
  244. package/dist/plugin-api/RenderedDomContext.js +1 -0
  245. package/dist/plugin-api/RenderedDomContext.mjs +1 -0
  246. package/dist/plugin-api/index.d.mts +15 -0
  247. package/dist/plugin-api/index.d.ts +15 -0
  248. package/dist/plugin-api/index.js +1 -0
  249. package/dist/plugin-api/index.mjs +0 -0
  250. package/dist/plugin-api/resolveItemPositions.d.mts +54 -0
  251. package/dist/plugin-api/resolveItemPositions.d.ts +54 -0
  252. package/dist/plugin-api/resolveItemPositions.js +1 -0
  253. package/dist/plugin-api/resolveItemPositions.mjs +1 -0
  254. package/dist/plugin-api/types.d.mts +190 -0
  255. package/dist/plugin-api/types.d.ts +190 -0
  256. package/dist/plugin-api/types.js +1 -0
  257. package/dist/plugin-api/types.mjs +0 -0
  258. package/dist/processTemplate-GPFDLQMX.mjs +1 -0
  259. package/dist/processTemplate-HH2E3HBO.js +1 -0
  260. package/dist/prosemirror/commands/formatting.d.mts +100 -0
  261. package/dist/prosemirror/commands/formatting.d.ts +100 -0
  262. package/dist/prosemirror/commands/formatting.js +1 -0
  263. package/dist/prosemirror/commands/formatting.mjs +1 -0
  264. package/dist/prosemirror/commands/index.d.mts +114 -0
  265. package/dist/prosemirror/commands/index.d.ts +114 -0
  266. package/dist/prosemirror/commands/index.js +1 -0
  267. package/dist/prosemirror/commands/index.mjs +1 -0
  268. package/dist/prosemirror/commands/pageBreak.d.mts +20 -0
  269. package/dist/prosemirror/commands/pageBreak.d.ts +20 -0
  270. package/dist/prosemirror/commands/pageBreak.js +1 -0
  271. package/dist/prosemirror/commands/pageBreak.mjs +1 -0
  272. package/dist/prosemirror/commands/paragraph.d.mts +70 -0
  273. package/dist/prosemirror/commands/paragraph.d.ts +70 -0
  274. package/dist/prosemirror/commands/paragraph.js +1 -0
  275. package/dist/prosemirror/commands/paragraph.mjs +1 -0
  276. package/dist/prosemirror/conversion/fromProseDoc.d.mts +66 -0
  277. package/dist/prosemirror/conversion/fromProseDoc.d.ts +66 -0
  278. package/dist/prosemirror/conversion/fromProseDoc.js +1 -0
  279. package/dist/prosemirror/conversion/fromProseDoc.mjs +1 -0
  280. package/dist/prosemirror/conversion/index.d.mts +78 -0
  281. package/dist/prosemirror/conversion/index.d.ts +78 -0
  282. package/dist/prosemirror/conversion/index.js +1 -0
  283. package/dist/prosemirror/conversion/index.mjs +1 -0
  284. package/dist/prosemirror/editor.css +763 -0
  285. package/dist/prosemirror/extensions/index.d.mts +79 -0
  286. package/dist/prosemirror/extensions/index.d.ts +79 -0
  287. package/dist/prosemirror/extensions/index.js +1 -0
  288. package/dist/prosemirror/extensions/index.mjs +1 -0
  289. package/dist/prosemirror/extensions/nodes/TableExtension.d.mts +30 -0
  290. package/dist/prosemirror/extensions/nodes/TableExtension.d.ts +30 -0
  291. package/dist/prosemirror/extensions/nodes/TableExtension.js +1 -0
  292. package/dist/prosemirror/extensions/nodes/TableExtension.mjs +1 -0
  293. package/dist/prosemirror/index.d.mts +71 -0
  294. package/dist/prosemirror/index.d.ts +71 -0
  295. package/dist/prosemirror/index.js +1 -0
  296. package/dist/prosemirror/index.mjs +1 -0
  297. package/dist/prosemirror/plugins/index.d.mts +50 -0
  298. package/dist/prosemirror/plugins/index.d.ts +50 -0
  299. package/dist/prosemirror/plugins/index.js +1 -0
  300. package/dist/prosemirror/plugins/index.mjs +1 -0
  301. package/dist/prosemirror/plugins/selectionTracker.d.mts +78 -0
  302. package/dist/prosemirror/plugins/selectionTracker.d.ts +78 -0
  303. package/dist/prosemirror/plugins/selectionTracker.js +1 -0
  304. package/dist/prosemirror/plugins/selectionTracker.mjs +1 -0
  305. package/dist/prosemirror/schema/index.d.mts +30 -0
  306. package/dist/prosemirror/schema/index.d.ts +30 -0
  307. package/dist/prosemirror/schema/index.js +1 -0
  308. package/dist/prosemirror/schema/index.mjs +1 -0
  309. package/dist/prosemirror/styles/index.d.mts +124 -0
  310. package/dist/prosemirror/styles/index.d.ts +124 -0
  311. package/dist/prosemirror/styles/index.js +1 -0
  312. package/dist/prosemirror/styles/index.mjs +1 -0
  313. package/dist/prosemirror/template/prosemirror-plugin.d.mts +66 -0
  314. package/dist/prosemirror/template/prosemirror-plugin.d.ts +66 -0
  315. package/dist/prosemirror/template/prosemirror-plugin.js +15 -0
  316. package/dist/prosemirror/template/prosemirror-plugin.mjs +15 -0
  317. package/dist/prosemirror/utils/ClickPositionResolver.d.mts +109 -0
  318. package/dist/prosemirror/utils/ClickPositionResolver.d.ts +109 -0
  319. package/dist/prosemirror/utils/ClickPositionResolver.js +1 -0
  320. package/dist/prosemirror/utils/ClickPositionResolver.mjs +1 -0
  321. package/dist/prosemirror/utils/LayoutSelectionGate.d.mts +81 -0
  322. package/dist/prosemirror/utils/LayoutSelectionGate.d.ts +81 -0
  323. package/dist/prosemirror/utils/LayoutSelectionGate.js +1 -0
  324. package/dist/prosemirror/utils/LayoutSelectionGate.mjs +1 -0
  325. package/dist/prosemirror/utils/PointerEventHandler.d.mts +94 -0
  326. package/dist/prosemirror/utils/PointerEventHandler.d.ts +94 -0
  327. package/dist/prosemirror/utils/PointerEventHandler.js +1 -0
  328. package/dist/prosemirror/utils/PointerEventHandler.mjs +1 -0
  329. package/dist/prosemirror/utils/extractTrackedChanges.d.mts +63 -0
  330. package/dist/prosemirror/utils/extractTrackedChanges.d.ts +63 -0
  331. package/dist/prosemirror/utils/extractTrackedChanges.js +1 -0
  332. package/dist/prosemirror/utils/extractTrackedChanges.mjs +1 -0
  333. package/dist/prosemirror/utils/visualLineNavigation.d.mts +45 -0
  334. package/dist/prosemirror/utils/visualLineNavigation.d.ts +45 -0
  335. package/dist/prosemirror/utils/visualLineNavigation.js +1 -0
  336. package/dist/prosemirror/utils/visualLineNavigation.mjs +1 -0
  337. package/dist/registry-Cpyybgij.d.mts +165 -0
  338. package/dist/registry-E5pahPKL.d.ts +165 -0
  339. package/dist/selectionContext-85CE0f7a.d.ts +570 -0
  340. package/dist/selectionContext-Xq3AY7pn.d.mts +570 -0
  341. package/dist/selectiveSave-CWaPEv0B.d.ts +31 -0
  342. package/dist/selectiveSave-jinP_4xa.d.mts +31 -0
  343. package/dist/selectiveXmlPatch-ypkxlTD_.d.mts +23 -0
  344. package/dist/selectiveXmlPatch-ypkxlTD_.d.ts +23 -0
  345. package/dist/styles-BBoqh07F.d.mts +233 -0
  346. package/dist/styles-jqO45PSq.d.ts +233 -0
  347. package/dist/table-P8esKWAc.d.ts +82 -0
  348. package/dist/table-_t_W8oQf.d.mts +82 -0
  349. package/dist/types/agentApi.d.mts +467 -0
  350. package/dist/types/agentApi.d.ts +467 -0
  351. package/dist/types/agentApi.js +1 -0
  352. package/dist/types/agentApi.mjs +1 -0
  353. package/dist/types/content.d.mts +1181 -0
  354. package/dist/types/content.d.ts +1181 -0
  355. package/dist/types/content.js +1 -0
  356. package/dist/types/content.mjs +0 -0
  357. package/dist/types/document.d.mts +106 -0
  358. package/dist/types/document.d.ts +106 -0
  359. package/dist/types/document.js +1 -0
  360. package/dist/types/document.mjs +0 -0
  361. package/dist/types-DXG7vqe9.d.ts +311 -0
  362. package/dist/types-RchZmPFN.d.mts +137 -0
  363. package/dist/types-RchZmPFN.d.ts +137 -0
  364. package/dist/types-dYdjUZMo.d.mts +311 -0
  365. package/dist/utils/cardStyles.d.mts +31 -0
  366. package/dist/utils/cardStyles.d.ts +31 -0
  367. package/dist/utils/cardStyles.js +1 -0
  368. package/dist/utils/cardStyles.mjs +1 -0
  369. package/dist/utils/comments.d.mts +48 -0
  370. package/dist/utils/comments.d.ts +48 -0
  371. package/dist/utils/comments.js +1 -0
  372. package/dist/utils/comments.mjs +1 -0
  373. package/dist/utils/findReplace.d.mts +114 -0
  374. package/dist/utils/findReplace.d.ts +114 -0
  375. package/dist/utils/findReplace.js +2 -0
  376. package/dist/utils/findReplace.mjs +2 -0
  377. package/dist/utils/findVerticalScrollParent.d.mts +25 -0
  378. package/dist/utils/findVerticalScrollParent.d.ts +25 -0
  379. package/dist/utils/findVerticalScrollParent.js +1 -0
  380. package/dist/utils/findVerticalScrollParent.mjs +1 -0
  381. package/dist/utils/fontOptions.d.mts +21 -0
  382. package/dist/utils/fontOptions.d.ts +21 -0
  383. package/dist/utils/fontOptions.js +1 -0
  384. package/dist/utils/fontOptions.mjs +1 -0
  385. package/dist/utils/headingCollector.d.mts +32 -0
  386. package/dist/utils/headingCollector.d.ts +32 -0
  387. package/dist/utils/headingCollector.js +1 -0
  388. package/dist/utils/headingCollector.mjs +1 -0
  389. package/dist/utils/highlightColors.d.mts +14 -0
  390. package/dist/utils/highlightColors.d.ts +14 -0
  391. package/dist/utils/highlightColors.js +1 -0
  392. package/dist/utils/highlightColors.mjs +1 -0
  393. package/dist/utils/index.d.mts +711 -0
  394. package/dist/utils/index.d.ts +711 -0
  395. package/dist/utils/index.js +82 -0
  396. package/dist/utils/index.mjs +82 -0
  397. package/dist/utils/listState.d.mts +27 -0
  398. package/dist/utils/listState.d.ts +27 -0
  399. package/dist/utils/listState.js +1 -0
  400. package/dist/utils/listState.mjs +1 -0
  401. package/dist/utils/reportIssue.d.mts +23 -0
  402. package/dist/utils/reportIssue.d.ts +23 -0
  403. package/dist/utils/reportIssue.js +2 -0
  404. package/dist/utils/reportIssue.mjs +2 -0
  405. package/dist/utils/sidebarConstants.d.mts +10 -0
  406. package/dist/utils/sidebarConstants.d.ts +10 -0
  407. package/dist/utils/sidebarConstants.js +1 -0
  408. package/dist/utils/sidebarConstants.mjs +1 -0
  409. package/dist/utils/textSelection.d.mts +92 -0
  410. package/dist/utils/textSelection.d.ts +92 -0
  411. package/dist/utils/textSelection.js +1 -0
  412. package/dist/utils/textSelection.mjs +1 -0
  413. package/dist/utils/units.d.mts +91 -0
  414. package/dist/utils/units.d.ts +91 -0
  415. package/dist/utils/units.js +1 -0
  416. package/dist/utils/units.mjs +1 -0
  417. package/dist/variableDetector-CAdt8yOr.d.mts +115 -0
  418. package/dist/variableDetector-W4XEN9YC.d.ts +115 -0
  419. package/package.json +565 -0
@@ -0,0 +1,15 @@
1
+ /**
2
+ * Core Plugin API — Framework-Agnostic
3
+ *
4
+ * Exports the core plugin interfaces and types that can be used
5
+ * by any framework adapter (React, Vue, etc.).
6
+ *
7
+ * @experimental Plugin API is still evolving. Breaking changes may
8
+ * happen in minor releases until plugin authors stabilize the contract.
9
+ * @packageDocumentation
10
+ * @public
11
+ */
12
+ export { EditorPluginCore, PanelConfig, PluginPanelProps, PositionCoordinates, RenderedDomContext, SidebarItem, SidebarItemContext } from './types.mjs';
13
+ import 'prosemirror-state';
14
+ import 'prosemirror-view';
15
+ import 'prosemirror-model';
@@ -0,0 +1,15 @@
1
+ /**
2
+ * Core Plugin API — Framework-Agnostic
3
+ *
4
+ * Exports the core plugin interfaces and types that can be used
5
+ * by any framework adapter (React, Vue, etc.).
6
+ *
7
+ * @experimental Plugin API is still evolving. Breaking changes may
8
+ * happen in minor releases until plugin authors stabilize the contract.
9
+ * @packageDocumentation
10
+ * @public
11
+ */
12
+ export { EditorPluginCore, PanelConfig, PluginPanelProps, PositionCoordinates, RenderedDomContext, SidebarItem, SidebarItemContext } from './types.js';
13
+ import 'prosemirror-state';
14
+ import 'prosemirror-view';
15
+ import 'prosemirror-model';
@@ -0,0 +1 @@
1
+ 'use strict';
File without changes
@@ -0,0 +1,54 @@
1
+ /**
2
+ * Pure layout algorithm: given a list of sidebar items + their
3
+ * anchor sources, return a list of resolved Y positions with
4
+ * collision avoidance applied. Lifted from React's
5
+ * components/sidebar/resolveItemPositions.ts so the Vue adapter
6
+ * can call it directly.
7
+ *
8
+ * The algorithm walks the items in three priority stages:
9
+ * 1. explicit fixedY (already in scroll-container coords)
10
+ * 2. anchorKey lookup in anchorPositions (layout-engine coords)
11
+ * 3. DOM-based anchor lookup via renderedDomContext.getRectsForRange
12
+ * 4. last-known cache so cards don't pop out during transient layout
13
+ *
14
+ * Then it sorts by target Y and pushes overlapping cards down by
15
+ * their height + MIN_CARD_GAP.
16
+ * @packageDocumentation
17
+ * @public
18
+ */
19
+ import { SidebarItem, RenderedDomContext } from './types.mjs';
20
+ import 'prosemirror-state';
21
+ import 'prosemirror-view';
22
+ import 'prosemirror-model';
23
+
24
+ /**
25
+ * Pure layout algorithm: given a list of sidebar items + their
26
+ * anchor sources, return a list of resolved Y positions with
27
+ * collision avoidance applied. Lifted from React's
28
+ * components/sidebar/resolveItemPositions.ts so the Vue adapter
29
+ * can call it directly.
30
+ *
31
+ * The algorithm walks the items in three priority stages:
32
+ * 1. explicit fixedY (already in scroll-container coords)
33
+ * 2. anchorKey lookup in anchorPositions (layout-engine coords)
34
+ * 3. DOM-based anchor lookup via renderedDomContext.getRectsForRange
35
+ * 4. last-known cache so cards don't pop out during transient layout
36
+ *
37
+ * Then it sorts by target Y and pushes overlapping cards down by
38
+ * their height + MIN_CARD_GAP.
39
+ * @packageDocumentation
40
+ * @public
41
+ */
42
+
43
+ /** Generic sidebar item with optional fixedY / estimatedHeight. */
44
+ interface ResolvableSidebarItem extends SidebarItem {
45
+ fixedY?: number;
46
+ estimatedHeight?: number;
47
+ }
48
+ interface ResolvedPosition<T extends ResolvableSidebarItem = ResolvableSidebarItem> {
49
+ item: T;
50
+ y: number;
51
+ }
52
+ declare function resolveItemPositions<T extends ResolvableSidebarItem>(items: T[], anchorPositions: Map<string, number>, renderedDomContext: RenderedDomContext | null, zoom: number, cardHeights: Map<string, number>, lastKnown: Map<string, number>): ResolvedPosition<T>[];
53
+
54
+ export { type ResolvableSidebarItem, type ResolvedPosition, resolveItemPositions };
@@ -0,0 +1,54 @@
1
+ /**
2
+ * Pure layout algorithm: given a list of sidebar items + their
3
+ * anchor sources, return a list of resolved Y positions with
4
+ * collision avoidance applied. Lifted from React's
5
+ * components/sidebar/resolveItemPositions.ts so the Vue adapter
6
+ * can call it directly.
7
+ *
8
+ * The algorithm walks the items in three priority stages:
9
+ * 1. explicit fixedY (already in scroll-container coords)
10
+ * 2. anchorKey lookup in anchorPositions (layout-engine coords)
11
+ * 3. DOM-based anchor lookup via renderedDomContext.getRectsForRange
12
+ * 4. last-known cache so cards don't pop out during transient layout
13
+ *
14
+ * Then it sorts by target Y and pushes overlapping cards down by
15
+ * their height + MIN_CARD_GAP.
16
+ * @packageDocumentation
17
+ * @public
18
+ */
19
+ import { SidebarItem, RenderedDomContext } from './types.js';
20
+ import 'prosemirror-state';
21
+ import 'prosemirror-view';
22
+ import 'prosemirror-model';
23
+
24
+ /**
25
+ * Pure layout algorithm: given a list of sidebar items + their
26
+ * anchor sources, return a list of resolved Y positions with
27
+ * collision avoidance applied. Lifted from React's
28
+ * components/sidebar/resolveItemPositions.ts so the Vue adapter
29
+ * can call it directly.
30
+ *
31
+ * The algorithm walks the items in three priority stages:
32
+ * 1. explicit fixedY (already in scroll-container coords)
33
+ * 2. anchorKey lookup in anchorPositions (layout-engine coords)
34
+ * 3. DOM-based anchor lookup via renderedDomContext.getRectsForRange
35
+ * 4. last-known cache so cards don't pop out during transient layout
36
+ *
37
+ * Then it sorts by target Y and pushes overlapping cards down by
38
+ * their height + MIN_CARD_GAP.
39
+ * @packageDocumentation
40
+ * @public
41
+ */
42
+
43
+ /** Generic sidebar item with optional fixedY / estimatedHeight. */
44
+ interface ResolvableSidebarItem extends SidebarItem {
45
+ fixedY?: number;
46
+ estimatedHeight?: number;
47
+ }
48
+ interface ResolvedPosition<T extends ResolvableSidebarItem = ResolvableSidebarItem> {
49
+ item: T;
50
+ y: number;
51
+ }
52
+ declare function resolveItemPositions<T extends ResolvableSidebarItem>(items: T[], anchorPositions: Map<string, number>, renderedDomContext: RenderedDomContext | null, zoom: number, cardHeights: Map<string, number>, lastKnown: Map<string, number>): ResolvedPosition<T>[];
53
+
54
+ export { type ResolvableSidebarItem, type ResolvedPosition, resolveItemPositions };
@@ -0,0 +1 @@
1
+ 'use strict';require('../chunk-AAPBAMD7.js'),require('../chunk-DC7S76ZX.js');function g(s,u,n,r,d,l){if(s.length===0)return [];let a=n?.getContainerOffset(),o=[];for(let e of s){let t;if(e.fixedY!=null&&(t=e.fixedY*r),t==null&&e.anchorKey){let i=u.get(e.anchorKey);i!=null&&(t=i*r);}if(t==null&&n){let i=n.getRectsForRange(e.anchorPos,e.anchorPos+1);i.length>0&&a&&(t=(i[0].y+a.y)*r);}if(t==null){let i=l.get(e.id);i!=null&&(t=i);}t!=null&&(o.push({item:e,targetY:t}),l.set(e.id,t));}o.sort((e,t)=>{let i=e.targetY-t.targetY;return i!==0?i:(e.item.priority??0)-(t.item.priority??0)});let m=[],f=0;for(let e of o){let t=d.get(e.item.id)??e.item.estimatedHeight??80,i=Math.max(e.targetY,f+8);m.push({item:e.item,y:i}),f=i+t;}return m}exports.resolveItemPositions=g;
@@ -0,0 +1 @@
1
+ import'../chunk-PRRM64JO.mjs';import'../chunk-QYUPLKLP.mjs';function g(s,u,n,r,d,l){if(s.length===0)return [];let a=n?.getContainerOffset(),o=[];for(let e of s){let t;if(e.fixedY!=null&&(t=e.fixedY*r),t==null&&e.anchorKey){let i=u.get(e.anchorKey);i!=null&&(t=i*r);}if(t==null&&n){let i=n.getRectsForRange(e.anchorPos,e.anchorPos+1);i.length>0&&a&&(t=(i[0].y+a.y)*r);}if(t==null){let i=l.get(e.id);i!=null&&(t=i);}t!=null&&(o.push({item:e,targetY:t}),l.set(e.id,t));}o.sort((e,t)=>{let i=e.targetY-t.targetY;return i!==0?i:(e.item.priority??0)-(t.item.priority??0)});let m=[],f=0;for(let e of o){let t=d.get(e.item.id)??e.item.estimatedHeight??80,i=Math.max(e.targetY,f+8);m.push({item:e.item,y:i}),f=i+t;}return m}export{g as resolveItemPositions};
@@ -0,0 +1,190 @@
1
+ /**
2
+ * Framework-Agnostic Plugin Interface for the DOCX Editor
3
+ *
4
+ * Core plugin types that can be used by any framework (React, Vue, etc.).
5
+ * Framework-specific adapters extend EditorPluginCore with their own
6
+ * UI rendering capabilities (e.g., ReactEditorPlugin, VueEditorPlugin).
7
+ * @packageDocumentation
8
+ * @public
9
+ */
10
+ import { Plugin } from 'prosemirror-state';
11
+ import { EditorView } from 'prosemirror-view';
12
+ import { Node } from 'prosemirror-model';
13
+
14
+ /**
15
+ * Framework-Agnostic Plugin Interface for the DOCX Editor
16
+ *
17
+ * Core plugin types that can be used by any framework (React, Vue, etc.).
18
+ * Framework-specific adapters extend EditorPluginCore with their own
19
+ * UI rendering capabilities (e.g., ReactEditorPlugin, VueEditorPlugin).
20
+ * @packageDocumentation
21
+ * @public
22
+ */
23
+
24
+ /**
25
+ * Coordinates returned by position lookup in the rendered DOM.
26
+ */
27
+ interface PositionCoordinates {
28
+ x: number;
29
+ y: number;
30
+ height: number;
31
+ }
32
+ /**
33
+ * Context for accessing the rendered DOM in the paged editor.
34
+ *
35
+ * Provides DOM-based position mapping that works with the LayoutPainter
36
+ * output (visible pages). Use this for rendering overlays, annotations,
37
+ * and other visual elements positioned relative to rendered content.
38
+ *
39
+ * The rendered DOM uses data-pm-start/data-pm-end attributes on spans
40
+ * to map between ProseMirror positions and DOM elements.
41
+ */
42
+ interface RenderedDomContext {
43
+ /** The container element holding all rendered pages. */
44
+ pagesContainer: HTMLElement;
45
+ /**
46
+ * Get pixel coordinates for a ProseMirror position in the rendered DOM.
47
+ * Returns null if the position cannot be found.
48
+ */
49
+ getCoordinatesForPosition(pmPos: number): PositionCoordinates | null;
50
+ /**
51
+ * Find DOM elements that overlap with a ProseMirror position range.
52
+ */
53
+ findElementsForRange(from: number, to: number): Element[];
54
+ /**
55
+ * Get bounding rectangles for a range of text, accounting for line wraps.
56
+ * Returns rects relative to the pages container.
57
+ */
58
+ getRectsForRange(from: number, to: number): Array<{
59
+ x: number;
60
+ y: number;
61
+ width: number;
62
+ height: number;
63
+ }>;
64
+ /** Current zoom level (1 = 100%). */
65
+ zoom: number;
66
+ /**
67
+ * Offset of the pages container from its parent viewport.
68
+ */
69
+ getContainerOffset(): {
70
+ x: number;
71
+ y: number;
72
+ };
73
+ }
74
+ /**
75
+ * Props passed to plugin panel components (framework-agnostic base).
76
+ */
77
+ interface PluginPanelProps<TState = unknown> {
78
+ /** Current ProseMirror editor view */
79
+ editorView: EditorView | null;
80
+ /** Current ProseMirror document */
81
+ doc: Node | null;
82
+ /** Scroll editor to a specific position */
83
+ scrollToPosition: (pos: number) => void;
84
+ /** Select a range in the editor */
85
+ selectRange: (from: number, to: number) => void;
86
+ /** Plugin-specific state (managed by the plugin) */
87
+ pluginState: TState;
88
+ /** Width of the panel in pixels */
89
+ panelWidth: number;
90
+ /**
91
+ * Context for the rendered DOM (LayoutPainter output).
92
+ * May be null if layout hasn't completed yet.
93
+ */
94
+ renderedDomContext: RenderedDomContext | null;
95
+ }
96
+ /**
97
+ * Configuration for plugin panel rendering.
98
+ */
99
+ interface PanelConfig {
100
+ /** Where to render the panel */
101
+ position: 'left' | 'right' | 'bottom';
102
+ /** Default width/height of the panel */
103
+ defaultSize: number;
104
+ /** Minimum size */
105
+ minSize?: number;
106
+ /** Maximum size */
107
+ maxSize?: number;
108
+ /** Whether the panel is resizable */
109
+ resizable?: boolean;
110
+ /** Whether the panel can be collapsed */
111
+ collapsible?: boolean;
112
+ /** Initial collapsed state */
113
+ defaultCollapsed?: boolean;
114
+ }
115
+ /**
116
+ * Framework-agnostic core plugin interface.
117
+ *
118
+ * Contains all non-UI plugin capabilities:
119
+ * - ProseMirror plugins (decorations, keymaps, etc.)
120
+ * - State management (initialize, onStateChange, destroy)
121
+ * - CSS injection
122
+ * - Panel configuration
123
+ *
124
+ * Framework adapters (ReactEditorPlugin, VueEditorPlugin) extend this
125
+ * with their own Panel component type and renderOverlay function.
126
+ */
127
+ interface EditorPluginCore<TState = any> {
128
+ /** Unique plugin identifier */
129
+ id: string;
130
+ /** Display name for the plugin */
131
+ name: string;
132
+ /**
133
+ * ProseMirror plugins to register with the editor.
134
+ * These are merged with the editor's internal plugins.
135
+ */
136
+ proseMirrorPlugins?: Plugin[];
137
+ /**
138
+ * Configuration for the panel (position, size, etc.)
139
+ */
140
+ panelConfig?: PanelConfig;
141
+ /**
142
+ * Called when the editor state changes.
143
+ * Use this to update plugin-specific state based on document changes.
144
+ */
145
+ onStateChange?: (view: EditorView) => TState | undefined;
146
+ /**
147
+ * Initialize plugin state when the plugin is first loaded.
148
+ */
149
+ initialize?: (view: EditorView | null) => TState;
150
+ /**
151
+ * Called when the plugin is being destroyed.
152
+ * Use this for cleanup (subscriptions, timers, etc.)
153
+ */
154
+ destroy?: () => void;
155
+ /**
156
+ * CSS styles to inject for this plugin.
157
+ * Can be a string of CSS or a URL to a stylesheet.
158
+ */
159
+ styles?: string;
160
+ }
161
+ /**
162
+ * A sidebar item anchored to a document position.
163
+ * Framework adapters extend this with rendering capabilities.
164
+ */
165
+ interface SidebarItem {
166
+ /** Unique ID for this item (used as React key and for overlap resolution). */
167
+ id: string;
168
+ /** ProseMirror document position this item anchors to. */
169
+ anchorPos: number;
170
+ /** Optional key into the anchorPositions Map (e.g. "comment-42", "revision-7"). */
171
+ anchorKey?: string;
172
+ /** Sort priority within items at the same anchor Y. Lower = first. Default: 0. */
173
+ priority?: number;
174
+ /** Temporary items (e.g. "add comment" input) skip entrance animation. */
175
+ isTemporary?: boolean;
176
+ /** Pre-computed Y position (scroll-container coords, pre-zoom). Overrides anchor resolution. */
177
+ fixedY?: number;
178
+ }
179
+ /**
180
+ * Context provided to plugins when computing sidebar items.
181
+ */
182
+ interface SidebarItemContext {
183
+ editorView: EditorView | null;
184
+ renderedDomContext: RenderedDomContext | null;
185
+ /** Pre-computed Y positions from layout engine (keys like "comment-{id}"). */
186
+ anchorPositions: Map<string, number>;
187
+ zoom: number;
188
+ }
189
+
190
+ export type { EditorPluginCore, PanelConfig, PluginPanelProps, PositionCoordinates, RenderedDomContext, SidebarItem, SidebarItemContext };
@@ -0,0 +1,190 @@
1
+ /**
2
+ * Framework-Agnostic Plugin Interface for the DOCX Editor
3
+ *
4
+ * Core plugin types that can be used by any framework (React, Vue, etc.).
5
+ * Framework-specific adapters extend EditorPluginCore with their own
6
+ * UI rendering capabilities (e.g., ReactEditorPlugin, VueEditorPlugin).
7
+ * @packageDocumentation
8
+ * @public
9
+ */
10
+ import { Plugin } from 'prosemirror-state';
11
+ import { EditorView } from 'prosemirror-view';
12
+ import { Node } from 'prosemirror-model';
13
+
14
+ /**
15
+ * Framework-Agnostic Plugin Interface for the DOCX Editor
16
+ *
17
+ * Core plugin types that can be used by any framework (React, Vue, etc.).
18
+ * Framework-specific adapters extend EditorPluginCore with their own
19
+ * UI rendering capabilities (e.g., ReactEditorPlugin, VueEditorPlugin).
20
+ * @packageDocumentation
21
+ * @public
22
+ */
23
+
24
+ /**
25
+ * Coordinates returned by position lookup in the rendered DOM.
26
+ */
27
+ interface PositionCoordinates {
28
+ x: number;
29
+ y: number;
30
+ height: number;
31
+ }
32
+ /**
33
+ * Context for accessing the rendered DOM in the paged editor.
34
+ *
35
+ * Provides DOM-based position mapping that works with the LayoutPainter
36
+ * output (visible pages). Use this for rendering overlays, annotations,
37
+ * and other visual elements positioned relative to rendered content.
38
+ *
39
+ * The rendered DOM uses data-pm-start/data-pm-end attributes on spans
40
+ * to map between ProseMirror positions and DOM elements.
41
+ */
42
+ interface RenderedDomContext {
43
+ /** The container element holding all rendered pages. */
44
+ pagesContainer: HTMLElement;
45
+ /**
46
+ * Get pixel coordinates for a ProseMirror position in the rendered DOM.
47
+ * Returns null if the position cannot be found.
48
+ */
49
+ getCoordinatesForPosition(pmPos: number): PositionCoordinates | null;
50
+ /**
51
+ * Find DOM elements that overlap with a ProseMirror position range.
52
+ */
53
+ findElementsForRange(from: number, to: number): Element[];
54
+ /**
55
+ * Get bounding rectangles for a range of text, accounting for line wraps.
56
+ * Returns rects relative to the pages container.
57
+ */
58
+ getRectsForRange(from: number, to: number): Array<{
59
+ x: number;
60
+ y: number;
61
+ width: number;
62
+ height: number;
63
+ }>;
64
+ /** Current zoom level (1 = 100%). */
65
+ zoom: number;
66
+ /**
67
+ * Offset of the pages container from its parent viewport.
68
+ */
69
+ getContainerOffset(): {
70
+ x: number;
71
+ y: number;
72
+ };
73
+ }
74
+ /**
75
+ * Props passed to plugin panel components (framework-agnostic base).
76
+ */
77
+ interface PluginPanelProps<TState = unknown> {
78
+ /** Current ProseMirror editor view */
79
+ editorView: EditorView | null;
80
+ /** Current ProseMirror document */
81
+ doc: Node | null;
82
+ /** Scroll editor to a specific position */
83
+ scrollToPosition: (pos: number) => void;
84
+ /** Select a range in the editor */
85
+ selectRange: (from: number, to: number) => void;
86
+ /** Plugin-specific state (managed by the plugin) */
87
+ pluginState: TState;
88
+ /** Width of the panel in pixels */
89
+ panelWidth: number;
90
+ /**
91
+ * Context for the rendered DOM (LayoutPainter output).
92
+ * May be null if layout hasn't completed yet.
93
+ */
94
+ renderedDomContext: RenderedDomContext | null;
95
+ }
96
+ /**
97
+ * Configuration for plugin panel rendering.
98
+ */
99
+ interface PanelConfig {
100
+ /** Where to render the panel */
101
+ position: 'left' | 'right' | 'bottom';
102
+ /** Default width/height of the panel */
103
+ defaultSize: number;
104
+ /** Minimum size */
105
+ minSize?: number;
106
+ /** Maximum size */
107
+ maxSize?: number;
108
+ /** Whether the panel is resizable */
109
+ resizable?: boolean;
110
+ /** Whether the panel can be collapsed */
111
+ collapsible?: boolean;
112
+ /** Initial collapsed state */
113
+ defaultCollapsed?: boolean;
114
+ }
115
+ /**
116
+ * Framework-agnostic core plugin interface.
117
+ *
118
+ * Contains all non-UI plugin capabilities:
119
+ * - ProseMirror plugins (decorations, keymaps, etc.)
120
+ * - State management (initialize, onStateChange, destroy)
121
+ * - CSS injection
122
+ * - Panel configuration
123
+ *
124
+ * Framework adapters (ReactEditorPlugin, VueEditorPlugin) extend this
125
+ * with their own Panel component type and renderOverlay function.
126
+ */
127
+ interface EditorPluginCore<TState = any> {
128
+ /** Unique plugin identifier */
129
+ id: string;
130
+ /** Display name for the plugin */
131
+ name: string;
132
+ /**
133
+ * ProseMirror plugins to register with the editor.
134
+ * These are merged with the editor's internal plugins.
135
+ */
136
+ proseMirrorPlugins?: Plugin[];
137
+ /**
138
+ * Configuration for the panel (position, size, etc.)
139
+ */
140
+ panelConfig?: PanelConfig;
141
+ /**
142
+ * Called when the editor state changes.
143
+ * Use this to update plugin-specific state based on document changes.
144
+ */
145
+ onStateChange?: (view: EditorView) => TState | undefined;
146
+ /**
147
+ * Initialize plugin state when the plugin is first loaded.
148
+ */
149
+ initialize?: (view: EditorView | null) => TState;
150
+ /**
151
+ * Called when the plugin is being destroyed.
152
+ * Use this for cleanup (subscriptions, timers, etc.)
153
+ */
154
+ destroy?: () => void;
155
+ /**
156
+ * CSS styles to inject for this plugin.
157
+ * Can be a string of CSS or a URL to a stylesheet.
158
+ */
159
+ styles?: string;
160
+ }
161
+ /**
162
+ * A sidebar item anchored to a document position.
163
+ * Framework adapters extend this with rendering capabilities.
164
+ */
165
+ interface SidebarItem {
166
+ /** Unique ID for this item (used as React key and for overlap resolution). */
167
+ id: string;
168
+ /** ProseMirror document position this item anchors to. */
169
+ anchorPos: number;
170
+ /** Optional key into the anchorPositions Map (e.g. "comment-42", "revision-7"). */
171
+ anchorKey?: string;
172
+ /** Sort priority within items at the same anchor Y. Lower = first. Default: 0. */
173
+ priority?: number;
174
+ /** Temporary items (e.g. "add comment" input) skip entrance animation. */
175
+ isTemporary?: boolean;
176
+ /** Pre-computed Y position (scroll-container coords, pre-zoom). Overrides anchor resolution. */
177
+ fixedY?: number;
178
+ }
179
+ /**
180
+ * Context provided to plugins when computing sidebar items.
181
+ */
182
+ interface SidebarItemContext {
183
+ editorView: EditorView | null;
184
+ renderedDomContext: RenderedDomContext | null;
185
+ /** Pre-computed Y positions from layout engine (keys like "comment-{id}"). */
186
+ anchorPositions: Map<string, number>;
187
+ zoom: number;
188
+ }
189
+
190
+ export type { EditorPluginCore, PanelConfig, PluginPanelProps, PositionCoordinates, RenderedDomContext, SidebarItem, SidebarItemContext };
@@ -0,0 +1 @@
1
+ 'use strict';
File without changes
@@ -0,0 +1 @@
1
+ export{j as createTemplateProcessor,k as default,g as getMissingVariables,e as getTemplateTags,h as previewTemplate,a as processTemplate,i as processTemplateAdvanced,d as processTemplateAndDownload,c as processTemplateAsBlob,b as processTemplateDetailed,f as validateTemplate}from'./chunk-CGJ6S3AH.mjs';import'./chunk-QYUPLKLP.mjs';
@@ -0,0 +1 @@
1
+ 'use strict';Object.defineProperty(exports,'__esModule',{value:true});var chunkESI4BSBF_js=require('./chunk-ESI4BSBF.js');require('./chunk-DC7S76ZX.js');Object.defineProperty(exports,"createTemplateProcessor",{enumerable:true,get:function(){return chunkESI4BSBF_js.j}});Object.defineProperty(exports,"default",{enumerable:true,get:function(){return chunkESI4BSBF_js.k}});Object.defineProperty(exports,"getMissingVariables",{enumerable:true,get:function(){return chunkESI4BSBF_js.g}});Object.defineProperty(exports,"getTemplateTags",{enumerable:true,get:function(){return chunkESI4BSBF_js.e}});Object.defineProperty(exports,"previewTemplate",{enumerable:true,get:function(){return chunkESI4BSBF_js.h}});Object.defineProperty(exports,"processTemplate",{enumerable:true,get:function(){return chunkESI4BSBF_js.a}});Object.defineProperty(exports,"processTemplateAdvanced",{enumerable:true,get:function(){return chunkESI4BSBF_js.i}});Object.defineProperty(exports,"processTemplateAndDownload",{enumerable:true,get:function(){return chunkESI4BSBF_js.d}});Object.defineProperty(exports,"processTemplateAsBlob",{enumerable:true,get:function(){return chunkESI4BSBF_js.c}});Object.defineProperty(exports,"processTemplateDetailed",{enumerable:true,get:function(){return chunkESI4BSBF_js.b}});Object.defineProperty(exports,"validateTemplate",{enumerable:true,get:function(){return chunkESI4BSBF_js.f}});
@@ -0,0 +1,100 @@
1
+ /**
2
+ * Text Formatting Commands — thin re-exports from extension system
3
+ *
4
+ * Toggle marks, set marks, clear formatting, hyperlinks.
5
+ * All implementations live in extensions/marks/; this file re-exports
6
+ * for backward compatibility.
7
+ * @packageDocumentation
8
+ * @public
9
+ */
10
+ import { Command, EditorState } from 'prosemirror-state';
11
+ import { MarkType, Mark } from 'prosemirror-model';
12
+ import { T as TextFormatting } from '../../formatting-D9I-lFS4.mjs';
13
+ import { T as TextColorAttrs } from '../../marks-CCPVlQzL.mjs';
14
+ import '../../colors-C3vA7HUU.mjs';
15
+
16
+ /**
17
+ * Shared mark utility functions
18
+ *
19
+ * setMark, removeMark, isMarkActive, getMarkAttr, marksToTextFormatting, textFormattingToMarks, clearFormatting
20
+ */
21
+
22
+ /**
23
+ * Check if a mark is active in the current selection
24
+ */
25
+ declare function isMarkActive(state: EditorState, markType: MarkType, attrs?: Record<string, unknown>): boolean;
26
+ /**
27
+ * Get the current value of a mark attribute
28
+ */
29
+ declare function getMarkAttr(state: EditorState, markType: MarkType, attr: string): unknown | null;
30
+ /**
31
+ * Clear all text formatting (remove all marks)
32
+ */
33
+ declare const clearFormatting: Command;
34
+ /**
35
+ * Create a command that sets a mark on the selection
36
+ */
37
+ declare function createSetMarkCommand(markType: MarkType, attrs?: Record<string, unknown>): Command;
38
+ /**
39
+ * Create a command that removes a mark from the selection
40
+ */
41
+ declare function createRemoveMarkCommand(markType: MarkType): Command;
42
+
43
+ declare function isHyperlinkActive(state: EditorState): boolean;
44
+ declare function getHyperlinkAttrs(state: EditorState): {
45
+ href: string;
46
+ tooltip?: string;
47
+ } | null;
48
+ declare function getSelectedText(state: EditorState): string;
49
+ /**
50
+ * Resolve the hyperlink mark + contiguous range that surrounds the
51
+ * current cursor. Used by edit/remove popup actions in both adapters.
52
+ *
53
+ * Resolution order for the mark itself:
54
+ * 1. `$from.marks()` — the normal active-marks lookup
55
+ * 2. `$from.nodeAfter`/`nodeBefore` marks — boundary positions don't
56
+ * report active marks via `marks()`
57
+ * 3. (optional) text-node search by `fallbackHref` — last resort when
58
+ * the popup knows the href but the cursor sits at a gap
59
+ *
60
+ * The returned range walks the parent block grouping consecutive text
61
+ * nodes that share the same href, and returns whichever range contains
62
+ * the cursor.
63
+ */
64
+ declare function findHyperlinkRangeAt(state: EditorState, fallbackHref?: string): {
65
+ mark: Mark;
66
+ start: number;
67
+ end: number;
68
+ } | null;
69
+
70
+ /**
71
+ * Text Formatting Commands — thin re-exports from extension system
72
+ *
73
+ * Toggle marks, set marks, clear formatting, hyperlinks.
74
+ * All implementations live in extensions/marks/; this file re-exports
75
+ * for backward compatibility.
76
+ * @packageDocumentation
77
+ * @public
78
+ */
79
+
80
+ declare function textFormattingToMarks(formatting: TextFormatting): Mark[];
81
+ declare const toggleBold: Command;
82
+ declare const toggleItalic: Command;
83
+ declare const toggleUnderline: Command;
84
+ declare const toggleStrike: Command;
85
+ declare const toggleSuperscript: Command;
86
+ declare const toggleSubscript: Command;
87
+ declare function setTextColor(attrs: TextColorAttrs): Command;
88
+ declare const clearTextColor: Command;
89
+ declare function setHighlight(color: string): Command;
90
+ declare const clearHighlight: Command;
91
+ declare function setFontSize(size: number): Command;
92
+ declare const clearFontSize: Command;
93
+ declare function setFontFamily(fontName: string): Command;
94
+ declare const clearFontFamily: Command;
95
+ declare function setUnderlineStyle(style: string, color?: TextColorAttrs): Command;
96
+ declare function setHyperlink(href: string, tooltip?: string): Command;
97
+ declare const removeHyperlink: Command;
98
+ declare function insertHyperlink(text: string, href: string, tooltip?: string): Command;
99
+
100
+ export { clearFontFamily, clearFontSize, clearFormatting, clearHighlight, clearTextColor, createRemoveMarkCommand, createSetMarkCommand, findHyperlinkRangeAt, getHyperlinkAttrs, getMarkAttr, getSelectedText, insertHyperlink, isHyperlinkActive, isMarkActive, removeHyperlink, setFontFamily, setFontSize, setHighlight, setHyperlink, setTextColor, setUnderlineStyle, textFormattingToMarks, toggleBold, toggleItalic, toggleStrike, toggleSubscript, toggleSuperscript, toggleUnderline };