@sy-design/svelte 1.0.14 → 1.0.16

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.es.js CHANGED
@@ -12,11 +12,11 @@ var un = (s, e, t) => e in s ? xi(s, e, { enumerable: !0, configurable: !0, writ
12
12
  for (var t of es(e))
13
13
  Li.call(e, t) && un(s, t, e[t]);
14
14
  return s;
15
- }, be = (s, e) => Ii(s, Ri(e));
15
+ }, ye = (s, e) => Ii(s, Ri(e));
16
16
  var re = (s, e, t) => un(s, typeof e != "symbol" ? e + "" : e, t), Mi = (s, e, t) => e.has(s) || ts("Cannot " + t);
17
17
  var ns = (s, e, t) => e.has(s) ? ts("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(s) : e.set(s, t);
18
18
  var Wt = (s, e, t) => (Mi(s, e, "access private method"), t);
19
- var Ee = (s, e, t) => new Promise((n, o) => {
19
+ var Se = (s, e, t) => new Promise((n, o) => {
20
20
  var l = (c) => {
21
21
  try {
22
22
  r(t.next(c));
@@ -40,7 +40,7 @@ function Vs(s) {
40
40
  function ss() {
41
41
  return /* @__PURE__ */ Object.create(null);
42
42
  }
43
- function Se(s) {
43
+ function Ae(s) {
44
44
  s.forEach(Vs);
45
45
  }
46
46
  function xn(s) {
@@ -63,20 +63,20 @@ function Oi(s, ...e) {
63
63
  }
64
64
  const Qs = typeof window != "undefined";
65
65
  let is = Qs ? () => window.performance.now() : () => Date.now(), Js = Qs ? (s) => requestAnimationFrame(s) : Oe;
66
- const _t = /* @__PURE__ */ new Set();
66
+ const kt = /* @__PURE__ */ new Set();
67
67
  function Ks(s) {
68
- _t.forEach((e) => {
69
- e.c(s) || (_t.delete(e), e.f());
70
- }), _t.size !== 0 && Js(Ks);
68
+ kt.forEach((e) => {
69
+ e.c(s) || (kt.delete(e), e.f());
70
+ }), kt.size !== 0 && Js(Ks);
71
71
  }
72
72
  function Di(s) {
73
73
  let e;
74
- return _t.size === 0 && Js(Ks), {
74
+ return kt.size === 0 && Js(Ks), {
75
75
  promise: new Promise((t) => {
76
- _t.add(e = { c: s, f: t });
76
+ kt.add(e = { c: s, f: t });
77
77
  }),
78
78
  abort() {
79
- _t.delete(e);
79
+ kt.delete(e);
80
80
  }
81
81
  };
82
82
  }
@@ -96,17 +96,17 @@ function $s(s, e) {
96
96
  function S(s) {
97
97
  return document.createElement(s);
98
98
  }
99
- function J(s) {
99
+ function Q(s) {
100
100
  return document.createElementNS("http://www.w3.org/2000/svg", s);
101
101
  }
102
- function ye(s) {
102
+ function Te(s) {
103
103
  return document.createTextNode(s);
104
104
  }
105
105
  function j() {
106
- return ye(" ");
106
+ return Te(" ");
107
107
  }
108
108
  function nn() {
109
- return ye("");
109
+ return Te("");
110
110
  }
111
111
  function G(s, e, t, n) {
112
112
  return s.addEventListener(e, t, n), () => s.removeEventListener(e, t, n);
@@ -126,10 +126,10 @@ function Ne(s, e) {
126
126
  e = "" + e, s.data !== e && (s.data = /** @type {string} */
127
127
  e);
128
128
  }
129
- function st(s, e) {
129
+ function nt(s, e) {
130
130
  s.value = e == null ? "" : e;
131
131
  }
132
- function F(s, e, t, n) {
132
+ function N(s, e, t, n) {
133
133
  t == null ? s.style.removeProperty(e) : s.style.setProperty(e, t, "");
134
134
  }
135
135
  function os(s, e, t) {
@@ -149,13 +149,13 @@ function Ni(s) {
149
149
  function $(s, e, t) {
150
150
  s.classList.toggle(e, !!t);
151
151
  }
152
- let zt;
153
- function Ct(s) {
154
- zt = s;
152
+ let Mt;
153
+ function Rt(s) {
154
+ Mt = s;
155
155
  }
156
156
  function In() {
157
- if (!zt) throw new Error("Function called outside component initialization");
158
- return zt;
157
+ if (!Mt) throw new Error("Function called outside component initialization");
158
+ return Mt;
159
159
  }
160
160
  function Rn(s) {
161
161
  In().$$.on_mount.push(s);
@@ -166,107 +166,107 @@ function Fi(s) {
166
166
  function Hi(s) {
167
167
  In().$$.on_destroy.push(s);
168
168
  }
169
- const gt = [], wt = [];
170
- let kt = [];
169
+ const gt = [], zt = [];
170
+ let _t = [];
171
171
  const ls = [], Bi = /* @__PURE__ */ Promise.resolve();
172
172
  let wn = !1;
173
173
  function Ui() {
174
174
  wn || (wn = !0, Bi.then(ti));
175
175
  }
176
176
  function Jt(s) {
177
- kt.push(s);
177
+ _t.push(s);
178
178
  }
179
179
  const fn = /* @__PURE__ */ new Set();
180
180
  let dt = 0;
181
181
  function ti() {
182
182
  if (dt !== 0)
183
183
  return;
184
- const s = zt;
184
+ const s = Mt;
185
185
  do {
186
186
  try {
187
187
  for (; dt < gt.length; ) {
188
188
  const e = gt[dt];
189
- dt++, Ct(e), ji(e.$$);
189
+ dt++, Rt(e), ji(e.$$);
190
190
  }
191
191
  } catch (e) {
192
192
  throw gt.length = 0, dt = 0, e;
193
193
  }
194
- for (Ct(null), gt.length = 0, dt = 0; wt.length; ) wt.pop()();
195
- for (let e = 0; e < kt.length; e += 1) {
196
- const t = kt[e];
194
+ for (Rt(null), gt.length = 0, dt = 0; zt.length; ) zt.pop()();
195
+ for (let e = 0; e < _t.length; e += 1) {
196
+ const t = _t[e];
197
197
  fn.has(t) || (fn.add(t), t());
198
198
  }
199
- kt.length = 0;
199
+ _t.length = 0;
200
200
  } while (gt.length);
201
201
  for (; ls.length; )
202
202
  ls.pop()();
203
- wn = !1, fn.clear(), Ct(s);
203
+ wn = !1, fn.clear(), Rt(s);
204
204
  }
205
205
  function ji(s) {
206
206
  if (s.fragment !== null) {
207
- s.update(), Se(s.before_update);
207
+ s.update(), Ae(s.before_update);
208
208
  const e = s.dirty;
209
209
  s.dirty = [-1], s.fragment && s.fragment.p(s.ctx, e), s.after_update.forEach(Jt);
210
210
  }
211
211
  }
212
212
  function Wi(s) {
213
213
  const e = [], t = [];
214
- kt.forEach((n) => s.indexOf(n) === -1 ? e.push(n) : t.push(n)), t.forEach((n) => n()), kt = e;
214
+ _t.forEach((n) => s.indexOf(n) === -1 ? e.push(n) : t.push(n)), t.forEach((n) => n()), _t = e;
215
215
  }
216
216
  const Vt = /* @__PURE__ */ new Set();
217
- let rt;
217
+ let lt;
218
218
  function Cn() {
219
- rt = {
219
+ lt = {
220
220
  r: 0,
221
221
  c: [],
222
- p: rt
222
+ p: lt
223
223
  // parent group
224
224
  };
225
225
  }
226
226
  function Ln() {
227
- rt.r || Se(rt.c), rt = rt.p;
227
+ lt.r || Ae(lt.c), lt = lt.p;
228
228
  }
229
229
  function je(s, e) {
230
230
  s && s.i && (Vt.delete(s), s.i(e));
231
231
  }
232
- function $e(s, e, t, n) {
232
+ function Ke(s, e, t, n) {
233
233
  if (s && s.o) {
234
234
  if (Vt.has(s)) return;
235
- Vt.add(s), rt.c.push(() => {
235
+ Vt.add(s), lt.c.push(() => {
236
236
  Vt.delete(s), n && (t && s.d(1), n());
237
237
  }), s.o(e);
238
238
  } else n && n();
239
239
  }
240
- function it(s) {
240
+ function st(s) {
241
241
  return (s == null ? void 0 : s.length) !== void 0 ? s : Array.from(s);
242
242
  }
243
243
  function ni(s, e) {
244
244
  s.d(1), e.delete(s.key);
245
245
  }
246
246
  function si(s, e, t, n, o, l, i, r, c, u, h, p) {
247
- let m = s.length, g = l.length, _ = m;
247
+ let m = s.length, g = l.length, k = m;
248
248
  const T = {};
249
- for (; _--; ) T[s[_].key] = _;
249
+ for (; k--; ) T[s[k].key] = k;
250
250
  const R = [], L = /* @__PURE__ */ new Map(), A = /* @__PURE__ */ new Map(), w = [];
251
- for (_ = g; _--; ) {
252
- const x = p(o, l, _), M = t(x);
251
+ for (k = g; k--; ) {
252
+ const x = p(o, l, k), M = t(x);
253
253
  let z = i.get(M);
254
- z ? w.push(() => z.p(x, e)) : (z = u(M, x), z.c()), L.set(M, R[_] = z), M in T && A.set(M, Math.abs(_ - T[M]));
254
+ z ? w.push(() => z.p(x, e)) : (z = u(M, x), z.c()), L.set(M, R[k] = z), M in T && A.set(M, Math.abs(k - T[M]));
255
255
  }
256
- const k = /* @__PURE__ */ new Set(), y = /* @__PURE__ */ new Set();
256
+ const _ = /* @__PURE__ */ new Set(), b = /* @__PURE__ */ new Set();
257
257
  function v(x) {
258
258
  je(x, 1), x.m(r, h), i.set(x.key, x), h = x.first, g--;
259
259
  }
260
260
  for (; m && g; ) {
261
261
  const x = R[g - 1], M = s[m - 1], z = x.key, Z = M.key;
262
- x === M ? (h = x.first, m--, g--) : L.has(Z) ? !i.has(z) || k.has(z) ? v(x) : y.has(Z) ? m-- : A.get(z) > A.get(Z) ? (y.add(z), v(x)) : (k.add(Z), m--) : (c(M, i), m--);
262
+ x === M ? (h = x.first, m--, g--) : L.has(Z) ? !i.has(z) || _.has(z) ? v(x) : b.has(Z) ? m-- : A.get(z) > A.get(Z) ? (b.add(z), v(x)) : (_.add(Z), m--) : (c(M, i), m--);
263
263
  }
264
264
  for (; m--; ) {
265
265
  const x = s[m];
266
266
  L.has(x.key) || c(x, i);
267
267
  }
268
268
  for (; g; ) v(R[g - 1]);
269
- return Se(w), R;
269
+ return Ae(w), R;
270
270
  }
271
271
  function Mn(s) {
272
272
  s && s.c();
@@ -275,19 +275,19 @@ function sn(s, e, t) {
275
275
  const { fragment: n, after_update: o } = s.$$;
276
276
  n && n.m(e, t), Jt(() => {
277
277
  const l = s.$$.on_mount.map(Vs).filter(xn);
278
- s.$$.on_destroy ? s.$$.on_destroy.push(...l) : Se(l), s.$$.on_mount = [];
278
+ s.$$.on_destroy ? s.$$.on_destroy.push(...l) : Ae(l), s.$$.on_mount = [];
279
279
  }), o.forEach(Jt);
280
280
  }
281
281
  function on(s, e) {
282
282
  const t = s.$$;
283
- t.fragment !== null && (Wi(t.after_update), Se(t.on_destroy), t.fragment && t.fragment.d(e), t.on_destroy = t.fragment = null, t.ctx = []);
283
+ t.fragment !== null && (Wi(t.after_update), Ae(t.on_destroy), t.fragment && t.fragment.d(e), t.on_destroy = t.fragment = null, t.ctx = []);
284
284
  }
285
285
  function qi(s, e) {
286
286
  s.$$.dirty[0] === -1 && (gt.push(s), Ui(), s.$$.dirty.fill(0)), s.$$.dirty[e / 31 | 0] |= 1 << e % 31;
287
287
  }
288
288
  function zn(s, e, t, n, o, l, i = null, r = [-1]) {
289
- const c = zt;
290
- Ct(s);
289
+ const c = Mt;
290
+ Rt(s);
291
291
  const u = s.$$ = {
292
292
  fragment: null,
293
293
  ctx: [],
@@ -312,9 +312,9 @@ function zn(s, e, t, n, o, l, i = null, r = [-1]) {
312
312
  i && i(u.root);
313
313
  let h = !1;
314
314
  if (u.ctx = t ? t(s, e.props || {}, (p, m, ...g) => {
315
- const _ = g.length ? g[0] : m;
316
- return u.ctx && o(u.ctx[p], u.ctx[p] = _) && (!u.skip_bound && u.bound[p] && u.bound[p](_), h && qi(s, p)), m;
317
- }) : [], u.update(), h = !0, Se(u.before_update), u.fragment = n ? n(u.ctx) : !1, e.target) {
315
+ const k = g.length ? g[0] : m;
316
+ return u.ctx && o(u.ctx[p], u.ctx[p] = k) && (!u.skip_bound && u.bound[p] && u.bound[p](k), h && qi(s, p)), m;
317
+ }) : [], u.update(), h = !0, Ae(u.before_update), u.fragment = n ? n(u.ctx) : !1, e.target) {
318
318
  if (e.hydrate) {
319
319
  const p = Pi(e.target);
320
320
  u.fragment && u.fragment.l(p), p.forEach(W);
@@ -322,7 +322,7 @@ function zn(s, e, t, n, o, l, i = null, r = [-1]) {
322
322
  u.fragment && u.fragment.c();
323
323
  e.intro && je(s.$$.fragment), sn(s, e.target, e.anchor), ti();
324
324
  }
325
- Ct(c);
325
+ Rt(c);
326
326
  }
327
327
  class On {
328
328
  constructor() {
@@ -423,20 +423,20 @@ function bn(s, e, t, n) {
423
423
  function Zi(s, e = {}) {
424
424
  const t = Yi(s), { stiffness: n = 0.15, damping: o = 0.8, precision: l = 0.01 } = e;
425
425
  let i, r, c, u = s, h = s, p = 1, m = 0, g = !1;
426
- function _(R, L = {}) {
426
+ function k(R, L = {}) {
427
427
  h = R;
428
428
  const A = c = {};
429
429
  return s == null || L.hard || T.stiffness >= 1 && T.damping >= 1 ? (g = !0, i = is(), u = R, t.set(s = h), Promise.resolve()) : (L.soft && (m = 1 / ((L.soft === !0 ? 0.5 : +L.soft) * 60), p = 0), r || (i = is(), g = !1, r = Di((w) => {
430
430
  if (g)
431
431
  return g = !1, r = null, !1;
432
432
  p = Math.min(p + m, 1);
433
- const k = {
433
+ const _ = {
434
434
  inv_mass: p,
435
435
  opts: T,
436
436
  settled: !0,
437
437
  dt: (w - i) * 60 / 1e3
438
- }, y = bn(k, u, s, h);
439
- return i = w, u = s, t.set(s = y), k.settled && (r = null), !k.settled;
438
+ }, b = bn(_, u, s, h);
439
+ return i = w, u = s, t.set(s = b), _.settled && (r = null), !_.settled;
440
440
  })), new Promise((w) => {
441
441
  r.promise.then(() => {
442
442
  A === c && w();
@@ -444,8 +444,8 @@ function Zi(s, e = {}) {
444
444
  }));
445
445
  }
446
446
  const T = {
447
- set: _,
448
- update: (R, L) => _(R(h, s), L),
447
+ set: k,
448
+ update: (R, L) => k(R(h, s), L),
449
449
  subscribe: t.subscribe,
450
450
  stiffness: n,
451
451
  damping: o,
@@ -454,7 +454,7 @@ function Zi(s, e = {}) {
454
454
  return T;
455
455
  }
456
456
  function Xi(s, e) {
457
- return Ee(this, null, function* () {
457
+ return Se(this, null, function* () {
458
458
  const t = s.getReader();
459
459
  let n;
460
460
  for (; !(n = yield t.read()).done; )
@@ -541,42 +541,42 @@ function eo(s, e) {
541
541
  return new Promise((p, m) => {
542
542
  const g = Object.assign({}, n);
543
543
  g.accept || (g.accept = yn);
544
- let _;
544
+ let k;
545
545
  function T() {
546
- _.abort(), document.hidden || y();
546
+ k.abort(), document.hidden || b();
547
547
  }
548
548
  c || document.addEventListener("visibilitychange", T);
549
549
  let R = $i, L = 0;
550
550
  function A() {
551
- document.removeEventListener("visibilitychange", T), window.clearTimeout(L), _.abort();
551
+ document.removeEventListener("visibilitychange", T), window.clearTimeout(L), k.abort();
552
552
  }
553
553
  t == null || t.addEventListener("abort", () => {
554
554
  A(), p();
555
555
  });
556
- const w = u != null ? u : window.fetch, k = o != null ? o : to;
557
- function y() {
558
- return Ee(this, null, function* () {
556
+ const w = u != null ? u : window.fetch, _ = o != null ? o : to;
557
+ function b() {
558
+ return Se(this, null, function* () {
559
559
  var v;
560
- _ = new AbortController();
560
+ k = new AbortController();
561
561
  try {
562
- const x = yield w(s, Object.assign(Object.assign({}, h), { headers: g, signal: _.signal }));
563
- yield k(x), yield Xi(x.body, Vi(Qi((M) => {
562
+ const x = yield w(s, Object.assign(Object.assign({}, h), { headers: g, signal: k.signal }));
563
+ yield _(x), yield Xi(x.body, Vi(Qi((M) => {
564
564
  M ? g[cs] = M : delete g[cs];
565
565
  }, (M) => {
566
566
  R = M;
567
567
  }, l))), i == null || i(), A(), p();
568
568
  } catch (x) {
569
- if (!_.signal.aborted)
569
+ if (!k.signal.aborted)
570
570
  try {
571
571
  const M = (v = r == null ? void 0 : r(x)) !== null && v !== void 0 ? v : R;
572
- window.clearTimeout(L), L = window.setTimeout(y, M);
572
+ window.clearTimeout(L), L = window.setTimeout(b, M);
573
573
  } catch (M) {
574
574
  A(), m(M);
575
575
  }
576
576
  }
577
577
  });
578
578
  }
579
- y();
579
+ b();
580
580
  });
581
581
  }
582
582
  function to(s) {
@@ -598,9 +598,9 @@ function Dn() {
598
598
  walkTokens: null
599
599
  };
600
600
  }
601
- let ut = Dn();
601
+ let ct = Dn();
602
602
  function ii(s) {
603
- ut = s;
603
+ ct = s;
604
604
  }
605
605
  const oi = /[&<>"']/, no = new RegExp(oi.source, "g"), li = /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, so = new RegExp(li.source, "g"), io = {
606
606
  "&": "&amp;",
@@ -642,7 +642,7 @@ function fs(s) {
642
642
  }
643
643
  return s;
644
644
  }
645
- const Lt = { exec: () => null };
645
+ const Ct = { exec: () => null };
646
646
  function hs(s, e) {
647
647
  const t = s.replace(/\|/g, (l, i, r) => {
648
648
  let c = !1, u = i;
@@ -734,7 +734,7 @@ class Kt {
734
734
  re(this, "rules");
735
735
  // set by the lexer
736
736
  re(this, "lexer");
737
- this.options = e || ut;
737
+ this.options = e || ct;
738
738
  }
739
739
  space(e) {
740
740
  const t = this.rules.block.newline.exec(e);
@@ -833,26 +833,26 @@ class Kt {
833
833
  `, 1)[0].replace(/^\t+/, (L) => " ".repeat(3 * L.length)), m = e.split(`
834
834
  `, 1)[0], g = 0;
835
835
  this.options.pedantic ? (g = 2, c = p.trimStart()) : (g = t[2].search(/[^ ]/), g = g > 4 ? 1 : g, c = p.slice(g), g += t[1].length);
836
- let _ = !1;
836
+ let k = !1;
837
837
  if (!p && /^ *$/.test(m) && (r += m + `
838
838
  `, e = e.substring(m.length + 1), h = !0), !h) {
839
- const L = new RegExp(`^ {0,${Math.min(3, g - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`), A = new RegExp(`^ {0,${Math.min(3, g - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`), w = new RegExp(`^ {0,${Math.min(3, g - 1)}}(?:\`\`\`|~~~)`), k = new RegExp(`^ {0,${Math.min(3, g - 1)}}#`);
839
+ const L = new RegExp(`^ {0,${Math.min(3, g - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`), A = new RegExp(`^ {0,${Math.min(3, g - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`), w = new RegExp(`^ {0,${Math.min(3, g - 1)}}(?:\`\`\`|~~~)`), _ = new RegExp(`^ {0,${Math.min(3, g - 1)}}#`);
840
840
  for (; e; ) {
841
- const y = e.split(`
841
+ const b = e.split(`
842
842
  `, 1)[0];
843
- if (m = y, this.options.pedantic && (m = m.replace(/^ {1,4}(?=( {4})*[^ ])/g, " ")), w.test(m) || k.test(m) || L.test(m) || A.test(e))
843
+ if (m = b, this.options.pedantic && (m = m.replace(/^ {1,4}(?=( {4})*[^ ])/g, " ")), w.test(m) || _.test(m) || L.test(m) || A.test(e))
844
844
  break;
845
845
  if (m.search(/[^ ]/) >= g || !m.trim())
846
846
  c += `
847
847
  ` + m.slice(g);
848
848
  else {
849
- if (_ || p.search(/[^ ]/) >= 4 || w.test(p) || k.test(p) || A.test(p))
849
+ if (k || p.search(/[^ ]/) >= 4 || w.test(p) || _.test(p) || A.test(p))
850
850
  break;
851
851
  c += `
852
852
  ` + m;
853
853
  }
854
- !_ && !m.trim() && (_ = !0), r += y + `
855
- `, e = e.substring(y.length + 1), p = m.slice(g);
854
+ !k && !m.trim() && (k = !0), r += b + `
855
+ `, e = e.substring(b.length + 1), p = m.slice(g);
856
856
  }
857
857
  }
858
858
  l.loose || (u ? l.loose = !0 : /\n *\n *$/.test(r) && (u = !0));
@@ -1061,12 +1061,12 @@ class Kt {
1061
1061
  tokens: this.lexer.inlineTokens(T)
1062
1062
  };
1063
1063
  }
1064
- const _ = g.slice(2, -2);
1064
+ const k = g.slice(2, -2);
1065
1065
  return {
1066
1066
  type: "strong",
1067
1067
  raw: g,
1068
- text: _,
1069
- tokens: this.lexer.inlineTokens(_)
1068
+ text: k,
1069
+ tokens: this.lexer.inlineTokens(k)
1070
1070
  };
1071
1071
  }
1072
1072
  }
@@ -1161,41 +1161,41 @@ class Kt {
1161
1161
  }
1162
1162
  }
1163
1163
  }
1164
- const uo = /^(?: *(?:\n|$))+/, fo = /^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/, ho = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, Ot = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, po = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, ri = /(?:[*+-]|\d{1,9}[.)])/, ai = oe(/^(?!bull )((?:.|\n(?!\s*?\n|bull ))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g, ri).getRegex(), Pn = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, mo = /^[^\n]+/, Nn = /(?!\s*\])(?:\\.|[^\[\]\\])+/, go = oe(/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/).replace("label", Nn).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), _o = oe(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, ri).getRegex(), ln = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", Fn = /<!--(?!-?>)[\s\S]*?(?:-->|$)/, ko = oe("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))", "i").replace("comment", Fn).replace("tag", ln).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), ci = oe(Pn).replace("hr", Ot).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", ln).getRegex(), wo = oe(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", ci).getRegex(), Hn = {
1164
+ const uo = /^(?: *(?:\n|$))+/, fo = /^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/, ho = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, Ot = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, po = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, ri = /(?:[*+-]|\d{1,9}[.)])/, ai = oe(/^(?!bull )((?:.|\n(?!\s*?\n|bull ))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g, ri).getRegex(), Pn = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, mo = /^[^\n]+/, Nn = /(?!\s*\])(?:\\.|[^\[\]\\])+/, go = oe(/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/).replace("label", Nn).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), ko = oe(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, ri).getRegex(), ln = "address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|section|source|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul", Fn = /<!--(?!-?>)[\s\S]*?(?:-->|$)/, _o = oe("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))", "i").replace("comment", Fn).replace("tag", ln).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), ci = oe(Pn).replace("hr", Ot).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("|table", "").replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", ln).getRegex(), wo = oe(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", ci).getRegex(), Hn = {
1165
1165
  blockquote: wo,
1166
1166
  code: fo,
1167
1167
  def: go,
1168
1168
  fences: ho,
1169
1169
  heading: po,
1170
1170
  hr: Ot,
1171
- html: ko,
1171
+ html: _o,
1172
1172
  lheading: ai,
1173
- list: _o,
1173
+ list: ko,
1174
1174
  newline: uo,
1175
1175
  paragraph: ci,
1176
- table: Lt,
1176
+ table: Ct,
1177
1177
  text: mo
1178
- }, ds = oe("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", Ot).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", " {4}[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", ln).getRegex(), bo = be(ie({}, Hn), {
1178
+ }, ds = oe("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", Ot).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("blockquote", " {0,3}>").replace("code", " {4}[^\\n]").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", ln).getRegex(), bo = ye(ie({}, Hn), {
1179
1179
  table: ds,
1180
1180
  paragraph: oe(Pn).replace("hr", Ot).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", ds).replace("blockquote", " {0,3}>").replace("fences", " {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list", " {0,3}(?:[*+-]|1[.)]) ").replace("html", "</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag", ln).getRegex()
1181
- }), yo = be(ie({}, Hn), {
1181
+ }), yo = ye(ie({}, Hn), {
1182
1182
  html: oe(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment", Fn).replace(/tag/g, "(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),
1183
1183
  def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
1184
1184
  heading: /^(#{1,6})(.*)(?:\n+|$)/,
1185
- fences: Lt,
1185
+ fences: Ct,
1186
1186
  // fences not supported
1187
1187
  lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
1188
1188
  paragraph: oe(Pn).replace("hr", Ot).replace("heading", ` *#{1,6} *[^
1189
1189
  ]`).replace("lheading", ai).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
1190
1190
  }), ui = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, To = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, fi = /^( {2,}|\\)\n(?!\s*$)/, vo = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, Dt = "\\p{P}$+<=>`^|~", Eo = oe(/^((?![*_])[\spunctuation])/, "u").replace(/punctuation/g, Dt).getRegex(), So = /\[[^[\]]*?\]\([^\(\)]*?\)|`[^`]*?`|<[^<>]*?>/g, Ao = oe(/^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/, "u").replace(/punct/g, Dt).getRegex(), xo = oe("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)[punct](\\*+)(?=[\\s]|$)|[^punct\\s](\\*+)(?!\\*)(?=[punct\\s]|$)|(?!\\*)[punct\\s](\\*+)(?=[^punct\\s])|[\\s](\\*+)(?!\\*)(?=[punct])|(?!\\*)[punct](\\*+)(?!\\*)(?=[punct])|[^punct\\s](\\*+)(?=[^punct\\s])", "gu").replace(/punct/g, Dt).getRegex(), Io = oe("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\\s]|$)|[^punct\\s](_+)(?!_)(?=[punct\\s]|$)|(?!_)[punct\\s](_+)(?=[^punct\\s])|[\\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])", "gu").replace(/punct/g, Dt).getRegex(), Ro = oe(/\\([punct])/, "gu").replace(/punct/g, Dt).getRegex(), Co = oe(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme", /[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email", /[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(), Lo = oe(Fn).replace("(?:-->|$)", "-->").getRegex(), Mo = oe("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment", Lo).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), $t = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/, zo = oe(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label", $t).replace("href", /<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), hi = oe(/^!?\[(label)\]\[(ref)\]/).replace("label", $t).replace("ref", Nn).getRegex(), pi = oe(/^!?\[(ref)\](?:\[\])?/).replace("ref", Nn).getRegex(), Oo = oe("reflink|nolink(?!\\()", "g").replace("reflink", hi).replace("nolink", pi).getRegex(), Bn = {
1191
- _backpedal: Lt,
1191
+ _backpedal: Ct,
1192
1192
  // only used for GFM url
1193
1193
  anyPunctuation: Ro,
1194
1194
  autolink: Co,
1195
1195
  blockSkip: So,
1196
1196
  br: fi,
1197
1197
  code: To,
1198
- del: Lt,
1198
+ del: Ct,
1199
1199
  emStrongLDelim: Ao,
1200
1200
  emStrongRDelimAst: xo,
1201
1201
  emStrongRDelimUnd: Io,
@@ -1207,24 +1207,24 @@ const uo = /^(?: *(?:\n|$))+/, fo = /^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/, ho =
1207
1207
  reflinkSearch: Oo,
1208
1208
  tag: Mo,
1209
1209
  text: vo,
1210
- url: Lt
1211
- }, Do = be(ie({}, Bn), {
1210
+ url: Ct
1211
+ }, Do = ye(ie({}, Bn), {
1212
1212
  link: oe(/^!?\[(label)\]\((.*?)\)/).replace("label", $t).getRegex(),
1213
1213
  reflink: oe(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", $t).getRegex()
1214
- }), Tn = be(ie({}, Bn), {
1214
+ }), Tn = ye(ie({}, Bn), {
1215
1215
  escape: oe(ui).replace("])", "~|])").getRegex(),
1216
1216
  url: oe(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/, "i").replace("email", /[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),
1217
1217
  _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
1218
1218
  del: /^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,
1219
1219
  text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/
1220
- }), Po = be(ie({}, Tn), {
1220
+ }), Po = ye(ie({}, Tn), {
1221
1221
  br: oe(fi).replace("{2,}", "*").getRegex(),
1222
1222
  text: oe(Tn.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
1223
1223
  }), Gt = {
1224
1224
  normal: Hn,
1225
1225
  gfm: bo,
1226
1226
  pedantic: yo
1227
- }, Et = {
1227
+ }, vt = {
1228
1228
  normal: Bn,
1229
1229
  gfm: Tn,
1230
1230
  breaks: Po,
@@ -1237,16 +1237,16 @@ class Xe {
1237
1237
  re(this, "state");
1238
1238
  re(this, "tokenizer");
1239
1239
  re(this, "inlineQueue");
1240
- this.tokens = [], this.tokens.links = /* @__PURE__ */ Object.create(null), this.options = e || ut, this.options.tokenizer = this.options.tokenizer || new Kt(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = {
1240
+ this.tokens = [], this.tokens.links = /* @__PURE__ */ Object.create(null), this.options = e || ct, this.options.tokenizer = this.options.tokenizer || new Kt(), this.tokenizer = this.options.tokenizer, this.tokenizer.options = this.options, this.tokenizer.lexer = this, this.inlineQueue = [], this.state = {
1241
1241
  inLink: !1,
1242
1242
  inRawBlock: !1,
1243
1243
  top: !0
1244
1244
  };
1245
1245
  const t = {
1246
1246
  block: Gt.normal,
1247
- inline: Et.normal
1247
+ inline: vt.normal
1248
1248
  };
1249
- this.options.pedantic ? (t.block = Gt.pedantic, t.inline = Et.pedantic) : this.options.gfm && (t.block = Gt.gfm, this.options.breaks ? t.inline = Et.breaks : t.inline = Et.gfm), this.tokenizer.rules = t;
1249
+ this.options.pedantic ? (t.block = Gt.pedantic, t.inline = vt.pedantic) : this.options.gfm && (t.block = Gt.gfm, this.options.breaks ? t.inline = vt.breaks : t.inline = vt.gfm), this.tokenizer.rules = t;
1250
1250
  }
1251
1251
  /**
1252
1252
  * Expose Rules
@@ -1254,7 +1254,7 @@ class Xe {
1254
1254
  static get rules() {
1255
1255
  return {
1256
1256
  block: Gt,
1257
- inline: Et
1257
+ inline: vt
1258
1258
  };
1259
1259
  }
1260
1260
  /**
@@ -1456,7 +1456,7 @@ class Xe {
1456
1456
  class en {
1457
1457
  constructor(e) {
1458
1458
  re(this, "options");
1459
- this.options = e || ut;
1459
+ this.options = e || ct;
1460
1460
  }
1461
1461
  code(e, t, n) {
1462
1462
  var l;
@@ -1589,7 +1589,7 @@ class Ve {
1589
1589
  re(this, "options");
1590
1590
  re(this, "renderer");
1591
1591
  re(this, "textRenderer");
1592
- this.options = e || ut, this.options.renderer = this.options.renderer || new en(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.textRenderer = new Un();
1592
+ this.options = e || ct, this.options.renderer = this.options.renderer || new en(), this.renderer = this.options.renderer, this.renderer.options = this.options, this.textRenderer = new Un();
1593
1593
  }
1594
1594
  /**
1595
1595
  * Static Parse Method
@@ -1660,7 +1660,7 @@ class Ve {
1660
1660
  const i = l, r = i.ordered, c = i.start, u = i.loose;
1661
1661
  let h = "";
1662
1662
  for (let p = 0; p < i.items.length; p++) {
1663
- const m = i.items[p], g = m.checked, _ = m.task;
1663
+ const m = i.items[p], g = m.checked, k = m.task;
1664
1664
  let T = "";
1665
1665
  if (m.task) {
1666
1666
  const R = this.renderer.checkbox(!!g);
@@ -1669,7 +1669,7 @@ class Ve {
1669
1669
  text: R + " "
1670
1670
  }) : T += R + " ";
1671
1671
  }
1672
- T += this.parse(m.tokens, u), h += this.renderer.listitem(T, _, !!g);
1672
+ T += this.parse(m.tokens, u), h += this.renderer.listitem(T, k, !!g);
1673
1673
  }
1674
1674
  n += this.renderer.list(h, r, c);
1675
1675
  continue;
@@ -1778,10 +1778,10 @@ class Ve {
1778
1778
  return n;
1779
1779
  }
1780
1780
  }
1781
- class Mt {
1781
+ class Lt {
1782
1782
  constructor(e) {
1783
1783
  re(this, "options");
1784
- this.options = e || ut;
1784
+ this.options = e || ct;
1785
1785
  }
1786
1786
  /**
1787
1787
  * Process markdown before marked
@@ -1802,25 +1802,25 @@ class Mt {
1802
1802
  return e;
1803
1803
  }
1804
1804
  }
1805
- re(Mt, "passThroughHooks", /* @__PURE__ */ new Set([
1805
+ re(Lt, "passThroughHooks", /* @__PURE__ */ new Set([
1806
1806
  "preprocess",
1807
1807
  "postprocess",
1808
1808
  "processAllTokens"
1809
1809
  ]));
1810
- var ct, vn, di;
1810
+ var at, vn, di;
1811
1811
  class No {
1812
1812
  constructor(...e) {
1813
- ns(this, ct);
1813
+ ns(this, at);
1814
1814
  re(this, "defaults", Dn());
1815
1815
  re(this, "options", this.setOptions);
1816
- re(this, "parse", Wt(this, ct, vn).call(this, Xe.lex, Ve.parse));
1817
- re(this, "parseInline", Wt(this, ct, vn).call(this, Xe.lexInline, Ve.parseInline));
1816
+ re(this, "parse", Wt(this, at, vn).call(this, Xe.lex, Ve.parse));
1817
+ re(this, "parseInline", Wt(this, at, vn).call(this, Xe.lexInline, Ve.parseInline));
1818
1818
  re(this, "Parser", Ve);
1819
1819
  re(this, "Renderer", en);
1820
1820
  re(this, "TextRenderer", Un);
1821
1821
  re(this, "Lexer", Xe);
1822
1822
  re(this, "Tokenizer", Kt);
1823
- re(this, "Hooks", Mt);
1823
+ re(this, "Hooks", Lt);
1824
1824
  this.use(...e);
1825
1825
  }
1826
1826
  /**
@@ -1907,14 +1907,14 @@ class No {
1907
1907
  o.tokenizer = l;
1908
1908
  }
1909
1909
  if (n.hooks) {
1910
- const l = this.defaults.hooks || new Mt();
1910
+ const l = this.defaults.hooks || new Lt();
1911
1911
  for (const i in n.hooks) {
1912
1912
  if (!(i in l))
1913
1913
  throw new Error(`hook '${i}' does not exist`);
1914
1914
  if (i === "options")
1915
1915
  continue;
1916
1916
  const r = i, c = n.hooks[r], u = l[r];
1917
- Mt.passThroughHooks.has(i) ? l[r] = (h) => {
1917
+ Lt.passThroughHooks.has(i) ? l[r] = (h) => {
1918
1918
  if (this.defaults.async)
1919
1919
  return Promise.resolve(c.call(l, h)).then((m) => u.call(l, m));
1920
1920
  const p = c.call(l, h);
@@ -1946,11 +1946,11 @@ class No {
1946
1946
  return Ve.parse(e, t != null ? t : this.defaults);
1947
1947
  }
1948
1948
  }
1949
- ct = new WeakSet(), vn = function(e, t) {
1949
+ at = new WeakSet(), vn = function(e, t) {
1950
1950
  return (n, o) => {
1951
1951
  const l = ie({}, o), i = ie(ie({}, this.defaults), l);
1952
1952
  this.defaults.async === !0 && l.async === !1 && (i.silent || console.warn("marked(): The async option was set to true by an extension. The async: false option sent to parse will be ignored."), i.async = !0);
1953
- const r = Wt(this, ct, di).call(this, !!i.silent, !!i.async);
1953
+ const r = Wt(this, at, di).call(this, !!i.silent, !!i.async);
1954
1954
  if (typeof n == "undefined" || n === null)
1955
1955
  return r(new Error("marked(): input parameter is undefined or null"));
1956
1956
  if (typeof n != "string")
@@ -1979,22 +1979,22 @@ Please report this to https://github.com/markedjs/marked.`, e) {
1979
1979
  throw n;
1980
1980
  };
1981
1981
  };
1982
- const at = new No();
1982
+ const rt = new No();
1983
1983
  function te(s, e) {
1984
- return at.parse(s, e);
1984
+ return rt.parse(s, e);
1985
1985
  }
1986
1986
  te.options = te.setOptions = function(s) {
1987
- return at.setOptions(s), te.defaults = at.defaults, ii(te.defaults), te;
1987
+ return rt.setOptions(s), te.defaults = rt.defaults, ii(te.defaults), te;
1988
1988
  };
1989
1989
  te.getDefaults = Dn;
1990
- te.defaults = ut;
1990
+ te.defaults = ct;
1991
1991
  te.use = function(...s) {
1992
- return at.use(...s), te.defaults = at.defaults, ii(te.defaults), te;
1992
+ return rt.use(...s), te.defaults = rt.defaults, ii(te.defaults), te;
1993
1993
  };
1994
1994
  te.walkTokens = function(s, e) {
1995
- return at.walkTokens(s, e);
1995
+ return rt.walkTokens(s, e);
1996
1996
  };
1997
- te.parseInline = at.parseInline;
1997
+ te.parseInline = rt.parseInline;
1998
1998
  te.Parser = Ve;
1999
1999
  te.parser = Ve.parse;
2000
2000
  te.Renderer = en;
@@ -2002,7 +2002,7 @@ te.TextRenderer = Un;
2002
2002
  te.Lexer = Xe;
2003
2003
  te.lexer = Xe.lex;
2004
2004
  te.Tokenizer = Kt;
2005
- te.Hooks = Mt;
2005
+ te.Hooks = Lt;
2006
2006
  te.parse = te;
2007
2007
  te.options;
2008
2008
  te.setOptions;
@@ -2039,7 +2039,7 @@ En || (En = function(e, t, n) {
2039
2039
  Sn || (Sn = function(e, t) {
2040
2040
  return new e(...t);
2041
2041
  });
2042
- const Yt = Fe(Array.prototype.forEach), gs = Fe(Array.prototype.pop), St = Fe(Array.prototype.push), Qt = Fe(String.prototype.toLowerCase), hn = Fe(String.prototype.toString), _s = Fe(String.prototype.match), At = Fe(String.prototype.replace), Uo = Fe(String.prototype.indexOf), jo = Fe(String.prototype.trim), Ge = Fe(Object.prototype.hasOwnProperty), Re = Fe(RegExp.prototype.test), xt = Wo(TypeError);
2042
+ const Yt = Fe(Array.prototype.forEach), gs = Fe(Array.prototype.pop), Et = Fe(Array.prototype.push), Qt = Fe(String.prototype.toLowerCase), hn = Fe(String.prototype.toString), ks = Fe(String.prototype.match), St = Fe(String.prototype.replace), Uo = Fe(String.prototype.indexOf), jo = Fe(String.prototype.trim), Ge = Fe(Object.prototype.hasOwnProperty), Re = Fe(RegExp.prototype.test), At = Wo(TypeError);
2043
2043
  function Fe(s) {
2044
2044
  return function(e) {
2045
2045
  for (var t = arguments.length, n = new Array(t > 1 ? t - 1 : 0), o = 1; o < t; o++)
@@ -2054,7 +2054,7 @@ function Wo(s) {
2054
2054
  return Sn(s, t);
2055
2055
  };
2056
2056
  }
2057
- function Q(s, e) {
2057
+ function V(s, e) {
2058
2058
  let t = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : Qt;
2059
2059
  ms && ms(s, null);
2060
2060
  let n = e.length;
@@ -2073,13 +2073,13 @@ function qo(s) {
2073
2073
  Ge(s, e) || (s[e] = null);
2074
2074
  return s;
2075
2075
  }
2076
- function lt(s) {
2076
+ function ot(s) {
2077
2077
  const e = gi(null);
2078
2078
  for (const [t, n] of mi(s))
2079
- Ge(s, t) && (Array.isArray(n) ? e[t] = qo(n) : n && typeof n == "object" && n.constructor === Object ? e[t] = lt(n) : e[t] = n);
2079
+ Ge(s, t) && (Array.isArray(n) ? e[t] = qo(n) : n && typeof n == "object" && n.constructor === Object ? e[t] = ot(n) : e[t] = n);
2080
2080
  return e;
2081
2081
  }
2082
- function It(s, e) {
2082
+ function xt(s, e) {
2083
2083
  for (; s !== null; ) {
2084
2084
  const n = Bo(s, e);
2085
2085
  if (n) {
@@ -2095,27 +2095,27 @@ function It(s, e) {
2095
2095
  }
2096
2096
  return t;
2097
2097
  }
2098
- const ks = Ce(["a", "abbr", "acronym", "address", "area", "article", "aside", "audio", "b", "bdi", "bdo", "big", "blink", "blockquote", "body", "br", "button", "canvas", "caption", "center", "cite", "code", "col", "colgroup", "content", "data", "datalist", "dd", "decorator", "del", "details", "dfn", "dialog", "dir", "div", "dl", "dt", "element", "em", "fieldset", "figcaption", "figure", "font", "footer", "form", "h1", "h2", "h3", "h4", "h5", "h6", "head", "header", "hgroup", "hr", "html", "i", "img", "input", "ins", "kbd", "label", "legend", "li", "main", "map", "mark", "marquee", "menu", "menuitem", "meter", "nav", "nobr", "ol", "optgroup", "option", "output", "p", "picture", "pre", "progress", "q", "rp", "rt", "ruby", "s", "samp", "section", "select", "shadow", "small", "source", "spacer", "span", "strike", "strong", "style", "sub", "summary", "sup", "table", "tbody", "td", "template", "textarea", "tfoot", "th", "thead", "time", "tr", "track", "tt", "u", "ul", "var", "video", "wbr"]), pn = Ce(["svg", "a", "altglyph", "altglyphdef", "altglyphitem", "animatecolor", "animatemotion", "animatetransform", "circle", "clippath", "defs", "desc", "ellipse", "filter", "font", "g", "glyph", "glyphref", "hkern", "image", "line", "lineargradient", "marker", "mask", "metadata", "mpath", "path", "pattern", "polygon", "polyline", "radialgradient", "rect", "stop", "style", "switch", "symbol", "text", "textpath", "title", "tref", "tspan", "view", "vkern"]), dn = Ce(["feBlend", "feColorMatrix", "feComponentTransfer", "feComposite", "feConvolveMatrix", "feDiffuseLighting", "feDisplacementMap", "feDistantLight", "feDropShadow", "feFlood", "feFuncA", "feFuncB", "feFuncG", "feFuncR", "feGaussianBlur", "feImage", "feMerge", "feMergeNode", "feMorphology", "feOffset", "fePointLight", "feSpecularLighting", "feSpotLight", "feTile", "feTurbulence"]), Go = Ce(["animate", "color-profile", "cursor", "discard", "font-face", "font-face-format", "font-face-name", "font-face-src", "font-face-uri", "foreignobject", "hatch", "hatchpath", "mesh", "meshgradient", "meshpatch", "meshrow", "missing-glyph", "script", "set", "solidcolor", "unknown", "use"]), mn = Ce(["math", "menclose", "merror", "mfenced", "mfrac", "mglyph", "mi", "mlabeledtr", "mmultiscripts", "mn", "mo", "mover", "mpadded", "mphantom", "mroot", "mrow", "ms", "mspace", "msqrt", "mstyle", "msub", "msup", "msubsup", "mtable", "mtd", "mtext", "mtr", "munder", "munderover", "mprescripts"]), Yo = Ce(["maction", "maligngroup", "malignmark", "mlongdiv", "mscarries", "mscarry", "msgroup", "mstack", "msline", "msrow", "semantics", "annotation", "annotation-xml", "mprescripts", "none"]), ws = Ce(["#text"]), bs = Ce(["accept", "action", "align", "alt", "autocapitalize", "autocomplete", "autopictureinpicture", "autoplay", "background", "bgcolor", "border", "capture", "cellpadding", "cellspacing", "checked", "cite", "class", "clear", "color", "cols", "colspan", "controls", "controlslist", "coords", "crossorigin", "datetime", "decoding", "default", "dir", "disabled", "disablepictureinpicture", "disableremoteplayback", "download", "draggable", "enctype", "enterkeyhint", "face", "for", "headers", "height", "hidden", "high", "href", "hreflang", "id", "inputmode", "integrity", "ismap", "kind", "label", "lang", "list", "loading", "loop", "low", "max", "maxlength", "media", "method", "min", "minlength", "multiple", "muted", "name", "nonce", "noshade", "novalidate", "nowrap", "open", "optimum", "pattern", "placeholder", "playsinline", "popover", "popovertarget", "popovertargetaction", "poster", "preload", "pubdate", "radiogroup", "readonly", "rel", "required", "rev", "reversed", "role", "rows", "rowspan", "spellcheck", "scope", "selected", "shape", "size", "sizes", "span", "srclang", "start", "src", "srcset", "step", "style", "summary", "tabindex", "title", "translate", "type", "usemap", "valign", "value", "width", "wrap", "xmlns", "slot"]), gn = Ce(["accent-height", "accumulate", "additive", "alignment-baseline", "amplitude", "ascent", "attributename", "attributetype", "azimuth", "basefrequency", "baseline-shift", "begin", "bias", "by", "class", "clip", "clippathunits", "clip-path", "clip-rule", "color", "color-interpolation", "color-interpolation-filters", "color-profile", "color-rendering", "cx", "cy", "d", "dx", "dy", "diffuseconstant", "direction", "display", "divisor", "dur", "edgemode", "elevation", "end", "exponent", "fill", "fill-opacity", "fill-rule", "filter", "filterunits", "flood-color", "flood-opacity", "font-family", "font-size", "font-size-adjust", "font-stretch", "font-style", "font-variant", "font-weight", "fx", "fy", "g1", "g2", "glyph-name", "glyphref", "gradientunits", "gradienttransform", "height", "href", "id", "image-rendering", "in", "in2", "intercept", "k", "k1", "k2", "k3", "k4", "kerning", "keypoints", "keysplines", "keytimes", "lang", "lengthadjust", "letter-spacing", "kernelmatrix", "kernelunitlength", "lighting-color", "local", "marker-end", "marker-mid", "marker-start", "markerheight", "markerunits", "markerwidth", "maskcontentunits", "maskunits", "max", "mask", "media", "method", "mode", "min", "name", "numoctaves", "offset", "operator", "opacity", "order", "orient", "orientation", "origin", "overflow", "paint-order", "path", "pathlength", "patterncontentunits", "patterntransform", "patternunits", "points", "preservealpha", "preserveaspectratio", "primitiveunits", "r", "rx", "ry", "radius", "refx", "refy", "repeatcount", "repeatdur", "restart", "result", "rotate", "scale", "seed", "shape-rendering", "slope", "specularconstant", "specularexponent", "spreadmethod", "startoffset", "stddeviation", "stitchtiles", "stop-color", "stop-opacity", "stroke-dasharray", "stroke-dashoffset", "stroke-linecap", "stroke-linejoin", "stroke-miterlimit", "stroke-opacity", "stroke", "stroke-width", "style", "surfacescale", "systemlanguage", "tabindex", "tablevalues", "targetx", "targety", "transform", "transform-origin", "text-anchor", "text-decoration", "text-rendering", "textlength", "type", "u1", "u2", "unicode", "values", "viewbox", "visibility", "version", "vert-adv-y", "vert-origin-x", "vert-origin-y", "width", "word-spacing", "wrap", "writing-mode", "xchannelselector", "ychannelselector", "x", "x1", "x2", "xmlns", "y", "y1", "y2", "z", "zoomandpan"]), ys = Ce(["accent", "accentunder", "align", "bevelled", "close", "columnsalign", "columnlines", "columnspan", "denomalign", "depth", "dir", "display", "displaystyle", "encoding", "fence", "frame", "height", "href", "id", "largeop", "length", "linethickness", "lspace", "lquote", "mathbackground", "mathcolor", "mathsize", "mathvariant", "maxsize", "minsize", "movablelimits", "notation", "numalign", "open", "rowalign", "rowlines", "rowspacing", "rowspan", "rspace", "rquote", "scriptlevel", "scriptminsize", "scriptsizemultiplier", "selection", "separator", "separators", "stretchy", "subscriptshift", "supscriptshift", "symmetric", "voffset", "width", "xmlns"]), Zt = Ce(["xlink:href", "xml:id", "xlink:title", "xml:space", "xmlns:xlink"]), Zo = We(/\{\{[\w\W]*|[\w\W]*\}\}/gm), Xo = We(/<%[\w\W]*|[\w\W]*%>/gm), Vo = We(/\$\{[\w\W]*}/gm), Qo = We(/^data-[\-\w.\u00B7-\uFFFF]+$/), Jo = We(/^aria-[\-\w]+$/), _i = We(
2098
+ const _s = Ce(["a", "abbr", "acronym", "address", "area", "article", "aside", "audio", "b", "bdi", "bdo", "big", "blink", "blockquote", "body", "br", "button", "canvas", "caption", "center", "cite", "code", "col", "colgroup", "content", "data", "datalist", "dd", "decorator", "del", "details", "dfn", "dialog", "dir", "div", "dl", "dt", "element", "em", "fieldset", "figcaption", "figure", "font", "footer", "form", "h1", "h2", "h3", "h4", "h5", "h6", "head", "header", "hgroup", "hr", "html", "i", "img", "input", "ins", "kbd", "label", "legend", "li", "main", "map", "mark", "marquee", "menu", "menuitem", "meter", "nav", "nobr", "ol", "optgroup", "option", "output", "p", "picture", "pre", "progress", "q", "rp", "rt", "ruby", "s", "samp", "section", "select", "shadow", "small", "source", "spacer", "span", "strike", "strong", "style", "sub", "summary", "sup", "table", "tbody", "td", "template", "textarea", "tfoot", "th", "thead", "time", "tr", "track", "tt", "u", "ul", "var", "video", "wbr"]), pn = Ce(["svg", "a", "altglyph", "altglyphdef", "altglyphitem", "animatecolor", "animatemotion", "animatetransform", "circle", "clippath", "defs", "desc", "ellipse", "filter", "font", "g", "glyph", "glyphref", "hkern", "image", "line", "lineargradient", "marker", "mask", "metadata", "mpath", "path", "pattern", "polygon", "polyline", "radialgradient", "rect", "stop", "style", "switch", "symbol", "text", "textpath", "title", "tref", "tspan", "view", "vkern"]), dn = Ce(["feBlend", "feColorMatrix", "feComponentTransfer", "feComposite", "feConvolveMatrix", "feDiffuseLighting", "feDisplacementMap", "feDistantLight", "feDropShadow", "feFlood", "feFuncA", "feFuncB", "feFuncG", "feFuncR", "feGaussianBlur", "feImage", "feMerge", "feMergeNode", "feMorphology", "feOffset", "fePointLight", "feSpecularLighting", "feSpotLight", "feTile", "feTurbulence"]), Go = Ce(["animate", "color-profile", "cursor", "discard", "font-face", "font-face-format", "font-face-name", "font-face-src", "font-face-uri", "foreignobject", "hatch", "hatchpath", "mesh", "meshgradient", "meshpatch", "meshrow", "missing-glyph", "script", "set", "solidcolor", "unknown", "use"]), mn = Ce(["math", "menclose", "merror", "mfenced", "mfrac", "mglyph", "mi", "mlabeledtr", "mmultiscripts", "mn", "mo", "mover", "mpadded", "mphantom", "mroot", "mrow", "ms", "mspace", "msqrt", "mstyle", "msub", "msup", "msubsup", "mtable", "mtd", "mtext", "mtr", "munder", "munderover", "mprescripts"]), Yo = Ce(["maction", "maligngroup", "malignmark", "mlongdiv", "mscarries", "mscarry", "msgroup", "mstack", "msline", "msrow", "semantics", "annotation", "annotation-xml", "mprescripts", "none"]), ws = Ce(["#text"]), bs = Ce(["accept", "action", "align", "alt", "autocapitalize", "autocomplete", "autopictureinpicture", "autoplay", "background", "bgcolor", "border", "capture", "cellpadding", "cellspacing", "checked", "cite", "class", "clear", "color", "cols", "colspan", "controls", "controlslist", "coords", "crossorigin", "datetime", "decoding", "default", "dir", "disabled", "disablepictureinpicture", "disableremoteplayback", "download", "draggable", "enctype", "enterkeyhint", "face", "for", "headers", "height", "hidden", "high", "href", "hreflang", "id", "inputmode", "integrity", "ismap", "kind", "label", "lang", "list", "loading", "loop", "low", "max", "maxlength", "media", "method", "min", "minlength", "multiple", "muted", "name", "nonce", "noshade", "novalidate", "nowrap", "open", "optimum", "pattern", "placeholder", "playsinline", "popover", "popovertarget", "popovertargetaction", "poster", "preload", "pubdate", "radiogroup", "readonly", "rel", "required", "rev", "reversed", "role", "rows", "rowspan", "spellcheck", "scope", "selected", "shape", "size", "sizes", "span", "srclang", "start", "src", "srcset", "step", "style", "summary", "tabindex", "title", "translate", "type", "usemap", "valign", "value", "width", "wrap", "xmlns", "slot"]), gn = Ce(["accent-height", "accumulate", "additive", "alignment-baseline", "amplitude", "ascent", "attributename", "attributetype", "azimuth", "basefrequency", "baseline-shift", "begin", "bias", "by", "class", "clip", "clippathunits", "clip-path", "clip-rule", "color", "color-interpolation", "color-interpolation-filters", "color-profile", "color-rendering", "cx", "cy", "d", "dx", "dy", "diffuseconstant", "direction", "display", "divisor", "dur", "edgemode", "elevation", "end", "exponent", "fill", "fill-opacity", "fill-rule", "filter", "filterunits", "flood-color", "flood-opacity", "font-family", "font-size", "font-size-adjust", "font-stretch", "font-style", "font-variant", "font-weight", "fx", "fy", "g1", "g2", "glyph-name", "glyphref", "gradientunits", "gradienttransform", "height", "href", "id", "image-rendering", "in", "in2", "intercept", "k", "k1", "k2", "k3", "k4", "kerning", "keypoints", "keysplines", "keytimes", "lang", "lengthadjust", "letter-spacing", "kernelmatrix", "kernelunitlength", "lighting-color", "local", "marker-end", "marker-mid", "marker-start", "markerheight", "markerunits", "markerwidth", "maskcontentunits", "maskunits", "max", "mask", "media", "method", "mode", "min", "name", "numoctaves", "offset", "operator", "opacity", "order", "orient", "orientation", "origin", "overflow", "paint-order", "path", "pathlength", "patterncontentunits", "patterntransform", "patternunits", "points", "preservealpha", "preserveaspectratio", "primitiveunits", "r", "rx", "ry", "radius", "refx", "refy", "repeatcount", "repeatdur", "restart", "result", "rotate", "scale", "seed", "shape-rendering", "slope", "specularconstant", "specularexponent", "spreadmethod", "startoffset", "stddeviation", "stitchtiles", "stop-color", "stop-opacity", "stroke-dasharray", "stroke-dashoffset", "stroke-linecap", "stroke-linejoin", "stroke-miterlimit", "stroke-opacity", "stroke", "stroke-width", "style", "surfacescale", "systemlanguage", "tabindex", "tablevalues", "targetx", "targety", "transform", "transform-origin", "text-anchor", "text-decoration", "text-rendering", "textlength", "type", "u1", "u2", "unicode", "values", "viewbox", "visibility", "version", "vert-adv-y", "vert-origin-x", "vert-origin-y", "width", "word-spacing", "wrap", "writing-mode", "xchannelselector", "ychannelselector", "x", "x1", "x2", "xmlns", "y", "y1", "y2", "z", "zoomandpan"]), ys = Ce(["accent", "accentunder", "align", "bevelled", "close", "columnsalign", "columnlines", "columnspan", "denomalign", "depth", "dir", "display", "displaystyle", "encoding", "fence", "frame", "height", "href", "id", "largeop", "length", "linethickness", "lspace", "lquote", "mathbackground", "mathcolor", "mathsize", "mathvariant", "maxsize", "minsize", "movablelimits", "notation", "numalign", "open", "rowalign", "rowlines", "rowspacing", "rowspan", "rspace", "rquote", "scriptlevel", "scriptminsize", "scriptsizemultiplier", "selection", "separator", "separators", "stretchy", "subscriptshift", "supscriptshift", "symmetric", "voffset", "width", "xmlns"]), Zt = Ce(["xlink:href", "xml:id", "xlink:title", "xml:space", "xmlns:xlink"]), Zo = We(/\{\{[\w\W]*|[\w\W]*\}\}/gm), Xo = We(/<%[\w\W]*|[\w\W]*%>/gm), Vo = We(/\$\{[\w\W]*}/gm), Qo = We(/^data-[\-\w.\u00B7-\uFFFF]+$/), Jo = We(/^aria-[\-\w]+$/), ki = We(
2099
2099
  /^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i
2100
2100
  // eslint-disable-line no-useless-escape
2101
2101
  ), Ko = We(/^(?:\w+script|data):/i), $o = We(
2102
2102
  /[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g
2103
2103
  // eslint-disable-line no-control-regex
2104
- ), ki = We(/^html$/i), el = We(/^[a-z][.\w]*(-[.\w]+)+$/i);
2104
+ ), _i = We(/^html$/i), el = We(/^[a-z][.\w]*(-[.\w]+)+$/i);
2105
2105
  var Ts = /* @__PURE__ */ Object.freeze({
2106
2106
  __proto__: null,
2107
2107
  ARIA_ATTR: Jo,
2108
2108
  ATTR_WHITESPACE: $o,
2109
2109
  CUSTOM_ELEMENT: el,
2110
2110
  DATA_ATTR: Qo,
2111
- DOCTYPE_NAME: ki,
2111
+ DOCTYPE_NAME: _i,
2112
2112
  ERB_EXPR: Xo,
2113
- IS_ALLOWED_URI: _i,
2113
+ IS_ALLOWED_URI: ki,
2114
2114
  IS_SCRIPT_OR_DATA: Ko,
2115
2115
  MUSTACHE_EXPR: Zo,
2116
2116
  TMPLIT_EXPR: Vo
2117
2117
  });
2118
- const Rt = {
2118
+ const It = {
2119
2119
  element: 1,
2120
2120
  attribute: 2,
2121
2121
  text: 3,
@@ -2167,8 +2167,8 @@ const Rt = {
2167
2167
  };
2168
2168
  function wi() {
2169
2169
  let s = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : tl();
2170
- const e = (H) => wi(H);
2171
- if (e.version = "3.2.3", e.removed = [], !s || !s.document || s.document.nodeType !== Rt.document)
2170
+ const e = (F) => wi(F);
2171
+ if (e.version = "3.2.3", e.removed = [], !s || !s.document || s.document.nodeType !== It.document)
2172
2172
  return e.isSupported = !1, e;
2173
2173
  let {
2174
2174
  document: t
@@ -2183,12 +2183,12 @@ function wi() {
2183
2183
  HTMLFormElement: p,
2184
2184
  DOMParser: m,
2185
2185
  trustedTypes: g
2186
- } = s, _ = c.prototype, T = It(_, "cloneNode"), R = It(_, "remove"), L = It(_, "nextSibling"), A = It(_, "childNodes"), w = It(_, "parentNode");
2186
+ } = s, k = c.prototype, T = xt(k, "cloneNode"), R = xt(k, "remove"), L = xt(k, "nextSibling"), A = xt(k, "childNodes"), w = xt(k, "parentNode");
2187
2187
  if (typeof i == "function") {
2188
- const H = t.createElement("template");
2189
- H.content && H.content.ownerDocument && (t = H.content.ownerDocument);
2188
+ const F = t.createElement("template");
2189
+ F.content && F.content.ownerDocument && (t = F.content.ownerDocument);
2190
2190
  }
2191
- let k, y = "";
2191
+ let _, b = "";
2192
2192
  const {
2193
2193
  implementation: v,
2194
2194
  createNodeIterator: x,
@@ -2203,18 +2203,18 @@ function wi() {
2203
2203
  MUSTACHE_EXPR: I,
2204
2204
  ERB_EXPR: C,
2205
2205
  TMPLIT_EXPR: U,
2206
- DATA_ATTR: V,
2206
+ DATA_ATTR: X,
2207
2207
  ARIA_ATTR: ne,
2208
2208
  IS_SCRIPT_OR_DATA: he,
2209
2209
  ATTR_WHITESPACE: He,
2210
- CUSTOM_ELEMENT: ue
2210
+ CUSTOM_ELEMENT: fe
2211
2211
  } = Ts;
2212
2212
  let {
2213
2213
  IS_ALLOWED_URI: Be
2214
2214
  } = Ts, ee = null;
2215
- const qe = Q({}, [...ks, ...pn, ...dn, ...mn, ...ws]);
2215
+ const qe = V({}, [..._s, ...pn, ...dn, ...mn, ...ws]);
2216
2216
  let se = null;
2217
- const Ae = Q({}, [...bs, ...gn, ...ys, ...Zt]);
2217
+ const xe = V({}, [...bs, ...gn, ...ys, ...Zt]);
2218
2218
  let K = Object.seal(gi(null, {
2219
2219
  tagNameCheck: {
2220
2220
  writable: !0,
@@ -2234,47 +2234,47 @@ function wi() {
2234
2234
  enumerable: !0,
2235
2235
  value: !1
2236
2236
  }
2237
- })), Le = null, Te = null, Qe = !0, P = !0, le = !1, D = !0, q = !1, me = !0, ge = !1, Me = !1, De = !1, et = !1, ft = !1, ht = !1, Pt = !0, Nt = !1;
2237
+ })), Le = null, ve = null, Qe = !0, P = !0, le = !1, D = !0, q = !1, me = !0, ge = !1, Me = !1, De = !1, $e = !1, ut = !1, ft = !1, Pt = !0, Nt = !1;
2238
2238
  const rn = "user-content-";
2239
- let bt = !0, ot = !1, tt = {}, nt = null;
2240
- const Ft = Q({}, ["annotation-xml", "audio", "colgroup", "desc", "foreignobject", "head", "iframe", "math", "mi", "mn", "mo", "ms", "mtext", "noembed", "noframes", "noscript", "plaintext", "script", "style", "svg", "template", "thead", "title", "video", "xmp"]);
2239
+ let wt = !0, it = !1, et = {}, tt = null;
2240
+ const Ft = V({}, ["annotation-xml", "audio", "colgroup", "desc", "foreignobject", "head", "iframe", "math", "mi", "mn", "mo", "ms", "mtext", "noembed", "noframes", "noscript", "plaintext", "script", "style", "svg", "template", "thead", "title", "video", "xmp"]);
2241
2241
  let Ht = null;
2242
- const Bt = Q({}, ["audio", "video", "img", "source", "image", "track"]);
2242
+ const Bt = V({}, ["audio", "video", "img", "source", "image", "track"]);
2243
+ let bt = null;
2244
+ const y = V({}, ["alt", "class", "for", "id", "label", "name", "pattern", "placeholder", "role", "summary", "title", "value", "style", "xmlns"]), H = "http://www.w3.org/1998/Math/MathML", J = "http://www.w3.org/2000/svg", ae = "http://www.w3.org/1999/xhtml";
2245
+ let ce = ae, _e = !1, we = null;
2246
+ const ht = V({}, [H, J, ae], hn);
2247
+ let Ue = V({}, ["mi", "mo", "mn", "ms", "mtext"]), Ut = V({}, ["annotation-xml"]);
2248
+ const yi = V({}, ["title", "style", "font", "a", "script"]);
2243
2249
  let yt = null;
2244
- const Ut = Q({}, ["alt", "class", "for", "id", "label", "name", "pattern", "placeholder", "role", "summary", "title", "value", "style", "xmlns"]), b = "http://www.w3.org/1998/Math/MathML", N = "http://www.w3.org/2000/svg", X = "http://www.w3.org/1999/xhtml";
2245
- let ce = X, fe = !1, ke = null;
2246
- const xe = Q({}, [b, N, X], hn);
2247
- let Je = Q({}, ["mi", "mo", "mn", "ms", "mtext"]), Ue = Q({}, ["annotation-xml"]);
2248
- const yi = Q({}, ["title", "style", "font", "a", "script"]);
2249
- let Tt = null;
2250
2250
  const Ti = ["application/xhtml+xml", "text/html"], vi = "text/html";
2251
- let _e = null, pt = null;
2251
+ let ke = null, pt = null;
2252
2252
  const Ei = t.createElement("form"), jn = function(f) {
2253
2253
  return f instanceof RegExp || f instanceof Function;
2254
2254
  }, an = function() {
2255
2255
  let f = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
2256
2256
  if (!(pt && pt === f)) {
2257
- if ((!f || typeof f != "object") && (f = {}), f = lt(f), Tt = // eslint-disable-next-line unicorn/prefer-includes
2258
- Ti.indexOf(f.PARSER_MEDIA_TYPE) === -1 ? vi : f.PARSER_MEDIA_TYPE, _e = Tt === "application/xhtml+xml" ? hn : Qt, ee = Ge(f, "ALLOWED_TAGS") ? Q({}, f.ALLOWED_TAGS, _e) : qe, se = Ge(f, "ALLOWED_ATTR") ? Q({}, f.ALLOWED_ATTR, _e) : Ae, ke = Ge(f, "ALLOWED_NAMESPACES") ? Q({}, f.ALLOWED_NAMESPACES, hn) : xe, yt = Ge(f, "ADD_URI_SAFE_ATTR") ? Q(lt(Ut), f.ADD_URI_SAFE_ATTR, _e) : Ut, Ht = Ge(f, "ADD_DATA_URI_TAGS") ? Q(lt(Bt), f.ADD_DATA_URI_TAGS, _e) : Bt, nt = Ge(f, "FORBID_CONTENTS") ? Q({}, f.FORBID_CONTENTS, _e) : Ft, Le = Ge(f, "FORBID_TAGS") ? Q({}, f.FORBID_TAGS, _e) : {}, Te = Ge(f, "FORBID_ATTR") ? Q({}, f.FORBID_ATTR, _e) : {}, tt = Ge(f, "USE_PROFILES") ? f.USE_PROFILES : !1, Qe = f.ALLOW_ARIA_ATTR !== !1, P = f.ALLOW_DATA_ATTR !== !1, le = f.ALLOW_UNKNOWN_PROTOCOLS || !1, D = f.ALLOW_SELF_CLOSE_IN_ATTR !== !1, q = f.SAFE_FOR_TEMPLATES || !1, me = f.SAFE_FOR_XML !== !1, ge = f.WHOLE_DOCUMENT || !1, et = f.RETURN_DOM || !1, ft = f.RETURN_DOM_FRAGMENT || !1, ht = f.RETURN_TRUSTED_TYPE || !1, De = f.FORCE_BODY || !1, Pt = f.SANITIZE_DOM !== !1, Nt = f.SANITIZE_NAMED_PROPS || !1, bt = f.KEEP_CONTENT !== !1, ot = f.IN_PLACE || !1, Be = f.ALLOWED_URI_REGEXP || _i, ce = f.NAMESPACE || X, Je = f.MATHML_TEXT_INTEGRATION_POINTS || Je, Ue = f.HTML_INTEGRATION_POINTS || Ue, K = f.CUSTOM_ELEMENT_HANDLING || {}, f.CUSTOM_ELEMENT_HANDLING && jn(f.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (K.tagNameCheck = f.CUSTOM_ELEMENT_HANDLING.tagNameCheck), f.CUSTOM_ELEMENT_HANDLING && jn(f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (K.attributeNameCheck = f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), f.CUSTOM_ELEMENT_HANDLING && typeof f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (K.allowCustomizedBuiltInElements = f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), q && (P = !1), ft && (et = !0), tt && (ee = Q({}, ws), se = [], tt.html === !0 && (Q(ee, ks), Q(se, bs)), tt.svg === !0 && (Q(ee, pn), Q(se, gn), Q(se, Zt)), tt.svgFilters === !0 && (Q(ee, dn), Q(se, gn), Q(se, Zt)), tt.mathMl === !0 && (Q(ee, mn), Q(se, ys), Q(se, Zt))), f.ADD_TAGS && (ee === qe && (ee = lt(ee)), Q(ee, f.ADD_TAGS, _e)), f.ADD_ATTR && (se === Ae && (se = lt(se)), Q(se, f.ADD_ATTR, _e)), f.ADD_URI_SAFE_ATTR && Q(yt, f.ADD_URI_SAFE_ATTR, _e), f.FORBID_CONTENTS && (nt === Ft && (nt = lt(nt)), Q(nt, f.FORBID_CONTENTS, _e)), bt && (ee["#text"] = !0), ge && Q(ee, ["html", "head", "body"]), ee.table && (Q(ee, ["tbody"]), delete Le.tbody), f.TRUSTED_TYPES_POLICY) {
2257
+ if ((!f || typeof f != "object") && (f = {}), f = ot(f), yt = // eslint-disable-next-line unicorn/prefer-includes
2258
+ Ti.indexOf(f.PARSER_MEDIA_TYPE) === -1 ? vi : f.PARSER_MEDIA_TYPE, ke = yt === "application/xhtml+xml" ? hn : Qt, ee = Ge(f, "ALLOWED_TAGS") ? V({}, f.ALLOWED_TAGS, ke) : qe, se = Ge(f, "ALLOWED_ATTR") ? V({}, f.ALLOWED_ATTR, ke) : xe, we = Ge(f, "ALLOWED_NAMESPACES") ? V({}, f.ALLOWED_NAMESPACES, hn) : ht, bt = Ge(f, "ADD_URI_SAFE_ATTR") ? V(ot(y), f.ADD_URI_SAFE_ATTR, ke) : y, Ht = Ge(f, "ADD_DATA_URI_TAGS") ? V(ot(Bt), f.ADD_DATA_URI_TAGS, ke) : Bt, tt = Ge(f, "FORBID_CONTENTS") ? V({}, f.FORBID_CONTENTS, ke) : Ft, Le = Ge(f, "FORBID_TAGS") ? V({}, f.FORBID_TAGS, ke) : {}, ve = Ge(f, "FORBID_ATTR") ? V({}, f.FORBID_ATTR, ke) : {}, et = Ge(f, "USE_PROFILES") ? f.USE_PROFILES : !1, Qe = f.ALLOW_ARIA_ATTR !== !1, P = f.ALLOW_DATA_ATTR !== !1, le = f.ALLOW_UNKNOWN_PROTOCOLS || !1, D = f.ALLOW_SELF_CLOSE_IN_ATTR !== !1, q = f.SAFE_FOR_TEMPLATES || !1, me = f.SAFE_FOR_XML !== !1, ge = f.WHOLE_DOCUMENT || !1, $e = f.RETURN_DOM || !1, ut = f.RETURN_DOM_FRAGMENT || !1, ft = f.RETURN_TRUSTED_TYPE || !1, De = f.FORCE_BODY || !1, Pt = f.SANITIZE_DOM !== !1, Nt = f.SANITIZE_NAMED_PROPS || !1, wt = f.KEEP_CONTENT !== !1, it = f.IN_PLACE || !1, Be = f.ALLOWED_URI_REGEXP || ki, ce = f.NAMESPACE || ae, Ue = f.MATHML_TEXT_INTEGRATION_POINTS || Ue, Ut = f.HTML_INTEGRATION_POINTS || Ut, K = f.CUSTOM_ELEMENT_HANDLING || {}, f.CUSTOM_ELEMENT_HANDLING && jn(f.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && (K.tagNameCheck = f.CUSTOM_ELEMENT_HANDLING.tagNameCheck), f.CUSTOM_ELEMENT_HANDLING && jn(f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && (K.attributeNameCheck = f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), f.CUSTOM_ELEMENT_HANDLING && typeof f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && (K.allowCustomizedBuiltInElements = f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), q && (P = !1), ut && ($e = !0), et && (ee = V({}, ws), se = [], et.html === !0 && (V(ee, _s), V(se, bs)), et.svg === !0 && (V(ee, pn), V(se, gn), V(se, Zt)), et.svgFilters === !0 && (V(ee, dn), V(se, gn), V(se, Zt)), et.mathMl === !0 && (V(ee, mn), V(se, ys), V(se, Zt))), f.ADD_TAGS && (ee === qe && (ee = ot(ee)), V(ee, f.ADD_TAGS, ke)), f.ADD_ATTR && (se === xe && (se = ot(se)), V(se, f.ADD_ATTR, ke)), f.ADD_URI_SAFE_ATTR && V(bt, f.ADD_URI_SAFE_ATTR, ke), f.FORBID_CONTENTS && (tt === Ft && (tt = ot(tt)), V(tt, f.FORBID_CONTENTS, ke)), wt && (ee["#text"] = !0), ge && V(ee, ["html", "head", "body"]), ee.table && (V(ee, ["tbody"]), delete Le.tbody), f.TRUSTED_TYPES_POLICY) {
2259
2259
  if (typeof f.TRUSTED_TYPES_POLICY.createHTML != "function")
2260
- throw xt('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
2260
+ throw At('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
2261
2261
  if (typeof f.TRUSTED_TYPES_POLICY.createScriptURL != "function")
2262
- throw xt('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');
2263
- k = f.TRUSTED_TYPES_POLICY, y = k.createHTML("");
2262
+ throw At('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');
2263
+ _ = f.TRUSTED_TYPES_POLICY, b = _.createHTML("");
2264
2264
  } else
2265
- k === void 0 && (k = nl(g, o)), k !== null && typeof y == "string" && (y = k.createHTML(""));
2265
+ _ === void 0 && (_ = nl(g, o)), _ !== null && typeof b == "string" && (b = _.createHTML(""));
2266
2266
  Ce && Ce(f), pt = f;
2267
2267
  }
2268
- }, Wn = Q({}, [...pn, ...dn, ...Go]), qn = Q({}, [...mn, ...Yo]), Si = function(f) {
2268
+ }, Wn = V({}, [...pn, ...dn, ...Go]), qn = V({}, [...mn, ...Yo]), Si = function(f) {
2269
2269
  let E = w(f);
2270
2270
  (!E || !E.tagName) && (E = {
2271
2271
  namespaceURI: ce,
2272
2272
  tagName: "template"
2273
2273
  });
2274
- const O = Qt(f.tagName), ae = Qt(E.tagName);
2275
- return ke[f.namespaceURI] ? f.namespaceURI === N ? E.namespaceURI === X ? O === "svg" : E.namespaceURI === b ? O === "svg" && (ae === "annotation-xml" || Je[ae]) : !!Wn[O] : f.namespaceURI === b ? E.namespaceURI === X ? O === "math" : E.namespaceURI === N ? O === "math" && Ue[ae] : !!qn[O] : f.namespaceURI === X ? E.namespaceURI === N && !Ue[ae] || E.namespaceURI === b && !Je[ae] ? !1 : !qn[O] && (yi[O] || !Wn[O]) : !!(Tt === "application/xhtml+xml" && ke[f.namespaceURI]) : !1;
2274
+ const O = Qt(f.tagName), ue = Qt(E.tagName);
2275
+ return we[f.namespaceURI] ? f.namespaceURI === J ? E.namespaceURI === ae ? O === "svg" : E.namespaceURI === H ? O === "svg" && (ue === "annotation-xml" || Ue[ue]) : !!Wn[O] : f.namespaceURI === H ? E.namespaceURI === ae ? O === "math" : E.namespaceURI === J ? O === "math" && Ut[ue] : !!qn[O] : f.namespaceURI === ae ? E.namespaceURI === J && !Ut[ue] || E.namespaceURI === H && !Ue[ue] ? !1 : !qn[O] && (yi[O] || !Wn[O]) : !!(yt === "application/xhtml+xml" && we[f.namespaceURI]) : !1;
2276
2276
  }, Ye = function(f) {
2277
- St(e.removed, {
2277
+ Et(e.removed, {
2278
2278
  element: f
2279
2279
  });
2280
2280
  try {
@@ -2284,18 +2284,18 @@ function wi() {
2284
2284
  }
2285
2285
  }, jt = function(f, E) {
2286
2286
  try {
2287
- St(e.removed, {
2287
+ Et(e.removed, {
2288
2288
  attribute: E.getAttributeNode(f),
2289
2289
  from: E
2290
2290
  });
2291
2291
  } catch (O) {
2292
- St(e.removed, {
2292
+ Et(e.removed, {
2293
2293
  attribute: null,
2294
2294
  from: E
2295
2295
  });
2296
2296
  }
2297
2297
  if (E.removeAttribute(f), f === "is")
2298
- if (et || ft)
2298
+ if ($e || ut)
2299
2299
  try {
2300
2300
  Ye(E);
2301
2301
  } catch (O) {
@@ -2310,25 +2310,25 @@ function wi() {
2310
2310
  if (De)
2311
2311
  f = "<remove></remove>" + f;
2312
2312
  else {
2313
- const we = _s(f, /^[\r\n\t ]+/);
2314
- O = we && we[0];
2313
+ const be = ks(f, /^[\r\n\t ]+/);
2314
+ O = be && be[0];
2315
2315
  }
2316
- Tt === "application/xhtml+xml" && ce === X && (f = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + f + "</body></html>");
2317
- const ae = k ? k.createHTML(f) : f;
2318
- if (ce === X)
2316
+ yt === "application/xhtml+xml" && ce === ae && (f = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + f + "</body></html>");
2317
+ const ue = _ ? _.createHTML(f) : f;
2318
+ if (ce === ae)
2319
2319
  try {
2320
- E = new m().parseFromString(ae, Tt);
2321
- } catch (we) {
2320
+ E = new m().parseFromString(ue, yt);
2321
+ } catch (be) {
2322
2322
  }
2323
2323
  if (!E || !E.documentElement) {
2324
2324
  E = v.createDocument(ce, "template", null);
2325
2325
  try {
2326
- E.documentElement.innerHTML = fe ? y : ae;
2327
- } catch (we) {
2326
+ E.documentElement.innerHTML = _e ? b : ue;
2327
+ } catch (be) {
2328
2328
  }
2329
2329
  }
2330
- const ve = E.body || E.documentElement;
2331
- return f && O && ve.insertBefore(t.createTextNode(O), ve.childNodes[0] || null), ce === X ? z.call(E, ge ? "html" : "body")[0] : ge ? E.documentElement : ve;
2330
+ const Ee = E.body || E.documentElement;
2331
+ return f && O && Ee.insertBefore(t.createTextNode(O), Ee.childNodes[0] || null), ce === ae ? z.call(E, ge ? "html" : "body")[0] : ge ? E.documentElement : Ee;
2332
2332
  }, Yn = function(f) {
2333
2333
  return x.call(
2334
2334
  f.ownerDocument || f,
@@ -2342,47 +2342,47 @@ function wi() {
2342
2342
  }, Zn = function(f) {
2343
2343
  return typeof r == "function" && f instanceof r;
2344
2344
  };
2345
- function Ke(H, f, E) {
2346
- Yt(H, (O) => {
2345
+ function Je(F, f, E) {
2346
+ Yt(F, (O) => {
2347
2347
  O.call(e, f, E, pt);
2348
2348
  });
2349
2349
  }
2350
2350
  const Xn = function(f) {
2351
2351
  let E = null;
2352
- if (Ke(B.beforeSanitizeElements, f, null), cn(f))
2352
+ if (Je(B.beforeSanitizeElements, f, null), cn(f))
2353
2353
  return Ye(f), !0;
2354
- const O = _e(f.nodeName);
2355
- if (Ke(B.uponSanitizeElement, f, {
2354
+ const O = ke(f.nodeName);
2355
+ if (Je(B.uponSanitizeElement, f, {
2356
2356
  tagName: O,
2357
2357
  allowedTags: ee
2358
- }), f.hasChildNodes() && !Zn(f.firstElementChild) && Re(/<[/\w]/g, f.innerHTML) && Re(/<[/\w]/g, f.textContent) || f.nodeType === Rt.progressingInstruction || me && f.nodeType === Rt.comment && Re(/<[/\w]/g, f.data))
2358
+ }), f.hasChildNodes() && !Zn(f.firstElementChild) && Re(/<[/\w]/g, f.innerHTML) && Re(/<[/\w]/g, f.textContent) || f.nodeType === It.progressingInstruction || me && f.nodeType === It.comment && Re(/<[/\w]/g, f.data))
2359
2359
  return Ye(f), !0;
2360
2360
  if (!ee[O] || Le[O]) {
2361
2361
  if (!Le[O] && Qn(O) && (K.tagNameCheck instanceof RegExp && Re(K.tagNameCheck, O) || K.tagNameCheck instanceof Function && K.tagNameCheck(O)))
2362
2362
  return !1;
2363
- if (bt && !nt[O]) {
2364
- const ae = w(f) || f.parentNode, ve = A(f) || f.childNodes;
2365
- if (ve && ae) {
2366
- const we = ve.length;
2367
- for (let ze = we - 1; ze >= 0; --ze) {
2368
- const Ze = T(ve[ze], !0);
2369
- Ze.__removalCount = (f.__removalCount || 0) + 1, ae.insertBefore(Ze, L(f));
2363
+ if (wt && !tt[O]) {
2364
+ const ue = w(f) || f.parentNode, Ee = A(f) || f.childNodes;
2365
+ if (Ee && ue) {
2366
+ const be = Ee.length;
2367
+ for (let ze = be - 1; ze >= 0; --ze) {
2368
+ const Ze = T(Ee[ze], !0);
2369
+ Ze.__removalCount = (f.__removalCount || 0) + 1, ue.insertBefore(Ze, L(f));
2370
2370
  }
2371
2371
  }
2372
2372
  }
2373
2373
  return Ye(f), !0;
2374
2374
  }
2375
- return f instanceof c && !Si(f) || (O === "noscript" || O === "noembed" || O === "noframes") && Re(/<\/no(script|embed|frames)/i, f.innerHTML) ? (Ye(f), !0) : (q && f.nodeType === Rt.text && (E = f.textContent, Yt([I, C, U], (ae) => {
2376
- E = At(E, ae, " ");
2377
- }), f.textContent !== E && (St(e.removed, {
2375
+ return f instanceof c && !Si(f) || (O === "noscript" || O === "noembed" || O === "noframes") && Re(/<\/no(script|embed|frames)/i, f.innerHTML) ? (Ye(f), !0) : (q && f.nodeType === It.text && (E = f.textContent, Yt([I, C, U], (ue) => {
2376
+ E = St(E, ue, " ");
2377
+ }), f.textContent !== E && (Et(e.removed, {
2378
2378
  element: f.cloneNode()
2379
- }), f.textContent = E)), Ke(B.afterSanitizeElements, f, null), !1);
2379
+ }), f.textContent = E)), Je(B.afterSanitizeElements, f, null), !1);
2380
2380
  }, Vn = function(f, E, O) {
2381
2381
  if (Pt && (E === "id" || E === "name") && (O in t || O in Ei))
2382
2382
  return !1;
2383
- if (!(P && !Te[E] && Re(V, E))) {
2383
+ if (!(P && !ve[E] && Re(X, E))) {
2384
2384
  if (!(Qe && Re(ne, E))) {
2385
- if (!se[E] || Te[E]) {
2385
+ if (!se[E] || ve[E]) {
2386
2386
  if (
2387
2387
  // First condition does a very basic check if a) it's basically a valid custom element tagname AND
2388
2388
  // b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
@@ -2391,10 +2391,10 @@ function wi() {
2391
2391
  // the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
2392
2392
  E === "is" && K.allowCustomizedBuiltInElements && (K.tagNameCheck instanceof RegExp && Re(K.tagNameCheck, O) || K.tagNameCheck instanceof Function && K.tagNameCheck(O)))
2393
2393
  ) return !1;
2394
- } else if (!yt[E]) {
2395
- if (!Re(Be, At(O, He, ""))) {
2394
+ } else if (!bt[E]) {
2395
+ if (!Re(Be, St(O, He, ""))) {
2396
2396
  if (!((E === "src" || E === "xlink:href" || E === "href") && f !== "script" && Uo(O, "data:") === 0 && Ht[f])) {
2397
- if (!(le && !Re(he, At(O, He, "")))) {
2397
+ if (!(le && !Re(he, St(O, He, "")))) {
2398
2398
  if (O)
2399
2399
  return !1;
2400
2400
  }
@@ -2405,9 +2405,9 @@ function wi() {
2405
2405
  }
2406
2406
  return !0;
2407
2407
  }, Qn = function(f) {
2408
- return f !== "annotation-xml" && _s(f, ue);
2408
+ return f !== "annotation-xml" && ks(f, fe);
2409
2409
  }, Jn = function(f) {
2410
- Ke(B.beforeSanitizeAttributes, f, null);
2410
+ Je(B.beforeSanitizeAttributes, f, null);
2411
2411
  const {
2412
2412
  attributes: E
2413
2413
  } = f;
@@ -2420,113 +2420,113 @@ function wi() {
2420
2420
  allowedAttributes: se,
2421
2421
  forceKeepAttr: void 0
2422
2422
  };
2423
- let ae = E.length;
2424
- for (; ae--; ) {
2425
- const ve = E[ae], {
2426
- name: we,
2423
+ let ue = E.length;
2424
+ for (; ue--; ) {
2425
+ const Ee = E[ue], {
2426
+ name: be,
2427
2427
  namespaceURI: ze,
2428
2428
  value: Ze
2429
- } = ve, vt = _e(we);
2430
- let Ie = we === "value" ? Ze : jo(Ze);
2431
- if (O.attrName = vt, O.attrValue = Ie, O.keepAttr = !0, O.forceKeepAttr = void 0, Ke(B.uponSanitizeAttribute, f, O), Ie = O.attrValue, Nt && (vt === "id" || vt === "name") && (jt(we, f), Ie = rn + Ie), me && Re(/((--!?|])>)|<\/(style|title)/i, Ie)) {
2432
- jt(we, f);
2429
+ } = Ee, Tt = ke(be);
2430
+ let Ie = be === "value" ? Ze : jo(Ze);
2431
+ if (O.attrName = Tt, O.attrValue = Ie, O.keepAttr = !0, O.forceKeepAttr = void 0, Je(B.uponSanitizeAttribute, f, O), Ie = O.attrValue, Nt && (Tt === "id" || Tt === "name") && (jt(be, f), Ie = rn + Ie), me && Re(/((--!?|])>)|<\/(style|title)/i, Ie)) {
2432
+ jt(be, f);
2433
2433
  continue;
2434
2434
  }
2435
- if (O.forceKeepAttr || (jt(we, f), !O.keepAttr))
2435
+ if (O.forceKeepAttr || (jt(be, f), !O.keepAttr))
2436
2436
  continue;
2437
2437
  if (!D && Re(/\/>/i, Ie)) {
2438
- jt(we, f);
2438
+ jt(be, f);
2439
2439
  continue;
2440
2440
  }
2441
2441
  q && Yt([I, C, U], ($n) => {
2442
- Ie = At(Ie, $n, " ");
2442
+ Ie = St(Ie, $n, " ");
2443
2443
  });
2444
- const Kn = _e(f.nodeName);
2445
- if (Vn(Kn, vt, Ie)) {
2446
- if (k && typeof g == "object" && typeof g.getAttributeType == "function" && !ze)
2447
- switch (g.getAttributeType(Kn, vt)) {
2444
+ const Kn = ke(f.nodeName);
2445
+ if (Vn(Kn, Tt, Ie)) {
2446
+ if (_ && typeof g == "object" && typeof g.getAttributeType == "function" && !ze)
2447
+ switch (g.getAttributeType(Kn, Tt)) {
2448
2448
  case "TrustedHTML": {
2449
- Ie = k.createHTML(Ie);
2449
+ Ie = _.createHTML(Ie);
2450
2450
  break;
2451
2451
  }
2452
2452
  case "TrustedScriptURL": {
2453
- Ie = k.createScriptURL(Ie);
2453
+ Ie = _.createScriptURL(Ie);
2454
2454
  break;
2455
2455
  }
2456
2456
  }
2457
2457
  try {
2458
- ze ? f.setAttributeNS(ze, we, Ie) : f.setAttribute(we, Ie), cn(f) ? Ye(f) : gs(e.removed);
2458
+ ze ? f.setAttributeNS(ze, be, Ie) : f.setAttribute(be, Ie), cn(f) ? Ye(f) : gs(e.removed);
2459
2459
  } catch ($n) {
2460
2460
  }
2461
2461
  }
2462
2462
  }
2463
- Ke(B.afterSanitizeAttributes, f, null);
2464
- }, Ai = function H(f) {
2463
+ Je(B.afterSanitizeAttributes, f, null);
2464
+ }, Ai = function F(f) {
2465
2465
  let E = null;
2466
2466
  const O = Yn(f);
2467
- for (Ke(B.beforeSanitizeShadowDOM, f, null); E = O.nextNode(); )
2468
- Ke(B.uponSanitizeShadowNode, E, null), Xn(E), Jn(E), E.content instanceof l && H(E.content);
2469
- Ke(B.afterSanitizeShadowDOM, f, null);
2467
+ for (Je(B.beforeSanitizeShadowDOM, f, null); E = O.nextNode(); )
2468
+ Je(B.uponSanitizeShadowNode, E, null), Xn(E), Jn(E), E.content instanceof l && F(E.content);
2469
+ Je(B.afterSanitizeShadowDOM, f, null);
2470
2470
  };
2471
- return e.sanitize = function(H) {
2472
- let f = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, E = null, O = null, ae = null, ve = null;
2473
- if (fe = !H, fe && (H = "<!-->"), typeof H != "string" && !Zn(H))
2474
- if (typeof H.toString == "function") {
2475
- if (H = H.toString(), typeof H != "string")
2476
- throw xt("dirty is not a string, aborting");
2471
+ return e.sanitize = function(F) {
2472
+ let f = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, E = null, O = null, ue = null, Ee = null;
2473
+ if (_e = !F, _e && (F = "<!-->"), typeof F != "string" && !Zn(F))
2474
+ if (typeof F.toString == "function") {
2475
+ if (F = F.toString(), typeof F != "string")
2476
+ throw At("dirty is not a string, aborting");
2477
2477
  } else
2478
- throw xt("toString is not a function");
2478
+ throw At("toString is not a function");
2479
2479
  if (!e.isSupported)
2480
- return H;
2481
- if (Me || an(f), e.removed = [], typeof H == "string" && (ot = !1), ot) {
2482
- if (H.nodeName) {
2483
- const Ze = _e(H.nodeName);
2480
+ return F;
2481
+ if (Me || an(f), e.removed = [], typeof F == "string" && (it = !1), it) {
2482
+ if (F.nodeName) {
2483
+ const Ze = ke(F.nodeName);
2484
2484
  if (!ee[Ze] || Le[Ze])
2485
- throw xt("root node is forbidden and cannot be sanitized in-place");
2485
+ throw At("root node is forbidden and cannot be sanitized in-place");
2486
2486
  }
2487
- } else if (H instanceof r)
2488
- E = Gn("<!---->"), O = E.ownerDocument.importNode(H, !0), O.nodeType === Rt.element && O.nodeName === "BODY" || O.nodeName === "HTML" ? E = O : E.appendChild(O);
2487
+ } else if (F instanceof r)
2488
+ E = Gn("<!---->"), O = E.ownerDocument.importNode(F, !0), O.nodeType === It.element && O.nodeName === "BODY" || O.nodeName === "HTML" ? E = O : E.appendChild(O);
2489
2489
  else {
2490
- if (!et && !q && !ge && // eslint-disable-next-line unicorn/prefer-includes
2491
- H.indexOf("<") === -1)
2492
- return k && ht ? k.createHTML(H) : H;
2493
- if (E = Gn(H), !E)
2494
- return et ? null : ht ? y : "";
2490
+ if (!$e && !q && !ge && // eslint-disable-next-line unicorn/prefer-includes
2491
+ F.indexOf("<") === -1)
2492
+ return _ && ft ? _.createHTML(F) : F;
2493
+ if (E = Gn(F), !E)
2494
+ return $e ? null : ft ? b : "";
2495
2495
  }
2496
2496
  E && De && Ye(E.firstChild);
2497
- const we = Yn(ot ? H : E);
2498
- for (; ae = we.nextNode(); )
2499
- Xn(ae), Jn(ae), ae.content instanceof l && Ai(ae.content);
2500
- if (ot)
2501
- return H;
2502
- if (et) {
2503
- if (ft)
2504
- for (ve = M.call(E.ownerDocument); E.firstChild; )
2505
- ve.appendChild(E.firstChild);
2497
+ const be = Yn(it ? F : E);
2498
+ for (; ue = be.nextNode(); )
2499
+ Xn(ue), Jn(ue), ue.content instanceof l && Ai(ue.content);
2500
+ if (it)
2501
+ return F;
2502
+ if ($e) {
2503
+ if (ut)
2504
+ for (Ee = M.call(E.ownerDocument); E.firstChild; )
2505
+ Ee.appendChild(E.firstChild);
2506
2506
  else
2507
- ve = E;
2508
- return (se.shadowroot || se.shadowrootmode) && (ve = Z.call(n, ve, !0)), ve;
2507
+ Ee = E;
2508
+ return (se.shadowroot || se.shadowrootmode) && (Ee = Z.call(n, Ee, !0)), Ee;
2509
2509
  }
2510
2510
  let ze = ge ? E.outerHTML : E.innerHTML;
2511
- return ge && ee["!doctype"] && E.ownerDocument && E.ownerDocument.doctype && E.ownerDocument.doctype.name && Re(ki, E.ownerDocument.doctype.name) && (ze = "<!DOCTYPE " + E.ownerDocument.doctype.name + `>
2511
+ return ge && ee["!doctype"] && E.ownerDocument && E.ownerDocument.doctype && E.ownerDocument.doctype.name && Re(_i, E.ownerDocument.doctype.name) && (ze = "<!DOCTYPE " + E.ownerDocument.doctype.name + `>
2512
2512
  ` + ze), q && Yt([I, C, U], (Ze) => {
2513
- ze = At(ze, Ze, " ");
2514
- }), k && ht ? k.createHTML(ze) : ze;
2513
+ ze = St(ze, Ze, " ");
2514
+ }), _ && ft ? _.createHTML(ze) : ze;
2515
2515
  }, e.setConfig = function() {
2516
- let H = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
2517
- an(H), Me = !0;
2516
+ let F = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
2517
+ an(F), Me = !0;
2518
2518
  }, e.clearConfig = function() {
2519
2519
  pt = null, Me = !1;
2520
- }, e.isValidAttribute = function(H, f, E) {
2520
+ }, e.isValidAttribute = function(F, f, E) {
2521
2521
  pt || an({});
2522
- const O = _e(H), ae = _e(f);
2523
- return Vn(O, ae, E);
2524
- }, e.addHook = function(H, f) {
2525
- typeof f == "function" && St(B[H], f);
2526
- }, e.removeHook = function(H) {
2527
- return gs(B[H]);
2528
- }, e.removeHooks = function(H) {
2529
- B[H] = [];
2522
+ const O = ke(F), ue = ke(f);
2523
+ return Vn(O, ue, E);
2524
+ }, e.addHook = function(F, f) {
2525
+ typeof f == "function" && Et(B[F], f);
2526
+ }, e.removeHook = function(F) {
2527
+ return gs(B[F]);
2528
+ }, e.removeHooks = function(F) {
2529
+ B[F] = [];
2530
2530
  }, e.removeAllHooks = function() {
2531
2531
  B = vs();
2532
2532
  }, e;
@@ -2565,17 +2565,17 @@ function xs(s) {
2565
2565
  ), n;
2566
2566
  return {
2567
2567
  c() {
2568
- e = S("div"), n = ye(t), a(e, "class", "sy-assistant-button-tooltip svelte-1g6fj9a"), F(
2568
+ e = S("div"), n = Te(t), a(e, "class", "sy-assistant-button-tooltip svelte-1g6fj9a"), N(
2569
2569
  e,
2570
2570
  "left",
2571
2571
  /*buttonTooltip*/
2572
2572
  s[9].x + "px"
2573
- ), F(
2573
+ ), N(
2574
2574
  e,
2575
2575
  "top",
2576
2576
  /*buttonTooltip*/
2577
2577
  s[9].y + "px"
2578
- ), F(
2578
+ ), N(
2579
2579
  e,
2580
2580
  "z-index",
2581
2581
  /*zIndex*/
@@ -2589,19 +2589,19 @@ function xs(s) {
2589
2589
  l & /*buttonTooltip*/
2590
2590
  512 && t !== (t = /*buttonTooltip*/
2591
2591
  o[9].text + "") && Ne(n, t), l & /*buttonTooltip*/
2592
- 512 && F(
2592
+ 512 && N(
2593
2593
  e,
2594
2594
  "left",
2595
2595
  /*buttonTooltip*/
2596
2596
  o[9].x + "px"
2597
2597
  ), l & /*buttonTooltip*/
2598
- 512 && F(
2598
+ 512 && N(
2599
2599
  e,
2600
2600
  "top",
2601
2601
  /*buttonTooltip*/
2602
2602
  o[9].y + "px"
2603
2603
  ), l & /*zIndex*/
2604
- 8 && F(
2604
+ 8 && N(
2605
2605
  e,
2606
2606
  "z-index",
2607
2607
  /*zIndex*/
@@ -2614,7 +2614,7 @@ function xs(s) {
2614
2614
  };
2615
2615
  }
2616
2616
  function sl(s) {
2617
- let e = [], t = /* @__PURE__ */ new Map(), n, o, l = it(
2617
+ let e = [], t = /* @__PURE__ */ new Map(), n, o, l = st(
2618
2618
  /*sessions*/
2619
2619
  s[0]
2620
2620
  );
@@ -2643,7 +2643,7 @@ function sl(s) {
2643
2643
  },
2644
2644
  p(c, u) {
2645
2645
  u & /*sessions, deletingSessionId, showDeleteConfirm, onSelect, formatDate*/
2646
- 8261 && (l = it(
2646
+ 8261 && (l = st(
2647
2647
  /*sessions*/
2648
2648
  c[0]
2649
2649
  ), e = si(e, u, i, 1, c, l, t, n.parentNode, ni, Is, n, As)), /*isLoading*/
@@ -2667,7 +2667,7 @@ function il(s) {
2667
2667
  ), n;
2668
2668
  return {
2669
2669
  c() {
2670
- e = S("div"), n = ye(t), a(e, "class", "sy-session-empty svelte-1g6fj9a");
2670
+ e = S("div"), n = Te(t), a(e, "class", "sy-session-empty svelte-1g6fj9a");
2671
2671
  },
2672
2672
  m(o, l) {
2673
2673
  Y(o, e, l), d(e, n);
@@ -2692,7 +2692,7 @@ function Is(s, e) {
2692
2692
  ), r, c, u, h = Ls(
2693
2693
  /*session*/
2694
2694
  e[25].timestamp
2695
- ) + "", p, m, g, _, T, R, L, A, w, k, y;
2695
+ ) + "", p, m, g, k, T, R, L, A, w, _, b;
2696
2696
  function v() {
2697
2697
  return (
2698
2698
  /*click_handler*/
@@ -2716,7 +2716,7 @@ function Is(s, e) {
2716
2716
  key: s,
2717
2717
  first: null,
2718
2718
  c() {
2719
- t = S("div"), n = S("button"), o = S("div"), l = S("div"), r = ye(i), c = j(), u = S("div"), p = ye(h), m = j(), g = S("button"), _ = J("svg"), T = J("path"), R = J("path"), L = J("path"), a(l, "class", "sy-session-title svelte-1g6fj9a"), a(u, "class", "sy-session-time svelte-1g6fj9a"), a(o, "class", "sy-session-info svelte-1g6fj9a"), a(n, "class", "sy-session-select svelte-1g6fj9a"), a(T, "d", "M3 6h18"), a(R, "d", "M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"), a(L, "d", "M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"), a(_, "xmlns", "http://www.w3.org/2000/svg"), a(_, "width", "16"), a(_, "height", "16"), a(_, "viewBox", "0 0 24 24"), a(_, "fill", "none"), a(_, "stroke", "currentColor"), a(_, "stroke-width", "2"), a(_, "stroke-linecap", "round"), a(_, "stroke-linejoin", "round"), a(g, "class", "sy-session-delete svelte-1g6fj9a"), g.disabled = A = /*deletingSessionId*/
2719
+ t = S("div"), n = S("button"), o = S("div"), l = S("div"), r = Te(i), c = j(), u = S("div"), p = Te(h), m = j(), g = S("button"), k = Q("svg"), T = Q("path"), R = Q("path"), L = Q("path"), a(l, "class", "sy-session-title svelte-1g6fj9a"), a(u, "class", "sy-session-time svelte-1g6fj9a"), a(o, "class", "sy-session-info svelte-1g6fj9a"), a(n, "class", "sy-session-select svelte-1g6fj9a"), a(T, "d", "M3 6h18"), a(R, "d", "M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"), a(L, "d", "M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"), a(k, "xmlns", "http://www.w3.org/2000/svg"), a(k, "width", "16"), a(k, "height", "16"), a(k, "viewBox", "0 0 24 24"), a(k, "fill", "none"), a(k, "stroke", "currentColor"), a(k, "stroke-width", "2"), a(k, "stroke-linecap", "round"), a(k, "stroke-linejoin", "round"), a(g, "class", "sy-session-delete svelte-1g6fj9a"), g.disabled = A = /*deletingSessionId*/
2720
2720
  e[6] === /*session*/
2721
2721
  e[25].sessionId, a(g, "aria-label", "删除会话"), a(t, "class", "sy-session-item svelte-1g6fj9a"), a(t, "data-session-id", w = /*session*/
2722
2722
  e[25].sessionId), $(
@@ -2727,10 +2727,10 @@ function Is(s, e) {
2727
2727
  ), this.first = t;
2728
2728
  },
2729
2729
  m(M, z) {
2730
- Y(M, t, z), d(t, n), d(n, o), d(o, l), d(l, r), d(o, c), d(o, u), d(u, p), d(t, m), d(t, g), d(g, _), d(_, T), d(_, R), d(_, L), k || (y = [
2730
+ Y(M, t, z), d(t, n), d(n, o), d(o, l), d(l, r), d(o, c), d(o, u), d(u, p), d(t, m), d(t, g), d(g, k), d(k, T), d(k, R), d(k, L), _ || (b = [
2731
2731
  G(n, "click", v),
2732
2732
  G(g, "click", x)
2733
- ], k = !0);
2733
+ ], _ = !0);
2734
2734
  },
2735
2735
  p(M, z) {
2736
2736
  e = M, z & /*sessions*/
@@ -2753,7 +2753,7 @@ function Is(s, e) {
2753
2753
  );
2754
2754
  },
2755
2755
  d(M) {
2756
- M && W(t), k = !1, Se(y);
2756
+ M && W(t), _ = !1, Ae(b);
2757
2757
  }
2758
2758
  };
2759
2759
  }
@@ -2775,17 +2775,17 @@ function Cs(s) {
2775
2775
  let e, t, n, o, l, i, r, c, u;
2776
2776
  return {
2777
2777
  c() {
2778
- e = S("div"), t = S("div"), t.textContent = "确认删除此会话?", n = j(), o = S("div"), l = S("button"), l.textContent = "取消", i = j(), r = S("button"), r.textContent = "删除", a(t, "class", "sy-session-confirm-content svelte-1g6fj9a"), a(l, "class", "sy-session-confirm-cancel svelte-1g6fj9a"), a(r, "class", "sy-session-confirm-delete svelte-1g6fj9a"), a(o, "class", "sy-session-confirm-actions svelte-1g6fj9a"), a(e, "class", "sy-session-confirm-popup svelte-1g6fj9a"), F(
2778
+ e = S("div"), t = S("div"), t.textContent = "确认删除此会话?", n = j(), o = S("div"), l = S("button"), l.textContent = "取消", i = j(), r = S("button"), r.textContent = "删除", a(t, "class", "sy-session-confirm-content svelte-1g6fj9a"), a(l, "class", "sy-session-confirm-cancel svelte-1g6fj9a"), a(r, "class", "sy-session-confirm-delete svelte-1g6fj9a"), a(o, "class", "sy-session-confirm-actions svelte-1g6fj9a"), a(e, "class", "sy-session-confirm-popup svelte-1g6fj9a"), N(
2779
2779
  e,
2780
2780
  "left",
2781
2781
  /*confirmPosition*/
2782
2782
  s[8].x + "px"
2783
- ), F(
2783
+ ), N(
2784
2784
  e,
2785
2785
  "top",
2786
2786
  /*confirmPosition*/
2787
2787
  s[8].y + "px"
2788
- ), F(
2788
+ ), N(
2789
2789
  e,
2790
2790
  "z-index",
2791
2791
  /*zIndex*/
@@ -2810,19 +2810,19 @@ function Cs(s) {
2810
2810
  },
2811
2811
  p(h, p) {
2812
2812
  p & /*confirmPosition*/
2813
- 256 && F(
2813
+ 256 && N(
2814
2814
  e,
2815
2815
  "left",
2816
2816
  /*confirmPosition*/
2817
2817
  h[8].x + "px"
2818
2818
  ), p & /*confirmPosition*/
2819
- 256 && F(
2819
+ 256 && N(
2820
2820
  e,
2821
2821
  "top",
2822
2822
  /*confirmPosition*/
2823
2823
  h[8].y + "px"
2824
2824
  ), p & /*zIndex*/
2825
- 8 && F(
2825
+ 8 && N(
2826
2826
  e,
2827
2827
  "z-index",
2828
2828
  /*zIndex*/
@@ -2830,28 +2830,28 @@ function Cs(s) {
2830
2830
  );
2831
2831
  },
2832
2832
  d(h) {
2833
- h && W(e), c = !1, Se(u);
2833
+ h && W(e), c = !1, Ae(u);
2834
2834
  }
2835
2835
  };
2836
2836
  }
2837
2837
  function ol(s) {
2838
- let e, t, n, o, l, i, r, c, u, h, p, m, g, _, T, R, L, A, w, k = (
2838
+ let e, t, n, o, l, i, r, c, u, h, p, m, g, k, T, R, L, A, w, _ = (
2839
2839
  /*buttonTooltip*/
2840
2840
  s[9] && xs(s)
2841
2841
  );
2842
- function y(z, Z) {
2842
+ function b(z, Z) {
2843
2843
  return (
2844
2844
  /*sessions*/
2845
2845
  z[0].length === 0 ? il : sl
2846
2846
  );
2847
2847
  }
2848
- let v = y(s), x = v(s), M = (
2848
+ let v = b(s), x = v(s), M = (
2849
2849
  /*confirmDeleteId*/
2850
2850
  s[7] && Cs(s)
2851
2851
  );
2852
2852
  return {
2853
2853
  c() {
2854
- e = S("div"), t = S("div"), n = S("h2"), n.textContent = "历史会话", o = j(), l = S("button"), l.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="18" y1="6" x2="6" y2="18"></line><line x1="6" y1="6" x2="18" y2="18"></line></svg>', i = j(), r = S("div"), c = S("input"), u = j(), h = J("svg"), p = J("circle"), m = J("line"), g = j(), k && k.c(), _ = j(), T = S("div"), x.c(), R = j(), M && M.c(), L = nn(), a(n, "class", "svelte-1g6fj9a"), a(l, "class", "sy-session-close svelte-1g6fj9a"), a(l, "aria-label", "关闭历史会话"), a(t, "class", "sy-session-header svelte-1g6fj9a"), a(c, "type", "text"), a(c, "class", "sy-session-search-input svelte-1g6fj9a"), a(c, "placeholder", "搜索历史会话..."), a(p, "cx", "11"), a(p, "cy", "11"), a(p, "r", "8"), a(m, "x1", "21"), a(m, "y1", "21"), a(m, "x2", "16.65"), a(m, "y2", "16.65"), a(h, "class", "sy-session-search-icon svelte-1g6fj9a"), a(h, "xmlns", "http://www.w3.org/2000/svg"), a(h, "width", "16"), a(h, "height", "16"), a(h, "viewBox", "0 0 24 24"), a(h, "fill", "none"), a(h, "stroke", "currentColor"), a(h, "stroke-width", "2"), a(h, "stroke-linecap", "round"), a(h, "stroke-linejoin", "round"), a(r, "class", "sy-session-search svelte-1g6fj9a"), a(T, "class", "sy-session-list svelte-1g6fj9a"), a(e, "class", "sy-session-history svelte-1g6fj9a"), F(
2854
+ e = S("div"), t = S("div"), n = S("h2"), n.textContent = "历史会话", o = j(), l = S("button"), l.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="18" y1="6" x2="6" y2="18"></line><line x1="6" y1="6" x2="18" y2="18"></line></svg>', i = j(), r = S("div"), c = S("input"), u = j(), h = Q("svg"), p = Q("circle"), m = Q("line"), g = j(), _ && _.c(), k = j(), T = S("div"), x.c(), R = j(), M && M.c(), L = nn(), a(n, "class", "svelte-1g6fj9a"), a(l, "class", "sy-session-close svelte-1g6fj9a"), a(l, "aria-label", "关闭历史会话"), a(t, "class", "sy-session-header svelte-1g6fj9a"), a(c, "type", "text"), a(c, "class", "sy-session-search-input svelte-1g6fj9a"), a(c, "placeholder", "搜索历史会话..."), a(p, "cx", "11"), a(p, "cy", "11"), a(p, "r", "8"), a(m, "x1", "21"), a(m, "y1", "21"), a(m, "x2", "16.65"), a(m, "y2", "16.65"), a(h, "class", "sy-session-search-icon svelte-1g6fj9a"), a(h, "xmlns", "http://www.w3.org/2000/svg"), a(h, "width", "16"), a(h, "height", "16"), a(h, "viewBox", "0 0 24 24"), a(h, "fill", "none"), a(h, "stroke", "currentColor"), a(h, "stroke-width", "2"), a(h, "stroke-linecap", "round"), a(h, "stroke-linejoin", "round"), a(r, "class", "sy-session-search svelte-1g6fj9a"), a(T, "class", "sy-session-list svelte-1g6fj9a"), a(e, "class", "sy-session-history svelte-1g6fj9a"), N(
2855
2855
  e,
2856
2856
  "z-index",
2857
2857
  /*zIndex*/
@@ -2859,11 +2859,11 @@ function ol(s) {
2859
2859
  );
2860
2860
  },
2861
2861
  m(z, Z) {
2862
- Y(z, e, Z), d(e, t), d(t, n), d(t, o), d(t, l), d(e, i), d(e, r), d(r, c), st(
2862
+ Y(z, e, Z), d(e, t), d(t, n), d(t, o), d(t, l), d(e, i), d(e, r), d(r, c), nt(
2863
2863
  c,
2864
2864
  /*searchQuery*/
2865
2865
  s[4]
2866
- ), d(r, u), d(r, h), d(h, p), d(h, m), d(e, g), k && k.m(e, null), d(e, _), d(e, T), x.m(T, null), Y(z, R, Z), M && M.m(z, Z), Y(z, L, Z), A || (w = [
2866
+ ), d(r, u), d(r, h), d(h, p), d(h, m), d(e, g), _ && _.m(e, null), d(e, k), d(e, T), x.m(T, null), Y(z, R, Z), M && M.m(z, Z), Y(z, L, Z), A || (w = [
2867
2867
  G(l, "click", function() {
2868
2868
  xn(
2869
2869
  /*onClose*/
@@ -2899,13 +2899,13 @@ function ol(s) {
2899
2899
  p(z, [Z]) {
2900
2900
  s = z, Z & /*searchQuery*/
2901
2901
  16 && c.value !== /*searchQuery*/
2902
- s[4] && st(
2902
+ s[4] && nt(
2903
2903
  c,
2904
2904
  /*searchQuery*/
2905
2905
  s[4]
2906
2906
  ), /*buttonTooltip*/
2907
- s[9] ? k ? k.p(s, Z) : (k = xs(s), k.c(), k.m(e, _)) : k && (k.d(1), k = null), v === (v = y(s)) && x ? x.p(s, Z) : (x.d(1), x = v(s), x && (x.c(), x.m(T, null))), Z & /*zIndex*/
2908
- 8 && F(
2907
+ s[9] ? _ ? _.p(s, Z) : (_ = xs(s), _.c(), _.m(e, k)) : _ && (_.d(1), _ = null), v === (v = b(s)) && x ? x.p(s, Z) : (x.d(1), x = v(s), x && (x.c(), x.m(T, null))), Z & /*zIndex*/
2908
+ 8 && N(
2909
2909
  e,
2910
2910
  "z-index",
2911
2911
  /*zIndex*/
@@ -2916,18 +2916,18 @@ function ol(s) {
2916
2916
  i: Oe,
2917
2917
  o: Oe,
2918
2918
  d(z) {
2919
- z && (W(e), W(R), W(L)), k && k.d(), x.d(), M && M.d(z), A = !1, Se(w);
2919
+ z && (W(e), W(R), W(L)), _ && _.d(), x.d(), M && M.d(z), A = !1, Ae(w);
2920
2920
  }
2921
2921
  };
2922
2922
  }
2923
- const _n = 10;
2923
+ const kn = 10;
2924
2924
  function Ls(s) {
2925
2925
  return new Date(s).toLocaleString();
2926
2926
  }
2927
2927
  function ll(s, e, t) {
2928
- let { sessions: n = [] } = e, { onClose: o } = e, { onSelect: l } = e, { zIndex: i } = e, { apiPrefix: r } = e, c = !1, u = !0, h = 0, p = "", m = null, g = null, _ = { x: 0, y: 0 };
2928
+ let { sessions: n = [] } = e, { onClose: o } = e, { onSelect: l } = e, { zIndex: i } = e, { apiPrefix: r } = e, c = !1, u = !0, h = 0, p = "", m = null, g = null, k = { x: 0, y: 0 };
2929
2929
  function T() {
2930
- return Ee(this, null, function* () {
2930
+ return Se(this, null, function* () {
2931
2931
  if (!(c || !u)) {
2932
2932
  t(5, c = !0);
2933
2933
  try {
@@ -2938,18 +2938,18 @@ function ll(s, e, t) {
2938
2938
  "Auth-Token": `${de()}`,
2939
2939
  Authorization: `bearer ${de()}`
2940
2940
  },
2941
- body: JSON.stringify({ start: h, length: _n, keyword: p })
2941
+ body: JSON.stringify({ start: h, length: kn, keyword: p })
2942
2942
  });
2943
2943
  if (!I.ok)
2944
2944
  throw new Error("Failed to load sessions");
2945
2945
  const C = yield I.json();
2946
2946
  if (C.code === 0) {
2947
- const U = C.data.sessionList.map((V) => ({
2948
- sessionId: V.sessionId,
2949
- title: V.name,
2950
- timestamp: new Date(V.createDate).getTime()
2947
+ const U = C.data.sessionList.map((X) => ({
2948
+ sessionId: X.sessionId,
2949
+ title: X.name,
2950
+ timestamp: new Date(X.createDate).getTime()
2951
2951
  }));
2952
- t(0, n = [...n, ...U]), h += _n, u = U.length === _n;
2952
+ t(0, n = [...n, ...U]), h += kn, u = U.length === kn;
2953
2953
  }
2954
2954
  } catch (I) {
2955
2955
  console.error("Failed to load sessions:", I);
@@ -2960,34 +2960,34 @@ function ll(s, e, t) {
2960
2960
  });
2961
2961
  }
2962
2962
  function R(I) {
2963
- const C = I.target, { scrollTop: U, scrollHeight: V, clientHeight: ne } = C;
2964
- V - U - ne < 50 && T();
2963
+ const C = I.target, { scrollTop: U, scrollHeight: X, clientHeight: ne } = C;
2964
+ X - U - ne < 50 && T();
2965
2965
  }
2966
2966
  Rn(() => {
2967
2967
  T();
2968
2968
  });
2969
2969
  let L = null;
2970
2970
  function A(I, C) {
2971
- const V = I.currentTarget.getBoundingClientRect();
2971
+ const X = I.currentTarget.getBoundingClientRect();
2972
2972
  t(9, L = {
2973
2973
  text: C,
2974
- x: V.left + V.width / 2,
2975
- y: V.bottom + 8
2974
+ x: X.left + X.width / 2,
2975
+ y: X.bottom + 8
2976
2976
  });
2977
2977
  }
2978
2978
  function w() {
2979
2979
  t(9, L = null);
2980
2980
  }
2981
- function k(I, C) {
2982
- const V = I.currentTarget.getBoundingClientRect();
2983
- t(8, _ = {
2984
- x: V.left - 16,
2981
+ function _(I, C) {
2982
+ const X = I.currentTarget.getBoundingClientRect();
2983
+ t(8, k = {
2984
+ x: X.left - 16,
2985
2985
  // 靠近删除按钮
2986
- y: V.top + V.height / 2
2986
+ y: X.top + X.height / 2
2987
2987
  }), t(7, g = C);
2988
2988
  }
2989
- function y(I) {
2990
- return Ee(this, null, function* () {
2989
+ function b(I) {
2990
+ return Se(this, null, function* () {
2991
2991
  if (I && !m)
2992
2992
  try {
2993
2993
  t(6, m = I), t(7, g = null);
@@ -3004,9 +3004,9 @@ function ll(s, e, t) {
3004
3004
  });
3005
3005
  if (!U.ok)
3006
3006
  throw new Error("Delete request failed");
3007
- const V = yield U.json();
3008
- if (V.code === 0 && V.data.respCode === 0)
3009
- t(0, n = n.map((ne) => be(ie({}, ne), {
3007
+ const X = yield U.json();
3008
+ if (X.code === 0 && X.data.respCode === 0)
3009
+ t(0, n = n.map((ne) => ye(ie({}, ne), {
3010
3010
  deleting: ne.sessionId === I
3011
3011
  }))), setTimeout(
3012
3012
  () => {
@@ -3015,7 +3015,7 @@ function ll(s, e, t) {
3015
3015
  300
3016
3016
  );
3017
3017
  else
3018
- throw new Error("Delete failed: " + V.message);
3018
+ throw new Error("Delete failed: " + X.message);
3019
3019
  } catch (C) {
3020
3020
  console.error("Failed to delete session:", C);
3021
3021
  const U = document.querySelector(`[data-session-id="${I}"]`);
@@ -3026,13 +3026,13 @@ function ll(s, e, t) {
3026
3026
  });
3027
3027
  }
3028
3028
  function v() {
3029
- g && y(g);
3029
+ g && b(g);
3030
3030
  }
3031
3031
  const x = (I) => A(I, "关闭历史会话");
3032
3032
  function M() {
3033
3033
  p = this.value, t(4, p);
3034
3034
  }
3035
- const z = (I) => l(I.sessionId), Z = (I, C) => k(C, I.sessionId), B = () => t(7, g = null);
3035
+ const z = (I) => l(I.sessionId), Z = (I, C) => _(C, I.sessionId), B = () => t(7, g = null);
3036
3036
  return s.$$set = (I) => {
3037
3037
  "sessions" in I && t(0, n = I.sessions), "onClose" in I && t(1, o = I.onClose), "onSelect" in I && t(2, l = I.onSelect), "zIndex" in I && t(3, i = I.zIndex), "apiPrefix" in I && t(15, r = I.apiPrefix);
3038
3038
  }, s.$$.update = () => {
@@ -3047,12 +3047,12 @@ function ll(s, e, t) {
3047
3047
  c,
3048
3048
  m,
3049
3049
  g,
3050
- _,
3050
+ k,
3051
3051
  L,
3052
3052
  R,
3053
3053
  A,
3054
3054
  w,
3055
- k,
3055
+ _,
3056
3056
  v,
3057
3057
  r,
3058
3058
  x,
@@ -3075,24 +3075,24 @@ class bi extends On {
3075
3075
  }
3076
3076
  function Ms(s, e, t) {
3077
3077
  const n = s.slice();
3078
- return n[66] = e[t], n;
3078
+ return n[65] = e[t], n;
3079
3079
  }
3080
3080
  function zs(s, e, t) {
3081
3081
  const n = s.slice();
3082
- return n[69] = e[t], n[70] = e, n[71] = t, n;
3082
+ return n[68] = e[t], n[69] = e, n[70] = t, n;
3083
3083
  }
3084
3084
  function Os(s, e, t) {
3085
3085
  const n = s.slice();
3086
- return n[72] = e[t], n[74] = t, n;
3086
+ return n[71] = e[t], n[73] = t, n;
3087
3087
  }
3088
3088
  function rl(s) {
3089
- let e, t = [], n = /* @__PURE__ */ new Map(), o = it(
3089
+ let e, t = [], n = /* @__PURE__ */ new Map(), o = st(
3090
3090
  /*messages*/
3091
3091
  s[5]
3092
3092
  );
3093
3093
  const l = (i) => (
3094
3094
  /*msg*/
3095
- i[69].id
3095
+ i[68].id
3096
3096
  );
3097
3097
  for (let i = 0; i < o.length; i += 1) {
3098
3098
  let r = zs(s, o, i), c = l(r);
@@ -3114,7 +3114,7 @@ function rl(s) {
3114
3114
  p(i, r) {
3115
3115
  r[0] & /*messages, dislikeFeedbackPosition, zIndex, submitDislikeFeedback, showDislikeFeedback, feedbackStatus, dislikeFeedbackContent, handleDislikeClick, showButtonTooltip, handleFeedback, copyStatus, handleCopy, isLoading, tooltipPosition, tooltipTimer, tooltipContent, handleDownload, showTooltip, hideTooltip, renderMarkdown*/
3116
3116
  2141447137 | r[1] & /*hideButtonTooltip*/
3117
- 1 && (o = it(
3117
+ 1 && (o = st(
3118
3118
  /*messages*/
3119
3119
  i[5]
3120
3120
  ), t = si(t, r, l, 1, i, o, n, e, ni, Us, null, zs));
@@ -3173,7 +3173,7 @@ function al(s) {
3173
3173
  t || (je(e.$$.fragment, n), t = !0);
3174
3174
  },
3175
3175
  o(n) {
3176
- $e(e.$$.fragment, n), t = !1;
3176
+ Ke(e.$$.fragment, n), t = !1;
3177
3177
  },
3178
3178
  d(n) {
3179
3179
  on(e, n);
@@ -3213,7 +3213,7 @@ function fl(s) {
3213
3213
  /*renderMarkdown*/
3214
3214
  s[21](
3215
3215
  /*msg*/
3216
- s[69].content
3216
+ s[68].content
3217
3217
  ) + ""
3218
3218
  );
3219
3219
  return {
@@ -3228,7 +3228,7 @@ function fl(s) {
3228
3228
  32 && t !== (t = /*renderMarkdown*/
3229
3229
  n[21](
3230
3230
  /*msg*/
3231
- n[69].content
3231
+ n[68].content
3232
3232
  ) + "") && (e.innerHTML = t);
3233
3233
  },
3234
3234
  d(n) {
@@ -3252,9 +3252,9 @@ function hl(s) {
3252
3252
  };
3253
3253
  }
3254
3254
  function Ds(s) {
3255
- let e, t = it(
3255
+ let e, t = st(
3256
3256
  /*msg*/
3257
- s[69].attachments
3257
+ s[68].attachments
3258
3258
  ), n = [];
3259
3259
  for (let o = 0; o < t.length; o += 1)
3260
3260
  n[o] = Fs(Os(s, t, o));
@@ -3273,9 +3273,9 @@ function Ds(s) {
3273
3273
  p(o, l) {
3274
3274
  if (l[0] & /*tooltipPosition, zIndex, tooltipTimer, tooltipContent, handleDownload, messages, showTooltip, hideTooltip*/
3275
3275
  58720737) {
3276
- t = it(
3276
+ t = st(
3277
3277
  /*msg*/
3278
- o[69].attachments
3278
+ o[68].attachments
3279
3279
  );
3280
3280
  let i;
3281
3281
  for (i = 0; i < t.length; i += 1) {
@@ -3299,7 +3299,7 @@ function Ps(s) {
3299
3299
  /*mouseenter_handler*/
3300
3300
  s[38](
3301
3301
  /*attachment*/
3302
- s[72],
3302
+ s[71],
3303
3303
  ...l
3304
3304
  )
3305
3305
  );
@@ -3323,7 +3323,7 @@ function Ps(s) {
3323
3323
  s = l;
3324
3324
  },
3325
3325
  d(l) {
3326
- l && W(e), t = !1, Se(n);
3326
+ l && W(e), t = !1, Ae(n);
3327
3327
  }
3328
3328
  };
3329
3329
  }
@@ -3334,17 +3334,17 @@ function Ns(s) {
3334
3334
  ), n, o;
3335
3335
  return {
3336
3336
  c() {
3337
- e = S("div"), a(e, "class", "sy-assistant-tooltip svelte-mogmt"), a(e, "role", "tooltip"), F(
3337
+ e = S("div"), a(e, "class", "sy-assistant-tooltip svelte-mogmt"), a(e, "role", "tooltip"), N(
3338
3338
  e,
3339
3339
  "left",
3340
3340
  /*tooltipPosition*/
3341
3341
  s[7].x + "px"
3342
- ), F(
3342
+ ), N(
3343
3343
  e,
3344
3344
  "top",
3345
3345
  /*tooltipPosition*/
3346
3346
  s[7].y + "px"
3347
- ), F(
3347
+ ), N(
3348
3348
  e,
3349
3349
  "z-index",
3350
3350
  /*zIndex*/
@@ -3376,19 +3376,19 @@ function Ns(s) {
3376
3376
  i[0] & /*tooltipContent*/
3377
3377
  64 && t !== (t = /*tooltipContent*/
3378
3378
  l[6].replace(/\n/g, "<br>") + "") && (e.innerHTML = t), i[0] & /*tooltipPosition*/
3379
- 128 && F(
3379
+ 128 && N(
3380
3380
  e,
3381
3381
  "left",
3382
3382
  /*tooltipPosition*/
3383
3383
  l[7].x + "px"
3384
3384
  ), i[0] & /*tooltipPosition*/
3385
- 128 && F(
3385
+ 128 && N(
3386
3386
  e,
3387
3387
  "top",
3388
3388
  /*tooltipPosition*/
3389
3389
  l[7].y + "px"
3390
3390
  ), i[0] & /*zIndex*/
3391
- 1 && F(
3391
+ 1 && N(
3392
3392
  e,
3393
3393
  "z-index",
3394
3394
  /*zIndex*/
@@ -3402,27 +3402,27 @@ function Ns(s) {
3402
3402
  );
3403
3403
  },
3404
3404
  d(l) {
3405
- l && W(e), n = !1, Se(o);
3405
+ l && W(e), n = !1, Ae(o);
3406
3406
  }
3407
3407
  };
3408
3408
  }
3409
3409
  function Fs(s) {
3410
3410
  let e, t, n, o, l, i, r, c, u, h = Xt(
3411
3411
  /*attachment*/
3412
- s[72].content_title
3413
- ).name + "", p, m, g, _ = Xt(
3412
+ s[71].content_title
3413
+ ).name + "", p, m, g, k = Xt(
3414
3414
  /*attachment*/
3415
- s[72].content_title
3416
- ).ext + "", T, R, L, A, w, k, y, v, x, M, z = (
3415
+ s[71].content_title
3416
+ ).ext + "", T, R, L, A, w, _, b, v, x, M, z = (
3417
3417
  /*attachment*/
3418
- s[72].tips && Ps(s)
3418
+ s[71].tips && Ps(s)
3419
3419
  );
3420
3420
  function Z() {
3421
3421
  return (
3422
3422
  /*click_handler*/
3423
3423
  s[39](
3424
3424
  /*attachment*/
3425
- s[72]
3425
+ s[71]
3426
3426
  )
3427
3427
  );
3428
3428
  }
@@ -3432,25 +3432,25 @@ function Fs(s) {
3432
3432
  );
3433
3433
  return {
3434
3434
  c() {
3435
- e = S("div"), t = S("div"), n = S("div"), o = J("svg"), l = J("path"), i = J("polyline"), r = j(), c = S("div"), u = S("span"), p = ye(h), m = j(), g = S("span"), T = ye(_), L = j(), A = S("div"), z && z.c(), w = j(), k = S("button"), k.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="svelte-mogmt"><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"></path><polyline points="7 10 12 15 17 10"></polyline><line x1="12" y1="15" x2="12" y2="3"></line></svg>', y = j(), B && B.c(), v = j(), a(l, "d", "M13 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9z"), a(i, "points", "13 2 13 9 20 9"), a(o, "xmlns", "http://www.w3.org/2000/svg"), a(o, "width", "16"), a(o, "height", "16"), a(o, "viewBox", "0 0 24 24"), a(o, "fill", "none"), a(o, "stroke", "currentColor"), a(o, "stroke-width", "2"), a(o, "stroke-linecap", "round"), a(o, "stroke-linejoin", "round"), a(u, "class", "sy-assistant-filename svelte-mogmt"), a(g, "class", "sy-assistant-attachment-ext svelte-mogmt"), a(c, "class", "sy-assistant-attachment-name svelte-mogmt"), a(c, "title", R = /*attachment*/
3436
- s[72].content_title), a(n, "class", "sy-assistant-attachment-title svelte-mogmt"), a(k, "class", "sy-assistant-attachment-toggle svelte-mogmt"), a(k, "aria-label", "下载文件"), a(A, "class", "sy-assistant-attachment-actions svelte-mogmt"), a(t, "class", "sy-assistant-attachment-header svelte-mogmt"), a(e, "class", "sy-assistant-attachment svelte-mogmt");
3435
+ e = S("div"), t = S("div"), n = S("div"), o = Q("svg"), l = Q("path"), i = Q("polyline"), r = j(), c = S("div"), u = S("span"), p = Te(h), m = j(), g = S("span"), T = Te(k), L = j(), A = S("div"), z && z.c(), w = j(), _ = S("button"), _.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="svelte-mogmt"><path d="M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4"></path><polyline points="7 10 12 15 17 10"></polyline><line x1="12" y1="15" x2="12" y2="3"></line></svg>', b = j(), B && B.c(), v = j(), a(l, "d", "M13 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9z"), a(i, "points", "13 2 13 9 20 9"), a(o, "xmlns", "http://www.w3.org/2000/svg"), a(o, "width", "16"), a(o, "height", "16"), a(o, "viewBox", "0 0 24 24"), a(o, "fill", "none"), a(o, "stroke", "currentColor"), a(o, "stroke-width", "2"), a(o, "stroke-linecap", "round"), a(o, "stroke-linejoin", "round"), a(u, "class", "sy-assistant-filename svelte-mogmt"), a(g, "class", "sy-assistant-attachment-ext svelte-mogmt"), a(c, "class", "sy-assistant-attachment-name svelte-mogmt"), a(c, "title", R = /*attachment*/
3436
+ s[71].content_title), a(n, "class", "sy-assistant-attachment-title svelte-mogmt"), a(_, "class", "sy-assistant-attachment-toggle svelte-mogmt"), a(_, "aria-label", "下载文件"), a(A, "class", "sy-assistant-attachment-actions svelte-mogmt"), a(t, "class", "sy-assistant-attachment-header svelte-mogmt"), a(e, "class", "sy-assistant-attachment svelte-mogmt");
3437
3437
  },
3438
3438
  m(I, C) {
3439
- Y(I, e, C), d(e, t), d(t, n), d(n, o), d(o, l), d(o, i), d(n, r), d(n, c), d(c, u), d(u, p), d(c, m), d(c, g), d(g, T), d(t, L), d(t, A), z && z.m(A, null), d(A, w), d(A, k), d(e, y), B && B.m(e, null), d(e, v), x || (M = G(k, "click", Z), x = !0);
3439
+ Y(I, e, C), d(e, t), d(t, n), d(n, o), d(o, l), d(o, i), d(n, r), d(n, c), d(c, u), d(u, p), d(c, m), d(c, g), d(g, T), d(t, L), d(t, A), z && z.m(A, null), d(A, w), d(A, _), d(e, b), B && B.m(e, null), d(e, v), x || (M = G(_, "click", Z), x = !0);
3440
3440
  },
3441
3441
  p(I, C) {
3442
3442
  s = I, C[0] & /*messages*/
3443
3443
  32 && h !== (h = Xt(
3444
3444
  /*attachment*/
3445
- s[72].content_title
3445
+ s[71].content_title
3446
3446
  ).name + "") && Ne(p, h), C[0] & /*messages*/
3447
- 32 && _ !== (_ = Xt(
3447
+ 32 && k !== (k = Xt(
3448
3448
  /*attachment*/
3449
- s[72].content_title
3450
- ).ext + "") && Ne(T, _), C[0] & /*messages*/
3449
+ s[71].content_title
3450
+ ).ext + "") && Ne(T, k), C[0] & /*messages*/
3451
3451
  32 && R !== (R = /*attachment*/
3452
- s[72].content_title) && a(c, "title", R), /*attachment*/
3453
- s[72].tips ? z ? z.p(s, C) : (z = Ps(s), z.c(), z.m(A, w)) : z && (z.d(1), z = null), /*tooltipContent*/
3452
+ s[71].content_title) && a(c, "title", R), /*attachment*/
3453
+ s[71].tips ? z ? z.p(s, C) : (z = Ps(s), z.c(), z.m(A, w)) : z && (z.d(1), z = null), /*tooltipContent*/
3454
3454
  s[6] ? B ? B.p(s, C) : (B = Ns(s), B.c(), B.m(e, v)) : B && (B.d(1), B = null);
3455
3455
  },
3456
3456
  d(I) {
@@ -3465,17 +3465,17 @@ function Hs(s) {
3465
3465
  /*copyStatus*/
3466
3466
  v[13][
3467
3467
  /*msg*/
3468
- v[69].id
3468
+ v[68].id
3469
3469
  ] ? dl : pl
3470
3470
  );
3471
3471
  }
3472
- let g = m(s), _ = g(s);
3472
+ let g = m(s), k = g(s);
3473
3473
  function T() {
3474
3474
  return (
3475
3475
  /*click_handler_1*/
3476
3476
  s[42](
3477
3477
  /*msg*/
3478
- s[69]
3478
+ s[68]
3479
3479
  )
3480
3480
  );
3481
3481
  }
@@ -3484,7 +3484,7 @@ function Hs(s) {
3484
3484
  /*mouseenter_handler_2*/
3485
3485
  s[43](
3486
3486
  /*msg*/
3487
- s[69],
3487
+ s[68],
3488
3488
  ...v
3489
3489
  )
3490
3490
  );
@@ -3494,7 +3494,7 @@ function Hs(s) {
3494
3494
  /*click_handler_2*/
3495
3495
  s[44](
3496
3496
  /*msg*/
3497
- s[69]
3497
+ s[68]
3498
3498
  )
3499
3499
  );
3500
3500
  }
@@ -3503,7 +3503,7 @@ function Hs(s) {
3503
3503
  /*mouseenter_handler_3*/
3504
3504
  s[45](
3505
3505
  /*msg*/
3506
- s[69],
3506
+ s[68],
3507
3507
  ...v
3508
3508
  )
3509
3509
  );
@@ -3513,42 +3513,42 @@ function Hs(s) {
3513
3513
  /*click_handler_3*/
3514
3514
  s[46](
3515
3515
  /*msg*/
3516
- s[69],
3516
+ s[68],
3517
3517
  ...v
3518
3518
  )
3519
3519
  );
3520
3520
  }
3521
- function k(...v) {
3521
+ function _(...v) {
3522
3522
  return (
3523
3523
  /*mouseenter_handler_4*/
3524
3524
  s[47](
3525
3525
  /*msg*/
3526
- s[69],
3526
+ s[68],
3527
3527
  ...v
3528
3528
  )
3529
3529
  );
3530
3530
  }
3531
- let y = (
3531
+ let b = (
3532
3532
  /*showDislikeFeedback*/
3533
3533
  s[16] && /*feedbackStatus*/
3534
3534
  s[14][
3535
3535
  /*msg*/
3536
- s[69].id
3536
+ s[68].id
3537
3537
  ] === "dislike" && Bs(s)
3538
3538
  );
3539
3539
  return {
3540
3540
  c() {
3541
- e = S("div"), t = S("button"), _.c(), o = j(), l = S("button"), l.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M14 9V5a3 3 0 0 0-3-3l-4 9v11h11.28a2 2 0 0 0 2-1.7l1.38-9a2 2 0 0 0-2-2.3zM7 22H4a2 2 0 0 1-2-2v-7a2 2 0 0 1 2-2h3"></path></svg>', i = j(), r = S("button"), r.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M10 15v4a3 3 0 0 0 3 3l4-9V2H5.72a2 2 0 0 0-2 1.7l-1.38 9a2 2 0 0 0 2 2.3zm7-13h3a2 2 0 0 1 2 2v7a2 2 0 0 1-2 2h-3"></path></svg>', c = j(), y && y.c(), u = nn(), a(t, "class", "sy-assistant-action-button svelte-mogmt"), a(t, "aria-label", n = /*copyStatus*/
3541
+ e = S("div"), t = S("button"), k.c(), o = j(), l = S("button"), l.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M14 9V5a3 3 0 0 0-3-3l-4 9v11h11.28a2 2 0 0 0 2-1.7l1.38-9a2 2 0 0 0-2-2.3zM7 22H4a2 2 0 0 1-2-2v-7a2 2 0 0 1 2-2h3"></path></svg>', i = j(), r = S("button"), r.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="14" height="14" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M10 15v4a3 3 0 0 0 3 3l4-9V2H5.72a2 2 0 0 0-2 1.7l-1.38 9a2 2 0 0 0 2 2.3zm7-13h3a2 2 0 0 1 2 2v7a2 2 0 0 1-2 2h-3"></path></svg>', c = j(), b && b.c(), u = nn(), a(t, "class", "sy-assistant-action-button svelte-mogmt"), a(t, "aria-label", n = /*copyStatus*/
3542
3542
  s[13][
3543
3543
  /*msg*/
3544
- s[69].id
3544
+ s[68].id
3545
3545
  ] ? "已复制" : "复制内容"), $(
3546
3546
  t,
3547
3547
  "copied",
3548
3548
  /*copyStatus*/
3549
3549
  s[13][
3550
3550
  /*msg*/
3551
- s[69].id
3551
+ s[68].id
3552
3552
  ]
3553
3553
  ), a(l, "class", "sy-assistant-action-button svelte-mogmt"), a(l, "aria-label", "点赞"), $(
3554
3554
  l,
@@ -3556,7 +3556,7 @@ function Hs(s) {
3556
3556
  /*feedbackStatus*/
3557
3557
  s[14][
3558
3558
  /*msg*/
3559
- s[69].id
3559
+ s[68].id
3560
3560
  ] === "like"
3561
3561
  ), a(r, "class", "sy-assistant-action-button svelte-mogmt"), a(r, "aria-label", "点踩"), $(
3562
3562
  r,
@@ -3564,12 +3564,12 @@ function Hs(s) {
3564
3564
  /*feedbackStatus*/
3565
3565
  s[14][
3566
3566
  /*msg*/
3567
- s[69].id
3567
+ s[68].id
3568
3568
  ] === "dislike"
3569
3569
  ), a(e, "class", "sy-assistant-message-actions svelte-mogmt");
3570
3570
  },
3571
3571
  m(v, x) {
3572
- Y(v, e, x), d(e, t), _.m(t, null), d(e, o), d(e, l), d(e, i), d(e, r), Y(v, c, x), y && y.m(v, x), Y(v, u, x), h || (p = [
3572
+ Y(v, e, x), d(e, t), k.m(t, null), d(e, o), d(e, l), d(e, i), d(e, r), Y(v, c, x), b && b.m(v, x), Y(v, u, x), h || (p = [
3573
3573
  G(t, "click", T),
3574
3574
  G(t, "mouseenter", R),
3575
3575
  G(
@@ -3587,7 +3587,7 @@ function Hs(s) {
3587
3587
  s[31]
3588
3588
  ),
3589
3589
  G(r, "click", w),
3590
- G(r, "mouseenter", k),
3590
+ G(r, "mouseenter", _),
3591
3591
  G(
3592
3592
  r,
3593
3593
  "mouseleave",
@@ -3597,11 +3597,11 @@ function Hs(s) {
3597
3597
  ], h = !0);
3598
3598
  },
3599
3599
  p(v, x) {
3600
- s = v, g !== (g = m(s)) && (_.d(1), _ = g(s), _ && (_.c(), _.m(t, null))), x[0] & /*copyStatus, messages*/
3600
+ s = v, g !== (g = m(s)) && (k.d(1), k = g(s), k && (k.c(), k.m(t, null))), x[0] & /*copyStatus, messages*/
3601
3601
  8224 && n !== (n = /*copyStatus*/
3602
3602
  s[13][
3603
3603
  /*msg*/
3604
- s[69].id
3604
+ s[68].id
3605
3605
  ] ? "已复制" : "复制内容") && a(t, "aria-label", n), x[0] & /*copyStatus, messages*/
3606
3606
  8224 && $(
3607
3607
  t,
@@ -3609,7 +3609,7 @@ function Hs(s) {
3609
3609
  /*copyStatus*/
3610
3610
  s[13][
3611
3611
  /*msg*/
3612
- s[69].id
3612
+ s[68].id
3613
3613
  ]
3614
3614
  ), x[0] & /*feedbackStatus, messages*/
3615
3615
  16416 && $(
@@ -3618,7 +3618,7 @@ function Hs(s) {
3618
3618
  /*feedbackStatus*/
3619
3619
  s[14][
3620
3620
  /*msg*/
3621
- s[69].id
3621
+ s[68].id
3622
3622
  ] === "like"
3623
3623
  ), x[0] & /*feedbackStatus, messages*/
3624
3624
  16416 && $(
@@ -3627,17 +3627,17 @@ function Hs(s) {
3627
3627
  /*feedbackStatus*/
3628
3628
  s[14][
3629
3629
  /*msg*/
3630
- s[69].id
3630
+ s[68].id
3631
3631
  ] === "dislike"
3632
3632
  ), /*showDislikeFeedback*/
3633
3633
  s[16] && /*feedbackStatus*/
3634
3634
  s[14][
3635
3635
  /*msg*/
3636
- s[69].id
3637
- ] === "dislike" ? y ? y.p(s, x) : (y = Bs(s), y.c(), y.m(u.parentNode, u)) : y && (y.d(1), y = null);
3636
+ s[68].id
3637
+ ] === "dislike" ? b ? b.p(s, x) : (b = Bs(s), b.c(), b.m(u.parentNode, u)) : b && (b.d(1), b = null);
3638
3638
  },
3639
3639
  d(v) {
3640
- v && (W(e), W(c), W(u)), _.d(), y && y.d(v), h = !1, Se(p);
3640
+ v && (W(e), W(c), W(u)), k.d(), b && b.d(v), h = !1, Ae(p);
3641
3641
  }
3642
3642
  };
3643
3643
  }
@@ -3645,7 +3645,7 @@ function pl(s) {
3645
3645
  let e, t, n;
3646
3646
  return {
3647
3647
  c() {
3648
- e = J("svg"), t = J("rect"), n = J("path"), a(t, "x", "9"), a(t, "y", "9"), a(t, "width", "13"), a(t, "height", "13"), a(t, "rx", "2"), a(t, "ry", "2"), a(n, "d", "M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"), a(e, "xmlns", "http://www.w3.org/2000/svg"), a(e, "width", "14"), a(e, "height", "14"), a(e, "viewBox", "0 0 24 24"), a(e, "fill", "none"), a(e, "stroke", "currentColor"), a(e, "stroke-width", "2"), a(e, "stroke-linecap", "round"), a(e, "stroke-linejoin", "round");
3648
+ e = Q("svg"), t = Q("rect"), n = Q("path"), a(t, "x", "9"), a(t, "y", "9"), a(t, "width", "13"), a(t, "height", "13"), a(t, "rx", "2"), a(t, "ry", "2"), a(n, "d", "M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"), a(e, "xmlns", "http://www.w3.org/2000/svg"), a(e, "width", "14"), a(e, "height", "14"), a(e, "viewBox", "0 0 24 24"), a(e, "fill", "none"), a(e, "stroke", "currentColor"), a(e, "stroke-width", "2"), a(e, "stroke-linecap", "round"), a(e, "stroke-linejoin", "round");
3649
3649
  },
3650
3650
  m(o, l) {
3651
3651
  Y(o, e, l), d(e, t), d(e, n);
@@ -3659,7 +3659,7 @@ function dl(s) {
3659
3659
  let e, t;
3660
3660
  return {
3661
3661
  c() {
3662
- e = J("svg"), t = J("polyline"), a(t, "points", "20 6 9 17 4 12"), a(e, "xmlns", "http://www.w3.org/2000/svg"), a(e, "width", "14"), a(e, "height", "14"), a(e, "viewBox", "0 0 24 24"), a(e, "fill", "none"), a(e, "stroke", "currentColor"), a(e, "stroke-width", "2"), a(e, "stroke-linecap", "round"), a(e, "stroke-linejoin", "round");
3662
+ e = Q("svg"), t = Q("polyline"), a(t, "points", "20 6 9 17 4 12"), a(e, "xmlns", "http://www.w3.org/2000/svg"), a(e, "width", "14"), a(e, "height", "14"), a(e, "viewBox", "0 0 24 24"), a(e, "fill", "none"), a(e, "stroke", "currentColor"), a(e, "stroke-width", "2"), a(e, "stroke-linecap", "round"), a(e, "stroke-linejoin", "round");
3663
3663
  },
3664
3664
  m(n, o) {
3665
3665
  Y(n, e, o), d(e, t);
@@ -3675,7 +3675,7 @@ function Bs(s) {
3675
3675
  s[48].call(
3676
3676
  o,
3677
3677
  /*msg*/
3678
- s[69]
3678
+ s[68]
3679
3679
  );
3680
3680
  }
3681
3681
  function g() {
@@ -3683,32 +3683,32 @@ function Bs(s) {
3683
3683
  /*click_handler_4*/
3684
3684
  s[49](
3685
3685
  /*msg*/
3686
- s[69]
3686
+ s[68]
3687
3687
  )
3688
3688
  );
3689
3689
  }
3690
- function _() {
3690
+ function k() {
3691
3691
  return (
3692
3692
  /*click_handler_5*/
3693
3693
  s[50](
3694
3694
  /*msg*/
3695
- s[69]
3695
+ s[68]
3696
3696
  )
3697
3697
  );
3698
3698
  }
3699
3699
  return {
3700
3700
  c() {
3701
- e = S("div"), t = S("div"), t.textContent = "反馈意见", n = j(), o = S("textarea"), l = j(), i = S("div"), r = S("button"), r.textContent = "取消", c = j(), u = S("button"), u.textContent = "提交", a(t, "class", "sy-assistant-dislike-title svelte-mogmt"), a(o, "class", "sy-assistant-dislike-input svelte-mogmt"), a(o, "placeholder", "请输入您的反馈意见..."), a(r, "class", "sy-assistant-popup-cancel svelte-mogmt"), a(u, "class", "sy-assistant-popup-submit svelte-mogmt"), a(i, "class", "sy-assistant-popup-actions svelte-mogmt"), a(e, "class", "sy-assistant-dislike-popup svelte-mogmt"), F(
3701
+ e = S("div"), t = S("div"), t.textContent = "反馈意见", n = j(), o = S("textarea"), l = j(), i = S("div"), r = S("button"), r.textContent = "取消", c = j(), u = S("button"), u.textContent = "提交", a(t, "class", "sy-assistant-dislike-title svelte-mogmt"), a(o, "class", "sy-assistant-dislike-input svelte-mogmt"), a(o, "placeholder", "请输入您的反馈意见..."), a(r, "class", "sy-assistant-popup-cancel svelte-mogmt"), a(u, "class", "sy-assistant-popup-submit svelte-mogmt"), a(i, "class", "sy-assistant-popup-actions svelte-mogmt"), a(e, "class", "sy-assistant-dislike-popup svelte-mogmt"), N(
3702
3702
  e,
3703
3703
  "left",
3704
3704
  /*dislikeFeedbackPosition*/
3705
3705
  s[17].x + "px"
3706
- ), F(
3706
+ ), N(
3707
3707
  e,
3708
3708
  "top",
3709
3709
  /*dislikeFeedbackPosition*/
3710
3710
  s[17].y + "px"
3711
- ), F(
3711
+ ), N(
3712
3712
  e,
3713
3713
  "z-index",
3714
3714
  /*zIndex*/
@@ -3716,42 +3716,42 @@ function Bs(s) {
3716
3716
  );
3717
3717
  },
3718
3718
  m(T, R) {
3719
- Y(T, e, R), d(e, t), d(e, n), d(e, o), st(
3719
+ Y(T, e, R), d(e, t), d(e, n), d(e, o), nt(
3720
3720
  o,
3721
3721
  /*dislikeFeedbackContent*/
3722
3722
  s[15][
3723
3723
  /*msg*/
3724
- s[69].id
3724
+ s[68].id
3725
3725
  ]
3726
3726
  ), d(e, l), d(e, i), d(i, r), d(i, c), d(i, u), h || (p = [
3727
3727
  G(o, "input", m),
3728
3728
  G(r, "click", g),
3729
- G(u, "click", _)
3729
+ G(u, "click", k)
3730
3730
  ], h = !0);
3731
3731
  },
3732
3732
  p(T, R) {
3733
3733
  s = T, R[0] & /*dislikeFeedbackContent, messages*/
3734
- 32800 && st(
3734
+ 32800 && nt(
3735
3735
  o,
3736
3736
  /*dislikeFeedbackContent*/
3737
3737
  s[15][
3738
3738
  /*msg*/
3739
- s[69].id
3739
+ s[68].id
3740
3740
  ]
3741
3741
  ), R[0] & /*dislikeFeedbackPosition*/
3742
- 131072 && F(
3742
+ 131072 && N(
3743
3743
  e,
3744
3744
  "left",
3745
3745
  /*dislikeFeedbackPosition*/
3746
3746
  s[17].x + "px"
3747
3747
  ), R[0] & /*dislikeFeedbackPosition*/
3748
- 131072 && F(
3748
+ 131072 && N(
3749
3749
  e,
3750
3750
  "top",
3751
3751
  /*dislikeFeedbackPosition*/
3752
3752
  s[17].y + "px"
3753
3753
  ), R[0] & /*zIndex*/
3754
- 1 && F(
3754
+ 1 && N(
3755
3755
  e,
3756
3756
  "z-index",
3757
3757
  /*zIndex*/
@@ -3759,106 +3759,106 @@ function Bs(s) {
3759
3759
  );
3760
3760
  },
3761
3761
  d(T) {
3762
- T && W(e), h = !1, Se(p);
3762
+ T && W(e), h = !1, Ae(p);
3763
3763
  }
3764
3764
  };
3765
3765
  }
3766
3766
  function Us(s, e) {
3767
3767
  let t, n, o, l, i, r, c, u, h = new Date(
3768
3768
  /*msg*/
3769
- e[69].timestamp
3769
+ e[68].timestamp
3770
3770
  ).toLocaleString() + "", p, m;
3771
- function g(y, v) {
3771
+ function g(b, v) {
3772
3772
  return (
3773
3773
  /*msg*/
3774
- y[69].type === "assistant" ? ul : cl
3774
+ b[68].type === "assistant" ? ul : cl
3775
3775
  );
3776
3776
  }
3777
- let _ = g(e), T = _(e);
3778
- function R(y, v) {
3777
+ let k = g(e), T = k(e);
3778
+ function R(b, v) {
3779
3779
  return (
3780
3780
  /*isLoading*/
3781
- y[9] && /*msg*/
3782
- y[69].id === /*messages*/
3783
- y[5][
3781
+ b[9] && /*msg*/
3782
+ b[68].id === /*messages*/
3783
+ b[5][
3784
3784
  /*messages*/
3785
- y[5].length - 1
3785
+ b[5].length - 1
3786
3786
  ].id && /*msg*/
3787
- y[69].type === "assistant" && !/*msg*/
3788
- y[69].content ? hl : fl
3787
+ b[68].type === "assistant" && !/*msg*/
3788
+ b[68].content ? hl : fl
3789
3789
  );
3790
3790
  }
3791
3791
  let L = R(e), A = L(e), w = (
3792
3792
  /*msg*/
3793
- e[69].attachments && Ds(e)
3794
- ), k = (
3793
+ e[68].attachments && Ds(e)
3794
+ ), _ = (
3795
3795
  /*msg*/
3796
- e[69].id !== "-1" && /*msg*/
3797
- e[69].type === "assistant" && !/*isLoading*/
3796
+ e[68].id !== "-1" && /*msg*/
3797
+ e[68].type === "assistant" && !/*isLoading*/
3798
3798
  e[9] && Hs(e)
3799
3799
  );
3800
3800
  return {
3801
3801
  key: s,
3802
3802
  first: null,
3803
3803
  c() {
3804
- t = S("div"), T.c(), n = j(), o = S("div"), l = S("div"), A.c(), i = j(), w && w.c(), r = j(), k && k.c(), c = j(), u = S("div"), p = ye(h), m = j(), a(l, "class", "sy-assistant-message-content svelte-mogmt"), a(u, "class", "sy-assistant-message-time svelte-mogmt"), a(o, "class", "sy-assistant-message-bubble svelte-mogmt"), a(t, "class", "sy-assistant-message svelte-mogmt"), $(
3804
+ t = S("div"), T.c(), n = j(), o = S("div"), l = S("div"), A.c(), i = j(), w && w.c(), r = j(), _ && _.c(), c = j(), u = S("div"), p = Te(h), m = j(), a(l, "class", "sy-assistant-message-content svelte-mogmt"), a(u, "class", "sy-assistant-message-time svelte-mogmt"), a(o, "class", "sy-assistant-message-bubble svelte-mogmt"), a(t, "class", "sy-assistant-message svelte-mogmt"), $(
3805
3805
  t,
3806
3806
  "user",
3807
3807
  /*msg*/
3808
- e[69].type === "user"
3808
+ e[68].type === "user"
3809
3809
  ), this.first = t;
3810
3810
  },
3811
- m(y, v) {
3812
- Y(y, t, v), T.m(t, null), d(t, n), d(t, o), d(o, l), A.m(l, null), d(l, i), w && w.m(l, null), d(l, r), k && k.m(l, null), d(o, c), d(o, u), d(u, p), d(t, m);
3811
+ m(b, v) {
3812
+ Y(b, t, v), T.m(t, null), d(t, n), d(t, o), d(o, l), A.m(l, null), d(l, i), w && w.m(l, null), d(l, r), _ && _.m(l, null), d(o, c), d(o, u), d(u, p), d(t, m);
3813
3813
  },
3814
- p(y, v) {
3815
- e = y, _ !== (_ = g(e)) && (T.d(1), T = _(e), T && (T.c(), T.m(t, n))), L === (L = R(e)) && A ? A.p(e, v) : (A.d(1), A = L(e), A && (A.c(), A.m(l, i))), /*msg*/
3816
- e[69].attachments ? w ? w.p(e, v) : (w = Ds(e), w.c(), w.m(l, r)) : w && (w.d(1), w = null), /*msg*/
3817
- e[69].id !== "-1" && /*msg*/
3818
- e[69].type === "assistant" && !/*isLoading*/
3819
- e[9] ? k ? k.p(e, v) : (k = Hs(e), k.c(), k.m(l, null)) : k && (k.d(1), k = null), v[0] & /*messages*/
3814
+ p(b, v) {
3815
+ e = b, k !== (k = g(e)) && (T.d(1), T = k(e), T && (T.c(), T.m(t, n))), L === (L = R(e)) && A ? A.p(e, v) : (A.d(1), A = L(e), A && (A.c(), A.m(l, i))), /*msg*/
3816
+ e[68].attachments ? w ? w.p(e, v) : (w = Ds(e), w.c(), w.m(l, r)) : w && (w.d(1), w = null), /*msg*/
3817
+ e[68].id !== "-1" && /*msg*/
3818
+ e[68].type === "assistant" && !/*isLoading*/
3819
+ e[9] ? _ ? _.p(e, v) : (_ = Hs(e), _.c(), _.m(l, null)) : _ && (_.d(1), _ = null), v[0] & /*messages*/
3820
3820
  32 && h !== (h = new Date(
3821
3821
  /*msg*/
3822
- e[69].timestamp
3822
+ e[68].timestamp
3823
3823
  ).toLocaleString() + "") && Ne(p, h), v[0] & /*messages*/
3824
3824
  32 && $(
3825
3825
  t,
3826
3826
  "user",
3827
3827
  /*msg*/
3828
- e[69].type === "user"
3828
+ e[68].type === "user"
3829
3829
  );
3830
3830
  },
3831
- d(y) {
3832
- y && W(t), T.d(), A.d(), w && w.d(), k && k.d();
3831
+ d(b) {
3832
+ b && W(t), T.d(), A.d(), w && w.d(), _ && _.d();
3833
3833
  }
3834
3834
  };
3835
3835
  }
3836
3836
  function js(s) {
3837
- let e, t, n, o, l, i, r, c, u, h, p, m, g, _, T, R, L, A, w, k, y, v, x, M, z, Z, B, I = (
3837
+ let e, t, n, o, l, i, r, c, u, h, p, m, g, k, T, R, L, A, w, _, b, v, x, M, z, Z, B, I = (
3838
3838
  /*hasScene*/
3839
3839
  s[1] && Ws(s)
3840
3840
  ), C = !/*hasScene*/
3841
3841
  s[1] && Gs();
3842
3842
  return {
3843
3843
  c() {
3844
- e = S("div"), t = S("div"), I && I.c(), n = j(), C && C.c(), o = j(), l = S("div"), i = S("button"), i.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M12 8v4l3 3"></path><circle cx="12" cy="12" r="10"></circle></svg>', r = j(), c = S("button"), c.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="12" y1="5" x2="12" y2="19"></line><line x1="5" y1="12" x2="19" y2="12"></line></svg>', u = j(), h = S("div"), p = S("div"), m = S("div"), g = S("div"), _ = S("textarea"), T = j(), R = S("div"), L = ye(
3844
+ e = S("div"), t = S("div"), I && I.c(), n = j(), C && C.c(), o = j(), l = S("div"), i = S("button"), i.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><path d="M12 8v4l3 3"></path><circle cx="12" cy="12" r="10"></circle></svg>', r = j(), c = S("button"), c.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="16" height="16" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="12" y1="5" x2="12" y2="19"></line><line x1="5" y1="12" x2="19" y2="12"></line></svg>', u = j(), h = S("div"), p = S("div"), m = S("div"), g = S("div"), k = S("textarea"), T = j(), R = S("div"), L = Te(
3845
3845
  /*messageLength*/
3846
3846
  s[4]
3847
- ), A = ye("/"), w = ye(An), k = j(), y = S("button"), v = J("svg"), x = J("line"), M = J("polygon"), a(i, "class", "sy-assistant-icon-button svelte-mogmt"), a(i, "aria-label", "历史会话"), a(c, "class", "sy-assistant-icon-button svelte-mogmt"), a(c, "aria-label", "新建会话"), a(l, "class", "sy-assistant-chat-actions-btns svelte-mogmt"), a(t, "class", "sy-assistant-chat-actions svelte-mogmt"), a(e, "class", "sy-assistant-chat-footer svelte-mogmt"), a(_, "class", "sy-assistant-textarea svelte-mogmt"), a(_, "placeholder", "输入您的问题..."), a(_, "maxlength", An), a(_, "rows", "3"), a(R, "class", "sy-assistant-char-count svelte-mogmt"), $(
3847
+ ), A = Te("/"), w = Te(An), _ = j(), b = S("button"), v = Q("svg"), x = Q("line"), M = Q("polygon"), a(i, "class", "sy-assistant-icon-button svelte-mogmt"), a(i, "aria-label", "历史会话"), a(c, "class", "sy-assistant-icon-button svelte-mogmt"), a(c, "aria-label", "新建会话"), a(l, "class", "sy-assistant-chat-actions-btns svelte-mogmt"), a(t, "class", "sy-assistant-chat-actions svelte-mogmt"), a(e, "class", "sy-assistant-chat-footer svelte-mogmt"), a(k, "class", "sy-assistant-textarea svelte-mogmt"), a(k, "placeholder", "输入您的问题..."), a(k, "maxlength", An), a(k, "rows", "3"), a(R, "class", "sy-assistant-char-count svelte-mogmt"), $(
3848
3848
  R,
3849
3849
  "over-limit",
3850
3850
  /*isOverLimit*/
3851
3851
  s[20]
3852
- ), a(g, "class", "sy-assistant-textarea-container svelte-mogmt"), a(m, "class", "sy-assistant-input-wrapper svelte-mogmt"), a(x, "x1", "22"), a(x, "y1", "2"), a(x, "x2", "11"), a(x, "y2", "13"), a(M, "points", "22 2 15 22 11 13 2 9 22 2"), a(v, "xmlns", "http://www.w3.org/2000/svg"), a(v, "width", "20"), a(v, "height", "20"), a(v, "viewBox", "0 0 24 24"), a(v, "fill", "none"), a(v, "stroke", "currentColor"), a(v, "stroke-width", "2"), a(v, "stroke-linecap", "round"), a(v, "stroke-linejoin", "round"), a(y, "class", "sy-assistant-send-button svelte-mogmt"), y.disabled = z = !/*message*/
3852
+ ), a(g, "class", "sy-assistant-textarea-container svelte-mogmt"), a(m, "class", "sy-assistant-input-wrapper svelte-mogmt"), a(x, "x1", "22"), a(x, "y1", "2"), a(x, "x2", "11"), a(x, "y2", "13"), a(M, "points", "22 2 15 22 11 13 2 9 22 2"), a(v, "xmlns", "http://www.w3.org/2000/svg"), a(v, "width", "20"), a(v, "height", "20"), a(v, "viewBox", "0 0 24 24"), a(v, "fill", "none"), a(v, "stroke", "currentColor"), a(v, "stroke-width", "2"), a(v, "stroke-linecap", "round"), a(v, "stroke-linejoin", "round"), a(b, "class", "sy-assistant-send-button svelte-mogmt"), b.disabled = z = !/*message*/
3853
3853
  s[3].trim() || /*isOverLimit*/
3854
- s[20], a(y, "aria-label", "发送消息"), a(p, "class", "sy-assistant-input-container svelte-mogmt"), a(h, "class", "sy-assistant-input-area svelte-mogmt");
3854
+ s[20], a(b, "aria-label", "发送消息"), a(p, "class", "sy-assistant-input-container svelte-mogmt"), a(h, "class", "sy-assistant-input-area svelte-mogmt");
3855
3855
  },
3856
- m(U, V) {
3857
- Y(U, e, V), d(e, t), I && I.m(t, null), d(t, n), C && C.m(t, null), d(t, o), d(t, l), d(l, i), d(l, r), d(l, c), Y(U, u, V), Y(U, h, V), d(h, p), d(p, m), d(m, g), d(g, _), st(
3858
- _,
3856
+ m(U, X) {
3857
+ Y(U, e, X), d(e, t), I && I.m(t, null), d(t, n), C && C.m(t, null), d(t, o), d(t, l), d(l, i), d(l, r), d(l, c), Y(U, u, X), Y(U, h, X), d(h, p), d(p, m), d(m, g), d(g, k), nt(
3858
+ k,
3859
3859
  /*message*/
3860
3860
  s[3]
3861
- ), d(g, T), d(g, R), d(R, L), d(R, A), d(R, w), d(p, k), d(p, y), d(y, v), d(v, x), d(v, M), Z || (B = [
3861
+ ), d(g, T), d(g, R), d(R, L), d(R, A), d(R, w), d(p, _), d(p, b), d(b, v), d(v, x), d(v, M), Z || (B = [
3862
3862
  G(
3863
3863
  i,
3864
3864
  "click",
@@ -3896,68 +3896,68 @@ function js(s) {
3896
3896
  s[31]
3897
3897
  ),
3898
3898
  G(
3899
- _,
3899
+ k,
3900
3900
  "input",
3901
3901
  /*textarea_input_handler_1*/
3902
3902
  s[55]
3903
3903
  ),
3904
3904
  G(
3905
- _,
3905
+ k,
3906
3906
  "keydown",
3907
3907
  /*keydown_handler*/
3908
3908
  s[56]
3909
3909
  ),
3910
3910
  G(
3911
- y,
3911
+ b,
3912
3912
  "click",
3913
3913
  /*handleSend*/
3914
3914
  s[22]
3915
3915
  ),
3916
3916
  G(
3917
- y,
3917
+ b,
3918
3918
  "mouseenter",
3919
3919
  /*mouseenter_handler_7*/
3920
3920
  s[57]
3921
3921
  ),
3922
3922
  G(
3923
- y,
3923
+ b,
3924
3924
  "mouseleave",
3925
3925
  /*hideButtonTooltip*/
3926
3926
  s[31]
3927
3927
  )
3928
3928
  ], Z = !0);
3929
3929
  },
3930
- p(U, V) {
3930
+ p(U, X) {
3931
3931
  /*hasScene*/
3932
- U[1] ? I ? I.p(U, V) : (I = Ws(U), I.c(), I.m(t, n)) : I && (I.d(1), I = null), /*hasScene*/
3933
- U[1] ? C && (C.d(1), C = null) : C || (C = Gs(), C.c(), C.m(t, o)), V[0] & /*message*/
3934
- 8 && st(
3935
- _,
3932
+ U[1] ? I ? I.p(U, X) : (I = Ws(U), I.c(), I.m(t, n)) : I && (I.d(1), I = null), /*hasScene*/
3933
+ U[1] ? C && (C.d(1), C = null) : C || (C = Gs(), C.c(), C.m(t, o)), X[0] & /*message*/
3934
+ 8 && nt(
3935
+ k,
3936
3936
  /*message*/
3937
3937
  U[3]
3938
- ), V[0] & /*messageLength*/
3938
+ ), X[0] & /*messageLength*/
3939
3939
  16 && Ne(
3940
3940
  L,
3941
3941
  /*messageLength*/
3942
3942
  U[4]
3943
- ), V[0] & /*isOverLimit*/
3943
+ ), X[0] & /*isOverLimit*/
3944
3944
  1048576 && $(
3945
3945
  R,
3946
3946
  "over-limit",
3947
3947
  /*isOverLimit*/
3948
3948
  U[20]
3949
- ), V[0] & /*message, isOverLimit*/
3949
+ ), X[0] & /*message, isOverLimit*/
3950
3950
  1048584 && z !== (z = !/*message*/
3951
3951
  U[3].trim() || /*isOverLimit*/
3952
- U[20]) && (y.disabled = z);
3952
+ U[20]) && (b.disabled = z);
3953
3953
  },
3954
3954
  d(U) {
3955
- U && (W(e), W(u), W(h)), I && I.d(), C && C.d(), Z = !1, Se(B);
3955
+ U && (W(e), W(u), W(h)), I && I.d(), C && C.d(), Z = !1, Ae(B);
3956
3956
  }
3957
3957
  };
3958
3958
  }
3959
3959
  function Ws(s) {
3960
- let e, t, n, o, l = it(
3960
+ let e, t, n, o, l = st(
3961
3961
  /*scenes*/
3962
3962
  s[11]
3963
3963
  ), i = [];
@@ -3993,7 +3993,7 @@ function Ws(s) {
3993
3993
  p(r, c) {
3994
3994
  if (c[0] & /*scenes*/
3995
3995
  2048) {
3996
- l = it(
3996
+ l = st(
3997
3997
  /*scenes*/
3998
3998
  r[11]
3999
3999
  );
@@ -4021,12 +4021,12 @@ function Ws(s) {
4021
4021
  function qs(s) {
4022
4022
  let e, t = (
4023
4023
  /*scene*/
4024
- s[66].name + ""
4024
+ s[65].name + ""
4025
4025
  ), n, o, l;
4026
4026
  return {
4027
4027
  c() {
4028
- e = S("option"), n = ye(t), o = j(), e.__value = l = /*scene*/
4029
- s[66].code, st(e, e.__value);
4028
+ e = S("option"), n = Te(t), o = j(), e.__value = l = /*scene*/
4029
+ s[65].code, nt(e, e.__value);
4030
4030
  },
4031
4031
  m(i, r) {
4032
4032
  Y(i, e, r), d(e, n), d(e, o);
@@ -4034,9 +4034,9 @@ function qs(s) {
4034
4034
  p(i, r) {
4035
4035
  r[0] & /*scenes*/
4036
4036
  2048 && t !== (t = /*scene*/
4037
- i[66].name + "") && Ne(n, t), r[0] & /*scenes*/
4037
+ i[65].name + "") && Ne(n, t), r[0] & /*scenes*/
4038
4038
  2048 && l !== (l = /*scene*/
4039
- i[66].code) && (e.__value = l, st(e, e.__value));
4039
+ i[65].code) && (e.__value = l, nt(e, e.__value));
4040
4040
  },
4041
4041
  d(i) {
4042
4042
  i && W(e);
@@ -4064,12 +4064,12 @@ function Ys(s) {
4064
4064
  ), n;
4065
4065
  return {
4066
4066
  c() {
4067
- e = S("div"), n = ye(t), a(e, "class", "sy-assistant-button-tooltip svelte-mogmt"), F(
4067
+ e = S("div"), n = Te(t), a(e, "class", "sy-assistant-button-tooltip svelte-mogmt"), N(
4068
4068
  e,
4069
4069
  "left",
4070
4070
  /*buttonTooltip*/
4071
4071
  s[18].x + "px"
4072
- ), F(
4072
+ ), N(
4073
4073
  e,
4074
4074
  "top",
4075
4075
  /*buttonTooltip*/
@@ -4083,13 +4083,13 @@ function Ys(s) {
4083
4083
  l[0] & /*buttonTooltip*/
4084
4084
  262144 && t !== (t = /*buttonTooltip*/
4085
4085
  o[18].text + "") && Ne(n, t), l[0] & /*buttonTooltip*/
4086
- 262144 && F(
4086
+ 262144 && N(
4087
4087
  e,
4088
4088
  "left",
4089
4089
  /*buttonTooltip*/
4090
4090
  o[18].x + "px"
4091
4091
  ), l[0] & /*buttonTooltip*/
4092
- 262144 && F(
4092
+ 262144 && N(
4093
4093
  e,
4094
4094
  "top",
4095
4095
  /*buttonTooltip*/
@@ -4104,7 +4104,7 @@ function Ys(s) {
4104
4104
  function ml(s) {
4105
4105
  let e, t, n, o, l, i, r;
4106
4106
  const c = [al, rl], u = [];
4107
- function h(g, _) {
4107
+ function h(g, k) {
4108
4108
  return (
4109
4109
  /*showHistory*/
4110
4110
  g[19] ? 0 : 1
@@ -4118,38 +4118,38 @@ function ml(s) {
4118
4118
  );
4119
4119
  return {
4120
4120
  c() {
4121
- e = S("div"), n.c(), o = j(), p && p.c(), l = j(), m && m.c(), i = nn(), a(e, "class", "sy-assistant-chat-container svelte-mogmt"), F(
4121
+ e = S("div"), n.c(), o = j(), p && p.c(), l = j(), m && m.c(), i = nn(), a(e, "class", "sy-assistant-chat-container svelte-mogmt"), N(
4122
4122
  e,
4123
4123
  "z-index",
4124
4124
  /*zIndex*/
4125
4125
  s[0] + 2
4126
4126
  );
4127
4127
  },
4128
- m(g, _) {
4129
- Y(g, e, _), u[t].m(e, null), d(e, o), p && p.m(e, null), s[58](e), Y(g, l, _), m && m.m(g, _), Y(g, i, _), r = !0;
4128
+ m(g, k) {
4129
+ Y(g, e, k), u[t].m(e, null), d(e, o), p && p.m(e, null), Y(g, l, k), m && m.m(g, k), Y(g, i, k), r = !0;
4130
4130
  },
4131
- p(g, _) {
4131
+ p(g, k) {
4132
4132
  let T = t;
4133
- t = h(g), t === T ? u[t].p(g, _) : (Cn(), $e(u[T], 1, 1, () => {
4133
+ t = h(g), t === T ? u[t].p(g, k) : (Cn(), Ke(u[T], 1, 1, () => {
4134
4134
  u[T] = null;
4135
- }), Ln(), n = u[t], n ? n.p(g, _) : (n = u[t] = c[t](g), n.c()), je(n, 1), n.m(e, o)), /*showHistory*/
4136
- g[19] ? p && (p.d(1), p = null) : p ? p.p(g, _) : (p = js(g), p.c(), p.m(e, null)), (!r || _[0] & /*zIndex*/
4137
- 1) && F(
4135
+ }), Ln(), n = u[t], n ? n.p(g, k) : (n = u[t] = c[t](g), n.c()), je(n, 1), n.m(e, o)), /*showHistory*/
4136
+ g[19] ? p && (p.d(1), p = null) : p ? p.p(g, k) : (p = js(g), p.c(), p.m(e, null)), (!r || k[0] & /*zIndex*/
4137
+ 1) && N(
4138
4138
  e,
4139
4139
  "z-index",
4140
4140
  /*zIndex*/
4141
4141
  g[0] + 2
4142
4142
  ), /*buttonTooltip*/
4143
- g[18] ? m ? m.p(g, _) : (m = Ys(g), m.c(), m.m(i.parentNode, i)) : m && (m.d(1), m = null);
4143
+ g[18] ? m ? m.p(g, k) : (m = Ys(g), m.c(), m.m(i.parentNode, i)) : m && (m.d(1), m = null);
4144
4144
  },
4145
4145
  i(g) {
4146
4146
  r || (je(n), r = !0);
4147
4147
  },
4148
4148
  o(g) {
4149
- $e(n), r = !1;
4149
+ Ke(n), r = !1;
4150
4150
  },
4151
4151
  d(g) {
4152
- g && (W(e), W(l), W(i)), u[t].d(), p && p.d(), s[58](null), m && m.d(g);
4152
+ g && (W(e), W(l), W(i)), u[t].d(), p && p.d(), m && m.d(g);
4153
4153
  }
4154
4154
  };
4155
4155
  }
@@ -4179,7 +4179,7 @@ function Xt(s) {
4179
4179
  }
4180
4180
  return { name: s, ext: "" };
4181
4181
  }
4182
- function _l(s, e, t) {
4182
+ function kl(s, e, t) {
4183
4183
  let n, o, l = "", i = [
4184
4184
  {
4185
4185
  sessionId: "",
@@ -4196,51 +4196,50 @@ function _l(s, e, t) {
4196
4196
  gfm: !0
4197
4197
  // 支持 GitHub 风格 Markdown
4198
4198
  });
4199
- function g(b) {
4199
+ function g(y) {
4200
4200
  try {
4201
- const N = te(b);
4202
- return Es.sanitize(N);
4203
- } catch (N) {
4204
- console.warn("Markdown parsing failed, fallback to HTML:", N);
4201
+ const H = te(y);
4202
+ return Es.sanitize(H);
4203
+ } catch (H) {
4204
+ console.warn("Markdown parsing failed, fallback to HTML:", H);
4205
4205
  try {
4206
- const X = b.replace(/\n/g, "<br>").replace(
4206
+ const J = y.replace(/\n/g, "<br>").replace(
4207
4207
  /\*\*(.*?)\*\*/g,
4208
4208
  "<strong>$1</strong>"
4209
4209
  // 处理加粗
4210
4210
  ).replace(/\*(.*?)\*/g, "<em>$1</em>");
4211
- return Es.sanitize(X);
4212
- } catch (X) {
4213
- return console.error("HTML fallback failed:", X), b;
4211
+ return Es.sanitize(J);
4212
+ } catch (J) {
4213
+ return console.error("HTML fallback failed:", J), y;
4214
4214
  }
4215
4215
  }
4216
4216
  }
4217
- let _;
4218
- function T(b = !1) {
4219
- _ && _.scrollTo({
4220
- top: _.scrollHeight,
4221
- behavior: b ? "smooth" : "auto"
4217
+ let k;
4218
+ function T(y = !1) {
4219
+ k && k.scrollTo({
4220
+ top: k.scrollHeight,
4221
+ behavior: y ? "smooth" : "auto"
4222
4222
  });
4223
4223
  }
4224
4224
  Fi(() => {
4225
4225
  T(!1);
4226
4226
  });
4227
- let { zIndex: R } = e, { sessionId: L } = e, { hasScene: A } = e, { apiPrefix: w } = e, k = [], y = "";
4227
+ let { zIndex: R } = e, { sessionId: L } = e, { hasScene: A } = e, { apiPrefix: w } = e, _ = [], b = "";
4228
4228
  function v() {
4229
- return Ee(this, null, function* () {
4230
- var b;
4229
+ return Se(this, null, function* () {
4231
4230
  if (A)
4232
4231
  try {
4233
- const N = yield fetch(`${w}/chat/getSceneList`, {
4232
+ const y = yield fetch(`${w}/chat/getSceneList`, {
4234
4233
  headers: {
4235
4234
  "Auth-Token": `${de()}`,
4236
4235
  Authorization: `bearer ${de()}`
4237
4236
  }
4238
4237
  });
4239
- if (!N.ok) throw new Error("Failed to fetch scenes");
4240
- const X = yield N.json();
4241
- X.status === "success" && ((b = X.data) != null && b.sceneList) && (t(11, k = X.data.sceneList), k.length > 0 && t(12, y = k[0].code));
4242
- } catch (N) {
4243
- console.error("Failed to fetch scenes:", N);
4238
+ if (!y.ok) throw new Error("Failed to fetch scenes");
4239
+ const H = yield y.json();
4240
+ H.code === 0 && (t(11, _ = H.data.sceneList || []), _.length > 0 && t(12, b = _[0].code));
4241
+ } catch (y) {
4242
+ console.error("Failed to fetch scenes:", y);
4244
4243
  }
4245
4244
  });
4246
4245
  }
@@ -4248,30 +4247,30 @@ function _l(s, e, t) {
4248
4247
  v();
4249
4248
  });
4250
4249
  function x() {
4251
- return Ee(this, null, function* () {
4250
+ return Se(this, null, function* () {
4252
4251
  if (!l.trim() || o) return;
4253
4252
  if (!L) {
4254
4253
  console.error("No session ID available");
4255
4254
  return;
4256
4255
  }
4257
- const b = Date.now().toString(), N = Date.now().toString() + Math.random().toString().slice(2, 8), X = {
4256
+ const y = Date.now().toString(), H = Date.now().toString() + Math.random().toString().slice(2, 8), J = {
4258
4257
  sessionId: L,
4259
- requestId: N,
4260
- id: b,
4258
+ requestId: H,
4259
+ id: y,
4261
4260
  type: "user",
4262
4261
  content: l.trim(),
4263
4262
  timestamp: Date.now()
4264
4263
  };
4265
- t(5, i = [...i, X]);
4266
- const ce = l.trim();
4264
+ t(5, i = [...i, J]);
4265
+ const ae = l.trim();
4267
4266
  t(3, l = "");
4268
- const fe = (Date.now() + 1).toString();
4267
+ const ce = (Date.now() + 1).toString();
4269
4268
  r = "", t(5, i = [
4270
4269
  ...i,
4271
4270
  {
4272
4271
  sessionId: L,
4273
- requestId: N,
4274
- id: fe,
4272
+ requestId: H,
4273
+ id: ce,
4275
4274
  type: "assistant",
4276
4275
  content: "",
4277
4276
  timestamp: Date.now()
@@ -4287,41 +4286,41 @@ function _l(s, e, t) {
4287
4286
  },
4288
4287
  body: JSON.stringify({
4289
4288
  sessionId: L,
4290
- requestId: N,
4291
- keyword: ce,
4289
+ requestId: H,
4290
+ keyword: ae,
4292
4291
  flowId: "1",
4293
- extendKeys: A ? { sceneCode: y } : void 0
4292
+ extendKeys: A ? { sceneCode: b } : void 0
4294
4293
  }),
4295
4294
  signal: c.signal,
4296
- onmessage(ke) {
4295
+ onmessage(_e) {
4297
4296
  try {
4298
- const xe = ke.data;
4299
- if (xe) {
4300
- const Je = Zs(xe);
4301
- Je ? (t(5, i = i.map((Ue) => Ue.id === fe ? be(ie({}, Ue), { attachments: Je }) : Ue)), T(!0)) : (r += xe, t(5, i = i.map((Ue) => Ue.id === fe ? be(ie({}, Ue), { content: r }) : Ue)), T(!1));
4297
+ const we = _e.data;
4298
+ if (we) {
4299
+ const ht = Zs(we);
4300
+ ht ? (t(5, i = i.map((Ue) => Ue.id === ce ? ye(ie({}, Ue), { attachments: ht }) : Ue)), T(!0)) : (r += we, t(5, i = i.map((Ue) => Ue.id === ce ? ye(ie({}, Ue), { content: r }) : Ue)), T(!1));
4302
4301
  }
4303
- } catch (xe) {
4304
- console.error("Failed to process SSE message:", xe);
4302
+ } catch (we) {
4303
+ console.error("Failed to process SSE message:", we);
4305
4304
  }
4306
4305
  },
4307
- onerror(ke) {
4308
- console.error("SSE error:", ke), c = null, t(9, m = !1);
4306
+ onerror(_e) {
4307
+ console.error("SSE error:", _e), c = null, t(9, m = !1);
4309
4308
  },
4310
4309
  onclose() {
4311
4310
  c = null, t(9, m = !1);
4312
4311
  }
4313
4312
  });
4314
- } catch (ke) {
4315
- console.error("Failed to send message:", ke), t(9, m = !1);
4313
+ } catch (_e) {
4314
+ console.error("Failed to send message:", _e), t(9, m = !1);
4316
4315
  }
4317
4316
  });
4318
4317
  }
4319
- function M(b, N, X) {
4320
- const ce = X.getBoundingClientRect(), fe = _.getBoundingClientRect(), ke = ce.left < fe.width / 2;
4321
- t(6, u = N), t(7, h = {
4322
- x: ce.left,
4323
- y: ce.top + ce.height / 2,
4324
- alignRight: ke
4318
+ function M(y, H, J) {
4319
+ const ae = J.getBoundingClientRect(), ce = k.getBoundingClientRect(), _e = ae.left < ce.width / 2;
4320
+ t(6, u = H), t(7, h = {
4321
+ x: ae.left,
4322
+ y: ae.top + ae.height / 2,
4323
+ alignRight: _e
4325
4324
  });
4326
4325
  }
4327
4326
  function z() {
@@ -4335,56 +4334,56 @@ function _l(s, e, t) {
4335
4334
  Hi(() => {
4336
4335
  c && c.abort(), p && clearTimeout(p);
4337
4336
  });
4338
- function Z(b, N) {
4339
- return Ee(this, null, function* () {
4337
+ function Z(y, H) {
4338
+ return Se(this, null, function* () {
4340
4339
  try {
4341
- const X = yield fetch(`${w}/file/downloadFile`, {
4340
+ const J = yield fetch(`${w}/file/downloadFile`, {
4342
4341
  method: "POST",
4343
4342
  headers: {
4344
4343
  "Content-Type": "application/json",
4345
4344
  "Auth-Token": `${de()}`,
4346
4345
  Authorization: `bearer ${de()}`
4347
4346
  },
4348
- body: JSON.stringify({ fileName: b, fileUrl: N })
4347
+ body: JSON.stringify({ fileName: y, fileUrl: H })
4349
4348
  });
4350
- if (!X.ok)
4349
+ if (!J.ok)
4351
4350
  throw new Error("Download failed");
4352
- const ce = X.headers.get("content-type") || "application/octet-stream", fe = yield X.blob(), ke = window.URL.createObjectURL(fe), xe = document.createElement("a");
4353
- xe.href = ke, xe.download = b, document.body.appendChild(xe), xe.click(), window.URL.revokeObjectURL(ke), document.body.removeChild(xe);
4354
- } catch (X) {
4355
- console.error("Failed to download file:", X);
4351
+ const ae = J.headers.get("content-type") || "application/octet-stream", ce = yield J.blob(), _e = window.URL.createObjectURL(ce), we = document.createElement("a");
4352
+ we.href = _e, we.download = y, document.body.appendChild(we), we.click(), window.URL.revokeObjectURL(_e), document.body.removeChild(we);
4353
+ } catch (J) {
4354
+ console.error("Failed to download file:", J);
4356
4355
  }
4357
4356
  });
4358
4357
  }
4359
4358
  let B = {};
4360
- function I(b, N) {
4361
- return Ee(this, null, function* () {
4359
+ function I(y, H) {
4360
+ return Se(this, null, function* () {
4362
4361
  try {
4363
- const X = N.replace(/<br\s*\/?>/g, `
4362
+ const J = H.replace(/<br\s*\/?>/g, `
4364
4363
  `).replace(
4365
4364
  /\*\*(.*?)\*\*/g,
4366
4365
  "$1"
4367
4366
  // 移除加粗标记
4368
4367
  ).replace(/###/g, "").trim();
4369
- yield navigator.clipboard.writeText(X), t(13, B[b] = !0, B), setTimeout(
4368
+ yield navigator.clipboard.writeText(J), t(13, B[y] = !0, B), setTimeout(
4370
4369
  () => {
4371
- t(13, B[b] = !1, B), t(13, B);
4370
+ t(13, B[y] = !1, B), t(13, B);
4372
4371
  },
4373
4372
  1500
4374
4373
  );
4375
- } catch (X) {
4376
- console.error("Failed to copy:", X);
4374
+ } catch (J) {
4375
+ console.error("Failed to copy:", J);
4377
4376
  }
4378
4377
  });
4379
4378
  }
4380
- let C = {}, U = {}, V = !1;
4381
- function ne(b, N) {
4382
- return Ee(this, null, function* () {
4383
- if (C[b] === N) {
4384
- t(14, C[b] = null, C), t(14, C);
4379
+ let C = {}, U = {}, X = !1;
4380
+ function ne(y, H) {
4381
+ return Se(this, null, function* () {
4382
+ if (C[y] === H) {
4383
+ t(14, C[y] = null, C), t(14, C);
4385
4384
  return;
4386
4385
  }
4387
- if (t(14, C[b] = N, C), t(14, C), N === "like")
4386
+ if (t(14, C[y] = H, C), t(14, C), H === "like")
4388
4387
  try {
4389
4388
  if (!(yield fetch(`${w}/chat/record/feedback`, {
4390
4389
  method: "POST",
@@ -4395,23 +4394,23 @@ function _l(s, e, t) {
4395
4394
  },
4396
4395
  body: JSON.stringify({
4397
4396
  sessionId: L,
4398
- requestId: b,
4397
+ requestId: y,
4399
4398
  feedBackFlag: "1",
4400
4399
  feedBackContent: "点赞"
4401
4400
  })
4402
4401
  })).ok)
4403
4402
  throw new Error("Feedback failed");
4404
- } catch (X) {
4405
- console.error("Failed to send feedback:", X), t(14, C[b] = null, C), t(14, C);
4403
+ } catch (J) {
4404
+ console.error("Failed to send feedback:", J), t(14, C[y] = null, C), t(14, C);
4406
4405
  }
4407
4406
  else
4408
- t(16, V = !0);
4407
+ t(16, X = !0);
4409
4408
  });
4410
4409
  }
4411
- function he(b) {
4412
- return Ee(this, null, function* () {
4413
- var N;
4414
- if ((N = U[b]) != null && N.trim())
4410
+ function he(y) {
4411
+ return Se(this, null, function* () {
4412
+ var H;
4413
+ if ((H = U[y]) != null && H.trim())
4415
4414
  try {
4416
4415
  if (!(yield fetch(`${w}/chat/record/feedback`, {
4417
4416
  method: "POST",
@@ -4422,92 +4421,92 @@ function _l(s, e, t) {
4422
4421
  },
4423
4422
  body: JSON.stringify({
4424
4423
  sessionId: L,
4425
- requestId: b,
4424
+ requestId: y,
4426
4425
  feedBackFlag: "0",
4427
- feedBackContent: U[b]
4426
+ feedBackContent: U[y]
4428
4427
  })
4429
4428
  })).ok)
4430
4429
  throw new Error("Feedback failed");
4431
- t(16, V = !1), t(15, U[b] = "", U), t(15, U);
4432
- } catch (X) {
4433
- console.error("Failed to send feedback:", X), t(14, C[b] = null, C), t(14, C);
4430
+ t(16, X = !1), t(15, U[y] = "", U), t(15, U);
4431
+ } catch (J) {
4432
+ console.error("Failed to send feedback:", J), t(14, C[y] = null, C), t(14, C);
4434
4433
  }
4435
4434
  });
4436
4435
  }
4437
4436
  let He = { x: 0, y: 0 };
4438
- function ue(b, N) {
4439
- const ce = b.currentTarget.getBoundingClientRect();
4437
+ function fe(y, H) {
4438
+ const ae = y.currentTarget.getBoundingClientRect();
4440
4439
  t(17, He = {
4441
- x: ce.left - 290,
4440
+ x: ae.left - 290,
4442
4441
  // 弹框宽度 + 间距
4443
- y: ce.top - 160
4442
+ y: ae.top - 160
4444
4443
  // 弹框高度 + 间距
4445
- }), ne(N, "dislike");
4444
+ }), ne(H, "dislike");
4446
4445
  }
4447
4446
  let Be = null;
4448
- function ee(b, N) {
4449
- const ce = b.currentTarget.getBoundingClientRect();
4447
+ function ee(y, H) {
4448
+ const ae = y.currentTarget.getBoundingClientRect();
4450
4449
  t(18, Be = {
4451
- text: N,
4452
- x: ce.left + ce.width / 2,
4453
- y: ce.top - 8
4450
+ text: H,
4451
+ x: ae.left + ae.width / 2,
4452
+ y: ae.top - 8
4454
4453
  });
4455
4454
  }
4456
4455
  function qe() {
4457
4456
  t(18, Be = null);
4458
4457
  }
4459
- let se = !1, Ae = [], K = Date.now().toString();
4458
+ let se = !1, xe = [], K = Date.now().toString();
4460
4459
  function Le() {
4461
4460
  qe(), t(19, se = !0);
4462
4461
  }
4463
- function Te() {
4462
+ function ve() {
4464
4463
  qe(), t(19, se = !1);
4465
4464
  }
4466
- function Qe(b) {
4467
- return Ee(this, null, function* () {
4465
+ function Qe(y) {
4466
+ return Se(this, null, function* () {
4468
4467
  if (!m) {
4469
4468
  t(9, m = !0);
4470
4469
  try {
4471
- const N = yield fetch(`${w}/chat/record/session/detail/query`, {
4470
+ const H = yield fetch(`${w}/chat/record/session/detail/query`, {
4472
4471
  method: "POST",
4473
4472
  headers: {
4474
4473
  "Content-Type": "application/json",
4475
4474
  "Auth-Token": `${de()}`,
4476
4475
  Authorization: `bearer ${de()}`
4477
4476
  },
4478
- body: JSON.stringify({ sessionId: b })
4477
+ body: JSON.stringify({ sessionId: y })
4479
4478
  });
4480
- if (!N.ok)
4479
+ if (!H.ok)
4481
4480
  throw new Error("Failed to load sessions");
4482
- const X = yield N.json();
4483
- if (X.code === 0) {
4484
- K = b, t(19, se = !1);
4485
- const ce = X.data.map((fe, ke) => {
4486
- const xe = Zs(fe.answer), Je = gl(fe.answer);
4481
+ const J = yield H.json();
4482
+ if (J.code === 0) {
4483
+ K = y, t(19, se = !1);
4484
+ const ae = J.data.map((ce, _e) => {
4485
+ const we = Zs(ce.answer), ht = gl(ce.answer);
4487
4486
  return [
4488
4487
  {
4489
- sessionId: fe.sessionId,
4490
- requestId: fe.requestId,
4491
- id: (Date.now() + 2 * ke).toString(),
4488
+ sessionId: ce.sessionId,
4489
+ requestId: ce.requestId,
4490
+ id: (Date.now() + 2 * _e).toString(),
4492
4491
  type: "user",
4493
- content: fe.keyword,
4494
- timestamp: new Date(fe.createDate).getTime()
4492
+ content: ce.keyword,
4493
+ timestamp: new Date(ce.createDate).getTime()
4495
4494
  },
4496
4495
  {
4497
- sessionId: fe.sessionId,
4498
- requestId: fe.requestId,
4499
- id: (Date.now() + 2 * ke + 1).toString(),
4496
+ sessionId: ce.sessionId,
4497
+ requestId: ce.requestId,
4498
+ id: (Date.now() + 2 * _e + 1).toString(),
4500
4499
  type: "assistant",
4501
- content: Je,
4502
- attachments: xe,
4503
- timestamp: new Date(fe.createDate).getTime()
4500
+ content: ht,
4501
+ attachments: we,
4502
+ timestamp: new Date(ce.createDate).getTime()
4504
4503
  }
4505
4504
  ];
4506
4505
  });
4507
- t(5, i = ce.flat());
4506
+ t(5, i = ae.flat());
4508
4507
  }
4509
- } catch (N) {
4510
- console.error("Failed to load sessions:", N);
4508
+ } catch (H) {
4509
+ console.error("Failed to load sessions:", H);
4511
4510
  } finally {
4512
4511
  t(9, m = !1);
4513
4512
  }
@@ -4515,13 +4514,13 @@ function _l(s, e, t) {
4515
4514
  });
4516
4515
  }
4517
4516
  function P() {
4518
- return Ee(this, null, function* () {
4519
- const b = yield le();
4520
- if (!b) {
4517
+ return Se(this, null, function* () {
4518
+ const y = yield le();
4519
+ if (!y) {
4521
4520
  console.error("Failed to create new session");
4522
4521
  return;
4523
4522
  }
4524
- K = b, t(5, i = [
4523
+ K = y, t(5, i = [
4525
4524
  {
4526
4525
  sessionId: K,
4527
4526
  requestId: "",
@@ -4534,9 +4533,9 @@ function _l(s, e, t) {
4534
4533
  });
4535
4534
  }
4536
4535
  function le() {
4537
- return Ee(this, null, function* () {
4536
+ return Se(this, null, function* () {
4538
4537
  try {
4539
- const b = yield fetch(`${w}/chat/getSessionId`, {
4538
+ const y = yield fetch(`${w}/chat/getSessionId`, {
4540
4539
  method: "POST",
4541
4540
  headers: {
4542
4541
  "Content-Type": "application/json",
@@ -4544,48 +4543,43 @@ function _l(s, e, t) {
4544
4543
  Authorization: `bearer ${de()}`
4545
4544
  }
4546
4545
  });
4547
- if (!b.ok)
4546
+ if (!y.ok)
4548
4547
  throw new Error("Failed to get session ID");
4549
- const N = yield b.json();
4550
- if (N.code === 0)
4551
- return K = N.data.sessionId, K;
4552
- throw new Error(N.message || "Failed to get session ID");
4553
- } catch (b) {
4554
- return console.error("Failed to get session ID:", b), null;
4548
+ const H = yield y.json();
4549
+ if (H.code === 0)
4550
+ return K = H.data.sessionId, K;
4551
+ throw new Error(H.message || "Failed to get session ID");
4552
+ } catch (y) {
4553
+ return console.error("Failed to get session ID:", y), null;
4555
4554
  }
4556
4555
  });
4557
4556
  }
4558
- const D = (b, N) => M(N, b.tips, N.currentTarget), q = (b) => Z(b.content_title, b.link), me = () => {
4557
+ const D = (y, H) => M(H, y.tips, H.currentTarget), q = (y) => Z(y.content_title, y.link), me = () => {
4559
4558
  p && (clearTimeout(p), t(8, p = null));
4560
4559
  }, ge = () => {
4561
4560
  t(6, u = null);
4562
- }, Me = (b) => I(b.id, b.content), De = (b, N) => ee(N, B[b.id] ? "已复制" : "复制内容"), et = (b) => ne(b.id, "like"), ft = (b, N) => ee(N, C[b.id] === "like" ? "取消点赞" : "点赞"), ht = (b, N) => ue(N, b.id), Pt = (b, N) => ee(N, C[b.id] === "dislike" ? "取消点踩" : "点踩");
4563
- function Nt(b) {
4564
- U[b.id] = this.value, t(15, U);
4565
- }
4566
- const rn = (b) => {
4567
- t(16, V = !1), t(14, C[b.id] = null, C), t(14, C);
4568
- }, bt = (b) => he(b.id);
4569
- function ot(b) {
4570
- wt[b ? "unshift" : "push"](() => {
4571
- _ = b, t(10, _);
4561
+ }, Me = (y) => I(y.id, y.content), De = (y, H) => ee(H, B[y.id] ? "已复制" : "复制内容"), $e = (y) => ne(y.id, "like"), ut = (y, H) => ee(H, C[y.id] === "like" ? "取消点赞" : "点赞"), ft = (y, H) => fe(H, y.id), Pt = (y, H) => ee(H, C[y.id] === "dislike" ? "取消点踩" : "点踩");
4562
+ function Nt(y) {
4563
+ U[y.id] = this.value, t(15, U);
4564
+ }
4565
+ const rn = (y) => {
4566
+ t(16, X = !1), t(14, C[y.id] = null, C), t(14, C);
4567
+ }, wt = (y) => he(y.id);
4568
+ function it(y) {
4569
+ zt[y ? "unshift" : "push"](() => {
4570
+ k = y, t(10, k);
4572
4571
  });
4573
4572
  }
4574
- function tt() {
4575
- y = Ni(this), t(12, y), t(11, k);
4573
+ function et() {
4574
+ b = Ni(this), t(12, b), t(11, _);
4576
4575
  }
4577
- const nt = (b) => ee(b, "历史会话"), Ft = (b) => ee(b, "新建会话");
4576
+ const tt = (y) => ee(y, "历史会话"), Ft = (y) => ee(y, "新建会话");
4578
4577
  function Ht() {
4579
4578
  l = this.value, t(3, l);
4580
4579
  }
4581
- const Bt = (b) => b.key === "Enter" && !b.shiftKey && (x(), b.preventDefault()), yt = (b) => ee(b, "发送消息");
4582
- function Ut(b) {
4583
- wt[b ? "unshift" : "push"](() => {
4584
- _ = b, t(10, _);
4585
- });
4586
- }
4587
- return s.$$set = (b) => {
4588
- "zIndex" in b && t(0, R = b.zIndex), "sessionId" in b && t(37, L = b.sessionId), "hasScene" in b && t(1, A = b.hasScene), "apiPrefix" in b && t(2, w = b.apiPrefix);
4580
+ const Bt = (y) => y.key === "Enter" && !y.shiftKey && (x(), y.preventDefault()), bt = (y) => ee(y, "发送消息");
4581
+ return s.$$set = (y) => {
4582
+ "zIndex" in y && t(0, R = y.zIndex), "sessionId" in y && t(37, L = y.sessionId), "hasScene" in y && t(1, A = y.hasScene), "apiPrefix" in y && t(2, w = y.apiPrefix);
4589
4583
  }, s.$$.update = () => {
4590
4584
  s.$$.dirty[0] & /*message*/
4591
4585
  8 && t(4, n = l.length), s.$$.dirty[0] & /*messageLength*/
@@ -4601,13 +4595,13 @@ function _l(s, e, t) {
4601
4595
  h,
4602
4596
  p,
4603
4597
  m,
4604
- _,
4605
4598
  k,
4606
- y,
4599
+ _,
4600
+ b,
4607
4601
  B,
4608
4602
  C,
4609
4603
  U,
4610
- V,
4604
+ X,
4611
4605
  He,
4612
4606
  Be,
4613
4607
  se,
@@ -4620,12 +4614,12 @@ function _l(s, e, t) {
4620
4614
  I,
4621
4615
  ne,
4622
4616
  he,
4623
- ue,
4617
+ fe,
4624
4618
  ee,
4625
4619
  qe,
4626
- Ae,
4620
+ xe,
4627
4621
  Le,
4628
- Te,
4622
+ ve,
4629
4623
  Qe,
4630
4624
  P,
4631
4625
  L,
@@ -4635,29 +4629,28 @@ function _l(s, e, t) {
4635
4629
  ge,
4636
4630
  Me,
4637
4631
  De,
4638
- et,
4632
+ $e,
4633
+ ut,
4639
4634
  ft,
4640
- ht,
4641
4635
  Pt,
4642
4636
  Nt,
4643
4637
  rn,
4644
- bt,
4645
- ot,
4638
+ wt,
4639
+ it,
4640
+ et,
4646
4641
  tt,
4647
- nt,
4648
4642
  Ft,
4649
4643
  Ht,
4650
4644
  Bt,
4651
- yt,
4652
- Ut
4645
+ bt
4653
4646
  ];
4654
4647
  }
4655
- class kl extends On {
4648
+ class _l extends On {
4656
4649
  constructor(e) {
4657
4650
  super(), zn(
4658
4651
  this,
4659
4652
  e,
4660
- _l,
4653
+ kl,
4661
4654
  ml,
4662
4655
  tn,
4663
4656
  {
@@ -4675,28 +4668,28 @@ function Xs(s) {
4675
4668
  let e, t, n, o, l = (
4676
4669
  /*mergedOptions*/
4677
4670
  s[3].title + ""
4678
- ), i, r, c, u, h, p, m, g, _, T = (
4671
+ ), i, r, c, u, h, p, m, g, k, T = (
4679
4672
  /*isFullscreen*/
4680
4673
  s[2] ? "退出全屏" : "全屏显示"
4681
- ), R, L, A, w, k, y, v, x, M = (
4674
+ ), R, L, A, w, _, b, v, x, M = (
4682
4675
  /*isSnapped*/
4683
4676
  s[7] ? "取消吸附" : "吸附到边缘"
4684
- ), z, Z, B, I, C, U, V, ne, he, He = `${/*mergedOptions*/
4685
- s[3].height}px`, ue, Be, ee;
4677
+ ), z, Z, B, I, C, U, X, ne, he, He = `${/*mergedOptions*/
4678
+ s[3].height}px`, fe, Be, ee;
4686
4679
  function qe(D, q) {
4687
4680
  return (
4688
4681
  /*isFullscreen*/
4689
4682
  D[2] ? bl : wl
4690
4683
  );
4691
4684
  }
4692
- let se = qe(s), Ae = se(s);
4685
+ let se = qe(s), xe = se(s);
4693
4686
  function K(D, q) {
4694
4687
  return (
4695
4688
  /*isSnapped*/
4696
4689
  D[7] ? Tl : yl
4697
4690
  );
4698
4691
  }
4699
- let Le = K(s), Te = Le(s);
4692
+ let Le = K(s), ve = Le(s);
4700
4693
  const Qe = [El, vl], P = [];
4701
4694
  function le(D, q) {
4702
4695
  return (
@@ -4707,29 +4700,29 @@ function Xs(s) {
4707
4700
  return ne = le(s), he = P[ne] = Qe[ne](s), {
4708
4701
  c() {
4709
4702
  var D, q, me;
4710
- e = S("div"), t = S("div"), n = S("div"), o = S("h3"), i = ye(l), r = j(), c = S("div"), u = S("div"), h = S("button"), p = J("svg"), Ae.c(), g = j(), _ = S("span"), R = ye(T), L = j(), A = S("div"), w = S("button"), k = J("svg"), Te.c(), v = j(), x = S("span"), z = ye(M), Z = j(), B = S("div"), I = S("button"), I.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="18" y1="6" x2="6" y2="18"></line><line x1="6" y1="6" x2="18" y2="18"></line></svg>', C = j(), U = S("span"), U.textContent = "关闭助手", V = j(), he.c(), a(o, "class", "svelte-1427avp"), a(p, "xmlns", "http://www.w3.org/2000/svg"), a(p, "width", "18"), a(p, "height", "18"), a(p, "viewBox", "0 0 24 24"), a(p, "fill", "none"), a(p, "stroke", "currentColor"), a(p, "stroke-width", "2"), a(p, "stroke-linecap", "round"), a(p, "stroke-linejoin", "round"), a(h, "class", "sy-assistant-action-button svelte-1427avp"), a(h, "aria-label", m = /*isFullscreen*/
4703
+ e = S("div"), t = S("div"), n = S("div"), o = S("h3"), i = Te(l), r = j(), c = S("div"), u = S("div"), h = S("button"), p = Q("svg"), xe.c(), g = j(), k = S("span"), R = Te(T), L = j(), A = S("div"), w = S("button"), _ = Q("svg"), ve.c(), v = j(), x = S("span"), z = Te(M), Z = j(), B = S("div"), I = S("button"), I.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="20" height="20" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><line x1="18" y1="6" x2="6" y2="18"></line><line x1="6" y1="6" x2="18" y2="18"></line></svg>', C = j(), U = S("span"), U.textContent = "关闭助手", X = j(), he.c(), a(o, "class", "svelte-1427avp"), a(p, "xmlns", "http://www.w3.org/2000/svg"), a(p, "width", "18"), a(p, "height", "18"), a(p, "viewBox", "0 0 24 24"), a(p, "fill", "none"), a(p, "stroke", "currentColor"), a(p, "stroke-width", "2"), a(p, "stroke-linecap", "round"), a(p, "stroke-linejoin", "round"), a(h, "class", "sy-assistant-action-button svelte-1427avp"), a(h, "aria-label", m = /*isFullscreen*/
4711
4704
  s[2] ? "退出全屏" : "全屏显示"), $(
4712
4705
  h,
4713
4706
  "active",
4714
4707
  /*isFullscreen*/
4715
4708
  s[2]
4716
- ), a(_, "class", "sy-assistant-tooltip svelte-1427avp"), F(
4717
- _,
4709
+ ), a(k, "class", "sy-assistant-tooltip svelte-1427avp"), N(
4710
+ k,
4718
4711
  "z-index",
4719
4712
  /*mergedOptions*/
4720
4713
  ((D = s[3].zIndex) != null ? D : 1e3) + 3
4721
- ), a(u, "class", "sy-assistant-tooltip-wrapper svelte-1427avp"), a(k, "xmlns", "http://www.w3.org/2000/svg"), a(k, "width", "18"), a(k, "height", "18"), a(k, "viewBox", "0 0 24 24"), a(k, "fill", "none"), a(k, "stroke", "currentColor"), a(k, "stroke-width", "2"), a(k, "stroke-linecap", "round"), a(k, "stroke-linejoin", "round"), a(w, "class", "sy-assistant-action-button svelte-1427avp"), a(w, "aria-label", y = /*isSnapped*/
4714
+ ), a(u, "class", "sy-assistant-tooltip-wrapper svelte-1427avp"), a(_, "xmlns", "http://www.w3.org/2000/svg"), a(_, "width", "18"), a(_, "height", "18"), a(_, "viewBox", "0 0 24 24"), a(_, "fill", "none"), a(_, "stroke", "currentColor"), a(_, "stroke-width", "2"), a(_, "stroke-linecap", "round"), a(_, "stroke-linejoin", "round"), a(w, "class", "sy-assistant-action-button svelte-1427avp"), a(w, "aria-label", b = /*isSnapped*/
4722
4715
  s[7] ? "取消吸附" : "吸附到边缘"), $(
4723
4716
  w,
4724
4717
  "active",
4725
4718
  /*isSnapped*/
4726
4719
  s[7]
4727
- ), a(x, "class", "sy-assistant-tooltip svelte-1427avp"), F(
4720
+ ), a(x, "class", "sy-assistant-tooltip svelte-1427avp"), N(
4728
4721
  x,
4729
4722
  "z-index",
4730
4723
  /*mergedOptions*/
4731
4724
  ((q = s[3].zIndex) != null ? q : 1e3) + 3
4732
- ), a(A, "class", "sy-assistant-tooltip-wrapper svelte-1427avp"), a(I, "class", "sy-assistant-close-button svelte-1427avp"), a(I, "aria-label", "关闭助手"), a(U, "class", "sy-assistant-tooltip svelte-1427avp"), F(
4725
+ ), a(A, "class", "sy-assistant-tooltip-wrapper svelte-1427avp"), a(I, "class", "sy-assistant-close-button svelte-1427avp"), a(I, "aria-label", "关闭助手"), a(U, "class", "sy-assistant-tooltip svelte-1427avp"), N(
4733
4726
  U,
4734
4727
  "z-index",
4735
4728
  /*mergedOptions*/
@@ -4754,10 +4747,10 @@ function Xs(s) {
4754
4747
  "fullscreen",
4755
4748
  /*isFullscreen*/
4756
4749
  s[2]
4757
- ), F(e, "height", He);
4750
+ ), N(e, "height", He);
4758
4751
  },
4759
4752
  m(D, q) {
4760
- Y(D, e, q), d(e, t), d(t, n), d(n, o), d(o, i), d(n, r), d(n, c), d(c, u), d(u, h), d(h, p), Ae.m(p, null), d(u, g), d(u, _), d(_, R), d(c, L), d(c, A), d(A, w), d(w, k), Te.m(k, null), d(A, v), d(A, x), d(x, z), d(c, Z), d(c, B), d(B, I), d(B, C), d(B, U), d(t, V), P[ne].m(t, null), ue = !0, Be || (ee = [
4753
+ Y(D, e, q), d(e, t), d(t, n), d(n, o), d(o, i), d(n, r), d(n, c), d(c, u), d(u, h), d(h, p), xe.m(p, null), d(u, g), d(u, k), d(k, R), d(c, L), d(c, A), d(A, w), d(w, _), ve.m(_, null), d(A, v), d(A, x), d(x, z), d(c, Z), d(c, B), d(B, I), d(B, C), d(B, U), d(t, X), P[ne].m(t, null), fe = !0, Be || (ee = [
4761
4754
  G(
4762
4755
  h,
4763
4756
  "click",
@@ -4784,59 +4777,59 @@ function Xs(s) {
4784
4777
  },
4785
4778
  p(D, q) {
4786
4779
  var ge, Me, De;
4787
- (!ue || q[0] & /*mergedOptions*/
4780
+ (!fe || q[0] & /*mergedOptions*/
4788
4781
  8) && l !== (l = /*mergedOptions*/
4789
- D[3].title + "") && Ne(i, l), se !== (se = qe(D)) && (Ae.d(1), Ae = se(D), Ae && (Ae.c(), Ae.m(p, null))), (!ue || q[0] & /*isFullscreen*/
4782
+ D[3].title + "") && Ne(i, l), se !== (se = qe(D)) && (xe.d(1), xe = se(D), xe && (xe.c(), xe.m(p, null))), (!fe || q[0] & /*isFullscreen*/
4790
4783
  4 && m !== (m = /*isFullscreen*/
4791
- D[2] ? "退出全屏" : "全屏显示")) && a(h, "aria-label", m), (!ue || q[0] & /*isFullscreen*/
4784
+ D[2] ? "退出全屏" : "全屏显示")) && a(h, "aria-label", m), (!fe || q[0] & /*isFullscreen*/
4792
4785
  4) && $(
4793
4786
  h,
4794
4787
  "active",
4795
4788
  /*isFullscreen*/
4796
4789
  D[2]
4797
- ), (!ue || q[0] & /*isFullscreen*/
4790
+ ), (!fe || q[0] & /*isFullscreen*/
4798
4791
  4) && T !== (T = /*isFullscreen*/
4799
4792
  D[2] ? "退出全屏" : "全屏显示") && Ne(R, T), q[0] & /*mergedOptions*/
4800
- 8 && F(
4801
- _,
4793
+ 8 && N(
4794
+ k,
4802
4795
  "z-index",
4803
4796
  /*mergedOptions*/
4804
4797
  ((ge = D[3].zIndex) != null ? ge : 1e3) + 3
4805
- ), Le !== (Le = K(D)) && (Te.d(1), Te = Le(D), Te && (Te.c(), Te.m(k, null))), (!ue || q[0] & /*isSnapped*/
4806
- 128 && y !== (y = /*isSnapped*/
4807
- D[7] ? "取消吸附" : "吸附到边缘")) && a(w, "aria-label", y), (!ue || q[0] & /*isSnapped*/
4798
+ ), Le !== (Le = K(D)) && (ve.d(1), ve = Le(D), ve && (ve.c(), ve.m(_, null))), (!fe || q[0] & /*isSnapped*/
4799
+ 128 && b !== (b = /*isSnapped*/
4800
+ D[7] ? "取消吸附" : "吸附到边缘")) && a(w, "aria-label", b), (!fe || q[0] & /*isSnapped*/
4808
4801
  128) && $(
4809
4802
  w,
4810
4803
  "active",
4811
4804
  /*isSnapped*/
4812
4805
  D[7]
4813
- ), (!ue || q[0] & /*isSnapped*/
4806
+ ), (!fe || q[0] & /*isSnapped*/
4814
4807
  128) && M !== (M = /*isSnapped*/
4815
4808
  D[7] ? "取消吸附" : "吸附到边缘") && Ne(z, M), q[0] & /*mergedOptions*/
4816
- 8 && F(
4809
+ 8 && N(
4817
4810
  x,
4818
4811
  "z-index",
4819
4812
  /*mergedOptions*/
4820
4813
  ((Me = D[3].zIndex) != null ? Me : 1e3) + 3
4821
4814
  ), q[0] & /*mergedOptions*/
4822
- 8 && F(
4815
+ 8 && N(
4823
4816
  U,
4824
4817
  "z-index",
4825
4818
  /*mergedOptions*/
4826
4819
  ((De = D[3].zIndex) != null ? De : 1e3) + 3
4827
- ), (!ue || q[0] & /*isDragging*/
4820
+ ), (!fe || q[0] & /*isDragging*/
4828
4821
  64) && $(
4829
4822
  n,
4830
4823
  "dragging",
4831
4824
  /*isDragging*/
4832
4825
  D[6]
4833
- ), (!ue || q[0] & /*isFullscreen*/
4826
+ ), (!fe || q[0] & /*isFullscreen*/
4834
4827
  4) && $(
4835
4828
  n,
4836
4829
  "fullscreen",
4837
4830
  /*isFullscreen*/
4838
4831
  D[2]
4839
- ), (!ue || q[0] & /*isSnapped*/
4832
+ ), (!fe || q[0] & /*isSnapped*/
4840
4833
  128) && $(
4841
4834
  n,
4842
4835
  "snapped",
@@ -4844,9 +4837,9 @@ function Xs(s) {
4844
4837
  D[7]
4845
4838
  );
4846
4839
  let me = ne;
4847
- ne = le(D), ne === me ? P[ne].p(D, q) : (Cn(), $e(P[me], 1, 1, () => {
4840
+ ne = le(D), ne === me ? P[ne].p(D, q) : (Cn(), Ke(P[me], 1, 1, () => {
4848
4841
  P[me] = null;
4849
- }), Ln(), he = P[ne], he ? he.p(D, q) : (he = P[ne] = Qe[ne](D), he.c()), je(he, 1), he.m(t, null)), (!ue || q[0] & /*isFullscreen*/
4842
+ }), Ln(), he = P[ne], he ? he.p(D, q) : (he = P[ne] = Qe[ne](D), he.c()), je(he, 1), he.m(t, null)), (!fe || q[0] & /*isFullscreen*/
4850
4843
  4) && $(
4851
4844
  e,
4852
4845
  "fullscreen",
@@ -4854,16 +4847,16 @@ function Xs(s) {
4854
4847
  D[2]
4855
4848
  ), q[0] & /*mergedOptions*/
4856
4849
  8 && He !== (He = `${/*mergedOptions*/
4857
- D[3].height}px`) && F(e, "height", He);
4850
+ D[3].height}px`) && N(e, "height", He);
4858
4851
  },
4859
4852
  i(D) {
4860
- ue || (je(he), ue = !0);
4853
+ fe || (je(he), fe = !0);
4861
4854
  },
4862
4855
  o(D) {
4863
- $e(he), ue = !1;
4856
+ Ke(he), fe = !1;
4864
4857
  },
4865
4858
  d(D) {
4866
- D && W(e), Ae.d(), Te.d(), P[ne].d(), Be = !1, Se(ee);
4859
+ D && W(e), xe.d(), ve.d(), P[ne].d(), Be = !1, Ae(ee);
4867
4860
  }
4868
4861
  };
4869
4862
  }
@@ -4871,7 +4864,7 @@ function wl(s) {
4871
4864
  let e;
4872
4865
  return {
4873
4866
  c() {
4874
- e = J("path"), a(e, "d", "M8 3H5a2 2 0 0 0-2 2v3m18 0V5a2 2 0 0 0-2-2h-3m0 18h3a2 2 0 0 0 2-2v-3M3 16v3a2 2 0 0 0 2 2h3");
4867
+ e = Q("path"), a(e, "d", "M8 3H5a2 2 0 0 0-2 2v3m18 0V5a2 2 0 0 0-2-2h-3m0 18h3a2 2 0 0 0 2-2v-3M3 16v3a2 2 0 0 0 2 2h3");
4875
4868
  },
4876
4869
  m(t, n) {
4877
4870
  Y(t, e, n);
@@ -4885,7 +4878,7 @@ function bl(s) {
4885
4878
  let e;
4886
4879
  return {
4887
4880
  c() {
4888
- e = J("path"), a(e, "d", "M8 3v3a2 2 0 0 1-2 2H3m18 0h-3a2 2 0 0 1-2-2V3m0 18v-3a2 2 0 0 1 2-2h3M3 16h3a2 2 0 0 1 2 2v3");
4881
+ e = Q("path"), a(e, "d", "M8 3v3a2 2 0 0 1-2 2H3m18 0h-3a2 2 0 0 1-2-2V3m0 18v-3a2 2 0 0 1 2-2h3M3 16h3a2 2 0 0 1 2 2v3");
4889
4882
  },
4890
4883
  m(t, n) {
4891
4884
  Y(t, e, n);
@@ -4899,7 +4892,7 @@ function yl(s) {
4899
4892
  let e, t;
4900
4893
  return {
4901
4894
  c() {
4902
- e = J("rect"), t = J("line"), a(e, "x", "3"), a(e, "y", "3"), a(e, "width", "18"), a(e, "height", "18"), a(e, "rx", "2"), a(e, "ry", "2"), a(t, "x1", "16"), a(t, "y1", "6"), a(t, "x2", "16"), a(t, "y2", "18");
4895
+ e = Q("rect"), t = Q("line"), a(e, "x", "3"), a(e, "y", "3"), a(e, "width", "18"), a(e, "height", "18"), a(e, "rx", "2"), a(e, "ry", "2"), a(t, "x1", "16"), a(t, "y1", "6"), a(t, "x2", "16"), a(t, "y2", "18");
4903
4896
  },
4904
4897
  m(n, o) {
4905
4898
  Y(n, e, o), Y(n, t, o);
@@ -4913,7 +4906,7 @@ function Tl(s) {
4913
4906
  let e, t;
4914
4907
  return {
4915
4908
  c() {
4916
- e = J("rect"), t = J("rect"), a(e, "x", "3"), a(e, "y", "3"), a(e, "width", "18"), a(e, "height", "18"), a(e, "rx", "2"), a(e, "ry", "2"), a(t, "x", "12"), a(t, "y", "10"), a(t, "width", "6"), a(t, "height", "8"), a(t, "rx", "1"), a(t, "ry", "1");
4909
+ e = Q("rect"), t = Q("rect"), a(e, "x", "3"), a(e, "y", "3"), a(e, "width", "18"), a(e, "height", "18"), a(e, "rx", "2"), a(e, "ry", "2"), a(t, "x", "12"), a(t, "y", "10"), a(t, "width", "6"), a(t, "height", "8"), a(t, "rx", "1"), a(t, "ry", "1");
4917
4910
  },
4918
4911
  m(n, o) {
4919
4912
  Y(n, e, o), Y(n, t, o);
@@ -4926,7 +4919,7 @@ function Tl(s) {
4926
4919
  function vl(s) {
4927
4920
  var n, o, l;
4928
4921
  let e, t;
4929
- return e = new kl({
4922
+ return e = new _l({
4930
4923
  props: {
4931
4924
  zIndex: (
4932
4925
  /*mergedOptions*/
@@ -4969,7 +4962,7 @@ function vl(s) {
4969
4962
  t || (je(e.$$.fragment, i), t = !0);
4970
4963
  },
4971
4964
  o(i) {
4972
- $e(e.$$.fragment, i), t = !1;
4965
+ Ke(e.$$.fragment, i), t = !1;
4973
4966
  },
4974
4967
  d(i) {
4975
4968
  on(e, i);
@@ -5024,7 +5017,7 @@ function El(s) {
5024
5017
  t || (je(e.$$.fragment, l), t = !0);
5025
5018
  },
5026
5019
  o(l) {
5027
- $e(e.$$.fragment, l), t = !1;
5020
+ Ke(e.$$.fragment, l), t = !1;
5028
5021
  },
5029
5022
  d(l) {
5030
5023
  on(e, l);
@@ -5033,19 +5026,19 @@ function El(s) {
5033
5026
  }
5034
5027
  function Sl(s) {
5035
5028
  let e, t, n = `${/*$drawerWidth*/
5036
- s[12]}px`, o, l, i, r, c, u, h, p, m, g, _, T, R, L, A = (
5029
+ s[12]}px`, o, l, i, r, c, u, h, p, m, g, k, T, R, L, A = (
5037
5030
  /*$drawerWidth*/
5038
5031
  s[12] > 0 && Xs(s)
5039
5032
  );
5040
5033
  return {
5041
5034
  c() {
5042
- var w, k;
5043
- e = S("div"), t = S("div"), A && A.c(), o = j(), l = S("button"), i = J("svg"), r = J("path"), c = J("path"), u = J("path"), h = J("path"), p = J("path"), m = J("path"), g = J("path"), a(t, "class", "sy-assistant-drawer-wrapper svelte-1427avp"), $(
5035
+ var w, _;
5036
+ e = S("div"), t = S("div"), A && A.c(), o = j(), l = S("button"), i = Q("svg"), r = Q("path"), c = Q("path"), u = Q("path"), h = Q("path"), p = Q("path"), m = Q("path"), g = Q("path"), a(t, "class", "sy-assistant-drawer-wrapper svelte-1427avp"), $(
5044
5037
  t,
5045
5038
  "fullscreen",
5046
5039
  /*isFullscreen*/
5047
5040
  s[2]
5048
- ), F(t, "width", n), a(r, "d", "M896.512 698.88H132.608c-58.88 0-107.008-48.128-107.008-107.008v-10.24c0-58.88 48.128-107.008 107.008-107.008h763.904c58.88 0 107.008 48.128 107.008 107.008v10.24c0 58.88-48.128 107.008-107.008 107.008zM496.64 201.728h35.84v117.248h-35.84z"), a(r, "fill", "#6F8698"), a(c, "d", "M516.608 223.744h-4.608c-37.888 0-68.096-30.72-68.096-68.096v-6.656c0-37.888 30.72-68.096 68.096-68.096h4.608c37.888 0 68.096 30.72 68.096 68.096v6.656c0.512 37.888-30.208 68.096-68.096 68.096z"), a(c, "fill", "#3677FF"), a(u, "d", "M573.44 944.64H450.56c-181.248 0-327.68-146.432-327.68-327.68v-4.096c0-181.248 146.432-327.68 327.68-327.68h122.88c181.248 0 327.68 146.432 327.68 327.68v4.096c0 180.224-146.432 327.68-327.68 327.68z"), a(u, "fill", "#D0D5F1"), a(h, "d", "M681.984 715.264H347.136c-72.704 0-131.584-58.88-131.584-131.584s58.88-131.584 131.584-131.584h334.336c72.704 0 131.584 58.88 131.584 131.584 0.512 72.704-58.368 131.584-131.072 131.584z"), a(h, "fill", "#3677FF"), a(p, "d", "M286.72 583.68a78.336 70.144 90 1 0 140.288 0 78.336 70.144 90 1 0-140.288 0Z"), a(p, "fill", "#FFFFFF"), a(m, "d", "M608.256 583.68a78.336 70.144 90 1 0 140.288 0 78.336 70.144 90 1 0-140.288 0Z"), a(m, "fill", "#FFFFFF"), a(g, "d", "M443.392 799.232s2.56 58.88 68.096 58.88c58.88 0 69.632-61.952 69.632-61.952s-27.136 33.28-68.096 33.28c-42.496 0-69.632-30.208-69.632-30.208z"), a(g, "fill", "#8896A4"), a(i, "class", "sy-assistant-icon"), a(i, "viewBox", "0 0 1024 1024"), a(i, "version", "1.1"), a(i, "xmlns", "http://www.w3.org/2000/svg"), a(i, "width", "32"), a(i, "height", "32"), a(i, "fill", "currentColor"), a(i, "aria-label", "助手图标"), a(l, "class", "sy-assistant-floating-button svelte-1427avp"), a(l, "aria-label", "打开助手"), a(l, "style", _ = /*buttonStyle*/
5041
+ ), N(t, "width", n), a(r, "d", "M896.512 698.88H132.608c-58.88 0-107.008-48.128-107.008-107.008v-10.24c0-58.88 48.128-107.008 107.008-107.008h763.904c58.88 0 107.008 48.128 107.008 107.008v10.24c0 58.88-48.128 107.008-107.008 107.008zM496.64 201.728h35.84v117.248h-35.84z"), a(r, "fill", "#6F8698"), a(c, "d", "M516.608 223.744h-4.608c-37.888 0-68.096-30.72-68.096-68.096v-6.656c0-37.888 30.72-68.096 68.096-68.096h4.608c37.888 0 68.096 30.72 68.096 68.096v6.656c0.512 37.888-30.208 68.096-68.096 68.096z"), a(c, "fill", "#3677FF"), a(u, "d", "M573.44 944.64H450.56c-181.248 0-327.68-146.432-327.68-327.68v-4.096c0-181.248 146.432-327.68 327.68-327.68h122.88c181.248 0 327.68 146.432 327.68 327.68v4.096c0 180.224-146.432 327.68-327.68 327.68z"), a(u, "fill", "#D0D5F1"), a(h, "d", "M681.984 715.264H347.136c-72.704 0-131.584-58.88-131.584-131.584s58.88-131.584 131.584-131.584h334.336c72.704 0 131.584 58.88 131.584 131.584 0.512 72.704-58.368 131.584-131.072 131.584z"), a(h, "fill", "#3677FF"), a(p, "d", "M286.72 583.68a78.336 70.144 90 1 0 140.288 0 78.336 70.144 90 1 0-140.288 0Z"), a(p, "fill", "#FFFFFF"), a(m, "d", "M608.256 583.68a78.336 70.144 90 1 0 140.288 0 78.336 70.144 90 1 0-140.288 0Z"), a(m, "fill", "#FFFFFF"), a(g, "d", "M443.392 799.232s2.56 58.88 68.096 58.88c58.88 0 69.632-61.952 69.632-61.952s-27.136 33.28-68.096 33.28c-42.496 0-69.632-30.208-69.632-30.208z"), a(g, "fill", "#8896A4"), a(i, "class", "sy-assistant-icon"), a(i, "viewBox", "0 0 1024 1024"), a(i, "version", "1.1"), a(i, "xmlns", "http://www.w3.org/2000/svg"), a(i, "width", "32"), a(i, "height", "32"), a(i, "fill", "currentColor"), a(i, "aria-label", "助手图标"), a(l, "class", "sy-assistant-floating-button svelte-1427avp"), a(l, "aria-label", "打开助手"), a(l, "style", k = /*buttonStyle*/
5049
5042
  s[10] + " z-index: " + /*mergedOptions*/
5050
5043
  (((w = s[3].zIndex) != null ? w : 1e3) + 1) + ";"), a(e, "class", "sy-assistant-container sy-assistant-theme svelte-1427avp"), $(
5051
5044
  e,
@@ -5057,43 +5050,43 @@ function Sl(s) {
5057
5050
  "snapped",
5058
5051
  /*isSnapped*/
5059
5052
  s[7]
5060
- ), F(
5053
+ ), N(
5061
5054
  e,
5062
5055
  "position",
5063
5056
  /*mergedOptions*/
5064
5057
  s[3].position
5065
- ), F(
5058
+ ), N(
5066
5059
  e,
5067
5060
  "right",
5068
5061
  /*isSnapped*/
5069
5062
  s[7] ? 0 : `${/*right*/
5070
5063
  s[0]}px`
5071
- ), F(
5064
+ ), N(
5072
5065
  e,
5073
5066
  "bottom",
5074
5067
  /*isSnapped*/
5075
5068
  s[7] ? 0 : `${/*bottom*/
5076
5069
  s[1]}px`
5077
- ), F(
5070
+ ), N(
5078
5071
  e,
5079
5072
  "top",
5080
5073
  /*isSnapped*/
5081
5074
  s[7] || /*isFullscreen*/
5082
5075
  s[2] ? "0" : "auto"
5083
- ), F(
5076
+ ), N(
5084
5077
  e,
5085
5078
  "left",
5086
5079
  /*isFullscreen*/
5087
5080
  s[2] ? "0" : "auto"
5088
- ), F(
5081
+ ), N(
5089
5082
  e,
5090
5083
  "z-index",
5091
5084
  /*mergedOptions*/
5092
- (k = s[3].zIndex) != null ? k : 1e3
5085
+ (_ = s[3].zIndex) != null ? _ : 1e3
5093
5086
  );
5094
5087
  },
5095
- m(w, k) {
5096
- Y(w, e, k), d(e, t), A && A.m(t, null), d(e, o), d(e, l), d(l, i), d(i, r), d(i, c), d(i, u), d(i, h), d(i, p), d(i, m), d(i, g), s[27](l), s[29](e), T = !0, R || (L = [
5088
+ m(w, _) {
5089
+ Y(w, e, _), d(e, t), A && A.m(t, null), d(e, o), d(e, l), d(l, i), d(i, r), d(i, c), d(i, u), d(i, h), d(i, p), d(i, m), d(i, g), s[27](l), s[29](e), T = !0, R || (L = [
5097
5090
  G(
5098
5091
  l,
5099
5092
  "click",
@@ -5106,70 +5099,70 @@ function Sl(s) {
5106
5099
  ))
5107
5100
  ], R = !0);
5108
5101
  },
5109
- p(w, k) {
5110
- var y, v;
5102
+ p(w, _) {
5103
+ var b, v;
5111
5104
  /*$drawerWidth*/
5112
- w[12] > 0 ? A ? (A.p(w, k), k[0] & /*$drawerWidth*/
5113
- 4096 && je(A, 1)) : (A = Xs(w), A.c(), je(A, 1), A.m(t, null)) : A && (Cn(), $e(A, 1, 1, () => {
5105
+ w[12] > 0 ? A ? (A.p(w, _), _[0] & /*$drawerWidth*/
5106
+ 4096 && je(A, 1)) : (A = Xs(w), A.c(), je(A, 1), A.m(t, null)) : A && (Cn(), Ke(A, 1, 1, () => {
5114
5107
  A = null;
5115
- }), Ln()), (!T || k[0] & /*isFullscreen*/
5108
+ }), Ln()), (!T || _[0] & /*isFullscreen*/
5116
5109
  4) && $(
5117
5110
  t,
5118
5111
  "fullscreen",
5119
5112
  /*isFullscreen*/
5120
5113
  w[2]
5121
- ), k[0] & /*$drawerWidth*/
5114
+ ), _[0] & /*$drawerWidth*/
5122
5115
  4096 && n !== (n = `${/*$drawerWidth*/
5123
- w[12]}px`) && F(t, "width", n), (!T || k[0] & /*buttonStyle, mergedOptions*/
5124
- 1032 && _ !== (_ = /*buttonStyle*/
5116
+ w[12]}px`) && N(t, "width", n), (!T || _[0] & /*buttonStyle, mergedOptions*/
5117
+ 1032 && k !== (k = /*buttonStyle*/
5125
5118
  w[10] + " z-index: " + /*mergedOptions*/
5126
- (((y = w[3].zIndex) != null ? y : 1e3) + 1) + ";")) && a(l, "style", _), (!T || k[0] & /*isFullscreen*/
5119
+ (((b = w[3].zIndex) != null ? b : 1e3) + 1) + ";")) && a(l, "style", k), (!T || _[0] & /*isFullscreen*/
5127
5120
  4) && $(
5128
5121
  e,
5129
5122
  "fullscreen",
5130
5123
  /*isFullscreen*/
5131
5124
  w[2]
5132
- ), (!T || k[0] & /*isSnapped*/
5125
+ ), (!T || _[0] & /*isSnapped*/
5133
5126
  128) && $(
5134
5127
  e,
5135
5128
  "snapped",
5136
5129
  /*isSnapped*/
5137
5130
  w[7]
5138
- ), k[0] & /*mergedOptions*/
5139
- 8 && F(
5131
+ ), _[0] & /*mergedOptions*/
5132
+ 8 && N(
5140
5133
  e,
5141
5134
  "position",
5142
5135
  /*mergedOptions*/
5143
5136
  w[3].position
5144
- ), k[0] & /*isSnapped, right*/
5145
- 129 && F(
5137
+ ), _[0] & /*isSnapped, right*/
5138
+ 129 && N(
5146
5139
  e,
5147
5140
  "right",
5148
5141
  /*isSnapped*/
5149
5142
  w[7] ? 0 : `${/*right*/
5150
5143
  w[0]}px`
5151
- ), k[0] & /*isSnapped, bottom*/
5152
- 130 && F(
5144
+ ), _[0] & /*isSnapped, bottom*/
5145
+ 130 && N(
5153
5146
  e,
5154
5147
  "bottom",
5155
5148
  /*isSnapped*/
5156
5149
  w[7] ? 0 : `${/*bottom*/
5157
5150
  w[1]}px`
5158
- ), k[0] & /*isSnapped, isFullscreen*/
5159
- 132 && F(
5151
+ ), _[0] & /*isSnapped, isFullscreen*/
5152
+ 132 && N(
5160
5153
  e,
5161
5154
  "top",
5162
5155
  /*isSnapped*/
5163
5156
  w[7] || /*isFullscreen*/
5164
5157
  w[2] ? "0" : "auto"
5165
- ), k[0] & /*isFullscreen*/
5166
- 4 && F(
5158
+ ), _[0] & /*isFullscreen*/
5159
+ 4 && N(
5167
5160
  e,
5168
5161
  "left",
5169
5162
  /*isFullscreen*/
5170
5163
  w[2] ? "0" : "auto"
5171
- ), k[0] & /*mergedOptions*/
5172
- 8 && F(
5164
+ ), _[0] & /*mergedOptions*/
5165
+ 8 && N(
5173
5166
  e,
5174
5167
  "z-index",
5175
5168
  /*mergedOptions*/
@@ -5180,14 +5173,14 @@ function Sl(s) {
5180
5173
  T || (je(A), T = !0);
5181
5174
  },
5182
5175
  o(w) {
5183
- $e(A), T = !1;
5176
+ Ke(A), T = !1;
5184
5177
  },
5185
5178
  d(w) {
5186
- w && W(e), A && A.d(), s[27](null), s[29](null), R = !1, Se(L);
5179
+ w && W(e), A && A.d(), s[27](null), s[29](null), R = !1, Ae(L);
5187
5180
  }
5188
5181
  };
5189
5182
  }
5190
- const kn = 48, pe = 20;
5183
+ const _n = 48, pe = 20;
5191
5184
  function Al(s, e, t) {
5192
5185
  let n, o, l, i, r = Oe, c = () => (r(), r = Oi(o, (P) => t(12, i = P)), o);
5193
5186
  s.$$.on_destroy.push(() => r());
@@ -5204,9 +5197,9 @@ function Al(s, e, t) {
5204
5197
  hasScene: !1,
5205
5198
  apiPrefix: "/aiops/aigc"
5206
5199
  };
5207
- let { target: h = "body" } = e, { options: p = {} } = e, m, g = null, _ = !1, T, R = !1, L = 0, A = 0, w = pe, k = 20, y = w, v = k, x = !1, M = pe, z = 50, Z = !1, B = { width: 0, height: 0, right: 0, bottom: 0 }, I = !1, C = !1, U = [], V = null;
5200
+ let { target: h = "body" } = e, { options: p = {} } = e, m, g = null, k = !1, T, R = !1, L = 0, A = 0, w = pe, _ = 20, b = w, v = _, x = !1, M = pe, z = 50, Z = !1, B = { width: 0, height: 0, right: 0, bottom: 0 }, I = !1, C = !1, U = [], X = null;
5208
5201
  function ne() {
5209
- return Ee(this, null, function* () {
5202
+ return Se(this, null, function* () {
5210
5203
  try {
5211
5204
  const P = yield fetch(`${n.apiPrefix}/chat/getSessionId`, {
5212
5205
  method: "POST",
@@ -5220,7 +5213,7 @@ function Al(s, e, t) {
5220
5213
  throw new Error("Failed to get session ID");
5221
5214
  const le = yield P.json();
5222
5215
  if (le.code === 0)
5223
- return t(9, V = le.data.sessionId), V;
5216
+ return t(9, X = le.data.sessionId), X;
5224
5217
  throw new Error(le.message || "Failed to get session ID");
5225
5218
  } catch (P) {
5226
5219
  return console.error("Failed to get session ID:", P), null;
@@ -5228,33 +5221,33 @@ function Al(s, e, t) {
5228
5221
  });
5229
5222
  }
5230
5223
  function he(P, le = !1) {
5231
- le ? t(23, x = !0) : t(6, R = !0), L = P.clientX, A = P.clientY, w = le ? M : y, k = le ? z : v, P.preventDefault();
5224
+ le ? t(23, x = !0) : t(6, R = !0), L = P.clientX, A = P.clientY, w = le ? M : b, _ = le ? z : v, P.preventDefault();
5232
5225
  }
5233
5226
  function He(P) {
5234
5227
  if (!R && !x) return;
5235
5228
  const le = L - P.clientX, D = A - P.clientY;
5236
5229
  if (x) {
5237
5230
  const q = w + le, me = P.clientY;
5238
- t(24, M = Math.max(pe, Math.min(window.innerWidth - kn - pe, q)));
5239
- const ge = window.innerHeight - kn - pe, De = Math.max(pe, Math.min(ge, me));
5240
- t(25, z = (window.innerHeight - De - kn) / window.innerHeight * 100);
5231
+ t(24, M = Math.max(pe, Math.min(window.innerWidth - _n - pe, q)));
5232
+ const ge = window.innerHeight - _n - pe, De = Math.max(pe, Math.min(ge, me));
5233
+ t(25, z = (window.innerHeight - De - _n) / window.innerHeight * 100);
5241
5234
  } else {
5242
5235
  const q = n.width || 0, me = n.height || 0, ge = w + le;
5243
- t(0, y = Math.max(pe, Math.min(window.innerWidth - q - pe, ge)));
5244
- const Me = k + D;
5236
+ t(0, b = Math.max(pe, Math.min(window.innerWidth - q - pe, ge)));
5237
+ const Me = _ + D;
5245
5238
  t(1, v = Math.max(pe, Math.min(window.innerHeight - me - pe, Me)));
5246
5239
  }
5247
5240
  }
5248
- function ue() {
5241
+ function fe() {
5249
5242
  t(6, R = !1), t(23, x = !1);
5250
5243
  }
5251
5244
  Rn(() => {
5252
5245
  typeof h == "string" ? g = document.querySelector(h) || document.body : g = h || document.body;
5253
- const P = (D) => He(D), le = () => ue();
5254
- return document.addEventListener("mousemove", P), document.addEventListener("mouseup", le), m && g && g.appendChild(m), T && T.getBoundingClientRect().left, t(7, I = n.initialState === "snapped"), t(2, Z = n.initialState === "fullscreen"), n.initialState === "snapped" ? (t(0, y = 0), t(1, v = 0), t(3, n = be(ie({}, n), {
5246
+ const P = (D) => He(D), le = () => fe();
5247
+ return document.addEventListener("mousemove", P), document.addEventListener("mouseup", le), m && g && g.appendChild(m), T && T.getBoundingClientRect().left, t(7, I = n.initialState === "snapped"), t(2, Z = n.initialState === "fullscreen"), n.initialState === "snapped" ? (t(0, b = 0), t(1, v = 0), t(3, n = ye(ie({}, n), {
5255
5248
  height: typeof window != "undefined" ? window.innerHeight : n.height,
5256
5249
  width: n.snappedWidth || n.width
5257
- }))) : n.initialState === "fullscreen" && (t(0, y = 0), t(1, v = 0), t(3, n = be(ie({}, n), {
5250
+ }))) : n.initialState === "fullscreen" && (t(0, b = 0), t(1, v = 0), t(3, n = ye(ie({}, n), {
5258
5251
  width: typeof window != "undefined" ? window.innerWidth : n.width,
5259
5252
  height: typeof window != "undefined" ? window.innerHeight : n.height
5260
5253
  }))), () => {
@@ -5262,8 +5255,8 @@ function Al(s, e, t) {
5262
5255
  };
5263
5256
  });
5264
5257
  function Be() {
5265
- return Ee(this, null, function* () {
5266
- _ || (yield ne()), t(22, _ = !_);
5258
+ return Se(this, null, function* () {
5259
+ k || (yield ne()), t(22, k = !k);
5267
5260
  });
5268
5261
  }
5269
5262
  function ee() {
@@ -5273,47 +5266,47 @@ function Al(s, e, t) {
5273
5266
  height: u.height,
5274
5267
  right: (le = (P = u.defaultPosition) == null ? void 0 : P.right) != null ? le : pe,
5275
5268
  bottom: (q = (D = u.defaultPosition) == null ? void 0 : D.bottom) != null ? q : pe
5276
- }), I && t(7, I = !1), t(20, p = be(ie({}, n), {
5269
+ }), I && t(7, I = !1), t(20, p = ye(ie({}, n), {
5277
5270
  width: window.innerWidth,
5278
5271
  height: window.innerHeight,
5279
5272
  drawerWidth: window.innerWidth
5280
- })), t(0, y = 0), t(1, v = 0)) : (t(20, p = be(ie({}, n), {
5273
+ })), t(0, b = 0), t(1, v = 0)) : (t(20, p = ye(ie({}, n), {
5281
5274
  width: u.width,
5282
5275
  height: u.height,
5283
5276
  drawerWidth: u.drawerWidth
5284
- })), t(0, y = (ge = (me = u.defaultPosition) == null ? void 0 : me.right) != null ? ge : pe), t(1, v = (De = (Me = u.defaultPosition) == null ? void 0 : Me.bottom) != null ? De : pe));
5277
+ })), t(0, b = (ge = (me = u.defaultPosition) == null ? void 0 : me.right) != null ? ge : pe), t(1, v = (De = (Me = u.defaultPosition) == null ? void 0 : Me.bottom) != null ? De : pe));
5285
5278
  }
5286
5279
  function qe(P) {
5287
5280
  Z || he(P);
5288
5281
  }
5289
5282
  function se() {
5290
5283
  var P, le, D, q;
5291
- Z && (t(2, Z = !1), t(20, p = be(ie({}, n), {
5284
+ Z && (t(2, Z = !1), t(20, p = ye(ie({}, n), {
5292
5285
  width: u.width,
5293
5286
  height: u.height,
5294
5287
  drawerWidth: u.drawerWidth
5295
- }))), t(7, I = !I), I ? (n.height, t(0, y = 0), t(1, v = 0), t(20, p = be(ie({}, n), {
5288
+ }))), t(7, I = !I), I ? (n.height, t(0, b = 0), t(1, v = 0), t(20, p = ye(ie({}, n), {
5296
5289
  height: window.innerHeight,
5297
5290
  width: n.snappedWidth || u.width,
5298
5291
  drawerWidth: n.snappedWidth || u.width
5299
- }))) : (t(20, p = be(ie({}, n), {
5292
+ }))) : (t(20, p = ye(ie({}, n), {
5300
5293
  width: u.width,
5301
5294
  height: u.height,
5302
5295
  drawerWidth: u.drawerWidth
5303
- })), t(0, y = (le = (P = u.defaultPosition) == null ? void 0 : P.right) != null ? le : pe), t(1, v = (q = (D = u.defaultPosition) == null ? void 0 : D.bottom) != null ? q : pe));
5296
+ })), t(0, b = (le = (P = u.defaultPosition) == null ? void 0 : P.right) != null ? le : pe), t(1, v = (q = (D = u.defaultPosition) == null ? void 0 : D.bottom) != null ? q : pe));
5304
5297
  }
5305
- function Ae(P) {
5298
+ function xe(P) {
5306
5299
  t(8, C = !1);
5307
5300
  }
5308
5301
  const K = () => t(8, C = !1);
5309
5302
  function Le(P) {
5310
- wt[P ? "unshift" : "push"](() => {
5303
+ zt[P ? "unshift" : "push"](() => {
5311
5304
  T = P, t(5, T);
5312
5305
  });
5313
5306
  }
5314
- const Te = (P) => he(P, !0);
5307
+ const ve = (P) => he(P, !0);
5315
5308
  function Qe(P) {
5316
- wt[P ? "unshift" : "push"](() => {
5309
+ zt[P ? "unshift" : "push"](() => {
5317
5310
  m = P, t(4, m);
5318
5311
  });
5319
5312
  }
@@ -5321,17 +5314,17 @@ function Al(s, e, t) {
5321
5314
  "target" in P && t(21, h = P.target), "options" in P && t(20, p = P.options);
5322
5315
  }, s.$$.update = () => {
5323
5316
  s.$$.dirty[0] & /*options*/
5324
- 1048576 && t(3, n = be(ie(ie({}, u), p), {
5317
+ 1048576 && t(3, n = ye(ie(ie({}, u), p), {
5325
5318
  defaultPosition: ie(ie({}, u.defaultPosition), p.defaultPosition)
5326
5319
  })), s.$$.dirty[0] & /*isOpen, isFullscreen, mergedOptions*/
5327
5320
  4194316 && c(t(11, o = Zi(
5328
- _ ? Z ? window.innerWidth : n.drawerWidth : 0,
5321
+ k ? Z ? window.innerWidth : n.drawerWidth : 0,
5329
5322
  { stiffness: 0.1, damping: 0.6 }
5330
5323
  ))), s.$$.dirty[0] & /*mergedOptions, right, bottom*/
5331
- 11 && typeof window != "undefined" && (t(0, y = Math.max(pe, Math.min(window.innerWidth - (n.width || 0), y))), t(1, v = Math.max(pe, Math.min(window.innerHeight - (n.height || 0), v)))), s.$$.dirty[0] & /*isOpen, buttonRight, buttonBottom, isButtonDragging*/
5332
- 62914560 && t(10, l = _ ? "display: none;" : `position: fixed; right: ${M}px; bottom: ${z}%; transform: none; cursor: ${x ? "grabbing" : "grab"};`);
5324
+ 11 && typeof window != "undefined" && (t(0, b = Math.max(pe, Math.min(window.innerWidth - (n.width || 0), b))), t(1, v = Math.max(pe, Math.min(window.innerHeight - (n.height || 0), v)))), s.$$.dirty[0] & /*isOpen, buttonRight, buttonBottom, isButtonDragging*/
5325
+ 62914560 && t(10, l = k ? "display: none;" : `position: fixed; right: ${M}px; bottom: ${z}%; transform: none; cursor: ${x ? "grabbing" : "grab"};`);
5333
5326
  }, [
5334
- y,
5327
+ b,
5335
5328
  v,
5336
5329
  Z,
5337
5330
  n,
@@ -5340,7 +5333,7 @@ function Al(s, e, t) {
5340
5333
  R,
5341
5334
  I,
5342
5335
  C,
5343
- V,
5336
+ X,
5344
5337
  l,
5345
5338
  o,
5346
5339
  i,
@@ -5350,16 +5343,16 @@ function Al(s, e, t) {
5350
5343
  ee,
5351
5344
  qe,
5352
5345
  se,
5353
- Ae,
5346
+ xe,
5354
5347
  p,
5355
5348
  h,
5356
- _,
5349
+ k,
5357
5350
  x,
5358
5351
  M,
5359
5352
  z,
5360
5353
  K,
5361
5354
  Le,
5362
- Te,
5355
+ ve,
5363
5356
  Qe
5364
5357
  ];
5365
5358
  }