phx-react 1.3.1569 → 1.3.1571

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 (855) hide show
  1. package/dist/cjs/components/Combobox/Combobox.js +9 -3
  2. package/dist/cjs/components/Combobox/Combobox.js.map +1 -1
  3. package/dist/cjs/components/TextEditorV2/commenting/index.d.ts +41 -0
  4. package/dist/cjs/components/TextEditorV2/commenting/index.js +340 -0
  5. package/dist/cjs/components/TextEditorV2/commenting/index.js.map +1 -0
  6. package/dist/cjs/components/TextEditorV2/constants.d.ts +1 -0
  7. package/dist/cjs/components/TextEditorV2/constants.js +5 -0
  8. package/dist/cjs/components/TextEditorV2/constants.js.map +1 -0
  9. package/dist/cjs/components/TextEditorV2/context/SettingsContext.d.ts +12 -0
  10. package/dist/cjs/components/TextEditorV2/context/SettingsContext.js +59 -0
  11. package/dist/cjs/components/TextEditorV2/context/SettingsContext.js.map +1 -0
  12. package/dist/cjs/components/TextEditorV2/context/SharedAutocompleteContext.d.ts +10 -0
  13. package/dist/cjs/components/TextEditorV2/context/SharedAutocompleteContext.js +50 -0
  14. package/dist/cjs/components/TextEditorV2/context/SharedAutocompleteContext.js.map +1 -0
  15. package/dist/cjs/components/TextEditorV2/context/SharedHistoryContext.d.ts +11 -0
  16. package/dist/cjs/components/TextEditorV2/context/SharedHistoryContext.js +17 -0
  17. package/dist/cjs/components/TextEditorV2/context/SharedHistoryContext.js.map +1 -0
  18. package/dist/cjs/components/TextEditorV2/editor.d.ts +10 -0
  19. package/dist/cjs/components/TextEditorV2/editor.js +203 -0
  20. package/dist/cjs/components/TextEditorV2/editor.js.map +1 -0
  21. package/dist/cjs/components/TextEditorV2/hooks/useModal.d.ts +5 -0
  22. package/dist/cjs/components/TextEditorV2/hooks/useModal.js +32 -0
  23. package/dist/cjs/components/TextEditorV2/hooks/useModal.js.map +1 -0
  24. package/dist/cjs/components/TextEditorV2/hooks/useReport.d.ts +1 -0
  25. package/dist/cjs/components/TextEditorV2/hooks/useReport.js +45 -0
  26. package/dist/cjs/components/TextEditorV2/hooks/useReport.js.map +1 -0
  27. package/dist/cjs/components/TextEditorV2/lib/Settings.d.ts +2 -0
  28. package/dist/cjs/components/TextEditorV2/lib/Settings.js +52 -0
  29. package/dist/cjs/components/TextEditorV2/lib/Settings.js.map +1 -0
  30. package/dist/cjs/components/TextEditorV2/lib/appSettings.d.ts +19 -0
  31. package/dist/cjs/components/TextEditorV2/lib/appSettings.js +21 -0
  32. package/dist/cjs/components/TextEditorV2/lib/appSettings.js.map +1 -0
  33. package/dist/cjs/components/TextEditorV2/lib/collaboration.d.ts +3 -0
  34. package/dist/cjs/components/TextEditorV2/lib/collaboration.js +26 -0
  35. package/dist/cjs/components/TextEditorV2/lib/collaboration.js.map +1 -0
  36. package/dist/cjs/components/TextEditorV2/lib/setupEnv.d.ts +1 -0
  37. package/dist/cjs/components/TextEditorV2/lib/setupEnv.js +23 -0
  38. package/dist/cjs/components/TextEditorV2/lib/setupEnv.js.map +1 -0
  39. package/dist/cjs/components/TextEditorV2/nodes/AutocompleteNode.d.ts +25 -0
  40. package/dist/cjs/components/TextEditorV2/nodes/AutocompleteNode.js +58 -0
  41. package/dist/cjs/components/TextEditorV2/nodes/AutocompleteNode.js.map +1 -0
  42. package/dist/cjs/components/TextEditorV2/nodes/EmojiNode.d.ts +18 -0
  43. package/dist/cjs/components/TextEditorV2/nodes/EmojiNode.js +62 -0
  44. package/dist/cjs/components/TextEditorV2/nodes/EmojiNode.js.map +1 -0
  45. package/dist/cjs/components/TextEditorV2/nodes/EquationComponent.d.ts +9 -0
  46. package/dist/cjs/components/TextEditorV2/nodes/EquationComponent.js +72 -0
  47. package/dist/cjs/components/TextEditorV2/nodes/EquationComponent.js.map +1 -0
  48. package/dist/cjs/components/TextEditorV2/nodes/EquationNode.d.ts +26 -0
  49. package/dist/cjs/components/TextEditorV2/nodes/EquationNode.js +126 -0
  50. package/dist/cjs/components/TextEditorV2/nodes/EquationNode.js.map +1 -0
  51. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.d.ts +6 -0
  52. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.js +117 -0
  53. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.js.map +1 -0
  54. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.d.ts +50 -0
  55. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.js +59 -0
  56. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.js.map +1 -0
  57. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.d.ts +44 -0
  58. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.js +143 -0
  59. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.js.map +1 -0
  60. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/index.d.ts +22 -0
  61. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/index.js +103 -0
  62. package/dist/cjs/components/TextEditorV2/nodes/ExcalidrawNode/index.js.map +1 -0
  63. package/dist/cjs/components/TextEditorV2/nodes/ExtendedTextNode.d.ts +12 -0
  64. package/dist/cjs/components/TextEditorV2/nodes/ExtendedTextNode.js +106 -0
  65. package/dist/cjs/components/TextEditorV2/nodes/ExtendedTextNode.js.map +1 -0
  66. package/dist/cjs/components/TextEditorV2/nodes/FigmaNode.d.ts +19 -0
  67. package/dist/cjs/components/TextEditorV2/nodes/FigmaNode.js +63 -0
  68. package/dist/cjs/components/TextEditorV2/nodes/FigmaNode.js.map +1 -0
  69. package/dist/cjs/components/TextEditorV2/nodes/ImageComponent.d.ts +14 -0
  70. package/dist/cjs/components/TextEditorV2/nodes/ImageComponent.js +212 -0
  71. package/dist/cjs/components/TextEditorV2/nodes/ImageComponent.js.map +1 -0
  72. package/dist/cjs/components/TextEditorV2/nodes/ImageNode.d.ts +56 -0
  73. package/dist/cjs/components/TextEditorV2/nodes/ImageNode.js +136 -0
  74. package/dist/cjs/components/TextEditorV2/nodes/ImageNode.js.map +1 -0
  75. package/dist/cjs/components/TextEditorV2/nodes/InlineImageComponent.d.ts +18 -0
  76. package/dist/cjs/components/TextEditorV2/nodes/InlineImageComponent.js +194 -0
  77. package/dist/cjs/components/TextEditorV2/nodes/InlineImageComponent.js.map +1 -0
  78. package/dist/cjs/components/TextEditorV2/nodes/InlineImageNode.d.ts +54 -0
  79. package/dist/cjs/components/TextEditorV2/nodes/InlineImageNode.js +142 -0
  80. package/dist/cjs/components/TextEditorV2/nodes/InlineImageNode.js.map +1 -0
  81. package/dist/cjs/components/TextEditorV2/nodes/KeywordNode.d.ts +15 -0
  82. package/dist/cjs/components/TextEditorV2/nodes/KeywordNode.js +54 -0
  83. package/dist/cjs/components/TextEditorV2/nodes/KeywordNode.js.map +1 -0
  84. package/dist/cjs/components/TextEditorV2/nodes/LayoutContainerNode.d.ts +21 -0
  85. package/dist/cjs/components/TextEditorV2/nodes/LayoutContainerNode.js +63 -0
  86. package/dist/cjs/components/TextEditorV2/nodes/LayoutContainerNode.js.map +1 -0
  87. package/dist/cjs/components/TextEditorV2/nodes/LayoutItemNode.d.ts +15 -0
  88. package/dist/cjs/components/TextEditorV2/nodes/LayoutItemNode.js +51 -0
  89. package/dist/cjs/components/TextEditorV2/nodes/LayoutItemNode.js.map +1 -0
  90. package/dist/cjs/components/TextEditorV2/nodes/MentionNode.d.ts +20 -0
  91. package/dist/cjs/components/TextEditorV2/nodes/MentionNode.js +89 -0
  92. package/dist/cjs/components/TextEditorV2/nodes/MentionNode.js.map +1 -0
  93. package/dist/cjs/components/TextEditorV2/nodes/PageBreakNode/index.d.ts +17 -0
  94. package/dist/cjs/components/TextEditorV2/nodes/PageBreakNode/index.js +113 -0
  95. package/dist/cjs/components/TextEditorV2/nodes/PageBreakNode/index.js.map +1 -0
  96. package/dist/cjs/components/TextEditorV2/nodes/PlaygroundNodes.d.ts +3 -0
  97. package/dist/cjs/components/TextEditorV2/nodes/PlaygroundNodes.js +68 -0
  98. package/dist/cjs/components/TextEditorV2/nodes/PlaygroundNodes.js.map +1 -0
  99. package/dist/cjs/components/TextEditorV2/nodes/PollComponent.d.ts +8 -0
  100. package/dist/cjs/components/TextEditorV2/nodes/PollComponent.js +113 -0
  101. package/dist/cjs/components/TextEditorV2/nodes/PollComponent.js.map +1 -0
  102. package/dist/cjs/components/TextEditorV2/nodes/PollNode.d.ts +33 -0
  103. package/dist/cjs/components/TextEditorV2/nodes/PollNode.js +149 -0
  104. package/dist/cjs/components/TextEditorV2/nodes/PollNode.js.map +1 -0
  105. package/dist/cjs/components/TextEditorV2/nodes/StickyComponent.d.ts +9 -0
  106. package/dist/cjs/components/TextEditorV2/nodes/StickyComponent.js +167 -0
  107. package/dist/cjs/components/TextEditorV2/nodes/StickyComponent.js.map +1 -0
  108. package/dist/cjs/components/TextEditorV2/nodes/StickyNode.d.ts +37 -0
  109. package/dist/cjs/components/TextEditorV2/nodes/StickyNode.js +94 -0
  110. package/dist/cjs/components/TextEditorV2/nodes/StickyNode.js.map +1 -0
  111. package/dist/cjs/components/TextEditorV2/nodes/TableNode.d.ts +54 -0
  112. package/dist/cjs/components/TextEditorV2/nodes/TableNode.js +198 -0
  113. package/dist/cjs/components/TextEditorV2/nodes/TableNode.js.map +1 -0
  114. package/dist/cjs/components/TextEditorV2/nodes/TweetNode.d.ts +28 -0
  115. package/dist/cjs/components/TextEditorV2/nodes/TweetNode.js +156 -0
  116. package/dist/cjs/components/TextEditorV2/nodes/TweetNode.js.map +1 -0
  117. package/dist/cjs/components/TextEditorV2/nodes/YouTubeNode.d.ts +28 -0
  118. package/dist/cjs/components/TextEditorV2/nodes/YouTubeNode.js +103 -0
  119. package/dist/cjs/components/TextEditorV2/nodes/YouTubeNode.js.map +1 -0
  120. package/dist/cjs/components/TextEditorV2/plugins/ActionsPlugin/index.d.ts +2 -0
  121. package/dist/cjs/components/TextEditorV2/plugins/ActionsPlugin/index.js +183 -0
  122. package/dist/cjs/components/TextEditorV2/plugins/ActionsPlugin/index.js.map +1 -0
  123. package/dist/cjs/components/TextEditorV2/plugins/AutoEmbedPlugin/index.d.ts +19 -0
  124. package/dist/cjs/components/TextEditorV2/plugins/AutoEmbedPlugin/index.js +179 -0
  125. package/dist/cjs/components/TextEditorV2/plugins/AutoEmbedPlugin/index.js.map +1 -0
  126. package/dist/cjs/components/TextEditorV2/plugins/AutoLinkPlugin/index.d.ts +2 -0
  127. package/dist/cjs/components/TextEditorV2/plugins/AutoLinkPlugin/index.js +16 -0
  128. package/dist/cjs/components/TextEditorV2/plugins/AutoLinkPlugin/index.js.map +1 -0
  129. package/dist/cjs/components/TextEditorV2/plugins/AutocompletePlugin/index.d.ts +2 -0
  130. package/dist/cjs/components/TextEditorV2/plugins/AutocompletePlugin/index.js +2465 -0
  131. package/dist/cjs/components/TextEditorV2/plugins/AutocompletePlugin/index.js.map +1 -0
  132. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.d.ts +8 -0
  133. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.js +55 -0
  134. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.js.map +1 -0
  135. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.d.ts +10 -0
  136. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.js +159 -0
  137. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.js.map +1 -0
  138. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.d.ts +4 -0
  139. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.js +111 -0
  140. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.js.map +1 -0
  141. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.d.ts +1 -0
  142. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.js +21 -0
  143. package/dist/cjs/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.js.map +1 -0
  144. package/dist/cjs/components/TextEditorV2/plugins/CodeHighlightPlugin/index.d.ts +1 -0
  145. package/dist/cjs/components/TextEditorV2/plugins/CodeHighlightPlugin/index.js +12 -0
  146. package/dist/cjs/components/TextEditorV2/plugins/CodeHighlightPlugin/index.js.map +1 -0
  147. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.d.ts +23 -0
  148. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.js +88 -0
  149. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.js.map +1 -0
  150. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.d.ts +17 -0
  151. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.js +70 -0
  152. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.js.map +1 -0
  153. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.d.ts +18 -0
  154. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.js +95 -0
  155. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.js.map +1 -0
  156. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/index.d.ts +3 -0
  157. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/index.js +148 -0
  158. package/dist/cjs/components/TextEditorV2/plugins/CollapsiblePlugin/index.js.map +1 -0
  159. package/dist/cjs/components/TextEditorV2/plugins/ComponentPickerPlugin/index.d.ts +2 -0
  160. package/dist/cjs/components/TextEditorV2/plugins/ComponentPickerPlugin/index.js +264 -0
  161. package/dist/cjs/components/TextEditorV2/plugins/ComponentPickerPlugin/index.js.map +1 -0
  162. package/dist/cjs/components/TextEditorV2/plugins/ContextMenuPlugin/index.d.ts +11 -0
  163. package/dist/cjs/components/TextEditorV2/plugins/ContextMenuPlugin/index.js +171 -0
  164. package/dist/cjs/components/TextEditorV2/plugins/ContextMenuPlugin/index.js.map +1 -0
  165. package/dist/cjs/components/TextEditorV2/plugins/DocsPlugin/index.d.ts +2 -0
  166. package/dist/cjs/components/TextEditorV2/plugins/DocsPlugin/index.js +10 -0
  167. package/dist/cjs/components/TextEditorV2/plugins/DocsPlugin/index.js.map +1 -0
  168. package/dist/cjs/components/TextEditorV2/plugins/DragDropPastePlugin/index.d.ts +1 -0
  169. package/dist/cjs/components/TextEditorV2/plugins/DragDropPastePlugin/index.js +44 -0
  170. package/dist/cjs/components/TextEditorV2/plugins/DragDropPastePlugin/index.js.map +1 -0
  171. package/dist/cjs/components/TextEditorV2/plugins/DraggableBlockPlugin/index.d.ts +4 -0
  172. package/dist/cjs/components/TextEditorV2/plugins/DraggableBlockPlugin/index.js +288 -0
  173. package/dist/cjs/components/TextEditorV2/plugins/DraggableBlockPlugin/index.js.map +1 -0
  174. package/dist/cjs/components/TextEditorV2/plugins/EmojiPickerPlugin/index.d.ts +2 -0
  175. package/dist/cjs/components/TextEditorV2/plugins/EmojiPickerPlugin/index.js +97 -0
  176. package/dist/cjs/components/TextEditorV2/plugins/EmojiPickerPlugin/index.js.map +1 -0
  177. package/dist/cjs/components/TextEditorV2/plugins/EmojisPlugin/index.d.ts +1 -0
  178. package/dist/cjs/components/TextEditorV2/plugins/EmojisPlugin/index.js +64 -0
  179. package/dist/cjs/components/TextEditorV2/plugins/EmojisPlugin/index.js.map +1 -0
  180. package/dist/cjs/components/TextEditorV2/plugins/EquationsPlugin/index.d.ts +14 -0
  181. package/dist/cjs/components/TextEditorV2/plugins/EquationsPlugin/index.js +42 -0
  182. package/dist/cjs/components/TextEditorV2/plugins/EquationsPlugin/index.js.map +1 -0
  183. package/dist/cjs/components/TextEditorV2/plugins/ExcalidrawPlugin/index.d.ts +3 -0
  184. package/dist/cjs/components/TextEditorV2/plugins/ExcalidrawPlugin/index.js +28 -0
  185. package/dist/cjs/components/TextEditorV2/plugins/ExcalidrawPlugin/index.js.map +1 -0
  186. package/dist/cjs/components/TextEditorV2/plugins/FigmaPlugin/index.d.ts +3 -0
  187. package/dist/cjs/components/TextEditorV2/plugins/FigmaPlugin/index.js +25 -0
  188. package/dist/cjs/components/TextEditorV2/plugins/FigmaPlugin/index.js.map +1 -0
  189. package/dist/cjs/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.d.ts +7 -0
  190. package/dist/cjs/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.js +200 -0
  191. package/dist/cjs/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.js.map +1 -0
  192. package/dist/cjs/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.d.ts +4 -0
  193. package/dist/cjs/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.js +229 -0
  194. package/dist/cjs/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.js.map +1 -0
  195. package/dist/cjs/components/TextEditorV2/plugins/ImagesPlugin/index.d.ts +22 -0
  196. package/dist/cjs/components/TextEditorV2/plugins/ImagesPlugin/index.js +188 -0
  197. package/dist/cjs/components/TextEditorV2/plugins/ImagesPlugin/index.js.map +1 -0
  198. package/dist/cjs/components/TextEditorV2/plugins/InlineImagePlugin/index.d.ts +17 -0
  199. package/dist/cjs/components/TextEditorV2/plugins/InlineImagePlugin/index.js +193 -0
  200. package/dist/cjs/components/TextEditorV2/plugins/InlineImagePlugin/index.js.map +1 -0
  201. package/dist/cjs/components/TextEditorV2/plugins/KeywordsPlugin/index.d.ts +1 -0
  202. package/dist/cjs/components/TextEditorV2/plugins/KeywordsPlugin/index.js +33 -0
  203. package/dist/cjs/components/TextEditorV2/plugins/KeywordsPlugin/index.js.map +1 -0
  204. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.d.ts +6 -0
  205. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.js +34 -0
  206. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.js.map +1 -0
  207. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.d.ts +7 -0
  208. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.js +89 -0
  209. package/dist/cjs/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.js.map +1 -0
  210. package/dist/cjs/components/TextEditorV2/plugins/LinkPlugin/index.d.ts +2 -0
  211. package/dist/cjs/components/TextEditorV2/plugins/LinkPlugin/index.js +11 -0
  212. package/dist/cjs/components/TextEditorV2/plugins/LinkPlugin/index.js.map +1 -0
  213. package/dist/cjs/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.d.ts +5 -0
  214. package/dist/cjs/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.js +44 -0
  215. package/dist/cjs/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.js.map +1 -0
  216. package/dist/cjs/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.d.ts +2 -0
  217. package/dist/cjs/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.js +11 -0
  218. package/dist/cjs/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.js.map +1 -0
  219. package/dist/cjs/components/TextEditorV2/plugins/MarkdownTransformers/index.d.ts +8 -0
  220. package/dist/cjs/components/TextEditorV2/plugins/MarkdownTransformers/index.js +242 -0
  221. package/dist/cjs/components/TextEditorV2/plugins/MarkdownTransformers/index.js.map +1 -0
  222. package/dist/cjs/components/TextEditorV2/plugins/MaxLengthPlugin/index.d.ts +3 -0
  223. package/dist/cjs/components/TextEditorV2/plugins/MaxLengthPlugin/index.js +41 -0
  224. package/dist/cjs/components/TextEditorV2/plugins/MaxLengthPlugin/index.js.map +1 -0
  225. package/dist/cjs/components/TextEditorV2/plugins/MentionsPlugin/index.d.ts +2 -0
  226. package/dist/cjs/components/TextEditorV2/plugins/MentionsPlugin/index.js +560 -0
  227. package/dist/cjs/components/TextEditorV2/plugins/MentionsPlugin/index.js.map +1 -0
  228. package/dist/cjs/components/TextEditorV2/plugins/PageBreakPlugin/index.d.ts +3 -0
  229. package/dist/cjs/components/TextEditorV2/plugins/PageBreakPlugin/index.js +31 -0
  230. package/dist/cjs/components/TextEditorV2/plugins/PageBreakPlugin/index.js.map +1 -0
  231. package/dist/cjs/components/TextEditorV2/plugins/PasteLogPlugin/index.d.ts +2 -0
  232. package/dist/cjs/components/TextEditorV2/plugins/PasteLogPlugin/index.js +37 -0
  233. package/dist/cjs/components/TextEditorV2/plugins/PasteLogPlugin/index.js.map +1 -0
  234. package/dist/cjs/components/TextEditorV2/plugins/PollPlugin/index.d.ts +8 -0
  235. package/dist/cjs/components/TextEditorV2/plugins/PollPlugin/index.js +46 -0
  236. package/dist/cjs/components/TextEditorV2/plugins/PollPlugin/index.js.map +1 -0
  237. package/dist/cjs/components/TextEditorV2/plugins/StickyPlugin/index.d.ts +1 -0
  238. package/dist/cjs/components/TextEditorV2/plugins/StickyPlugin/index.js +16 -0
  239. package/dist/cjs/components/TextEditorV2/plugins/StickyPlugin/index.js.map +1 -0
  240. package/dist/cjs/components/TextEditorV2/plugins/TabFocusPlugin/index.d.ts +1 -0
  241. package/dist/cjs/components/TextEditorV2/plugins/TabFocusPlugin/index.js +38 -0
  242. package/dist/cjs/components/TextEditorV2/plugins/TabFocusPlugin/index.js.map +1 -0
  243. package/dist/cjs/components/TextEditorV2/plugins/TableActionMenuPlugin/index.d.ts +5 -0
  244. package/dist/cjs/components/TextEditorV2/plugins/TableActionMenuPlugin/index.js +487 -0
  245. package/dist/cjs/components/TextEditorV2/plugins/TableActionMenuPlugin/index.js.map +1 -0
  246. package/dist/cjs/components/TextEditorV2/plugins/TableCellResizer/index.d.ts +2 -0
  247. package/dist/cjs/components/TextEditorV2/plugins/TableCellResizer/index.js +253 -0
  248. package/dist/cjs/components/TextEditorV2/plugins/TableCellResizer/index.js.map +1 -0
  249. package/dist/cjs/components/TextEditorV2/plugins/TableOfContentsPlugin/index.d.ts +2 -0
  250. package/dist/cjs/components/TextEditorV2/plugins/TableOfContentsPlugin/index.js +117 -0
  251. package/dist/cjs/components/TextEditorV2/plugins/TableOfContentsPlugin/index.js.map +1 -0
  252. package/dist/cjs/components/TextEditorV2/plugins/TablePlugin.d.ts +32 -0
  253. package/dist/cjs/components/TextEditorV2/plugins/TablePlugin.js +85 -0
  254. package/dist/cjs/components/TextEditorV2/plugins/TablePlugin.js.map +1 -0
  255. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.d.ts +6 -0
  256. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.js +18 -0
  257. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.js.map +1 -0
  258. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.d.ts +6 -0
  259. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.js +28 -0
  260. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.js.map +1 -0
  261. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.d.ts +6 -0
  262. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.js +65 -0
  263. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.js.map +1 -0
  264. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.d.ts +6 -0
  265. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.js +71 -0
  266. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.js.map +1 -0
  267. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.d.ts +6 -0
  268. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.js +18 -0
  269. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.js.map +1 -0
  270. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/link.d.ts +5 -0
  271. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/link.js +46 -0
  272. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/link.js.map +1 -0
  273. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.d.ts +6 -0
  274. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.js +28 -0
  275. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.js.map +1 -0
  276. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.d.ts +6 -0
  277. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.js +52 -0
  278. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.js.map +1 -0
  279. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.d.ts +6 -0
  280. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.js +28 -0
  281. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.js.map +1 -0
  282. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.d.ts +6 -0
  283. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.js +19 -0
  284. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.js.map +1 -0
  285. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.d.ts +6 -0
  286. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.js +41 -0
  287. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.js.map +1 -0
  288. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.d.ts +11 -0
  289. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.js +162 -0
  290. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.js.map +1 -0
  291. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/index.d.ts +4 -0
  292. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/index.js +163 -0
  293. package/dist/cjs/components/TextEditorV2/plugins/ToolbarPlugin/index.js.map +1 -0
  294. package/dist/cjs/components/TextEditorV2/plugins/TreeViewPlugin/index.d.ts +2 -0
  295. package/dist/cjs/components/TextEditorV2/plugins/TreeViewPlugin/index.js +12 -0
  296. package/dist/cjs/components/TextEditorV2/plugins/TreeViewPlugin/index.js.map +1 -0
  297. package/dist/cjs/components/TextEditorV2/plugins/TwitterPlugin/index.d.ts +3 -0
  298. package/dist/cjs/components/TextEditorV2/plugins/TwitterPlugin/index.js +25 -0
  299. package/dist/cjs/components/TextEditorV2/plugins/TwitterPlugin/index.js.map +1 -0
  300. package/dist/cjs/components/TextEditorV2/plugins/YouTubePlugin/index.d.ts +3 -0
  301. package/dist/cjs/components/TextEditorV2/plugins/YouTubePlugin/index.js +25 -0
  302. package/dist/cjs/components/TextEditorV2/plugins/YouTubePlugin/index.js.map +1 -0
  303. package/dist/cjs/components/TextEditorV2/shared/canUseDOM.d.ts +1 -0
  304. package/dist/cjs/components/TextEditorV2/shared/canUseDOM.js +7 -0
  305. package/dist/cjs/components/TextEditorV2/shared/canUseDOM.js.map +1 -0
  306. package/dist/cjs/components/TextEditorV2/shared/caretFromPoint.d.ts +4 -0
  307. package/dist/cjs/components/TextEditorV2/shared/caretFromPoint.js +32 -0
  308. package/dist/cjs/components/TextEditorV2/shared/caretFromPoint.js.map +1 -0
  309. package/dist/cjs/components/TextEditorV2/shared/environment.d.ts +16 -0
  310. package/dist/cjs/components/TextEditorV2/shared/environment.js +17 -0
  311. package/dist/cjs/components/TextEditorV2/shared/environment.js.map +1 -0
  312. package/dist/cjs/components/TextEditorV2/shared/invariant.d.ts +1 -0
  313. package/dist/cjs/components/TextEditorV2/shared/invariant.js +15 -0
  314. package/dist/cjs/components/TextEditorV2/shared/invariant.js.map +1 -0
  315. package/dist/cjs/components/TextEditorV2/shared/simpleDiffWithCursor.d.ts +5 -0
  316. package/dist/cjs/components/TextEditorV2/shared/simpleDiffWithCursor.js +28 -0
  317. package/dist/cjs/components/TextEditorV2/shared/simpleDiffWithCursor.js.map +1 -0
  318. package/dist/cjs/components/TextEditorV2/shared/useLayoutEffect.d.ts +3 -0
  319. package/dist/cjs/components/TextEditorV2/shared/useLayoutEffect.js +7 -0
  320. package/dist/cjs/components/TextEditorV2/shared/useLayoutEffect.js.map +1 -0
  321. package/dist/cjs/components/TextEditorV2/shared/warnOnlyOnce.d.ts +1 -0
  322. package/dist/cjs/components/TextEditorV2/shared/warnOnlyOnce.js +16 -0
  323. package/dist/cjs/components/TextEditorV2/shared/warnOnlyOnce.js.map +1 -0
  324. package/dist/cjs/components/TextEditorV2/style.d.ts +2 -0
  325. package/dist/cjs/components/TextEditorV2/style.js +9 -0
  326. package/dist/cjs/components/TextEditorV2/style.js.map +1 -0
  327. package/dist/cjs/components/TextEditorV2/themes/CommentEditorTheme.d.ts +3 -0
  328. package/dist/cjs/components/TextEditorV2/themes/CommentEditorTheme.js +7 -0
  329. package/dist/cjs/components/TextEditorV2/themes/CommentEditorTheme.js.map +1 -0
  330. package/dist/cjs/components/TextEditorV2/themes/PlaygroundEditorTheme.d.ts +3 -0
  331. package/dist/cjs/components/TextEditorV2/themes/PlaygroundEditorTheme.js +107 -0
  332. package/dist/cjs/components/TextEditorV2/themes/PlaygroundEditorTheme.js.map +1 -0
  333. package/dist/cjs/components/TextEditorV2/themes/StickyEditorTheme.d.ts +3 -0
  334. package/dist/cjs/components/TextEditorV2/themes/StickyEditorTheme.js +7 -0
  335. package/dist/cjs/components/TextEditorV2/themes/StickyEditorTheme.js.map +1 -0
  336. package/dist/cjs/components/TextEditorV2/ui/Button.d.ts +11 -0
  337. package/dist/cjs/components/TextEditorV2/ui/Button.js +11 -0
  338. package/dist/cjs/components/TextEditorV2/ui/Button.js.map +1 -0
  339. package/dist/cjs/components/TextEditorV2/ui/ColorPicker.d.ts +12 -0
  340. package/dist/cjs/components/TextEditorV2/ui/ColorPicker.js +216 -0
  341. package/dist/cjs/components/TextEditorV2/ui/ColorPicker.js.map +1 -0
  342. package/dist/cjs/components/TextEditorV2/ui/ContentEditable.d.ts +4 -0
  343. package/dist/cjs/components/TextEditorV2/ui/ContentEditable.js +11 -0
  344. package/dist/cjs/components/TextEditorV2/ui/ContentEditable.js.map +1 -0
  345. package/dist/cjs/components/TextEditorV2/ui/Dialog.d.ts +9 -0
  346. package/dist/cjs/components/TextEditorV2/ui/Dialog.js +15 -0
  347. package/dist/cjs/components/TextEditorV2/ui/Dialog.js.map +1 -0
  348. package/dist/cjs/components/TextEditorV2/ui/DropDown.d.ts +17 -0
  349. package/dist/cjs/components/TextEditorV2/ui/DropDown.js +133 -0
  350. package/dist/cjs/components/TextEditorV2/ui/DropDown.js.map +1 -0
  351. package/dist/cjs/components/TextEditorV2/ui/DropdownColorPicker.d.ts +21 -0
  352. package/dist/cjs/components/TextEditorV2/ui/DropdownColorPicker.js +20 -0
  353. package/dist/cjs/components/TextEditorV2/ui/DropdownColorPicker.js.map +1 -0
  354. package/dist/cjs/components/TextEditorV2/ui/EquationEditor.d.ts +8 -0
  355. package/dist/cjs/components/TextEditorV2/ui/EquationEditor.js +20 -0
  356. package/dist/cjs/components/TextEditorV2/ui/EquationEditor.js.map +1 -0
  357. package/dist/cjs/components/TextEditorV2/ui/FileInput.d.ts +9 -0
  358. package/dist/cjs/components/TextEditorV2/ui/FileInput.js +12 -0
  359. package/dist/cjs/components/TextEditorV2/ui/FileInput.js.map +1 -0
  360. package/dist/cjs/components/TextEditorV2/ui/ImageResizer.d.ts +11 -0
  361. package/dist/cjs/components/TextEditorV2/ui/ImageResizer.js +178 -0
  362. package/dist/cjs/components/TextEditorV2/ui/ImageResizer.js.map +1 -0
  363. package/dist/cjs/components/TextEditorV2/ui/KatexEquationAlterer.d.ts +7 -0
  364. package/dist/cjs/components/TextEditorV2/ui/KatexEquationAlterer.js +39 -0
  365. package/dist/cjs/components/TextEditorV2/ui/KatexEquationAlterer.js.map +1 -0
  366. package/dist/cjs/components/TextEditorV2/ui/KatexRenderer.d.ts +6 -0
  367. package/dist/cjs/components/TextEditorV2/ui/KatexRenderer.js +33 -0
  368. package/dist/cjs/components/TextEditorV2/ui/KatexRenderer.js.map +1 -0
  369. package/dist/cjs/components/TextEditorV2/ui/Modal.d.ts +8 -0
  370. package/dist/cjs/components/TextEditorV2/ui/Modal.js +54 -0
  371. package/dist/cjs/components/TextEditorV2/ui/Modal.js.map +1 -0
  372. package/dist/cjs/components/TextEditorV2/ui/Placeholder.d.ts +6 -0
  373. package/dist/cjs/components/TextEditorV2/ui/Placeholder.js +10 -0
  374. package/dist/cjs/components/TextEditorV2/ui/Placeholder.js.map +1 -0
  375. package/dist/cjs/components/TextEditorV2/ui/Select.d.ts +7 -0
  376. package/dist/cjs/components/TextEditorV2/ui/Select.js +12 -0
  377. package/dist/cjs/components/TextEditorV2/ui/Select.js.map +1 -0
  378. package/dist/cjs/components/TextEditorV2/ui/Switch.d.ts +7 -0
  379. package/dist/cjs/components/TextEditorV2/ui/Switch.js +15 -0
  380. package/dist/cjs/components/TextEditorV2/ui/Switch.js.map +1 -0
  381. package/dist/cjs/components/TextEditorV2/ui/TextInput.d.ts +12 -0
  382. package/dist/cjs/components/TextEditorV2/ui/TextInput.js +14 -0
  383. package/dist/cjs/components/TextEditorV2/ui/TextInput.js.map +1 -0
  384. package/dist/cjs/components/TextEditorV2/utils/emoji-list.d.ts +20 -0
  385. package/dist/cjs/components/TextEditorV2/utils/emoji-list.js +16607 -0
  386. package/dist/cjs/components/TextEditorV2/utils/emoji-list.js.map +1 -0
  387. package/dist/cjs/components/TextEditorV2/utils/getDOMRangeRect.d.ts +1 -0
  388. package/dist/cjs/components/TextEditorV2/utils/getDOMRangeRect.js +19 -0
  389. package/dist/cjs/components/TextEditorV2/utils/getDOMRangeRect.js.map +1 -0
  390. package/dist/cjs/components/TextEditorV2/utils/getPrepopulatedRichText.d.ts +1 -0
  391. package/dist/cjs/components/TextEditorV2/utils/getPrepopulatedRichText.js +35 -0
  392. package/dist/cjs/components/TextEditorV2/utils/getPrepopulatedRichText.js.map +1 -0
  393. package/dist/cjs/components/TextEditorV2/utils/getSelectedNode.d.ts +2 -0
  394. package/dist/cjs/components/TextEditorV2/utils/getSelectedNode.js +21 -0
  395. package/dist/cjs/components/TextEditorV2/utils/getSelectedNode.js.map +1 -0
  396. package/dist/cjs/components/TextEditorV2/utils/guard.d.ts +1 -0
  397. package/dist/cjs/components/TextEditorV2/utils/guard.js +7 -0
  398. package/dist/cjs/components/TextEditorV2/utils/guard.js.map +1 -0
  399. package/dist/cjs/components/TextEditorV2/utils/isMobileWidth.d.ts +0 -0
  400. package/dist/cjs/components/TextEditorV2/utils/isMobileWidth.js +2 -0
  401. package/dist/cjs/components/TextEditorV2/utils/isMobileWidth.js.map +1 -0
  402. package/dist/cjs/components/TextEditorV2/utils/joinClasses.d.ts +1 -0
  403. package/dist/cjs/components/TextEditorV2/utils/joinClasses.js +11 -0
  404. package/dist/cjs/components/TextEditorV2/utils/joinClasses.js.map +1 -0
  405. package/dist/cjs/components/TextEditorV2/utils/point.d.ts +14 -0
  406. package/dist/cjs/components/TextEditorV2/utils/point.js +51 -0
  407. package/dist/cjs/components/TextEditorV2/utils/point.js.map +1 -0
  408. package/dist/cjs/components/TextEditorV2/utils/rect.d.ts +38 -0
  409. package/dist/cjs/components/TextEditorV2/utils/rect.js +125 -0
  410. package/dist/cjs/components/TextEditorV2/utils/rect.js.map +1 -0
  411. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPosition.d.ts +1 -0
  412. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPosition.js +33 -0
  413. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPosition.js.map +1 -0
  414. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.d.ts +1 -0
  415. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.js +31 -0
  416. package/dist/cjs/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.js.map +1 -0
  417. package/dist/cjs/components/TextEditorV2/utils/swipe.d.ts +4 -0
  418. package/dist/cjs/components/TextEditorV2/utils/swipe.js +97 -0
  419. package/dist/cjs/components/TextEditorV2/utils/swipe.js.map +1 -0
  420. package/dist/cjs/components/TextEditorV2/utils/url.d.ts +2 -0
  421. package/dist/cjs/components/TextEditorV2/utils/url.js +26 -0
  422. package/dist/cjs/components/TextEditorV2/utils/url.js.map +1 -0
  423. package/dist/cjs/components/Textarea/Textarea.js +28 -4
  424. package/dist/cjs/components/Textarea/Textarea.js.map +1 -1
  425. package/dist/cjs/index.d.ts +2 -1
  426. package/dist/cjs/index.js +5 -3
  427. package/dist/cjs/index.js.map +1 -1
  428. package/dist/esm/components/Combobox/Combobox.js +9 -3
  429. package/dist/esm/components/Combobox/Combobox.js.map +1 -1
  430. package/dist/esm/components/TextEditorV2/commenting/index.d.ts +41 -0
  431. package/dist/esm/components/TextEditorV2/commenting/index.js +334 -0
  432. package/dist/esm/components/TextEditorV2/commenting/index.js.map +1 -0
  433. package/dist/esm/components/TextEditorV2/constants.d.ts +1 -0
  434. package/dist/esm/components/TextEditorV2/constants.js +2 -0
  435. package/dist/esm/components/TextEditorV2/constants.js.map +1 -0
  436. package/dist/esm/components/TextEditorV2/context/SettingsContext.d.ts +12 -0
  437. package/dist/esm/components/TextEditorV2/context/SettingsContext.js +54 -0
  438. package/dist/esm/components/TextEditorV2/context/SettingsContext.js.map +1 -0
  439. package/dist/esm/components/TextEditorV2/context/SharedAutocompleteContext.d.ts +10 -0
  440. package/dist/esm/components/TextEditorV2/context/SharedAutocompleteContext.js +44 -0
  441. package/dist/esm/components/TextEditorV2/context/SharedAutocompleteContext.js.map +1 -0
  442. package/dist/esm/components/TextEditorV2/context/SharedHistoryContext.d.ts +11 -0
  443. package/dist/esm/components/TextEditorV2/context/SharedHistoryContext.js +11 -0
  444. package/dist/esm/components/TextEditorV2/context/SharedHistoryContext.js.map +1 -0
  445. package/dist/esm/components/TextEditorV2/editor.d.ts +10 -0
  446. package/dist/esm/components/TextEditorV2/editor.js +200 -0
  447. package/dist/esm/components/TextEditorV2/editor.js.map +1 -0
  448. package/dist/esm/components/TextEditorV2/hooks/useModal.d.ts +5 -0
  449. package/dist/esm/components/TextEditorV2/hooks/useModal.js +28 -0
  450. package/dist/esm/components/TextEditorV2/hooks/useModal.js.map +1 -0
  451. package/dist/esm/components/TextEditorV2/hooks/useReport.d.ts +1 -0
  452. package/dist/esm/components/TextEditorV2/hooks/useReport.js +42 -0
  453. package/dist/esm/components/TextEditorV2/hooks/useReport.js.map +1 -0
  454. package/dist/esm/components/TextEditorV2/lib/Settings.d.ts +2 -0
  455. package/dist/esm/components/TextEditorV2/lib/Settings.js +48 -0
  456. package/dist/esm/components/TextEditorV2/lib/Settings.js.map +1 -0
  457. package/dist/esm/components/TextEditorV2/lib/appSettings.d.ts +19 -0
  458. package/dist/esm/components/TextEditorV2/lib/appSettings.js +18 -0
  459. package/dist/esm/components/TextEditorV2/lib/appSettings.js.map +1 -0
  460. package/dist/esm/components/TextEditorV2/lib/collaboration.d.ts +3 -0
  461. package/dist/esm/components/TextEditorV2/lib/collaboration.js +23 -0
  462. package/dist/esm/components/TextEditorV2/lib/collaboration.js.map +1 -0
  463. package/dist/esm/components/TextEditorV2/lib/setupEnv.d.ts +1 -0
  464. package/dist/esm/components/TextEditorV2/lib/setupEnv.js +21 -0
  465. package/dist/esm/components/TextEditorV2/lib/setupEnv.js.map +1 -0
  466. package/dist/esm/components/TextEditorV2/nodes/AutocompleteNode.d.ts +25 -0
  467. package/dist/esm/components/TextEditorV2/nodes/AutocompleteNode.js +54 -0
  468. package/dist/esm/components/TextEditorV2/nodes/AutocompleteNode.js.map +1 -0
  469. package/dist/esm/components/TextEditorV2/nodes/EmojiNode.d.ts +18 -0
  470. package/dist/esm/components/TextEditorV2/nodes/EmojiNode.js +57 -0
  471. package/dist/esm/components/TextEditorV2/nodes/EmojiNode.js.map +1 -0
  472. package/dist/esm/components/TextEditorV2/nodes/EquationComponent.d.ts +9 -0
  473. package/dist/esm/components/TextEditorV2/nodes/EquationComponent.js +68 -0
  474. package/dist/esm/components/TextEditorV2/nodes/EquationComponent.js.map +1 -0
  475. package/dist/esm/components/TextEditorV2/nodes/EquationNode.d.ts +26 -0
  476. package/dist/esm/components/TextEditorV2/nodes/EquationNode.js +121 -0
  477. package/dist/esm/components/TextEditorV2/nodes/EquationNode.js.map +1 -0
  478. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.d.ts +6 -0
  479. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.js +113 -0
  480. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawComponent.js.map +1 -0
  481. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.d.ts +50 -0
  482. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.js +56 -0
  483. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawImage.js.map +1 -0
  484. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.d.ts +44 -0
  485. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.js +137 -0
  486. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/ExcalidrawModal.js.map +1 -0
  487. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/index.d.ts +22 -0
  488. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/index.js +98 -0
  489. package/dist/esm/components/TextEditorV2/nodes/ExcalidrawNode/index.js.map +1 -0
  490. package/dist/esm/components/TextEditorV2/nodes/ExtendedTextNode.d.ts +12 -0
  491. package/dist/esm/components/TextEditorV2/nodes/ExtendedTextNode.js +101 -0
  492. package/dist/esm/components/TextEditorV2/nodes/ExtendedTextNode.js.map +1 -0
  493. package/dist/esm/components/TextEditorV2/nodes/FigmaNode.d.ts +19 -0
  494. package/dist/esm/components/TextEditorV2/nodes/FigmaNode.js +58 -0
  495. package/dist/esm/components/TextEditorV2/nodes/FigmaNode.js.map +1 -0
  496. package/dist/esm/components/TextEditorV2/nodes/ImageComponent.d.ts +14 -0
  497. package/dist/esm/components/TextEditorV2/nodes/ImageComponent.js +207 -0
  498. package/dist/esm/components/TextEditorV2/nodes/ImageComponent.js.map +1 -0
  499. package/dist/esm/components/TextEditorV2/nodes/ImageNode.d.ts +56 -0
  500. package/dist/esm/components/TextEditorV2/nodes/ImageNode.js +131 -0
  501. package/dist/esm/components/TextEditorV2/nodes/ImageNode.js.map +1 -0
  502. package/dist/esm/components/TextEditorV2/nodes/InlineImageComponent.d.ts +18 -0
  503. package/dist/esm/components/TextEditorV2/nodes/InlineImageComponent.js +189 -0
  504. package/dist/esm/components/TextEditorV2/nodes/InlineImageComponent.js.map +1 -0
  505. package/dist/esm/components/TextEditorV2/nodes/InlineImageNode.d.ts +54 -0
  506. package/dist/esm/components/TextEditorV2/nodes/InlineImageNode.js +137 -0
  507. package/dist/esm/components/TextEditorV2/nodes/InlineImageNode.js.map +1 -0
  508. package/dist/esm/components/TextEditorV2/nodes/KeywordNode.d.ts +15 -0
  509. package/dist/esm/components/TextEditorV2/nodes/KeywordNode.js +49 -0
  510. package/dist/esm/components/TextEditorV2/nodes/KeywordNode.js.map +1 -0
  511. package/dist/esm/components/TextEditorV2/nodes/LayoutContainerNode.d.ts +21 -0
  512. package/dist/esm/components/TextEditorV2/nodes/LayoutContainerNode.js +58 -0
  513. package/dist/esm/components/TextEditorV2/nodes/LayoutContainerNode.js.map +1 -0
  514. package/dist/esm/components/TextEditorV2/nodes/LayoutItemNode.d.ts +15 -0
  515. package/dist/esm/components/TextEditorV2/nodes/LayoutItemNode.js +46 -0
  516. package/dist/esm/components/TextEditorV2/nodes/LayoutItemNode.js.map +1 -0
  517. package/dist/esm/components/TextEditorV2/nodes/MentionNode.d.ts +20 -0
  518. package/dist/esm/components/TextEditorV2/nodes/MentionNode.js +84 -0
  519. package/dist/esm/components/TextEditorV2/nodes/MentionNode.js.map +1 -0
  520. package/dist/esm/components/TextEditorV2/nodes/PageBreakNode/index.d.ts +17 -0
  521. package/dist/esm/components/TextEditorV2/nodes/PageBreakNode/index.js +108 -0
  522. package/dist/esm/components/TextEditorV2/nodes/PageBreakNode/index.js.map +1 -0
  523. package/dist/esm/components/TextEditorV2/nodes/PlaygroundNodes.d.ts +3 -0
  524. package/dist/esm/components/TextEditorV2/nodes/PlaygroundNodes.js +66 -0
  525. package/dist/esm/components/TextEditorV2/nodes/PlaygroundNodes.js.map +1 -0
  526. package/dist/esm/components/TextEditorV2/nodes/PollComponent.d.ts +8 -0
  527. package/dist/esm/components/TextEditorV2/nodes/PollComponent.js +109 -0
  528. package/dist/esm/components/TextEditorV2/nodes/PollComponent.js.map +1 -0
  529. package/dist/esm/components/TextEditorV2/nodes/PollNode.d.ts +33 -0
  530. package/dist/esm/components/TextEditorV2/nodes/PollNode.js +143 -0
  531. package/dist/esm/components/TextEditorV2/nodes/PollNode.js.map +1 -0
  532. package/dist/esm/components/TextEditorV2/nodes/StickyComponent.d.ts +9 -0
  533. package/dist/esm/components/TextEditorV2/nodes/StickyComponent.js +163 -0
  534. package/dist/esm/components/TextEditorV2/nodes/StickyComponent.js.map +1 -0
  535. package/dist/esm/components/TextEditorV2/nodes/StickyNode.d.ts +37 -0
  536. package/dist/esm/components/TextEditorV2/nodes/StickyNode.js +89 -0
  537. package/dist/esm/components/TextEditorV2/nodes/StickyNode.js.map +1 -0
  538. package/dist/esm/components/TextEditorV2/nodes/TableNode.d.ts +54 -0
  539. package/dist/esm/components/TextEditorV2/nodes/TableNode.js +188 -0
  540. package/dist/esm/components/TextEditorV2/nodes/TableNode.js.map +1 -0
  541. package/dist/esm/components/TextEditorV2/nodes/TweetNode.d.ts +28 -0
  542. package/dist/esm/components/TextEditorV2/nodes/TweetNode.js +151 -0
  543. package/dist/esm/components/TextEditorV2/nodes/TweetNode.js.map +1 -0
  544. package/dist/esm/components/TextEditorV2/nodes/YouTubeNode.d.ts +28 -0
  545. package/dist/esm/components/TextEditorV2/nodes/YouTubeNode.js +98 -0
  546. package/dist/esm/components/TextEditorV2/nodes/YouTubeNode.js.map +1 -0
  547. package/dist/esm/components/TextEditorV2/plugins/ActionsPlugin/index.d.ts +2 -0
  548. package/dist/esm/components/TextEditorV2/plugins/ActionsPlugin/index.js +180 -0
  549. package/dist/esm/components/TextEditorV2/plugins/ActionsPlugin/index.js.map +1 -0
  550. package/dist/esm/components/TextEditorV2/plugins/AutoEmbedPlugin/index.d.ts +19 -0
  551. package/dist/esm/components/TextEditorV2/plugins/AutoEmbedPlugin/index.js +174 -0
  552. package/dist/esm/components/TextEditorV2/plugins/AutoEmbedPlugin/index.js.map +1 -0
  553. package/dist/esm/components/TextEditorV2/plugins/AutoLinkPlugin/index.d.ts +2 -0
  554. package/dist/esm/components/TextEditorV2/plugins/AutoLinkPlugin/index.js +12 -0
  555. package/dist/esm/components/TextEditorV2/plugins/AutoLinkPlugin/index.js.map +1 -0
  556. package/dist/esm/components/TextEditorV2/plugins/AutocompletePlugin/index.d.ts +2 -0
  557. package/dist/esm/components/TextEditorV2/plugins/AutocompletePlugin/index.js +2461 -0
  558. package/dist/esm/components/TextEditorV2/plugins/AutocompletePlugin/index.js.map +1 -0
  559. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.d.ts +8 -0
  560. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.js +52 -0
  561. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/CopyButton/index.js.map +1 -0
  562. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.d.ts +10 -0
  563. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.js +155 -0
  564. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/components/PrettierButton/index.js.map +1 -0
  565. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.d.ts +4 -0
  566. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.js +108 -0
  567. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/index.js.map +1 -0
  568. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.d.ts +1 -0
  569. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.js +18 -0
  570. package/dist/esm/components/TextEditorV2/plugins/CodeActionMenuPlugin/utils.js.map +1 -0
  571. package/dist/esm/components/TextEditorV2/plugins/CodeHighlightPlugin/index.d.ts +1 -0
  572. package/dist/esm/components/TextEditorV2/plugins/CodeHighlightPlugin/index.js +9 -0
  573. package/dist/esm/components/TextEditorV2/plugins/CodeHighlightPlugin/index.js.map +1 -0
  574. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.d.ts +23 -0
  575. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.js +82 -0
  576. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContainerNode.js.map +1 -0
  577. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.d.ts +17 -0
  578. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.js +64 -0
  579. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleContentNode.js.map +1 -0
  580. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.d.ts +18 -0
  581. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.js +89 -0
  582. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/CollapsibleTitleNode.js.map +1 -0
  583. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/index.d.ts +3 -0
  584. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/index.js +144 -0
  585. package/dist/esm/components/TextEditorV2/plugins/CollapsiblePlugin/index.js.map +1 -0
  586. package/dist/esm/components/TextEditorV2/plugins/ComponentPickerPlugin/index.d.ts +2 -0
  587. package/dist/esm/components/TextEditorV2/plugins/ComponentPickerPlugin/index.js +261 -0
  588. package/dist/esm/components/TextEditorV2/plugins/ComponentPickerPlugin/index.js.map +1 -0
  589. package/dist/esm/components/TextEditorV2/plugins/ContextMenuPlugin/index.d.ts +11 -0
  590. package/dist/esm/components/TextEditorV2/plugins/ContextMenuPlugin/index.js +167 -0
  591. package/dist/esm/components/TextEditorV2/plugins/ContextMenuPlugin/index.js.map +1 -0
  592. package/dist/esm/components/TextEditorV2/plugins/DocsPlugin/index.d.ts +2 -0
  593. package/dist/esm/components/TextEditorV2/plugins/DocsPlugin/index.js +6 -0
  594. package/dist/esm/components/TextEditorV2/plugins/DocsPlugin/index.js.map +1 -0
  595. package/dist/esm/components/TextEditorV2/plugins/DragDropPastePlugin/index.d.ts +1 -0
  596. package/dist/esm/components/TextEditorV2/plugins/DragDropPastePlugin/index.js +41 -0
  597. package/dist/esm/components/TextEditorV2/plugins/DragDropPastePlugin/index.js.map +1 -0
  598. package/dist/esm/components/TextEditorV2/plugins/DraggableBlockPlugin/index.d.ts +4 -0
  599. package/dist/esm/components/TextEditorV2/plugins/DraggableBlockPlugin/index.js +284 -0
  600. package/dist/esm/components/TextEditorV2/plugins/DraggableBlockPlugin/index.js.map +1 -0
  601. package/dist/esm/components/TextEditorV2/plugins/EmojiPickerPlugin/index.d.ts +2 -0
  602. package/dist/esm/components/TextEditorV2/plugins/EmojiPickerPlugin/index.js +94 -0
  603. package/dist/esm/components/TextEditorV2/plugins/EmojiPickerPlugin/index.js.map +1 -0
  604. package/dist/esm/components/TextEditorV2/plugins/EmojisPlugin/index.d.ts +1 -0
  605. package/dist/esm/components/TextEditorV2/plugins/EmojisPlugin/index.js +61 -0
  606. package/dist/esm/components/TextEditorV2/plugins/EmojisPlugin/index.js.map +1 -0
  607. package/dist/esm/components/TextEditorV2/plugins/EquationsPlugin/index.d.ts +14 -0
  608. package/dist/esm/components/TextEditorV2/plugins/EquationsPlugin/index.js +36 -0
  609. package/dist/esm/components/TextEditorV2/plugins/EquationsPlugin/index.js.map +1 -0
  610. package/dist/esm/components/TextEditorV2/plugins/ExcalidrawPlugin/index.d.ts +3 -0
  611. package/dist/esm/components/TextEditorV2/plugins/ExcalidrawPlugin/index.js +24 -0
  612. package/dist/esm/components/TextEditorV2/plugins/ExcalidrawPlugin/index.js.map +1 -0
  613. package/dist/esm/components/TextEditorV2/plugins/FigmaPlugin/index.d.ts +3 -0
  614. package/dist/esm/components/TextEditorV2/plugins/FigmaPlugin/index.js +21 -0
  615. package/dist/esm/components/TextEditorV2/plugins/FigmaPlugin/index.js.map +1 -0
  616. package/dist/esm/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.d.ts +7 -0
  617. package/dist/esm/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.js +196 -0
  618. package/dist/esm/components/TextEditorV2/plugins/FloatingLinkEditorPlugin/index.js.map +1 -0
  619. package/dist/esm/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.d.ts +4 -0
  620. package/dist/esm/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.js +225 -0
  621. package/dist/esm/components/TextEditorV2/plugins/FloatingTextFormatToolbarPlugin/index.js.map +1 -0
  622. package/dist/esm/components/TextEditorV2/plugins/ImagesPlugin/index.d.ts +22 -0
  623. package/dist/esm/components/TextEditorV2/plugins/ImagesPlugin/index.js +181 -0
  624. package/dist/esm/components/TextEditorV2/plugins/ImagesPlugin/index.js.map +1 -0
  625. package/dist/esm/components/TextEditorV2/plugins/InlineImagePlugin/index.d.ts +17 -0
  626. package/dist/esm/components/TextEditorV2/plugins/InlineImagePlugin/index.js +187 -0
  627. package/dist/esm/components/TextEditorV2/plugins/InlineImagePlugin/index.js.map +1 -0
  628. package/dist/esm/components/TextEditorV2/plugins/KeywordsPlugin/index.d.ts +1 -0
  629. package/dist/esm/components/TextEditorV2/plugins/KeywordsPlugin/index.js +30 -0
  630. package/dist/esm/components/TextEditorV2/plugins/KeywordsPlugin/index.js.map +1 -0
  631. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.d.ts +6 -0
  632. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.js +30 -0
  633. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/InsertLayoutDialog.js.map +1 -0
  634. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.d.ts +7 -0
  635. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.js +85 -0
  636. package/dist/esm/components/TextEditorV2/plugins/LayoutPlugin/LayoutPlugin.js.map +1 -0
  637. package/dist/esm/components/TextEditorV2/plugins/LinkPlugin/index.d.ts +2 -0
  638. package/dist/esm/components/TextEditorV2/plugins/LinkPlugin/index.js +7 -0
  639. package/dist/esm/components/TextEditorV2/plugins/LinkPlugin/index.js.map +1 -0
  640. package/dist/esm/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.d.ts +5 -0
  641. package/dist/esm/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.js +41 -0
  642. package/dist/esm/components/TextEditorV2/plugins/ListMaxIndentLevelPlugin/index.js.map +1 -0
  643. package/dist/esm/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.d.ts +2 -0
  644. package/dist/esm/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.js +7 -0
  645. package/dist/esm/components/TextEditorV2/plugins/MarkdownShortcutPlugin/index.js.map +1 -0
  646. package/dist/esm/components/TextEditorV2/plugins/MarkdownTransformers/index.d.ts +8 -0
  647. package/dist/esm/components/TextEditorV2/plugins/MarkdownTransformers/index.js +239 -0
  648. package/dist/esm/components/TextEditorV2/plugins/MarkdownTransformers/index.js.map +1 -0
  649. package/dist/esm/components/TextEditorV2/plugins/MaxLengthPlugin/index.d.ts +3 -0
  650. package/dist/esm/components/TextEditorV2/plugins/MaxLengthPlugin/index.js +38 -0
  651. package/dist/esm/components/TextEditorV2/plugins/MaxLengthPlugin/index.js.map +1 -0
  652. package/dist/esm/components/TextEditorV2/plugins/MentionsPlugin/index.d.ts +2 -0
  653. package/dist/esm/components/TextEditorV2/plugins/MentionsPlugin/index.js +557 -0
  654. package/dist/esm/components/TextEditorV2/plugins/MentionsPlugin/index.js.map +1 -0
  655. package/dist/esm/components/TextEditorV2/plugins/PageBreakPlugin/index.d.ts +3 -0
  656. package/dist/esm/components/TextEditorV2/plugins/PageBreakPlugin/index.js +27 -0
  657. package/dist/esm/components/TextEditorV2/plugins/PageBreakPlugin/index.js.map +1 -0
  658. package/dist/esm/components/TextEditorV2/plugins/PasteLogPlugin/index.d.ts +2 -0
  659. package/dist/esm/components/TextEditorV2/plugins/PasteLogPlugin/index.js +33 -0
  660. package/dist/esm/components/TextEditorV2/plugins/PasteLogPlugin/index.js.map +1 -0
  661. package/dist/esm/components/TextEditorV2/plugins/PollPlugin/index.d.ts +8 -0
  662. package/dist/esm/components/TextEditorV2/plugins/PollPlugin/index.js +40 -0
  663. package/dist/esm/components/TextEditorV2/plugins/PollPlugin/index.js.map +1 -0
  664. package/dist/esm/components/TextEditorV2/plugins/StickyPlugin/index.d.ts +1 -0
  665. package/dist/esm/components/TextEditorV2/plugins/StickyPlugin/index.js +13 -0
  666. package/dist/esm/components/TextEditorV2/plugins/StickyPlugin/index.js.map +1 -0
  667. package/dist/esm/components/TextEditorV2/plugins/TabFocusPlugin/index.d.ts +1 -0
  668. package/dist/esm/components/TextEditorV2/plugins/TabFocusPlugin/index.js +35 -0
  669. package/dist/esm/components/TextEditorV2/plugins/TabFocusPlugin/index.js.map +1 -0
  670. package/dist/esm/components/TextEditorV2/plugins/TableActionMenuPlugin/index.d.ts +5 -0
  671. package/dist/esm/components/TextEditorV2/plugins/TableActionMenuPlugin/index.js +483 -0
  672. package/dist/esm/components/TextEditorV2/plugins/TableActionMenuPlugin/index.js.map +1 -0
  673. package/dist/esm/components/TextEditorV2/plugins/TableCellResizer/index.d.ts +2 -0
  674. package/dist/esm/components/TextEditorV2/plugins/TableCellResizer/index.js +249 -0
  675. package/dist/esm/components/TextEditorV2/plugins/TableCellResizer/index.js.map +1 -0
  676. package/dist/esm/components/TextEditorV2/plugins/TableOfContentsPlugin/index.d.ts +2 -0
  677. package/dist/esm/components/TextEditorV2/plugins/TableOfContentsPlugin/index.js +113 -0
  678. package/dist/esm/components/TextEditorV2/plugins/TableOfContentsPlugin/index.js.map +1 -0
  679. package/dist/esm/components/TextEditorV2/plugins/TablePlugin.d.ts +32 -0
  680. package/dist/esm/components/TextEditorV2/plugins/TablePlugin.js +78 -0
  681. package/dist/esm/components/TextEditorV2/plugins/TablePlugin.js.map +1 -0
  682. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.d.ts +6 -0
  683. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.js +14 -0
  684. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bold-text.js.map +1 -0
  685. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.d.ts +6 -0
  686. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.js +24 -0
  687. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/bullet.js.map +1 -0
  688. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.d.ts +6 -0
  689. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.js +61 -0
  690. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/font-size.js.map +1 -0
  691. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.d.ts +6 -0
  692. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.js +67 -0
  693. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/heading.js.map +1 -0
  694. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.d.ts +6 -0
  695. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.js +14 -0
  696. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/italic-text.js.map +1 -0
  697. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/link.d.ts +5 -0
  698. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/link.js +42 -0
  699. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/link.js.map +1 -0
  700. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.d.ts +6 -0
  701. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.js +24 -0
  702. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/number-bullet.js.map +1 -0
  703. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.d.ts +6 -0
  704. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.js +48 -0
  705. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-align.js.map +1 -0
  706. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.d.ts +6 -0
  707. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.js +24 -0
  708. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/text-color.js.map +1 -0
  709. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.d.ts +6 -0
  710. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.js +15 -0
  711. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/underline-text.js.map +1 -0
  712. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.d.ts +6 -0
  713. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.js +37 -0
  714. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-image.js.map +1 -0
  715. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.d.ts +11 -0
  716. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.js +159 -0
  717. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/components/upload-pdf.js.map +1 -0
  718. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/index.d.ts +4 -0
  719. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/index.js +159 -0
  720. package/dist/esm/components/TextEditorV2/plugins/ToolbarPlugin/index.js.map +1 -0
  721. package/dist/esm/components/TextEditorV2/plugins/TreeViewPlugin/index.d.ts +2 -0
  722. package/dist/esm/components/TextEditorV2/plugins/TreeViewPlugin/index.js +8 -0
  723. package/dist/esm/components/TextEditorV2/plugins/TreeViewPlugin/index.js.map +1 -0
  724. package/dist/esm/components/TextEditorV2/plugins/TwitterPlugin/index.d.ts +3 -0
  725. package/dist/esm/components/TextEditorV2/plugins/TwitterPlugin/index.js +21 -0
  726. package/dist/esm/components/TextEditorV2/plugins/TwitterPlugin/index.js.map +1 -0
  727. package/dist/esm/components/TextEditorV2/plugins/YouTubePlugin/index.d.ts +3 -0
  728. package/dist/esm/components/TextEditorV2/plugins/YouTubePlugin/index.js +21 -0
  729. package/dist/esm/components/TextEditorV2/plugins/YouTubePlugin/index.js.map +1 -0
  730. package/dist/esm/components/TextEditorV2/shared/canUseDOM.d.ts +1 -0
  731. package/dist/esm/components/TextEditorV2/shared/canUseDOM.js +4 -0
  732. package/dist/esm/components/TextEditorV2/shared/canUseDOM.js.map +1 -0
  733. package/dist/esm/components/TextEditorV2/shared/caretFromPoint.d.ts +4 -0
  734. package/dist/esm/components/TextEditorV2/shared/caretFromPoint.js +29 -0
  735. package/dist/esm/components/TextEditorV2/shared/caretFromPoint.js.map +1 -0
  736. package/dist/esm/components/TextEditorV2/shared/environment.d.ts +16 -0
  737. package/dist/esm/components/TextEditorV2/shared/environment.js +14 -0
  738. package/dist/esm/components/TextEditorV2/shared/environment.js.map +1 -0
  739. package/dist/esm/components/TextEditorV2/shared/invariant.d.ts +1 -0
  740. package/dist/esm/components/TextEditorV2/shared/invariant.js +12 -0
  741. package/dist/esm/components/TextEditorV2/shared/invariant.js.map +1 -0
  742. package/dist/esm/components/TextEditorV2/shared/simpleDiffWithCursor.d.ts +5 -0
  743. package/dist/esm/components/TextEditorV2/shared/simpleDiffWithCursor.js +25 -0
  744. package/dist/esm/components/TextEditorV2/shared/simpleDiffWithCursor.js.map +1 -0
  745. package/dist/esm/components/TextEditorV2/shared/useLayoutEffect.d.ts +3 -0
  746. package/dist/esm/components/TextEditorV2/shared/useLayoutEffect.js +5 -0
  747. package/dist/esm/components/TextEditorV2/shared/useLayoutEffect.js.map +1 -0
  748. package/dist/esm/components/TextEditorV2/shared/warnOnlyOnce.d.ts +1 -0
  749. package/dist/esm/components/TextEditorV2/shared/warnOnlyOnce.js +13 -0
  750. package/dist/esm/components/TextEditorV2/shared/warnOnlyOnce.js.map +1 -0
  751. package/dist/esm/components/TextEditorV2/style.d.ts +2 -0
  752. package/dist/esm/components/TextEditorV2/style.js +5 -0
  753. package/dist/esm/components/TextEditorV2/style.js.map +1 -0
  754. package/dist/esm/components/TextEditorV2/themes/CommentEditorTheme.d.ts +3 -0
  755. package/dist/esm/components/TextEditorV2/themes/CommentEditorTheme.js +5 -0
  756. package/dist/esm/components/TextEditorV2/themes/CommentEditorTheme.js.map +1 -0
  757. package/dist/esm/components/TextEditorV2/themes/PlaygroundEditorTheme.d.ts +3 -0
  758. package/dist/esm/components/TextEditorV2/themes/PlaygroundEditorTheme.js +105 -0
  759. package/dist/esm/components/TextEditorV2/themes/PlaygroundEditorTheme.js.map +1 -0
  760. package/dist/esm/components/TextEditorV2/themes/StickyEditorTheme.d.ts +3 -0
  761. package/dist/esm/components/TextEditorV2/themes/StickyEditorTheme.js +5 -0
  762. package/dist/esm/components/TextEditorV2/themes/StickyEditorTheme.js.map +1 -0
  763. package/dist/esm/components/TextEditorV2/ui/Button.d.ts +11 -0
  764. package/dist/esm/components/TextEditorV2/ui/Button.js +8 -0
  765. package/dist/esm/components/TextEditorV2/ui/Button.js.map +1 -0
  766. package/dist/esm/components/TextEditorV2/ui/ColorPicker.d.ts +12 -0
  767. package/dist/esm/components/TextEditorV2/ui/ColorPicker.js +212 -0
  768. package/dist/esm/components/TextEditorV2/ui/ColorPicker.js.map +1 -0
  769. package/dist/esm/components/TextEditorV2/ui/ContentEditable.d.ts +4 -0
  770. package/dist/esm/components/TextEditorV2/ui/ContentEditable.js +7 -0
  771. package/dist/esm/components/TextEditorV2/ui/ContentEditable.js.map +1 -0
  772. package/dist/esm/components/TextEditorV2/ui/Dialog.d.ts +9 -0
  773. package/dist/esm/components/TextEditorV2/ui/Dialog.js +10 -0
  774. package/dist/esm/components/TextEditorV2/ui/Dialog.js.map +1 -0
  775. package/dist/esm/components/TextEditorV2/ui/DropDown.d.ts +17 -0
  776. package/dist/esm/components/TextEditorV2/ui/DropDown.js +129 -0
  777. package/dist/esm/components/TextEditorV2/ui/DropDown.js.map +1 -0
  778. package/dist/esm/components/TextEditorV2/ui/DropdownColorPicker.d.ts +21 -0
  779. package/dist/esm/components/TextEditorV2/ui/DropdownColorPicker.js +17 -0
  780. package/dist/esm/components/TextEditorV2/ui/DropdownColorPicker.js.map +1 -0
  781. package/dist/esm/components/TextEditorV2/ui/EquationEditor.d.ts +8 -0
  782. package/dist/esm/components/TextEditorV2/ui/EquationEditor.js +17 -0
  783. package/dist/esm/components/TextEditorV2/ui/EquationEditor.js.map +1 -0
  784. package/dist/esm/components/TextEditorV2/ui/FileInput.d.ts +9 -0
  785. package/dist/esm/components/TextEditorV2/ui/FileInput.js +8 -0
  786. package/dist/esm/components/TextEditorV2/ui/FileInput.js.map +1 -0
  787. package/dist/esm/components/TextEditorV2/ui/ImageResizer.d.ts +11 -0
  788. package/dist/esm/components/TextEditorV2/ui/ImageResizer.js +174 -0
  789. package/dist/esm/components/TextEditorV2/ui/ImageResizer.js.map +1 -0
  790. package/dist/esm/components/TextEditorV2/ui/KatexEquationAlterer.d.ts +7 -0
  791. package/dist/esm/components/TextEditorV2/ui/KatexEquationAlterer.js +35 -0
  792. package/dist/esm/components/TextEditorV2/ui/KatexEquationAlterer.js.map +1 -0
  793. package/dist/esm/components/TextEditorV2/ui/KatexRenderer.d.ts +6 -0
  794. package/dist/esm/components/TextEditorV2/ui/KatexRenderer.js +29 -0
  795. package/dist/esm/components/TextEditorV2/ui/KatexRenderer.js.map +1 -0
  796. package/dist/esm/components/TextEditorV2/ui/Modal.d.ts +8 -0
  797. package/dist/esm/components/TextEditorV2/ui/Modal.js +50 -0
  798. package/dist/esm/components/TextEditorV2/ui/Modal.js.map +1 -0
  799. package/dist/esm/components/TextEditorV2/ui/Placeholder.d.ts +6 -0
  800. package/dist/esm/components/TextEditorV2/ui/Placeholder.js +6 -0
  801. package/dist/esm/components/TextEditorV2/ui/Placeholder.js.map +1 -0
  802. package/dist/esm/components/TextEditorV2/ui/Select.d.ts +7 -0
  803. package/dist/esm/components/TextEditorV2/ui/Select.js +9 -0
  804. package/dist/esm/components/TextEditorV2/ui/Select.js.map +1 -0
  805. package/dist/esm/components/TextEditorV2/ui/Switch.d.ts +7 -0
  806. package/dist/esm/components/TextEditorV2/ui/Switch.js +11 -0
  807. package/dist/esm/components/TextEditorV2/ui/Switch.js.map +1 -0
  808. package/dist/esm/components/TextEditorV2/ui/TextInput.d.ts +12 -0
  809. package/dist/esm/components/TextEditorV2/ui/TextInput.js +10 -0
  810. package/dist/esm/components/TextEditorV2/ui/TextInput.js.map +1 -0
  811. package/dist/esm/components/TextEditorV2/utils/emoji-list.d.ts +20 -0
  812. package/dist/esm/components/TextEditorV2/utils/emoji-list.js +16605 -0
  813. package/dist/esm/components/TextEditorV2/utils/emoji-list.js.map +1 -0
  814. package/dist/esm/components/TextEditorV2/utils/getDOMRangeRect.d.ts +1 -0
  815. package/dist/esm/components/TextEditorV2/utils/getDOMRangeRect.js +16 -0
  816. package/dist/esm/components/TextEditorV2/utils/getDOMRangeRect.js.map +1 -0
  817. package/dist/esm/components/TextEditorV2/utils/getPrepopulatedRichText.d.ts +1 -0
  818. package/dist/esm/components/TextEditorV2/utils/getPrepopulatedRichText.js +32 -0
  819. package/dist/esm/components/TextEditorV2/utils/getPrepopulatedRichText.js.map +1 -0
  820. package/dist/esm/components/TextEditorV2/utils/getSelectedNode.d.ts +2 -0
  821. package/dist/esm/components/TextEditorV2/utils/getSelectedNode.js +18 -0
  822. package/dist/esm/components/TextEditorV2/utils/getSelectedNode.js.map +1 -0
  823. package/dist/esm/components/TextEditorV2/utils/guard.d.ts +1 -0
  824. package/dist/esm/components/TextEditorV2/utils/guard.js +4 -0
  825. package/dist/esm/components/TextEditorV2/utils/guard.js.map +1 -0
  826. package/dist/esm/components/TextEditorV2/utils/isMobileWidth.d.ts +0 -0
  827. package/dist/esm/components/TextEditorV2/utils/isMobileWidth.js +2 -0
  828. package/dist/esm/components/TextEditorV2/utils/isMobileWidth.js.map +1 -0
  829. package/dist/esm/components/TextEditorV2/utils/joinClasses.d.ts +1 -0
  830. package/dist/esm/components/TextEditorV2/utils/joinClasses.js +8 -0
  831. package/dist/esm/components/TextEditorV2/utils/joinClasses.js.map +1 -0
  832. package/dist/esm/components/TextEditorV2/utils/point.d.ts +14 -0
  833. package/dist/esm/components/TextEditorV2/utils/point.js +47 -0
  834. package/dist/esm/components/TextEditorV2/utils/point.js.map +1 -0
  835. package/dist/esm/components/TextEditorV2/utils/rect.d.ts +38 -0
  836. package/dist/esm/components/TextEditorV2/utils/rect.js +122 -0
  837. package/dist/esm/components/TextEditorV2/utils/rect.js.map +1 -0
  838. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPosition.d.ts +1 -0
  839. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPosition.js +30 -0
  840. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPosition.js.map +1 -0
  841. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.d.ts +1 -0
  842. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.js +28 -0
  843. package/dist/esm/components/TextEditorV2/utils/setFloatingElemPositionForLinkEditor.js.map +1 -0
  844. package/dist/esm/components/TextEditorV2/utils/swipe.d.ts +4 -0
  845. package/dist/esm/components/TextEditorV2/utils/swipe.js +91 -0
  846. package/dist/esm/components/TextEditorV2/utils/swipe.js.map +1 -0
  847. package/dist/esm/components/TextEditorV2/utils/url.d.ts +2 -0
  848. package/dist/esm/components/TextEditorV2/utils/url.js +22 -0
  849. package/dist/esm/components/TextEditorV2/utils/url.js.map +1 -0
  850. package/dist/esm/components/Textarea/Textarea.js +28 -4
  851. package/dist/esm/components/Textarea/Textarea.js.map +1 -1
  852. package/dist/esm/index.d.ts +2 -1
  853. package/dist/esm/index.js +2 -1
  854. package/dist/esm/index.js.map +1 -1
  855. package/package.json +11 -2
@@ -0,0 +1,151 @@
1
+ /**
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ *
7
+ */
8
+ import { __assign, __awaiter, __extends, __generator } from "tslib";
9
+ import { BlockWithAlignableContents } from '@lexical/react/LexicalBlockWithAlignableContents';
10
+ import { DecoratorBlockNode } from '@lexical/react/LexicalDecoratorBlockNode';
11
+ import * as React from 'react';
12
+ import { useCallback, useEffect, useRef, useState } from 'react';
13
+ var WIDGET_SCRIPT_URL = 'https://platform.twitter.com/widgets.js';
14
+ function convertTweetElement(domNode) {
15
+ var id = domNode.getAttribute('data-lexical-tweet-id');
16
+ if (id) {
17
+ var node = $createTweetNode(id);
18
+ return { node: node };
19
+ }
20
+ return null;
21
+ }
22
+ var isTwitterScriptLoading = true;
23
+ function TweetComponent(_a) {
24
+ var _this = this;
25
+ var className = _a.className, format = _a.format, loadingComponent = _a.loadingComponent, nodeKey = _a.nodeKey, onError = _a.onError, onLoad = _a.onLoad, tweetID = _a.tweetID;
26
+ var containerRef = useRef(null);
27
+ var previousTweetIDRef = useRef('');
28
+ var _b = useState(false), isTweetLoading = _b[0], setIsTweetLoading = _b[1];
29
+ var createTweet = useCallback(function () { return __awaiter(_this, void 0, void 0, function () {
30
+ var error_1;
31
+ return __generator(this, function (_a) {
32
+ switch (_a.label) {
33
+ case 0:
34
+ _a.trys.push([0, 2, , 3]);
35
+ // @ts-expect-error Twitter is attached to the window.
36
+ return [4 /*yield*/, window.twttr.widgets.createTweet(tweetID, containerRef.current)];
37
+ case 1:
38
+ // @ts-expect-error Twitter is attached to the window.
39
+ _a.sent();
40
+ setIsTweetLoading(false);
41
+ isTwitterScriptLoading = false;
42
+ if (onLoad) {
43
+ onLoad();
44
+ }
45
+ return [3 /*break*/, 3];
46
+ case 2:
47
+ error_1 = _a.sent();
48
+ if (onError) {
49
+ onError(String(error_1));
50
+ }
51
+ return [3 /*break*/, 3];
52
+ case 3: return [2 /*return*/];
53
+ }
54
+ });
55
+ }); }, [onError, onLoad, tweetID]);
56
+ useEffect(function () {
57
+ var _a;
58
+ if (tweetID !== previousTweetIDRef.current) {
59
+ setIsTweetLoading(true);
60
+ if (isTwitterScriptLoading) {
61
+ var script = document.createElement('script');
62
+ script.src = WIDGET_SCRIPT_URL;
63
+ script.async = true;
64
+ (_a = document.body) === null || _a === void 0 ? void 0 : _a.appendChild(script);
65
+ script.onload = createTweet;
66
+ if (onError) {
67
+ script.onerror = onError;
68
+ }
69
+ }
70
+ else {
71
+ createTweet();
72
+ }
73
+ if (previousTweetIDRef) {
74
+ previousTweetIDRef.current = tweetID;
75
+ }
76
+ }
77
+ }, [createTweet, onError, tweetID]);
78
+ return (React.createElement(BlockWithAlignableContents, { className: className, format: format, nodeKey: nodeKey },
79
+ isTweetLoading ? loadingComponent : null,
80
+ React.createElement("div", { ref: containerRef, style: { display: 'inline-block', width: '550px' } })));
81
+ }
82
+ var TweetNode = /** @class */ (function (_super) {
83
+ __extends(TweetNode, _super);
84
+ function TweetNode(id, format, key) {
85
+ var _this = _super.call(this, format, key) || this;
86
+ _this.__id = id;
87
+ return _this;
88
+ }
89
+ TweetNode.getType = function () {
90
+ return 'tweet';
91
+ };
92
+ TweetNode.clone = function (node) {
93
+ return new TweetNode(node.__id, node.__format, node.__key);
94
+ };
95
+ TweetNode.importJSON = function (serializedNode) {
96
+ var node = $createTweetNode(serializedNode.id);
97
+ node.setFormat(serializedNode.format);
98
+ return node;
99
+ };
100
+ TweetNode.prototype.exportJSON = function () {
101
+ return __assign(__assign({}, _super.prototype.exportJSON.call(this)), { id: this.getId(), type: 'tweet', version: 1 });
102
+ };
103
+ TweetNode.importDOM = function () {
104
+ return {
105
+ div: function (domNode) {
106
+ if (!domNode.hasAttribute('data-lexical-tweet-id')) {
107
+ return null;
108
+ }
109
+ return {
110
+ conversion: convertTweetElement,
111
+ priority: 2,
112
+ };
113
+ },
114
+ };
115
+ };
116
+ TweetNode.prototype.exportDOM = function () {
117
+ var element = document.createElement('div');
118
+ element.setAttribute('data-lexical-tweet-id', this.__id);
119
+ var text = document.createTextNode(this.getTextContent());
120
+ element.append(text);
121
+ return { element: element };
122
+ };
123
+ TweetNode.prototype.getId = function () {
124
+ return this.__id;
125
+ };
126
+ TweetNode.prototype.getTextContent = function (
127
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
128
+ _includeInert,
129
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
130
+ _includeDirectionless) {
131
+ return "https://x.com/i/web/status/".concat(this.__id);
132
+ };
133
+ TweetNode.prototype.decorate = function (editor, config) {
134
+ console.log(editor);
135
+ var embedBlockTheme = config.theme.embedBlock || {};
136
+ var className = {
137
+ base: embedBlockTheme.base || '',
138
+ focus: embedBlockTheme.focus || '',
139
+ };
140
+ return (React.createElement(TweetComponent, { className: className, format: this.__format, loadingComponent: 'Loading...', nodeKey: this.getKey(), tweetID: this.__id }));
141
+ };
142
+ return TweetNode;
143
+ }(DecoratorBlockNode));
144
+ export { TweetNode };
145
+ export function $createTweetNode(tweetID) {
146
+ return new TweetNode(tweetID);
147
+ }
148
+ export function $isTweetNode(node) {
149
+ return node instanceof TweetNode;
150
+ }
151
+ //# sourceMappingURL=TweetNode.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"TweetNode.js","sourceRoot":"","sources":["../../../../../src/components/TextEditorV2/nodes/TweetNode.tsx"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,OAAO,EAAE,0BAA0B,EAAE,MAAM,kDAAkD,CAAA;AAC7F,OAAO,EAAE,kBAAkB,EAAgC,MAAM,0CAA0C,CAAA;AAY3G,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAC9B,OAAO,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,OAAO,CAAA;AAEhE,IAAM,iBAAiB,GAAG,yCAAyC,CAAA;AAenE,SAAS,mBAAmB,CAAC,OAAuB;IAClD,IAAM,EAAE,GAAG,OAAO,CAAC,YAAY,CAAC,uBAAuB,CAAC,CAAA;IACxD,IAAI,EAAE,EAAE,CAAC;QACP,IAAM,IAAI,GAAG,gBAAgB,CAAC,EAAE,CAAC,CAAA;QACjC,OAAO,EAAE,IAAI,MAAA,EAAE,CAAA;IACjB,CAAC;IACD,OAAO,IAAI,CAAA;AACb,CAAC;AAED,IAAI,sBAAsB,GAAG,IAAI,CAAA;AAEj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AA;QACrD,IAAM,SAAS,GAAG;YAChB,IAAI,EAAE,eAAe,CAAC,IAAI,IAAI,EAAE;YAChC,KAAK,EAAE,eAAe,CAAC,KAAK,IAAI,EAAE;SACnC,CAAA;QACD,OAAO,CACL,oBAAC,cAAc,IACb,SAAS,EAAE,SAAS,EACpB,MAAM,EAAE,IAAI,CAAC,QAAQ,EACrB,gBAAgB,EAAC,YAAY,EAC7B,OAAO,EAAE,IAAI,CAAC,MAAM,EAAE,EACtB,OAAO,EAAE,IAAI,CAAC,IAAI,GAClB,CACH,CAAA;IACH,CAAC;IACH,gBAAC;AAAD,CAAC,AAnFD,CAA+B,kBAAkB,GAmFhD;;AAED,MAAM,UAAU,gBAAgB,CAAC,OAAe;IAC9C,OAAO,IAAI,SAAS,CAAC,OAAO,CAAC,CAAA;AAC/B,CAAC;AAED,MAAM,UAAU,YAAY,CAAC,IAAgD;IAC3E,OAAO,IAAI,YAAY,SAAS,CAAA;AAClC,CAAC"}
@@ -0,0 +1,28 @@
1
+ /**
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ *
7
+ */
8
+ import { DecoratorBlockNode, SerializedDecoratorBlockNode } from '@lexical/react/LexicalDecoratorBlockNode';
9
+ import type { DOMConversionMap, DOMExportOutput, EditorConfig, ElementFormatType, LexicalEditor, LexicalNode, NodeKey, Spread } from 'lexical';
10
+ import * as React from 'react';
11
+ export type SerializedYouTubeNode = Spread<{
12
+ videoID: string;
13
+ }, SerializedDecoratorBlockNode>;
14
+ export declare class YouTubeNode extends DecoratorBlockNode {
15
+ __id: string;
16
+ static getType(): string;
17
+ static clone(node: YouTubeNode): YouTubeNode;
18
+ static importJSON(serializedNode: SerializedYouTubeNode): YouTubeNode;
19
+ exportJSON(): SerializedYouTubeNode;
20
+ constructor(id: string, format?: ElementFormatType, key?: NodeKey);
21
+ exportDOM(): DOMExportOutput;
22
+ static importDOM(): DOMConversionMap | null;
23
+ updateDOM(): false;
24
+ getTextContent(_includeInert?: boolean | undefined, _includeDirectionless?: false | undefined): string;
25
+ decorate(_editor: LexicalEditor, config: EditorConfig): React.JSX.Element;
26
+ }
27
+ export declare function $createYouTubeNode(videoID: string): YouTubeNode;
28
+ export declare function $isYouTubeNode(node: YouTubeNode | LexicalNode | null | undefined): node is YouTubeNode;
@@ -0,0 +1,98 @@
1
+ /**
2
+ * Copyright (c) Meta Platforms, Inc. and affiliates.
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ *
7
+ */
8
+ import { __assign, __extends } from "tslib";
9
+ import { BlockWithAlignableContents } from '@lexical/react/LexicalBlockWithAlignableContents';
10
+ import { DecoratorBlockNode } from '@lexical/react/LexicalDecoratorBlockNode';
11
+ import * as React from 'react';
12
+ function YouTubeComponent(_a) {
13
+ var className = _a.className, format = _a.format, nodeKey = _a.nodeKey, videoID = _a.videoID;
14
+ return (React.createElement(BlockWithAlignableContents, { className: className, format: format, nodeKey: nodeKey },
15
+ React.createElement("iframe", { allow: 'accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture', allowFullScreen: true, frameBorder: '0', height: '315', src: "https://www.youtube-nocookie.com/embed/".concat(videoID), title: 'YouTube video', width: '560' })));
16
+ }
17
+ function convertYoutubeElement(domNode) {
18
+ var videoID = domNode.getAttribute('data-lexical-youtube');
19
+ if (videoID) {
20
+ var node = $createYouTubeNode(videoID);
21
+ return { node: node };
22
+ }
23
+ return null;
24
+ }
25
+ var YouTubeNode = /** @class */ (function (_super) {
26
+ __extends(YouTubeNode, _super);
27
+ function YouTubeNode(id, format, key) {
28
+ var _this = _super.call(this, format, key) || this;
29
+ _this.__id = id;
30
+ return _this;
31
+ }
32
+ YouTubeNode.getType = function () {
33
+ return 'youtube';
34
+ };
35
+ YouTubeNode.clone = function (node) {
36
+ return new YouTubeNode(node.__id, node.__format, node.__key);
37
+ };
38
+ YouTubeNode.importJSON = function (serializedNode) {
39
+ var node = $createYouTubeNode(serializedNode.videoID);
40
+ node.setFormat(serializedNode.format);
41
+ return node;
42
+ };
43
+ YouTubeNode.prototype.exportJSON = function () {
44
+ return __assign(__assign({}, _super.prototype.exportJSON.call(this)), { type: 'youtube', version: 1, videoID: this.__id });
45
+ };
46
+ YouTubeNode.prototype.exportDOM = function () {
47
+ var element = document.createElement('iframe');
48
+ element.setAttribute('data-lexical-youtube', this.__id);
49
+ element.setAttribute('width', '560');
50
+ element.setAttribute('height', '315');
51
+ element.setAttribute('src', "https://www.youtube-nocookie.com/embed/".concat(this.__id));
52
+ element.setAttribute('frameborder', '0');
53
+ element.setAttribute('allow', 'accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture');
54
+ element.setAttribute('allowfullscreen', 'true');
55
+ element.setAttribute('title', 'YouTube video');
56
+ return { element: element };
57
+ };
58
+ YouTubeNode.importDOM = function () {
59
+ return {
60
+ iframe: function (domNode) {
61
+ if (!domNode.hasAttribute('data-lexical-youtube')) {
62
+ return null;
63
+ }
64
+ return {
65
+ conversion: convertYoutubeElement,
66
+ priority: 1,
67
+ };
68
+ },
69
+ };
70
+ };
71
+ YouTubeNode.prototype.updateDOM = function () {
72
+ return false;
73
+ };
74
+ YouTubeNode.prototype.getTextContent = function (
75
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
76
+ _includeInert,
77
+ // eslint-disable-next-line @typescript-eslint/no-unused-vars
78
+ _includeDirectionless) {
79
+ return "https://www.youtube.com/watch?v=".concat(this.__id);
80
+ };
81
+ YouTubeNode.prototype.decorate = function (_editor, config) {
82
+ var embedBlockTheme = config.theme.embedBlock || {};
83
+ var className = {
84
+ base: embedBlockTheme.base || '',
85
+ focus: embedBlockTheme.focus || '',
86
+ };
87
+ return React.createElement(YouTubeComponent, { className: className, format: this.__format, nodeKey: this.getKey(), videoID: this.__id });
88
+ };
89
+ return YouTubeNode;
90
+ }(DecoratorBlockNode));
91
+ export { YouTubeNode };
92
+ export function $createYouTubeNode(videoID) {
93
+ return new YouTubeNode(videoID);
94
+ }
95
+ export function $isYouTubeNode(node) {
96
+ return node instanceof YouTubeNode;
97
+ }
98
+ //# sourceMappingURL=YouTubeNode.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"YouTubeNode.js","sourceRoot":"","sources":["../../../../../src/components/TextEditorV2/nodes/YouTubeNode.tsx"],"names":[],"mappings":"AAAA;;;;;;GAMG;;AAEH,OAAO,EAAE,0BAA0B,EAAE,MAAM,kDAAkD,CAAA;AAC7F,OAAO,EAAE,kBAAkB,EAAgC,MAAM,0CAA0C,CAAA;AAY3G,OAAO,KAAK,KAAK,MAAM,OAAO,CAAA;AAY9B,SAAS,gBAAgB,CAAC,EAA8D;QAA5D,SAAS,eAAA,EAAE,MAAM,YAAA,EAAE,OAAO,aAAA,EAAE,OAAO,aAAA;IAC7D,OAAO,CACL,oBAAC,0BAA0B,IAAC,SAAS,EAAE,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,OAAO;QAChF,gCACE,KAAK,EAAC,0FAA0F,EAChG,eAAe,QACf,WAAW,EAAC,GAAG,EACf,MAAM,EAAC,KAAK,EACZ,GAAG,EAAE,iDAA0C,OAAO,CAAE,EACxD,KAAK,EAAC,eAAe,EACrB,KAAK,EAAC,KAAK,GACX,CACyB,CAC9B,CAAA;AACH,CAAC;AASD,SAAS,qBAAqB,CAAC,OAAoB;IACjD,IAAM,OAAO,GAAG,OAAO,CAAC,YAAY,CAAC,sBAAsB,CAAC,CAAA;IAC5D,IAAI,OAAO,EAAE,CAAC;QACZ,IAAM,IAAI,GAAG,kBAAkB,CAAC,OAAO,CAAC,CAAA;QACxC,OAAO,EAAE,IAAI,MAAA,EAAE,CAAA;IACjB,CAAC;IACD,OAAO,IAAI,CAAA;AACb,CAAC;AAED;IAAiC,+BAAkB;IA0BjD,qBAAY,EAAU,EAAE,MAA0B,EAAE,GAAa;QAC/D,YAAA,MAAK,YAAC,MAA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AAA;AACpC,CAAC"}
@@ -0,0 +1,2 @@
1
+ import * as React from 'react';
2
+ export default function ActionsPlugin(): React.JSX.Element;
@@ -0,0 +1,180 @@
1
+ import { __awaiter, __generator } from "tslib";
2
+ import { $createCodeNode, $isCodeNode } from '@lexical/code';
3
+ import { exportFile, importFile } from '@lexical/file';
4
+ import { $convertFromMarkdownString, $convertToMarkdownString } from '@lexical/markdown';
5
+ import { useCollaborationContext } from '@lexical/react/LexicalCollaborationContext';
6
+ import { useLexicalComposerContext } from '@lexical/react/LexicalComposerContext';
7
+ import { mergeRegister } from '@lexical/utils';
8
+ import { CONNECTED_COMMAND, TOGGLE_CONNECT_COMMAND } from '@lexical/yjs';
9
+ import { $createTextNode, $getRoot, $isParagraphNode, CLEAR_EDITOR_COMMAND, COMMAND_PRIORITY_EDITOR } from 'lexical';
10
+ import * as React from 'react';
11
+ import { useCallback, useEffect, useState } from 'react';
12
+ import useModal from '../../hooks/useModal';
13
+ import Button from '../../ui/Button';
14
+ import { PLAYGROUND_TRANSFORMERS } from '../MarkdownTransformers';
15
+ function sendEditorState(editor) {
16
+ return __awaiter(this, void 0, void 0, function () {
17
+ var stringifiedEditorState, _a;
18
+ return __generator(this, function (_b) {
19
+ switch (_b.label) {
20
+ case 0:
21
+ stringifiedEditorState = JSON.stringify(editor.getEditorState());
22
+ _b.label = 1;
23
+ case 1:
24
+ _b.trys.push([1, 3, , 4]);
25
+ return [4 /*yield*/, fetch('http://localhost:1235/setEditorState', {
26
+ body: stringifiedEditorState,
27
+ headers: {
28
+ Accept: 'application/json',
29
+ 'Content-type': 'application/json',
30
+ },
31
+ method: 'POST',
32
+ })];
33
+ case 2:
34
+ _b.sent();
35
+ return [3 /*break*/, 4];
36
+ case 3:
37
+ _a = _b.sent();
38
+ return [3 /*break*/, 4];
39
+ case 4: return [2 /*return*/];
40
+ }
41
+ });
42
+ });
43
+ }
44
+ function validateEditorState(editor) {
45
+ return __awaiter(this, void 0, void 0, function () {
46
+ var stringifiedEditorState, response, _a;
47
+ return __generator(this, function (_b) {
48
+ switch (_b.label) {
49
+ case 0:
50
+ stringifiedEditorState = JSON.stringify(editor.getEditorState());
51
+ response = null;
52
+ _b.label = 1;
53
+ case 1:
54
+ _b.trys.push([1, 3, , 4]);
55
+ return [4 /*yield*/, fetch('http://localhost:1235/validateEditorState', {
56
+ body: stringifiedEditorState,
57
+ headers: {
58
+ Accept: 'application/json',
59
+ 'Content-type': 'application/json',
60
+ },
61
+ method: 'POST',
62
+ })];
63
+ case 2:
64
+ response = _b.sent();
65
+ return [3 /*break*/, 4];
66
+ case 3:
67
+ _a = _b.sent();
68
+ return [3 /*break*/, 4];
69
+ case 4:
70
+ if (response !== null && response.status === 403) {
71
+ throw new Error('Editor state validation failed! Server did not accept changes.');
72
+ }
73
+ return [2 /*return*/];
74
+ }
75
+ });
76
+ });
77
+ }
78
+ export default function ActionsPlugin() {
79
+ var editor = useLexicalComposerContext()[0];
80
+ var _a = useState(function () { return editor.isEditable(); }), isEditable = _a[0], setIsEditable = _a[1];
81
+ var _b = useState(false), connected = _b[0], setConnected = _b[1];
82
+ var _c = useState(true), isEditorEmpty = _c[0], setIsEditorEmpty = _c[1];
83
+ var _d = useModal(), modal = _d[0], showModal = _d[1];
84
+ var isCollabActive = useCollaborationContext().isCollabActive;
85
+ useEffect(function () {
86
+ return mergeRegister(editor.registerEditableListener(function (editable) {
87
+ setIsEditable(editable);
88
+ }), editor.registerCommand(CONNECTED_COMMAND, function (payload) {
89
+ var isConnected = payload;
90
+ setConnected(isConnected);
91
+ return false;
92
+ }, COMMAND_PRIORITY_EDITOR));
93
+ }, [editor]);
94
+ useEffect(function () {
95
+ return editor.registerUpdateListener(function (_a) {
96
+ var dirtyElements = _a.dirtyElements, tags = _a.tags;
97
+ // If we are in read only mode, send the editor state
98
+ // to server and ask for validation if possible.
99
+ if (!isEditable && dirtyElements.size > 0 && !tags.has('historic') && !tags.has('collaboration')) {
100
+ validateEditorState(editor);
101
+ }
102
+ editor.getEditorState().read(function () {
103
+ var root = $getRoot();
104
+ var children = root.getChildren();
105
+ if (children.length > 1) {
106
+ setIsEditorEmpty(false);
107
+ }
108
+ else {
109
+ if ($isParagraphNode(children[0])) {
110
+ var paragraphChildren = children[0].getChildren();
111
+ setIsEditorEmpty(paragraphChildren.length === 0);
112
+ }
113
+ else {
114
+ setIsEditorEmpty(false);
115
+ }
116
+ }
117
+ });
118
+ });
119
+ }, [editor, isEditable]);
120
+ var handleMarkdownToggle = useCallback(function () {
121
+ editor.update(function () {
122
+ var root = $getRoot();
123
+ var firstChild = root.getFirstChild();
124
+ if ($isCodeNode(firstChild) && firstChild.getLanguage() === 'markdown') {
125
+ $convertFromMarkdownString(firstChild.getTextContent(), PLAYGROUND_TRANSFORMERS);
126
+ }
127
+ else {
128
+ var markdown = $convertToMarkdownString(PLAYGROUND_TRANSFORMERS);
129
+ root.clear().append($createCodeNode('markdown').append($createTextNode(markdown)));
130
+ }
131
+ root.selectEnd();
132
+ });
133
+ }, [editor]);
134
+ return (React.createElement("div", { className: 'actions' },
135
+ React.createElement("button", { "aria-label": 'Import editor state from JSON', className: 'action-button import', onClick: function () { return importFile(editor); }, title: 'Import', type: 'button' },
136
+ React.createElement("i", { className: 'import' })),
137
+ React.createElement("button", { "aria-label": 'Export editor state to JSON', className: 'action-button export', onClick: function () {
138
+ return exportFile(editor, {
139
+ fileName: "Playground ".concat(new Date().toISOString()),
140
+ source: 'Playground',
141
+ });
142
+ }, title: 'Export', type: 'button' },
143
+ React.createElement("i", { className: 'export' })),
144
+ React.createElement("button", { "aria-label": 'Clear editor contents', className: 'action-button clear', disabled: isEditorEmpty, onClick: function () {
145
+ showModal('Clear editor', function (onClose) { return React.createElement(ShowClearDialog, { editor: editor, onClose: onClose }); });
146
+ }, title: 'Clear', type: 'button' },
147
+ React.createElement("i", { className: 'clear' })),
148
+ React.createElement("button", { "aria-label": "".concat(!isEditable ? 'Unlock' : 'Lock', " read-only mode"), className: "action-button ".concat(!isEditable ? 'unlock' : 'lock'), onClick: function () {
149
+ // Send latest editor state to commenting validation server
150
+ if (isEditable) {
151
+ sendEditorState(editor);
152
+ }
153
+ editor.setEditable(!editor.isEditable());
154
+ }, title: 'Read-Only Mode', type: 'button' },
155
+ React.createElement("i", { className: !isEditable ? 'unlock' : 'lock' })),
156
+ React.createElement("button", { "aria-label": 'Convert from markdown', className: 'action-button', onClick: handleMarkdownToggle, title: 'Convert From Markdown', type: 'button' },
157
+ React.createElement("i", { className: 'markdown' })),
158
+ isCollabActive && (React.createElement("button", { "aria-label": "".concat(connected ? 'Disconnect from' : 'Connect to', " a collaborative editing server"), className: 'action-button connect', onClick: function () {
159
+ editor.dispatchCommand(TOGGLE_CONNECT_COMMAND, !connected);
160
+ }, title: "".concat(connected ? 'Disconnect' : 'Connect', " Collaborative Editing"), type: 'button' },
161
+ React.createElement("i", { className: connected ? 'disconnect' : 'connect' }))),
162
+ modal));
163
+ }
164
+ function ShowClearDialog(_a) {
165
+ var editor = _a.editor, onClose = _a.onClose;
166
+ return (React.createElement(React.Fragment, null,
167
+ "Are you sure you want to clear the editor?",
168
+ React.createElement("div", { className: 'Modal__content' },
169
+ React.createElement(Button, { onClick: function () {
170
+ editor.dispatchCommand(CLEAR_EDITOR_COMMAND, undefined);
171
+ editor.focus();
172
+ onClose();
173
+ } }, "Clear"),
174
+ ' ',
175
+ React.createElement(Button, { onClick: function () {
176
+ editor.focus();
177
+ onClose();
178
+ } }, "Cancel"))));
179
+ }
180
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../src/components/TextEditorV2/plugins/ActionsPlugin/index.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,eAAe,EAAE,WAAW,EAAE,MAAM,eAAe,CAAA;AAC5D,OAAO,EAAE,UAAU,EAAE,UAAU,EAAE,MAAM,eAAe,CAAA;AACtD,OAAO,EAAE,0BAA0B,EAAE,wBAAwB,EAAE,MAAM,mBAAmB,CAAA;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AC;AAED,SAAS,eAAe,CAAC,EAA+D;QAA7D,MAAM,YAAA,EAAE,OAAO,aAAA;IACxC,OAAO,CACL;;QAEE,6BAAK,SAAS,EAAC,gBAAgB;YAC7B,oBAAC,MAAM,IACL,OAAO,EAAE;oBACP,MAAM,CAAC,eAAe,CAAC,oBAAoB,EAAE,SAAS,CAAC,CAAA;oBACvD,MAAM,CAAC,KAAK,EAAE,CAAA;oBACd,OAAO,EAAE,CAAA;gBACX,CAAC,YAGM;YAAC,GAAG;YACb,oBAAC,MAAM,IACL,OAAO,EAAE;oBACP,MAAM,CAAC,KAAK,EAAE,CAAA;oBACd,OAAO,EAAE,CAAA;gBACX,CAAC,aAGM,CACL,CACL,CACJ,CAAA;AACH,CAAC"}
@@ -0,0 +1,19 @@
1
+ import { EmbedConfig } from '@lexical/react/LexicalAutoEmbedPlugin';
2
+ import * as React from 'react';
3
+ interface PlaygroundEmbedConfig extends EmbedConfig {
4
+ contentName: string;
5
+ icon?: React.JSX.Element;
6
+ exampleUrl: string;
7
+ keywords: Array<string>;
8
+ description?: string;
9
+ }
10
+ export declare const YoutubeEmbedConfig: PlaygroundEmbedConfig;
11
+ export declare const TwitterEmbedConfig: PlaygroundEmbedConfig;
12
+ export declare const FigmaEmbedConfig: PlaygroundEmbedConfig;
13
+ export declare const EmbedConfigs: PlaygroundEmbedConfig[];
14
+ export declare function AutoEmbedDialog({ embedConfig, onClose, }: {
15
+ embedConfig: PlaygroundEmbedConfig;
16
+ onClose(): void;
17
+ }): React.JSX.Element;
18
+ export default function AutoEmbedPlugin(): React.JSX.Element;
19
+ export {};