@uiw/react-md-editor 3.13.0 → 3.14.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 +31 -34
- package/dist/mdeditor.css +20 -21
- package/dist/mdeditor.js +1076 -986
- package/dist/mdeditor.min.css +1 -1
- package/dist/mdeditor.min.js +1 -1
- package/esm/Editor.d.ts +6 -2
- package/esm/Editor.js +3 -3
- package/esm/Editor.js.map +3 -2
- package/esm/commands/bold.js +1 -1
- package/esm/commands/bold.js.map +2 -2
- package/esm/components/TextArea/Markdown.js +31 -24
- package/esm/components/TextArea/Markdown.js.map +12 -9
- package/esm/components/TextArea/index.js +3 -8
- package/esm/components/TextArea/index.js.map +2 -4
- package/esm/index.css +4 -0
- package/esm/index.less +6 -0
- package/lib/Context.js +3 -3
- package/lib/Context.js.map +1 -1
- package/lib/Editor.d.ts +6 -2
- package/lib/Editor.js +22 -22
- package/lib/Editor.js.map +3 -2
- package/lib/commands/bold.js +2 -2
- package/lib/commands/bold.js.map +1 -1
- package/lib/commands/code.js +1 -1
- package/lib/commands/fullscreen.js +1 -1
- package/lib/commands/group.js +4 -4
- package/lib/commands/group.js.map +1 -1
- package/lib/commands/hr.js +1 -1
- package/lib/commands/image.js +1 -1
- package/lib/commands/index.js +8 -8
- package/lib/commands/italic.js +1 -1
- package/lib/commands/link.js +1 -1
- package/lib/commands/list.js +1 -1
- package/lib/commands/preview.js +1 -1
- package/lib/commands/quote.js +1 -1
- package/lib/commands/strikeThrough.js +1 -1
- package/lib/commands/title.js +2 -2
- package/lib/commands/title.js.map +1 -1
- package/lib/commands/title1.js +1 -1
- package/lib/commands/title2.js +1 -1
- package/lib/commands/title3.js +1 -1
- package/lib/commands/title4.js +1 -1
- package/lib/commands/title5.js +1 -1
- package/lib/commands/title6.js +1 -1
- package/lib/components/DragBar/index.js +3 -3
- package/lib/components/TextArea/Markdown.js +39 -33
- package/lib/components/TextArea/Markdown.js.map +12 -9
- package/lib/components/TextArea/Textarea.js +10 -10
- package/lib/components/TextArea/Textarea.js.map +1 -1
- package/lib/components/TextArea/handleKeyDown.js +1 -1
- package/lib/components/TextArea/index.js +14 -19
- package/lib/components/TextArea/index.js.map +2 -4
- package/lib/components/TextArea/shortcuts.js +3 -3
- package/lib/components/TextArea/shortcuts.js.map +1 -1
- package/lib/components/Toolbar/Child.js +4 -4
- package/lib/components/Toolbar/Child.js.map +1 -1
- package/lib/components/Toolbar/index.js +11 -11
- package/lib/components/Toolbar/index.js.map +1 -1
- package/lib/index.js +4 -4
- package/lib/index.js.map +1 -1
- package/lib/index.less +6 -0
- package/lib/utils/InsertTextAtPosition.js +2 -2
- package/lib/utils/InsertTextAtPosition.js.map +1 -1
- package/markdown-editor.css +4 -0
- package/package.json +3 -61
- package/src/Editor.tsx +8 -4
- package/src/commands/bold.tsx +1 -1
- package/src/components/TextArea/Markdown.tsx +31 -24
- package/src/components/TextArea/index.tsx +4 -4
- package/src/index.less +6 -0
- package/LICENSE +0 -21
- package/src/tsconfig.json +0 -8
package/README.md
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
<!--rehype:ignore:start-->
|
|
1
2
|
<p align="center">
|
|
2
3
|
<a href="https://uiwjs.github.io/npm-unpkg/#/pkg/@uiw/react-md-editor/file/README.md">
|
|
3
4
|
<img alt="react-md-editor logo" src="https://user-images.githubusercontent.com/1680273/146292033-0e5e57fc-6f3e-4032-9fa6-0de05f239e36.png">
|
|
@@ -32,7 +33,7 @@
|
|
|
32
33
|
</a>
|
|
33
34
|
</p>
|
|
34
35
|
|
|
35
|
-
<!--
|
|
36
|
+
<!--rehype:ignore:end-->
|
|
36
37
|
|
|
37
38
|
A simple markdown editor with preview, implemented with React.js and TypeScript. This React Component aims to provide a simple Markdown editor with syntax highlighting support. This is based on `textarea` encapsulation, so it does not depend on any modern code editors such as Acs, CodeMirror, Monaco etc.
|
|
38
39
|
|
|
@@ -58,7 +59,7 @@ npm i @uiw/react-md-editor
|
|
|
58
59
|
[](https://uiwjs.github.io/react-md-editor/)
|
|
59
60
|
[](https://uiw.gitee.io/react-md-editor/)
|
|
60
61
|
|
|
61
|
-
```jsx
|
|
62
|
+
```jsx mdx:preview
|
|
62
63
|
import React from "react";
|
|
63
64
|
import MDEditor from '@uiw/react-md-editor';
|
|
64
65
|
|
|
@@ -70,7 +71,7 @@ export default function App() {
|
|
|
70
71
|
value={value}
|
|
71
72
|
onChange={setValue}
|
|
72
73
|
/>
|
|
73
|
-
<MDEditor.Markdown source={value} />
|
|
74
|
+
<MDEditor.Markdown source={value} style={{ whiteSpace: 'pre-wrap' }} />
|
|
74
75
|
</div>
|
|
75
76
|
);
|
|
76
77
|
}
|
|
@@ -81,13 +82,13 @@ export default function App() {
|
|
|
81
82
|
Please note markdown needs to be sanitized if you do not **completely trust** your authors.
|
|
82
83
|
Otherwise, your app is vulnerable to XSS. This can be achieved by adding [rehype-sanitize](https://github.com/rehypejs/rehype-sanitize) as a plugin.
|
|
83
84
|
|
|
84
|
-
```jsx
|
|
85
|
+
```jsx mdx:preview
|
|
85
86
|
import React from "react";
|
|
86
87
|
import MDEditor from '@uiw/react-md-editor';
|
|
87
88
|
import rehypeSanitize from "rehype-sanitize";
|
|
88
89
|
|
|
89
90
|
export default function App() {
|
|
90
|
-
const [value, setValue] = React.useState(
|
|
91
|
+
const [value, setValue] = React.useState(`**Hello world!!!** <IFRAME SRC=\"javascript:javascript:alert(window.origin);\"></IFRAME>`);
|
|
91
92
|
return (
|
|
92
93
|
<div className="container">
|
|
93
94
|
<MDEditor
|
|
@@ -97,10 +98,6 @@ export default function App() {
|
|
|
97
98
|
rehypePlugins: [[rehypeSanitize]],
|
|
98
99
|
}}
|
|
99
100
|
/>
|
|
100
|
-
<MDEditor.Markdown
|
|
101
|
-
source={value}
|
|
102
|
-
rehypePlugins={[[rehypeSanitize]]}
|
|
103
|
-
/>
|
|
104
101
|
</div>
|
|
105
102
|
);
|
|
106
103
|
}
|
|
@@ -110,12 +107,11 @@ export default function App() {
|
|
|
110
107
|
|
|
111
108
|
[](https://codesandbox.io/embed/react-md-editor-custom-toolbars-m2n10?fontsize=14&hidenavigation=1&theme=dark)
|
|
112
109
|
|
|
113
|
-
```
|
|
110
|
+
```jsx mdx:preview
|
|
114
111
|
import React from "react";
|
|
115
|
-
import
|
|
116
|
-
import MDEditor, { commands, ICommand, TextState, TextAreaTextApi } from '@uiw/react-md-editor';
|
|
112
|
+
import MDEditor, { commands } from '@uiw/react-md-editor';
|
|
117
113
|
|
|
118
|
-
const title3
|
|
114
|
+
const title3 = {
|
|
119
115
|
name: 'title3',
|
|
120
116
|
keyCommand: 'title3',
|
|
121
117
|
buttonProps: { 'aria-label': 'Insert title3' },
|
|
@@ -124,7 +120,7 @@ const title3: ICommand = {
|
|
|
124
120
|
<path fill="currentColor" d="M15.7083333,468 C7.03242448,468 0,462.030833 0,454.666667 L0,421.333333 C0,413.969167 7.03242448,408 15.7083333,408 L361.291667,408 C369.967576,408 377,413.969167 377,421.333333 L377,454.666667 C377,462.030833 369.967576,468 361.291667,468 L15.7083333,468 Z M21.6666667,366 C9.69989583,366 0,359.831861 0,352.222222 L0,317.777778 C0,310.168139 9.69989583,304 21.6666667,304 L498.333333,304 C510.300104,304 520,310.168139 520,317.777778 L520,352.222222 C520,359.831861 510.300104,366 498.333333,366 L21.6666667,366 Z M136.835938,64 L136.835937,126 L107.25,126 L107.25,251 L40.75,251 L40.75,126 L-5.68434189e-14,126 L-5.68434189e-14,64 L136.835938,64 Z M212,64 L212,251 L161.648438,251 L161.648438,64 L212,64 Z M378,64 L378,126 L343.25,126 L343.25,251 L281.75,251 L281.75,126 L238,126 L238,64 L378,64 Z M449.047619,189.550781 L520,189.550781 L520,251 L405,251 L405,64 L449.047619,64 L449.047619,189.550781 Z" />
|
|
125
121
|
</svg>
|
|
126
122
|
),
|
|
127
|
-
execute: (state
|
|
123
|
+
execute: (state, api) => {
|
|
128
124
|
let modifyText = `### ${state.selectedText}\n`;
|
|
129
125
|
if (!state.selectedText) {
|
|
130
126
|
modifyText = `### `;
|
|
@@ -134,14 +130,12 @@ const title3: ICommand = {
|
|
|
134
130
|
};
|
|
135
131
|
|
|
136
132
|
export default function App() {
|
|
137
|
-
const [value, setValue] = React.useState("
|
|
133
|
+
const [value, setValue] = React.useState("Hello Markdown! `Tab` key uses default behavior");
|
|
138
134
|
return (
|
|
139
135
|
<div className="container">
|
|
140
136
|
<MDEditor
|
|
141
|
-
value=
|
|
142
|
-
onChange={
|
|
143
|
-
setValue(val!);
|
|
144
|
-
}}
|
|
137
|
+
value={value}
|
|
138
|
+
onChange={setValue}
|
|
145
139
|
commands={[
|
|
146
140
|
// Custom Toolbars
|
|
147
141
|
title3,
|
|
@@ -163,13 +157,13 @@ export default function App() {
|
|
|
163
157
|
return (
|
|
164
158
|
<div style={{ width: 120, padding: 10 }}>
|
|
165
159
|
<div>My Custom Toolbar</div>
|
|
166
|
-
<button type="button" onClick={() => console.log('> execute: >>>>>', getState
|
|
160
|
+
<button type="button" onClick={() => console.log('> execute: >>>>>', getState())}>State</button>
|
|
167
161
|
<button type="button" onClick={() => close()}>Close</button>
|
|
168
162
|
<button type="button" onClick={() => execute()}>Execute</button>
|
|
169
163
|
</div>
|
|
170
164
|
);
|
|
171
165
|
},
|
|
172
|
-
execute: (state
|
|
166
|
+
execute: (state, api) => {
|
|
173
167
|
console.log('>>>>>>update>>>>>', state)
|
|
174
168
|
},
|
|
175
169
|
buttonProps: { 'aria-label': 'Insert title'}
|
|
@@ -185,7 +179,7 @@ export default function App() {
|
|
|
185
179
|
|
|
186
180
|
[](https://codesandbox.io/embed/react-md-editor-preview-markdown-vrucl?fontsize=14&hidenavigation=1&theme=dark)
|
|
187
181
|
|
|
188
|
-
```jsx
|
|
182
|
+
```jsx mdx:preview
|
|
189
183
|
import React from "react";
|
|
190
184
|
import ReactDOM from "react-dom";
|
|
191
185
|
import MDEditor from '@uiw/react-md-editor';
|
|
@@ -207,16 +201,17 @@ The following example is preview in [CodeSandbox](https://codesandbox.io/s/markd
|
|
|
207
201
|
|
|
208
202
|
[](https://codesandbox.io/embed/headless-frog-em8yg?fontsize=14&hidenavigation=1&theme=dark)
|
|
209
203
|
|
|
210
|
-
> ⚠️ Upgrade v2 to v3 [d025430](https://github.com/uiwjs/react-md-editor/blob/
|
|
204
|
+
> ⚠️ Upgrade v2 to v3 [d025430](https://github.com/uiwjs/react-md-editor/blob/7b9f11ab689a7ea288df3e82c26f4f0e9a53d271/website/ExmapleKaTeX.tsx#L1-L63)
|
|
211
205
|
|
|
212
206
|
```bash
|
|
213
207
|
npm install katex
|
|
214
208
|
```
|
|
215
209
|
|
|
216
|
-
```jsx
|
|
210
|
+
```jsx mdx:preview
|
|
217
211
|
import React from "react";
|
|
218
212
|
import ReactDOM from "react-dom";
|
|
219
213
|
import MDEditor from '@uiw/react-md-editor';
|
|
214
|
+
import { getCodeString } from 'rehype-rewrite';
|
|
220
215
|
import katex from 'katex';
|
|
221
216
|
import 'katex/dist/katex.css';
|
|
222
217
|
|
|
@@ -246,15 +241,16 @@ export default function App() {
|
|
|
246
241
|
}
|
|
247
242
|
return <code>{txt}</code>;
|
|
248
243
|
}
|
|
244
|
+
const code = props.node && props.node.children ? getCodeString(props.node.children) : txt;
|
|
249
245
|
if (
|
|
250
|
-
typeof
|
|
246
|
+
typeof code === 'string' &&
|
|
251
247
|
typeof className === 'string' &&
|
|
252
248
|
/^language-katex/.test(className.toLocaleLowerCase())
|
|
253
249
|
) {
|
|
254
|
-
const html = katex.renderToString(
|
|
250
|
+
const html = katex.renderToString(code, {
|
|
255
251
|
throwOnError: false,
|
|
256
252
|
});
|
|
257
|
-
return <code dangerouslySetInnerHTML={{ __html: html }} />;
|
|
253
|
+
return <code style={{ fontSize: '150%' }} dangerouslySetInnerHTML={{ __html: html }} />;
|
|
258
254
|
}
|
|
259
255
|
return <code className={String(className)}>{txt}</code>;
|
|
260
256
|
},
|
|
@@ -269,7 +265,7 @@ export default function App() {
|
|
|
269
265
|
|
|
270
266
|
[](https://codesandbox.io/embed/react-md-editor-text-to-images-ijqmx?fontsize=14&hidenavigation=1&theme=dark)
|
|
271
267
|
|
|
272
|
-
```
|
|
268
|
+
```tsx mdx:preview
|
|
273
269
|
import React from "react";
|
|
274
270
|
import MDEditor, { commands, ICommand, TextState, TextAreaTextApi } from "@uiw/react-md-editor";
|
|
275
271
|
import domToImage from "dom-to-image";
|
|
@@ -284,7 +280,7 @@ const textToImage: ICommand = {
|
|
|
284
280
|
</svg>
|
|
285
281
|
),
|
|
286
282
|
execute: (state: TextState, api: TextAreaTextApi) => {
|
|
287
|
-
const dom = document.getElementsByClassName("
|
|
283
|
+
const dom = document.getElementsByClassName("gooooooooo")[0];
|
|
288
284
|
if (dom) {
|
|
289
285
|
domToImage.toJpeg(dom, {}).then((dataUrl) => {
|
|
290
286
|
const link = document.createElement("a");
|
|
@@ -300,6 +296,7 @@ export default function App() {
|
|
|
300
296
|
return (
|
|
301
297
|
<div className="container">
|
|
302
298
|
<MDEditor
|
|
299
|
+
className="gooooooooo"
|
|
303
300
|
value="**Hello world!!!**"
|
|
304
301
|
commands={[
|
|
305
302
|
textToImage,
|
|
@@ -321,7 +318,7 @@ Using [mermaid](https://github.com/mermaid-js/mermaid) to generation of diagram
|
|
|
321
318
|
npm install mermaid
|
|
322
319
|
```
|
|
323
320
|
|
|
324
|
-
```jsx
|
|
321
|
+
```jsx mdx:preview
|
|
325
322
|
import React, { useState, useRef, useEffect } from "react";
|
|
326
323
|
import ReactDOM from "react-dom";
|
|
327
324
|
import MDEditor from "@uiw/react-md-editor";
|
|
@@ -351,7 +348,7 @@ Bob-->>John: Jolly good!
|
|
|
351
348
|
`;
|
|
352
349
|
|
|
353
350
|
const randomid = () => parseInt(String(Math.random() * 1e15), 10).toString(36);
|
|
354
|
-
const Code = ({ inline, children = [], className, ...props }
|
|
351
|
+
const Code = ({ inline, children = [], className, ...props }) => {
|
|
355
352
|
const demoid = useRef(`dome${randomid()}`);
|
|
356
353
|
const code = getCode(children);
|
|
357
354
|
const demo = useRef(null);
|
|
@@ -488,13 +485,13 @@ Inherit custom color variables by adding [`.wmde-markdown-var`](https://github.c
|
|
|
488
485
|
- `textareaProps?: TextareaHTMLAttributes`: Set the `textarea` related props.
|
|
489
486
|
- `renderTextarea?: (props, opts) => JSX.Element;`: Use div to replace TextArea or re-render TextArea. [#193](https://github.com/uiwjs/react-md-editor/issues/193)
|
|
490
487
|
- `height?: number=200`: The height of the editor.
|
|
491
|
-
- `
|
|
488
|
+
- `visibleDragbar?: boolean=true`: Show drag and drop tool. Set the height of the editor.
|
|
492
489
|
- `highlightEnable?: boolean=true`: Disable editing area code highlighting. The value is `false`, which increases the editing speed.
|
|
493
490
|
- `fullscreen?: boolean=false`: Show markdown preview.
|
|
494
491
|
- `overflow?: boolean=true`: Disable `fullscreen` setting body styles
|
|
495
492
|
- `preview?: 'live' | 'edit' | 'preview'`: Default value `live`, Show markdown preview.
|
|
496
|
-
- `maxHeight?: number=1200`: Maximum drag height. The `
|
|
497
|
-
- `minHeights?: number=100`: Minimum drag height. The `
|
|
493
|
+
- `maxHeight?: number=1200`: Maximum drag height. The `visibleDragbar=true` value is valid.
|
|
494
|
+
- `minHeights?: number=100`: Minimum drag height. The `visibleDragbar=true` value is valid.
|
|
498
495
|
- `tabSize?: number=2`: The number of characters to insert when pressing tab key. Default `2` spaces.
|
|
499
496
|
- `defaultTabEnable?: boolean=false`: If `false`, the `tab` key inserts a tab character into the textarea. If `true`, the `tab` key executes default behavior e.g. focus shifts to next element.
|
|
500
497
|
- `hideToolbar?: boolean=false`: Option to hide the tool bar.
|
package/dist/mdeditor.css
CHANGED
|
@@ -96,6 +96,7 @@
|
|
|
96
96
|
}
|
|
97
97
|
[data-color-mode*='dark'] .wmde-markdown,
|
|
98
98
|
[data-color-mode*='dark'] .wmde-markdown-var,
|
|
99
|
+
.wmde-markdown[data-color-mode*='dark'],
|
|
99
100
|
body[data-color-mode*='dark'] {
|
|
100
101
|
color-scheme: dark;
|
|
101
102
|
--color-prettylights-syntax-comment: #8b949e;
|
|
@@ -143,6 +144,7 @@ body[data-color-mode*='dark'] {
|
|
|
143
144
|
}
|
|
144
145
|
[data-color-mode*='light'] .wmde-markdown,
|
|
145
146
|
[data-color-mode*='light'] .wmde-markdown-var,
|
|
147
|
+
.wmde-markdown[data-color-mode*='light'],
|
|
146
148
|
body[data-color-mode*='light'] {
|
|
147
149
|
color-scheme: light;
|
|
148
150
|
--color-prettylights-syntax-comment: #6e7781;
|
|
@@ -351,7 +353,6 @@ body[data-color-mode*='light'] {
|
|
|
351
353
|
width: -webkit-max-content;
|
|
352
354
|
width: max-content;
|
|
353
355
|
max-width: 100%;
|
|
354
|
-
overflow: auto;
|
|
355
356
|
}
|
|
356
357
|
.wmde-markdown td,
|
|
357
358
|
.wmde-markdown th {
|
|
@@ -387,15 +388,6 @@ body[data-color-mode*='light'] {
|
|
|
387
388
|
font-weight: 600;
|
|
388
389
|
line-height: 1.25;
|
|
389
390
|
}
|
|
390
|
-
.wmde-markdown table {
|
|
391
|
-
border-spacing: 0;
|
|
392
|
-
border-collapse: collapse;
|
|
393
|
-
display: block;
|
|
394
|
-
width: -webkit-max-content;
|
|
395
|
-
width: max-content;
|
|
396
|
-
max-width: 100%;
|
|
397
|
-
overflow: auto;
|
|
398
|
-
}
|
|
399
391
|
.wmde-markdown td,
|
|
400
392
|
.wmde-markdown th {
|
|
401
393
|
padding: 0;
|
|
@@ -878,8 +870,7 @@ body[data-color-mode*='light'] {
|
|
|
878
870
|
.wmde-markdown .task-list-item .handle {
|
|
879
871
|
display: none;
|
|
880
872
|
}
|
|
881
|
-
.wmde-markdown .task-list-item-checkbox
|
|
882
|
-
.wmde-markdown input[type='checkbox'] {
|
|
873
|
+
.wmde-markdown .task-list-item-checkbox {
|
|
883
874
|
margin: 0 0.2em 0.25em -1.6em;
|
|
884
875
|
vertical-align: middle;
|
|
885
876
|
}
|
|
@@ -1027,10 +1018,8 @@ body[data-color-mode*='light'] {
|
|
|
1027
1018
|
margin: 0;
|
|
1028
1019
|
font-size: 14px;
|
|
1029
1020
|
line-height: 18px;
|
|
1030
|
-
|
|
1031
|
-
|
|
1032
|
-
-webkit-font-variant-ligatures: common-ligatures;
|
|
1033
|
-
font-variant-ligatures: common-ligatures;
|
|
1021
|
+
font-feature-settings: "liga", "clig";
|
|
1022
|
+
font-variant-ligatures: common-ligatures;
|
|
1034
1023
|
}
|
|
1035
1024
|
.w-md-editor-text-pre,
|
|
1036
1025
|
.w-md-editor-text-input,
|
|
@@ -1043,14 +1032,14 @@ body[data-color-mode*='light'] {
|
|
|
1043
1032
|
font-family: inherit;
|
|
1044
1033
|
font-size: inherit;
|
|
1045
1034
|
font-style: inherit;
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
-webkit-font-variant-ligatures: inherit;
|
|
1049
|
-
font-variant-ligatures: inherit;
|
|
1035
|
+
font-feature-settings: inherit;
|
|
1036
|
+
font-variant-ligatures: inherit;
|
|
1050
1037
|
font-weight: inherit;
|
|
1051
1038
|
letter-spacing: inherit;
|
|
1052
1039
|
line-height: inherit;
|
|
1053
|
-
tab-size: inherit;
|
|
1040
|
+
-moz-tab-size: inherit;
|
|
1041
|
+
-o-tab-size: inherit;
|
|
1042
|
+
tab-size: inherit;
|
|
1054
1043
|
text-indent: inherit;
|
|
1055
1044
|
text-rendering: inherit;
|
|
1056
1045
|
text-transform: inherit;
|
|
@@ -1112,6 +1101,10 @@ body[data-color-mode*='light'] {
|
|
|
1112
1101
|
.w-md-editor-text-input {
|
|
1113
1102
|
color: transparent !important;
|
|
1114
1103
|
}
|
|
1104
|
+
.w-md-editor-text-input::-moz-selection {
|
|
1105
|
+
background-color: #accef7 !important;
|
|
1106
|
+
color: transparent !important;
|
|
1107
|
+
}
|
|
1115
1108
|
.w-md-editor-text-input::selection {
|
|
1116
1109
|
background-color: #accef7 !important;
|
|
1117
1110
|
color: transparent !important;
|
|
@@ -1183,6 +1176,7 @@ body[data-color-mode*='light'] {
|
|
|
1183
1176
|
align-items: center;
|
|
1184
1177
|
border-radius: 3px 3px 0 0;
|
|
1185
1178
|
-webkit-user-select: none;
|
|
1179
|
+
-moz-user-select: none;
|
|
1186
1180
|
-ms-user-select: none;
|
|
1187
1181
|
user-select: none;
|
|
1188
1182
|
}
|
|
@@ -1258,6 +1252,7 @@ body[data-color-mode*='light'] {
|
|
|
1258
1252
|
height: 10px;
|
|
1259
1253
|
border-radius: 0 0 3px 0;
|
|
1260
1254
|
-webkit-user-select: none;
|
|
1255
|
+
-moz-user-select: none;
|
|
1261
1256
|
-ms-user-select: none;
|
|
1262
1257
|
user-select: none;
|
|
1263
1258
|
}
|
|
@@ -1288,6 +1283,10 @@ body[data-color-mode*='light'] {
|
|
|
1288
1283
|
width: 50%;
|
|
1289
1284
|
height: 100%;
|
|
1290
1285
|
}
|
|
1286
|
+
.w-md-editor-text-pre > code {
|
|
1287
|
+
word-break: break-word !important;
|
|
1288
|
+
white-space: pre-wrap !important;
|
|
1289
|
+
}
|
|
1291
1290
|
.w-md-editor-preview {
|
|
1292
1291
|
width: 50%;
|
|
1293
1292
|
box-sizing: border-box;
|