@sy-design/svelte 1.0.7 → 1.0.8

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
@@ -1,22 +1,22 @@
1
- var _i = Object.defineProperty, yi = Object.defineProperties;
2
- var Ti = Object.getOwnPropertyDescriptors;
1
+ var yi = Object.defineProperty, Ti = Object.defineProperties;
2
+ var vi = Object.getOwnPropertyDescriptors;
3
3
  var Kn = Object.getOwnPropertySymbols;
4
- var vi = Object.prototype.hasOwnProperty, Ei = Object.prototype.propertyIsEnumerable;
4
+ var Ei = Object.prototype.hasOwnProperty, Si = Object.prototype.propertyIsEnumerable;
5
5
  var $n = (s) => {
6
6
  throw TypeError(s);
7
7
  };
8
- var an = (s, e, t) => e in s ? _i(s, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[e] = t, ee = (s, e) => {
8
+ var an = (s, e, t) => e in s ? yi(s, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[e] = t, ee = (s, e) => {
9
9
  for (var t in e || (e = {}))
10
- vi.call(e, t) && an(s, t, e[t]);
10
+ Ei.call(e, t) && an(s, t, e[t]);
11
11
  if (Kn)
12
12
  for (var t of Kn(e))
13
- Ei.call(e, t) && an(s, t, e[t]);
13
+ Si.call(e, t) && an(s, t, e[t]);
14
14
  return s;
15
- }, me = (s, e) => yi(s, Ti(e));
16
- var se = (s, e, t) => an(s, typeof e != "symbol" ? e + "" : e, t), Si = (s, e, t) => e.has(s) || $n("Cannot " + t);
15
+ }, ke = (s, e) => Ti(s, vi(e));
16
+ var se = (s, e, t) => an(s, typeof e != "symbol" ? e + "" : e, t), Ai = (s, e, t) => e.has(s) || $n("Cannot " + t);
17
17
  var es = (s, e, t) => e.has(s) ? $n("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(s) : e.set(s, t);
18
- var Bt = (s, e, t) => (Si(s, e, "access private method"), t);
19
- var Ie = (s, e, t) => new Promise((n, i) => {
18
+ var Bt = (s, e, t) => (Ai(s, e, "access private method"), t);
19
+ var xe = (s, e, t) => new Promise((n, i) => {
20
20
  var o = (c) => {
21
21
  try {
22
22
  a(t.next(c));
@@ -32,16 +32,16 @@ var Ie = (s, e, t) => new Promise((n, i) => {
32
32
  }, a = (c) => c.done ? n(c.value) : Promise.resolve(c.value).then(o, l);
33
33
  a((t = t.apply(s, e)).next());
34
34
  });
35
- function Ce() {
35
+ function Le() {
36
36
  }
37
- function Us(s) {
37
+ function js(s) {
38
38
  return s();
39
39
  }
40
40
  function ts() {
41
41
  return /* @__PURE__ */ Object.create(null);
42
42
  }
43
- function ve(s) {
44
- s.forEach(Us);
43
+ function Ee(s) {
44
+ s.forEach(js);
45
45
  }
46
46
  function An(s) {
47
47
  return typeof s == "function";
@@ -49,29 +49,29 @@ function An(s) {
49
49
  function Jt(s, e) {
50
50
  return s != s ? e == e : s !== e || s && typeof s == "object" || typeof s == "function";
51
51
  }
52
- function Ai(s) {
52
+ function xi(s) {
53
53
  return Object.keys(s).length === 0;
54
54
  }
55
- function xi(s, ...e) {
55
+ function Ri(s, ...e) {
56
56
  if (s == null) {
57
57
  for (const n of e)
58
58
  n(void 0);
59
- return Ce;
59
+ return Le;
60
60
  }
61
61
  const t = s.subscribe(...e);
62
62
  return t.unsubscribe ? () => t.unsubscribe() : t;
63
63
  }
64
- const js = typeof window != "undefined";
65
- let ns = js ? () => window.performance.now() : () => Date.now(), Ws = js ? (s) => requestAnimationFrame(s) : Ce;
64
+ const Ws = typeof window != "undefined";
65
+ let ns = Ws ? () => window.performance.now() : () => Date.now(), qs = Ws ? (s) => requestAnimationFrame(s) : Le;
66
66
  const dt = /* @__PURE__ */ new Set();
67
67
  function Gs(s) {
68
68
  dt.forEach((e) => {
69
69
  e.c(s) || (dt.delete(e), e.f());
70
- }), dt.size !== 0 && Ws(Gs);
70
+ }), dt.size !== 0 && qs(Gs);
71
71
  }
72
- function Ri(s) {
72
+ function Ii(s) {
73
73
  let e;
74
- return dt.size === 0 && Ws(Gs), {
74
+ return dt.size === 0 && qs(Gs), {
75
75
  promise: new Promise((t) => {
76
76
  dt.add(e = { c: s, f: t });
77
77
  }),
@@ -83,10 +83,10 @@ function Ri(s) {
83
83
  function m(s, e) {
84
84
  s.appendChild(e);
85
85
  }
86
- function W(s, e, t) {
86
+ function q(s, e, t) {
87
87
  s.insertBefore(e, t || null);
88
88
  }
89
- function U(s) {
89
+ function j(s) {
90
90
  s.parentNode && s.parentNode.removeChild(s);
91
91
  }
92
92
  function zi(s, e) {
@@ -99,19 +99,19 @@ function x(s) {
99
99
  function X(s) {
100
100
  return document.createElementNS("http://www.w3.org/2000/svg", s);
101
101
  }
102
- function Te(s) {
102
+ function ve(s) {
103
103
  return document.createTextNode(s);
104
104
  }
105
- function j() {
106
- return Te(" ");
105
+ function W() {
106
+ return ve(" ");
107
107
  }
108
108
  function Kt() {
109
- return Te("");
109
+ return ve("");
110
110
  }
111
- function H(s, e, t, n) {
111
+ function B(s, e, t, n) {
112
112
  return s.addEventListener(e, t, n), () => s.removeEventListener(e, t, n);
113
113
  }
114
- function qs(s) {
114
+ function Ys(s) {
115
115
  return function(e) {
116
116
  return e.preventDefault(), s.call(this, e);
117
117
  };
@@ -119,7 +119,7 @@ function qs(s) {
119
119
  function r(s, e, t) {
120
120
  t == null ? s.removeAttribute(e) : s.getAttribute(e) !== t && s.setAttribute(e, t);
121
121
  }
122
- function Ii(s) {
122
+ function Ci(s) {
123
123
  return Array.from(s.childNodes);
124
124
  }
125
125
  function De(s, e) {
@@ -132,7 +132,7 @@ function mt(s, e) {
132
132
  function F(s, e, t, n) {
133
133
  t == null ? s.style.removeProperty(e) : s.style.setProperty(e, t, "");
134
134
  }
135
- function Q(s, e, t) {
135
+ function J(s, e, t) {
136
136
  s.classList.toggle(e, !!t);
137
137
  }
138
138
  let Ct;
@@ -143,28 +143,28 @@ function xn() {
143
143
  if (!Ct) throw new Error("Function called outside component initialization");
144
144
  return Ct;
145
145
  }
146
- function Ys(s) {
146
+ function Zs(s) {
147
147
  xn().$$.on_mount.push(s);
148
148
  }
149
- function Ci(s) {
149
+ function Li(s) {
150
150
  xn().$$.after_update.push(s);
151
151
  }
152
- function Li(s) {
152
+ function Mi(s) {
153
153
  xn().$$.on_destroy.push(s);
154
154
  }
155
155
  const pt = [], wt = [];
156
156
  let gt = [];
157
- const ss = [], Mi = /* @__PURE__ */ Promise.resolve();
157
+ const ss = [], Oi = /* @__PURE__ */ Promise.resolve();
158
158
  let wn = !1;
159
- function Oi() {
160
- wn || (wn = !0, Mi.then(Zs));
159
+ function Di() {
160
+ wn || (wn = !0, Oi.then(Xs));
161
161
  }
162
162
  function kn(s) {
163
163
  gt.push(s);
164
164
  }
165
165
  const cn = /* @__PURE__ */ new Set();
166
166
  let ft = 0;
167
- function Zs() {
167
+ function Xs() {
168
168
  if (ft !== 0)
169
169
  return;
170
170
  const s = Ct;
@@ -172,7 +172,7 @@ function Zs() {
172
172
  try {
173
173
  for (; ft < pt.length; ) {
174
174
  const e = pt[ft];
175
- ft++, Rt(e), Di(e.$$);
175
+ ft++, Rt(e), Ni(e.$$);
176
176
  }
177
177
  } catch (e) {
178
178
  throw pt.length = 0, ft = 0, e;
@@ -188,14 +188,14 @@ function Zs() {
188
188
  ss.pop()();
189
189
  wn = !1, cn.clear(), Rt(s);
190
190
  }
191
- function Di(s) {
191
+ function Ni(s) {
192
192
  if (s.fragment !== null) {
193
- s.update(), ve(s.before_update);
193
+ s.update(), Ee(s.before_update);
194
194
  const e = s.dirty;
195
195
  s.dirty = [-1], s.fragment && s.fragment.p(s.ctx, e), s.after_update.forEach(kn);
196
196
  }
197
197
  }
198
- function Ni(s) {
198
+ function Pi(s) {
199
199
  const e = [], t = [];
200
200
  gt.forEach((n) => s.indexOf(n) === -1 ? e.push(n) : t.push(n)), t.forEach((n) => n()), gt = e;
201
201
  }
@@ -209,8 +209,8 @@ function Rn() {
209
209
  // parent group
210
210
  };
211
211
  }
212
- function zn() {
213
- st.r || ve(st.c), st = st.p;
212
+ function In() {
213
+ st.r || Ee(st.c), st = st.p;
214
214
  }
215
215
  function Ne(s, e) {
216
216
  s && s.i && (Yt.delete(s), s.i(e));
@@ -226,50 +226,50 @@ function Ke(s, e, t, n) {
226
226
  function kt(s) {
227
227
  return (s == null ? void 0 : s.length) !== void 0 ? s : Array.from(s);
228
228
  }
229
- function Xs(s, e) {
229
+ function Vs(s, e) {
230
230
  s.d(1), e.delete(s.key);
231
231
  }
232
- function Vs(s, e, t, n, i, o, l, a, c, u, h, p) {
233
- let g = s.length, d = o.length, w = g;
232
+ function Qs(s, e, t, n, i, o, l, a, c, u, h, p) {
233
+ let d = s.length, g = o.length, w = d;
234
234
  const S = {};
235
235
  for (; w--; ) S[s[w].key] = w;
236
236
  const C = [], M = /* @__PURE__ */ new Map(), v = /* @__PURE__ */ new Map(), b = [];
237
- for (w = d; w--; ) {
238
- const y = p(i, o, w), I = t(y);
239
- let R = l.get(I);
240
- R ? b.push(() => R.p(y, e)) : (R = u(I, y), R.c()), M.set(I, C[w] = R), I in S && v.set(I, Math.abs(w - S[I]));
237
+ for (w = g; w--; ) {
238
+ const T = p(i, o, w), z = t(T);
239
+ let R = l.get(z);
240
+ R ? b.push(() => R.p(T, e)) : (R = u(z, T), R.c()), M.set(z, C[w] = R), z in S && v.set(z, Math.abs(w - S[z]));
241
241
  }
242
- const k = /* @__PURE__ */ new Set(), _ = /* @__PURE__ */ new Set();
243
- function A(y) {
244
- Ne(y, 1), y.m(a, h), l.set(y.key, y), h = y.first, d--;
242
+ const k = /* @__PURE__ */ new Set(), y = /* @__PURE__ */ new Set();
243
+ function A(T) {
244
+ Ne(T, 1), T.m(a, h), l.set(T.key, T), h = T.first, g--;
245
245
  }
246
- for (; g && d; ) {
247
- const y = C[d - 1], I = s[g - 1], R = y.key, P = I.key;
248
- y === I ? (h = y.first, g--, d--) : M.has(P) ? !l.has(R) || k.has(R) ? A(y) : _.has(P) ? g-- : v.get(R) > v.get(P) ? (_.add(R), A(y)) : (k.add(P), g--) : (c(I, l), g--);
246
+ for (; d && g; ) {
247
+ const T = C[g - 1], z = s[d - 1], R = T.key, P = z.key;
248
+ T === z ? (h = T.first, d--, g--) : M.has(P) ? !l.has(R) || k.has(R) ? A(T) : y.has(P) ? d-- : v.get(R) > v.get(P) ? (y.add(R), A(T)) : (k.add(P), d--) : (c(z, l), d--);
249
249
  }
250
- for (; g--; ) {
251
- const y = s[g];
252
- M.has(y.key) || c(y, l);
250
+ for (; d--; ) {
251
+ const T = s[d];
252
+ M.has(T.key) || c(T, l);
253
253
  }
254
- for (; d; ) A(C[d - 1]);
255
- return ve(b), C;
254
+ for (; g; ) A(C[g - 1]);
255
+ return Ee(b), C;
256
256
  }
257
- function In(s) {
257
+ function zn(s) {
258
258
  s && s.c();
259
259
  }
260
260
  function $t(s, e, t) {
261
261
  const { fragment: n, after_update: i } = s.$$;
262
262
  n && n.m(e, t), kn(() => {
263
- const o = s.$$.on_mount.map(Us).filter(An);
264
- s.$$.on_destroy ? s.$$.on_destroy.push(...o) : ve(o), s.$$.on_mount = [];
263
+ const o = s.$$.on_mount.map(js).filter(An);
264
+ s.$$.on_destroy ? s.$$.on_destroy.push(...o) : Ee(o), s.$$.on_mount = [];
265
265
  }), i.forEach(kn);
266
266
  }
267
267
  function en(s, e) {
268
268
  const t = s.$$;
269
- t.fragment !== null && (Ni(t.after_update), ve(t.on_destroy), t.fragment && t.fragment.d(e), t.on_destroy = t.fragment = null, t.ctx = []);
269
+ t.fragment !== null && (Pi(t.after_update), Ee(t.on_destroy), t.fragment && t.fragment.d(e), t.on_destroy = t.fragment = null, t.ctx = []);
270
270
  }
271
- function Pi(s, e) {
272
- s.$$.dirty[0] === -1 && (pt.push(s), Oi(), s.$$.dirty.fill(0)), s.$$.dirty[e / 31 | 0] |= 1 << e % 31;
271
+ function Fi(s, e) {
272
+ s.$$.dirty[0] === -1 && (pt.push(s), Di(), s.$$.dirty.fill(0)), s.$$.dirty[e / 31 | 0] |= 1 << e % 31;
273
273
  }
274
274
  function Cn(s, e, t, n, i, o, l = null, a = [-1]) {
275
275
  const c = Ct;
@@ -279,7 +279,7 @@ function Cn(s, e, t, n, i, o, l = null, a = [-1]) {
279
279
  ctx: [],
280
280
  // state
281
281
  props: o,
282
- update: Ce,
282
+ update: Le,
283
283
  not_equal: i,
284
284
  bound: ts(),
285
285
  // lifecycle
@@ -297,16 +297,16 @@ function Cn(s, e, t, n, i, o, l = null, a = [-1]) {
297
297
  };
298
298
  l && l(u.root);
299
299
  let h = !1;
300
- if (u.ctx = t ? t(s, e.props || {}, (p, g, ...d) => {
301
- const w = d.length ? d[0] : g;
302
- return u.ctx && i(u.ctx[p], u.ctx[p] = w) && (!u.skip_bound && u.bound[p] && u.bound[p](w), h && Pi(s, p)), g;
303
- }) : [], u.update(), h = !0, ve(u.before_update), u.fragment = n ? n(u.ctx) : !1, e.target) {
300
+ if (u.ctx = t ? t(s, e.props || {}, (p, d, ...g) => {
301
+ const w = g.length ? g[0] : d;
302
+ return u.ctx && i(u.ctx[p], u.ctx[p] = w) && (!u.skip_bound && u.bound[p] && u.bound[p](w), h && Fi(s, p)), d;
303
+ }) : [], u.update(), h = !0, Ee(u.before_update), u.fragment = n ? n(u.ctx) : !1, e.target) {
304
304
  if (e.hydrate) {
305
- const p = Ii(e.target);
306
- u.fragment && u.fragment.l(p), p.forEach(U);
305
+ const p = Ci(e.target);
306
+ u.fragment && u.fragment.l(p), p.forEach(j);
307
307
  } else
308
308
  u.fragment && u.fragment.c();
309
- e.intro && Ne(s.$$.fragment), $t(s, e.target, e.anchor), Zs();
309
+ e.intro && Ne(s.$$.fragment), $t(s, e.target, e.anchor), Xs();
310
310
  }
311
311
  Rt(c);
312
312
  }
@@ -331,7 +331,7 @@ class Ln {
331
331
  }
332
332
  /** @returns {void} */
333
333
  $destroy() {
334
- en(this, 1), this.$destroy = Ce;
334
+ en(this, 1), this.$destroy = Le;
335
335
  }
336
336
  /**
337
337
  * @template {Extract<keyof Events, string>} K
@@ -341,7 +341,7 @@ class Ln {
341
341
  */
342
342
  $on(e, t) {
343
343
  if (!An(t))
344
- return Ce;
344
+ return Le;
345
345
  const n = this.$$.callbacks[e] || (this.$$.callbacks[e] = []);
346
346
  return n.push(t), () => {
347
347
  const i = n.indexOf(t);
@@ -353,13 +353,13 @@ class Ln {
353
353
  * @returns {void}
354
354
  */
355
355
  $set(e) {
356
- this.$$set && !Ai(e) && (this.$$.skip_bound = !0, this.$$set(e), this.$$.skip_bound = !1);
356
+ this.$$set && !xi(e) && (this.$$.skip_bound = !0, this.$$set(e), this.$$.skip_bound = !1);
357
357
  }
358
358
  }
359
- const Fi = "4";
360
- typeof window != "undefined" && (window.__svelte || (window.__svelte = { v: /* @__PURE__ */ new Set() })).v.add(Fi);
359
+ const Hi = "4";
360
+ typeof window != "undefined" && (window.__svelte || (window.__svelte = { v: /* @__PURE__ */ new Set() })).v.add(Hi);
361
361
  const ht = [];
362
- function Hi(s, e = Ce) {
362
+ function Bi(s, e = Le) {
363
363
  let t;
364
364
  const n = /* @__PURE__ */ new Set();
365
365
  function i(a) {
@@ -377,9 +377,9 @@ function Hi(s, e = Ce) {
377
377
  function o(a) {
378
378
  i(a(s));
379
379
  }
380
- function l(a, c = Ce) {
380
+ function l(a, c = Le) {
381
381
  const u = [a, c];
382
- return n.add(u), n.size === 1 && (t = e(i, o) || Ce), a(s), () => {
382
+ return n.add(u), n.size === 1 && (t = e(i, o) || Le), a(s), () => {
383
383
  n.delete(u), n.size === 0 && t && (t(), t = null);
384
384
  };
385
385
  }
@@ -406,23 +406,23 @@ function bn(s, e, t, n) {
406
406
  throw new Error(`Cannot spring ${typeof t} values`);
407
407
  }
408
408
  }
409
- function Bi(s, e = {}) {
410
- const t = Hi(s), { stiffness: n = 0.15, damping: i = 0.8, precision: o = 0.01 } = e;
411
- let l, a, c, u = s, h = s, p = 1, g = 0, d = !1;
409
+ function Ui(s, e = {}) {
410
+ const t = Bi(s), { stiffness: n = 0.15, damping: i = 0.8, precision: o = 0.01 } = e;
411
+ let l, a, c, u = s, h = s, p = 1, d = 0, g = !1;
412
412
  function w(C, M = {}) {
413
413
  h = C;
414
414
  const v = c = {};
415
- return s == null || M.hard || S.stiffness >= 1 && S.damping >= 1 ? (d = !0, l = ns(), u = C, t.set(s = h), Promise.resolve()) : (M.soft && (g = 1 / ((M.soft === !0 ? 0.5 : +M.soft) * 60), p = 0), a || (l = ns(), d = !1, a = Ri((b) => {
416
- if (d)
417
- return d = !1, a = null, !1;
418
- p = Math.min(p + g, 1);
415
+ return s == null || M.hard || S.stiffness >= 1 && S.damping >= 1 ? (g = !0, l = ns(), u = C, t.set(s = h), Promise.resolve()) : (M.soft && (d = 1 / ((M.soft === !0 ? 0.5 : +M.soft) * 60), p = 0), a || (l = ns(), g = !1, a = Ii((b) => {
416
+ if (g)
417
+ return g = !1, a = null, !1;
418
+ p = Math.min(p + d, 1);
419
419
  const k = {
420
420
  inv_mass: p,
421
421
  opts: S,
422
422
  settled: !0,
423
423
  dt: (b - l) * 60 / 1e3
424
- }, _ = bn(k, u, s, h);
425
- return l = b, u = s, t.set(s = _), k.settled && (a = null), !k.settled;
424
+ }, y = bn(k, u, s, h);
425
+ return l = b, u = s, t.set(s = y), k.settled && (a = null), !k.settled;
426
426
  })), new Promise((b) => {
427
427
  a.promise.then(() => {
428
428
  v === c && b();
@@ -439,15 +439,15 @@ function Bi(s, e = {}) {
439
439
  };
440
440
  return S;
441
441
  }
442
- function Ui(s, e) {
443
- return Ie(this, null, function* () {
442
+ function ji(s, e) {
443
+ return xe(this, null, function* () {
444
444
  const t = s.getReader();
445
445
  let n;
446
446
  for (; !(n = yield t.read()).done; )
447
447
  e(n.value);
448
448
  });
449
449
  }
450
- function ji(s) {
450
+ function Wi(s) {
451
451
  let e, t, n, i = !1;
452
452
  return function(l) {
453
453
  e === void 0 ? (e = l, t = 0, n = -1) : e = Gi(e, l);
@@ -474,7 +474,7 @@ function ji(s) {
474
474
  c === a ? e = void 0 : c !== 0 && (e = e.subarray(c), t -= c);
475
475
  };
476
476
  }
477
- function Wi(s, e, t) {
477
+ function qi(s, e, t) {
478
478
  let n = os();
479
479
  const i = new TextDecoder();
480
480
  return function(l, a) {
@@ -513,7 +513,7 @@ function os() {
513
513
  retry: void 0
514
514
  };
515
515
  }
516
- var qi = function(s, e) {
516
+ var Yi = function(s, e) {
517
517
  var t = {};
518
518
  for (var n in s) Object.prototype.hasOwnProperty.call(s, n) && e.indexOf(n) < 0 && (t[n] = s[n]);
519
519
  if (s != null && typeof Object.getOwnPropertySymbols == "function")
@@ -521,51 +521,51 @@ var qi = function(s, e) {
521
521
  e.indexOf(n[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, n[i]) && (t[n[i]] = s[n[i]]);
522
522
  return t;
523
523
  };
524
- const _n = "text/event-stream", Yi = 1e3, ls = "last-event-id";
525
- function Zi(s, e) {
526
- var { signal: t, headers: n, onopen: i, onmessage: o, onclose: l, onerror: a, openWhenHidden: c, fetch: u } = e, h = qi(e, ["signal", "headers", "onopen", "onmessage", "onclose", "onerror", "openWhenHidden", "fetch"]);
527
- return new Promise((p, g) => {
528
- const d = Object.assign({}, n);
529
- d.accept || (d.accept = _n);
524
+ const _n = "text/event-stream", Zi = 1e3, ls = "last-event-id";
525
+ function Xi(s, e) {
526
+ var { signal: t, headers: n, onopen: i, onmessage: o, onclose: l, onerror: a, openWhenHidden: c, fetch: u } = e, h = Yi(e, ["signal", "headers", "onopen", "onmessage", "onclose", "onerror", "openWhenHidden", "fetch"]);
527
+ return new Promise((p, d) => {
528
+ const g = Object.assign({}, n);
529
+ g.accept || (g.accept = _n);
530
530
  let w;
531
531
  function S() {
532
- w.abort(), document.hidden || _();
532
+ w.abort(), document.hidden || y();
533
533
  }
534
534
  c || document.addEventListener("visibilitychange", S);
535
- let C = Yi, M = 0;
535
+ let C = Zi, M = 0;
536
536
  function v() {
537
537
  document.removeEventListener("visibilitychange", S), window.clearTimeout(M), w.abort();
538
538
  }
539
539
  t == null || t.addEventListener("abort", () => {
540
540
  v(), p();
541
541
  });
542
- const b = u != null ? u : window.fetch, k = i != null ? i : Xi;
543
- function _() {
544
- return Ie(this, null, function* () {
542
+ const b = u != null ? u : window.fetch, k = i != null ? i : Vi;
543
+ function y() {
544
+ return xe(this, null, function* () {
545
545
  var A;
546
546
  w = new AbortController();
547
547
  try {
548
- const y = yield b(s, Object.assign(Object.assign({}, h), { headers: d, signal: w.signal }));
549
- yield k(y), yield Ui(y.body, ji(Wi((I) => {
550
- I ? d[ls] = I : delete d[ls];
551
- }, (I) => {
552
- C = I;
548
+ const T = yield b(s, Object.assign(Object.assign({}, h), { headers: g, signal: w.signal }));
549
+ yield k(T), yield ji(T.body, Wi(qi((z) => {
550
+ z ? g[ls] = z : delete g[ls];
551
+ }, (z) => {
552
+ C = z;
553
553
  }, o))), l == null || l(), v(), p();
554
- } catch (y) {
554
+ } catch (T) {
555
555
  if (!w.signal.aborted)
556
556
  try {
557
- const I = (A = a == null ? void 0 : a(y)) !== null && A !== void 0 ? A : C;
558
- window.clearTimeout(M), M = window.setTimeout(_, I);
559
- } catch (I) {
560
- v(), g(I);
557
+ const z = (A = a == null ? void 0 : a(T)) !== null && A !== void 0 ? A : C;
558
+ window.clearTimeout(M), M = window.setTimeout(y, z);
559
+ } catch (z) {
560
+ v(), d(z);
561
561
  }
562
562
  }
563
563
  });
564
564
  }
565
- _();
565
+ y();
566
566
  });
567
567
  }
568
- function Xi(s) {
568
+ function Vi(s) {
569
569
  const e = s.headers.get("content-type");
570
570
  if (!(e != null && e.startsWith(_n)))
571
571
  throw new Error(`Expected content-type to be ${_n}, Actual: ${e}`);
@@ -585,36 +585,36 @@ function Mn() {
585
585
  };
586
586
  }
587
587
  let lt = Mn();
588
- function Qs(s) {
588
+ function Js(s) {
589
589
  lt = s;
590
590
  }
591
- const Js = /[&<>"']/, Vi = new RegExp(Js.source, "g"), Ks = /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, Qi = new RegExp(Ks.source, "g"), Ji = {
591
+ const Ks = /[&<>"']/, Qi = new RegExp(Ks.source, "g"), $s = /[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/, Ji = new RegExp($s.source, "g"), Ki = {
592
592
  "&": "&amp;",
593
593
  "<": "&lt;",
594
594
  ">": "&gt;",
595
595
  '"': "&quot;",
596
596
  "'": "&#39;"
597
- }, rs = (s) => Ji[s];
597
+ }, rs = (s) => Ki[s];
598
598
  function Me(s, e) {
599
599
  if (e) {
600
- if (Js.test(s))
601
- return s.replace(Vi, rs);
602
- } else if (Ks.test(s))
603
- return s.replace(Qi, rs);
600
+ if (Ks.test(s))
601
+ return s.replace(Qi, rs);
602
+ } else if ($s.test(s))
603
+ return s.replace(Ji, rs);
604
604
  return s;
605
605
  }
606
- const Ki = /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;
607
- function $i(s) {
608
- return s.replace(Ki, (e, t) => (t = t.toLowerCase(), t === "colon" ? ":" : t.charAt(0) === "#" ? t.charAt(1) === "x" ? String.fromCharCode(parseInt(t.substring(2), 16)) : String.fromCharCode(+t.substring(1)) : ""));
606
+ const $i = /&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;
607
+ function eo(s) {
608
+ return s.replace($i, (e, t) => (t = t.toLowerCase(), t === "colon" ? ":" : t.charAt(0) === "#" ? t.charAt(1) === "x" ? String.fromCharCode(parseInt(t.substring(2), 16)) : String.fromCharCode(+t.substring(1)) : ""));
609
609
  }
610
- const eo = /(^|[^\[])\^/g;
610
+ const to = /(^|[^\[])\^/g;
611
611
  function te(s, e) {
612
612
  let t = typeof s == "string" ? s : s.source;
613
613
  e = e || "";
614
614
  const n = {
615
615
  replace: (i, o) => {
616
616
  let l = typeof o == "string" ? o : o.source;
617
- return l = l.replace(eo, "$1"), t = t.replace(i, l), n;
617
+ return l = l.replace(to, "$1"), t = t.replace(i, l), n;
618
618
  },
619
619
  getRegex: () => new RegExp(t, e)
620
620
  };
@@ -628,7 +628,7 @@ function as(s) {
628
628
  }
629
629
  return s;
630
630
  }
631
- const zt = { exec: () => null };
631
+ const It = { exec: () => null };
632
632
  function cs(s, e) {
633
633
  const t = s.replace(/\|/g, (o, l, a) => {
634
634
  let c = !1, u = l;
@@ -663,7 +663,7 @@ function Ut(s, e, t) {
663
663
  }
664
664
  return s.slice(0, n - i);
665
665
  }
666
- function to(s, e) {
666
+ function no(s, e) {
667
667
  if (s.indexOf(e[1]) === -1)
668
668
  return -1;
669
669
  let t = 0;
@@ -698,7 +698,7 @@ function us(s, e, t, n) {
698
698
  text: Me(l)
699
699
  };
700
700
  }
701
- function no(s, e) {
701
+ function so(s, e) {
702
702
  const t = s.match(/^(\s+)(?:```)/);
703
703
  if (t === null)
704
704
  return e;
@@ -746,7 +746,7 @@ class Xt {
746
746
  fences(e) {
747
747
  const t = this.rules.block.fences.exec(e);
748
748
  if (t) {
749
- const n = t[0], i = no(n, t[3] || "");
749
+ const n = t[0], i = so(n, t[3] || "");
750
750
  return {
751
751
  type: "code",
752
752
  raw: n,
@@ -816,29 +816,29 @@ class Xt {
816
816
  break;
817
817
  a = t[0], e = e.substring(a.length);
818
818
  let p = t[2].split(`
819
- `, 1)[0].replace(/^\t+/, (M) => " ".repeat(3 * M.length)), g = e.split(`
820
- `, 1)[0], d = 0;
821
- this.options.pedantic ? (d = 2, c = p.trimStart()) : (d = t[2].search(/[^ ]/), d = d > 4 ? 1 : d, c = p.slice(d), d += t[1].length);
819
+ `, 1)[0].replace(/^\t+/, (M) => " ".repeat(3 * M.length)), d = e.split(`
820
+ `, 1)[0], g = 0;
821
+ 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);
822
822
  let w = !1;
823
- if (!p && /^ *$/.test(g) && (a += g + `
824
- `, e = e.substring(g.length + 1), h = !0), !h) {
825
- const M = new RegExp(`^ {0,${Math.min(3, d - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`), v = new RegExp(`^ {0,${Math.min(3, d - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`), b = new RegExp(`^ {0,${Math.min(3, d - 1)}}(?:\`\`\`|~~~)`), k = new RegExp(`^ {0,${Math.min(3, d - 1)}}#`);
823
+ if (!p && /^ *$/.test(d) && (a += d + `
824
+ `, e = e.substring(d.length + 1), h = !0), !h) {
825
+ const M = new RegExp(`^ {0,${Math.min(3, g - 1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`), v = new RegExp(`^ {0,${Math.min(3, g - 1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`), b = new RegExp(`^ {0,${Math.min(3, g - 1)}}(?:\`\`\`|~~~)`), k = new RegExp(`^ {0,${Math.min(3, g - 1)}}#`);
826
826
  for (; e; ) {
827
- const _ = e.split(`
827
+ const y = e.split(`
828
828
  `, 1)[0];
829
- if (g = _, this.options.pedantic && (g = g.replace(/^ {1,4}(?=( {4})*[^ ])/g, " ")), b.test(g) || k.test(g) || M.test(g) || v.test(e))
829
+ if (d = y, this.options.pedantic && (d = d.replace(/^ {1,4}(?=( {4})*[^ ])/g, " ")), b.test(d) || k.test(d) || M.test(d) || v.test(e))
830
830
  break;
831
- if (g.search(/[^ ]/) >= d || !g.trim())
831
+ if (d.search(/[^ ]/) >= g || !d.trim())
832
832
  c += `
833
- ` + g.slice(d);
833
+ ` + d.slice(g);
834
834
  else {
835
835
  if (w || p.search(/[^ ]/) >= 4 || b.test(p) || k.test(p) || v.test(p))
836
836
  break;
837
837
  c += `
838
- ` + g;
838
+ ` + d;
839
839
  }
840
- !w && !g.trim() && (w = !0), a += _ + `
841
- `, e = e.substring(_.length + 1), p = g.slice(d);
840
+ !w && !d.trim() && (w = !0), a += y + `
841
+ `, e = e.substring(y.length + 1), p = d.slice(g);
842
842
  }
843
843
  }
844
844
  o.loose || (u ? o.loose = !0 : /\n *\n *$/.test(a) && (u = !0));
@@ -856,8 +856,8 @@ class Xt {
856
856
  o.items[o.items.length - 1].raw = a.trimEnd(), o.items[o.items.length - 1].text = c.trimEnd(), o.raw = o.raw.trimEnd();
857
857
  for (let h = 0; h < o.items.length; h++)
858
858
  if (this.lexer.state.top = !1, o.items[h].tokens = this.lexer.blockTokens(o.items[h].text, []), !o.loose) {
859
- const p = o.items[h].tokens.filter((d) => d.type === "space"), g = p.length > 0 && p.some((d) => /\n.*\n/.test(d.raw));
860
- o.loose = g;
859
+ const p = o.items[h].tokens.filter((g) => g.type === "space"), d = p.length > 0 && p.some((g) => /\n.*\n/.test(g.raw));
860
+ o.loose = d;
861
861
  }
862
862
  if (o.loose)
863
863
  for (let h = 0; h < o.items.length; h++)
@@ -983,7 +983,7 @@ class Xt {
983
983
  if ((n.length - l.length) % 2 === 0)
984
984
  return;
985
985
  } else {
986
- const l = to(t[2], "()");
986
+ const l = no(t[2], "()");
987
987
  if (l > -1) {
988
988
  const c = (t[0].indexOf("!") === 0 ? 5 : 4) + t[1].length + l;
989
989
  t[2] = t[2].substring(0, l), t[0] = t[0].substring(0, c).trim(), t[3] = "";
@@ -1037,20 +1037,20 @@ class Xt {
1037
1037
  if (u -= c, u > 0)
1038
1038
  continue;
1039
1039
  c = Math.min(c, c + u + h);
1040
- const g = [...i[0]][0].length, d = e.slice(0, l + i.index + g + c);
1040
+ const d = [...i[0]][0].length, g = e.slice(0, l + i.index + d + c);
1041
1041
  if (Math.min(l, c) % 2) {
1042
- const S = d.slice(1, -1);
1042
+ const S = g.slice(1, -1);
1043
1043
  return {
1044
1044
  type: "em",
1045
- raw: d,
1045
+ raw: g,
1046
1046
  text: S,
1047
1047
  tokens: this.lexer.inlineTokens(S)
1048
1048
  };
1049
1049
  }
1050
- const w = d.slice(2, -2);
1050
+ const w = g.slice(2, -2);
1051
1051
  return {
1052
1052
  type: "strong",
1053
- raw: d,
1053
+ raw: g,
1054
1054
  text: w,
1055
1055
  tokens: this.lexer.inlineTokens(w)
1056
1056
  };
@@ -1147,74 +1147,74 @@ class Xt {
1147
1147
  }
1148
1148
  }
1149
1149
  }
1150
- const so = /^(?: *(?:\n|$))+/, io = /^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/, oo = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, Lt = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, lo = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, $s = /(?:[*+-]|\d{1,9}[.)])/, ei = te(/^(?!bull )((?:.|\n(?!\s*?\n|bull ))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g, $s).getRegex(), On = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, ro = /^[^\n]+/, Dn = /(?!\s*\])(?:\\.|[^\[\]\\])+/, ao = te(/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/).replace("label", Dn).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), co = te(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, $s).getRegex(), tn = "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", Nn = /<!--(?!-?>)[\s\S]*?(?:-->|$)/, uo = te("^ {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", Nn).replace("tag", tn).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), ti = te(On).replace("hr", Lt).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", tn).getRegex(), fo = te(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", ti).getRegex(), Pn = {
1151
- blockquote: fo,
1152
- code: io,
1153
- def: ao,
1154
- fences: oo,
1155
- heading: lo,
1150
+ const io = /^(?: *(?:\n|$))+/, oo = /^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/, lo = /^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/, Lt = /^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/, ro = /^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/, ei = /(?:[*+-]|\d{1,9}[.)])/, ti = te(/^(?!bull )((?:.|\n(?!\s*?\n|bull ))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g, ei).getRegex(), On = /^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/, ao = /^[^\n]+/, Dn = /(?!\s*\])(?:\\.|[^\[\]\\])+/, co = te(/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/).replace("label", Dn).replace("title", /(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(), uo = te(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g, ei).getRegex(), tn = "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", Nn = /<!--(?!-?>)[\s\S]*?(?:-->|$)/, fo = te("^ {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", Nn).replace("tag", tn).replace("attribute", / +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(), ni = te(On).replace("hr", Lt).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", tn).getRegex(), ho = te(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph", ni).getRegex(), Pn = {
1151
+ blockquote: ho,
1152
+ code: oo,
1153
+ def: co,
1154
+ fences: lo,
1155
+ heading: ro,
1156
1156
  hr: Lt,
1157
- html: uo,
1158
- lheading: ei,
1159
- list: co,
1160
- newline: so,
1161
- paragraph: ti,
1162
- table: zt,
1163
- text: ro
1164
- }, fs = te("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", Lt).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", tn).getRegex(), ho = me(ee({}, Pn), {
1157
+ html: fo,
1158
+ lheading: ti,
1159
+ list: uo,
1160
+ newline: io,
1161
+ paragraph: ni,
1162
+ table: It,
1163
+ text: ao
1164
+ }, fs = te("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr", Lt).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", tn).getRegex(), po = ke(ee({}, Pn), {
1165
1165
  table: fs,
1166
1166
  paragraph: te(On).replace("hr", Lt).replace("heading", " {0,3}#{1,6}(?:\\s|$)").replace("|lheading", "").replace("table", fs).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", tn).getRegex()
1167
- }), po = me(ee({}, Pn), {
1167
+ }), go = ke(ee({}, Pn), {
1168
1168
  html: te(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment", Nn).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(),
1169
1169
  def: /^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,
1170
1170
  heading: /^(#{1,6})(.*)(?:\n+|$)/,
1171
- fences: zt,
1171
+ fences: It,
1172
1172
  // fences not supported
1173
1173
  lheading: /^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,
1174
1174
  paragraph: te(On).replace("hr", Lt).replace("heading", ` *#{1,6} *[^
1175
- ]`).replace("lheading", ei).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
1176
- }), ni = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, go = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, si = /^( {2,}|\\)\n(?!\s*$)/, mo = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, Mt = "\\p{P}$+<=>`^|~", wo = te(/^((?![*_])[\spunctuation])/, "u").replace(/punctuation/g, Mt).getRegex(), ko = /\[[^[\]]*?\]\([^\(\)]*?\)|`[^`]*?`|<[^<>]*?>/g, bo = te(/^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/, "u").replace(/punct/g, Mt).getRegex(), _o = te("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)[punct](\\*+)(?=[\\s]|$)|[^punct\\s](\\*+)(?!\\*)(?=[punct\\s]|$)|(?!\\*)[punct\\s](\\*+)(?=[^punct\\s])|[\\s](\\*+)(?!\\*)(?=[punct])|(?!\\*)[punct](\\*+)(?!\\*)(?=[punct])|[^punct\\s](\\*+)(?=[^punct\\s])", "gu").replace(/punct/g, Mt).getRegex(), yo = te("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\\s]|$)|[^punct\\s](_+)(?!_)(?=[punct\\s]|$)|(?!_)[punct\\s](_+)(?=[^punct\\s])|[\\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])", "gu").replace(/punct/g, Mt).getRegex(), To = te(/\\([punct])/, "gu").replace(/punct/g, Mt).getRegex(), vo = te(/^<(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(), Eo = te(Nn).replace("(?:-->|$)", "-->").getRegex(), So = te("^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", Eo).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), Vt = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/, Ao = te(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label", Vt).replace("href", /<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), ii = te(/^!?\[(label)\]\[(ref)\]/).replace("label", Vt).replace("ref", Dn).getRegex(), oi = te(/^!?\[(ref)\](?:\[\])?/).replace("ref", Dn).getRegex(), xo = te("reflink|nolink(?!\\()", "g").replace("reflink", ii).replace("nolink", oi).getRegex(), Fn = {
1177
- _backpedal: zt,
1175
+ ]`).replace("lheading", ti).replace("|table", "").replace("blockquote", " {0,3}>").replace("|fences", "").replace("|list", "").replace("|html", "").replace("|tag", "").getRegex()
1176
+ }), si = /^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/, mo = /^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/, ii = /^( {2,}|\\)\n(?!\s*$)/, wo = /^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/, Mt = "\\p{P}$+<=>`^|~", ko = te(/^((?![*_])[\spunctuation])/, "u").replace(/punctuation/g, Mt).getRegex(), bo = /\[[^[\]]*?\]\([^\(\)]*?\)|`[^`]*?`|<[^<>]*?>/g, _o = te(/^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/, "u").replace(/punct/g, Mt).getRegex(), yo = te("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)[punct](\\*+)(?=[\\s]|$)|[^punct\\s](\\*+)(?!\\*)(?=[punct\\s]|$)|(?!\\*)[punct\\s](\\*+)(?=[^punct\\s])|[\\s](\\*+)(?!\\*)(?=[punct])|(?!\\*)[punct](\\*+)(?!\\*)(?=[punct])|[^punct\\s](\\*+)(?=[^punct\\s])", "gu").replace(/punct/g, Mt).getRegex(), To = te("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\\s]|$)|[^punct\\s](_+)(?!_)(?=[punct\\s]|$)|(?!_)[punct\\s](_+)(?=[^punct\\s])|[\\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])", "gu").replace(/punct/g, Mt).getRegex(), vo = te(/\\([punct])/, "gu").replace(/punct/g, Mt).getRegex(), Eo = te(/^<(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(), So = te(Nn).replace("(?:-->|$)", "-->").getRegex(), Ao = te("^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", So).replace("attribute", /\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(), Vt = /(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/, xo = te(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label", Vt).replace("href", /<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title", /"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(), oi = te(/^!?\[(label)\]\[(ref)\]/).replace("label", Vt).replace("ref", Dn).getRegex(), li = te(/^!?\[(ref)\](?:\[\])?/).replace("ref", Dn).getRegex(), Ro = te("reflink|nolink(?!\\()", "g").replace("reflink", oi).replace("nolink", li).getRegex(), Fn = {
1177
+ _backpedal: It,
1178
1178
  // only used for GFM url
1179
- anyPunctuation: To,
1180
- autolink: vo,
1181
- blockSkip: ko,
1182
- br: si,
1183
- code: go,
1184
- del: zt,
1185
- emStrongLDelim: bo,
1186
- emStrongRDelimAst: _o,
1187
- emStrongRDelimUnd: yo,
1188
- escape: ni,
1189
- link: Ao,
1190
- nolink: oi,
1191
- punctuation: wo,
1192
- reflink: ii,
1193
- reflinkSearch: xo,
1194
- tag: So,
1195
- text: mo,
1196
- url: zt
1197
- }, Ro = me(ee({}, Fn), {
1179
+ anyPunctuation: vo,
1180
+ autolink: Eo,
1181
+ blockSkip: bo,
1182
+ br: ii,
1183
+ code: mo,
1184
+ del: It,
1185
+ emStrongLDelim: _o,
1186
+ emStrongRDelimAst: yo,
1187
+ emStrongRDelimUnd: To,
1188
+ escape: si,
1189
+ link: xo,
1190
+ nolink: li,
1191
+ punctuation: ko,
1192
+ reflink: oi,
1193
+ reflinkSearch: Ro,
1194
+ tag: Ao,
1195
+ text: wo,
1196
+ url: It
1197
+ }, Io = ke(ee({}, Fn), {
1198
1198
  link: te(/^!?\[(label)\]\((.*?)\)/).replace("label", Vt).getRegex(),
1199
1199
  reflink: te(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label", Vt).getRegex()
1200
- }), yn = me(ee({}, Fn), {
1201
- escape: te(ni).replace("])", "~|])").getRegex(),
1200
+ }), yn = ke(ee({}, Fn), {
1201
+ escape: te(si).replace("])", "~|])").getRegex(),
1202
1202
  url: te(/^((?: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(),
1203
1203
  _backpedal: /(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,
1204
1204
  del: /^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,
1205
1205
  text: /^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|https?:\/\/|ftp:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/
1206
- }), zo = me(ee({}, yn), {
1207
- br: te(si).replace("{2,}", "*").getRegex(),
1206
+ }), zo = ke(ee({}, yn), {
1207
+ br: te(ii).replace("{2,}", "*").getRegex(),
1208
1208
  text: te(yn.text).replace("\\b_", "\\b_| {2,}\\n").replace(/\{2,\}/g, "*").getRegex()
1209
1209
  }), jt = {
1210
1210
  normal: Pn,
1211
- gfm: ho,
1212
- pedantic: po
1211
+ gfm: po,
1212
+ pedantic: go
1213
1213
  }, Tt = {
1214
1214
  normal: Fn,
1215
1215
  gfm: yn,
1216
1216
  breaks: zo,
1217
- pedantic: Ro
1217
+ pedantic: Io
1218
1218
  };
1219
1219
  class Ye {
1220
1220
  constructor(e) {
@@ -1418,9 +1418,9 @@ class Ye {
1418
1418
  if (o = e, this.options.extensions && this.options.extensions.startInline) {
1419
1419
  let h = 1 / 0;
1420
1420
  const p = e.slice(1);
1421
- let g;
1422
- this.options.extensions.startInline.forEach((d) => {
1423
- g = d.call({ lexer: this }, p), typeof g == "number" && g >= 0 && (h = Math.min(h, g));
1421
+ let d;
1422
+ this.options.extensions.startInline.forEach((g) => {
1423
+ d = g.call({ lexer: this }, p), typeof d == "number" && d >= 0 && (h = Math.min(h, d));
1424
1424
  }), h < 1 / 0 && h >= 0 && (o = e.substring(0, h + 1));
1425
1425
  }
1426
1426
  if (n = this.tokenizer.inlineText(o)) {
@@ -1612,7 +1612,7 @@ class Ze {
1612
1612
  }
1613
1613
  case "heading": {
1614
1614
  const l = o;
1615
- n += this.renderer.heading(this.parseInline(l.tokens), l.depth, $i(this.parseInline(l.tokens, this.textRenderer)));
1615
+ n += this.renderer.heading(this.parseInline(l.tokens), l.depth, eo(this.parseInline(l.tokens, this.textRenderer)));
1616
1616
  continue;
1617
1617
  }
1618
1618
  case "code": {
@@ -1630,8 +1630,8 @@ class Ze {
1630
1630
  for (let h = 0; h < l.rows.length; h++) {
1631
1631
  const p = l.rows[h];
1632
1632
  c = "";
1633
- for (let g = 0; g < p.length; g++)
1634
- c += this.renderer.tablecell(this.parseInline(p[g].tokens), { header: !1, align: l.align[g] });
1633
+ for (let d = 0; d < p.length; d++)
1634
+ c += this.renderer.tablecell(this.parseInline(p[d].tokens), { header: !1, align: l.align[d] });
1635
1635
  u += this.renderer.tablerow(c);
1636
1636
  }
1637
1637
  n += this.renderer.table(a, u);
@@ -1646,16 +1646,16 @@ class Ze {
1646
1646
  const l = o, a = l.ordered, c = l.start, u = l.loose;
1647
1647
  let h = "";
1648
1648
  for (let p = 0; p < l.items.length; p++) {
1649
- const g = l.items[p], d = g.checked, w = g.task;
1649
+ const d = l.items[p], g = d.checked, w = d.task;
1650
1650
  let S = "";
1651
- if (g.task) {
1652
- const C = this.renderer.checkbox(!!d);
1653
- u ? g.tokens.length > 0 && g.tokens[0].type === "paragraph" ? (g.tokens[0].text = C + " " + g.tokens[0].text, g.tokens[0].tokens && g.tokens[0].tokens.length > 0 && g.tokens[0].tokens[0].type === "text" && (g.tokens[0].tokens[0].text = C + " " + g.tokens[0].tokens[0].text)) : g.tokens.unshift({
1651
+ if (d.task) {
1652
+ const C = this.renderer.checkbox(!!g);
1653
+ u ? d.tokens.length > 0 && d.tokens[0].type === "paragraph" ? (d.tokens[0].text = C + " " + d.tokens[0].text, d.tokens[0].tokens && d.tokens[0].tokens.length > 0 && d.tokens[0].tokens[0].type === "text" && (d.tokens[0].tokens[0].text = C + " " + d.tokens[0].tokens[0].text)) : d.tokens.unshift({
1654
1654
  type: "text",
1655
1655
  text: C + " "
1656
1656
  }) : S += C + " ";
1657
1657
  }
1658
- S += this.parse(g.tokens, u), h += this.renderer.listitem(S, w, !!d);
1658
+ S += this.parse(d.tokens, u), h += this.renderer.listitem(S, w, !!g);
1659
1659
  }
1660
1660
  n += this.renderer.list(h, a, c);
1661
1661
  continue;
@@ -1764,7 +1764,7 @@ class Ze {
1764
1764
  return n;
1765
1765
  }
1766
1766
  }
1767
- class It {
1767
+ class zt {
1768
1768
  constructor(e) {
1769
1769
  se(this, "options");
1770
1770
  this.options = e || lt;
@@ -1788,13 +1788,13 @@ class It {
1788
1788
  return e;
1789
1789
  }
1790
1790
  }
1791
- se(It, "passThroughHooks", /* @__PURE__ */ new Set([
1791
+ se(zt, "passThroughHooks", /* @__PURE__ */ new Set([
1792
1792
  "preprocess",
1793
1793
  "postprocess",
1794
1794
  "processAllTokens"
1795
1795
  ]));
1796
- var ot, Tn, li;
1797
- class Io {
1796
+ var ot, Tn, ri;
1797
+ class Co {
1798
1798
  constructor(...e) {
1799
1799
  es(this, ot);
1800
1800
  se(this, "defaults", Mn());
@@ -1806,7 +1806,7 @@ class Io {
1806
1806
  se(this, "TextRenderer", Hn);
1807
1807
  se(this, "Lexer", Ye);
1808
1808
  se(this, "Tokenizer", Xt);
1809
- se(this, "Hooks", It);
1809
+ se(this, "Hooks", zt);
1810
1810
  this.use(...e);
1811
1811
  }
1812
1812
  /**
@@ -1893,16 +1893,16 @@ class Io {
1893
1893
  i.tokenizer = o;
1894
1894
  }
1895
1895
  if (n.hooks) {
1896
- const o = this.defaults.hooks || new It();
1896
+ const o = this.defaults.hooks || new zt();
1897
1897
  for (const l in n.hooks) {
1898
1898
  if (!(l in o))
1899
1899
  throw new Error(`hook '${l}' does not exist`);
1900
1900
  if (l === "options")
1901
1901
  continue;
1902
1902
  const a = l, c = n.hooks[a], u = o[a];
1903
- It.passThroughHooks.has(l) ? o[a] = (h) => {
1903
+ zt.passThroughHooks.has(l) ? o[a] = (h) => {
1904
1904
  if (this.defaults.async)
1905
- return Promise.resolve(c.call(o, h)).then((g) => u.call(o, g));
1905
+ return Promise.resolve(c.call(o, h)).then((d) => u.call(o, d));
1906
1906
  const p = c.call(o, h);
1907
1907
  return u.call(o, p);
1908
1908
  } : o[a] = (...h) => {
@@ -1936,7 +1936,7 @@ ot = new WeakSet(), Tn = function(e, t) {
1936
1936
  return (n, i) => {
1937
1937
  const o = ee({}, i), l = ee(ee({}, this.defaults), o);
1938
1938
  this.defaults.async === !0 && o.async === !1 && (l.silent || console.warn("marked(): The async option was set to true by an extension. The async: false option sent to parse will be ignored."), l.async = !0);
1939
- const a = Bt(this, ot, li).call(this, !!l.silent, !!l.async);
1939
+ const a = Bt(this, ot, ri).call(this, !!l.silent, !!l.async);
1940
1940
  if (typeof n == "undefined" || n === null)
1941
1941
  return a(new Error("marked(): input parameter is undefined or null"));
1942
1942
  if (typeof n != "string")
@@ -1953,7 +1953,7 @@ ot = new WeakSet(), Tn = function(e, t) {
1953
1953
  return a(c);
1954
1954
  }
1955
1955
  };
1956
- }, li = function(e, t) {
1956
+ }, ri = function(e, t) {
1957
1957
  return (n) => {
1958
1958
  if (n.message += `
1959
1959
  Please report this to https://github.com/markedjs/marked.`, e) {
@@ -1965,17 +1965,17 @@ Please report this to https://github.com/markedjs/marked.`, e) {
1965
1965
  throw n;
1966
1966
  };
1967
1967
  };
1968
- const it = new Io();
1968
+ const it = new Co();
1969
1969
  function K(s, e) {
1970
1970
  return it.parse(s, e);
1971
1971
  }
1972
1972
  K.options = K.setOptions = function(s) {
1973
- return it.setOptions(s), K.defaults = it.defaults, Qs(K.defaults), K;
1973
+ return it.setOptions(s), K.defaults = it.defaults, Js(K.defaults), K;
1974
1974
  };
1975
1975
  K.getDefaults = Mn;
1976
1976
  K.defaults = lt;
1977
1977
  K.use = function(...s) {
1978
- return it.use(...s), K.defaults = it.defaults, Qs(K.defaults), K;
1978
+ return it.use(...s), K.defaults = it.defaults, Js(K.defaults), K;
1979
1979
  };
1980
1980
  K.walkTokens = function(s, e) {
1981
1981
  return it.walkTokens(s, e);
@@ -1988,7 +1988,7 @@ K.TextRenderer = Hn;
1988
1988
  K.Lexer = Ye;
1989
1989
  K.lexer = Ye.lex;
1990
1990
  K.Tokenizer = Xt;
1991
- K.Hooks = It;
1991
+ K.Hooks = zt;
1992
1992
  K.parse = K;
1993
1993
  K.options;
1994
1994
  K.setOptions;
@@ -1999,21 +1999,21 @@ Ze.parse;
1999
1999
  Ye.lex;
2000
2000
  /*! @license DOMPurify 3.2.3 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.2.3/LICENSE */
2001
2001
  const {
2002
- entries: ri,
2002
+ entries: ai,
2003
2003
  setPrototypeOf: hs,
2004
- isFrozen: Co,
2005
- getPrototypeOf: Lo,
2006
- getOwnPropertyDescriptor: Mo
2004
+ isFrozen: Lo,
2005
+ getPrototypeOf: Mo,
2006
+ getOwnPropertyDescriptor: Oo
2007
2007
  } = Object;
2008
2008
  let {
2009
- freeze: xe,
2009
+ freeze: Ie,
2010
2010
  seal: Pe,
2011
- create: ai
2011
+ create: ci
2012
2012
  } = Object, {
2013
2013
  apply: vn,
2014
2014
  construct: En
2015
2015
  } = typeof Reflect != "undefined" && Reflect;
2016
- xe || (xe = function(e) {
2016
+ Ie || (Ie = function(e) {
2017
2017
  return e;
2018
2018
  });
2019
2019
  Pe || (Pe = function(e) {
@@ -2025,7 +2025,7 @@ vn || (vn = function(e, t, n) {
2025
2025
  En || (En = function(e, t) {
2026
2026
  return new e(...t);
2027
2027
  });
2028
- const Wt = Oe(Array.prototype.forEach), ps = Oe(Array.prototype.pop), vt = Oe(Array.prototype.push), Zt = Oe(String.prototype.toLowerCase), un = Oe(String.prototype.toString), ds = Oe(String.prototype.match), Et = Oe(String.prototype.replace), Oo = Oe(String.prototype.indexOf), Do = Oe(String.prototype.trim), Be = Oe(Object.prototype.hasOwnProperty), Ae = Oe(RegExp.prototype.test), St = No(TypeError);
2028
+ const Wt = Oe(Array.prototype.forEach), ps = Oe(Array.prototype.pop), vt = Oe(Array.prototype.push), Zt = Oe(String.prototype.toLowerCase), un = Oe(String.prototype.toString), ds = Oe(String.prototype.match), Et = Oe(String.prototype.replace), Do = Oe(String.prototype.indexOf), No = Oe(String.prototype.trim), Be = Oe(Object.prototype.hasOwnProperty), Re = Oe(RegExp.prototype.test), St = Po(TypeError);
2029
2029
  function Oe(s) {
2030
2030
  return function(e) {
2031
2031
  for (var t = arguments.length, n = new Array(t > 1 ? t - 1 : 0), i = 1; i < t; i++)
@@ -2033,7 +2033,7 @@ function Oe(s) {
2033
2033
  return vn(s, e, n);
2034
2034
  };
2035
2035
  }
2036
- function No(s) {
2036
+ function Po(s) {
2037
2037
  return function() {
2038
2038
  for (var e = arguments.length, t = new Array(e), n = 0; n < e; n++)
2039
2039
  t[n] = arguments[n];
@@ -2048,58 +2048,58 @@ function Y(s, e) {
2048
2048
  let i = e[n];
2049
2049
  if (typeof i == "string") {
2050
2050
  const o = t(i);
2051
- o !== i && (Co(e) || (e[n] = o), i = o);
2051
+ o !== i && (Lo(e) || (e[n] = o), i = o);
2052
2052
  }
2053
2053
  s[i] = !0;
2054
2054
  }
2055
2055
  return s;
2056
2056
  }
2057
- function Po(s) {
2057
+ function Fo(s) {
2058
2058
  for (let e = 0; e < s.length; e++)
2059
2059
  Be(s, e) || (s[e] = null);
2060
2060
  return s;
2061
2061
  }
2062
2062
  function nt(s) {
2063
- const e = ai(null);
2064
- for (const [t, n] of ri(s))
2065
- Be(s, t) && (Array.isArray(n) ? e[t] = Po(n) : n && typeof n == "object" && n.constructor === Object ? e[t] = nt(n) : e[t] = n);
2063
+ const e = ci(null);
2064
+ for (const [t, n] of ai(s))
2065
+ Be(s, t) && (Array.isArray(n) ? e[t] = Fo(n) : n && typeof n == "object" && n.constructor === Object ? e[t] = nt(n) : e[t] = n);
2066
2066
  return e;
2067
2067
  }
2068
2068
  function At(s, e) {
2069
2069
  for (; s !== null; ) {
2070
- const n = Mo(s, e);
2070
+ const n = Oo(s, e);
2071
2071
  if (n) {
2072
2072
  if (n.get)
2073
2073
  return Oe(n.get);
2074
2074
  if (typeof n.value == "function")
2075
2075
  return Oe(n.value);
2076
2076
  }
2077
- s = Lo(s);
2077
+ s = Mo(s);
2078
2078
  }
2079
2079
  function t() {
2080
2080
  return null;
2081
2081
  }
2082
2082
  return t;
2083
2083
  }
2084
- const gs = xe(["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"]), fn = xe(["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"]), hn = xe(["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"]), Fo = xe(["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"]), pn = xe(["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"]), Ho = xe(["maction", "maligngroup", "malignmark", "mlongdiv", "mscarries", "mscarry", "msgroup", "mstack", "msline", "msrow", "semantics", "annotation", "annotation-xml", "mprescripts", "none"]), ms = xe(["#text"]), ws = xe(["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"]), dn = xe(["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"]), ks = xe(["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"]), Gt = xe(["xlink:href", "xml:id", "xlink:title", "xml:space", "xmlns:xlink"]), Bo = Pe(/\{\{[\w\W]*|[\w\W]*\}\}/gm), Uo = Pe(/<%[\w\W]*|[\w\W]*%>/gm), jo = Pe(/\$\{[\w\W]*}/gm), Wo = Pe(/^data-[\-\w.\u00B7-\uFFFF]+$/), Go = Pe(/^aria-[\-\w]+$/), ci = Pe(
2084
+ const gs = Ie(["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"]), fn = Ie(["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"]), hn = Ie(["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"]), Ho = Ie(["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"]), pn = Ie(["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"]), Bo = Ie(["maction", "maligngroup", "malignmark", "mlongdiv", "mscarries", "mscarry", "msgroup", "mstack", "msline", "msrow", "semantics", "annotation", "annotation-xml", "mprescripts", "none"]), ms = Ie(["#text"]), ws = Ie(["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"]), dn = Ie(["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"]), ks = Ie(["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"]), qt = Ie(["xlink:href", "xml:id", "xlink:title", "xml:space", "xmlns:xlink"]), Uo = Pe(/\{\{[\w\W]*|[\w\W]*\}\}/gm), jo = Pe(/<%[\w\W]*|[\w\W]*%>/gm), Wo = Pe(/\$\{[\w\W]*}/gm), qo = Pe(/^data-[\-\w.\u00B7-\uFFFF]+$/), Go = Pe(/^aria-[\-\w]+$/), ui = Pe(
2085
2085
  /^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i
2086
2086
  // eslint-disable-line no-useless-escape
2087
- ), qo = Pe(/^(?:\w+script|data):/i), Yo = Pe(
2087
+ ), Yo = Pe(/^(?:\w+script|data):/i), Zo = Pe(
2088
2088
  /[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g
2089
2089
  // eslint-disable-line no-control-regex
2090
- ), ui = Pe(/^html$/i), Zo = Pe(/^[a-z][.\w]*(-[.\w]+)+$/i);
2090
+ ), fi = Pe(/^html$/i), Xo = Pe(/^[a-z][.\w]*(-[.\w]+)+$/i);
2091
2091
  var bs = /* @__PURE__ */ Object.freeze({
2092
2092
  __proto__: null,
2093
2093
  ARIA_ATTR: Go,
2094
- ATTR_WHITESPACE: Yo,
2095
- CUSTOM_ELEMENT: Zo,
2096
- DATA_ATTR: Wo,
2097
- DOCTYPE_NAME: ui,
2098
- ERB_EXPR: Uo,
2099
- IS_ALLOWED_URI: ci,
2100
- IS_SCRIPT_OR_DATA: qo,
2101
- MUSTACHE_EXPR: Bo,
2102
- TMPLIT_EXPR: jo
2094
+ ATTR_WHITESPACE: Zo,
2095
+ CUSTOM_ELEMENT: Xo,
2096
+ DATA_ATTR: qo,
2097
+ DOCTYPE_NAME: fi,
2098
+ ERB_EXPR: jo,
2099
+ IS_ALLOWED_URI: ui,
2100
+ IS_SCRIPT_OR_DATA: Yo,
2101
+ MUSTACHE_EXPR: Uo,
2102
+ TMPLIT_EXPR: Wo
2103
2103
  });
2104
2104
  const xt = {
2105
2105
  element: 1,
@@ -2117,9 +2117,9 @@ const xt = {
2117
2117
  documentFragment: 11,
2118
2118
  notation: 12
2119
2119
  // Deprecated
2120
- }, Xo = function() {
2120
+ }, Vo = function() {
2121
2121
  return typeof window == "undefined" ? null : window;
2122
- }, Vo = function(e, t) {
2122
+ }, Qo = function(e, t) {
2123
2123
  if (typeof e != "object" || typeof e.createPolicy != "function")
2124
2124
  return null;
2125
2125
  let n = null;
@@ -2151,9 +2151,9 @@ const xt = {
2151
2151
  uponSanitizeShadowNode: []
2152
2152
  };
2153
2153
  };
2154
- function fi() {
2155
- let s = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : Xo();
2156
- const e = (D) => fi(D);
2154
+ function hi() {
2155
+ let s = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : Vo();
2156
+ const e = (D) => hi(D);
2157
2157
  if (e.version = "3.2.3", e.removed = [], !s || !s.document || s.document.nodeType !== xt.document)
2158
2158
  return e.isSupported = !1, e;
2159
2159
  let {
@@ -2167,31 +2167,31 @@ function fi() {
2167
2167
  NodeFilter: u,
2168
2168
  NamedNodeMap: h = s.NamedNodeMap || s.MozNamedAttrMap,
2169
2169
  HTMLFormElement: p,
2170
- DOMParser: g,
2171
- trustedTypes: d
2170
+ DOMParser: d,
2171
+ trustedTypes: g
2172
2172
  } = s, w = c.prototype, S = At(w, "cloneNode"), C = At(w, "remove"), M = At(w, "nextSibling"), v = At(w, "childNodes"), b = At(w, "parentNode");
2173
2173
  if (typeof l == "function") {
2174
2174
  const D = t.createElement("template");
2175
2175
  D.content && D.content.ownerDocument && (t = D.content.ownerDocument);
2176
2176
  }
2177
- let k, _ = "";
2177
+ let k, y = "";
2178
2178
  const {
2179
2179
  implementation: A,
2180
- createNodeIterator: y,
2181
- createDocumentFragment: I,
2180
+ createNodeIterator: T,
2181
+ createDocumentFragment: z,
2182
2182
  getElementsByTagName: R
2183
2183
  } = t, {
2184
2184
  importNode: P
2185
2185
  } = n;
2186
- let z = _s();
2187
- e.isSupported = typeof ri == "function" && typeof b == "function" && A && A.createHTMLDocument !== void 0;
2186
+ let I = _s();
2187
+ e.isSupported = typeof ai == "function" && typeof b == "function" && A && A.createHTMLDocument !== void 0;
2188
2188
  const {
2189
- MUSTACHE_EXPR: B,
2189
+ MUSTACHE_EXPR: U,
2190
2190
  ERB_EXPR: Z,
2191
- TMPLIT_EXPR: V,
2191
+ TMPLIT_EXPR: Q,
2192
2192
  DATA_ATTR: oe,
2193
- ARIA_ATTR: fe,
2194
- IS_SCRIPT_OR_DATA: ce,
2193
+ ARIA_ATTR: he,
2194
+ IS_SCRIPT_OR_DATA: fe,
2195
2195
  ATTR_WHITESPACE: Fe,
2196
2196
  CUSTOM_ELEMENT: re
2197
2197
  } = bs;
@@ -2200,8 +2200,8 @@ function fi() {
2200
2200
  } = bs, le = null;
2201
2201
  const Xe = Y({}, [...gs, ...fn, ...hn, ...pn, ...ms]);
2202
2202
  let ie = null;
2203
- const Ee = Y({}, [...ws, ...dn, ...ks, ...Gt]);
2204
- let $ = Object.seal(ai(null, {
2203
+ const Se = Y({}, [...ws, ...dn, ...ks, ...qt]);
2204
+ let $ = Object.seal(ci(null, {
2205
2205
  tagNameCheck: {
2206
2206
  writable: !0,
2207
2207
  configurable: !1,
@@ -2220,46 +2220,46 @@ function fi() {
2220
2220
  enumerable: !0,
2221
2221
  value: !1
2222
2222
  }
2223
- })), Re = null, we = null, Ve = !0, O = !0, ne = !1, N = !0, q = !1, ke = !0, be = !1, He = !1, je = !1, $e = !1, rt = !1, at = !1, Ot = !0, Dt = !1;
2223
+ })), ze = null, be = null, Ve = !0, O = !0, ne = !1, N = !0, G = !1, _e = !0, ye = !1, He = !1, je = !1, $e = !1, rt = !1, at = !1, Ot = !0, Dt = !1;
2224
2224
  const nn = "user-content-";
2225
- let bt = !0, tt = !1, et = {}, T = null;
2226
- const G = Y({}, ["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"]);
2227
- let J = null;
2228
- const ue = Y({}, ["audio", "video", "img", "source", "image", "track"]);
2229
- let Le = null;
2230
- const We = Y({}, ["alt", "class", "for", "id", "label", "name", "pattern", "placeholder", "role", "summary", "title", "value", "style", "xmlns"]), pe = "http://www.w3.org/1998/Math/MathML", Nt = "http://www.w3.org/2000/svg", Qe = "http://www.w3.org/1999/xhtml";
2225
+ let bt = !0, tt = !1, et = {}, _ = null;
2226
+ const H = Y({}, ["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"]);
2227
+ let V = null;
2228
+ const ce = Y({}, ["audio", "video", "img", "source", "image", "track"]);
2229
+ let ue = null;
2230
+ const We = Y({}, ["alt", "class", "for", "id", "label", "name", "pattern", "placeholder", "role", "summary", "title", "value", "style", "xmlns"]), de = "http://www.w3.org/1998/Math/MathML", Nt = "http://www.w3.org/2000/svg", Qe = "http://www.w3.org/1999/xhtml";
2231
2231
  let ct = Qe, sn = !1, on = null;
2232
- const pi = Y({}, [pe, Nt, Qe], un);
2232
+ const di = Y({}, [de, Nt, Qe], un);
2233
2233
  let Pt = Y({}, ["mi", "mo", "mn", "ms", "mtext"]), Ft = Y({}, ["annotation-xml"]);
2234
- const di = Y({}, ["title", "style", "font", "a", "script"]);
2234
+ const gi = Y({}, ["title", "style", "font", "a", "script"]);
2235
2235
  let _t = null;
2236
- const gi = ["application/xhtml+xml", "text/html"], mi = "text/html";
2237
- let de = null, ut = null;
2238
- const wi = t.createElement("form"), Bn = function(f) {
2236
+ const mi = ["application/xhtml+xml", "text/html"], wi = "text/html";
2237
+ let ge = null, ut = null;
2238
+ const ki = t.createElement("form"), Bn = function(f) {
2239
2239
  return f instanceof RegExp || f instanceof Function;
2240
2240
  }, ln = function() {
2241
2241
  let f = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
2242
2242
  if (!(ut && ut === f)) {
2243
2243
  if ((!f || typeof f != "object") && (f = {}), f = nt(f), _t = // eslint-disable-next-line unicorn/prefer-includes
2244
- gi.indexOf(f.PARSER_MEDIA_TYPE) === -1 ? mi : f.PARSER_MEDIA_TYPE, de = _t === "application/xhtml+xml" ? un : Zt, le = Be(f, "ALLOWED_TAGS") ? Y({}, f.ALLOWED_TAGS, de) : Xe, ie = Be(f, "ALLOWED_ATTR") ? Y({}, f.ALLOWED_ATTR, de) : Ee, on = Be(f, "ALLOWED_NAMESPACES") ? Y({}, f.ALLOWED_NAMESPACES, un) : pi, Le = Be(f, "ADD_URI_SAFE_ATTR") ? Y(nt(We), f.ADD_URI_SAFE_ATTR, de) : We, J = Be(f, "ADD_DATA_URI_TAGS") ? Y(nt(ue), f.ADD_DATA_URI_TAGS, de) : ue, T = Be(f, "FORBID_CONTENTS") ? Y({}, f.FORBID_CONTENTS, de) : G, Re = Be(f, "FORBID_TAGS") ? Y({}, f.FORBID_TAGS, de) : {}, we = Be(f, "FORBID_ATTR") ? Y({}, f.FORBID_ATTR, de) : {}, et = Be(f, "USE_PROFILES") ? f.USE_PROFILES : !1, Ve = f.ALLOW_ARIA_ATTR !== !1, O = f.ALLOW_DATA_ATTR !== !1, ne = f.ALLOW_UNKNOWN_PROTOCOLS || !1, N = f.ALLOW_SELF_CLOSE_IN_ATTR !== !1, q = f.SAFE_FOR_TEMPLATES || !1, ke = f.SAFE_FOR_XML !== !1, be = f.WHOLE_DOCUMENT || !1, $e = f.RETURN_DOM || !1, rt = f.RETURN_DOM_FRAGMENT || !1, at = f.RETURN_TRUSTED_TYPE || !1, je = f.FORCE_BODY || !1, Ot = f.SANITIZE_DOM !== !1, Dt = f.SANITIZE_NAMED_PROPS || !1, bt = f.KEEP_CONTENT !== !1, tt = f.IN_PLACE || !1, Ue = f.ALLOWED_URI_REGEXP || ci, ct = f.NAMESPACE || Qe, Pt = f.MATHML_TEXT_INTEGRATION_POINTS || Pt, Ft = f.HTML_INTEGRATION_POINTS || Ft, $ = f.CUSTOM_ELEMENT_HANDLING || {}, f.CUSTOM_ELEMENT_HANDLING && Bn(f.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && ($.tagNameCheck = f.CUSTOM_ELEMENT_HANDLING.tagNameCheck), f.CUSTOM_ELEMENT_HANDLING && Bn(f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && ($.attributeNameCheck = f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), f.CUSTOM_ELEMENT_HANDLING && typeof f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && ($.allowCustomizedBuiltInElements = f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), q && (O = !1), rt && ($e = !0), et && (le = Y({}, ms), ie = [], et.html === !0 && (Y(le, gs), Y(ie, ws)), et.svg === !0 && (Y(le, fn), Y(ie, dn), Y(ie, Gt)), et.svgFilters === !0 && (Y(le, hn), Y(ie, dn), Y(ie, Gt)), et.mathMl === !0 && (Y(le, pn), Y(ie, ks), Y(ie, Gt))), f.ADD_TAGS && (le === Xe && (le = nt(le)), Y(le, f.ADD_TAGS, de)), f.ADD_ATTR && (ie === Ee && (ie = nt(ie)), Y(ie, f.ADD_ATTR, de)), f.ADD_URI_SAFE_ATTR && Y(Le, f.ADD_URI_SAFE_ATTR, de), f.FORBID_CONTENTS && (T === G && (T = nt(T)), Y(T, f.FORBID_CONTENTS, de)), bt && (le["#text"] = !0), be && Y(le, ["html", "head", "body"]), le.table && (Y(le, ["tbody"]), delete Re.tbody), f.TRUSTED_TYPES_POLICY) {
2244
+ mi.indexOf(f.PARSER_MEDIA_TYPE) === -1 ? wi : f.PARSER_MEDIA_TYPE, ge = _t === "application/xhtml+xml" ? un : Zt, le = Be(f, "ALLOWED_TAGS") ? Y({}, f.ALLOWED_TAGS, ge) : Xe, ie = Be(f, "ALLOWED_ATTR") ? Y({}, f.ALLOWED_ATTR, ge) : Se, on = Be(f, "ALLOWED_NAMESPACES") ? Y({}, f.ALLOWED_NAMESPACES, un) : di, ue = Be(f, "ADD_URI_SAFE_ATTR") ? Y(nt(We), f.ADD_URI_SAFE_ATTR, ge) : We, V = Be(f, "ADD_DATA_URI_TAGS") ? Y(nt(ce), f.ADD_DATA_URI_TAGS, ge) : ce, _ = Be(f, "FORBID_CONTENTS") ? Y({}, f.FORBID_CONTENTS, ge) : H, ze = Be(f, "FORBID_TAGS") ? Y({}, f.FORBID_TAGS, ge) : {}, be = Be(f, "FORBID_ATTR") ? Y({}, f.FORBID_ATTR, ge) : {}, et = Be(f, "USE_PROFILES") ? f.USE_PROFILES : !1, Ve = f.ALLOW_ARIA_ATTR !== !1, O = f.ALLOW_DATA_ATTR !== !1, ne = f.ALLOW_UNKNOWN_PROTOCOLS || !1, N = f.ALLOW_SELF_CLOSE_IN_ATTR !== !1, G = f.SAFE_FOR_TEMPLATES || !1, _e = f.SAFE_FOR_XML !== !1, ye = f.WHOLE_DOCUMENT || !1, $e = f.RETURN_DOM || !1, rt = f.RETURN_DOM_FRAGMENT || !1, at = f.RETURN_TRUSTED_TYPE || !1, je = f.FORCE_BODY || !1, Ot = f.SANITIZE_DOM !== !1, Dt = f.SANITIZE_NAMED_PROPS || !1, bt = f.KEEP_CONTENT !== !1, tt = f.IN_PLACE || !1, Ue = f.ALLOWED_URI_REGEXP || ui, ct = f.NAMESPACE || Qe, Pt = f.MATHML_TEXT_INTEGRATION_POINTS || Pt, Ft = f.HTML_INTEGRATION_POINTS || Ft, $ = f.CUSTOM_ELEMENT_HANDLING || {}, f.CUSTOM_ELEMENT_HANDLING && Bn(f.CUSTOM_ELEMENT_HANDLING.tagNameCheck) && ($.tagNameCheck = f.CUSTOM_ELEMENT_HANDLING.tagNameCheck), f.CUSTOM_ELEMENT_HANDLING && Bn(f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck) && ($.attributeNameCheck = f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck), f.CUSTOM_ELEMENT_HANDLING && typeof f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements == "boolean" && ($.allowCustomizedBuiltInElements = f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements), G && (O = !1), rt && ($e = !0), et && (le = Y({}, ms), ie = [], et.html === !0 && (Y(le, gs), Y(ie, ws)), et.svg === !0 && (Y(le, fn), Y(ie, dn), Y(ie, qt)), et.svgFilters === !0 && (Y(le, hn), Y(ie, dn), Y(ie, qt)), et.mathMl === !0 && (Y(le, pn), Y(ie, ks), Y(ie, qt))), f.ADD_TAGS && (le === Xe && (le = nt(le)), Y(le, f.ADD_TAGS, ge)), f.ADD_ATTR && (ie === Se && (ie = nt(ie)), Y(ie, f.ADD_ATTR, ge)), f.ADD_URI_SAFE_ATTR && Y(ue, f.ADD_URI_SAFE_ATTR, ge), f.FORBID_CONTENTS && (_ === H && (_ = nt(_)), Y(_, f.FORBID_CONTENTS, ge)), bt && (le["#text"] = !0), ye && Y(le, ["html", "head", "body"]), le.table && (Y(le, ["tbody"]), delete ze.tbody), f.TRUSTED_TYPES_POLICY) {
2245
2245
  if (typeof f.TRUSTED_TYPES_POLICY.createHTML != "function")
2246
2246
  throw St('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');
2247
2247
  if (typeof f.TRUSTED_TYPES_POLICY.createScriptURL != "function")
2248
2248
  throw St('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');
2249
- k = f.TRUSTED_TYPES_POLICY, _ = k.createHTML("");
2249
+ k = f.TRUSTED_TYPES_POLICY, y = k.createHTML("");
2250
2250
  } else
2251
- k === void 0 && (k = Vo(d, i)), k !== null && typeof _ == "string" && (_ = k.createHTML(""));
2252
- xe && xe(f), ut = f;
2251
+ k === void 0 && (k = Qo(g, i)), k !== null && typeof y == "string" && (y = k.createHTML(""));
2252
+ Ie && Ie(f), ut = f;
2253
2253
  }
2254
- }, Un = Y({}, [...fn, ...hn, ...Fo]), jn = Y({}, [...pn, ...Ho]), ki = function(f) {
2254
+ }, Un = Y({}, [...fn, ...hn, ...Ho]), jn = Y({}, [...pn, ...Bo]), bi = function(f) {
2255
2255
  let E = b(f);
2256
2256
  (!E || !E.tagName) && (E = {
2257
2257
  namespaceURI: ct,
2258
2258
  tagName: "template"
2259
2259
  });
2260
2260
  const L = Zt(f.tagName), ae = Zt(E.tagName);
2261
- return on[f.namespaceURI] ? f.namespaceURI === Nt ? E.namespaceURI === Qe ? L === "svg" : E.namespaceURI === pe ? L === "svg" && (ae === "annotation-xml" || Pt[ae]) : !!Un[L] : f.namespaceURI === pe ? E.namespaceURI === Qe ? L === "math" : E.namespaceURI === Nt ? L === "math" && Ft[ae] : !!jn[L] : f.namespaceURI === Qe ? E.namespaceURI === Nt && !Ft[ae] || E.namespaceURI === pe && !Pt[ae] ? !1 : !jn[L] && (di[L] || !Un[L]) : !!(_t === "application/xhtml+xml" && on[f.namespaceURI]) : !1;
2262
- }, Ge = function(f) {
2261
+ return on[f.namespaceURI] ? f.namespaceURI === Nt ? E.namespaceURI === Qe ? L === "svg" : E.namespaceURI === de ? L === "svg" && (ae === "annotation-xml" || Pt[ae]) : !!Un[L] : f.namespaceURI === de ? E.namespaceURI === Qe ? L === "math" : E.namespaceURI === Nt ? L === "math" && Ft[ae] : !!jn[L] : f.namespaceURI === Qe ? E.namespaceURI === Nt && !Ft[ae] || E.namespaceURI === de && !Pt[ae] ? !1 : !jn[L] && (gi[L] || !Un[L]) : !!(_t === "application/xhtml+xml" && on[f.namespaceURI]) : !1;
2262
+ }, qe = function(f) {
2263
2263
  vt(e.removed, {
2264
2264
  element: f
2265
2265
  });
@@ -2283,7 +2283,7 @@ function fi() {
2283
2283
  if (E.removeAttribute(f), f === "is")
2284
2284
  if ($e || rt)
2285
2285
  try {
2286
- Ge(E);
2286
+ qe(E);
2287
2287
  } catch (L) {
2288
2288
  }
2289
2289
  else
@@ -2296,27 +2296,27 @@ function fi() {
2296
2296
  if (je)
2297
2297
  f = "<remove></remove>" + f;
2298
2298
  else {
2299
- const ge = ds(f, /^[\r\n\t ]+/);
2300
- L = ge && ge[0];
2299
+ const we = ds(f, /^[\r\n\t ]+/);
2300
+ L = we && we[0];
2301
2301
  }
2302
2302
  _t === "application/xhtml+xml" && ct === Qe && (f = '<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>' + f + "</body></html>");
2303
2303
  const ae = k ? k.createHTML(f) : f;
2304
2304
  if (ct === Qe)
2305
2305
  try {
2306
- E = new g().parseFromString(ae, _t);
2307
- } catch (ge) {
2306
+ E = new d().parseFromString(ae, _t);
2307
+ } catch (we) {
2308
2308
  }
2309
2309
  if (!E || !E.documentElement) {
2310
2310
  E = A.createDocument(ct, "template", null);
2311
2311
  try {
2312
- E.documentElement.innerHTML = sn ? _ : ae;
2313
- } catch (ge) {
2312
+ E.documentElement.innerHTML = sn ? y : ae;
2313
+ } catch (we) {
2314
2314
  }
2315
2315
  }
2316
- const _e = E.body || E.documentElement;
2317
- return f && L && _e.insertBefore(t.createTextNode(L), _e.childNodes[0] || null), ct === Qe ? R.call(E, be ? "html" : "body")[0] : be ? E.documentElement : _e;
2318
- }, Gn = function(f) {
2319
- return y.call(
2316
+ const Te = E.body || E.documentElement;
2317
+ return f && L && Te.insertBefore(t.createTextNode(L), Te.childNodes[0] || null), ct === Qe ? R.call(E, ye ? "html" : "body")[0] : ye ? E.documentElement : Te;
2318
+ }, qn = function(f) {
2319
+ return T.call(
2320
2320
  f.ownerDocument || f,
2321
2321
  f,
2322
2322
  // eslint-disable-next-line no-bitwise
@@ -2325,7 +2325,7 @@ function fi() {
2325
2325
  );
2326
2326
  }, rn = function(f) {
2327
2327
  return f instanceof p && (typeof f.nodeName != "string" || typeof f.textContent != "string" || typeof f.removeChild != "function" || !(f.attributes instanceof h) || typeof f.removeAttribute != "function" || typeof f.setAttribute != "function" || typeof f.namespaceURI != "string" || typeof f.insertBefore != "function" || typeof f.hasChildNodes != "function");
2328
- }, qn = function(f) {
2328
+ }, Gn = function(f) {
2329
2329
  return typeof a == "function" && f instanceof a;
2330
2330
  };
2331
2331
  function Je(D, f, E) {
@@ -2335,52 +2335,52 @@ function fi() {
2335
2335
  }
2336
2336
  const Yn = function(f) {
2337
2337
  let E = null;
2338
- if (Je(z.beforeSanitizeElements, f, null), rn(f))
2339
- return Ge(f), !0;
2340
- const L = de(f.nodeName);
2341
- if (Je(z.uponSanitizeElement, f, {
2338
+ if (Je(I.beforeSanitizeElements, f, null), rn(f))
2339
+ return qe(f), !0;
2340
+ const L = ge(f.nodeName);
2341
+ if (Je(I.uponSanitizeElement, f, {
2342
2342
  tagName: L,
2343
2343
  allowedTags: le
2344
- }), f.hasChildNodes() && !qn(f.firstElementChild) && Ae(/<[/\w]/g, f.innerHTML) && Ae(/<[/\w]/g, f.textContent) || f.nodeType === xt.progressingInstruction || ke && f.nodeType === xt.comment && Ae(/<[/\w]/g, f.data))
2345
- return Ge(f), !0;
2346
- if (!le[L] || Re[L]) {
2347
- if (!Re[L] && Xn(L) && ($.tagNameCheck instanceof RegExp && Ae($.tagNameCheck, L) || $.tagNameCheck instanceof Function && $.tagNameCheck(L)))
2344
+ }), f.hasChildNodes() && !Gn(f.firstElementChild) && Re(/<[/\w]/g, f.innerHTML) && Re(/<[/\w]/g, f.textContent) || f.nodeType === xt.progressingInstruction || _e && f.nodeType === xt.comment && Re(/<[/\w]/g, f.data))
2345
+ return qe(f), !0;
2346
+ if (!le[L] || ze[L]) {
2347
+ if (!ze[L] && Xn(L) && ($.tagNameCheck instanceof RegExp && Re($.tagNameCheck, L) || $.tagNameCheck instanceof Function && $.tagNameCheck(L)))
2348
2348
  return !1;
2349
- if (bt && !T[L]) {
2350
- const ae = b(f) || f.parentNode, _e = v(f) || f.childNodes;
2351
- if (_e && ae) {
2352
- const ge = _e.length;
2353
- for (let ze = ge - 1; ze >= 0; --ze) {
2354
- const qe = S(_e[ze], !0);
2355
- qe.__removalCount = (f.__removalCount || 0) + 1, ae.insertBefore(qe, M(f));
2349
+ if (bt && !_[L]) {
2350
+ const ae = b(f) || f.parentNode, Te = v(f) || f.childNodes;
2351
+ if (Te && ae) {
2352
+ const we = Te.length;
2353
+ for (let Ce = we - 1; Ce >= 0; --Ce) {
2354
+ const Ge = S(Te[Ce], !0);
2355
+ Ge.__removalCount = (f.__removalCount || 0) + 1, ae.insertBefore(Ge, M(f));
2356
2356
  }
2357
2357
  }
2358
2358
  }
2359
- return Ge(f), !0;
2359
+ return qe(f), !0;
2360
2360
  }
2361
- return f instanceof c && !ki(f) || (L === "noscript" || L === "noembed" || L === "noframes") && Ae(/<\/no(script|embed|frames)/i, f.innerHTML) ? (Ge(f), !0) : (q && f.nodeType === xt.text && (E = f.textContent, Wt([B, Z, V], (ae) => {
2361
+ return f instanceof c && !bi(f) || (L === "noscript" || L === "noembed" || L === "noframes") && Re(/<\/no(script|embed|frames)/i, f.innerHTML) ? (qe(f), !0) : (G && f.nodeType === xt.text && (E = f.textContent, Wt([U, Z, Q], (ae) => {
2362
2362
  E = Et(E, ae, " ");
2363
2363
  }), f.textContent !== E && (vt(e.removed, {
2364
2364
  element: f.cloneNode()
2365
- }), f.textContent = E)), Je(z.afterSanitizeElements, f, null), !1);
2365
+ }), f.textContent = E)), Je(I.afterSanitizeElements, f, null), !1);
2366
2366
  }, Zn = function(f, E, L) {
2367
- if (Ot && (E === "id" || E === "name") && (L in t || L in wi))
2367
+ if (Ot && (E === "id" || E === "name") && (L in t || L in ki))
2368
2368
  return !1;
2369
- if (!(O && !we[E] && Ae(oe, E))) {
2370
- if (!(Ve && Ae(fe, E))) {
2371
- if (!ie[E] || we[E]) {
2369
+ if (!(O && !be[E] && Re(oe, E))) {
2370
+ if (!(Ve && Re(he, E))) {
2371
+ if (!ie[E] || be[E]) {
2372
2372
  if (
2373
2373
  // First condition does a very basic check if a) it's basically a valid custom element tagname AND
2374
2374
  // b) if the tagName passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
2375
2375
  // and c) if the attribute name passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.attributeNameCheck
2376
- !(Xn(f) && ($.tagNameCheck instanceof RegExp && Ae($.tagNameCheck, f) || $.tagNameCheck instanceof Function && $.tagNameCheck(f)) && ($.attributeNameCheck instanceof RegExp && Ae($.attributeNameCheck, E) || $.attributeNameCheck instanceof Function && $.attributeNameCheck(E)) || // Alternative, second condition checks if it's an `is`-attribute, AND
2376
+ !(Xn(f) && ($.tagNameCheck instanceof RegExp && Re($.tagNameCheck, f) || $.tagNameCheck instanceof Function && $.tagNameCheck(f)) && ($.attributeNameCheck instanceof RegExp && Re($.attributeNameCheck, E) || $.attributeNameCheck instanceof Function && $.attributeNameCheck(E)) || // Alternative, second condition checks if it's an `is`-attribute, AND
2377
2377
  // the value passes whatever the user has configured for CUSTOM_ELEMENT_HANDLING.tagNameCheck
2378
- E === "is" && $.allowCustomizedBuiltInElements && ($.tagNameCheck instanceof RegExp && Ae($.tagNameCheck, L) || $.tagNameCheck instanceof Function && $.tagNameCheck(L)))
2378
+ E === "is" && $.allowCustomizedBuiltInElements && ($.tagNameCheck instanceof RegExp && Re($.tagNameCheck, L) || $.tagNameCheck instanceof Function && $.tagNameCheck(L)))
2379
2379
  ) return !1;
2380
- } else if (!Le[E]) {
2381
- if (!Ae(Ue, Et(L, Fe, ""))) {
2382
- if (!((E === "src" || E === "xlink:href" || E === "href") && f !== "script" && Oo(L, "data:") === 0 && J[f])) {
2383
- if (!(ne && !Ae(ce, Et(L, Fe, "")))) {
2380
+ } else if (!ue[E]) {
2381
+ if (!Re(Ue, Et(L, Fe, ""))) {
2382
+ if (!((E === "src" || E === "xlink:href" || E === "href") && f !== "script" && Do(L, "data:") === 0 && V[f])) {
2383
+ if (!(ne && !Re(fe, Et(L, Fe, "")))) {
2384
2384
  if (L)
2385
2385
  return !1;
2386
2386
  }
@@ -2393,7 +2393,7 @@ function fi() {
2393
2393
  }, Xn = function(f) {
2394
2394
  return f !== "annotation-xml" && ds(f, re);
2395
2395
  }, Vn = function(f) {
2396
- Je(z.beforeSanitizeAttributes, f, null);
2396
+ Je(I.beforeSanitizeAttributes, f, null);
2397
2397
  const {
2398
2398
  attributes: E
2399
2399
  } = f;
@@ -2408,55 +2408,55 @@ function fi() {
2408
2408
  };
2409
2409
  let ae = E.length;
2410
2410
  for (; ae--; ) {
2411
- const _e = E[ae], {
2412
- name: ge,
2413
- namespaceURI: ze,
2414
- value: qe
2415
- } = _e, yt = de(ge);
2416
- let Se = ge === "value" ? qe : Do(qe);
2417
- if (L.attrName = yt, L.attrValue = Se, L.keepAttr = !0, L.forceKeepAttr = void 0, Je(z.uponSanitizeAttribute, f, L), Se = L.attrValue, Dt && (yt === "id" || yt === "name") && (Ht(ge, f), Se = nn + Se), ke && Ae(/((--!?|])>)|<\/(style|title)/i, Se)) {
2418
- Ht(ge, f);
2411
+ const Te = E[ae], {
2412
+ name: we,
2413
+ namespaceURI: Ce,
2414
+ value: Ge
2415
+ } = Te, yt = ge(we);
2416
+ let Ae = we === "value" ? Ge : No(Ge);
2417
+ if (L.attrName = yt, L.attrValue = Ae, L.keepAttr = !0, L.forceKeepAttr = void 0, Je(I.uponSanitizeAttribute, f, L), Ae = L.attrValue, Dt && (yt === "id" || yt === "name") && (Ht(we, f), Ae = nn + Ae), _e && Re(/((--!?|])>)|<\/(style|title)/i, Ae)) {
2418
+ Ht(we, f);
2419
2419
  continue;
2420
2420
  }
2421
- if (L.forceKeepAttr || (Ht(ge, f), !L.keepAttr))
2421
+ if (L.forceKeepAttr || (Ht(we, f), !L.keepAttr))
2422
2422
  continue;
2423
- if (!N && Ae(/\/>/i, Se)) {
2424
- Ht(ge, f);
2423
+ if (!N && Re(/\/>/i, Ae)) {
2424
+ Ht(we, f);
2425
2425
  continue;
2426
2426
  }
2427
- q && Wt([B, Z, V], (Jn) => {
2428
- Se = Et(Se, Jn, " ");
2427
+ G && Wt([U, Z, Q], (Jn) => {
2428
+ Ae = Et(Ae, Jn, " ");
2429
2429
  });
2430
- const Qn = de(f.nodeName);
2431
- if (Zn(Qn, yt, Se)) {
2432
- if (k && typeof d == "object" && typeof d.getAttributeType == "function" && !ze)
2433
- switch (d.getAttributeType(Qn, yt)) {
2430
+ const Qn = ge(f.nodeName);
2431
+ if (Zn(Qn, yt, Ae)) {
2432
+ if (k && typeof g == "object" && typeof g.getAttributeType == "function" && !Ce)
2433
+ switch (g.getAttributeType(Qn, yt)) {
2434
2434
  case "TrustedHTML": {
2435
- Se = k.createHTML(Se);
2435
+ Ae = k.createHTML(Ae);
2436
2436
  break;
2437
2437
  }
2438
2438
  case "TrustedScriptURL": {
2439
- Se = k.createScriptURL(Se);
2439
+ Ae = k.createScriptURL(Ae);
2440
2440
  break;
2441
2441
  }
2442
2442
  }
2443
2443
  try {
2444
- ze ? f.setAttributeNS(ze, ge, Se) : f.setAttribute(ge, Se), rn(f) ? Ge(f) : ps(e.removed);
2444
+ Ce ? f.setAttributeNS(Ce, we, Ae) : f.setAttribute(we, Ae), rn(f) ? qe(f) : ps(e.removed);
2445
2445
  } catch (Jn) {
2446
2446
  }
2447
2447
  }
2448
2448
  }
2449
- Je(z.afterSanitizeAttributes, f, null);
2450
- }, bi = function D(f) {
2449
+ Je(I.afterSanitizeAttributes, f, null);
2450
+ }, _i = function D(f) {
2451
2451
  let E = null;
2452
- const L = Gn(f);
2453
- for (Je(z.beforeSanitizeShadowDOM, f, null); E = L.nextNode(); )
2454
- Je(z.uponSanitizeShadowNode, E, null), Yn(E), Vn(E), E.content instanceof o && D(E.content);
2455
- Je(z.afterSanitizeShadowDOM, f, null);
2452
+ const L = qn(f);
2453
+ for (Je(I.beforeSanitizeShadowDOM, f, null); E = L.nextNode(); )
2454
+ Je(I.uponSanitizeShadowNode, E, null), Yn(E), Vn(E), E.content instanceof o && D(E.content);
2455
+ Je(I.afterSanitizeShadowDOM, f, null);
2456
2456
  };
2457
2457
  return e.sanitize = function(D) {
2458
- let f = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, E = null, L = null, ae = null, _e = null;
2459
- if (sn = !D, sn && (D = "<!-->"), typeof D != "string" && !qn(D))
2458
+ let f = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, E = null, L = null, ae = null, Te = null;
2459
+ if (sn = !D, sn && (D = "<!-->"), typeof D != "string" && !Gn(D))
2460
2460
  if (typeof D.toString == "function") {
2461
2461
  if (D = D.toString(), typeof D != "string")
2462
2462
  throw St("dirty is not a string, aborting");
@@ -2466,38 +2466,38 @@ function fi() {
2466
2466
  return D;
2467
2467
  if (He || ln(f), e.removed = [], typeof D == "string" && (tt = !1), tt) {
2468
2468
  if (D.nodeName) {
2469
- const qe = de(D.nodeName);
2470
- if (!le[qe] || Re[qe])
2469
+ const Ge = ge(D.nodeName);
2470
+ if (!le[Ge] || ze[Ge])
2471
2471
  throw St("root node is forbidden and cannot be sanitized in-place");
2472
2472
  }
2473
2473
  } else if (D instanceof a)
2474
2474
  E = Wn("<!---->"), L = E.ownerDocument.importNode(D, !0), L.nodeType === xt.element && L.nodeName === "BODY" || L.nodeName === "HTML" ? E = L : E.appendChild(L);
2475
2475
  else {
2476
- if (!$e && !q && !be && // eslint-disable-next-line unicorn/prefer-includes
2476
+ if (!$e && !G && !ye && // eslint-disable-next-line unicorn/prefer-includes
2477
2477
  D.indexOf("<") === -1)
2478
2478
  return k && at ? k.createHTML(D) : D;
2479
2479
  if (E = Wn(D), !E)
2480
- return $e ? null : at ? _ : "";
2480
+ return $e ? null : at ? y : "";
2481
2481
  }
2482
- E && je && Ge(E.firstChild);
2483
- const ge = Gn(tt ? D : E);
2484
- for (; ae = ge.nextNode(); )
2485
- Yn(ae), Vn(ae), ae.content instanceof o && bi(ae.content);
2482
+ E && je && qe(E.firstChild);
2483
+ const we = qn(tt ? D : E);
2484
+ for (; ae = we.nextNode(); )
2485
+ Yn(ae), Vn(ae), ae.content instanceof o && _i(ae.content);
2486
2486
  if (tt)
2487
2487
  return D;
2488
2488
  if ($e) {
2489
2489
  if (rt)
2490
- for (_e = I.call(E.ownerDocument); E.firstChild; )
2491
- _e.appendChild(E.firstChild);
2490
+ for (Te = z.call(E.ownerDocument); E.firstChild; )
2491
+ Te.appendChild(E.firstChild);
2492
2492
  else
2493
- _e = E;
2494
- return (ie.shadowroot || ie.shadowrootmode) && (_e = P.call(n, _e, !0)), _e;
2493
+ Te = E;
2494
+ return (ie.shadowroot || ie.shadowrootmode) && (Te = P.call(n, Te, !0)), Te;
2495
2495
  }
2496
- let ze = be ? E.outerHTML : E.innerHTML;
2497
- return be && le["!doctype"] && E.ownerDocument && E.ownerDocument.doctype && E.ownerDocument.doctype.name && Ae(ui, E.ownerDocument.doctype.name) && (ze = "<!DOCTYPE " + E.ownerDocument.doctype.name + `>
2498
- ` + ze), q && Wt([B, Z, V], (qe) => {
2499
- ze = Et(ze, qe, " ");
2500
- }), k && at ? k.createHTML(ze) : ze;
2496
+ let Ce = ye ? E.outerHTML : E.innerHTML;
2497
+ return ye && le["!doctype"] && E.ownerDocument && E.ownerDocument.doctype && E.ownerDocument.doctype.name && Re(fi, E.ownerDocument.doctype.name) && (Ce = "<!DOCTYPE " + E.ownerDocument.doctype.name + `>
2498
+ ` + Ce), G && Wt([U, Z, Q], (Ge) => {
2499
+ Ce = Et(Ce, Ge, " ");
2500
+ }), k && at ? k.createHTML(Ce) : Ce;
2501
2501
  }, e.setConfig = function() {
2502
2502
  let D = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
2503
2503
  ln(D), He = !0;
@@ -2505,26 +2505,26 @@ function fi() {
2505
2505
  ut = null, He = !1;
2506
2506
  }, e.isValidAttribute = function(D, f, E) {
2507
2507
  ut || ln({});
2508
- const L = de(D), ae = de(f);
2508
+ const L = ge(D), ae = ge(f);
2509
2509
  return Zn(L, ae, E);
2510
2510
  }, e.addHook = function(D, f) {
2511
- typeof f == "function" && vt(z[D], f);
2511
+ typeof f == "function" && vt(I[D], f);
2512
2512
  }, e.removeHook = function(D) {
2513
- return ps(z[D]);
2513
+ return ps(I[D]);
2514
2514
  }, e.removeHooks = function(D) {
2515
- z[D] = [];
2515
+ I[D] = [];
2516
2516
  }, e.removeAllHooks = function() {
2517
- z = _s();
2517
+ I = _s();
2518
2518
  }, e;
2519
2519
  }
2520
- var ys = fi();
2520
+ var ys = hi();
2521
2521
  function Ts(s) {
2522
2522
  var n;
2523
2523
  if (typeof document == "undefined") return null;
2524
2524
  const t = `; ${document.cookie}`.split(`; ${s}=`);
2525
2525
  return t.length === 2 && ((n = t.pop()) == null ? void 0 : n.split(";").shift()) || null;
2526
2526
  }
2527
- const ye = () => {
2527
+ const me = () => {
2528
2528
  if (typeof window == "undefined") return null;
2529
2529
  const s = Ts("access_token");
2530
2530
  if (s) return s;
@@ -2551,7 +2551,7 @@ function Es(s) {
2551
2551
  ), n;
2552
2552
  return {
2553
2553
  c() {
2554
- e = x("div"), n = Te(t), r(e, "class", "sy-assistant-button-tooltip svelte-1g6fj9a"), F(
2554
+ e = x("div"), n = ve(t), r(e, "class", "sy-assistant-button-tooltip svelte-1g6fj9a"), F(
2555
2555
  e,
2556
2556
  "left",
2557
2557
  /*buttonTooltip*/
@@ -2569,7 +2569,7 @@ function Es(s) {
2569
2569
  );
2570
2570
  },
2571
2571
  m(i, o) {
2572
- W(i, e, o), m(e, n);
2572
+ q(i, e, o), m(e, n);
2573
2573
  },
2574
2574
  p(i, o) {
2575
2575
  o & /*buttonTooltip*/
@@ -2595,18 +2595,18 @@ function Es(s) {
2595
2595
  );
2596
2596
  },
2597
2597
  d(i) {
2598
- i && U(e);
2598
+ i && j(e);
2599
2599
  }
2600
2600
  };
2601
2601
  }
2602
- function Qo(s) {
2602
+ function Jo(s) {
2603
2603
  let e = [], t = /* @__PURE__ */ new Map(), n, i, o = kt(
2604
2604
  /*sessions*/
2605
2605
  s[0]
2606
2606
  );
2607
2607
  const l = (c) => (
2608
2608
  /*session*/
2609
- c[24].id
2609
+ c[24].sessionId
2610
2610
  );
2611
2611
  for (let c = 0; c < o.length; c += 1) {
2612
2612
  let u = vs(s, o, c), h = l(u);
@@ -2620,30 +2620,30 @@ function Qo(s) {
2620
2620
  c() {
2621
2621
  for (let c = 0; c < e.length; c += 1)
2622
2622
  e[c].c();
2623
- n = j(), a && a.c(), i = Kt();
2623
+ n = W(), a && a.c(), i = Kt();
2624
2624
  },
2625
2625
  m(c, u) {
2626
2626
  for (let h = 0; h < e.length; h += 1)
2627
2627
  e[h] && e[h].m(c, u);
2628
- W(c, n, u), a && a.m(c, u), W(c, i, u);
2628
+ q(c, n, u), a && a.m(c, u), q(c, i, u);
2629
2629
  },
2630
2630
  p(c, u) {
2631
2631
  u & /*sessions, deletingSessionId, showDeleteConfirm, onSelect, formatDate*/
2632
2632
  8261 && (o = kt(
2633
2633
  /*sessions*/
2634
2634
  c[0]
2635
- ), e = Vs(e, u, l, 1, c, o, t, n.parentNode, Xs, Ss, n, vs)), /*isLoading*/
2635
+ ), e = Qs(e, u, l, 1, c, o, t, n.parentNode, Vs, Ss, n, vs)), /*isLoading*/
2636
2636
  c[5] ? a || (a = As(), a.c(), a.m(i.parentNode, i)) : a && (a.d(1), a = null);
2637
2637
  },
2638
2638
  d(c) {
2639
- c && (U(n), U(i));
2639
+ c && (j(n), j(i));
2640
2640
  for (let u = 0; u < e.length; u += 1)
2641
2641
  e[u].d(c);
2642
2642
  a && a.d(c);
2643
2643
  }
2644
2644
  };
2645
2645
  }
2646
- function Jo(s) {
2646
+ function Ko(s) {
2647
2647
  let e, t = (
2648
2648
  /*searchQuery*/
2649
2649
  s[4] ? "未找到相关会话" : (
@@ -2653,10 +2653,10 @@ function Jo(s) {
2653
2653
  ), n;
2654
2654
  return {
2655
2655
  c() {
2656
- e = x("div"), n = Te(t), r(e, "class", "sy-session-empty svelte-1g6fj9a");
2656
+ e = x("div"), n = ve(t), r(e, "class", "sy-session-empty svelte-1g6fj9a");
2657
2657
  },
2658
2658
  m(i, o) {
2659
- W(i, e, o), m(e, n);
2659
+ q(i, e, o), m(e, n);
2660
2660
  },
2661
2661
  p(i, o) {
2662
2662
  o & /*searchQuery, isLoading*/
@@ -2667,7 +2667,7 @@ function Jo(s) {
2667
2667
  )) && De(n, t);
2668
2668
  },
2669
2669
  d(i) {
2670
- i && U(e);
2670
+ i && j(e);
2671
2671
  }
2672
2672
  };
2673
2673
  }
@@ -2678,7 +2678,7 @@ function Ss(s, e) {
2678
2678
  ), a, c, u, h = Rs(
2679
2679
  /*session*/
2680
2680
  e[24].timestamp
2681
- ) + "", p, g, d, w, S, C, M, v, b, k, _;
2681
+ ) + "", p, d, g, w, S, C, M, v, b, k, y;
2682
2682
  function A() {
2683
2683
  return (
2684
2684
  /*click_handler*/
@@ -2688,13 +2688,13 @@ function Ss(s, e) {
2688
2688
  )
2689
2689
  );
2690
2690
  }
2691
- function y(...I) {
2691
+ function T(...z) {
2692
2692
  return (
2693
2693
  /*click_handler_1*/
2694
2694
  e[18](
2695
2695
  /*session*/
2696
2696
  e[24],
2697
- ...I
2697
+ ...z
2698
2698
  )
2699
2699
  );
2700
2700
  }
@@ -2702,24 +2702,24 @@ function Ss(s, e) {
2702
2702
  key: s,
2703
2703
  first: null,
2704
2704
  c() {
2705
- t = x("div"), n = x("button"), i = x("div"), o = x("div"), a = Te(l), c = j(), u = x("div"), p = Te(h), g = j(), d = x("button"), w = X("svg"), S = X("path"), C = X("path"), M = X("path"), r(o, "class", "sy-session-title svelte-1g6fj9a"), r(u, "class", "sy-session-time svelte-1g6fj9a"), r(i, "class", "sy-session-info svelte-1g6fj9a"), r(n, "class", "sy-session-select svelte-1g6fj9a"), r(S, "d", "M3 6h18"), r(C, "d", "M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"), r(M, "d", "M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"), r(w, "xmlns", "http://www.w3.org/2000/svg"), r(w, "width", "16"), r(w, "height", "16"), r(w, "viewBox", "0 0 24 24"), r(w, "fill", "none"), r(w, "stroke", "currentColor"), r(w, "stroke-width", "2"), r(w, "stroke-linecap", "round"), r(w, "stroke-linejoin", "round"), r(d, "class", "sy-session-delete svelte-1g6fj9a"), d.disabled = v = /*deletingSessionId*/
2705
+ t = x("div"), n = x("button"), i = x("div"), o = x("div"), a = ve(l), c = W(), u = x("div"), p = ve(h), d = W(), g = x("button"), w = X("svg"), S = X("path"), C = X("path"), M = X("path"), r(o, "class", "sy-session-title svelte-1g6fj9a"), r(u, "class", "sy-session-time svelte-1g6fj9a"), r(i, "class", "sy-session-info svelte-1g6fj9a"), r(n, "class", "sy-session-select svelte-1g6fj9a"), r(S, "d", "M3 6h18"), r(C, "d", "M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"), r(M, "d", "M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"), r(w, "xmlns", "http://www.w3.org/2000/svg"), r(w, "width", "16"), r(w, "height", "16"), r(w, "viewBox", "0 0 24 24"), r(w, "fill", "none"), r(w, "stroke", "currentColor"), r(w, "stroke-width", "2"), r(w, "stroke-linecap", "round"), r(w, "stroke-linejoin", "round"), r(g, "class", "sy-session-delete svelte-1g6fj9a"), g.disabled = v = /*deletingSessionId*/
2706
2706
  e[6] === /*session*/
2707
- e[24].id, r(d, "aria-label", "删除会话"), r(t, "class", "sy-session-item svelte-1g6fj9a"), r(t, "data-session-id", b = /*session*/
2708
- e[24].id), Q(
2707
+ e[24].sessionId, r(g, "aria-label", "删除会话"), r(t, "class", "sy-session-item svelte-1g6fj9a"), r(t, "data-session-id", b = /*session*/
2708
+ e[24].sessionId), J(
2709
2709
  t,
2710
2710
  "deleting",
2711
2711
  /*session*/
2712
2712
  e[24].deleting
2713
2713
  ), this.first = t;
2714
2714
  },
2715
- m(I, R) {
2716
- W(I, t, R), m(t, n), m(n, i), m(i, o), m(o, a), m(i, c), m(i, u), m(u, p), m(t, g), m(t, d), m(d, w), m(w, S), m(w, C), m(w, M), k || (_ = [
2717
- H(n, "click", A),
2718
- H(d, "click", y)
2715
+ m(z, R) {
2716
+ q(z, t, R), m(t, n), m(n, i), m(i, o), m(o, a), m(i, c), m(i, u), m(u, p), m(t, d), m(t, g), m(g, w), m(w, S), m(w, C), m(w, M), k || (y = [
2717
+ B(n, "click", A),
2718
+ B(g, "click", T)
2719
2719
  ], k = !0);
2720
2720
  },
2721
- p(I, R) {
2722
- e = I, R & /*sessions*/
2721
+ p(z, R) {
2722
+ e = z, R & /*sessions*/
2723
2723
  1 && l !== (l = /*session*/
2724
2724
  e[24].title + "") && De(a, l), R & /*sessions*/
2725
2725
  1 && h !== (h = Rs(
@@ -2728,18 +2728,18 @@ function Ss(s, e) {
2728
2728
  ) + "") && De(p, h), R & /*deletingSessionId, sessions*/
2729
2729
  65 && v !== (v = /*deletingSessionId*/
2730
2730
  e[6] === /*session*/
2731
- e[24].id) && (d.disabled = v), R & /*sessions*/
2731
+ e[24].sessionId) && (g.disabled = v), R & /*sessions*/
2732
2732
  1 && b !== (b = /*session*/
2733
- e[24].id) && r(t, "data-session-id", b), R & /*sessions*/
2734
- 1 && Q(
2733
+ e[24].sessionId) && r(t, "data-session-id", b), R & /*sessions*/
2734
+ 1 && J(
2735
2735
  t,
2736
2736
  "deleting",
2737
2737
  /*session*/
2738
2738
  e[24].deleting
2739
2739
  );
2740
2740
  },
2741
- d(I) {
2742
- I && U(t), k = !1, ve(_);
2741
+ d(z) {
2742
+ z && j(t), k = !1, Ee(y);
2743
2743
  }
2744
2744
  };
2745
2745
  }
@@ -2750,10 +2750,10 @@ function As(s) {
2750
2750
  e = x("div"), e.innerHTML = '<span class="loading-dot svelte-1g6fj9a"></span> <span class="loading-dot svelte-1g6fj9a"></span> <span class="loading-dot svelte-1g6fj9a"></span>', r(e, "class", "sy-session-loading svelte-1g6fj9a");
2751
2751
  },
2752
2752
  m(t, n) {
2753
- W(t, e, n);
2753
+ q(t, e, n);
2754
2754
  },
2755
2755
  d(t) {
2756
- t && U(e);
2756
+ t && j(e);
2757
2757
  }
2758
2758
  };
2759
2759
  }
@@ -2761,7 +2761,7 @@ function xs(s) {
2761
2761
  let e, t, n, i, o, l, a, c, u;
2762
2762
  return {
2763
2763
  c() {
2764
- e = x("div"), t = x("div"), t.textContent = "确认删除此会话?", n = j(), i = x("div"), o = x("button"), o.textContent = "取消", l = j(), a = x("button"), a.textContent = "删除", r(t, "class", "sy-session-confirm-content svelte-1g6fj9a"), r(o, "class", "sy-session-confirm-cancel svelte-1g6fj9a"), r(a, "class", "sy-session-confirm-delete svelte-1g6fj9a"), r(i, "class", "sy-session-confirm-actions svelte-1g6fj9a"), r(e, "class", "sy-session-confirm-popup svelte-1g6fj9a"), F(
2764
+ e = x("div"), t = x("div"), t.textContent = "确认删除此会话?", n = W(), i = x("div"), o = x("button"), o.textContent = "取消", l = W(), a = x("button"), a.textContent = "删除", r(t, "class", "sy-session-confirm-content svelte-1g6fj9a"), r(o, "class", "sy-session-confirm-cancel svelte-1g6fj9a"), r(a, "class", "sy-session-confirm-delete svelte-1g6fj9a"), r(i, "class", "sy-session-confirm-actions svelte-1g6fj9a"), r(e, "class", "sy-session-confirm-popup svelte-1g6fj9a"), F(
2765
2765
  e,
2766
2766
  "left",
2767
2767
  /*confirmPosition*/
@@ -2779,14 +2779,14 @@ function xs(s) {
2779
2779
  );
2780
2780
  },
2781
2781
  m(h, p) {
2782
- W(h, e, p), m(e, t), m(e, n), m(e, i), m(i, o), m(i, l), m(i, a), c || (u = [
2783
- H(
2782
+ q(h, e, p), m(e, t), m(e, n), m(e, i), m(i, o), m(i, l), m(i, a), c || (u = [
2783
+ B(
2784
2784
  o,
2785
2785
  "click",
2786
2786
  /*click_handler_2*/
2787
2787
  s[19]
2788
2788
  ),
2789
- H(
2789
+ B(
2790
2790
  a,
2791
2791
  "click",
2792
2792
  /*handleConfirmDelete*/
@@ -2816,28 +2816,28 @@ function xs(s) {
2816
2816
  );
2817
2817
  },
2818
2818
  d(h) {
2819
- h && U(e), c = !1, ve(u);
2819
+ h && j(e), c = !1, Ee(u);
2820
2820
  }
2821
2821
  };
2822
2822
  }
2823
- function Ko(s) {
2824
- let e, t, n, i, o, l, a, c, u, h, p, g, d, w, S, C, M, v, b, k = (
2823
+ function $o(s) {
2824
+ let e, t, n, i, o, l, a, c, u, h, p, d, g, w, S, C, M, v, b, k = (
2825
2825
  /*buttonTooltip*/
2826
2826
  s[9] && Es(s)
2827
2827
  );
2828
- function _(R, P) {
2828
+ function y(R, P) {
2829
2829
  return (
2830
2830
  /*sessions*/
2831
- R[0].length === 0 ? Jo : Qo
2831
+ R[0].length === 0 ? Ko : Jo
2832
2832
  );
2833
2833
  }
2834
- let A = _(s), y = A(s), I = (
2834
+ let A = y(s), T = A(s), z = (
2835
2835
  /*confirmDeleteId*/
2836
2836
  s[7] && xs(s)
2837
2837
  );
2838
2838
  return {
2839
2839
  c() {
2840
- e = x("div"), t = x("div"), n = x("h2"), n.textContent = "历史会话", i = j(), o = x("button"), o.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>', l = j(), a = x("div"), c = x("input"), u = j(), h = X("svg"), p = X("circle"), g = X("line"), d = j(), k && k.c(), w = j(), S = x("div"), y.c(), C = j(), I && I.c(), M = Kt(), r(n, "class", "svelte-1g6fj9a"), r(o, "class", "sy-session-close svelte-1g6fj9a"), r(o, "aria-label", "关闭历史会话"), r(t, "class", "sy-session-header svelte-1g6fj9a"), r(c, "type", "text"), r(c, "class", "sy-session-search-input svelte-1g6fj9a"), r(c, "placeholder", "搜索历史会话..."), r(p, "cx", "11"), r(p, "cy", "11"), r(p, "r", "8"), r(g, "x1", "21"), r(g, "y1", "21"), r(g, "x2", "16.65"), r(g, "y2", "16.65"), r(h, "class", "sy-session-search-icon svelte-1g6fj9a"), r(h, "xmlns", "http://www.w3.org/2000/svg"), r(h, "width", "16"), r(h, "height", "16"), r(h, "viewBox", "0 0 24 24"), r(h, "fill", "none"), r(h, "stroke", "currentColor"), r(h, "stroke-width", "2"), r(h, "stroke-linecap", "round"), r(h, "stroke-linejoin", "round"), r(a, "class", "sy-session-search svelte-1g6fj9a"), r(S, "class", "sy-session-list svelte-1g6fj9a"), r(e, "class", "sy-session-history svelte-1g6fj9a"), F(
2840
+ e = x("div"), t = x("div"), n = x("h2"), n.textContent = "历史会话", i = W(), o = x("button"), o.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>', l = W(), a = x("div"), c = x("input"), u = W(), h = X("svg"), p = X("circle"), d = X("line"), g = W(), k && k.c(), w = W(), S = x("div"), T.c(), C = W(), z && z.c(), M = Kt(), r(n, "class", "svelte-1g6fj9a"), r(o, "class", "sy-session-close svelte-1g6fj9a"), r(o, "aria-label", "关闭历史会话"), r(t, "class", "sy-session-header svelte-1g6fj9a"), r(c, "type", "text"), r(c, "class", "sy-session-search-input svelte-1g6fj9a"), r(c, "placeholder", "搜索历史会话..."), r(p, "cx", "11"), r(p, "cy", "11"), r(p, "r", "8"), r(d, "x1", "21"), r(d, "y1", "21"), r(d, "x2", "16.65"), r(d, "y2", "16.65"), r(h, "class", "sy-session-search-icon svelte-1g6fj9a"), r(h, "xmlns", "http://www.w3.org/2000/svg"), r(h, "width", "16"), r(h, "height", "16"), r(h, "viewBox", "0 0 24 24"), r(h, "fill", "none"), r(h, "stroke", "currentColor"), r(h, "stroke-width", "2"), r(h, "stroke-linecap", "round"), r(h, "stroke-linejoin", "round"), r(a, "class", "sy-session-search svelte-1g6fj9a"), r(S, "class", "sy-session-list svelte-1g6fj9a"), r(e, "class", "sy-session-history svelte-1g6fj9a"), F(
2841
2841
  e,
2842
2842
  "z-index",
2843
2843
  /*zIndex*/
@@ -2845,36 +2845,36 @@ function Ko(s) {
2845
2845
  );
2846
2846
  },
2847
2847
  m(R, P) {
2848
- W(R, e, P), m(e, t), m(t, n), m(t, i), m(t, o), m(e, l), m(e, a), m(a, c), mt(
2848
+ q(R, e, P), m(e, t), m(t, n), m(t, i), m(t, o), m(e, l), m(e, a), m(a, c), mt(
2849
2849
  c,
2850
2850
  /*searchQuery*/
2851
2851
  s[4]
2852
- ), m(a, u), m(a, h), m(h, p), m(h, g), m(e, d), k && k.m(e, null), m(e, w), m(e, S), y.m(S, null), W(R, C, P), I && I.m(R, P), W(R, M, P), v || (b = [
2853
- H(o, "click", function() {
2852
+ ), m(a, u), m(a, h), m(h, p), m(h, d), m(e, g), k && k.m(e, null), m(e, w), m(e, S), T.m(S, null), q(R, C, P), z && z.m(R, P), q(R, M, P), v || (b = [
2853
+ B(o, "click", function() {
2854
2854
  An(
2855
2855
  /*onClose*/
2856
2856
  s[1]
2857
2857
  ) && s[1].apply(this, arguments);
2858
2858
  }),
2859
- H(
2859
+ B(
2860
2860
  o,
2861
2861
  "mouseenter",
2862
2862
  /*mouseenter_handler*/
2863
2863
  s[15]
2864
2864
  ),
2865
- H(
2865
+ B(
2866
2866
  o,
2867
2867
  "mouseleave",
2868
2868
  /*hideButtonTooltip*/
2869
2869
  s[12]
2870
2870
  ),
2871
- H(
2871
+ B(
2872
2872
  c,
2873
2873
  "input",
2874
2874
  /*input_input_handler*/
2875
2875
  s[16]
2876
2876
  ),
2877
- H(
2877
+ B(
2878
2878
  S,
2879
2879
  "scroll",
2880
2880
  /*handleScroll*/
@@ -2890,19 +2890,19 @@ function Ko(s) {
2890
2890
  /*searchQuery*/
2891
2891
  s[4]
2892
2892
  ), /*buttonTooltip*/
2893
- s[9] ? k ? k.p(s, P) : (k = Es(s), k.c(), k.m(e, w)) : k && (k.d(1), k = null), A === (A = _(s)) && y ? y.p(s, P) : (y.d(1), y = A(s), y && (y.c(), y.m(S, null))), P & /*zIndex*/
2893
+ s[9] ? k ? k.p(s, P) : (k = Es(s), k.c(), k.m(e, w)) : k && (k.d(1), k = null), A === (A = y(s)) && T ? T.p(s, P) : (T.d(1), T = A(s), T && (T.c(), T.m(S, null))), P & /*zIndex*/
2894
2894
  8 && F(
2895
2895
  e,
2896
2896
  "z-index",
2897
2897
  /*zIndex*/
2898
2898
  s[3] + 2
2899
2899
  ), /*confirmDeleteId*/
2900
- s[7] ? I ? I.p(s, P) : (I = xs(s), I.c(), I.m(M.parentNode, M)) : I && (I.d(1), I = null);
2900
+ s[7] ? z ? z.p(s, P) : (z = xs(s), z.c(), z.m(M.parentNode, M)) : z && (z.d(1), z = null);
2901
2901
  },
2902
- i: Ce,
2903
- o: Ce,
2902
+ i: Le,
2903
+ o: Le,
2904
2904
  d(R) {
2905
- R && (U(e), U(C), U(M)), k && k.d(), y.d(), I && I.d(R), v = !1, ve(b);
2905
+ R && (j(e), j(C), j(M)), k && k.d(), T.d(), z && z.d(R), v = !1, Ee(b);
2906
2906
  }
2907
2907
  };
2908
2908
  }
@@ -2910,115 +2910,117 @@ const gn = 10;
2910
2910
  function Rs(s) {
2911
2911
  return new Date(s).toLocaleString();
2912
2912
  }
2913
- function $o(s, e, t) {
2914
- let { sessions: n = [] } = e, { onClose: i } = e, { onSelect: o } = e, { zIndex: l } = e, a = !1, c = !0, u = 0, h = "", p = null, g = null, d = { x: 0, y: 0 };
2913
+ function el(s, e, t) {
2914
+ let { sessions: n = [] } = e, { onClose: i } = e, { onSelect: o } = e, { zIndex: l } = e, a = !1, c = !0, u = 0, h = "", p = null, d = null, g = { x: 0, y: 0 };
2915
2915
  function w() {
2916
- return Ie(this, null, function* () {
2916
+ return xe(this, null, function* () {
2917
2917
  if (!(a || !c)) {
2918
2918
  t(5, a = !0);
2919
2919
  try {
2920
- const z = yield fetch("/aiops/aigc/chat/record/session/list/query", {
2920
+ const I = yield fetch("/aiops/aigc/chat/record/session/list/query", {
2921
2921
  method: "POST",
2922
2922
  headers: {
2923
2923
  "Content-Type": "application/json",
2924
- "Auth-Token": `${ye()}`,
2925
- Authorization: `bearer ${ye()}`
2924
+ "Auth-Token": `${me()}`,
2925
+ Authorization: `bearer ${me()}`
2926
2926
  },
2927
2927
  body: JSON.stringify({ start: u, length: gn, keyword: h })
2928
2928
  });
2929
- if (!z.ok)
2929
+ if (!I.ok)
2930
2930
  throw new Error("Failed to load sessions");
2931
- const B = yield z.json();
2932
- if (B.code === 0) {
2933
- const Z = B.data.sessionList.map((V) => ({
2934
- id: V.session_id,
2935
- title: V.name,
2936
- timestamp: new Date(V.createDate).getTime()
2931
+ const U = yield I.json();
2932
+ if (U.code === 0) {
2933
+ const Z = U.data.sessionList.map((Q) => ({
2934
+ sessionId: Q.sessionId,
2935
+ title: Q.name,
2936
+ timestamp: new Date(Q.createDate).getTime()
2937
2937
  }));
2938
2938
  t(0, n = [...n, ...Z]), u += gn, c = Z.length === gn;
2939
2939
  }
2940
- } catch (z) {
2941
- console.error("Failed to load sessions:", z);
2940
+ } catch (I) {
2941
+ console.error("Failed to load sessions:", I);
2942
2942
  } finally {
2943
2943
  t(5, a = !1);
2944
2944
  }
2945
2945
  }
2946
2946
  });
2947
2947
  }
2948
- function S(z) {
2949
- const B = z.target, { scrollTop: Z, scrollHeight: V, clientHeight: oe } = B;
2950
- V - Z - oe < 50 && w();
2948
+ function S(I) {
2949
+ const U = I.target, { scrollTop: Z, scrollHeight: Q, clientHeight: oe } = U;
2950
+ Q - Z - oe < 50 && w();
2951
2951
  }
2952
- Ys(() => {
2952
+ Zs(() => {
2953
2953
  w();
2954
2954
  });
2955
2955
  let C = null;
2956
- function M(z, B) {
2957
- const V = z.currentTarget.getBoundingClientRect();
2956
+ function M(I, U) {
2957
+ const Q = I.currentTarget.getBoundingClientRect();
2958
2958
  t(9, C = {
2959
- text: B,
2960
- x: V.left + V.width / 2,
2961
- y: V.bottom + 8
2959
+ text: U,
2960
+ x: Q.left + Q.width / 2,
2961
+ y: Q.bottom + 8
2962
2962
  });
2963
2963
  }
2964
2964
  function v() {
2965
2965
  t(9, C = null);
2966
2966
  }
2967
- function b(z, B) {
2968
- const V = z.currentTarget.getBoundingClientRect();
2969
- t(8, d = {
2970
- x: V.left - 16,
2967
+ function b(I, U) {
2968
+ const Q = I.currentTarget.getBoundingClientRect();
2969
+ t(8, g = {
2970
+ x: Q.left - 16,
2971
2971
  // 靠近删除按钮
2972
- y: V.top + V.height / 2
2973
- }), t(7, g = B);
2972
+ y: Q.top + Q.height / 2
2973
+ }), t(7, d = U);
2974
2974
  }
2975
- function k(z) {
2976
- return Ie(this, null, function* () {
2977
- if (z && !p)
2975
+ function k(I) {
2976
+ return xe(this, null, function* () {
2977
+ if (I && !p)
2978
2978
  try {
2979
- t(6, p = z), t(7, g = null);
2980
- const B = document.querySelector(`[data-session-id="${z}"]`);
2981
- B && B.classList.add("deleting"), yield new Promise((oe) => setTimeout(oe, 300));
2979
+ t(6, p = I), t(7, d = null);
2980
+ const U = document.querySelector(`[data-session-id="${I}"]`);
2981
+ U && U.classList.add("deleting"), yield new Promise((oe) => setTimeout(oe, 300));
2982
2982
  const Z = yield fetch("/aiops/aigc/chat/record/session/delete", {
2983
2983
  method: "POST",
2984
2984
  headers: {
2985
2985
  "Content-Type": "application/json",
2986
- "Auth-Token": `${ye()}`,
2987
- Authorization: `bearer ${ye()}`
2986
+ "Auth-Token": `${me()}`,
2987
+ Authorization: `bearer ${me()}`
2988
2988
  },
2989
- body: JSON.stringify({ sessionId: z })
2989
+ body: JSON.stringify({ sessionId: I })
2990
2990
  });
2991
2991
  if (!Z.ok)
2992
2992
  throw new Error("Delete request failed");
2993
- const V = yield Z.json();
2994
- if (V.code === 0 && V.data.respCode === 0)
2995
- t(0, n = n.map((oe) => me(ee({}, oe), { deleting: oe.id === z }))), setTimeout(
2993
+ const Q = yield Z.json();
2994
+ if (Q.code === 0 && Q.data.respCode === 0)
2995
+ t(0, n = n.map((oe) => ke(ee({}, oe), {
2996
+ deleting: oe.sessionId === I
2997
+ }))), setTimeout(
2996
2998
  () => {
2997
2999
  t(0, n = n.filter((oe) => !oe.deleting));
2998
3000
  },
2999
3001
  300
3000
3002
  );
3001
3003
  else
3002
- throw new Error("Delete failed: " + V.message);
3003
- } catch (B) {
3004
- console.error("Failed to delete session:", B);
3005
- const Z = document.querySelector(`[data-session-id="${z}"]`);
3004
+ throw new Error("Delete failed: " + Q.message);
3005
+ } catch (U) {
3006
+ console.error("Failed to delete session:", U);
3007
+ const Z = document.querySelector(`[data-session-id="${I}"]`);
3006
3008
  Z && Z.classList.remove("deleting");
3007
3009
  } finally {
3008
3010
  t(6, p = null);
3009
3011
  }
3010
3012
  });
3011
3013
  }
3012
- function _() {
3013
- g && k(g);
3014
- }
3015
- const A = (z) => M(z, "关闭历史会话");
3016
3014
  function y() {
3015
+ d && k(d);
3016
+ }
3017
+ const A = (I) => M(I, "关闭历史会话");
3018
+ function T() {
3017
3019
  h = this.value, t(4, h);
3018
3020
  }
3019
- const I = (z) => o(z.id), R = (z, B) => b(B, z.id), P = () => t(7, g = null);
3020
- return s.$$set = (z) => {
3021
- "sessions" in z && t(0, n = z.sessions), "onClose" in z && t(1, i = z.onClose), "onSelect" in z && t(2, o = z.onSelect), "zIndex" in z && t(3, l = z.zIndex);
3021
+ const z = (I) => o(I.sessionId), R = (I, U) => b(U, I.sessionId), P = () => t(7, d = null);
3022
+ return s.$$set = (I) => {
3023
+ "sessions" in I && t(0, n = I.sessions), "onClose" in I && t(1, i = I.onClose), "onSelect" in I && t(2, o = I.onSelect), "zIndex" in I && t(3, l = I.zIndex);
3022
3024
  }, s.$$.update = () => {
3023
3025
  s.$$.dirty & /*searchQuery*/
3024
3026
  16 && h !== void 0 && (t(0, n = []), u = 0, c = !0, w());
@@ -3030,24 +3032,24 @@ function $o(s, e, t) {
3030
3032
  h,
3031
3033
  a,
3032
3034
  p,
3033
- g,
3034
3035
  d,
3036
+ g,
3035
3037
  C,
3036
3038
  S,
3037
3039
  M,
3038
3040
  v,
3039
3041
  b,
3040
- _,
3041
- A,
3042
3042
  y,
3043
- I,
3043
+ A,
3044
+ T,
3045
+ z,
3044
3046
  R,
3045
3047
  P
3046
3048
  ];
3047
3049
  }
3048
- class hi extends Ln {
3050
+ class pi extends Ln {
3049
3051
  constructor(e) {
3050
- super(), Cn(this, e, $o, Ko, Jt, {
3052
+ super(), Cn(this, e, el, $o, Jt, {
3051
3053
  sessions: 0,
3052
3054
  onClose: 1,
3053
3055
  onSelect: 2,
@@ -3055,25 +3057,25 @@ class hi extends Ln {
3055
3057
  });
3056
3058
  }
3057
3059
  }
3058
- function zs(s, e, t) {
3060
+ function Is(s, e, t) {
3059
3061
  const n = s.slice();
3060
- return n[61] = e[t], n[62] = e, n[63] = t, n;
3062
+ return n[60] = e[t], n[61] = e, n[62] = t, n;
3061
3063
  }
3062
- function Is(s, e, t) {
3064
+ function zs(s, e, t) {
3063
3065
  const n = s.slice();
3064
- return n[64] = e[t], n[66] = t, n;
3066
+ return n[63] = e[t], n[65] = t, n;
3065
3067
  }
3066
- function el(s) {
3068
+ function tl(s) {
3067
3069
  let e, t = [], n = /* @__PURE__ */ new Map(), i = kt(
3068
3070
  /*messages*/
3069
3071
  s[3]
3070
3072
  );
3071
3073
  const o = (l) => (
3072
3074
  /*msg*/
3073
- l[61].id
3075
+ l[60].id
3074
3076
  );
3075
3077
  for (let l = 0; l < i.length; l += 1) {
3076
- let a = zs(s, i, l), c = o(a);
3078
+ let a = Is(s, i, l), c = o(a);
3077
3079
  n.set(c, t[l] = Ps(c, a));
3078
3080
  }
3079
3081
  return {
@@ -3084,35 +3086,35 @@ function el(s) {
3084
3086
  r(e, "class", "sy-assistant-message-list svelte-46wzni");
3085
3087
  },
3086
3088
  m(l, a) {
3087
- W(l, e, a);
3089
+ q(l, e, a);
3088
3090
  for (let c = 0; c < t.length; c += 1)
3089
3091
  t[c] && t[c].m(e, null);
3090
3092
  s[47](e);
3091
3093
  },
3092
3094
  p(l, a) {
3093
3095
  a[0] & /*messages, dislikeFeedbackPosition, zIndex, submitDislikeFeedback, showDislikeFeedback, feedbackStatus, dislikeFeedbackContent, handleDislikeClick, showButtonTooltip, hideButtonTooltip, handleFeedback, copyStatus, handleCopy, isLoading, tooltipPosition, tooltipTimer, tooltipContent, handleDownload, showTooltip, hideTooltip, renderMarkdown*/
3094
- 536100601 && (i = kt(
3096
+ 268058361 && (i = kt(
3095
3097
  /*messages*/
3096
3098
  l[3]
3097
- ), t = Vs(t, a, o, 1, l, i, n, e, Xs, Ps, null, zs));
3099
+ ), t = Qs(t, a, o, 1, l, i, n, e, Vs, Ps, null, Is));
3098
3100
  },
3099
- i: Ce,
3100
- o: Ce,
3101
+ i: Le,
3102
+ o: Le,
3101
3103
  d(l) {
3102
- l && U(e);
3104
+ l && j(e);
3103
3105
  for (let a = 0; a < t.length; a += 1)
3104
3106
  t[a].d();
3105
3107
  s[47](null);
3106
3108
  }
3107
3109
  };
3108
3110
  }
3109
- function tl(s) {
3111
+ function nl(s) {
3110
3112
  let e, t;
3111
- return e = new hi({
3113
+ return e = new pi({
3112
3114
  props: {
3113
3115
  sessions: (
3114
3116
  /*sessions*/
3115
- s[16]
3117
+ s[28]
3116
3118
  ),
3117
3119
  onClose: (
3118
3120
  /*handleCloseHistory*/
@@ -3129,16 +3131,14 @@ function tl(s) {
3129
3131
  }
3130
3132
  }), {
3131
3133
  c() {
3132
- In(e.$$.fragment);
3134
+ zn(e.$$.fragment);
3133
3135
  },
3134
3136
  m(n, i) {
3135
3137
  $t(e, n, i), t = !0;
3136
3138
  },
3137
3139
  p(n, i) {
3138
3140
  const o = {};
3139
- i[0] & /*sessions*/
3140
- 65536 && (o.sessions = /*sessions*/
3141
- n[16]), i[0] & /*zIndex*/
3141
+ i[0] & /*zIndex*/
3142
3142
  1 && (o.zIndex = /*zIndex*/
3143
3143
  n[0]), e.$set(o);
3144
3144
  },
@@ -3153,40 +3153,40 @@ function tl(s) {
3153
3153
  }
3154
3154
  };
3155
3155
  }
3156
- function nl(s) {
3156
+ function sl(s) {
3157
3157
  let e;
3158
3158
  return {
3159
3159
  c() {
3160
3160
  e = x("div"), e.innerHTML = '<svg xmlns="http://www.w3.org/2000/svg" width="100%" height="100%" viewBox="0 0 24 24" fill="currentColor"><path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 3c1.66 0 3 1.34 3 3s-1.34 3-3 3-3-1.34-3-3 1.34-3 3-3zm0 14.2c-2.5 0-4.71-1.28-6-3.22.03-1.99 4-3.08 6-3.08 1.99 0 5.97 1.09 6 3.08-1.29 1.94-3.5 3.22-6 3.22z"></path></svg>', r(e, "class", "sy-assistant-avatar user svelte-46wzni");
3161
3161
  },
3162
3162
  m(t, n) {
3163
- W(t, e, n);
3163
+ q(t, e, n);
3164
3164
  },
3165
3165
  d(t) {
3166
- t && U(e);
3166
+ t && j(e);
3167
3167
  }
3168
3168
  };
3169
3169
  }
3170
- function sl(s) {
3170
+ function il(s) {
3171
3171
  let e;
3172
3172
  return {
3173
3173
  c() {
3174
3174
  e = x("div"), e.innerHTML = '<svg viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" width="100%" height="100%" fill="currentColor"><path 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" fill="#6F8698"></path><path 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" fill="#3677FF"></path><path 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" fill="#D0D5F1"></path><path 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" fill="#3677FF"></path><path d="M286.72 583.68a78.336 70.144 90 1 0 140.288 0 78.336 70.144 90 1 0-140.288 0Z" fill="#FFFFFF"></path><path d="M608.256 583.68a78.336 70.144 90 1 0 140.288 0 78.336 70.144 90 1 0-140.288 0Z" fill="#FFFFFF"></path><path 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" fill="#8896A4"></path></svg>', r(e, "class", "sy-assistant-avatar assistant svelte-46wzni");
3175
3175
  },
3176
3176
  m(t, n) {
3177
- W(t, e, n);
3177
+ q(t, e, n);
3178
3178
  },
3179
3179
  d(t) {
3180
- t && U(e);
3180
+ t && j(e);
3181
3181
  }
3182
3182
  };
3183
3183
  }
3184
- function il(s) {
3184
+ function ol(s) {
3185
3185
  let e, t = (
3186
3186
  /*renderMarkdown*/
3187
- s[18](
3187
+ s[17](
3188
3188
  /*msg*/
3189
- s[61].content
3189
+ s[60].content
3190
3190
  ) + ""
3191
3191
  );
3192
3192
  return {
@@ -3194,43 +3194,43 @@ function il(s) {
3194
3194
  e = x("div"), r(e, "class", "markdown-content svelte-46wzni");
3195
3195
  },
3196
3196
  m(n, i) {
3197
- W(n, e, i), e.innerHTML = t;
3197
+ q(n, e, i), e.innerHTML = t;
3198
3198
  },
3199
3199
  p(n, i) {
3200
3200
  i[0] & /*messages*/
3201
3201
  8 && t !== (t = /*renderMarkdown*/
3202
- n[18](
3202
+ n[17](
3203
3203
  /*msg*/
3204
- n[61].content
3204
+ n[60].content
3205
3205
  ) + "") && (e.innerHTML = t);
3206
3206
  },
3207
3207
  d(n) {
3208
- n && U(e);
3208
+ n && j(e);
3209
3209
  }
3210
3210
  };
3211
3211
  }
3212
- function ol(s) {
3212
+ function ll(s) {
3213
3213
  let e;
3214
3214
  return {
3215
3215
  c() {
3216
3216
  e = x("span"), e.innerHTML = '<span class="dot svelte-46wzni">.</span> <span class="dot svelte-46wzni">.</span> <span class="dot svelte-46wzni">.</span>', r(e, "class", "sy-assistant-loading svelte-46wzni");
3217
3217
  },
3218
3218
  m(t, n) {
3219
- W(t, e, n);
3219
+ q(t, e, n);
3220
3220
  },
3221
- p: Ce,
3221
+ p: Le,
3222
3222
  d(t) {
3223
- t && U(e);
3223
+ t && j(e);
3224
3224
  }
3225
3225
  };
3226
3226
  }
3227
3227
  function Cs(s) {
3228
3228
  let e, t = kt(
3229
3229
  /*msg*/
3230
- s[61].attachments
3230
+ s[60].attachments
3231
3231
  ), n = [];
3232
3232
  for (let i = 0; i < t.length; i += 1)
3233
- n[i] = Os(Is(s, t, i));
3233
+ n[i] = Os(zs(s, t, i));
3234
3234
  return {
3235
3235
  c() {
3236
3236
  e = x("div");
@@ -3239,20 +3239,20 @@ function Cs(s) {
3239
3239
  r(e, "class", "sy-assistant-attachments svelte-46wzni");
3240
3240
  },
3241
3241
  m(i, o) {
3242
- W(i, e, o);
3242
+ q(i, e, o);
3243
3243
  for (let l = 0; l < n.length; l += 1)
3244
3244
  n[l] && n[l].m(e, null);
3245
3245
  },
3246
3246
  p(i, o) {
3247
3247
  if (o[0] & /*tooltipPosition, zIndex, tooltipTimer, tooltipContent, handleDownload, messages, showTooltip, hideTooltip*/
3248
- 7340153) {
3248
+ 3670137) {
3249
3249
  t = kt(
3250
3250
  /*msg*/
3251
- i[61].attachments
3251
+ i[60].attachments
3252
3252
  );
3253
3253
  let l;
3254
3254
  for (l = 0; l < t.length; l += 1) {
3255
- const a = Is(i, t, l);
3255
+ const a = zs(i, t, l);
3256
3256
  n[l] ? n[l].p(a, o) : (n[l] = Os(a), n[l].c(), n[l].m(e, null));
3257
3257
  }
3258
3258
  for (; l < n.length; l += 1)
@@ -3261,7 +3261,7 @@ function Cs(s) {
3261
3261
  }
3262
3262
  },
3263
3263
  d(i) {
3264
- i && U(e), zi(n, i);
3264
+ i && j(e), zi(n, i);
3265
3265
  }
3266
3266
  };
3267
3267
  }
@@ -3272,7 +3272,7 @@ function Ls(s) {
3272
3272
  /*mouseenter_handler*/
3273
3273
  s[34](
3274
3274
  /*attachment*/
3275
- s[64],
3275
+ s[63],
3276
3276
  ...o
3277
3277
  )
3278
3278
  );
@@ -3282,13 +3282,13 @@ function Ls(s) {
3282
3282
  e = x("button"), e.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-46wzni"><circle cx="11" cy="11" r="8"></circle><line x1="21" y1="21" x2="16.65" y2="16.65"></line></svg>', r(e, "class", "sy-assistant-attachment-toggle svelte-46wzni"), r(e, "aria-label", "查看详情");
3283
3283
  },
3284
3284
  m(o, l) {
3285
- W(o, e, l), t || (n = [
3286
- H(e, "mouseenter", i),
3287
- H(
3285
+ q(o, e, l), t || (n = [
3286
+ B(e, "mouseenter", i),
3287
+ B(
3288
3288
  e,
3289
3289
  "mouseleave",
3290
3290
  /*hideTooltip*/
3291
- s[21]
3291
+ s[20]
3292
3292
  )
3293
3293
  ], t = !0);
3294
3294
  },
@@ -3296,7 +3296,7 @@ function Ls(s) {
3296
3296
  s = o;
3297
3297
  },
3298
3298
  d(o) {
3299
- o && U(e), t = !1, ve(n);
3299
+ o && j(e), t = !1, Ee(n);
3300
3300
  }
3301
3301
  };
3302
3302
  }
@@ -3322,7 +3322,7 @@ function Ms(s) {
3322
3322
  "z-index",
3323
3323
  /*zIndex*/
3324
3324
  s[0] + 3
3325
- ), Q(
3325
+ ), J(
3326
3326
  e,
3327
3327
  "align-right",
3328
3328
  /*tooltipPosition*/
@@ -3330,14 +3330,14 @@ function Ms(s) {
3330
3330
  );
3331
3331
  },
3332
3332
  m(o, l) {
3333
- W(o, e, l), e.innerHTML = t, n || (i = [
3334
- H(
3333
+ q(o, e, l), e.innerHTML = t, n || (i = [
3334
+ B(
3335
3335
  e,
3336
3336
  "mouseenter",
3337
3337
  /*mouseenter_handler_1*/
3338
3338
  s[36]
3339
3339
  ),
3340
- H(
3340
+ B(
3341
3341
  e,
3342
3342
  "mouseleave",
3343
3343
  /*mouseleave_handler*/
@@ -3367,7 +3367,7 @@ function Ms(s) {
3367
3367
  /*zIndex*/
3368
3368
  o[0] + 3
3369
3369
  ), l[0] & /*tooltipPosition*/
3370
- 32 && Q(
3370
+ 32 && J(
3371
3371
  e,
3372
3372
  "align-right",
3373
3373
  /*tooltipPosition*/
@@ -3375,80 +3375,80 @@ function Ms(s) {
3375
3375
  );
3376
3376
  },
3377
3377
  d(o) {
3378
- o && U(e), n = !1, ve(i);
3378
+ o && j(e), n = !1, Ee(i);
3379
3379
  }
3380
3380
  };
3381
3381
  }
3382
3382
  function Os(s) {
3383
- let e, t, n, i, o, l, a, c, u, h = qt(
3383
+ let e, t, n, i, o, l, a, c, u, h = Gt(
3384
3384
  /*attachment*/
3385
- s[64].content_title
3386
- ).name + "", p, g, d, w = qt(
3385
+ s[63].content_title
3386
+ ).name + "", p, d, g, w = Gt(
3387
3387
  /*attachment*/
3388
- s[64].content_title
3389
- ).ext + "", S, C, M, v, b, k, _, A, y, I, R = (
3388
+ s[63].content_title
3389
+ ).ext + "", S, C, M, v, b, k, y, A, T, z, R = (
3390
3390
  /*attachment*/
3391
- s[64].tips && Ls(s)
3391
+ s[63].tips && Ls(s)
3392
3392
  );
3393
3393
  function P() {
3394
3394
  return (
3395
3395
  /*click_handler*/
3396
3396
  s[35](
3397
3397
  /*attachment*/
3398
- s[64]
3398
+ s[63]
3399
3399
  )
3400
3400
  );
3401
3401
  }
3402
- let z = (
3402
+ let I = (
3403
3403
  /*tooltipContent*/
3404
3404
  s[4] && Ms(s)
3405
3405
  );
3406
3406
  return {
3407
3407
  c() {
3408
- e = x("div"), t = x("div"), n = x("div"), i = X("svg"), o = X("path"), l = X("polyline"), a = j(), c = x("div"), u = x("span"), p = Te(h), g = j(), d = x("span"), S = Te(w), M = j(), v = x("div"), R && R.c(), b = j(), k = x("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-46wzni"><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>', _ = j(), z && z.c(), A = j(), r(o, "d", "M13 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9z"), r(l, "points", "13 2 13 9 20 9"), r(i, "xmlns", "http://www.w3.org/2000/svg"), r(i, "width", "16"), r(i, "height", "16"), r(i, "viewBox", "0 0 24 24"), r(i, "fill", "none"), r(i, "stroke", "currentColor"), r(i, "stroke-width", "2"), r(i, "stroke-linecap", "round"), r(i, "stroke-linejoin", "round"), r(u, "class", "sy-assistant-filename svelte-46wzni"), r(d, "class", "sy-assistant-attachment-ext svelte-46wzni"), r(c, "class", "sy-assistant-attachment-name svelte-46wzni"), r(c, "title", C = /*attachment*/
3409
- s[64].content_title), r(n, "class", "sy-assistant-attachment-title svelte-46wzni"), r(k, "class", "sy-assistant-attachment-toggle svelte-46wzni"), r(k, "aria-label", "下载文件"), r(v, "class", "sy-assistant-attachment-actions svelte-46wzni"), r(t, "class", "sy-assistant-attachment-header svelte-46wzni"), r(e, "class", "sy-assistant-attachment svelte-46wzni");
3408
+ e = x("div"), t = x("div"), n = x("div"), i = X("svg"), o = X("path"), l = X("polyline"), a = W(), c = x("div"), u = x("span"), p = ve(h), d = W(), g = x("span"), S = ve(w), M = W(), v = x("div"), R && R.c(), b = W(), k = x("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-46wzni"><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 = W(), I && I.c(), A = W(), r(o, "d", "M13 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V9z"), r(l, "points", "13 2 13 9 20 9"), r(i, "xmlns", "http://www.w3.org/2000/svg"), r(i, "width", "16"), r(i, "height", "16"), r(i, "viewBox", "0 0 24 24"), r(i, "fill", "none"), r(i, "stroke", "currentColor"), r(i, "stroke-width", "2"), r(i, "stroke-linecap", "round"), r(i, "stroke-linejoin", "round"), r(u, "class", "sy-assistant-filename svelte-46wzni"), r(g, "class", "sy-assistant-attachment-ext svelte-46wzni"), r(c, "class", "sy-assistant-attachment-name svelte-46wzni"), r(c, "title", C = /*attachment*/
3409
+ s[63].content_title), r(n, "class", "sy-assistant-attachment-title svelte-46wzni"), r(k, "class", "sy-assistant-attachment-toggle svelte-46wzni"), r(k, "aria-label", "下载文件"), r(v, "class", "sy-assistant-attachment-actions svelte-46wzni"), r(t, "class", "sy-assistant-attachment-header svelte-46wzni"), r(e, "class", "sy-assistant-attachment svelte-46wzni");
3410
3410
  },
3411
- m(B, Z) {
3412
- W(B, e, Z), m(e, t), m(t, n), m(n, i), m(i, o), m(i, l), m(n, a), m(n, c), m(c, u), m(u, p), m(c, g), m(c, d), m(d, S), m(t, M), m(t, v), R && R.m(v, null), m(v, b), m(v, k), m(e, _), z && z.m(e, null), m(e, A), y || (I = H(k, "click", P), y = !0);
3411
+ m(U, Z) {
3412
+ q(U, e, Z), m(e, t), m(t, n), m(n, i), m(i, o), m(i, l), m(n, a), m(n, c), m(c, u), m(u, p), m(c, d), m(c, g), m(g, S), m(t, M), m(t, v), R && R.m(v, null), m(v, b), m(v, k), m(e, y), I && I.m(e, null), m(e, A), T || (z = B(k, "click", P), T = !0);
3413
3413
  },
3414
- p(B, Z) {
3415
- s = B, Z[0] & /*messages*/
3416
- 8 && h !== (h = qt(
3414
+ p(U, Z) {
3415
+ s = U, Z[0] & /*messages*/
3416
+ 8 && h !== (h = Gt(
3417
3417
  /*attachment*/
3418
- s[64].content_title
3418
+ s[63].content_title
3419
3419
  ).name + "") && De(p, h), Z[0] & /*messages*/
3420
- 8 && w !== (w = qt(
3420
+ 8 && w !== (w = Gt(
3421
3421
  /*attachment*/
3422
- s[64].content_title
3422
+ s[63].content_title
3423
3423
  ).ext + "") && De(S, w), Z[0] & /*messages*/
3424
3424
  8 && C !== (C = /*attachment*/
3425
- s[64].content_title) && r(c, "title", C), /*attachment*/
3426
- s[64].tips ? R ? R.p(s, Z) : (R = Ls(s), R.c(), R.m(v, b)) : R && (R.d(1), R = null), /*tooltipContent*/
3427
- s[4] ? z ? z.p(s, Z) : (z = Ms(s), z.c(), z.m(e, A)) : z && (z.d(1), z = null);
3425
+ s[63].content_title) && r(c, "title", C), /*attachment*/
3426
+ s[63].tips ? R ? R.p(s, Z) : (R = Ls(s), R.c(), R.m(v, b)) : R && (R.d(1), R = null), /*tooltipContent*/
3427
+ s[4] ? I ? I.p(s, Z) : (I = Ms(s), I.c(), I.m(e, A)) : I && (I.d(1), I = null);
3428
3428
  },
3429
- d(B) {
3430
- B && U(e), R && R.d(), z && z.d(), y = !1, I();
3429
+ d(U) {
3430
+ U && j(e), R && R.d(), I && I.d(), T = !1, z();
3431
3431
  }
3432
3432
  };
3433
3433
  }
3434
3434
  function Ds(s) {
3435
3435
  let e, t, n, i, o, l, a, c, u, h, p;
3436
- function g(A, y) {
3436
+ function d(A, T) {
3437
3437
  return (
3438
3438
  /*copyStatus*/
3439
3439
  A[9][
3440
3440
  /*msg*/
3441
- A[61].id
3442
- ] ? rl : ll
3441
+ A[60].id
3442
+ ] ? al : rl
3443
3443
  );
3444
3444
  }
3445
- let d = g(s), w = d(s);
3445
+ let g = d(s), w = g(s);
3446
3446
  function S() {
3447
3447
  return (
3448
3448
  /*click_handler_1*/
3449
3449
  s[38](
3450
3450
  /*msg*/
3451
- s[61]
3451
+ s[60]
3452
3452
  )
3453
3453
  );
3454
3454
  }
@@ -3457,7 +3457,7 @@ function Ds(s) {
3457
3457
  /*mouseenter_handler_2*/
3458
3458
  s[39](
3459
3459
  /*msg*/
3460
- s[61],
3460
+ s[60],
3461
3461
  ...A
3462
3462
  )
3463
3463
  );
@@ -3467,7 +3467,7 @@ function Ds(s) {
3467
3467
  /*click_handler_2*/
3468
3468
  s[40](
3469
3469
  /*msg*/
3470
- s[61]
3470
+ s[60]
3471
3471
  )
3472
3472
  );
3473
3473
  }
@@ -3476,7 +3476,7 @@ function Ds(s) {
3476
3476
  /*mouseenter_handler_3*/
3477
3477
  s[41](
3478
3478
  /*msg*/
3479
- s[61],
3479
+ s[60],
3480
3480
  ...A
3481
3481
  )
3482
3482
  );
@@ -3486,7 +3486,7 @@ function Ds(s) {
3486
3486
  /*click_handler_3*/
3487
3487
  s[42](
3488
3488
  /*msg*/
3489
- s[61],
3489
+ s[60],
3490
3490
  ...A
3491
3491
  )
3492
3492
  );
@@ -3496,149 +3496,149 @@ function Ds(s) {
3496
3496
  /*mouseenter_handler_4*/
3497
3497
  s[43](
3498
3498
  /*msg*/
3499
- s[61],
3499
+ s[60],
3500
3500
  ...A
3501
3501
  )
3502
3502
  );
3503
3503
  }
3504
- let _ = (
3504
+ let y = (
3505
3505
  /*showDislikeFeedback*/
3506
3506
  s[12] && /*feedbackStatus*/
3507
3507
  s[10][
3508
3508
  /*msg*/
3509
- s[61].id
3509
+ s[60].id
3510
3510
  ] === "dislike" && Ns(s)
3511
3511
  );
3512
3512
  return {
3513
3513
  c() {
3514
- e = x("div"), t = x("button"), w.c(), i = j(), o = x("button"), o.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>', l = j(), a = x("button"), a.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(), _ && _.c(), u = Kt(), r(t, "class", "sy-assistant-action-button svelte-46wzni"), r(t, "aria-label", n = /*copyStatus*/
3514
+ e = x("div"), t = x("button"), w.c(), i = W(), o = x("button"), o.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>', l = W(), a = x("button"), a.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 = W(), y && y.c(), u = Kt(), r(t, "class", "sy-assistant-action-button svelte-46wzni"), r(t, "aria-label", n = /*copyStatus*/
3515
3515
  s[9][
3516
3516
  /*msg*/
3517
- s[61].id
3518
- ] ? "已复制" : "复制内容"), Q(
3517
+ s[60].id
3518
+ ] ? "已复制" : "复制内容"), J(
3519
3519
  t,
3520
3520
  "copied",
3521
3521
  /*copyStatus*/
3522
3522
  s[9][
3523
3523
  /*msg*/
3524
- s[61].id
3524
+ s[60].id
3525
3525
  ]
3526
- ), r(o, "class", "sy-assistant-action-button svelte-46wzni"), r(o, "aria-label", "点赞"), Q(
3526
+ ), r(o, "class", "sy-assistant-action-button svelte-46wzni"), r(o, "aria-label", "点赞"), J(
3527
3527
  o,
3528
3528
  "active",
3529
3529
  /*feedbackStatus*/
3530
3530
  s[10][
3531
3531
  /*msg*/
3532
- s[61].id
3532
+ s[60].id
3533
3533
  ] === "like"
3534
- ), r(a, "class", "sy-assistant-action-button svelte-46wzni"), r(a, "aria-label", "点踩"), Q(
3534
+ ), r(a, "class", "sy-assistant-action-button svelte-46wzni"), r(a, "aria-label", "点踩"), J(
3535
3535
  a,
3536
3536
  "active",
3537
3537
  /*feedbackStatus*/
3538
3538
  s[10][
3539
3539
  /*msg*/
3540
- s[61].id
3540
+ s[60].id
3541
3541
  ] === "dislike"
3542
3542
  ), r(e, "class", "sy-assistant-message-actions svelte-46wzni");
3543
3543
  },
3544
- m(A, y) {
3545
- W(A, e, y), m(e, t), w.m(t, null), m(e, i), m(e, o), m(e, l), m(e, a), W(A, c, y), _ && _.m(A, y), W(A, u, y), h || (p = [
3546
- H(t, "click", S),
3547
- H(t, "mouseenter", C),
3548
- H(
3544
+ m(A, T) {
3545
+ q(A, e, T), m(e, t), w.m(t, null), m(e, i), m(e, o), m(e, l), m(e, a), q(A, c, T), y && y.m(A, T), q(A, u, T), h || (p = [
3546
+ B(t, "click", S),
3547
+ B(t, "mouseenter", C),
3548
+ B(
3549
3549
  t,
3550
3550
  "mouseleave",
3551
3551
  /*hideButtonTooltip*/
3552
- s[28]
3552
+ s[27]
3553
3553
  ),
3554
- H(o, "click", M),
3555
- H(o, "mouseenter", v),
3556
- H(
3554
+ B(o, "click", M),
3555
+ B(o, "mouseenter", v),
3556
+ B(
3557
3557
  o,
3558
3558
  "mouseleave",
3559
3559
  /*hideButtonTooltip*/
3560
- s[28]
3560
+ s[27]
3561
3561
  ),
3562
- H(a, "click", b),
3563
- H(a, "mouseenter", k),
3564
- H(
3562
+ B(a, "click", b),
3563
+ B(a, "mouseenter", k),
3564
+ B(
3565
3565
  a,
3566
3566
  "mouseleave",
3567
3567
  /*hideButtonTooltip*/
3568
- s[28]
3568
+ s[27]
3569
3569
  )
3570
3570
  ], h = !0);
3571
3571
  },
3572
- p(A, y) {
3573
- s = A, d !== (d = g(s)) && (w.d(1), w = d(s), w && (w.c(), w.m(t, null))), y[0] & /*copyStatus, messages*/
3572
+ p(A, T) {
3573
+ s = A, g !== (g = d(s)) && (w.d(1), w = g(s), w && (w.c(), w.m(t, null))), T[0] & /*copyStatus, messages*/
3574
3574
  520 && n !== (n = /*copyStatus*/
3575
3575
  s[9][
3576
3576
  /*msg*/
3577
- s[61].id
3578
- ] ? "已复制" : "复制内容") && r(t, "aria-label", n), y[0] & /*copyStatus, messages*/
3579
- 520 && Q(
3577
+ s[60].id
3578
+ ] ? "已复制" : "复制内容") && r(t, "aria-label", n), T[0] & /*copyStatus, messages*/
3579
+ 520 && J(
3580
3580
  t,
3581
3581
  "copied",
3582
3582
  /*copyStatus*/
3583
3583
  s[9][
3584
3584
  /*msg*/
3585
- s[61].id
3585
+ s[60].id
3586
3586
  ]
3587
- ), y[0] & /*feedbackStatus, messages*/
3588
- 1032 && Q(
3587
+ ), T[0] & /*feedbackStatus, messages*/
3588
+ 1032 && J(
3589
3589
  o,
3590
3590
  "active",
3591
3591
  /*feedbackStatus*/
3592
3592
  s[10][
3593
3593
  /*msg*/
3594
- s[61].id
3594
+ s[60].id
3595
3595
  ] === "like"
3596
- ), y[0] & /*feedbackStatus, messages*/
3597
- 1032 && Q(
3596
+ ), T[0] & /*feedbackStatus, messages*/
3597
+ 1032 && J(
3598
3598
  a,
3599
3599
  "active",
3600
3600
  /*feedbackStatus*/
3601
3601
  s[10][
3602
3602
  /*msg*/
3603
- s[61].id
3603
+ s[60].id
3604
3604
  ] === "dislike"
3605
3605
  ), /*showDislikeFeedback*/
3606
3606
  s[12] && /*feedbackStatus*/
3607
3607
  s[10][
3608
3608
  /*msg*/
3609
- s[61].id
3610
- ] === "dislike" ? _ ? _.p(s, y) : (_ = Ns(s), _.c(), _.m(u.parentNode, u)) : _ && (_.d(1), _ = null);
3609
+ s[60].id
3610
+ ] === "dislike" ? y ? y.p(s, T) : (y = Ns(s), y.c(), y.m(u.parentNode, u)) : y && (y.d(1), y = null);
3611
3611
  },
3612
3612
  d(A) {
3613
- A && (U(e), U(c), U(u)), w.d(), _ && _.d(A), h = !1, ve(p);
3613
+ A && (j(e), j(c), j(u)), w.d(), y && y.d(A), h = !1, Ee(p);
3614
3614
  }
3615
3615
  };
3616
3616
  }
3617
- function ll(s) {
3617
+ function rl(s) {
3618
3618
  let e, t, n;
3619
3619
  return {
3620
3620
  c() {
3621
3621
  e = X("svg"), t = X("rect"), n = X("path"), r(t, "x", "9"), r(t, "y", "9"), r(t, "width", "13"), r(t, "height", "13"), r(t, "rx", "2"), r(t, "ry", "2"), r(n, "d", "M5 15H4a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h9a2 2 0 0 1 2 2v1"), r(e, "xmlns", "http://www.w3.org/2000/svg"), r(e, "width", "14"), r(e, "height", "14"), r(e, "viewBox", "0 0 24 24"), r(e, "fill", "none"), r(e, "stroke", "currentColor"), r(e, "stroke-width", "2"), r(e, "stroke-linecap", "round"), r(e, "stroke-linejoin", "round");
3622
3622
  },
3623
3623
  m(i, o) {
3624
- W(i, e, o), m(e, t), m(e, n);
3624
+ q(i, e, o), m(e, t), m(e, n);
3625
3625
  },
3626
3626
  d(i) {
3627
- i && U(e);
3627
+ i && j(e);
3628
3628
  }
3629
3629
  };
3630
3630
  }
3631
- function rl(s) {
3631
+ function al(s) {
3632
3632
  let e, t;
3633
3633
  return {
3634
3634
  c() {
3635
3635
  e = X("svg"), t = X("polyline"), r(t, "points", "20 6 9 17 4 12"), r(e, "xmlns", "http://www.w3.org/2000/svg"), r(e, "width", "14"), r(e, "height", "14"), r(e, "viewBox", "0 0 24 24"), r(e, "fill", "none"), r(e, "stroke", "currentColor"), r(e, "stroke-width", "2"), r(e, "stroke-linecap", "round"), r(e, "stroke-linejoin", "round");
3636
3636
  },
3637
3637
  m(n, i) {
3638
- W(n, e, i), m(e, t);
3638
+ q(n, e, i), m(e, t);
3639
3639
  },
3640
3640
  d(n) {
3641
- n && U(e);
3641
+ n && j(e);
3642
3642
  }
3643
3643
  };
3644
3644
  }
@@ -3648,7 +3648,7 @@ function Ns(s) {
3648
3648
  s[44].call(
3649
3649
  t,
3650
3650
  /*msg*/
3651
- s[61]
3651
+ s[60]
3652
3652
  );
3653
3653
  }
3654
3654
  function p() {
@@ -3656,22 +3656,22 @@ function Ns(s) {
3656
3656
  /*click_handler_4*/
3657
3657
  s[45](
3658
3658
  /*msg*/
3659
- s[61]
3659
+ s[60]
3660
3660
  )
3661
3661
  );
3662
3662
  }
3663
- function g() {
3663
+ function d() {
3664
3664
  return (
3665
3665
  /*click_handler_5*/
3666
3666
  s[46](
3667
3667
  /*msg*/
3668
- s[61]
3668
+ s[60]
3669
3669
  )
3670
3670
  );
3671
3671
  }
3672
3672
  return {
3673
3673
  c() {
3674
- e = x("div"), t = x("textarea"), n = j(), i = x("div"), o = x("button"), o.textContent = "取消", l = j(), a = x("button"), a.textContent = "提交", r(t, "class", "sy-assistant-dislike-input svelte-46wzni"), r(t, "placeholder", "请输入您的反馈意见..."), r(o, "class", "sy-assistant-popup-cancel svelte-46wzni"), r(a, "class", "sy-assistant-popup-submit svelte-46wzni"), r(i, "class", "sy-assistant-popup-actions svelte-46wzni"), r(e, "class", "sy-assistant-dislike-popup svelte-46wzni"), F(
3674
+ e = x("div"), t = x("textarea"), n = W(), i = x("div"), o = x("button"), o.textContent = "取消", l = W(), a = x("button"), a.textContent = "提交", r(t, "class", "sy-assistant-dislike-input svelte-46wzni"), r(t, "placeholder", "请输入您的反馈意见..."), r(o, "class", "sy-assistant-popup-cancel svelte-46wzni"), r(a, "class", "sy-assistant-popup-submit svelte-46wzni"), r(i, "class", "sy-assistant-popup-actions svelte-46wzni"), r(e, "class", "sy-assistant-dislike-popup svelte-46wzni"), F(
3675
3675
  e,
3676
3676
  "left",
3677
3677
  /*dislikeFeedbackPosition*/
@@ -3688,28 +3688,28 @@ function Ns(s) {
3688
3688
  s[0] + 3
3689
3689
  );
3690
3690
  },
3691
- m(d, w) {
3692
- W(d, e, w), m(e, t), mt(
3691
+ m(g, w) {
3692
+ q(g, e, w), m(e, t), mt(
3693
3693
  t,
3694
3694
  /*dislikeFeedbackContent*/
3695
3695
  s[11][
3696
3696
  /*msg*/
3697
- s[61].id
3697
+ s[60].id
3698
3698
  ]
3699
3699
  ), m(e, n), m(e, i), m(i, o), m(i, l), m(i, a), c || (u = [
3700
- H(t, "input", h),
3701
- H(o, "click", p),
3702
- H(a, "click", g)
3700
+ B(t, "input", h),
3701
+ B(o, "click", p),
3702
+ B(a, "click", d)
3703
3703
  ], c = !0);
3704
3704
  },
3705
- p(d, w) {
3706
- s = d, w[0] & /*dislikeFeedbackContent, messages*/
3705
+ p(g, w) {
3706
+ s = g, w[0] & /*dislikeFeedbackContent, messages*/
3707
3707
  2056 && mt(
3708
3708
  t,
3709
3709
  /*dislikeFeedbackContent*/
3710
3710
  s[11][
3711
3711
  /*msg*/
3712
- s[61].id
3712
+ s[60].id
3713
3713
  ]
3714
3714
  ), w[0] & /*dislikeFeedbackPosition*/
3715
3715
  8192 && F(
@@ -3731,176 +3731,176 @@ function Ns(s) {
3731
3731
  s[0] + 3
3732
3732
  );
3733
3733
  },
3734
- d(d) {
3735
- d && U(e), c = !1, ve(u);
3734
+ d(g) {
3735
+ g && j(e), c = !1, Ee(u);
3736
3736
  }
3737
3737
  };
3738
3738
  }
3739
3739
  function Ps(s, e) {
3740
3740
  let t, n, i, o, l, a, c, u, h = new Date(
3741
3741
  /*msg*/
3742
- e[61].timestamp
3743
- ).toLocaleTimeString() + "", p, g;
3744
- function d(_, A) {
3742
+ e[60].timestamp
3743
+ ).toLocaleTimeString() + "", p, d;
3744
+ function g(y, A) {
3745
3745
  return (
3746
3746
  /*msg*/
3747
- _[61].type === "assistant" ? sl : nl
3747
+ y[60].type === "assistant" ? il : sl
3748
3748
  );
3749
3749
  }
3750
- let w = d(e), S = w(e);
3751
- function C(_, A) {
3750
+ let w = g(e), S = w(e);
3751
+ function C(y, A) {
3752
3752
  return (
3753
3753
  /*isLoading*/
3754
- _[7] && /*msg*/
3755
- _[61].id === /*messages*/
3756
- _[3][
3754
+ y[7] && /*msg*/
3755
+ y[60].id === /*messages*/
3756
+ y[3][
3757
3757
  /*messages*/
3758
- _[3].length - 1
3758
+ y[3].length - 1
3759
3759
  ].id && /*msg*/
3760
- _[61].type === "assistant" && !/*msg*/
3761
- _[61].content ? ol : il
3760
+ y[60].type === "assistant" && !/*msg*/
3761
+ y[60].content ? ll : ol
3762
3762
  );
3763
3763
  }
3764
3764
  let M = C(e), v = M(e), b = (
3765
3765
  /*msg*/
3766
- e[61].attachments && Cs(e)
3766
+ e[60].attachments && Cs(e)
3767
3767
  ), k = (
3768
3768
  /*msg*/
3769
- e[61].id !== "-1" && /*msg*/
3770
- e[61].type === "assistant" && !/*isLoading*/
3769
+ e[60].id !== "-1" && /*msg*/
3770
+ e[60].type === "assistant" && !/*isLoading*/
3771
3771
  e[7] && Ds(e)
3772
3772
  );
3773
3773
  return {
3774
3774
  key: s,
3775
3775
  first: null,
3776
3776
  c() {
3777
- t = x("div"), S.c(), n = j(), i = x("div"), o = x("div"), v.c(), l = j(), b && b.c(), a = j(), k && k.c(), c = j(), u = x("div"), p = Te(h), g = j(), r(o, "class", "sy-assistant-message-content svelte-46wzni"), r(u, "class", "sy-assistant-message-time svelte-46wzni"), r(i, "class", "sy-assistant-message-bubble svelte-46wzni"), r(t, "class", "sy-assistant-message svelte-46wzni"), Q(
3777
+ t = x("div"), S.c(), n = W(), i = x("div"), o = x("div"), v.c(), l = W(), b && b.c(), a = W(), k && k.c(), c = W(), u = x("div"), p = ve(h), d = W(), r(o, "class", "sy-assistant-message-content svelte-46wzni"), r(u, "class", "sy-assistant-message-time svelte-46wzni"), r(i, "class", "sy-assistant-message-bubble svelte-46wzni"), r(t, "class", "sy-assistant-message svelte-46wzni"), J(
3778
3778
  t,
3779
3779
  "user",
3780
3780
  /*msg*/
3781
- e[61].type === "user"
3781
+ e[60].type === "user"
3782
3782
  ), this.first = t;
3783
3783
  },
3784
- m(_, A) {
3785
- W(_, t, A), S.m(t, null), m(t, n), m(t, i), m(i, o), v.m(o, null), m(o, l), b && b.m(o, null), m(o, a), k && k.m(o, null), m(i, c), m(i, u), m(u, p), m(t, g);
3784
+ m(y, A) {
3785
+ q(y, t, A), S.m(t, null), m(t, n), m(t, i), m(i, o), v.m(o, null), m(o, l), b && b.m(o, null), m(o, a), k && k.m(o, null), m(i, c), m(i, u), m(u, p), m(t, d);
3786
3786
  },
3787
- p(_, A) {
3788
- e = _, w !== (w = d(e)) && (S.d(1), S = w(e), S && (S.c(), S.m(t, n))), M === (M = C(e)) && v ? v.p(e, A) : (v.d(1), v = M(e), v && (v.c(), v.m(o, l))), /*msg*/
3789
- e[61].attachments ? b ? b.p(e, A) : (b = Cs(e), b.c(), b.m(o, a)) : b && (b.d(1), b = null), /*msg*/
3790
- e[61].id !== "-1" && /*msg*/
3791
- e[61].type === "assistant" && !/*isLoading*/
3787
+ p(y, A) {
3788
+ e = y, w !== (w = g(e)) && (S.d(1), S = w(e), S && (S.c(), S.m(t, n))), M === (M = C(e)) && v ? v.p(e, A) : (v.d(1), v = M(e), v && (v.c(), v.m(o, l))), /*msg*/
3789
+ e[60].attachments ? b ? b.p(e, A) : (b = Cs(e), b.c(), b.m(o, a)) : b && (b.d(1), b = null), /*msg*/
3790
+ e[60].id !== "-1" && /*msg*/
3791
+ e[60].type === "assistant" && !/*isLoading*/
3792
3792
  e[7] ? k ? k.p(e, A) : (k = Ds(e), k.c(), k.m(o, null)) : k && (k.d(1), k = null), A[0] & /*messages*/
3793
3793
  8 && h !== (h = new Date(
3794
3794
  /*msg*/
3795
- e[61].timestamp
3795
+ e[60].timestamp
3796
3796
  ).toLocaleTimeString() + "") && De(p, h), A[0] & /*messages*/
3797
- 8 && Q(
3797
+ 8 && J(
3798
3798
  t,
3799
3799
  "user",
3800
3800
  /*msg*/
3801
- e[61].type === "user"
3801
+ e[60].type === "user"
3802
3802
  );
3803
3803
  },
3804
- d(_) {
3805
- _ && U(t), S.d(), v.d(), b && b.d(), k && k.d();
3804
+ d(y) {
3805
+ y && j(t), S.d(), v.d(), b && b.d(), k && k.d();
3806
3806
  }
3807
3807
  };
3808
3808
  }
3809
3809
  function Fs(s) {
3810
- let e, t, n, i, o, l, a, c, u, h, p, g, d, w, S, C, M, v, b, k, _, A, y, I;
3810
+ let e, t, n, i, o, l, a, c, u, h, p, d, g, w, S, C, M, v, b, k, y, A, T, z;
3811
3811
  return {
3812
3812
  c() {
3813
- e = x("div"), t = x("div"), n = x("button"), n.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>', i = j(), o = x("button"), o.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>', l = j(), a = x("div"), c = x("div"), u = x("div"), h = x("div"), p = x("textarea"), g = j(), d = x("div"), w = Te(
3813
+ e = x("div"), t = x("div"), n = x("button"), n.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>', i = W(), o = x("button"), o.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>', l = W(), a = x("div"), c = x("div"), u = x("div"), h = x("div"), p = x("textarea"), d = W(), g = x("div"), w = ve(
3814
3814
  /*messageLength*/
3815
3815
  s[2]
3816
- ), S = Te("/"), C = Te(Sn), M = j(), v = x("button"), b = X("svg"), k = X("line"), _ = X("polygon"), r(n, "class", "sy-assistant-icon-button svelte-46wzni"), r(n, "aria-label", "历史会话"), r(o, "class", "sy-assistant-icon-button svelte-46wzni"), r(o, "aria-label", "新建会话"), r(t, "class", "sy-assistant-chat-actions svelte-46wzni"), r(e, "class", "sy-assistant-chat-footer svelte-46wzni"), r(p, "class", "sy-assistant-textarea svelte-46wzni"), r(p, "placeholder", "输入您的问题..."), r(p, "maxlength", Sn), r(p, "rows", "3"), r(d, "class", "sy-assistant-char-count svelte-46wzni"), Q(
3817
- d,
3816
+ ), S = ve("/"), C = ve(Sn), M = W(), v = x("button"), b = X("svg"), k = X("line"), y = X("polygon"), r(n, "class", "sy-assistant-icon-button svelte-46wzni"), r(n, "aria-label", "历史会话"), r(o, "class", "sy-assistant-icon-button svelte-46wzni"), r(o, "aria-label", "新建会话"), r(t, "class", "sy-assistant-chat-actions svelte-46wzni"), r(e, "class", "sy-assistant-chat-footer svelte-46wzni"), r(p, "class", "sy-assistant-textarea svelte-46wzni"), r(p, "placeholder", "输入您的问题..."), r(p, "maxlength", Sn), r(p, "rows", "3"), r(g, "class", "sy-assistant-char-count svelte-46wzni"), J(
3817
+ g,
3818
3818
  "over-limit",
3819
3819
  /*isOverLimit*/
3820
- s[17]
3821
- ), r(h, "class", "sy-assistant-textarea-container svelte-46wzni"), r(u, "class", "sy-assistant-input-wrapper svelte-46wzni"), r(k, "x1", "22"), r(k, "y1", "2"), r(k, "x2", "11"), r(k, "y2", "13"), r(_, "points", "22 2 15 22 11 13 2 9 22 2"), r(b, "xmlns", "http://www.w3.org/2000/svg"), r(b, "width", "20"), r(b, "height", "20"), r(b, "viewBox", "0 0 24 24"), r(b, "fill", "none"), r(b, "stroke", "currentColor"), r(b, "stroke-width", "2"), r(b, "stroke-linecap", "round"), r(b, "stroke-linejoin", "round"), r(v, "class", "sy-assistant-send-button svelte-46wzni"), v.disabled = A = !/*message*/
3820
+ s[16]
3821
+ ), r(h, "class", "sy-assistant-textarea-container svelte-46wzni"), r(u, "class", "sy-assistant-input-wrapper svelte-46wzni"), r(k, "x1", "22"), r(k, "y1", "2"), r(k, "x2", "11"), r(k, "y2", "13"), r(y, "points", "22 2 15 22 11 13 2 9 22 2"), r(b, "xmlns", "http://www.w3.org/2000/svg"), r(b, "width", "20"), r(b, "height", "20"), r(b, "viewBox", "0 0 24 24"), r(b, "fill", "none"), r(b, "stroke", "currentColor"), r(b, "stroke-width", "2"), r(b, "stroke-linecap", "round"), r(b, "stroke-linejoin", "round"), r(v, "class", "sy-assistant-send-button svelte-46wzni"), v.disabled = A = !/*message*/
3822
3822
  s[1].trim() || /*isOverLimit*/
3823
- s[17], r(v, "aria-label", "发送消息"), r(c, "class", "sy-assistant-input-container svelte-46wzni"), r(a, "class", "sy-assistant-input-area svelte-46wzni");
3823
+ s[16], r(v, "aria-label", "发送消息"), r(c, "class", "sy-assistant-input-container svelte-46wzni"), r(a, "class", "sy-assistant-input-area svelte-46wzni");
3824
3824
  },
3825
3825
  m(R, P) {
3826
- W(R, e, P), m(e, t), m(t, n), m(t, i), m(t, o), W(R, l, P), W(R, a, P), m(a, c), m(c, u), m(u, h), m(h, p), mt(
3826
+ q(R, e, P), m(e, t), m(t, n), m(t, i), m(t, o), q(R, l, P), q(R, a, P), m(a, c), m(c, u), m(u, h), m(h, p), mt(
3827
3827
  p,
3828
3828
  /*message*/
3829
3829
  s[1]
3830
- ), m(h, g), m(h, d), m(d, w), m(d, S), m(d, C), m(c, M), m(c, v), m(v, b), m(b, k), m(b, _), y || (I = [
3831
- H(
3830
+ ), m(h, d), m(h, g), m(g, w), m(g, S), m(g, C), m(c, M), m(c, v), m(v, b), m(b, k), m(b, y), T || (z = [
3831
+ B(
3832
3832
  n,
3833
3833
  "click",
3834
3834
  /*handleShowHistory*/
3835
3835
  s[29]
3836
3836
  ),
3837
- H(
3837
+ B(
3838
3838
  n,
3839
3839
  "mouseenter",
3840
3840
  /*mouseenter_handler_5*/
3841
3841
  s[48]
3842
3842
  ),
3843
- H(
3843
+ B(
3844
3844
  n,
3845
3845
  "mouseleave",
3846
3846
  /*hideButtonTooltip*/
3847
- s[28]
3847
+ s[27]
3848
3848
  ),
3849
- H(
3849
+ B(
3850
3850
  n,
3851
3851
  "blur",
3852
3852
  /*hideButtonTooltip*/
3853
- s[28]
3853
+ s[27]
3854
3854
  ),
3855
- H(
3855
+ B(
3856
3856
  o,
3857
3857
  "click",
3858
3858
  /*handleNewSession*/
3859
3859
  s[32]
3860
3860
  ),
3861
- H(
3861
+ B(
3862
3862
  o,
3863
3863
  "mouseenter",
3864
3864
  /*mouseenter_handler_6*/
3865
3865
  s[49]
3866
3866
  ),
3867
- H(
3867
+ B(
3868
3868
  o,
3869
3869
  "mouseleave",
3870
3870
  /*hideButtonTooltip*/
3871
- s[28]
3871
+ s[27]
3872
3872
  ),
3873
- H(
3873
+ B(
3874
3874
  p,
3875
3875
  "input",
3876
3876
  /*textarea_input_handler_1*/
3877
3877
  s[50]
3878
3878
  ),
3879
- H(
3879
+ B(
3880
3880
  p,
3881
3881
  "keydown",
3882
3882
  /*keydown_handler*/
3883
3883
  s[51]
3884
3884
  ),
3885
- H(
3885
+ B(
3886
3886
  v,
3887
3887
  "click",
3888
3888
  /*handleSend*/
3889
- s[19]
3889
+ s[18]
3890
3890
  ),
3891
- H(
3891
+ B(
3892
3892
  v,
3893
3893
  "mouseenter",
3894
3894
  /*mouseenter_handler_7*/
3895
3895
  s[52]
3896
3896
  ),
3897
- H(
3897
+ B(
3898
3898
  v,
3899
3899
  "mouseleave",
3900
3900
  /*hideButtonTooltip*/
3901
- s[28]
3901
+ s[27]
3902
3902
  )
3903
- ], y = !0);
3903
+ ], T = !0);
3904
3904
  },
3905
3905
  p(R, P) {
3906
3906
  P[0] & /*message*/
@@ -3914,18 +3914,18 @@ function Fs(s) {
3914
3914
  /*messageLength*/
3915
3915
  R[2]
3916
3916
  ), P[0] & /*isOverLimit*/
3917
- 131072 && Q(
3918
- d,
3917
+ 65536 && J(
3918
+ g,
3919
3919
  "over-limit",
3920
3920
  /*isOverLimit*/
3921
- R[17]
3921
+ R[16]
3922
3922
  ), P[0] & /*message, isOverLimit*/
3923
- 131074 && A !== (A = !/*message*/
3923
+ 65538 && A !== (A = !/*message*/
3924
3924
  R[1].trim() || /*isOverLimit*/
3925
- R[17]) && (v.disabled = A);
3925
+ R[16]) && (v.disabled = A);
3926
3926
  },
3927
3927
  d(R) {
3928
- R && (U(e), U(l), U(a)), y = !1, ve(I);
3928
+ R && (j(e), j(l), j(a)), T = !1, Ee(z);
3929
3929
  }
3930
3930
  };
3931
3931
  }
@@ -3936,7 +3936,7 @@ function Hs(s) {
3936
3936
  ), n;
3937
3937
  return {
3938
3938
  c() {
3939
- e = x("div"), n = Te(t), r(e, "class", "sy-assistant-button-tooltip svelte-46wzni"), F(
3939
+ e = x("div"), n = ve(t), r(e, "class", "sy-assistant-button-tooltip svelte-46wzni"), F(
3940
3940
  e,
3941
3941
  "left",
3942
3942
  /*buttonTooltip*/
@@ -3949,7 +3949,7 @@ function Hs(s) {
3949
3949
  );
3950
3950
  },
3951
3951
  m(i, o) {
3952
- W(i, e, o), m(e, n);
3952
+ q(i, e, o), m(e, n);
3953
3953
  },
3954
3954
  p(i, o) {
3955
3955
  o[0] & /*buttonTooltip*/
@@ -3969,64 +3969,64 @@ function Hs(s) {
3969
3969
  );
3970
3970
  },
3971
3971
  d(i) {
3972
- i && U(e);
3972
+ i && j(e);
3973
3973
  }
3974
3974
  };
3975
3975
  }
3976
- function al(s) {
3976
+ function cl(s) {
3977
3977
  let e, t, n, i, o, l, a;
3978
- const c = [tl, el], u = [];
3979
- function h(d, w) {
3978
+ const c = [nl, tl], u = [];
3979
+ function h(g, w) {
3980
3980
  return (
3981
3981
  /*showHistory*/
3982
- d[15] ? 0 : 1
3982
+ g[15] ? 0 : 1
3983
3983
  );
3984
3984
  }
3985
3985
  t = h(s), n = u[t] = c[t](s);
3986
3986
  let p = !/*showHistory*/
3987
- s[15] && Fs(s), g = (
3987
+ s[15] && Fs(s), d = (
3988
3988
  /*buttonTooltip*/
3989
3989
  s[14] && Hs(s)
3990
3990
  );
3991
3991
  return {
3992
3992
  c() {
3993
- e = x("div"), n.c(), i = j(), p && p.c(), o = j(), g && g.c(), l = Kt(), r(e, "class", "sy-assistant-chat-container svelte-46wzni"), F(
3993
+ e = x("div"), n.c(), i = W(), p && p.c(), o = W(), d && d.c(), l = Kt(), r(e, "class", "sy-assistant-chat-container svelte-46wzni"), F(
3994
3994
  e,
3995
3995
  "z-index",
3996
3996
  /*zIndex*/
3997
3997
  s[0] + 2
3998
3998
  );
3999
3999
  },
4000
- m(d, w) {
4001
- W(d, e, w), u[t].m(e, null), m(e, i), p && p.m(e, null), s[53](e), W(d, o, w), g && g.m(d, w), W(d, l, w), a = !0;
4000
+ m(g, w) {
4001
+ q(g, e, w), u[t].m(e, null), m(e, i), p && p.m(e, null), s[53](e), q(g, o, w), d && d.m(g, w), q(g, l, w), a = !0;
4002
4002
  },
4003
- p(d, w) {
4003
+ p(g, w) {
4004
4004
  let S = t;
4005
- t = h(d), t === S ? u[t].p(d, w) : (Rn(), Ke(u[S], 1, 1, () => {
4005
+ t = h(g), t === S ? u[t].p(g, w) : (Rn(), Ke(u[S], 1, 1, () => {
4006
4006
  u[S] = null;
4007
- }), zn(), n = u[t], n ? n.p(d, w) : (n = u[t] = c[t](d), n.c()), Ne(n, 1), n.m(e, i)), /*showHistory*/
4008
- d[15] ? p && (p.d(1), p = null) : p ? p.p(d, w) : (p = Fs(d), p.c(), p.m(e, null)), (!a || w[0] & /*zIndex*/
4007
+ }), In(), n = u[t], n ? n.p(g, w) : (n = u[t] = c[t](g), n.c()), Ne(n, 1), n.m(e, i)), /*showHistory*/
4008
+ g[15] ? p && (p.d(1), p = null) : p ? p.p(g, w) : (p = Fs(g), p.c(), p.m(e, null)), (!a || w[0] & /*zIndex*/
4009
4009
  1) && F(
4010
4010
  e,
4011
4011
  "z-index",
4012
4012
  /*zIndex*/
4013
- d[0] + 2
4013
+ g[0] + 2
4014
4014
  ), /*buttonTooltip*/
4015
- d[14] ? g ? g.p(d, w) : (g = Hs(d), g.c(), g.m(l.parentNode, l)) : g && (g.d(1), g = null);
4015
+ g[14] ? d ? d.p(g, w) : (d = Hs(g), d.c(), d.m(l.parentNode, l)) : d && (d.d(1), d = null);
4016
4016
  },
4017
- i(d) {
4017
+ i(g) {
4018
4018
  a || (Ne(n), a = !0);
4019
4019
  },
4020
- o(d) {
4020
+ o(g) {
4021
4021
  Ke(n), a = !1;
4022
4022
  },
4023
- d(d) {
4024
- d && (U(e), U(o), U(l)), u[t].d(), p && p.d(), s[53](null), g && g.d(d);
4023
+ d(g) {
4024
+ g && (j(e), j(o), j(l)), u[t].d(), p && p.d(), s[53](null), d && d.d(g);
4025
4025
  }
4026
4026
  };
4027
4027
  }
4028
4028
  let Sn = 500;
4029
- function cl(s) {
4029
+ function Bs(s) {
4030
4030
  const e = s.match(/source#\[(.*)\]#source/);
4031
4031
  if (e)
4032
4032
  try {
@@ -4036,7 +4036,7 @@ function cl(s) {
4036
4036
  }
4037
4037
  return null;
4038
4038
  }
4039
- function qt(s) {
4039
+ function Gt(s) {
4040
4040
  const e = s.split(".");
4041
4041
  if (e.length > 1) {
4042
4042
  const t = e.pop() || "";
@@ -4055,111 +4055,111 @@ function ul(s, e, t) {
4055
4055
  content: "您好!我是您的AI助手,有什么可以帮您的吗?",
4056
4056
  timestamp: Date.now()
4057
4057
  }
4058
- ], a = "", c = null, u = null, h = { x: 0, y: 0, alignRight: !1 }, p = null, g = !1;
4058
+ ], a = "", c = null, u = null, h = { x: 0, y: 0, alignRight: !1 }, p = null, d = !1;
4059
4059
  K.setOptions({
4060
4060
  breaks: !0,
4061
4061
  // 支持换行
4062
4062
  gfm: !0
4063
4063
  // 支持 GitHub 风格 Markdown
4064
4064
  });
4065
- function d(T) {
4065
+ function g(_) {
4066
4066
  try {
4067
- const G = K(T);
4068
- return ys.sanitize(G);
4069
- } catch (G) {
4070
- console.warn("Markdown parsing failed, fallback to HTML:", G);
4067
+ const H = K(_);
4068
+ return ys.sanitize(H);
4069
+ } catch (H) {
4070
+ console.warn("Markdown parsing failed, fallback to HTML:", H);
4071
4071
  try {
4072
- const J = T.replace(/\n/g, "<br>").replace(
4072
+ const V = _.replace(/\n/g, "<br>").replace(
4073
4073
  /\*\*(.*?)\*\*/g,
4074
4074
  "<strong>$1</strong>"
4075
4075
  // 处理加粗
4076
4076
  ).replace(/\*(.*?)\*/g, "<em>$1</em>");
4077
- return ys.sanitize(J);
4078
- } catch (J) {
4079
- return console.error("HTML fallback failed:", J), T;
4077
+ return ys.sanitize(V);
4078
+ } catch (V) {
4079
+ return console.error("HTML fallback failed:", V), _;
4080
4080
  }
4081
4081
  }
4082
4082
  }
4083
4083
  let w;
4084
- function S(T = !1) {
4084
+ function S(_ = !1) {
4085
4085
  w && w.scrollTo({
4086
4086
  top: w.scrollHeight,
4087
- behavior: T ? "smooth" : "auto"
4087
+ behavior: _ ? "smooth" : "auto"
4088
4088
  });
4089
4089
  }
4090
- Ci(() => {
4090
+ Li(() => {
4091
4091
  S(!1);
4092
4092
  });
4093
4093
  let { sessionId: C } = e;
4094
4094
  function M() {
4095
- return Ie(this, null, function* () {
4095
+ return xe(this, null, function* () {
4096
4096
  if (!o.trim() || i) return;
4097
4097
  if (!C) {
4098
4098
  console.error("No session ID available");
4099
4099
  return;
4100
4100
  }
4101
- const T = {
4101
+ const _ = {
4102
4102
  id: Date.now().toString(),
4103
4103
  type: "user",
4104
4104
  content: o.trim(),
4105
4105
  timestamp: Date.now()
4106
4106
  };
4107
- t(3, l = [...l, T]);
4108
- const G = o.trim();
4107
+ t(3, l = [...l, _]);
4108
+ const H = o.trim();
4109
4109
  t(1, o = "");
4110
- const J = (Date.now() + 1).toString();
4110
+ const V = (Date.now() + 1).toString();
4111
4111
  a = "", t(3, l = [
4112
4112
  ...l,
4113
4113
  {
4114
- id: J,
4114
+ id: V,
4115
4115
  type: "assistant",
4116
4116
  content: "",
4117
4117
  timestamp: Date.now()
4118
4118
  }
4119
- ]), t(7, g = !0), c && c.abort(), c = new AbortController();
4119
+ ]), t(7, d = !0), c && c.abort(), c = new AbortController();
4120
4120
  try {
4121
- yield Zi("/aiops/aigc/chat/sse", {
4121
+ yield Xi("/aiops/aigc/chat/sse", {
4122
4122
  method: "POST",
4123
4123
  headers: {
4124
4124
  "Content-Type": "application/json",
4125
- "Auth-Token": `${ye()}`,
4126
- Authorization: `bearer ${ye()}`
4125
+ "Auth-Token": `${me()}`,
4126
+ Authorization: `bearer ${me()}`
4127
4127
  },
4128
4128
  body: JSON.stringify({
4129
4129
  sessionId: C,
4130
4130
  requestId: Date.now().toString(),
4131
- keyword: G,
4131
+ keyword: H,
4132
4132
  flowId: "1"
4133
4133
  }),
4134
4134
  signal: c.signal,
4135
- onmessage(ue) {
4135
+ onmessage(ce) {
4136
4136
  try {
4137
- const Le = ue.data;
4138
- if (Le) {
4139
- const We = cl(Le);
4140
- We ? (t(3, l = l.map((pe) => pe.id === J ? me(ee({}, pe), { attachments: We }) : pe)), S(!0)) : (a += Le, t(3, l = l.map((pe) => pe.id === J ? me(ee({}, pe), { content: a }) : pe)), S(!1));
4137
+ const ue = ce.data;
4138
+ if (ue) {
4139
+ const We = Bs(ue);
4140
+ We ? (t(3, l = l.map((de) => de.id === V ? ke(ee({}, de), { attachments: We }) : de)), S(!0)) : (a += ue, t(3, l = l.map((de) => de.id === V ? ke(ee({}, de), { content: a }) : de)), S(!1));
4141
4141
  }
4142
- } catch (Le) {
4143
- console.error("Failed to process SSE message:", Le);
4142
+ } catch (ue) {
4143
+ console.error("Failed to process SSE message:", ue);
4144
4144
  }
4145
4145
  },
4146
- onerror(ue) {
4147
- console.error("SSE error:", ue), c = null, t(7, g = !1);
4146
+ onerror(ce) {
4147
+ console.error("SSE error:", ce), c = null, t(7, d = !1);
4148
4148
  },
4149
4149
  onclose() {
4150
- c = null, t(7, g = !1);
4150
+ c = null, t(7, d = !1);
4151
4151
  }
4152
4152
  });
4153
- } catch (ue) {
4154
- console.error("Failed to send message:", ue), t(7, g = !1);
4153
+ } catch (ce) {
4154
+ console.error("Failed to send message:", ce), t(7, d = !1);
4155
4155
  }
4156
4156
  });
4157
4157
  }
4158
- function v(T, G, J) {
4159
- const ue = J.getBoundingClientRect(), Le = w.getBoundingClientRect(), We = ue.left < Le.width / 2;
4160
- t(4, u = G), t(5, h = {
4161
- x: ue.left,
4162
- y: ue.top + ue.height / 2,
4158
+ function v(_, H, V) {
4159
+ const ce = V.getBoundingClientRect(), ue = w.getBoundingClientRect(), We = ce.left < ue.width / 2;
4160
+ t(4, u = H), t(5, h = {
4161
+ x: ce.left,
4162
+ y: ce.top + ce.height / 2,
4163
4163
  alignRight: We
4164
4164
  });
4165
4165
  }
@@ -4171,148 +4171,191 @@ function ul(s, e, t) {
4171
4171
  200
4172
4172
  ));
4173
4173
  }
4174
- Li(() => {
4174
+ Mi(() => {
4175
4175
  c && c.abort(), p && clearTimeout(p);
4176
4176
  });
4177
- function k(T, G) {
4178
- return Ie(this, null, function* () {
4177
+ function k(_, H) {
4178
+ return xe(this, null, function* () {
4179
4179
  try {
4180
- const J = yield fetch("/aiops/aigc/file/downloadFile", {
4180
+ const V = yield fetch("/aiops/aigc/file/downloadFile", {
4181
4181
  method: "POST",
4182
4182
  headers: {
4183
4183
  "Content-Type": "application/json",
4184
- "Auth-Token": `${ye()}`,
4185
- Authorization: `bearer ${ye()}`
4184
+ "Auth-Token": `${me()}`,
4185
+ Authorization: `bearer ${me()}`
4186
4186
  },
4187
- body: JSON.stringify({ fileName: T, fileUrl: G })
4187
+ body: JSON.stringify({ fileName: _, fileUrl: H })
4188
4188
  });
4189
- if (!J.ok)
4189
+ if (!V.ok)
4190
4190
  throw new Error("Download failed");
4191
- const ue = J.headers.get("content-type") || "application/octet-stream", Le = yield J.blob(), We = window.URL.createObjectURL(Le), pe = document.createElement("a");
4192
- pe.href = We, pe.download = T, document.body.appendChild(pe), pe.click(), window.URL.revokeObjectURL(We), document.body.removeChild(pe);
4193
- } catch (J) {
4194
- console.error("Failed to download file:", J);
4191
+ const ce = V.headers.get("content-type") || "application/octet-stream", ue = yield V.blob(), We = window.URL.createObjectURL(ue), de = document.createElement("a");
4192
+ de.href = We, de.download = _, document.body.appendChild(de), de.click(), window.URL.revokeObjectURL(We), document.body.removeChild(de);
4193
+ } catch (V) {
4194
+ console.error("Failed to download file:", V);
4195
4195
  }
4196
4196
  });
4197
4197
  }
4198
- let _ = {};
4199
- function A(T, G) {
4200
- return Ie(this, null, function* () {
4198
+ let y = {};
4199
+ function A(_, H) {
4200
+ return xe(this, null, function* () {
4201
4201
  try {
4202
- const J = G.replace(/<br\s*\/?>/g, `
4202
+ const V = H.replace(/<br\s*\/?>/g, `
4203
4203
  `).replace(
4204
4204
  /\*\*(.*?)\*\*/g,
4205
4205
  "$1"
4206
4206
  // 移除加粗标记
4207
4207
  ).replace(/###/g, "").trim();
4208
- yield navigator.clipboard.writeText(J), t(9, _[T] = !0, _), setTimeout(
4208
+ yield navigator.clipboard.writeText(V), t(9, y[_] = !0, y), setTimeout(
4209
4209
  () => {
4210
- t(9, _[T] = !1, _), t(9, _);
4210
+ t(9, y[_] = !1, y), t(9, y);
4211
4211
  },
4212
4212
  1500
4213
4213
  );
4214
- } catch (J) {
4215
- console.error("Failed to copy:", J);
4214
+ } catch (V) {
4215
+ console.error("Failed to copy:", V);
4216
4216
  }
4217
4217
  });
4218
4218
  }
4219
- let y = {}, I = {}, R = !1;
4220
- function P(T, G) {
4221
- return Ie(this, null, function* () {
4222
- if (y[T] === G) {
4223
- t(10, y[T] = null, y), t(10, y);
4219
+ let T = {}, z = {}, R = !1;
4220
+ function P(_, H) {
4221
+ return xe(this, null, function* () {
4222
+ if (T[_] === H) {
4223
+ t(10, T[_] = null, T), t(10, T);
4224
4224
  return;
4225
4225
  }
4226
- if (t(10, y[T] = G, y), t(10, y), G === "like")
4226
+ if (t(10, T[_] = H, T), t(10, T), H === "like")
4227
4227
  try {
4228
4228
  if (!(yield fetch("/aiops/aigc/chat/record/feedback", {
4229
4229
  method: "POST",
4230
4230
  headers: {
4231
4231
  "Content-Type": "application/json",
4232
- "Auth-Token": `${ye()}`,
4233
- Authorization: `bearer ${ye()}`
4232
+ "Auth-Token": `${me()}`,
4233
+ Authorization: `bearer ${me()}`
4234
4234
  },
4235
4235
  body: JSON.stringify({
4236
4236
  sessionId: C,
4237
- requestId: T,
4237
+ requestId: _,
4238
4238
  feedBackFlag: "1",
4239
4239
  feedBackContent: "点赞"
4240
4240
  })
4241
4241
  })).ok)
4242
4242
  throw new Error("Feedback failed");
4243
- } catch (J) {
4244
- console.error("Failed to send feedback:", J), t(10, y[T] = null, y), t(10, y);
4243
+ } catch (V) {
4244
+ console.error("Failed to send feedback:", V), t(10, T[_] = null, T), t(10, T);
4245
4245
  }
4246
4246
  else
4247
4247
  t(12, R = !0);
4248
4248
  });
4249
4249
  }
4250
- function z(T) {
4251
- return Ie(this, null, function* () {
4252
- var G;
4253
- if ((G = I[T]) != null && G.trim())
4250
+ function I(_) {
4251
+ return xe(this, null, function* () {
4252
+ var H;
4253
+ if ((H = z[_]) != null && H.trim())
4254
4254
  try {
4255
4255
  if (!(yield fetch("/aiops/aigc/chat/record/feedback", {
4256
4256
  method: "POST",
4257
4257
  headers: {
4258
4258
  "Content-Type": "application/json",
4259
- "Auth-Token": `${ye()}`,
4260
- Authorization: `bearer ${ye()}`
4259
+ "Auth-Token": `${me()}`,
4260
+ Authorization: `bearer ${me()}`
4261
4261
  },
4262
4262
  body: JSON.stringify({
4263
4263
  sessionId: C,
4264
- requestId: T,
4264
+ requestId: _,
4265
4265
  feedBackFlag: "0",
4266
- feedBackContent: I[T]
4266
+ feedBackContent: z[_]
4267
4267
  })
4268
4268
  })).ok)
4269
4269
  throw new Error("Feedback failed");
4270
- t(12, R = !1), t(11, I[T] = "", I), t(11, I);
4271
- } catch (J) {
4272
- console.error("Failed to send feedback:", J), t(10, y[T] = null, y), t(10, y);
4270
+ t(12, R = !1), t(11, z[_] = "", z), t(11, z);
4271
+ } catch (V) {
4272
+ console.error("Failed to send feedback:", V), t(10, T[_] = null, T), t(10, T);
4273
4273
  }
4274
4274
  });
4275
4275
  }
4276
- let B = { x: 0, y: 0 };
4277
- function Z(T, G) {
4278
- const ue = T.currentTarget.getBoundingClientRect();
4279
- t(13, B = {
4280
- x: ue.left - 290,
4276
+ let U = { x: 0, y: 0 };
4277
+ function Z(_, H) {
4278
+ const ce = _.currentTarget.getBoundingClientRect();
4279
+ t(13, U = {
4280
+ x: ce.left - 290,
4281
4281
  // 弹框宽度 + 间距
4282
- y: ue.top - 160
4282
+ y: ce.top - 160
4283
4283
  // 弹框高度 + 间距
4284
- }), P(G, "dislike");
4285
- }
4286
- let V = null;
4287
- function oe(T, G) {
4288
- const ue = T.currentTarget.getBoundingClientRect();
4289
- t(14, V = {
4290
- text: G,
4291
- x: ue.left + ue.width / 2,
4292
- y: ue.top - 8
4284
+ }), P(H, "dislike");
4285
+ }
4286
+ let Q = null;
4287
+ function oe(_, H) {
4288
+ const ce = _.currentTarget.getBoundingClientRect();
4289
+ t(14, Q = {
4290
+ text: H,
4291
+ x: ce.left + ce.width / 2,
4292
+ y: ce.top - 8
4293
4293
  });
4294
4294
  }
4295
- function fe() {
4296
- t(14, V = null);
4295
+ function he() {
4296
+ t(14, Q = null);
4297
4297
  }
4298
- let ce = !1, Fe = [], re = Date.now().toString();
4298
+ let fe = !1, Fe = [], re = Date.now().toString();
4299
4299
  function Ue() {
4300
- fe(), t(15, ce = !0);
4300
+ he(), t(15, fe = !0);
4301
4301
  }
4302
4302
  function le() {
4303
- fe(), t(15, ce = !1);
4303
+ he(), t(15, fe = !1);
4304
4304
  }
4305
- function Xe(T) {
4306
- re = T, t(15, ce = !1);
4305
+ function Xe(_) {
4306
+ return xe(this, null, function* () {
4307
+ if (!d) {
4308
+ t(7, d = !0);
4309
+ try {
4310
+ const H = yield fetch("/aiops/aigc/chat/record/session/detail/query", {
4311
+ method: "POST",
4312
+ headers: {
4313
+ "Content-Type": "application/json",
4314
+ "Auth-Token": `${me()}`,
4315
+ Authorization: `bearer ${me()}`
4316
+ },
4317
+ body: JSON.stringify({ sessionId: _ })
4318
+ });
4319
+ if (!H.ok)
4320
+ throw new Error("Failed to load sessions");
4321
+ const V = yield H.json();
4322
+ if (V.code === 0) {
4323
+ re = _, t(15, fe = !1);
4324
+ const ce = V.data.map((ue) => [
4325
+ {
4326
+ sessionId: ue.sessionId,
4327
+ requestId: ue.requestId,
4328
+ type: "user",
4329
+ content: ue.keyword,
4330
+ timestamp: new Date(ue.createDate).getTime()
4331
+ },
4332
+ {
4333
+ sessionId: ue.sessionId,
4334
+ requestId: ue.requestId,
4335
+ type: "assistant",
4336
+ content: ue.answer,
4337
+ attachments: Bs(ue.answer),
4338
+ timestamp: new Date(ue.createDate).getTime()
4339
+ }
4340
+ ]);
4341
+ t(3, l = ce.flat());
4342
+ }
4343
+ } catch (H) {
4344
+ console.error("Failed to load sessions:", H);
4345
+ } finally {
4346
+ t(7, d = !1);
4347
+ }
4348
+ }
4349
+ });
4307
4350
  }
4308
4351
  function ie() {
4309
- return Ie(this, null, function* () {
4310
- const T = yield Ee();
4311
- if (!T) {
4352
+ return xe(this, null, function* () {
4353
+ const _ = yield Se();
4354
+ if (!_) {
4312
4355
  console.error("Failed to create new session");
4313
4356
  return;
4314
4357
  }
4315
- re = T, t(3, l = [
4358
+ re = _, t(3, l = [
4316
4359
  {
4317
4360
  id: "-1",
4318
4361
  type: "assistant",
@@ -4322,61 +4365,61 @@ function ul(s, e, t) {
4322
4365
  ]), t(1, o = "");
4323
4366
  });
4324
4367
  }
4325
- function Ee() {
4326
- return Ie(this, null, function* () {
4368
+ function Se() {
4369
+ return xe(this, null, function* () {
4327
4370
  try {
4328
- const T = yield fetch("/aiops/aigc/chat/getSessionId", {
4371
+ const _ = yield fetch("/aiops/aigc/chat/getSessionId", {
4329
4372
  method: "POST",
4330
4373
  headers: {
4331
4374
  "Content-Type": "application/json",
4332
- "Auth-Token": `${ye()}`,
4333
- Authorization: `bearer ${ye()}`
4375
+ "Auth-Token": `${me()}`,
4376
+ Authorization: `bearer ${me()}`
4334
4377
  }
4335
4378
  });
4336
- if (!T.ok)
4379
+ if (!_.ok)
4337
4380
  throw new Error("Failed to get session ID");
4338
- const G = yield T.json();
4339
- if (G.code === 0)
4340
- return re = G.data.sessionId, re;
4341
- throw new Error(G.message || "Failed to get session ID");
4342
- } catch (T) {
4343
- return console.error("Failed to get session ID:", T), null;
4381
+ const H = yield _.json();
4382
+ if (H.code === 0)
4383
+ return re = H.data.sessionId, re;
4384
+ throw new Error(H.message || "Failed to get session ID");
4385
+ } catch (_) {
4386
+ return console.error("Failed to get session ID:", _), null;
4344
4387
  }
4345
4388
  });
4346
4389
  }
4347
4390
  let { zIndex: $ } = e;
4348
- const Re = (T, G) => v(G, T.tips, G.currentTarget), we = (T) => k(T.content_title, T.link), Ve = () => {
4391
+ const ze = (_, H) => v(H, _.tips, H.currentTarget), be = (_) => k(_.content_title, _.link), Ve = () => {
4349
4392
  p && (clearTimeout(p), t(6, p = null));
4350
4393
  }, O = () => {
4351
4394
  t(4, u = null);
4352
- }, ne = (T) => A(T.id, T.content), N = (T, G) => oe(G, _[T.id] ? "已复制" : "复制内容"), q = (T) => P(T.id, "like"), ke = (T, G) => oe(G, y[T.id] === "like" ? "取消点赞" : "点赞"), be = (T, G) => Z(G, T.id), He = (T, G) => oe(G, y[T.id] === "dislike" ? "取消点踩" : "点踩");
4353
- function je(T) {
4354
- I[T.id] = this.value, t(11, I);
4355
- }
4356
- const $e = (T) => {
4357
- t(12, R = !1), t(10, y[T.id] = null, y), t(10, y);
4358
- }, rt = (T) => z(T.id);
4359
- function at(T) {
4360
- wt[T ? "unshift" : "push"](() => {
4361
- w = T, t(8, w);
4395
+ }, ne = (_) => A(_.id, _.content), N = (_, H) => oe(H, y[_.id] ? "已复制" : "复制内容"), G = (_) => P(_.id, "like"), _e = (_, H) => oe(H, T[_.id] === "like" ? "取消点赞" : "点赞"), ye = (_, H) => Z(H, _.id), He = (_, H) => oe(H, T[_.id] === "dislike" ? "取消点踩" : "点踩");
4396
+ function je(_) {
4397
+ z[_.id] = this.value, t(11, z);
4398
+ }
4399
+ const $e = (_) => {
4400
+ t(12, R = !1), t(10, T[_.id] = null, T), t(10, T);
4401
+ }, rt = (_) => I(_.id);
4402
+ function at(_) {
4403
+ wt[_ ? "unshift" : "push"](() => {
4404
+ w = _, t(8, w);
4362
4405
  });
4363
4406
  }
4364
- const Ot = (T) => oe(T, "历史会话"), Dt = (T) => oe(T, "新建会话");
4407
+ const Ot = (_) => oe(_, "历史会话"), Dt = (_) => oe(_, "新建会话");
4365
4408
  function nn() {
4366
4409
  o = this.value, t(1, o);
4367
4410
  }
4368
- const bt = (T) => T.key === "Enter" && !T.shiftKey && (M(), T.preventDefault()), tt = (T) => oe(T, "发送消息");
4369
- function et(T) {
4370
- wt[T ? "unshift" : "push"](() => {
4371
- w = T, t(8, w);
4411
+ const bt = (_) => _.key === "Enter" && !_.shiftKey && (M(), _.preventDefault()), tt = (_) => oe(_, "发送消息");
4412
+ function et(_) {
4413
+ wt[_ ? "unshift" : "push"](() => {
4414
+ w = _, t(8, w);
4372
4415
  });
4373
4416
  }
4374
- return s.$$set = (T) => {
4375
- "sessionId" in T && t(33, C = T.sessionId), "zIndex" in T && t(0, $ = T.zIndex);
4417
+ return s.$$set = (_) => {
4418
+ "sessionId" in _ && t(33, C = _.sessionId), "zIndex" in _ && t(0, $ = _.zIndex);
4376
4419
  }, s.$$.update = () => {
4377
4420
  s.$$.dirty[0] & /*message*/
4378
4421
  2 && t(2, n = o.length), s.$$.dirty[0] & /*messageLength*/
4379
- 4 && t(17, i = n > Sn);
4422
+ 4 && t(16, i = n > Sn);
4380
4423
  }, [
4381
4424
  $,
4382
4425
  o,
@@ -4385,42 +4428,42 @@ function ul(s, e, t) {
4385
4428
  u,
4386
4429
  h,
4387
4430
  p,
4388
- g,
4431
+ d,
4389
4432
  w,
4390
- _,
4391
4433
  y,
4392
- I,
4434
+ T,
4435
+ z,
4393
4436
  R,
4394
- B,
4395
- V,
4396
- ce,
4397
- Fe,
4437
+ U,
4438
+ Q,
4439
+ fe,
4398
4440
  i,
4399
- d,
4441
+ g,
4400
4442
  M,
4401
4443
  v,
4402
4444
  b,
4403
4445
  k,
4404
4446
  A,
4405
4447
  P,
4406
- z,
4448
+ I,
4407
4449
  Z,
4408
4450
  oe,
4409
- fe,
4451
+ he,
4452
+ Fe,
4410
4453
  Ue,
4411
4454
  le,
4412
4455
  Xe,
4413
4456
  ie,
4414
4457
  C,
4415
- Re,
4416
- we,
4458
+ ze,
4459
+ be,
4417
4460
  Ve,
4418
4461
  O,
4419
4462
  ne,
4420
4463
  N,
4421
- q,
4422
- ke,
4423
- be,
4464
+ G,
4465
+ _e,
4466
+ ye,
4424
4467
  He,
4425
4468
  je,
4426
4469
  $e,
@@ -4436,167 +4479,167 @@ function ul(s, e, t) {
4436
4479
  }
4437
4480
  class fl extends Ln {
4438
4481
  constructor(e) {
4439
- super(), Cn(this, e, ul, al, Jt, { sessionId: 33, zIndex: 0 }, null, [-1, -1, -1]);
4482
+ super(), Cn(this, e, ul, cl, Jt, { sessionId: 33, zIndex: 0 }, null, [-1, -1, -1]);
4440
4483
  }
4441
4484
  }
4442
- function Bs(s) {
4485
+ function Us(s) {
4443
4486
  let e, t, n, i, o = (
4444
4487
  /*mergedOptions*/
4445
4488
  s[3].title + ""
4446
- ), l, a, c, u, h, p, g, d, w, S = (
4489
+ ), l, a, c, u, h, p, d, g, w, S = (
4447
4490
  /*isFullscreen*/
4448
4491
  s[2] ? "退出全屏" : "全屏显示"
4449
- ), C, M, v, b, k, _, A, y, I = (
4492
+ ), C, M, v, b, k, y, A, T, z = (
4450
4493
  /*isSnapped*/
4451
4494
  s[7] ? "取消吸附" : "吸附到边缘"
4452
- ), R, P, z, B, Z, V, oe, fe, ce, Fe = `${/*mergedOptions*/
4495
+ ), R, P, I, U, Z, Q, oe, he, fe, Fe = `${/*mergedOptions*/
4453
4496
  s[3].height}px`, re, Ue, le;
4454
- function Xe(N, q) {
4497
+ function Xe(N, G) {
4455
4498
  return (
4456
4499
  /*isFullscreen*/
4457
4500
  N[2] ? pl : hl
4458
4501
  );
4459
4502
  }
4460
- let ie = Xe(s), Ee = ie(s);
4461
- function $(N, q) {
4503
+ let ie = Xe(s), Se = ie(s);
4504
+ function $(N, G) {
4462
4505
  return (
4463
4506
  /*isSnapped*/
4464
4507
  N[7] ? gl : dl
4465
4508
  );
4466
4509
  }
4467
- let Re = $(s), we = Re(s);
4510
+ let ze = $(s), be = ze(s);
4468
4511
  const Ve = [wl, ml], O = [];
4469
- function ne(N, q) {
4512
+ function ne(N, G) {
4470
4513
  return (
4471
4514
  /*showHistory*/
4472
4515
  N[8] ? 0 : 1
4473
4516
  );
4474
4517
  }
4475
- return fe = ne(s), ce = O[fe] = Ve[fe](s), {
4518
+ return he = ne(s), fe = O[he] = Ve[he](s), {
4476
4519
  c() {
4477
- e = x("div"), t = x("div"), n = x("div"), i = x("h3"), l = Te(o), a = j(), c = x("div"), u = x("div"), h = x("button"), p = X("svg"), Ee.c(), d = j(), w = x("span"), C = Te(S), M = j(), v = x("div"), b = x("button"), k = X("svg"), we.c(), A = j(), y = x("span"), R = Te(I), P = j(), z = x("div"), B = x("button"), B.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>', Z = j(), V = x("span"), V.textContent = "关闭助手", oe = j(), ce.c(), r(i, "class", "svelte-1dubpto"), r(p, "xmlns", "http://www.w3.org/2000/svg"), r(p, "width", "18"), r(p, "height", "18"), r(p, "viewBox", "0 0 24 24"), r(p, "fill", "none"), r(p, "stroke", "currentColor"), r(p, "stroke-width", "2"), r(p, "stroke-linecap", "round"), r(p, "stroke-linejoin", "round"), r(h, "class", "sy-assistant-action-button svelte-1dubpto"), r(h, "aria-label", g = /*isFullscreen*/
4478
- s[2] ? "退出全屏" : "全屏显示"), Q(
4520
+ e = x("div"), t = x("div"), n = x("div"), i = x("h3"), l = ve(o), a = W(), c = x("div"), u = x("div"), h = x("button"), p = X("svg"), Se.c(), g = W(), w = x("span"), C = ve(S), M = W(), v = x("div"), b = x("button"), k = X("svg"), be.c(), A = W(), T = x("span"), R = ve(z), P = W(), I = x("div"), U = x("button"), U.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>', Z = W(), Q = x("span"), Q.textContent = "关闭助手", oe = W(), fe.c(), r(i, "class", "svelte-1dubpto"), r(p, "xmlns", "http://www.w3.org/2000/svg"), r(p, "width", "18"), r(p, "height", "18"), r(p, "viewBox", "0 0 24 24"), r(p, "fill", "none"), r(p, "stroke", "currentColor"), r(p, "stroke-width", "2"), r(p, "stroke-linecap", "round"), r(p, "stroke-linejoin", "round"), r(h, "class", "sy-assistant-action-button svelte-1dubpto"), r(h, "aria-label", d = /*isFullscreen*/
4521
+ s[2] ? "退出全屏" : "全屏显示"), J(
4479
4522
  h,
4480
4523
  "active",
4481
4524
  /*isFullscreen*/
4482
4525
  s[2]
4483
- ), r(w, "class", "sy-assistant-tooltip svelte-1dubpto"), r(u, "class", "sy-assistant-tooltip-wrapper svelte-1dubpto"), r(k, "xmlns", "http://www.w3.org/2000/svg"), r(k, "width", "18"), r(k, "height", "18"), r(k, "viewBox", "0 0 24 24"), r(k, "fill", "none"), r(k, "stroke", "currentColor"), r(k, "stroke-width", "2"), r(k, "stroke-linecap", "round"), r(k, "stroke-linejoin", "round"), r(b, "class", "sy-assistant-action-button svelte-1dubpto"), r(b, "aria-label", _ = /*isSnapped*/
4484
- s[7] ? "取消吸附" : "吸附到边缘"), Q(
4526
+ ), r(w, "class", "sy-assistant-tooltip svelte-1dubpto"), r(u, "class", "sy-assistant-tooltip-wrapper svelte-1dubpto"), r(k, "xmlns", "http://www.w3.org/2000/svg"), r(k, "width", "18"), r(k, "height", "18"), r(k, "viewBox", "0 0 24 24"), r(k, "fill", "none"), r(k, "stroke", "currentColor"), r(k, "stroke-width", "2"), r(k, "stroke-linecap", "round"), r(k, "stroke-linejoin", "round"), r(b, "class", "sy-assistant-action-button svelte-1dubpto"), r(b, "aria-label", y = /*isSnapped*/
4527
+ s[7] ? "取消吸附" : "吸附到边缘"), J(
4485
4528
  b,
4486
4529
  "active",
4487
4530
  /*isSnapped*/
4488
4531
  s[7]
4489
- ), r(y, "class", "sy-assistant-tooltip svelte-1dubpto"), r(v, "class", "sy-assistant-tooltip-wrapper svelte-1dubpto"), r(B, "class", "sy-assistant-close-button svelte-1dubpto"), r(B, "aria-label", "关闭助手"), r(V, "class", "sy-assistant-tooltip svelte-1dubpto"), r(z, "class", "sy-assistant-tooltip-wrapper svelte-1dubpto"), r(c, "class", "sy-assistant-header-actions svelte-1dubpto"), r(n, "class", "sy-assistant-drawer-header svelte-1dubpto"), r(n, "role", "button"), r(n, "tabindex", "0"), r(n, "aria-label", "拖动助手窗口"), Q(
4532
+ ), r(T, "class", "sy-assistant-tooltip svelte-1dubpto"), r(v, "class", "sy-assistant-tooltip-wrapper svelte-1dubpto"), r(U, "class", "sy-assistant-close-button svelte-1dubpto"), r(U, "aria-label", "关闭助手"), r(Q, "class", "sy-assistant-tooltip svelte-1dubpto"), r(I, "class", "sy-assistant-tooltip-wrapper svelte-1dubpto"), r(c, "class", "sy-assistant-header-actions svelte-1dubpto"), r(n, "class", "sy-assistant-drawer-header svelte-1dubpto"), r(n, "role", "button"), r(n, "tabindex", "0"), r(n, "aria-label", "拖动助手窗口"), J(
4490
4533
  n,
4491
4534
  "dragging",
4492
4535
  /*isDragging*/
4493
4536
  s[6]
4494
- ), Q(
4537
+ ), J(
4495
4538
  n,
4496
4539
  "fullscreen",
4497
4540
  /*isFullscreen*/
4498
4541
  s[2]
4499
- ), Q(
4542
+ ), J(
4500
4543
  n,
4501
4544
  "snapped",
4502
4545
  /*isSnapped*/
4503
4546
  s[7]
4504
- ), r(t, "class", "sy-assistant-drawer-content svelte-1dubpto"), r(e, "class", "sy-assistant-drawer svelte-1dubpto"), Q(
4547
+ ), r(t, "class", "sy-assistant-drawer-content svelte-1dubpto"), r(e, "class", "sy-assistant-drawer svelte-1dubpto"), J(
4505
4548
  e,
4506
4549
  "fullscreen",
4507
4550
  /*isFullscreen*/
4508
4551
  s[2]
4509
4552
  ), F(e, "height", Fe);
4510
4553
  },
4511
- m(N, q) {
4512
- W(N, e, q), m(e, t), m(t, n), m(n, i), m(i, l), m(n, a), m(n, c), m(c, u), m(u, h), m(h, p), Ee.m(p, null), m(u, d), m(u, w), m(w, C), m(c, M), m(c, v), m(v, b), m(b, k), we.m(k, null), m(v, A), m(v, y), m(y, R), m(c, P), m(c, z), m(z, B), m(z, Z), m(z, V), m(t, oe), O[fe].m(t, null), re = !0, Ue || (le = [
4513
- H(
4554
+ m(N, G) {
4555
+ q(N, e, G), m(e, t), m(t, n), m(n, i), m(i, l), m(n, a), m(n, c), m(c, u), m(u, h), m(h, p), Se.m(p, null), m(u, g), m(u, w), m(w, C), m(c, M), m(c, v), m(v, b), m(b, k), be.m(k, null), m(v, A), m(v, T), m(T, R), m(c, P), m(c, I), m(I, U), m(I, Z), m(I, Q), m(t, oe), O[he].m(t, null), re = !0, Ue || (le = [
4556
+ B(
4514
4557
  h,
4515
4558
  "click",
4516
4559
  /*toggleFullscreen*/
4517
4560
  s[16]
4518
4561
  ),
4519
- H(
4562
+ B(
4520
4563
  b,
4521
4564
  "click",
4522
4565
  /*toggleSnap*/
4523
4566
  s[18]
4524
4567
  ),
4525
- H(
4526
- B,
4568
+ B(
4569
+ U,
4527
4570
  "click",
4528
4571
  /*toggleDrawer*/
4529
4572
  s[15]
4530
4573
  ),
4531
- H(n, "mousedown", qs(
4574
+ B(n, "mousedown", Ys(
4532
4575
  /*handleDragStartWhenNotFullscreen*/
4533
4576
  s[17]
4534
4577
  ))
4535
4578
  ], Ue = !0);
4536
4579
  },
4537
- p(N, q) {
4538
- (!re || q[0] & /*mergedOptions*/
4580
+ p(N, G) {
4581
+ (!re || G[0] & /*mergedOptions*/
4539
4582
  8) && o !== (o = /*mergedOptions*/
4540
- N[3].title + "") && De(l, o), ie !== (ie = Xe(N)) && (Ee.d(1), Ee = ie(N), Ee && (Ee.c(), Ee.m(p, null))), (!re || q[0] & /*isFullscreen*/
4541
- 4 && g !== (g = /*isFullscreen*/
4542
- N[2] ? "退出全屏" : "全屏显示")) && r(h, "aria-label", g), (!re || q[0] & /*isFullscreen*/
4543
- 4) && Q(
4583
+ N[3].title + "") && De(l, o), ie !== (ie = Xe(N)) && (Se.d(1), Se = ie(N), Se && (Se.c(), Se.m(p, null))), (!re || G[0] & /*isFullscreen*/
4584
+ 4 && d !== (d = /*isFullscreen*/
4585
+ N[2] ? "退出全屏" : "全屏显示")) && r(h, "aria-label", d), (!re || G[0] & /*isFullscreen*/
4586
+ 4) && J(
4544
4587
  h,
4545
4588
  "active",
4546
4589
  /*isFullscreen*/
4547
4590
  N[2]
4548
- ), (!re || q[0] & /*isFullscreen*/
4591
+ ), (!re || G[0] & /*isFullscreen*/
4549
4592
  4) && S !== (S = /*isFullscreen*/
4550
- N[2] ? "退出全屏" : "全屏显示") && De(C, S), Re !== (Re = $(N)) && (we.d(1), we = Re(N), we && (we.c(), we.m(k, null))), (!re || q[0] & /*isSnapped*/
4551
- 128 && _ !== (_ = /*isSnapped*/
4552
- N[7] ? "取消吸附" : "吸附到边缘")) && r(b, "aria-label", _), (!re || q[0] & /*isSnapped*/
4553
- 128) && Q(
4593
+ N[2] ? "退出全屏" : "全屏显示") && De(C, S), ze !== (ze = $(N)) && (be.d(1), be = ze(N), be && (be.c(), be.m(k, null))), (!re || G[0] & /*isSnapped*/
4594
+ 128 && y !== (y = /*isSnapped*/
4595
+ N[7] ? "取消吸附" : "吸附到边缘")) && r(b, "aria-label", y), (!re || G[0] & /*isSnapped*/
4596
+ 128) && J(
4554
4597
  b,
4555
4598
  "active",
4556
4599
  /*isSnapped*/
4557
4600
  N[7]
4558
- ), (!re || q[0] & /*isSnapped*/
4559
- 128) && I !== (I = /*isSnapped*/
4560
- N[7] ? "取消吸附" : "吸附到边缘") && De(R, I), (!re || q[0] & /*isDragging*/
4561
- 64) && Q(
4601
+ ), (!re || G[0] & /*isSnapped*/
4602
+ 128) && z !== (z = /*isSnapped*/
4603
+ N[7] ? "取消吸附" : "吸附到边缘") && De(R, z), (!re || G[0] & /*isDragging*/
4604
+ 64) && J(
4562
4605
  n,
4563
4606
  "dragging",
4564
4607
  /*isDragging*/
4565
4608
  N[6]
4566
- ), (!re || q[0] & /*isFullscreen*/
4567
- 4) && Q(
4609
+ ), (!re || G[0] & /*isFullscreen*/
4610
+ 4) && J(
4568
4611
  n,
4569
4612
  "fullscreen",
4570
4613
  /*isFullscreen*/
4571
4614
  N[2]
4572
- ), (!re || q[0] & /*isSnapped*/
4573
- 128) && Q(
4615
+ ), (!re || G[0] & /*isSnapped*/
4616
+ 128) && J(
4574
4617
  n,
4575
4618
  "snapped",
4576
4619
  /*isSnapped*/
4577
4620
  N[7]
4578
4621
  );
4579
- let ke = fe;
4580
- fe = ne(N), fe === ke ? O[fe].p(N, q) : (Rn(), Ke(O[ke], 1, 1, () => {
4581
- O[ke] = null;
4582
- }), zn(), ce = O[fe], ce ? ce.p(N, q) : (ce = O[fe] = Ve[fe](N), ce.c()), Ne(ce, 1), ce.m(t, null)), (!re || q[0] & /*isFullscreen*/
4583
- 4) && Q(
4622
+ let _e = he;
4623
+ he = ne(N), he === _e ? O[he].p(N, G) : (Rn(), Ke(O[_e], 1, 1, () => {
4624
+ O[_e] = null;
4625
+ }), In(), fe = O[he], fe ? fe.p(N, G) : (fe = O[he] = Ve[he](N), fe.c()), Ne(fe, 1), fe.m(t, null)), (!re || G[0] & /*isFullscreen*/
4626
+ 4) && J(
4584
4627
  e,
4585
4628
  "fullscreen",
4586
4629
  /*isFullscreen*/
4587
4630
  N[2]
4588
- ), q[0] & /*mergedOptions*/
4631
+ ), G[0] & /*mergedOptions*/
4589
4632
  8 && Fe !== (Fe = `${/*mergedOptions*/
4590
4633
  N[3].height}px`) && F(e, "height", Fe);
4591
4634
  },
4592
4635
  i(N) {
4593
- re || (Ne(ce), re = !0);
4636
+ re || (Ne(fe), re = !0);
4594
4637
  },
4595
4638
  o(N) {
4596
- Ke(ce), re = !1;
4639
+ Ke(fe), re = !1;
4597
4640
  },
4598
4641
  d(N) {
4599
- N && U(e), Ee.d(), we.d(), O[fe].d(), Ue = !1, ve(le);
4642
+ N && j(e), Se.d(), be.d(), O[he].d(), Ue = !1, Ee(le);
4600
4643
  }
4601
4644
  };
4602
4645
  }
@@ -4607,10 +4650,10 @@ function hl(s) {
4607
4650
  e = X("path"), r(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");
4608
4651
  },
4609
4652
  m(t, n) {
4610
- W(t, e, n);
4653
+ q(t, e, n);
4611
4654
  },
4612
4655
  d(t) {
4613
- t && U(e);
4656
+ t && j(e);
4614
4657
  }
4615
4658
  };
4616
4659
  }
@@ -4621,10 +4664,10 @@ function pl(s) {
4621
4664
  e = X("path"), r(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");
4622
4665
  },
4623
4666
  m(t, n) {
4624
- W(t, e, n);
4667
+ q(t, e, n);
4625
4668
  },
4626
4669
  d(t) {
4627
- t && U(e);
4670
+ t && j(e);
4628
4671
  }
4629
4672
  };
4630
4673
  }
@@ -4635,10 +4678,10 @@ function dl(s) {
4635
4678
  e = X("rect"), t = X("line"), r(e, "x", "3"), r(e, "y", "3"), r(e, "width", "18"), r(e, "height", "18"), r(e, "rx", "2"), r(e, "ry", "2"), r(t, "x1", "16"), r(t, "y1", "6"), r(t, "x2", "16"), r(t, "y2", "18");
4636
4679
  },
4637
4680
  m(n, i) {
4638
- W(n, e, i), W(n, t, i);
4681
+ q(n, e, i), q(n, t, i);
4639
4682
  },
4640
4683
  d(n) {
4641
- n && (U(e), U(t));
4684
+ n && (j(e), j(t));
4642
4685
  }
4643
4686
  };
4644
4687
  }
@@ -4649,10 +4692,10 @@ function gl(s) {
4649
4692
  e = X("rect"), t = X("rect"), r(e, "x", "3"), r(e, "y", "3"), r(e, "width", "18"), r(e, "height", "18"), r(e, "rx", "2"), r(e, "ry", "2"), r(t, "x", "12"), r(t, "y", "10"), r(t, "width", "6"), r(t, "height", "8"), r(t, "rx", "1"), r(t, "ry", "1");
4650
4693
  },
4651
4694
  m(n, i) {
4652
- W(n, e, i), W(n, t, i);
4695
+ q(n, e, i), q(n, t, i);
4653
4696
  },
4654
4697
  d(n) {
4655
- n && (U(e), U(t));
4698
+ n && (j(e), j(t));
4656
4699
  }
4657
4700
  };
4658
4701
  }
@@ -4672,7 +4715,7 @@ function ml(s) {
4672
4715
  }
4673
4716
  }), {
4674
4717
  c() {
4675
- In(e.$$.fragment);
4718
+ zn(e.$$.fragment);
4676
4719
  },
4677
4720
  m(i, o) {
4678
4721
  $t(e, i, o), t = !0;
@@ -4700,7 +4743,7 @@ function ml(s) {
4700
4743
  function wl(s) {
4701
4744
  var n;
4702
4745
  let e, t;
4703
- return e = new hi({
4746
+ return e = new pi({
4704
4747
  props: {
4705
4748
  sessions: (
4706
4749
  /*sessions*/
@@ -4721,7 +4764,7 @@ function wl(s) {
4721
4764
  }
4722
4765
  }), {
4723
4766
  c() {
4724
- In(e.$$.fragment);
4767
+ zn(e.$$.fragment);
4725
4768
  },
4726
4769
  m(i, o) {
4727
4770
  $t(e, i, o), t = !0;
@@ -4748,26 +4791,26 @@ function wl(s) {
4748
4791
  }
4749
4792
  function kl(s) {
4750
4793
  let e, t, n = `${/*$drawerWidth*/
4751
- s[12]}px`, i, o, l, a, c, u, h, p, g, d, w, S, C, M, v = (
4794
+ s[12]}px`, i, o, l, a, c, u, h, p, d, g, w, S, C, M, v = (
4752
4795
  /*$drawerWidth*/
4753
- s[12] > 0 && Bs(s)
4796
+ s[12] > 0 && Us(s)
4754
4797
  );
4755
4798
  return {
4756
4799
  c() {
4757
4800
  var b, k;
4758
- e = x("div"), t = x("div"), v && v.c(), i = j(), o = x("button"), l = X("svg"), a = X("path"), c = X("path"), u = X("path"), h = X("path"), p = X("path"), g = X("path"), d = X("path"), r(t, "class", "sy-assistant-drawer-wrapper svelte-1dubpto"), Q(
4801
+ e = x("div"), t = x("div"), v && v.c(), i = W(), o = x("button"), l = X("svg"), a = X("path"), c = X("path"), u = X("path"), h = X("path"), p = X("path"), d = X("path"), g = X("path"), r(t, "class", "sy-assistant-drawer-wrapper svelte-1dubpto"), J(
4759
4802
  t,
4760
4803
  "fullscreen",
4761
4804
  /*isFullscreen*/
4762
4805
  s[2]
4763
- ), F(t, "width", n), r(a, "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"), r(a, "fill", "#6F8698"), r(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"), r(c, "fill", "#3677FF"), r(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"), r(u, "fill", "#D0D5F1"), r(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"), r(h, "fill", "#3677FF"), r(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"), r(p, "fill", "#FFFFFF"), r(g, "d", "M608.256 583.68a78.336 70.144 90 1 0 140.288 0 78.336 70.144 90 1 0-140.288 0Z"), r(g, "fill", "#FFFFFF"), r(d, "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"), r(d, "fill", "#8896A4"), r(l, "class", "sy-assistant-icon"), r(l, "viewBox", "0 0 1024 1024"), r(l, "version", "1.1"), r(l, "xmlns", "http://www.w3.org/2000/svg"), r(l, "width", "32"), r(l, "height", "32"), r(l, "fill", "currentColor"), r(l, "aria-label", "助手图标"), r(o, "class", "sy-assistant-floating-button svelte-1dubpto"), r(o, "aria-label", "打开助手"), r(o, "style", w = /*buttonStyle*/
4806
+ ), F(t, "width", n), r(a, "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"), r(a, "fill", "#6F8698"), r(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"), r(c, "fill", "#3677FF"), r(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"), r(u, "fill", "#D0D5F1"), r(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"), r(h, "fill", "#3677FF"), r(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"), r(p, "fill", "#FFFFFF"), r(d, "d", "M608.256 583.68a78.336 70.144 90 1 0 140.288 0 78.336 70.144 90 1 0-140.288 0Z"), r(d, "fill", "#FFFFFF"), r(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"), r(g, "fill", "#8896A4"), r(l, "class", "sy-assistant-icon"), r(l, "viewBox", "0 0 1024 1024"), r(l, "version", "1.1"), r(l, "xmlns", "http://www.w3.org/2000/svg"), r(l, "width", "32"), r(l, "height", "32"), r(l, "fill", "currentColor"), r(l, "aria-label", "助手图标"), r(o, "class", "sy-assistant-floating-button svelte-1dubpto"), r(o, "aria-label", "打开助手"), r(o, "style", w = /*buttonStyle*/
4764
4807
  s[10] + " z-index: " + /*mergedOptions*/
4765
- (((b = s[3].zIndex) != null ? b : 1e3) + 1) + ";"), r(e, "class", "sy-assistant-container sy-assistant-theme svelte-1dubpto"), Q(
4808
+ (((b = s[3].zIndex) != null ? b : 1e3) + 1) + ";"), r(e, "class", "sy-assistant-container sy-assistant-theme svelte-1dubpto"), J(
4766
4809
  e,
4767
4810
  "fullscreen",
4768
4811
  /*isFullscreen*/
4769
4812
  s[2]
4770
- ), Q(
4813
+ ), J(
4771
4814
  e,
4772
4815
  "snapped",
4773
4816
  /*isSnapped*/
@@ -4808,27 +4851,27 @@ function kl(s) {
4808
4851
  );
4809
4852
  },
4810
4853
  m(b, k) {
4811
- W(b, e, k), m(e, t), v && v.m(t, null), m(e, i), m(e, o), m(o, l), m(l, a), m(l, c), m(l, u), m(l, h), m(l, p), m(l, g), m(l, d), s[27](o), s[29](e), S = !0, C || (M = [
4812
- H(
4854
+ q(b, e, k), m(e, t), v && v.m(t, null), m(e, i), m(e, o), m(o, l), m(l, a), m(l, c), m(l, u), m(l, h), m(l, p), m(l, d), m(l, g), s[27](o), s[29](e), S = !0, C || (M = [
4855
+ B(
4813
4856
  o,
4814
4857
  "click",
4815
4858
  /*toggleDrawer*/
4816
4859
  s[15]
4817
4860
  ),
4818
- H(o, "mousedown", qs(
4861
+ B(o, "mousedown", Ys(
4819
4862
  /*mousedown_handler*/
4820
4863
  s[28]
4821
4864
  ))
4822
4865
  ], C = !0);
4823
4866
  },
4824
4867
  p(b, k) {
4825
- var _, A;
4868
+ var y, A;
4826
4869
  /*$drawerWidth*/
4827
4870
  b[12] > 0 ? v ? (v.p(b, k), k[0] & /*$drawerWidth*/
4828
- 4096 && Ne(v, 1)) : (v = Bs(b), v.c(), Ne(v, 1), v.m(t, null)) : v && (Rn(), Ke(v, 1, 1, () => {
4871
+ 4096 && Ne(v, 1)) : (v = Us(b), v.c(), Ne(v, 1), v.m(t, null)) : v && (Rn(), Ke(v, 1, 1, () => {
4829
4872
  v = null;
4830
- }), zn()), (!S || k[0] & /*isFullscreen*/
4831
- 4) && Q(
4873
+ }), In()), (!S || k[0] & /*isFullscreen*/
4874
+ 4) && J(
4832
4875
  t,
4833
4876
  "fullscreen",
4834
4877
  /*isFullscreen*/
@@ -4838,14 +4881,14 @@ function kl(s) {
4838
4881
  b[12]}px`) && F(t, "width", n), (!S || k[0] & /*buttonStyle, mergedOptions*/
4839
4882
  1032 && w !== (w = /*buttonStyle*/
4840
4883
  b[10] + " z-index: " + /*mergedOptions*/
4841
- (((_ = b[3].zIndex) != null ? _ : 1e3) + 1) + ";")) && r(o, "style", w), (!S || k[0] & /*isFullscreen*/
4842
- 4) && Q(
4884
+ (((y = b[3].zIndex) != null ? y : 1e3) + 1) + ";")) && r(o, "style", w), (!S || k[0] & /*isFullscreen*/
4885
+ 4) && J(
4843
4886
  e,
4844
4887
  "fullscreen",
4845
4888
  /*isFullscreen*/
4846
4889
  b[2]
4847
4890
  ), (!S || k[0] & /*isSnapped*/
4848
- 128) && Q(
4891
+ 128) && J(
4849
4892
  e,
4850
4893
  "snapped",
4851
4894
  /*isSnapped*/
@@ -4898,13 +4941,13 @@ function kl(s) {
4898
4941
  Ke(v), S = !1;
4899
4942
  },
4900
4943
  d(b) {
4901
- b && U(e), v && v.d(), s[27](null), s[29](null), C = !1, ve(M);
4944
+ b && j(e), v && v.d(), s[27](null), s[29](null), C = !1, Ee(M);
4902
4945
  }
4903
4946
  };
4904
4947
  }
4905
- const mn = 48, he = 20;
4948
+ const mn = 48, pe = 20;
4906
4949
  function bl(s, e, t) {
4907
- let n, i, o, l, a = Ce, c = () => (a(), a = xi(i, (O) => t(12, l = O)), i);
4950
+ let n, i, o, l, a = Le, c = () => (a(), a = Ri(i, (O) => t(12, l = O)), i);
4908
4951
  s.$$.on_destroy.push(() => a());
4909
4952
  const u = {
4910
4953
  position: "fixed",
@@ -4912,23 +4955,23 @@ function bl(s, e, t) {
4912
4955
  height: 600,
4913
4956
  title: "智慧运维助手",
4914
4957
  initialState: "default",
4915
- defaultPosition: { right: he, bottom: he },
4958
+ defaultPosition: { right: pe, bottom: pe },
4916
4959
  snappedWidth: 480,
4917
4960
  // 设置默认吸附抽屉宽度
4918
4961
  drawerWidth: 480,
4919
4962
  // 设置默认抽屉宽度
4920
4963
  zIndex: 1e3
4921
4964
  };
4922
- let { target: h = "body" } = e, { options: p = {} } = e, g, d = null, w = !1, S, C = !1, M = 0, v = 0, b = he, k = 20, _ = b, A = k, y = !1, I = he, R = 50, P = !1, z = { width: 0, height: 0, right: 0, bottom: 0 }, B = !1, Z = !1, V = [], oe = null;
4923
- function fe() {
4924
- return Ie(this, null, function* () {
4965
+ let { target: h = "body" } = e, { options: p = {} } = e, d, g = null, w = !1, S, C = !1, M = 0, v = 0, b = pe, k = 20, y = b, A = k, T = !1, z = pe, R = 50, P = !1, I = { width: 0, height: 0, right: 0, bottom: 0 }, U = !1, Z = !1, Q = [], oe = null;
4966
+ function he() {
4967
+ return xe(this, null, function* () {
4925
4968
  try {
4926
4969
  const O = yield fetch("/aiops/aigc/chat/getSessionId", {
4927
4970
  method: "POST",
4928
4971
  headers: {
4929
4972
  "Content-Type": "application/json",
4930
- "Auth-Token": `${ye()}`,
4931
- Authorization: `bearer ${ye()}`
4973
+ "Auth-Token": `${me()}`,
4974
+ Authorization: `bearer ${me()}`
4932
4975
  }
4933
4976
  });
4934
4977
  if (!O.ok)
@@ -4942,139 +4985,139 @@ function bl(s, e, t) {
4942
4985
  }
4943
4986
  });
4944
4987
  }
4945
- function ce(O, ne = !1) {
4946
- ne ? t(23, y = !0) : t(6, C = !0), M = O.clientX, v = O.clientY, b = ne ? I : _, k = ne ? R : A, O.preventDefault();
4988
+ function fe(O, ne = !1) {
4989
+ ne ? t(23, T = !0) : t(6, C = !0), M = O.clientX, v = O.clientY, b = ne ? z : y, k = ne ? R : A, O.preventDefault();
4947
4990
  }
4948
4991
  function Fe(O) {
4949
- if (!C && !y) return;
4992
+ if (!C && !T) return;
4950
4993
  const ne = M - O.clientX, N = v - O.clientY;
4951
- if (y) {
4952
- const q = b + ne, ke = O.clientY;
4953
- t(24, I = Math.max(he, Math.min(window.innerWidth - mn - he, q)));
4954
- const be = window.innerHeight - mn - he, je = Math.max(he, Math.min(be, ke));
4994
+ if (T) {
4995
+ const G = b + ne, _e = O.clientY;
4996
+ t(24, z = Math.max(pe, Math.min(window.innerWidth - mn - pe, G)));
4997
+ const ye = window.innerHeight - mn - pe, je = Math.max(pe, Math.min(ye, _e));
4955
4998
  t(25, R = (window.innerHeight - je - mn) / window.innerHeight * 100);
4956
4999
  } else {
4957
- const q = n.width || 0, ke = n.height || 0, be = b + ne;
4958
- t(0, _ = Math.max(he, Math.min(window.innerWidth - q - he, be)));
5000
+ const G = n.width || 0, _e = n.height || 0, ye = b + ne;
5001
+ t(0, y = Math.max(pe, Math.min(window.innerWidth - G - pe, ye)));
4959
5002
  const He = k + N;
4960
- t(1, A = Math.max(he, Math.min(window.innerHeight - ke - he, He)));
5003
+ t(1, A = Math.max(pe, Math.min(window.innerHeight - _e - pe, He)));
4961
5004
  }
4962
5005
  }
4963
5006
  function re() {
4964
- t(6, C = !1), t(23, y = !1);
5007
+ t(6, C = !1), t(23, T = !1);
4965
5008
  }
4966
- Ys(() => {
4967
- typeof h == "string" ? d = document.querySelector(h) || document.body : d = h || document.body;
5009
+ Zs(() => {
5010
+ typeof h == "string" ? g = document.querySelector(h) || document.body : g = h || document.body;
4968
5011
  const O = (N) => Fe(N), ne = () => re();
4969
- return document.addEventListener("mousemove", O), document.addEventListener("mouseup", ne), g && d && d.appendChild(g), S && S.getBoundingClientRect().left, t(7, B = n.initialState === "snapped"), t(2, P = n.initialState === "fullscreen"), n.initialState === "snapped" ? (t(0, _ = 0), t(1, A = 0), t(3, n = me(ee({}, n), {
5012
+ return document.addEventListener("mousemove", O), document.addEventListener("mouseup", ne), d && g && g.appendChild(d), S && S.getBoundingClientRect().left, t(7, U = n.initialState === "snapped"), t(2, P = n.initialState === "fullscreen"), n.initialState === "snapped" ? (t(0, y = 0), t(1, A = 0), t(3, n = ke(ee({}, n), {
4970
5013
  height: typeof window != "undefined" ? window.innerHeight : n.height,
4971
5014
  width: n.snappedWidth || n.width
4972
- }))) : n.initialState === "fullscreen" && (t(0, _ = 0), t(1, A = 0), t(3, n = me(ee({}, n), {
5015
+ }))) : n.initialState === "fullscreen" && (t(0, y = 0), t(1, A = 0), t(3, n = ke(ee({}, n), {
4973
5016
  width: typeof window != "undefined" ? window.innerWidth : n.width,
4974
5017
  height: typeof window != "undefined" ? window.innerHeight : n.height
4975
5018
  }))), () => {
4976
- document.removeEventListener("mousemove", O), document.removeEventListener("mouseup", ne), d && g && d.removeChild(g);
5019
+ document.removeEventListener("mousemove", O), document.removeEventListener("mouseup", ne), g && d && g.removeChild(d);
4977
5020
  };
4978
5021
  });
4979
5022
  function Ue() {
4980
- return Ie(this, null, function* () {
4981
- w || (yield fe()), t(22, w = !w);
5023
+ return xe(this, null, function* () {
5024
+ w || (yield he()), t(22, w = !w);
4982
5025
  });
4983
5026
  }
4984
5027
  function le() {
4985
- var O, ne, N, q, ke, be, He, je;
4986
- t(2, P = !P), P ? (z.width || (z = {
5028
+ var O, ne, N, G, _e, ye, He, je;
5029
+ t(2, P = !P), P ? (I.width || (I = {
4987
5030
  width: u.width,
4988
5031
  height: u.height,
4989
- right: (ne = (O = u.defaultPosition) == null ? void 0 : O.right) != null ? ne : he,
4990
- bottom: (q = (N = u.defaultPosition) == null ? void 0 : N.bottom) != null ? q : he
4991
- }), B && t(7, B = !1), t(20, p = me(ee({}, n), {
5032
+ right: (ne = (O = u.defaultPosition) == null ? void 0 : O.right) != null ? ne : pe,
5033
+ bottom: (G = (N = u.defaultPosition) == null ? void 0 : N.bottom) != null ? G : pe
5034
+ }), U && t(7, U = !1), t(20, p = ke(ee({}, n), {
4992
5035
  width: window.innerWidth,
4993
5036
  height: window.innerHeight,
4994
5037
  drawerWidth: window.innerWidth
4995
- })), t(0, _ = 0), t(1, A = 0)) : (t(20, p = me(ee({}, n), {
5038
+ })), t(0, y = 0), t(1, A = 0)) : (t(20, p = ke(ee({}, n), {
4996
5039
  width: u.width,
4997
5040
  height: u.height,
4998
5041
  drawerWidth: u.drawerWidth
4999
- })), t(0, _ = (be = (ke = u.defaultPosition) == null ? void 0 : ke.right) != null ? be : he), t(1, A = (je = (He = u.defaultPosition) == null ? void 0 : He.bottom) != null ? je : he));
5042
+ })), t(0, y = (ye = (_e = u.defaultPosition) == null ? void 0 : _e.right) != null ? ye : pe), t(1, A = (je = (He = u.defaultPosition) == null ? void 0 : He.bottom) != null ? je : pe));
5000
5043
  }
5001
5044
  function Xe(O) {
5002
- P || ce(O);
5045
+ P || fe(O);
5003
5046
  }
5004
5047
  function ie() {
5005
- var O, ne, N, q;
5006
- P && (t(2, P = !1), t(20, p = me(ee({}, n), {
5048
+ var O, ne, N, G;
5049
+ P && (t(2, P = !1), t(20, p = ke(ee({}, n), {
5007
5050
  width: u.width,
5008
5051
  height: u.height,
5009
5052
  drawerWidth: u.drawerWidth
5010
- }))), t(7, B = !B), B ? (n.height, t(0, _ = 0), t(1, A = 0), t(20, p = me(ee({}, n), {
5053
+ }))), t(7, U = !U), U ? (n.height, t(0, y = 0), t(1, A = 0), t(20, p = ke(ee({}, n), {
5011
5054
  height: window.innerHeight,
5012
5055
  width: n.snappedWidth || u.width,
5013
5056
  drawerWidth: n.snappedWidth || u.width
5014
- }))) : (t(20, p = me(ee({}, n), {
5057
+ }))) : (t(20, p = ke(ee({}, n), {
5015
5058
  width: u.width,
5016
5059
  height: u.height,
5017
5060
  drawerWidth: u.drawerWidth
5018
- })), t(0, _ = (ne = (O = u.defaultPosition) == null ? void 0 : O.right) != null ? ne : he), t(1, A = (q = (N = u.defaultPosition) == null ? void 0 : N.bottom) != null ? q : he));
5061
+ })), t(0, y = (ne = (O = u.defaultPosition) == null ? void 0 : O.right) != null ? ne : pe), t(1, A = (G = (N = u.defaultPosition) == null ? void 0 : N.bottom) != null ? G : pe));
5019
5062
  }
5020
- function Ee(O) {
5063
+ function Se(O) {
5021
5064
  t(8, Z = !1);
5022
5065
  }
5023
5066
  const $ = () => t(8, Z = !1);
5024
- function Re(O) {
5067
+ function ze(O) {
5025
5068
  wt[O ? "unshift" : "push"](() => {
5026
5069
  S = O, t(5, S);
5027
5070
  });
5028
5071
  }
5029
- const we = (O) => ce(O, !0);
5072
+ const be = (O) => fe(O, !0);
5030
5073
  function Ve(O) {
5031
5074
  wt[O ? "unshift" : "push"](() => {
5032
- g = O, t(4, g);
5075
+ d = O, t(4, d);
5033
5076
  });
5034
5077
  }
5035
5078
  return s.$$set = (O) => {
5036
5079
  "target" in O && t(21, h = O.target), "options" in O && t(20, p = O.options);
5037
5080
  }, s.$$.update = () => {
5038
5081
  s.$$.dirty[0] & /*options*/
5039
- 1048576 && t(3, n = me(ee(ee({}, u), p), {
5082
+ 1048576 && t(3, n = ke(ee(ee({}, u), p), {
5040
5083
  defaultPosition: ee(ee({}, u.defaultPosition), p.defaultPosition)
5041
5084
  })), s.$$.dirty[0] & /*isOpen, isFullscreen, mergedOptions*/
5042
- 4194316 && c(t(11, i = Bi(
5085
+ 4194316 && c(t(11, i = Ui(
5043
5086
  w ? P ? window.innerWidth : n.drawerWidth : 0,
5044
5087
  { stiffness: 0.1, damping: 0.6 }
5045
5088
  ))), s.$$.dirty[0] & /*mergedOptions, right, bottom*/
5046
- 11 && typeof window != "undefined" && (t(0, _ = Math.max(he, Math.min(window.innerWidth - (n.width || 0), _))), t(1, A = Math.max(he, Math.min(window.innerHeight - (n.height || 0), A)))), s.$$.dirty[0] & /*isOpen, buttonRight, buttonBottom, isButtonDragging*/
5047
- 62914560 && t(10, o = w ? "display: none;" : `position: fixed; right: ${I}px; bottom: ${R}%; transform: none; cursor: ${y ? "grabbing" : "grab"};`);
5089
+ 11 && typeof window != "undefined" && (t(0, y = Math.max(pe, Math.min(window.innerWidth - (n.width || 0), y))), t(1, A = Math.max(pe, Math.min(window.innerHeight - (n.height || 0), A)))), s.$$.dirty[0] & /*isOpen, buttonRight, buttonBottom, isButtonDragging*/
5090
+ 62914560 && t(10, o = w ? "display: none;" : `position: fixed; right: ${z}px; bottom: ${R}%; transform: none; cursor: ${T ? "grabbing" : "grab"};`);
5048
5091
  }, [
5049
- _,
5092
+ y,
5050
5093
  A,
5051
5094
  P,
5052
5095
  n,
5053
- g,
5096
+ d,
5054
5097
  S,
5055
5098
  C,
5056
- B,
5099
+ U,
5057
5100
  Z,
5058
5101
  oe,
5059
5102
  o,
5060
5103
  i,
5061
5104
  l,
5062
- V,
5063
- ce,
5105
+ Q,
5106
+ fe,
5064
5107
  Ue,
5065
5108
  le,
5066
5109
  Xe,
5067
5110
  ie,
5068
- Ee,
5111
+ Se,
5069
5112
  p,
5070
5113
  h,
5071
5114
  w,
5072
- y,
5073
- I,
5115
+ T,
5116
+ z,
5074
5117
  R,
5075
5118
  $,
5076
- Re,
5077
- we,
5119
+ ze,
5120
+ be,
5078
5121
  Ve
5079
5122
  ];
5080
5123
  }