@crystallize/design-system 1.21.0 → 1.21.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@crystallize/design-system",
3
- "version": "1.21.0",
3
+ "version": "1.21.1",
4
4
  "types": "./dist/index.d.ts",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",
@@ -0,0 +1,15 @@
1
+ import { lazy, Suspense } from 'react';
2
+
3
+ const LazyRichTextEditor = lazy(() => import('./rich-text-editor'));
4
+
5
+ // Export types
6
+ export type { CrystallizeRichText } from './types/crystallize-rich-text-types';
7
+ export * from './types/types';
8
+
9
+ export const RichTextEditor = (props: any) => {
10
+ return (
11
+ <Suspense fallback={null}>
12
+ <LazyRichTextEditor {...props} />
13
+ </Suspense>
14
+ );
15
+ };
@@ -45,10 +45,6 @@ import type { CrystallizeRichTextActionMenuItem } from './types/types';
45
45
  */
46
46
  // import DraggableBlockPlugin from './plugins/DraggableBlockPlugin';
47
47
 
48
- // Export types
49
- export type { CrystallizeRichText } from './types/crystallize-rich-text-types';
50
- export * from './types/types';
51
-
52
48
  type TRichTextBase = {
53
49
  placeholder?: string;
54
50
  onChange?: (data: CrystallizeRichText) => void;
@@ -186,3 +182,5 @@ function RichTextEditorWithoutContext({
186
182
  </>
187
183
  );
188
184
  }
185
+
186
+ export default RichTextEditor;
@@ -1 +0,0 @@
1
- export * from './rich-text-editor';