reactjs-tiptap-editor-pro 0.2.31 → 0.2.32

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 (333) hide show
  1. package/lib/RichTextEditor-BwbqJLnA.cjs +141 -0
  2. package/lib/RichTextEditor-iGJ6-rbq.js +8833 -0
  3. package/lib/extension-bundle.cjs +33 -0
  4. package/lib/extension-bundle.d.cts +947 -0
  5. package/lib/extension-bundle.d.ts +947 -0
  6. package/lib/extension-bundle.js +5755 -0
  7. package/lib/index-DV-nXpU1.cjs +1 -0
  8. package/lib/index-M6H3FoBi.js +1147 -0
  9. package/lib/index.cjs +1 -0
  10. package/lib/index.d.cts +513 -0
  11. package/lib/index.d.ts +513 -0
  12. package/lib/index.js +16 -0
  13. package/lib/locale-bundle.cjs +1 -0
  14. package/lib/locale-bundle.d.cts +1140 -0
  15. package/lib/locale-bundle.d.ts +1140 -0
  16. package/lib/locale-bundle.js +9 -0
  17. package/lib/style.css +1 -0
  18. package/lib/tiptap-DkWHMWDt.js +6061 -0
  19. package/lib/tiptap-gBG-1T-V.cjs +116 -0
  20. package/lib/vendor-BJ0Yf78E.cjs +8114 -0
  21. package/lib/vendor-Cpa6z-M0.js +67575 -0
  22. package/package.json +58 -5
  23. package/src/components/ActionButton.tsx +0 -103
  24. package/src/components/ActionMenuButton.tsx +0 -76
  25. package/src/components/BubbleMenu.tsx +0 -93
  26. package/src/components/CharactorCount.tsx +0 -50
  27. package/src/components/ColorPicker.tsx +0 -272
  28. package/src/components/RichTextEditor.tsx +0 -212
  29. package/src/components/SizeSetter/SizeSetter.tsx +0 -102
  30. package/src/components/Toolbar.tsx +0 -108
  31. package/src/components/icons/Activity.tsx +0 -19
  32. package/src/components/icons/Animas.tsx +0 -24
  33. package/src/components/icons/AspectRatio.tsx +0 -13
  34. package/src/components/icons/Blockquote.tsx +0 -17
  35. package/src/components/icons/ColumnAddLeft.tsx +0 -7
  36. package/src/components/icons/ColumnAddRight.tsx +0 -7
  37. package/src/components/icons/DeleteColumn.tsx +0 -26
  38. package/src/components/icons/DeleteRow.tsx +0 -26
  39. package/src/components/icons/Direction.tsx +0 -7
  40. package/src/components/icons/Excalidraw.tsx +0 -7
  41. package/src/components/icons/ExportPdf.tsx +0 -8
  42. package/src/components/icons/ExportWord.tsx +0 -24
  43. package/src/components/icons/FileWordOutline.tsx +0 -13
  44. package/src/components/icons/Flag.tsx +0 -19
  45. package/src/components/icons/Food.tsx +0 -20
  46. package/src/components/icons/GIfIcon.tsx +0 -10
  47. package/src/components/icons/Icon.tsx +0 -30
  48. package/src/components/icons/ImportWord.tsx +0 -23
  49. package/src/components/icons/LeftToRight.tsx +0 -7
  50. package/src/components/icons/LineHeight.tsx +0 -13
  51. package/src/components/icons/MenuDown.tsx +0 -24
  52. package/src/components/icons/Mermaid.tsx +0 -13
  53. package/src/components/icons/NoFill.tsx +0 -7
  54. package/src/components/icons/Object.tsx +0 -24
  55. package/src/components/icons/RightToLeft.tsx +0 -7
  56. package/src/components/icons/SizeL.tsx +0 -9
  57. package/src/components/icons/SizeM.tsx +0 -13
  58. package/src/components/icons/SizeS.tsx +0 -13
  59. package/src/components/icons/Symbol.tsx +0 -19
  60. package/src/components/icons/Travel.tsx +0 -24
  61. package/src/components/icons/Twitter.tsx +0 -7
  62. package/src/components/icons/icons.ts +0 -212
  63. package/src/components/icons/index.ts +0 -12
  64. package/src/components/index.ts +0 -9
  65. package/src/components/menus/bubble.ts +0 -395
  66. package/src/components/menus/components/BubbleMenuContent.tsx +0 -15
  67. package/src/components/menus/components/BubbleMenuDrawer.tsx +0 -128
  68. package/src/components/menus/components/BubbleMenuExcalidraw.tsx +0 -91
  69. package/src/components/menus/components/BubbleMenuIframe.tsx +0 -143
  70. package/src/components/menus/components/BubbleMenuKatex.tsx +0 -136
  71. package/src/components/menus/components/BubbleMenuLink.tsx +0 -99
  72. package/src/components/menus/components/BubbleMenuMedia.tsx +0 -235
  73. package/src/components/menus/components/BubbleMenuMermaid.tsx +0 -128
  74. package/src/components/menus/components/BubbleMenuText.tsx +0 -102
  75. package/src/components/menus/components/BubbleMenuTwitter.tsx +0 -91
  76. package/src/components/menus/components/ColumnsBubbleMenu.tsx +0 -59
  77. package/src/components/menus/components/ContentMenu.tsx +0 -396
  78. package/src/components/menus/components/TableBubbleMenu.tsx +0 -362
  79. package/src/components/menus/index.ts +0 -7
  80. package/src/components/ui/button.tsx +0 -56
  81. package/src/components/ui/checkbox.tsx +0 -30
  82. package/src/components/ui/dialog.tsx +0 -128
  83. package/src/components/ui/dropdown-menu.tsx +0 -203
  84. package/src/components/ui/emoji-picker.tsx +0 -166
  85. package/src/components/ui/index.ts +0 -14
  86. package/src/components/ui/input.tsx +0 -25
  87. package/src/components/ui/label.tsx +0 -26
  88. package/src/components/ui/popover.tsx +0 -31
  89. package/src/components/ui/select.tsx +0 -162
  90. package/src/components/ui/separator.tsx +0 -31
  91. package/src/components/ui/switch.tsx +0 -29
  92. package/src/components/ui/tabs.tsx +0 -55
  93. package/src/components/ui/textarea.tsx +0 -24
  94. package/src/components/ui/toast.tsx +0 -129
  95. package/src/components/ui/toaster.tsx +0 -44
  96. package/src/components/ui/toggle.tsx +0 -45
  97. package/src/components/ui/tooltip.tsx +0 -30
  98. package/src/components/ui/use-toast.ts +0 -197
  99. package/src/constants/index.ts +0 -223
  100. package/src/constants/resetCSS.ts +0 -139
  101. package/src/extension-bundle.ts +0 -2
  102. package/src/extensions/Attachment/Attachment.ts +0 -144
  103. package/src/extensions/Attachment/components/NodeViewAttachment/FileIcon.tsx +0 -69
  104. package/src/extensions/Attachment/components/NodeViewAttachment/FileIconString.ts +0 -28
  105. package/src/extensions/Attachment/components/NodeViewAttachment/NodeViewAttachment.tsx +0 -155
  106. package/src/extensions/Attachment/components/NodeViewAttachment/index.module.scss +0 -23
  107. package/src/extensions/Attachment/index.ts +0 -1
  108. package/src/extensions/BaseKit.ts +0 -253
  109. package/src/extensions/Blockquote/Blockquote.ts +0 -31
  110. package/src/extensions/Blockquote/index.ts +0 -1
  111. package/src/extensions/Bold/Bold.ts +0 -26
  112. package/src/extensions/Bold/index.ts +0 -1
  113. package/src/extensions/BulletList/BulletList.ts +0 -28
  114. package/src/extensions/BulletList/index.ts +0 -1
  115. package/src/extensions/Clear/Clear.ts +0 -24
  116. package/src/extensions/Clear/index.ts +0 -1
  117. package/src/extensions/Code/Code.ts +0 -26
  118. package/src/extensions/Code/index.ts +0 -1
  119. package/src/extensions/CodeBlock/CodeBlock.ts +0 -54
  120. package/src/extensions/CodeBlock/components/CodeBlockActiveButton.tsx +0 -66
  121. package/src/extensions/CodeBlock/components/NodeViewCodeBlock/NodeViewCodeBlock.tsx +0 -89
  122. package/src/extensions/CodeBlock/components/NodeViewCodeBlock/index.module.scss +0 -81
  123. package/src/extensions/CodeBlock/highlighter.ts +0 -132
  124. package/src/extensions/CodeBlock/index.ts +0 -1
  125. package/src/extensions/CodeBlock/shiki-plugin.ts +0 -213
  126. package/src/extensions/Color/Color.ts +0 -52
  127. package/src/extensions/Color/components/ColorActionButton.tsx +0 -104
  128. package/src/extensions/Color/index.ts +0 -1
  129. package/src/extensions/Document/Document.ts +0 -8
  130. package/src/extensions/Document/index.ts +0 -1
  131. package/src/extensions/Drawer/Drawer.ts +0 -177
  132. package/src/extensions/Drawer/components/ControlDrawer/ControlDrawer.module.scss +0 -85
  133. package/src/extensions/Drawer/components/ControlDrawer/ControlDrawer.tsx +0 -598
  134. package/src/extensions/Drawer/components/ControlDrawer/icon.tsx +0 -500
  135. package/src/extensions/Drawer/components/DrawerActiveButton.tsx +0 -239
  136. package/src/extensions/Drawer/components/EditDrawerBlock.tsx +0 -238
  137. package/src/extensions/Drawer/components/NodeViewDrawer/NodeViewDrawer.tsx +0 -260
  138. package/src/extensions/Drawer/index.ts +0 -1
  139. package/src/extensions/Emoji/Emoji.ts +0 -146
  140. package/src/extensions/Emoji/components/EmojiList/EmojiList.tsx +0 -103
  141. package/src/extensions/Emoji/components/EmojiList/emojis.ts +0 -1858
  142. package/src/extensions/Emoji/components/EmojiPicker/EmojiPicker.tsx +0 -61
  143. package/src/extensions/Emoji/index.ts +0 -1
  144. package/src/extensions/Excalidraw/Excalidraw.ts +0 -123
  145. package/src/extensions/Excalidraw/components/ExcalidrawActiveButton.tsx +0 -138
  146. package/src/extensions/Excalidraw/components/NodeViewExcalidraw/NodeViewExcalidraw.tsx +0 -178
  147. package/src/extensions/Excalidraw/components/NodeViewExcalidraw/index.module.scss +0 -43
  148. package/src/extensions/Excalidraw/index.ts +0 -1
  149. package/src/extensions/ExportPdf/ExportPdf.ts +0 -25
  150. package/src/extensions/ExportPdf/index.ts +0 -1
  151. package/src/extensions/ExportWord/ExportWord.ts +0 -87
  152. package/src/extensions/ExportWord/index.ts +0 -1
  153. package/src/extensions/FontFamily/FontFamily.ts +0 -64
  154. package/src/extensions/FontFamily/components/FontFamilyButton.tsx +0 -97
  155. package/src/extensions/FontFamily/index.ts +0 -1
  156. package/src/extensions/FontSize/FontSize.ts +0 -119
  157. package/src/extensions/FontSize/components/FontSizeMenuButton.tsx +0 -84
  158. package/src/extensions/FontSize/index.ts +0 -1
  159. package/src/extensions/FormatPainter/FormatPainter.ts +0 -121
  160. package/src/extensions/FormatPainter/index.ts +0 -1
  161. package/src/extensions/Heading/Heading.ts +0 -57
  162. package/src/extensions/Heading/components/HeadingButton.tsx +0 -96
  163. package/src/extensions/Heading/index.ts +0 -1
  164. package/src/extensions/Highlight/Highlight.ts +0 -36
  165. package/src/extensions/Highlight/components/HighlightActionButton.tsx +0 -108
  166. package/src/extensions/Highlight/index.ts +0 -1
  167. package/src/extensions/History/History.ts +0 -39
  168. package/src/extensions/History/components/HistoryActionButton.tsx +0 -74
  169. package/src/extensions/History/index.ts +0 -1
  170. package/src/extensions/HorizontalRule/HorizontalRule.ts +0 -42
  171. package/src/extensions/HorizontalRule/index.ts +0 -1
  172. package/src/extensions/Iframe/Iframe.ts +0 -140
  173. package/src/extensions/Iframe/components/IframeNodeView.tsx +0 -92
  174. package/src/extensions/Iframe/components/index.module.scss +0 -40
  175. package/src/extensions/Iframe/embed.ts +0 -487
  176. package/src/extensions/Iframe/index.ts +0 -1
  177. package/src/extensions/Image/Image.ts +0 -303
  178. package/src/extensions/Image/components/ActionImageButton.tsx +0 -186
  179. package/src/extensions/Image/components/ImageCropper.tsx +0 -198
  180. package/src/extensions/Image/components/ImageView.tsx +0 -271
  181. package/src/extensions/Image/index.ts +0 -1
  182. package/src/extensions/Image/store.ts +0 -15
  183. package/src/extensions/ImageGif/ImageGif.ts +0 -176
  184. package/src/extensions/ImageGif/components/ImageGifActionButton.tsx +0 -138
  185. package/src/extensions/ImageGif/components/ImageGifView.tsx +0 -260
  186. package/src/extensions/ImageGif/index.ts +0 -1
  187. package/src/extensions/ImportWord/ImportWord.ts +0 -52
  188. package/src/extensions/ImportWord/components/ImportWordButton.tsx +0 -151
  189. package/src/extensions/ImportWord/index.ts +0 -1
  190. package/src/extensions/Indent/Indent.ts +0 -110
  191. package/src/extensions/Indent/index.ts +0 -1
  192. package/src/extensions/Italic/Italic.ts +0 -29
  193. package/src/extensions/Italic/index.ts +0 -1
  194. package/src/extensions/Katex/Katex.ts +0 -109
  195. package/src/extensions/Katex/components/KatexActiveButton.tsx +0 -117
  196. package/src/extensions/Katex/components/KatexWrapper.tsx +0 -53
  197. package/src/extensions/Katex/index.ts +0 -1
  198. package/src/extensions/LineHeight/LineHeight.ts +0 -76
  199. package/src/extensions/LineHeight/components/LineHeightDropdown.tsx +0 -93
  200. package/src/extensions/LineHeight/index.ts +0 -1
  201. package/src/extensions/Link/Link.ts +0 -92
  202. package/src/extensions/Link/components/LinkEditBlock.tsx +0 -110
  203. package/src/extensions/Link/components/LinkEditPopover.tsx +0 -46
  204. package/src/extensions/Link/components/LinkViewBlock.tsx +0 -54
  205. package/src/extensions/Link/index.ts +0 -1
  206. package/src/extensions/ListItem/ListItem.ts +0 -1
  207. package/src/extensions/ListItem/index.ts +0 -1
  208. package/src/extensions/Mention/Mention.ts +0 -100
  209. package/src/extensions/Mention/components/NodeViewMentionList/NodeViewMentionList.tsx +0 -94
  210. package/src/extensions/Mention/components/NodeViewMentionList/index.module.scss +0 -38
  211. package/src/extensions/Mention/index.ts +0 -1
  212. package/src/extensions/Mermaid/Mermaid.ts +0 -177
  213. package/src/extensions/Mermaid/components/EditMermaidBlock.tsx +0 -155
  214. package/src/extensions/Mermaid/components/MermaidActiveButton.tsx +0 -151
  215. package/src/extensions/Mermaid/components/NodeViewMermaid/NodeViewMermaid.tsx +0 -260
  216. package/src/extensions/Mermaid/index.ts +0 -1
  217. package/src/extensions/MoreMark/MoreMark.ts +0 -102
  218. package/src/extensions/MoreMark/components/ActionMoreButton.tsx +0 -97
  219. package/src/extensions/MoreMark/index.ts +0 -1
  220. package/src/extensions/MultiColumn/Column.ts +0 -36
  221. package/src/extensions/MultiColumn/MultiColumn.ts +0 -111
  222. package/src/extensions/MultiColumn/components/ColumnActionButton.ts +0 -22
  223. package/src/extensions/MultiColumn/index.ts +0 -3
  224. package/src/extensions/OrderedList/OrderedList.ts +0 -28
  225. package/src/extensions/OrderedList/index.ts +0 -1
  226. package/src/extensions/SearchAndReplace/SearchAndReplace.ts +0 -395
  227. package/src/extensions/SearchAndReplace/components/SearchAndReplaceButton.tsx +0 -190
  228. package/src/extensions/SearchAndReplace/index.ts +0 -1
  229. package/src/extensions/Selection/Selection.ts +0 -32
  230. package/src/extensions/Selection/index.ts +0 -1
  231. package/src/extensions/SlashCommand/SlashCommand.ts +0 -255
  232. package/src/extensions/SlashCommand/components/CommandsList.tsx +0 -180
  233. package/src/extensions/SlashCommand/groups.ts +0 -183
  234. package/src/extensions/SlashCommand/index.ts +0 -1
  235. package/src/extensions/SlashCommand/types.ts +0 -24
  236. package/src/extensions/Strike/Strike.ts +0 -26
  237. package/src/extensions/Strike/index.ts +0 -1
  238. package/src/extensions/Subscript/Subscript.ts +0 -88
  239. package/src/extensions/Subscript/index.ts +0 -1
  240. package/src/extensions/Table/Cell.ts +0 -131
  241. package/src/extensions/Table/Header.ts +0 -93
  242. package/src/extensions/Table/Row.ts +0 -8
  243. package/src/extensions/Table/Table.ts +0 -60
  244. package/src/extensions/Table/cell-background.ts +0 -112
  245. package/src/extensions/Table/components/CreateTablePopover.tsx +0 -132
  246. package/src/extensions/Table/components/TableActionButton.tsx +0 -42
  247. package/src/extensions/Table/index.ts +0 -6
  248. package/src/extensions/Table/utils.ts +0 -352
  249. package/src/extensions/TableOfContent/TableOfContent.ts +0 -124
  250. package/src/extensions/TableOfContent/components/NodeViewTableOfContent.tsx +0 -116
  251. package/src/extensions/TableOfContent/components/TableOfContentActionButton.tsx +0 -27
  252. package/src/extensions/TableOfContent/components/index.module.scss +0 -40
  253. package/src/extensions/TableOfContent/index.ts +0 -1
  254. package/src/extensions/TaskList/TaskList.ts +0 -46
  255. package/src/extensions/TaskList/index.ts +0 -1
  256. package/src/extensions/TextAlign/TextAlign.ts +0 -68
  257. package/src/extensions/TextAlign/components/TextAlignMenuButton.tsx +0 -103
  258. package/src/extensions/TextAlign/index.ts +0 -1
  259. package/src/extensions/TextBubble/TextBubble.ts +0 -22
  260. package/src/extensions/TextBubble/components/TextDropdown.tsx +0 -146
  261. package/src/extensions/TextBubble/index.ts +0 -1
  262. package/src/extensions/TextDirection/TextDirection.ts +0 -97
  263. package/src/extensions/TextDirection/components/TextDirectionButton.tsx +0 -103
  264. package/src/extensions/TextDirection/index.ts +0 -1
  265. package/src/extensions/TrailingNode/TrailingNode.ts +0 -71
  266. package/src/extensions/TrailingNode/index.ts +0 -1
  267. package/src/extensions/Twitter/Twitter.ts +0 -161
  268. package/src/extensions/Twitter/components/FormEditLinkTwitter.tsx +0 -68
  269. package/src/extensions/Twitter/components/NodeViewTweet.tsx +0 -30
  270. package/src/extensions/Twitter/components/TwitterActiveButton.tsx +0 -41
  271. package/src/extensions/Twitter/index.ts +0 -1
  272. package/src/extensions/UnderLine/Underline.ts +0 -30
  273. package/src/extensions/UnderLine/index.ts +0 -1
  274. package/src/extensions/Video/Video.ts +0 -204
  275. package/src/extensions/Video/components/ActiveVideoButton.tsx +0 -191
  276. package/src/extensions/Video/index.ts +0 -1
  277. package/src/extensions/Video/store.ts +0 -15
  278. package/src/extensions/index.ts +0 -122
  279. package/src/hooks/useActive.tsx +0 -24
  280. package/src/hooks/useAttributes.tsx +0 -45
  281. package/src/hooks/useCopy.tsx +0 -20
  282. package/src/hooks/useEditorState.tsx +0 -23
  283. package/src/hooks/useExtension.tsx +0 -29
  284. package/src/index.ts +0 -8
  285. package/src/lib/utils.ts +0 -7
  286. package/src/locale-bundle.ts +0 -3
  287. package/src/locales/en.ts +0 -173
  288. package/src/locales/hu.ts +0 -173
  289. package/src/locales/index.tsx +0 -163
  290. package/src/locales/pt-br.ts +0 -173
  291. package/src/locales/vi.ts +0 -173
  292. package/src/locales/zh-cn.ts +0 -173
  293. package/src/plugins/DragHandle/index.ts +0 -375
  294. package/src/plugins/DragHandle/range.ts +0 -114
  295. package/src/plugins/DragHandle/utils.ts +0 -80
  296. package/src/plugins/image-upload.ts +0 -160
  297. package/src/store/ProviderRichText.tsx +0 -53
  298. package/src/store/editableEditor.ts +0 -15
  299. package/src/store/fast-context.tsx +0 -70
  300. package/src/store/store.ts +0 -35
  301. package/src/styles/ProseMirror.scss +0 -176
  302. package/src/styles/columns.scss +0 -23
  303. package/src/styles/editor.scss +0 -411
  304. package/src/styles/global.scss +0 -87
  305. package/src/styles/index.scss +0 -5
  306. package/src/styles/mention.scss +0 -6
  307. package/src/theme/theme.ts +0 -15
  308. package/src/types.ts +0 -271
  309. package/src/utils/_event.ts +0 -55
  310. package/src/utils/color.ts +0 -67
  311. package/src/utils/columns.ts +0 -142
  312. package/src/utils/customEvents/customEvents.ts +0 -18
  313. package/src/utils/customEvents/events.constant.ts +0 -11
  314. package/src/utils/delete-node.ts +0 -46
  315. package/src/utils/dom-dataset.ts +0 -121
  316. package/src/utils/download.ts +0 -17
  317. package/src/utils/dynamicCSS.ts +0 -192
  318. package/src/utils/editor-container-size.ts +0 -28
  319. package/src/utils/file.ts +0 -112
  320. package/src/utils/getRenderContainer.ts +0 -41
  321. package/src/utils/indent.ts +0 -99
  322. package/src/utils/is-mobile.ts +0 -57
  323. package/src/utils/json.ts +0 -18
  324. package/src/utils/line-height.ts +0 -109
  325. package/src/utils/lru-cache.ts +0 -145
  326. package/src/utils/mitt.ts +0 -114
  327. package/src/utils/node.ts +0 -92
  328. package/src/utils/pdf.ts +0 -72
  329. package/src/utils/plateform.ts +0 -49
  330. package/src/utils/shortId.ts +0 -5
  331. package/src/utils/storage.ts +0 -18
  332. package/src/utils/utils.ts +0 -71
  333. package/src/vite-env.d.ts +0 -3
@@ -1,212 +0,0 @@
1
- import { forwardRef, useEffect, useId, useImperativeHandle, useLayoutEffect, useMemo } from 'react';
2
-
3
- import type { AnyExtension, Editor as CoreEditor } from '@tiptap/core';
4
- import type { UseEditorOptions } from '@tiptap/react';
5
- import { EditorContent, useEditor } from '@tiptap/react';
6
- import { differenceBy, throttle } from 'lodash-es';
7
-
8
- import { BubbleMenu, Toolbar, TooltipProvider } from 'reactjs-tiptap-editor-pro/components';
9
- import CharactorCount from 'reactjs-tiptap-editor-pro/components/CharactorCount';
10
- import { Toaster } from 'reactjs-tiptap-editor-pro/components/ui/toaster';
11
- import { EDITOR_UPDATE_WATCH_THROTTLE_WAIT_TIME } from 'reactjs-tiptap-editor-pro/constants';
12
- import { RESET_CSS } from 'reactjs-tiptap-editor-pro/constants/resetCSS';
13
- import { editableEditorActions } from 'reactjs-tiptap-editor-pro/store/editableEditor';
14
- import { ProviderRichText } from 'reactjs-tiptap-editor-pro/store/ProviderRichText';
15
- import { themeActions } from 'reactjs-tiptap-editor-pro/theme/theme';
16
- import type { BubbleMenuProps, ToolbarProps } from 'reactjs-tiptap-editor-pro/types';
17
- import { removeCSS, updateCSS } from 'reactjs-tiptap-editor-pro/utils/dynamicCSS';
18
- import { hasExtension } from 'reactjs-tiptap-editor-pro/utils/utils';
19
-
20
- import '../styles/index.scss';
21
-
22
- /**
23
- * Interface for RichTextEditor component props
24
- */
25
- export interface RichTextEditorProps {
26
- /** Content of the editor */
27
- content: string
28
- /** Extensions for the editor */
29
- extensions: AnyExtension[]
30
-
31
- /** Output format */
32
- output: 'html' | 'json' | 'text'
33
- /** Model value */
34
- modelValue?: string | object
35
- /** Dark mode flag */
36
- dark?: boolean
37
- /** Dense mode flag */
38
- dense?: boolean
39
- /** Disabled flag */
40
- disabled?: boolean
41
- /** Label for the editor */
42
- label?: string
43
- /** Hide toolbar flag */
44
- hideToolbar?: boolean
45
- /** Disable bubble menu flag */
46
- disableBubble?: boolean
47
- /** Hide bubble menu flag */
48
- hideBubble?: boolean
49
- /** Remove default wrapper flag */
50
- removeDefaultWrapper?: boolean
51
- /** Maximum width */
52
- maxWidth?: string | number
53
- /** Minimum height */
54
- minHeight?: string | number
55
- /** Maximum height */
56
- maxHeight?: string | number
57
- /** Content class */
58
- contentClass?: string | string[] | Record<string, any>
59
- /** Content change callback */
60
- onChangeContent?: (val: any) => void
61
- /** Bubble menu props */
62
- bubbleMenu?: BubbleMenuProps
63
- /** Toolbar props */
64
- toolbar?: ToolbarProps
65
-
66
- /** Use editor options */
67
- useEditorOptions?: UseEditorOptions
68
-
69
- /** Use editor options */
70
- resetCSS?: boolean
71
- }
72
-
73
- function RichTextEditor(props: RichTextEditorProps, ref: React.ForwardedRef<{ editor: CoreEditor | null }>) {
74
- const { content, extensions, useEditorOptions = {} } = props;
75
-
76
- const id = useId();
77
-
78
- const sortExtensions = useMemo(() => {
79
- const diff = differenceBy(extensions, extensions, 'name');
80
- const exts = extensions.map((k: any) => {
81
- const find = extensions.find((ext: any) => ext.name === k.name);
82
- if (!find) {
83
- return k;
84
- }
85
- return k.configure(find.options);
86
- });
87
- return [...exts, ...diff].map((k, i) => k.configure({ sort: i }));
88
- }, [extensions]);
89
-
90
- const onValueChange = throttle((editor) => {
91
- const output = getOutput(editor, props.output as any);
92
-
93
- props?.onChangeContent?.(output as any);
94
- }, EDITOR_UPDATE_WATCH_THROTTLE_WAIT_TIME);
95
-
96
- const editor = useEditor({
97
- extensions: sortExtensions,
98
- content,
99
- onUpdate: ({ editor }) => {
100
- if (onValueChange)
101
- onValueChange(editor);
102
- },
103
- ...useEditorOptions,
104
- }) as any;
105
-
106
- useImperativeHandle(ref, () => {
107
- return {
108
- editor,
109
- };
110
- });
111
-
112
- useEffect(() => {
113
- document.documentElement.classList.toggle('dark', props.dark);
114
- themeActions.setTheme(id, props.dark ? 'dark' : 'light');
115
- }, [props.dark]);
116
-
117
- useEffect(() => {
118
- editor?.setEditable(!props?.disabled);
119
- editableEditorActions.setDisable(id, !props?.disabled);
120
- }, [editor, props?.disabled]);
121
-
122
- useEffect(() => {
123
- if (props?.resetCSS !== false) {
124
- updateCSS(RESET_CSS, 'react-tiptap-reset');
125
- }
126
-
127
- return () => {
128
- removeCSS('react-tiptap-reset');
129
- };
130
- }, [props?.resetCSS]);
131
-
132
- function getOutput(editor: CoreEditor, output: RichTextEditorProps['output']) {
133
- if (props?.removeDefaultWrapper) {
134
- if (output === 'html') {
135
- return editor.isEmpty ? '' : editor.getHTML();
136
- }
137
- if (output === 'json') {
138
- return editor.isEmpty ? {} : editor.getJSON();
139
- }
140
- if (output === 'text') {
141
- return editor.isEmpty ? '' : editor.getText();
142
- }
143
- return '';
144
- }
145
-
146
- if (output === 'html') {
147
- return editor.getHTML();
148
- }
149
- if (output === 'json') {
150
- return editor.getJSON();
151
- }
152
- if (output === 'text') {
153
- return editor.getText();
154
- }
155
- return '';
156
- }
157
-
158
- useLayoutEffect(() => {
159
- if (editor) editor!.id = id;
160
- }, [id, editor]);
161
-
162
- useEffect(() => {
163
- return () => {
164
- editor?.destroy?.();
165
- };
166
- }, []);
167
-
168
- const hasExtensionValue = hasExtension(editor, 'characterCount');
169
-
170
- if (!editor) {
171
- return <></>;
172
- }
173
-
174
- return (
175
- <div className="reactjs-tiptap-editor">
176
- <ProviderRichText
177
- id={id}
178
- >
179
- <TooltipProvider delayDuration={0}
180
- disableHoverableContent
181
- >
182
- <div className="overflow-hidden rounded-[0.5rem] bg-background">
183
- <div className="flex max-h-full w-full flex-col">
184
- {!props?.hideToolbar && <Toolbar disabled={!!props?.disabled}
185
- editor={editor}
186
- toolbar={props.toolbar}
187
- />}
188
-
189
- <EditorContent className={`relative ${props?.contentClass || ''}`}
190
- editor={editor}
191
-
192
- />
193
-
194
- {hasExtensionValue && <CharactorCount editor={editor}
195
- extensions={extensions}
196
- />}
197
-
198
- {!props?.hideBubble && <BubbleMenu bubbleMenu={props?.bubbleMenu}
199
- disabled={props?.disabled}
200
- editor={editor}
201
- />}
202
- </div>
203
- </div>
204
- </TooltipProvider>
205
- </ProviderRichText>
206
-
207
- <Toaster />
208
- </div>
209
- );
210
- }
211
-
212
- export default forwardRef(RichTextEditor);
@@ -1,102 +0,0 @@
1
- import { useEffect, useState } from 'react';
2
- import { Button, Input, Label, Popover, PopoverContent, PopoverTrigger } from 'reactjs-tiptap-editor-pro/components/ui';
3
- import { useLocale } from 'reactjs-tiptap-editor-pro/locales';
4
-
5
- interface ISize {
6
- width: number | string, height: number | string
7
- }
8
-
9
- interface IProps {
10
- width: number | string
11
- maxWidth?: number | string
12
- height: number | string
13
- onOk: (arg: ISize) => void
14
- children: React.ReactNode
15
- }
16
-
17
- const containerStyle = { padding: '0 12px 12px' };
18
-
19
- export const SizeSetter: React.FC<IProps> = ({ width, maxWidth, height, onOk, children }: any) => {
20
- const { t } = useLocale();
21
-
22
- const [form, setForm] = useState({
23
- width: '',
24
- height: '',
25
- maxWidth: '',
26
- });
27
-
28
- useEffect(() => {
29
- setForm({
30
- width,
31
- height,
32
- maxWidth,
33
- });
34
- }, [height, maxWidth, width]);
35
-
36
- function handleSubmit(event: any) {
37
- event.preventDefault();
38
- event.stopPropagation();
39
- onOk(form);
40
- }
41
-
42
- return (
43
- <Popover modal>
44
- <PopoverTrigger asChild>
45
- {children}
46
- </PopoverTrigger>
47
-
48
- <PopoverContent>
49
- <div style={containerStyle}>
50
- <form className="flex flex-col gap-2" onSubmit={handleSubmit}>
51
- <Label className="mb-[6px]">
52
- Width
53
- </Label>
54
-
55
- <div className="flex w-full max-w-sm items-center gap-1.5">
56
- <div className="relative items-center w-full max-w-sm">
57
- <Input
58
- type="number"
59
- value={form.width}
60
- required
61
- onChange={e => setForm({ ...form, width: e.target.value })}
62
- />
63
- </div>
64
- </div>
65
-
66
- <Label className="mb-[6px]">
67
- Max Width
68
- </Label>
69
-
70
- <div className="flex w-full max-w-sm items-center gap-1.5">
71
- <div className="relative items-center w-full max-w-sm">
72
- <Input
73
- type="number"
74
- value={form.maxWidth}
75
- required
76
- onChange={e => setForm({ ...form, maxWidth: e.target.value })}
77
- />
78
- </div>
79
- </div>
80
- <Label className="mb-[6px]">
81
- Height
82
- </Label>
83
- <div className="flex w-full max-w-sm items-center gap-1.5">
84
- <div className="relative items-center w-full max-w-sm">
85
- <Input
86
- type="number"
87
- value={form.height}
88
- required
89
- onChange={e => setForm({ ...form, height: e.target.value })}
90
- />
91
- </div>
92
- </div>
93
-
94
- <Button type="submit" className="self-end mt-2">
95
- {t('editor.link.dialog.button.apply')}
96
- </Button>
97
- </form>
98
- </div>
99
- </PopoverContent>
100
- </Popover>
101
- );
102
- };
@@ -1,108 +0,0 @@
1
- import React, { useMemo } from 'react';
2
- import type { Editor } from '@tiptap/core';
3
- import type { ToolbarItemProps, ToolbarProps } from 'reactjs-tiptap-editor-pro/types';
4
-
5
- import { Separator } from 'reactjs-tiptap-editor-pro/components';
6
- import { useLocale } from 'reactjs-tiptap-editor-pro/locales';
7
- import { isFunction } from 'reactjs-tiptap-editor-pro/utils/utils';
8
-
9
- export interface ToolbarComponentProps {
10
- editor: Editor
11
- disabled?: boolean
12
- toolbar?: ToolbarProps
13
- }
14
-
15
- function Toolbar({ editor, disabled, toolbar }: ToolbarComponentProps) {
16
- const { t, lang } = useLocale();
17
-
18
- const toolbarItems = useMemo(() => {
19
- const extensions = [...editor.extensionManager.extensions];
20
- const sortExtensions = extensions.sort((arr, acc) => {
21
- const a = (arr.options).sort ?? -1;
22
- const b = (acc.options).sort ?? -1;
23
- return a - b;
24
- });
25
-
26
- let menus: ToolbarItemProps[] = [];
27
-
28
- for (const extension of sortExtensions) {
29
- const {
30
- button,
31
- divider = false,
32
- spacer = false,
33
- toolbar = true,
34
- } = extension.options;
35
- if (!button || !isFunction(button) || !toolbar) {
36
- continue;
37
- }
38
-
39
- const _button: ToolbarItemProps['button'] | ToolbarItemProps['button'][] = button({
40
- editor,
41
- extension,
42
- t,
43
- });
44
-
45
- if (Array.isArray(_button)) {
46
- const menu: ToolbarItemProps[] = _button.map((k, i) => ({
47
- button: k,
48
- divider: i === _button.length - 1 ? divider : false,
49
- spacer: i === 0 ? spacer : false,
50
- type: extension.type,
51
- name: extension.name,
52
- }));
53
- menus = [...menus, ...menu];
54
- continue;
55
- }
56
-
57
- menus.push({
58
- button: _button,
59
- divider,
60
- spacer,
61
- type: extension.type,
62
- name: extension.name,
63
- });
64
- }
65
- return menus;
66
- }, [editor, t, lang]);
67
-
68
- const containerDom = (innerContent: React.ReactNode) => {
69
- return (
70
- <div
71
- className="toolbar px-1 py-2 !border-b"
72
- style={{
73
- pointerEvents: disabled ? 'none' : 'auto',
74
- opacity: disabled ? 0.5 : 1,
75
- }}
76
- >
77
- <div className="relative flex flex-wrap h-auto gap-y-1 gap-x-1">
78
- {innerContent}
79
- </div>
80
- </div>
81
- );
82
- };
83
-
84
- const dom = toolbarItems.map((item: ToolbarItemProps, key) => {
85
- const ButtonComponent = item.button.component;
86
-
87
- return (
88
- <div className="flex items-center" key={`toolbar-item-${key}`}>
89
- {item?.spacer && <Separator orientation="vertical" className="!h-[16px] !mx-[10px]" />}
90
-
91
- <ButtonComponent
92
- {...item.button.componentProps}
93
- disabled={disabled || item?.button?.componentProps?.disabled}
94
- />
95
-
96
- {item?.divider && <Separator orientation="vertical" className="!h-auto !mx-2" />}
97
- </div>
98
- );
99
- });
100
-
101
- if (toolbar && toolbar?.render) {
102
- return toolbar.render({ editor, disabled: disabled || false }, toolbarItems, dom, containerDom);
103
- }
104
-
105
- return containerDom(dom);
106
- }
107
-
108
- export { Toolbar };
@@ -1,19 +0,0 @@
1
- import React from 'react';
2
-
3
- function Activity() {
4
- return (
5
- <svg
6
- xmlns="http://www.w3.org/2000/svg"
7
- viewBox="0 0 24 24"
8
- width="1em"
9
- height="1em"
10
- >
11
- <path
12
- d="M12 0C5.373 0 0 5.372 0 12c0 6.627 5.373 12 12 12 6.628 0 12-5.373 12-12 0-6.628-5.372-12-12-12m9.949 11H17.05c.224-2.527 1.232-4.773 1.968-6.113A9.966 9.966 0 0 1 21.949 11M13 11V2.051a9.945 9.945 0 0 1 4.432 1.564c-.858 1.491-2.156 4.22-2.392 7.385H13zm-2 0H8.961c-.238-3.165-1.536-5.894-2.393-7.385A9.95 9.95 0 0 1 11 2.051V11zm0 2v8.949a9.937 9.937 0 0 1-4.432-1.564c.857-1.492 2.155-4.221 2.393-7.385H11zm4.04 0c.236 3.164 1.534 5.893 2.392 7.385A9.92 9.92 0 0 1 13 21.949V13h2.04zM4.982 4.887C5.718 6.227 6.726 8.473 6.951 11h-4.9a9.977 9.977 0 0 1 2.931-6.113M2.051 13h4.9c-.226 2.527-1.233 4.771-1.969 6.113A9.972 9.972 0 0 1 2.051 13m16.967 6.113c-.735-1.342-1.744-3.586-1.968-6.113h4.899a9.961 9.961 0 0 1-2.931 6.113"
13
- fill="currentColor"
14
- />
15
- </svg>
16
- );
17
- }
18
-
19
- export default Activity;
@@ -1,24 +0,0 @@
1
- import React from 'react';
2
-
3
- function Animal() {
4
- return (
5
- <svg
6
- xmlns="http://www.w3.org/2000/svg"
7
- viewBox="0 0 24 24"
8
- width="1em"
9
- height="1em"
10
- >
11
- <path
12
- d="M15.5 8a1.5 1.5 0 1 0 .001 3.001A1.5 1.5 0 0 0 15.5 8M8.5 8a1.5 1.5 0 1 0 .001 3.001A1.5 1.5 0 0 0 8.5 8"
13
- fill="currentColor"
14
- />
15
- <path
16
- d="M18.933 0h-.027c-.97 0-2.138.787-3.018 1.497-1.274-.374-2.612-.51-3.887-.51-1.285 0-2.616.133-3.874.517C7.245.79 6.069 0 5.093 0h-.027C3.352 0 .07 2.67.002 7.026c-.039 2.479.276 4.238 1.04 5.013.254.258.882.677 1.295.882.191 3.177.922 5.238 2.536 6.38.897.637 2.187.949 3.2 1.102C8.04 20.6 8 20.795 8 21c0 1.773 2.35 3 4 3 1.648 0 4-1.227 4-3 0-.201-.038-.393-.072-.586 2.573-.385 5.435-1.877 5.925-7.587.396-.22.887-.568 1.104-.788.763-.774 1.079-2.534 1.04-5.013C23.929 2.67 20.646 0 18.933 0M3.223 9.135c-.237.281-.837 1.155-.884 1.238-.15-.41-.368-1.349-.337-3.291.051-3.281 2.478-4.972 3.091-5.031.256.015.731.27 1.265.646-1.11 1.171-2.275 2.915-2.352 5.125-.133.546-.398.858-.783 1.313M12 22c-.901 0-1.954-.693-2-1 0-.654.475-1.236 1-1.602V20a1 1 0 1 0 2 0v-.602c.524.365 1 .947 1 1.602-.046.307-1.099 1-2 1m3-3.48v.02a4.752 4.752 0 0 0-1.262-1.02c1.092-.516 2.239-1.334 2.239-2.217 0-1.842-1.781-2.195-3.977-2.195-2.196 0-3.978.354-3.978 2.195 0 .883 1.148 1.701 2.238 2.217A4.8 4.8 0 0 0 9 18.539v-.025c-1-.076-2.182-.281-2.973-.842-1.301-.92-1.838-3.045-1.853-6.478l.023-.041c.496-.826 1.49-1.45 1.804-3.102 0-2.047 1.357-3.631 2.362-4.522C9.37 3.178 10.555 3 11.948 3c1.447 0 2.685.192 3.733.57 1 .9 2.316 2.465 2.316 4.48.313 1.651 1.307 2.275 1.803 3.102.035.058.068.117.102.178-.059 5.967-1.949 7.01-4.902 7.19m6.628-8.202c-.037-.065-.074-.13-.113-.195a7.587 7.587 0 0 0-.739-.987c-.385-.455-.648-.768-.782-1.313-.076-2.209-1.241-3.954-2.353-5.124.531-.376 1.004-.63 1.261-.647.636.071 3.044 1.764 3.096 5.031.027 1.81-.347 3.218-.37 3.235"
17
- fill="currentColor"
18
- />
19
- </svg>
20
-
21
- );
22
- }
23
-
24
- export default Animal;
@@ -1,13 +0,0 @@
1
- import type { SVGProps } from 'react';
2
-
3
- export function AspectRatio(props: SVGProps<SVGSVGElement>) {
4
- return (
5
- <svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24" {...props}>
6
- <path
7
- fill="currentColor"
8
- d="M19 12h-2v3h-3v2h5zM7 9h3V7H5v5h2zm14-6H3a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h18a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2m0 16H3V5h18z"
9
- >
10
- </path>
11
- </svg>
12
- );
13
- }
@@ -1,17 +0,0 @@
1
- import type { SVGProps } from 'react';
2
-
3
- export function BlockquoteLeft(props: SVGProps<SVGSVGElement>) {
4
- return (
5
- <svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24" {...props}>
6
- <path
7
- fill="none"
8
- stroke="currentColor"
9
- strokeLinecap="round"
10
- strokeLinejoin="round"
11
- strokeWidth="2"
12
- d="M6 15h15m0 4H6m9-8h6m0-4h-6M9 9h1a1 1 0 1 1-1 1V7.5a2 2 0 0 1 2-2M3 9h1a1 1 0 1 1-1 1V7.5a2 2 0 0 1 2-2"
13
- >
14
- </path>
15
- </svg>
16
- );
17
- }
@@ -1,7 +0,0 @@
1
- export function ColumnAddLeft() {
2
- return (
3
- <svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24">
4
- <path fill="none" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M14 4h4a1 1 0 0 1 1 1v14a1 1 0 0 1-1 1h-4a1 1 0 0 1-1-1V5a1 1 0 0 1 1-1m-9 8h4m-2-2v4"></path>
5
- </svg>
6
- );
7
- }
@@ -1,7 +0,0 @@
1
- export function ColumnAddRight() {
2
- return (
3
- <svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24">
4
- <path fill="none" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M6 4h4a1 1 0 0 1 1 1v14a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V5a1 1 0 0 1 1-1m9 8h4m-2-2v4"></path>
5
- </svg>
6
- );
7
- }
@@ -1,26 +0,0 @@
1
- function DeleteColumn() {
2
- return (
3
- <svg
4
- xmlns="http://www.w3.org/2000/svg"
5
- xmlnsXlink="http://www.w3.org/1999/xlink"
6
- aria-hidden="true"
7
- role="img"
8
- className="w-4 h-4"
9
- width="1em"
10
- height="1em"
11
- viewBox="0 0 24 24"
12
- >
13
- <path
14
- fill="none"
15
- stroke="currentColor"
16
- strokeLinecap="round"
17
- strokeLinejoin="round"
18
- strokeWidth="1.5"
19
- d="M5.5 3c1.404 0 2.107 0 2.611.38c.219.164.406.375.552.62C9 4.568 9 5.358 9 6.938v10.125c0 1.58 0 2.37-.337 2.937a2.1 2.1 0 0 1-.552.621c-.504.38-1.207.38-2.611.38s-2.107 0-2.611-.38a2.1 2.1 0 0 1-.552-.62C2 19.432 2 18.642 2 17.062V6.938c0-1.58 0-2.37.337-2.938a2.1 2.1 0 0 1 .552-.62C3.393 3 4.096 3 5.5 3M20 11.938v5.124c0 1.58 0 2.37-.337 2.938a2.1 2.1 0 0 1-.552.62c-.504.38-1.207.38-2.611.38s-2.107 0-2.611-.38a2.1 2.1 0 0 1-.552-.62C13 19.433 13 18.642 13 17.063V6.938c0-1.58 0-2.37.337-2.938M22 9l-6-6m6 0l-6 6"
20
- color="currentColor"
21
- />
22
- </svg>
23
- );
24
- }
25
-
26
- export { DeleteColumn };
@@ -1,26 +0,0 @@
1
- function DeleteRow() {
2
- return (
3
- <svg
4
- xmlns="http://www.w3.org/2000/svg"
5
- xmlnsXlink="http://www.w3.org/1999/xlink"
6
- aria-hidden="true"
7
- role="img"
8
- className="w-4 h-4"
9
- width="1em"
10
- height="1em"
11
- viewBox="0 0 24 24"
12
- >
13
- <path
14
- fill="none"
15
- stroke="currentColor"
16
- strokeLinecap="round"
17
- strokeLinejoin="round"
18
- strokeWidth="1.5"
19
- d="M21 18.5c0 1.404 0 2.107-.38 2.611a2.1 2.1 0 0 1-.62.552c-.567.337-1.358.337-2.937.337H6.938c-1.58 0-2.37 0-2.938-.337a2.1 2.1 0 0 1-.62-.552C3 20.607 3 19.904 3 18.5s0-2.107.38-2.611c.163-.218.374-.406.62-.552C4.567 15 5.357 15 6.938 15h10.125c1.58 0 2.37 0 2.937.337c.246.146.457.334.62.552c.38.504.38 1.207.38 2.611M12.063 4H6.937C5.358 4 4.568 4 4 4.337a2.1 2.1 0 0 0-.62.552C3 5.393 3 6.096 3 7.5s0 2.107.38 2.611c.163.218.374.406.62.552C4.567 11 5.357 11 6.938 11h10.125c1.58 0 2.37 0 2.937-.337M21 8l-6-6m6 0l-6 6"
20
- color="currentColor"
21
- />
22
- </svg>
23
- );
24
- }
25
-
26
- export { DeleteRow };
@@ -1,7 +0,0 @@
1
- export function Direction() {
2
- return (
3
- <svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24">
4
- <path fill="none" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M12 21v-4m0-4V9m0-4V3m-2 18h4M8 5v4h11l2-2l-2-2zm6 8v4H6l-2-2l2-2z"></path>
5
- </svg>
6
- );
7
- }
@@ -1,7 +0,0 @@
1
- export function Excalidraw() {
2
- return (
3
- <svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24">
4
- <path fill="currentColor" d="M23.943 19.806a.2.2 0 0 0-.168-.034c-1.26-1.855-2.873-3.61-4.419-5.315l-.252-.284c-.001-.073-.067-.12-.134-.15l-.084-.084c-.05-.1-.169-.167-.286-.1c-.47.234-.907.585-1.327.919c-.554.434-1.109.87-1.63 1.354a5 5 0 0 0-.588.618c-.084.117-.017.217.084.267c-.37.368-.74.736-1.109 1.12a.2.2 0 0 0-.05.134c0 .05.033.1.067.117l.655.502v.016c.924.92 2.554 2.173 4.285 3.527c.251.201.52.402.773.602c.117.134.234.285.335.418c.05.066.169.084.236.033c.033.034.084.067.118.1a.24.24 0 0 0 .1.034a.15.15 0 0 0 .135-.066a.24.24 0 0 0 .033-.1c.017 0 .017.016.034.016a.2.2 0 0 0 .134-.05l3.058-3.327c.12-.116.014-.267 0-.267m-7.628-.134l-1.546-1.17l-.15-.1c-.035-.017-.068-.05-.102-.067l-.117-.1c.66-.66 1.33-1.308 2-1.956c-.488.484-1.463 1.906-1.261 2.373c.002 0 .018.042.067.084zm4.1 3.126l-1.277-.97a27 27 0 0 0-1.58-1.504c.69.518 1.277.97 1.361 1.053c.673.585.638.485 1.093.87l.554.4c-.074.103-.151.148-.151.151m.336.25l-.034-.016a1 1 0 0 0 .152-.117zM.588 3.476c.033.217.084.435.117.636c.201 1.103.403 2.106.772 2.858l.152.568c.05.217.134.485.219.552a67 67 0 0 0 3.578 2.942a.18.18 0 0 0 .219 0s0 .016.016.016a.15.15 0 0 0 .118.05a.2.2 0 0 0 .134-.05c1.798-1.989 3.142-3.627 4.1-4.998c.068-.066.084-.167.084-.25c.067-.067.118-.151.185-.201c.067-.067.067-.184 0-.235l-.017-.016c0-.033-.017-.084-.05-.1c-.42-.401-.722-.685-1.042-.986a94 94 0 0 1-2.352-2.273c-.017-.017-.034-.034-.067-.034c-.336-.117-1.025-.234-1.882-.385c-1.277-.216-3.008-.517-4.57-.986c0 0-.101 0-.118.017l-.05.05C.05.714.022.707 0 .718c.017.1.017.167.05.284c0 .033.068.301.068.334zm7.19 4.78l-.033.034a.036.036 0 0 1 .033-.034M6.553 2.238c.101.1.521.502.622.585c-.437-.2-1.529-.702-2.034-.869c.505.1 1.194.201 1.412.284M.79 1.403c.252.434.454 1.939.655 3.41c-.118-.469-.201-.936-.302-1.372C.992 2.673.84 1.988.638 1.386c.124 0 .152.021.152.017m-.286-.369c0-.016 0-.033-.017-.033c.085 0 .135.017.202.05c0 .006-.145-.017-.185-.017m23.17-.217c.017-.066-.336-.367-.219-.384c.253-.017.253-.401 0-.401c-.335.017-.688.1-1.008.15c-.587.117-1.192.234-1.78.367a80 80 0 0 0-3.949.937c-.403.117-.857.2-1.243.401c-.135.067-.118.2-.05.284c-.034.017-.051.017-.085.034c-.117.017-.218.034-.335.05c-.102.017-.152.1-.135.2c0 .017.017.05.017.067c-.706.936-1.496 1.923-2.353 2.976c-.84.969-1.73 1.989-2.62 3.042c-2.84 3.31-6.05 7.07-9.594 10.38a.16.16 0 0 0 0 .234c.016.016.033.033.05.033c-.05.05-.101.085-.152.134q-.05.05-.05.1a.4.4 0 0 0-.067.084c-.067.067-.067.184.017.234c.067.066.185.066.235-.017c.017-.017.017-.033.033-.033a.265.265 0 0 1 .37 0c.202.217.404.435.588.618l-.42-.35c-.067-.067-.184-.05-.234.016c-.068.066-.051.184.016.234l4.469 3.727c.034.034.067.034.118.034a.15.15 0 0 0 .117-.05l.101-.1c.017.016.05.016.067.016c.05 0 .084-.016.118-.05c6.049-6.05 10.922-10.614 16.5-14.693c.05-.033.067-.1.067-.15c.067 0 .118-.05.15-.117c1.026-3.125 1.228-5.9 1.295-7.27c0-.059.016-.038.016-.068c.017-.033.017-.05.017-.05a.98.98 0 0 0-.067-.619m-10.82 4.915c.268-.301.537-.619.806-.903c-1.73 2.273-4.603 5.767-8.67 9.929c2.773-3.059 5.562-6.218 7.864-9.026M5.14 23.466c-.016-.017-.016-.017 0-.017zm2.504-2.156c.135-.15.27-.284.42-.434c0 0 0 .016.017.016c-.224.198-.433.418-.437.418m.69-.668c.099-.1.14-.173.284-.318c.992-1.02 2.017-2.04 3.059-3.076l.016-.016c.252-.2.555-.418.824-.619a228 228 0 0 0-4.184 4.029M14.852 3.91c-.554.719-1.176 1.671-1.697 2.423c-1.646 2.374-6.94 8.174-7.057 8.274a1190 1190 0 0 1-4.839 4.597l-.1.1c-.085-.1-.085-.25.016-.334C8.652 11.966 13.19 6.133 15.021 3.576c-.05.116-.084.216-.168.334zm2.906 3.427c-.671-.386-.99-.987-.806-1.572l.05-.2a.8.8 0 0 1 .085-.167a1.9 1.9 0 0 1 .756-.703c.016 0 .033 0 .05-.016c-.017-.034-.017-.084-.017-.134c.017-.1.085-.167.202-.167c.202 0 .824.184 1.059.384c.067.05.134.117.202.184c.084.1.218.268.285.401c.034.017.067.184.118.268c.033.134.067.284.05.418c-.017.016 0 .116-.017.116a1.6 1.6 0 0 1-.218.619c-.03.03.006.012-.05.067a1.2 1.2 0 0 1-.32.334a1.49 1.49 0 0 1-1.26.234a2 2 0 0 0-.169-.066m4.37 1.403c0 .017-.017.05 0 .067c-.034 0-.05.017-.085.034a110 110 0 0 0-3.915 3.025c1.11-.986 2.218-1.989 3.378-2.975c.336-.301.571-.686.638-1.12l.168-1.003v-.033c.085-.201.404-.118.353.1c-.004-.001-.173.795-.537 1.905"></path>
5
- </svg>
6
- );
7
- }
@@ -1,8 +0,0 @@
1
- export function ExportPdf() {
2
- return (
3
- <svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 32 32">
4
- <path fill="currentColor" d="M30 18v-2h-6v10h2v-4h3v-2h-3v-2zm-11 8h-4V16h4a3.003 3.003 0 0 1 3 3v4a3.003 3.003 0 0 1-3 3m-2-2h2a1 1 0 0 0 1-1v-4a1 1 0 0 0-1-1h-2zm-6-8H6v10h2v-3h3a2.003 2.003 0 0 0 2-2v-3a2 2 0 0 0-2-2m-3 5v-3h3l.001 3z"></path>
5
- <path fill="currentColor" d="M22 14v-4a.91.91 0 0 0-.3-.7l-7-7A.9.9 0 0 0 14 2H4a2.006 2.006 0 0 0-2 2v24a2 2 0 0 0 2 2h16v-2H4V4h8v6a2.006 2.006 0 0 0 2 2h6v2Zm-8-4V4.4l5.6 5.6Z"></path>
6
- </svg>
7
- );
8
- }
@@ -1,24 +0,0 @@
1
- import React from 'react';
2
-
3
- function ExportWord() {
4
- return (
5
- <svg
6
- xmlns="http://www.w3.org/2000/svg"
7
- width="1em"
8
- height="1em"
9
- className="icon"
10
- viewBox="0 0 1024 1024"
11
- >
12
- <path
13
- fill="currentColor"
14
- d="M679.253 402.364 618.77 561.015l-60.348-158.651a30.04 30.04 0 0 0-30.447-18.637 29.76 29.76 0 0 0-30.447 18.637l-60.416 158.651-60.416-158.651a30.515 30.515 0 0 0-38.843-17.272 28.945 28.945 0 0 0-17.954 37.547l88.815 233.267c4.369 11.469 15.7 19.115 28.398 19.115a30.31 30.31 0 0 0 28.468-19.115l62.395-163.908 62.396 163.84c4.437 11.605 15.701 19.183 28.4 19.183a30.31 30.31 0 0 0 28.466-19.115l88.747-233.267a28.945 28.945 0 0 0-17.886-37.547 30.447 30.447 0 0 0-38.912 17.272zm219.478 395.605-51.883-29.218c-28.672-16.18-52.224-3.072-52.224 29.082v.273H643.209a29.833 29.833 0 0 0-30.31 29.354c0 16.18 13.584 29.218 30.31 29.218h151.825c1.092 30.516 24.03 43.077 52.224 27.648l51.063-27.989c29.013-15.906 29.15-42.189.41-58.368"
15
- />
16
- <path
17
- fill="currentColor"
18
- d="m810.667 913.135-.478.068H201.796c-19.865 0-36.727-11.673-36.727-25.6v-618.36h154.965c51.268 0 92.911-39.39 92.911-87.858v-87.86H810.19c19.797 0 36.522 11.742 36.522 25.669V739.26h61.987V119.262c0-46.421-44.169-84.241-98.51-84.241H328.364l-225.28 194.56v658.09c0 46.285 44.236 84.105 98.713 84.105H810.19c43.759 0 80.554-24.713 93.32-58.573h-92.842zM350.89 94.89v86.562c0 16.11-13.858 29.286-30.925 29.286H216.815L350.959 94.891z"
19
- />
20
- </svg>
21
- );
22
- }
23
-
24
- export default ExportWord;
@@ -1,13 +0,0 @@
1
- import type { SVGProps } from 'react';
2
-
3
- export function FileWordOutline(props: SVGProps<SVGSVGElement>) {
4
- return (
5
- <svg xmlns="http://www.w3.org/2000/svg" width="1em" height="1em" viewBox="0 0 24 24" {...props}>
6
- <path
7
- fill="currentColor"
8
- d="M14 2H6a2 2 0 0 0-2 2v16c0 1.11.89 2 2 2h12c1.11 0 2-.89 2-2V8zm4 18H6V4h7v5h5zm-.65-10l-2.1 9h-1.4l-1.8-6.79l-1.8 6.79h-1.4l-2.2-9h1.5l1.4 6.81l1.8-6.81h1.3l1.8 6.81l1.4-6.81z"
9
- >
10
- </path>
11
- </svg>
12
- );
13
- }
@@ -1,19 +0,0 @@
1
- import React from 'react';
2
-
3
- function Flag() {
4
- return (
5
- <svg
6
- xmlns="http://www.w3.org/2000/svg"
7
- viewBox="0 0 24 24"
8
- width="1em"
9
- height="1em"
10
- >
11
- <path
12
- d="M0 0l6.084 24H8L1.916 0zM21 5h-4l-1-4H4l3 12h3l1 4h13L21 5zM6.563 3h7.875l2 8H8.563l-2-8zm8.832 10l-2.856 1.904L12.063 13h3.332zM19 13l-1.5-6h1.938l2 8H16l3-2z"
13
- fill="currentColor"
14
- />
15
- </svg>
16
- );
17
- }
18
-
19
- export default Flag;