phx-react 1.3.1570 → 1.3.1572

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 (885) hide show
  1. package/dist/cjs/components/MainWrapV4/components/notification/component/HtmlIFrame.d.ts +2 -2
  2. package/dist/cjs/components/MainWrapV4/components/notification/component/HtmlIFrame.js +15 -14
  3. package/dist/cjs/components/MainWrapV4/components/notification/component/HtmlIFrame.js.map +1 -1
  4. package/dist/cjs/components/MainWrapV4/components/notification/component/NotiDropdown.js +7 -6
  5. package/dist/cjs/components/MainWrapV4/components/notification/component/NotiDropdown.js.map +1 -1
  6. package/dist/cjs/components/MainWrapV4/components/notification/component/NotiHeader.js +1 -1
  7. package/dist/cjs/components/MainWrapV4/components/notification/component/NotiHeader.js.map +1 -1
  8. package/dist/cjs/components/MainWrapV4/components/notification/component/NotiListPane.d.ts +3 -4
  9. package/dist/cjs/components/MainWrapV4/components/notification/component/NotiListPane.js +18 -8
  10. package/dist/cjs/components/MainWrapV4/components/notification/component/NotiListPane.js.map +1 -1
  11. package/dist/cjs/components/MainWrapV4/components/notification/component/NotiPreviewPane.d.ts +1 -4
  12. package/dist/cjs/components/MainWrapV4/components/notification/component/NotiPreviewPane.js +3 -39
  13. package/dist/cjs/components/MainWrapV4/components/notification/component/NotiPreviewPane.js.map +1 -1
  14. package/dist/cjs/components/MainWrapV4/components/notification/hook/useNotificationData.d.ts +1 -1
  15. package/dist/cjs/components/MainWrapV4/components/notification/hook/useNotificationData.js +1 -1
  16. package/dist/cjs/components/MainWrapV4/components/notification/hook/useNotificationData.js.map +1 -1
  17. package/dist/cjs/components/MainWrapV4/components/notification/index.js +8 -2
  18. package/dist/cjs/components/MainWrapV4/components/notification/index.js.map +1 -1
  19. package/dist/cjs/components/MainWrapV4/types/notification.d.ts +0 -1
  20. package/dist/cjs/components/TextEditorV2/commenting/index.d.ts +41 -0
  21. package/dist/cjs/components/TextEditorV2/commenting/index.js +340 -0
  22. package/dist/cjs/components/TextEditorV2/commenting/index.js.map +1 -0
  23. package/dist/cjs/components/TextEditorV2/constants.d.ts +1 -0
  24. package/dist/cjs/components/TextEditorV2/constants.js +5 -0
  25. package/dist/cjs/components/TextEditorV2/constants.js.map +1 -0
  26. package/dist/cjs/components/TextEditorV2/context/SettingsContext.d.ts +12 -0
  27. package/dist/cjs/components/TextEditorV2/context/SettingsContext.js +59 -0
  28. package/dist/cjs/components/TextEditorV2/context/SettingsContext.js.map +1 -0
  29. package/dist/cjs/components/TextEditorV2/context/SharedAutocompleteContext.d.ts +10 -0
  30. package/dist/cjs/components/TextEditorV2/context/SharedAutocompleteContext.js +50 -0
  31. package/dist/cjs/components/TextEditorV2/context/SharedAutocompleteContext.js.map +1 -0
  32. package/dist/cjs/components/TextEditorV2/context/SharedHistoryContext.d.ts +11 -0
  33. package/dist/cjs/components/TextEditorV2/context/SharedHistoryContext.js +17 -0
  34. package/dist/cjs/components/TextEditorV2/context/SharedHistoryContext.js.map +1 -0
  35. package/dist/cjs/components/TextEditorV2/editor.d.ts +10 -0
  36. package/dist/cjs/components/TextEditorV2/editor.js +203 -0
  37. package/dist/cjs/components/TextEditorV2/editor.js.map +1 -0
  38. package/dist/cjs/components/TextEditorV2/hooks/useModal.d.ts +5 -0
  39. package/dist/cjs/components/TextEditorV2/hooks/useModal.js +32 -0
  40. package/dist/cjs/components/TextEditorV2/hooks/useModal.js.map +1 -0
  41. package/dist/cjs/components/TextEditorV2/hooks/useReport.d.ts +1 -0
  42. package/dist/cjs/components/TextEditorV2/hooks/useReport.js +45 -0
  43. package/dist/cjs/components/TextEditorV2/hooks/useReport.js.map +1 -0
  44. package/dist/cjs/components/TextEditorV2/lib/Settings.d.ts +2 -0
  45. package/dist/cjs/components/TextEditorV2/lib/Settings.js +52 -0
  46. package/dist/cjs/components/TextEditorV2/lib/Settings.js.map +1 -0
  47. package/dist/cjs/components/TextEditorV2/lib/appSettings.d.ts +19 -0
  48. package/dist/cjs/components/TextEditorV2/lib/appSettings.js +21 -0
  49. package/dist/cjs/components/TextEditorV2/lib/appSettings.js.map +1 -0
  50. package/dist/cjs/components/TextEditorV2/lib/collaboration.d.ts +3 -0
  51. package/dist/cjs/components/TextEditorV2/lib/collaboration.js +26 -0
  52. package/dist/cjs/components/TextEditorV2/lib/collaboration.js.map +1 -0
  53. package/dist/cjs/components/TextEditorV2/lib/setupEnv.d.ts +1 -0
  54. package/dist/cjs/components/TextEditorV2/lib/setupEnv.js +23 -0
  55. package/dist/cjs/components/TextEditorV2/lib/setupEnv.js.map +1 -0
  56. package/dist/cjs/components/TextEditorV2/nodes/AutocompleteNode.d.ts +25 -0
  57. package/dist/cjs/components/TextEditorV2/nodes/AutocompleteNode.js +58 -0
  58. package/dist/cjs/components/TextEditorV2/nodes/AutocompleteNode.js.map +1 -0
  59. package/dist/cjs/components/TextEditorV2/nodes/EmojiNode.d.ts +18 -0
  60. package/dist/cjs/components/TextEditorV2/nodes/EmojiNode.js +62 -0
  61. package/dist/cjs/components/TextEditorV2/nodes/EmojiNode.js.map +1 -0
  62. package/dist/cjs/components/TextEditorV2/nodes/EquationComponent.d.ts +9 -0
  63. package/dist/cjs/components/TextEditorV2/nodes/EquationComponent.js +72 -0
  64. package/dist/cjs/components/TextEditorV2/nodes/EquationComponent.js.map +1 -0
  65. package/dist/cjs/components/TextEditorV2/nodes/EquationNode.d.ts +26 -0
  66. package/dist/cjs/components/TextEditorV2/nodes/EquationNode.js +126 -0
  67. package/dist/cjs/components/TextEditorV2/nodes/EquationNode.js.map +1 -0
  68. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.d.ts +6 -0
  69. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.js +117 -0
  70. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.js.map +1 -0
  71. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.d.ts +50 -0
  72. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.js +59 -0
  73. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.js.map +1 -0
  74. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.d.ts +44 -0
  75. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.js +143 -0
  76. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.js.map +1 -0
  77. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/index.d.ts +22 -0
  78. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/index.js +103 -0
  79. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/index.js.map +1 -0
  80. package/dist/cjs/components/TextEditorV2/nodes/ExtendedTextNode.d.ts +12 -0
  81. package/dist/cjs/components/TextEditorV2/nodes/ExtendedTextNode.js +106 -0
  82. package/dist/cjs/components/TextEditorV2/nodes/ExtendedTextNode.js.map +1 -0
  83. package/dist/cjs/components/TextEditorV2/nodes/FigmaNode.d.ts +19 -0
  84. package/dist/cjs/components/TextEditorV2/nodes/FigmaNode.js +63 -0
  85. package/dist/cjs/components/TextEditorV2/nodes/FigmaNode.js.map +1 -0
  86. package/dist/cjs/components/TextEditorV2/nodes/ImageComponent.d.ts +14 -0
  87. package/dist/cjs/components/TextEditorV2/nodes/ImageComponent.js +212 -0
  88. package/dist/cjs/components/TextEditorV2/nodes/ImageComponent.js.map +1 -0
  89. package/dist/cjs/components/TextEditorV2/nodes/ImageNode.d.ts +56 -0
  90. package/dist/cjs/components/TextEditorV2/nodes/ImageNode.js +136 -0
  91. package/dist/cjs/components/TextEditorV2/nodes/ImageNode.js.map +1 -0
  92. package/dist/cjs/components/TextEditorV2/nodes/InlineImageComponent.d.ts +18 -0
  93. package/dist/cjs/components/TextEditorV2/nodes/InlineImageComponent.js +194 -0
  94. package/dist/cjs/components/TextEditorV2/nodes/InlineImageComponent.js.map +1 -0
  95. package/dist/cjs/components/TextEditorV2/nodes/InlineImageNode.d.ts +54 -0
  96. package/dist/cjs/components/TextEditorV2/nodes/InlineImageNode.js +142 -0
  97. package/dist/cjs/components/TextEditorV2/nodes/InlineImageNode.js.map +1 -0
  98. package/dist/cjs/components/TextEditorV2/nodes/KeywordNode.d.ts +15 -0
  99. package/dist/cjs/components/TextEditorV2/nodes/KeywordNode.js +54 -0
  100. package/dist/cjs/components/TextEditorV2/nodes/KeywordNode.js.map +1 -0
  101. package/dist/cjs/components/TextEditorV2/nodes/LayoutContainerNode.d.ts +21 -0
  102. package/dist/cjs/components/TextEditorV2/nodes/LayoutContainerNode.js +63 -0
  103. package/dist/cjs/components/TextEditorV2/nodes/LayoutContainerNode.js.map +1 -0
  104. package/dist/cjs/components/TextEditorV2/nodes/LayoutItemNode.d.ts +15 -0
  105. package/dist/cjs/components/TextEditorV2/nodes/LayoutItemNode.js +51 -0
  106. package/dist/cjs/components/TextEditorV2/nodes/LayoutItemNode.js.map +1 -0
  107. package/dist/cjs/components/TextEditorV2/nodes/MentionNode.d.ts +20 -0
  108. package/dist/cjs/components/TextEditorV2/nodes/MentionNode.js +89 -0
  109. package/dist/cjs/components/TextEditorV2/nodes/MentionNode.js.map +1 -0
  110. package/dist/cjs/components/TextEditorV2/nodes/PageBreakNode/index.d.ts +17 -0
  111. package/dist/cjs/components/TextEditorV2/nodes/PageBreakNode/index.js +113 -0
  112. package/dist/cjs/components/TextEditorV2/nodes/PageBreakNode/index.js.map +1 -0
  113. package/dist/cjs/components/TextEditorV2/nodes/PlaygroundNodes.d.ts +3 -0
  114. package/dist/cjs/components/TextEditorV2/nodes/PlaygroundNodes.js +68 -0
  115. package/dist/cjs/components/TextEditorV2/nodes/PlaygroundNodes.js.map +1 -0
  116. package/dist/cjs/components/TextEditorV2/nodes/PollComponent.d.ts +8 -0
  117. package/dist/cjs/components/TextEditorV2/nodes/PollComponent.js +113 -0
  118. package/dist/cjs/components/TextEditorV2/nodes/PollComponent.js.map +1 -0
  119. package/dist/cjs/components/TextEditorV2/nodes/PollNode.d.ts +33 -0
  120. package/dist/cjs/components/TextEditorV2/nodes/PollNode.js +149 -0
  121. package/dist/cjs/components/TextEditorV2/nodes/PollNode.js.map +1 -0
  122. package/dist/cjs/components/TextEditorV2/nodes/StickyComponent.d.ts +9 -0
  123. package/dist/cjs/components/TextEditorV2/nodes/StickyComponent.js +167 -0
  124. package/dist/cjs/components/TextEditorV2/nodes/StickyComponent.js.map +1 -0
  125. package/dist/cjs/components/TextEditorV2/nodes/StickyNode.d.ts +37 -0
  126. package/dist/cjs/components/TextEditorV2/nodes/StickyNode.js +94 -0
  127. package/dist/cjs/components/TextEditorV2/nodes/StickyNode.js.map +1 -0
  128. package/dist/cjs/components/TextEditorV2/nodes/TableNode.d.ts +54 -0
  129. package/dist/cjs/components/TextEditorV2/nodes/TableNode.js +198 -0
  130. package/dist/cjs/components/TextEditorV2/nodes/TableNode.js.map +1 -0
  131. package/dist/cjs/components/TextEditorV2/nodes/TweetNode.d.ts +28 -0
  132. package/dist/cjs/components/TextEditorV2/nodes/TweetNode.js +156 -0
  133. package/dist/cjs/components/TextEditorV2/nodes/TweetNode.js.map +1 -0
  134. package/dist/cjs/components/TextEditorV2/nodes/YouTubeNode.d.ts +28 -0
  135. package/dist/cjs/components/TextEditorV2/nodes/YouTubeNode.js +103 -0
  136. package/dist/cjs/components/TextEditorV2/nodes/YouTubeNode.js.map +1 -0
  137. package/dist/cjs/components/TextEditorV2/plugins/ActionsPlugin/index.d.ts +2 -0
  138. package/dist/cjs/components/TextEditorV2/plugins/ActionsPlugin/index.js +183 -0
  139. package/dist/cjs/components/TextEditorV2/plugins/ActionsPlugin/index.js.map +1 -0
  140. package/dist/cjs/components/TextEditorV2/plugins/AutoEmbedPlugin/index.d.ts +19 -0
  141. package/dist/cjs/components/TextEditorV2/plugins/AutoEmbedPlugin/index.js +179 -0
  142. package/dist/cjs/components/TextEditorV2/plugins/AutoEmbedPlugin/index.js.map +1 -0
  143. package/dist/cjs/components/TextEditorV2/plugins/AutoLinkPlugin/index.d.ts +2 -0
  144. package/dist/cjs/components/TextEditorV2/plugins/AutoLinkPlugin/index.js +16 -0
  145. package/dist/cjs/components/TextEditorV2/plugins/AutoLinkPlugin/index.js.map +1 -0
  146. package/dist/cjs/components/TextEditorV2/plugins/AutocompletePlugin/index.d.ts +2 -0
  147. package/dist/cjs/components/TextEditorV2/plugins/AutocompletePlugin/index.js +2465 -0
  148. package/dist/cjs/components/TextEditorV2/plugins/AutocompletePlugin/index.js.map +1 -0
  149. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.d.ts +8 -0
  150. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.js +55 -0
  151. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.js.map +1 -0
  152. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.d.ts +10 -0
  153. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.js +159 -0
  154. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.js.map +1 -0
  155. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.d.ts +4 -0
  156. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.js +111 -0
  157. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.js.map +1 -0
  158. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.d.ts +1 -0
  159. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.js +21 -0
  160. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.js.map +1 -0
  161. package/dist/cjs/components/TextEditorV2/plugins/CodeHighlightPlugin/index.d.ts +1 -0
  162. package/dist/cjs/components/TextEditorV2/plugins/CodeHighlightPlugin/index.js +12 -0
  163. package/dist/cjs/components/TextEditorV2/plugins/CodeHighlightPlugin/index.js.map +1 -0
  164. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.d.ts +23 -0
  165. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.js +88 -0
  166. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.js.map +1 -0
  167. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.d.ts +17 -0
  168. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.js +70 -0
  169. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.js.map +1 -0
  170. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.d.ts +18 -0
  171. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.js +95 -0
  172. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.js.map +1 -0
  173. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/index.d.ts +3 -0
  174. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/index.js +148 -0
  175. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/index.js.map +1 -0
  176. package/dist/cjs/components/TextEditorV2/plugins/ComponentPickerPlugin/index.d.ts +2 -0
  177. package/dist/cjs/components/TextEditorV2/plugins/ComponentPickerPlugin/index.js +264 -0
  178. package/dist/cjs/components/TextEditorV2/plugins/ComponentPickerPlugin/index.js.map +1 -0
  179. package/dist/cjs/components/TextEditorV2/plugins/ContextMenuPlugin/index.d.ts +11 -0
  180. package/dist/cjs/components/TextEditorV2/plugins/ContextMenuPlugin/index.js +171 -0
  181. package/dist/cjs/components/TextEditorV2/plugins/ContextMenuPlugin/index.js.map +1 -0
  182. package/dist/cjs/components/TextEditorV2/plugins/DocsPlugin/index.d.ts +2 -0
  183. package/dist/cjs/components/TextEditorV2/plugins/DocsPlugin/index.js +10 -0
  184. package/dist/cjs/components/TextEditorV2/plugins/DocsPlugin/index.js.map +1 -0
  185. package/dist/cjs/components/TextEditorV2/plugins/DragDropPastePlugin/index.d.ts +1 -0
  186. package/dist/cjs/components/TextEditorV2/plugins/DragDropPastePlugin/index.js +44 -0
  187. package/dist/cjs/components/TextEditorV2/plugins/DragDropPastePlugin/index.js.map +1 -0
  188. package/dist/cjs/components/TextEditorV2/plugins/DraggableBlockPlugin/index.d.ts +4 -0
  189. package/dist/cjs/components/TextEditorV2/plugins/DraggableBlockPlugin/index.js +288 -0
  190. package/dist/cjs/components/TextEditorV2/plugins/DraggableBlockPlugin/index.js.map +1 -0
  191. package/dist/cjs/components/TextEditorV2/plugins/EmojiPickerPlugin/index.d.ts +2 -0
  192. package/dist/cjs/components/TextEditorV2/plugins/EmojiPickerPlugin/index.js +97 -0
  193. package/dist/cjs/components/TextEditorV2/plugins/EmojiPickerPlugin/index.js.map +1 -0
  194. package/dist/cjs/components/TextEditorV2/plugins/EmojisPlugin/index.d.ts +1 -0
  195. package/dist/cjs/components/TextEditorV2/plugins/EmojisPlugin/index.js +64 -0
  196. package/dist/cjs/components/TextEditorV2/plugins/EmojisPlugin/index.js.map +1 -0
  197. package/dist/cjs/components/TextEditorV2/plugins/EquationsPlugin/index.d.ts +14 -0
  198. package/dist/cjs/components/TextEditorV2/plugins/EquationsPlugin/index.js +42 -0
  199. package/dist/cjs/components/TextEditorV2/plugins/EquationsPlugin/index.js.map +1 -0
  200. package/dist/cjs/components/TextEditorV2/plugins/ExcalidrawPlugin/index.d.ts +3 -0
  201. package/dist/cjs/components/TextEditorV2/plugins/ExcalidrawPlugin/index.js +28 -0
  202. package/dist/cjs/components/TextEditorV2/plugins/ExcalidrawPlugin/index.js.map +1 -0
  203. package/dist/cjs/components/TextEditorV2/plugins/FigmaPlugin/index.d.ts +3 -0
  204. package/dist/cjs/components/TextEditorV2/plugins/FigmaPlugin/index.js +25 -0
  205. package/dist/cjs/components/TextEditorV2/plugins/FigmaPlugin/index.js.map +1 -0
  206. package/dist/cjs/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.d.ts +7 -0
  207. package/dist/cjs/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.js +200 -0
  208. package/dist/cjs/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.js.map +1 -0
  209. package/dist/cjs/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.d.ts +4 -0
  210. package/dist/cjs/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.js +229 -0
  211. package/dist/cjs/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.js.map +1 -0
  212. package/dist/cjs/components/TextEditorV2/plugins/ImagesPlugin/index.d.ts +22 -0
  213. package/dist/cjs/components/TextEditorV2/plugins/ImagesPlugin/index.js +188 -0
  214. package/dist/cjs/components/TextEditorV2/plugins/ImagesPlugin/index.js.map +1 -0
  215. package/dist/cjs/components/TextEditorV2/plugins/InlineImagePlugin/index.d.ts +17 -0
  216. package/dist/cjs/components/TextEditorV2/plugins/InlineImagePlugin/index.js +193 -0
  217. package/dist/cjs/components/TextEditorV2/plugins/InlineImagePlugin/index.js.map +1 -0
  218. package/dist/cjs/components/TextEditorV2/plugins/KeywordsPlugin/index.d.ts +1 -0
  219. package/dist/cjs/components/TextEditorV2/plugins/KeywordsPlugin/index.js +33 -0
  220. package/dist/cjs/components/TextEditorV2/plugins/KeywordsPlugin/index.js.map +1 -0
  221. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.d.ts +6 -0
  222. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.js +34 -0
  223. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.js.map +1 -0
  224. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.d.ts +7 -0
  225. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.js +89 -0
  226. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.js.map +1 -0
  227. package/dist/cjs/components/TextEditorV2/plugins/LinkPlugin/index.d.ts +2 -0
  228. package/dist/cjs/components/TextEditorV2/plugins/LinkPlugin/index.js +11 -0
  229. package/dist/cjs/components/TextEditorV2/plugins/LinkPlugin/index.js.map +1 -0
  230. package/dist/cjs/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.d.ts +5 -0
  231. package/dist/cjs/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.js +44 -0
  232. package/dist/cjs/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.js.map +1 -0
  233. package/dist/cjs/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.d.ts +2 -0
  234. package/dist/cjs/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.js +11 -0
  235. package/dist/cjs/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.js.map +1 -0
  236. package/dist/cjs/components/TextEditorV2/plugins/MarkdownTransformers/index.d.ts +8 -0
  237. package/dist/cjs/components/TextEditorV2/plugins/MarkdownTransformers/index.js +242 -0
  238. package/dist/cjs/components/TextEditorV2/plugins/MarkdownTransformers/index.js.map +1 -0
  239. package/dist/cjs/components/TextEditorV2/plugins/MaxLengthPlugin/index.d.ts +3 -0
  240. package/dist/cjs/components/TextEditorV2/plugins/MaxLengthPlugin/index.js +41 -0
  241. package/dist/cjs/components/TextEditorV2/plugins/MaxLengthPlugin/index.js.map +1 -0
  242. package/dist/cjs/components/TextEditorV2/plugins/MentionsPlugin/index.d.ts +2 -0
  243. package/dist/cjs/components/TextEditorV2/plugins/MentionsPlugin/index.js +560 -0
  244. package/dist/cjs/components/TextEditorV2/plugins/MentionsPlugin/index.js.map +1 -0
  245. package/dist/cjs/components/TextEditorV2/plugins/PageBreakPlugin/index.d.ts +3 -0
  246. package/dist/cjs/components/TextEditorV2/plugins/PageBreakPlugin/index.js +31 -0
  247. package/dist/cjs/components/TextEditorV2/plugins/PageBreakPlugin/index.js.map +1 -0
  248. package/dist/cjs/components/TextEditorV2/plugins/PasteLogPlugin/index.d.ts +2 -0
  249. package/dist/cjs/components/TextEditorV2/plugins/PasteLogPlugin/index.js +37 -0
  250. package/dist/cjs/components/TextEditorV2/plugins/PasteLogPlugin/index.js.map +1 -0
  251. package/dist/cjs/components/TextEditorV2/plugins/PollPlugin/index.d.ts +8 -0
  252. package/dist/cjs/components/TextEditorV2/plugins/PollPlugin/index.js +46 -0
  253. package/dist/cjs/components/TextEditorV2/plugins/PollPlugin/index.js.map +1 -0
  254. package/dist/cjs/components/TextEditorV2/plugins/StickyPlugin/index.d.ts +1 -0
  255. package/dist/cjs/components/TextEditorV2/plugins/StickyPlugin/index.js +16 -0
  256. package/dist/cjs/components/TextEditorV2/plugins/StickyPlugin/index.js.map +1 -0
  257. package/dist/cjs/components/TextEditorV2/plugins/TabFocusPlugin/index.d.ts +1 -0
  258. package/dist/cjs/components/TextEditorV2/plugins/TabFocusPlugin/index.js +38 -0
  259. package/dist/cjs/components/TextEditorV2/plugins/TabFocusPlugin/index.js.map +1 -0
  260. package/dist/cjs/components/TextEditorV2/plugins/TableActionMenuPlugin/index.d.ts +5 -0
  261. package/dist/cjs/components/TextEditorV2/plugins/TableActionMenuPlugin/index.js +487 -0
  262. package/dist/cjs/components/TextEditorV2/plugins/TableActionMenuPlugin/index.js.map +1 -0
  263. package/dist/cjs/components/TextEditorV2/plugins/TableCellResizer/index.d.ts +2 -0
  264. package/dist/cjs/components/TextEditorV2/plugins/TableCellResizer/index.js +253 -0
  265. package/dist/cjs/components/TextEditorV2/plugins/TableCellResizer/index.js.map +1 -0
  266. package/dist/cjs/components/TextEditorV2/plugins/TableOfContentsPlugin/index.d.ts +2 -0
  267. package/dist/cjs/components/TextEditorV2/plugins/TableOfContentsPlugin/index.js +117 -0
  268. package/dist/cjs/components/TextEditorV2/plugins/TableOfContentsPlugin/index.js.map +1 -0
  269. package/dist/cjs/components/TextEditorV2/plugins/TablePlugin.d.ts +32 -0
  270. package/dist/cjs/components/TextEditorV2/plugins/TablePlugin.js +85 -0
  271. package/dist/cjs/components/TextEditorV2/plugins/TablePlugin.js.map +1 -0
  272. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.d.ts +6 -0
  273. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.js +18 -0
  274. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.js.map +1 -0
  275. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.d.ts +6 -0
  276. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.js +28 -0
  277. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.js.map +1 -0
  278. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.d.ts +6 -0
  279. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.js +65 -0
  280. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.js.map +1 -0
  281. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.d.ts +6 -0
  282. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.js +71 -0
  283. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.js.map +1 -0
  284. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.d.ts +6 -0
  285. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.js +18 -0
  286. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.js.map +1 -0
  287. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/link.d.ts +5 -0
  288. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/link.js +46 -0
  289. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/link.js.map +1 -0
  290. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.d.ts +6 -0
  291. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.js +28 -0
  292. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.js.map +1 -0
  293. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.d.ts +6 -0
  294. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.js +52 -0
  295. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.js.map +1 -0
  296. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.d.ts +6 -0
  297. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.js +28 -0
  298. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.js.map +1 -0
  299. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.d.ts +6 -0
  300. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.js +19 -0
  301. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.js.map +1 -0
  302. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.d.ts +6 -0
  303. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.js +41 -0
  304. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.js.map +1 -0
  305. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.d.ts +11 -0
  306. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.js +162 -0
  307. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.js.map +1 -0
  308. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/index.d.ts +4 -0
  309. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/index.js +163 -0
  310. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/index.js.map +1 -0
  311. package/dist/cjs/components/TextEditorV2/plugins/TreeViewPlugin/index.d.ts +2 -0
  312. package/dist/cjs/components/TextEditorV2/plugins/TreeViewPlugin/index.js +12 -0
  313. package/dist/cjs/components/TextEditorV2/plugins/TreeViewPlugin/index.js.map +1 -0
  314. package/dist/cjs/components/TextEditorV2/plugins/TwitterPlugin/index.d.ts +3 -0
  315. package/dist/cjs/components/TextEditorV2/plugins/TwitterPlugin/index.js +25 -0
  316. package/dist/cjs/components/TextEditorV2/plugins/TwitterPlugin/index.js.map +1 -0
  317. package/dist/cjs/components/TextEditorV2/plugins/YouTubePlugin/index.d.ts +3 -0
  318. package/dist/cjs/components/TextEditorV2/plugins/YouTubePlugin/index.js +25 -0
  319. package/dist/cjs/components/TextEditorV2/plugins/YouTubePlugin/index.js.map +1 -0
  320. package/dist/cjs/components/TextEditorV2/shared/canUseDOM.d.ts +1 -0
  321. package/dist/cjs/components/TextEditorV2/shared/canUseDOM.js +7 -0
  322. package/dist/cjs/components/TextEditorV2/shared/canUseDOM.js.map +1 -0
  323. package/dist/cjs/components/TextEditorV2/shared/caretFromPoint.d.ts +4 -0
  324. package/dist/cjs/components/TextEditorV2/shared/caretFromPoint.js +32 -0
  325. package/dist/cjs/components/TextEditorV2/shared/caretFromPoint.js.map +1 -0
  326. package/dist/cjs/components/TextEditorV2/shared/environment.d.ts +16 -0
  327. package/dist/cjs/components/TextEditorV2/shared/environment.js +17 -0
  328. package/dist/cjs/components/TextEditorV2/shared/environment.js.map +1 -0
  329. package/dist/cjs/components/TextEditorV2/shared/invariant.d.ts +1 -0
  330. package/dist/cjs/components/TextEditorV2/shared/invariant.js +15 -0
  331. package/dist/cjs/components/TextEditorV2/shared/invariant.js.map +1 -0
  332. package/dist/cjs/components/TextEditorV2/shared/simpleDiffWithCursor.d.ts +5 -0
  333. package/dist/cjs/components/TextEditorV2/shared/simpleDiffWithCursor.js +28 -0
  334. package/dist/cjs/components/TextEditorV2/shared/simpleDiffWithCursor.js.map +1 -0
  335. package/dist/cjs/components/TextEditorV2/shared/useLayoutEffect.d.ts +3 -0
  336. package/dist/cjs/components/TextEditorV2/shared/useLayoutEffect.js +7 -0
  337. package/dist/cjs/components/TextEditorV2/shared/useLayoutEffect.js.map +1 -0
  338. package/dist/cjs/components/TextEditorV2/shared/warnOnlyOnce.d.ts +1 -0
  339. package/dist/cjs/components/TextEditorV2/shared/warnOnlyOnce.js +16 -0
  340. package/dist/cjs/components/TextEditorV2/shared/warnOnlyOnce.js.map +1 -0
  341. package/dist/cjs/components/TextEditorV2/style.d.ts +2 -0
  342. package/dist/cjs/components/TextEditorV2/style.js +9 -0
  343. package/dist/cjs/components/TextEditorV2/style.js.map +1 -0
  344. package/dist/cjs/components/TextEditorV2/themes/CommentEditorTheme.d.ts +3 -0
  345. package/dist/cjs/components/TextEditorV2/themes/CommentEditorTheme.js +7 -0
  346. package/dist/cjs/components/TextEditorV2/themes/CommentEditorTheme.js.map +1 -0
  347. package/dist/cjs/components/TextEditorV2/themes/PlaygroundEditorTheme.d.ts +3 -0
  348. package/dist/cjs/components/TextEditorV2/themes/PlaygroundEditorTheme.js +107 -0
  349. package/dist/cjs/components/TextEditorV2/themes/PlaygroundEditorTheme.js.map +1 -0
  350. package/dist/cjs/components/TextEditorV2/themes/StickyEditorTheme.d.ts +3 -0
  351. package/dist/cjs/components/TextEditorV2/themes/StickyEditorTheme.js +7 -0
  352. package/dist/cjs/components/TextEditorV2/themes/StickyEditorTheme.js.map +1 -0
  353. package/dist/cjs/components/TextEditorV2/ui/Button.d.ts +11 -0
  354. package/dist/cjs/components/TextEditorV2/ui/Button.js +11 -0
  355. package/dist/cjs/components/TextEditorV2/ui/Button.js.map +1 -0
  356. package/dist/cjs/components/TextEditorV2/ui/ColorPicker.d.ts +12 -0
  357. package/dist/cjs/components/TextEditorV2/ui/ColorPicker.js +216 -0
  358. package/dist/cjs/components/TextEditorV2/ui/ColorPicker.js.map +1 -0
  359. package/dist/cjs/components/TextEditorV2/ui/ContentEditable.d.ts +4 -0
  360. package/dist/cjs/components/TextEditorV2/ui/ContentEditable.js +11 -0
  361. package/dist/cjs/components/TextEditorV2/ui/ContentEditable.js.map +1 -0
  362. package/dist/cjs/components/TextEditorV2/ui/Dialog.d.ts +9 -0
  363. package/dist/cjs/components/TextEditorV2/ui/Dialog.js +15 -0
  364. package/dist/cjs/components/TextEditorV2/ui/Dialog.js.map +1 -0
  365. package/dist/cjs/components/TextEditorV2/ui/DropDown.d.ts +17 -0
  366. package/dist/cjs/components/TextEditorV2/ui/DropDown.js +133 -0
  367. package/dist/cjs/components/TextEditorV2/ui/DropDown.js.map +1 -0
  368. package/dist/cjs/components/TextEditorV2/ui/DropdownColorPicker.d.ts +21 -0
  369. package/dist/cjs/components/TextEditorV2/ui/DropdownColorPicker.js +20 -0
  370. package/dist/cjs/components/TextEditorV2/ui/DropdownColorPicker.js.map +1 -0
  371. package/dist/cjs/components/TextEditorV2/ui/EquationEditor.d.ts +8 -0
  372. package/dist/cjs/components/TextEditorV2/ui/EquationEditor.js +20 -0
  373. package/dist/cjs/components/TextEditorV2/ui/EquationEditor.js.map +1 -0
  374. package/dist/cjs/components/TextEditorV2/ui/FileInput.d.ts +9 -0
  375. package/dist/cjs/components/TextEditorV2/ui/FileInput.js +12 -0
  376. package/dist/cjs/components/TextEditorV2/ui/FileInput.js.map +1 -0
  377. package/dist/cjs/components/TextEditorV2/ui/ImageResizer.d.ts +11 -0
  378. package/dist/cjs/components/TextEditorV2/ui/ImageResizer.js +178 -0
  379. package/dist/cjs/components/TextEditorV2/ui/ImageResizer.js.map +1 -0
  380. package/dist/cjs/components/TextEditorV2/ui/KatexEquationAlterer.d.ts +7 -0
  381. package/dist/cjs/components/TextEditorV2/ui/KatexEquationAlterer.js +39 -0
  382. package/dist/cjs/components/TextEditorV2/ui/KatexEquationAlterer.js.map +1 -0
  383. package/dist/cjs/components/TextEditorV2/ui/KatexRenderer.d.ts +6 -0
  384. package/dist/cjs/components/TextEditorV2/ui/KatexRenderer.js +33 -0
  385. package/dist/cjs/components/TextEditorV2/ui/KatexRenderer.js.map +1 -0
  386. package/dist/cjs/components/TextEditorV2/ui/Modal.d.ts +8 -0
  387. package/dist/cjs/components/TextEditorV2/ui/Modal.js +54 -0
  388. package/dist/cjs/components/TextEditorV2/ui/Modal.js.map +1 -0
  389. package/dist/cjs/components/TextEditorV2/ui/Placeholder.d.ts +6 -0
  390. package/dist/cjs/components/TextEditorV2/ui/Placeholder.js +10 -0
  391. package/dist/cjs/components/TextEditorV2/ui/Placeholder.js.map +1 -0
  392. package/dist/cjs/components/TextEditorV2/ui/Select.d.ts +7 -0
  393. package/dist/cjs/components/TextEditorV2/ui/Select.js +12 -0
  394. package/dist/cjs/components/TextEditorV2/ui/Select.js.map +1 -0
  395. package/dist/cjs/components/TextEditorV2/ui/Switch.d.ts +7 -0
  396. package/dist/cjs/components/TextEditorV2/ui/Switch.js +15 -0
  397. package/dist/cjs/components/TextEditorV2/ui/Switch.js.map +1 -0
  398. package/dist/cjs/components/TextEditorV2/ui/TextInput.d.ts +12 -0
  399. package/dist/cjs/components/TextEditorV2/ui/TextInput.js +14 -0
  400. package/dist/cjs/components/TextEditorV2/ui/TextInput.js.map +1 -0
  401. package/dist/cjs/components/TextEditorV2/utils/emoji-list.d.ts +20 -0
  402. package/dist/cjs/components/TextEditorV2/utils/emoji-list.js +16607 -0
  403. package/dist/cjs/components/TextEditorV2/utils/emoji-list.js.map +1 -0
  404. package/dist/cjs/components/TextEditorV2/utils/getDOMRangeRect.d.ts +1 -0
  405. package/dist/cjs/components/TextEditorV2/utils/getDOMRangeRect.js +19 -0
  406. package/dist/cjs/components/TextEditorV2/utils/getDOMRangeRect.js.map +1 -0
  407. package/dist/cjs/components/TextEditorV2/utils/getPrepopulatedRichText.d.ts +1 -0
  408. package/dist/cjs/components/TextEditorV2/utils/getPrepopulatedRichText.js +35 -0
  409. package/dist/cjs/components/TextEditorV2/utils/getPrepopulatedRichText.js.map +1 -0
  410. package/dist/cjs/components/TextEditorV2/utils/getSelectedNode.d.ts +2 -0
  411. package/dist/cjs/components/TextEditorV2/utils/getSelectedNode.js +21 -0
  412. package/dist/cjs/components/TextEditorV2/utils/getSelectedNode.js.map +1 -0
  413. package/dist/cjs/components/TextEditorV2/utils/guard.d.ts +1 -0
  414. package/dist/cjs/components/TextEditorV2/utils/guard.js +7 -0
  415. package/dist/cjs/components/TextEditorV2/utils/guard.js.map +1 -0
  416. package/dist/cjs/components/TextEditorV2/utils/isMobileWidth.d.ts +0 -0
  417. package/dist/cjs/components/TextEditorV2/utils/isMobileWidth.js +2 -0
  418. package/dist/cjs/components/TextEditorV2/utils/isMobileWidth.js.map +1 -0
  419. package/dist/cjs/components/TextEditorV2/utils/joinClasses.d.ts +1 -0
  420. package/dist/cjs/components/TextEditorV2/utils/joinClasses.js +11 -0
  421. package/dist/cjs/components/TextEditorV2/utils/joinClasses.js.map +1 -0
  422. package/dist/cjs/components/TextEditorV2/utils/point.d.ts +14 -0
  423. package/dist/cjs/components/TextEditorV2/utils/point.js +51 -0
  424. package/dist/cjs/components/TextEditorV2/utils/point.js.map +1 -0
  425. package/dist/cjs/components/TextEditorV2/utils/rect.d.ts +38 -0
  426. package/dist/cjs/components/TextEditorV2/utils/rect.js +125 -0
  427. package/dist/cjs/components/TextEditorV2/utils/rect.js.map +1 -0
  428. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPosition.d.ts +1 -0
  429. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPosition.js +33 -0
  430. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPosition.js.map +1 -0
  431. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.d.ts +1 -0
  432. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.js +31 -0
  433. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.js.map +1 -0
  434. package/dist/cjs/components/TextEditorV2/utils/swipe.d.ts +4 -0
  435. package/dist/cjs/components/TextEditorV2/utils/swipe.js +97 -0
  436. package/dist/cjs/components/TextEditorV2/utils/swipe.js.map +1 -0
  437. package/dist/cjs/components/TextEditorV2/utils/url.d.ts +2 -0
  438. package/dist/cjs/components/TextEditorV2/utils/url.js +26 -0
  439. package/dist/cjs/components/TextEditorV2/utils/url.js.map +1 -0
  440. package/dist/cjs/index.d.ts +2 -1
  441. package/dist/cjs/index.js +5 -3
  442. package/dist/cjs/index.js.map +1 -1
  443. package/dist/esm/components/MainWrapV4/components/notification/component/HtmlIFrame.d.ts +2 -2
  444. package/dist/esm/components/MainWrapV4/components/notification/component/HtmlIFrame.js +11 -10
  445. package/dist/esm/components/MainWrapV4/components/notification/component/HtmlIFrame.js.map +1 -1
  446. package/dist/esm/components/MainWrapV4/components/notification/component/NotiDropdown.js +8 -7
  447. package/dist/esm/components/MainWrapV4/components/notification/component/NotiDropdown.js.map +1 -1
  448. package/dist/esm/components/MainWrapV4/components/notification/component/NotiHeader.js +1 -1
  449. package/dist/esm/components/MainWrapV4/components/notification/component/NotiHeader.js.map +1 -1
  450. package/dist/esm/components/MainWrapV4/components/notification/component/NotiListPane.d.ts +3 -4
  451. package/dist/esm/components/MainWrapV4/components/notification/component/NotiListPane.js +18 -8
  452. package/dist/esm/components/MainWrapV4/components/notification/component/NotiListPane.js.map +1 -1
  453. package/dist/esm/components/MainWrapV4/components/notification/component/NotiPreviewPane.d.ts +1 -4
  454. package/dist/esm/components/MainWrapV4/components/notification/component/NotiPreviewPane.js +4 -40
  455. package/dist/esm/components/MainWrapV4/components/notification/component/NotiPreviewPane.js.map +1 -1
  456. package/dist/esm/components/MainWrapV4/components/notification/hook/useNotificationData.d.ts +1 -1
  457. package/dist/esm/components/MainWrapV4/components/notification/hook/useNotificationData.js +1 -1
  458. package/dist/esm/components/MainWrapV4/components/notification/hook/useNotificationData.js.map +1 -1
  459. package/dist/esm/components/MainWrapV4/components/notification/index.js +8 -2
  460. package/dist/esm/components/MainWrapV4/components/notification/index.js.map +1 -1
  461. package/dist/esm/components/MainWrapV4/types/notification.d.ts +0 -1
  462. package/dist/esm/components/TextEditorV2/commenting/index.d.ts +41 -0
  463. package/dist/esm/components/TextEditorV2/commenting/index.js +334 -0
  464. package/dist/esm/components/TextEditorV2/commenting/index.js.map +1 -0
  465. package/dist/esm/components/TextEditorV2/constants.d.ts +1 -0
  466. package/dist/esm/components/TextEditorV2/constants.js +2 -0
  467. package/dist/esm/components/TextEditorV2/constants.js.map +1 -0
  468. package/dist/esm/components/TextEditorV2/context/SettingsContext.d.ts +12 -0
  469. package/dist/esm/components/TextEditorV2/context/SettingsContext.js +54 -0
  470. package/dist/esm/components/TextEditorV2/context/SettingsContext.js.map +1 -0
  471. package/dist/esm/components/TextEditorV2/context/SharedAutocompleteContext.d.ts +10 -0
  472. package/dist/esm/components/TextEditorV2/context/SharedAutocompleteContext.js +44 -0
  473. package/dist/esm/components/TextEditorV2/context/SharedAutocompleteContext.js.map +1 -0
  474. package/dist/esm/components/TextEditorV2/context/SharedHistoryContext.d.ts +11 -0
  475. package/dist/esm/components/TextEditorV2/context/SharedHistoryContext.js +11 -0
  476. package/dist/esm/components/TextEditorV2/context/SharedHistoryContext.js.map +1 -0
  477. package/dist/esm/components/TextEditorV2/editor.d.ts +10 -0
  478. package/dist/esm/components/TextEditorV2/editor.js +200 -0
  479. package/dist/esm/components/TextEditorV2/editor.js.map +1 -0
  480. package/dist/esm/components/TextEditorV2/hooks/useModal.d.ts +5 -0
  481. package/dist/esm/components/TextEditorV2/hooks/useModal.js +28 -0
  482. package/dist/esm/components/TextEditorV2/hooks/useModal.js.map +1 -0
  483. package/dist/esm/components/TextEditorV2/hooks/useReport.d.ts +1 -0
  484. package/dist/esm/components/TextEditorV2/hooks/useReport.js +42 -0
  485. package/dist/esm/components/TextEditorV2/hooks/useReport.js.map +1 -0
  486. package/dist/esm/components/TextEditorV2/lib/Settings.d.ts +2 -0
  487. package/dist/esm/components/TextEditorV2/lib/Settings.js +48 -0
  488. package/dist/esm/components/TextEditorV2/lib/Settings.js.map +1 -0
  489. package/dist/esm/components/TextEditorV2/lib/appSettings.d.ts +19 -0
  490. package/dist/esm/components/TextEditorV2/lib/appSettings.js +18 -0
  491. package/dist/esm/components/TextEditorV2/lib/appSettings.js.map +1 -0
  492. package/dist/esm/components/TextEditorV2/lib/collaboration.d.ts +3 -0
  493. package/dist/esm/components/TextEditorV2/lib/collaboration.js +23 -0
  494. package/dist/esm/components/TextEditorV2/lib/collaboration.js.map +1 -0
  495. package/dist/esm/components/TextEditorV2/lib/setupEnv.d.ts +1 -0
  496. package/dist/esm/components/TextEditorV2/lib/setupEnv.js +21 -0
  497. package/dist/esm/components/TextEditorV2/lib/setupEnv.js.map +1 -0
  498. package/dist/esm/components/TextEditorV2/nodes/AutocompleteNode.d.ts +25 -0
  499. package/dist/esm/components/TextEditorV2/nodes/AutocompleteNode.js +54 -0
  500. package/dist/esm/components/TextEditorV2/nodes/AutocompleteNode.js.map +1 -0
  501. package/dist/esm/components/TextEditorV2/nodes/EmojiNode.d.ts +18 -0
  502. package/dist/esm/components/TextEditorV2/nodes/EmojiNode.js +57 -0
  503. package/dist/esm/components/TextEditorV2/nodes/EmojiNode.js.map +1 -0
  504. package/dist/esm/components/TextEditorV2/nodes/EquationComponent.d.ts +9 -0
  505. package/dist/esm/components/TextEditorV2/nodes/EquationComponent.js +68 -0
  506. package/dist/esm/components/TextEditorV2/nodes/EquationComponent.js.map +1 -0
  507. package/dist/esm/components/TextEditorV2/nodes/EquationNode.d.ts +26 -0
  508. package/dist/esm/components/TextEditorV2/nodes/EquationNode.js +121 -0
  509. package/dist/esm/components/TextEditorV2/nodes/EquationNode.js.map +1 -0
  510. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.d.ts +6 -0
  511. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.js +113 -0
  512. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.js.map +1 -0
  513. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.d.ts +50 -0
  514. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.js +56 -0
  515. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.js.map +1 -0
  516. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.d.ts +44 -0
  517. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.js +137 -0
  518. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.js.map +1 -0
  519. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/index.d.ts +22 -0
  520. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/index.js +98 -0
  521. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/index.js.map +1 -0
  522. package/dist/esm/components/TextEditorV2/nodes/ExtendedTextNode.d.ts +12 -0
  523. package/dist/esm/components/TextEditorV2/nodes/ExtendedTextNode.js +101 -0
  524. package/dist/esm/components/TextEditorV2/nodes/ExtendedTextNode.js.map +1 -0
  525. package/dist/esm/components/TextEditorV2/nodes/FigmaNode.d.ts +19 -0
  526. package/dist/esm/components/TextEditorV2/nodes/FigmaNode.js +58 -0
  527. package/dist/esm/components/TextEditorV2/nodes/FigmaNode.js.map +1 -0
  528. package/dist/esm/components/TextEditorV2/nodes/ImageComponent.d.ts +14 -0
  529. package/dist/esm/components/TextEditorV2/nodes/ImageComponent.js +207 -0
  530. package/dist/esm/components/TextEditorV2/nodes/ImageComponent.js.map +1 -0
  531. package/dist/esm/components/TextEditorV2/nodes/ImageNode.d.ts +56 -0
  532. package/dist/esm/components/TextEditorV2/nodes/ImageNode.js +131 -0
  533. package/dist/esm/components/TextEditorV2/nodes/ImageNode.js.map +1 -0
  534. package/dist/esm/components/TextEditorV2/nodes/InlineImageComponent.d.ts +18 -0
  535. package/dist/esm/components/TextEditorV2/nodes/InlineImageComponent.js +189 -0
  536. package/dist/esm/components/TextEditorV2/nodes/InlineImageComponent.js.map +1 -0
  537. package/dist/esm/components/TextEditorV2/nodes/InlineImageNode.d.ts +54 -0
  538. package/dist/esm/components/TextEditorV2/nodes/InlineImageNode.js +137 -0
  539. package/dist/esm/components/TextEditorV2/nodes/InlineImageNode.js.map +1 -0
  540. package/dist/esm/components/TextEditorV2/nodes/KeywordNode.d.ts +15 -0
  541. package/dist/esm/components/TextEditorV2/nodes/KeywordNode.js +49 -0
  542. package/dist/esm/components/TextEditorV2/nodes/KeywordNode.js.map +1 -0
  543. package/dist/esm/components/TextEditorV2/nodes/LayoutContainerNode.d.ts +21 -0
  544. package/dist/esm/components/TextEditorV2/nodes/LayoutContainerNode.js +58 -0
  545. package/dist/esm/components/TextEditorV2/nodes/LayoutContainerNode.js.map +1 -0
  546. package/dist/esm/components/TextEditorV2/nodes/LayoutItemNode.d.ts +15 -0
  547. package/dist/esm/components/TextEditorV2/nodes/LayoutItemNode.js +46 -0
  548. package/dist/esm/components/TextEditorV2/nodes/LayoutItemNode.js.map +1 -0
  549. package/dist/esm/components/TextEditorV2/nodes/MentionNode.d.ts +20 -0
  550. package/dist/esm/components/TextEditorV2/nodes/MentionNode.js +84 -0
  551. package/dist/esm/components/TextEditorV2/nodes/MentionNode.js.map +1 -0
  552. package/dist/esm/components/TextEditorV2/nodes/PageBreakNode/index.d.ts +17 -0
  553. package/dist/esm/components/TextEditorV2/nodes/PageBreakNode/index.js +108 -0
  554. package/dist/esm/components/TextEditorV2/nodes/PageBreakNode/index.js.map +1 -0
  555. package/dist/esm/components/TextEditorV2/nodes/PlaygroundNodes.d.ts +3 -0
  556. package/dist/esm/components/TextEditorV2/nodes/PlaygroundNodes.js +66 -0
  557. package/dist/esm/components/TextEditorV2/nodes/PlaygroundNodes.js.map +1 -0
  558. package/dist/esm/components/TextEditorV2/nodes/PollComponent.d.ts +8 -0
  559. package/dist/esm/components/TextEditorV2/nodes/PollComponent.js +109 -0
  560. package/dist/esm/components/TextEditorV2/nodes/PollComponent.js.map +1 -0
  561. package/dist/esm/components/TextEditorV2/nodes/PollNode.d.ts +33 -0
  562. package/dist/esm/components/TextEditorV2/nodes/PollNode.js +143 -0
  563. package/dist/esm/components/TextEditorV2/nodes/PollNode.js.map +1 -0
  564. package/dist/esm/components/TextEditorV2/nodes/StickyComponent.d.ts +9 -0
  565. package/dist/esm/components/TextEditorV2/nodes/StickyComponent.js +163 -0
  566. package/dist/esm/components/TextEditorV2/nodes/StickyComponent.js.map +1 -0
  567. package/dist/esm/components/TextEditorV2/nodes/StickyNode.d.ts +37 -0
  568. package/dist/esm/components/TextEditorV2/nodes/StickyNode.js +89 -0
  569. package/dist/esm/components/TextEditorV2/nodes/StickyNode.js.map +1 -0
  570. package/dist/esm/components/TextEditorV2/nodes/TableNode.d.ts +54 -0
  571. package/dist/esm/components/TextEditorV2/nodes/TableNode.js +188 -0
  572. package/dist/esm/components/TextEditorV2/nodes/TableNode.js.map +1 -0
  573. package/dist/esm/components/TextEditorV2/nodes/TweetNode.d.ts +28 -0
  574. package/dist/esm/components/TextEditorV2/nodes/TweetNode.js +151 -0
  575. package/dist/esm/components/TextEditorV2/nodes/TweetNode.js.map +1 -0
  576. package/dist/esm/components/TextEditorV2/nodes/YouTubeNode.d.ts +28 -0
  577. package/dist/esm/components/TextEditorV2/nodes/YouTubeNode.js +98 -0
  578. package/dist/esm/components/TextEditorV2/nodes/YouTubeNode.js.map +1 -0
  579. package/dist/esm/components/TextEditorV2/plugins/ActionsPlugin/index.d.ts +2 -0
  580. package/dist/esm/components/TextEditorV2/plugins/ActionsPlugin/index.js +180 -0
  581. package/dist/esm/components/TextEditorV2/plugins/ActionsPlugin/index.js.map +1 -0
  582. package/dist/esm/components/TextEditorV2/plugins/AutoEmbedPlugin/index.d.ts +19 -0
  583. package/dist/esm/components/TextEditorV2/plugins/AutoEmbedPlugin/index.js +174 -0
  584. package/dist/esm/components/TextEditorV2/plugins/AutoEmbedPlugin/index.js.map +1 -0
  585. package/dist/esm/components/TextEditorV2/plugins/AutoLinkPlugin/index.d.ts +2 -0
  586. package/dist/esm/components/TextEditorV2/plugins/AutoLinkPlugin/index.js +12 -0
  587. package/dist/esm/components/TextEditorV2/plugins/AutoLinkPlugin/index.js.map +1 -0
  588. package/dist/esm/components/TextEditorV2/plugins/AutocompletePlugin/index.d.ts +2 -0
  589. package/dist/esm/components/TextEditorV2/plugins/AutocompletePlugin/index.js +2461 -0
  590. package/dist/esm/components/TextEditorV2/plugins/AutocompletePlugin/index.js.map +1 -0
  591. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.d.ts +8 -0
  592. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.js +52 -0
  593. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.js.map +1 -0
  594. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.d.ts +10 -0
  595. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.js +155 -0
  596. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.js.map +1 -0
  597. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.d.ts +4 -0
  598. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.js +108 -0
  599. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.js.map +1 -0
  600. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.d.ts +1 -0
  601. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.js +18 -0
  602. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.js.map +1 -0
  603. package/dist/esm/components/TextEditorV2/plugins/CodeHighlightPlugin/index.d.ts +1 -0
  604. package/dist/esm/components/TextEditorV2/plugins/CodeHighlightPlugin/index.js +9 -0
  605. package/dist/esm/components/TextEditorV2/plugins/CodeHighlightPlugin/index.js.map +1 -0
  606. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.d.ts +23 -0
  607. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.js +82 -0
  608. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.js.map +1 -0
  609. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.d.ts +17 -0
  610. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.js +64 -0
  611. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.js.map +1 -0
  612. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.d.ts +18 -0
  613. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.js +89 -0
  614. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.js.map +1 -0
  615. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/index.d.ts +3 -0
  616. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/index.js +144 -0
  617. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/index.js.map +1 -0
  618. package/dist/esm/components/TextEditorV2/plugins/ComponentPickerPlugin/index.d.ts +2 -0
  619. package/dist/esm/components/TextEditorV2/plugins/ComponentPickerPlugin/index.js +261 -0
  620. package/dist/esm/components/TextEditorV2/plugins/ComponentPickerPlugin/index.js.map +1 -0
  621. package/dist/esm/components/TextEditorV2/plugins/ContextMenuPlugin/index.d.ts +11 -0
  622. package/dist/esm/components/TextEditorV2/plugins/ContextMenuPlugin/index.js +167 -0
  623. package/dist/esm/components/TextEditorV2/plugins/ContextMenuPlugin/index.js.map +1 -0
  624. package/dist/esm/components/TextEditorV2/plugins/DocsPlugin/index.d.ts +2 -0
  625. package/dist/esm/components/TextEditorV2/plugins/DocsPlugin/index.js +6 -0
  626. package/dist/esm/components/TextEditorV2/plugins/DocsPlugin/index.js.map +1 -0
  627. package/dist/esm/components/TextEditorV2/plugins/DragDropPastePlugin/index.d.ts +1 -0
  628. package/dist/esm/components/TextEditorV2/plugins/DragDropPastePlugin/index.js +41 -0
  629. package/dist/esm/components/TextEditorV2/plugins/DragDropPastePlugin/index.js.map +1 -0
  630. package/dist/esm/components/TextEditorV2/plugins/DraggableBlockPlugin/index.d.ts +4 -0
  631. package/dist/esm/components/TextEditorV2/plugins/DraggableBlockPlugin/index.js +284 -0
  632. package/dist/esm/components/TextEditorV2/plugins/DraggableBlockPlugin/index.js.map +1 -0
  633. package/dist/esm/components/TextEditorV2/plugins/EmojiPickerPlugin/index.d.ts +2 -0
  634. package/dist/esm/components/TextEditorV2/plugins/EmojiPickerPlugin/index.js +94 -0
  635. package/dist/esm/components/TextEditorV2/plugins/EmojiPickerPlugin/index.js.map +1 -0
  636. package/dist/esm/components/TextEditorV2/plugins/EmojisPlugin/index.d.ts +1 -0
  637. package/dist/esm/components/TextEditorV2/plugins/EmojisPlugin/index.js +61 -0
  638. package/dist/esm/components/TextEditorV2/plugins/EmojisPlugin/index.js.map +1 -0
  639. package/dist/esm/components/TextEditorV2/plugins/EquationsPlugin/index.d.ts +14 -0
  640. package/dist/esm/components/TextEditorV2/plugins/EquationsPlugin/index.js +36 -0
  641. package/dist/esm/components/TextEditorV2/plugins/EquationsPlugin/index.js.map +1 -0
  642. package/dist/esm/components/TextEditorV2/plugins/ExcalidrawPlugin/index.d.ts +3 -0
  643. package/dist/esm/components/TextEditorV2/plugins/ExcalidrawPlugin/index.js +24 -0
  644. package/dist/esm/components/TextEditorV2/plugins/ExcalidrawPlugin/index.js.map +1 -0
  645. package/dist/esm/components/TextEditorV2/plugins/FigmaPlugin/index.d.ts +3 -0
  646. package/dist/esm/components/TextEditorV2/plugins/FigmaPlugin/index.js +21 -0
  647. package/dist/esm/components/TextEditorV2/plugins/FigmaPlugin/index.js.map +1 -0
  648. package/dist/esm/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.d.ts +7 -0
  649. package/dist/esm/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.js +196 -0
  650. package/dist/esm/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.js.map +1 -0
  651. package/dist/esm/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.d.ts +4 -0
  652. package/dist/esm/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.js +225 -0
  653. package/dist/esm/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.js.map +1 -0
  654. package/dist/esm/components/TextEditorV2/plugins/ImagesPlugin/index.d.ts +22 -0
  655. package/dist/esm/components/TextEditorV2/plugins/ImagesPlugin/index.js +181 -0
  656. package/dist/esm/components/TextEditorV2/plugins/ImagesPlugin/index.js.map +1 -0
  657. package/dist/esm/components/TextEditorV2/plugins/InlineImagePlugin/index.d.ts +17 -0
  658. package/dist/esm/components/TextEditorV2/plugins/InlineImagePlugin/index.js +187 -0
  659. package/dist/esm/components/TextEditorV2/plugins/InlineImagePlugin/index.js.map +1 -0
  660. package/dist/esm/components/TextEditorV2/plugins/KeywordsPlugin/index.d.ts +1 -0
  661. package/dist/esm/components/TextEditorV2/plugins/KeywordsPlugin/index.js +30 -0
  662. package/dist/esm/components/TextEditorV2/plugins/KeywordsPlugin/index.js.map +1 -0
  663. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.d.ts +6 -0
  664. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.js +30 -0
  665. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.js.map +1 -0
  666. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.d.ts +7 -0
  667. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.js +85 -0
  668. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.js.map +1 -0
  669. package/dist/esm/components/TextEditorV2/plugins/LinkPlugin/index.d.ts +2 -0
  670. package/dist/esm/components/TextEditorV2/plugins/LinkPlugin/index.js +7 -0
  671. package/dist/esm/components/TextEditorV2/plugins/LinkPlugin/index.js.map +1 -0
  672. package/dist/esm/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.d.ts +5 -0
  673. package/dist/esm/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.js +41 -0
  674. package/dist/esm/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.js.map +1 -0
  675. package/dist/esm/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.d.ts +2 -0
  676. package/dist/esm/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.js +7 -0
  677. package/dist/esm/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.js.map +1 -0
  678. package/dist/esm/components/TextEditorV2/plugins/MarkdownTransformers/index.d.ts +8 -0
  679. package/dist/esm/components/TextEditorV2/plugins/MarkdownTransformers/index.js +239 -0
  680. package/dist/esm/components/TextEditorV2/plugins/MarkdownTransformers/index.js.map +1 -0
  681. package/dist/esm/components/TextEditorV2/plugins/MaxLengthPlugin/index.d.ts +3 -0
  682. package/dist/esm/components/TextEditorV2/plugins/MaxLengthPlugin/index.js +38 -0
  683. package/dist/esm/components/TextEditorV2/plugins/MaxLengthPlugin/index.js.map +1 -0
  684. package/dist/esm/components/TextEditorV2/plugins/MentionsPlugin/index.d.ts +2 -0
  685. package/dist/esm/components/TextEditorV2/plugins/MentionsPlugin/index.js +557 -0
  686. package/dist/esm/components/TextEditorV2/plugins/MentionsPlugin/index.js.map +1 -0
  687. package/dist/esm/components/TextEditorV2/plugins/PageBreakPlugin/index.d.ts +3 -0
  688. package/dist/esm/components/TextEditorV2/plugins/PageBreakPlugin/index.js +27 -0
  689. package/dist/esm/components/TextEditorV2/plugins/PageBreakPlugin/index.js.map +1 -0
  690. package/dist/esm/components/TextEditorV2/plugins/PasteLogPlugin/index.d.ts +2 -0
  691. package/dist/esm/components/TextEditorV2/plugins/PasteLogPlugin/index.js +33 -0
  692. package/dist/esm/components/TextEditorV2/plugins/PasteLogPlugin/index.js.map +1 -0
  693. package/dist/esm/components/TextEditorV2/plugins/PollPlugin/index.d.ts +8 -0
  694. package/dist/esm/components/TextEditorV2/plugins/PollPlugin/index.js +40 -0
  695. package/dist/esm/components/TextEditorV2/plugins/PollPlugin/index.js.map +1 -0
  696. package/dist/esm/components/TextEditorV2/plugins/StickyPlugin/index.d.ts +1 -0
  697. package/dist/esm/components/TextEditorV2/plugins/StickyPlugin/index.js +13 -0
  698. package/dist/esm/components/TextEditorV2/plugins/StickyPlugin/index.js.map +1 -0
  699. package/dist/esm/components/TextEditorV2/plugins/TabFocusPlugin/index.d.ts +1 -0
  700. package/dist/esm/components/TextEditorV2/plugins/TabFocusPlugin/index.js +35 -0
  701. package/dist/esm/components/TextEditorV2/plugins/TabFocusPlugin/index.js.map +1 -0
  702. package/dist/esm/components/TextEditorV2/plugins/TableActionMenuPlugin/index.d.ts +5 -0
  703. package/dist/esm/components/TextEditorV2/plugins/TableActionMenuPlugin/index.js +483 -0
  704. package/dist/esm/components/TextEditorV2/plugins/TableActionMenuPlugin/index.js.map +1 -0
  705. package/dist/esm/components/TextEditorV2/plugins/TableCellResizer/index.d.ts +2 -0
  706. package/dist/esm/components/TextEditorV2/plugins/TableCellResizer/index.js +249 -0
  707. package/dist/esm/components/TextEditorV2/plugins/TableCellResizer/index.js.map +1 -0
  708. package/dist/esm/components/TextEditorV2/plugins/TableOfContentsPlugin/index.d.ts +2 -0
  709. package/dist/esm/components/TextEditorV2/plugins/TableOfContentsPlugin/index.js +113 -0
  710. package/dist/esm/components/TextEditorV2/plugins/TableOfContentsPlugin/index.js.map +1 -0
  711. package/dist/esm/components/TextEditorV2/plugins/TablePlugin.d.ts +32 -0
  712. package/dist/esm/components/TextEditorV2/plugins/TablePlugin.js +78 -0
  713. package/dist/esm/components/TextEditorV2/plugins/TablePlugin.js.map +1 -0
  714. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.d.ts +6 -0
  715. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.js +14 -0
  716. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.js.map +1 -0
  717. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.d.ts +6 -0
  718. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.js +24 -0
  719. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.js.map +1 -0
  720. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.d.ts +6 -0
  721. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.js +61 -0
  722. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.js.map +1 -0
  723. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.d.ts +6 -0
  724. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.js +67 -0
  725. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.js.map +1 -0
  726. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.d.ts +6 -0
  727. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.js +14 -0
  728. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.js.map +1 -0
  729. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/link.d.ts +5 -0
  730. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/link.js +42 -0
  731. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/link.js.map +1 -0
  732. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.d.ts +6 -0
  733. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.js +24 -0
  734. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.js.map +1 -0
  735. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.d.ts +6 -0
  736. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.js +48 -0
  737. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.js.map +1 -0
  738. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.d.ts +6 -0
  739. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.js +24 -0
  740. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.js.map +1 -0
  741. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.d.ts +6 -0
  742. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.js +15 -0
  743. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.js.map +1 -0
  744. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.d.ts +6 -0
  745. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.js +37 -0
  746. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.js.map +1 -0
  747. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.d.ts +11 -0
  748. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.js +159 -0
  749. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.js.map +1 -0
  750. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/index.d.ts +4 -0
  751. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/index.js +159 -0
  752. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/index.js.map +1 -0
  753. package/dist/esm/components/TextEditorV2/plugins/TreeViewPlugin/index.d.ts +2 -0
  754. package/dist/esm/components/TextEditorV2/plugins/TreeViewPlugin/index.js +8 -0
  755. package/dist/esm/components/TextEditorV2/plugins/TreeViewPlugin/index.js.map +1 -0
  756. package/dist/esm/components/TextEditorV2/plugins/TwitterPlugin/index.d.ts +3 -0
  757. package/dist/esm/components/TextEditorV2/plugins/TwitterPlugin/index.js +21 -0
  758. package/dist/esm/components/TextEditorV2/plugins/TwitterPlugin/index.js.map +1 -0
  759. package/dist/esm/components/TextEditorV2/plugins/YouTubePlugin/index.d.ts +3 -0
  760. package/dist/esm/components/TextEditorV2/plugins/YouTubePlugin/index.js +21 -0
  761. package/dist/esm/components/TextEditorV2/plugins/YouTubePlugin/index.js.map +1 -0
  762. package/dist/esm/components/TextEditorV2/shared/canUseDOM.d.ts +1 -0
  763. package/dist/esm/components/TextEditorV2/shared/canUseDOM.js +4 -0
  764. package/dist/esm/components/TextEditorV2/shared/canUseDOM.js.map +1 -0
  765. package/dist/esm/components/TextEditorV2/shared/caretFromPoint.d.ts +4 -0
  766. package/dist/esm/components/TextEditorV2/shared/caretFromPoint.js +29 -0
  767. package/dist/esm/components/TextEditorV2/shared/caretFromPoint.js.map +1 -0
  768. package/dist/esm/components/TextEditorV2/shared/environment.d.ts +16 -0
  769. package/dist/esm/components/TextEditorV2/shared/environment.js +14 -0
  770. package/dist/esm/components/TextEditorV2/shared/environment.js.map +1 -0
  771. package/dist/esm/components/TextEditorV2/shared/invariant.d.ts +1 -0
  772. package/dist/esm/components/TextEditorV2/shared/invariant.js +12 -0
  773. package/dist/esm/components/TextEditorV2/shared/invariant.js.map +1 -0
  774. package/dist/esm/components/TextEditorV2/shared/simpleDiffWithCursor.d.ts +5 -0
  775. package/dist/esm/components/TextEditorV2/shared/simpleDiffWithCursor.js +25 -0
  776. package/dist/esm/components/TextEditorV2/shared/simpleDiffWithCursor.js.map +1 -0
  777. package/dist/esm/components/TextEditorV2/shared/useLayoutEffect.d.ts +3 -0
  778. package/dist/esm/components/TextEditorV2/shared/useLayoutEffect.js +5 -0
  779. package/dist/esm/components/TextEditorV2/shared/useLayoutEffect.js.map +1 -0
  780. package/dist/esm/components/TextEditorV2/shared/warnOnlyOnce.d.ts +1 -0
  781. package/dist/esm/components/TextEditorV2/shared/warnOnlyOnce.js +13 -0
  782. package/dist/esm/components/TextEditorV2/shared/warnOnlyOnce.js.map +1 -0
  783. package/dist/esm/components/TextEditorV2/style.d.ts +2 -0
  784. package/dist/esm/components/TextEditorV2/style.js +5 -0
  785. package/dist/esm/components/TextEditorV2/style.js.map +1 -0
  786. package/dist/esm/components/TextEditorV2/themes/CommentEditorTheme.d.ts +3 -0
  787. package/dist/esm/components/TextEditorV2/themes/CommentEditorTheme.js +5 -0
  788. package/dist/esm/components/TextEditorV2/themes/CommentEditorTheme.js.map +1 -0
  789. package/dist/esm/components/TextEditorV2/themes/PlaygroundEditorTheme.d.ts +3 -0
  790. package/dist/esm/components/TextEditorV2/themes/PlaygroundEditorTheme.js +105 -0
  791. package/dist/esm/components/TextEditorV2/themes/PlaygroundEditorTheme.js.map +1 -0
  792. package/dist/esm/components/TextEditorV2/themes/StickyEditorTheme.d.ts +3 -0
  793. package/dist/esm/components/TextEditorV2/themes/StickyEditorTheme.js +5 -0
  794. package/dist/esm/components/TextEditorV2/themes/StickyEditorTheme.js.map +1 -0
  795. package/dist/esm/components/TextEditorV2/ui/Button.d.ts +11 -0
  796. package/dist/esm/components/TextEditorV2/ui/Button.js +8 -0
  797. package/dist/esm/components/TextEditorV2/ui/Button.js.map +1 -0
  798. package/dist/esm/components/TextEditorV2/ui/ColorPicker.d.ts +12 -0
  799. package/dist/esm/components/TextEditorV2/ui/ColorPicker.js +212 -0
  800. package/dist/esm/components/TextEditorV2/ui/ColorPicker.js.map +1 -0
  801. package/dist/esm/components/TextEditorV2/ui/ContentEditable.d.ts +4 -0
  802. package/dist/esm/components/TextEditorV2/ui/ContentEditable.js +7 -0
  803. package/dist/esm/components/TextEditorV2/ui/ContentEditable.js.map +1 -0
  804. package/dist/esm/components/TextEditorV2/ui/Dialog.d.ts +9 -0
  805. package/dist/esm/components/TextEditorV2/ui/Dialog.js +10 -0
  806. package/dist/esm/components/TextEditorV2/ui/Dialog.js.map +1 -0
  807. package/dist/esm/components/TextEditorV2/ui/DropDown.d.ts +17 -0
  808. package/dist/esm/components/TextEditorV2/ui/DropDown.js +129 -0
  809. package/dist/esm/components/TextEditorV2/ui/DropDown.js.map +1 -0
  810. package/dist/esm/components/TextEditorV2/ui/DropdownColorPicker.d.ts +21 -0
  811. package/dist/esm/components/TextEditorV2/ui/DropdownColorPicker.js +17 -0
  812. package/dist/esm/components/TextEditorV2/ui/DropdownColorPicker.js.map +1 -0
  813. package/dist/esm/components/TextEditorV2/ui/EquationEditor.d.ts +8 -0
  814. package/dist/esm/components/TextEditorV2/ui/EquationEditor.js +17 -0
  815. package/dist/esm/components/TextEditorV2/ui/EquationEditor.js.map +1 -0
  816. package/dist/esm/components/TextEditorV2/ui/FileInput.d.ts +9 -0
  817. package/dist/esm/components/TextEditorV2/ui/FileInput.js +8 -0
  818. package/dist/esm/components/TextEditorV2/ui/FileInput.js.map +1 -0
  819. package/dist/esm/components/TextEditorV2/ui/ImageResizer.d.ts +11 -0
  820. package/dist/esm/components/TextEditorV2/ui/ImageResizer.js +174 -0
  821. package/dist/esm/components/TextEditorV2/ui/ImageResizer.js.map +1 -0
  822. package/dist/esm/components/TextEditorV2/ui/KatexEquationAlterer.d.ts +7 -0
  823. package/dist/esm/components/TextEditorV2/ui/KatexEquationAlterer.js +35 -0
  824. package/dist/esm/components/TextEditorV2/ui/KatexEquationAlterer.js.map +1 -0
  825. package/dist/esm/components/TextEditorV2/ui/KatexRenderer.d.ts +6 -0
  826. package/dist/esm/components/TextEditorV2/ui/KatexRenderer.js +29 -0
  827. package/dist/esm/components/TextEditorV2/ui/KatexRenderer.js.map +1 -0
  828. package/dist/esm/components/TextEditorV2/ui/Modal.d.ts +8 -0
  829. package/dist/esm/components/TextEditorV2/ui/Modal.js +50 -0
  830. package/dist/esm/components/TextEditorV2/ui/Modal.js.map +1 -0
  831. package/dist/esm/components/TextEditorV2/ui/Placeholder.d.ts +6 -0
  832. package/dist/esm/components/TextEditorV2/ui/Placeholder.js +6 -0
  833. package/dist/esm/components/TextEditorV2/ui/Placeholder.js.map +1 -0
  834. package/dist/esm/components/TextEditorV2/ui/Select.d.ts +7 -0
  835. package/dist/esm/components/TextEditorV2/ui/Select.js +9 -0
  836. package/dist/esm/components/TextEditorV2/ui/Select.js.map +1 -0
  837. package/dist/esm/components/TextEditorV2/ui/Switch.d.ts +7 -0
  838. package/dist/esm/components/TextEditorV2/ui/Switch.js +11 -0
  839. package/dist/esm/components/TextEditorV2/ui/Switch.js.map +1 -0
  840. package/dist/esm/components/TextEditorV2/ui/TextInput.d.ts +12 -0
  841. package/dist/esm/components/TextEditorV2/ui/TextInput.js +10 -0
  842. package/dist/esm/components/TextEditorV2/ui/TextInput.js.map +1 -0
  843. package/dist/esm/components/TextEditorV2/utils/emoji-list.d.ts +20 -0
  844. package/dist/esm/components/TextEditorV2/utils/emoji-list.js +16605 -0
  845. package/dist/esm/components/TextEditorV2/utils/emoji-list.js.map +1 -0
  846. package/dist/esm/components/TextEditorV2/utils/getDOMRangeRect.d.ts +1 -0
  847. package/dist/esm/components/TextEditorV2/utils/getDOMRangeRect.js +16 -0
  848. package/dist/esm/components/TextEditorV2/utils/getDOMRangeRect.js.map +1 -0
  849. package/dist/esm/components/TextEditorV2/utils/getPrepopulatedRichText.d.ts +1 -0
  850. package/dist/esm/components/TextEditorV2/utils/getPrepopulatedRichText.js +32 -0
  851. package/dist/esm/components/TextEditorV2/utils/getPrepopulatedRichText.js.map +1 -0
  852. package/dist/esm/components/TextEditorV2/utils/getSelectedNode.d.ts +2 -0
  853. package/dist/esm/components/TextEditorV2/utils/getSelectedNode.js +18 -0
  854. package/dist/esm/components/TextEditorV2/utils/getSelectedNode.js.map +1 -0
  855. package/dist/esm/components/TextEditorV2/utils/guard.d.ts +1 -0
  856. package/dist/esm/components/TextEditorV2/utils/guard.js +4 -0
  857. package/dist/esm/components/TextEditorV2/utils/guard.js.map +1 -0
  858. package/dist/esm/components/TextEditorV2/utils/isMobileWidth.d.ts +0 -0
  859. package/dist/esm/components/TextEditorV2/utils/isMobileWidth.js +2 -0
  860. package/dist/esm/components/TextEditorV2/utils/isMobileWidth.js.map +1 -0
  861. package/dist/esm/components/TextEditorV2/utils/joinClasses.d.ts +1 -0
  862. package/dist/esm/components/TextEditorV2/utils/joinClasses.js +8 -0
  863. package/dist/esm/components/TextEditorV2/utils/joinClasses.js.map +1 -0
  864. package/dist/esm/components/TextEditorV2/utils/point.d.ts +14 -0
  865. package/dist/esm/components/TextEditorV2/utils/point.js +47 -0
  866. package/dist/esm/components/TextEditorV2/utils/point.js.map +1 -0
  867. package/dist/esm/components/TextEditorV2/utils/rect.d.ts +38 -0
  868. package/dist/esm/components/TextEditorV2/utils/rect.js +122 -0
  869. package/dist/esm/components/TextEditorV2/utils/rect.js.map +1 -0
  870. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPosition.d.ts +1 -0
  871. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPosition.js +30 -0
  872. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPosition.js.map +1 -0
  873. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.d.ts +1 -0
  874. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.js +28 -0
  875. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.js.map +1 -0
  876. package/dist/esm/components/TextEditorV2/utils/swipe.d.ts +4 -0
  877. package/dist/esm/components/TextEditorV2/utils/swipe.js +91 -0
  878. package/dist/esm/components/TextEditorV2/utils/swipe.js.map +1 -0
  879. package/dist/esm/components/TextEditorV2/utils/url.d.ts +2 -0
  880. package/dist/esm/components/TextEditorV2/utils/url.js +22 -0
  881. package/dist/esm/components/TextEditorV2/utils/url.js.map +1 -0
  882. package/dist/esm/index.d.ts +2 -1
  883. package/dist/esm/index.js +2 -1
  884. package/dist/esm/index.js.map +1 -1
  885. package/package.json +11 -2
@@ -0,0 +1,229 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.default = FloatingTextFormatToolbarPlugin;
4
+ var tslib_1 = require("tslib");
5
+ var code_1 = require("@lexical/code");
6
+ var link_1 = require("@lexical/link");
7
+ var LexicalComposerContext_1 = require("@lexical/react/LexicalComposerContext");
8
+ var utils_1 = require("@lexical/utils");
9
+ var lexical_1 = require("lexical");
10
+ var react_1 = require("react");
11
+ var React = tslib_1.__importStar(require("react"));
12
+ var react_dom_1 = require("react-dom");
13
+ var getDOMRangeRect_1 = require("../../utils/getDOMRangeRect");
14
+ var getSelectedNode_1 = require("../../utils/getSelectedNode");
15
+ var setFloatingElemPosition_1 = require("../../utils/setFloatingElemPosition");
16
+ function TextFormatFloatingToolbar(_a) {
17
+ var anchorElem = _a.anchorElem, editor = _a.editor, isBold = _a.isBold, isCode = _a.isCode, isItalic = _a.isItalic, isLink = _a.isLink, isStrikethrough = _a.isStrikethrough, isSubscript = _a.isSubscript, isSuperscript = _a.isSuperscript, isUnderline = _a.isUnderline;
18
+ var popupCharStylesEditorRef = (0, react_1.useRef)(null);
19
+ var insertLink = (0, react_1.useCallback)(function () {
20
+ if (!isLink) {
21
+ editor.dispatchCommand(link_1.TOGGLE_LINK_COMMAND, 'https://');
22
+ }
23
+ else {
24
+ editor.dispatchCommand(link_1.TOGGLE_LINK_COMMAND, null);
25
+ }
26
+ }, [editor, isLink]);
27
+ var insertComment = function () {
28
+ console.log('insert comment');
29
+ };
30
+ function mouseMoveListener(e) {
31
+ if ((popupCharStylesEditorRef === null || popupCharStylesEditorRef === void 0 ? void 0 : popupCharStylesEditorRef.current) && (e.buttons === 1 || e.buttons === 3)) {
32
+ if (popupCharStylesEditorRef.current.style.pointerEvents !== 'none') {
33
+ var x = e.clientX;
34
+ var y = e.clientY;
35
+ var elementUnderMouse = document.elementFromPoint(x, y);
36
+ if (!popupCharStylesEditorRef.current.contains(elementUnderMouse)) {
37
+ // Mouse is not over the target element => not a normal click, but probably a drag
38
+ popupCharStylesEditorRef.current.style.pointerEvents = 'none';
39
+ }
40
+ }
41
+ }
42
+ }
43
+ function mouseUpListener() {
44
+ if (popupCharStylesEditorRef === null || popupCharStylesEditorRef === void 0 ? void 0 : popupCharStylesEditorRef.current) {
45
+ if (popupCharStylesEditorRef.current.style.pointerEvents !== 'auto') {
46
+ popupCharStylesEditorRef.current.style.pointerEvents = 'auto';
47
+ }
48
+ }
49
+ }
50
+ (0, react_1.useEffect)(function () {
51
+ if (popupCharStylesEditorRef === null || popupCharStylesEditorRef === void 0 ? void 0 : popupCharStylesEditorRef.current) {
52
+ document.addEventListener('mousemove', mouseMoveListener);
53
+ document.addEventListener('mouseup', mouseUpListener);
54
+ return function () {
55
+ document.removeEventListener('mousemove', mouseMoveListener);
56
+ document.removeEventListener('mouseup', mouseUpListener);
57
+ };
58
+ }
59
+ return function () {
60
+ console.log('clean up');
61
+ };
62
+ }, [popupCharStylesEditorRef]);
63
+ var updateTextFormatFloatingToolbar = (0, react_1.useCallback)(function () {
64
+ var selection = (0, lexical_1.$getSelection)();
65
+ var popupCharStylesEditorElem = popupCharStylesEditorRef.current;
66
+ var nativeSelection = window.getSelection();
67
+ if (popupCharStylesEditorElem === null) {
68
+ return;
69
+ }
70
+ var rootElement = editor.getRootElement();
71
+ if (selection !== null &&
72
+ nativeSelection !== null &&
73
+ !nativeSelection.isCollapsed &&
74
+ rootElement !== null &&
75
+ rootElement.contains(nativeSelection.anchorNode)) {
76
+ var rangeRect = (0, getDOMRangeRect_1.getDOMRangeRect)(nativeSelection, rootElement);
77
+ (0, setFloatingElemPosition_1.setFloatingElemPosition)(rangeRect, popupCharStylesEditorElem, anchorElem, isLink);
78
+ }
79
+ }, [editor, anchorElem, isLink]);
80
+ (0, react_1.useEffect)(function () {
81
+ var scrollerElem = anchorElem.parentElement;
82
+ var update = function () {
83
+ editor.getEditorState().read(function () {
84
+ updateTextFormatFloatingToolbar();
85
+ });
86
+ };
87
+ window.addEventListener('resize', update);
88
+ if (scrollerElem) {
89
+ scrollerElem.addEventListener('scroll', update);
90
+ }
91
+ return function () {
92
+ window.removeEventListener('resize', update);
93
+ if (scrollerElem) {
94
+ scrollerElem.removeEventListener('scroll', update);
95
+ }
96
+ };
97
+ }, [editor, updateTextFormatFloatingToolbar, anchorElem]);
98
+ (0, react_1.useEffect)(function () {
99
+ editor.getEditorState().read(function () {
100
+ updateTextFormatFloatingToolbar();
101
+ });
102
+ return (0, utils_1.mergeRegister)(editor.registerUpdateListener(function (_a) {
103
+ var editorState = _a.editorState;
104
+ editorState.read(function () {
105
+ updateTextFormatFloatingToolbar();
106
+ });
107
+ }), editor.registerCommand(lexical_1.SELECTION_CHANGE_COMMAND, function () {
108
+ updateTextFormatFloatingToolbar();
109
+ return false;
110
+ }, lexical_1.COMMAND_PRIORITY_LOW));
111
+ }, [editor, updateTextFormatFloatingToolbar]);
112
+ return (React.createElement("div", { ref: popupCharStylesEditorRef, className: 'floating-text-format-popup' },
113
+ editor.isEditable() && (React.createElement(React.Fragment, null,
114
+ React.createElement("button", { "aria-label": 'Format text as bold', className: 'popup-item spaced ' + (isBold ? 'active' : ''), onClick: function () {
115
+ editor.dispatchCommand(lexical_1.FORMAT_TEXT_COMMAND, 'bold');
116
+ }, type: 'button' },
117
+ React.createElement("i", { className: 'format bold' })),
118
+ React.createElement("button", { "aria-label": 'Format text as italics', className: 'popup-item spaced ' + (isItalic ? 'active' : ''), onClick: function () {
119
+ editor.dispatchCommand(lexical_1.FORMAT_TEXT_COMMAND, 'italic');
120
+ }, type: 'button' },
121
+ React.createElement("i", { className: 'format italic' })),
122
+ React.createElement("button", { "aria-label": 'Format text to underlined', className: 'popup-item spaced ' + (isUnderline ? 'active' : ''), onClick: function () {
123
+ editor.dispatchCommand(lexical_1.FORMAT_TEXT_COMMAND, 'underline');
124
+ }, type: 'button' },
125
+ React.createElement("i", { className: 'format underline' })),
126
+ React.createElement("button", { "aria-label": 'Format text with a strikethrough', className: 'popup-item spaced ' + (isStrikethrough ? 'active' : ''), onClick: function () {
127
+ editor.dispatchCommand(lexical_1.FORMAT_TEXT_COMMAND, 'strikethrough');
128
+ }, type: 'button' },
129
+ React.createElement("i", { className: 'format strikethrough' })),
130
+ React.createElement("button", { "aria-label": 'Format Subscript', className: 'popup-item spaced ' + (isSubscript ? 'active' : ''), onClick: function () {
131
+ editor.dispatchCommand(lexical_1.FORMAT_TEXT_COMMAND, 'subscript');
132
+ }, title: 'Subscript', type: 'button' },
133
+ React.createElement("i", { className: 'format subscript' })),
134
+ React.createElement("button", { "aria-label": 'Format Superscript', className: 'popup-item spaced ' + (isSuperscript ? 'active' : ''), onClick: function () {
135
+ editor.dispatchCommand(lexical_1.FORMAT_TEXT_COMMAND, 'superscript');
136
+ }, title: 'Superscript', type: 'button' },
137
+ React.createElement("i", { className: 'format superscript' })),
138
+ React.createElement("button", { "aria-label": 'Insert code block', className: 'popup-item spaced ' + (isCode ? 'active' : ''), onClick: function () {
139
+ editor.dispatchCommand(lexical_1.FORMAT_TEXT_COMMAND, 'code');
140
+ }, type: 'button' },
141
+ React.createElement("i", { className: 'format code' })),
142
+ React.createElement("button", { "aria-label": 'Insert link', className: 'popup-item spaced ' + (isLink ? 'active' : ''), onClick: insertLink, type: 'button' },
143
+ React.createElement("i", { className: 'format link' })))),
144
+ React.createElement("button", { "aria-label": 'Insert comment', className: 'popup-item spaced insert-comment', onClick: insertComment, type: 'button' },
145
+ React.createElement("i", { className: 'format add-comment' }))));
146
+ }
147
+ function useFloatingTextFormatToolbar(editor, anchorElem) {
148
+ var _a = (0, react_1.useState)(false), isText = _a[0], setIsText = _a[1];
149
+ var _b = (0, react_1.useState)(false), isLink = _b[0], setIsLink = _b[1];
150
+ var _c = (0, react_1.useState)(false), isBold = _c[0], setIsBold = _c[1];
151
+ var _d = (0, react_1.useState)(false), isItalic = _d[0], setIsItalic = _d[1];
152
+ var _e = (0, react_1.useState)(false), isUnderline = _e[0], setIsUnderline = _e[1];
153
+ var _f = (0, react_1.useState)(false), isStrikethrough = _f[0], setIsStrikethrough = _f[1];
154
+ var _g = (0, react_1.useState)(false), isSubscript = _g[0], setIsSubscript = _g[1];
155
+ var _h = (0, react_1.useState)(false), isSuperscript = _h[0], setIsSuperscript = _h[1];
156
+ var _j = (0, react_1.useState)(false), isCode = _j[0], setIsCode = _j[1];
157
+ var updatePopup = (0, react_1.useCallback)(function () {
158
+ editor.getEditorState().read(function () {
159
+ // Should not to pop up the floating toolbar when using IME input
160
+ if (editor.isComposing()) {
161
+ return;
162
+ }
163
+ var selection = (0, lexical_1.$getSelection)();
164
+ var nativeSelection = window.getSelection();
165
+ var rootElement = editor.getRootElement();
166
+ if (nativeSelection !== null &&
167
+ (!(0, lexical_1.$isRangeSelection)(selection) || rootElement === null || !rootElement.contains(nativeSelection.anchorNode))) {
168
+ setIsText(false);
169
+ return;
170
+ }
171
+ if (!(0, lexical_1.$isRangeSelection)(selection)) {
172
+ return;
173
+ }
174
+ var node = (0, getSelectedNode_1.getSelectedNode)(selection);
175
+ // Update text format
176
+ setIsBold(selection.hasFormat('bold'));
177
+ setIsItalic(selection.hasFormat('italic'));
178
+ setIsUnderline(selection.hasFormat('underline'));
179
+ setIsStrikethrough(selection.hasFormat('strikethrough'));
180
+ setIsSubscript(selection.hasFormat('subscript'));
181
+ setIsSuperscript(selection.hasFormat('superscript'));
182
+ setIsCode(selection.hasFormat('code'));
183
+ // Update links
184
+ var parent = node.getParent();
185
+ if ((0, link_1.$isLinkNode)(parent) || (0, link_1.$isLinkNode)(node)) {
186
+ setIsLink(true);
187
+ }
188
+ else {
189
+ setIsLink(false);
190
+ }
191
+ if (!(0, code_1.$isCodeHighlightNode)(selection.anchor.getNode()) && selection.getTextContent() !== '') {
192
+ setIsText((0, lexical_1.$isTextNode)(node) || (0, lexical_1.$isParagraphNode)(node));
193
+ }
194
+ else {
195
+ setIsText(false);
196
+ }
197
+ var rawTextContent = selection.getTextContent().replace(/\n/g, '');
198
+ if (!selection.isCollapsed() && rawTextContent === '') {
199
+ setIsText(false);
200
+ return;
201
+ }
202
+ });
203
+ }, [editor]);
204
+ (0, react_1.useEffect)(function () {
205
+ document.addEventListener('selectionchange', updatePopup);
206
+ return function () {
207
+ document.removeEventListener('selectionchange', updatePopup);
208
+ };
209
+ }, [updatePopup]);
210
+ (0, react_1.useEffect)(function () {
211
+ return (0, utils_1.mergeRegister)(editor.registerUpdateListener(function () {
212
+ updatePopup();
213
+ }), editor.registerRootListener(function () {
214
+ if (editor.getRootElement() === null) {
215
+ setIsText(false);
216
+ }
217
+ }));
218
+ }, [editor, updatePopup]);
219
+ if (!isText) {
220
+ return null;
221
+ }
222
+ return (0, react_dom_1.createPortal)(React.createElement(TextFormatFloatingToolbar, { anchorElem: anchorElem, editor: editor, isBold: isBold, isCode: isCode, isItalic: isItalic, isLink: isLink, isStrikethrough: isStrikethrough, isSubscript: isSubscript, isSuperscript: isSuperscript, isUnderline: isUnderline }), anchorElem);
223
+ }
224
+ function FloatingTextFormatToolbarPlugin(_a) {
225
+ var _b = _a.anchorElem, anchorElem = _b === void 0 ? document.body : _b;
226
+ var editor = (0, LexicalComposerContext_1.useLexicalComposerContext)()[0];
227
+ return useFloatingTextFormatToolbar(editor, anchorElem);
228
+ }
229
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.tsx"],"names":[],"mappings":";;AAmXA,kDAOC;;AA1XD,sCAAoD;AACpD,sCAAgE;AAChE,gFAAiF;AACjF,wCAA8C;AAC9C,mCASgB;AAChB,+BAAgE;AAChE,mDAA8B;AAC9B,uCAA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AW,CAAC,CAAA;QAC9D,CAAC,CAAA;IACH,CAAC,EAAE,CAAC,WAAW,CAAC,CAAC,CAAA;IAEjB,IAAA,iBAAS,EACP;QACE,OAAA,IAAA,qBAAa,EACX,MAAM,CAAC,sBAAsB,CAAC;YAC5B,WAAW,EAAE,CAAA;QACf,CAAC,CAAC,EACF,MAAM,CAAC,oBAAoB,CAAC;YAC1B,IAAI,MAAM,CAAC,cAAc,EAAE,KAAK,IAAI,EAAE,CAAC;gBACrC,SAAS,CAAC,KAAK,CAAC,CAAA;YAClB,CAAC;QACH,CAAC,CAAC,CACH;IATD,CASC,EACH,CAAC,MAAM,EAAE,WAAW,CAAC,CACtB,CAAA;IAED,IAAI,CAAC,MAAM,EAAE,CAAC;QACZ,OAAO,IAAI,CAAA;IACb,CAAC;IAED,OAAO,IAAA,wBAAY,EACjB,oBAAC,yBAAyB,IACxB,UAAU,EAAE,UAAU,EACtB,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,MAAM,EACd,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,QAAQ,EAClB,MAAM,EAAE,MAAM,EACd,eAAe,EAAE,eAAe,EAChC,WAAW,EAAE,WAAW,EACxB,aAAa,EAAE,aAAa,EAC5B,WAAW,EAAE,WAAW,GACxB,EACF,UAAU,CACX,CAAA;AACH,CAAC;AAED,SAAwB,+BAA+B,CAAC,EAIvD;QAHC,kBAA0B,EAA1B,UAAU,mBAAG,QAAQ,CAAC,IAAI,KAAA;IAInB,IAAA,MAAM,GAAI,IAAA,kDAAyB,GAAE,GAA/B,CAA+B;IAC5C,OAAO,4BAA4B,CAAC,MAAM,EAAE,UAAU,CAAC,CAAA;AACzD,CAAC"}
@@ -0,0 +1,22 @@
1
+ import { LexicalCommand, LexicalEditor } from 'lexical';
2
+ import * as React from 'react';
3
+ import { ImagePayload } from '../../nodes/ImageNode';
4
+ export type InsertImagePayload = Readonly<ImagePayload>;
5
+ export declare const INSERT_IMAGE_COMMAND: LexicalCommand<InsertImagePayload>;
6
+ export declare function InsertImageUriDialogBody({ onClick }: {
7
+ onClick(payload: InsertImagePayload): void;
8
+ }): React.JSX.Element;
9
+ export declare function InsertImageModal({ activeEditor, setShow, show, }: {
10
+ activeEditor: LexicalEditor;
11
+ show: boolean;
12
+ setShow: any;
13
+ }): React.JSX.Element;
14
+ export default function ImagesPlugin({ captionsEnabled }: {
15
+ captionsEnabled?: boolean;
16
+ }): React.JSX.Element | null;
17
+ declare global {
18
+ interface DragEvent {
19
+ rangeOffset?: number;
20
+ rangeParent?: Node;
21
+ }
22
+ }
@@ -0,0 +1,188 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.INSERT_IMAGE_COMMAND = void 0;
4
+ exports.InsertImageUriDialogBody = InsertImageUriDialogBody;
5
+ exports.InsertImageModal = InsertImageModal;
6
+ exports.default = ImagesPlugin;
7
+ var tslib_1 = require("tslib");
8
+ var LexicalComposerContext_1 = require("@lexical/react/LexicalComposerContext");
9
+ var utils_1 = require("@lexical/utils");
10
+ var lexical_1 = require("lexical");
11
+ var react_1 = require("react");
12
+ var React = tslib_1.__importStar(require("react"));
13
+ var ImageNode_1 = require("../../nodes/ImageNode");
14
+ var canUseDOM_1 = require("../../shared/canUseDOM");
15
+ var Button_1 = tslib_1.__importDefault(require("../../ui/Button"));
16
+ var Dialog_1 = require("../../ui/Dialog");
17
+ var TextInput_1 = tslib_1.__importDefault(require("../../ui/TextInput"));
18
+ var Modal_1 = require("../../../Modal");
19
+ var Input_1 = require("../../../Input");
20
+ var UploadFile_1 = require("../../../UploadFile");
21
+ var getDOMSelection = function (targetWindow) {
22
+ return canUseDOM_1.CAN_USE_DOM ? (targetWindow || window).getSelection() : null;
23
+ };
24
+ exports.INSERT_IMAGE_COMMAND = (0, lexical_1.createCommand)('INSERT_IMAGE_COMMAND');
25
+ function InsertImageUriDialogBody(_a) {
26
+ var onClick = _a.onClick;
27
+ var _b = (0, react_1.useState)(''), src = _b[0], setSrc = _b[1];
28
+ var _c = (0, react_1.useState)(''), altText = _c[0], setAltText = _c[1];
29
+ var isDisabled = src === '';
30
+ return (React.createElement(React.Fragment, null,
31
+ React.createElement(TextInput_1.default, { "data-test-id": 'image-modal-url-input', label: 'Image URL', onChange: setSrc, placeholder: 'i.e. https://source.unsplash.com/random', value: src }),
32
+ React.createElement(TextInput_1.default, { "data-test-id": 'image-modal-alt-text-input', label: 'Alt Text', onChange: setAltText, placeholder: 'Random unsplash image', value: altText }),
33
+ React.createElement(Dialog_1.DialogActions, null,
34
+ React.createElement(Button_1.default, { "data-test-id": 'image-modal-confirm-btn', disabled: isDisabled, onClick: function () { return onClick({ altText: altText, src: src }); } }, "Confirm"))));
35
+ }
36
+ function InsertImageModal(_a) {
37
+ var activeEditor = _a.activeEditor, setShow = _a.setShow, show = _a.show;
38
+ var _b = (0, react_1.useState)(''), fileName = _b[0], setFileName = _b[1];
39
+ var _c = (0, react_1.useState)(''), cdnLink = _c[0], setCdnLink = _c[1];
40
+ var altText = 'photo';
41
+ var onHide = function () {
42
+ setShow(false);
43
+ setCdnLink('');
44
+ setFileName('');
45
+ };
46
+ var handleListenUpload = function (fileUpload, linkCdn) {
47
+ setFileName(fileUpload.name);
48
+ setCdnLink(linkCdn[0]);
49
+ };
50
+ var handleSubmit = function () {
51
+ activeEditor.dispatchCommand(exports.INSERT_IMAGE_COMMAND, { altText: altText, src: cdnLink });
52
+ onHide();
53
+ };
54
+ return (React.createElement(Modal_1.PHXModal, { onHide: onHide, onPrimaryClick: handleSubmit, show: show, title: 'Insert Image' },
55
+ React.createElement("div", { className: 'space-y-4' },
56
+ React.createElement(Input_1.PHXInput, { defaultValue: altText, label: 'Alt Text', onChange: function (e) { return (altText = e.target.value); } }),
57
+ React.createElement(UploadFile_1.PHXUploadFile, { apiCdnUpload: '/api/cdn-upload', basePath: '', defaultLink: [cdnLink], fileName: fileName, fileType: 'image', handleListenUpload: handleListenUpload, inCard: false, label: 'Image upload', moduleId: 'insert-editor-image', oneImg: true, projectId: 'phenikaa', titleHeaderAction: '' }))));
58
+ }
59
+ function ImagesPlugin(_a) {
60
+ var captionsEnabled = _a.captionsEnabled;
61
+ var editor = (0, LexicalComposerContext_1.useLexicalComposerContext)()[0];
62
+ (0, react_1.useEffect)(function () {
63
+ if (!editor.hasNodes([ImageNode_1.ImageNode])) {
64
+ throw new Error('ImagesPlugin: ImageNode not registered on editor');
65
+ }
66
+ return (0, utils_1.mergeRegister)(editor.registerCommand(exports.INSERT_IMAGE_COMMAND, function (payload) {
67
+ var imageNode = (0, ImageNode_1.$createImageNode)(payload);
68
+ (0, lexical_1.$insertNodes)([imageNode]);
69
+ if ((0, lexical_1.$isRootOrShadowRoot)(imageNode.getParentOrThrow())) {
70
+ (0, utils_1.$wrapNodeInElement)(imageNode, lexical_1.$createParagraphNode).selectEnd();
71
+ }
72
+ return true;
73
+ }, lexical_1.COMMAND_PRIORITY_EDITOR), editor.registerCommand(lexical_1.DRAGSTART_COMMAND, function (event) { return onDragStart(event); }, lexical_1.COMMAND_PRIORITY_HIGH), editor.registerCommand(lexical_1.DRAGOVER_COMMAND, function (event) { return onDragover(event); }, lexical_1.COMMAND_PRIORITY_LOW), editor.registerCommand(lexical_1.DROP_COMMAND, function (event) { return onDrop(event, editor); }, lexical_1.COMMAND_PRIORITY_HIGH));
74
+ }, [captionsEnabled, editor]);
75
+ return null;
76
+ }
77
+ var TRANSPARENT_IMAGE = 'data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7';
78
+ function onDragStart(event) {
79
+ var img = document.createElement('img');
80
+ img.src = TRANSPARENT_IMAGE;
81
+ var node = getImageNodeInSelection();
82
+ if (!node) {
83
+ return false;
84
+ }
85
+ var dataTransfer = event.dataTransfer;
86
+ if (!dataTransfer) {
87
+ return false;
88
+ }
89
+ dataTransfer.setData('text/plain', '_');
90
+ dataTransfer.setDragImage(img, 0, 0);
91
+ dataTransfer.setData('application/x-lexical-drag', JSON.stringify({
92
+ data: {
93
+ altText: node.__altText,
94
+ caption: node.__caption,
95
+ height: node.__height,
96
+ key: node.getKey(),
97
+ maxWidth: node.__maxWidth,
98
+ showCaption: node.__showCaption,
99
+ src: node.__src,
100
+ width: node.__width,
101
+ },
102
+ type: 'image',
103
+ }));
104
+ return true;
105
+ }
106
+ function onDragover(event) {
107
+ var node = getImageNodeInSelection();
108
+ if (!node) {
109
+ return false;
110
+ }
111
+ if (!canDropImage(event)) {
112
+ event.preventDefault();
113
+ }
114
+ return true;
115
+ }
116
+ function onDrop(event, editor) {
117
+ var node = getImageNodeInSelection();
118
+ if (!node) {
119
+ return false;
120
+ }
121
+ var data = getDragImageData(event);
122
+ if (!data) {
123
+ return false;
124
+ }
125
+ event.preventDefault();
126
+ if (canDropImage(event)) {
127
+ var range = getDragSelection(event);
128
+ node.remove();
129
+ var rangeSelection = (0, lexical_1.$createRangeSelection)();
130
+ if (range !== null && range !== undefined) {
131
+ rangeSelection.applyDOMRange(range);
132
+ }
133
+ (0, lexical_1.$setSelection)(rangeSelection);
134
+ editor.dispatchCommand(exports.INSERT_IMAGE_COMMAND, data);
135
+ }
136
+ return true;
137
+ }
138
+ function getImageNodeInSelection() {
139
+ var selection = (0, lexical_1.$getSelection)();
140
+ if (!(0, lexical_1.$isNodeSelection)(selection)) {
141
+ return null;
142
+ }
143
+ var nodes = selection.getNodes();
144
+ var node = nodes[0];
145
+ return (0, ImageNode_1.$isImageNode)(node) ? node : null;
146
+ }
147
+ function getDragImageData(event) {
148
+ var _a;
149
+ var dragData = (_a = event.dataTransfer) === null || _a === void 0 ? void 0 : _a.getData('application/x-lexical-drag');
150
+ if (!dragData) {
151
+ return null;
152
+ }
153
+ var _b = JSON.parse(dragData), data = _b.data, type = _b.type;
154
+ if (type !== 'image') {
155
+ return null;
156
+ }
157
+ return data;
158
+ }
159
+ function canDropImage(event) {
160
+ var target = event.target;
161
+ return !!(target &&
162
+ target instanceof HTMLElement &&
163
+ !target.closest('code, span.editor-image') &&
164
+ target.parentElement &&
165
+ target.parentElement.closest('div.ContentEditable__root'));
166
+ }
167
+ function getDragSelection(event) {
168
+ var range;
169
+ var target = event.target;
170
+ var targetWindow = target == null
171
+ ? null
172
+ : target.nodeType === 9
173
+ ? target.defaultView
174
+ : target.ownerDocument.defaultView;
175
+ var domSelection = getDOMSelection(targetWindow);
176
+ if (document.caretRangeFromPoint) {
177
+ range = document.caretRangeFromPoint(event.clientX, event.clientY);
178
+ }
179
+ else if (event.rangeParent && domSelection !== null) {
180
+ domSelection.collapse(event.rangeParent, event.rangeOffset || 0);
181
+ range = domSelection.getRangeAt(0);
182
+ }
183
+ else {
184
+ throw Error("Cannot get the selection when dragging");
185
+ }
186
+ return range;
187
+ }
188
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/components/TextEditorV2/plugins/ImagesPlugin/index.tsx"],"names":[],"mappings":";;;AAsCA,4DA6BC;AAED,4CAkDC;AAED,+BA6BC;;AAtJD,gFAAiF;AACjF,wCAAkE;AAClE,mCAiBgB;AAChB,+BAA2C;AAC3C,mDAA8B;AAC9B,mDAA+F;AAC/F,oDAAoD;AACpD,mEAAoC;AACpC,0CAA+C;AAC/C,yEAA0C;AAC1C,wCAAyC;AACzC,wCAAyC;AACzC,kDAAmD;AAInD,IAAM,eAAe,GAAG,UAAC,YAA2B;IAClD,OAAA,uBAAW,CAAC,CAAC,CAAC,CAAC,YAAY,IAAI,MAAM,CAAC,CAAC,YAAY,EAAE,CAAC,CAAC,CAAC,IAAI;AAA5D,CAA4D,CAAA;AAEjD,QAAA,oBAAoB,GAAuC,IAAA,uBAAa,EAAC,sBAAsB,CAAC,CAAA;AAE7G,SAAgB,wBAAwB,CAAC,EAA2D;QAAzD,OAAO,aAAA;IAC1C,IAAA,KAAgB,IAAA,gBAAQ,EAAC,EAAE,CAAC,EAA3B,GAAG,QAAA,EAAE,MAAM,QAAgB,CAAA;IAC5B,IAAA,KAAw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}
@@ -0,0 +1,17 @@
1
+ import { LexicalCommand, LexicalEditor } from 'lexical';
2
+ import * as React from 'react';
3
+ import { InlineImagePayload } from '../../nodes/InlineImageNode';
4
+ export type InsertInlineImagePayload = Readonly<InlineImagePayload>;
5
+ export declare const INSERT_INLINE_IMAGE_COMMAND: LexicalCommand<InlineImagePayload>;
6
+ export declare function InsertInlineImageModal({ activeEditor, setShow, show, }: {
7
+ activeEditor: LexicalEditor;
8
+ show: boolean;
9
+ setShow: any;
10
+ }): React.JSX.Element;
11
+ export default function InlineImagePlugin(): React.JSX.Element | null;
12
+ declare global {
13
+ interface DragEvent {
14
+ rangeOffset?: number;
15
+ rangeParent?: Node;
16
+ }
17
+ }