md-editor-v3 7.0.0 → 7.1.0-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/lib/cjs/chunks/config.cjs +14 -14
- package/lib/cjs/chunks/index2.cjs +1 -1
- package/lib/cjs/chunks/index3.cjs +1 -1
- package/lib/cjs/chunks/index4.cjs +47 -44
- package/lib/cjs/chunks/index5.cjs +7 -7
- package/lib/es/chunks/config.mjs +602 -466
- package/lib/es/chunks/index2.mjs +11 -11
- package/lib/es/chunks/index3.mjs +3 -1
- package/lib/es/chunks/index4.mjs +859 -850
- package/lib/es/chunks/index5.mjs +80 -80
- package/lib/types/index.d.ts +87 -76
- package/package.json +1 -1
package/lib/es/chunks/index2.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { createVNode as t, defineComponent as k, h as j, inject as p, ref as c, shallowRef as O, reactive as E, computed as g, watch as x, nextTick as b, onMounted as W, Teleport as q } from "vue";
|
|
2
2
|
import { p as l, g as C } from "./config.mjs";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
3
|
+
import { Upload as N, Trash2 as D, X as U, SquareSigma as X, ChartArea as G, ListTree as Q, CodeXml as V, Eye as Z, View as J, Expand as K, Shrink as Y, Maximize2 as _, Minimize2 as ee, SquareCode as w, Save as te, Forward as ne, Reply as oe, Table as ie, Image as le, Link as se, Code as ae, ListTodo as re, ListOrdered as ue, List as ce, Quote as de, Superscript as me, Subscript as fe, Heading as he, Strikethrough as ve, Italic as ye, Underline as ge, Bold as Se } from "@lucide/vue";
|
|
4
|
+
import { c as I } from "./index5.mjs";
|
|
5
|
+
import { k as z } from "./dom.mjs";
|
|
6
|
+
import { g as M } from "./vue-tsx.mjs";
|
|
7
7
|
const pe = () => t("svg", {
|
|
8
8
|
xmlns: "http://www.w3.org/2000/svg",
|
|
9
9
|
viewBox: "0 0 24 24",
|
|
@@ -30,14 +30,14 @@ const pe = () => t("svg", {
|
|
|
30
30
|
"ordered-list": ue,
|
|
31
31
|
task: re,
|
|
32
32
|
"code-row": ae,
|
|
33
|
-
code:
|
|
33
|
+
code: w,
|
|
34
34
|
link: se,
|
|
35
35
|
image: le,
|
|
36
36
|
table: ie,
|
|
37
37
|
revoke: oe,
|
|
38
38
|
next: ne,
|
|
39
39
|
save: te,
|
|
40
|
-
prettier:
|
|
40
|
+
prettier: w,
|
|
41
41
|
minimize: ee,
|
|
42
42
|
maximize: _,
|
|
43
43
|
"fullscreen-exit": Y,
|
|
@@ -161,14 +161,14 @@ const pe = () => t("svg", {
|
|
|
161
161
|
});
|
|
162
162
|
x(() => e.isFullscreen, (o) => {
|
|
163
163
|
o ? d() : b(() => {
|
|
164
|
-
d =
|
|
164
|
+
d = z(h.value, (i, s) => {
|
|
165
165
|
n.initPos.insetInlineStart = i + "px", n.initPos.insetBlockStart = s + "px";
|
|
166
166
|
});
|
|
167
167
|
});
|
|
168
168
|
}), x(() => e.visible, (o) => {
|
|
169
|
-
o ? (n.maskStyle.zIndex = C.editorConfig.zIndex +
|
|
169
|
+
o ? (n.maskStyle.zIndex = C.editorConfig.zIndex + I(), n.modalStyle.zIndex = C.editorConfig.zIndex + I(), r.value.push("zoom-in"), m.value = o, b(() => {
|
|
170
170
|
const i = f.value.offsetWidth / 2, s = f.value.offsetHeight / 2, T = document.documentElement.clientWidth / 2, H = document.documentElement.clientHeight / 2;
|
|
171
|
-
n.initPos.insetInlineStart = T - i + "px", n.initPos.insetBlockStart = H - s + "px", e.isFullscreen || (d =
|
|
171
|
+
n.initPos.insetInlineStart = T - i + "px", n.initPos.insetBlockStart = H - s + "px", e.isFullscreen || (d = z(h.value, (A, L) => {
|
|
172
172
|
n.initPos.insetInlineStart = A + "px", n.initPos.insetBlockStart = L + "px";
|
|
173
173
|
}));
|
|
174
174
|
}), setTimeout(() => {
|
|
@@ -192,9 +192,9 @@ const pe = () => t("svg", {
|
|
|
192
192
|
const o = $.value?.getRootNode();
|
|
193
193
|
v.value = o instanceof Document ? document.body : o;
|
|
194
194
|
}), () => {
|
|
195
|
-
const o =
|
|
195
|
+
const o = M({
|
|
196
196
|
ctx: u
|
|
197
|
-
}), i =
|
|
197
|
+
}), i = M({
|
|
198
198
|
props: e,
|
|
199
199
|
ctx: u
|
|
200
200
|
}, "title");
|
package/lib/es/chunks/index3.mjs
CHANGED
|
@@ -69,7 +69,9 @@ const ce = `.${w}-preview > [data-line]`, R = (e, l) => +getComputedStyle(e).get
|
|
|
69
69
|
return !1;
|
|
70
70
|
let E = 1;
|
|
71
71
|
const f = l.querySelector(`[data-line="${n.start}"]`) || l.firstElementChild?.firstElementChild, u = l.querySelector(`[data-line="${n.end + 1}"]`) || l.lastElementChild?.lastElementChild, h = c.scrollHeight - c.clientHeight, i = l.scrollHeight - l.clientHeight;
|
|
72
|
-
let g = d(n.start)
|
|
72
|
+
let g = d(n.start);
|
|
73
|
+
const p = y(n.end);
|
|
74
|
+
let r = f.offsetTop, b = u.offsetTop - r;
|
|
73
75
|
g === 0 && (r = 0, f === u ? (v = 0, b = 0) : b = u.offsetTop), E = (c.scrollTop - g) / (p - g);
|
|
74
76
|
const A = u == l.lastElementChild?.lastElementChild ? u.offsetTop + u.clientHeight : u.offsetTop;
|
|
75
77
|
if (p >= h || A > i) {
|