@majoo-ui/react 1.51.0 → 1.52.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/components/contentEditor/ContentEditor.d.ts +36 -0
- package/components/contentEditor/index.d.ts +1 -0
- package/components/index.d.ts +1 -0
- package/index.esm.css +1065 -0
- package/index.esm.js +713 -354
- package/index.umd.css +1065 -0
- package/index.umd.js +720 -357
- package/package.json +7 -3
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { EditorState } from 'draft-js';
|
|
3
|
+
import { CSS } from '../../config/stitches.config';
|
|
4
|
+
import './styles.css';
|
|
5
|
+
interface ContentEditorProps {
|
|
6
|
+
/**
|
|
7
|
+
* Additional css styles.
|
|
8
|
+
*/
|
|
9
|
+
css?: CSS;
|
|
10
|
+
/**
|
|
11
|
+
* Adjust editor height.
|
|
12
|
+
*/
|
|
13
|
+
editorHeight?: number;
|
|
14
|
+
/**
|
|
15
|
+
* Customize pre-built option in the toolbar.
|
|
16
|
+
*/
|
|
17
|
+
toolbar?: (defaultToolbar: object) => void;
|
|
18
|
+
/**
|
|
19
|
+
* State of the editor content.
|
|
20
|
+
*/
|
|
21
|
+
editorState?: string;
|
|
22
|
+
/**
|
|
23
|
+
* Change event handler.
|
|
24
|
+
*/
|
|
25
|
+
onChange?: (e: EditorState) => void;
|
|
26
|
+
/**
|
|
27
|
+
* Callback function to add image upload option.
|
|
28
|
+
*/
|
|
29
|
+
uploadCallback?: () => void;
|
|
30
|
+
/**
|
|
31
|
+
* Set max length of the content.
|
|
32
|
+
*/
|
|
33
|
+
maxLength?: number;
|
|
34
|
+
}
|
|
35
|
+
export default function ContentEditor(props: ContentEditorProps): JSX.Element;
|
|
36
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { default as ContentEditor } from './ContentEditor';
|
package/components/index.d.ts
CHANGED