juneau 0.9.0 → 0.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { useState as Me, useRef as Ue, useEffect as St, useCallback as de, useMemo as Ar, useContext as sn, createContext as Tr } from "react";
1
+ import { useState as Re, useRef as Ue, useEffect as St, useCallback as de, useMemo as Ar, useContext as sn, createContext as Tr } from "react";
2
2
  import { jsx as b, jsxs as Y, Fragment as un } from "react/jsx-runtime";
3
3
  function Ki(e) {
4
4
  return e.map((n) => n.role !== "assistant" || n.parts.some((t) => t.type === "text") ? n : { ...n, parts: [{ type: "text", text: "" }] });
@@ -40,9 +40,9 @@ function nl(e, n) {
40
40
  return e.slice(t);
41
41
  }
42
42
  function Jh(e, n) {
43
- return n <= 0 || e.length <= n ? [...e].sort(Rn) : [...e].sort(Rn).slice(0, n);
43
+ return n <= 0 || e.length <= n ? [...e].sort(Mn) : [...e].sort(Mn).slice(0, n);
44
44
  }
45
- const Rn = (e, n) => n.updatedAt.getTime() - e.updatedAt.getTime(), Kh = {
45
+ const Mn = (e, n) => n.updatedAt.getTime() - e.updatedAt.getTime(), Kh = {
46
46
  async *sendMessage(e) {
47
47
  const n = [...e.messages].reverse().find((r) => r.role === "user"), t = n ? Zi(n).toLowerCase() : "";
48
48
  t.includes("activity") || t.includes("progress") || t.includes("document") || t.includes("dokument") ? yield* rl() : t.includes("table") || t.includes("data") || t.includes("list") || t.includes("show") ? yield* il() : t.includes("proposal") || t.includes("suggest") || t.includes("recommend") ? yield* ll() : t.includes("entity") || t.includes("card") || t.includes("detail") || t.includes("find") ? yield* ol() : t.includes("help") || t.includes("what can") || t.includes("how do") ? yield* al() : t.includes("error") || t.includes("fail") || t.includes("break") ? yield* sl() : yield* ul(t);
@@ -387,7 +387,7 @@ const hl = (e) => {
387
387
  return n.length > 0 ? n : e ? [{ type: "text", text: e }] : [];
388
388
  };
389
389
  let dl = 0;
390
- const dt = () => `msg-${++dl}-${Date.now()}`, Mn = Ki;
390
+ const dt = () => `msg-${++dl}-${Date.now()}`, Rn = Ki;
391
391
  function ml({
392
392
  adapter: e,
393
393
  context: n,
@@ -397,38 +397,38 @@ function ml({
397
397
  historyLimit: o,
398
398
  onMessagesChange: l
399
399
  }) {
400
- const [a, s] = Me(i ?? []), [u, f] = Me(""), [c, h] = Me(!1), [p, g] = Me(!1), [C, S] = Me(null), y = Ue(null), I = Ue(!1), _ = Ue(l);
400
+ const [a, s] = Re(i ?? []), [u, f] = Re(""), [c, h] = Re(!1), [p, g] = Re(!1), [C, S] = Re(null), y = Ue(null), I = Ue(!1), _ = Ue(l);
401
401
  St(() => {
402
402
  _.current = l;
403
403
  }), St(() => {
404
404
  !I.current || c || (I.current = !1, _.current?.(a));
405
405
  }, [a, c]);
406
406
  const L = de((v) => {
407
- s((R) => {
408
- const B = R[R.length - 1];
409
- if (!B || B.role !== "assistant") return R;
407
+ s((M) => {
408
+ const j = M[M.length - 1];
409
+ if (!j || j.role !== "assistant") return M;
410
410
  if (v.type === "activity" && v.id) {
411
- const Q = [...B.parts], W = Q.findIndex(
411
+ const Q = [...j.parts], W = Q.findIndex(
412
412
  (d) => d.type === "activity" && d.id === v.id
413
413
  );
414
414
  if (W !== -1)
415
- return Q[W] = v, [...R.slice(0, -1), { ...B, parts: Q }];
415
+ return Q[W] = v, [...M.slice(0, -1), { ...j, parts: Q }];
416
416
  }
417
417
  return [
418
- ...R.slice(0, -1),
419
- { ...B, parts: [...B.parts, v] }
418
+ ...M.slice(0, -1),
419
+ { ...j, parts: [...j.parts, v] }
420
420
  ];
421
421
  });
422
422
  }, []), N = de((v) => {
423
- s((R) => {
424
- const B = R[R.length - 1];
425
- if (!B || B.role !== "assistant") return R;
426
- const Q = [...B.parts], W = Q[Q.length - 1];
427
- return W?.type === "text" ? Q[Q.length - 1] = { type: "text", text: W.text + v } : Q.push({ type: "text", text: v }), [...R.slice(0, -1), { ...B, parts: Q }];
423
+ s((M) => {
424
+ const j = M[M.length - 1];
425
+ if (!j || j.role !== "assistant") return M;
426
+ const Q = [...j.parts], W = Q[Q.length - 1];
427
+ return W?.type === "text" ? Q[Q.length - 1] = { type: "text", text: W.text + v } : Q.push({ type: "text", text: v }), [...M.slice(0, -1), { ...j, parts: Q }];
428
428
  });
429
- }, []), x = de(async (v, R) => {
429
+ }, []), x = de(async (v, M) => {
430
430
  S(null);
431
- const B = {
431
+ const j = {
432
432
  id: dt(),
433
433
  role: "user",
434
434
  parts: [{ type: "text", text: v }],
@@ -446,14 +446,14 @@ function ml({
446
446
  };
447
447
  s((m) => [...m, te]);
448
448
  };
449
- s((te) => [...te, B]), h(!0), g(!0), y.current?.abort();
449
+ s((te) => [...te, j]), h(!0), g(!0), y.current?.abort();
450
450
  const se = new AbortController();
451
451
  y.current = se;
452
452
  try {
453
453
  const te = nl(
454
- [...R, B],
454
+ [...M, j],
455
455
  o ?? Number.POSITIVE_INFINITY
456
- ), m = e.sendMessage({ messages: Mn(te), context: n });
456
+ ), m = e.sendMessage({ messages: Rn(te), context: n });
457
457
  await Nn(
458
458
  m,
459
459
  (ne) => {
@@ -484,18 +484,18 @@ function ml({
484
484
  !v || c || (f(""), await x(v, a));
485
485
  }, [u, c, a, x]), H = de(async (v) => {
486
486
  !v.trim() || c || await x(v, a);
487
- }, [c, a, x]), j = de(async (v) => {
487
+ }, [c, a, x]), B = de(async (v) => {
488
488
  if (c) return;
489
489
  S(null), h(!0), g(!0);
490
- const R = {
490
+ const M = {
491
491
  id: dt(),
492
492
  role: "assistant",
493
493
  parts: [],
494
494
  createdAt: /* @__PURE__ */ new Date()
495
495
  };
496
- s((W) => [...W, R]), y.current?.abort();
497
- const B = new AbortController();
498
- y.current = B;
496
+ s((W) => [...W, M]), y.current?.abort();
497
+ const j = new AbortController();
498
+ y.current = j;
499
499
  const Q = {
500
500
  id: dt(),
501
501
  role: "system",
@@ -503,7 +503,7 @@ function ml({
503
503
  createdAt: /* @__PURE__ */ new Date()
504
504
  };
505
505
  try {
506
- const W = e.sendMessage({ messages: Mn([Q]), context: n });
506
+ const W = e.sendMessage({ messages: Rn([Q]), context: n });
507
507
  await Nn(
508
508
  W,
509
509
  (d) => {
@@ -521,7 +521,7 @@ function ml({
521
521
  break;
522
522
  }
523
523
  },
524
- B.signal
524
+ j.signal
525
525
  );
526
526
  } catch (W) {
527
527
  const d = W instanceof Error ? W.message : "Unknown error occurred";
@@ -533,15 +533,15 @@ function ml({
533
533
  y.current?.abort(), h(!1), g(!1);
534
534
  }, []), T = de((v) => {
535
535
  y.current?.abort(), I.current = !0, s(v ?? []), f(""), S(null), h(!1), g(!1);
536
- }, []), z = de((v, R) => {
537
- I.current = !0, s((B) => B.map((Q) => ({
536
+ }, []), z = de((v, M) => {
537
+ I.current = !0, s((j) => j.map((Q) => ({
538
538
  ...Q,
539
539
  parts: Q.parts.map(
540
- (W) => zr(W) && W.proposal.id === v ? { ...W, proposal: { ...W.proposal, resolved: R } } : W
540
+ (W) => zr(W) && W.proposal.id === v ? { ...W, proposal: { ...W.proposal, resolved: M } } : W
541
541
  )
542
542
  })));
543
- }, []), U = de((v, R) => {
544
- z(v, "confirmed"), t?.(v, R);
543
+ }, []), U = de((v, M) => {
544
+ z(v, "confirmed"), t?.(v, M);
545
545
  }, [t, z]), P = de((v) => {
546
546
  z(v, "cancelled"), r?.(v);
547
547
  }, [r, z]);
@@ -551,7 +551,7 @@ function ml({
551
551
  setInput: f,
552
552
  sendMessage: O,
553
553
  sendMessageWithText: H,
554
- sendGreeting: j,
554
+ sendGreeting: B,
555
555
  stop: k,
556
556
  isLoading: c,
557
557
  isConnecting: p,
@@ -564,7 +564,7 @@ function ml({
564
564
  u,
565
565
  O,
566
566
  H,
567
- j,
567
+ B,
568
568
  k,
569
569
  c,
570
570
  p,
@@ -644,10 +644,29 @@ function kl(e) {
644
644
  "--juneau-color-text-faint": e.colorTextFaint,
645
645
  "--juneau-color-text-inverse": e.colorTextInverse,
646
646
  "--juneau-color-assistant-avatar": e.colorAssistantAvatar,
647
+ "--juneau-color-error-bg": e.colorErrorBg,
648
+ "--juneau-color-error-border": e.colorErrorBorder,
649
+ "--juneau-color-error-text": e.colorErrorText,
650
+ "--juneau-color-success-bg": e.colorSuccessBg,
651
+ "--juneau-color-success-text": e.colorSuccessText,
652
+ "--juneau-color-warning-bg": e.colorWarningBg,
653
+ "--juneau-color-warning-text": e.colorWarningText,
654
+ "--juneau-color-danger-bg": e.colorDangerBg,
655
+ "--juneau-color-danger-text": e.colorDangerText,
647
656
  "--juneau-radius-sm": e.radiusSm,
648
657
  "--juneau-radius-md": e.radiusMd,
649
658
  "--juneau-radius-lg": e.radiusLg,
650
- "--juneau-font-family": e.fontFamily
659
+ "--juneau-radius-full": e.radiusFull,
660
+ "--juneau-font-size-xs": e.fontSizeXs,
661
+ "--juneau-font-size-sm": e.fontSizeSm,
662
+ "--juneau-font-size-base": e.fontSizeBase,
663
+ "--juneau-font-size-md": e.fontSizeMd,
664
+ "--juneau-font-size-lg": e.fontSizeLg,
665
+ "--juneau-font-size-xl": e.fontSizeXl,
666
+ "--juneau-font-size-2xl": e.fontSize2xl,
667
+ "--juneau-font-size-3xl": e.fontSize3xl,
668
+ "--juneau-font-family": e.fontFamily,
669
+ "--juneau-transition-fast": e.transitionFast
651
670
  };
652
671
  return Object.fromEntries(
653
672
  Object.entries(n).filter(([, t]) => t !== void 0)
@@ -675,7 +694,7 @@ function rd({
675
694
  onMessagesChange: l,
676
695
  children: a
677
696
  }) {
678
- const [s, u] = Me(n), f = de((p) => {
697
+ const [s, u] = Re(n), f = de((p) => {
679
698
  u(typeof p == "function" ? (g) => p(g) : p);
680
699
  }, []), c = ml({
681
700
  adapter: e,
@@ -914,7 +933,7 @@ class ct {
914
933
  ct.prototype.normal = {};
915
934
  ct.prototype.property = {};
916
935
  ct.prototype.space = void 0;
917
- function Rr(e, n) {
936
+ function Mr(e, n) {
918
937
  const t = {}, r = {};
919
938
  for (const i of e)
920
939
  Object.assign(t, i.property), Object.assign(r, i.normal);
@@ -948,14 +967,14 @@ ce.prototype.overloadedBoolean = !1;
948
967
  ce.prototype.property = "";
949
968
  ce.prototype.spaceSeparated = !1;
950
969
  ce.prototype.space = void 0;
951
- let Rl = 0;
952
- const M = Be(), Z = Be(), Jt = Be(), E = Be(), G = Be(), Fe = Be(), pe = Be();
953
- function Be() {
954
- return 2 ** ++Rl;
970
+ let Ml = 0;
971
+ const R = je(), Z = je(), Jt = je(), E = je(), G = je(), Fe = je(), pe = je();
972
+ function je() {
973
+ return 2 ** ++Ml;
955
974
  }
956
975
  const Kt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
957
976
  __proto__: null,
958
- boolean: M,
977
+ boolean: R,
959
978
  booleanish: Z,
960
979
  commaOrSpaceSeparated: pe,
961
980
  commaSeparated: Fe,
@@ -982,15 +1001,15 @@ class fn extends ce {
982
1001
  */
983
1002
  constructor(n, t, r, i) {
984
1003
  let o = -1;
985
- if (super(n, t), Bn(this, "space", i), typeof r == "number")
1004
+ if (super(n, t), jn(this, "space", i), typeof r == "number")
986
1005
  for (; ++o < Dt.length; ) {
987
1006
  const l = Dt[o];
988
- Bn(this, Dt[o], (r & Kt[l]) === Kt[l]);
1007
+ jn(this, Dt[o], (r & Kt[l]) === Kt[l]);
989
1008
  }
990
1009
  }
991
1010
  }
992
1011
  fn.prototype.defined = !0;
993
- function Bn(e, n, t) {
1012
+ function jn(e, n, t) {
994
1013
  t && (e[n] = t);
995
1014
  }
996
1015
  function Ye(e) {
@@ -1006,7 +1025,7 @@ function Ye(e) {
1006
1025
  }
1007
1026
  return new ct(n, t, e.space);
1008
1027
  }
1009
- const Mr = Ye({
1028
+ const Rr = Ye({
1010
1029
  properties: {
1011
1030
  ariaActiveDescendant: null,
1012
1031
  ariaAtomic: Z,
@@ -1068,7 +1087,7 @@ function Fr(e, n) {
1068
1087
  function Or(e, n) {
1069
1088
  return Fr(e, n.toLowerCase());
1070
1089
  }
1071
- const Ml = Ye({
1090
+ const Rl = Ye({
1072
1091
  attributes: {
1073
1092
  acceptcharset: "accept-charset",
1074
1093
  classname: "class",
@@ -1084,21 +1103,21 @@ const Ml = Ye({
1084
1103
  accessKey: G,
1085
1104
  action: null,
1086
1105
  allow: null,
1087
- allowFullScreen: M,
1088
- allowPaymentRequest: M,
1089
- allowUserMedia: M,
1090
- alpha: M,
1106
+ allowFullScreen: R,
1107
+ allowPaymentRequest: R,
1108
+ allowUserMedia: R,
1109
+ alpha: R,
1091
1110
  alt: null,
1092
1111
  as: null,
1093
- async: M,
1112
+ async: R,
1094
1113
  autoCapitalize: null,
1095
1114
  autoComplete: G,
1096
- autoFocus: M,
1097
- autoPlay: M,
1115
+ autoFocus: R,
1116
+ autoPlay: R,
1098
1117
  blocking: G,
1099
1118
  capture: null,
1100
1119
  charSet: null,
1101
- checked: M,
1120
+ checked: R,
1102
1121
  cite: null,
1103
1122
  className: G,
1104
1123
  closedBy: null,
@@ -1109,18 +1128,18 @@ const Ml = Ye({
1109
1128
  commandFor: null,
1110
1129
  content: null,
1111
1130
  contentEditable: Z,
1112
- controls: M,
1131
+ controls: R,
1113
1132
  controlsList: G,
1114
1133
  coords: E | Fe,
1115
1134
  crossOrigin: null,
1116
1135
  data: null,
1117
1136
  dateTime: null,
1118
1137
  decoding: null,
1119
- default: M,
1120
- defer: M,
1138
+ default: R,
1139
+ defer: R,
1121
1140
  dir: null,
1122
1141
  dirName: null,
1123
- disabled: M,
1142
+ disabled: R,
1124
1143
  download: Jt,
1125
1144
  draggable: Z,
1126
1145
  encType: null,
@@ -1130,7 +1149,7 @@ const Ml = Ye({
1130
1149
  formAction: null,
1131
1150
  formEncType: null,
1132
1151
  formMethod: null,
1133
- formNoValidate: M,
1152
+ formNoValidate: R,
1134
1153
  formTarget: null,
1135
1154
  headers: G,
1136
1155
  height: E,
@@ -1143,15 +1162,15 @@ const Ml = Ye({
1143
1162
  id: null,
1144
1163
  imageSizes: null,
1145
1164
  imageSrcSet: null,
1146
- inert: M,
1165
+ inert: R,
1147
1166
  inputMode: null,
1148
1167
  integrity: null,
1149
1168
  is: null,
1150
- isMap: M,
1169
+ isMap: R,
1151
1170
  itemId: null,
1152
1171
  itemProp: G,
1153
1172
  itemRef: G,
1154
- itemScope: M,
1173
+ itemScope: R,
1155
1174
  itemType: G,
1156
1175
  kind: null,
1157
1176
  label: null,
@@ -1159,7 +1178,7 @@ const Ml = Ye({
1159
1178
  language: null,
1160
1179
  list: null,
1161
1180
  loading: null,
1162
- loop: M,
1181
+ loop: R,
1163
1182
  low: E,
1164
1183
  manifest: null,
1165
1184
  max: null,
@@ -1168,12 +1187,12 @@ const Ml = Ye({
1168
1187
  method: null,
1169
1188
  min: null,
1170
1189
  minLength: E,
1171
- multiple: M,
1172
- muted: M,
1190
+ multiple: R,
1191
+ muted: R,
1173
1192
  name: null,
1174
1193
  nonce: null,
1175
- noModule: M,
1176
- noValidate: M,
1194
+ noModule: R,
1195
+ noValidate: R,
1177
1196
  onAbort: null,
1178
1197
  onAfterPrint: null,
1179
1198
  onAuxClick: null,
@@ -1262,34 +1281,34 @@ const Ml = Ye({
1262
1281
  onVolumeChange: null,
1263
1282
  onWaiting: null,
1264
1283
  onWheel: null,
1265
- open: M,
1284
+ open: R,
1266
1285
  optimum: E,
1267
1286
  pattern: null,
1268
1287
  ping: G,
1269
1288
  placeholder: null,
1270
- playsInline: M,
1289
+ playsInline: R,
1271
1290
  popover: null,
1272
1291
  popoverTarget: null,
1273
1292
  popoverTargetAction: null,
1274
1293
  poster: null,
1275
1294
  preload: null,
1276
- readOnly: M,
1295
+ readOnly: R,
1277
1296
  referrerPolicy: null,
1278
1297
  rel: G,
1279
- required: M,
1280
- reversed: M,
1298
+ required: R,
1299
+ reversed: R,
1281
1300
  rows: E,
1282
1301
  rowSpan: E,
1283
1302
  sandbox: G,
1284
1303
  scope: null,
1285
- scoped: M,
1286
- seamless: M,
1287
- selected: M,
1288
- shadowRootClonable: M,
1289
- shadowRootCustomElementRegistry: M,
1290
- shadowRootDelegatesFocus: M,
1304
+ scoped: R,
1305
+ seamless: R,
1306
+ selected: R,
1307
+ shadowRootClonable: R,
1308
+ shadowRootCustomElementRegistry: R,
1309
+ shadowRootDelegatesFocus: R,
1291
1310
  shadowRootMode: null,
1292
- shadowRootSerializable: M,
1311
+ shadowRootSerializable: R,
1293
1312
  shape: null,
1294
1313
  size: E,
1295
1314
  sizes: null,
@@ -1308,7 +1327,7 @@ const Ml = Ye({
1308
1327
  title: null,
1309
1328
  translate: null,
1310
1329
  type: null,
1311
- typeMustMatch: M,
1330
+ typeMustMatch: R,
1312
1331
  useMap: null,
1313
1332
  value: Z,
1314
1333
  width: E,
@@ -1354,9 +1373,9 @@ const Ml = Ye({
1354
1373
  // `<object>`
1355
1374
  color: null,
1356
1375
  // `<font>` and `<hr>`. Use CSS instead
1357
- compact: M,
1376
+ compact: R,
1358
1377
  // Lists. Use CSS to reduce space between items instead
1359
- declare: M,
1378
+ declare: R,
1360
1379
  // `<object>`
1361
1380
  event: null,
1362
1381
  // `<script>`
@@ -1380,13 +1399,13 @@ const Ml = Ye({
1380
1399
  // `<body>`
1381
1400
  marginWidth: E,
1382
1401
  // `<body>`
1383
- noResize: M,
1402
+ noResize: R,
1384
1403
  // `<frame>`
1385
- noHref: M,
1404
+ noHref: R,
1386
1405
  // `<area>`. Use no href instead of an explicit `nohref`
1387
- noShade: M,
1406
+ noShade: R,
1388
1407
  // `<hr>`. Use background-color and height instead of borders
1389
- noWrap: M,
1408
+ noWrap: R,
1390
1409
  // `<td>` and `<th>`
1391
1410
  object: null,
1392
1411
  // `<applet>`
@@ -1426,9 +1445,9 @@ const Ml = Ye({
1426
1445
  allowTransparency: null,
1427
1446
  autoCorrect: null,
1428
1447
  autoSave: null,
1429
- credentialless: M,
1430
- disablePictureInPicture: M,
1431
- disableRemotePlayback: M,
1448
+ credentialless: R,
1449
+ disablePictureInPicture: R,
1450
+ disableRemotePlayback: R,
1432
1451
  exportParts: Fe,
1433
1452
  part: G,
1434
1453
  prefix: null,
@@ -1666,7 +1685,7 @@ const Ml = Ye({
1666
1685
  dur: null,
1667
1686
  divisor: E,
1668
1687
  dominantBaseline: null,
1669
- download: M,
1688
+ download: R,
1670
1689
  dx: null,
1671
1690
  dy: null,
1672
1691
  edgeMode: null,
@@ -2000,7 +2019,7 @@ const Ml = Ye({
2000
2019
  },
2001
2020
  space: "svg",
2002
2021
  transform: Fr
2003
- }), Br = Ye({
2022
+ }), jr = Ye({
2004
2023
  properties: {
2005
2024
  xLinkActuate: null,
2006
2025
  xLinkArcRole: null,
@@ -2014,7 +2033,7 @@ const Ml = Ye({
2014
2033
  transform(e, n) {
2015
2034
  return "xlink:" + n.slice(5).toLowerCase();
2016
2035
  }
2017
- }), jr = Ye({
2036
+ }), Br = Ye({
2018
2037
  attributes: { xmlnsxlink: "xmlns:xlink" },
2019
2038
  properties: { xmlnsXLink: null, xmlns: null },
2020
2039
  space: "xmlns",
@@ -2043,20 +2062,20 @@ const Ml = Ye({
2043
2062
  xLinkTitle: "xlinkTitle",
2044
2063
  xLinkType: "xlinkType",
2045
2064
  xmlnsXLink: "xmlnsXlink"
2046
- }, Bl = /[A-Z]/g, jn = /-[a-z]/g, jl = /^data[-\w.:]+$/i;
2065
+ }, jl = /[A-Z]/g, Bn = /-[a-z]/g, Bl = /^data[-\w.:]+$/i;
2047
2066
  function $l(e, n) {
2048
2067
  const t = Gt(n);
2049
2068
  let r = n, i = ce;
2050
2069
  if (t in e.normal)
2051
2070
  return e.property[e.normal[t]];
2052
- if (t.length > 4 && t.slice(0, 4) === "data" && jl.test(n)) {
2071
+ if (t.length > 4 && t.slice(0, 4) === "data" && Bl.test(n)) {
2053
2072
  if (n.charAt(4) === "-") {
2054
- const o = n.slice(5).replace(jn, Vl);
2073
+ const o = n.slice(5).replace(Bn, Vl);
2055
2074
  r = "data" + o.charAt(0).toUpperCase() + o.slice(1);
2056
2075
  } else {
2057
2076
  const o = n.slice(4);
2058
- if (!jn.test(o)) {
2059
- let l = o.replace(Bl, Hl);
2077
+ if (!Bn.test(o)) {
2078
+ let l = o.replace(jl, Hl);
2060
2079
  l.charAt(0) !== "-" && (l = "-" + l), n = "data" + l;
2061
2080
  }
2062
2081
  }
@@ -2070,7 +2089,7 @@ function Hl(e) {
2070
2089
  function Vl(e) {
2071
2090
  return e.charAt(1).toUpperCase();
2072
2091
  }
2073
- const ql = Rr([Mr, Ml, Br, jr, $r], "html"), pn = Rr([Mr, Fl, Br, jr, $r], "svg");
2092
+ const ql = Mr([Rr, Rl, jr, Br, $r], "html"), pn = Mr([Rr, Fl, jr, Br, $r], "svg");
2074
2093
  function Ul(e) {
2075
2094
  return e.join(" ").trim();
2076
2095
  }
@@ -2092,13 +2111,13 @@ function Wl() {
2092
2111
  function L(P) {
2093
2112
  var v = P.match(n);
2094
2113
  v && (I += v.length);
2095
- var R = P.lastIndexOf(s);
2096
- _ = ~R ? P.length - R : _ + P.length;
2114
+ var M = P.lastIndexOf(s);
2115
+ _ = ~M ? P.length - M : _ + P.length;
2097
2116
  }
2098
2117
  function N() {
2099
2118
  var P = { line: I, column: _ };
2100
2119
  return function(v) {
2101
- return v.position = new x(P), j(), v;
2120
+ return v.position = new x(P), B(), v;
2102
2121
  };
2103
2122
  }
2104
2123
  function x(P) {
@@ -2114,11 +2133,11 @@ function Wl() {
2114
2133
  function H(P) {
2115
2134
  var v = P.exec(S);
2116
2135
  if (v) {
2117
- var R = v[0];
2118
- return L(R), S = S.slice(R.length), v;
2136
+ var M = v[0];
2137
+ return L(M), S = S.slice(M.length), v;
2119
2138
  }
2120
2139
  }
2121
- function j() {
2140
+ function B() {
2122
2141
  H(t);
2123
2142
  }
2124
2143
  function k(P) {
@@ -2134,10 +2153,10 @@ function Wl() {
2134
2153
  ++v;
2135
2154
  if (v += 2, c === S.charAt(v - 1))
2136
2155
  return O("End of comment missing");
2137
- var R = S.slice(2, v - 2);
2138
- return _ += 2, L(R), S = S.slice(v), _ += 2, P({
2156
+ var M = S.slice(2, v - 2);
2157
+ return _ += 2, L(M), S = S.slice(v), _ += 2, P({
2139
2158
  type: h,
2140
- comment: R
2159
+ comment: M
2141
2160
  });
2142
2161
  }
2143
2162
  }
@@ -2145,12 +2164,12 @@ function Wl() {
2145
2164
  var P = N(), v = H(r);
2146
2165
  if (v) {
2147
2166
  if (T(), !H(i)) return O("property missing ':'");
2148
- var R = H(o), B = P({
2167
+ var M = H(o), j = P({
2149
2168
  type: p,
2150
2169
  property: C(v[0].replace(e, c)),
2151
- value: R ? C(R[0].replace(e, c)) : c
2170
+ value: M ? C(M[0].replace(e, c)) : c
2152
2171
  });
2153
- return H(l), B;
2172
+ return H(l), j;
2154
2173
  }
2155
2174
  }
2156
2175
  function U() {
@@ -2160,7 +2179,7 @@ function Wl() {
2160
2179
  v !== !1 && (P.push(v), k(P));
2161
2180
  return P;
2162
2181
  }
2163
- return j(), U();
2182
+ return B(), U();
2164
2183
  }
2165
2184
  function C(S) {
2166
2185
  return S ? S.replace(a, c) : c;
@@ -2626,7 +2645,7 @@ function ko(e) {
2626
2645
  function xo(e) {
2627
2646
  return "-" + e.toLowerCase();
2628
2647
  }
2629
- const Rt = {
2648
+ const Mt = {
2630
2649
  action: ["form"],
2631
2650
  cite: ["blockquote", "del", "ins", "q"],
2632
2651
  data: ["object"],
@@ -2917,14 +2936,14 @@ function zo(e) {
2917
2936
  )
2918
2937
  return;
2919
2938
  const O = n.events.length;
2920
- let H = O, j, k;
2939
+ let H = O, B, k;
2921
2940
  for (; H--; )
2922
2941
  if (n.events[H][0] === "exit" && n.events[H][1].type === "chunkFlow") {
2923
- if (j) {
2942
+ if (B) {
2924
2943
  k = n.events[H][1].end;
2925
2944
  break;
2926
2945
  }
2927
- j = !0;
2946
+ B = !0;
2928
2947
  }
2929
2948
  for (y(r), x = O; x < n.events.length; )
2930
2949
  n.events[x][1].end = {
@@ -3042,9 +3061,9 @@ function Jn(e, n) {
3042
3061
  }
3043
3062
  const No = {
3044
3063
  name: "autolink",
3045
- tokenize: Ro
3064
+ tokenize: Mo
3046
3065
  };
3047
- function Ro(e, n, t) {
3066
+ function Mo(e, n, t) {
3048
3067
  let r = 0;
3049
3068
  return i;
3050
3069
  function i(p) {
@@ -3081,9 +3100,9 @@ function Ro(e, n, t) {
3081
3100
  }
3082
3101
  const ft = {
3083
3102
  partial: !0,
3084
- tokenize: Mo
3103
+ tokenize: Ro
3085
3104
  };
3086
- function Mo(e, n, t) {
3105
+ function Ro(e, n, t) {
3087
3106
  return r;
3088
3107
  function r(o) {
3089
3108
  return $(o) ? q(e, i, "linePrefix")(o) : i(o);
@@ -3096,7 +3115,7 @@ const Kr = {
3096
3115
  continuation: {
3097
3116
  tokenize: Oo
3098
3117
  },
3099
- exit: Bo,
3118
+ exit: jo,
3100
3119
  name: "blockQuote",
3101
3120
  tokenize: Fo
3102
3121
  };
@@ -3126,14 +3145,14 @@ function Oo(e, n, t) {
3126
3145
  return e.attempt(Kr, n, t)(l);
3127
3146
  }
3128
3147
  }
3129
- function Bo(e) {
3148
+ function jo(e) {
3130
3149
  e.exit("blockQuote");
3131
3150
  }
3132
3151
  const Zr = {
3133
3152
  name: "characterEscape",
3134
- tokenize: jo
3153
+ tokenize: Bo
3135
3154
  };
3136
- function jo(e, n, t) {
3155
+ function Bo(e, n, t) {
3137
3156
  return r;
3138
3157
  function r(o) {
3139
3158
  return e.enter("characterEscape"), e.enter("escapeMarker"), e.consume(o), e.exit("escapeMarker"), i;
@@ -3227,7 +3246,7 @@ function Ho(e, n, t) {
3227
3246
  return e.exit("codeFenced"), n(x);
3228
3247
  }
3229
3248
  function N(x, O, H) {
3230
- let j = 0;
3249
+ let B = 0;
3231
3250
  return k;
3232
3251
  function k(v) {
3233
3252
  return x.enter("lineEnding"), x.consume(v), x.exit("lineEnding"), T;
@@ -3239,7 +3258,7 @@ function Ho(e, n, t) {
3239
3258
  return v === a ? (x.enter("codeFencedFenceSequence"), U(v)) : H(v);
3240
3259
  }
3241
3260
  function U(v) {
3242
- return v === a ? (j++, x.consume(v), U) : j >= l ? (x.exit("codeFencedFenceSequence"), $(v) ? q(x, P, "whitespace")(v) : P(v)) : H(v);
3261
+ return v === a ? (B++, x.consume(v), U) : B >= l ? (x.exit("codeFencedFenceSequence"), $(v) ? q(x, P, "whitespace")(v) : P(v)) : H(v);
3243
3262
  }
3244
3263
  function P(v) {
3245
3264
  return v === null || D(v) ? (x.exit("codeFencedFence"), O(v)) : H(v);
@@ -3256,7 +3275,7 @@ function Vo(e, n, t) {
3256
3275
  return r.parser.lazy[r.now().line] ? t(l) : n(l);
3257
3276
  }
3258
3277
  }
3259
- const Mt = {
3278
+ const Rt = {
3260
3279
  name: "codeIndented",
3261
3280
  tokenize: Uo
3262
3281
  }, qo = {
@@ -3935,12 +3954,12 @@ function ka(e, n, t) {
3935
3954
  return m === null || m === 60 || m === 61 || m === 62 || m === 96 ? t(m) : m === 34 || m === 39 ? (e.consume(m), s = m, O) : $(m) ? (e.consume(m), x) : H(m);
3936
3955
  }
3937
3956
  function O(m) {
3938
- return m === s ? (e.consume(m), s = null, j) : m === null || D(m) ? t(m) : (e.consume(m), O);
3957
+ return m === s ? (e.consume(m), s = null, B) : m === null || D(m) ? t(m) : (e.consume(m), O);
3939
3958
  }
3940
3959
  function H(m) {
3941
3960
  return m === null || m === 34 || m === 39 || m === 47 || m === 60 || m === 61 || m === 62 || m === 96 || J(m) ? N(m) : (e.consume(m), H);
3942
3961
  }
3943
- function j(m) {
3962
+ function B(m) {
3944
3963
  return m === 47 || m === 62 || $(m) ? _(m) : t(m);
3945
3964
  }
3946
3965
  function k(m) {
@@ -3950,7 +3969,7 @@ function ka(e, n, t) {
3950
3969
  return m === null || D(m) ? z(m) : $(m) ? (e.consume(m), T) : t(m);
3951
3970
  }
3952
3971
  function z(m) {
3953
- return m === 45 && i === 2 ? (e.consume(m), R) : m === 60 && i === 1 ? (e.consume(m), B) : m === 62 && i === 4 ? (e.consume(m), se) : m === 63 && i === 3 ? (e.consume(m), d) : m === 93 && i === 5 ? (e.consume(m), W) : D(m) && (i === 6 || i === 7) ? (e.exit("htmlFlowData"), e.check(ma, te, U)(m)) : m === null || D(m) ? (e.exit("htmlFlowData"), U(m)) : (e.consume(m), z);
3972
+ return m === 45 && i === 2 ? (e.consume(m), M) : m === 60 && i === 1 ? (e.consume(m), j) : m === 62 && i === 4 ? (e.consume(m), se) : m === 63 && i === 3 ? (e.consume(m), d) : m === 93 && i === 5 ? (e.consume(m), W) : D(m) && (i === 6 || i === 7) ? (e.exit("htmlFlowData"), e.check(ma, te, U)(m)) : m === null || D(m) ? (e.exit("htmlFlowData"), U(m)) : (e.consume(m), z);
3954
3973
  }
3955
3974
  function U(m) {
3956
3975
  return e.check(ga, P, te)(m);
@@ -3961,10 +3980,10 @@ function ka(e, n, t) {
3961
3980
  function v(m) {
3962
3981
  return m === null || D(m) ? U(m) : (e.enter("htmlFlowData"), z(m));
3963
3982
  }
3964
- function R(m) {
3983
+ function M(m) {
3965
3984
  return m === 45 ? (e.consume(m), d) : z(m);
3966
3985
  }
3967
- function B(m) {
3986
+ function j(m) {
3968
3987
  return m === 47 ? (e.consume(m), l = "", Q) : z(m);
3969
3988
  }
3970
3989
  function Q(m) {
@@ -4024,35 +4043,35 @@ function Ca(e, n, t) {
4024
4043
  return d === 45 ? (e.consume(d), p) : t(d);
4025
4044
  }
4026
4045
  function c(d) {
4027
- return d === null ? t(d) : d === 45 ? (e.consume(d), h) : D(d) ? (l = c, B(d)) : (e.consume(d), c);
4046
+ return d === null ? t(d) : d === 45 ? (e.consume(d), h) : D(d) ? (l = c, j(d)) : (e.consume(d), c);
4028
4047
  }
4029
4048
  function h(d) {
4030
4049
  return d === 45 ? (e.consume(d), p) : c(d);
4031
4050
  }
4032
4051
  function p(d) {
4033
- return d === 62 ? R(d) : d === 45 ? h(d) : c(d);
4052
+ return d === 62 ? M(d) : d === 45 ? h(d) : c(d);
4034
4053
  }
4035
4054
  function g(d) {
4036
4055
  const se = "CDATA[";
4037
4056
  return d === se.charCodeAt(o++) ? (e.consume(d), o === se.length ? C : g) : t(d);
4038
4057
  }
4039
4058
  function C(d) {
4040
- return d === null ? t(d) : d === 93 ? (e.consume(d), S) : D(d) ? (l = C, B(d)) : (e.consume(d), C);
4059
+ return d === null ? t(d) : d === 93 ? (e.consume(d), S) : D(d) ? (l = C, j(d)) : (e.consume(d), C);
4041
4060
  }
4042
4061
  function S(d) {
4043
4062
  return d === 93 ? (e.consume(d), y) : C(d);
4044
4063
  }
4045
4064
  function y(d) {
4046
- return d === 62 ? R(d) : d === 93 ? (e.consume(d), y) : C(d);
4065
+ return d === 62 ? M(d) : d === 93 ? (e.consume(d), y) : C(d);
4047
4066
  }
4048
4067
  function I(d) {
4049
- return d === null || d === 62 ? R(d) : D(d) ? (l = I, B(d)) : (e.consume(d), I);
4068
+ return d === null || d === 62 ? M(d) : D(d) ? (l = I, j(d)) : (e.consume(d), I);
4050
4069
  }
4051
4070
  function _(d) {
4052
- return d === null ? t(d) : d === 63 ? (e.consume(d), L) : D(d) ? (l = _, B(d)) : (e.consume(d), _);
4071
+ return d === null ? t(d) : d === 63 ? (e.consume(d), L) : D(d) ? (l = _, j(d)) : (e.consume(d), _);
4053
4072
  }
4054
4073
  function L(d) {
4055
- return d === 62 ? R(d) : _(d);
4074
+ return d === 62 ? M(d) : _(d);
4056
4075
  }
4057
4076
  function N(d) {
4058
4077
  return ae(d) ? (e.consume(d), x) : t(d);
@@ -4061,36 +4080,36 @@ function Ca(e, n, t) {
4061
4080
  return d === 45 || ie(d) ? (e.consume(d), x) : O(d);
4062
4081
  }
4063
4082
  function O(d) {
4064
- return D(d) ? (l = O, B(d)) : $(d) ? (e.consume(d), O) : R(d);
4083
+ return D(d) ? (l = O, j(d)) : $(d) ? (e.consume(d), O) : M(d);
4065
4084
  }
4066
4085
  function H(d) {
4067
- return d === 45 || ie(d) ? (e.consume(d), H) : d === 47 || d === 62 || J(d) ? j(d) : t(d);
4086
+ return d === 45 || ie(d) ? (e.consume(d), H) : d === 47 || d === 62 || J(d) ? B(d) : t(d);
4068
4087
  }
4069
- function j(d) {
4070
- return d === 47 ? (e.consume(d), R) : d === 58 || d === 95 || ae(d) ? (e.consume(d), k) : D(d) ? (l = j, B(d)) : $(d) ? (e.consume(d), j) : R(d);
4088
+ function B(d) {
4089
+ return d === 47 ? (e.consume(d), M) : d === 58 || d === 95 || ae(d) ? (e.consume(d), k) : D(d) ? (l = B, j(d)) : $(d) ? (e.consume(d), B) : M(d);
4071
4090
  }
4072
4091
  function k(d) {
4073
4092
  return d === 45 || d === 46 || d === 58 || d === 95 || ie(d) ? (e.consume(d), k) : T(d);
4074
4093
  }
4075
4094
  function T(d) {
4076
- return d === 61 ? (e.consume(d), z) : D(d) ? (l = T, B(d)) : $(d) ? (e.consume(d), T) : j(d);
4095
+ return d === 61 ? (e.consume(d), z) : D(d) ? (l = T, j(d)) : $(d) ? (e.consume(d), T) : B(d);
4077
4096
  }
4078
4097
  function z(d) {
4079
- return d === null || d === 60 || d === 61 || d === 62 || d === 96 ? t(d) : d === 34 || d === 39 ? (e.consume(d), i = d, U) : D(d) ? (l = z, B(d)) : $(d) ? (e.consume(d), z) : (e.consume(d), P);
4098
+ return d === null || d === 60 || d === 61 || d === 62 || d === 96 ? t(d) : d === 34 || d === 39 ? (e.consume(d), i = d, U) : D(d) ? (l = z, j(d)) : $(d) ? (e.consume(d), z) : (e.consume(d), P);
4080
4099
  }
4081
4100
  function U(d) {
4082
- return d === i ? (e.consume(d), i = void 0, v) : d === null ? t(d) : D(d) ? (l = U, B(d)) : (e.consume(d), U);
4101
+ return d === i ? (e.consume(d), i = void 0, v) : d === null ? t(d) : D(d) ? (l = U, j(d)) : (e.consume(d), U);
4083
4102
  }
4084
4103
  function P(d) {
4085
- return d === null || d === 34 || d === 39 || d === 60 || d === 61 || d === 96 ? t(d) : d === 47 || d === 62 || J(d) ? j(d) : (e.consume(d), P);
4104
+ return d === null || d === 34 || d === 39 || d === 60 || d === 61 || d === 96 ? t(d) : d === 47 || d === 62 || J(d) ? B(d) : (e.consume(d), P);
4086
4105
  }
4087
4106
  function v(d) {
4088
- return d === 47 || d === 62 || J(d) ? j(d) : t(d);
4107
+ return d === 47 || d === 62 || J(d) ? B(d) : t(d);
4089
4108
  }
4090
- function R(d) {
4109
+ function M(d) {
4091
4110
  return d === 62 ? (e.consume(d), e.exit("htmlTextData"), e.exit("htmlText"), n) : t(d);
4092
4111
  }
4093
- function B(d) {
4112
+ function j(d) {
4094
4113
  return e.exit("htmlTextData"), e.enter("lineEnding"), e.consume(d), e.exit("lineEnding"), Q;
4095
4114
  }
4096
4115
  function Q(d) {
@@ -4262,9 +4281,9 @@ function Da(e, n, t) {
4262
4281
  const Na = {
4263
4282
  name: "labelStartLink",
4264
4283
  resolveAll: xn.resolveAll,
4265
- tokenize: Ra
4284
+ tokenize: Ma
4266
4285
  };
4267
- function Ra(e, n, t) {
4286
+ function Ma(e, n, t) {
4268
4287
  const r = this;
4269
4288
  return i;
4270
4289
  function i(l) {
@@ -4276,9 +4295,9 @@ function Ra(e, n, t) {
4276
4295
  }
4277
4296
  const Ft = {
4278
4297
  name: "lineEnding",
4279
- tokenize: Ma
4298
+ tokenize: Ra
4280
4299
  };
4281
- function Ma(e, n) {
4300
+ function Ra(e, n) {
4282
4301
  return t;
4283
4302
  function t(r) {
4284
4303
  return e.enter("lineEnding"), e.consume(r), e.exit("lineEnding"), q(e, n, "linePrefix");
@@ -4310,15 +4329,15 @@ const ue = {
4310
4329
  },
4311
4330
  exit: Va,
4312
4331
  name: "list",
4313
- tokenize: ja
4332
+ tokenize: Ba
4314
4333
  }, Oa = {
4315
4334
  partial: !0,
4316
4335
  tokenize: qa
4317
- }, Ba = {
4336
+ }, ja = {
4318
4337
  partial: !0,
4319
4338
  tokenize: Ha
4320
4339
  };
4321
- function ja(e, n, t) {
4340
+ function Ba(e, n, t) {
4322
4341
  const r = this, i = r.events[r.events.length - 1];
4323
4342
  let o = i && i[1].type === "linePrefix" ? i[2].sliceSerialize(i[1], !0).length : 0, l = 0;
4324
4343
  return a;
@@ -4362,7 +4381,7 @@ function $a(e, n, t) {
4362
4381
  return r.containerState.furtherBlankLines = r.containerState.furtherBlankLines || r.containerState.initialBlankLine, q(e, n, "listItemIndent", r.containerState.size + 1)(a);
4363
4382
  }
4364
4383
  function o(a) {
4365
- return r.containerState.furtherBlankLines || !$(a) ? (r.containerState.furtherBlankLines = void 0, r.containerState.initialBlankLine = void 0, l(a)) : (r.containerState.furtherBlankLines = void 0, r.containerState.initialBlankLine = void 0, e.attempt(Ba, n, l)(a));
4384
+ return r.containerState.furtherBlankLines || !$(a) ? (r.containerState.furtherBlankLines = void 0, r.containerState.initialBlankLine = void 0, l(a)) : (r.containerState.furtherBlankLines = void 0, r.containerState.initialBlankLine = void 0, e.attempt(ja, n, l)(a));
4366
4385
  }
4367
4386
  function l(a) {
4368
4387
  return r.containerState._closeFlow = !0, r.interrupt = void 0, q(e, e.attempt(ue, n, t), "linePrefix", r.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4)(a);
@@ -4574,9 +4593,9 @@ const Za = {
4574
4593
  }, es = {
4575
4594
  91: ia
4576
4595
  }, ts = {
4577
- [-2]: Mt,
4578
- [-1]: Mt,
4579
- 32: Mt
4596
+ [-2]: Rt,
4597
+ [-1]: Rt,
4598
+ 32: Rt
4580
4599
  }, ns = {
4581
4600
  35: ca,
4582
4601
  42: Ct,
@@ -4717,8 +4736,8 @@ function us(e, n, t) {
4717
4736
  }
4718
4737
  function O(T, z) {
4719
4738
  return U;
4720
- function U(P, v, R) {
4721
- let B, Q, W, d;
4739
+ function U(P, v, M) {
4740
+ let j, Q, W, d;
4722
4741
  return Array.isArray(P) ? (
4723
4742
  /* c8 ignore next 1 */
4724
4743
  te(P)
@@ -4732,22 +4751,22 @@ function us(e, n, t) {
4732
4751
  function se(re) {
4733
4752
  return Xe;
4734
4753
  function Xe(Ie) {
4735
- const je = Ie !== null && re[Ie], $e = Ie !== null && re.null, ht = [
4754
+ const Be = Ie !== null && re[Ie], $e = Ie !== null && re.null, ht = [
4736
4755
  // To do: add more extension tests.
4737
4756
  /* c8 ignore next 2 */
4738
- ...Array.isArray(je) ? je : je ? [je] : [],
4757
+ ...Array.isArray(Be) ? Be : Be ? [Be] : [],
4739
4758
  ...Array.isArray($e) ? $e : $e ? [$e] : []
4740
4759
  ];
4741
4760
  return te(ht)(Ie);
4742
4761
  }
4743
4762
  }
4744
4763
  function te(re) {
4745
- return B = re, Q = 0, re.length === 0 ? R : m(re[Q]);
4764
+ return j = re, Q = 0, re.length === 0 ? M : m(re[Q]);
4746
4765
  }
4747
4766
  function m(re) {
4748
4767
  return Xe;
4749
4768
  function Xe(Ie) {
4750
- return d = j(), W = re, re.partial || (u.currentConstruct = re), re.name && u.parser.constructs.disable.null.includes(re.name) ? Pe() : re.tokenize.call(
4769
+ return d = B(), W = re, re.partial || (u.currentConstruct = re), re.name && u.parser.constructs.disable.null.includes(re.name) ? Pe() : re.tokenize.call(
4751
4770
  // If we do have fields, create an object w/ `context` as its
4752
4771
  // prototype.
4753
4772
  // This allows a “live binding”, which is needed for `interrupt`.
@@ -4762,20 +4781,20 @@ function us(e, n, t) {
4762
4781
  return T(W, d), v;
4763
4782
  }
4764
4783
  function Pe(re) {
4765
- return d.restore(), ++Q < B.length ? m(B[Q]) : R;
4784
+ return d.restore(), ++Q < j.length ? m(j[Q]) : M;
4766
4785
  }
4767
4786
  }
4768
4787
  }
4769
4788
  function H(T, z) {
4770
4789
  T.resolveAll && !o.includes(T) && o.push(T), T.resolve && he(u.events, z, u.events.length - z, T.resolve(u.events.slice(z), u)), T.resolveTo && (u.events = T.resolveTo(u.events, u));
4771
4790
  }
4772
- function j() {
4791
+ function B() {
4773
4792
  const T = g(), z = u.previous, U = u.currentConstruct, P = u.events.length, v = Array.from(a);
4774
4793
  return {
4775
4794
  from: P,
4776
- restore: R
4795
+ restore: M
4777
4796
  };
4778
- function R() {
4797
+ function M() {
4779
4798
  r = T, u.previous = z, u.currentConstruct = U, u.events.length = P, a = v, k();
4780
4799
  }
4781
4800
  }
@@ -4923,20 +4942,20 @@ function xs(e) {
4923
4942
  canContainEols: ["emphasis", "fragment", "heading", "paragraph", "strong"],
4924
4943
  enter: {
4925
4944
  autolink: o(Ln),
4926
- autolinkProtocol: j,
4927
- autolinkEmail: j,
4945
+ autolinkProtocol: B,
4946
+ autolinkEmail: B,
4928
4947
  atxHeading: o(Tn),
4929
4948
  blockQuote: o($e),
4930
- characterEscape: j,
4931
- characterReference: j,
4949
+ characterEscape: B,
4950
+ characterReference: B,
4932
4951
  codeFenced: o(ht),
4933
4952
  codeFencedFenceInfo: l,
4934
4953
  codeFencedFenceMeta: l,
4935
4954
  codeIndented: o(ht, l),
4936
4955
  codeText: o(Vi, l),
4937
- codeTextData: j,
4938
- data: j,
4939
- codeFlowValue: j,
4956
+ codeTextData: B,
4957
+ data: B,
4958
+ codeFlowValue: B,
4940
4959
  definition: o(qi),
4941
4960
  definitionDestinationString: l,
4942
4961
  definitionLabelString: l,
@@ -4945,9 +4964,9 @@ function xs(e) {
4945
4964
  hardBreakEscape: o(zn),
4946
4965
  hardBreakTrailing: o(zn),
4947
4966
  htmlFlow: o(Pn, l),
4948
- htmlFlowData: j,
4967
+ htmlFlowData: B,
4949
4968
  htmlText: o(Pn, l),
4950
- htmlTextData: j,
4969
+ htmlTextData: B,
4951
4970
  image: o(Wi),
4952
4971
  label: l,
4953
4972
  link: o(Ln),
@@ -4968,7 +4987,7 @@ function xs(e) {
4968
4987
  atxHeading: s(),
4969
4988
  atxHeadingSequence: N,
4970
4989
  autolink: s(),
4971
- autolinkEmail: je,
4990
+ autolinkEmail: Be,
4972
4991
  autolinkProtocol: Ie,
4973
4992
  blockQuote: s(),
4974
4993
  characterEscapeValue: k,
@@ -4996,11 +5015,11 @@ function xs(e) {
4996
5015
  htmlFlowData: k,
4997
5016
  htmlText: s(P),
4998
5017
  htmlTextData: k,
4999
- image: s(B),
5018
+ image: s(j),
5000
5019
  label: W,
5001
5020
  labelText: Q,
5002
5021
  lineEnding: T,
5003
- link: s(R),
5022
+ link: s(M),
5004
5023
  listItem: s(),
5005
5024
  listOrdered: s(),
5006
5025
  listUnordered: s(),
@@ -5213,7 +5232,7 @@ function xs(e) {
5213
5232
  function H() {
5214
5233
  this.data.setextHeadingSlurpLineEnding = void 0;
5215
5234
  }
5216
- function j(w) {
5235
+ function B(w) {
5217
5236
  const F = this.stack[this.stack.length - 1].children;
5218
5237
  let V = F[F.length - 1];
5219
5238
  (!V || V.type !== "text") && (V = Gi(), V.position = {
@@ -5233,7 +5252,7 @@ function xs(e) {
5233
5252
  F.position.end = Ae(w.end), this.data.atHardBreak = void 0;
5234
5253
  return;
5235
5254
  }
5236
- !this.data.setextHeadingSlurpLineEnding && n.canContainEols.includes(A.type) && (j.call(this, w), k.call(this, w));
5255
+ !this.data.setextHeadingSlurpLineEnding && n.canContainEols.includes(A.type) && (B.call(this, w), k.call(this, w));
5237
5256
  }
5238
5257
  function z() {
5239
5258
  this.data.atHardBreak = !0;
@@ -5250,7 +5269,7 @@ function xs(e) {
5250
5269
  const w = this.resume(), A = this.stack[this.stack.length - 1];
5251
5270
  A.value = w;
5252
5271
  }
5253
- function R() {
5272
+ function M() {
5254
5273
  const w = this.stack[this.stack.length - 1];
5255
5274
  if (this.data.inReference) {
5256
5275
  const A = this.data.referenceType || "shortcut";
@@ -5259,7 +5278,7 @@ function xs(e) {
5259
5278
  delete w.identifier, delete w.label;
5260
5279
  this.data.referenceType = void 0;
5261
5280
  }
5262
- function B() {
5281
+ function j() {
5263
5282
  const w = this.stack[this.stack.length - 1];
5264
5283
  if (this.data.inReference) {
5265
5284
  const A = this.data.referenceType || "shortcut";
@@ -5317,7 +5336,7 @@ function xs(e) {
5317
5336
  const A = this.stack[this.stack.length - 1];
5318
5337
  A.url = this.sliceSerialize(w);
5319
5338
  }
5320
- function je(w) {
5339
+ function Be(w) {
5321
5340
  k.call(this, w);
5322
5341
  const A = this.stack[this.stack.length - 1];
5323
5342
  A.url = "mailto:" + this.sliceSerialize(w);
@@ -5641,8 +5660,8 @@ function Ns(e, n) {
5641
5660
  };
5642
5661
  return e.patch(n, r), e.applyData(n, r);
5643
5662
  }
5644
- function Rs(e, n, t) {
5645
- const r = e.all(n), i = t ? Ms(t) : ci(n), o = {}, l = [];
5663
+ function Ms(e, n, t) {
5664
+ const r = e.all(n), i = t ? Rs(t) : ci(n), o = {}, l = [];
5646
5665
  if (typeof n.checked == "boolean") {
5647
5666
  const f = r[0];
5648
5667
  let c;
@@ -5665,7 +5684,7 @@ function Rs(e, n, t) {
5665
5684
  const u = { type: "element", tagName: "li", properties: o, children: l };
5666
5685
  return e.patch(n, u), e.applyData(n, u);
5667
5686
  }
5668
- function Ms(e) {
5687
+ function Rs(e) {
5669
5688
  let n = !1;
5670
5689
  if (e.type === "list") {
5671
5690
  n = e.spread || !1;
@@ -5707,11 +5726,11 @@ function Os(e, n) {
5707
5726
  };
5708
5727
  return e.patch(n, t), e.applyData(n, t);
5709
5728
  }
5710
- function Bs(e, n) {
5729
+ function js(e, n) {
5711
5730
  const t = { type: "root", children: e.wrap(e.all(n)) };
5712
5731
  return e.patch(n, t), e.applyData(n, t);
5713
5732
  }
5714
- function js(e, n) {
5733
+ function Bs(e, n) {
5715
5734
  const t = {
5716
5735
  type: "element",
5717
5736
  tagName: "strong",
@@ -5829,12 +5848,12 @@ const Ys = {
5829
5848
  inlineCode: Ls,
5830
5849
  linkReference: Ds,
5831
5850
  link: Ns,
5832
- listItem: Rs,
5851
+ listItem: Ms,
5833
5852
  list: Fs,
5834
5853
  paragraph: Os,
5835
5854
  // @ts-expect-error: root is different, but hard to type.
5836
- root: Bs,
5837
- strong: js,
5855
+ root: js,
5856
+ strong: Bs,
5838
5857
  table: $s,
5839
5858
  tableCell: Vs,
5840
5859
  tableRow: Hs,
@@ -5918,24 +5937,24 @@ const fi = -1, zt = 0, at = 1, _t = 2, bn = 3, wn = 4, Cn = 5, Sn = 6, pi = 7, h
5918
5937
  return t(ar(o, l), i);
5919
5938
  };
5920
5939
  return r;
5921
- }, sr = (e) => Qs(/* @__PURE__ */ new Map(), e)(0), Re = "", { toString: Xs } = {}, { keys: Gs } = Object, tt = (e) => {
5940
+ }, sr = (e) => Qs(/* @__PURE__ */ new Map(), e)(0), Me = "", { toString: Xs } = {}, { keys: Gs } = Object, tt = (e) => {
5922
5941
  const n = typeof e;
5923
5942
  if (n !== "object" || !e)
5924
5943
  return [zt, n];
5925
5944
  const t = Xs.call(e).slice(8, -1);
5926
5945
  switch (t) {
5927
5946
  case "Array":
5928
- return [at, Re];
5947
+ return [at, Me];
5929
5948
  case "Object":
5930
- return [_t, Re];
5949
+ return [_t, Me];
5931
5950
  case "Date":
5932
- return [bn, Re];
5951
+ return [bn, Me];
5933
5952
  case "RegExp":
5934
- return [wn, Re];
5953
+ return [wn, Me];
5935
5954
  case "Map":
5936
- return [Cn, Re];
5955
+ return [Cn, Me];
5937
5956
  case "Set":
5938
- return [Sn, Re];
5957
+ return [Sn, Me];
5939
5958
  case "DataView":
5940
5959
  return [at, t];
5941
5960
  }
@@ -5994,7 +6013,7 @@ const fi = -1, zt = 0, at = 1, _t = 2, bn = 3, wn = 4, Cn = 5, Sn = 6, pi = 7, h
5994
6013
  return c;
5995
6014
  }
5996
6015
  case bn:
5997
- return i([a, isNaN(l.getTime()) ? Re : l.toISOString()], l);
6016
+ return i([a, isNaN(l.getTime()) ? Me : l.toISOString()], l);
5998
6017
  case wn: {
5999
6018
  const { source: f, flags: c } = l;
6000
6019
  return i([a, { source: f, flags: c }], l);
@@ -6410,7 +6429,7 @@ function gu() {
6410
6429
  }, Ot;
6411
6430
  }
6412
6431
  var yu = gu();
6413
- const Bt = /* @__PURE__ */ Hr(yu);
6432
+ const jt = /* @__PURE__ */ Hr(yu);
6414
6433
  function ln(e) {
6415
6434
  if (typeof e != "object" || e === null)
6416
6435
  return !1;
@@ -6626,7 +6645,7 @@ function Tu(e) {
6626
6645
  }
6627
6646
  return decodeURIComponent(n);
6628
6647
  }
6629
- const jt = (
6648
+ const Bt = (
6630
6649
  /** @type {const} */
6631
6650
  [
6632
6651
  "history",
@@ -6664,13 +6683,13 @@ class yi {
6664
6683
  let t;
6665
6684
  n ? on(n) ? t = { path: n } : typeof n == "string" || zu(n) ? t = { value: n } : t = n : t = {}, this.cwd = "cwd" in t ? "" : Eu.cwd(), this.data = {}, this.history = [], this.messages = [], this.value, this.map, this.result, this.stored;
6666
6685
  let r = -1;
6667
- for (; ++r < jt.length; ) {
6668
- const o = jt[r];
6686
+ for (; ++r < Bt.length; ) {
6687
+ const o = Bt[r];
6669
6688
  o in t && t[o] !== void 0 && t[o] !== null && (this[o] = o === "history" ? [...t[o]] : t[o]);
6670
6689
  }
6671
6690
  let i;
6672
6691
  for (i in t)
6673
- jt.includes(i) || (this[i] = t[i]);
6692
+ Bt.includes(i) || (this[i] = t[i]);
6674
6693
  }
6675
6694
  /**
6676
6695
  * Get the basename (including extname) (example: `'index.min.js'`).
@@ -7074,7 +7093,7 @@ class _n extends Pu {
7074
7093
  const r = this.attachers[t];
7075
7094
  n.use(...r);
7076
7095
  }
7077
- return n.data(Bt(!0, {}, this.namespace)), n;
7096
+ return n.data(jt(!0, {}, this.namespace)), n;
7078
7097
  }
7079
7098
  /**
7080
7099
  * Configure the processor with info available to all plugins.
@@ -7251,7 +7270,7 @@ class _n extends Pu {
7251
7270
  /** @type {unknown} */
7252
7271
  c
7253
7272
  ), g = r.stringify(p, h);
7254
- Ru(g) ? h.value = g : h.result = g, u(
7273
+ Mu(g) ? h.value = g : h.result = g, u(
7255
7274
  f,
7256
7275
  /** @type {VFileWithOutput<CompileResult>} */
7257
7276
  h
@@ -7498,7 +7517,7 @@ class _n extends Pu {
7498
7517
  throw new Error(
7499
7518
  "Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither"
7500
7519
  );
7501
- a(u.plugins), u.settings && (i.settings = Bt(!0, i.settings, u.settings));
7520
+ a(u.plugins), u.settings && (i.settings = jt(!0, i.settings, u.settings));
7502
7521
  }
7503
7522
  function a(u) {
7504
7523
  let f = -1;
@@ -7522,7 +7541,7 @@ class _n extends Pu {
7522
7541
  else if (f.length > 0) {
7523
7542
  let [p, ...g] = f;
7524
7543
  const C = r[h][1];
7525
- ln(C) && ln(p) && (p = Bt(!0, C, p)), r[h] = [u, p, ...g];
7544
+ ln(C) && ln(p) && (p = jt(!0, C, p)), r[h] = [u, p, ...g];
7526
7545
  }
7527
7546
  }
7528
7547
  }
@@ -7558,13 +7577,13 @@ function yt(e) {
7558
7577
  function Nu(e) {
7559
7578
  return !!(e && typeof e == "object" && "message" in e && "messages" in e);
7560
7579
  }
7561
- function Ru(e) {
7562
- return typeof e == "string" || Mu(e);
7563
- }
7564
7580
  function Mu(e) {
7581
+ return typeof e == "string" || Ru(e);
7582
+ }
7583
+ function Ru(e) {
7565
7584
  return !!(e && typeof e == "object" && "byteLength" in e && "byteOffset" in e);
7566
7585
  }
7567
- const Fu = "https://github.com/remarkjs/react-markdown/blob/main/changelog.md", yr = [], kr = { allowDangerousHtml: !0 }, Ou = /^(https?|ircs?|mailto|xmpp)$/i, Bu = [
7586
+ const Fu = "https://github.com/remarkjs/react-markdown/blob/main/changelog.md", yr = [], kr = { allowDangerousHtml: !0 }, Ou = /^(https?|ircs?|mailto|xmpp)$/i, ju = [
7568
7587
  { from: "astPlugins", id: "remove-buggy-html-in-markdown-parser" },
7569
7588
  { from: "allowDangerousHtml", id: "remove-buggy-html-in-markdown-parser" },
7570
7589
  {
@@ -7598,7 +7617,7 @@ const Fu = "https://github.com/remarkjs/react-markdown/blob/main/changelog.md",
7598
7617
  { from: "transformImageUri", id: "#add-urltransform", to: "urlTransform" },
7599
7618
  { from: "transformLinkUri", id: "#add-urltransform", to: "urlTransform" }
7600
7619
  ];
7601
- function ju(e) {
7620
+ function Bu(e) {
7602
7621
  const n = $u(e), t = Hu(e);
7603
7622
  return Vu(n.runSync(n.parse(t), t), e);
7604
7623
  }
@@ -7612,7 +7631,7 @@ function Hu(e) {
7612
7631
  }
7613
7632
  function Vu(e, n) {
7614
7633
  const t = n.allowedElements, r = n.allowElement, i = n.components, o = n.disallowedElements, l = n.skipHtml, a = n.unwrapDisallowed, s = n.urlTransform || qu;
7615
- for (const f of Bu)
7634
+ for (const f of ju)
7616
7635
  Object.hasOwn(n, f.from) && ("" + f.from + (f.to ? "use `" + f.to + "` instead" : "remove it") + Fu + f.id, void 0);
7617
7636
  return vn(e, u), ro(e, {
7618
7637
  Fragment: un,
@@ -7628,9 +7647,9 @@ function Vu(e, n) {
7628
7647
  return l ? h.children.splice(c, 1) : h.children[c] = { type: "text", value: f.value }, c;
7629
7648
  if (f.type === "element") {
7630
7649
  let p;
7631
- for (p in Rt)
7632
- if (Object.hasOwn(Rt, p) && Object.hasOwn(f.properties, p)) {
7633
- const g = f.properties[p], C = Rt[p];
7650
+ for (p in Mt)
7651
+ if (Object.hasOwn(Mt, p) && Object.hasOwn(f.properties, p)) {
7652
+ const g = f.properties[p], C = Mt[p];
7634
7653
  (C === null || C.includes(f.tagName)) && (f.properties[p] = s(String(g || ""), p, f));
7635
7654
  }
7636
7655
  }
@@ -8113,10 +8132,10 @@ function Nc(e) {
8113
8132
  );
8114
8133
  return n;
8115
8134
  }
8116
- function Rc(e, n, t, r) {
8135
+ function Mc(e, n, t, r) {
8117
8136
  const i = Nc(t), o = e.value || "", l = i === "`" ? "GraveAccent" : "Tilde";
8118
8137
  if (Dc(e, t)) {
8119
- const c = t.enter("codeIndented"), h = t.indentLines(o, Mc);
8138
+ const c = t.enter("codeIndented"), h = t.indentLines(o, Rc);
8120
8139
  return c(), h;
8121
8140
  }
8122
8141
  const a = t.createTracker(r), s = i.repeat(Math.max(Lc(o, i) + 1, 3)), u = t.enter("codeFenced");
@@ -8148,7 +8167,7 @@ function Rc(e, n, t, r) {
8148
8167
  `), o && (f += a.move(o + `
8149
8168
  `)), f += a.move(s), u(), f;
8150
8169
  }
8151
- function Mc(e, n, t) {
8170
+ function Rc(e, n, t) {
8152
8171
  return (t ? "" : " ") + e;
8153
8172
  }
8154
8173
  function En(e) {
@@ -8233,7 +8252,7 @@ function It(e, n, t) {
8233
8252
  { inside: !1, outside: !1 }
8234
8253
  );
8235
8254
  }
8236
- Ci.peek = Bc;
8255
+ Ci.peek = jc;
8237
8256
  function Ci(e, n, t, r) {
8238
8257
  const i = Oc(t), o = t.enter("emphasis"), l = t.createTracker(r), a = l.move(i);
8239
8258
  let s = l.move(
@@ -8257,10 +8276,10 @@ function Ci(e, n, t, r) {
8257
8276
  before: f.outside
8258
8277
  }, a + s + p;
8259
8278
  }
8260
- function Bc(e, n, t) {
8279
+ function jc(e, n, t) {
8261
8280
  return t.options.emphasis || "*";
8262
8281
  }
8263
- function jc(e, n) {
8282
+ function Bc(e, n) {
8264
8283
  let t = !1;
8265
8284
  return vn(e, function(r) {
8266
8285
  if ("value" in r && /\r?\n|\r/.test(r.value) || r.type === "break")
@@ -8269,7 +8288,7 @@ function jc(e, n) {
8269
8288
  }
8270
8289
  function $c(e, n, t, r) {
8271
8290
  const i = Math.max(Math.min(6, e.depth || 1), 1), o = t.createTracker(r);
8272
- if (jc(e, t)) {
8291
+ if (Bc(e, t)) {
8273
8292
  const f = t.enter("headingSetext"), c = t.enter("phrasing"), h = t.containerPhrasing(e, {
8274
8293
  ...o.current(),
8275
8294
  before: `
@@ -8634,7 +8653,7 @@ function af(e, n, t) {
8634
8653
  const Li = {
8635
8654
  blockquote: Tc,
8636
8655
  break: Cr,
8637
- code: Rc,
8656
+ code: Mc,
8638
8657
  definition: Fc,
8639
8658
  emphasis: Ci,
8640
8659
  hardBreak: Cr,
@@ -8862,24 +8881,24 @@ const wf = {
8862
8881
  }, Ni = {
8863
8882
  tokenize: Tf,
8864
8883
  partial: !0
8865
- }, Ri = {
8884
+ }, Mi = {
8866
8885
  tokenize: zf,
8867
8886
  partial: !0
8868
8887
  }, Cf = {
8869
8888
  tokenize: Pf,
8870
8889
  partial: !0
8871
- }, Mi = {
8890
+ }, Ri = {
8872
8891
  name: "wwwAutolink",
8873
8892
  tokenize: _f,
8874
8893
  previous: Oi
8875
8894
  }, Fi = {
8876
8895
  name: "protocolAutolink",
8877
8896
  tokenize: Ef,
8878
- previous: Bi
8897
+ previous: ji
8879
8898
  }, Ee = {
8880
8899
  name: "emailAutolink",
8881
8900
  tokenize: vf,
8882
- previous: ji
8901
+ previous: Bi
8883
8902
  }, we = {};
8884
8903
  function Sf() {
8885
8904
  return {
@@ -8895,14 +8914,14 @@ we[46] = Ee;
8895
8914
  we[95] = Ee;
8896
8915
  we[72] = [Ee, Fi];
8897
8916
  we[104] = [Ee, Fi];
8898
- we[87] = [Ee, Mi];
8899
- we[119] = [Ee, Mi];
8917
+ we[87] = [Ee, Ri];
8918
+ we[119] = [Ee, Ri];
8900
8919
  function vf(e, n, t) {
8901
8920
  const r = this;
8902
8921
  let i, o;
8903
8922
  return l;
8904
8923
  function l(c) {
8905
- return !an(c) || !ji.call(r, r.previous) || An(r.events) ? t(c) : (e.enter("literalAutolink"), e.enter("literalAutolinkEmail"), a(c));
8924
+ return !an(c) || !Bi.call(r, r.previous) || An(r.events) ? t(c) : (e.enter("literalAutolink"), e.enter("literalAutolinkEmail"), a(c));
8906
8925
  }
8907
8926
  function a(c) {
8908
8927
  return an(c) ? (e.consume(c), a) : c === 64 ? (e.consume(c), s) : t(c);
@@ -8932,7 +8951,7 @@ function Ef(e, n, t) {
8932
8951
  let i = "", o = !1;
8933
8952
  return l;
8934
8953
  function l(c) {
8935
- return (c === 72 || c === 104) && Bi.call(r, r.previous) && !An(r.events) ? (e.enter("literalAutolink"), e.enter("literalAutolinkHttp"), i += String.fromCodePoint(c), e.consume(c), a) : t(c);
8954
+ return (c === 72 || c === 104) && ji.call(r, r.previous) && !An(r.events) ? (e.enter("literalAutolink"), e.enter("literalAutolinkHttp"), i += String.fromCodePoint(c), e.consume(c), a) : t(c);
8936
8955
  }
8937
8956
  function a(c) {
8938
8957
  if (ae(c) && i.length < 5)
@@ -8968,7 +8987,7 @@ function Af(e, n, t) {
8968
8987
  let r, i, o;
8969
8988
  return l;
8970
8989
  function l(u) {
8971
- return u === 46 || u === 95 ? e.check(Ri, s, a)(u) : u === null || J(u) || Oe(u) || u !== 45 && At(u) ? s(u) : (o = !0, e.consume(u), l);
8990
+ return u === 46 || u === 95 ? e.check(Mi, s, a)(u) : u === null || J(u) || Oe(u) || u !== 45 && At(u) ? s(u) : (o = !0, e.consume(u), l);
8972
8991
  }
8973
8992
  function a(u) {
8974
8993
  return u === 95 ? r = !0 : (i = r, r = void 0), e.consume(u), l;
@@ -8981,7 +9000,7 @@ function Tf(e, n) {
8981
9000
  let t = 0, r = 0;
8982
9001
  return i;
8983
9002
  function i(l) {
8984
- return l === 40 ? (t++, e.consume(l), i) : l === 41 && r < t ? o(l) : l === 33 || l === 34 || l === 38 || l === 39 || l === 41 || l === 42 || l === 44 || l === 46 || l === 58 || l === 59 || l === 60 || l === 63 || l === 93 || l === 95 || l === 126 ? e.check(Ri, n, o)(l) : l === null || J(l) || Oe(l) ? n(l) : (e.consume(l), i);
9003
+ return l === 40 ? (t++, e.consume(l), i) : l === 41 && r < t ? o(l) : l === 33 || l === 34 || l === 38 || l === 39 || l === 41 || l === 42 || l === 44 || l === 46 || l === 58 || l === 59 || l === 60 || l === 63 || l === 93 || l === 95 || l === 126 ? e.check(Mi, n, o)(l) : l === null || J(l) || Oe(l) ? n(l) : (e.consume(l), i);
8985
9004
  }
8986
9005
  function o(l) {
8987
9006
  return l === 41 && r++, e.consume(l), i;
@@ -9018,10 +9037,10 @@ function Pf(e, n, t) {
9018
9037
  function Oi(e) {
9019
9038
  return e === null || e === 40 || e === 42 || e === 95 || e === 91 || e === 93 || e === 126 || J(e);
9020
9039
  }
9021
- function Bi(e) {
9040
+ function ji(e) {
9022
9041
  return !ae(e);
9023
9042
  }
9024
- function ji(e) {
9043
+ function Bi(e) {
9025
9044
  return !(e === 47 || an(e));
9026
9045
  }
9027
9046
  function an(e) {
@@ -9043,7 +9062,7 @@ function An(e) {
9043
9062
  return e.length > 0 && !t && (e[e.length - 1][1]._gfmAutolinkLiteralWalkedInto = !0), t;
9044
9063
  }
9045
9064
  const Lf = {
9046
- tokenize: jf,
9065
+ tokenize: Bf,
9047
9066
  partial: !0
9048
9067
  };
9049
9068
  function Df() {
@@ -9055,19 +9074,19 @@ function Df() {
9055
9074
  continuation: {
9056
9075
  tokenize: Of
9057
9076
  },
9058
- exit: Bf
9077
+ exit: jf
9059
9078
  }
9060
9079
  },
9061
9080
  text: {
9062
9081
  91: {
9063
9082
  name: "gfmFootnoteCall",
9064
- tokenize: Mf
9083
+ tokenize: Rf
9065
9084
  },
9066
9085
  93: {
9067
9086
  name: "gfmPotentialFootnoteCall",
9068
9087
  add: "after",
9069
9088
  tokenize: Nf,
9070
- resolveTo: Rf
9089
+ resolveTo: Mf
9071
9090
  }
9072
9091
  }
9073
9092
  };
@@ -9097,7 +9116,7 @@ function Nf(e, n, t) {
9097
9116
  return u.codePointAt(0) !== 94 || !o.includes(u.slice(1)) ? t(s) : (e.enter("gfmFootnoteCallLabelMarker"), e.consume(s), e.exit("gfmFootnoteCallLabelMarker"), n(s));
9098
9117
  }
9099
9118
  }
9100
- function Rf(e, n) {
9119
+ function Mf(e, n) {
9101
9120
  let t = e.length;
9102
9121
  for (; t--; )
9103
9122
  if (e[t][1].type === "labelImage" && e[t][0] === "enter") {
@@ -9147,7 +9166,7 @@ function Rf(e, n) {
9147
9166
  ];
9148
9167
  return e.splice(t, e.length - t + 1, ...a), e;
9149
9168
  }
9150
- function Mf(e, n, t) {
9169
+ function Rf(e, n, t) {
9151
9170
  const r = this, i = r.parser.gfmFootnotes || (r.parser.gfmFootnotes = []);
9152
9171
  let o = 0, l;
9153
9172
  return a;
@@ -9216,10 +9235,10 @@ function Ff(e, n, t) {
9216
9235
  function Of(e, n, t) {
9217
9236
  return e.check(ft, n, e.attempt(Lf, n, t));
9218
9237
  }
9219
- function Bf(e) {
9238
+ function jf(e) {
9220
9239
  e.exit("gfmFootnoteDefinition");
9221
9240
  }
9222
- function jf(e, n, t) {
9241
+ function Bf(e, n, t) {
9223
9242
  const r = this;
9224
9243
  return q(e, i, "gfmFootnoteDefinitionIndent", 5);
9225
9244
  function i(o) {
@@ -9451,9 +9470,9 @@ function Wf(e, n, t) {
9451
9470
  return k === 124 ? (e.enter("tableCellDivider"), e.consume(k), e.exit("tableCellDivider"), O) : k === null || D(k) ? (e.exit("tableRow"), n(k)) : $(k) ? q(e, O, "whitespace")(k) : (e.enter("data"), H(k));
9452
9471
  }
9453
9472
  function H(k) {
9454
- return k === null || k === 124 || J(k) ? (e.exit("data"), O(k)) : (e.consume(k), k === 92 ? j : H);
9473
+ return k === null || k === 124 || J(k) ? (e.exit("data"), O(k)) : (e.consume(k), k === 92 ? B : H);
9455
9474
  }
9456
- function j(k) {
9475
+ function B(k) {
9457
9476
  return k === 92 || k === 124 ? (e.consume(k), H) : H(k);
9458
9477
  }
9459
9478
  }
@@ -9579,7 +9598,7 @@ const tp = "_wrapper_izvjy_1", np = "_table_izvjy_15", rp = "_th_izvjy_27", ip =
9579
9598
  td: lp
9580
9599
  };
9581
9600
  function op({ part: e }) {
9582
- return /* @__PURE__ */ b("div", { className: nt.wrapper, children: /* @__PURE__ */ Y("table", { className: nt.table, children: [
9601
+ return /* @__PURE__ */ b("div", { className: nt.wrapper, "data-juneau": "table-part", children: /* @__PURE__ */ Y("table", { className: nt.table, children: [
9583
9602
  /* @__PURE__ */ b("thead", { children: /* @__PURE__ */ b("tr", { children: e.columns.map((n) => /* @__PURE__ */ b("th", { className: nt.th, children: n }, n)) }) }),
9584
9603
  /* @__PURE__ */ b("tbody", { children: e.rows.map((n, t) => /* @__PURE__ */ b("tr", { className: nt.tr, children: e.columns.map((r) => /* @__PURE__ */ b("td", { className: nt.td, children: String(n[r] ?? "") }, r)) }, t)) })
9585
9604
  ] }) });
@@ -9598,31 +9617,38 @@ const ap = "_card_1gzm6_1", sp = "_header_1gzm6_17", up = "_icon_1gzm6_31", cp =
9598
9617
  };
9599
9618
  function yp({ part: e, onConfirm: n, onCancel: t }) {
9600
9619
  const r = Te(), { proposal: i } = e, o = i.resolved === "confirmed" ? r.proposalConfirmed : i.resolved === "cancelled" ? r.proposalCancelled : i.resolved === "expired" ? r.proposalExpired : null;
9601
- return /* @__PURE__ */ Y("div", { className: i.resolved ? `${ye.card} ${ye.cardResolved}` : ye.card, children: [
9602
- /* @__PURE__ */ Y("div", { className: ye.header, children: [
9603
- /* @__PURE__ */ b("svg", { className: ye.icon, viewBox: "0 0 20 20", fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ b("path", { d: "M10 1a.75.75 0 01.75.75v1.5a.75.75 0 01-1.5 0v-1.5A.75.75 0 0110 1zM5.05 3.05a.75.75 0 011.06 1.06l-1.06 1.06a.75.75 0 11-1.06-1.06l1.06-1.06zm9.9 0a.75.75 0 010 1.06l-1.06 1.06a.75.75 0 11-1.06-1.06l1.06-1.06a.75.75 0 011.06 0zM10 6a4 4 0 100 8 4 4 0 000-8zm-9 4a.75.75 0 01.75-.75h1.5a.75.75 0 010 1.5h-1.5A.75.75 0 011 10zm15.75-.75a.75.75 0 000 1.5h1.5a.75.75 0 000-1.5h-1.5zM4.11 14.89a.75.75 0 010 1.06l-1.06 1.06a.75.75 0 11-1.06-1.06l1.06-1.06a.75.75 0 011.06 0zm11.84 1.06a.75.75 0 10-1.06-1.06l-1.06 1.06a.75.75 0 101.06 1.06l1.06-1.06zM10 17.25a.75.75 0 01.75.75v1.5a.75.75 0 01-1.5 0v-1.5a.75.75 0 01.75-.75z" }) }),
9604
- /* @__PURE__ */ b("span", { className: ye.title, children: i.title })
9605
- ] }),
9606
- i.description && /* @__PURE__ */ b("p", { className: ye.description, children: i.description }),
9607
- o ? /* @__PURE__ */ b("span", { className: ye.resolvedBadge, children: o }) : /* @__PURE__ */ Y("div", { className: ye.actions, children: [
9608
- /* @__PURE__ */ b(
9609
- "button",
9610
- {
9611
- className: ye.confirm,
9612
- onClick: () => n(i.id, i.payload),
9613
- children: i.confirmLabel ?? r.proposalConfirm
9614
- }
9615
- ),
9616
- /* @__PURE__ */ b(
9617
- "button",
9618
- {
9619
- className: ye.cancel,
9620
- onClick: () => t(i.id),
9621
- children: i.cancelLabel ?? r.proposalCancel
9622
- }
9623
- )
9624
- ] })
9625
- ] });
9620
+ return /* @__PURE__ */ Y(
9621
+ "div",
9622
+ {
9623
+ className: i.resolved ? `${ye.card} ${ye.cardResolved}` : ye.card,
9624
+ "data-juneau": "proposal-card",
9625
+ children: [
9626
+ /* @__PURE__ */ Y("div", { className: ye.header, children: [
9627
+ /* @__PURE__ */ b("svg", { className: ye.icon, viewBox: "0 0 20 20", fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ b("path", { d: "M10 1a.75.75 0 01.75.75v1.5a.75.75 0 01-1.5 0v-1.5A.75.75 0 0110 1zM5.05 3.05a.75.75 0 011.06 1.06l-1.06 1.06a.75.75 0 11-1.06-1.06l1.06-1.06zm9.9 0a.75.75 0 010 1.06l-1.06 1.06a.75.75 0 11-1.06-1.06l1.06-1.06a.75.75 0 011.06 0zM10 6a4 4 0 100 8 4 4 0 000-8zm-9 4a.75.75 0 01.75-.75h1.5a.75.75 0 010 1.5h-1.5A.75.75 0 011 10zm15.75-.75a.75.75 0 000 1.5h1.5a.75.75 0 000-1.5h-1.5zM4.11 14.89a.75.75 0 010 1.06l-1.06 1.06a.75.75 0 11-1.06-1.06l1.06-1.06a.75.75 0 011.06 0zm11.84 1.06a.75.75 0 10-1.06-1.06l-1.06 1.06a.75.75 0 101.06 1.06l1.06-1.06zM10 17.25a.75.75 0 01.75.75v1.5a.75.75 0 01-1.5 0v-1.5a.75.75 0 01.75-.75z" }) }),
9628
+ /* @__PURE__ */ b("span", { className: ye.title, children: i.title })
9629
+ ] }),
9630
+ i.description && /* @__PURE__ */ b("p", { className: ye.description, children: i.description }),
9631
+ o ? /* @__PURE__ */ b("span", { className: ye.resolvedBadge, children: o }) : /* @__PURE__ */ Y("div", { className: ye.actions, children: [
9632
+ /* @__PURE__ */ b(
9633
+ "button",
9634
+ {
9635
+ className: ye.confirm,
9636
+ onClick: () => n(i.id, i.payload),
9637
+ children: i.confirmLabel ?? r.proposalConfirm
9638
+ }
9639
+ ),
9640
+ /* @__PURE__ */ b(
9641
+ "button",
9642
+ {
9643
+ className: ye.cancel,
9644
+ onClick: () => t(i.id),
9645
+ children: i.cancelLabel ?? r.proposalCancel
9646
+ }
9647
+ )
9648
+ ] })
9649
+ ]
9650
+ }
9651
+ );
9626
9652
  }
9627
9653
  const kp = "_activity_1661l_1", xp = "_indicator_1661l_25", bp = "_content_1661l_71", wp = "_title_1661l_79", Cp = "_description_1661l_89", rt = {
9628
9654
  activity: kp,
@@ -9632,7 +9658,7 @@ const kp = "_activity_1661l_1", xp = "_indicator_1661l_25", bp = "_content_1661l
9632
9658
  description: Cp
9633
9659
  };
9634
9660
  function Sp({ part: e }) {
9635
- return /* @__PURE__ */ Y("div", { className: rt.activity, "data-status": e.status, children: [
9661
+ return /* @__PURE__ */ Y("div", { className: rt.activity, "data-status": e.status, "data-juneau": "activity-part", children: [
9636
9662
  /* @__PURE__ */ b("span", { className: rt.indicator, "aria-hidden": "true" }),
9637
9663
  /* @__PURE__ */ Y("div", { className: rt.content, children: [
9638
9664
  /* @__PURE__ */ b("div", { className: rt.title, children: e.title }),
@@ -9640,7 +9666,7 @@ function Sp({ part: e }) {
9640
9666
  ] })
9641
9667
  ] });
9642
9668
  }
9643
- const vp = "_card_jwkcu_1", _p = "_cardClickable_jwkcu_14", Ep = "_header_jwkcu_24", Ip = "_title_jwkcu_30", Ap = "_subtitle_jwkcu_36", Tp = "_fields_jwkcu_41", zp = "_fieldRow_jwkcu_48", Pp = "_fieldLabel_jwkcu_55", Lp = "_fieldValue_jwkcu_61", Dp = "_badge_jwkcu_68", Np = "_badgeSuccess_jwkcu_76", Rp = "_badgeWarning_jwkcu_81", Mp = "_badgeDanger_jwkcu_86", Fp = "_badgeNeutral_jwkcu_91", oe = {
9669
+ const vp = "_card_jwkcu_1", _p = "_cardClickable_jwkcu_14", Ep = "_header_jwkcu_24", Ip = "_title_jwkcu_30", Ap = "_subtitle_jwkcu_36", Tp = "_fields_jwkcu_41", zp = "_fieldRow_jwkcu_48", Pp = "_fieldLabel_jwkcu_55", Lp = "_fieldValue_jwkcu_61", Dp = "_badge_jwkcu_68", Np = "_badgeSuccess_jwkcu_76", Mp = "_badgeWarning_jwkcu_81", Rp = "_badgeDanger_jwkcu_86", Fp = "_badgeNeutral_jwkcu_91", oe = {
9644
9670
  card: vp,
9645
9671
  cardClickable: _p,
9646
9672
  header: Ep,
@@ -9652,8 +9678,8 @@ const vp = "_card_jwkcu_1", _p = "_cardClickable_jwkcu_14", Ep = "_header_jwkcu_
9652
9678
  fieldValue: Lp,
9653
9679
  badge: Dp,
9654
9680
  badgeSuccess: Np,
9655
- badgeWarning: Rp,
9656
- badgeDanger: Mp,
9681
+ badgeWarning: Mp,
9682
+ badgeDanger: Rp,
9657
9683
  badgeNeutral: Fp
9658
9684
  }, Op = {
9659
9685
  success: oe.badgeSuccess,
@@ -9678,16 +9704,17 @@ function $i({ part: e, onEntityClick: n }) {
9678
9704
  type: "button",
9679
9705
  className: `${oe.card} ${oe.cardClickable}`,
9680
9706
  onClick: () => n(t, r),
9707
+ "data-juneau": "entity-card",
9681
9708
  children: o
9682
9709
  }
9683
- ) : /* @__PURE__ */ b("div", { className: oe.card, children: o });
9710
+ ) : /* @__PURE__ */ b("div", { className: oe.card, "data-juneau": "entity-card", children: o });
9684
9711
  }
9685
- const Bp = "_list_a2maw_1", jp = "_listTitle_a2maw_11", Er = {
9686
- list: Bp,
9687
- listTitle: jp
9712
+ const jp = "_list_a2maw_1", Bp = "_listTitle_a2maw_11", Er = {
9713
+ list: jp,
9714
+ listTitle: Bp
9688
9715
  };
9689
9716
  function $p({ part: e, onEntityClick: n }) {
9690
- return /* @__PURE__ */ Y("div", { className: Er.list, children: [
9717
+ return /* @__PURE__ */ Y("div", { className: Er.list, "data-juneau": "entity-list-part", children: [
9691
9718
  e.title && /* @__PURE__ */ b("span", { className: Er.listTitle, children: e.title }),
9692
9719
  e.entities.map((t, r) => /* @__PURE__ */ b(
9693
9720
  $i,
@@ -9713,7 +9740,7 @@ function Wp({ part: e, onProposalConfirm: n, onProposalCancel: t, onEntityClick:
9713
9740
  }
9714
9741
  switch (e.type) {
9715
9742
  case "text":
9716
- return /* @__PURE__ */ b("div", { className: xt.markdown, children: /* @__PURE__ */ b(ju, { remarkPlugins: [ep], children: e.text }) });
9743
+ return /* @__PURE__ */ b("div", { className: xt.markdown, children: /* @__PURE__ */ b(Bu, { remarkPlugins: [ep], children: e.text }) });
9717
9744
  case "table":
9718
9745
  return /* @__PURE__ */ b(op, { part: e });
9719
9746
  case "activity":
@@ -9783,22 +9810,30 @@ function rh({ message: e, onProposalConfirm: n, onProposalCancel: t, onEntityCli
9783
9810
  },
9784
9811
  c
9785
9812
  ), u = e.parts.some(Hi);
9786
- return /* @__PURE__ */ Y("div", { className: `${xe.wrapper} ${a ? xe.user : xe.assistant}`, children: [
9787
- !a && /* @__PURE__ */ b("div", { className: xe.avatar, "aria-hidden": "true", children: i ?? /* @__PURE__ */ b(Nr, {}) }),
9788
- u ? /* @__PURE__ */ b("div", { className: xe.content, children: nh(e.parts).map((f, c) => /* @__PURE__ */ b(
9789
- "div",
9790
- {
9791
- className: f.card ? xe.card : xe.bubble,
9792
- "data-juneau-segment": f.card ? "card" : "bubble",
9793
- children: f.parts.map(({ part: h, index: p }) => s(h, p))
9794
- },
9795
- c
9796
- )) }) : /* @__PURE__ */ Y("div", { className: xe.bubble, "data-juneau-segment": "bubble", children: [
9797
- e.parts.map((f, c) => s(f, c)),
9798
- e.parts.length === 0 && /* @__PURE__ */ b("span", { className: xe.empty })
9799
- ] }),
9800
- a && /* @__PURE__ */ b("div", { className: xe.avatar, children: l.userLabel })
9801
- ] });
9813
+ return /* @__PURE__ */ Y(
9814
+ "div",
9815
+ {
9816
+ className: `${xe.wrapper} ${a ? xe.user : xe.assistant}`,
9817
+ "data-juneau": "message",
9818
+ "data-juneau-role": e.role,
9819
+ children: [
9820
+ !a && /* @__PURE__ */ b("div", { className: xe.avatar, "aria-hidden": "true", children: i ?? /* @__PURE__ */ b(Nr, {}) }),
9821
+ u ? /* @__PURE__ */ b("div", { className: xe.content, children: nh(e.parts).map((f, c) => /* @__PURE__ */ b(
9822
+ "div",
9823
+ {
9824
+ className: f.card ? xe.card : xe.bubble,
9825
+ "data-juneau-segment": f.card ? "card" : "bubble",
9826
+ children: f.parts.map(({ part: h, index: p }) => s(h, p))
9827
+ },
9828
+ c
9829
+ )) }) : /* @__PURE__ */ Y("div", { className: xe.bubble, "data-juneau-segment": "bubble", children: [
9830
+ e.parts.map((f, c) => s(f, c)),
9831
+ e.parts.length === 0 && /* @__PURE__ */ b("span", { className: xe.empty })
9832
+ ] }),
9833
+ a && /* @__PURE__ */ b("div", { className: xe.avatar, children: l.userLabel })
9834
+ ]
9835
+ }
9836
+ );
9802
9837
  }
9803
9838
  const ih = "_wrapper_1oco7_1", lh = "_dot_1oco7_15", oh = "_connectingLabel_1oco7_37", it = {
9804
9839
  wrapper: ih,
@@ -9812,6 +9847,7 @@ function ah({ connecting: e = !1 }) {
9812
9847
  {
9813
9848
  className: it.wrapper,
9814
9849
  "aria-label": e ? n.connectingMessage : n.typingMessage,
9850
+ "data-juneau": "typing-indicator",
9815
9851
  children: [
9816
9852
  /* @__PURE__ */ b("span", { className: it.dot }),
9817
9853
  /* @__PURE__ */ b("span", { className: it.dot }),
@@ -9831,8 +9867,8 @@ function ph({ messages: e, isLoading: n, isConnecting: t, onProposalConfirm: r,
9831
9867
  const u = Te(), f = Ue(null);
9832
9868
  return St(() => {
9833
9869
  f.current?.scrollIntoView({ behavior: "smooth" });
9834
- }, [e, n]), /* @__PURE__ */ Y("div", { className: bt.list, children: [
9835
- e.length === 0 && (s ?? /* @__PURE__ */ Y("div", { className: bt.empty, children: [
9870
+ }, [e, n]), /* @__PURE__ */ Y("div", { className: bt.list, "data-juneau": "message-list", children: [
9871
+ e.length === 0 && (s ?? /* @__PURE__ */ Y("div", { className: bt.empty, "data-juneau": "empty-state", children: [
9836
9872
  /* @__PURE__ */ b("p", { children: u.emptyStateText }),
9837
9873
  /* @__PURE__ */ b("p", { className: bt.hint, children: /* @__PURE__ */ b("em", { children: u.emptyStateHint }) })
9838
9874
  ] })),
@@ -9877,12 +9913,13 @@ function Ch({ value: e, onChange: n, onSend: t, onStop: r, isLoading: i, placeho
9877
9913
  ], h = l ?? c, p = (g) => {
9878
9914
  g.key === "Enter" && !g.shiftKey && (g.preventDefault(), i || t());
9879
9915
  };
9880
- return /* @__PURE__ */ Y("div", { className: ve.wrapper, children: [
9916
+ return /* @__PURE__ */ Y("div", { className: ve.wrapper, "data-juneau": "input", children: [
9881
9917
  /* @__PURE__ */ b(
9882
9918
  "textarea",
9883
9919
  {
9884
9920
  ref: u,
9885
9921
  className: ve.textarea,
9922
+ "data-juneau": "input-textarea",
9886
9923
  value: e,
9887
9924
  onChange: (g) => n(g.target.value),
9888
9925
  onKeyDown: p,
@@ -9944,7 +9981,7 @@ const Sh = "_wrapper_1e3w5_1", vh = "_icon_1e3w5_27", _h = "_message_1e3w5_39",
9944
9981
  };
9945
9982
  function Ih({ message: e, onDismiss: n }) {
9946
9983
  const t = Te();
9947
- return /* @__PURE__ */ Y("div", { className: wt.wrapper, role: "alert", children: [
9984
+ return /* @__PURE__ */ Y("div", { className: wt.wrapper, role: "alert", "data-juneau": "error", children: [
9948
9985
  /* @__PURE__ */ b("svg", { className: wt.icon, viewBox: "0 0 20 20", fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ b("path", { fillRule: "evenodd", d: "M8.485 2.495c.673-1.167 2.357-1.167 3.03 0l6.28 10.875c.673 1.167-.17 2.625-1.516 2.625H3.72c-1.347 0-2.189-1.458-1.515-2.625L8.485 2.495zM10 5a.75.75 0 01.75.75v3.5a.75.75 0 01-1.5 0v-3.5A.75.75 0 0110 5zm0 9a1 1 0 100-2 1 1 0 000 2z", clipRule: "evenodd" }) }),
9949
9986
  /* @__PURE__ */ b("span", { className: wt.message, children: e }),
9950
9987
  n && /* @__PURE__ */ b("button", { className: wt.dismiss, onClick: n, "aria-label": t.errorDismiss, children: /* @__PURE__ */ b("svg", { viewBox: "0 0 16 16", fill: "currentColor", "aria-hidden": "true", children: /* @__PURE__ */ b("path", { d: "M3.72 3.72a.75.75 0 011.06 0L8 6.94l3.22-3.22a.75.75 0 111.06 1.06L9.06 8l3.22 3.22a.75.75 0 11-1.06 1.06L8 9.06l-3.22 3.22a.75.75 0 01-1.06-1.06L6.94 8 3.72 4.78a.75.75 0 010-1.06z" }) }) })
@@ -9979,6 +10016,7 @@ function zh({
9979
10016
  {
9980
10017
  className: [Th.chat, y].filter(Boolean).join(" "),
9981
10018
  style: I,
10019
+ "data-juneau": "chat",
9982
10020
  children: [
9983
10021
  /* @__PURE__ */ b(
9984
10022
  ph,
@@ -10012,13 +10050,13 @@ function zh({
10012
10050
  }
10013
10051
  );
10014
10052
  }
10015
- const Ph = "_header_1saak_1", Lh = "_left_1saak_23", Dh = "_icon_1saak_35", Nh = "_title_1saak_45", Rh = "_resetBtn_1saak_57", Mh = "_actions_1saak_99", Ne = {
10053
+ const Ph = "_header_1saak_1", Lh = "_left_1saak_23", Dh = "_icon_1saak_35", Nh = "_title_1saak_45", Mh = "_resetBtn_1saak_57", Rh = "_actions_1saak_99", Ne = {
10016
10054
  header: Ph,
10017
10055
  left: Lh,
10018
10056
  icon: Dh,
10019
10057
  title: Nh,
10020
- resetBtn: Rh,
10021
- actions: Mh
10058
+ resetBtn: Mh,
10059
+ actions: Rh
10022
10060
  };
10023
10061
  function Fh({
10024
10062
  title: e,
@@ -10029,7 +10067,7 @@ function Fh({
10029
10067
  headerActions: o
10030
10068
  }) {
10031
10069
  const l = Te();
10032
- return /* @__PURE__ */ Y("div", { className: Ne.header, children: [
10070
+ return /* @__PURE__ */ Y("div", { className: Ne.header, "data-juneau": "header", children: [
10033
10071
  /* @__PURE__ */ Y("div", { className: Ne.left, children: [
10034
10072
  /* @__PURE__ */ b("span", { className: Ne.icon, "aria-hidden": "true", children: r ?? /* @__PURE__ */ b(Nr, {}) }),
10035
10073
  /* @__PURE__ */ b("span", { className: Ne.title, children: e ?? l.sidebarTitle })
@@ -10059,9 +10097,9 @@ function Fh({
10059
10097
  ] })
10060
10098
  ] });
10061
10099
  }
10062
- const Oh = "_sidebar_u9ybt_1", Bh = "_minimized_u9ybt_39", Ir = {
10100
+ const Oh = "_sidebar_u9ybt_1", jh = "_minimized_u9ybt_39", Ir = {
10063
10101
  sidebar: Oh,
10064
- minimized: Bh
10102
+ minimized: jh
10065
10103
  };
10066
10104
  function ld({
10067
10105
  title: e,
@@ -10074,66 +10112,69 @@ function ld({
10074
10112
  onReset: a,
10075
10113
  renderPart: s,
10076
10114
  onEntityClick: u,
10077
- headerActions: f
10115
+ headerActions: f,
10116
+ emptyState: c
10078
10117
  }) {
10079
- const [c, h] = Me(!1), {
10080
- messages: p,
10081
- input: g,
10082
- setInput: C,
10083
- sendMessage: S,
10084
- stop: y,
10085
- isLoading: I,
10086
- isConnecting: _,
10087
- error: L,
10088
- reset: N,
10089
- confirmProposal: x,
10090
- cancelProposal: O
10091
- } = xl(), H = a ? () => {
10092
- N(), a();
10118
+ const [h, p] = Re(!1), {
10119
+ messages: g,
10120
+ input: C,
10121
+ setInput: S,
10122
+ sendMessage: y,
10123
+ stop: I,
10124
+ isLoading: _,
10125
+ isConnecting: L,
10126
+ error: N,
10127
+ reset: x,
10128
+ confirmProposal: O,
10129
+ cancelProposal: H
10130
+ } = xl(), B = a ? () => {
10131
+ x(), a();
10093
10132
  } : void 0;
10094
10133
  return /* @__PURE__ */ Y(
10095
10134
  "aside",
10096
10135
  {
10097
- className: [Ir.sidebar, c ? Ir.minimized : "", o].filter(Boolean).join(" "),
10098
- style: { height: c ? void 0 : i, ...l },
10136
+ className: [Ir.sidebar, h ? Ir.minimized : "", o].filter(Boolean).join(" "),
10137
+ style: { height: h ? void 0 : i, ...l },
10138
+ "data-juneau": "sidebar",
10099
10139
  children: [
10100
10140
  /* @__PURE__ */ b(
10101
10141
  Fh,
10102
10142
  {
10103
10143
  title: e,
10104
10144
  icon: n,
10105
- onMinimize: () => h((j) => !j),
10106
- isMinimized: c,
10107
- onReset: H,
10145
+ onMinimize: () => p((k) => !k),
10146
+ isMinimized: h,
10147
+ onReset: B,
10108
10148
  headerActions: f
10109
10149
  }
10110
10150
  ),
10111
- !c && /* @__PURE__ */ b(
10151
+ !h && /* @__PURE__ */ b(
10112
10152
  zh,
10113
10153
  {
10114
- messages: p,
10115
- input: g,
10116
- isLoading: I,
10117
- isConnecting: _,
10118
- error: L,
10119
- onInputChange: C,
10120
- onSend: S,
10121
- onStop: y,
10122
- onProposalConfirm: x,
10123
- onProposalCancel: O,
10154
+ messages: g,
10155
+ input: C,
10156
+ isLoading: _,
10157
+ isConnecting: L,
10158
+ error: N,
10159
+ onInputChange: S,
10160
+ onSend: y,
10161
+ onStop: I,
10162
+ onProposalConfirm: O,
10163
+ onProposalCancel: H,
10124
10164
  assistantIcon: n,
10125
10165
  actions: t,
10126
10166
  sendIcon: r,
10127
10167
  renderPart: s,
10128
- onEntityClick: u
10168
+ onEntityClick: u,
10169
+ emptyState: c
10129
10170
  }
10130
10171
  )
10131
10172
  ]
10132
10173
  }
10133
10174
  );
10134
10175
  }
10135
- const jh = "_list_j7fvh_1", $h = "_item_j7fvh_19", Hh = "_chat_j7fvh_31", Vh = "_chatActive_j7fvh_71", qh = "_title_j7fvh_79", Uh = "_date_j7fvh_99", Wh = "_empty_j7fvh_163", _e = {
10136
- list: jh,
10176
+ const Bh = "_list_j7fvh_1", $h = "_item_j7fvh_19", Hh = "_chat_j7fvh_31", Vh = "_chatActive_j7fvh_71", qh = "_title_j7fvh_79", Uh = "_date_j7fvh_99", Wh = "_empty_j7fvh_163", _e = {
10177
+ list: Bh,
10137
10178
  item: $h,
10138
10179
  chat: Hh,
10139
10180
  chatActive: Vh,
@@ -10144,7 +10185,7 @@ const jh = "_list_j7fvh_1", $h = "_item_j7fvh_19", Hh = "_chat_j7fvh_31", Vh = "
10144
10185
  };
10145
10186
  function od({ chats: e, onSelect: n, activeChatId: t, onDelete: r }) {
10146
10187
  const i = Te();
10147
- return e.length === 0 ? /* @__PURE__ */ b("p", { className: _e.empty, children: i.historyEmpty }) : /* @__PURE__ */ b("ul", { className: _e.list, children: e.map((o) => /* @__PURE__ */ Y("li", { className: _e.item, children: [
10188
+ return e.length === 0 ? /* @__PURE__ */ b("p", { className: _e.empty, children: i.historyEmpty }) : /* @__PURE__ */ b("ul", { className: _e.list, "data-juneau": "history-list", children: e.map((o) => /* @__PURE__ */ Y("li", { className: _e.item, children: [
10148
10189
  /* @__PURE__ */ Y(
10149
10190
  "button",
10150
10191
  {