md-editor-v3 1.9.1 → 1.10.2
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/README.md +37 -29
- package/lib/MdEditor/DropdownToolbar.d.ts +42 -0
- package/lib/MdEditor/Editor.d.ts +197 -214
- package/lib/MdEditor/NormalToolbar.d.ts +30 -0
- package/lib/MdEditor/index.d.ts +920 -0
- package/lib/MdEditor/type.d.ts +113 -0
- package/lib/md-editor-v3.es.js +811 -646
- package/lib/md-editor-v3.umd.js +44 -42
- package/lib/style.css +1 -1
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -6,7 +6,7 @@ English \| [中文](https://github.com/imzbf/md-editor-v3/blob/dev/README-CN.md)
|
|
|
6
6
|
|
|
7
7
|
Markdown editor for vue3, developed in `jsx` and `typescript`.
|
|
8
8
|
|
|
9
|
-
- Documentation and
|
|
9
|
+
- Documentation and example:[Go](https://imzbf.github.io/md-editor-v3)
|
|
10
10
|
|
|
11
11
|
- Use it online:[Go](https://codesandbox.io/s/epic-bird-2znqo)
|
|
12
12
|
|
|
@@ -49,33 +49,39 @@ Markdown editor for vue3, developed in `jsx` and `typescript`.
|
|
|
49
49
|
| pageFullScreen | Boolean | false | Screenfull in web page |
|
|
50
50
|
| preview | Boolean | true | Preview content in editor |
|
|
51
51
|
| htmlPreview | Boolean | false | Preview html in editor |
|
|
52
|
-
| previewOnly
|
|
52
|
+
| previewOnly | Boolean | false | Only render article content, no toolbar, no edit area |
|
|
53
53
|
| language | String | 'zh-CN' | Build-in language('zh-CN','en-US') |
|
|
54
|
-
| languageUserDefined
|
|
55
|
-
| toolbars | Array | [toolbars] | Show some item of toolbars,all keys<sup>see `toolbars` below
|
|
56
|
-
| toolbarsExclude
|
|
54
|
+
| languageUserDefined | Object | {key: StaticTextDefaultValue} | Expand language,update `language` api to your key |
|
|
55
|
+
| toolbars | Array | [toolbars] | Show some item of toolbars,all keys<sup>see `toolbars` below</sup> |
|
|
56
|
+
| toolbarsExclude | Array | [] | Don't show some item of toolbars,all keys`toolbars` |
|
|
57
57
|
| prettier | Boolean | true | Use prettier to beautify content or not |
|
|
58
58
|
| prettierCDN | String | [standalone@2.4.0](https://cdn.jsdelivr.net/npm/prettier@2.4.0/standalone.js) | |
|
|
59
59
|
| prettierMDCDN | String | [parser-markdown@2.4.0](https://cdn.jsdelivr.net/npm/prettier@2.4.0/parser-markdown.js) | |
|
|
60
|
-
| cropperCss
|
|
61
|
-
| cropperJs
|
|
62
|
-
| iconfontJs
|
|
63
|
-
| editorId
|
|
64
|
-
| tabWidth
|
|
65
|
-
| showCodeRowNumber
|
|
66
|
-
| screenfull
|
|
67
|
-
| screenfullJs
|
|
68
|
-
| previewTheme
|
|
69
|
-
| style
|
|
70
|
-
| tableShape
|
|
71
|
-
| mermaid
|
|
72
|
-
| mermaidJs
|
|
73
|
-
| noMermaid
|
|
74
|
-
| placeholder
|
|
75
|
-
| katex
|
|
76
|
-
| katexJs
|
|
77
|
-
| katexCss
|
|
78
|
-
| noKatex
|
|
60
|
+
| cropperCss | String | [cropper.min.css@1.5.12](https://cdn.jsdelivr.net/npm/cropperjs@1.5.12/dist/cropper.min.css) | Cropper css url |
|
|
61
|
+
| cropperJs | String | [cropper.min.js@1.5.12](https://cdn.jsdelivr.net/npm/cropperjs@1.5.12/dist/cropper.min.js) | Cropper js url |
|
|
62
|
+
| iconfontJs | String | [iconfont](https://at.alicdn.com/t/font_2605852_khjf435c7th.js) | Icon url |
|
|
63
|
+
| editorId | String | md-editor-v3 | Editor id, also the html id, it is used when there are more than two editors |
|
|
64
|
+
| tabWidth | Number | 2 | One tab eq some space |
|
|
65
|
+
| showCodeRowNumber | Boolean | false | Show row number for code block or not |
|
|
66
|
+
| screenfull | Object | null | Screenfull instance, editor will not insert script of it |
|
|
67
|
+
| screenfullJs | String | [screenfull@5.1.0](https://cdn.jsdelivr.net/npm/screenfull@5.1.0/dist/screenfull.js) | Screenfull js url |
|
|
68
|
+
| previewTheme | 'default' \| 'github' \| 'vuepress' | 'default' | Preview themes |
|
|
69
|
+
| style | CSSProperties | {} | Editor's inline style |
|
|
70
|
+
| tableShape | [Number, Number] | [6, 4] | Preset the size of the table, [columns, rows]. |
|
|
71
|
+
| mermaid | Object | undefined | `mermaid` instance |
|
|
72
|
+
| mermaidJs | String | [mermaid@8.13.5](https://cdn.jsdelivr.net/npm/mermaid@8.13.5/dist/mermaid.min.js) | MermaidJs url |
|
|
73
|
+
| noMermaid | Boolean | false | Do not use mermaid |
|
|
74
|
+
| placeholder | String | '' | |
|
|
75
|
+
| katex | Object | undefined | `katex` instance(you need import css by yourself.) |
|
|
76
|
+
| katexJs | String | [katex.min.js@0.15.1](https://cdn.jsdelivr.net/npm/katex@0.15.1/dist/katex.min.js) | KatexJs url |
|
|
77
|
+
| katexCss | String | [katex.min.css@0.15.1](https://cdn.jsdelivr.net/npm/katex@0.15.1/dist/katex.min.css) | KatexCss url |
|
|
78
|
+
| noKatex | Boolean | false | Do not use katex |
|
|
79
|
+
| defToolbars | Array<DropdownToolbar \| NormalToolbar> | null | Customize Toolbar, for more usage, please refer to [docs](https://imzbf.github.io/md-editor-v3/docs/index#%F0%9F%92%AA%20defToolbars) and [emoji](https://imzbf.github.io/md-editor-v3/demo/index#💪%20Customize%20Toolbar) |
|
|
80
|
+
| extensions | Array | [] | [marked](https://marked.js.org/using_pro#extensions) extensions |
|
|
81
|
+
|
|
82
|
+
mark and emoji extensions
|
|
83
|
+
|
|
84
|
+

|
|
79
85
|
|
|
80
86
|
[toolbars]
|
|
81
87
|
|
|
@@ -114,7 +120,9 @@ Markdown editor for vue3, developed in `jsx` and `typescript`.
|
|
|
114
120
|
];
|
|
115
121
|
```
|
|
116
122
|
|
|
117
|
-
>
|
|
123
|
+
> After v1.6.0, You can sort the toolbar as you like, split tools by `'-'`, the left and right toolbars are divided by `'='`!
|
|
124
|
+
|
|
125
|
+
> After v1.10.0, you can customize the toolbar. To display them, put index of `defToolbars` into `toolbars`(this is not standard), for more usage, please refer to[docs]().
|
|
118
126
|
|
|
119
127
|
Expand language,you need to replace all the content here:
|
|
120
128
|
|
|
@@ -219,9 +227,9 @@ export interface StaticTextDefaultValue {
|
|
|
219
227
|
| onSave | v:String | Save Content event,`ctrl+s`and click button will trigger |
|
|
220
228
|
| onUploadImg | files:FileList, callback:Function | Upload picture event,when picture is uploading the modal will not close,please provide right urls to the callback function |
|
|
221
229
|
| onHtmlChanged | h:String | Compile markdown successful event,you can use it to get the html code |
|
|
222
|
-
| onGetCatalog
|
|
223
|
-
| markedHeading
|
|
224
|
-
| markedHeadingId
|
|
230
|
+
| onGetCatalog | list: HeadList[] | Get catalogue of article |
|
|
231
|
+
| markedHeading | text: string,level: 1-6,raw: string, slugger: Slugger | `marked` head renderer methods |
|
|
232
|
+
| markedHeadingId | (text: string, level: number) => string | title `ID` generator |
|
|
225
233
|
| sanitize | (html: string) => string | Sanitize the html, prevent XSS. |
|
|
226
234
|
|
|
227
235
|
> If `markedHeading` is overridden, be sure to tell the editor the algorithm for generating the title ID by `marketheadingid`.
|
|
@@ -255,7 +263,7 @@ export interface StaticTextDefaultValue {
|
|
|
255
263
|
| CTRL + ALT + C | code row | | v1.0.0 |
|
|
256
264
|
| CTRL + SHIFT + ALT + T | table | `\|table\|` | v1.4.0 |
|
|
257
265
|
|
|
258
|
-
## Simple
|
|
266
|
+
## Simple example
|
|
259
267
|
|
|
260
268
|
### Jsx module
|
|
261
269
|
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { PropType } from 'vue';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
title: {
|
|
4
|
+
type: PropType<string>;
|
|
5
|
+
default: string;
|
|
6
|
+
};
|
|
7
|
+
visible: {
|
|
8
|
+
type: PropType<boolean>;
|
|
9
|
+
};
|
|
10
|
+
trigger: {
|
|
11
|
+
type: PropType<string | JSX.Element>;
|
|
12
|
+
};
|
|
13
|
+
onChange: {
|
|
14
|
+
type: PropType<(visible: boolean) => void>;
|
|
15
|
+
default: () => () => void;
|
|
16
|
+
};
|
|
17
|
+
overlay: {
|
|
18
|
+
type: PropType<string | JSX.Element>;
|
|
19
|
+
};
|
|
20
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
21
|
+
title: {
|
|
22
|
+
type: PropType<string>;
|
|
23
|
+
default: string;
|
|
24
|
+
};
|
|
25
|
+
visible: {
|
|
26
|
+
type: PropType<boolean>;
|
|
27
|
+
};
|
|
28
|
+
trigger: {
|
|
29
|
+
type: PropType<string | JSX.Element>;
|
|
30
|
+
};
|
|
31
|
+
onChange: {
|
|
32
|
+
type: PropType<(visible: boolean) => void>;
|
|
33
|
+
default: () => () => void;
|
|
34
|
+
};
|
|
35
|
+
overlay: {
|
|
36
|
+
type: PropType<string | JSX.Element>;
|
|
37
|
+
};
|
|
38
|
+
}>>, {
|
|
39
|
+
title: string;
|
|
40
|
+
onChange: (visible: boolean) => void;
|
|
41
|
+
}>;
|
|
42
|
+
export default _default;
|
package/lib/MdEditor/Editor.d.ts
CHANGED
|
@@ -1,118 +1,6 @@
|
|
|
1
1
|
import { PropType, CSSProperties } from 'vue';
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
hljs: any;
|
|
5
|
-
prettier: any;
|
|
6
|
-
prettierPlugins: any;
|
|
7
|
-
Cropper: any;
|
|
8
|
-
screenfull: any;
|
|
9
|
-
mermaid: any;
|
|
10
|
-
}
|
|
11
|
-
}
|
|
12
|
-
export interface ToolbarTips {
|
|
13
|
-
bold?: string;
|
|
14
|
-
underline?: string;
|
|
15
|
-
italic?: string;
|
|
16
|
-
strikeThrough?: string;
|
|
17
|
-
title?: string;
|
|
18
|
-
sub?: string;
|
|
19
|
-
sup?: string;
|
|
20
|
-
quote?: string;
|
|
21
|
-
unorderedList?: string;
|
|
22
|
-
orderedList?: string;
|
|
23
|
-
codeRow?: string;
|
|
24
|
-
code?: string;
|
|
25
|
-
link?: string;
|
|
26
|
-
image?: string;
|
|
27
|
-
table?: string;
|
|
28
|
-
mermaid?: string;
|
|
29
|
-
katex?: string;
|
|
30
|
-
revoke?: string;
|
|
31
|
-
next?: string;
|
|
32
|
-
save?: string;
|
|
33
|
-
prettier?: string;
|
|
34
|
-
pageFullscreen?: string;
|
|
35
|
-
fullscreen?: string;
|
|
36
|
-
preview?: string;
|
|
37
|
-
htmlPreview?: string;
|
|
38
|
-
catalog?: string;
|
|
39
|
-
github?: string;
|
|
40
|
-
'-'?: string;
|
|
41
|
-
'='?: string;
|
|
42
|
-
}
|
|
43
|
-
export interface StaticTextDefaultValue {
|
|
44
|
-
toolbarTips?: ToolbarTips;
|
|
45
|
-
titleItem?: {
|
|
46
|
-
h1?: string;
|
|
47
|
-
h2?: string;
|
|
48
|
-
h3?: string;
|
|
49
|
-
h4?: string;
|
|
50
|
-
h5?: string;
|
|
51
|
-
h6?: string;
|
|
52
|
-
};
|
|
53
|
-
imgTitleItem?: {
|
|
54
|
-
link: string;
|
|
55
|
-
upload: string;
|
|
56
|
-
clip2upload: string;
|
|
57
|
-
};
|
|
58
|
-
linkModalTips?: {
|
|
59
|
-
title?: string;
|
|
60
|
-
descLable?: string;
|
|
61
|
-
descLablePlaceHolder?: string;
|
|
62
|
-
urlLable?: string;
|
|
63
|
-
UrlLablePlaceHolder?: string;
|
|
64
|
-
buttonOK?: string;
|
|
65
|
-
};
|
|
66
|
-
clipModalTips?: {
|
|
67
|
-
title?: string;
|
|
68
|
-
buttonUpload?: string;
|
|
69
|
-
};
|
|
70
|
-
copyCode?: {
|
|
71
|
-
text?: string;
|
|
72
|
-
tips?: string;
|
|
73
|
-
};
|
|
74
|
-
mermaid?: {
|
|
75
|
-
flow?: string;
|
|
76
|
-
sequence?: string;
|
|
77
|
-
gantt?: string;
|
|
78
|
-
class?: string;
|
|
79
|
-
state?: string;
|
|
80
|
-
pie?: string;
|
|
81
|
-
relationship?: string;
|
|
82
|
-
journey?: string;
|
|
83
|
-
};
|
|
84
|
-
katex?: {
|
|
85
|
-
inline: string;
|
|
86
|
-
block: string;
|
|
87
|
-
};
|
|
88
|
-
}
|
|
89
|
-
export interface StaticTextDefault {
|
|
90
|
-
'zh-CN': StaticTextDefaultValue;
|
|
91
|
-
'en-US': StaticTextDefaultValue;
|
|
92
|
-
}
|
|
93
|
-
export declare type StaticTextDefaultKey = keyof StaticTextDefault;
|
|
94
|
-
export declare type ToolbarNames = keyof ToolbarTips;
|
|
95
|
-
export interface SettingType {
|
|
96
|
-
pageFullScreen: boolean;
|
|
97
|
-
fullscreen: boolean;
|
|
98
|
-
preview: boolean;
|
|
99
|
-
htmlPreview: boolean;
|
|
100
|
-
}
|
|
101
|
-
export declare const prefix = "md";
|
|
102
|
-
export interface HeadList {
|
|
103
|
-
text: string;
|
|
104
|
-
level: 1 | 2 | 3 | 4 | 5 | 6;
|
|
105
|
-
}
|
|
106
|
-
export declare type PreviewThemes = 'default' | 'github' | 'vuepress';
|
|
107
|
-
export declare type MarkedHeading = (text: string, level: 1 | 2 | 3 | 4 | 5 | 6, raw: string, slugger: {
|
|
108
|
-
seen: {
|
|
109
|
-
[slugValue: string]: number;
|
|
110
|
-
};
|
|
111
|
-
slug(value: string, options?: {
|
|
112
|
-
dryrun: boolean;
|
|
113
|
-
}): string;
|
|
114
|
-
}) => string;
|
|
115
|
-
export declare type MarkedHeadingId = (text: string, level: number) => string;
|
|
2
|
+
import { StaticTextDefaultValue, ToolbarNames, HeadList, PreviewThemes, MarkedHeading, MarkedHeadingId } from './type';
|
|
3
|
+
export declare const markedHeadingId: MarkedHeadingId;
|
|
116
4
|
declare const _default: import("vue").DefineComponent<{
|
|
117
5
|
modelValue: {
|
|
118
6
|
type: PropType<string>;
|
|
@@ -178,11 +66,11 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
178
66
|
default: () => {};
|
|
179
67
|
};
|
|
180
68
|
toolbars: {
|
|
181
|
-
type: PropType<
|
|
69
|
+
type: PropType<ToolbarNames[]>;
|
|
182
70
|
default: string[];
|
|
183
71
|
};
|
|
184
72
|
toolbarsExclude: {
|
|
185
|
-
type: PropType<
|
|
73
|
+
type: PropType<ToolbarNames[]>;
|
|
186
74
|
default: never[];
|
|
187
75
|
};
|
|
188
76
|
prettier: {
|
|
@@ -293,104 +181,199 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
293
181
|
type: PropType<boolean>;
|
|
294
182
|
default: boolean;
|
|
295
183
|
};
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
}
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
highlightCss: string;
|
|
361
|
-
pageFullScreen: boolean;
|
|
362
|
-
language: string;
|
|
184
|
+
defToolbars: {
|
|
185
|
+
type: PropType<string | JSX.Element>;
|
|
186
|
+
};
|
|
187
|
+
extensions: {
|
|
188
|
+
type: PropType<any[]>;
|
|
189
|
+
};
|
|
190
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
191
|
+
modelValue: {
|
|
192
|
+
type: PropType<string>;
|
|
193
|
+
default: string;
|
|
194
|
+
};
|
|
195
|
+
theme: {
|
|
196
|
+
type: PropType<"dark" | "light">;
|
|
197
|
+
default: string;
|
|
198
|
+
};
|
|
199
|
+
editorClass: {
|
|
200
|
+
type: StringConstructor;
|
|
201
|
+
default: string;
|
|
202
|
+
};
|
|
203
|
+
hljs: {
|
|
204
|
+
type: ObjectConstructor;
|
|
205
|
+
default: null;
|
|
206
|
+
};
|
|
207
|
+
highlightJs: {
|
|
208
|
+
type: PropType<string>;
|
|
209
|
+
default: string;
|
|
210
|
+
};
|
|
211
|
+
highlightCss: {
|
|
212
|
+
type: PropType<string>;
|
|
213
|
+
default: string;
|
|
214
|
+
};
|
|
215
|
+
historyLength: {
|
|
216
|
+
type: PropType<number>;
|
|
217
|
+
default: number;
|
|
218
|
+
};
|
|
219
|
+
onChange: {
|
|
220
|
+
type: PropType<(v: string) => void>;
|
|
221
|
+
};
|
|
222
|
+
onSave: {
|
|
223
|
+
type: PropType<(v: string) => void>;
|
|
224
|
+
};
|
|
225
|
+
onUploadImg: {
|
|
226
|
+
type: PropType<(files: FileList, callBack: (urls: string[]) => void) => void>;
|
|
227
|
+
};
|
|
228
|
+
pageFullScreen: {
|
|
229
|
+
type: PropType<boolean>;
|
|
230
|
+
default: boolean;
|
|
231
|
+
};
|
|
232
|
+
preview: {
|
|
233
|
+
type: PropType<boolean>;
|
|
234
|
+
default: boolean;
|
|
235
|
+
};
|
|
236
|
+
htmlPreview: {
|
|
237
|
+
type: PropType<boolean>;
|
|
238
|
+
default: boolean;
|
|
239
|
+
};
|
|
240
|
+
previewOnly: {
|
|
241
|
+
type: PropType<boolean>;
|
|
242
|
+
default: boolean;
|
|
243
|
+
};
|
|
244
|
+
language: {
|
|
245
|
+
type: PropType<string>;
|
|
246
|
+
default: string;
|
|
247
|
+
};
|
|
363
248
|
languageUserDefined: {
|
|
364
|
-
|
|
249
|
+
type: PropType<{
|
|
250
|
+
[key: string]: StaticTextDefaultValue;
|
|
251
|
+
}>;
|
|
252
|
+
default: () => {};
|
|
365
253
|
};
|
|
366
|
-
toolbars:
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
}
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
254
|
+
toolbars: {
|
|
255
|
+
type: PropType<ToolbarNames[]>;
|
|
256
|
+
default: string[];
|
|
257
|
+
};
|
|
258
|
+
toolbarsExclude: {
|
|
259
|
+
type: PropType<ToolbarNames[]>;
|
|
260
|
+
default: never[];
|
|
261
|
+
};
|
|
262
|
+
prettier: {
|
|
263
|
+
type: PropType<boolean>;
|
|
264
|
+
default: boolean;
|
|
265
|
+
};
|
|
266
|
+
prettierCDN: {
|
|
267
|
+
type: PropType<string>;
|
|
268
|
+
default: string;
|
|
269
|
+
};
|
|
270
|
+
prettierMDCDN: {
|
|
271
|
+
type: PropType<string>;
|
|
272
|
+
default: string;
|
|
273
|
+
};
|
|
274
|
+
onHtmlChanged: {
|
|
275
|
+
type: PropType<(h: string) => void>;
|
|
276
|
+
};
|
|
277
|
+
Cropper: {
|
|
278
|
+
type: FunctionConstructor;
|
|
279
|
+
default: null;
|
|
280
|
+
};
|
|
281
|
+
cropperCss: {
|
|
282
|
+
type: PropType<string>;
|
|
283
|
+
default: string;
|
|
284
|
+
};
|
|
285
|
+
cropperJs: {
|
|
286
|
+
type: PropType<string>;
|
|
287
|
+
default: string;
|
|
288
|
+
};
|
|
289
|
+
iconfontJs: {
|
|
290
|
+
type: PropType<string>;
|
|
291
|
+
default: string;
|
|
292
|
+
};
|
|
293
|
+
onGetCatalog: {
|
|
294
|
+
type: PropType<(list: HeadList[]) => void>;
|
|
295
|
+
};
|
|
296
|
+
editorId: {
|
|
297
|
+
type: PropType<string>;
|
|
298
|
+
default: string;
|
|
299
|
+
};
|
|
300
|
+
tabWidth: {
|
|
301
|
+
type: PropType<number>;
|
|
302
|
+
default: number;
|
|
303
|
+
};
|
|
304
|
+
showCodeRowNumber: {
|
|
305
|
+
type: PropType<boolean>;
|
|
306
|
+
default: boolean;
|
|
307
|
+
};
|
|
308
|
+
screenfull: {
|
|
309
|
+
type: ObjectConstructor;
|
|
310
|
+
default: null;
|
|
311
|
+
};
|
|
312
|
+
screenfullJs: {
|
|
313
|
+
type: PropType<string>;
|
|
314
|
+
default: string;
|
|
315
|
+
};
|
|
316
|
+
previewTheme: {
|
|
317
|
+
type: PropType<PreviewThemes>;
|
|
318
|
+
default: string;
|
|
319
|
+
};
|
|
320
|
+
markedHeading: {
|
|
321
|
+
type: PropType<MarkedHeading>;
|
|
322
|
+
default: (text: string, level: number, raw: string) => string;
|
|
323
|
+
};
|
|
324
|
+
style: {
|
|
325
|
+
type: PropType<string | CSSProperties>;
|
|
326
|
+
default: () => {};
|
|
327
|
+
};
|
|
328
|
+
markedHeadingId: {
|
|
329
|
+
type: PropType<MarkedHeadingId>;
|
|
330
|
+
default: MarkedHeadingId;
|
|
331
|
+
};
|
|
332
|
+
tableShape: {
|
|
333
|
+
type: PropType<number[]>;
|
|
334
|
+
default: () => number[];
|
|
335
|
+
};
|
|
336
|
+
mermaid: {
|
|
337
|
+
type: ObjectConstructor;
|
|
338
|
+
};
|
|
339
|
+
mermaidJs: {
|
|
340
|
+
type: PropType<string>;
|
|
341
|
+
default: string;
|
|
342
|
+
};
|
|
343
|
+
noMermaid: {
|
|
344
|
+
type: PropType<boolean>;
|
|
345
|
+
default: boolean;
|
|
346
|
+
};
|
|
347
|
+
sanitize: {
|
|
348
|
+
type: PropType<(html: string) => string>;
|
|
349
|
+
default: (html: string) => string;
|
|
350
|
+
};
|
|
351
|
+
placeholder: {
|
|
352
|
+
type: PropType<string>;
|
|
353
|
+
default: string;
|
|
354
|
+
};
|
|
355
|
+
katex: {
|
|
356
|
+
type: ObjectConstructor;
|
|
357
|
+
};
|
|
358
|
+
katexJs: {
|
|
359
|
+
type: PropType<string>;
|
|
360
|
+
default: string;
|
|
361
|
+
};
|
|
362
|
+
katexCss: {
|
|
363
|
+
type: PropType<string>;
|
|
364
|
+
default: string;
|
|
365
|
+
};
|
|
366
|
+
noKatex: {
|
|
367
|
+
type: PropType<boolean>;
|
|
368
|
+
default: boolean;
|
|
369
|
+
};
|
|
370
|
+
defToolbars: {
|
|
371
|
+
type: PropType<string | JSX.Element>;
|
|
372
|
+
};
|
|
373
|
+
extensions: {
|
|
374
|
+
type: PropType<any[]>;
|
|
375
|
+
};
|
|
376
|
+
}>>, {
|
|
394
377
|
editorId: string;
|
|
395
378
|
prettier: boolean;
|
|
396
379
|
preview: boolean;
|
|
@@ -413,8 +396,8 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
413
396
|
languageUserDefined: {
|
|
414
397
|
[key: string]: StaticTextDefaultValue;
|
|
415
398
|
};
|
|
416
|
-
toolbars:
|
|
417
|
-
toolbarsExclude:
|
|
399
|
+
toolbars: ToolbarNames[];
|
|
400
|
+
toolbarsExclude: ToolbarNames[];
|
|
418
401
|
prettierCDN: string;
|
|
419
402
|
prettierMDCDN: string;
|
|
420
403
|
cropperCss: string;
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { PropType } from 'vue';
|
|
2
|
+
declare const _default: import("vue").DefineComponent<{
|
|
3
|
+
title: {
|
|
4
|
+
type: PropType<string>;
|
|
5
|
+
default: string;
|
|
6
|
+
};
|
|
7
|
+
trigger: {
|
|
8
|
+
type: PropType<string | JSX.Element>;
|
|
9
|
+
};
|
|
10
|
+
onClick: {
|
|
11
|
+
type: PropType<(e: MouseEvent) => void>;
|
|
12
|
+
default: () => () => void;
|
|
13
|
+
};
|
|
14
|
+
}, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<import("vue").ExtractPropTypes<{
|
|
15
|
+
title: {
|
|
16
|
+
type: PropType<string>;
|
|
17
|
+
default: string;
|
|
18
|
+
};
|
|
19
|
+
trigger: {
|
|
20
|
+
type: PropType<string | JSX.Element>;
|
|
21
|
+
};
|
|
22
|
+
onClick: {
|
|
23
|
+
type: PropType<(e: MouseEvent) => void>;
|
|
24
|
+
default: () => () => void;
|
|
25
|
+
};
|
|
26
|
+
}>>, {
|
|
27
|
+
title: string;
|
|
28
|
+
onClick: (e: MouseEvent) => void;
|
|
29
|
+
}>;
|
|
30
|
+
export default _default;
|