@kennethmakjw/appflowy-editor-react19 0.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (152) hide show
  1. package/README.md +306 -0
  2. package/dist/ar-SA-B3W2Oswh.cjs +8 -0
  3. package/dist/ar-SA-CaPcPWVS.js +8 -0
  4. package/dist/ca-ES-DehQhAeM.js +8 -0
  5. package/dist/ca-ES-WjpoQZs5.cjs +8 -0
  6. package/dist/ckb-KU-Cc13dwJI.cjs +8 -0
  7. package/dist/ckb-KU-DXz5rZMu.js +8 -0
  8. package/dist/components/Leaf.d.ts +3 -0
  9. package/dist/components/element/BulletedList.d.ts +3 -0
  10. package/dist/components/element/Checkbox.d.ts +3 -0
  11. package/dist/components/element/CodeBlock/index.d.ts +3 -0
  12. package/dist/components/element/CodeBlock/useDecorate.d.ts +3 -0
  13. package/dist/components/element/CodeBlock/utils.d.ts +2 -0
  14. package/dist/components/element/Divider.d.ts +3 -0
  15. package/dist/components/element/Element.d.ts +3 -0
  16. package/dist/components/element/Heading.d.ts +3 -0
  17. package/dist/components/element/Image.d.ts +3 -0
  18. package/dist/components/element/LinkPreview.d.ts +3 -0
  19. package/dist/components/element/NumberedList.d.ts +3 -0
  20. package/dist/components/element/Quote.d.ts +3 -0
  21. package/dist/components/element/Table.d.ts +3 -0
  22. package/dist/components/element/TableCell.d.ts +3 -0
  23. package/dist/components/element/TableRow.d.ts +3 -0
  24. package/dist/components/element/index.d.ts +1 -0
  25. package/dist/components/fixed-toolbar/Aa.d.ts +2 -0
  26. package/dist/components/fixed-toolbar/BIUS.d.ts +4 -0
  27. package/dist/components/fixed-toolbar/Color.d.ts +2 -0
  28. package/dist/components/fixed-toolbar/FixedToolbar.d.ts +2 -0
  29. package/dist/components/fixed-toolbar/List.d.ts +2 -0
  30. package/dist/components/fixed-toolbar/index.d.ts +1 -0
  31. package/dist/components/ui/alert.d.ts +8 -0
  32. package/dist/components/ui/button.d.ts +15 -0
  33. package/dist/components/ui/input.d.ts +3 -0
  34. package/dist/components/ui/label.d.ts +5 -0
  35. package/dist/components/ui/loading-dots.d.ts +4 -0
  36. package/dist/components/ui/popover.d.ts +12 -0
  37. package/dist/components/ui/select.d.ts +13 -0
  38. package/dist/components/ui/separator.d.ts +4 -0
  39. package/dist/components/ui/switch.d.ts +4 -0
  40. package/dist/components/ui/tooltip.d.ts +7 -0
  41. package/dist/cs-CZ-B7cFODNF.js +8 -0
  42. package/dist/cs-CZ-BiGttx8Y.cjs +8 -0
  43. package/dist/de-DE-3L1r5Sau.cjs +8 -0
  44. package/dist/de-DE-CJLJMQlm.js +8 -0
  45. package/dist/dev/App.d.ts +1 -0
  46. package/dist/dev/MarkdownDemo.d.ts +2 -0
  47. package/dist/dev/i18n.d.ts +1 -0
  48. package/dist/dev/main.d.ts +1 -0
  49. package/dist/editor/Editor.d.ts +3 -0
  50. package/dist/editor/RichText.d.ts +12 -0
  51. package/dist/editor/context.d.ts +6 -0
  52. package/dist/editor/index.d.ts +2 -0
  53. package/dist/editor/useEditor.d.ts +5 -0
  54. package/dist/editor/useKeydown.d.ts +3 -0
  55. package/dist/es-VE-IXYuj5s7.js +8 -0
  56. package/dist/es-VE-ZvJoouw6.cjs +8 -0
  57. package/dist/eu-ES-BGs4iMYs.js +8 -0
  58. package/dist/eu-ES-DjInTP04.cjs +8 -0
  59. package/dist/fa-BCkDldDE.js +8 -0
  60. package/dist/fa-BsZBNwW8.cjs +8 -0
  61. package/dist/fr-CA-BlpVaep8.cjs +8 -0
  62. package/dist/fr-CA-v0JzOPW4.js +8 -0
  63. package/dist/fr-FR-CiKan-7_.cjs +8 -0
  64. package/dist/fr-FR-DsF3n-KY.js +8 -0
  65. package/dist/he-BwXJVdkh.cjs +8 -0
  66. package/dist/he-DtMbntw2.js +8 -0
  67. package/dist/hu-HU-B6cP2C9b.cjs +8 -0
  68. package/dist/hu-HU-BIfnlWEM.js +8 -0
  69. package/dist/i18n/config.d.ts +3 -0
  70. package/dist/i18n/index.d.ts +4 -0
  71. package/dist/id-ID-AOveF0gP.js +8 -0
  72. package/dist/id-ID-cZS98QKP.cjs +8 -0
  73. package/dist/index.css +1593 -0
  74. package/dist/index.d.ts +3 -0
  75. package/dist/index.js +10266 -0
  76. package/dist/index.mjs +10250 -0
  77. package/dist/it-IT-DN-rTKuB.js +8 -0
  78. package/dist/it-IT-rGclB8nF.cjs +8 -0
  79. package/dist/ja-JP-BT23Z2YG.js +8 -0
  80. package/dist/ja-JP-DaiwUIKv.cjs +8 -0
  81. package/dist/ko-KR-CBlhTpPW.cjs +8 -0
  82. package/dist/ko-KR-DYwSdomr.js +8 -0
  83. package/dist/lib/color.d.ts +50 -0
  84. package/dist/lib/editor.d.ts +11 -0
  85. package/dist/lib/hotkeys.d.ts +66 -0
  86. package/dist/lib/list.d.ts +6 -0
  87. package/dist/lib/markdown.d.ts +3 -0
  88. package/dist/lib/mdast.d.ts +5 -0
  89. package/dist/lib/mdast.test.d.ts +1 -0
  90. package/dist/lib/transform.d.ts +7 -0
  91. package/dist/lib/utils.d.ts +9 -0
  92. package/dist/locales/ar-SA.json +17 -0
  93. package/dist/locales/ca-ES.json +17 -0
  94. package/dist/locales/ckb-KU.json +5 -0
  95. package/dist/locales/cs-CZ.json +17 -0
  96. package/dist/locales/de-DE.json +17 -0
  97. package/dist/locales/en.json +38 -0
  98. package/dist/locales/es-VE.json +17 -0
  99. package/dist/locales/eu-ES.json +17 -0
  100. package/dist/locales/fa.json +17 -0
  101. package/dist/locales/fr-CA.json +17 -0
  102. package/dist/locales/fr-FR.json +17 -0
  103. package/dist/locales/he.json +17 -0
  104. package/dist/locales/hu-HU.json +17 -0
  105. package/dist/locales/id-ID.json +17 -0
  106. package/dist/locales/it-IT.json +17 -0
  107. package/dist/locales/ja-JP.json +17 -0
  108. package/dist/locales/ko-KR.json +17 -0
  109. package/dist/locales/pl-PL.json +17 -0
  110. package/dist/locales/pt-BR.json +17 -0
  111. package/dist/locales/pt-PT.json +17 -0
  112. package/dist/locales/ru-RU.json +17 -0
  113. package/dist/locales/sv-SE.json +17 -0
  114. package/dist/locales/th-TH.json +17 -0
  115. package/dist/locales/tr-TR.json +17 -0
  116. package/dist/locales/uk-UA.json +17 -0
  117. package/dist/locales/vi-VN.json +17 -0
  118. package/dist/locales/vi.json +17 -0
  119. package/dist/locales/zh-CN.json +17 -0
  120. package/dist/locales/zh-TW.json +17 -0
  121. package/dist/markdown-BidIaSbx.cjs +3274 -0
  122. package/dist/markdown-CeG0xHLH.js +3275 -0
  123. package/dist/pl-PL-C_wxsekf.js +8 -0
  124. package/dist/pl-PL-DBrdwSfX.cjs +8 -0
  125. package/dist/plugins/index.d.ts +2 -0
  126. package/dist/plugins/withMarkdown.d.ts +2 -0
  127. package/dist/plugins/withPasted.d.ts +18 -0
  128. package/dist/pt-BR-CcIBbs5v.js +8 -0
  129. package/dist/pt-BR-CpCH-0Ym.cjs +8 -0
  130. package/dist/pt-PT-2DJTSiTI.js +8 -0
  131. package/dist/pt-PT-CuvXqmHX.cjs +8 -0
  132. package/dist/ru-RU-BcrEOraZ.cjs +8 -0
  133. package/dist/ru-RU-DZ-BGTMT.js +8 -0
  134. package/dist/sv-SE-B-1TVV6s.js +8 -0
  135. package/dist/sv-SE-EHxWN7g5.cjs +8 -0
  136. package/dist/th-TH-B2osIZz0.cjs +8 -0
  137. package/dist/th-TH-HhkGXVcg.js +8 -0
  138. package/dist/tr-TR-DKzjnjXz.js +8 -0
  139. package/dist/tr-TR-DPok6TDa.cjs +8 -0
  140. package/dist/types/element.d.ts +10 -0
  141. package/dist/types/index.d.ts +53 -0
  142. package/dist/uk-UA-CvadWbnH.cjs +8 -0
  143. package/dist/uk-UA-Us4Zq40s.js +8 -0
  144. package/dist/vi-DGchnzC4.cjs +8 -0
  145. package/dist/vi-DV4OvZ5s.js +8 -0
  146. package/dist/vi-VN-BZdQFzYv.js +8 -0
  147. package/dist/vi-VN-DzF53ZQz.cjs +8 -0
  148. package/dist/zh-CN-D7lPKvRq.js +8 -0
  149. package/dist/zh-CN-FWhRTZFL.cjs +8 -0
  150. package/dist/zh-TW-D24z6DBg.js +8 -0
  151. package/dist/zh-TW-DSEvmJwy.cjs +8 -0
  152. package/package.json +103 -0
package/README.md ADDED
@@ -0,0 +1,306 @@
1
+ # AppFlowy Web Editor
2
+
3
+ A modern editor library with support for rich text, markdown, and code editing.
4
+
5
+ ## ✨ Features
6
+
7
+ - 🌓 Day/Night mode switching
8
+ - 🌍 Multi-language support
9
+ - 📱 Responsive design
10
+ - 💪 TypeScript support
11
+ - 📝 Rich text, markdown, and code editing
12
+ - 📦 Easy to integrate
13
+ - 🎉 And more!
14
+
15
+ ## 📦 Installation
16
+
17
+ To install the AppFlowy Web Editor, run the following command:
18
+
19
+ ```bash
20
+ npm install @appflowyinc/editor
21
+
22
+ # or
23
+
24
+ yarn add @appflowyinc/editor
25
+
26
+ # or
27
+
28
+ pnpm add @appflowyinc/editor
29
+ ```
30
+
31
+ Note: This package requires these peer dependencies to be installed:
32
+
33
+ ```
34
+ "peerDependencies": {
35
+ "i18next": "^22.4.10",
36
+ "i18next-resources-to-backend": "^1.2.1",
37
+ "react": "^18.3.1",
38
+ "react-dom": "^18.3.1",
39
+ "react-i18next": "^14.1.0",
40
+ "slate": "^0.112.0",
41
+ "slate-history": "^0.110.3",
42
+ "slate-react": "^0.112.0"
43
+ }
44
+ ```
45
+
46
+ ## 🚀 Quick Start
47
+
48
+ To use the AppFlowy Web Editor, import the `Editor` and `EditorProvider` components from the package and wrap your app
49
+
50
+ Note: Using the editor requires the `EditorProvider` component. Therefore, each `Editor` component needs to be wrapped
51
+ by the corresponding `EditorProvider`
52
+
53
+ ```tsx
54
+
55
+ import { Editor, EditorProvider } from '@appflowyinc/editor';
56
+
57
+ const App = () => {
58
+ return <EditorProvider>
59
+ <Editor/>
60
+ </EditorProvider>
61
+ };
62
+
63
+ export default App;
64
+ ```
65
+
66
+ ## 🎨 Custom Toolbar
67
+
68
+ The AppFlowy Web Editor provides a toolbar with various options for editing content. You can customize the toolbar by
69
+ passing the `ToolbarComponent` prop to the `Editor` component.
70
+
71
+ ```tsx
72
+ import { Editor, EditorProvider, FixedToolbar } from '@appflowyinc/editor';
73
+
74
+ const App = () => {
75
+ return <EditorProvider>
76
+ <Editor ToolbarComponent={FixedToolbar}/>
77
+ </EditorProvider>;
78
+ };
79
+
80
+ export default App;
81
+ ```
82
+
83
+ ## 📚 Apply Data
84
+
85
+ You can get `editor` from the `useEditor` hook and apply data to the editor.
86
+
87
+ ```tsx
88
+ import { Editor, EditorProvider, useEditor, NodeType } from '@appflowyinc/editor';
89
+
90
+ const App = () => {
91
+ const editor = useEditor();
92
+
93
+ useEffect(() => {
94
+ editor.applyData({
95
+ type: NodeType.Paragraph,
96
+ delta: [
97
+ {
98
+ insert: 'Hello, World!',
99
+ },
100
+ ],
101
+ children: []
102
+ });
103
+
104
+ // or apply markdown
105
+ editor.applyMarkdown('# Hello, World!');
106
+ }, []);
107
+
108
+ return
109
+ <Editor/>;
110
+ };
111
+
112
+ const Main = () => {
113
+ return <EditorProvider>
114
+ <App/>
115
+ </EditorProvider>;
116
+ };
117
+
118
+ export default App;
119
+ ```
120
+
121
+ ## 💡 Theme Switching
122
+
123
+ The AppFlowy Web Editor supports theme switching between light and dark modes. You can customize the themes by passing
124
+ the `theme` prop to the `Editor` component.
125
+
126
+ ```tsx
127
+ import { Editor, EditorProvider } from '@appflowyinc/editor';
128
+
129
+ const App = () => {
130
+ return <EditorProvider>
131
+ <Editor theme={'dark'}/>
132
+ </EditorProvider>;
133
+ };
134
+
135
+ export default App;
136
+ ```
137
+
138
+ ## 🌍 Multi-language Usage
139
+
140
+ The AppFlowy Web Editor supports multiple languages. You can customize the language by passing the `language` prop to
141
+ the `Editor` component.
142
+
143
+ ```tsx
144
+
145
+ import { Editor, EditorProvider } from '@appflowyinc/editor';
146
+ // Optionally, you can import the language resources from the package
147
+ import zh from '@appflowyinc/editor/locales/zh-CN.json';
148
+
149
+ import hostI18n from 'i18next';
150
+
151
+ const App = () => {
152
+ return <I18nextProvider i18n={hostI18n}>
153
+ <EditorProvider>
154
+ <Editor locale={{
155
+ // The language code.
156
+ lang: 'zh-CN',
157
+ // Optionally, you can pass the language resources or let it use the default resources
158
+ resources: zh,
159
+ }}/>
160
+ </EditorProvider>
161
+ </I18nextProvider>;
162
+ };
163
+
164
+ export default App;
165
+ ```
166
+
167
+ ### Supported Languages
168
+
169
+ - English(en)
170
+ - Arabic(ar-SA)
171
+ - Catalan(ca-ES)
172
+ - Central Kurdish(ckb-KU)
173
+ - Czech(cs-CZ)
174
+ - German(de-DE)
175
+ - Spanish(es-VE)
176
+ - Basque(eu-ES)
177
+ - Persian(fa)
178
+ - French(fr-CA)
179
+ - French(fr-FR)
180
+ - Hebrew(he)
181
+ - Hungarian(hu-HU)
182
+ - Indonesian(id-ID)
183
+ - Italian(it-IT)
184
+ - Japanese(ja-JP)
185
+ - Korean(ko-KR)
186
+ - Polish(pl-PL)
187
+ - Brazilian Portuguese(pt-BR)
188
+ - Portuguese(pt-PT)
189
+ - Russian(ru-RU)
190
+ - Swedish(sv-SE)
191
+ - Thai(th-TH)
192
+ - Turkish(tr-TR)
193
+ - Ukrainian(uk-UA)
194
+ - Vietnamese(vi)
195
+ - Vietnamese(vi-VN)
196
+ - Simplified Chinese(zh-CN)
197
+ - Traditional Chinese(zh-TW)
198
+
199
+ ## 📖 API
200
+
201
+ ### Editor Props
202
+
203
+ | Prop | Type | Default | Description |
204
+ |------------------|--------------------------------------------------------|-----------|--------------------------------------|
205
+ | theme | `'light' \| 'dark'` | `'light'` | Editor theme |
206
+ | locale | `{ lang: string; resources?: Record<string, string> }` | - | Editor language configuration |
207
+ | readOnly | `boolean` | `false` | Whether the editor is read-only |
208
+ | onChange | `(data: EditorData) => void` | - | Callback when editor content changes |
209
+ | initialValue | `EditorData` | - | Initial editor content |
210
+ | modalZIndex | `number` | 50 | Editor modal z-index |
211
+ | ToolbarComponent | `FC` | - | Custom toolbar component |
212
+
213
+ ### EditorProvider Props
214
+
215
+ | Prop | Type | Default | Description |
216
+ |----------|-------------|---------|-------------------------|
217
+ | children | `ReactNode` | - | The children components |
218
+
219
+ ### EditorData
220
+
221
+ ```ts
222
+ type EditorData = {
223
+ type: NodeType;
224
+ data: Record<string, any>;
225
+ delta: DeltaOperation[];
226
+ children: EditorData[];
227
+ };
228
+ ```
229
+
230
+ ### NodeType
231
+
232
+ ```ts
233
+
234
+ enum NodeType {
235
+ Paragraph = 'paragraph',
236
+ Heading = 'heading',
237
+ NestedBlock = 'nested-block',
238
+ Todo = 'todo_list',
239
+ NumberedList = 'numbered_list',
240
+ BulletedList = 'bulleted_list',
241
+ Quote = 'quote',
242
+ }
243
+ ```
244
+
245
+ ### Hooks
246
+
247
+ #### useEditor
248
+
249
+ Returns the editor instance with methods to control the editor.
250
+
251
+ ```ts
252
+ const editor = useEditor();
253
+ ```
254
+
255
+ | Method | Description |
256
+ |---------------|------------------------------|
257
+ | applyData | Apply data to the editor |
258
+ | applyMarkdown | Apply markdown to the editor |
259
+
260
+ ## 🔨 Development
261
+
262
+ Guide
263
+
264
+ ###
265
+
266
+ Development
267
+ Mode
268
+
269
+ ```
270
+
271
+ # Install dependencies
272
+
273
+ pnpm i
274
+
275
+ # Start development server
276
+
277
+ pnpm run dev
278
+
279
+ # Build library
280
+
281
+ pnpm run build
282
+
283
+ ```
284
+
285
+ To run the demo locally:
286
+
287
+ ```bash
288
+ pnpm install
289
+ pnpm run dev
290
+ ```
291
+
292
+ Open [http://localhost:5173/](http://localhost:5173/) with your browser to see the result.
293
+ ![img.png](img.png)
294
+
295
+ Switch between light and dark mode by clicking the theme switcher in the top right corner.
296
+ ![img_1.png](img_1.png)
297
+
298
+ ## 📄 License
299
+
300
+ MIT License
301
+
302
+ ```
303
+
304
+ []: # (END) README.md
305
+
306
+
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const editor = { "placeholder": "اكتب شيئا...", "fontColorDefault": "تقصير", "fontColorRed": "أحمر", "fontColorGreen": "أخضر", "fontColorBlue": "أزرق", "fontColorYellow": "أصفر", "fontColorOrange": "البرتقالي", "fontColorPurple": "أرجواني", "fontColorPink": "لون القرنفل", "fontColorBrown": "بني", "fontColorGray": "رمادي", "backgroundColorDefault": "تقصير", "backgroundColorRed": "أحمر" };
4
+ const arSA = {
5
+ editor
6
+ };
7
+ exports.default = arSA;
8
+ exports.editor = editor;
@@ -0,0 +1,8 @@
1
+ const editor = { "placeholder": "اكتب شيئا...", "fontColorDefault": "تقصير", "fontColorRed": "أحمر", "fontColorGreen": "أخضر", "fontColorBlue": "أزرق", "fontColorYellow": "أصفر", "fontColorOrange": "البرتقالي", "fontColorPurple": "أرجواني", "fontColorPink": "لون القرنفل", "fontColorBrown": "بني", "fontColorGray": "رمادي", "backgroundColorDefault": "تقصير", "backgroundColorRed": "أحمر" };
2
+ const arSA = {
3
+ editor
4
+ };
5
+ export {
6
+ arSA as default,
7
+ editor
8
+ };
@@ -0,0 +1,8 @@
1
+ const editor = { "placeholder": "Escriu alguna cosa...", "fontColorDefault": "Per defecte", "fontColorRed": "Vermell", "fontColorGreen": "Verd", "fontColorBlue": "Blau", "fontColorYellow": "groc", "fontColorOrange": "Taronja", "fontColorPurple": "Lila", "fontColorPink": "Rosa", "fontColorBrown": "marró", "fontColorGray": "Gris", "backgroundColorDefault": "Per defecte", "backgroundColorRed": "Vermell" };
2
+ const caES = {
3
+ editor
4
+ };
5
+ export {
6
+ caES as default,
7
+ editor
8
+ };
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const editor = { "placeholder": "Escriu alguna cosa...", "fontColorDefault": "Per defecte", "fontColorRed": "Vermell", "fontColorGreen": "Verd", "fontColorBlue": "Blau", "fontColorYellow": "groc", "fontColorOrange": "Taronja", "fontColorPurple": "Lila", "fontColorPink": "Rosa", "fontColorBrown": "marró", "fontColorGray": "Gris", "backgroundColorDefault": "Per defecte", "backgroundColorRed": "Vermell" };
4
+ const caES = {
5
+ editor
6
+ };
7
+ exports.default = caES;
8
+ exports.editor = editor;
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const editor = { "backgroundColorDefault": "\n" };
4
+ const ckbKU = {
5
+ editor
6
+ };
7
+ exports.default = ckbKU;
8
+ exports.editor = editor;
@@ -0,0 +1,8 @@
1
+ const editor = { "backgroundColorDefault": "\n" };
2
+ const ckbKU = {
3
+ editor
4
+ };
5
+ export {
6
+ ckbKU as default,
7
+ editor
8
+ };
@@ -0,0 +1,3 @@
1
+ import { RenderLeafProps } from 'slate-react';
2
+ declare function Leaf({ attributes, children, leaf }: RenderLeafProps): import("react/jsx-runtime").JSX.Element;
3
+ export default Leaf;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function BulletedList({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default BulletedList;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function Checkbox({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default Checkbox;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function Code({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default Code;
@@ -0,0 +1,3 @@
1
+ import { BaseRange, NodeEntry } from 'slate';
2
+ import { ReactEditor } from 'slate-react';
3
+ export declare function useDecorate(editor: ReactEditor): (entry: NodeEntry) => BaseRange[];
@@ -0,0 +1,2 @@
1
+ import { BaseRange, NodeEntry } from 'slate';
2
+ export declare const decorateCode: ([node, path]: NodeEntry, language: string) => BaseRange[];
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function Divider({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default Divider;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ export declare function Element({ element, attributes, children, }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default Element;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function Heading({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default Heading;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function Image({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default Image;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function LinkPreview({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default LinkPreview;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function NumberedList({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default NumberedList;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function Quote({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default Quote;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function Table({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default Table;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function TableCell({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default TableCell;
@@ -0,0 +1,3 @@
1
+ import { RenderElementProps } from 'slate-react';
2
+ declare function TableRow({ attributes, children, element }: RenderElementProps): import("react/jsx-runtime").JSX.Element;
3
+ export default TableRow;
@@ -0,0 +1 @@
1
+ export * from './Element';
@@ -0,0 +1,2 @@
1
+ declare function Aa(): import("react/jsx-runtime").JSX.Element;
2
+ export default Aa;
@@ -0,0 +1,4 @@
1
+ declare function BUIS({ onAfterChange, }: {
2
+ onAfterChange?: () => void;
3
+ }): import("react/jsx-runtime").JSX.Element;
4
+ export default BUIS;
@@ -0,0 +1,2 @@
1
+ declare function Color(): import("react/jsx-runtime").JSX.Element;
2
+ export default Color;
@@ -0,0 +1,2 @@
1
+ export declare function FixedToolbar(): import("react/jsx-runtime").JSX.Element;
2
+ export default FixedToolbar;
@@ -0,0 +1,2 @@
1
+ declare function List(): import("react/jsx-runtime").JSX.Element;
2
+ export default List;
@@ -0,0 +1 @@
1
+ export * from './FixedToolbar';
@@ -0,0 +1,8 @@
1
+ import { VariantProps } from 'class-variance-authority';
2
+ import * as React from "react";
3
+ declare const Alert: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & VariantProps<(props?: ({
4
+ variant?: "default" | "destructive" | null | undefined;
5
+ } & import('class-variance-authority/dist/types').ClassProp) | undefined) => string> & React.RefAttributes<HTMLDivElement>>;
6
+ declare const AlertTitle: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLHeadingElement> & React.RefAttributes<HTMLParagraphElement>>;
7
+ declare const AlertDescription: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLParagraphElement> & React.RefAttributes<HTMLParagraphElement>>;
8
+ export { Alert, AlertTitle, AlertDescription };
@@ -0,0 +1,15 @@
1
+ import { VariantProps } from 'class-variance-authority';
2
+ import * as React from 'react';
3
+ declare const buttonVariants: (props?: ({
4
+ variant?: "link" | "default" | "destructive" | "outline" | "secondary" | "ghost" | null | undefined;
5
+ color?: "default" | "secondary" | "primary" | null | undefined;
6
+ size?: "default" | "sm" | "lg" | "icon" | null | undefined;
7
+ } & import('class-variance-authority/dist/types').ClassProp) | undefined) => string;
8
+ export interface ButtonProps extends React.ButtonHTMLAttributes<HTMLButtonElement>, VariantProps<typeof buttonVariants> {
9
+ asChild?: boolean;
10
+ color?: 'default' | 'primary' | 'secondary';
11
+ startIcon?: React.ReactNode;
12
+ endIcon?: React.ReactNode;
13
+ }
14
+ declare const Button: React.ForwardRefExoticComponent<ButtonProps & React.RefAttributes<HTMLButtonElement>>;
15
+ export { Button, buttonVariants };
@@ -0,0 +1,3 @@
1
+ import * as React from "react";
2
+ declare const Input: React.ForwardRefExoticComponent<Omit<React.DetailedHTMLProps<React.InputHTMLAttributes<HTMLInputElement>, HTMLInputElement>, "ref"> & React.RefAttributes<HTMLInputElement>>;
3
+ export { Input };
@@ -0,0 +1,5 @@
1
+ import { VariantProps } from 'class-variance-authority';
2
+ import * as React from "react";
3
+ import * as LabelPrimitive from "@radix-ui/react-label";
4
+ declare const Label: React.ForwardRefExoticComponent<Omit<LabelPrimitive.LabelProps & React.RefAttributes<HTMLLabelElement>, "ref"> & VariantProps<(props?: import('class-variance-authority/dist/types').ClassProp | undefined) => string> & React.RefAttributes<HTMLLabelElement>>;
5
+ export { Label };
@@ -0,0 +1,4 @@
1
+ export default function LoadingDots({ className, colors, }: {
2
+ className?: string;
3
+ colors?: [string, string, string];
4
+ }): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,12 @@
1
+ import * as React from 'react';
2
+ import * as PopoverPrimitive from '@radix-ui/react-popover';
3
+ declare const Popover: React.FC<PopoverPrimitive.PopoverProps>;
4
+ declare const PopoverTrigger: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverTriggerProps & React.RefAttributes<HTMLButtonElement>>;
5
+ declare const PopoverAnchor: React.ForwardRefExoticComponent<PopoverPrimitive.PopoverAnchorProps & React.RefAttributes<HTMLDivElement>>;
6
+ export interface PopoverContentProps extends React.ComponentPropsWithoutRef<typeof PopoverPrimitive.Content> {
7
+ container?: HTMLElement | null;
8
+ forceMount?: true;
9
+ disableOutsidePointerEvents?: boolean;
10
+ }
11
+ declare const PopoverContent: React.ForwardRefExoticComponent<PopoverContentProps & React.RefAttributes<HTMLDivElement>>;
12
+ export { Popover, PopoverTrigger, PopoverContent, PopoverAnchor };
@@ -0,0 +1,13 @@
1
+ import * as React from 'react';
2
+ import * as SelectPrimitive from '@radix-ui/react-select';
3
+ declare const Select: React.FC<SelectPrimitive.SelectProps>;
4
+ declare const SelectGroup: React.ForwardRefExoticComponent<SelectPrimitive.SelectGroupProps & React.RefAttributes<HTMLDivElement>>;
5
+ declare const SelectValue: React.ForwardRefExoticComponent<SelectPrimitive.SelectValueProps & React.RefAttributes<HTMLSpanElement>>;
6
+ declare const SelectTrigger: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectTriggerProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
7
+ declare const SelectScrollUpButton: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollUpButtonProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
8
+ declare const SelectScrollDownButton: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectScrollDownButtonProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
9
+ declare const SelectContent: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
10
+ declare const SelectLabel: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectLabelProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
11
+ declare const SelectItem: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectItemProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
12
+ declare const SelectSeparator: React.ForwardRefExoticComponent<Omit<SelectPrimitive.SelectSeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
13
+ export { Select, SelectGroup, SelectValue, SelectTrigger, SelectContent, SelectLabel, SelectItem, SelectSeparator, SelectScrollUpButton, SelectScrollDownButton, };
@@ -0,0 +1,4 @@
1
+ import * as React from "react";
2
+ import * as SeparatorPrimitive from "@radix-ui/react-separator";
3
+ declare const Separator: React.ForwardRefExoticComponent<Omit<SeparatorPrimitive.SeparatorProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
4
+ export { Separator };
@@ -0,0 +1,4 @@
1
+ import * as React from "react";
2
+ import * as SwitchPrimitives from "@radix-ui/react-switch";
3
+ declare const Switch: React.ForwardRefExoticComponent<Omit<SwitchPrimitives.SwitchProps & React.RefAttributes<HTMLButtonElement>, "ref"> & React.RefAttributes<HTMLButtonElement>>;
4
+ export { Switch };
@@ -0,0 +1,7 @@
1
+ import * as React from 'react';
2
+ import * as TooltipPrimitive from '@radix-ui/react-tooltip';
3
+ declare const TooltipProvider: React.FC<TooltipPrimitive.TooltipProviderProps>;
4
+ declare const Tooltip: React.FC<TooltipPrimitive.TooltipProps>;
5
+ declare const TooltipTrigger: React.ForwardRefExoticComponent<TooltipPrimitive.TooltipTriggerProps & React.RefAttributes<HTMLButtonElement>>;
6
+ declare const TooltipContent: React.ForwardRefExoticComponent<Omit<TooltipPrimitive.TooltipContentProps & React.RefAttributes<HTMLDivElement>, "ref"> & React.RefAttributes<HTMLDivElement>>;
7
+ export { Tooltip, TooltipTrigger, TooltipContent, TooltipProvider };
@@ -0,0 +1,8 @@
1
+ const editor = { "placeholder": "Napiš něco...", "fontColorDefault": "Výchozí", "fontColorRed": "Červený", "fontColorGreen": "Zelený", "fontColorBlue": "Modrý", "fontColorYellow": "Žluť", "fontColorOrange": "Pomerančový", "fontColorPurple": "Fialová", "fontColorPink": "Růžový", "fontColorBrown": "Hnědý", "fontColorGray": "Šedá", "backgroundColorDefault": "Výchozí", "backgroundColorRed": "Červený" };
2
+ const csCZ = {
3
+ editor
4
+ };
5
+ export {
6
+ csCZ as default,
7
+ editor
8
+ };
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const editor = { "placeholder": "Napiš něco...", "fontColorDefault": "Výchozí", "fontColorRed": "Červený", "fontColorGreen": "Zelený", "fontColorBlue": "Modrý", "fontColorYellow": "Žluť", "fontColorOrange": "Pomerančový", "fontColorPurple": "Fialová", "fontColorPink": "Růžový", "fontColorBrown": "Hnědý", "fontColorGray": "Šedá", "backgroundColorDefault": "Výchozí", "backgroundColorRed": "Červený" };
4
+ const csCZ = {
5
+ editor
6
+ };
7
+ exports.default = csCZ;
8
+ exports.editor = editor;
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
3
+ const editor = { "placeholder": "Schreib etwas...", "fontColorDefault": "Standard", "fontColorRed": "Rot", "fontColorGreen": "Grün", "fontColorBlue": "Blau", "fontColorYellow": "Gelb", "fontColorOrange": "Orange", "fontColorPurple": "Lila", "fontColorPink": "Rosa", "fontColorBrown": "Braun", "fontColorGray": "Grau", "backgroundColorDefault": "Standard", "backgroundColorRed": "Rot" };
4
+ const deDE = {
5
+ editor
6
+ };
7
+ exports.default = deDE;
8
+ exports.editor = editor;
@@ -0,0 +1,8 @@
1
+ const editor = { "placeholder": "Schreib etwas...", "fontColorDefault": "Standard", "fontColorRed": "Rot", "fontColorGreen": "Grün", "fontColorBlue": "Blau", "fontColorYellow": "Gelb", "fontColorOrange": "Orange", "fontColorPurple": "Lila", "fontColorPink": "Rosa", "fontColorBrown": "Braun", "fontColorGray": "Grau", "backgroundColorDefault": "Standard", "backgroundColorRed": "Rot" };
2
+ const deDE = {
3
+ editor
4
+ };
5
+ export {
6
+ deDE as default,
7
+ editor
8
+ };
@@ -0,0 +1 @@
1
+ export default function App(): import("react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ import { default as React } from 'react';
2
+ export declare const MarkdownDemo: React.FC;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,3 @@
1
+ import { EditorProps } from '../types';
2
+ export declare function Editor({ locale, theme, readOnly, onChange, initialValue: initialValueProp, modalZIndex, ToolbarComponent, }: EditorProps): import("react/jsx-runtime").JSX.Element;
3
+ export default Editor;
@@ -0,0 +1,12 @@
1
+ import { FC } from 'react';
2
+ import { ReactEditor } from 'slate-react';
3
+ import { Descendant, Operation } from 'slate';
4
+ export interface RichTextProps {
5
+ readOnly?: boolean;
6
+ onChange?: (ops: Operation[], value: Descendant[]) => void;
7
+ initialValue?: Descendant[];
8
+ editor: ReactEditor;
9
+ ToolbarComponent?: FC;
10
+ }
11
+ declare const RichText: ({ editor, readOnly, onChange, ToolbarComponent, initialValue, }: RichTextProps) => import("react/jsx-runtime").JSX.Element;
12
+ export default RichText;