md-editor-v3 1.8.0 → 1.10.0

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 CHANGED
@@ -4,9 +4,9 @@
4
4
 
5
5
  English \| [中文](https://github.com/imzbf/md-editor-v3/blob/dev/README-CN.md)
6
6
 
7
- Markdown editor for vue3, developed by `jsx` and `typescript`.
7
+ Markdown editor for vue3, developed in `jsx` and `typescript`.
8
8
 
9
- - Documentation and demo:[Go](https://imzbf.github.io/md-editor-v3)
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
 
@@ -22,7 +22,8 @@ Markdown editor for vue3, developed by `jsx` and `typescript`.
22
22
  - Upload picture, paste or clip the picture and upload it.
23
23
  - Render article directly(no editor,no event listener, only preview content).
24
24
  - Preview themes, support `defalut`、`vuepress`、`github` styles(not identical).
25
- - `mermaid`(>=1.3.0).
25
+ - `mermaid`(>=1.8.0).
26
+ - `katex` mathematical formula(>=1.9.0).
26
27
 
27
28
  > More features are developing, if you have some ideas or find issues, please tell it to me~
28
29
 
@@ -37,7 +38,7 @@ Markdown editor for vue3, developed by `jsx` and `typescript`.
37
38
  ### Props
38
39
 
39
40
  | name | type | default | description |
40
- | --- | --- | --- | --- |
41
+ | --- | --- | --- | --- | --- |
41
42
  | modelValue | String | '' | Markdown content,use `v-model` in vue template |
42
43
  | theme | 'light' \| 'dark' | 'light' | Change editor theme |
43
44
  | editorClass | String | '' | |
@@ -48,29 +49,39 @@ Markdown editor for vue3, developed by `jsx` and `typescript`.
48
49
  | pageFullScreen | Boolean | false | Screenfull in web page |
49
50
  | preview | Boolean | true | Preview content in editor |
50
51
  | htmlPreview | Boolean | false | Preview html in editor |
51
- | previewOnly<sup>v1.3.0</sup> | Boolean | false | Only render article content, no toolbar, no edit area |
52
+ | previewOnly | Boolean | false | Only render article content, no toolbar, no edit area |
52
53
  | language | String | 'zh-CN' | Build-in language('zh-CN','en-US') |
53
- | languageUserDefined<sup>v1.5.0 changed</sup> | Object | {key: StaticTextDefaultValue} | Expand language,update `language` api to your key |
54
+ | languageUserDefined | Object | {key: StaticTextDefaultValue} | Expand language,update `language` api to your key |
54
55
  | toolbars | Array | [toolbars] | Show some item of toolbars,all keys<sup>see `toolbars` below<sup> |
55
- | toolbarsExclude<sup>v1.1.4</sup> | Array | [] | Don't show some item of toolbars,all keys`toolbars` |
56
+ | toolbarsExclude | Array | [] | Don't show some item of toolbars,all keys`toolbars` |
56
57
  | prettier | Boolean | true | Use prettier to beautify content or not |
57
58
  | prettierCDN | String | [standalone@2.4.0](https://cdn.jsdelivr.net/npm/prettier@2.4.0/standalone.js) | |
58
59
  | prettierMDCDN | String | [parser-markdown@2.4.0](https://cdn.jsdelivr.net/npm/prettier@2.4.0/parser-markdown.js) | |
59
- | cropperCss<sup>v1.2.0</sup> | String | [cropper.min.css@1.5.12](https://cdn.jsdelivr.net/npm/cropperjs@1.5.12/dist/cropper.min.css) | Cropper css url |
60
- | cropperJs<sup>v1.2.0</sup> | String | [cropper.min.js@1.5.12](https://cdn.jsdelivr.net/npm/cropperjs@1.5.12/dist/cropper.min.js) | Cropper js url |
61
- | iconfontJs<sup>v1.3.2</sup> | String | [iconfont](https://at.alicdn.com/t/font_2605852_khjf435c7th.js) | Icon url |
62
- | editorId<sup>[v1.6.4 updated](https://github.com/imzbf/md-editor-v3/releases/tag/v1.6.4)</sup> | String | md-editor-v3 | Editor id, also the html id, it is used when there are more than two editors |
63
- | tabWidth<sup>v1.4.0<sup> | Number | 2 | One tab eq some space |
64
- | showCodeRowNumber<sup>v1.4.3</sup> | Boolean | false | Show row number for code block or not |
65
- | screenfull<sup>v1.4.3</sup> | Object | null | Screenfull instance, editor will not insert script of it |
66
- | screenfullJs<sup><v1.4.3</sup> | String | [screenfull@5.1.0](https://cdn.jsdelivr.net/npm/screenfull@5.1.0/dist/screenfull.js) | Screenfull js url |
67
- | previewTheme<sup>v1.4.3</sup> | 'default' \| 'github' \| 'vuepress' | 'default' | Preview themes |
68
- | style<sup>v1.7.0</sup> | CSSProperties | {} | Editor's inline style |
69
- | tableShape<sup>v1.8.0</sup> | [Number, Number] | [6, 4] | Preset the size of the table, [columns, rows]. |
70
- | mermaid<sup>v1.8.0</sup> | Object | undefined | `mermaid` instance |
71
- | mermaidJs<sup>v1.8.0</sup> | String | [mermaid@8.13.5](https://cdn.jsdelivr.net/npm/mermaid@8.13.5/dist/mermaid.min.js) | mermaidJs url |
72
- | noMermaid<sup>v1.8.0</sup> | Boolean | false | do not use mermaid |
73
- | placeholder<sup>v1.8.0</sup> | String | '' | |
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<Object> | null | [marked](https://marked.js.org/using_pro#extensions) extensions |
81
+
82
+ mark and emoji extensions
83
+
84
+ ![mark and Emoji extension](https://imzbf.github.io/md-editor-v3/imgs/mark_emoji.gif)
74
85
 
75
86
  [toolbars]
76
87
 
@@ -94,6 +105,7 @@ Markdown editor for vue3, developed by `jsx` and `typescript`.
94
105
  'image',
95
106
  'table',
96
107
  'mermaid',
108
+ 'katex',
97
109
  '-',
98
110
  'revoke',
99
111
  'next',
@@ -108,7 +120,9 @@ Markdown editor for vue3, developed by `jsx` and `typescript`.
108
120
  ];
109
121
  ```
110
122
 
111
- > after v1.6.0, You can sort the toolbar as you like, split tools by `'-'`, the left and right toolbars are divided by `'='`!
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]().
112
126
 
113
127
  Expand language,you need to replace all the content here:
114
128
 
@@ -132,6 +146,7 @@ export interface ToolbarTips {
132
146
  image?: string;
133
147
  table?: string;
134
148
  mermaid?: string;
149
+ katex?: string;
135
150
  revoke?: string;
136
151
  next?: string;
137
152
  save?: string;
@@ -194,6 +209,13 @@ export interface StaticTextDefaultValue {
194
209
  relationship?: string;
195
210
  journey?: string;
196
211
  };
212
+ // 1.9.0
213
+ katex?: {
214
+ // formula inline
215
+ inline: string;
216
+ // formula block
217
+ block: string;
218
+ };
197
219
  }
198
220
  ```
199
221
 
@@ -205,9 +227,9 @@ export interface StaticTextDefaultValue {
205
227
  | onSave | v:String | Save Content event,`ctrl+s`and click button will trigger |
206
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 |
207
229
  | onHtmlChanged | h:String | Compile markdown successful event,you can use it to get the html code |
208
- | onGetCatalog<sup>v1.4.0</sup> | list: HeadList[] | Get catalogue of article |
209
- | markedHeading<sup>v1.6.0</sup> | text: string,level: 1-6,raw: string, slugger: Slugger | `marked` head renderer methods |
210
- | markedHeadingId<sup>v1.7.0</sup> | (text: string, level: number) => string | title `ID` generator |
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 |
211
233
  | sanitize | (html: string) => string | Sanitize the html, prevent XSS. |
212
234
 
213
235
  > If `markedHeading` is overridden, be sure to tell the editor the algorithm for generating the title ID by `marketheadingid`.
@@ -241,7 +263,7 @@ export interface StaticTextDefaultValue {
241
263
  | CTRL + ALT + C | code row | | v1.0.0 |
242
264
  | CTRL + SHIFT + ALT + T | table | `\|table\|` | v1.4.0 |
243
265
 
244
- ## Simple demo
266
+ ## Simple example
245
267
 
246
268
  ### Jsx module
247
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;
@@ -1,113 +1,6 @@
1
1
  import { PropType, CSSProperties } from 'vue';
2
- declare global {
3
- interface Window {
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
- revoke?: string;
30
- next?: string;
31
- save?: string;
32
- prettier?: string;
33
- pageFullscreen?: string;
34
- fullscreen?: string;
35
- preview?: string;
36
- htmlPreview?: string;
37
- catalog?: string;
38
- github?: string;
39
- '-'?: string;
40
- '='?: string;
41
- }
42
- export interface StaticTextDefaultValue {
43
- toolbarTips?: ToolbarTips;
44
- titleItem?: {
45
- h1?: string;
46
- h2?: string;
47
- h3?: string;
48
- h4?: string;
49
- h5?: string;
50
- h6?: string;
51
- };
52
- imgTitleItem?: {
53
- link: string;
54
- upload: string;
55
- clip2upload: string;
56
- };
57
- linkModalTips?: {
58
- title?: string;
59
- descLable?: string;
60
- descLablePlaceHolder?: string;
61
- urlLable?: string;
62
- UrlLablePlaceHolder?: string;
63
- buttonOK?: string;
64
- };
65
- clipModalTips?: {
66
- title?: string;
67
- buttonUpload?: string;
68
- };
69
- copyCode?: {
70
- text?: string;
71
- tips?: string;
72
- };
73
- mermaid?: {
74
- flow?: string;
75
- sequence?: string;
76
- gantt?: string;
77
- class?: string;
78
- state?: string;
79
- pie?: string;
80
- relationship?: string;
81
- journey?: string;
82
- };
83
- }
84
- export interface StaticTextDefault {
85
- 'zh-CN': StaticTextDefaultValue;
86
- 'en-US': StaticTextDefaultValue;
87
- }
88
- export declare type StaticTextDefaultKey = keyof StaticTextDefault;
89
- export declare type ToolbarNames = keyof ToolbarTips;
90
- export interface SettingType {
91
- pageFullScreen: boolean;
92
- fullscreen: boolean;
93
- preview: boolean;
94
- htmlPreview: boolean;
95
- }
96
- export declare const prefix = "md";
97
- export interface HeadList {
98
- text: string;
99
- level: 1 | 2 | 3 | 4 | 5 | 6;
100
- }
101
- export declare type PreviewThemes = 'default' | 'github' | 'vuepress';
102
- export declare type MarkedHeading = (text: string, level: 1 | 2 | 3 | 4 | 5 | 6, raw: string, slugger: {
103
- seen: {
104
- [slugValue: string]: number;
105
- };
106
- slug(value: string, options?: {
107
- dryrun: boolean;
108
- }): string;
109
- }) => string;
110
- 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;
111
4
  declare const _default: import("vue").DefineComponent<{
112
5
  modelValue: {
113
6
  type: PropType<string>;
@@ -173,11 +66,11 @@ declare const _default: import("vue").DefineComponent<{
173
66
  default: () => {};
174
67
  };
175
68
  toolbars: {
176
- type: PropType<(keyof ToolbarTips)[]>;
69
+ type: PropType<ToolbarNames[]>;
177
70
  default: string[];
178
71
  };
179
72
  toolbarsExclude: {
180
- type: PropType<(keyof ToolbarTips)[]>;
73
+ type: PropType<ToolbarNames[]>;
181
74
  default: never[];
182
75
  };
183
76
  prettier: {
@@ -273,96 +166,214 @@ declare const _default: import("vue").DefineComponent<{
273
166
  type: PropType<string>;
274
167
  default: string;
275
168
  };
276
- }, () => JSX.Element, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, Record<string, any>, string, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps, Readonly<{
277
- modelValue?: unknown;
278
- theme?: unknown;
279
- editorClass?: unknown;
280
- hljs?: unknown;
281
- highlightJs?: unknown;
282
- highlightCss?: unknown;
283
- historyLength?: unknown;
284
- onChange?: unknown;
285
- onSave?: unknown;
286
- onUploadImg?: unknown;
287
- pageFullScreen?: unknown;
288
- preview?: unknown;
289
- htmlPreview?: unknown;
290
- previewOnly?: unknown;
291
- language?: unknown;
292
- languageUserDefined?: unknown;
293
- toolbars?: unknown;
294
- toolbarsExclude?: unknown;
295
- prettier?: unknown;
296
- prettierCDN?: unknown;
297
- prettierMDCDN?: unknown;
298
- onHtmlChanged?: unknown;
299
- Cropper?: unknown;
300
- cropperCss?: unknown;
301
- cropperJs?: unknown;
302
- iconfontJs?: unknown;
303
- onGetCatalog?: unknown;
304
- editorId?: unknown;
305
- tabWidth?: unknown;
306
- showCodeRowNumber?: unknown;
307
- screenfull?: unknown;
308
- screenfullJs?: unknown;
309
- previewTheme?: unknown;
310
- markedHeading?: unknown;
311
- style?: unknown;
312
- markedHeadingId?: unknown;
313
- tableShape?: unknown;
314
- mermaid?: unknown;
315
- mermaidJs?: unknown;
316
- noMermaid?: unknown;
317
- sanitize?: unknown;
318
- placeholder?: unknown;
319
- } & {
320
- editorId: string;
321
- prettier: boolean;
322
- preview: boolean;
323
- htmlPreview: boolean;
324
- previewOnly: boolean;
325
- tabWidth: number;
326
- showCodeRowNumber: boolean;
327
- Cropper: Function;
328
- theme: "dark" | "light";
329
- historyLength: number;
330
- previewTheme: PreviewThemes;
331
- style: string | CSSProperties;
332
- modelValue: string;
333
- editorClass: string;
334
- hljs: Record<string, any>;
335
- highlightJs: string;
336
- highlightCss: string;
337
- pageFullScreen: boolean;
338
- language: string;
169
+ katex: {
170
+ type: ObjectConstructor;
171
+ };
172
+ katexJs: {
173
+ type: PropType<string>;
174
+ default: string;
175
+ };
176
+ katexCss: {
177
+ type: PropType<string>;
178
+ default: string;
179
+ };
180
+ noKatex: {
181
+ type: PropType<boolean>;
182
+ default: boolean;
183
+ };
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
+ };
339
248
  languageUserDefined: {
340
- [key: string]: StaticTextDefaultValue;
249
+ type: PropType<{
250
+ [key: string]: StaticTextDefaultValue;
251
+ }>;
252
+ default: () => {};
341
253
  };
342
- toolbars: (keyof ToolbarTips)[];
343
- toolbarsExclude: (keyof ToolbarTips)[];
344
- prettierCDN: string;
345
- prettierMDCDN: string;
346
- cropperCss: string;
347
- cropperJs: string;
348
- iconfontJs: string;
349
- screenfull: Record<string, any>;
350
- screenfullJs: string;
351
- markedHeading: MarkedHeading;
352
- markedHeadingId: MarkedHeadingId;
353
- tableShape: number[];
354
- mermaidJs: string;
355
- noMermaid: boolean;
356
- sanitize: (html: string) => string;
357
- placeholder: string;
358
- } & {
359
- mermaid?: Record<string, any> | undefined;
360
- onSave?: ((v: string) => void) | undefined;
361
- onChange?: ((v: string) => void) | undefined;
362
- onUploadImg?: ((files: FileList, callBack: (urls: string[]) => void) => void) | undefined;
363
- onHtmlChanged?: ((h: string) => void) | undefined;
364
- onGetCatalog?: ((list: HeadList[]) => void) | undefined;
365
- }>, {
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
+ }>>, {
366
377
  editorId: string;
367
378
  prettier: boolean;
368
379
  preview: boolean;
@@ -385,8 +396,8 @@ declare const _default: import("vue").DefineComponent<{
385
396
  languageUserDefined: {
386
397
  [key: string]: StaticTextDefaultValue;
387
398
  };
388
- toolbars: (keyof ToolbarTips)[];
389
- toolbarsExclude: (keyof ToolbarTips)[];
399
+ toolbars: ToolbarNames[];
400
+ toolbarsExclude: ToolbarNames[];
390
401
  prettierCDN: string;
391
402
  prettierMDCDN: string;
392
403
  cropperCss: string;
@@ -401,5 +412,8 @@ declare const _default: import("vue").DefineComponent<{
401
412
  noMermaid: boolean;
402
413
  sanitize: (html: string) => string;
403
414
  placeholder: string;
415
+ katexJs: string;
416
+ katexCss: string;
417
+ noKatex: boolean;
404
418
  }>;
405
419
  export default _default;
@@ -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;