@ctzhian/tiptap 2.13.7 → 3.0.1

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 (968) hide show
  1. package/dist/app/editor/Editor/demo.d.ts +4 -0
  2. package/dist/app/editor/Editor/demo.js +222 -0
  3. package/dist/app/editor/Editor/index.d.ts +5 -0
  4. package/dist/app/editor/Editor/index.js +47 -0
  5. package/dist/app/editor/EditorDiff/demo.d.ts +4 -0
  6. package/dist/app/editor/EditorDiff/demo.js +13 -0
  7. package/dist/app/editor/EditorDiff/index.js +34 -0
  8. package/dist/app/editor/EditorMarkdown/demo.d.ts +4 -0
  9. package/dist/app/editor/EditorMarkdown/demo.js +169 -0
  10. package/dist/app/editor/EditorMarkdown/index.d.ts +1 -0
  11. package/dist/app/editor/EditorMarkdown/index.js +1 -0
  12. package/dist/app/editor/EditorThemeProvider/index.d.ts +11 -0
  13. package/dist/app/editor/EditorThemeProvider/index.js +90 -0
  14. package/dist/components/ActionDropdown/index.d.ts +30 -0
  15. package/dist/components/ActionDropdown/index.js +138 -0
  16. package/dist/components/CustomBubbleMenu/index.d.ts +9 -0
  17. package/dist/components/CustomBubbleMenu/index.js +165 -0
  18. package/dist/components/FloatingPopover/index.js +66 -0
  19. package/dist/components/HoverPopover/index.js +56 -0
  20. package/dist/components/Menu/NestedList.d.ts +16 -0
  21. package/dist/components/Menu/NestedList.js +141 -0
  22. package/dist/components/Menu/index.d.ts +7 -0
  23. package/dist/components/Menu/index.js +100 -0
  24. package/dist/components/Toolbar/CommandSelect.d.ts +20 -0
  25. package/dist/components/Toolbar/CommandSelect.js +129 -0
  26. package/dist/components/Toolbar/EditorAlignSelect.js +76 -0
  27. package/dist/components/Toolbar/EditorCode.js +50 -0
  28. package/dist/components/Toolbar/EditorHeading.js +173 -0
  29. package/dist/components/Toolbar/EditorInsert/index.js +40 -0
  30. package/dist/components/Toolbar/EditorInsert/menu-builders.d.ts +3 -0
  31. package/dist/components/Toolbar/EditorInsert/menu-builders.js +407 -0
  32. package/dist/components/Toolbar/EditorListSelect.js +62 -0
  33. package/dist/components/Toolbar/EditorMath.js +54 -0
  34. package/dist/components/Toolbar/EditorMore/NotificationDialog.js +73 -0
  35. package/dist/components/Toolbar/EditorMore/index.d.ts +7 -0
  36. package/dist/components/Toolbar/EditorMore/index.js +104 -0
  37. package/dist/components/Toolbar/EditorMore/menu-builders.d.ts +5 -0
  38. package/dist/components/Toolbar/EditorMore/menu-builders.js +13 -0
  39. package/dist/components/Toolbar/EditorScript.js +50 -0
  40. package/dist/components/Toolbar/EditorVerticalAlignSelect.js +64 -0
  41. package/dist/components/Toolbar/Item.js +74 -0
  42. package/dist/components/Toolbar/TableSizePicker.js +80 -0
  43. package/dist/components/Toolbar/index.d.ts +14 -0
  44. package/dist/components/Toolbar/index.js +14 -0
  45. package/dist/components/shared/menu-item-content.d.ts +7 -0
  46. package/dist/components/shared/menu-item-content.js +23 -0
  47. package/dist/components/shared/menu-surface.d.ts +13 -0
  48. package/dist/components/shared/menu-surface.js +35 -0
  49. package/dist/components/shared/use-floating-popover.d.ts +16 -0
  50. package/dist/components/shared/use-floating-popover.js +79 -0
  51. package/dist/components/shared/use-hover-popover.d.ts +15 -0
  52. package/dist/components/shared/use-hover-popover.js +96 -0
  53. package/dist/components/shared/use-popover-anchor.d.ts +8 -0
  54. package/dist/components/shared/use-popover-anchor.js +26 -0
  55. package/dist/constants/enums.d.ts +49 -0
  56. package/dist/constants/enums.js +213 -0
  57. package/dist/constants/slash-commands.js +397 -0
  58. package/dist/editor-core/extensions/builders.d.ts +13 -0
  59. package/dist/editor-core/extensions/builders.js +225 -0
  60. package/dist/editor-core/extensions/catalog.d.ts +22 -0
  61. package/dist/editor-core/extensions/catalog.js +326 -0
  62. package/dist/editor-core/extensions/component/Alert/index.js +239 -0
  63. package/dist/editor-core/extensions/component/Attachment/AttachmentContent.js +420 -0
  64. package/dist/editor-core/extensions/component/Attachment/Insert.d.ts +13 -0
  65. package/dist/editor-core/extensions/component/Attachment/Insert.js +213 -0
  66. package/dist/editor-core/extensions/component/Attachment/index.d.ts +15 -0
  67. package/dist/editor-core/extensions/component/Attachment/index.js +302 -0
  68. package/dist/editor-core/extensions/component/Audio/AudioPlayer.d.ts +8 -0
  69. package/dist/editor-core/extensions/component/Audio/AudioPlayer.js +391 -0
  70. package/dist/editor-core/extensions/component/Audio/Insert.d.ts +10 -0
  71. package/dist/editor-core/extensions/component/Audio/Insert.js +224 -0
  72. package/dist/editor-core/extensions/component/Audio/index.d.ts +5 -0
  73. package/dist/editor-core/extensions/component/Audio/index.js +309 -0
  74. package/dist/editor-core/extensions/component/Audio/shared.d.ts +12 -0
  75. package/dist/editor-core/extensions/component/Audio/shared.js +48 -0
  76. package/dist/editor-core/extensions/component/Audio/use-audio-upload-fields.d.ts +21 -0
  77. package/dist/editor-core/extensions/component/Audio/use-audio-upload-fields.js +48 -0
  78. package/dist/editor-core/extensions/component/CodeBlock/Readonly.js +124 -0
  79. package/dist/editor-core/extensions/component/CodeBlock/index.js +330 -0
  80. package/dist/editor-core/extensions/component/CodeBlock/shared.d.ts +15 -0
  81. package/dist/editor-core/extensions/component/CodeBlock/shared.js +70 -0
  82. package/dist/editor-core/extensions/component/DrawPanel/index.d.ts +5 -0
  83. package/dist/editor-core/extensions/component/DrawPanel/index.js +168 -0
  84. package/dist/editor-core/extensions/component/FlipGrid/ColumnView.js +191 -0
  85. package/dist/editor-core/extensions/component/Flow/Edit.js +69 -0
  86. package/dist/editor-core/extensions/component/Flow/Insert.js +108 -0
  87. package/dist/editor-core/extensions/component/Flow/index.d.ts +10 -0
  88. package/dist/editor-core/extensions/component/Flow/index.js +416 -0
  89. package/dist/editor-core/extensions/component/Link/Insert.d.ts +10 -0
  90. package/dist/editor-core/extensions/component/Link/Insert.js +162 -0
  91. package/dist/editor-core/extensions/component/Link/LinkContent.d.ts +13 -0
  92. package/dist/editor-core/extensions/component/Link/LinkContent.js +168 -0
  93. package/dist/editor-core/extensions/component/Link/Markdown.js +66 -0
  94. package/dist/editor-core/extensions/component/Link/index.d.ts +4 -0
  95. package/dist/editor-core/extensions/component/Link/index.js +381 -0
  96. package/dist/editor-core/extensions/component/Link/shared.d.ts +26 -0
  97. package/dist/editor-core/extensions/component/Link/shared.js +74 -0
  98. package/dist/editor-core/extensions/component/Mathematics/block/Readonly.d.ts +9 -0
  99. package/dist/editor-core/extensions/component/Mathematics/block/index.d.ts +7 -0
  100. package/dist/editor-core/extensions/component/Mathematics/block/index.js +128 -0
  101. package/dist/editor-core/extensions/component/Mathematics/inline/Readonly.d.ts +9 -0
  102. package/dist/editor-core/extensions/component/Mathematics/inline/index.d.ts +7 -0
  103. package/dist/editor-core/extensions/component/Mathematics/inline/index.js +124 -0
  104. package/dist/editor-core/extensions/component/Mathematics/shared.d.ts +18 -0
  105. package/dist/editor-core/extensions/component/Mathematics/shared.js +64 -0
  106. package/dist/editor-core/extensions/component/SlashCommandsList/Overlay.d.ts +10 -0
  107. package/dist/editor-core/extensions/component/SlashCommandsList/Overlay.js +26 -0
  108. package/dist/editor-core/extensions/component/SlashCommandsList/index.d.ts +4 -0
  109. package/dist/editor-core/extensions/component/SlashCommandsList/index.js +330 -0
  110. package/dist/editor-core/extensions/component/Tooltip/EditPopover.js +152 -0
  111. package/dist/editor-core/extensions/component/Tooltip/index.js +148 -0
  112. package/dist/editor-core/extensions/component/UploadProgress/Inline.d.ts +11 -0
  113. package/dist/editor-core/extensions/component/UploadProgress/Inline.js +28 -0
  114. package/dist/editor-core/extensions/component/UploadProgress/file-meta.d.ts +4 -0
  115. package/dist/editor-core/extensions/component/UploadProgress/file-meta.js +42 -0
  116. package/dist/editor-core/extensions/component/UploadProgress/index.d.ts +11 -0
  117. package/dist/editor-core/extensions/component/UploadProgress/index.js +19 -0
  118. package/dist/editor-core/extensions/component/UploadProgress/shared.d.ts +10 -0
  119. package/dist/editor-core/extensions/component/UploadProgress/shared.js +69 -0
  120. package/dist/editor-core/extensions/component/shared/edit-popover.d.ts +27 -0
  121. package/dist/editor-core/extensions/component/shared/edit-popover.js +82 -0
  122. package/dist/editor-core/extensions/component/shared/insert-popover.d.ts +34 -0
  123. package/dist/editor-core/extensions/component/shared/insert-popover.js +160 -0
  124. package/dist/editor-core/extensions/component/shared/resource-form.d.ts +26 -0
  125. package/dist/editor-core/extensions/component/shared/resource-form.js +78 -0
  126. package/dist/editor-core/extensions/component/shared/upload-flow.d.ts +25 -0
  127. package/dist/editor-core/extensions/component/shared/upload-flow.js +143 -0
  128. package/dist/editor-core/extensions/extension/ImeComposition.d.ts +12 -0
  129. package/dist/editor-core/extensions/extension/ImeComposition.js +132 -0
  130. package/dist/editor-core/extensions/extension/StructuredDiff.js +130 -0
  131. package/dist/editor-core/extensions/extension/ime-shared.d.ts +11 -0
  132. package/dist/editor-core/extensions/extension/ime-shared.js +20 -0
  133. package/dist/editor-core/extensions/index.d.ts +4 -0
  134. package/dist/editor-core/extensions/index.js +6 -0
  135. package/dist/editor-core/extensions/node/Attachment.d.ts +33 -0
  136. package/dist/editor-core/extensions/node/Attachment.js +337 -0
  137. package/dist/editor-core/extensions/node/Audio.d.ts +25 -0
  138. package/dist/editor-core/extensions/node/Audio.js +201 -0
  139. package/dist/editor-core/extensions/node/CodeBlockLowlight.js +31 -0
  140. package/dist/editor-core/extensions/node/DrawPanel.d.ts +11 -0
  141. package/dist/editor-core/extensions/node/FileHandler.d.ts +4 -0
  142. package/dist/editor-core/extensions/node/FileHandler.js +198 -0
  143. package/dist/editor-core/extensions/node/Flow/index.d.ts +22 -0
  144. package/dist/editor-core/extensions/node/Iframe.d.ts +18 -0
  145. package/dist/editor-core/extensions/node/Iframe.js +172 -0
  146. package/dist/editor-core/extensions/node/Image.d.ts +5 -0
  147. package/dist/editor-core/extensions/node/Image.js +602 -0
  148. package/dist/editor-core/extensions/node/Link/index.js +568 -0
  149. package/dist/editor-core/extensions/node/ListKit.js +18 -0
  150. package/dist/editor-core/extensions/node/Mathematics.d.ts +27 -0
  151. package/dist/editor-core/extensions/node/Mathematics.js +58 -0
  152. package/dist/editor-core/extensions/node/Mention.d.ts +2 -0
  153. package/dist/editor-core/extensions/node/Table.js +328 -0
  154. package/dist/editor-core/extensions/node/TableOfContents/index.d.ts +11 -0
  155. package/dist/editor-core/extensions/node/TableOfContents/index.js +449 -0
  156. package/dist/editor-core/extensions/node/TableOfContents/plugin.js +57 -0
  157. package/dist/editor-core/extensions/node/Video.d.ts +26 -0
  158. package/dist/editor-core/extensions/node/Video.js +368 -0
  159. package/dist/editor-core/extensions/node/code-block-lowlight-shared.d.ts +14 -0
  160. package/dist/editor-core/extensions/node/code-block-lowlight-shared.js +34 -0
  161. package/dist/editor-core/extensions/node/list-shared.d.ts +18 -0
  162. package/dist/editor-core/extensions/node/list-shared.js +18 -0
  163. package/dist/editor-core/extensions/node/mathematics-shared.d.ts +7 -0
  164. package/dist/editor-core/extensions/node/mathematics-shared.js +40 -0
  165. package/dist/editor-core/extensions/node/resource-shared.d.ts +13 -0
  166. package/dist/editor-core/extensions/node/resource-shared.js +45 -0
  167. package/dist/editor-core/extensions/plugin-keys.d.ts +2 -0
  168. package/dist/editor-core/extensions/plugin-keys.js +2 -0
  169. package/dist/editor-core/extensions/suggestion/mention.d.ts +4 -0
  170. package/dist/editor-core/extensions/suggestion/mention.js +88 -0
  171. package/dist/editor-core/extensions/suggestion/slash.d.ts +52 -0
  172. package/dist/editor-core/extensions/suggestion/slash.js +94 -0
  173. package/dist/extensions.d.ts +2 -0
  174. package/dist/extensions.js +2 -0
  175. package/dist/features/drag-handle/action-count-badge.d.ts +5 -0
  176. package/dist/features/drag-handle/action-count-badge.js +23 -0
  177. package/dist/features/drag-handle/action-groups.d.ts +13 -0
  178. package/dist/features/drag-handle/action-groups.js +49 -0
  179. package/dist/features/drag-handle/convert-builders.d.ts +8 -0
  180. package/dist/features/drag-handle/convert-builders.js +201 -0
  181. package/dist/features/drag-handle/download-builders.d.ts +7 -0
  182. package/dist/features/drag-handle/download-builders.js +237 -0
  183. package/dist/features/drag-handle/drag-handle-header.d.ts +17 -0
  184. package/dist/features/drag-handle/drag-handle-header.js +233 -0
  185. package/dist/features/drag-handle/index.d.ts +9 -0
  186. package/dist/features/drag-handle/index.js +210 -0
  187. package/dist/features/drag-handle/insert-builders.d.ts +3 -0
  188. package/dist/features/drag-handle/insert-builders.js +81 -0
  189. package/dist/features/drag-handle/menu-builders.d.ts +4 -0
  190. package/dist/features/drag-handle/menu-builders.js +4 -0
  191. package/dist/features/drag-handle/menu-shared.d.ts +11 -0
  192. package/dist/features/drag-handle/menu-shared.js +102 -0
  193. package/dist/features/drag-handle/node-actions.d.ts +5 -0
  194. package/dist/features/drag-handle/node-actions.js +57 -0
  195. package/dist/features/drag-handle/style-builders.d.ts +8 -0
  196. package/dist/features/drag-handle/style-builders.js +197 -0
  197. package/dist/features/drag-handle/types.d.ts +27 -0
  198. package/dist/features/drag-handle/use-current-node-context.d.ts +11 -0
  199. package/dist/features/drag-handle/use-current-node-context.js +109 -0
  200. package/dist/features/markdown/Toolbar.d.ts +10 -0
  201. package/dist/features/markdown/Toolbar.js +81 -0
  202. package/dist/features/markdown/index.d.ts +33 -0
  203. package/dist/features/markdown/index.js +284 -0
  204. package/dist/features/markdown/toolbar-actions.d.ts +82 -0
  205. package/dist/features/markdown/toolbar-actions.js +734 -0
  206. package/dist/features/markdown/toolbar-menu.d.ts +9 -0
  207. package/dist/features/markdown/toolbar-menu.js +87 -0
  208. package/dist/features/markdown/toolbar-tool-list.d.ts +12 -0
  209. package/dist/features/markdown/toolbar-tool-list.js +24 -0
  210. package/dist/features/markdown/use-ace-composition.d.ts +5 -0
  211. package/dist/features/markdown/use-ace-composition.js +39 -0
  212. package/dist/features/markdown/use-display-mode.d.ts +8 -0
  213. package/dist/features/markdown/use-display-mode.js +28 -0
  214. package/dist/features/markdown/use-markdown-file-inputs.d.ts +10 -0
  215. package/dist/features/markdown/use-markdown-file-inputs.js +69 -0
  216. package/dist/features/markdown/use-markdown-sync.d.ts +13 -0
  217. package/dist/features/markdown/use-markdown-sync.js +56 -0
  218. package/dist/features/markdown/use-markdown-transfer.d.ts +18 -0
  219. package/dist/features/markdown/use-markdown-transfer.js +123 -0
  220. package/dist/features/markdown/use-markdown-upload.d.ts +13 -0
  221. package/dist/features/markdown/use-markdown-upload.js +98 -0
  222. package/dist/features/media/iframe/Insert.d.ts +16 -0
  223. package/dist/features/media/iframe/Insert.js +123 -0
  224. package/dist/features/media/iframe/index.d.ts +5 -0
  225. package/dist/features/media/iframe/index.js +255 -0
  226. package/dist/features/media/image/Crop.d.ts +12 -0
  227. package/dist/features/media/image/Insert.d.ts +10 -0
  228. package/dist/features/media/image/Insert.js +294 -0
  229. package/dist/features/media/image/Readonly.js +53 -0
  230. package/dist/features/media/image/index.d.ts +22 -0
  231. package/dist/features/media/image/index.js +408 -0
  232. package/dist/features/media/shared/media-edit-popover.d.ts +26 -0
  233. package/dist/features/media/shared/media-edit-popover.js +105 -0
  234. package/dist/features/media/shared/media-hover-toolbar.d.ts +18 -0
  235. package/dist/features/media/shared/media-hover-toolbar.js +140 -0
  236. package/dist/features/media/shared/media-resize-handles.d.ts +8 -0
  237. package/dist/features/media/shared/media-resize-handles.js +70 -0
  238. package/dist/features/media/shared/use-media-resize.d.ts +20 -0
  239. package/dist/features/media/shared/use-media-resize.js +88 -0
  240. package/dist/features/media/shared/use-media-width.d.ts +14 -0
  241. package/dist/features/media/shared/use-media-width.js +76 -0
  242. package/dist/features/media/video/Insert.d.ts +10 -0
  243. package/dist/features/media/video/Insert.js +220 -0
  244. package/dist/features/media/video/index.d.ts +15 -0
  245. package/dist/features/media/video/index.js +261 -0
  246. package/dist/features/table/TableCellHandleMenu/index.js +234 -0
  247. package/dist/features/table/TableExtendButton/index.d.ts +21 -0
  248. package/dist/features/table/TableExtendButton/index.js +210 -0
  249. package/dist/features/table/TableHandle/TableHandleAddButton.d.ts +14 -0
  250. package/dist/features/table/TableHandle/TableHandleAddButton.js +78 -0
  251. package/dist/features/table/TableHandle/TableHandleMenu.d.ts +17 -0
  252. package/dist/features/table/TableHandle/TableHandleMenu.js +583 -0
  253. package/dist/features/table/TableHandle/index.d.ts +11 -0
  254. package/dist/features/table/TableHandle/index.js +73 -0
  255. package/dist/features/table/TableHandle/menu-builders.d.ts +14 -0
  256. package/dist/features/table/TableHandle/menu-builders.js +242 -0
  257. package/dist/features/table/TableHandle/table-handle-group.d.ts +16 -0
  258. package/dist/features/table/TableHandle/table-handle-group.js +84 -0
  259. package/dist/features/table/TableHandle/use-table-handle-positioning.js +166 -0
  260. package/dist/features/table/TableHandle/use-table-handle-state.d.ts +13 -0
  261. package/dist/features/table/TableHandle/use-table-handle-visibility.d.ts +14 -0
  262. package/dist/features/table/TableHandle/use-table-handle-visibility.js +47 -0
  263. package/dist/features/table/TableHandle/use-table-menu-open.d.ts +12 -0
  264. package/dist/features/table/TableHandle/use-table-menu-open.js +39 -0
  265. package/dist/features/table/TableSelectionOverlay/index.js +449 -0
  266. package/dist/features/table/plugin/decorations.d.ts +9 -0
  267. package/dist/features/table/plugin/decorations.js +80 -0
  268. package/dist/features/table/plugin/drag-helpers.d.ts +11 -0
  269. package/dist/features/table/plugin/drag-helpers.js +188 -0
  270. package/dist/features/table/plugin/hover-state.d.ts +27 -0
  271. package/dist/features/table/plugin/hover-state.js +60 -0
  272. package/dist/features/table/plugin/index.d.ts +17 -0
  273. package/dist/features/table/plugin/index.js +36 -0
  274. package/dist/features/table/plugin/plugin.d.ts +4 -0
  275. package/dist/features/table/plugin/plugin.js +512 -0
  276. package/dist/features/table/plugin/positioning.d.ts +40 -0
  277. package/dist/features/table/plugin/positioning.js +124 -0
  278. package/dist/features/table/plugin/shared.d.ts +37 -0
  279. package/dist/features/table/plugin/shared.js +9 -0
  280. package/dist/features/table/plugin/state-sync.d.ts +12 -0
  281. package/dist/features/table/plugin/state-sync.js +75 -0
  282. package/dist/features/toolbar/index.d.ts +16 -0
  283. package/dist/features/toolbar/index.js +179 -0
  284. package/dist/features/toolbar/toolbar-config.d.ts +32 -0
  285. package/dist/features/toolbar/toolbar-config.js +209 -0
  286. package/dist/features/toolbar/toolbar-divider.d.ts +3 -0
  287. package/dist/features/toolbar/toolbar-divider.js +14 -0
  288. package/dist/features/toolbar/toolbar-sections.d.ts +23 -0
  289. package/dist/features/toolbar/toolbar-sections.js +107 -0
  290. package/dist/hooks/fn.d.ts +13 -0
  291. package/dist/hooks/fn.js +37 -0
  292. package/dist/hooks/index.d.ts +4 -0
  293. package/dist/hooks/index.js +133 -0
  294. package/dist/index.d.ts +8 -10
  295. package/dist/index.js +8 -10
  296. package/dist/ssr.d.ts +2 -0
  297. package/dist/ssr.js +1 -0
  298. package/dist/themes/componentStyleOverrides.js +1 -1
  299. package/dist/themes/index.d.ts +1 -1
  300. package/dist/types/index.js +1 -0
  301. package/dist/utils/color.d.ts +1 -0
  302. package/dist/utils/color.js +18 -0
  303. package/dist/utils/diff/index.d.ts +2 -0
  304. package/dist/utils/diff/index.js +2 -0
  305. package/dist/utils/editor.d.ts +6 -0
  306. package/dist/utils/editor.js +29 -0
  307. package/dist/utils/embed.d.ts +2 -0
  308. package/dist/utils/embed.js +27 -0
  309. package/dist/utils/file/index.d.ts +3 -0
  310. package/dist/utils/file/index.js +3 -0
  311. package/dist/utils/file.d.ts +3 -0
  312. package/dist/utils/file.js +20 -0
  313. package/dist/utils/fileHandler.d.ts +7 -0
  314. package/dist/utils/fileHandler.js +69 -0
  315. package/dist/utils/index.d.ts +10 -0
  316. package/dist/utils/index.js +10 -0
  317. package/dist/utils/link.d.ts +5 -0
  318. package/dist/utils/link.js +25 -0
  319. package/dist/utils/resource.d.ts +2 -0
  320. package/dist/utils/resource.js +38 -0
  321. package/dist/utils/resourceExtractor.d.ts +15 -0
  322. package/dist/utils/resourceExtractor.js +61 -0
  323. package/dist/utils/shortcutKey.js +10 -0
  324. package/dist/utils/table/index.d.ts +1 -0
  325. package/dist/utils/table/index.js +1 -0
  326. package/package.json +53 -32
  327. package/dist/Editor/demo.d.ts +0 -4
  328. package/dist/Editor/demo.js +0 -219
  329. package/dist/Editor/index.d.ts +0 -5
  330. package/dist/Editor/index.js +0 -46
  331. package/dist/EditorDiff/demo.d.ts +0 -4
  332. package/dist/EditorDiff/demo.js +0 -12
  333. package/dist/EditorDiff/index.js +0 -34
  334. package/dist/EditorMarkdown/Toolbar.d.ts +0 -9
  335. package/dist/EditorMarkdown/Toolbar.js +0 -942
  336. package/dist/EditorMarkdown/demo.d.ts +0 -4
  337. package/dist/EditorMarkdown/demo.js +0 -167
  338. package/dist/EditorMarkdown/index.d.ts +0 -33
  339. package/dist/EditorMarkdown/index.js +0 -566
  340. package/dist/EditorThemeProvider/index.d.ts +0 -11
  341. package/dist/EditorThemeProvider/index.js +0 -90
  342. package/dist/EditorToolbar/index.d.ts +0 -16
  343. package/dist/EditorToolbar/index.js +0 -361
  344. package/dist/component/ActionDropdown/index.d.ts +0 -30
  345. package/dist/component/ActionDropdown/index.js +0 -152
  346. package/dist/component/CustomBubbleMenu/index.d.ts +0 -9
  347. package/dist/component/CustomBubbleMenu/index.js +0 -164
  348. package/dist/component/CustomDragHandle/index.d.ts +0 -9
  349. package/dist/component/CustomDragHandle/index.js +0 -1372
  350. package/dist/component/FloatingPopover/index.js +0 -120
  351. package/dist/component/HoverPopover/index.js +0 -162
  352. package/dist/component/Menu/NestedList.d.ts +0 -16
  353. package/dist/component/Menu/NestedList.js +0 -163
  354. package/dist/component/Menu/index.d.ts +0 -7
  355. package/dist/component/Menu/index.js +0 -108
  356. package/dist/component/Toolbar/EditorAlignSelect.js +0 -187
  357. package/dist/component/Toolbar/EditorCode.js +0 -161
  358. package/dist/component/Toolbar/EditorHeading.js +0 -173
  359. package/dist/component/Toolbar/EditorInsert/index.js +0 -491
  360. package/dist/component/Toolbar/EditorListSelect.js +0 -174
  361. package/dist/component/Toolbar/EditorMath.js +0 -159
  362. package/dist/component/Toolbar/EditorMore/NotificationDialog.js +0 -73
  363. package/dist/component/Toolbar/EditorMore/index.d.ts +0 -7
  364. package/dist/component/Toolbar/EditorMore/index.js +0 -109
  365. package/dist/component/Toolbar/EditorScript.js +0 -161
  366. package/dist/component/Toolbar/EditorVerticalAlignSelect.js +0 -174
  367. package/dist/component/Toolbar/Item.js +0 -74
  368. package/dist/component/Toolbar/TableSizePicker.js +0 -80
  369. package/dist/component/Toolbar/index.d.ts +0 -13
  370. package/dist/component/Toolbar/index.js +0 -13
  371. package/dist/contants/enums.d.ts +0 -47
  372. package/dist/contants/enums.js +0 -199
  373. package/dist/contants/slash-commands.js +0 -397
  374. package/dist/extension/component/Alert/index.js +0 -239
  375. package/dist/extension/component/Attachment/AttachmentContent.js +0 -420
  376. package/dist/extension/component/Attachment/Insert.d.ts +0 -13
  377. package/dist/extension/component/Attachment/Insert.js +0 -221
  378. package/dist/extension/component/Attachment/index.d.ts +0 -15
  379. package/dist/extension/component/Attachment/index.js +0 -310
  380. package/dist/extension/component/Audio/AudioPlayer.d.ts +0 -8
  381. package/dist/extension/component/Audio/AudioPlayer.js +0 -382
  382. package/dist/extension/component/Audio/Insert.d.ts +0 -10
  383. package/dist/extension/component/Audio/Insert.js +0 -388
  384. package/dist/extension/component/Audio/index.d.ts +0 -14
  385. package/dist/extension/component/Audio/index.js +0 -406
  386. package/dist/extension/component/CodeBlock/Readonly.js +0 -162
  387. package/dist/extension/component/CodeBlock/index.js +0 -374
  388. package/dist/extension/component/DrawPanel/index.d.ts +0 -5
  389. package/dist/extension/component/DrawPanel/index.js +0 -168
  390. package/dist/extension/component/FlipGrid/ColumnView.js +0 -191
  391. package/dist/extension/component/Flow/Edit.js +0 -69
  392. package/dist/extension/component/Flow/Insert.js +0 -108
  393. package/dist/extension/component/Flow/index.d.ts +0 -10
  394. package/dist/extension/component/Flow/index.js +0 -416
  395. package/dist/extension/component/Iframe/Insert.d.ts +0 -16
  396. package/dist/extension/component/Iframe/Insert.js +0 -154
  397. package/dist/extension/component/Iframe/index.d.ts +0 -5
  398. package/dist/extension/component/Iframe/index.js +0 -551
  399. package/dist/extension/component/Image/Crop.d.ts +0 -12
  400. package/dist/extension/component/Image/Insert.d.ts +0 -10
  401. package/dist/extension/component/Image/Insert.js +0 -366
  402. package/dist/extension/component/Image/Readonly.js +0 -53
  403. package/dist/extension/component/Image/index.d.ts +0 -22
  404. package/dist/extension/component/Image/index.js +0 -602
  405. package/dist/extension/component/Link/Insert.d.ts +0 -10
  406. package/dist/extension/component/Link/Insert.js +0 -252
  407. package/dist/extension/component/Link/LinkContent.d.ts +0 -13
  408. package/dist/extension/component/Link/LinkContent.js +0 -171
  409. package/dist/extension/component/Link/Markdown.js +0 -66
  410. package/dist/extension/component/Link/index.d.ts +0 -12
  411. package/dist/extension/component/Link/index.js +0 -433
  412. package/dist/extension/component/Mathematics/block/Readonly.d.ts +0 -9
  413. package/dist/extension/component/Mathematics/block/index.d.ts +0 -8
  414. package/dist/extension/component/Mathematics/block/index.js +0 -149
  415. package/dist/extension/component/Mathematics/inline/Readonly.d.ts +0 -9
  416. package/dist/extension/component/Mathematics/inline/index.d.ts +0 -8
  417. package/dist/extension/component/Mathematics/inline/index.js +0 -147
  418. package/dist/extension/component/SlashCommandsList/Overlay.d.ts +0 -10
  419. package/dist/extension/component/SlashCommandsList/Overlay.js +0 -26
  420. package/dist/extension/component/SlashCommandsList/index.d.ts +0 -4
  421. package/dist/extension/component/SlashCommandsList/index.js +0 -330
  422. package/dist/extension/component/TableCellHandleMenu/index.js +0 -512
  423. package/dist/extension/component/TableExtendButton/index.d.ts +0 -21
  424. package/dist/extension/component/TableExtendButton/index.js +0 -210
  425. package/dist/extension/component/TableHandle/TableHandleAddButton.d.ts +0 -14
  426. package/dist/extension/component/TableHandle/TableHandleAddButton.js +0 -78
  427. package/dist/extension/component/TableHandle/TableHandleMenu.d.ts +0 -17
  428. package/dist/extension/component/TableHandle/TableHandleMenu.js +0 -800
  429. package/dist/extension/component/TableHandle/index.d.ts +0 -23
  430. package/dist/extension/component/TableHandle/index.js +0 -140
  431. package/dist/extension/component/TableHandle/use-table-handle-positioning.js +0 -166
  432. package/dist/extension/component/TableHandle/use-table-handle-state.d.ts +0 -13
  433. package/dist/extension/component/TableSelectionOverlay/index.js +0 -449
  434. package/dist/extension/component/Tooltip/EditPopover.js +0 -162
  435. package/dist/extension/component/Tooltip/index.js +0 -148
  436. package/dist/extension/component/UploadProgress/Inline.d.ts +0 -10
  437. package/dist/extension/component/UploadProgress/Inline.js +0 -80
  438. package/dist/extension/component/UploadProgress/index.d.ts +0 -12
  439. package/dist/extension/component/UploadProgress/index.js +0 -111
  440. package/dist/extension/component/Video/Insert.d.ts +0 -10
  441. package/dist/extension/component/Video/Insert.js +0 -296
  442. package/dist/extension/component/Video/index.d.ts +0 -15
  443. package/dist/extension/component/Video/index.js +0 -554
  444. package/dist/extension/extension/ImeComposition.d.ts +0 -2
  445. package/dist/extension/extension/ImeComposition.js +0 -145
  446. package/dist/extension/extension/StructuredDiff.js +0 -131
  447. package/dist/extension/index.d.ts +0 -2
  448. package/dist/extension/index.js +0 -191
  449. package/dist/extension/node/Attachment.d.ts +0 -33
  450. package/dist/extension/node/Attachment.js +0 -325
  451. package/dist/extension/node/Audio.d.ts +0 -25
  452. package/dist/extension/node/Audio.js +0 -209
  453. package/dist/extension/node/CodeBlockLowlight.js +0 -58
  454. package/dist/extension/node/DrawPanel.d.ts +0 -11
  455. package/dist/extension/node/FileHandler.d.ts +0 -4
  456. package/dist/extension/node/FileHandler.js +0 -198
  457. package/dist/extension/node/Flow/index.d.ts +0 -22
  458. package/dist/extension/node/Iframe.d.ts +0 -18
  459. package/dist/extension/node/Iframe.js +0 -172
  460. package/dist/extension/node/Image.d.ts +0 -5
  461. package/dist/extension/node/Image.js +0 -602
  462. package/dist/extension/node/Link/index.js +0 -562
  463. package/dist/extension/node/ListKit.js +0 -23
  464. package/dist/extension/node/Mathematics.d.ts +0 -27
  465. package/dist/extension/node/Mathematics.js +0 -97
  466. package/dist/extension/node/Mention.d.ts +0 -2
  467. package/dist/extension/node/Table.js +0 -328
  468. package/dist/extension/node/TableHandler/index.d.ts +0 -15
  469. package/dist/extension/node/TableHandler/index.js +0 -33
  470. package/dist/extension/node/TableHandler/plugin.d.ts +0 -45
  471. package/dist/extension/node/TableHandler/plugin.js +0 -1083
  472. package/dist/extension/node/TableOfContents/index.d.ts +0 -11
  473. package/dist/extension/node/TableOfContents/index.js +0 -449
  474. package/dist/extension/node/TableOfContents/plugin.js +0 -58
  475. package/dist/extension/node/Video.d.ts +0 -26
  476. package/dist/extension/node/Video.js +0 -368
  477. package/dist/extension/suggestion/mention.d.ts +0 -4
  478. package/dist/extension/suggestion/mention.js +0 -88
  479. package/dist/extension/suggestion/slash.d.ts +0 -52
  480. package/dist/extension/suggestion/slash.js +0 -94
  481. package/dist/hook/fn.d.ts +0 -13
  482. package/dist/hook/fn.js +0 -37
  483. package/dist/hook/index.d.ts +0 -4
  484. package/dist/hook/index.js +0 -123
  485. package/dist/util/fileHandler.d.ts +0 -7
  486. package/dist/util/fileHandler.js +0 -82
  487. package/dist/util/index.d.ts +0 -35
  488. package/dist/util/index.js +0 -165
  489. package/dist/util/resourceExtractor.d.ts +0 -15
  490. package/dist/util/resourceExtractor.js +0 -61
  491. package/dist/util/shortcutKey.js +0 -10
  492. /package/dist/{EditorDiff → app/editor/EditorDiff}/index.d.ts +0 -0
  493. /package/dist/{component → components}/CustomFloatingMenu/index.d.ts +0 -0
  494. /package/dist/{component → components}/CustomFloatingMenu/index.js +0 -0
  495. /package/dist/{component → components}/FloatingPopover/index.d.ts +0 -0
  496. /package/dist/{component → components}/HoverPopover/index.d.ts +0 -0
  497. /package/dist/{component → components}/Icons/add-circle-fill-icon.d.ts +0 -0
  498. /package/dist/{component → components}/Icons/add-circle-fill-icon.js +0 -0
  499. /package/dist/{component → components}/Icons/add-line-icon.d.ts +0 -0
  500. /package/dist/{component → components}/Icons/add-line-icon.js +0 -0
  501. /package/dist/{component → components}/Icons/ai-generate-2-icon.d.ts +0 -0
  502. /package/dist/{component → components}/Icons/ai-generate-2-icon.js +0 -0
  503. /package/dist/{component → components}/Icons/ai-generate-text-icon.d.ts +0 -0
  504. /package/dist/{component → components}/Icons/ai-generate-text-icon.js +0 -0
  505. /package/dist/{component → components}/Icons/align-bottom-icon.d.ts +0 -0
  506. /package/dist/{component → components}/Icons/align-bottom-icon.js +0 -0
  507. /package/dist/{component → components}/Icons/align-center-icon.d.ts +0 -0
  508. /package/dist/{component → components}/Icons/align-center-icon.js +0 -0
  509. /package/dist/{component → components}/Icons/align-justify-icon.d.ts +0 -0
  510. /package/dist/{component → components}/Icons/align-justify-icon.js +0 -0
  511. /package/dist/{component → components}/Icons/align-left-icon.d.ts +0 -0
  512. /package/dist/{component → components}/Icons/align-left-icon.js +0 -0
  513. /package/dist/{component → components}/Icons/align-right-icon.d.ts +0 -0
  514. /package/dist/{component → components}/Icons/align-right-icon.js +0 -0
  515. /package/dist/{component → components}/Icons/align-top-icon.d.ts +0 -0
  516. /package/dist/{component → components}/Icons/align-top-icon.js +0 -0
  517. /package/dist/{component → components}/Icons/align-vertically-icon.d.ts +0 -0
  518. /package/dist/{component → components}/Icons/align-vertically-icon.js +0 -0
  519. /package/dist/{component → components}/Icons/anticlockwise-line-icon.d.ts +0 -0
  520. /package/dist/{component → components}/Icons/anticlockwise-line-icon.js +0 -0
  521. /package/dist/{component → components}/Icons/arrow-down-s-line-icon.d.ts +0 -0
  522. /package/dist/{component → components}/Icons/arrow-down-s-line-icon.js +0 -0
  523. /package/dist/{component → components}/Icons/arrow-go-back-line-icon.d.ts +0 -0
  524. /package/dist/{component → components}/Icons/arrow-go-back-line-icon.js +0 -0
  525. /package/dist/{component → components}/Icons/arrow-go-forward-line-icon.d.ts +0 -0
  526. /package/dist/{component → components}/Icons/arrow-go-forward-line-icon.js +0 -0
  527. /package/dist/{component → components}/Icons/arrow-left-wide-line-icon.d.ts +0 -0
  528. /package/dist/{component → components}/Icons/arrow-left-wide-line-icon.js +0 -0
  529. /package/dist/{component → components}/Icons/at-line-icon.d.ts +0 -0
  530. /package/dist/{component → components}/Icons/at-line-icon.js +0 -0
  531. /package/dist/{component → components}/Icons/attachment-2-icon.d.ts +0 -0
  532. /package/dist/{component → components}/Icons/attachment-2-icon.js +0 -0
  533. /package/dist/{component → components}/Icons/attachment-line-icon.d.ts +0 -0
  534. /package/dist/{component → components}/Icons/attachment-line-icon.js +0 -0
  535. /package/dist/{component → components}/Icons/bilibili-line-icon.d.ts +0 -0
  536. /package/dist/{component → components}/Icons/bilibili-line-icon.js +0 -0
  537. /package/dist/{component → components}/Icons/bold-icon.d.ts +0 -0
  538. /package/dist/{component → components}/Icons/bold-icon.js +0 -0
  539. /package/dist/{component → components}/Icons/brush-line-icon.d.ts +0 -0
  540. /package/dist/{component → components}/Icons/brush-line-icon.js +0 -0
  541. /package/dist/{component → components}/Icons/carousel-view-icon.d.ts +0 -0
  542. /package/dist/{component → components}/Icons/carousel-view-icon.js +0 -0
  543. /package/dist/{component → components}/Icons/checkbox-blank-circle-line-icon.d.ts +0 -0
  544. /package/dist/{component → components}/Icons/checkbox-blank-circle-line-icon.js +0 -0
  545. /package/dist/{component → components}/Icons/checkbox-circle-fill-icon.d.ts +0 -0
  546. /package/dist/{component → components}/Icons/checkbox-circle-fill-icon.js +0 -0
  547. /package/dist/{component → components}/Icons/checkbox-circle-line-icon.d.ts +0 -0
  548. /package/dist/{component → components}/Icons/checkbox-circle-line-icon.js +0 -0
  549. /package/dist/{component → components}/Icons/chrome-icon.d.ts +0 -0
  550. /package/dist/{component → components}/Icons/chrome-icon.js +0 -0
  551. /package/dist/{component → components}/Icons/clockwise-line-icon.d.ts +0 -0
  552. /package/dist/{component → components}/Icons/clockwise-line-icon.js +0 -0
  553. /package/dist/{component → components}/Icons/close-circle-fill-icon.d.ts +0 -0
  554. /package/dist/{component → components}/Icons/close-circle-fill-icon.js +0 -0
  555. /package/dist/{component → components}/Icons/code-box-line-icon.d.ts +0 -0
  556. /package/dist/{component → components}/Icons/code-box-line-icon.js +0 -0
  557. /package/dist/{component → components}/Icons/code-line-icon.d.ts +0 -0
  558. /package/dist/{component → components}/Icons/code-line-icon.js +0 -0
  559. /package/dist/{component → components}/Icons/code-s-slash-line-icon.d.ts +0 -0
  560. /package/dist/{component → components}/Icons/code-s-slash-line-icon.js +0 -0
  561. /package/dist/{component → components}/Icons/collapse-horizontal-line.d.ts +0 -0
  562. /package/dist/{component → components}/Icons/collapse-horizontal-line.js +0 -0
  563. /package/dist/{component → components}/Icons/collapse-icon.d.ts +0 -0
  564. /package/dist/{component → components}/Icons/collapse-icon.js +0 -0
  565. /package/dist/{component → components}/Icons/command-line-icon.d.ts +0 -0
  566. /package/dist/{component → components}/Icons/command-line-icon.js +0 -0
  567. /package/dist/{component → components}/Icons/copy-icon.d.ts +0 -0
  568. /package/dist/{component → components}/Icons/copy-icon.js +0 -0
  569. /package/dist/{component → components}/Icons/custom-size-icon.d.ts +0 -0
  570. /package/dist/{component → components}/Icons/custom-size-icon.js +0 -0
  571. /package/dist/{component → components}/Icons/delete-back-2-line-icon.d.ts +0 -0
  572. /package/dist/{component → components}/Icons/delete-back-2-line-icon.js +0 -0
  573. /package/dist/{component → components}/Icons/delete-column-icon.d.ts +0 -0
  574. /package/dist/{component → components}/Icons/delete-column-icon.js +0 -0
  575. /package/dist/{component → components}/Icons/delete-line-icon.d.ts +0 -0
  576. /package/dist/{component → components}/Icons/delete-line-icon.js +0 -0
  577. /package/dist/{component → components}/Icons/delete-row-icon.d.ts +0 -0
  578. /package/dist/{component → components}/Icons/delete-row-icon.js +0 -0
  579. /package/dist/{component → components}/Icons/double-quotes-l-icon.d.ts +0 -0
  580. /package/dist/{component → components}/Icons/double-quotes-l-icon.js +0 -0
  581. /package/dist/{component → components}/Icons/download-2-line-icon.d.ts +0 -0
  582. /package/dist/{component → components}/Icons/download-2-line-icon.js +0 -0
  583. /package/dist/{component → components}/Icons/download-line-icon.d.ts +0 -0
  584. /package/dist/{component → components}/Icons/download-line-icon.js +0 -0
  585. /package/dist/{component → components}/Icons/draggable-icon.d.ts +0 -0
  586. /package/dist/{component → components}/Icons/draggable-icon.js +0 -0
  587. /package/dist/{component → components}/Icons/edit-box-line-icon.d.ts +0 -0
  588. /package/dist/{component → components}/Icons/edit-box-line-icon.js +0 -0
  589. /package/dist/{component → components}/Icons/edit-line-icon.d.ts +0 -0
  590. /package/dist/{component → components}/Icons/edit-line-icon.js +0 -0
  591. /package/dist/{component → components}/Icons/emotion-line-icon.d.ts +0 -0
  592. /package/dist/{component → components}/Icons/emotion-line-icon.js +0 -0
  593. /package/dist/{component → components}/Icons/eraser-line-icon.d.ts +0 -0
  594. /package/dist/{component → components}/Icons/eraser-line-icon.js +0 -0
  595. /package/dist/{component → components}/Icons/error-warning-fill-icon.d.ts +0 -0
  596. /package/dist/{component → components}/Icons/error-warning-fill-icon.js +0 -0
  597. /package/dist/{component → components}/Icons/expand-horizontal-line-icon.d.ts +0 -0
  598. /package/dist/{component → components}/Icons/expand-horizontal-line-icon.js +0 -0
  599. /package/dist/{component → components}/Icons/expend-icon.d.ts +0 -0
  600. /package/dist/{component → components}/Icons/expend-icon.js +0 -0
  601. /package/dist/{component → components}/Icons/export-line-icon.d.ts +0 -0
  602. /package/dist/{component → components}/Icons/export-line-icon.js +0 -0
  603. /package/dist/{component → components}/Icons/eye-line-icon.d.ts +0 -0
  604. /package/dist/{component → components}/Icons/eye-line-icon.js +0 -0
  605. /package/dist/{component → components}/Icons/file-copy-line-icon.d.ts +0 -0
  606. /package/dist/{component → components}/Icons/file-copy-line-icon.js +0 -0
  607. /package/dist/{component → components}/Icons/file-icon.d.ts +0 -0
  608. /package/dist/{component → components}/Icons/file-icon.js +0 -0
  609. /package/dist/{component → components}/Icons/file-upload-line-icon.d.ts +0 -0
  610. /package/dist/{component → components}/Icons/file-upload-line-icon.js +0 -0
  611. /package/dist/{component → components}/Icons/flip-grid-icon.d.ts +0 -0
  612. /package/dist/{component → components}/Icons/flip-grid-icon.js +0 -0
  613. /package/dist/{component → components}/Icons/flip-left-line-icon.d.ts +0 -0
  614. /package/dist/{component → components}/Icons/flip-left-line-icon.js +0 -0
  615. /package/dist/{component → components}/Icons/flip-right-line-icon.d.ts +0 -0
  616. /package/dist/{component → components}/Icons/flip-right-line-icon.js +0 -0
  617. /package/dist/{component → components}/Icons/flow-chart-icon.d.ts +0 -0
  618. /package/dist/{component → components}/Icons/flow-chart-icon.js +0 -0
  619. /package/dist/{component → components}/Icons/folder-2-line-icon.d.ts +0 -0
  620. /package/dist/{component → components}/Icons/folder-2-line-icon.js +0 -0
  621. /package/dist/{component → components}/Icons/font-color-icon.d.ts +0 -0
  622. /package/dist/{component → components}/Icons/font-color-icon.js +0 -0
  623. /package/dist/{component → components}/Icons/font-family-icon.d.ts +0 -0
  624. /package/dist/{component → components}/Icons/font-family-icon.js +0 -0
  625. /package/dist/{component → components}/Icons/font-size-icon.d.ts +0 -0
  626. /package/dist/{component → components}/Icons/font-size-icon.js +0 -0
  627. /package/dist/{component → components}/Icons/format-clear-icon.d.ts +0 -0
  628. /package/dist/{component → components}/Icons/format-clear-icon.js +0 -0
  629. /package/dist/{component → components}/Icons/formula-icon.d.ts +0 -0
  630. /package/dist/{component → components}/Icons/formula-icon.js +0 -0
  631. /package/dist/{component → components}/Icons/fullscreen-exit-line-icon.d.ts +0 -0
  632. /package/dist/{component → components}/Icons/fullscreen-exit-line-icon.js +0 -0
  633. /package/dist/{component → components}/Icons/fullscreen-line-icon.d.ts +0 -0
  634. /package/dist/{component → components}/Icons/fullscreen-line-icon.js +0 -0
  635. /package/dist/{component → components}/Icons/functions-icon.d.ts +0 -0
  636. /package/dist/{component → components}/Icons/functions-icon.js +0 -0
  637. /package/dist/{component → components}/Icons/game-line-icon.d.ts +0 -0
  638. /package/dist/{component → components}/Icons/game-line-icon.js +0 -0
  639. /package/dist/{component → components}/Icons/h-1-icon.d.ts +0 -0
  640. /package/dist/{component → components}/Icons/h-1-icon.js +0 -0
  641. /package/dist/{component → components}/Icons/h-2-icon.d.ts +0 -0
  642. /package/dist/{component → components}/Icons/h-2-icon.js +0 -0
  643. /package/dist/{component → components}/Icons/h-3-icon.d.ts +0 -0
  644. /package/dist/{component → components}/Icons/h-3-icon.js +0 -0
  645. /package/dist/{component → components}/Icons/h-4-icon.d.ts +0 -0
  646. /package/dist/{component → components}/Icons/h-4-icon.js +0 -0
  647. /package/dist/{component → components}/Icons/h-5-icon.d.ts +0 -0
  648. /package/dist/{component → components}/Icons/h-5-icon.js +0 -0
  649. /package/dist/{component → components}/Icons/h-6-icon.d.ts +0 -0
  650. /package/dist/{component → components}/Icons/h-6-icon.js +0 -0
  651. /package/dist/{component → components}/Icons/heading-icon.d.ts +0 -0
  652. /package/dist/{component → components}/Icons/heading-icon.js +0 -0
  653. /package/dist/{component → components}/Icons/image-add-line-icon.d.ts +0 -0
  654. /package/dist/{component → components}/Icons/image-add-line-icon.js +0 -0
  655. /package/dist/{component → components}/Icons/image-line-icon.d.ts +0 -0
  656. /package/dist/{component → components}/Icons/image-line-icon.js +0 -0
  657. /package/dist/{component → components}/Icons/import-line-icon.d.ts +0 -0
  658. /package/dist/{component → components}/Icons/import-line-icon.js +0 -0
  659. /package/dist/{component → components}/Icons/indent-decrease-icon.d.ts +0 -0
  660. /package/dist/{component → components}/Icons/indent-decrease-icon.js +0 -0
  661. /package/dist/{component → components}/Icons/indent-increase-icon.d.ts +0 -0
  662. /package/dist/{component → components}/Icons/indent-increase-icon.js +0 -0
  663. /package/dist/{component → components}/Icons/index.d.ts +0 -0
  664. /package/dist/{component → components}/Icons/index.js +0 -0
  665. /package/dist/{component → components}/Icons/information-2-fill-icon.d.ts +0 -0
  666. /package/dist/{component → components}/Icons/information-2-fill-icon.js +0 -0
  667. /package/dist/{component → components}/Icons/information-2-line-icon.d.ts +0 -0
  668. /package/dist/{component → components}/Icons/information-2-line-icon.js +0 -0
  669. /package/dist/{component → components}/Icons/insert-column-left-icon.d.ts +0 -0
  670. /package/dist/{component → components}/Icons/insert-column-left-icon.js +0 -0
  671. /package/dist/{component → components}/Icons/insert-column-right-icon.d.ts +0 -0
  672. /package/dist/{component → components}/Icons/insert-column-right-icon.js +0 -0
  673. /package/dist/{component → components}/Icons/insert-row-bottom-icon.d.ts +0 -0
  674. /package/dist/{component → components}/Icons/insert-row-bottom-icon.js +0 -0
  675. /package/dist/{component → components}/Icons/insert-row-top-icon.d.ts +0 -0
  676. /package/dist/{component → components}/Icons/insert-row-top-icon.js +0 -0
  677. /package/dist/{component → components}/Icons/italic-icon.d.ts +0 -0
  678. /package/dist/{component → components}/Icons/italic-icon.js +0 -0
  679. /package/dist/{component → components}/Icons/keyboard-line-icon.d.ts +0 -0
  680. /package/dist/{component → components}/Icons/keyboard-line-icon.js +0 -0
  681. /package/dist/{component → components}/Icons/layout-left-2-line-icon.d.ts +0 -0
  682. /package/dist/{component → components}/Icons/layout-left-2-line-icon.js +0 -0
  683. /package/dist/{component → components}/Icons/layout-top-2-line-icon.d.ts +0 -0
  684. /package/dist/{component → components}/Icons/layout-top-2-line-icon.js +0 -0
  685. /package/dist/{component → components}/Icons/link-icon.d.ts +0 -0
  686. /package/dist/{component → components}/Icons/link-icon.js +0 -0
  687. /package/dist/{component → components}/Icons/link-unlink-icon.d.ts +0 -0
  688. /package/dist/{component → components}/Icons/link-unlink-icon.js +0 -0
  689. /package/dist/{component → components}/Icons/list-check-2-icon.d.ts +0 -0
  690. /package/dist/{component → components}/Icons/list-check-2-icon.js +0 -0
  691. /package/dist/{component → components}/Icons/list-check-3-icon.d.ts +0 -0
  692. /package/dist/{component → components}/Icons/list-check-3-icon.js +0 -0
  693. /package/dist/{component → components}/Icons/list-ordered-2-icon.d.ts +0 -0
  694. /package/dist/{component → components}/Icons/list-ordered-2-icon.js +0 -0
  695. /package/dist/{component → components}/Icons/list-unordered-icon.d.ts +0 -0
  696. /package/dist/{component → components}/Icons/list-unordered-icon.js +0 -0
  697. /package/dist/{component → components}/Icons/mark-pen-line-icon.d.ts +0 -0
  698. /package/dist/{component → components}/Icons/mark-pen-line-icon.js +0 -0
  699. /package/dist/{component → components}/Icons/markdown-line-icon.d.ts +0 -0
  700. /package/dist/{component → components}/Icons/markdown-line-icon.js +0 -0
  701. /package/dist/{component → components}/Icons/markup-line-icon.d.ts +0 -0
  702. /package/dist/{component → components}/Icons/markup-line-icon.js +0 -0
  703. /package/dist/{component → components}/Icons/menu-fold-2-fill-icon.d.ts +0 -0
  704. /package/dist/{component → components}/Icons/menu-fold-2-fill-icon.js +0 -0
  705. /package/dist/{component → components}/Icons/merge-cells-horizontal-icon.d.ts +0 -0
  706. /package/dist/{component → components}/Icons/merge-cells-horizontal-icon.js +0 -0
  707. /package/dist/{component → components}/Icons/merge-cells-vertical-icon.d.ts +0 -0
  708. /package/dist/{component → components}/Icons/merge-cells-vertical-icon.js +0 -0
  709. /package/dist/{component → components}/Icons/mind-map-icon.d.ts +0 -0
  710. /package/dist/{component → components}/Icons/mind-map-icon.js +0 -0
  711. /package/dist/{component → components}/Icons/more-line-icon.d.ts +0 -0
  712. /package/dist/{component → components}/Icons/more-line-icon.js +0 -0
  713. /package/dist/{component → components}/Icons/movie-line-icon.d.ts +0 -0
  714. /package/dist/{component → components}/Icons/movie-line-icon.js +0 -0
  715. /package/dist/{component → components}/Icons/music-2-line-icon.d.ts +0 -0
  716. /package/dist/{component → components}/Icons/music-2-line-icon.js +0 -0
  717. /package/dist/{component → components}/Icons/node-tree-icon.d.ts +0 -0
  718. /package/dist/{component → components}/Icons/node-tree-icon.js +0 -0
  719. /package/dist/{component → components}/Icons/notification-3-line-icon.d.ts +0 -0
  720. /package/dist/{component → components}/Icons/notification-3-line-icon.js +0 -0
  721. /package/dist/{component → components}/Icons/organization-chart-icon.d.ts +0 -0
  722. /package/dist/{component → components}/Icons/organization-chart-icon.js +0 -0
  723. /package/dist/{component → components}/Icons/pause-line-icon.d.ts +0 -0
  724. /package/dist/{component → components}/Icons/pause-line-icon.js +0 -0
  725. /package/dist/{component → components}/Icons/play-line-icon.d.ts +0 -0
  726. /package/dist/{component → components}/Icons/play-line-icon.js +0 -0
  727. /package/dist/{component → components}/Icons/question-fill-icon.d.ts +0 -0
  728. /package/dist/{component → components}/Icons/question-fill-icon.js +0 -0
  729. /package/dist/{component → components}/Icons/quote-text-icon.d.ts +0 -0
  730. /package/dist/{component → components}/Icons/quote-text-icon.js +0 -0
  731. /package/dist/{component → components}/Icons/repeat-2-line-icon.d.ts +0 -0
  732. /package/dist/{component → components}/Icons/repeat-2-line-icon.js +0 -0
  733. /package/dist/{component → components}/Icons/reset-left-fill-icon.d.ts +0 -0
  734. /package/dist/{component → components}/Icons/reset-left-fill-icon.js +0 -0
  735. /package/dist/{component → components}/Icons/scissors-cut-line-icon.d.ts +0 -0
  736. /package/dist/{component → components}/Icons/scissors-cut-line-icon.js +0 -0
  737. /package/dist/{component → components}/Icons/screenshot-line-icon.d.ts +0 -0
  738. /package/dist/{component → components}/Icons/screenshot-line-icon.js +0 -0
  739. /package/dist/{component → components}/Icons/scroll-to-bottom-line-icon.d.ts +0 -0
  740. /package/dist/{component → components}/Icons/scroll-to-bottom-line-icon.js +0 -0
  741. /package/dist/{component → components}/Icons/separator-icon.d.ts +0 -0
  742. /package/dist/{component → components}/Icons/separator-icon.js +0 -0
  743. /package/dist/{component → components}/Icons/share-box-line-icon.d.ts +0 -0
  744. /package/dist/{component → components}/Icons/share-box-line-icon.js +0 -0
  745. /package/dist/{component → components}/Icons/sketching-icon.d.ts +0 -0
  746. /package/dist/{component → components}/Icons/sketching-icon.js +0 -0
  747. /package/dist/{component → components}/Icons/skip-down-icon.d.ts +0 -0
  748. /package/dist/{component → components}/Icons/skip-down-icon.js +0 -0
  749. /package/dist/{component → components}/Icons/skip-left-icon.d.ts +0 -0
  750. /package/dist/{component → components}/Icons/skip-left-icon.js +0 -0
  751. /package/dist/{component → components}/Icons/skip-right-icon.d.ts +0 -0
  752. /package/dist/{component → components}/Icons/skip-right-icon.js +0 -0
  753. /package/dist/{component → components}/Icons/skip-up-icon.d.ts +0 -0
  754. /package/dist/{component → components}/Icons/skip-up-icon.js +0 -0
  755. /package/dist/{component → components}/Icons/slash-commands-2-icon.d.ts +0 -0
  756. /package/dist/{component → components}/Icons/slash-commands-2-icon.js +0 -0
  757. /package/dist/{component → components}/Icons/speed-line-icon.d.ts +0 -0
  758. /package/dist/{component → components}/Icons/speed-line-icon.js +0 -0
  759. /package/dist/{component → components}/Icons/split-cells-horizontal-icon.d.ts +0 -0
  760. /package/dist/{component → components}/Icons/split-cells-horizontal-icon.js +0 -0
  761. /package/dist/{component → components}/Icons/split-cells-vertical-icon.d.ts +0 -0
  762. /package/dist/{component → components}/Icons/split-cells-vertical-icon.js +0 -0
  763. /package/dist/{component → components}/Icons/square-root-icon.d.ts +0 -0
  764. /package/dist/{component → components}/Icons/square-root-icon.js +0 -0
  765. /package/dist/{component → components}/Icons/strikethrough-icon.d.ts +0 -0
  766. /package/dist/{component → components}/Icons/strikethrough-icon.js +0 -0
  767. /package/dist/{component → components}/Icons/subscript-icon.d.ts +0 -0
  768. /package/dist/{component → components}/Icons/subscript-icon.js +0 -0
  769. /package/dist/{component → components}/Icons/superscript-icon.d.ts +0 -0
  770. /package/dist/{component → components}/Icons/superscript-icon.js +0 -0
  771. /package/dist/{component → components}/Icons/table-2-icon.d.ts +0 -0
  772. /package/dist/{component → components}/Icons/table-2-icon.js +0 -0
  773. /package/dist/{component → components}/Icons/table-view-icon.d.ts +0 -0
  774. /package/dist/{component → components}/Icons/table-view-icon.js +0 -0
  775. /package/dist/{component → components}/Icons/text-icon.d.ts +0 -0
  776. /package/dist/{component → components}/Icons/text-icon.js +0 -0
  777. /package/dist/{component → components}/Icons/text-wrap-icon.d.ts +0 -0
  778. /package/dist/{component → components}/Icons/text-wrap-icon.js +0 -0
  779. /package/dist/{component → components}/Icons/title-icon.d.ts +0 -0
  780. /package/dist/{component → components}/Icons/title-icon.js +0 -0
  781. /package/dist/{component → components}/Icons/tooltip-line-icon.d.ts +0 -0
  782. /package/dist/{component → components}/Icons/tooltip-line-icon.js +0 -0
  783. /package/dist/{component → components}/Icons/underline-icon.d.ts +0 -0
  784. /package/dist/{component → components}/Icons/underline-icon.js +0 -0
  785. /package/dist/{component → components}/Icons/upload-cloud-2-line-icon.d.ts +0 -0
  786. /package/dist/{component → components}/Icons/upload-cloud-2-line-icon.js +0 -0
  787. /package/dist/{component → components}/Icons/upload-icon.d.ts +0 -0
  788. /package/dist/{component → components}/Icons/upload-icon.js +0 -0
  789. /package/dist/{component → components}/Icons/user-smile-fill-icon.d.ts +0 -0
  790. /package/dist/{component → components}/Icons/user-smile-fill-icon.js +0 -0
  791. /package/dist/{component → components}/Icons/volume-down-line-icon.d.ts +0 -0
  792. /package/dist/{component → components}/Icons/volume-down-line-icon.js +0 -0
  793. /package/dist/{component → components}/Icons/volume-mute-line-icon.d.ts +0 -0
  794. /package/dist/{component → components}/Icons/volume-mute-line-icon.js +0 -0
  795. /package/dist/{component → components}/Icons/volume-up-line-icon.d.ts +0 -0
  796. /package/dist/{component → components}/Icons/volume-up-line-icon.js +0 -0
  797. /package/dist/{component → components}/Icons/window-fill-icon.d.ts +0 -0
  798. /package/dist/{component → components}/Icons/window-fill-icon.js +0 -0
  799. /package/dist/{component → components}/ImageViewer/Item.d.ts +0 -0
  800. /package/dist/{component → components}/ImageViewer/Item.js +0 -0
  801. /package/dist/{component → components}/ImageViewer/Provider.d.ts +0 -0
  802. /package/dist/{component → components}/ImageViewer/Provider.js +0 -0
  803. /package/dist/{component → components}/ImageViewer/Toolbar.d.ts +0 -0
  804. /package/dist/{component → components}/ImageViewer/Toolbar.js +0 -0
  805. /package/dist/{component → components}/ImageViewer/context.d.ts +0 -0
  806. /package/dist/{component → components}/ImageViewer/context.js +0 -0
  807. /package/dist/{component → components}/ImageViewer/index.d.ts +0 -0
  808. /package/dist/{component → components}/ImageViewer/index.js +0 -0
  809. /package/dist/{component → components}/ImageViewer/styles.d.ts +0 -0
  810. /package/dist/{component → components}/ImageViewer/styles.js +0 -0
  811. /package/dist/{component → components}/ImageViewer/types.d.ts +0 -0
  812. /package/dist/{component → components}/ImageViewer/types.js +0 -0
  813. /package/dist/{component → components}/Toolbar/EditorAlignSelect.d.ts +0 -0
  814. /package/dist/{component → components}/Toolbar/EditorCode.d.ts +0 -0
  815. /package/dist/{component → components}/Toolbar/EditorFontBgColor.d.ts +0 -0
  816. /package/dist/{component → components}/Toolbar/EditorFontBgColor.js +0 -0
  817. /package/dist/{component → components}/Toolbar/EditorFontColor.d.ts +0 -0
  818. /package/dist/{component → components}/Toolbar/EditorFontColor.js +0 -0
  819. /package/dist/{component → components}/Toolbar/EditorFontSize.d.ts +0 -0
  820. /package/dist/{component → components}/Toolbar/EditorFontSize.js +0 -0
  821. /package/dist/{component → components}/Toolbar/EditorHeading.d.ts +0 -0
  822. /package/dist/{component → components}/Toolbar/EditorInsert/index.d.ts +0 -0
  823. /package/dist/{component → components}/Toolbar/EditorListSelect.d.ts +0 -0
  824. /package/dist/{component → components}/Toolbar/EditorMath.d.ts +0 -0
  825. /package/dist/{component → components}/Toolbar/EditorMore/NotificationDialog.d.ts +0 -0
  826. /package/dist/{component → components}/Toolbar/EditorScript.d.ts +0 -0
  827. /package/dist/{component → components}/Toolbar/EditorVerticalAlignSelect.d.ts +0 -0
  828. /package/dist/{component → components}/Toolbar/Item.d.ts +0 -0
  829. /package/dist/{component → components}/Toolbar/TableSizePicker.d.ts +0 -0
  830. /package/dist/{component → components}/index.d.ts +0 -0
  831. /package/dist/{component → components}/index.js +0 -0
  832. /package/dist/{contants → constants}/highlight.d.ts +0 -0
  833. /package/dist/{contants → constants}/highlight.js +0 -0
  834. /package/dist/{contants → constants}/markdown-placeholder.d.ts +0 -0
  835. /package/dist/{contants → constants}/markdown-placeholder.js +0 -0
  836. /package/dist/{contants → constants}/placeholder.d.ts +0 -0
  837. /package/dist/{contants → constants}/placeholder.js +0 -0
  838. /package/dist/{contants → constants}/shortcut-key.d.ts +0 -0
  839. /package/dist/{contants → constants}/shortcut-key.js +0 -0
  840. /package/dist/{contants → constants}/slash-commands.d.ts +0 -0
  841. /package/dist/{extension → editor-core/extensions}/component/Alert/index.d.ts +0 -0
  842. /package/dist/{extension → editor-core/extensions}/component/Attachment/AttachmentContent.d.ts +0 -0
  843. /package/dist/{extension → editor-core/extensions}/component/CodeBlock/Readonly.d.ts +0 -0
  844. /package/dist/{extension → editor-core/extensions}/component/CodeBlock/index.d.ts +0 -0
  845. /package/dist/{extension → editor-core/extensions}/component/DrawPanel/ExcalidrawEditor.d.ts +0 -0
  846. /package/dist/{extension → editor-core/extensions}/component/DrawPanel/ExcalidrawEditor.js +0 -0
  847. /package/dist/{extension → editor-core/extensions}/component/DrawPanel/Modal.d.ts +0 -0
  848. /package/dist/{extension → editor-core/extensions}/component/DrawPanel/Modal.js +0 -0
  849. /package/dist/{extension → editor-core/extensions}/component/EmojiList/index.d.ts +0 -0
  850. /package/dist/{extension → editor-core/extensions}/component/EmojiList/index.js +0 -0
  851. /package/dist/{extension → editor-core/extensions}/component/FlipGrid/ColumnView.d.ts +0 -0
  852. /package/dist/{extension → editor-core/extensions}/component/FlipGrid/index.d.ts +0 -0
  853. /package/dist/{extension → editor-core/extensions}/component/FlipGrid/index.js +0 -0
  854. /package/dist/{extension → editor-core/extensions}/component/FlipGrid/utils.d.ts +0 -0
  855. /package/dist/{extension → editor-core/extensions}/component/FlipGrid/utils.js +0 -0
  856. /package/dist/{extension → editor-core/extensions}/component/Flow/Edit.d.ts +0 -0
  857. /package/dist/{extension → editor-core/extensions}/component/Flow/FlowDiagram.d.ts +0 -0
  858. /package/dist/{extension → editor-core/extensions}/component/Flow/FlowDiagram.js +0 -0
  859. /package/dist/{extension → editor-core/extensions}/component/Flow/Insert.d.ts +0 -0
  860. /package/dist/{extension → editor-core/extensions}/component/Flow/Readonly.d.ts +0 -0
  861. /package/dist/{extension → editor-core/extensions}/component/Flow/Readonly.js +0 -0
  862. /package/dist/{extension → editor-core/extensions}/component/Flow/useMermaidRender.d.ts +0 -0
  863. /package/dist/{extension → editor-core/extensions}/component/Flow/useMermaidRender.js +0 -0
  864. /package/dist/{extension → editor-core/extensions}/component/Flow/utils.d.ts +0 -0
  865. /package/dist/{extension → editor-core/extensions}/component/Flow/utils.js +0 -0
  866. /package/dist/{extension → editor-core/extensions}/component/Link/Markdown.d.ts +0 -0
  867. /package/dist/{extension → editor-core/extensions}/component/Mathematics/block/Readonly.js +0 -0
  868. /package/dist/{extension → editor-core/extensions}/component/Mathematics/index.d.ts +0 -0
  869. /package/dist/{extension → editor-core/extensions}/component/Mathematics/index.js +0 -0
  870. /package/dist/{extension → editor-core/extensions}/component/Mathematics/inline/Readonly.js +0 -0
  871. /package/dist/{extension → editor-core/extensions}/component/MentionList/index.d.ts +0 -0
  872. /package/dist/{extension → editor-core/extensions}/component/MentionList/index.js +0 -0
  873. /package/dist/{extension → editor-core/extensions}/component/Tooltip/EditPopover.d.ts +0 -0
  874. /package/dist/{extension → editor-core/extensions}/component/Tooltip/index.d.ts +0 -0
  875. /package/dist/{extension → editor-core/extensions}/extension/AiWriting.d.ts +0 -0
  876. /package/dist/{extension → editor-core/extensions}/extension/AiWriting.js +0 -0
  877. /package/dist/{extension → editor-core/extensions}/extension/SlashCommands.d.ts +0 -0
  878. /package/dist/{extension → editor-core/extensions}/extension/SlashCommands.js +0 -0
  879. /package/dist/{extension → editor-core/extensions}/extension/StructuredDiff.d.ts +0 -0
  880. /package/dist/{extension → editor-core/extensions}/extension/index.d.ts +0 -0
  881. /package/dist/{extension → editor-core/extensions}/extension/index.js +0 -0
  882. /package/dist/{extension → editor-core/extensions}/mark/Code.d.ts +0 -0
  883. /package/dist/{extension → editor-core/extensions}/mark/Code.js +0 -0
  884. /package/dist/{extension → editor-core/extensions}/mark/Tooltip.d.ts +0 -0
  885. /package/dist/{extension → editor-core/extensions}/mark/Tooltip.js +0 -0
  886. /package/dist/{extension → editor-core/extensions}/node/Alert.d.ts +0 -0
  887. /package/dist/{extension → editor-core/extensions}/node/Alert.js +0 -0
  888. /package/dist/{extension → editor-core/extensions}/node/CodeBlockLowlight.d.ts +0 -0
  889. /package/dist/{extension → editor-core/extensions}/node/Details.d.ts +0 -0
  890. /package/dist/{extension → editor-core/extensions}/node/Details.js +0 -0
  891. /package/dist/{extension → editor-core/extensions}/node/DrawPanel.js +0 -0
  892. /package/dist/{extension → editor-core/extensions}/node/Emoji.d.ts +0 -0
  893. /package/dist/{extension → editor-core/extensions}/node/Emoji.js +0 -0
  894. /package/dist/{extension → editor-core/extensions}/node/FlipGrid.d.ts +0 -0
  895. /package/dist/{extension → editor-core/extensions}/node/FlipGrid.js +0 -0
  896. /package/dist/{extension → editor-core/extensions}/node/Flow/index.js +0 -0
  897. /package/dist/{extension → editor-core/extensions}/node/HorizontalRule.d.ts +0 -0
  898. /package/dist/{extension → editor-core/extensions}/node/HorizontalRule.js +0 -0
  899. /package/dist/{extension → editor-core/extensions}/node/Indent.d.ts +0 -0
  900. /package/dist/{extension → editor-core/extensions}/node/Indent.js +0 -0
  901. /package/dist/{extension → editor-core/extensions}/node/InlineUploadProgress.d.ts +0 -0
  902. /package/dist/{extension → editor-core/extensions}/node/InlineUploadProgress.js +0 -0
  903. /package/dist/{extension → editor-core/extensions}/node/Link/helpers/autolink.d.ts +0 -0
  904. /package/dist/{extension → editor-core/extensions}/node/Link/helpers/autolink.js +0 -0
  905. /package/dist/{extension → editor-core/extensions}/node/Link/helpers/clickHandler.d.ts +0 -0
  906. /package/dist/{extension → editor-core/extensions}/node/Link/helpers/clickHandler.js +0 -0
  907. /package/dist/{extension → editor-core/extensions}/node/Link/helpers/pasteHandler.d.ts +0 -0
  908. /package/dist/{extension → editor-core/extensions}/node/Link/helpers/pasteHandler.js +0 -0
  909. /package/dist/{extension → editor-core/extensions}/node/Link/helpers/whitespace.d.ts +0 -0
  910. /package/dist/{extension → editor-core/extensions}/node/Link/helpers/whitespace.js +0 -0
  911. /package/dist/{extension → editor-core/extensions}/node/Link/index.d.ts +0 -0
  912. /package/dist/{extension → editor-core/extensions}/node/ListKit.d.ts +0 -0
  913. /package/dist/{extension → editor-core/extensions}/node/Mention.js +0 -0
  914. /package/dist/{extension → editor-core/extensions}/node/Script.d.ts +0 -0
  915. /package/dist/{extension → editor-core/extensions}/node/Script.js +0 -0
  916. /package/dist/{extension → editor-core/extensions}/node/Table.d.ts +0 -0
  917. /package/dist/{extension → editor-core/extensions}/node/TableOfContents/plugin.d.ts +0 -0
  918. /package/dist/{extension → editor-core/extensions}/node/TableOfContents/types.d.ts +0 -0
  919. /package/dist/{extension → editor-core/extensions}/node/TableOfContents/types.js +0 -0
  920. /package/dist/{extension → editor-core/extensions}/node/TableOfContents/util.d.ts +0 -0
  921. /package/dist/{extension → editor-core/extensions}/node/TableOfContents/util.js +0 -0
  922. /package/dist/{extension → editor-core/extensions}/node/UploadProgress.d.ts +0 -0
  923. /package/dist/{extension → editor-core/extensions}/node/UploadProgress.js +0 -0
  924. /package/dist/{extension → editor-core/extensions}/node/VerticalAlign.d.ts +0 -0
  925. /package/dist/{extension → editor-core/extensions}/node/VerticalAlign.js +0 -0
  926. /package/dist/{extension → editor-core/extensions}/node/YamlFormat.d.ts +0 -0
  927. /package/dist/{extension → editor-core/extensions}/node/YamlFormat.js +0 -0
  928. /package/dist/{extension → editor-core/extensions}/node/Youtube.d.ts +0 -0
  929. /package/dist/{extension → editor-core/extensions}/node/Youtube.js +0 -0
  930. /package/dist/{extension → editor-core/extensions}/node/index.d.ts +0 -0
  931. /package/dist/{extension → editor-core/extensions}/node/index.js +0 -0
  932. /package/dist/{extension → editor-core/extensions}/suggestion/emoji.d.ts +0 -0
  933. /package/dist/{extension → editor-core/extensions}/suggestion/emoji.js +0 -0
  934. /package/dist/{type/index.js → features/drag-handle/types.js} +0 -0
  935. /package/dist/{EditorMarkdown → features/markdown}/UploadProgress.d.ts +0 -0
  936. /package/dist/{EditorMarkdown → features/markdown}/UploadProgress.js +0 -0
  937. /package/dist/{EditorMarkdown → features/markdown}/util.d.ts +0 -0
  938. /package/dist/{EditorMarkdown → features/markdown}/util.js +0 -0
  939. /package/dist/{extension/component/Iframe → features/media/iframe}/Readonly.d.ts +0 -0
  940. /package/dist/{extension/component/Iframe → features/media/iframe}/Readonly.js +0 -0
  941. /package/dist/{extension/component/Image → features/media/image}/Crop.js +0 -0
  942. /package/dist/{extension/component/Image → features/media/image}/Readonly.d.ts +0 -0
  943. /package/dist/{extension/component/Video → features/media/video}/Readonly.d.ts +0 -0
  944. /package/dist/{extension/component/Video → features/media/video}/Readonly.js +0 -0
  945. /package/dist/{extension/component → features/table}/TableCellHandleMenu/index.d.ts +0 -0
  946. /package/dist/{extension/component → features/table}/TableExtendButton/TableExtendButton.css +0 -0
  947. /package/dist/{extension/component → features/table}/TableExtendButton/use-table-extend-row-column.d.ts +0 -0
  948. /package/dist/{extension/component → features/table}/TableExtendButton/use-table-extend-row-column.js +0 -0
  949. /package/dist/{extension/component → features/table}/TableHandle/TableHandleMenu.css +0 -0
  950. /package/dist/{extension/component → features/table}/TableHandle/use-table-handle-positioning.d.ts +0 -0
  951. /package/dist/{extension/component → features/table}/TableHandle/use-table-handle-state.js +0 -0
  952. /package/dist/{extension/component → features/table}/TableSelectionOverlay/index.d.ts +0 -0
  953. /package/dist/{extension/node/TableHandler → features/table/plugin}/create-image.d.ts +0 -0
  954. /package/dist/{extension/node/TableHandler → features/table/plugin}/create-image.js +0 -0
  955. /package/dist/{type → types}/index.d.ts +0 -0
  956. /package/dist/{util → utils}/decorations.d.ts +0 -0
  957. /package/dist/{util → utils}/decorations.js +0 -0
  958. /package/dist/{util → utils}/fileDownload.d.ts +0 -0
  959. /package/dist/{util → utils}/fileDownload.js +0 -0
  960. /package/dist/{util → utils}/floating.d.ts +0 -0
  961. /package/dist/{util → utils}/floating.js +0 -0
  962. /package/dist/{util → utils}/linewiseConvert.d.ts +0 -0
  963. /package/dist/{util → utils}/linewiseConvert.js +0 -0
  964. /package/dist/{util → utils}/shortcutKey.d.ts +0 -0
  965. /package/dist/{util → utils}/structuredDiff.d.ts +0 -0
  966. /package/dist/{util → utils}/structuredDiff.js +0 -0
  967. /package/dist/{util → utils}/table-utils.d.ts +0 -0
  968. /package/dist/{util → utils}/table-utils.js +0 -0
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ import { MenuItem } from '../../types';
3
+ interface MarkdownToolbarMenuProps {
4
+ type: 'insert' | 'heading' | 'table';
5
+ list: MenuItem[];
6
+ isExpend?: boolean;
7
+ }
8
+ declare const MarkdownToolbarMenu: ({ type, list, isExpend }: MarkdownToolbarMenuProps) => React.JSX.Element;
9
+ export default MarkdownToolbarMenu;
@@ -0,0 +1,87 @@
1
+ function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
2
+ import { Box } from '@mui/material';
3
+ import React from 'react';
4
+ import { AddCircleFillIcon, ArrowDownSLineIcon, Table2Icon } from "../../components/Icons";
5
+ import Menu from "../../components/Menu";
6
+ import { ToolbarItem } from "../../components/Toolbar";
7
+ var menuArrowIcon = /*#__PURE__*/React.createElement(ArrowDownSLineIcon, {
8
+ sx: {
9
+ fontSize: '1rem',
10
+ transform: 'rotate(-90deg)'
11
+ }
12
+ });
13
+ var menuProps = {
14
+ anchorOrigin: {
15
+ vertical: 'bottom',
16
+ horizontal: 'left'
17
+ },
18
+ transformOrigin: {
19
+ vertical: 'top',
20
+ horizontal: 'left'
21
+ }
22
+ };
23
+ var HeadingTrigger = function HeadingTrigger(props) {
24
+ return /*#__PURE__*/React.createElement(ToolbarItem, _extends({}, props, {
25
+ tip: "\u6807\u9898",
26
+ text: /*#__PURE__*/React.createElement(Box, {
27
+ sx: {
28
+ position: 'relative',
29
+ pr: 1
30
+ }
31
+ }, /*#__PURE__*/React.createElement(Box, {
32
+ sx: {
33
+ width: '38px',
34
+ textAlign: 'left'
35
+ }
36
+ }, "\u6807\u9898"), /*#__PURE__*/React.createElement(ArrowDownSLineIcon, {
37
+ sx: {
38
+ position: 'absolute',
39
+ right: -6,
40
+ top: '50%',
41
+ transform: 'translateY(-50%)',
42
+ flexSelf: 'center',
43
+ fontSize: '1rem',
44
+ flexShrink: 0,
45
+ mr: 0,
46
+ color: 'text.disabled',
47
+ cursor: 'pointer',
48
+ pointerEvents: 'none'
49
+ }
50
+ }))
51
+ }));
52
+ };
53
+ var getContext = function getContext(type) {
54
+ if (type === 'insert') {
55
+ return /*#__PURE__*/React.createElement(ToolbarItem, {
56
+ text: "\u63D2\u5165",
57
+ icon: /*#__PURE__*/React.createElement(AddCircleFillIcon, {
58
+ sx: {
59
+ fontSize: '1rem'
60
+ }
61
+ })
62
+ });
63
+ }
64
+ if (type === 'table') {
65
+ return /*#__PURE__*/React.createElement(ToolbarItem, {
66
+ tip: "\u8868\u683C",
67
+ icon: /*#__PURE__*/React.createElement(Table2Icon, {
68
+ sx: {
69
+ fontSize: '1rem'
70
+ }
71
+ })
72
+ });
73
+ }
74
+ return /*#__PURE__*/React.createElement(HeadingTrigger, null);
75
+ };
76
+ var MarkdownToolbarMenu = function MarkdownToolbarMenu(_ref) {
77
+ var type = _ref.type,
78
+ list = _ref.list,
79
+ isExpend = _ref.isExpend;
80
+ return /*#__PURE__*/React.createElement(Menu, _extends({
81
+ context: getContext(type),
82
+ arrowIcon: menuArrowIcon,
83
+ zIndex: isExpend ? 2100 : undefined,
84
+ list: list
85
+ }, menuProps));
86
+ };
87
+ export default MarkdownToolbarMenu;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ interface ToolListItem {
3
+ id: string;
4
+ label?: string;
5
+ icon?: React.ReactNode;
6
+ onClick?: () => void;
7
+ }
8
+ interface MarkdownToolbarToolListProps {
9
+ items: ToolListItem[];
10
+ }
11
+ declare const MarkdownToolbarToolList: ({ items }: MarkdownToolbarToolListProps) => React.JSX.Element;
12
+ export default MarkdownToolbarToolList;
@@ -0,0 +1,24 @@
1
+ import { Divider } from '@mui/material';
2
+ import React from 'react';
3
+ import { ToolbarItem } from "../../components/Toolbar";
4
+ var MarkdownToolbarToolList = function MarkdownToolbarToolList(_ref) {
5
+ var items = _ref.items;
6
+ return /*#__PURE__*/React.createElement(React.Fragment, null, items.map(function (item) {
7
+ return item.id.includes('divider') ? /*#__PURE__*/React.createElement(Divider, {
8
+ key: item.id,
9
+ sx: {
10
+ mx: 0.5,
11
+ height: 20,
12
+ alignSelf: 'center'
13
+ },
14
+ orientation: "vertical",
15
+ flexItem: true
16
+ }) : /*#__PURE__*/React.createElement(ToolbarItem, {
17
+ key: item.id,
18
+ tip: item.label,
19
+ icon: item.icon,
20
+ onClick: item.onClick
21
+ });
22
+ }));
23
+ };
24
+ export default MarkdownToolbarToolList;
@@ -0,0 +1,5 @@
1
+ import React from 'react';
2
+ import AceEditor from 'react-ace';
3
+ export declare const useAceComposition: (aceEditorRef: React.RefObject<AceEditor | null>) => {
4
+ isComposing: boolean;
5
+ };
@@ -0,0 +1,39 @@
1
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
2
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
3
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
4
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
5
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
6
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
7
+ import React from 'react';
8
+ export var useAceComposition = function useAceComposition(aceEditorRef) {
9
+ var _React$useState = React.useState(false),
10
+ _React$useState2 = _slicedToArray(_React$useState, 2),
11
+ isComposing = _React$useState2[0],
12
+ setIsComposing = _React$useState2[1];
13
+ React.useEffect(function () {
14
+ var _aceEditor$textInput;
15
+ if (!aceEditorRef.current) return;
16
+ var aceEditor = aceEditorRef.current.editor;
17
+ var textarea = (_aceEditor$textInput = aceEditor.textInput) === null || _aceEditor$textInput === void 0 ? void 0 : _aceEditor$textInput.getElement();
18
+ if (!textarea) return;
19
+ var handleCompositionStart = function handleCompositionStart() {
20
+ setTimeout(function () {
21
+ return setIsComposing(true);
22
+ }, 0);
23
+ };
24
+ var handleCompositionEnd = function handleCompositionEnd() {
25
+ setTimeout(function () {
26
+ return setIsComposing(false);
27
+ }, 0);
28
+ };
29
+ textarea.addEventListener('compositionstart', handleCompositionStart);
30
+ textarea.addEventListener('compositionend', handleCompositionEnd);
31
+ return function () {
32
+ textarea.removeEventListener('compositionstart', handleCompositionStart);
33
+ textarea.removeEventListener('compositionend', handleCompositionEnd);
34
+ };
35
+ }, [aceEditorRef]);
36
+ return {
37
+ isComposing: isComposing
38
+ };
39
+ };
@@ -0,0 +1,8 @@
1
+ import React from 'react';
2
+ export type DisplayMode = 'edit' | 'preview' | 'split';
3
+ export declare const useDisplayMode: (defaultDisplayMode: DisplayMode) => {
4
+ displayMode: DisplayMode;
5
+ setDisplayMode: React.Dispatch<React.SetStateAction<DisplayMode>>;
6
+ isExpend: boolean;
7
+ toggleExpand: () => void;
8
+ };
@@ -0,0 +1,28 @@
1
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
2
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
3
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
4
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
5
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
6
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
7
+ import React from 'react';
8
+ export var useDisplayMode = function useDisplayMode(defaultDisplayMode) {
9
+ var _React$useState = React.useState(defaultDisplayMode),
10
+ _React$useState2 = _slicedToArray(_React$useState, 2),
11
+ displayMode = _React$useState2[0],
12
+ setDisplayMode = _React$useState2[1];
13
+ var _React$useState3 = React.useState(false),
14
+ _React$useState4 = _slicedToArray(_React$useState3, 2),
15
+ isExpend = _React$useState4[0],
16
+ setIsExpend = _React$useState4[1];
17
+ var toggleExpand = React.useCallback(function () {
18
+ setIsExpend(function (previous) {
19
+ return !previous;
20
+ });
21
+ }, []);
22
+ return {
23
+ displayMode: displayMode,
24
+ setDisplayMode: setDisplayMode,
25
+ isExpend: isExpend,
26
+ toggleExpand: toggleExpand
27
+ };
28
+ };
@@ -0,0 +1,10 @@
1
+ import React from 'react';
2
+ import { MarkdownUploadType } from './use-markdown-upload';
3
+ interface UseMarkdownFileInputsProps {
4
+ onFileUpload: (file: File, expectedType?: MarkdownUploadType) => void;
5
+ }
6
+ export declare const useMarkdownFileInputs: ({ onFileUpload }: UseMarkdownFileInputsProps) => {
7
+ inputs: React.JSX.Element;
8
+ openPicker: (type: MarkdownUploadType) => void;
9
+ };
10
+ export {};
@@ -0,0 +1,69 @@
1
+ import React from 'react';
2
+ export var useMarkdownFileInputs = function useMarkdownFileInputs(_ref) {
3
+ var onFileUpload = _ref.onFileUpload;
4
+ var imageInputRef = React.useRef(null);
5
+ var videoInputRef = React.useRef(null);
6
+ var audioInputRef = React.useRef(null);
7
+ var attachmentInputRef = React.useRef(null);
8
+ var handleFileSelect = React.useCallback(function (event, expectedType) {
9
+ var _event$target$files;
10
+ var file = (_event$target$files = event.target.files) === null || _event$target$files === void 0 ? void 0 : _event$target$files[0];
11
+ if (file) {
12
+ onFileUpload(file, expectedType);
13
+ }
14
+ event.target.value = '';
15
+ }, [onFileUpload]);
16
+ var openPicker = React.useCallback(function (type) {
17
+ var _imageInputRef$curren, _videoInputRef$curren, _audioInputRef$curren, _attachmentInputRef$c;
18
+ if (type === 'image') (_imageInputRef$curren = imageInputRef.current) === null || _imageInputRef$curren === void 0 || _imageInputRef$curren.click();
19
+ if (type === 'video') (_videoInputRef$curren = videoInputRef.current) === null || _videoInputRef$curren === void 0 || _videoInputRef$curren.click();
20
+ if (type === 'audio') (_audioInputRef$curren = audioInputRef.current) === null || _audioInputRef$curren === void 0 || _audioInputRef$curren.click();
21
+ if (type === 'attachment') (_attachmentInputRef$c = attachmentInputRef.current) === null || _attachmentInputRef$c === void 0 || _attachmentInputRef$c.click();
22
+ }, []);
23
+ var inputs = React.useMemo(function () {
24
+ return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("input", {
25
+ ref: imageInputRef,
26
+ type: "file",
27
+ accept: "image/*",
28
+ style: {
29
+ display: 'none'
30
+ },
31
+ onChange: function onChange(event) {
32
+ return handleFileSelect(event, 'image');
33
+ }
34
+ }), /*#__PURE__*/React.createElement("input", {
35
+ ref: videoInputRef,
36
+ type: "file",
37
+ accept: "video/*",
38
+ style: {
39
+ display: 'none'
40
+ },
41
+ onChange: function onChange(event) {
42
+ return handleFileSelect(event, 'video');
43
+ }
44
+ }), /*#__PURE__*/React.createElement("input", {
45
+ ref: audioInputRef,
46
+ type: "file",
47
+ accept: "audio/*",
48
+ style: {
49
+ display: 'none'
50
+ },
51
+ onChange: function onChange(event) {
52
+ return handleFileSelect(event, 'audio');
53
+ }
54
+ }), /*#__PURE__*/React.createElement("input", {
55
+ ref: attachmentInputRef,
56
+ type: "file",
57
+ style: {
58
+ display: 'none'
59
+ },
60
+ onChange: function onChange(event) {
61
+ return handleFileSelect(event, 'attachment');
62
+ }
63
+ }));
64
+ }, [handleFileSelect]);
65
+ return {
66
+ inputs: inputs,
67
+ openPicker: openPicker
68
+ };
69
+ };
@@ -0,0 +1,13 @@
1
+ import { Editor } from '@tiptap/core';
2
+ type UseMarkdownSyncProps = {
3
+ editor: Editor;
4
+ value?: string;
5
+ onAceChange?: (value: string) => void;
6
+ onTiptapChange?: (value: string) => void;
7
+ };
8
+ export declare const useMarkdownSync: ({ editor, value, onAceChange, onTiptapChange, }: UseMarkdownSyncProps) => {
9
+ markdownValue: string;
10
+ setMarkdownValue: (nextValue: string) => void;
11
+ handleMarkdownChange: (nextValue: string) => void;
12
+ };
13
+ export {};
@@ -0,0 +1,56 @@
1
+ function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
2
+ function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
3
+ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
4
+ function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
5
+ function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
6
+ function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
7
+ import React, { useEffect, useMemo, useRef, useState } from 'react';
8
+ export var useMarkdownSync = function useMarkdownSync(_ref) {
9
+ var editor = _ref.editor,
10
+ value = _ref.value,
11
+ onAceChange = _ref.onAceChange,
12
+ onTiptapChange = _ref.onTiptapChange;
13
+ var initialMarkdown = useMemo(function () {
14
+ var _ref2, _editor$getMarkdown;
15
+ return (_ref2 = value !== null && value !== void 0 ? value : (_editor$getMarkdown = editor.getMarkdown) === null || _editor$getMarkdown === void 0 ? void 0 : _editor$getMarkdown.call(editor)) !== null && _ref2 !== void 0 ? _ref2 : '';
16
+ }, [editor, value]);
17
+ var syncedMarkdownRef = useRef(initialMarkdown);
18
+ var _useState = useState(initialMarkdown),
19
+ _useState2 = _slicedToArray(_useState, 2),
20
+ markdownValue = _useState2[0],
21
+ setMarkdownValue = _useState2[1];
22
+ var updateMarkdownValue = React.useCallback(function (nextValue) {
23
+ syncedMarkdownRef.current = nextValue;
24
+ setMarkdownValue(nextValue);
25
+ }, []);
26
+ var handleMarkdownChange = React.useCallback(function (nextValue) {
27
+ updateMarkdownValue(nextValue);
28
+ onAceChange === null || onAceChange === void 0 || onAceChange(nextValue);
29
+ onTiptapChange === null || onTiptapChange === void 0 || onTiptapChange(nextValue);
30
+ editor.commands.setContent(nextValue, {
31
+ contentType: 'markdown'
32
+ });
33
+ }, [editor, onAceChange, onTiptapChange, updateMarkdownValue]);
34
+ useEffect(function () {
35
+ if (value === undefined || value === syncedMarkdownRef.current) {
36
+ return;
37
+ }
38
+ updateMarkdownValue(value);
39
+ editor.commands.setContent(value, {
40
+ contentType: 'markdown'
41
+ });
42
+ }, [editor, updateMarkdownValue, value]);
43
+ useEffect(function () {
44
+ var _editor$getMarkdown2, _editor$getMarkdown3;
45
+ if (value !== undefined) {
46
+ return;
47
+ }
48
+ var nextMarkdown = (_editor$getMarkdown2 = (_editor$getMarkdown3 = editor.getMarkdown) === null || _editor$getMarkdown3 === void 0 ? void 0 : _editor$getMarkdown3.call(editor)) !== null && _editor$getMarkdown2 !== void 0 ? _editor$getMarkdown2 : '';
49
+ updateMarkdownValue(nextMarkdown);
50
+ }, [editor, updateMarkdownValue, value]);
51
+ return {
52
+ markdownValue: markdownValue,
53
+ setMarkdownValue: updateMarkdownValue,
54
+ handleMarkdownChange: handleMarkdownChange
55
+ };
56
+ };
@@ -0,0 +1,18 @@
1
+ import React from 'react';
2
+ import { MarkdownUploadType } from './use-markdown-upload';
3
+ export declare const useMarkdownTransfer: ({ aceEditorRef, displayMode, loading, readOnly, onFileUpload, }: {
4
+ aceEditorRef: React.RefObject<{
5
+ editor: {
6
+ focus: () => void;
7
+ };
8
+ } | null>;
9
+ displayMode: 'edit' | 'preview' | 'split';
10
+ loading: boolean;
11
+ readOnly: boolean;
12
+ onFileUpload: (file: File, expectedType?: MarkdownUploadType) => Promise<void>;
13
+ }) => {
14
+ handlePaste: (event: React.ClipboardEvent) => Promise<void>;
15
+ handleDragOver: (event: React.DragEvent) => void;
16
+ handleDragLeave: (event: React.DragEvent) => void;
17
+ handleDrop: (event: React.DragEvent) => Promise<void>;
18
+ };
@@ -0,0 +1,123 @@
1
+ function _typeof(o) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o; }, _typeof(o); }
2
+ function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = "function" == typeof Symbol ? Symbol : {}, a = i.iterator || "@@iterator", c = i.asyncIterator || "@@asyncIterator", u = i.toStringTag || "@@toStringTag"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, ""); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, "_invoke", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: "normal", arg: t.call(e, r) }; } catch (t) { return { type: "throw", arg: t }; } } e.wrap = wrap; var h = "suspendedStart", l = "suspendedYield", f = "executing", s = "completed", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { ["next", "throw", "return"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if ("throw" !== c.type) { var u = c.arg, h = u.value; return h && "object" == _typeof(h) && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) { invoke("next", t, i, a); }, function (t) { invoke("throw", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke("throw", t, i, a); }); } a(c.arg); } var r; o(this, "_invoke", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw new Error("Generator is already running"); if (o === s) { if ("throw" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else "return" === n.method && n.abrupt("return", n.arg); o = f; var p = tryCatch(e, r, n); if ("normal" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y; var i = tryCatch(o, e.iterator, r.arg); if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = "normal", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: "root" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || "" === e) { var r = e[a]; if (r) return r.call(e); if ("function" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + " is not iterable"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) { var e = "function" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () { return this; }), define(g, "toString", function () { return "[object Generator]"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if ("throw" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if ("root" === i.tryLoc) return handle("end"); if (i.tryLoc <= this.prev) { var c = n.call(i, "catchLoc"), u = n.call(i, "finallyLoc"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw new Error("try statement without catch or finally"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) { var i = o; break; } } i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if ("throw" === t.type) throw t.arg; return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, catch: function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if ("throw" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, "next" === this.method && (this.arg = t), y; } }, e; }
3
+ function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
4
+ function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
5
+ import React from 'react';
6
+ import { getFileType } from "../../utils";
7
+ var toMarkdownUploadType = function toMarkdownUploadType(file) {
8
+ var fileType = getFileType(file);
9
+ if (fileType === 'other') {
10
+ return 'attachment';
11
+ }
12
+ return fileType;
13
+ };
14
+ export var useMarkdownTransfer = function useMarkdownTransfer(_ref) {
15
+ var aceEditorRef = _ref.aceEditorRef,
16
+ displayMode = _ref.displayMode,
17
+ loading = _ref.loading,
18
+ readOnly = _ref.readOnly,
19
+ onFileUpload = _ref.onFileUpload;
20
+ var canHandleTransfer = React.useMemo(function () {
21
+ return ['edit', 'split'].includes(displayMode) && !loading && !readOnly;
22
+ }, [displayMode, loading, readOnly]);
23
+ var handlePaste = React.useCallback( /*#__PURE__*/function () {
24
+ var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(event) {
25
+ var items, imageItem, file;
26
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
27
+ while (1) switch (_context.prev = _context.next) {
28
+ case 0:
29
+ if (canHandleTransfer) {
30
+ _context.next = 2;
31
+ break;
32
+ }
33
+ return _context.abrupt("return");
34
+ case 2:
35
+ items = Array.from(event.clipboardData.items);
36
+ imageItem = items.find(function (item) {
37
+ return item.type.includes('image');
38
+ });
39
+ if (imageItem) {
40
+ _context.next = 6;
41
+ break;
42
+ }
43
+ return _context.abrupt("return");
44
+ case 6:
45
+ event.preventDefault();
46
+ file = imageItem.getAsFile();
47
+ if (!file) {
48
+ _context.next = 11;
49
+ break;
50
+ }
51
+ _context.next = 11;
52
+ return onFileUpload(file, 'image');
53
+ case 11:
54
+ case "end":
55
+ return _context.stop();
56
+ }
57
+ }, _callee);
58
+ }));
59
+ return function (_x) {
60
+ return _ref2.apply(this, arguments);
61
+ };
62
+ }(), [canHandleTransfer, onFileUpload]);
63
+ var handleDragOver = React.useCallback(function (event) {
64
+ if (!canHandleTransfer) {
65
+ return;
66
+ }
67
+ event.preventDefault();
68
+ event.stopPropagation();
69
+ }, [canHandleTransfer]);
70
+ var handleDragLeave = React.useCallback(function (event) {
71
+ if (!canHandleTransfer) {
72
+ return;
73
+ }
74
+ event.preventDefault();
75
+ event.stopPropagation();
76
+ }, [canHandleTransfer]);
77
+ var handleDrop = React.useCallback( /*#__PURE__*/function () {
78
+ var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee2(event) {
79
+ var _aceEditorRef$current;
80
+ var files, _i, _files, _file;
81
+ return _regeneratorRuntime().wrap(function _callee2$(_context2) {
82
+ while (1) switch (_context2.prev = _context2.next) {
83
+ case 0:
84
+ if (canHandleTransfer) {
85
+ _context2.next = 2;
86
+ break;
87
+ }
88
+ return _context2.abrupt("return");
89
+ case 2:
90
+ event.preventDefault();
91
+ event.stopPropagation();
92
+ (_aceEditorRef$current = aceEditorRef.current) === null || _aceEditorRef$current === void 0 || _aceEditorRef$current.editor.focus();
93
+ files = Array.from(event.dataTransfer.files);
94
+ _i = 0, _files = files;
95
+ case 7:
96
+ if (!(_i < _files.length)) {
97
+ _context2.next = 14;
98
+ break;
99
+ }
100
+ _file = _files[_i];
101
+ _context2.next = 11;
102
+ return onFileUpload(_file, toMarkdownUploadType(_file));
103
+ case 11:
104
+ _i++;
105
+ _context2.next = 7;
106
+ break;
107
+ case 14:
108
+ case "end":
109
+ return _context2.stop();
110
+ }
111
+ }, _callee2);
112
+ }));
113
+ return function (_x2) {
114
+ return _ref3.apply(this, arguments);
115
+ };
116
+ }(), [aceEditorRef, canHandleTransfer, onFileUpload]);
117
+ return {
118
+ handlePaste: handlePaste,
119
+ handleDragOver: handleDragOver,
120
+ handleDragLeave: handleDragLeave,
121
+ handleDrop: handleDrop
122
+ };
123
+ };
@@ -0,0 +1,13 @@
1
+ import React from 'react';
2
+ import AceEditor from 'react-ace';
3
+ import { UploadFunction } from '../../types';
4
+ export type MarkdownUploadType = 'image' | 'video' | 'audio' | 'attachment';
5
+ export declare const useMarkdownUpload: ({ aceEditorRef, onUpload, }: {
6
+ aceEditorRef: React.RefObject<AceEditor | null>;
7
+ onUpload?: UploadFunction | undefined;
8
+ }) => {
9
+ loading: boolean;
10
+ progress: number;
11
+ fileName: string;
12
+ handleFileUpload: (file: File, expectedType?: MarkdownUploadType) => Promise<void>;
13
+ };