@naersen/tts-rich-text 0.8.1 → 0.8.3

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/dist/index.js CHANGED
@@ -1,6 +1,6 @@
1
1
  import { ToolConfig as P, LanguageOptions as gl, DeleteMode as cl, getInitContent as Jn, sanitizePastedHtml as dl, sanitizePastedText as _i, resolveTtsEditorFeatures as ml, NumberToTextTools as pl, convertToTtsFormat as Yi, estimateTtsDuration as fl, StopOptions as yl } from "./core.js";
2
2
  import { allToolTypes as bc, getVisualLength as jc, splitTextToSentences as vc, toCardinal as Ac, toColloquial as Zc, toPhoneReading as xc, toPositional as Cc, transformParagraph as Ic } from "./core.js";
3
- import { ref as K, computed as T, useSlots as ql, defineComponent as $, useCssVars as Nt, unref as b, toRefs as ki, openBlock as Y, createElementBlock as L, normalizeClass as bn, createBlock as _, mergeProps as zl, createSlots as bl, withCtx as N, createElementVNode as A, createVNode as H, renderList as gn, renderSlot as wn, normalizeProps as jl, guardReactiveProps as vl, normalizeStyle as he, toDisplayString as F, getCurrentScope as Rt, onScopeDispose as Al, readonly as Ki, toRef as Zl, customRef as xl, watch as cn, onMounted as we, nextTick as de, getCurrentInstance as Ft, shallowRef as zi, watchEffect as $i, toRaw as Pt, Fragment as en, createCommentVNode as yn, Transition as Cl, withModifiers as bi, inject as Il, provide as Wl, onUnmounted as wl, onBeforeUnmount as Se, h as Ut, withDirectives as Te, vModelText as Ne, isRef as Et, createTextVNode as An, toValue as Sl, reactive as Vi, useModel as Gi, mergeModels as ae } from "vue";
3
+ import { ref as K, computed as T, useSlots as ql, defineComponent as $, useCssVars as Nt, unref as z, toRefs as ki, openBlock as Y, createElementBlock as L, normalizeClass as bn, createBlock as _, mergeProps as zl, createSlots as bl, withCtx as N, createElementVNode as v, createVNode as H, renderList as gn, renderSlot as wn, normalizeProps as jl, guardReactiveProps as vl, normalizeStyle as he, toDisplayString as F, getCurrentScope as Rt, onScopeDispose as Al, readonly as Ki, toRef as Zl, customRef as xl, watch as cn, onMounted as we, nextTick as de, getCurrentInstance as Ft, shallowRef as zi, watchEffect as $i, toRaw as Pt, Fragment as en, createCommentVNode as yn, Transition as Cl, withModifiers as bi, inject as Il, provide as Wl, onUnmounted as wl, onBeforeUnmount as Se, h as Ut, withDirectives as Te, vModelText as Ne, isRef as Et, createTextVNode as An, toValue as Sl, reactive as Vi, useModel as Gi, mergeModels as ae } from "vue";
4
4
  import { ElButton as Ol, ElMessage as ji, ElMessageBox as Yl, ElDialog as Oe, ElInput as nt, ElPopover as _e, ElInputNumber as kl } from "element-plus";
5
5
  import { Node as Kl, Extension as Vl, isTextSelection as Gl, posToDOMRect as Dt, getText as Xl, getTextSerializersFromSchema as Jl } from "@tiptap/core";
6
6
  import { nodeViewProps as Hl, NodeViewWrapper as Ll, NodeViewContent as ye, VueNodeViewRenderer as Ml, mergeAttributes as et, useEditor as Tl, EditorContent as Nl } from "@tiptap/vue-3";
@@ -15,99 +15,99 @@ var _t = { exports: {} };
15
15
  (function(i, t) {
16
16
  e.exports = t();
17
17
  })(Bt, function() {
18
- var i = 1e3, t = 6e4, o = 36e5, l = "millisecond", s = "second", h = "minute", r = "hour", u = "day", g = "week", a = "month", c = "quarter", d = "year", f = "date", m = "Invalid Date", y = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, j = /\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, Z = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(v) {
19
- var C = ["th", "st", "nd", "rd"], z = v % 100;
20
- return "[" + v + (C[(z - 20) % 10] || C[z] || C[0]) + "]";
21
- } }, I = function(v, C, z) {
22
- var S = String(v);
23
- return !S || S.length >= C ? v : "" + Array(C + 1 - S.length).join(z) + v;
24
- }, w = { s: I, z: function(v) {
25
- var C = -v.utcOffset(), z = Math.abs(C), S = Math.floor(z / 60), x = z % 60;
26
- return (C <= 0 ? "+" : "-") + I(S, 2, "0") + ":" + I(x, 2, "0");
27
- }, m: function v(C, z) {
28
- if (C.date() < z.date()) return -v(z, C);
29
- var S = 12 * (z.year() - C.year()) + (z.month() - C.month()), x = C.clone().add(S, a), X = z - x < 0, R = C.clone().add(S + (X ? -1 : 1), a);
30
- return +(-(S + (z - x) / (X ? x - R : R - x)) || 0);
31
- }, a: function(v) {
32
- return v < 0 ? Math.ceil(v) || 0 : Math.floor(v);
33
- }, p: function(v) {
34
- return { M: a, y: d, w: g, d: u, D: f, h: r, m: h, s, ms: l, Q: c }[v] || String(v || "").toLowerCase().replace(/s$/, "");
35
- }, u: function(v) {
36
- return v === void 0;
18
+ var i = 1e3, t = 6e4, o = 36e5, l = "millisecond", s = "second", h = "minute", r = "hour", u = "day", g = "week", a = "month", c = "quarter", p = "year", f = "date", d = "Invalid Date", y = /^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/, b = /\[([^\]]+)]|YYYY|YY|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g, A = { name: "en", weekdays: "Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"), months: "January_February_March_April_May_June_July_August_September_October_November_December".split("_"), ordinal: function(j) {
19
+ var x = ["th", "st", "nd", "rd"], q = j % 100;
20
+ return "[" + j + (x[(q - 20) % 10] || x[q] || x[0]) + "]";
21
+ } }, I = function(j, x, q) {
22
+ var O = String(j);
23
+ return !O || O.length >= x ? j : "" + Array(x + 1 - O.length).join(q) + j;
24
+ }, w = { s: I, z: function(j) {
25
+ var x = -j.utcOffset(), q = Math.abs(x), O = Math.floor(q / 60), Z = q % 60;
26
+ return (x <= 0 ? "+" : "-") + I(O, 2, "0") + ":" + I(Z, 2, "0");
27
+ }, m: function j(x, q) {
28
+ if (x.date() < q.date()) return -j(q, x);
29
+ var O = 12 * (q.year() - x.year()) + (q.month() - x.month()), Z = x.clone().add(O, a), X = q - Z < 0, R = x.clone().add(O + (X ? -1 : 1), a);
30
+ return +(-(O + (q - Z) / (X ? Z - R : R - Z)) || 0);
31
+ }, a: function(j) {
32
+ return j < 0 ? Math.ceil(j) || 0 : Math.floor(j);
33
+ }, p: function(j) {
34
+ return { M: a, y: p, w: g, d: u, D: f, h: r, m: h, s, ms: l, Q: c }[j] || String(j || "").toLowerCase().replace(/s$/, "");
35
+ }, u: function(j) {
36
+ return j === void 0;
37
37
  } }, J = "en", k = {};
38
- k[J] = Z;
39
- var G = "$isDayjsObject", M = function(v) {
40
- return v instanceof W || !(!v || !v[G]);
41
- }, V = function v(C, z, S) {
42
- var x;
43
- if (!C) return J;
44
- if (typeof C == "string") {
45
- var X = C.toLowerCase();
46
- k[X] && (x = X), z && (k[X] = z, x = X);
47
- var R = C.split("-");
48
- if (!x && R.length > 1) return v(R[0]);
38
+ k[J] = A;
39
+ var G = "$isDayjsObject", M = function(j) {
40
+ return j instanceof C || !(!j || !j[G]);
41
+ }, V = function j(x, q, O) {
42
+ var Z;
43
+ if (!x) return J;
44
+ if (typeof x == "string") {
45
+ var X = x.toLowerCase();
46
+ k[X] && (Z = X), q && (k[X] = q, Z = X);
47
+ var R = x.split("-");
48
+ if (!Z && R.length > 1) return j(R[0]);
49
49
  } else {
50
- var Q = C.name;
51
- k[Q] = C, x = Q;
50
+ var Q = x.name;
51
+ k[Q] = x, Z = Q;
52
52
  }
53
- return !S && x && (J = x), x || !S && J;
54
- }, q = function(v, C) {
55
- if (M(v)) return v.clone();
56
- var z = typeof C == "object" ? C : {};
57
- return z.date = v, z.args = arguments, new W(z);
58
- }, p = w;
59
- p.l = V, p.i = M, p.w = function(v, C) {
60
- return q(v, { locale: C.$L, utc: C.$u, x: C.$x, $offset: C.$offset });
53
+ return !O && Z && (J = Z), Z || !O && J;
54
+ }, S = function(j, x) {
55
+ if (M(j)) return j.clone();
56
+ var q = typeof x == "object" ? x : {};
57
+ return q.date = j, q.args = arguments, new C(q);
58
+ }, m = w;
59
+ m.l = V, m.i = M, m.w = function(j, x) {
60
+ return S(j, { locale: x.$L, utc: x.$u, x: x.$x, $offset: x.$offset });
61
61
  };
62
- var W = function() {
63
- function v(z) {
64
- this.$L = V(z.locale, null, !0), this.parse(z), this.$x = this.$x || z.x || {}, this[G] = !0;
62
+ var C = function() {
63
+ function j(q) {
64
+ this.$L = V(q.locale, null, !0), this.parse(q), this.$x = this.$x || q.x || {}, this[G] = !0;
65
65
  }
66
- var C = v.prototype;
67
- return C.parse = function(z) {
68
- this.$d = function(S) {
69
- var x = S.date, X = S.utc;
70
- if (x === null) return /* @__PURE__ */ new Date(NaN);
71
- if (p.u(x)) return /* @__PURE__ */ new Date();
72
- if (x instanceof Date) return new Date(x);
73
- if (typeof x == "string" && !/Z$/i.test(x)) {
74
- var R = x.match(y);
66
+ var x = j.prototype;
67
+ return x.parse = function(q) {
68
+ this.$d = function(O) {
69
+ var Z = O.date, X = O.utc;
70
+ if (Z === null) return /* @__PURE__ */ new Date(NaN);
71
+ if (m.u(Z)) return /* @__PURE__ */ new Date();
72
+ if (Z instanceof Date) return new Date(Z);
73
+ if (typeof Z == "string" && !/Z$/i.test(Z)) {
74
+ var R = Z.match(y);
75
75
  if (R) {
76
76
  var Q = R[2] - 1 || 0, tn = (R[7] || "0").substring(0, 3);
77
77
  return X ? new Date(Date.UTC(R[1], Q, R[3] || 1, R[4] || 0, R[5] || 0, R[6] || 0, tn)) : new Date(R[1], Q, R[3] || 1, R[4] || 0, R[5] || 0, R[6] || 0, tn);
78
78
  }
79
79
  }
80
- return new Date(x);
81
- }(z), this.init();
82
- }, C.init = function() {
83
- var z = this.$d;
84
- this.$y = z.getFullYear(), this.$M = z.getMonth(), this.$D = z.getDate(), this.$W = z.getDay(), this.$H = z.getHours(), this.$m = z.getMinutes(), this.$s = z.getSeconds(), this.$ms = z.getMilliseconds();
85
- }, C.$utils = function() {
86
- return p;
87
- }, C.isValid = function() {
88
- return this.$d.toString() !== m;
89
- }, C.isSame = function(z, S) {
90
- var x = q(z);
91
- return this.startOf(S) <= x && x <= this.endOf(S);
92
- }, C.isAfter = function(z, S) {
93
- return q(z) < this.startOf(S);
94
- }, C.isBefore = function(z, S) {
95
- return this.endOf(S) < q(z);
96
- }, C.$g = function(z, S, x) {
97
- return p.u(z) ? this[S] : this.set(x, z);
98
- }, C.unix = function() {
80
+ return new Date(Z);
81
+ }(q), this.init();
82
+ }, x.init = function() {
83
+ var q = this.$d;
84
+ this.$y = q.getFullYear(), this.$M = q.getMonth(), this.$D = q.getDate(), this.$W = q.getDay(), this.$H = q.getHours(), this.$m = q.getMinutes(), this.$s = q.getSeconds(), this.$ms = q.getMilliseconds();
85
+ }, x.$utils = function() {
86
+ return m;
87
+ }, x.isValid = function() {
88
+ return this.$d.toString() !== d;
89
+ }, x.isSame = function(q, O) {
90
+ var Z = S(q);
91
+ return this.startOf(O) <= Z && Z <= this.endOf(O);
92
+ }, x.isAfter = function(q, O) {
93
+ return S(q) < this.startOf(O);
94
+ }, x.isBefore = function(q, O) {
95
+ return this.endOf(O) < S(q);
96
+ }, x.$g = function(q, O, Z) {
97
+ return m.u(q) ? this[O] : this.set(Z, q);
98
+ }, x.unix = function() {
99
99
  return Math.floor(this.valueOf() / 1e3);
100
- }, C.valueOf = function() {
100
+ }, x.valueOf = function() {
101
101
  return this.$d.getTime();
102
- }, C.startOf = function(z, S) {
103
- var x = this, X = !!p.u(S) || S, R = p.p(z), Q = function(Qn, mn) {
104
- var Rn = p.w(x.$u ? Date.UTC(x.$y, mn, Qn) : new Date(x.$y, mn, Qn), x);
102
+ }, x.startOf = function(q, O) {
103
+ var Z = this, X = !!m.u(O) || O, R = m.p(q), Q = function(Qn, mn) {
104
+ var Rn = m.w(Z.$u ? Date.UTC(Z.$y, mn, Qn) : new Date(Z.$y, mn, Qn), Z);
105
105
  return X ? Rn : Rn.endOf(u);
106
106
  }, tn = function(Qn, mn) {
107
- return p.w(x.toDate()[Qn].apply(x.toDate("s"), (X ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(mn)), x);
107
+ return m.w(Z.toDate()[Qn].apply(Z.toDate("s"), (X ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(mn)), Z);
108
108
  }, hn = this.$W, an = this.$M, zn = this.$D, oe = "set" + (this.$u ? "UTC" : "");
109
109
  switch (R) {
110
- case d:
110
+ case p:
111
111
  return X ? Q(1, 0) : Q(31, 11);
112
112
  case a:
113
113
  return X ? Q(1, an) : Q(0, an + 1);
@@ -126,76 +126,76 @@ var _t = { exports: {} };
126
126
  default:
127
127
  return this.clone();
128
128
  }
129
- }, C.endOf = function(z) {
130
- return this.startOf(z, !1);
131
- }, C.$set = function(z, S) {
132
- var x, X = p.p(z), R = "set" + (this.$u ? "UTC" : ""), Q = (x = {}, x[u] = R + "Date", x[f] = R + "Date", x[a] = R + "Month", x[d] = R + "FullYear", x[r] = R + "Hours", x[h] = R + "Minutes", x[s] = R + "Seconds", x[l] = R + "Milliseconds", x)[X], tn = X === u ? this.$D + (S - this.$W) : S;
133
- if (X === a || X === d) {
129
+ }, x.endOf = function(q) {
130
+ return this.startOf(q, !1);
131
+ }, x.$set = function(q, O) {
132
+ var Z, X = m.p(q), R = "set" + (this.$u ? "UTC" : ""), Q = (Z = {}, Z[u] = R + "Date", Z[f] = R + "Date", Z[a] = R + "Month", Z[p] = R + "FullYear", Z[r] = R + "Hours", Z[h] = R + "Minutes", Z[s] = R + "Seconds", Z[l] = R + "Milliseconds", Z)[X], tn = X === u ? this.$D + (O - this.$W) : O;
133
+ if (X === a || X === p) {
134
134
  var hn = this.clone().set(f, 1);
135
135
  hn.$d[Q](tn), hn.init(), this.$d = hn.set(f, Math.min(this.$D, hn.daysInMonth())).$d;
136
136
  } else Q && this.$d[Q](tn);
137
137
  return this.init(), this;
138
- }, C.set = function(z, S) {
139
- return this.clone().$set(z, S);
140
- }, C.get = function(z) {
141
- return this[p.p(z)]();
142
- }, C.add = function(z, S) {
143
- var x, X = this;
144
- z = Number(z);
145
- var R = p.p(S), Q = function(an) {
146
- var zn = q(X);
147
- return p.w(zn.date(zn.date() + Math.round(an * z)), X);
138
+ }, x.set = function(q, O) {
139
+ return this.clone().$set(q, O);
140
+ }, x.get = function(q) {
141
+ return this[m.p(q)]();
142
+ }, x.add = function(q, O) {
143
+ var Z, X = this;
144
+ q = Number(q);
145
+ var R = m.p(O), Q = function(an) {
146
+ var zn = S(X);
147
+ return m.w(zn.date(zn.date() + Math.round(an * q)), X);
148
148
  };
149
- if (R === a) return this.set(a, this.$M + z);
150
- if (R === d) return this.set(d, this.$y + z);
149
+ if (R === a) return this.set(a, this.$M + q);
150
+ if (R === p) return this.set(p, this.$y + q);
151
151
  if (R === u) return Q(1);
152
152
  if (R === g) return Q(7);
153
- var tn = (x = {}, x[h] = t, x[r] = o, x[s] = i, x)[R] || 1, hn = this.$d.getTime() + z * tn;
154
- return p.w(hn, this);
155
- }, C.subtract = function(z, S) {
156
- return this.add(-1 * z, S);
157
- }, C.format = function(z) {
158
- var S = this, x = this.$locale();
159
- if (!this.isValid()) return x.invalidDate || m;
160
- var X = z || "YYYY-MM-DDTHH:mm:ssZ", R = p.z(this), Q = this.$H, tn = this.$m, hn = this.$M, an = x.weekdays, zn = x.months, oe = x.meridiem, Bn = function(mn, Rn, fe, Ke) {
161
- return mn && (mn[Rn] || mn(S, X)) || fe[Rn].slice(0, Ke);
153
+ var tn = (Z = {}, Z[h] = t, Z[r] = o, Z[s] = i, Z)[R] || 1, hn = this.$d.getTime() + q * tn;
154
+ return m.w(hn, this);
155
+ }, x.subtract = function(q, O) {
156
+ return this.add(-1 * q, O);
157
+ }, x.format = function(q) {
158
+ var O = this, Z = this.$locale();
159
+ if (!this.isValid()) return Z.invalidDate || d;
160
+ var X = q || "YYYY-MM-DDTHH:mm:ssZ", R = m.z(this), Q = this.$H, tn = this.$m, hn = this.$M, an = Z.weekdays, zn = Z.months, oe = Z.meridiem, Bn = function(mn, Rn, fe, Ke) {
161
+ return mn && (mn[Rn] || mn(O, X)) || fe[Rn].slice(0, Ke);
162
162
  }, pe = function(mn) {
163
- return p.s(Q % 12 || 12, mn, "0");
163
+ return m.s(Q % 12 || 12, mn, "0");
164
164
  }, Qn = oe || function(mn, Rn, fe) {
165
165
  var Ke = mn < 12 ? "AM" : "PM";
166
166
  return fe ? Ke.toLowerCase() : Ke;
167
167
  };
168
- return X.replace(j, function(mn, Rn) {
168
+ return X.replace(b, function(mn, Rn) {
169
169
  return Rn || function(fe) {
170
170
  switch (fe) {
171
171
  case "YY":
172
- return String(S.$y).slice(-2);
172
+ return String(O.$y).slice(-2);
173
173
  case "YYYY":
174
- return p.s(S.$y, 4, "0");
174
+ return m.s(O.$y, 4, "0");
175
175
  case "M":
176
176
  return hn + 1;
177
177
  case "MM":
178
- return p.s(hn + 1, 2, "0");
178
+ return m.s(hn + 1, 2, "0");
179
179
  case "MMM":
180
- return Bn(x.monthsShort, hn, zn, 3);
180
+ return Bn(Z.monthsShort, hn, zn, 3);
181
181
  case "MMMM":
182
182
  return Bn(zn, hn);
183
183
  case "D":
184
- return S.$D;
184
+ return O.$D;
185
185
  case "DD":
186
- return p.s(S.$D, 2, "0");
186
+ return m.s(O.$D, 2, "0");
187
187
  case "d":
188
- return String(S.$W);
188
+ return String(O.$W);
189
189
  case "dd":
190
- return Bn(x.weekdaysMin, S.$W, an, 2);
190
+ return Bn(Z.weekdaysMin, O.$W, an, 2);
191
191
  case "ddd":
192
- return Bn(x.weekdaysShort, S.$W, an, 3);
192
+ return Bn(Z.weekdaysShort, O.$W, an, 3);
193
193
  case "dddd":
194
- return an[S.$W];
194
+ return an[O.$W];
195
195
  case "H":
196
196
  return String(Q);
197
197
  case "HH":
198
- return p.s(Q, 2, "0");
198
+ return m.s(Q, 2, "0");
199
199
  case "h":
200
200
  return pe(1);
201
201
  case "hh":
@@ -207,27 +207,27 @@ var _t = { exports: {} };
207
207
  case "m":
208
208
  return String(tn);
209
209
  case "mm":
210
- return p.s(tn, 2, "0");
210
+ return m.s(tn, 2, "0");
211
211
  case "s":
212
- return String(S.$s);
212
+ return String(O.$s);
213
213
  case "ss":
214
- return p.s(S.$s, 2, "0");
214
+ return m.s(O.$s, 2, "0");
215
215
  case "SSS":
216
- return p.s(S.$ms, 3, "0");
216
+ return m.s(O.$ms, 3, "0");
217
217
  case "Z":
218
218
  return R;
219
219
  }
220
220
  return null;
221
221
  }(mn) || R.replace(":", "");
222
222
  });
223
- }, C.utcOffset = function() {
223
+ }, x.utcOffset = function() {
224
224
  return 15 * -Math.round(this.$d.getTimezoneOffset() / 15);
225
- }, C.diff = function(z, S, x) {
226
- var X, R = this, Q = p.p(S), tn = q(z), hn = (tn.utcOffset() - this.utcOffset()) * t, an = this - tn, zn = function() {
227
- return p.m(R, tn);
225
+ }, x.diff = function(q, O, Z) {
226
+ var X, R = this, Q = m.p(O), tn = S(q), hn = (tn.utcOffset() - this.utcOffset()) * t, an = this - tn, zn = function() {
227
+ return m.m(R, tn);
228
228
  };
229
229
  switch (Q) {
230
- case d:
230
+ case p:
231
231
  X = zn() / 12;
232
232
  break;
233
233
  case a:
@@ -254,36 +254,36 @@ var _t = { exports: {} };
254
254
  default:
255
255
  X = an;
256
256
  }
257
- return x ? X : p.a(X);
258
- }, C.daysInMonth = function() {
257
+ return Z ? X : m.a(X);
258
+ }, x.daysInMonth = function() {
259
259
  return this.endOf(a).$D;
260
- }, C.$locale = function() {
260
+ }, x.$locale = function() {
261
261
  return k[this.$L];
262
- }, C.locale = function(z, S) {
263
- if (!z) return this.$L;
264
- var x = this.clone(), X = V(z, S, !0);
265
- return X && (x.$L = X), x;
266
- }, C.clone = function() {
267
- return p.w(this.$d, this);
268
- }, C.toDate = function() {
262
+ }, x.locale = function(q, O) {
263
+ if (!q) return this.$L;
264
+ var Z = this.clone(), X = V(q, O, !0);
265
+ return X && (Z.$L = X), Z;
266
+ }, x.clone = function() {
267
+ return m.w(this.$d, this);
268
+ }, x.toDate = function() {
269
269
  return new Date(this.valueOf());
270
- }, C.toJSON = function() {
270
+ }, x.toJSON = function() {
271
271
  return this.isValid() ? this.toISOString() : null;
272
- }, C.toISOString = function() {
272
+ }, x.toISOString = function() {
273
273
  return this.$d.toISOString();
274
- }, C.toString = function() {
274
+ }, x.toString = function() {
275
275
  return this.$d.toUTCString();
276
- }, v;
277
- }(), O = W.prototype;
278
- return q.prototype = O, [["$ms", l], ["$s", s], ["$m", h], ["$H", r], ["$W", u], ["$M", a], ["$y", d], ["$D", f]].forEach(function(v) {
279
- O[v[1]] = function(C) {
280
- return this.$g(C, v[0], v[1]);
276
+ }, j;
277
+ }(), W = C.prototype;
278
+ return S.prototype = W, [["$ms", l], ["$s", s], ["$m", h], ["$H", r], ["$W", u], ["$M", a], ["$y", p], ["$D", f]].forEach(function(j) {
279
+ W[j[1]] = function(x) {
280
+ return this.$g(x, j[0], j[1]);
281
281
  };
282
- }), q.extend = function(v, C) {
283
- return v.$i || (v(C, W, q), v.$i = !0), q;
284
- }, q.locale = V, q.isDayjs = M, q.unix = function(v) {
285
- return q(1e3 * v);
286
- }, q.en = k[J], q.Ls = k, q.p = {}, q;
282
+ }), S.extend = function(j, x) {
283
+ return j.$i || (j(x, C, S), j.$i = !0), S;
284
+ }, S.locale = V, S.isDayjs = M, S.unix = function(j) {
285
+ return S(1e3 * j);
286
+ }, S.en = k[J], S.Ls = k, S.p = {}, S;
287
287
  });
288
288
  })(_t);
289
289
  var Pl = _t.exports;
@@ -296,51 +296,51 @@ var no = { exports: {} };
296
296
  var i = "minute", t = /[+-]\d\d(?::?\d\d)?/g, o = /([+-]|\d\d)/g;
297
297
  return function(l, s, h) {
298
298
  var r = s.prototype;
299
- h.utc = function(m) {
300
- var y = { date: m, utc: !0, args: arguments };
299
+ h.utc = function(d) {
300
+ var y = { date: d, utc: !0, args: arguments };
301
301
  return new s(y);
302
- }, r.utc = function(m) {
302
+ }, r.utc = function(d) {
303
303
  var y = h(this.toDate(), { locale: this.$L, utc: !0 });
304
- return m ? y.add(this.utcOffset(), i) : y;
304
+ return d ? y.add(this.utcOffset(), i) : y;
305
305
  }, r.local = function() {
306
306
  return h(this.toDate(), { locale: this.$L, utc: !1 });
307
307
  };
308
308
  var u = r.parse;
309
- r.parse = function(m) {
310
- m.utc && (this.$u = !0), this.$utils().u(m.$offset) || (this.$offset = m.$offset), u.call(this, m);
309
+ r.parse = function(d) {
310
+ d.utc && (this.$u = !0), this.$utils().u(d.$offset) || (this.$offset = d.$offset), u.call(this, d);
311
311
  };
312
312
  var g = r.init;
313
313
  r.init = function() {
314
314
  if (this.$u) {
315
- var m = this.$d;
316
- this.$y = m.getUTCFullYear(), this.$M = m.getUTCMonth(), this.$D = m.getUTCDate(), this.$W = m.getUTCDay(), this.$H = m.getUTCHours(), this.$m = m.getUTCMinutes(), this.$s = m.getUTCSeconds(), this.$ms = m.getUTCMilliseconds();
315
+ var d = this.$d;
316
+ this.$y = d.getUTCFullYear(), this.$M = d.getUTCMonth(), this.$D = d.getUTCDate(), this.$W = d.getUTCDay(), this.$H = d.getUTCHours(), this.$m = d.getUTCMinutes(), this.$s = d.getUTCSeconds(), this.$ms = d.getUTCMilliseconds();
317
317
  } else g.call(this);
318
318
  };
319
319
  var a = r.utcOffset;
320
- r.utcOffset = function(m, y) {
321
- var j = this.$utils().u;
322
- if (j(m)) return this.$u ? 0 : j(this.$offset) ? a.call(this) : this.$offset;
323
- if (typeof m == "string" && (m = function(J) {
320
+ r.utcOffset = function(d, y) {
321
+ var b = this.$utils().u;
322
+ if (b(d)) return this.$u ? 0 : b(this.$offset) ? a.call(this) : this.$offset;
323
+ if (typeof d == "string" && (d = function(J) {
324
324
  J === void 0 && (J = "");
325
325
  var k = J.match(t);
326
326
  if (!k) return null;
327
327
  var G = ("" + k[0]).match(o) || ["-", 0, 0], M = G[0], V = 60 * +G[1] + +G[2];
328
328
  return V === 0 ? 0 : M === "+" ? V : -V;
329
- }(m), m === null)) return this;
330
- var Z = Math.abs(m) <= 16 ? 60 * m : m;
331
- if (Z === 0) return this.utc(y);
329
+ }(d), d === null)) return this;
330
+ var A = Math.abs(d) <= 16 ? 60 * d : d;
331
+ if (A === 0) return this.utc(y);
332
332
  var I = this.clone();
333
- if (y) return I.$offset = Z, I.$u = !1, I;
333
+ if (y) return I.$offset = A, I.$u = !1, I;
334
334
  var w = this.$u ? this.toDate().getTimezoneOffset() : -1 * this.utcOffset();
335
- return (I = this.local().add(Z + w, i)).$offset = Z, I.$x.$localOffset = w, I;
335
+ return (I = this.local().add(A + w, i)).$offset = A, I.$x.$localOffset = w, I;
336
336
  };
337
337
  var c = r.format;
338
- r.format = function(m) {
339
- var y = m || (this.$u ? "YYYY-MM-DDTHH:mm:ss[Z]" : "");
338
+ r.format = function(d) {
339
+ var y = d || (this.$u ? "YYYY-MM-DDTHH:mm:ss[Z]" : "");
340
340
  return c.call(this, y);
341
341
  }, r.valueOf = function() {
342
- var m = this.$utils().u(this.$offset) ? 0 : this.$offset + (this.$x.$localOffset || this.$d.getTimezoneOffset());
343
- return this.$d.valueOf() - 6e4 * m;
342
+ var d = this.$utils().u(this.$offset) ? 0 : this.$offset + (this.$x.$localOffset || this.$d.getTimezoneOffset());
343
+ return this.$d.valueOf() - 6e4 * d;
344
344
  }, r.isUTC = function() {
345
345
  return !!this.$u;
346
346
  }, r.toISOString = function() {
@@ -348,15 +348,15 @@ var no = { exports: {} };
348
348
  }, r.toString = function() {
349
349
  return this.toDate().toUTCString();
350
350
  };
351
- var d = r.toDate;
352
- r.toDate = function(m) {
353
- return m === "s" && this.$offset ? h(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate() : d.call(this);
351
+ var p = r.toDate;
352
+ r.toDate = function(d) {
353
+ return d === "s" && this.$offset ? h(this.format("YYYY-MM-DD HH:mm:ss:SSS")).toDate() : p.call(this);
354
354
  };
355
355
  var f = r.diff;
356
- r.diff = function(m, y, j) {
357
- if (m && this.$u === m.$u) return f.call(this, m, y, j);
358
- var Z = this.local(), I = h(m).local();
359
- return f.call(Z, I, y, j);
356
+ r.diff = function(d, y, b) {
357
+ if (d && this.$u === d.$u) return f.call(this, d, y, b);
358
+ var A = this.local(), I = h(d).local();
359
+ return f.call(A, I, y, b);
360
360
  };
361
361
  };
362
362
  });
@@ -557,7 +557,7 @@ const Hn = (e) => {
557
557
  Nt((a) => ({
558
558
  v6cd858ea: u.value,
559
559
  v4f17a402: g.value,
560
- v6f0655b0: b(t)
560
+ v6f0655b0: z(t)
561
561
  }));
562
562
  const n = e, { size: i, color: t, name: o, prefix: l } = ki(n), h = Object.entries(/* @__PURE__ */ Object.assign({
563
563
  "../../assets/icons-component/icon-component-clear.svg": ds,
@@ -598,10 +598,10 @@ const Hn = (e) => {
598
598
  "../../assets/icons-editor/editor-time.svg": Es,
599
599
  "../../assets/icons-editor/editor-upload.svg": Ds
600
600
  })).reduce(
601
- (a, [c, d]) => {
602
- var m;
603
- const f = (m = c.split("/").pop()) == null ? void 0 : m.replace(/\.svg$/, "");
604
- return f && (a[f] = d), a;
601
+ (a, [c, p]) => {
602
+ var d;
603
+ const f = (d = c.split("/").pop()) == null ? void 0 : d.replace(/\.svg$/, "");
604
+ return f && (a[f] = p), a;
605
605
  },
606
606
  {}
607
607
  ), r = T(() => (h[o.value] ?? h[`${l.value}-${o.value}`] ?? "").replace("<svg", '<svg fill="currentColor"')), u = T(() => Ai(i.value) ? "1em" : Hn(vi(i.value) ? i.value[0] : i.value)), g = T(() => Ai(i.value) ? "1em" : Hn(vi(i.value) ? i.value[1] : i.value));
@@ -627,7 +627,7 @@ const Hn = (e) => {
627
627
  },
628
628
  setup(e) {
629
629
  const { renderSlots: n } = cs(["default", "icon"]);
630
- return (i, t) => (Y(), _(b(Ol), zl({
630
+ return (i, t) => (Y(), _(z(Ol), zl({
631
631
  class: [
632
632
  {
633
633
  "cx-button-link": e.link
@@ -635,8 +635,8 @@ const Hn = (e) => {
635
635
  ]
636
636
  }, i.$attrs, { size: "large" }), bl({
637
637
  loading: N(() => [
638
- A("i", _s, [
639
- H(b(rn), {
638
+ v("i", _s, [
639
+ H(z(rn), {
640
640
  name: "icon-component-loading",
641
641
  size: "18px"
642
642
  })
@@ -644,7 +644,7 @@ const Hn = (e) => {
644
644
  ]),
645
645
  _: 2
646
646
  }, [
647
- gn(b(n), (o) => ({
647
+ gn(z(n), (o) => ({
648
648
  name: o,
649
649
  fn: N((l) => [
650
650
  wn(i.$slots, o, jl(vl(l || {})), void 0, !0)
@@ -661,20 +661,20 @@ const Hn = (e) => {
661
661
  },
662
662
  setup(e) {
663
663
  return (n, i) => (Y(), L("div", ih, [
664
- A("div", {
664
+ v("div", {
665
665
  style: he({
666
- width: b(Hn)(e.size),
667
- height: b(Hn)(e.size)
666
+ width: z(Hn)(e.size),
667
+ height: z(Hn)(e.size)
668
668
  }),
669
669
  class: "cx-empty-icon"
670
670
  }, [
671
671
  wn(n.$slots, "icon", {}, () => [
672
- A("img", {
673
- src: e.type === "normal" ? b(nh) : b(eh)
672
+ v("img", {
673
+ src: e.type === "normal" ? z(nh) : z(eh)
674
674
  }, null, 8, th)
675
675
  ], !0)
676
676
  ], 4),
677
- A("div", oh, F(e.description), 1)
677
+ v("div", oh, F(e.description), 1)
678
678
  ]));
679
679
  }
680
680
  }), sh = /* @__PURE__ */ sn(lh, [["__scopeId", "data-v-56b17ee0"]]);
@@ -698,7 +698,7 @@ function Fe() {
698
698
  };
699
699
  }
700
700
  function nn(e) {
701
- return typeof e == "function" ? e() : b(e);
701
+ return typeof e == "function" ? e() : z(e);
702
702
  }
703
703
  const Ye = typeof window < "u" && typeof document < "u";
704
704
  typeof WorkerGlobalScope < "u" && globalThis instanceof WorkerGlobalScope;
@@ -791,14 +791,14 @@ function lt(e, n, i = {}) {
791
791
  { ...o, flush: "sync" }
792
792
  )
793
793
  ), s = (c) => {
794
- const d = a.value;
795
- c(), g.value += a.value - d;
794
+ const p = a.value;
795
+ c(), g.value += a.value - p;
796
796
  }, u.push(
797
797
  cn(
798
798
  e,
799
799
  (...c) => {
800
- const d = g.value > 0 && g.value === a.value;
801
- g.value = 0, a.value = 0, !d && l(...c);
800
+ const p = g.value > 0 && g.value === a.value;
801
+ g.value = 0, a.value = 0, !p && l(...c);
802
802
  },
803
803
  o
804
804
  )
@@ -821,14 +821,14 @@ function E(...e) {
821
821
  Array.isArray(i) || (i = [i]), Array.isArray(t) || (t = [t]);
822
822
  const l = [], s = () => {
823
823
  l.forEach((g) => g()), l.length = 0;
824
- }, h = (g, a, c, d) => (g.addEventListener(a, c, d), () => g.removeEventListener(a, c, d)), r = cn(
824
+ }, h = (g, a, c, p) => (g.addEventListener(a, c, p), () => g.removeEventListener(a, c, p)), r = cn(
825
825
  () => [$n(n), nn(o)],
826
826
  ([g, a]) => {
827
827
  if (s(), !g)
828
828
  return;
829
829
  const c = so(a) ? { ...a } : a;
830
830
  l.push(
831
- ...i.flatMap((d) => t.map((f) => h(g, d, f, c)))
831
+ ...i.flatMap((p) => t.map((f) => h(g, p, f, c)))
832
832
  );
833
833
  },
834
834
  { immediate: !0, flush: "post" }
@@ -884,25 +884,25 @@ function yh(e = {}) {
884
884
  copiedDuring: o = 1500,
885
885
  legacy: l = !1
886
886
  } = e, s = Ji(() => n && "clipboard" in n), h = st("clipboard-read"), r = st("clipboard-write"), u = T(() => s.value || l), g = K(""), a = K(!1), c = ph(() => a.value = !1, o);
887
- function d() {
888
- s.value && j(h.value) ? n.clipboard.readText().then((Z) => {
889
- g.value = Z;
887
+ function p() {
888
+ s.value && b(h.value) ? n.clipboard.readText().then((A) => {
889
+ g.value = A;
890
890
  }) : g.value = y();
891
891
  }
892
- u.value && i && E(["copy", "cut"], d);
893
- async function f(Z = nn(t)) {
894
- u.value && Z != null && (s.value && j(r.value) ? await n.clipboard.writeText(Z) : m(Z), g.value = Z, a.value = !0, c.start());
892
+ u.value && i && E(["copy", "cut"], p);
893
+ async function f(A = nn(t)) {
894
+ u.value && A != null && (s.value && b(r.value) ? await n.clipboard.writeText(A) : d(A), g.value = A, a.value = !0, c.start());
895
895
  }
896
- function m(Z) {
896
+ function d(A) {
897
897
  const I = document.createElement("textarea");
898
- I.value = Z ?? "", I.style.position = "absolute", I.style.opacity = "0", document.body.appendChild(I), I.select(), document.execCommand("copy"), I.remove();
898
+ I.value = A ?? "", I.style.position = "absolute", I.style.opacity = "0", document.body.appendChild(I), I.select(), document.execCommand("copy"), I.remove();
899
899
  }
900
900
  function y() {
901
- var Z, I, w;
902
- return (w = (I = (Z = document == null ? void 0 : document.getSelection) == null ? void 0 : Z.call(document)) == null ? void 0 : I.toString()) != null ? w : "";
901
+ var A, I, w;
902
+ return (w = (I = (A = document == null ? void 0 : document.getSelection) == null ? void 0 : A.call(document)) == null ? void 0 : I.toString()) != null ? w : "";
903
903
  }
904
- function j(Z) {
905
- return Z === "granted" || Z === "prompt";
904
+ function b(A) {
905
+ return A === "granted" || A === "prompt";
906
906
  }
907
907
  return {
908
908
  isSupported: u,
@@ -916,44 +916,44 @@ function qh(e, n = {}) {
916
916
  const o = K(!1), l = zi(null);
917
917
  let s = 0, h = !0;
918
918
  if (Ye) {
919
- const r = typeof n == "function" ? { onDrop: n } : n, u = (i = r.multiple) != null ? i : !0, g = (t = r.preventDefaultForUnhandled) != null ? t : !1, a = (m) => {
920
- var y, j;
921
- const Z = Array.from((j = (y = m.dataTransfer) == null ? void 0 : y.files) != null ? j : []);
922
- return Z.length === 0 ? null : u ? Z : [Z[0]];
923
- }, c = (m) => {
919
+ const r = typeof n == "function" ? { onDrop: n } : n, u = (i = r.multiple) != null ? i : !0, g = (t = r.preventDefaultForUnhandled) != null ? t : !1, a = (d) => {
920
+ var y, b;
921
+ const A = Array.from((b = (y = d.dataTransfer) == null ? void 0 : y.files) != null ? b : []);
922
+ return A.length === 0 ? null : u ? A : [A[0]];
923
+ }, c = (d) => {
924
924
  if (r.dataTypes) {
925
- const y = b(r.dataTypes);
926
- return typeof y == "function" ? y(m) : y ? y.some((j) => m.includes(j)) : !0;
925
+ const y = z(r.dataTypes);
926
+ return typeof y == "function" ? y(d) : y ? y.some((b) => d.includes(b)) : !0;
927
927
  }
928
928
  return !0;
929
- }, d = (m) => {
930
- var y, j;
931
- const Z = Array.from((j = (y = m.dataTransfer) == null ? void 0 : y.items) != null ? j : []), I = Z.map((k) => k.type), w = c(I), J = u || Z.length <= 1;
929
+ }, p = (d) => {
930
+ var y, b;
931
+ const A = Array.from((b = (y = d.dataTransfer) == null ? void 0 : y.items) != null ? b : []), I = A.map((k) => k.type), w = c(I), J = u || A.length <= 1;
932
932
  return w && J;
933
- }, f = (m, y) => {
934
- var j, Z, I, w;
935
- if (h = d(m), !h) {
936
- g && m.preventDefault(), m.dataTransfer && (m.dataTransfer.dropEffect = "none");
933
+ }, f = (d, y) => {
934
+ var b, A, I, w;
935
+ if (h = p(d), !h) {
936
+ g && d.preventDefault(), d.dataTransfer && (d.dataTransfer.dropEffect = "none");
937
937
  return;
938
938
  }
939
- m.preventDefault(), m.dataTransfer && (m.dataTransfer.dropEffect = "copy");
940
- const J = a(m);
939
+ d.preventDefault(), d.dataTransfer && (d.dataTransfer.dropEffect = "copy");
940
+ const J = a(d);
941
941
  switch (y) {
942
942
  case "enter":
943
- s += 1, o.value = !0, (j = r.onEnter) == null || j.call(r, null, m);
943
+ s += 1, o.value = !0, (b = r.onEnter) == null || b.call(r, null, d);
944
944
  break;
945
945
  case "over":
946
- (Z = r.onOver) == null || Z.call(r, null, m);
946
+ (A = r.onOver) == null || A.call(r, null, d);
947
947
  break;
948
948
  case "leave":
949
- s -= 1, s === 0 && (o.value = !1), (I = r.onLeave) == null || I.call(r, null, m);
949
+ s -= 1, s === 0 && (o.value = !1), (I = r.onLeave) == null || I.call(r, null, d);
950
950
  break;
951
951
  case "drop":
952
- s = 0, o.value = !1, h && (l.value = J, (w = r.onDrop) == null || w.call(r, J, m));
952
+ s = 0, o.value = !1, h && (l.value = J, (w = r.onDrop) == null || w.call(r, J, d));
953
953
  break;
954
954
  }
955
955
  };
956
- E(e, "dragenter", (m) => f(m, "enter")), E(e, "dragover", (m) => f(m, "over")), E(e, "dragleave", (m) => f(m, "leave")), E(e, "drop", (m) => f(m, "drop"));
956
+ E(e, "dragenter", (d) => f(d, "enter")), E(e, "dragover", (d) => f(d, "over")), E(e, "dragleave", (d) => f(d, "leave")), E(e, "drop", (d) => f(d, "drop"));
957
957
  }
958
958
  return {
959
959
  files: l,
@@ -995,14 +995,14 @@ function zh(e, n = { width: 0, height: 0 }, i = {}) {
995
995
  ([a]) => {
996
996
  const c = o === "border-box" ? a.borderBoxSize : o === "content-box" ? a.contentBoxSize : a.devicePixelContentBoxSize;
997
997
  if (t && l.value) {
998
- const d = $n(e);
999
- if (d) {
1000
- const f = d.getBoundingClientRect();
998
+ const p = $n(e);
999
+ if (p) {
1000
+ const f = p.getBoundingClientRect();
1001
1001
  s.value = f.width, h.value = f.height;
1002
1002
  }
1003
1003
  } else if (c) {
1004
- const d = Array.isArray(c) ? c : [c];
1005
- s.value = d.reduce((f, { inlineSize: m }) => f + m, 0), h.value = d.reduce((f, { blockSize: m }) => f + m, 0);
1004
+ const p = Array.isArray(c) ? c : [c];
1005
+ s.value = p.reduce((f, { inlineSize: d }) => f + d, 0), h.value = p.reduce((f, { blockSize: d }) => f + d, 0);
1006
1006
  } else
1007
1007
  s.value = a.contentRect.width, h.value = a.contentRect.height;
1008
1008
  },
@@ -1116,83 +1116,83 @@ function xh(e, n = {}) {
1116
1116
  };
1117
1117
  const {
1118
1118
  document: i = ro
1119
- } = n, t = K(0), o = K(0), l = K(!1), s = K(1), h = K(!1), r = K(!1), u = K(!1), g = K(1), a = K(!1), c = K([]), d = K([]), f = K(-1), m = K(!1), y = K(!1), j = i && "pictureInPictureEnabled" in i, Z = Fe(), I = Fe(), w = (p) => {
1120
- si(e, (W) => {
1121
- if (p) {
1122
- const O = typeof p == "number" ? p : p.id;
1123
- W.textTracks[O].mode = "disabled";
1119
+ } = n, t = K(0), o = K(0), l = K(!1), s = K(1), h = K(!1), r = K(!1), u = K(!1), g = K(1), a = K(!1), c = K([]), p = K([]), f = K(-1), d = K(!1), y = K(!1), b = i && "pictureInPictureEnabled" in i, A = Fe(), I = Fe(), w = (m) => {
1120
+ si(e, (C) => {
1121
+ if (m) {
1122
+ const W = typeof m == "number" ? m : m.id;
1123
+ C.textTracks[W].mode = "disabled";
1124
1124
  } else
1125
- for (let O = 0; O < W.textTracks.length; ++O)
1126
- W.textTracks[O].mode = "disabled";
1125
+ for (let W = 0; W < C.textTracks.length; ++W)
1126
+ C.textTracks[W].mode = "disabled";
1127
1127
  f.value = -1;
1128
1128
  });
1129
- }, J = (p, W = !0) => {
1130
- si(e, (O) => {
1131
- const v = typeof p == "number" ? p : p.id;
1132
- W && w(), O.textTracks[v].mode = "showing", f.value = v;
1129
+ }, J = (m, C = !0) => {
1130
+ si(e, (W) => {
1131
+ const j = typeof m == "number" ? m : m.id;
1132
+ C && w(), W.textTracks[j].mode = "showing", f.value = j;
1133
1133
  });
1134
- }, k = () => new Promise((p, W) => {
1135
- si(e, async (O) => {
1136
- j && (m.value ? i.exitPictureInPicture().then(p).catch(W) : O.requestPictureInPicture().then(p).catch(W));
1134
+ }, k = () => new Promise((m, C) => {
1135
+ si(e, async (W) => {
1136
+ b && (d.value ? i.exitPictureInPicture().then(m).catch(C) : W.requestPictureInPicture().then(m).catch(C));
1137
1137
  });
1138
1138
  });
1139
1139
  $i(() => {
1140
1140
  if (!i)
1141
1141
  return;
1142
- const p = nn(e);
1143
- if (!p)
1142
+ const m = nn(e);
1143
+ if (!m)
1144
1144
  return;
1145
- const W = nn(n.src);
1146
- let O = [];
1147
- W && (typeof W == "string" ? O = [{ src: W }] : Array.isArray(W) ? O = W : so(W) && (O = [W]), p.querySelectorAll("source").forEach((v) => {
1148
- v.removeEventListener("error", Z.trigger), v.remove();
1149
- }), O.forEach(({ src: v, type: C }) => {
1150
- const z = i.createElement("source");
1151
- z.setAttribute("src", v), z.setAttribute("type", C || ""), z.addEventListener("error", Z.trigger), p.appendChild(z);
1152
- }), p.load());
1145
+ const C = nn(n.src);
1146
+ let W = [];
1147
+ C && (typeof C == "string" ? W = [{ src: C }] : Array.isArray(C) ? W = C : so(C) && (W = [C]), m.querySelectorAll("source").forEach((j) => {
1148
+ j.removeEventListener("error", A.trigger), j.remove();
1149
+ }), W.forEach(({ src: j, type: x }) => {
1150
+ const q = i.createElement("source");
1151
+ q.setAttribute("src", j), q.setAttribute("type", x || ""), q.addEventListener("error", A.trigger), m.appendChild(q);
1152
+ }), m.load());
1153
1153
  }), ge(() => {
1154
- const p = nn(e);
1155
- p && p.querySelectorAll("source").forEach((W) => W.removeEventListener("error", Z.trigger));
1154
+ const m = nn(e);
1155
+ m && m.querySelectorAll("source").forEach((C) => C.removeEventListener("error", A.trigger));
1156
1156
  }), cn([e, s], () => {
1157
- const p = nn(e);
1158
- p && (p.volume = s.value);
1157
+ const m = nn(e);
1158
+ m && (m.volume = s.value);
1159
1159
  }), cn([e, y], () => {
1160
- const p = nn(e);
1161
- p && (p.muted = y.value);
1160
+ const m = nn(e);
1161
+ m && (m.muted = y.value);
1162
1162
  }), cn([e, g], () => {
1163
- const p = nn(e);
1164
- p && (p.playbackRate = g.value);
1163
+ const m = nn(e);
1164
+ m && (m.playbackRate = g.value);
1165
1165
  }), $i(() => {
1166
1166
  if (!i)
1167
1167
  return;
1168
- const p = nn(n.tracks), W = nn(e);
1169
- !p || !p.length || !W || (W.querySelectorAll("track").forEach((O) => O.remove()), p.forEach(({ default: O, kind: v, label: C, src: z, srcLang: S }, x) => {
1168
+ const m = nn(n.tracks), C = nn(e);
1169
+ !m || !m.length || !C || (C.querySelectorAll("track").forEach((W) => W.remove()), m.forEach(({ default: W, kind: j, label: x, src: q, srcLang: O }, Z) => {
1170
1170
  const X = i.createElement("track");
1171
- X.default = O || !1, X.kind = v, X.label = C, X.src = z, X.srclang = S, X.default && (f.value = x), W.appendChild(X);
1171
+ X.default = W || !1, X.kind = j, X.label = x, X.src = q, X.srclang = O, X.default && (f.value = Z), C.appendChild(X);
1172
1172
  }));
1173
1173
  });
1174
- const { ignoreUpdates: G } = lt(t, (p) => {
1175
- const W = nn(e);
1176
- W && (W.currentTime = p);
1177
- }), { ignoreUpdates: M } = lt(u, (p) => {
1178
- const W = nn(e);
1179
- W && (p ? W.play().catch((O) => {
1180
- throw I.trigger(O), O;
1181
- }) : W.pause());
1174
+ const { ignoreUpdates: G } = lt(t, (m) => {
1175
+ const C = nn(e);
1176
+ C && (C.currentTime = m);
1177
+ }), { ignoreUpdates: M } = lt(u, (m) => {
1178
+ const C = nn(e);
1179
+ C && (m ? C.play().catch((W) => {
1180
+ throw I.trigger(W), W;
1181
+ }) : C.pause());
1182
1182
  });
1183
1183
  E(e, "timeupdate", () => G(() => t.value = nn(e).currentTime)), E(e, "durationchange", () => o.value = nn(e).duration), E(e, "progress", () => c.value = Ah(nn(e).buffered)), E(e, "seeking", () => l.value = !0), E(e, "seeked", () => l.value = !1), E(e, ["waiting", "loadstart"], () => {
1184
1184
  h.value = !0, M(() => u.value = !1);
1185
1185
  }), E(e, "loadeddata", () => h.value = !1), E(e, "playing", () => {
1186
1186
  h.value = !1, r.value = !1, M(() => u.value = !0);
1187
- }), E(e, "ratechange", () => g.value = nn(e).playbackRate), E(e, "stalled", () => a.value = !0), E(e, "ended", () => r.value = !0), E(e, "pause", () => M(() => u.value = !1)), E(e, "play", () => M(() => u.value = !0)), E(e, "enterpictureinpicture", () => m.value = !0), E(e, "leavepictureinpicture", () => m.value = !1), E(e, "volumechange", () => {
1188
- const p = nn(e);
1189
- p && (s.value = p.volume, y.value = p.muted);
1187
+ }), E(e, "ratechange", () => g.value = nn(e).playbackRate), E(e, "stalled", () => a.value = !0), E(e, "ended", () => r.value = !0), E(e, "pause", () => M(() => u.value = !1)), E(e, "play", () => M(() => u.value = !0)), E(e, "enterpictureinpicture", () => d.value = !0), E(e, "leavepictureinpicture", () => d.value = !1), E(e, "volumechange", () => {
1188
+ const m = nn(e);
1189
+ m && (s.value = m.volume, y.value = m.muted);
1190
1190
  });
1191
- const V = [], q = cn([e], () => {
1192
- const p = nn(e);
1193
- p && (q(), V[0] = E(p.textTracks, "addtrack", () => d.value = hi(p.textTracks)), V[1] = E(p.textTracks, "removetrack", () => d.value = hi(p.textTracks)), V[2] = E(p.textTracks, "change", () => d.value = hi(p.textTracks)));
1191
+ const V = [], S = cn([e], () => {
1192
+ const m = nn(e);
1193
+ m && (S(), V[0] = E(m.textTracks, "addtrack", () => p.value = hi(m.textTracks)), V[1] = E(m.textTracks, "removetrack", () => p.value = hi(m.textTracks)), V[2] = E(m.textTracks, "change", () => p.value = hi(m.textTracks)));
1194
1194
  });
1195
- return ge(() => V.forEach((p) => p())), {
1195
+ return ge(() => V.forEach((m) => m())), {
1196
1196
  currentTime: t,
1197
1197
  duration: o,
1198
1198
  waiting: h,
@@ -1206,16 +1206,16 @@ function xh(e, n = {}) {
1206
1206
  volume: s,
1207
1207
  muted: y,
1208
1208
  // Tracks
1209
- tracks: d,
1209
+ tracks: p,
1210
1210
  selectedTrack: f,
1211
1211
  enableTrack: J,
1212
1212
  disableTrack: w,
1213
1213
  // Picture in Picture
1214
- supportsPictureInPicture: j,
1214
+ supportsPictureInPicture: b,
1215
1215
  togglePictureInPicture: k,
1216
- isPictureInPicture: m,
1216
+ isPictureInPicture: d,
1217
1217
  // Events
1218
- onSourceError: Z.on,
1218
+ onSourceError: A.on,
1219
1219
  onPlaybackError: I.on
1220
1220
  };
1221
1221
  }
@@ -1239,72 +1239,72 @@ const Ch = { class: "cx-radio-group" }, Ih = ["onClick"], Wh = {
1239
1239
  },
1240
1240
  emits: ["update:modelValue", "change"],
1241
1241
  setup(e, { emit: n }) {
1242
- Nt((m) => ({
1243
- v74036a63: m.background,
1244
- v41a8ae01: m.activeBackgound,
1245
- c15225e4: m.color,
1246
- v9294f916: b(h),
1247
- v5c0c1e88: b(r),
1248
- v69c0c568: m.activeColor
1242
+ Nt((d) => ({
1243
+ v74036a63: d.background,
1244
+ v41a8ae01: d.activeBackgound,
1245
+ c15225e4: d.color,
1246
+ v9294f916: z(h),
1247
+ v5c0c1e88: z(r),
1248
+ v69c0c568: d.activeColor
1249
1249
  }));
1250
1250
  const i = e, t = n, { modelValue: o, defaultValue: l, options: s, hoverBackground: h, hoverColor: r } = ki(i), u = lo(
1251
1251
  o,
1252
1252
  l.value || s.value[0].value,
1253
- (m) => {
1254
- t("update:modelValue", m), t("change", m);
1253
+ (d) => {
1254
+ t("update:modelValue", d), t("change", d);
1255
1255
  }
1256
- ), g = K([]), a = K(), c = (m = 18) => {
1257
- const y = Hn(m);
1256
+ ), g = K([]), a = K(), c = (d = 18) => {
1257
+ const y = Hn(d);
1258
1258
  return {
1259
1259
  width: y,
1260
1260
  height: y,
1261
1261
  fontSize: y
1262
1262
  };
1263
- }, d = (m) => {
1264
- u.value !== m && (u.value = m);
1263
+ }, p = (d) => {
1264
+ u.value !== d && (u.value = d);
1265
1265
  }, f = async () => {
1266
1266
  await de();
1267
- const m = s.value.findIndex(
1268
- (Z) => Z.value === u.value
1269
- ), y = m === -1 ? 0 : m, j = g.value[y];
1267
+ const d = s.value.findIndex(
1268
+ (A) => A.value === u.value
1269
+ ), y = d === -1 ? 0 : d, b = g.value[y];
1270
1270
  a.value = {
1271
1271
  ...i.sliderStyle || {},
1272
- width: Hn(j == null ? void 0 : j.offsetWidth),
1273
- transform: `translateX(${Hn(j == null ? void 0 : j.offsetLeft)})`
1272
+ width: Hn(b == null ? void 0 : b.offsetWidth),
1273
+ transform: `translateX(${Hn(b == null ? void 0 : b.offsetLeft)})`
1274
1274
  };
1275
1275
  };
1276
1276
  return cn(() => u.value, f, {
1277
1277
  immediate: !0
1278
1278
  }), Hi(g, f, {
1279
1279
  box: "border-box"
1280
- }), (m, y) => (Y(), L("div", Ch, [
1281
- A("div", {
1280
+ }), (d, y) => (Y(), L("div", Ch, [
1281
+ v("div", {
1282
1282
  class: "cx-radio-slider",
1283
1283
  style: he(a.value)
1284
1284
  }, null, 4),
1285
- (Y(!0), L(en, null, gn(b(s), (j, Z) => (Y(), L("div", {
1286
- key: j.value,
1285
+ (Y(!0), L(en, null, gn(z(s), (b, A) => (Y(), L("div", {
1286
+ key: b.value,
1287
1287
  style: he(e.radioStyle),
1288
1288
  class: bn([
1289
1289
  "cx-radio",
1290
1290
  {
1291
- "cx-radio-selected": b(u) === j.value
1291
+ "cx-radio-selected": z(u) === b.value
1292
1292
  }
1293
1293
  ]),
1294
1294
  ref_for: !0,
1295
- ref: (I) => g.value[Z] = I,
1296
- onClick: (I) => d(j.value)
1295
+ ref: (I) => g.value[A] = I,
1296
+ onClick: (I) => p(b.value)
1297
1297
  }, [
1298
- j.icon ? (Y(), L("div", {
1298
+ b.icon ? (Y(), L("div", {
1299
1299
  key: 0,
1300
1300
  class: "cx-radio-icon",
1301
- style: he(c(j.iconSize))
1301
+ style: he(c(b.iconSize))
1302
1302
  }, [
1303
- H(b(rn), {
1304
- name: j.icon
1303
+ H(z(rn), {
1304
+ name: b.icon
1305
1305
  }, null, 8, ["name"])
1306
1306
  ], 4)) : yn("", !0),
1307
- j.label ? (Y(), L("div", Wh, F(j.label), 1)) : yn("", !0)
1307
+ b.label ? (Y(), L("div", Wh, F(b.label), 1)) : yn("", !0)
1308
1308
  ], 14, Ih))), 128))
1309
1309
  ]));
1310
1310
  }
@@ -1327,13 +1327,13 @@ const Ch = { class: "cx-radio-group" }, Ih = ["onClick"], Wh = {
1327
1327
  H(Cl, { name: "el-fade-in" }, {
1328
1328
  default: N(() => [
1329
1329
  e.loading ? (Y(), L("div", Yh, [
1330
- A("div", kh, [
1331
- A("img", {
1332
- src: b(Sh),
1330
+ v("div", kh, [
1331
+ v("img", {
1332
+ src: z(Sh),
1333
1333
  class: "cx-spin-loading",
1334
1334
  style: he({
1335
- width: b(Hn)(e.size),
1336
- height: b(Hn)(e.size)
1335
+ width: z(Hn)(e.size),
1336
+ height: z(Hn)(e.size)
1337
1337
  })
1338
1338
  }, null, 12, Kh),
1339
1339
  e.text ? (Y(), L("span", Vh, F(e.text), 1)) : yn("", !0)
@@ -1369,26 +1369,26 @@ const Ch = { class: "cx-radio-group" }, Ih = ["onClick"], Wh = {
1369
1369
  (w) => {
1370
1370
  o("update:modelValue", w);
1371
1371
  }
1372
- ), a = T(() => g.value[0]), { onChange: c, open: d } = vh({
1372
+ ), a = T(() => g.value[0]), { onChange: c, open: p } = vh({
1373
1373
  accept: r.value.join(","),
1374
1374
  multiple: !1,
1375
1375
  reset: !0
1376
1376
  });
1377
- c((w) => j(w && [...w]));
1378
- const f = K(), { isOverDropZone: m } = qh(f, {
1377
+ c((w) => b(w && [...w]));
1378
+ const f = K(), { isOverDropZone: d } = qh(f, {
1379
1379
  preventDefaultForUnhandled: !0,
1380
- onDrop: (w) => j(w)
1380
+ onDrop: (w) => b(w)
1381
1381
  }), y = () => {
1382
1382
  o("clear"), g.value = [];
1383
- }, j = (w) => {
1383
+ }, b = (w) => {
1384
1384
  if (u.value || !(w != null && w.length)) return;
1385
1385
  const J = w.filter((k) => I(k));
1386
1386
  J.length && (g.value = J, o("change", J));
1387
- }, Z = () => {
1388
- u.value || d();
1387
+ }, A = () => {
1388
+ u.value || p();
1389
1389
  }, I = (w) => r.value.includes(`.${oo(w.name)}`) ? h.value > 0 && w.size > h.value ? (ji.error("文件大小不符合上传要求"), o("error", "size", w), !1) : !0 : (ji.error("文件类型不符合上传要求"), o("error", "type", w), !1);
1390
1390
  return n({
1391
- open: Z,
1391
+ open: A,
1392
1392
  clear: () => {
1393
1393
  g.value = [];
1394
1394
  }
@@ -1396,34 +1396,34 @@ const Ch = { class: "cx-radio-group" }, Ih = ["onClick"], Wh = {
1396
1396
  class: bn([
1397
1397
  "cx-upload-wrapper",
1398
1398
  {
1399
- "cx-upload-dragging": b(m),
1400
- "cx-upload-has-value": b(g).length > 0,
1401
- "cx-upload-disabled": b(u)
1399
+ "cx-upload-dragging": z(d),
1400
+ "cx-upload-has-value": z(g).length > 0,
1401
+ "cx-upload-disabled": z(u)
1402
1402
  }
1403
1403
  ])
1404
1404
  }, [
1405
1405
  a.value ? (Y(), L("div", Xh, [
1406
- A("div", Jh, [
1407
- H(b(rn), {
1408
- name: `icon-component-file-${b(gs)(a.value.name)}`,
1406
+ v("div", Jh, [
1407
+ H(z(rn), {
1408
+ name: `icon-component-file-${z(gs)(a.value.name)}`,
1409
1409
  size: "56"
1410
1410
  }, null, 8, ["name"]),
1411
- A("span", {
1411
+ v("span", {
1412
1412
  class: "cx-upload-clear-icon",
1413
1413
  onClick: y
1414
1414
  }, [
1415
- H(b(rn), {
1415
+ H(z(rn), {
1416
1416
  name: "icon-component-upload-clear",
1417
1417
  size: "16"
1418
1418
  })
1419
1419
  ])
1420
1420
  ]),
1421
- A("div", Hh, F(a.value.name), 1),
1422
- A("div", Lh, [
1421
+ v("div", Hh, F(a.value.name), 1),
1422
+ v("div", Lh, [
1423
1423
  wn(w.$slots, "operate", {}, () => [
1424
- A("div", {
1424
+ v("div", {
1425
1425
  class: "cx-upload-file-replace",
1426
- onClick: Z
1426
+ onClick: A
1427
1427
  }, " 点击更换文件 ")
1428
1428
  ], !0)
1429
1429
  ])
@@ -1432,15 +1432,15 @@ const Ch = { class: "cx-radio-group" }, Ih = ["onClick"], Wh = {
1432
1432
  class: "cx-upload",
1433
1433
  ref_key: "uploadRef",
1434
1434
  ref: f,
1435
- onClick: Z
1435
+ onClick: A
1436
1436
  }, [
1437
- A("div", Mh, [
1438
- H(b(rn), {
1437
+ v("div", Mh, [
1438
+ H(z(rn), {
1439
1439
  name: "icon-component-cx-upload",
1440
1440
  size: [28, 19]
1441
1441
  })
1442
1442
  ]),
1443
- A("div", Th, F(e.title), 1),
1443
+ v("div", Th, F(e.title), 1),
1444
1444
  e.tip ? (Y(), L("div", Nh, F(e.tip), 1)) : yn("", !0)
1445
1445
  ], 512))
1446
1446
  ], 2));
@@ -1525,8 +1525,8 @@ const Uh = {
1525
1525
  console.warn("无法获取节点位置");
1526
1526
  return;
1527
1527
  }
1528
- const d = n.node.textContent, f = c, m = c + n.node.nodeSize, y = g.schema.text(d), j = g.tr.replaceWith(f, m, y);
1529
- a(j);
1528
+ const p = n.node.textContent, f = c, d = c + n.node.nodeSize, y = g.schema.text(p), b = g.tr.replaceWith(f, d, y);
1529
+ a(b);
1530
1530
  }, s = () => {
1531
1531
  const u = P[o.value];
1532
1532
  if ("deleteMode" in u && u.deleteMode === cl.DELETE_NODE)
@@ -1537,7 +1537,7 @@ const Uh = {
1537
1537
  if (o.value === P.language.type)
1538
1538
  return ((u = gl.find((g) => g.value === t.value.code)) == null ? void 0 : u.label) || "";
1539
1539
  }), r = T(() => P[o.value].icon);
1540
- return (u, g) => (Y(), _(b(Ll), {
1540
+ return (u, g) => (Y(), _(z(Ll), {
1541
1541
  as: "span",
1542
1542
  class: bn(["tag-node", {
1543
1543
  "is-selected": i.value
@@ -1545,51 +1545,51 @@ const Uh = {
1545
1545
  contenteditable: "false"
1546
1546
  }, {
1547
1547
  default: N(() => {
1548
- var a, c, d;
1548
+ var a, c, p;
1549
1549
  return [
1550
- A("span", Dh, [
1551
- H(b(rn), {
1550
+ v("span", Dh, [
1551
+ H(z(rn), {
1552
1552
  name: r.value,
1553
1553
  size: 14
1554
1554
  }, null, 8, ["name"])
1555
1555
  ]),
1556
- o.value === b(P).stop.type ? (Y(), L("span", Bh, "停顿")) : o.value === b(P).customStop.type ? (Y(), L("span", Qh, "停顿" + F((a = t.value) == null ? void 0 : a.time) + "s", 1)) : o.value === b(P).continue.type ? (Y(), L(en, { key: 2 }, [
1557
- A("span", null, "连续" + F(be)),
1558
- H(b(ye), {
1556
+ o.value === z(P).stop.type ? (Y(), L("span", Bh, "停顿")) : o.value === z(P).customStop.type ? (Y(), L("span", Qh, "停顿" + F((a = t.value) == null ? void 0 : a.time) + "s", 1)) : o.value === z(P).continue.type ? (Y(), L(en, { key: 2 }, [
1557
+ v("span", null, "连续" + F(be)),
1558
+ H(z(ye), {
1559
1559
  as: "span",
1560
1560
  class: "tag-content"
1561
1561
  })
1562
- ], 64)) : o.value === b(P).replace.type ? (Y(), L(en, { key: 3 }, [
1563
- A("span", null, "替换" + F(be)),
1564
- H(b(ye), {
1562
+ ], 64)) : o.value === z(P).replace.type ? (Y(), L(en, { key: 3 }, [
1563
+ v("span", null, "替换" + F(be)),
1564
+ H(z(ye), {
1565
1565
  as: "span",
1566
1566
  class: "tag-content"
1567
1567
  }),
1568
- g[0] || (g[0] = A("span", null, "→", -1)),
1569
- A("span", null, F((c = t.value) == null ? void 0 : c.text), 1)
1570
- ], 64)) : o.value === b(P).pinyin.type ? (Y(), L(en, { key: 4 }, [
1571
- A("span", null, "拼音" + F(be)),
1572
- H(b(ye), {
1568
+ g[0] || (g[0] = v("span", null, "→", -1)),
1569
+ v("span", null, F((c = t.value) == null ? void 0 : c.text), 1)
1570
+ ], 64)) : o.value === z(P).pinyin.type ? (Y(), L(en, { key: 4 }, [
1571
+ v("span", null, "拼音" + F(be)),
1572
+ H(z(ye), {
1573
1573
  as: "span",
1574
1574
  class: "tag-content"
1575
1575
  }),
1576
- g[1] || (g[1] = A("span", null, "→", -1)),
1577
- A("span", null, F((d = t.value) == null ? void 0 : d.text), 1)
1578
- ], 64)) : o.value === b(P).language.type ? (Y(), L(en, { key: 5 }, [
1579
- A("span", null, F(h.value) + F(be), 1),
1580
- H(b(ye), {
1576
+ g[1] || (g[1] = v("span", null, "→", -1)),
1577
+ v("span", null, F((p = t.value) == null ? void 0 : p.text), 1)
1578
+ ], 64)) : o.value === z(P).language.type ? (Y(), L(en, { key: 5 }, [
1579
+ v("span", null, F(h.value) + F(be), 1),
1580
+ H(z(ye), {
1581
1581
  as: "span",
1582
1582
  class: "tag-content"
1583
1583
  })
1584
- ], 64)) : o.value === b(P).ignore.type ? (Y(), L(en, { key: 6 }, [
1585
- A("span", null, "忽略读音" + F(be)),
1586
- H(b(ye), {
1584
+ ], 64)) : o.value === z(P).ignore.type ? (Y(), L(en, { key: 6 }, [
1585
+ v("span", null, "忽略读音" + F(be)),
1586
+ H(z(ye), {
1587
1587
  as: "span",
1588
1588
  class: "tag-content"
1589
1589
  })
1590
1590
  ], 64)) : yn("", !0),
1591
- A("span", _h, [
1592
- H(b(rn), {
1591
+ v("span", _h, [
1592
+ H(z(rn), {
1593
1593
  name: "editor-close",
1594
1594
  class: "delete-btn",
1595
1595
  onClick: bi(s, ["stop"])
@@ -1622,7 +1622,22 @@ const Uh = {
1622
1622
  return {
1623
1623
  id: { default: "" },
1624
1624
  categ: { default: o },
1625
- payload: { default: {} }
1625
+ payload: {
1626
+ default: {},
1627
+ renderHTML: ({ payload: s }) => ({
1628
+ payload: JSON.stringify(s ?? {}) ?? "{}"
1629
+ }),
1630
+ parseHTML: (s) => {
1631
+ const h = s.getAttribute("payload");
1632
+ if (!h) return {};
1633
+ try {
1634
+ const r = JSON.parse(h);
1635
+ return r && typeof r == "object" ? r : {};
1636
+ } catch {
1637
+ return {};
1638
+ }
1639
+ }
1640
+ }
1626
1641
  };
1627
1642
  },
1628
1643
  parseHTML() {
@@ -2153,11 +2168,11 @@ class pn {
2153
2168
  break;
2154
2169
  let u = this.ranges[h + l], g = this.ranges[h + s], a = r + u;
2155
2170
  if (n <= a) {
2156
- let c = u ? n == r ? -1 : n == a ? 1 : i : i, d = r + o + (c < 0 ? 0 : g);
2171
+ let c = u ? n == r ? -1 : n == a ? 1 : i : i, p = r + o + (c < 0 ? 0 : g);
2157
2172
  if (t)
2158
- return d;
2159
- let f = n == (i < 0 ? r : a) ? null : or(h / 3, n - r), m = n == r ? jo : n == a ? bo : Le;
2160
- return (i < 0 ? n != r : n != a) && (m |= vo), new ut(d, m, f);
2173
+ return p;
2174
+ let f = n == (i < 0 ? r : a) ? null : or(h / 3, n - r), d = n == r ? jo : n == a ? bo : Le;
2175
+ return (i < 0 ? n != r : n != a) && (d |= vo), new ut(p, d, f);
2161
2176
  }
2162
2177
  o += g - u;
2163
2178
  }
@@ -3199,12 +3214,12 @@ function rr(e = {}) {
3199
3214
  editable: l = K(!0),
3200
3215
  services: s = K({}),
3201
3216
  features: h = K({})
3202
- } = e, r = e.getGenerateAudioParams ?? (() => ({})), u = K(Uh.TEXT), g = K(""), a = (q, p = "") => {
3203
- const { from: W, to: O, empty: v } = q.state.selection;
3204
- return v ? "" : q.state.doc.textBetween(W, O, p);
3205
- }, c = (q) => {
3206
- g.value = a(q);
3207
- }, d = Tl({
3217
+ } = e, r = e.getGenerateAudioParams ?? (() => ({})), u = e.getPlaybackSpeed ?? (() => 1), g = K(Uh.TEXT), a = K(""), c = (m, C = "") => {
3218
+ const { from: W, to: j, empty: x } = m.state.selection;
3219
+ return x ? "" : m.state.doc.textBetween(W, j, C);
3220
+ }, p = (m) => {
3221
+ a.value = c(m);
3222
+ }, f = Tl({
3208
3223
  content: n,
3209
3224
  editable: l.value,
3210
3225
  extensions: [
@@ -3228,65 +3243,65 @@ function rr(e = {}) {
3228
3243
  attributes: {
3229
3244
  class: "tiptap-editor"
3230
3245
  },
3231
- transformPastedText(q) {
3232
- return _i(q);
3246
+ transformPastedText(m) {
3247
+ return _i(m);
3233
3248
  },
3234
- transformPastedHTML(q) {
3235
- return dl(q);
3249
+ transformPastedHTML(m) {
3250
+ return dl(m);
3236
3251
  }
3237
3252
  },
3238
- onCreate({ editor: q }) {
3239
- var p;
3240
- c(q), (p = e.onCreate) == null || p.call(e, q);
3253
+ onCreate({ editor: m }) {
3254
+ var C;
3255
+ p(m), (C = e.onCreate) == null || C.call(e, m);
3241
3256
  },
3242
- onUpdate({ editor: q }) {
3243
- var p, W;
3244
- c(q), (p = e.onChange) == null || p.call(e, q), (W = e.onUpdate) == null || W.call(e, q.getJSON(), q);
3257
+ onUpdate({ editor: m }) {
3258
+ var C, W;
3259
+ p(m), (C = e.onChange) == null || C.call(e, m), (W = e.onUpdate) == null || W.call(e, m.getJSON(), m);
3245
3260
  },
3246
- onSelectionUpdate({ editor: q }) {
3247
- c(q);
3261
+ onSelectionUpdate({ editor: m }) {
3262
+ p(m);
3248
3263
  }
3249
3264
  });
3250
- cn(l, (q) => {
3251
- var p;
3252
- return (p = d.value) == null ? void 0 : p.setEditable(q);
3265
+ cn(l, (m) => {
3266
+ var C;
3267
+ return (C = f.value) == null ? void 0 : C.setEditable(m);
3253
3268
  });
3254
- const f = T(() => g.value.length > 0), m = T(() => /^\d+$/.test(g.value)), y = () => d.value ? a(d.value) : "", j = () => {
3255
- if (!d.value) return null;
3256
- const { empty: q } = d.value.state.selection;
3257
- return q ? null : d.value.state.selection.content().toJSON();
3269
+ const d = T(() => a.value.length > 0), y = T(() => /^\d+$/.test(a.value)), b = () => f.value ? c(f.value) : "", A = () => {
3270
+ if (!f.value) return null;
3271
+ const { empty: m } = f.value.state.selection;
3272
+ return m ? null : f.value.state.selection.content().toJSON();
3258
3273
  };
3259
- function Z(q) {
3274
+ function I(m) {
3260
3275
  var W;
3261
- if (!d.value) return;
3262
- const { empty: p } = d.value.state.selection;
3263
- p && ((W = d.value) == null || W.chain().focus().insertContent({
3276
+ if (!f.value) return;
3277
+ const { empty: C } = f.value.state.selection;
3278
+ C && ((W = f.value) == null || W.chain().focus().insertContent({
3264
3279
  type: ce,
3265
3280
  attrs: {
3266
3281
  id: Zi(16),
3267
- ...q
3282
+ ...m
3268
3283
  }
3269
3284
  }).run());
3270
3285
  }
3271
- function I(q) {
3272
- if (!d.value) return;
3273
- const { from: p, to: W, empty: O } = d.value.state.selection;
3274
- if (O) return;
3275
- const v = O ? "" : d.value.state.doc.textBetween(p, W, ""), C = d.value.chain().focus().deleteRange({ from: p, to: W }).insertContent({
3286
+ function w(m) {
3287
+ if (!f.value) return;
3288
+ const { from: C, to: W, empty: j } = f.value.state.selection;
3289
+ if (j) return;
3290
+ const x = j ? "" : f.value.state.doc.textBetween(C, W, ""), q = f.value.chain().focus().deleteRange({ from: C, to: W }).insertContent({
3276
3291
  type: ce,
3277
3292
  attrs: {
3278
3293
  id: Zi(16),
3279
- ...q
3294
+ ...m
3280
3295
  },
3281
- content: v ? [{ type: "text", text: v }] : []
3296
+ content: x ? [{ type: "text", text: x }] : []
3282
3297
  });
3283
- O && C.setTextSelection(p + 1), C.run();
3298
+ j && q.setTextSelection(C + 1), q.run();
3284
3299
  }
3285
- const w = () => {
3286
- if (!d.value) return null;
3287
- const { empty: q, head: p } = d.value.state.selection;
3288
- if (q) return null;
3289
- const W = d.value.view.coordsAtPos(p);
3300
+ const J = () => {
3301
+ if (!f.value) return null;
3302
+ const { empty: m, head: C } = f.value.state.selection;
3303
+ if (m) return null;
3304
+ const W = f.value.view.coordsAtPos(C);
3290
3305
  return {
3291
3306
  getBoundingClientRect() {
3292
3307
  return {
@@ -3302,58 +3317,59 @@ function rr(e = {}) {
3302
3317
  }
3303
3318
  };
3304
3319
  };
3305
- function J() {
3306
- var q;
3307
- (q = d.value) == null || q.commands.setContent(Jn());
3308
- }
3309
- const k = (q) => {
3310
- var p;
3311
- (p = d.value) == null || p.commands.setContent(q, { emitUpdate: !1 });
3312
- }, G = (q) => {
3313
- var W, O;
3314
- const p = _i(q);
3315
- if (!p) {
3316
- (W = d.value) == null || W.commands.setContent(Jn());
3320
+ function k() {
3321
+ var m;
3322
+ (m = f.value) == null || m.commands.setContent(Jn());
3323
+ }
3324
+ const G = (m) => {
3325
+ var C;
3326
+ (C = f.value) == null || C.commands.setContent(m, { emitUpdate: !1 });
3327
+ }, M = (m) => {
3328
+ var W, j;
3329
+ const C = _i(m);
3330
+ if (!C) {
3331
+ (W = f.value) == null || W.commands.setContent(Jn());
3317
3332
  return;
3318
3333
  }
3319
- (O = d.value) == null || O.commands.setContent({
3334
+ (j = f.value) == null || j.commands.setContent({
3320
3335
  type: "doc",
3321
- content: p.split(`
3322
- `).map((v) => ({
3336
+ content: C.split(`
3337
+ `).map((x) => ({
3323
3338
  type: "paragraph",
3324
- content: v ? [{ type: "text", text: v }] : []
3339
+ content: x ? [{ type: "text", text: x }] : []
3325
3340
  }))
3326
3341
  });
3327
- }, M = T(() => {
3328
- var q;
3329
- return ((q = d.value) == null ? void 0 : q.storage.characterCount.characters()) || 0;
3342
+ }, V = T(() => {
3343
+ var m;
3344
+ return ((m = f.value) == null ? void 0 : m.storage.characterCount.characters()) || 0;
3330
3345
  });
3331
3346
  return {
3332
- editor: d,
3333
- driveMode: u,
3334
- insertToken: Z,
3335
- insertWrappedToken: I,
3336
- clearContent: J,
3337
- setContent: k,
3338
- getSelectedText: y,
3339
- getSelectedJson: j,
3340
- selectedText: g,
3341
- hasSelectedText: f,
3342
- isSelectedPureNumber: m,
3347
+ editor: f,
3348
+ driveMode: g,
3349
+ insertToken: I,
3350
+ insertWrappedToken: w,
3351
+ clearContent: k,
3352
+ setContent: G,
3353
+ getSelectedText: b,
3354
+ getSelectedJson: A,
3355
+ selectedText: a,
3356
+ hasSelectedText: d,
3357
+ isSelectedPureNumber: y,
3343
3358
  textLimitLength: i,
3344
3359
  getGenerateAudioParams: r,
3360
+ getPlaybackSpeed: u,
3345
3361
  services: s,
3346
3362
  features: h,
3347
- notify: (q, p) => {
3363
+ notify: (m, C) => {
3348
3364
  if (s.value.notify) {
3349
- s.value.notify(q, p);
3365
+ s.value.notify(m, C);
3350
3366
  return;
3351
3367
  }
3352
- ji({ type: q, message: p });
3368
+ ji({ type: m, message: C });
3353
3369
  },
3354
- getReferencedVirtualElement: w,
3355
- replaceContentWithText: G,
3356
- textLength: M,
3370
+ getReferencedVirtualElement: J,
3371
+ replaceContentWithText: M,
3372
+ textLength: V,
3357
3373
  voiceVersion: t
3358
3374
  };
3359
3375
  }
@@ -3446,48 +3462,48 @@ const Co = Symbol("useRichTextEditor"), ur = (e) => {
3446
3462
  const { services: n } = Tn(), i = K(!1), t = K([]), o = K(-1), l = K("idle"), s = K(!1), h = K(!1);
3447
3463
  let r = null, u = null;
3448
3464
  const g = T(() => {
3449
- var v;
3450
- return o.value < 0 ? "" : ((v = t.value[o.value]) == null ? void 0 : v.src) || "";
3451
- }), a = xh(e, { src: g }), { playing: c } = a, d = T(() => l.value === "playing"), f = T(() => t.value.length > 0), m = T(
3452
- () => t.value.reduce((v, C) => v + C.duration, 0)
3453
- ), y = T(() => o.value <= 0 ? 0 : t.value.slice(0, o.value).reduce((v, C) => v + C.duration, 0)), j = T({
3465
+ var j;
3466
+ return o.value < 0 ? "" : ((j = t.value[o.value]) == null ? void 0 : j.src) || "";
3467
+ }), a = xh(e, { src: g }), { playing: c } = a, p = T(() => l.value === "playing"), f = T(() => t.value.length > 0), d = T(
3468
+ () => t.value.reduce((j, x) => j + x.duration, 0)
3469
+ ), y = T(() => o.value <= 0 ? 0 : t.value.slice(0, o.value).reduce((j, x) => j + x.duration, 0)), b = T({
3454
3470
  get() {
3455
3471
  return o.value < 0 || !g.value ? 0 : y.value + a.currentTime.value;
3456
3472
  },
3457
- set(v) {
3473
+ set(j) {
3458
3474
  a.currentTime.value = Math.max(
3459
3475
  0,
3460
- v - y.value
3476
+ j - y.value
3461
3477
  );
3462
3478
  }
3463
- }), Z = T({
3479
+ }), A = T({
3464
3480
  get: () => c.value,
3465
- set(v) {
3466
- l.value = v ? "playing" : "paused", c.value = v;
3481
+ set(j) {
3482
+ l.value = j ? "playing" : "paused", c.value = j;
3467
3483
  }
3468
3484
  }), I = {
3469
3485
  ...a,
3470
- playing: Z,
3471
- currentTime: j,
3472
- duration: m
3486
+ playing: A,
3487
+ currentTime: b,
3488
+ duration: d
3473
3489
  }, w = async () => {
3474
3490
  s.value = !1, await de(), c.value = !0;
3475
3491
  }, J = async () => {
3476
3492
  t.value.length && (o.value = 0, a.currentTime.value = 0, await w());
3477
3493
  }, k = async () => {
3478
3494
  if (l.value !== "playing") return;
3479
- const v = o.value + 1;
3480
- if (!t.value[v]) {
3495
+ const j = o.value + 1;
3496
+ if (!t.value[j]) {
3481
3497
  h.value ? l.value = "idle" : s.value = !0;
3482
3498
  return;
3483
3499
  }
3484
- o.value = v, await w();
3500
+ o.value = j, await w();
3485
3501
  }, G = async () => {
3486
3502
  if (l.value = "playing", o.value < 0 || s.value) {
3487
3503
  await k();
3488
3504
  return;
3489
3505
  }
3490
- if (m.value > 0 && j.value >= m.value) {
3506
+ if (d.value > 0 && b.value >= d.value) {
3491
3507
  await J();
3492
3508
  return;
3493
3509
  }
@@ -3496,66 +3512,66 @@ const Co = Symbol("useRichTextEditor"), ur = (e) => {
3496
3512
  E(e, "ended", () => {
3497
3513
  k();
3498
3514
  }), E(e, "loadedmetadata", () => {
3499
- var z;
3500
- const v = t.value[o.value], C = (z = e == null ? void 0 : e.value) == null ? void 0 : z.duration;
3501
- v && !v.duration && Number.isFinite(C) && (v.duration = C || 0);
3515
+ var q;
3516
+ const j = t.value[o.value], x = (q = e == null ? void 0 : e.value) == null ? void 0 : q.duration;
3517
+ j && !j.duration && Number.isFinite(x) && (j.duration = x || 0);
3502
3518
  });
3503
3519
  const M = () => {
3504
3520
  l.value = "stopped", c.value = !1, s.value = !1, i.value = !1, r == null || r.abort(), r = null;
3505
3521
  }, V = () => {
3506
- t.value.forEach((v) => URL.revokeObjectURL(v.src)), t.value = [], o.value = -1, a.currentTime.value = 0, s.value = !1, h.value = !1;
3507
- }, q = () => {
3522
+ t.value.forEach((j) => URL.revokeObjectURL(j.src)), t.value = [], o.value = -1, a.currentTime.value = 0, s.value = !1, h.value = !1;
3523
+ }, S = () => {
3508
3524
  h.value = !0, s.value && o.value >= t.value.length - 1 && (s.value = !1, l.value = "idle"), i.value = !1;
3509
- }, p = (v) => {
3510
- if (v.done) {
3511
- q(), u = v;
3525
+ }, m = (j) => {
3526
+ if (j.done) {
3527
+ S(), u = j;
3512
3528
  return;
3513
3529
  }
3514
- v.audio_base64 && (t.value[v.index] = {
3515
- src: pr(v.audio_base64, v.audio_format),
3516
- duration: mr(v)
3530
+ j.audio_base64 && (t.value[j.index] = {
3531
+ src: pr(j.audio_base64, j.audio_format),
3532
+ duration: mr(j)
3517
3533
  }, l.value === "playing" && (o.value < 0 || s.value) && k());
3518
- }, W = (v) => {
3519
- const C = v instanceof Blob ? URL.createObjectURL(v) : v;
3520
- t.value[0] = { src: C, duration: 0 }, h.value = !0, k();
3521
- }, O = async (v) => {
3522
- const C = n.value.synthesizePreviewStream, z = n.value.synthesizePreview;
3523
- if (!C && !z) return null;
3534
+ }, C = (j) => {
3535
+ const x = j instanceof Blob ? URL.createObjectURL(j) : j;
3536
+ t.value[0] = { src: x, duration: 0 }, h.value = !0, k();
3537
+ }, W = async (j) => {
3538
+ const x = n.value.synthesizePreviewStream, q = n.value.synthesizePreview;
3539
+ if (!x && !q) return null;
3524
3540
  M(), V(), i.value = !0, u = null, l.value = "playing";
3525
- const S = new AbortController();
3526
- r = S;
3541
+ const O = new AbortController();
3542
+ r = O;
3527
3543
  try {
3528
- if (C)
3529
- u = await C(v, {
3530
- signal: S.signal,
3531
- onMessage: (x) => {
3532
- S.signal.aborted || p(x);
3544
+ if (x)
3545
+ u = await x(j, {
3546
+ signal: O.signal,
3547
+ onMessage: (Z) => {
3548
+ O.signal.aborted || m(Z);
3533
3549
  }
3534
- }), h.value || q();
3535
- else if (z) {
3536
- const x = await z(v, S.signal);
3537
- if (S.signal.aborted) return null;
3538
- W(x);
3550
+ }), h.value || S();
3551
+ else if (q) {
3552
+ const Z = await q(j, O.signal);
3553
+ if (O.signal.aborted) return null;
3554
+ C(Z);
3539
3555
  }
3540
3556
  return u;
3541
- } catch (x) {
3542
- if (x instanceof Error && x.name === "AbortError") return null;
3543
- throw x;
3557
+ } catch (Z) {
3558
+ if (Z instanceof Error && Z.name === "AbortError") return null;
3559
+ throw Z;
3544
3560
  } finally {
3545
- r === S && (i.value = !1, r = null);
3561
+ r === O && (i.value = !1, r = null);
3546
3562
  }
3547
3563
  };
3548
3564
  return Se(() => {
3549
3565
  M(), V();
3550
3566
  }), {
3551
- execute: O,
3567
+ execute: W,
3552
3568
  loading: i,
3553
3569
  abort: M,
3554
3570
  resume: G,
3555
3571
  stop: M,
3556
- playing: Z,
3572
+ playing: A,
3557
3573
  mediaControls: I,
3558
- shouldAutoPlay: d,
3574
+ shouldAutoPlay: p,
3559
3575
  hasAudio: f
3560
3576
  };
3561
3577
  }, yr = /^[\u3400-\u9fff]+$/, qr = ({
@@ -3571,21 +3587,21 @@ const Co = Symbol("useRichTextEditor"), ur = (e) => {
3571
3587
  selectedText: h,
3572
3588
  hasSelectedText: r,
3573
3589
  isSelectedPureNumber: u
3574
- } = e, { features: g, notify: a, services: c } = e, d = T(
3590
+ } = e, { features: g, notify: a, services: c } = e, p = T(
3575
3591
  () => ml(i.value, g.value)
3576
- ), f = () => !r.value, m = () => {
3577
- var O;
3578
- const W = (((O = s()) == null ? void 0 : O.content) || []).some(
3579
- (v) => {
3580
- var C;
3581
- return (C = v.content) == null ? void 0 : C.some((z) => z.type !== "text");
3592
+ ), f = () => !r.value, d = () => {
3593
+ var W;
3594
+ const C = (((W = s()) == null ? void 0 : W.content) || []).some(
3595
+ (j) => {
3596
+ var x;
3597
+ return (x = j.content) == null ? void 0 : x.some((q) => q.type !== "text");
3582
3598
  }
3583
3599
  );
3584
- return W && a("info", "请选择纯文本"), W;
3585
- }, y = (p) => yr.test(p) ? Array.from(p).length > d.value.maxPinyinLength ? (a(
3600
+ return C && a("info", "请选择纯文本"), C;
3601
+ }, y = (m) => yr.test(m) ? Array.from(m).length > p.value.maxPinyinLength ? (a(
3586
3602
  "info",
3587
- `最多选择${d.value.maxPinyinLength}个中文`
3588
- ), !0) : !1 : (a("info", "请选择中文"), !0), j = [
3603
+ `最多选择${p.value.maxPinyinLength}个中文`
3604
+ ), !0) : !1 : (a("info", "请选择中文"), !0), b = [
3589
3605
  {
3590
3606
  tool: P.customStop
3591
3607
  },
@@ -3597,23 +3613,23 @@ const Co = Symbol("useRichTextEditor"), ur = (e) => {
3597
3613
  tool: P.continue,
3598
3614
  disabled: f,
3599
3615
  onClick: () => {
3600
- m() || o({ categ: "continue", payload: {} });
3616
+ d() || o({ categ: "continue", payload: {} });
3601
3617
  }
3602
3618
  },
3603
3619
  {
3604
3620
  tool: P.pinyin,
3605
3621
  disabled: f,
3606
3622
  onClick: () => {
3607
- const p = l();
3608
- !p || m() || y(p) || n.pinyin(p);
3623
+ const m = l();
3624
+ !m || d() || y(m) || n.pinyin(m);
3609
3625
  }
3610
3626
  },
3611
3627
  {
3612
3628
  tool: P.replace,
3613
3629
  disabled: f,
3614
3630
  onClick: () => {
3615
- const p = l();
3616
- !p || m() || n.replace(p);
3631
+ const m = l();
3632
+ !m || d() || n.replace(m);
3617
3633
  }
3618
3634
  },
3619
3635
  {
@@ -3624,19 +3640,19 @@ const Co = Symbol("useRichTextEditor"), ur = (e) => {
3624
3640
  tool: P.ignore,
3625
3641
  disabled: f,
3626
3642
  onClick: () => {
3627
- m() || o({ categ: "ignore", payload: {} });
3643
+ d() || o({ categ: "ignore", payload: {} });
3628
3644
  }
3629
3645
  },
3630
3646
  {
3631
3647
  tool: P.number,
3632
- disabled: () => !u.value || h.value.length > d.value.maxNumberLength
3648
+ disabled: () => !u.value || h.value.length > p.value.maxNumberLength
3633
3649
  },
3634
3650
  {
3635
3651
  tool: P.formula,
3636
3652
  disabled: f,
3637
3653
  onClick: () => {
3638
- const p = l();
3639
- !p || m() || n.formula(p);
3654
+ const m = l();
3655
+ !m || d() || n.formula(m);
3640
3656
  }
3641
3657
  },
3642
3658
  {
@@ -3647,30 +3663,30 @@ const Co = Symbol("useRichTextEditor"), ur = (e) => {
3647
3663
  tool: P.upload,
3648
3664
  onClick: n.upload
3649
3665
  }
3650
- ], Z = T(() => {
3651
- const p = new Set(d.value.tools);
3652
- return j.filter((W) => p.has(W.tool.type));
3653
- }), I = T(() => d.value.languages), w = T(() => u.value ? pl.map((p) => ({
3654
- label: p.label,
3655
- value: p.func(h.value)
3656
- })) : []), J = (p) => p === P.formula.type ? !c.value.readFormula : p === P.aiRewrite.type ? !c.value.generateDraft : p === P.upload.type ? !c.value.parseDocument : !1;
3666
+ ], A = T(() => {
3667
+ const m = new Set(p.value.tools);
3668
+ return b.filter((C) => m.has(C.tool.type));
3669
+ }), I = T(() => p.value.languages), w = T(() => u.value ? pl.map((m) => ({
3670
+ label: m.label,
3671
+ value: m.func(h.value)
3672
+ })) : []), J = (m) => m === P.formula.type ? !c.value.readFormula : m === P.aiRewrite.type ? !c.value.generateDraft : m === P.upload.type ? !c.value.parseDocument : !1;
3657
3673
  return {
3658
- toolList: Z,
3674
+ toolList: A,
3659
3675
  languageOptions: I,
3660
3676
  numberToTextList: w,
3661
- isToolDisabled: (p) => {
3662
- var W;
3663
- return (((W = p.disabled) == null ? void 0 : W.call(p)) ?? !1) || J(p.tool.type);
3677
+ isToolDisabled: (m) => {
3678
+ var C;
3679
+ return (((C = m.disabled) == null ? void 0 : C.call(m)) ?? !1) || J(m.tool.type);
3664
3680
  },
3665
- insertCustomStop: (p) => {
3666
- t({ categ: "customStop", payload: { time: p } });
3681
+ insertCustomStop: (m) => {
3682
+ t({ categ: "customStop", payload: { time: m } });
3667
3683
  },
3668
- setLanguage: (p) => m() ? !1 : (o({ categ: "language", payload: { code: p } }), !0),
3669
- replaceText: (p) => {
3670
- o({ categ: "replace", payload: { text: p } });
3684
+ setLanguage: (m) => d() ? !1 : (o({ categ: "language", payload: { code: m } }), !0),
3685
+ replaceText: (m) => {
3686
+ o({ categ: "replace", payload: { text: m } });
3671
3687
  },
3672
- markPinyin: (p) => {
3673
- o({ categ: "pinyin", payload: { text: p } });
3688
+ markPinyin: (m) => {
3689
+ o({ categ: "pinyin", payload: { text: m } });
3674
3690
  }
3675
3691
  };
3676
3692
  }, zr = {
@@ -3731,10 +3747,10 @@ const Co = Symbol("useRichTextEditor"), ur = (e) => {
3731
3747
  __name: "index",
3732
3748
  setup(e) {
3733
3749
  const { editor: n } = Tn();
3734
- return (i, t) => b(n) ? (Y(), _(b(Nl), {
3750
+ return (i, t) => z(n) ? (Y(), _(z(Nl), {
3735
3751
  key: 0,
3736
3752
  class: "tts-editor-content",
3737
- editor: b(n)
3753
+ editor: z(n)
3738
3754
  }, null, 8, ["editor"])) : yn("", !0);
3739
3755
  }
3740
3756
  }), vr = /* @__PURE__ */ sn(jr, [["__scopeId", "data-v-d764ae22"]]), wo = ["top", "right", "bottom", "left"], mt = ["start", "end"], pt = /* @__PURE__ */ wo.reduce((e, n) => e.concat(n, n + "-" + mt[0], n + "-" + mt[1]), []), Yn = Math.min, Cn = Math.max, Ue = Math.round, Mn = (e) => ({
@@ -3847,40 +3863,40 @@ function qt(e, n, i) {
3847
3863
  floating: o
3848
3864
  } = e;
3849
3865
  const l = Sn(n), s = Ri(n), h = Ni(s), r = Wn(n), u = l === "y", g = t.x + t.width / 2 - o.width / 2, a = t.y + t.height / 2 - o.height / 2, c = t[h] / 2 - o[h] / 2;
3850
- let d;
3866
+ let p;
3851
3867
  switch (r) {
3852
3868
  case "top":
3853
- d = {
3869
+ p = {
3854
3870
  x: g,
3855
3871
  y: t.y - o.height
3856
3872
  };
3857
3873
  break;
3858
3874
  case "bottom":
3859
- d = {
3875
+ p = {
3860
3876
  x: g,
3861
3877
  y: t.y + t.height
3862
3878
  };
3863
3879
  break;
3864
3880
  case "right":
3865
- d = {
3881
+ p = {
3866
3882
  x: t.x + t.width,
3867
3883
  y: a
3868
3884
  };
3869
3885
  break;
3870
3886
  case "left":
3871
- d = {
3887
+ p = {
3872
3888
  x: t.x - o.width,
3873
3889
  y: a
3874
3890
  };
3875
3891
  break;
3876
3892
  default:
3877
- d = {
3893
+ p = {
3878
3894
  x: t.x,
3879
3895
  y: t.y
3880
3896
  };
3881
3897
  }
3882
3898
  const f = In(n);
3883
- return f && (d[s] += c * (f === "end" ? 1 : -1) * (i && u ? -1 : 1)), d;
3899
+ return f && (p[s] += c * (f === "end" ? 1 : -1) * (i && u ? -1 : 1)), p;
3884
3900
  }
3885
3901
  async function Sr(e, n) {
3886
3902
  var i;
@@ -3897,13 +3913,13 @@ async function Sr(e, n) {
3897
3913
  rootBoundary: g = "viewport",
3898
3914
  elementContext: a = "floating",
3899
3915
  altBoundary: c = !1,
3900
- padding: d = 0
3901
- } = Nn(n, e), f = Fi(d), y = h[c ? a === "floating" ? "reference" : "floating" : a], j = Fn(await l.getClippingRect({
3916
+ padding: p = 0
3917
+ } = Nn(n, e), f = Fi(p), y = h[c ? a === "floating" ? "reference" : "floating" : a], b = Fn(await l.getClippingRect({
3902
3918
  element: (i = await (l.isElement == null ? void 0 : l.isElement(y))) == null || i ? y : y.contextElement || await (l.getDocumentElement == null ? void 0 : l.getDocumentElement(h.floating)),
3903
3919
  boundary: u,
3904
3920
  rootBoundary: g,
3905
3921
  strategy: r
3906
- })), Z = a === "floating" ? {
3922
+ })), A = a === "floating" ? {
3907
3923
  x: t,
3908
3924
  y: o,
3909
3925
  width: s.floating.width,
@@ -3913,15 +3929,15 @@ async function Sr(e, n) {
3913
3929
  y: 1
3914
3930
  }, J = Fn(l.convertOffsetParentRelativeRectToViewportRelativeRect ? await l.convertOffsetParentRelativeRectToViewportRelativeRect({
3915
3931
  elements: h,
3916
- rect: Z,
3932
+ rect: A,
3917
3933
  offsetParent: I,
3918
3934
  strategy: r
3919
- }) : Z);
3935
+ }) : A);
3920
3936
  return {
3921
- top: (j.top - J.top + f.top) / w.y,
3922
- bottom: (J.bottom - j.bottom + f.bottom) / w.y,
3923
- left: (j.left - J.left + f.left) / w.x,
3924
- right: (J.right - j.right + f.right) / w.x
3937
+ top: (b.top - J.top + f.top) / w.y,
3938
+ bottom: (J.bottom - b.bottom + f.bottom) / w.y,
3939
+ left: (b.left - J.left + f.left) / w.x,
3940
+ right: (J.right - b.right + f.right) / w.x
3925
3941
  };
3926
3942
  }
3927
3943
  const Or = 50, Yr = async (e, n, i) => {
@@ -3941,21 +3957,21 @@ const Or = 50, Yr = async (e, n, i) => {
3941
3957
  }), {
3942
3958
  x: g,
3943
3959
  y: a
3944
- } = qt(u, t, r), c = t, d = 0;
3960
+ } = qt(u, t, r), c = t, p = 0;
3945
3961
  const f = {};
3946
- for (let m = 0; m < l.length; m++) {
3947
- const y = l[m];
3962
+ for (let d = 0; d < l.length; d++) {
3963
+ const y = l[d];
3948
3964
  if (!y)
3949
3965
  continue;
3950
3966
  const {
3951
- name: j,
3952
- fn: Z
3967
+ name: b,
3968
+ fn: A
3953
3969
  } = y, {
3954
3970
  x: I,
3955
3971
  y: w,
3956
3972
  data: J,
3957
3973
  reset: k
3958
- } = await Z({
3974
+ } = await A({
3959
3975
  x: g,
3960
3976
  y: a,
3961
3977
  initialPlacement: t,
@@ -3969,17 +3985,17 @@ const Or = 50, Yr = async (e, n, i) => {
3969
3985
  floating: n
3970
3986
  }
3971
3987
  });
3972
- g = I ?? g, a = w ?? a, f[j] = {
3973
- ...f[j],
3988
+ g = I ?? g, a = w ?? a, f[b] = {
3989
+ ...f[b],
3974
3990
  ...J
3975
- }, k && d < Or && (d++, typeof k == "object" && (k.placement && (c = k.placement), k.rects && (u = k.rects === !0 ? await s.getElementRects({
3991
+ }, k && p < Or && (p++, typeof k == "object" && (k.placement && (c = k.placement), k.rects && (u = k.rects === !0 ? await s.getElementRects({
3976
3992
  reference: e,
3977
3993
  floating: n,
3978
3994
  strategy: o
3979
3995
  }) : k.rects), {
3980
3996
  x: g,
3981
3997
  y: a
3982
- } = qt(u, c, r)), m = -1);
3998
+ } = qt(u, c, r)), d = -1);
3983
3999
  }
3984
4000
  return {
3985
4001
  x: g,
@@ -4009,20 +4025,20 @@ const Or = 50, Yr = async (e, n, i) => {
4009
4025
  const a = Fi(g), c = {
4010
4026
  x: i,
4011
4027
  y: t
4012
- }, d = Ri(o), f = Ni(d), m = await s.getDimensions(u), y = d === "y", j = y ? "top" : "left", Z = y ? "bottom" : "right", I = y ? "clientHeight" : "clientWidth", w = l.reference[f] + l.reference[d] - c[d] - l.floating[f], J = c[d] - l.reference[d], k = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(u));
4028
+ }, p = Ri(o), f = Ni(p), d = await s.getDimensions(u), y = p === "y", b = y ? "top" : "left", A = y ? "bottom" : "right", I = y ? "clientHeight" : "clientWidth", w = l.reference[f] + l.reference[p] - c[p] - l.floating[f], J = c[p] - l.reference[p], k = await (s.getOffsetParent == null ? void 0 : s.getOffsetParent(u));
4013
4029
  let G = k ? k[I] : 0;
4014
4030
  (!G || !await (s.isElement == null ? void 0 : s.isElement(k))) && (G = h.floating[I] || l.floating[f]);
4015
- const M = w / 2 - J / 2, V = G / 2 - m[f] / 2 - 1, q = Yn(a[j], V), p = Yn(a[Z], V), W = G - m[f] - p, O = G / 2 - m[f] / 2 + M, v = So(q, O, W), C = !r.arrow && In(o) != null && O !== v && l.reference[f] / 2 - (O < q ? q : p) - m[f] / 2 < 0, z = C ? O < q ? O - q : O - W : 0;
4031
+ const M = w / 2 - J / 2, V = G / 2 - d[f] / 2 - 1, S = Yn(a[b], V), m = Yn(a[A], V), C = G - d[f] - m, W = G / 2 - d[f] / 2 + M, j = So(S, W, C), x = !r.arrow && In(o) != null && W !== j && l.reference[f] / 2 - (W < S ? S : m) - d[f] / 2 < 0, q = x ? W < S ? W - S : W - C : 0;
4016
4032
  return {
4017
- [d]: c[d] + z,
4033
+ [p]: c[p] + q,
4018
4034
  data: {
4019
- [d]: v,
4020
- centerOffset: O - v - z,
4021
- ...C && {
4022
- alignmentOffset: z
4035
+ [p]: j,
4036
+ centerOffset: W - j - q,
4037
+ ...x && {
4038
+ alignmentOffset: q
4023
4039
  }
4024
4040
  },
4025
- reset: C
4041
+ reset: x
4026
4042
  };
4027
4043
  }
4028
4044
  });
@@ -4045,21 +4061,21 @@ const Vr = function(e) {
4045
4061
  crossAxis: g = !1,
4046
4062
  alignment: a,
4047
4063
  allowedPlacements: c = pt,
4048
- autoAlignment: d = !0,
4064
+ autoAlignment: p = !0,
4049
4065
  ...f
4050
- } = Nn(e, n), m = a !== void 0 || c === pt ? Kr(a || null, d, c) : c, y = ((i = s.autoPlacement) == null ? void 0 : i.index) || 0, j = m[y];
4051
- if (j == null)
4066
+ } = Nn(e, n), d = a !== void 0 || c === pt ? Kr(a || null, p, c) : c, y = ((i = s.autoPlacement) == null ? void 0 : i.index) || 0, b = d[y];
4067
+ if (b == null)
4052
4068
  return {};
4053
- if (h !== j)
4069
+ if (h !== b)
4054
4070
  return {
4055
4071
  reset: {
4056
- placement: m[0]
4072
+ placement: d[0]
4057
4073
  }
4058
4074
  };
4059
- const Z = await r.detectOverflow(n, f), I = Yo(j, l, await (r.isRTL == null ? void 0 : r.isRTL(u.floating))), w = [Z[Wn(j)], Z[I[0]], Z[I[1]]], J = [...((t = s.autoPlacement) == null ? void 0 : t.overflows) || [], {
4060
- placement: j,
4075
+ const A = await r.detectOverflow(n, f), I = Yo(b, l, await (r.isRTL == null ? void 0 : r.isRTL(u.floating))), w = [A[Wn(b)], A[I[0]], A[I[1]]], J = [...((t = s.autoPlacement) == null ? void 0 : t.overflows) || [], {
4076
+ placement: b,
4061
4077
  overflows: w
4062
- }], k = m[y + 1];
4078
+ }], k = d[y + 1];
4063
4079
  if (k)
4064
4080
  return {
4065
4081
  data: {
@@ -4070,21 +4086,21 @@ const Vr = function(e) {
4070
4086
  placement: k
4071
4087
  }
4072
4088
  };
4073
- const G = J.map((q) => {
4074
- const p = In(q.placement);
4075
- return [q.placement, p && g ? (
4089
+ const G = J.map((S) => {
4090
+ const m = In(S.placement);
4091
+ return [S.placement, m && g ? (
4076
4092
  // Check along the mainAxis and main crossAxis side.
4077
- q.overflows.slice(0, 2).reduce((W, O) => W + O, 0)
4093
+ S.overflows.slice(0, 2).reduce((C, W) => C + W, 0)
4078
4094
  ) : (
4079
4095
  // Check only the mainAxis.
4080
- q.overflows[0]
4081
- ), q.overflows];
4082
- }).sort((q, p) => q[1] - p[1]), V = ((o = G.filter((q) => q[2].slice(
4096
+ S.overflows[0]
4097
+ ), S.overflows];
4098
+ }).sort((S, m) => S[1] - m[1]), V = ((o = G.filter((S) => S[2].slice(
4083
4099
  0,
4084
4100
  // Aligned placements should not check their opposite crossAxis
4085
4101
  // side.
4086
- In(q[0]) ? 2 : 3
4087
- ).every((p) => p <= 0))[0]) == null ? void 0 : o[0]) || G[0][0];
4102
+ In(S[0]) ? 2 : 3
4103
+ ).every((m) => m <= 0))[0]) == null ? void 0 : o[0]) || G[0][0];
4088
4104
  return V !== h ? {
4089
4105
  data: {
4090
4106
  index: y + 1,
@@ -4113,64 +4129,64 @@ const Vr = function(e) {
4113
4129
  mainAxis: g = !0,
4114
4130
  crossAxis: a = !0,
4115
4131
  fallbackPlacements: c,
4116
- fallbackStrategy: d = "bestFit",
4132
+ fallbackStrategy: p = "bestFit",
4117
4133
  fallbackAxisSideDirection: f = "none",
4118
- flipAlignment: m = !0,
4134
+ flipAlignment: d = !0,
4119
4135
  ...y
4120
4136
  } = Nn(e, n);
4121
4137
  if ((i = l.arrow) != null && i.alignmentOffset)
4122
4138
  return {};
4123
- const j = Wn(o), Z = Sn(h), I = Wn(h) === h, w = await (r.isRTL == null ? void 0 : r.isRTL(u.floating)), J = c || (I || !m ? [De(h)] : Zr(h)), k = f !== "none";
4124
- !c && k && J.push(...Wr(h, m, f, w));
4139
+ const b = Wn(o), A = Sn(h), I = Wn(h) === h, w = await (r.isRTL == null ? void 0 : r.isRTL(u.floating)), J = c || (I || !d ? [De(h)] : Zr(h)), k = f !== "none";
4140
+ !c && k && J.push(...Wr(h, d, f, w));
4125
4141
  const G = [h, ...J], M = await r.detectOverflow(n, y), V = [];
4126
- let q = ((t = l.flip) == null ? void 0 : t.overflows) || [];
4127
- if (g && V.push(M[j]), a) {
4128
- const v = Yo(o, s, w);
4129
- V.push(M[v[0]], M[v[1]]);
4142
+ let S = ((t = l.flip) == null ? void 0 : t.overflows) || [];
4143
+ if (g && V.push(M[b]), a) {
4144
+ const j = Yo(o, s, w);
4145
+ V.push(M[j[0]], M[j[1]]);
4130
4146
  }
4131
- if (q = [...q, {
4147
+ if (S = [...S, {
4132
4148
  placement: o,
4133
4149
  overflows: V
4134
- }], !V.every((v) => v <= 0)) {
4135
- var p, W;
4136
- const v = (((p = l.flip) == null ? void 0 : p.index) || 0) + 1, C = G[v];
4137
- if (C && (!(a === "alignment" ? Z !== Sn(C) : !1) || // We leave the current main axis only if every placement on that axis
4150
+ }], !V.every((j) => j <= 0)) {
4151
+ var m, C;
4152
+ const j = (((m = l.flip) == null ? void 0 : m.index) || 0) + 1, x = G[j];
4153
+ if (x && (!(a === "alignment" ? A !== Sn(x) : !1) || // We leave the current main axis only if every placement on that axis
4138
4154
  // overflows the main axis.
4139
- q.every((x) => Sn(x.placement) === Z ? x.overflows[0] > 0 : !0)))
4155
+ S.every((Z) => Sn(Z.placement) === A ? Z.overflows[0] > 0 : !0)))
4140
4156
  return {
4141
4157
  data: {
4142
- index: v,
4143
- overflows: q
4158
+ index: j,
4159
+ overflows: S
4144
4160
  },
4145
4161
  reset: {
4146
- placement: C
4162
+ placement: x
4147
4163
  }
4148
4164
  };
4149
- let z = (W = q.filter((S) => S.overflows[0] <= 0).sort((S, x) => S.overflows[1] - x.overflows[1])[0]) == null ? void 0 : W.placement;
4150
- if (!z)
4151
- switch (d) {
4165
+ let q = (C = S.filter((O) => O.overflows[0] <= 0).sort((O, Z) => O.overflows[1] - Z.overflows[1])[0]) == null ? void 0 : C.placement;
4166
+ if (!q)
4167
+ switch (p) {
4152
4168
  case "bestFit": {
4153
- var O;
4154
- const S = (O = q.filter((x) => {
4169
+ var W;
4170
+ const O = (W = S.filter((Z) => {
4155
4171
  if (k) {
4156
- const X = Sn(x.placement);
4157
- return X === Z || // Create a bias to the `y` side axis due to horizontal
4172
+ const X = Sn(Z.placement);
4173
+ return X === A || // Create a bias to the `y` side axis due to horizontal
4158
4174
  // reading directions favoring greater width.
4159
4175
  X === "y";
4160
4176
  }
4161
4177
  return !0;
4162
- }).map((x) => [x.placement, x.overflows.filter((X) => X > 0).reduce((X, R) => X + R, 0)]).sort((x, X) => x[1] - X[1])[0]) == null ? void 0 : O[0];
4163
- S && (z = S);
4178
+ }).map((Z) => [Z.placement, Z.overflows.filter((X) => X > 0).reduce((X, R) => X + R, 0)]).sort((Z, X) => Z[1] - X[1])[0]) == null ? void 0 : W[0];
4179
+ O && (q = O);
4164
4180
  break;
4165
4181
  }
4166
4182
  case "initialPlacement":
4167
- z = h;
4183
+ q = h;
4168
4184
  break;
4169
4185
  }
4170
- if (o !== z)
4186
+ if (o !== q)
4171
4187
  return {
4172
4188
  reset: {
4173
- placement: z
4189
+ placement: q
4174
4190
  }
4175
4191
  };
4176
4192
  }
@@ -4268,40 +4284,40 @@ const Hr = function(e) {
4268
4284
  } = Nn(e, n), g = Array.from(await (l.getClientRects == null ? void 0 : l.getClientRects(t.reference)) || []);
4269
4285
  if (!g.length)
4270
4286
  return {};
4271
- const a = Jr(g), c = Fn(ko(g)), d = Fi(h);
4287
+ const a = Jr(g), c = Fn(ko(g)), p = Fi(h);
4272
4288
  function f() {
4273
4289
  if (a.length === 2 && (a[0].left > a[1].right || a[1].left > a[0].right) && r != null && u != null)
4274
- return a.find((y) => r > y.left - d.left && r < y.right + d.right && u > y.top - d.top && u < y.bottom + d.bottom) || c;
4290
+ return a.find((y) => r > y.left - p.left && r < y.right + p.right && u > y.top - p.top && u < y.bottom + p.bottom) || c;
4275
4291
  if (a.length >= 2) {
4276
4292
  if (Sn(i) === "y") {
4277
- const k = a[0], G = a[a.length - 1], M = Wn(i) === "top", V = k.top, q = G.bottom, p = M ? k.left : G.left, W = M ? k.right : G.right;
4293
+ const k = a[0], G = a[a.length - 1], M = Wn(i) === "top", V = k.top, S = G.bottom, m = M ? k.left : G.left, C = M ? k.right : G.right;
4278
4294
  return Fn({
4279
- x: p,
4295
+ x: m,
4280
4296
  y: V,
4281
- width: W - p,
4282
- height: q - V
4297
+ width: C - m,
4298
+ height: S - V
4283
4299
  });
4284
4300
  }
4285
- const y = Wn(i) === "left", j = Cn(...a.map((k) => k.right)), Z = Yn(...a.map((k) => k.left)), I = a.filter((k) => y ? k.left === Z : k.right === j), w = I[0].top, J = I[I.length - 1].bottom;
4301
+ const y = Wn(i) === "left", b = Cn(...a.map((k) => k.right)), A = Yn(...a.map((k) => k.left)), I = a.filter((k) => y ? k.left === A : k.right === b), w = I[0].top, J = I[I.length - 1].bottom;
4286
4302
  return Fn({
4287
- x: Z,
4303
+ x: A,
4288
4304
  y: w,
4289
- width: j - Z,
4305
+ width: b - A,
4290
4306
  height: J - w
4291
4307
  });
4292
4308
  }
4293
4309
  return c;
4294
4310
  }
4295
- const m = await l.getElementRects({
4311
+ const d = await l.getElementRects({
4296
4312
  reference: {
4297
4313
  getBoundingClientRect: f
4298
4314
  },
4299
4315
  floating: t.floating,
4300
4316
  strategy: s
4301
4317
  });
4302
- return o.reference.x !== m.reference.x || o.reference.y !== m.reference.y || o.reference.width !== m.reference.width || o.reference.height !== m.reference.height ? {
4318
+ return o.reference.x !== d.reference.x || o.reference.y !== d.reference.y || o.reference.width !== d.reference.width || o.reference.height !== d.reference.height ? {
4303
4319
  reset: {
4304
- rects: m
4320
+ rects: d
4305
4321
  }
4306
4322
  } : {};
4307
4323
  }
@@ -4315,7 +4331,7 @@ async function Mr(e, n) {
4315
4331
  } = e, l = await (t.isRTL == null ? void 0 : t.isRTL(o.floating)), s = Wn(i), h = In(i), r = Sn(i) === "y", u = Lr.has(s) ? -1 : 1, g = l && r ? -1 : 1, a = Nn(n, e);
4316
4332
  let {
4317
4333
  mainAxis: c,
4318
- crossAxis: d,
4334
+ crossAxis: p,
4319
4335
  alignmentAxis: f
4320
4336
  } = typeof a == "number" ? {
4321
4337
  mainAxis: a,
@@ -4326,12 +4342,12 @@ async function Mr(e, n) {
4326
4342
  crossAxis: a.crossAxis || 0,
4327
4343
  alignmentAxis: a.alignmentAxis
4328
4344
  };
4329
- return h && typeof f == "number" && (d = h === "end" ? f * -1 : f), r ? {
4330
- x: d * g,
4345
+ return h && typeof f == "number" && (p = h === "end" ? f * -1 : f), r ? {
4346
+ x: p * g,
4331
4347
  y: c * u
4332
4348
  } : {
4333
4349
  x: c * u,
4334
- y: d * g
4350
+ y: p * g
4335
4351
  };
4336
4352
  }
4337
4353
  const Tr = function(e) {
@@ -4370,11 +4386,11 @@ const Tr = function(e) {
4370
4386
  mainAxis: s = !0,
4371
4387
  crossAxis: h = !1,
4372
4388
  limiter: r = {
4373
- fn: (Z) => {
4389
+ fn: (A) => {
4374
4390
  let {
4375
4391
  x: I,
4376
4392
  y: w
4377
- } = Z;
4393
+ } = A;
4378
4394
  return {
4379
4395
  x: I,
4380
4396
  y: w
@@ -4385,22 +4401,22 @@ const Tr = function(e) {
4385
4401
  } = Nn(e, n), g = {
4386
4402
  x: i,
4387
4403
  y: t
4388
- }, a = await l.detectOverflow(n, u), c = Sn(o), d = Oo(c);
4389
- let f = g[d], m = g[c];
4390
- const y = (Z, I) => So(I + a[Z === "y" ? "top" : "left"], I, I - a[Z === "y" ? "bottom" : "right"]);
4391
- s && (f = y(d, f)), h && (m = y(c, m));
4392
- const j = r.fn({
4404
+ }, a = await l.detectOverflow(n, u), c = Sn(o), p = Oo(c);
4405
+ let f = g[p], d = g[c];
4406
+ const y = (A, I) => So(I + a[A === "y" ? "top" : "left"], I, I - a[A === "y" ? "bottom" : "right"]);
4407
+ s && (f = y(p, f)), h && (d = y(c, d));
4408
+ const b = r.fn({
4393
4409
  ...n,
4394
- [d]: f,
4395
- [c]: m
4410
+ [p]: f,
4411
+ [c]: d
4396
4412
  });
4397
4413
  return {
4398
- ...j,
4414
+ ...b,
4399
4415
  data: {
4400
- x: j.x - i,
4401
- y: j.y - t,
4416
+ x: b.x - i,
4417
+ y: b.y - t,
4402
4418
  enabled: {
4403
- [d]: s,
4419
+ [p]: s,
4404
4420
  [c]: h
4405
4421
  }
4406
4422
  }
@@ -4423,19 +4439,19 @@ const Tr = function(e) {
4423
4439
  ...h
4424
4440
  } = Nn(e, n), r = await o.detectOverflow(n, h), u = Wn(i), g = In(i), a = Sn(i) === "y", {
4425
4441
  width: c,
4426
- height: d
4442
+ height: p
4427
4443
  } = t.floating;
4428
- let f, m;
4429
- u === "top" || u === "bottom" ? (f = u, m = g === (await (o.isRTL == null ? void 0 : o.isRTL(l.floating)) ? "start" : "end") ? "left" : "right") : (m = u, f = g === "end" ? "top" : "bottom");
4430
- const y = d - r.top - r.bottom, j = c - r.left - r.right, Z = Yn(d - r[f], y), I = Yn(c - r[m], j), w = n.middlewareData.shift, J = !w;
4431
- let k = Z, G = I;
4432
- w != null && w.enabled.x && (G = j), w != null && w.enabled.y && (k = y), J && !g && (a ? G = c - 2 * Cn(r.left, r.right) : k = d - 2 * Cn(r.top, r.bottom)), await s({
4444
+ let f, d;
4445
+ u === "top" || u === "bottom" ? (f = u, d = g === (await (o.isRTL == null ? void 0 : o.isRTL(l.floating)) ? "start" : "end") ? "left" : "right") : (d = u, f = g === "end" ? "top" : "bottom");
4446
+ const y = p - r.top - r.bottom, b = c - r.left - r.right, A = Yn(p - r[f], y), I = Yn(c - r[d], b), w = n.middlewareData.shift, J = !w;
4447
+ let k = A, G = I;
4448
+ w != null && w.enabled.x && (G = b), w != null && w.enabled.y && (k = y), J && !g && (a ? G = c - 2 * Cn(r.left, r.right) : k = p - 2 * Cn(r.top, r.bottom)), await s({
4433
4449
  ...n,
4434
4450
  availableWidth: G,
4435
4451
  availableHeight: k
4436
4452
  });
4437
4453
  const M = await o.getDimensions(l.floating);
4438
- return c !== M.width || d !== M.height ? {
4454
+ return c !== M.width || p !== M.height ? {
4439
4455
  reset: {
4440
4456
  rects: !0
4441
4457
  }
@@ -4600,11 +4616,11 @@ function Ie(e, n, i, t) {
4600
4616
  const h = Br(l, i, t) ? Ho(l) : Mn(0);
4601
4617
  let r = (o.left + h.x) / s.x, u = (o.top + h.y) / s.y, g = o.width / s.x, a = o.height / s.y;
4602
4618
  if (l && t) {
4603
- const c = fn(l), d = kn(t) ? fn(t) : t;
4604
- let f = c, m = Ii(f);
4605
- for (; m && d !== f; ) {
4606
- const y = ue(m), j = m.getBoundingClientRect(), Z = Kn(m), I = j.left + (m.clientLeft + parseFloat(Z.paddingLeft)) * y.x, w = j.top + (m.clientTop + parseFloat(Z.paddingTop)) * y.y;
4607
- r *= y.x, u *= y.y, g *= y.x, a *= y.y, r += I, u += w, f = fn(m), m = Ii(f);
4619
+ const c = fn(l), p = kn(t) ? fn(t) : t;
4620
+ let f = c, d = Ii(f);
4621
+ for (; d && p !== f; ) {
4622
+ const y = ue(d), b = d.getBoundingClientRect(), A = Kn(d), I = b.left + (d.clientLeft + parseFloat(A.paddingLeft)) * y.x, w = b.top + (d.clientTop + parseFloat(A.paddingTop)) * y.y;
4623
+ r *= y.x, u *= y.y, g *= y.x, a *= y.y, r += I, u += w, f = fn(d), d = Ii(f);
4608
4624
  }
4609
4625
  }
4610
4626
  return Fn({
@@ -4641,8 +4657,8 @@ function Qr(e) {
4641
4657
  }, u = Mn(1);
4642
4658
  const g = Mn(0), a = Dn(t);
4643
4659
  if ((a || !l) && ((me(t) !== "body" || ei(s)) && (r = ti(t)), a)) {
4644
- const d = Ie(t);
4645
- u = ue(t), g.x = d.x + t.clientLeft, g.y = d.y + t.clientTop;
4660
+ const p = Ie(t);
4661
+ u = ue(t), g.x = p.x + t.clientLeft, g.y = p.y + t.clientTop;
4646
4662
  }
4647
4663
  const c = s && !a && !l ? Lo(s, r) : Mn(0);
4648
4664
  return {
@@ -4676,8 +4692,8 @@ function eu(e, n, i) {
4676
4692
  t ? c || (u = -s.offsetLeft, g = -s.offsetTop) : (h = s.width, r = s.height, c && (u = s.offsetLeft, g = s.offsetTop));
4677
4693
  }
4678
4694
  if (oi(l) <= 0) {
4679
- const c = l.ownerDocument, d = c.body, f = getComputedStyle(d), m = c.compatMode === "CSS1Compat" && parseFloat(f.marginLeft) + parseFloat(f.marginRight) || 0, y = Math.abs(l.clientWidth - d.clientWidth - m), j = getComputedStyle(l).scrollbarGutter === "stable both-edges" ? y / 2 : y;
4680
- j <= nu && (h -= j);
4695
+ const c = l.ownerDocument, p = c.body, f = getComputedStyle(p), d = c.compatMode === "CSS1Compat" && parseFloat(f.marginLeft) + parseFloat(f.marginRight) || 0, y = Math.abs(l.clientWidth - p.clientWidth - d), b = getComputedStyle(l).scrollbarGutter === "stable both-edges" ? y / 2 : y;
4696
+ b <= nu && (h -= b);
4681
4697
  }
4682
4698
  return {
4683
4699
  width: h,
@@ -4737,8 +4753,8 @@ function ou(e) {
4737
4753
  const s = [...i === "clippingAncestors" ? ii(n) ? [] : tu(n, this._c) : [].concat(i), t], h = vt(n, s[0], o);
4738
4754
  let r = h.top, u = h.right, g = h.bottom, a = h.left;
4739
4755
  for (let c = 1; c < s.length; c++) {
4740
- const d = vt(n, s[c], o);
4741
- r = Cn(d.top, r), u = Yn(d.right, u), g = Yn(d.bottom, g), a = Cn(d.left, a);
4756
+ const p = vt(n, s[c], o);
4757
+ r = Cn(p.top, r), u = Yn(p.right, u), g = Yn(p.bottom, g), a = Cn(p.left, a);
4742
4758
  }
4743
4759
  return {
4744
4760
  width: u - a,
@@ -5069,13 +5085,13 @@ function qu(e) {
5069
5085
  for (let f = 0; ; f++) {
5070
5086
  for (; o < t.length && t[o] != 0; ) o++;
5071
5087
  if (f == a.childCount) break;
5072
- const m = a.child(f), { colspan: y, rowspan: j, colwidth: Z } = m.attrs;
5073
- for (let I = 0; I < j; I++) {
5088
+ const d = a.child(f), { colspan: y, rowspan: b, colwidth: A } = d.attrs;
5089
+ for (let I = 0; I < b; I++) {
5074
5090
  if (I + u >= i) {
5075
5091
  (l || (l = [])).push({
5076
5092
  type: "overlong_rowspan",
5077
5093
  pos: g,
5078
- n: j - I
5094
+ n: b - I
5079
5095
  });
5080
5096
  break;
5081
5097
  }
@@ -5087,22 +5103,22 @@ function qu(e) {
5087
5103
  pos: g,
5088
5104
  n: y - J
5089
5105
  });
5090
- const k = Z && Z[J];
5106
+ const k = A && A[J];
5091
5107
  if (k) {
5092
5108
  const G = (w + J) % n * 2, M = s[G];
5093
5109
  M == null || M != k && s[G + 1] == 1 ? (s[G] = k, s[G + 1] = 1) : M == k && s[G + 1]++;
5094
5110
  }
5095
5111
  }
5096
5112
  }
5097
- o += y, g += m.nodeSize;
5113
+ o += y, g += d.nodeSize;
5098
5114
  }
5099
5115
  const c = (u + 1) * n;
5100
- let d = 0;
5101
- for (; o < c; ) t[o++] == 0 && d++;
5102
- d && (l || (l = [])).push({
5116
+ let p = 0;
5117
+ for (; o < c; ) t[o++] == 0 && p++;
5118
+ p && (l || (l = [])).push({
5103
5119
  type: "missing",
5104
5120
  row: u,
5105
- n: d
5121
+ n: p
5106
5122
  }), g++;
5107
5123
  }
5108
5124
  (n === 0 || i === 0) && (l || (l = [])).push({ type: "zero_sized" });
@@ -5243,22 +5259,22 @@ var On = class Gn extends B {
5243
5259
  const c = i.map[g];
5244
5260
  if (l[c]) continue;
5245
5261
  l[c] = !0;
5246
- const d = i.findCell(c);
5262
+ const p = i.findCell(c);
5247
5263
  let f = n.nodeAt(c);
5248
5264
  if (!f) throw new RangeError(`No cell with offset ${c} found`);
5249
- const m = o.left - d.left, y = d.right - o.right;
5250
- if (m > 0 || y > 0) {
5251
- let j = f.attrs;
5252
- if (m > 0 && (j = xt(j, 0, m)), y > 0 && (j = xt(j, j.colspan - y, y)), d.left < o.left) {
5253
- if (f = f.type.createAndFill(j), !f) throw new RangeError(`Could not create cell with attrs ${JSON.stringify(j)}`);
5254
- } else f = f.type.create(j, f.content);
5265
+ const d = o.left - p.left, y = p.right - o.right;
5266
+ if (d > 0 || y > 0) {
5267
+ let b = f.attrs;
5268
+ if (d > 0 && (b = xt(b, 0, d)), y > 0 && (b = xt(b, b.colspan - y, y)), p.left < o.left) {
5269
+ if (f = f.type.createAndFill(b), !f) throw new RangeError(`Could not create cell with attrs ${JSON.stringify(b)}`);
5270
+ } else f = f.type.create(b, f.content);
5255
5271
  }
5256
- if (d.top < o.top || d.bottom > o.bottom) {
5257
- const j = {
5272
+ if (p.top < o.top || p.bottom > o.bottom) {
5273
+ const b = {
5258
5274
  ...f.attrs,
5259
- rowspan: Math.min(d.bottom, o.bottom) - Math.max(d.top, o.top)
5275
+ rowspan: Math.min(p.bottom, o.bottom) - Math.max(p.top, o.top)
5260
5276
  };
5261
- d.top < o.top ? f = f.type.createAndFill(j) : f = f.type.create(j, f.content);
5277
+ p.top < o.top ? f = f.type.createAndFill(b) : f = f.type.create(b, f.content);
5262
5278
  }
5263
5279
  u.push(f);
5264
5280
  }
@@ -5398,8 +5414,8 @@ function Di(e, n) {
5398
5414
  bottom: 1
5399
5415
  } : l, a = e == "column" ? r ? o.cell : o.header_cell : e == "row" ? h ? o.cell : o.header_cell : o.cell;
5400
5416
  l.map.cellsInRect(g).forEach((c) => {
5401
- const d = c + l.tableStart, f = s.doc.nodeAt(d);
5402
- f && s.setNodeMarkup(d, a, f.attrs);
5417
+ const p = c + l.tableStart, f = s.doc.nodeAt(p);
5418
+ f && s.setNodeMarkup(p, a, f.attrs);
5403
5419
  }), t(s);
5404
5420
  }
5405
5421
  return !0;
@@ -5516,11 +5532,11 @@ var Wu = class {
5516
5532
  }, this.shouldShow = ({
5517
5533
  view: a,
5518
5534
  state: c,
5519
- from: d,
5535
+ from: p,
5520
5536
  to: f
5521
5537
  }) => {
5522
- const { doc: m, selection: y } = c, { empty: j } = y, Z = !m.textBetween(d, f).length && Gl(c.selection), I = this.element.contains(document.activeElement);
5523
- return !(!(a.hasFocus() || I) || j || Z || !this.editor.isEditable);
5538
+ const { doc: d, selection: y } = c, { empty: b } = y, A = !d.textBetween(p, f).length && Gl(c.selection), I = this.element.contains(document.activeElement);
5539
+ return !(!(a.hasFocus() || I) || b || A || !this.editor.isEditable);
5524
5540
  }, this.mousedownHandler = () => {
5525
5541
  this.preventHide = !0;
5526
5542
  }, this.dragstartHandler = () => {
@@ -5543,13 +5559,13 @@ var Wu = class {
5543
5559
  }
5544
5560
  a != null && a.relatedTarget && ((c = this.element.parentNode) != null && c.contains(a.relatedTarget)) || (a == null ? void 0 : a.relatedTarget) !== this.editor.view.dom && this.hide();
5545
5561
  }, this.handleDebouncedUpdate = (a, c) => {
5546
- const d = !(c != null && c.selection.eq(a.state.selection)), f = !(c != null && c.doc.eq(a.state.doc));
5547
- !d && !f || (this.updateDebounceTimer && clearTimeout(this.updateDebounceTimer), this.updateDebounceTimer = window.setTimeout(() => {
5548
- this.updateHandler(a, d, f, c);
5562
+ const p = !(c != null && c.selection.eq(a.state.selection)), f = !(c != null && c.doc.eq(a.state.doc));
5563
+ !p && !f || (this.updateDebounceTimer && clearTimeout(this.updateDebounceTimer), this.updateDebounceTimer = window.setTimeout(() => {
5564
+ this.updateHandler(a, p, f, c);
5549
5565
  }, this.updateDelay));
5550
- }, this.updateHandler = (a, c, d, f) => {
5551
- const { composing: m } = a;
5552
- if (m || !c && !d)
5566
+ }, this.updateHandler = (a, c, p, f) => {
5567
+ const { composing: d } = a;
5568
+ if (d || !c && !p)
5553
5569
  return;
5554
5570
  if (!this.getShouldShow(f)) {
5555
5571
  this.hide();
@@ -5622,13 +5638,13 @@ var Wu = class {
5622
5638
  const { $anchorCell: h, $headCell: r } = t, u = h ? h.pos : r.pos, g = r ? r.pos : h.pos, a = this.view.nodeDOM(u), c = this.view.nodeDOM(g);
5623
5639
  if (!a || !c)
5624
5640
  return;
5625
- const d = a === c ? a.getBoundingClientRect() : Iu(
5641
+ const p = a === c ? a.getBoundingClientRect() : Iu(
5626
5642
  a.getBoundingClientRect(),
5627
5643
  c.getBoundingClientRect()
5628
5644
  );
5629
5645
  s = {
5630
- getBoundingClientRect: () => d,
5631
- getClientRects: () => [d]
5646
+ getBoundingClientRect: () => p,
5647
+ getClientRects: () => [p]
5632
5648
  };
5633
5649
  }
5634
5650
  return s;
@@ -5750,12 +5766,12 @@ var Wu = class {
5750
5766
  shouldShow: g,
5751
5767
  getReferencedVirtualElement: a,
5752
5768
  updateDelay: c
5753
- } = e, d = o.value;
5754
- d && (d.style.visibility = "hidden", d.style.position = "absolute", d.remove(), de(() => {
5769
+ } = e, p = o.value;
5770
+ p && (p.style.visibility = "hidden", p.style.position = "absolute", p.remove(), de(() => {
5755
5771
  s.registerPlugin(
5756
5772
  wu({
5757
5773
  editor: s,
5758
- element: d,
5774
+ element: p,
5759
5775
  options: h,
5760
5776
  pluginKey: l,
5761
5777
  resizeDelay: r,
@@ -5787,8 +5803,8 @@ var Wu = class {
5787
5803
  shouldShow: r
5788
5804
  }) {
5789
5805
  this.preventHide = !1, this.isVisible = !1, this.scrollTarget = window, this.shouldShow = ({ view: g, state: a }) => {
5790
- const { selection: c } = a, { $anchor: d, empty: f } = c, m = d.depth === 1, y = d.parent.isTextblock && !d.parent.type.spec.code && !d.parent.textContent && d.parent.childCount === 0 && !this.getTextContent(d.parent);
5791
- return !(!g.hasFocus() || !f || !m || !y || !this.editor.isEditable);
5806
+ const { selection: c } = a, { $anchor: p, empty: f } = c, d = p.depth === 1, y = p.parent.isTextblock && !p.parent.type.spec.code && !p.parent.textContent && p.parent.childCount === 0 && !this.getTextContent(p.parent);
5807
+ return !(!g.hasFocus() || !f || !d || !y || !this.editor.isEditable);
5792
5808
  }, this.floatingUIOptions = {
5793
5809
  strategy: "absolute",
5794
5810
  placement: "right",
@@ -5800,11 +5816,11 @@ var Wu = class {
5800
5816
  autoPlacement: !1,
5801
5817
  hide: !1,
5802
5818
  inline: !1
5803
- }, this.updateHandler = (g, a, c, d) => {
5819
+ }, this.updateHandler = (g, a, c, p) => {
5804
5820
  const { composing: f } = g;
5805
5821
  if (f || !a && !c)
5806
5822
  return;
5807
- if (!this.getShouldShow(d)) {
5823
+ if (!this.getShouldShow(p)) {
5808
5824
  this.hide();
5809
5825
  return;
5810
5826
  }
@@ -6011,12 +6027,12 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6011
6027
  on: () => {
6012
6028
  a.abort();
6013
6029
  }
6014
- }), d = () => {
6030
+ }), p = () => {
6015
6031
  var y;
6016
6032
  (y = i.value) == null || y.view.dispatch(
6017
6033
  i.value.state.tr.setMeta(u, "hide")
6018
6034
  );
6019
- }, m = [
6035
+ }, d = [
6020
6036
  {
6021
6037
  label: "试听",
6022
6038
  value: "test",
@@ -6025,10 +6041,10 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6025
6041
  c.emit();
6026
6042
  const y = l();
6027
6043
  if (!y.timberId) return;
6028
- const Z = t();
6029
- if (!Z) return;
6030
- const I = Yi(Z);
6031
- d(), await a.execute({
6044
+ const A = t();
6045
+ if (!A) return;
6046
+ const I = Yi(A);
6047
+ p(), await a.execute({
6032
6048
  ...y,
6033
6049
  ...I,
6034
6050
  partialPreview: !0
@@ -6039,25 +6055,25 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6039
6055
  }
6040
6056
  }
6041
6057
  ];
6042
- return (y, j) => r.value ? (Y(), L("div", ku, [
6043
- b(i) ? (Y(), _(b(Su), {
6058
+ return (y, b) => r.value ? (Y(), L("div", ku, [
6059
+ z(i) ? (Y(), _(z(Su), {
6044
6060
  key: 0,
6045
6061
  "plugin-key": u,
6046
- editor: b(i),
6047
- "get-referenced-virtual-element": b(o),
6062
+ editor: z(i),
6063
+ "get-referenced-virtual-element": z(o),
6048
6064
  class: "lsh-menu-box"
6049
6065
  }, {
6050
6066
  default: N(() => [
6051
- (Y(), L(en, null, gn(m, (Z) => A("button", {
6052
- key: Z.value,
6067
+ (Y(), L(en, null, gn(d, (A) => v("button", {
6068
+ key: A.value,
6053
6069
  type: "button",
6054
6070
  class: "lsh-menu-item",
6055
- onClick: Z.onClick
6056
- }, F(Z.label), 9, Ku)), 64))
6071
+ onClick: A.onClick
6072
+ }, F(A.label), 9, Ku)), 64))
6057
6073
  ]),
6058
6074
  _: 1
6059
6075
  }, 8, ["editor", "get-referenced-virtual-element"])) : yn("", !0),
6060
- A("audio", {
6076
+ v("audio", {
6061
6077
  ref_key: "audioRef",
6062
6078
  ref: g,
6063
6079
  preload: "metadata"
@@ -6074,6 +6090,7 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6074
6090
  features: { default: () => ({}) },
6075
6091
  services: { default: () => ({}) },
6076
6092
  getPreviewParams: {},
6093
+ getPlaybackSpeed: {},
6077
6094
  showSelectionMenu: { type: Boolean, default: !0 },
6078
6095
  initialContent: { default: Jn }
6079
6096
  },
@@ -6083,19 +6100,23 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6083
6100
  content: t.initialContent,
6084
6101
  textLimitLength: t.textLimit,
6085
6102
  getGenerateAudioParams: () => {
6086
- var m;
6087
- return ((m = t.getPreviewParams) == null ? void 0 : m.call(t)) ?? {};
6103
+ var d;
6104
+ return ((d = t.getPreviewParams) == null ? void 0 : d.call(t)) ?? {};
6105
+ },
6106
+ getPlaybackSpeed: () => {
6107
+ var d;
6108
+ return ((d = t.getPlaybackSpeed) == null ? void 0 : d.call(t)) ?? 1;
6088
6109
  },
6089
6110
  voiceVersion: l,
6090
6111
  placeholder: t.placeholder,
6091
6112
  editable: s,
6092
6113
  services: h,
6093
6114
  features: r,
6094
- onCreate: (m) => o("ready", m),
6115
+ onCreate: (d) => o("ready", d),
6095
6116
  onChange: () => o("change")
6096
6117
  }), { editor: g, clearContent: a, replaceContentWithText: c } = u;
6097
6118
  ur(u);
6098
- const { handleChangeVoice: d } = br({
6119
+ const { handleChangeVoice: p } = br({
6099
6120
  richTextEditor: u
6100
6121
  });
6101
6122
  return n({
@@ -6103,22 +6124,22 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6103
6124
  ...{
6104
6125
  clear: a,
6105
6126
  focus: () => {
6106
- var m;
6107
- return (m = g.value) == null ? void 0 : m.commands.focus();
6127
+ var d;
6128
+ return (d = g.value) == null ? void 0 : d.commands.focus();
6108
6129
  },
6109
6130
  getJson: () => {
6110
- var m;
6111
- return ((m = g.value) == null ? void 0 : m.getJSON()) ?? Jn();
6131
+ var d;
6132
+ return ((d = g.value) == null ? void 0 : d.getJSON()) ?? Jn();
6112
6133
  },
6113
6134
  getTtsData: () => {
6114
- var m;
6115
- return Yi(((m = g.value) == null ? void 0 : m.getJSON()) ?? Jn());
6135
+ var d;
6136
+ return Yi(((d = g.value) == null ? void 0 : d.getJSON()) ?? Jn());
6116
6137
  },
6117
6138
  replaceText: c,
6118
- handleChangeVoice: d
6139
+ handleChangeVoice: p
6119
6140
  }
6120
- }), (m, y) => (Y(), L(en, null, [
6121
- wn(m.$slots, "default"),
6141
+ }), (d, y) => (Y(), L(en, null, [
6142
+ wn(d.$slots, "default"),
6122
6143
  t.showSelectionMenu ? (Y(), _(Gu, { key: 0 })) : yn("", !0)
6123
6144
  ], 64));
6124
6145
  }
@@ -6136,22 +6157,22 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6136
6157
  emits: ["confirm"],
6137
6158
  setup(e, { expose: n, emit: i }) {
6138
6159
  const t = i, o = K(!1), l = K(), s = Tn(), { notify: h, services: r, textLimitLength: u } = s, g = Io({
6139
- runner: (W, O) => {
6140
- var v, C;
6141
- return ((C = (v = r.value).generateDraft) == null ? void 0 : C.call(
6142
- v,
6160
+ runner: (C, W) => {
6161
+ var j, x;
6162
+ return ((x = (j = r.value).generateDraft) == null ? void 0 : x.call(
6163
+ j,
6143
6164
  {
6144
- themeWord: String(W.themeWord ?? ""),
6145
- requireWord: String(W.requireWord ?? "")
6165
+ themeWord: String(C.themeWord ?? ""),
6166
+ requireWord: String(C.requireWord ?? "")
6146
6167
  },
6147
- O
6168
+ W
6148
6169
  )) ?? Promise.resolve();
6149
6170
  },
6150
6171
  scrollTarget: l
6151
- }), { loading: a, result: c } = g, d = K(""), f = K(""), { copy: m } = yh({ source: c }), y = K(!1), j = [
6172
+ }), { loading: a, result: c } = g, p = K(""), f = K(""), { copy: d } = yh({ source: c }), y = K(!1), b = [
6152
6173
  {
6153
6174
  label: "文稿主题",
6154
- modelValue: d,
6175
+ modelValue: p,
6155
6176
  placeholder: "请输入文稿主题...",
6156
6177
  inputHeight: 80,
6157
6178
  maxLength: 200
@@ -6167,152 +6188,152 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6167
6188
  inputHeight: 233,
6168
6189
  maxLength: 500
6169
6190
  }
6170
- ], Z = () => {
6191
+ ], A = () => {
6171
6192
  o.value = !o.value;
6172
6193
  }, I = () => {
6173
- Z();
6194
+ A();
6174
6195
  }, w = () => {
6175
- t("confirm", c.value), Z();
6196
+ t("confirm", c.value), A();
6176
6197
  }, J = async () => {
6177
6198
  try {
6178
- await m(), h("success", "复制成功");
6179
- } catch (W) {
6180
- console.log(W);
6199
+ await d(), h("success", "复制成功");
6200
+ } catch (C) {
6201
+ console.log(C);
6181
6202
  }
6182
6203
  }, k = async () => {
6183
6204
  try {
6184
6205
  await g.exec({
6185
- themeWord: d.value,
6206
+ themeWord: p.value,
6186
6207
  requireWord: f.value
6187
6208
  }), y.value = !0;
6188
6209
  } catch {
6189
6210
  }
6190
- }, G = T(() => !d.value || !f.value), M = T(() => u), V = T(() => c.value.length > M.value), q = T(() => a.value || !c.value), p = T(() => q.value || V.value);
6211
+ }, G = T(() => !p.value || !f.value), M = T(() => u), V = T(() => c.value.length > M.value), S = T(() => a.value || !c.value), m = T(() => S.value || V.value);
6191
6212
  return n({
6192
6213
  open: () => {
6193
- Z();
6214
+ A();
6194
6215
  }
6195
- }), (W, O) => (Y(), _(b(Oe), {
6216
+ }), (C, W) => (Y(), _(z(Oe), {
6196
6217
  modelValue: o.value,
6197
- "onUpdate:modelValue": O[1] || (O[1] = (v) => o.value = v),
6218
+ "onUpdate:modelValue": W[1] || (W[1] = (j) => o.value = j),
6198
6219
  width: 800,
6199
6220
  title: "AI写稿",
6200
6221
  class: "lsh-ai-modal"
6201
6222
  }, {
6202
6223
  footer: N(() => [
6203
- H(b(on), {
6224
+ H(z(on), {
6204
6225
  plain: "",
6205
6226
  onClick: I
6206
6227
  }, {
6207
- default: N(() => [...O[7] || (O[7] = [
6228
+ default: N(() => [...W[7] || (W[7] = [
6208
6229
  An("取消", -1)
6209
6230
  ])]),
6210
6231
  _: 1
6211
6232
  }),
6212
- H(b(on), {
6233
+ H(z(on), {
6213
6234
  plain: "",
6214
6235
  onClick: J,
6215
- disabled: q.value
6236
+ disabled: S.value
6216
6237
  }, {
6217
- default: N(() => [...O[8] || (O[8] = [
6238
+ default: N(() => [...W[8] || (W[8] = [
6218
6239
  An("复制", -1)
6219
6240
  ])]),
6220
6241
  _: 1
6221
6242
  }, 8, ["disabled"]),
6222
- H(b(on), {
6243
+ H(z(on), {
6223
6244
  type: "info",
6224
6245
  onClick: w,
6225
- disabled: p.value,
6226
- loading: b(a)
6246
+ disabled: m.value,
6247
+ loading: z(a)
6227
6248
  }, {
6228
- default: N(() => [...O[9] || (O[9] = [
6249
+ default: N(() => [...W[9] || (W[9] = [
6229
6250
  An(" 替换原文 ", -1)
6230
6251
  ])]),
6231
6252
  _: 1
6232
6253
  }, 8, ["disabled", "loading"])
6233
6254
  ]),
6234
6255
  default: N(() => [
6235
- A("div", Ju, [
6236
- A("div", Hu, [
6237
- A("div", Lu, [
6238
- O[4] || (O[4] = A("span", { class: "lsh-title" }, "文稿关键词", -1)),
6239
- b(a) ? (Y(), _(b(on), {
6256
+ v("div", Ju, [
6257
+ v("div", Hu, [
6258
+ v("div", Lu, [
6259
+ W[4] || (W[4] = v("span", { class: "lsh-title" }, "文稿关键词", -1)),
6260
+ z(a) ? (Y(), _(z(on), {
6240
6261
  key: 1,
6241
6262
  class: "lsh-text-btn red",
6242
- onClick: b(g).abort
6263
+ onClick: z(g).abort
6243
6264
  }, {
6244
6265
  icon: N(() => [
6245
- H(b(rn), { name: "editor-generate-stop" })
6266
+ H(z(rn), { name: "editor-generate-stop" })
6246
6267
  ]),
6247
6268
  default: N(() => [
6248
- O[3] || (O[3] = A("span", null, "停止生成 ", -1))
6269
+ W[3] || (W[3] = v("span", null, "停止生成 ", -1))
6249
6270
  ]),
6250
6271
  _: 1
6251
- }, 8, ["onClick"])) : (Y(), _(b(on), {
6272
+ }, 8, ["onClick"])) : (Y(), _(z(on), {
6252
6273
  key: 0,
6253
6274
  class: "lsh-text-btn blue",
6254
6275
  onClick: k,
6255
6276
  disabled: G.value
6256
6277
  }, {
6257
6278
  icon: N(() => [
6258
- H(b(rn), { name: "editor-send" })
6279
+ H(z(rn), { name: "editor-send" })
6259
6280
  ]),
6260
6281
  default: N(() => [
6261
- O[2] || (O[2] = A("span", null, "开始生成 ", -1))
6282
+ W[2] || (W[2] = v("span", null, "开始生成 ", -1))
6262
6283
  ]),
6263
6284
  _: 1
6264
6285
  }, 8, ["disabled"]))
6265
6286
  ]),
6266
- A("div", Mu, [
6267
- (Y(), L(en, null, gn(j, (v) => A("div", Tu, [
6268
- A("div", Nu, [
6269
- A("span", null, F(v.label), 1),
6270
- A("span", Ru, F(v.modelValue.value.length) + "/" + F(v.maxLength), 1)
6287
+ v("div", Mu, [
6288
+ (Y(), L(en, null, gn(b, (j) => v("div", Tu, [
6289
+ v("div", Nu, [
6290
+ v("span", null, F(j.label), 1),
6291
+ v("span", Ru, F(j.modelValue.value.length) + "/" + F(j.maxLength), 1)
6271
6292
  ]),
6272
- Te(A("textarea", {
6293
+ Te(v("textarea", {
6273
6294
  class: "lsh-textarea",
6274
- "onUpdate:modelValue": (C) => v.modelValue.value = C,
6275
- placeholder: v.placeholder,
6276
- style: he({ height: v.inputHeight + "px" }),
6295
+ "onUpdate:modelValue": (x) => j.modelValue.value = x,
6296
+ placeholder: j.placeholder,
6297
+ style: he({ height: j.inputHeight + "px" }),
6277
6298
  resizable: !1,
6278
- maxlength: v.maxLength
6299
+ maxlength: j.maxLength
6279
6300
  }, null, 12, Fu), [
6280
- [Ne, v.modelValue.value]
6301
+ [Ne, j.modelValue.value]
6281
6302
  ])
6282
6303
  ])), 64))
6283
6304
  ])
6284
6305
  ]),
6285
- A("div", Pu, [
6286
- O[6] || (O[6] = A("div", { class: "lsh-form-top" }, [
6287
- A("span", { class: "lsh-title" }, "AI写稿结果")
6306
+ v("div", Pu, [
6307
+ W[6] || (W[6] = v("div", { class: "lsh-form-top" }, [
6308
+ v("span", { class: "lsh-title" }, "AI写稿结果")
6288
6309
  ], -1)),
6289
- b(c) || y.value ? (Y(), L("div", Uu, [
6290
- Te(A("textarea", {
6310
+ z(c) || y.value ? (Y(), L("div", Uu, [
6311
+ Te(v("textarea", {
6291
6312
  class: "lsh-textarea lsh-result-box",
6292
6313
  ref_key: "textBoxRef",
6293
6314
  ref: l,
6294
- "onUpdate:modelValue": O[0] || (O[0] = (v) => Et(c) ? c.value = v : null)
6315
+ "onUpdate:modelValue": W[0] || (W[0] = (j) => Et(c) ? c.value = j : null)
6295
6316
  }, null, 512), [
6296
- [Ne, b(c)]
6317
+ [Ne, z(c)]
6297
6318
  ]),
6298
- A("div", Eu, [
6299
- O[5] || (O[5] = A("span", null, "内容由AI生成,仅供参考", -1)),
6300
- A("span", {
6319
+ v("div", Eu, [
6320
+ W[5] || (W[5] = v("span", null, "内容由AI生成,仅供参考", -1)),
6321
+ v("span", {
6301
6322
  class: bn({
6302
6323
  "red-text": V.value
6303
6324
  })
6304
- }, F(b(c).length) + "/" + F(M.value), 3)
6325
+ }, F(z(c).length) + "/" + F(M.value), 3)
6305
6326
  ])
6306
- ])) : b(a) ? (Y(), L("div", Du, [
6307
- A("div", Bu, [
6308
- H(b(ao), {
6327
+ ])) : z(a) ? (Y(), L("div", Du, [
6328
+ v("div", Bu, [
6329
+ H(z(ao), {
6309
6330
  loading: "",
6310
6331
  text: "正在生成中,请稍候..."
6311
6332
  })
6312
6333
  ])
6313
6334
  ])) : (Y(), L("div", Qu, [
6314
- A("div", _u, [
6315
- H(b(sh), {
6335
+ v("div", _u, [
6336
+ H(z(sh), {
6316
6337
  style: { height: "100%" },
6317
6338
  description: "暂无内容,请先输入关键词"
6318
6339
  })
@@ -6327,33 +6348,33 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6327
6348
  }), na = /* @__PURE__ */ sn($u, [["__scopeId", "data-v-259be8b7"]]), ea = { class: "lsh-footer-box" }, ia = { class: "lsh-option-item gray" }, ta = { class: "lsh-option-item gray" }, oa = /* @__PURE__ */ $({
6328
6349
  __name: "editor-footer",
6329
6350
  setup(e) {
6330
- const n = Tn(), { clearContent: i, editor: t, getGenerateAudioParams: o, textLimitLength: l, textLength: s } = n, h = T(() => {
6331
- var g;
6351
+ const n = Tn(), { clearContent: i, editor: t, getPlaybackSpeed: o, textLimitLength: l, textLength: s } = n, h = T(() => {
6352
+ var u;
6332
6353
  if (!s.value) return tt(0);
6333
- const { speed: r } = o(), u = ((g = t.value) == null ? void 0 : g.getText()) ?? "";
6334
- return tt(fl(u, r));
6354
+ const r = ((u = t.value) == null ? void 0 : u.getText()) ?? "";
6355
+ return tt(fl(r, o()));
6335
6356
  });
6336
6357
  return (r, u) => (Y(), L("div", ea, [
6337
- A("div", ia, [
6338
- H(b(rn), { name: "editor-text" }),
6339
- A("span", null, F(b(s)) + "/" + F(b(l)), 1)
6358
+ v("div", ia, [
6359
+ H(z(rn), { name: "editor-text" }),
6360
+ v("span", null, F(z(s)) + "/" + F(z(l)), 1)
6340
6361
  ]),
6341
- A("div", ta, [
6342
- H(b(rn), { name: "editor-time" }),
6343
- A("span", null, F(h.value), 1)
6362
+ v("div", ta, [
6363
+ H(z(rn), { name: "editor-time" }),
6364
+ v("span", null, F(h.value), 1)
6344
6365
  ]),
6345
- u[2] || (u[2] = A("div", { class: "lsh-divider" }, null, -1)),
6346
- A("div", {
6347
- class: bn(["lsh-option-item btn", { disabled: !b(s) }]),
6366
+ u[2] || (u[2] = v("div", { class: "lsh-divider" }, null, -1)),
6367
+ v("div", {
6368
+ class: bn(["lsh-option-item btn", { disabled: !z(s) }]),
6348
6369
  onClick: u[0] || (u[0] = //@ts-ignore
6349
- (...g) => b(i) && b(i)(...g))
6370
+ (...g) => z(i) && z(i)(...g))
6350
6371
  }, [
6351
- H(b(rn), { name: "editor-clear" }),
6352
- u[1] || (u[1] = A("span", null, "清空", -1))
6372
+ H(z(rn), { name: "editor-clear" }),
6373
+ u[1] || (u[1] = v("span", null, "清空", -1))
6353
6374
  ], 2)
6354
6375
  ]));
6355
6376
  }
6356
- }), la = /* @__PURE__ */ sn(oa, [["__scopeId", "data-v-aedd8e60"]]), sa = ({
6377
+ }), la = /* @__PURE__ */ sn(oa, [["__scopeId", "data-v-b83e8b96"]]), sa = ({
6357
6378
  list: e,
6358
6379
  toolbarRef: n,
6359
6380
  measureRef: i,
@@ -6366,23 +6387,23 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6366
6387
  () => l.value.slice(s.value)
6367
6388
  ), g = () => {
6368
6389
  var I;
6369
- const c = n.value, d = i.value;
6370
- if (!c || !d) return;
6390
+ const c = n.value, p = i.value;
6391
+ if (!c || !p) return;
6371
6392
  const f = c.clientWidth;
6372
6393
  if (f <= 0) return;
6373
- const m = Array.from(
6374
- d.querySelectorAll(t)
6375
- ), y = ((I = m[m.length - 1]) == null ? void 0 : I.offsetWidth) || 0, j = m.slice(0, -1).map((w) => w.offsetWidth);
6376
- if (!y || j.some((w) => !w)) return;
6377
- let Z = 0;
6378
- s.value = j.length;
6379
- for (let w = 0; w < j.length; w++) {
6380
- const J = j.length - w - 1, k = Z + (w > 0 ? o : 0) + j[w];
6394
+ const d = Array.from(
6395
+ p.querySelectorAll(t)
6396
+ ), y = ((I = d[d.length - 1]) == null ? void 0 : I.offsetWidth) || 0, b = d.slice(0, -1).map((w) => w.offsetWidth);
6397
+ if (!y || b.some((w) => !w)) return;
6398
+ let A = 0;
6399
+ s.value = b.length;
6400
+ for (let w = 0; w < b.length; w++) {
6401
+ const J = b.length - w - 1, k = A + (w > 0 ? o : 0) + b[w];
6381
6402
  if (k + (J > 0 ? o + y : 0) > f) {
6382
6403
  s.value = w;
6383
6404
  return;
6384
6405
  }
6385
- Z = k;
6406
+ A = k;
6386
6407
  }
6387
6408
  }, a = () => {
6388
6409
  de(g);
@@ -6406,7 +6427,7 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6406
6427
  var l;
6407
6428
  return (l = o.value) == null ? void 0 : l.$el;
6408
6429
  }
6409
- }), (l, s) => (Y(), _(b(on), {
6430
+ }), (l, s) => (Y(), _(z(on), {
6410
6431
  ref_key: "buttonRef",
6411
6432
  ref: o,
6412
6433
  plain: e.plain,
@@ -6415,13 +6436,13 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6415
6436
  link: ""
6416
6437
  }, {
6417
6438
  icon: N(() => [
6418
- H(b(rn), {
6439
+ H(z(rn), {
6419
6440
  name: e.item.tool.icon,
6420
6441
  size: "18"
6421
6442
  }, null, 8, ["name"])
6422
6443
  ]),
6423
6444
  default: N(() => [
6424
- A("span", null, F(e.item.tool.label), 1)
6445
+ v("span", null, F(e.item.tool.label), 1)
6425
6446
  ]),
6426
6447
  _: 1
6427
6448
  }, 8, ["plain", "disabled"]));
@@ -6442,25 +6463,25 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6442
6463
  return ((V = (M = r.value).readFormula) == null ? void 0 : V.call(M, String(k.formula ?? ""), G)) ?? Promise.resolve();
6443
6464
  },
6444
6465
  scrollTarget: s
6445
- }), { loading: c, result: d } = a, f = K(!1), m = () => {
6466
+ }), { loading: c, result: p } = a, f = K(!1), d = () => {
6446
6467
  o.value = !o.value;
6447
6468
  }, y = () => {
6448
- m();
6449
- }, j = () => {
6450
- t("confirm", d.value), m();
6451
- }, Z = async () => {
6469
+ d();
6470
+ }, b = () => {
6471
+ t("confirm", p.value), d();
6472
+ }, A = async () => {
6452
6473
  try {
6453
6474
  await a.exec({
6454
6475
  formula: l.value
6455
6476
  }), f.value = !0;
6456
6477
  } catch {
6457
6478
  }
6458
- }, I = T(() => g - u.value + l.value.length), w = T(() => d.value.length > I.value), J = T(() => c.value || !d.value || w.value);
6479
+ }, I = T(() => g - u.value + l.value.length), w = T(() => p.value.length > I.value), J = T(() => c.value || !p.value || w.value);
6459
6480
  return n({
6460
6481
  open: (k) => {
6461
- l.value = k, Z(), m();
6482
+ l.value = k, A(), d();
6462
6483
  }
6463
- }), (k, G) => (Y(), _(b(Oe), {
6484
+ }), (k, G) => (Y(), _(z(Oe), {
6464
6485
  modelValue: o.value,
6465
6486
  "onUpdate:modelValue": G[2] || (G[2] = (M) => o.value = M),
6466
6487
  width: 800,
@@ -6468,7 +6489,7 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6468
6489
  class: "lsh-ai-modal"
6469
6490
  }, {
6470
6491
  footer: N(() => [
6471
- H(b(on), {
6492
+ H(z(on), {
6472
6493
  plain: "",
6473
6494
  onClick: y
6474
6495
  }, {
@@ -6477,11 +6498,11 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6477
6498
  ])]),
6478
6499
  _: 1
6479
6500
  }),
6480
- H(b(on), {
6501
+ H(z(on), {
6481
6502
  type: "info",
6482
- onClick: j,
6503
+ onClick: b,
6483
6504
  disabled: J.value,
6484
- loading: b(c)
6505
+ loading: z(c)
6485
6506
  }, {
6486
6507
  default: N(() => [...G[9] || (G[9] = [
6487
6508
  An(" 确定 ", -1)
@@ -6490,55 +6511,55 @@ const ku = { key: 0 }, Ku = ["onClick"], Vu = /* @__PURE__ */ $({
6490
6511
  }, 8, ["disabled", "loading"])
6491
6512
  ]),
6492
6513
  default: N(() => [
6493
- A("div", ha, [
6494
- A("div", ra, [
6495
- G[3] || (G[3] = A("div", { class: "lsh-form-top" }, [
6496
- A("span", { class: "lsh-title" }, "原始文本")
6514
+ v("div", ha, [
6515
+ v("div", ra, [
6516
+ G[3] || (G[3] = v("div", { class: "lsh-form-top" }, [
6517
+ v("span", { class: "lsh-title" }, "原始文本")
6497
6518
  ], -1)),
6498
- A("div", ua, [
6499
- A("span", null, F(l.value), 1)
6519
+ v("div", ua, [
6520
+ v("span", null, F(l.value), 1)
6500
6521
  ])
6501
6522
  ]),
6502
- A("div", aa, [
6503
- A("div", ga, [
6504
- G[6] || (G[6] = A("span", { class: "lsh-title" }, "AI读公式结果", -1)),
6505
- b(c) ? (Y(), L("div", {
6523
+ v("div", aa, [
6524
+ v("div", ga, [
6525
+ G[6] || (G[6] = v("span", { class: "lsh-title" }, "AI读公式结果", -1)),
6526
+ z(c) ? (Y(), L("div", {
6506
6527
  key: 1,
6507
6528
  class: "lsh-text-btn stop",
6508
6529
  onClick: G[0] || (G[0] = //@ts-ignore
6509
- (...M) => b(a).abort && b(a).abort(...M))
6530
+ (...M) => z(a).abort && z(a).abort(...M))
6510
6531
  }, [
6511
- H(b(rn), { name: "editor-generate-stop" }),
6512
- G[5] || (G[5] = A("span", null, "停止生成 ", -1))
6532
+ H(z(rn), { name: "editor-generate-stop" }),
6533
+ G[5] || (G[5] = v("span", null, "停止生成 ", -1))
6513
6534
  ])) : (Y(), L("div", {
6514
6535
  key: 0,
6515
6536
  class: "lsh-text-btn",
6516
- onClick: Z
6537
+ onClick: A
6517
6538
  }, [
6518
- H(b(rn), { name: "editor-refresh" }),
6519
- G[4] || (G[4] = A("span", null, "重新生成 ", -1))
6539
+ H(z(rn), { name: "editor-refresh" }),
6540
+ G[4] || (G[4] = v("span", null, "重新生成 ", -1))
6520
6541
  ]))
6521
6542
  ]),
6522
- b(d) || f.value ? (Y(), L("div", ca, [
6523
- Te(A("textarea", {
6543
+ z(p) || f.value ? (Y(), L("div", ca, [
6544
+ Te(v("textarea", {
6524
6545
  class: "lsh-textarea lsh-result-box",
6525
6546
  ref_key: "textBoxRef",
6526
6547
  ref: s,
6527
- "onUpdate:modelValue": G[1] || (G[1] = (M) => Et(d) ? d.value = M : null)
6548
+ "onUpdate:modelValue": G[1] || (G[1] = (M) => Et(p) ? p.value = M : null)
6528
6549
  }, null, 512), [
6529
- [Ne, b(d)]
6550
+ [Ne, z(p)]
6530
6551
  ]),
6531
- A("div", da, [
6532
- G[7] || (G[7] = A("span", null, "内容由AI生成,仅供参考", -1)),
6533
- A("span", {
6552
+ v("div", da, [
6553
+ G[7] || (G[7] = v("span", null, "内容由AI生成,仅供参考", -1)),
6554
+ v("span", {
6534
6555
  class: bn({
6535
6556
  "red-text": w.value
6536
6557
  })
6537
- }, F(b(d).length) + "/" + F(I.value), 3)
6558
+ }, F(z(p).length) + "/" + F(I.value), 3)
6538
6559
  ])
6539
6560
  ])) : (Y(), L("div", ma, [
6540
- A("div", pa, [
6541
- H(b(ao), {
6561
+ v("div", pa, [
6562
+ H(z(ao), {
6542
6563
  loading: "",
6543
6564
  text: "正在生成中,请稍候..."
6544
6565
  })
@@ -30243,13 +30264,13 @@ const je = (e) => {
30243
30264
  const g = s[h];
30244
30265
  if (g && u === g.index) {
30245
30266
  if (g.length === 1 && g.priority <= qn.Normal) {
30246
- const d = r[u];
30247
- g.zh = d;
30267
+ const p = r[u];
30268
+ g.zh = p;
30248
30269
  let f = "";
30249
- f = Mt(d, r[u - 1], r[u + 1]), n[u] = {
30250
- origin: d,
30270
+ f = Mt(p, r[u - 1], r[u + 1]), n[u] = {
30271
+ origin: p,
30251
30272
  result: f,
30252
- isZh: f !== d,
30273
+ isZh: f !== p,
30253
30274
  originPinyin: f
30254
30275
  }, u++, h++;
30255
30276
  continue;
@@ -30257,9 +30278,9 @@ const je = (e) => {
30257
30278
  const a = g.pinyin.split(" ");
30258
30279
  let c = 0;
30259
30280
  o && (g.zh = r.slice(g.index, g.index + g.length).join(""));
30260
- for (let d = 0; d < g.length; d++)
30261
- n[u + d] = {
30262
- origin: r[d + g.index],
30281
+ for (let p = 0; p < g.length; p++)
30282
+ n[u + p] = {
30283
+ origin: r[p + g.index],
30263
30284
  result: a[c] || "",
30264
30285
  isZh: !0,
30265
30286
  originPinyin: a[c] || ""
@@ -30606,53 +30627,53 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
30606
30627
  }, c = () => {
30607
30628
  const V = s.value === "auto" ? G(u.autoPinyin) : J.value;
30608
30629
  o.value = !1, t("confirm", V);
30609
- }, d = (V) => {
30630
+ }, p = (V) => {
30610
30631
  I.value.initial = V === I.value.initial ? "" : V;
30611
30632
  }, f = (V) => {
30612
30633
  I.value.final = V;
30613
- }, m = (V) => {
30614
- var p, W;
30634
+ }, d = (V) => {
30635
+ var m, C;
30615
30636
  r.value = V;
30616
- const q = ((p = u.manualPinyin[V]) == null ? void 0 : p.final) ?? "";
30617
- h.value = ((W = le.find((O) => O.options.includes(q))) == null ? void 0 : W.value) ?? le[0].value;
30618
- }, y = (V, q) => {
30619
- const p = u.autoPinyin.split(" ");
30620
- p[V] = q, u.autoPinyin = p.join(" ");
30621
- }, j = T(() => {
30637
+ const S = ((m = u.manualPinyin[V]) == null ? void 0 : m.final) ?? "";
30638
+ h.value = ((C = le.find((W) => W.options.includes(S))) == null ? void 0 : C.value) ?? le[0].value;
30639
+ }, y = (V, S) => {
30640
+ const m = u.autoPinyin.split(" ");
30641
+ m[V] = S, u.autoPinyin = m.join(" ");
30642
+ }, b = T(() => {
30622
30643
  var V;
30623
- return ((V = le.find((q) => q.value === h.value)) == null ? void 0 : V.options) || [];
30624
- }), Z = T(() => s.value === "auto" ? !u.autoPinyin.length : u.manualPinyin.some((V) => !V.final)), I = T(
30644
+ return ((V = le.find((S) => S.value === h.value)) == null ? void 0 : V.options) || [];
30645
+ }), A = T(() => s.value === "auto" ? !u.autoPinyin.length : u.manualPinyin.some((V) => !V.final)), I = T(
30625
30646
  () => u.manualPinyin[r.value]
30626
30647
  ), w = (V) => {
30627
- const q = V.tone === "0" ? "" : V.tone;
30628
- return `${V.initial}${V.final}${V.final ? q : ""}`;
30648
+ const S = V.tone === "0" ? "" : V.tone;
30649
+ return `${V.initial}${V.final}${V.final ? S : ""}`;
30629
30650
  }, J = T(() => s.value === "auto" ? u.autoPinyin : u.manualPinyin.map(w).join(" ")), k = (V) => V.replace(/ü/g, "v").replace(/0$/, ""), G = (V) => V.trim().split(/\s+/).map(k).join(" "), M = (V) => {
30630
30651
  try {
30631
- const q = lg(V, {
30652
+ const S = lg(V, {
30632
30653
  type: "all",
30633
30654
  toneType: "num",
30634
30655
  nonZh: "consecutive"
30635
- }), p = hg(V, {
30656
+ }), m = hg(V, {
30636
30657
  type: "array",
30637
30658
  toneType: "num",
30638
30659
  nonZh: "consecutive"
30639
30660
  });
30640
- let W = 0;
30641
- u.autoPinyin = q.filter((O) => O.isZh && O.pinyin).map((O) => k(O.pinyin)).join(" "), u.pinyinOptions = q.reduce((O, v, C) => {
30642
- if (!v.isZh || !v.pinyin) return O;
30643
- const z = Array.from(
30661
+ let C = 0;
30662
+ u.autoPinyin = S.filter((W) => W.isZh && W.pinyin).map((W) => k(W.pinyin)).join(" "), u.pinyinOptions = S.reduce((W, j, x) => {
30663
+ if (!j.isZh || !j.pinyin) return W;
30664
+ const q = Array.from(
30644
30665
  /* @__PURE__ */ new Set([
30645
- k(v.pinyin),
30646
- ...(p[C] || []).map(
30647
- (S) => k(S)
30666
+ k(j.pinyin),
30667
+ ...(m[x] || []).map(
30668
+ (O) => k(O)
30648
30669
  )
30649
30670
  ])
30650
30671
  );
30651
- return z.length > 1 && O.push({
30652
- text: v.origin,
30653
- index: W,
30654
- options: z
30655
- }), W += 1, O;
30672
+ return q.length > 1 && W.push({
30673
+ text: j.origin,
30674
+ index: C,
30675
+ options: q
30676
+ }), C += 1, W;
30656
30677
  }, []);
30657
30678
  } catch {
30658
30679
  u.autoPinyin = "", u.pinyinOptions = [];
@@ -30660,157 +30681,157 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
30660
30681
  };
30661
30682
  return n({
30662
30683
  open: (V) => {
30663
- u.text = V, u.autoPinyin = "", u.manualPinyin = Array.from(V, (q) => ({
30664
- text: q,
30684
+ u.text = V, u.autoPinyin = "", u.manualPinyin = Array.from(V, (S) => ({
30685
+ text: S,
30665
30686
  initial: "",
30666
30687
  tone: ht[4].value,
30667
30688
  final: ""
30668
30689
  })), r.value = 0, h.value = le[0].value, u.pinyinOptions = [], M(V), g();
30669
30690
  }
30670
- }), (V, q) => (Y(), _(b(Oe), {
30691
+ }), (V, S) => (Y(), _(z(Oe), {
30671
30692
  modelValue: o.value,
30672
- "onUpdate:modelValue": q[4] || (q[4] = (p) => o.value = p),
30693
+ "onUpdate:modelValue": S[4] || (S[4] = (m) => o.value = m),
30673
30694
  width: 800,
30674
30695
  "header-class": "lsh-modal-header"
30675
30696
  }, {
30676
30697
  header: N(() => [
30677
- A("div", gg, [
30678
- q[5] || (q[5] = A("span", { class: "lsh-title" }, "拼音标注助手", -1)),
30679
- H(b(ri), {
30698
+ v("div", gg, [
30699
+ S[5] || (S[5] = v("span", { class: "lsh-title" }, "拼音标注助手", -1)),
30700
+ H(z(ri), {
30680
30701
  class: "lsh-radio-group",
30681
30702
  options: l,
30682
30703
  modelValue: s.value,
30683
- "onUpdate:modelValue": q[0] || (q[0] = (p) => s.value = p),
30704
+ "onUpdate:modelValue": S[0] || (S[0] = (m) => s.value = m),
30684
30705
  style: { "border-radius": "9px" }
30685
30706
  }, null, 8, ["modelValue"])
30686
30707
  ])
30687
30708
  ]),
30688
30709
  footer: N(() => [
30689
- H(b(on), {
30710
+ H(z(on), {
30690
30711
  plain: "",
30691
30712
  onClick: a
30692
30713
  }, {
30693
- default: N(() => [...q[12] || (q[12] = [
30714
+ default: N(() => [...S[12] || (S[12] = [
30694
30715
  An("取消", -1)
30695
30716
  ])]),
30696
30717
  _: 1
30697
30718
  }),
30698
- H(b(on), {
30719
+ H(z(on), {
30699
30720
  type: "info",
30700
30721
  onClick: c,
30701
- disabled: Z.value
30722
+ disabled: A.value
30702
30723
  }, {
30703
- default: N(() => [...q[13] || (q[13] = [
30724
+ default: N(() => [...S[13] || (S[13] = [
30704
30725
  An(" 确认 ", -1)
30705
30726
  ])]),
30706
30727
  _: 1
30707
30728
  }, 8, ["disabled"])
30708
30729
  ]),
30709
30730
  default: N(() => [
30710
- A("div", cg, [
30711
- A("div", null, [
30712
- q[6] || (q[6] = A("div", { class: "lsh-label" }, "拼音", -1)),
30731
+ v("div", cg, [
30732
+ v("div", null, [
30733
+ S[6] || (S[6] = v("div", { class: "lsh-label" }, "拼音", -1)),
30713
30734
  s.value === "auto" ? Te((Y(), L("input", {
30714
30735
  key: 0,
30715
30736
  class: "lsh-text-box",
30716
- "onUpdate:modelValue": q[1] || (q[1] = (p) => u.autoPinyin = p)
30737
+ "onUpdate:modelValue": S[1] || (S[1] = (m) => u.autoPinyin = m)
30717
30738
  }, null, 512)), [
30718
30739
  [Ne, u.autoPinyin]
30719
30740
  ]) : (Y(), L("div", dg, F(J.value), 1))
30720
30741
  ]),
30721
30742
  s.value === "auto" ? (Y(), L("div", mg, [
30722
- q[8] || (q[8] = A("div", { class: "lsh-label" }, "汉字", -1)),
30723
- A("div", pg, F(u.text), 1),
30743
+ S[8] || (S[8] = v("div", { class: "lsh-label" }, "汉字", -1)),
30744
+ v("div", pg, F(u.text), 1),
30724
30745
  u.pinyinOptions.length ? (Y(), L("div", fg, [
30725
- q[7] || (q[7] = A("div", { class: "lsh-label" }, "多音字候选", -1)),
30726
- A("div", yg, [
30727
- (Y(!0), L(en, null, gn(u.pinyinOptions, (p) => (Y(), L("div", {
30746
+ S[7] || (S[7] = v("div", { class: "lsh-label" }, "多音字候选", -1)),
30747
+ v("div", yg, [
30748
+ (Y(!0), L(en, null, gn(u.pinyinOptions, (m) => (Y(), L("div", {
30728
30749
  class: "lsh-polyphonic-item",
30729
- key: `${p.text}-${p.index}`
30750
+ key: `${m.text}-${m.index}`
30730
30751
  }, [
30731
- A("span", qg, F(p.text), 1),
30732
- A("div", zg, [
30733
- (Y(!0), L(en, null, gn(p.options, (W) => (Y(), L("div", {
30752
+ v("span", qg, F(m.text), 1),
30753
+ v("div", zg, [
30754
+ (Y(!0), L(en, null, gn(m.options, (C) => (Y(), L("div", {
30734
30755
  class: bn(["lsh-polyphonic-option", {
30735
- active: W === u.autoPinyin.split(" ")[p.index]
30756
+ active: C === u.autoPinyin.split(" ")[m.index]
30736
30757
  }]),
30737
- key: W,
30738
- onClick: (O) => y(
30739
- p.index,
30740
- W
30758
+ key: C,
30759
+ onClick: (W) => y(
30760
+ m.index,
30761
+ C
30741
30762
  )
30742
- }, F(W), 11, bg))), 128))
30763
+ }, F(C), 11, bg))), 128))
30743
30764
  ])
30744
30765
  ]))), 128))
30745
30766
  ])
30746
30767
  ])) : yn("", !0)
30747
30768
  ])) : (Y(), L(en, { key: 1 }, [
30748
- A("div", jg, [
30749
- q[9] || (q[9] = A("div", { class: "lsh-label" }, "汉字", -1)),
30750
- A("div", vg, [
30751
- (Y(!0), L(en, null, gn(u.manualPinyin, (p, W) => (Y(), L("div", {
30752
- class: bn(["lsh-manual-text-item", { active: W === r.value }]),
30753
- key: `${p.text}-${W}`,
30754
- onClick: (O) => m(W)
30769
+ v("div", jg, [
30770
+ S[9] || (S[9] = v("div", { class: "lsh-label" }, "汉字", -1)),
30771
+ v("div", vg, [
30772
+ (Y(!0), L(en, null, gn(u.manualPinyin, (m, C) => (Y(), L("div", {
30773
+ class: bn(["lsh-manual-text-item", { active: C === r.value }]),
30774
+ key: `${m.text}-${C}`,
30775
+ onClick: (W) => d(C)
30755
30776
  }, [
30756
- A("span", null, F(p.text), 1),
30757
- A("span", Zg, F(w(p) || "-"), 1)
30777
+ v("span", null, F(m.text), 1),
30778
+ v("span", Zg, F(w(m) || "-"), 1)
30758
30779
  ], 10, Ag))), 128))
30759
30780
  ])
30760
30781
  ]),
30761
- A("div", xg, [
30762
- A("div", Cg, [
30763
- q[10] || (q[10] = A("div", { class: "lsh-label" }, "声母", -1)),
30764
- A("div", Ig, [
30765
- (Y(!0), L(en, null, gn(b(Eh), (p) => (Y(), L("div", {
30782
+ v("div", xg, [
30783
+ v("div", Cg, [
30784
+ S[10] || (S[10] = v("div", { class: "lsh-label" }, "声母", -1)),
30785
+ v("div", Ig, [
30786
+ (Y(!0), L(en, null, gn(z(Eh), (m) => (Y(), L("div", {
30766
30787
  class: bn(["lsh-initial-btn", {
30767
- active: p === I.value.initial
30788
+ active: m === I.value.initial
30768
30789
  }]),
30769
- key: p,
30770
- onClick: (W) => d(p)
30771
- }, F(p), 11, Wg))), 128))
30790
+ key: m,
30791
+ onClick: (C) => p(m)
30792
+ }, F(m), 11, Wg))), 128))
30772
30793
  ])
30773
30794
  ]),
30774
- A("div", wg, [
30775
- q[11] || (q[11] = A("div", { class: "lsh-label" }, "韵母", -1)),
30776
- H(b(ri), {
30795
+ v("div", wg, [
30796
+ S[11] || (S[11] = v("div", { class: "lsh-label" }, "韵母", -1)),
30797
+ H(z(ri), {
30777
30798
  class: "lsh-radio-group-white",
30778
- options: b(ht),
30799
+ options: z(ht),
30779
30800
  color: "#101114",
30780
30801
  "active-color": "#101114",
30781
30802
  background: "#F1F2F5",
30782
30803
  "active-backgound": "#fff",
30783
30804
  style: { width: "284px" },
30784
30805
  modelValue: I.value.tone,
30785
- "onUpdate:modelValue": q[2] || (q[2] = (p) => I.value.tone = p),
30806
+ "onUpdate:modelValue": S[2] || (S[2] = (m) => I.value.tone = m),
30786
30807
  "slider-style": {
30787
30808
  borderRadius: "10px",
30788
30809
  boxShadow: "0 1px 4px 0 rgba(0, 0, 0, 0.10)"
30789
30810
  }
30790
30811
  }, null, 8, ["options", "modelValue"]),
30791
- A("div", Sg, [
30792
- H(b(ri), {
30812
+ v("div", Sg, [
30813
+ H(z(ri), {
30793
30814
  class: "lsh-radio-group-white",
30794
- options: b(le),
30815
+ options: z(le),
30795
30816
  color: "#101114",
30796
30817
  "active-color": "#101114",
30797
30818
  background: "#F1F2F5",
30798
30819
  "active-backgound": "#fff",
30799
30820
  modelValue: h.value,
30800
- "onUpdate:modelValue": q[3] || (q[3] = (p) => h.value = p),
30821
+ "onUpdate:modelValue": S[3] || (S[3] = (m) => h.value = m),
30801
30822
  "slider-style": {
30802
30823
  borderRadius: "10px",
30803
30824
  boxShadow: "0 1px 4px 0 rgba(0, 0, 0, 0.10)"
30804
30825
  }
30805
30826
  }, null, 8, ["options", "modelValue"]),
30806
- A("div", Og, [
30807
- (Y(!0), L(en, null, gn(j.value, (p) => (Y(), L("div", {
30827
+ v("div", Og, [
30828
+ (Y(!0), L(en, null, gn(b.value, (m) => (Y(), L("div", {
30808
30829
  class: bn(["lsh-final-item", {
30809
- active: p === I.value.final
30830
+ active: m === I.value.final
30810
30831
  }]),
30811
- key: p,
30812
- onClick: (W) => f(p)
30813
- }, F(p), 11, Yg))), 128))
30832
+ key: m,
30833
+ onClick: (C) => f(m)
30834
+ }, F(m), 11, Yg))), 128))
30814
30835
  ])
30815
30836
  ])
30816
30837
  ])
@@ -30842,20 +30863,20 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
30842
30863
  open: (g) => {
30843
30864
  l.origin = g, l.new = "", s();
30844
30865
  }
30845
- }), (g, a) => (Y(), _(b(Oe), {
30866
+ }), (g, a) => (Y(), _(z(Oe), {
30846
30867
  modelValue: o.value,
30847
30868
  "onUpdate:modelValue": a[2] || (a[2] = (c) => o.value = c),
30848
30869
  width: 400,
30849
30870
  "header-class": "lsh-modal-header"
30850
30871
  }, {
30851
30872
  header: N(() => [...a[3] || (a[3] = [
30852
- A("div", { class: "lsh-header-content" }, [
30853
- A("span", { class: "lsh-title" }, "文本替换"),
30854
- A("p", { class: "lsh-tip" }, " 替换的文本将保留显示,但语音合成朗读会使用替换后的内容 ")
30873
+ v("div", { class: "lsh-header-content" }, [
30874
+ v("span", { class: "lsh-title" }, "文本替换"),
30875
+ v("p", { class: "lsh-tip" }, " 替换的文本将保留显示,但语音合成朗读会使用替换后的内容 ")
30855
30876
  ], -1)
30856
30877
  ])]),
30857
30878
  footer: N(() => [
30858
- H(b(on), {
30879
+ H(z(on), {
30859
30880
  plain: "",
30860
30881
  onClick: h
30861
30882
  }, {
@@ -30864,7 +30885,7 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
30864
30885
  ])]),
30865
30886
  _: 1
30866
30887
  }),
30867
- H(b(on), {
30888
+ H(z(on), {
30868
30889
  type: "info",
30869
30890
  onClick: r,
30870
30891
  disabled: u.value
@@ -30876,18 +30897,18 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
30876
30897
  }, 8, ["disabled"])
30877
30898
  ]),
30878
30899
  default: N(() => [
30879
- A("div", Vg, [
30880
- A("div", null, [
30881
- a[4] || (a[4] = A("div", { class: "lsh-form-item-label" }, "原文", -1)),
30882
- H(b(nt), {
30900
+ v("div", Vg, [
30901
+ v("div", null, [
30902
+ a[4] || (a[4] = v("div", { class: "lsh-form-item-label" }, "原文", -1)),
30903
+ H(z(nt), {
30883
30904
  disabled: "",
30884
30905
  modelValue: l.origin,
30885
30906
  "onUpdate:modelValue": a[0] || (a[0] = (c) => l.origin = c)
30886
30907
  }, null, 8, ["modelValue"])
30887
30908
  ]),
30888
- A("div", null, [
30889
- a[5] || (a[5] = A("div", { class: "lsh-form-item-label" }, "替换文本", -1)),
30890
- H(b(nt), {
30909
+ v("div", null, [
30910
+ a[5] || (a[5] = v("div", { class: "lsh-form-item-label" }, "替换文本", -1)),
30911
+ H(z(nt), {
30891
30912
  placeholder: "请输入",
30892
30913
  modelValue: l.new,
30893
30914
  "onUpdate:modelValue": a[1] || (a[1] = (c) => l.new = c)
@@ -30910,7 +30931,7 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
30910
30931
  emits: /* @__PURE__ */ ae(["select"], ["update:visible"]),
30911
30932
  setup(e, { emit: n }) {
30912
30933
  const i = Gi(e, "visible"), t = n;
30913
- return (o, l) => (Y(), _(b(_e), {
30934
+ return (o, l) => (Y(), _(z(_e), {
30914
30935
  "virtual-ref": e.virtualRef,
30915
30936
  trigger: "click",
30916
30937
  "virtual-triggering": "",
@@ -30921,14 +30942,14 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
30921
30942
  placement: "top"
30922
30943
  }, {
30923
30944
  default: N(() => [
30924
- A("div", Jg, [
30925
- (Y(!0), L(en, null, gn(e.options, (s) => (Y(), _(b(on), {
30945
+ v("div", Jg, [
30946
+ (Y(!0), L(en, null, gn(e.options, (s) => (Y(), _(z(on), {
30926
30947
  key: s.value,
30927
30948
  onClick: (h) => t("select", s.value)
30928
30949
  }, {
30929
30950
  default: N(() => [
30930
- A("span", null, F(s.value.toUpperCase()), 1),
30931
- A("span", null, " " + F(s.label), 1)
30951
+ v("span", null, F(s.value.toUpperCase()), 1),
30952
+ v("span", null, " " + F(s.label), 1)
30932
30953
  ]),
30933
30954
  _: 2
30934
30955
  }, 1032, ["onClick"]))), 128))
@@ -30949,7 +30970,7 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
30949
30970
  emits: /* @__PURE__ */ ae(["select"], ["update:visible"]),
30950
30971
  setup(e, { emit: n }) {
30951
30972
  const i = Gi(e, "visible"), t = n;
30952
- return (o, l) => (Y(), _(b(_e), {
30973
+ return (o, l) => (Y(), _(z(_e), {
30953
30974
  "virtual-ref": e.virtualRef,
30954
30975
  trigger: "click",
30955
30976
  "virtual-triggering": "",
@@ -30960,14 +30981,14 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
30960
30981
  placement: "top"
30961
30982
  }, {
30962
30983
  default: N(() => [
30963
- A("div", Mg, [
30964
- (Y(!0), L(en, null, gn(e.options, (s) => (Y(), _(b(on), {
30984
+ v("div", Mg, [
30985
+ (Y(!0), L(en, null, gn(e.options, (s) => (Y(), _(z(on), {
30965
30986
  key: s.label,
30966
30987
  onClick: (h) => t("select", s.value)
30967
30988
  }, {
30968
30989
  default: N(() => [
30969
- A("span", Tg, F(s.label) + ":", 1),
30970
- A("span", Ng, " " + F(s.value), 1)
30990
+ v("span", Tg, F(s.label) + ":", 1),
30991
+ v("span", Ng, " " + F(s.value), 1)
30971
30992
  ]),
30972
30993
  _: 2
30973
30994
  }, 1032, ["onClick"]))), 128))
@@ -30989,7 +31010,7 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
30989
31010
  const i = Gi(e, "visible"), t = n, o = K(), l = (s) => {
30990
31011
  t("select", s), o.value = void 0;
30991
31012
  };
30992
- return (s, h) => (Y(), _(b(_e), {
31013
+ return (s, h) => (Y(), _(z(_e), {
30993
31014
  "virtual-ref": e.virtualRef,
30994
31015
  trigger: "click",
30995
31016
  "virtual-triggering": "",
@@ -31000,8 +31021,8 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31000
31021
  placement: "top"
31001
31022
  }, {
31002
31023
  default: N(() => [
31003
- A("div", Pg, [
31004
- (Y(!0), L(en, null, gn(b(yl), (r) => (Y(), _(b(on), {
31024
+ v("div", Pg, [
31025
+ (Y(!0), L(en, null, gn(z(yl), (r) => (Y(), _(z(on), {
31005
31026
  key: r.label,
31006
31027
  onClick: (u) => l(r.value)
31007
31028
  }, {
@@ -31010,12 +31031,12 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31010
31031
  ]),
31011
31032
  _: 2
31012
31033
  }, 1032, ["onClick"]))), 128)),
31013
- H(b(on), {
31034
+ H(z(on), {
31014
31035
  onClick: h[2] || (h[2] = bi((r) => o.value && l(o.value), ["stop"]))
31015
31036
  }, {
31016
31037
  default: N(() => [
31017
- h[4] || (h[4] = A("span", null, "停顿", -1)),
31018
- H(b(kl), {
31038
+ h[4] || (h[4] = v("span", null, "停顿", -1)),
31039
+ H(z(kl), {
31019
31040
  modelValue: o.value,
31020
31041
  "onUpdate:modelValue": h[0] || (h[0] = (r) => o.value = r),
31021
31042
  min: 0.1,
@@ -31025,7 +31046,7 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31025
31046
  onClick: h[1] || (h[1] = bi(() => {
31026
31047
  }, ["stop"]))
31027
31048
  }, null, 8, ["modelValue"]),
31028
- h[5] || (h[5] = A("span", null, "秒", -1))
31049
+ h[5] || (h[5] = v("span", null, "秒", -1))
31029
31050
  ]),
31030
31051
  _: 1
31031
31052
  })
@@ -31047,15 +31068,15 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31047
31068
  s.value = !s.value;
31048
31069
  }, c = () => {
31049
31070
  u == null || u.abort(), a();
31050
- }, d = async () => {
31051
- const m = h.value[0], y = l.value.parseDocument;
31052
- if (!(!m || !y)) {
31071
+ }, p = async () => {
31072
+ const d = h.value[0], y = l.value.parseDocument;
31073
+ if (!(!d || !y)) {
31053
31074
  r.value = !0, u == null || u.abort(), u = new AbortController();
31054
31075
  try {
31055
- const j = await y(m, u.signal);
31056
- t("confirm", j), a();
31057
- } catch (j) {
31058
- j instanceof Error && j.name === "AbortError" || o("error", "解析失败");
31076
+ const b = await y(d, u.signal);
31077
+ t("confirm", b), a();
31078
+ } catch (b) {
31079
+ b instanceof Error && b.name === "AbortError" || o("error", "解析失败");
31059
31080
  } finally {
31060
31081
  r.value = !1, u = null;
31061
31082
  }
@@ -31065,15 +31086,15 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31065
31086
  open: () => {
31066
31087
  a();
31067
31088
  }
31068
- }), Se(() => u == null ? void 0 : u.abort()), (m, y) => (Y(), _(b(Oe), {
31089
+ }), Se(() => u == null ? void 0 : u.abort()), (d, y) => (Y(), _(z(Oe), {
31069
31090
  modelValue: s.value,
31070
- "onUpdate:modelValue": y[1] || (y[1] = (j) => s.value = j),
31091
+ "onUpdate:modelValue": y[1] || (y[1] = (b) => s.value = b),
31071
31092
  width: 800,
31072
31093
  title: "上传文稿",
31073
31094
  "modal-class": "word-upload-modal"
31074
31095
  }, {
31075
31096
  footer: N(() => [
31076
- H(b(on), {
31097
+ H(z(on), {
31077
31098
  plain: "",
31078
31099
  onClick: c
31079
31100
  }, {
@@ -31082,9 +31103,9 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31082
31103
  ])]),
31083
31104
  _: 1
31084
31105
  }),
31085
- H(b(on), {
31106
+ H(z(on), {
31086
31107
  type: "info",
31087
- onClick: d,
31108
+ onClick: p,
31088
31109
  disabled: f.value,
31089
31110
  loading: r.value
31090
31111
  }, {
@@ -31095,7 +31116,7 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31095
31116
  }, 8, ["disabled", "loading"])
31096
31117
  ]),
31097
31118
  default: N(() => [
31098
- A("div", Dg, [
31119
+ v("div", Dg, [
31099
31120
  H(Fh, {
31100
31121
  class: "lsh-audio-upload",
31101
31122
  accept: [".txt", ".docx"],
@@ -31104,13 +31125,13 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31104
31125
  tip: "支持 TXT、DOCX 格式,大小不超过 3 MB",
31105
31126
  ref: "uploadRef",
31106
31127
  modelValue: h.value,
31107
- "onUpdate:modelValue": y[0] || (y[0] = (j) => h.value = j)
31128
+ "onUpdate:modelValue": y[0] || (y[0] = (b) => h.value = b)
31108
31129
  }, null, 8, ["modelValue"]),
31109
- A("div", Bg, [
31110
- y[2] || (y[2] = A("div", { class: "lsh-title" }, "注意事项:", -1)),
31111
- (Y(), L(en, null, gn(g, (j, Z) => A("div", Qg, [
31112
- A("span", null, F(Z + 1) + ".", 1),
31113
- A("span", null, F(j), 1)
31130
+ v("div", Bg, [
31131
+ y[2] || (y[2] = v("div", { class: "lsh-title" }, "注意事项:", -1)),
31132
+ (Y(), L(en, null, gn(g, (b, A) => v("div", Qg, [
31133
+ v("span", null, F(A + 1) + ".", 1),
31134
+ v("span", null, F(b), 1)
31114
31135
  ])), 64))
31115
31136
  ])
31116
31137
  ])
@@ -31125,189 +31146,189 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31125
31146
  customStop: !1,
31126
31147
  language: !1,
31127
31148
  number: !1
31128
- }), u = K(), g = K(), a = K(), c = K(), d = K(), {
31149
+ }), u = K(), g = K(), a = K(), c = K(), p = K(), {
31129
31150
  toolList: f,
31130
- languageOptions: m,
31151
+ languageOptions: d,
31131
31152
  numberToTextList: y,
31132
- isToolDisabled: j,
31133
- insertCustomStop: Z,
31153
+ isToolDisabled: b,
31154
+ insertCustomStop: A,
31134
31155
  setLanguage: I,
31135
31156
  replaceText: w,
31136
31157
  markPinyin: J
31137
31158
  } = qr({
31138
31159
  editorContext: n,
31139
31160
  openModal: {
31140
- pinyin: (z) => {
31141
- var S;
31142
- return (S = g.value) == null ? void 0 : S.open(z);
31161
+ pinyin: (q) => {
31162
+ var O;
31163
+ return (O = g.value) == null ? void 0 : O.open(q);
31143
31164
  },
31144
- replace: (z) => {
31145
- var S;
31146
- return (S = u.value) == null ? void 0 : S.open(z);
31165
+ replace: (q) => {
31166
+ var O;
31167
+ return (O = u.value) == null ? void 0 : O.open(q);
31147
31168
  },
31148
- formula: (z) => {
31149
- var S;
31150
- return (S = c.value) == null ? void 0 : S.open(z);
31169
+ formula: (q) => {
31170
+ var O;
31171
+ return (O = c.value) == null ? void 0 : O.open(q);
31151
31172
  },
31152
31173
  aiRewrite: () => {
31153
- var z;
31154
- return (z = d.value) == null ? void 0 : z.open();
31174
+ var q;
31175
+ return (q = p.value) == null ? void 0 : q.open();
31155
31176
  },
31156
31177
  upload: () => {
31157
- var z;
31158
- return (z = a.value) == null ? void 0 : z.open();
31178
+ var q;
31179
+ return (q = a.value) == null ? void 0 : q.open();
31159
31180
  }
31160
31181
  }
31161
31182
  }), { visibleList: k, hiddenList: G } = sa({
31162
31183
  list: f,
31163
31184
  toolbarRef: t,
31164
31185
  measureRef: o
31165
- }), M = (z, S) => {
31166
- if (!z || z instanceof Element) return;
31167
- const X = z.getVirtualRef();
31168
- X && l.value.set(S, X);
31186
+ }), M = (q, O) => {
31187
+ if (!q || q instanceof Element) return;
31188
+ const X = q.getVirtualRef();
31189
+ X && l.value.set(O, X);
31169
31190
  }, V = /* @__PURE__ */ new Set([
31170
31191
  P.customStop.type,
31171
31192
  P.language.type,
31172
31193
  P.number.type
31173
- ]), q = (z) => {
31174
- var S;
31175
- j(z) || ((S = z.onClick) == null || S.call(z), s.value = z.tool.type);
31176
- }, p = (z) => {
31177
- q(z), V.has(z.tool.type) || (h.value = !1);
31178
- }, W = (z) => {
31179
- Z(z), r.customStop = !1;
31180
- }, O = (z) => {
31181
- I(z) && (r.language = !1);
31182
- }, v = (z) => {
31183
- w(z), r.number = !1;
31184
- }, C = (z) => s.value !== z || !r[z];
31185
- return cn(G, (z) => {
31186
- z.length || (h.value = !1);
31187
- }), (z, S) => (Y(), L("div", {
31194
+ ]), S = (q) => {
31195
+ var O;
31196
+ b(q) || ((O = q.onClick) == null || O.call(q), s.value = q.tool.type);
31197
+ }, m = (q) => {
31198
+ S(q), V.has(q.tool.type) || (h.value = !1);
31199
+ }, C = (q) => {
31200
+ A(q), r.customStop = !1;
31201
+ }, W = (q) => {
31202
+ I(q) && (r.language = !1);
31203
+ }, j = (q) => {
31204
+ w(q), r.number = !1;
31205
+ }, x = (q) => s.value !== q || !r[q];
31206
+ return cn(G, (q) => {
31207
+ q.length || (h.value = !1);
31208
+ }), (q, O) => (Y(), L("div", {
31188
31209
  ref_key: "toolbarRef",
31189
31210
  ref: t,
31190
31211
  class: "lsh-toolbar-box"
31191
31212
  }, [
31192
- (Y(!0), L(en, null, gn(b(k), (x) => (Y(), _(yi, {
31193
- key: x.tool.label,
31213
+ (Y(!0), L(en, null, gn(z(k), (Z) => (Y(), _(yi, {
31214
+ key: Z.tool.label,
31194
31215
  ref_for: !0,
31195
- ref: (X) => M(X, x.tool.type),
31216
+ ref: (X) => M(X, Z.tool.type),
31196
31217
  class: "lsh-tool-btn",
31197
- item: x,
31198
- plain: C(x.tool.type),
31199
- disabled: b(j)(x),
31200
- onClick: (X) => q(x)
31218
+ item: Z,
31219
+ plain: x(Z.tool.type),
31220
+ disabled: z(b)(Z),
31221
+ onClick: (X) => S(Z)
31201
31222
  }, null, 8, ["item", "plain", "disabled", "onClick"]))), 128)),
31202
- b(G).length ? (Y(), _(b(_e), {
31223
+ z(G).length ? (Y(), _(z(_e), {
31203
31224
  key: 0,
31204
31225
  visible: h.value,
31205
- "onUpdate:visible": S[0] || (S[0] = (x) => h.value = x),
31226
+ "onUpdate:visible": O[0] || (O[0] = (Z) => h.value = Z),
31206
31227
  "show-arrow": !1,
31207
31228
  "popper-class": "lsh-popper lsh-more-popper",
31208
31229
  placement: "top-end",
31209
31230
  transition: "popper-slide"
31210
31231
  }, {
31211
31232
  reference: N(() => [
31212
- H(b(on), {
31233
+ H(z(on), {
31213
31234
  class: "lsh-tool-btn",
31214
31235
  plain: !h.value
31215
31236
  }, {
31216
31237
  icon: N(() => [
31217
- H(b(rn), {
31238
+ H(z(rn), {
31218
31239
  name: "editor-more",
31219
31240
  size: "18"
31220
31241
  })
31221
31242
  ]),
31222
31243
  default: N(() => [
31223
- S[4] || (S[4] = A("span", null, "更多", -1))
31244
+ O[4] || (O[4] = v("span", null, "更多", -1))
31224
31245
  ]),
31225
31246
  _: 1
31226
31247
  }, 8, ["plain"])
31227
31248
  ]),
31228
31249
  default: N(() => [
31229
- A("div", nc, [
31230
- (Y(!0), L(en, null, gn(b(G), (x) => (Y(), _(yi, {
31231
- key: x.tool.label,
31250
+ v("div", nc, [
31251
+ (Y(!0), L(en, null, gn(z(G), (Z) => (Y(), _(yi, {
31252
+ key: Z.tool.label,
31232
31253
  ref_for: !0,
31233
- ref: (X) => M(X, x.tool.type),
31254
+ ref: (X) => M(X, Z.tool.type),
31234
31255
  class: "lsh-more-item",
31235
- item: x,
31236
- plain: C(x.tool.type),
31237
- disabled: b(j)(x),
31238
- onClick: (X) => p(x)
31256
+ item: Z,
31257
+ plain: x(Z.tool.type),
31258
+ disabled: z(b)(Z),
31259
+ onClick: (X) => m(Z)
31239
31260
  }, null, 8, ["item", "plain", "disabled", "onClick"]))), 128))
31240
31261
  ])
31241
31262
  ]),
31242
31263
  _: 1
31243
31264
  }, 8, ["visible"])) : yn("", !0),
31244
- A("div", {
31265
+ v("div", {
31245
31266
  ref_key: "measureRef",
31246
31267
  ref: o,
31247
31268
  class: "lsh-toolbar-measure"
31248
31269
  }, [
31249
- (Y(!0), L(en, null, gn(b(f), (x) => (Y(), _(yi, {
31250
- key: x.tool.label,
31270
+ (Y(!0), L(en, null, gn(z(f), (Z) => (Y(), _(yi, {
31271
+ key: Z.tool.label,
31251
31272
  class: "lsh-tool-btn",
31252
- item: x
31273
+ item: Z
31253
31274
  }, null, 8, ["item"]))), 128)),
31254
- H(b(on), { class: "lsh-tool-btn" }, {
31275
+ H(z(on), { class: "lsh-tool-btn" }, {
31255
31276
  icon: N(() => [
31256
- H(b(rn), {
31277
+ H(z(rn), {
31257
31278
  name: "editor-more",
31258
31279
  size: "18"
31259
31280
  })
31260
31281
  ]),
31261
31282
  default: N(() => [
31262
- S[5] || (S[5] = A("span", null, "更多", -1))
31283
+ O[5] || (O[5] = v("span", null, "更多", -1))
31263
31284
  ]),
31264
31285
  _: 1
31265
31286
  })
31266
31287
  ], 512),
31267
31288
  H(Eg, {
31268
31289
  visible: r.customStop,
31269
- "onUpdate:visible": S[1] || (S[1] = (x) => r.customStop = x),
31270
- "virtual-ref": l.value.get(b(P).customStop.type),
31271
- onSelect: W
31290
+ "onUpdate:visible": O[1] || (O[1] = (Z) => r.customStop = Z),
31291
+ "virtual-ref": l.value.get(z(P).customStop.type),
31292
+ onSelect: C
31272
31293
  }, null, 8, ["visible", "virtual-ref"]),
31273
31294
  H(Lg, {
31274
31295
  visible: r.language,
31275
- "onUpdate:visible": S[2] || (S[2] = (x) => r.language = x),
31276
- "virtual-ref": l.value.get(b(P).language.type),
31277
- options: b(m),
31278
- onSelect: O
31296
+ "onUpdate:visible": O[2] || (O[2] = (Z) => r.language = Z),
31297
+ "virtual-ref": l.value.get(z(P).language.type),
31298
+ options: z(d),
31299
+ onSelect: W
31279
31300
  }, null, 8, ["visible", "virtual-ref", "options"]),
31280
31301
  H(Fg, {
31281
31302
  visible: r.number,
31282
- "onUpdate:visible": S[3] || (S[3] = (x) => r.number = x),
31283
- "virtual-ref": l.value.get(b(P).number.type),
31284
- options: b(y),
31285
- onSelect: v
31303
+ "onUpdate:visible": O[3] || (O[3] = (Z) => r.number = Z),
31304
+ "virtual-ref": l.value.get(z(P).number.type),
31305
+ options: z(y),
31306
+ onSelect: j
31286
31307
  }, null, 8, ["visible", "virtual-ref", "options"]),
31287
31308
  H(Xg, {
31288
31309
  ref_key: "replaceTextModalRef",
31289
31310
  ref: u,
31290
- onConfirm: b(w)
31311
+ onConfirm: z(w)
31291
31312
  }, null, 8, ["onConfirm"]),
31292
31313
  H(Kg, {
31293
31314
  ref_key: "markPinyinModalRef",
31294
31315
  ref: g,
31295
- onConfirm: b(J)
31316
+ onConfirm: z(J)
31296
31317
  }, null, 8, ["onConfirm"]),
31297
31318
  H($g, {
31298
31319
  ref_key: "uploadModalRef",
31299
31320
  ref: a,
31300
- onConfirm: b(i)
31321
+ onConfirm: z(i)
31301
31322
  }, null, 8, ["onConfirm"]),
31302
31323
  H(ya, {
31303
31324
  ref_key: "formulaModalRef",
31304
31325
  ref: c,
31305
- onConfirm: b(w)
31326
+ onConfirm: z(w)
31306
31327
  }, null, 8, ["onConfirm"]),
31307
31328
  H(na, {
31308
31329
  ref_key: "aiRewriteModalRef",
31309
- ref: d,
31310
- onConfirm: b(i)
31330
+ ref: p,
31331
+ onConfirm: z(i)
31311
31332
  }, null, 8, ["onConfirm"])
31312
31333
  ], 512));
31313
31334
  }
@@ -31322,6 +31343,7 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31322
31343
  features: { default: () => ({}) },
31323
31344
  services: { default: () => ({}) },
31324
31345
  getPreviewParams: {},
31346
+ getPlaybackSpeed: {},
31325
31347
  showSelectionMenu: { type: Boolean, default: !0 },
31326
31348
  showFullscreen: { type: Boolean, default: !0 }
31327
31349
  },
@@ -31337,13 +31359,13 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31337
31359
  return cn(
31338
31360
  () => t.modelValue,
31339
31361
  (a) => {
31340
- var d;
31362
+ var p;
31341
31363
  const c = Pt(a);
31342
31364
  if (c === h) {
31343
31365
  h = void 0;
31344
31366
  return;
31345
31367
  }
31346
- (d = s.value) == null || d.setContent(c);
31368
+ (p = s.value) == null || p.setContent(c);
31347
31369
  }
31348
31370
  ), n({
31349
31371
  clear: () => {
@@ -31367,10 +31389,10 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31367
31389
  return (c = s.value) == null ? void 0 : c.replaceText(a);
31368
31390
  },
31369
31391
  handleChangeVoice: (a, c) => {
31370
- var d;
31371
- return ((d = s.value) == null ? void 0 : d.handleChangeVoice(a, c)) ?? Promise.resolve(!1);
31392
+ var p;
31393
+ return ((p = s.value) == null ? void 0 : p.handleChangeVoice(a, c)) ?? Promise.resolve(!1);
31372
31394
  }
31373
- }), (a, c) => (Y(), _(b(Xu), {
31395
+ }), (a, c) => (Y(), _(z(Xu), {
31374
31396
  ref_key: "rootRef",
31375
31397
  ref: s,
31376
31398
  "initial-content": t.modelValue,
@@ -31381,14 +31403,15 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31381
31403
  features: t.features,
31382
31404
  services: t.services,
31383
31405
  "get-preview-params": t.getPreviewParams,
31406
+ "get-playback-speed": t.getPlaybackSpeed,
31384
31407
  "show-selection-menu": t.showSelectionMenu,
31385
31408
  onChange: r,
31386
31409
  onReady: u
31387
31410
  }, {
31388
31411
  default: N(() => {
31389
- var d, f, m, y, j, Z, I;
31412
+ var p, f, d, y, b, A, I;
31390
31413
  return [
31391
- A("div", {
31414
+ v("div", {
31392
31415
  class: bn([
31393
31416
  "tts-rich-text-editor lsh-tts-box",
31394
31417
  {
@@ -31397,10 +31420,10 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31397
31420
  }
31398
31421
  ])
31399
31422
  }, [
31400
- A("div", tc, [
31401
- A("div", oc, [
31423
+ v("div", tc, [
31424
+ v("div", oc, [
31402
31425
  wn(a.$slots, "toolbar-before", {
31403
- editor: (d = s.value) == null ? void 0 : d.editor
31426
+ editor: (p = s.value) == null ? void 0 : p.editor
31404
31427
  }, void 0, !0),
31405
31428
  H(ic),
31406
31429
  wn(a.$slots, "toolbar-after", {
@@ -31413,26 +31436,26 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31413
31436
  title: l.value ? "退出全屏" : "全屏编辑",
31414
31437
  onClick: c[0] || (c[0] = (w) => l.value = !l.value)
31415
31438
  }, [
31416
- H(b(rn), {
31439
+ H(z(rn), {
31417
31440
  name: `editor-fullscreen-${l.value ? "shrink" : "expand"}`,
31418
31441
  size: "20"
31419
31442
  }, null, 8, ["name"])
31420
31443
  ], 8, lc)) : yn("", !0)
31421
31444
  ]),
31422
- A("div", sc, [
31423
- H(b(vr), { class: "editor-shell" }),
31445
+ v("div", sc, [
31446
+ H(z(vr), { class: "editor-shell" }),
31424
31447
  wn(a.$slots, "editor-after", {
31425
- editor: (m = s.value) == null ? void 0 : m.editor
31448
+ editor: (d = s.value) == null ? void 0 : d.editor
31426
31449
  }, void 0, !0)
31427
31450
  ]),
31428
- A("div", hc, [
31451
+ v("div", hc, [
31429
31452
  wn(a.$slots, "footer-before", {
31430
31453
  editor: (y = s.value) == null ? void 0 : y.editor,
31431
- textLength: ((j = s.value) == null ? void 0 : j.textLength) ?? 0
31454
+ textLength: ((b = s.value) == null ? void 0 : b.textLength) ?? 0
31432
31455
  }, void 0, !0),
31433
31456
  H(la),
31434
31457
  wn(a.$slots, "footer-after", {
31435
- editor: (Z = s.value) == null ? void 0 : Z.editor,
31458
+ editor: (A = s.value) == null ? void 0 : A.editor,
31436
31459
  textLength: ((I = s.value) == null ? void 0 : I.textLength) ?? 0
31437
31460
  }, void 0, !0)
31438
31461
  ])
@@ -31441,9 +31464,9 @@ const gg = { class: "lsh-header-content" }, cg = { class: "lsh-content-box" }, d
31441
31464
  ];
31442
31465
  }),
31443
31466
  _: 3
31444
- }, 8, ["initial-content", "text-limit", "voice-version", "placeholder", "disabled", "features", "services", "get-preview-params", "show-selection-menu"]));
31467
+ }, 8, ["initial-content", "text-limit", "voice-version", "placeholder", "disabled", "features", "services", "get-preview-params", "get-playback-speed", "show-selection-menu"]));
31445
31468
  }
31446
- }), yc = /* @__PURE__ */ sn(rc, [["__scopeId", "data-v-139882dc"]]);
31469
+ }), yc = /* @__PURE__ */ sn(rc, [["__scopeId", "data-v-3ed36f16"]]);
31447
31470
  export {
31448
31471
  ce as CustomTagName,
31449
31472
  on as CxButton,