@_solaris/messenger-widget 0.6.12 → 0.6.13

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/messenger.js CHANGED
@@ -1,4 +1,4 @@
1
- import { reactive as We, openBlock as c, createElementBlock as d, normalizeStyle as N, normalizeClass as x, toDisplayString as v, resolveComponent as P, createVNode as K, Transition as Ae, withCtx as Se, Fragment as I, renderList as F, withKeys as _e, withModifiers as G, createElementVNode as l, createCommentVNode as b, createBlock as B, resolveDynamicComponent as Te, mergeProps as je, withDirectives as $, vModelText as ee, createTextVNode as Me, renderSlot as $e, vModelCheckbox as Ge, vModelSelect as Ye, markRaw as Ee } from "vue";
1
+ import { reactive as We, openBlock as c, createElementBlock as d, normalizeStyle as N, normalizeClass as x, toDisplayString as y, resolveComponent as P, createVNode as K, Transition as Ae, withCtx as Se, Fragment as I, renderList as F, withKeys as _e, withModifiers as G, createElementVNode as l, createCommentVNode as b, createBlock as B, resolveDynamicComponent as Te, mergeProps as je, withDirectives as $, vModelText as ee, createTextVNode as Me, renderSlot as $e, vModelCheckbox as Ge, vModelSelect as Ye, markRaw as Ee } from "vue";
2
2
  const Je = [
3
3
  "connected",
4
4
  "message",
@@ -150,7 +150,7 @@ function tt(e) {
150
150
  console.error("[transport] initial /conversations failed", u);
151
151
  }
152
152
  }
153
- async function y() {
153
+ async function v() {
154
154
  const u = await a("GET", "/customers/me");
155
155
  return (u == null ? void 0 : u.customer) ?? null;
156
156
  }
@@ -275,7 +275,7 @@ function tt(e) {
275
275
  t.panelOpen || Z();
276
276
  }, Ze));
277
277
  }
278
- function ye(u) {
278
+ function ve(u) {
279
279
  const g = t.panelOpen;
280
280
  t.panelOpen = !!u, t.panelOpen ? (clearTimeout(t.burstTimer), Q()) : te(), g !== t.panelOpen && h();
281
281
  }
@@ -334,11 +334,11 @@ function tt(e) {
334
334
  on: s,
335
335
  start: f,
336
336
  stop: w,
337
- setPanelOpen: ye,
337
+ setPanelOpen: ve,
338
338
  update: A,
339
339
  context: C,
340
340
  // REST
341
- getCustomer: y,
341
+ getCustomer: v,
342
342
  patchCustomer: T,
343
343
  listConversations: E,
344
344
  createConversation: S,
@@ -478,7 +478,7 @@ function it(e) {
478
478
  e.stop();
479
479
  }
480
480
  async function n(h) {
481
- const m = ye(h);
481
+ const m = ve(h);
482
482
  if (!m) return t.customer;
483
483
  try {
484
484
  const _ = await e.patchCustomer(m);
@@ -496,7 +496,7 @@ function it(e) {
496
496
  async function f(h) {
497
497
  const m = t.paginationByConv[h];
498
498
  if (!(m != null && m.loaded || m != null && m.loading)) {
499
- y(h, { nextCursor: null, loading: !0, loaded: !1 });
499
+ v(h, { nextCursor: null, loading: !0, loaded: !1 });
500
500
  try {
501
501
  const _ = await e.listMessages(h, {
502
502
  limit: o
@@ -506,13 +506,13 @@ function it(e) {
506
506
  const u = A.filter((g) => !((g == null ? void 0 : g.id) != null && C.has(`id:${String(g.id)}`) || g != null && g.client_msg_id && C.has(`c:${g.client_msg_id}`)));
507
507
  t.messagesByConv[h] = [...w, ...u].sort(
508
508
  te
509
- ), y(h, {
509
+ ), v(h, {
510
510
  nextCursor: (_ == null ? void 0 : _.next_cursor) ?? null,
511
511
  loading: !1,
512
512
  loaded: !0
513
513
  });
514
514
  } catch (_) {
515
- console.error("[store] openConversation failed", _), y(h, {
515
+ console.error("[store] openConversation failed", _), v(h, {
516
516
  nextCursor: null,
517
517
  loading: !1,
518
518
  loaded: !1
@@ -526,7 +526,7 @@ function it(e) {
526
526
  if (!m || m.loading || !m.nextCursor) return;
527
527
  const w = (A = (t.messagesByConv[h] || []).find((C) => C == null ? void 0 : C.created_at)) == null ? void 0 : A.created_at;
528
528
  if (w) {
529
- y(h, { ...m, loading: !0 });
529
+ v(h, { ...m, loading: !0 });
530
530
  try {
531
531
  const C = await e.listMessages(h, {
532
532
  before: w,
@@ -535,17 +535,17 @@ function it(e) {
535
535
  for (const R of g)
536
536
  (R == null ? void 0 : R.id) != null && p.add(`id:${String(R.id)}`), R != null && R.client_msg_id && p.add(`c:${R.client_msg_id}`);
537
537
  const L = u.filter((R) => !((R == null ? void 0 : R.id) != null && p.has(`id:${String(R.id)}`) || R != null && R.client_msg_id && p.has(`c:${R.client_msg_id}`)));
538
- t.messagesByConv[h] = [...L, ...g], y(h, {
538
+ t.messagesByConv[h] = [...L, ...g], v(h, {
539
539
  nextCursor: (C == null ? void 0 : C.next_cursor) ?? null,
540
540
  loading: !1,
541
541
  loaded: !0
542
542
  });
543
543
  } catch (C) {
544
- console.error("[store] loadMore failed", C), y(h, { ...m, loading: !1 });
544
+ console.error("[store] loadMore failed", C), v(h, { ...m, loading: !1 });
545
545
  }
546
546
  }
547
547
  }
548
- function y(h, m) {
548
+ function v(h, m) {
549
549
  t.paginationByConv = { ...t.paginationByConv, [h]: m };
550
550
  }
551
551
  async function T(h, m) {
@@ -751,7 +751,7 @@ function it(e) {
751
751
  function te(h, m) {
752
752
  return (h.created_at || "").localeCompare(m.created_at || "");
753
753
  }
754
- function ye(h) {
754
+ function ve(h) {
755
755
  if (!h || typeof h != "object") return null;
756
756
  const m = {}, _ = {};
757
757
  for (const [w, A] of Object.entries(h))
@@ -1263,22 +1263,22 @@ function _t(e) {
1263
1263
  if (!T) break;
1264
1264
  k.push(T[1]), r++;
1265
1265
  }
1266
- const y = k.map((T) => `<li>${de(T)}</li>`).join("");
1266
+ const v = k.map((T) => `<li>${de(T)}</li>`).join("");
1267
1267
  s.push({
1268
1268
  type: "block",
1269
- html: `<ul class="wm-md-ul">${y}</ul>`
1269
+ html: `<ul class="wm-md-ul">${v}</ul>`
1270
1270
  });
1271
1271
  continue;
1272
1272
  }
1273
1273
  const o = /^\s*(\d+)\.\s+(.*)$/.exec(n);
1274
1274
  if (o) {
1275
- const k = parseInt(o[1], 10), y = [o[2]];
1275
+ const k = parseInt(o[1], 10), v = [o[2]];
1276
1276
  for (r++; r < t.length; ) {
1277
1277
  const S = /^\s*\d+\.\s+(.*)$/.exec(t[r]);
1278
1278
  if (!S) break;
1279
- y.push(S[1]), r++;
1279
+ v.push(S[1]), r++;
1280
1280
  }
1281
- const T = y.map((S) => `<li>${de(S)}</li>`).join(""), E = k !== 1 ? ` start="${k}"` : "";
1281
+ const T = v.map((S) => `<li>${de(S)}</li>`).join(""), E = k !== 1 ? ` start="${k}"` : "";
1282
1282
  s.push({
1283
1283
  type: "block",
1284
1284
  html: `<ol class="wm-md-ol"${E}>${T}</ol>`
@@ -1335,10 +1335,10 @@ function gt(e, t) {
1335
1335
  }
1336
1336
  return (e == null ? void 0 : e.last_message_preview) || (e == null ? void 0 : e.preview) || ((i = e == null ? void 0 : e.metadata) == null ? void 0 : i.last_preview) || "";
1337
1337
  }
1338
- function vt(e, t) {
1338
+ function yt(e, t) {
1339
1339
  return (e == null ? void 0 : e.name) || ((e == null ? void 0 : e.type) === "user" ? t("common.you") : (e == null ? void 0 : e.type) === "agent_human" ? t("common.agent") : (e == null ? void 0 : e.type) === "agent_ia" ? t("common.aiAssistant") : t("common.system"));
1340
1340
  }
1341
- function yt(e, t, s, r) {
1341
+ function vt(e, t, s, r) {
1342
1342
  const i = [
1343
1343
  `# ${e.name || s("common.conversation")}`,
1344
1344
  e.created_at ? s("export.createdOn", {
@@ -1350,7 +1350,7 @@ function yt(e, t, s, r) {
1350
1350
  if (!n) continue;
1351
1351
  const a = (n.text_md || "").trim();
1352
1352
  if (!a) continue;
1353
- const o = vt(n.author, s), f = n.created_at ? new Date(n.created_at).toLocaleString(r) : "";
1353
+ const o = yt(n.author, s), f = n.created_at ? new Date(n.created_at).toLocaleString(r) : "";
1354
1354
  i.push(`[${f}] ${o} :`), i.push(a), i.push("");
1355
1355
  }
1356
1356
  return i.join(`
@@ -1358,7 +1358,7 @@ function yt(e, t, s, r) {
1358
1358
  }
1359
1359
  function pt(e, t, s = H(), r) {
1360
1360
  if (!e) return;
1361
- const i = yt(e, t || [], s, re(r)), n = new Blob([i], { type: "text/plain;charset=utf-8" });
1361
+ const i = vt(e, t || [], s, re(r)), n = new Blob([i], { type: "text/plain;charset=utf-8" });
1362
1362
  try {
1363
1363
  const a = URL.createObjectURL(n), o = document.createElement("a");
1364
1364
  o.href = a, o.download = `${(e.name || "conversation").replace(/[^a-z0-9-_]+/gi, "_")}.txt`, document.body.appendChild(o), o.click(), document.body.removeChild(o), setTimeout(() => URL.revokeObjectURL(a), 1e3);
@@ -1691,10 +1691,10 @@ const wt = {
1691
1691
  this.nextRevealAt + s.pauseBetweenMs
1692
1692
  ) + n;
1693
1693
  this.nextRevealAt = o;
1694
- const f = Math.max(0, o - r), k = e.id, y = setTimeout(() => {
1695
- this.revealedAt = { ...this.revealedAt, [k]: Date.now() }, this.revealTimers = this.revealTimers.filter((T) => T !== y), typeof this.onMessageRevealed == "function" && this.onMessageRevealed(e, t);
1694
+ const f = Math.max(0, o - r), k = e.id, v = setTimeout(() => {
1695
+ this.revealedAt = { ...this.revealedAt, [k]: Date.now() }, this.revealTimers = this.revealTimers.filter((T) => T !== v), typeof this.onMessageRevealed == "function" && this.onMessageRevealed(e, t);
1696
1696
  }, f);
1697
- this.revealTimers.push(y);
1697
+ this.revealTimers.push(v);
1698
1698
  },
1699
1699
  // Walk the message list and queue / instantly-reveal every new
1700
1700
  // entry according to its origin. Used by the `currentConvMessages`
@@ -1855,12 +1855,12 @@ function Mt(e, t, s, r, i, n) {
1855
1855
  }, null, 8, Tt)) : (c(), d("span", {
1856
1856
  key: 1,
1857
1857
  style: N({ fontSize: s.size * 0.36 + "px" })
1858
- }, v(n.initials), 5))
1858
+ }, y(n.initials), 5))
1859
1859
  ], 6);
1860
1860
  }
1861
- const ve = /* @__PURE__ */ U(St, [["render", Mt], ["__scopeId", "data-v-14e10c0d"]]), xt = 3, Ot = {
1861
+ const ye = /* @__PURE__ */ U(St, [["render", Mt], ["__scopeId", "data-v-14e10c0d"]]), xt = 3, Ot = {
1862
1862
  name: "WmLauncher",
1863
- components: { HumanAvatar: ve },
1863
+ components: { HumanAvatar: ye },
1864
1864
  inject: {
1865
1865
  // Translator shared by the Messenger shell; French fallback when
1866
1866
  // the component is used standalone.
@@ -1948,20 +1948,20 @@ function zt(e, t, s, r, i, n) {
1948
1948
  key: 0,
1949
1949
  class: "wm-peek__avatarBadge",
1950
1950
  "aria-label": n.t("launcher.unreadMessages", { count: o.count })
1951
- }, v(o.count > 9 ? "9+" : o.count), 9, It)) : b("", !0)
1951
+ }, y(o.count > 9 ? "9+" : o.count), 9, It)) : b("", !0)
1952
1952
  ]),
1953
1953
  l("div", Bt, [
1954
1954
  l("div", Pt, [
1955
- l("span", Ut, v(o.senderName || n.t("common.agent")), 1),
1956
- l("span", Dt, v(n.t("launcher.repliedToYou")), 1)
1955
+ l("span", Ut, y(o.senderName || n.t("common.agent")), 1),
1956
+ l("span", Dt, y(n.t("launcher.repliedToYou")), 1)
1957
1957
  ]),
1958
- l("p", Ft, v(o.preview), 1)
1958
+ l("p", Ft, y(o.preview), 1)
1959
1959
  ]),
1960
1960
  l("button", {
1961
1961
  type: "button",
1962
1962
  class: "wm-peek__open",
1963
1963
  onClick: G((k) => e.$emit("open", o.convId), ["stop"])
1964
- }, v(n.t("common.open")), 9, Nt)
1964
+ }, y(n.t("common.open")), 9, Nt)
1965
1965
  ], 44, Rt))), 128))
1966
1966
  ], 2)) : b("", !0)
1967
1967
  ]),
@@ -1994,7 +1994,7 @@ function zt(e, t, s, r, i, n) {
1994
1994
  }) : n.t("launcher.unreadConversationsOne", {
1995
1995
  count: s.unreadCount
1996
1996
  })
1997
- }, v(s.unreadCount > 9 ? "9+" : s.unreadCount), 9, jt)) : b("", !0)
1997
+ }, y(s.unreadCount > 9 ? "9+" : s.unreadCount), 9, jt)) : b("", !0)
1998
1998
  ], 8, Ht)
1999
1999
  ], 32);
2000
2000
  }
@@ -2058,7 +2058,7 @@ function Gt(e, t, s, r, i, n) {
2058
2058
  }, null, 8, Wt)) : n.initials ? (c(), d("span", {
2059
2059
  key: 1,
2060
2060
  style: N({ fontSize: s.size * 0.36 + "px" })
2061
- }, v(n.initials), 5)) : (c(), d("svg", {
2061
+ }, y(n.initials), 5)) : (c(), d("svg", {
2062
2062
  key: 2,
2063
2063
  width: s.size * 0.5,
2064
2064
  height: s.size * 0.5,
@@ -2137,10 +2137,10 @@ function en(e, t, s, r, i, n) {
2137
2137
  key: 0,
2138
2138
  src: a.avatar_url,
2139
2139
  alt: a.name || ""
2140
- }, null, 8, Xt)) : (c(), d("span", Qt, v(n.initialsFor(a)), 1))
2140
+ }, null, 8, Xt)) : (c(), d("span", Qt, y(n.initialsFor(a)), 1))
2141
2141
  ], 4))), 128))
2142
2142
  ], 4),
2143
- s.responseLabel ? (c(), d("span", Zt, v(s.responseLabel), 1)) : b("", !0)
2143
+ s.responseLabel ? (c(), d("span", Zt, y(s.responseLabel), 1)) : b("", !0)
2144
2144
  ])) : b("", !0);
2145
2145
  }
2146
2146
  const tn = /* @__PURE__ */ U(Yt, [["render", en], ["__scopeId", "data-v-e49a9063"]]), nn = {
@@ -2195,7 +2195,7 @@ function fn(e, t, s, r, i, n) {
2195
2195
  s.showBack ? (c(), d("button", {
2196
2196
  key: 0,
2197
2197
  type: "button",
2198
- class: "wm-header__icon",
2198
+ class: "wm-header__icon wm-header__back",
2199
2199
  "aria-label": n.t("header.backToHome"),
2200
2200
  onClick: t[0] || (t[0] = (f) => e.$emit("back"))
2201
2201
  }, [...t[3] || (t[3] = [
@@ -2222,7 +2222,7 @@ function fn(e, t, s, r, i, n) {
2222
2222
  }, null, 8, ["name", "image-url"])
2223
2223
  ]),
2224
2224
  l("div", ln, [
2225
- l("div", cn, v(s.title), 1)
2225
+ l("div", cn, y(s.title), 1)
2226
2226
  ]),
2227
2227
  n.hasTeam ? (c(), B(o, {
2228
2228
  key: 0,
@@ -2288,7 +2288,7 @@ function fn(e, t, s, r, i, n) {
2288
2288
  ])
2289
2289
  ]);
2290
2290
  }
2291
- const _n = /* @__PURE__ */ U(nn, [["render", fn], ["__scopeId", "data-v-7af4c118"]]), Fe = {
2291
+ const _n = /* @__PURE__ */ U(nn, [["render", fn], ["__scopeId", "data-v-27232009"]]), Fe = {
2292
2292
  book: "M12 6.253v13m0-13C10.832 5.477 9.246 5 7.5 5S4.168 5.477 3 6.253v13C4.168 18.477 5.754 18 7.5 18s3.332.477 4.5 1.253m0-13C13.168 5.477 14.754 5 16.5 5c1.747 0 3.332.477 4.5 1.253v13C19.832 18.477 18.247 18 16.5 18c-1.746 0-3.332.477-4.5 1.253",
2293
2293
  changelog: "M9 5H7a2 2 0 00-2 2v12a2 2 0 002 2h10a2 2 0 002-2V7a2 2 0 00-2-2h-2M9 5a2 2 0 002 2h2a2 2 0 002-2M9 5a2 2 0 012-2h2a2 2 0 012 2",
2294
2294
  status: "M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z",
@@ -2296,7 +2296,7 @@ const _n = /* @__PURE__ */ U(nn, [["render", fn], ["__scopeId", "data-v-7af4c118
2296
2296
  link: "M10 13a5 5 0 0 0 7.54.54l3-3a5 5 0 0 0-7.07-7.07l-1.72 1.71M14 11a5 5 0 0 0-7.54-.54l-3 3a5 5 0 0 0 7.07 7.07l1.71-1.71"
2297
2297
  }, gn = {
2298
2298
  name: "WmOnboarding",
2299
- components: { AIAvatar: me, HumanAvatar: ve },
2299
+ components: { AIAvatar: me, HumanAvatar: ye },
2300
2300
  inject: {
2301
2301
  // Translator + resolved-language getter shared by the Messenger
2302
2302
  // shell. The language getter feeds `formatTs` (relative date
@@ -2375,6 +2375,12 @@ const _n = /* @__PURE__ */ U(nn, [["render", fn], ["__scopeId", "data-v-7af4c118
2375
2375
  submitStarter() {
2376
2376
  this.canStart && this.$emit("start", this.starterText.trim());
2377
2377
  },
2378
+ // Enter sends (mirrors the chat composer) ; Shift+Enter inserts a
2379
+ // newline. The element is a textarea so the placeholder/text sits at
2380
+ // the top of the pill, matching the composer.
2381
+ onStarterKeydown(e) {
2382
+ e.key === "Enter" && !e.shiftKey && (e.preventDefault(), this.submitStarter());
2383
+ },
2378
2384
  // Launch choreography, in two beats:
2379
2385
  // 1. 'fade' — hero, alerts and quick-link buttons fade out,
2380
2386
  // leaving a white panel with just the input pill.
@@ -2491,7 +2497,7 @@ const _n = /* @__PURE__ */ U(nn, [["render", fn], ["__scopeId", "data-v-7af4c118
2491
2497
  });
2492
2498
  }
2493
2499
  }
2494
- }, vn = ["aria-label"], yn = {
2500
+ }, yn = ["aria-label"], vn = {
2495
2501
  key: 1,
2496
2502
  class: "wm-onb__hero-deco",
2497
2503
  width: "180",
@@ -2577,8 +2583,8 @@ function Xn(e, t, s, r, i, n) {
2577
2583
  style: N(n.coverStyle),
2578
2584
  role: "img",
2579
2585
  "aria-label": n.heroTitle
2580
- }, null, 12, vn)) : b("", !0),
2581
- n.hasCover ? b("", !0) : (c(), d("svg", yn, [...t[3] || (t[3] = [
2586
+ }, null, 12, yn)) : b("", !0),
2587
+ n.hasCover ? b("", !0) : (c(), d("svg", vn, [...t[4] || (t[4] = [
2582
2588
  l("circle", {
2583
2589
  cx: "170",
2584
2590
  cy: "10",
@@ -2610,8 +2616,8 @@ function Xn(e, t, s, r, i, n) {
2610
2616
  "image-url": s.defaultIconUrl
2611
2617
  }, null, 8, ["image-url"]),
2612
2618
  l("div", pn, [
2613
- l("div", wn, v(n.heroTitle), 1),
2614
- l("div", bn, v(n.heroSub), 1)
2619
+ l("div", wn, y(n.heroTitle), 1),
2620
+ l("div", bn, y(n.heroSub), 1)
2615
2621
  ])
2616
2622
  ], 2),
2617
2623
  n.unreadThreads.length ? (c(), d("div", kn, [
@@ -2624,7 +2630,7 @@ function Xn(e, t, s, r, i, n) {
2624
2630
  l("span", {
2625
2631
  class: x(["wm-onb__alert-avatar", n.avatarWrapperClass(o)])
2626
2632
  }, [
2627
- n.isDefaultAvatar(o) ? (c(), d("span", An, [...t[4] || (t[4] = [
2633
+ n.isDefaultAvatar(o) ? (c(), d("span", An, [...t[5] || (t[5] = [
2628
2634
  l("svg", {
2629
2635
  width: "20",
2630
2636
  height: "20",
@@ -2648,17 +2654,17 @@ function Xn(e, t, s, r, i, n) {
2648
2654
  }, null, 8, Sn)
2649
2655
  ], 2),
2650
2656
  l("span", Tn, [
2651
- l("span", Mn, v(o.title), 1),
2657
+ l("span", Mn, y(o.title), 1),
2652
2658
  l("span", xn, [
2653
- n.senderLabel(o) ? (c(), d("span", On, v(n.senderLabel(o)) + " · ", 1)) : b("", !0),
2659
+ n.senderLabel(o) ? (c(), d("span", On, y(n.senderLabel(o)) + " · ", 1)) : b("", !0),
2654
2660
  l("span", {
2655
2661
  innerHTML: n.renderPreview(o.preview)
2656
2662
  }, null, 8, Rn)
2657
2663
  ])
2658
2664
  ]),
2659
2665
  l("span", Ln, [
2660
- n.formatTs(o._ts) ? (c(), d("span", En, v(n.formatTs(o._ts)), 1)) : b("", !0),
2661
- l("span", In, v(n.t("onboarding.resume")), 1)
2666
+ n.formatTs(o._ts) ? (c(), d("span", En, y(n.formatTs(o._ts)), 1)) : b("", !0),
2667
+ l("span", In, y(n.t("onboarding.resume")), 1)
2662
2668
  ])
2663
2669
  ], 8, Cn))), 128))
2664
2670
  ])) : b("", !0),
@@ -2669,18 +2675,19 @@ function Xn(e, t, s, r, i, n) {
2669
2675
  "is-active": !!i.starterText.trim(),
2670
2676
  "wm-onb__starter--toBottom": i.launchPhase === "slide"
2671
2677
  }]),
2672
- onSubmit: t[1] || (t[1] = G((...o) => n.submitStarter && n.submitStarter(...o), ["prevent"]))
2678
+ onSubmit: t[2] || (t[2] = G((...o) => n.submitStarter && n.submitStarter(...o), ["prevent"]))
2673
2679
  }, [
2674
- $(l("input", {
2680
+ $(l("textarea", {
2675
2681
  ref: "starterInput",
2676
2682
  "onUpdate:modelValue": t[0] || (t[0] = (o) => i.starterText = o),
2677
- type: "text",
2678
2683
  class: "wm-onb__starter-input",
2684
+ rows: "1",
2679
2685
  placeholder: n.t("onboarding.starterPlaceholder"),
2680
2686
  disabled: s.busy,
2681
2687
  "aria-label": n.t("onboarding.start"),
2682
- enterkeyhint: "send"
2683
- }, null, 8, Pn), [
2688
+ enterkeyhint: "send",
2689
+ onKeydown: t[1] || (t[1] = (...o) => n.onStarterKeydown && n.onStarterKeydown(...o))
2690
+ }, null, 40, Pn), [
2684
2691
  [ee, i.starterText]
2685
2692
  ]),
2686
2693
  l("button", {
@@ -2689,7 +2696,7 @@ function Xn(e, t, s, r, i, n) {
2689
2696
  disabled: s.busy || !n.canStart,
2690
2697
  "aria-label": n.t("composer.send")
2691
2698
  }, [
2692
- s.busy ? (c(), d("span", Fn)) : (c(), d("svg", Dn, [...t[5] || (t[5] = [
2699
+ s.busy ? (c(), d("span", Fn)) : (c(), d("svg", Dn, [...t[6] || (t[6] = [
2693
2700
  l("path", { d: "M22 2L11 13M22 2l-7 20-4-9-9-4 20-7z" }, null, -1)
2694
2701
  ])]))
2695
2702
  ], 10, Un)
@@ -2713,8 +2720,8 @@ function Xn(e, t, s, r, i, n) {
2713
2720
  }, null, 8, qn)
2714
2721
  ]))
2715
2722
  ]),
2716
- l("span", Vn, v(o.label), 1),
2717
- n.isExternalLink(o) ? (c(), d("svg", Kn, [...t[6] || (t[6] = [
2723
+ l("span", Vn, y(o.label), 1),
2724
+ n.isExternalLink(o) ? (c(), d("svg", Kn, [...t[7] || (t[7] = [
2718
2725
  l("path", { d: "M7 17L17 7M9 7h8v8" }, null, -1)
2719
2726
  ])])) : b("", !0)
2720
2727
  ], 8, Nn))), 128)),
@@ -2722,7 +2729,7 @@ function Xn(e, t, s, r, i, n) {
2722
2729
  key: 0,
2723
2730
  type: "button",
2724
2731
  class: "wm-onb__btn",
2725
- onClick: t[2] || (t[2] = (o) => e.$emit("view-history"))
2732
+ onClick: t[3] || (t[3] = (o) => e.$emit("view-history"))
2726
2733
  }, [
2727
2734
  l("span", Wn, [
2728
2735
  (c(), d("svg", $n, [
@@ -2731,9 +2738,9 @@ function Xn(e, t, s, r, i, n) {
2731
2738
  }, null, 8, Gn)
2732
2739
  ]))
2733
2740
  ]),
2734
- l("span", Yn, v(n.t("onboarding.allConversations")), 1),
2735
- l("span", Jn, v(s.openThreads.length), 1),
2736
- t[7] || (t[7] = l("svg", {
2741
+ l("span", Yn, y(n.t("onboarding.allConversations")), 1),
2742
+ l("span", Jn, y(s.openThreads.length), 1),
2743
+ t[8] || (t[8] = l("svg", {
2737
2744
  class: "wm-onb__btn-trail",
2738
2745
  width: "13",
2739
2746
  height: "13",
@@ -2751,9 +2758,9 @@ function Xn(e, t, s, r, i, n) {
2751
2758
  ])
2752
2759
  ], 2);
2753
2760
  }
2754
- const Qn = /* @__PURE__ */ U(gn, [["render", Xn], ["__scopeId", "data-v-aafac3f0"]]), Zn = {
2761
+ const Qn = /* @__PURE__ */ U(gn, [["render", Xn], ["__scopeId", "data-v-bd58b3f3"]]), Zn = {
2755
2762
  name: "WmHistory",
2756
- components: { AIAvatar: me, HumanAvatar: ve },
2763
+ components: { AIAvatar: me, HumanAvatar: ye },
2757
2764
  inject: {
2758
2765
  t: { default: () => H() },
2759
2766
  wmLocale: { default: () => () => "fr" }
@@ -2892,14 +2899,14 @@ function ms(e, t, s, r, i, n) {
2892
2899
  }, null, 8, as)) : b("", !0)
2893
2900
  ], 2),
2894
2901
  l("span", os, [
2895
- l("span", ls, v(a.title), 1),
2902
+ l("span", ls, y(a.title), 1),
2896
2903
  l("span", {
2897
2904
  class: "wm-hist__thread-preview",
2898
2905
  innerHTML: n.renderPreview(a.preview)
2899
2906
  }, null, 8, cs)
2900
2907
  ]),
2901
2908
  l("span", ds, [
2902
- n.formatTs(a._ts) ? (c(), d("span", us, v(n.formatTs(a._ts)), 1)) : b("", !0),
2909
+ n.formatTs(a._ts) ? (c(), d("span", us, y(n.formatTs(a._ts)), 1)) : b("", !0),
2903
2910
  t[3] || (t[3] = l("svg", {
2904
2911
  width: "14",
2905
2912
  height: "14",
@@ -2916,7 +2923,7 @@ function ms(e, t, s, r, i, n) {
2916
2923
  ], -1))
2917
2924
  ])
2918
2925
  ], 10, rs))), 128)),
2919
- n.filteredThreads.length ? b("", !0) : (c(), d("div", hs, v(i.query ? n.t("onboarding.noResults", { query: i.query }) : n.t("onboarding.noConversations")), 1))
2926
+ n.filteredThreads.length ? b("", !0) : (c(), d("div", hs, y(i.query ? n.t("onboarding.noResults", { query: i.query }) : n.t("onboarding.noConversations")), 1))
2920
2927
  ])
2921
2928
  ]);
2922
2929
  }
@@ -2937,10 +2944,10 @@ const gs = {
2937
2944
  return _s(this.detail);
2938
2945
  }
2939
2946
  }
2940
- }, vs = {
2947
+ }, ys = {
2941
2948
  class: "wm-result__icon",
2942
2949
  "aria-hidden": "true"
2943
- }, ys = {
2950
+ }, vs = {
2944
2951
  key: 0,
2945
2952
  width: "11",
2946
2953
  height: "11",
@@ -2985,8 +2992,8 @@ function Ss(e, t, s, r, i, n) {
2985
2992
  return c(), d("div", {
2986
2993
  class: x(["wm-result", `wm-result--${s.state}`])
2987
2994
  }, [
2988
- l("span", vs, [
2989
- s.state === "success" ? (c(), d("svg", ys, [...t[0] || (t[0] = [
2995
+ l("span", ys, [
2996
+ s.state === "success" ? (c(), d("svg", vs, [...t[0] || (t[0] = [
2990
2997
  l("path", { d: "M20 6L9 17l-5-5" }, null, -1)
2991
2998
  ])])) : s.state === "rejected" ? (c(), d("svg", ps, [...t[1] || (t[1] = [
2992
2999
  l("path", { d: "M18 6L6 18M6 6l12 12" }, null, -1)
@@ -3014,13 +3021,13 @@ function Ss(e, t, s, r, i, n) {
3014
3021
  ])]))
3015
3022
  ]),
3016
3023
  l("span", ks, [
3017
- l("span", Cs, v(s.label), 1),
3024
+ l("span", Cs, y(s.label), 1),
3018
3025
  n.detailText ? (c(), d(I, { key: 0 }, [
3019
3026
  t[4] || (t[4] = l("span", {
3020
3027
  class: "wm-result__sep",
3021
3028
  "aria-hidden": "true"
3022
3029
  }, " · ", -1)),
3023
- l("span", As, v(n.detailText), 1)
3030
+ l("span", As, y(n.detailText), 1)
3024
3031
  ], 64)) : b("", !0)
3025
3032
  ])
3026
3033
  ], 2);
@@ -3045,7 +3052,7 @@ const Ts = /* @__PURE__ */ U(gs, [["render", Ss], ["__scopeId", "data-v-7284acd0
3045
3052
  function Bs(e, t, s, r, i, n) {
3046
3053
  return c(), d("div", xs, [
3047
3054
  l("div", Os, [
3048
- l("div", Rs, v(s.data.title || n.t("form.title")), 1),
3055
+ l("div", Rs, y(s.data.title || n.t("form.title")), 1),
3049
3056
  l("span", Ls, [
3050
3057
  t[0] || (t[0] = l("svg", {
3051
3058
  width: "11",
@@ -3060,7 +3067,7 @@ function Bs(e, t, s, r, i, n) {
3060
3067
  }, [
3061
3068
  l("polyline", { points: "20 6 9 17 4 12" })
3062
3069
  ], -1)),
3063
- Me(" " + v(n.t("form.sent")), 1)
3070
+ Me(" " + y(n.t("form.sent")), 1)
3064
3071
  ])
3065
3072
  ]),
3066
3073
  l("div", Es, [
@@ -3068,13 +3075,13 @@ function Bs(e, t, s, r, i, n) {
3068
3075
  key: o,
3069
3076
  class: "wm-art__field"
3070
3077
  }, [
3071
- l("div", Is, v(a.label), 1),
3078
+ l("div", Is, y(a.label), 1),
3072
3079
  l("div", {
3073
3080
  class: x([
3074
3081
  "wm-art__fieldValue",
3075
3082
  { "wm-art__fieldValue--multi": a.multiline }
3076
3083
  ])
3077
- }, v(a.value), 3)
3084
+ }, y(a.value), 3)
3078
3085
  ]))), 128))
3079
3086
  ])
3080
3087
  ]);
@@ -3118,8 +3125,8 @@ function $s(e, t, s, r, i, n) {
3118
3125
  ])) : b("", !0),
3119
3126
  l("div", Hs, [
3120
3127
  l("div", js, [
3121
- l("div", zs, v(s.data.title), 1),
3122
- s.data.subtitle ? (c(), d("div", qs, v(s.data.subtitle), 1)) : b("", !0)
3128
+ l("div", zs, y(s.data.title), 1),
3129
+ s.data.subtitle ? (c(), d("div", qs, y(s.data.subtitle), 1)) : b("", !0)
3123
3130
  ]),
3124
3131
  s.data.badge && s.data.badge.label ? (c(), d("span", {
3125
3132
  key: 0,
@@ -3127,21 +3134,21 @@ function $s(e, t, s, r, i, n) {
3127
3134
  "wm-art__badge",
3128
3135
  `wm-art__badge--${s.data.badge.tone || "neutral"}`
3129
3136
  ])
3130
- }, v(s.data.badge.label), 3)) : b("", !0)
3137
+ }, y(s.data.badge.label), 3)) : b("", !0)
3131
3138
  ]),
3132
3139
  n.hasBody ? (c(), d("div", Vs, [
3133
- s.data.body ? (c(), d("div", Ks, v(s.data.body), 1)) : b("", !0),
3140
+ s.data.body ? (c(), d("div", Ks, y(s.data.body), 1)) : b("", !0),
3134
3141
  n.fields.length ? (c(!0), d(I, { key: 1 }, F(n.fields, (a, o) => (c(), d("div", {
3135
3142
  key: o,
3136
3143
  class: "wm-art__field"
3137
3144
  }, [
3138
- l("div", Ws, v(a.label), 1),
3145
+ l("div", Ws, y(a.label), 1),
3139
3146
  l("div", {
3140
3147
  class: x([
3141
3148
  "wm-art__fieldValue",
3142
3149
  { "wm-art__fieldValue--multi": a.multiline }
3143
3150
  ])
3144
- }, v(a.value), 3)
3151
+ }, y(a.value), 3)
3145
3152
  ]))), 128)) : b("", !0)
3146
3153
  ])) : b("", !0)
3147
3154
  ]);
@@ -3232,7 +3239,7 @@ const Js = {
3232
3239
  function lr(e, t, s, r, i, n) {
3233
3240
  return c(), d("div", Xs, [
3234
3241
  l("div", Qs, [
3235
- l("div", Zs, v(s.data.title), 1),
3242
+ l("div", Zs, y(s.data.title), 1),
3236
3243
  l("div", er, [
3237
3244
  l("div", tr, [
3238
3245
  t[0] || (t[0] = l("svg", {
@@ -3249,7 +3256,7 @@ function lr(e, t, s, r, i, n) {
3249
3256
  l("path", { d: "M20 12a2 2 0 0 1 2-2V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v4a2 2 0 0 1 0 4v4a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-4a2 2 0 0 1-2-2z" }),
3250
3257
  l("path", { d: "M13 5v2M13 17v2M13 11v2" })
3251
3258
  ], -1)),
3252
- l("span", null, v(s.data.reference), 1)
3259
+ l("span", null, y(s.data.reference), 1)
3253
3260
  ]),
3254
3261
  l("span", {
3255
3262
  class: x([
@@ -3262,17 +3269,17 @@ function lr(e, t, s, r, i, n) {
3262
3269
  class: "wm-tk__dot",
3263
3270
  "aria-hidden": "true"
3264
3271
  }, null, -1)),
3265
- Me(" " + v(s.data.status.label), 1)
3272
+ Me(" " + y(s.data.status.label), 1)
3266
3273
  ], 2)
3267
3274
  ]),
3268
- s.data.body ? (c(), d("div", nr, v(s.data.body), 1)) : b("", !0)
3275
+ s.data.body ? (c(), d("div", nr, y(s.data.body), 1)) : b("", !0)
3269
3276
  ]),
3270
3277
  n.fields.length ? (c(), d("div", sr, [
3271
3278
  (c(!0), d(I, null, F(n.fields, (a, o) => (c(), d("div", {
3272
3279
  key: o,
3273
3280
  class: "wm-art__field"
3274
3281
  }, [
3275
- l("div", rr, v(a.label), 1),
3282
+ l("div", rr, y(a.label), 1),
3276
3283
  l("div", {
3277
3284
  class: x([
3278
3285
  "wm-art__fieldValue",
@@ -3319,7 +3326,7 @@ function lr(e, t, s, r, i, n) {
3319
3326
  }, null, -1),
3320
3327
  l("path", { d: "M16 2v4M8 2v4M3 10h18" }, null, -1)
3321
3328
  ])])) : b("", !0),
3322
- l("span", null, v(a.value), 1)
3329
+ l("span", null, y(a.value), 1)
3323
3330
  ], 2)
3324
3331
  ]))), 128))
3325
3332
  ])) : b("", !0),
@@ -3344,7 +3351,7 @@ function lr(e, t, s, r, i, n) {
3344
3351
  }),
3345
3352
  l("path", { d: "M16 2v4M8 2v4M3 10h18" })
3346
3353
  ], -1)),
3347
- l("span", null, v(n.formattedDate), 1)
3354
+ l("span", null, y(n.formattedDate), 1)
3348
3355
  ])) : b("", !0)
3349
3356
  ]);
3350
3357
  }
@@ -3441,7 +3448,7 @@ const mr = /* @__PURE__ */ U(ur, [["render", hr]]), fr = {
3441
3448
  this.safeHref === "#" && e.preventDefault();
3442
3449
  }
3443
3450
  }
3444
- }, _r = ["href"], gr = ["src", "alt"], vr = ["src"], yr = ["src"], pr = ["href", "download"], wr = { class: "wm-att__main" }, br = { class: "wm-att__name" }, kr = {
3451
+ }, _r = ["href"], gr = ["src", "alt"], yr = ["src"], vr = ["src"], pr = ["href", "download"], wr = { class: "wm-att__main" }, br = { class: "wm-att__name" }, kr = {
3445
3452
  key: 0,
3446
3453
  class: "wm-att__meta"
3447
3454
  }, Cr = {
@@ -3470,13 +3477,13 @@ function Ar(e, t, s, r, i, n) {
3470
3477
  src: i.url,
3471
3478
  controls: "",
3472
3479
  preload: "metadata"
3473
- }, null, 8, vr)) : n.kind === "video" && i.url ? (c(), d("video", {
3480
+ }, null, 8, yr)) : n.kind === "video" && i.url ? (c(), d("video", {
3474
3481
  key: 2,
3475
3482
  src: i.url,
3476
3483
  controls: "",
3477
3484
  playsinline: "",
3478
3485
  preload: "auto"
3479
- }, null, 8, yr)) : (c(), d("a", {
3486
+ }, null, 8, vr)) : (c(), d("a", {
3480
3487
  key: 3,
3481
3488
  class: "wm-att__file",
3482
3489
  href: n.safeHref,
@@ -3502,8 +3509,8 @@ function Ar(e, t, s, r, i, n) {
3502
3509
  ])
3503
3510
  ], -1)),
3504
3511
  l("span", wr, [
3505
- l("span", br, v(n.displayName), 1),
3506
- n.sizeLabel ? (c(), d("span", kr, v(n.sizeLabel), 1)) : b("", !0)
3512
+ l("span", br, y(n.displayName), 1),
3513
+ n.sizeLabel ? (c(), d("span", kr, y(n.sizeLabel), 1)) : b("", !0)
3507
3514
  ]),
3508
3515
  i.loading ? (c(), d("span", Cr)) : b("", !0)
3509
3516
  ], 8, pr))
@@ -3555,7 +3562,7 @@ const Br = {
3555
3562
  name: "WmMessageList",
3556
3563
  components: {
3557
3564
  AIAvatar: me,
3558
- HumanAvatar: ve,
3565
+ HumanAvatar: ye,
3559
3566
  Bubble: Or,
3560
3567
  Typing: Ir,
3561
3568
  ActionResult: Ts,
@@ -3670,7 +3677,7 @@ const Br = {
3670
3677
  if (o.role === "system") continue;
3671
3678
  const f = [];
3672
3679
  for (const k of o.messages)
3673
- for (const y of this.itemsOf(k)) f.push(y);
3680
+ for (const v of this.itemsOf(k)) f.push(v);
3674
3681
  o.items = f;
3675
3682
  }
3676
3683
  const t = [];
@@ -3956,9 +3963,9 @@ const Br = {
3956
3963
  // doit garder son arrondi.
3957
3964
  cornersFor(e, t) {
3958
3965
  var ie, ae, X;
3959
- const s = e.items, r = (ie = s[t]) == null ? void 0 : ie.kind, i = (ae = s[t - 1]) == null ? void 0 : ae.kind, n = (X = s[t + 1]) == null ? void 0 : X.kind, a = e.role === "user", o = 14, f = 4, k = i == null ? void 0 : i.bottom, y = n == null ? void 0 : n.top, T = this.widthByKey[this.rowKeyOf(e, t)], E = this.widthByKey[this.rowKeyOf(e, t - 1)], S = this.widthByKey[this.rowKeyOf(e, t + 1)], z = 0.5, M = (Q, oe, Z) => Q != null && T != null ? Q + z >= T : oe === Z || oe === "card" && Z === "bubble";
3966
+ const s = e.items, r = (ie = s[t]) == null ? void 0 : ie.kind, i = (ae = s[t - 1]) == null ? void 0 : ae.kind, n = (X = s[t + 1]) == null ? void 0 : X.kind, a = e.role === "user", o = 14, f = 4, k = i == null ? void 0 : i.bottom, v = n == null ? void 0 : n.top, T = this.widthByKey[this.rowKeyOf(e, t)], E = this.widthByKey[this.rowKeyOf(e, t - 1)], S = this.widthByKey[this.rowKeyOf(e, t + 1)], z = 0.5, M = (Q, oe, Z) => Q != null && T != null ? Q + z >= T : oe === Z || oe === "card" && Z === "bubble";
3960
3967
  let D = o, O = o, q = o, J = o;
3961
- return a ? (k && (O = f), (y || !n) && (q = f), k && M(E, k, r == null ? void 0 : r.top) && (D = f), y && M(S, y, r == null ? void 0 : r.bottom) && (J = f)) : (k && (D = f), (y || !n) && (J = f), k && M(E, k, r == null ? void 0 : r.top) && (O = f), y && M(S, y, r == null ? void 0 : r.bottom) && (q = f)), { tl: D, tr: O, br: q, bl: J };
3968
+ return a ? (k && (O = f), (v || !n) && (q = f), k && M(E, k, r == null ? void 0 : r.top) && (D = f), v && M(S, v, r == null ? void 0 : r.bottom) && (J = f)) : (k && (D = f), (v || !n) && (J = f), k && M(E, k, r == null ? void 0 : r.top) && (O = f), v && M(S, v, r == null ? void 0 : r.bottom) && (q = f)), { tl: D, tr: O, br: q, bl: J };
3962
3969
  },
3963
3970
  // Inline column-count for the mosaic grid, capped at 4. Single
3964
3971
  // attachment falls back to the vertical-list layout (null). Two
@@ -3981,8 +3988,8 @@ const Br = {
3981
3988
  // corners of every top-row cell flatten too.
3982
3989
  mosaicCornerStyle(e, t, s) {
3983
3990
  if (!t || t < 2) return null;
3984
- const r = Math.min(t, 4), i = Math.floor(e / r), n = e % r, a = n > 0, o = n < r - 1 && e + 1 < t, f = i > 0, k = e + r < t, y = "4px", T = {};
3985
- return (a || f) && (T["--wm-r-tl"] = y), (o || f) && (T["--wm-r-tr"] = y), (a || k) && (T["--wm-r-bl"] = y), (o || k) && (T["--wm-r-br"] = y), s && (T["--wm-r-tl"] = y, T["--wm-r-tr"] = y), Object.keys(T).length ? T : null;
3991
+ const r = Math.min(t, 4), i = Math.floor(e / r), n = e % r, a = n > 0, o = n < r - 1 && e + 1 < t, f = i > 0, k = e + r < t, v = "4px", T = {};
3992
+ return (a || f) && (T["--wm-r-tl"] = v), (o || f) && (T["--wm-r-tr"] = v), (a || k) && (T["--wm-r-bl"] = v), (o || k) && (T["--wm-r-br"] = v), s && (T["--wm-r-tl"] = v, T["--wm-r-tr"] = v), Object.keys(T).length ? T : null;
3986
3993
  },
3987
3994
  // Inline style emitting the four corner CSS variables. Set on
3988
3995
  // `.wm-list__row` so they cascade to Bubble/ActionResult/
@@ -4113,7 +4120,7 @@ const Br = {
4113
4120
  return ((s = t.success) == null ? void 0 : s.summary) || ((i = (r = t.success) == null ? void 0 : r.metadata) == null ? void 0 : i.description) || "";
4114
4121
  if (t.state === "rejected") {
4115
4122
  if ((n = t.rejected) != null && n.reason) return t.rejected.reason;
4116
- const y = (o = (a = t.rejected) == null ? void 0 : a.metadata) == null ? void 0 : o.resolution, T = typeof y == "string" && y.startsWith("admin") ? "action.rejectedByAdmin" : "action.rejectedByUser";
4123
+ const v = (o = (a = t.rejected) == null ? void 0 : a.metadata) == null ? void 0 : o.resolution, T = typeof v == "string" && v.startsWith("admin") ? "action.rejectedByAdmin" : "action.rejectedByUser";
4117
4124
  return this.t(T);
4118
4125
  }
4119
4126
  return t.state === "failure" && (((f = t.failure) == null ? void 0 : f.summary) || ((k = t.failure) == null ? void 0 : k.error)) || "";
@@ -4188,7 +4195,7 @@ const Br = {
4188
4195
  class: "wm-list__row wm-list__row--ai fade-up"
4189
4196
  }, si = { class: "wm-list__avatarSlot" }, ri = ["aria-label", "title"];
4190
4197
  function ii(e, t, s, r, i, n) {
4191
- const a = P("AIAvatar"), o = P("HumanAvatar"), f = P("ActionResult"), k = P("ArtifactRenderer"), y = P("Bubble"), T = P("AttachmentPreview"), E = P("Typing");
4198
+ const a = P("AIAvatar"), o = P("HumanAvatar"), f = P("ActionResult"), k = P("ArtifactRenderer"), v = P("Bubble"), T = P("AttachmentPreview"), E = P("Typing");
4192
4199
  return c(), d("div", Fr, [
4193
4200
  l("div", {
4194
4201
  ref: "scrollEl",
@@ -4200,11 +4207,11 @@ function ii(e, t, s, r, i, n) {
4200
4207
  class: "wm-list__loadMore-spinner",
4201
4208
  "aria-hidden": "true"
4202
4209
  }, null, -1)),
4203
- l("span", Hr, v(n.t("messageList.loadingHistory")), 1)
4204
- ])) : n.historyExhausted ? (c(), d("div", jr, v(n.t("messageList.conversationStart")), 1)) : b("", !0),
4210
+ l("span", Hr, y(n.t("messageList.loadingHistory")), 1)
4211
+ ])) : n.historyExhausted ? (c(), d("div", jr, y(n.t("messageList.conversationStart")), 1)) : b("", !0),
4205
4212
  s.dateLabel ? (c(), d("div", zr, [
4206
4213
  t[7] || (t[7] = l("div", { class: "wm-list__line" }, null, -1)),
4207
- l("span", qr, v(s.dateLabel), 1),
4214
+ l("span", qr, y(s.dateLabel), 1),
4208
4215
  t[8] || (t[8] = l("div", { class: "wm-list__line" }, null, -1))
4209
4216
  ])) : b("", !0),
4210
4217
  (c(!0), d(I, null, F(n.groups, (S, z) => (c(), d(I, {
@@ -4212,7 +4219,7 @@ function ii(e, t, s, r, i, n) {
4212
4219
  }, [
4213
4220
  S.key === n.unreadGroupKey ? (c(), d("div", Vr, [
4214
4221
  t[9] || (t[9] = l("div", { class: "wm-list__line wm-list__line--unread" }, null, -1)),
4215
- l("span", Kr, v(n.t("messageList.unread")), 1),
4222
+ l("span", Kr, y(n.t("messageList.unread")), 1),
4216
4223
  t[10] || (t[10] = l("div", { class: "wm-list__line wm-list__line--unread" }, null, -1))
4217
4224
  ])) : b("", !0),
4218
4225
  S.role === "system" || S.items.length ? (c(), d("div", {
@@ -4221,7 +4228,7 @@ function ii(e, t, s, r, i, n) {
4221
4228
  }, [
4222
4229
  S.role === "system" ? (c(), d("div", Wr, [
4223
4230
  t[11] || (t[11] = l("div", { class: "wm-list__line wm-list__line--strong" }, null, -1)),
4224
- l("span", $r, v(S.systemLabel), 1),
4231
+ l("span", $r, y(S.systemLabel), 1),
4225
4232
  t[12] || (t[12] = l("div", { class: "wm-list__line wm-list__line--strong" }, null, -1))
4226
4233
  ])) : (c(), d(I, { key: 1 }, [
4227
4234
  (c(!0), d(I, null, F(S.items, (M, D) => (c(), d(I, {
@@ -4283,7 +4290,7 @@ function ii(e, t, s, r, i, n) {
4283
4290
  "wm-list__body--mixed": !!M.message.text_md && n.attachmentsOf(M.message).length > 0
4284
4291
  }])
4285
4292
  }, [
4286
- M.message.text_md ? (c(), B(y, {
4293
+ M.message.text_md ? (c(), B(v, {
4287
4294
  key: 0,
4288
4295
  role: S.role,
4289
4296
  text: M.message.text_md
@@ -4320,18 +4327,18 @@ function ii(e, t, s, r, i, n) {
4320
4327
  key: 0,
4321
4328
  class: x(["wm-list__meta wm-list__meta--press", { "wm-list__meta--right": S.role === "user" }])
4322
4329
  }, [
4323
- S.role !== "user" ? (c(), d("span", Jr, v(n.roleLabel(S)), 1)) : b("", !0),
4330
+ S.role !== "user" ? (c(), d("span", Jr, y(n.roleLabel(S)), 1)) : b("", !0),
4324
4331
  S.role !== "user" && n.timeOf(M.message) ? (c(), d("span", Xr, "•")) : b("", !0),
4325
- n.timeOf(M.message) ? (c(), d("span", Qr, v(n.timeOf(M.message)), 1)) : b("", !0)
4332
+ n.timeOf(M.message) ? (c(), d("span", Qr, y(n.timeOf(M.message)), 1)) : b("", !0)
4326
4333
  ], 2)) : b("", !0)
4327
4334
  ], 64))), 128)),
4328
4335
  (S.role !== "user" || n.lastTimeOf(S)) && !n.hasTrailingOverlay(S) ? (c(), d("div", {
4329
4336
  key: 0,
4330
4337
  class: x(["wm-list__meta", { "wm-list__meta--right": S.role === "user" }])
4331
4338
  }, [
4332
- S.role !== "user" ? (c(), d("span", Zr, v(n.roleLabel(S)), 1)) : b("", !0),
4339
+ S.role !== "user" ? (c(), d("span", Zr, y(n.roleLabel(S)), 1)) : b("", !0),
4333
4340
  S.role !== "user" && n.lastTimeOf(S) ? (c(), d("span", ei, "•")) : b("", !0),
4334
- n.lastTimeOf(S) ? (c(), d("span", ti, v(n.lastTimeOf(S)), 1)) : b("", !0)
4341
+ n.lastTimeOf(S) ? (c(), d("span", ti, y(n.lastTimeOf(S)), 1)) : b("", !0)
4335
4342
  ], 2)) : b("", !0)
4336
4343
  ], 64))
4337
4344
  ], 2)) : b("", !0)
@@ -4442,56 +4449,56 @@ async function di(e = {}) {
4442
4449
  t = await navigator.mediaDevices.getDisplayMedia(
4443
4450
  Ke({ audio: !0 })
4444
4451
  );
4445
- } catch (y) {
4446
- return (y == null ? void 0 : y.name) !== "NotAllowedError" && console.error("[media] record picker", y), null;
4452
+ } catch (v) {
4453
+ return (v == null ? void 0 : v.name) !== "NotAllowedError" && console.error("[media] record picker", v), null;
4447
4454
  }
4448
4455
  const s = oi();
4449
4456
  let r;
4450
4457
  try {
4451
4458
  r = s ? new window.MediaRecorder(t, { mimeType: s }) : new window.MediaRecorder(t);
4452
- } catch (y) {
4453
- return console.error("[media] recorder init", y), t.getTracks().forEach((T) => {
4459
+ } catch (v) {
4460
+ return console.error("[media] recorder init", v), t.getTracks().forEach((T) => {
4454
4461
  T.stop();
4455
4462
  }), null;
4456
4463
  }
4457
4464
  const i = [];
4458
4465
  let n = null, a = !1;
4459
- r.addEventListener("dataavailable", (y) => {
4460
- y.data && y.data.size > 0 && i.push(y.data);
4466
+ r.addEventListener("dataavailable", (v) => {
4467
+ v.data && v.data.size > 0 && i.push(v.data);
4461
4468
  }), r.addEventListener("stop", () => {
4462
- var y, T;
4469
+ var v, T;
4463
4470
  if (n && clearInterval(n), t.getTracks().forEach((E) => {
4464
4471
  E.stop();
4465
4472
  }), i.length) {
4466
4473
  const E = r.mimeType || s || "video/webm", S = new Blob(i, { type: E }), z = /mp4/.test(E) ? "mp4" : "webm", M = (/* @__PURE__ */ new Date()).toISOString().replace(/[:.]/g, "-").slice(0, 19), D = new File([S], `ecran-${M}.${z}`, {
4467
4474
  type: E
4468
4475
  });
4469
- (y = e.onfinalize) == null || y.call(e, D);
4476
+ (v = e.onfinalize) == null || v.call(e, D);
4470
4477
  } else
4471
4478
  (T = e.oncancel) == null || T.call(e);
4472
- }), t.getVideoTracks().forEach((y) => {
4473
- y.addEventListener("ended", () => o(), { once: !0 });
4479
+ }), t.getVideoTracks().forEach((v) => {
4480
+ v.addEventListener("ended", () => o(), { once: !0 });
4474
4481
  });
4475
4482
  function o() {
4476
4483
  if (!a && (a = !0, r.state !== "inactive"))
4477
4484
  try {
4478
4485
  r.stop();
4479
- } catch (y) {
4480
- console.error("[media] recorder stop", y);
4486
+ } catch (v) {
4487
+ console.error("[media] recorder stop", v);
4481
4488
  }
4482
4489
  }
4483
4490
  try {
4484
4491
  r.start(1e3);
4485
- } catch (y) {
4486
- return console.error("[media] recorder start", y), t.getTracks().forEach((T) => {
4492
+ } catch (v) {
4493
+ return console.error("[media] recorder start", v), t.getTracks().forEach((T) => {
4487
4494
  T.stop();
4488
4495
  }), null;
4489
4496
  }
4490
4497
  (k = e.onstart) == null || k.call(e);
4491
4498
  const f = Date.now();
4492
4499
  return n = setInterval(() => {
4493
- var y;
4494
- (y = e.ontick) == null || y.call(e, Date.now() - f);
4500
+ var v;
4501
+ (v = e.ontick) == null || v.call(e, Date.now() - f);
4495
4502
  }, 500), {
4496
4503
  stop: o,
4497
4504
  get state() {
@@ -4678,7 +4685,7 @@ const ui = [
4678
4685
  key: 1,
4679
4686
  class: "wm-compose__menu",
4680
4687
  role: "menu"
4681
- }, gi = ["disabled", "onClick"], vi = { class: "wm-compose__menuIcon" }, yi = {
4688
+ }, gi = ["disabled", "onClick"], yi = { class: "wm-compose__menuIcon" }, vi = {
4682
4689
  viewBox: "0 0 24 24",
4683
4690
  width: "14",
4684
4691
  height: "14",
@@ -4694,12 +4701,12 @@ function Ai(e, t, s, r, i, n) {
4694
4701
  class: "wm-rec__dot",
4695
4702
  "aria-hidden": "true"
4696
4703
  }, null, -1)),
4697
- l("span", fi, v(n.t("composer.recording", { time: n.recordingElapsedLabel })), 1),
4704
+ l("span", fi, y(n.t("composer.recording", { time: n.recordingElapsedLabel })), 1),
4698
4705
  l("button", {
4699
4706
  type: "button",
4700
4707
  class: "wm-rec__stop",
4701
4708
  onClick: t[0] || (t[0] = (...a) => n.stopRecording && n.stopRecording(...a))
4702
- }, v(n.t("composer.stop")), 1)
4709
+ }, y(n.t("composer.stop")), 1)
4703
4710
  ])) : b("", !0),
4704
4711
  l("form", {
4705
4712
  class: x(["wm-compose", { "has-attach": i.attachOpen }]),
@@ -4725,8 +4732,8 @@ function Ai(e, t, s, r, i, n) {
4725
4732
  disabled: a.disabled,
4726
4733
  onClick: (o) => n.onAttachAction(a.action)
4727
4734
  }, [
4728
- l("span", vi, [
4729
- (c(), d("svg", yi, [
4735
+ l("span", yi, [
4736
+ (c(), d("svg", vi, [
4730
4737
  l("path", {
4731
4738
  d: a.path,
4732
4739
  stroke: "currentColor",
@@ -4737,7 +4744,7 @@ function Ai(e, t, s, r, i, n) {
4737
4744
  }, null, 8, pi)
4738
4745
  ]))
4739
4746
  ]),
4740
- l("span", null, v(a.label), 1)
4747
+ l("span", null, y(a.label), 1)
4741
4748
  ], 8, gi))), 128))
4742
4749
  ])) : b("", !0),
4743
4750
  $(l("textarea", {
@@ -4799,7 +4806,7 @@ function Ai(e, t, s, r, i, n) {
4799
4806
  ], 34)
4800
4807
  ], 6);
4801
4808
  }
4802
- const Si = /* @__PURE__ */ U(hi, [["render", Ai], ["__scopeId", "data-v-a7f822e9"]]), Ti = {
4809
+ const Si = /* @__PURE__ */ U(hi, [["render", Ai], ["__scopeId", "data-v-2e0e17a9"]]), Ti = {
4803
4810
  name: "WmInlineCallbacks",
4804
4811
  props: {
4805
4812
  // Array d'items `{ id?, label, style?, ... }`. Pour les suggestions,
@@ -4852,15 +4859,15 @@ function Li(e, t, s, r, i, n) {
4852
4859
  class: "wm-icb__btn wm-icb__btn--chip",
4853
4860
  style: N({ animationDelay: s.baseDelay + o * s.stepDelay + "ms" }),
4854
4861
  onClick: (f) => e.$emit("select", a)
4855
- }, v(a.label), 13, Mi))), 128)) : (c(), d(I, { key: 1 }, [
4856
- n.headerTitle ? (c(), d("div", xi, v(n.headerTitle), 1)) : b("", !0),
4862
+ }, y(a.label), 13, Mi))), 128)) : (c(), d(I, { key: 1 }, [
4863
+ n.headerTitle ? (c(), d("div", xi, y(n.headerTitle), 1)) : b("", !0),
4857
4864
  l("div", Oi, [
4858
4865
  (c(!0), d(I, null, F(s.items, (a, o) => (c(), d("button", {
4859
4866
  key: a.id != null ? a.id : o,
4860
4867
  type: "button",
4861
4868
  class: x(["wm-icb__btn", n.btnClass(a)]),
4862
4869
  onClick: (f) => e.$emit("select", a)
4863
- }, v(a.label), 11, Ri))), 128))
4870
+ }, y(a.label), 11, Ri))), 128))
4864
4871
  ])
4865
4872
  ], 64))
4866
4873
  ], 2)) : b("", !0);
@@ -4997,8 +5004,8 @@ function ra(e, t, s, r, i, n) {
4997
5004
  }, null, 8, ["name", "image-url"])
4998
5005
  ]),
4999
5006
  l("div", Fi, [
5000
- l("div", Ni, v(s.form.title || n.t("form.title")), 1),
5001
- s.form.description ? (c(), d("div", Hi, v(s.form.description), 1)) : b("", !0)
5007
+ l("div", Ni, y(s.form.title || n.t("form.title")), 1),
5008
+ s.form.description ? (c(), d("div", Hi, y(s.form.description), 1)) : b("", !0)
5002
5009
  ])
5003
5010
  ]),
5004
5011
  l("form", {
@@ -5013,7 +5020,7 @@ function ra(e, t, s, r, i, n) {
5013
5020
  for: `wm-f-${i._uid}-${o.key}`,
5014
5021
  class: "wm-form__label"
5015
5022
  }, [
5016
- Me(v(o.label), 1),
5023
+ Me(y(o.label), 1),
5017
5024
  o.required ? (c(), d("span", zi, "*")) : b("", !0)
5018
5025
  ], 8, ji),
5019
5026
  o.type === "text" ? $((c(), d("input", {
@@ -5073,7 +5080,7 @@ function ra(e, t, s, r, i, n) {
5073
5080
  }, null, 8, Gi), [
5074
5081
  [Ge, i.values[o.key]]
5075
5082
  ]),
5076
- l("span", null, v(o.placeholder || n.t("common.yes")), 1)
5083
+ l("span", null, y(o.placeholder || n.t("common.yes")), 1)
5077
5084
  ])) : o.type === "select" ? $((c(), d("select", {
5078
5085
  key: 5,
5079
5086
  id: `wm-f-${i._uid}-${o.key}`,
@@ -5082,11 +5089,11 @@ function ra(e, t, s, r, i, n) {
5082
5089
  required: o.required,
5083
5090
  disabled: s.readOnly || i.busy
5084
5091
  }, [
5085
- l("option", Ji, v(o.placeholder || n.t("form.choose")), 1),
5092
+ l("option", Ji, y(o.placeholder || n.t("form.choose")), 1),
5086
5093
  (c(!0), d(I, null, F(o.options, (f) => (c(), d("option", {
5087
5094
  key: f.value,
5088
5095
  value: f.value
5089
- }, v(f.label), 9, Xi))), 128))
5096
+ }, y(f.label), 9, Xi))), 128))
5090
5097
  ], 8, Yi)), [
5091
5098
  [Ye, i.values[o.key]]
5092
5099
  ]) : o.type === "multiselect" ? (c(), d("div", Qi, [
@@ -5105,19 +5112,19 @@ function ra(e, t, s, r, i, n) {
5105
5112
  k.target.checked
5106
5113
  )
5107
5114
  }, null, 40, Zi),
5108
- l("span", null, v(f.label), 1)
5115
+ l("span", null, y(f.label), 1)
5109
5116
  ]))), 128))
5110
5117
  ])) : b("", !0)
5111
5118
  ]))), 128)),
5112
- i.error ? (c(), d("div", ea, v(i.error), 1)) : b("", !0),
5113
- s.readOnly ? (c(), d("div", sa, v(n.t("form.responseSent")), 1)) : (c(), d("button", {
5119
+ i.error ? (c(), d("div", ea, y(i.error), 1)) : b("", !0),
5120
+ s.readOnly ? (c(), d("div", sa, y(n.t("form.responseSent")), 1)) : (c(), d("button", {
5114
5121
  key: 1,
5115
5122
  type: "submit",
5116
5123
  class: "wm-form__submit",
5117
5124
  disabled: i.busy
5118
5125
  }, [
5119
5126
  i.busy ? (c(), d("span", na)) : b("", !0),
5120
- l("span", null, v(i.busy ? n.t("common.sending") : s.form.submit_label || n.t("common.send")), 1)
5127
+ l("span", null, y(i.busy ? n.t("common.sending") : s.form.submit_label || n.t("common.send")), 1)
5121
5128
  ], 8, ta))
5122
5129
  ], 32)
5123
5130
  ]);
@@ -5159,8 +5166,8 @@ const ia = /* @__PURE__ */ U(Bi, [["render", ra], ["__scopeId", "data-v-fe65cc56
5159
5166
  }, oa = { class: "wm-fb" }, la = { class: "wm-fb__title" }, ca = { class: "wm-fb__sub" }, da = { class: "wm-fb__row" }, ua = ["onClick"], ha = { class: "wm-fb__emoji" }, ma = { class: "wm-fb__label" }, fa = ["disabled"], _a = {
5160
5167
  key: 1,
5161
5168
  class: "wm-fb__done"
5162
- }, ga = { class: "wm-fb__doneTitle" }, va = { class: "wm-fb__doneSub" };
5163
- function ya(e, t, s, r, i, n) {
5169
+ }, ga = { class: "wm-fb__doneTitle" }, ya = { class: "wm-fb__doneSub" };
5170
+ function va(e, t, s, r, i, n) {
5164
5171
  return c(), d("div", oa, [
5165
5172
  s.done ? (c(), d("div", _a, [
5166
5173
  t[1] || (t[1] = l("div", { class: "wm-fb__check" }, [
@@ -5178,11 +5185,11 @@ function ya(e, t, s, r, i, n) {
5178
5185
  l("path", { d: "M20 6L9 17l-5-5" })
5179
5186
  ])
5180
5187
  ], -1)),
5181
- l("div", ga, v(n.t("feedback.doneTitle")), 1),
5182
- l("div", va, v(n.t("feedback.doneSubtitle")), 1)
5188
+ l("div", ga, y(n.t("feedback.doneTitle")), 1),
5189
+ l("div", ya, y(n.t("feedback.doneSubtitle")), 1)
5183
5190
  ])) : (c(), d(I, { key: 0 }, [
5184
- l("div", la, v(n.t("feedback.question")), 1),
5185
- l("div", ca, v(n.t("feedback.subtitle")), 1),
5191
+ l("div", la, y(n.t("feedback.question")), 1),
5192
+ l("div", ca, y(n.t("feedback.subtitle")), 1),
5186
5193
  l("div", da, [
5187
5194
  (c(!0), d(I, null, F(n.options, (a) => (c(), d("button", {
5188
5195
  key: a.v,
@@ -5190,8 +5197,8 @@ function ya(e, t, s, r, i, n) {
5190
5197
  class: x(["wm-fb__opt", { "is-selected": i.sel === a.v }]),
5191
5198
  onClick: (o) => i.sel = a.v
5192
5199
  }, [
5193
- l("span", ha, v(a.e), 1),
5194
- l("span", ma, v(a.l), 1)
5200
+ l("span", ha, y(a.e), 1),
5201
+ l("span", ma, y(a.l), 1)
5195
5202
  ], 10, ua))), 128))
5196
5203
  ]),
5197
5204
  l("button", {
@@ -5199,11 +5206,11 @@ function ya(e, t, s, r, i, n) {
5199
5206
  class: "wm-fb__send",
5200
5207
  disabled: !i.sel || s.busy,
5201
5208
  onClick: t[0] || (t[0] = (...a) => n.onSend && n.onSend(...a))
5202
- }, v(s.busy ? n.t("common.sending") : n.t("feedback.submit")), 9, fa)
5209
+ }, y(s.busy ? n.t("common.sending") : n.t("feedback.submit")), 9, fa)
5203
5210
  ], 64))
5204
5211
  ]);
5205
5212
  }
5206
- const pa = /* @__PURE__ */ U(aa, [["render", ya], ["__scopeId", "data-v-9b630564"]]), wa = {
5213
+ const pa = /* @__PURE__ */ U(aa, [["render", va], ["__scopeId", "data-v-9b630564"]]), wa = {
5207
5214
  name: "WmMoreMenu",
5208
5215
  inject: {
5209
5216
  // Translator shared by the Messenger shell; French fallback when
@@ -5278,7 +5285,7 @@ function Ea(e, t, s, r, i, n) {
5278
5285
  l("path", { d: "M16.5 3.5a2.121 2.121 0 0 1 3 3L7 19l-4 1 1-4 12.5-12.5z" })
5279
5286
  ])
5280
5287
  ], -1)),
5281
- l("span", Aa, v(n.t("moreMenu.editTitle")), 1)
5288
+ l("span", Aa, y(n.t("moreMenu.editTitle")), 1)
5282
5289
  ])) : b("", !0),
5283
5290
  s.canExport ? (c(), d("button", {
5284
5291
  key: 1,
@@ -5301,7 +5308,7 @@ function Ea(e, t, s, r, i, n) {
5301
5308
  l("path", { d: "M4 12v8a2 2 0 002 2h12a2 2 0 002-2v-8M16 6l-4-4-4 4M12 2v13" })
5302
5309
  ])
5303
5310
  ], -1)),
5304
- l("span", Sa, v(n.t("moreMenu.exportTranscript")), 1),
5311
+ l("span", Sa, y(n.t("moreMenu.exportTranscript")), 1),
5305
5312
  t[8] || (t[8] = l("span", { class: "wm-mm__hint" }, ".txt", -1))
5306
5313
  ])) : b("", !0)
5307
5314
  ])) : b("", !0),
@@ -5328,7 +5335,7 @@ function Ea(e, t, s, r, i, n) {
5328
5335
  l("path", { d: "M15.54 8.46a5 5 0 010 7.07M19.07 4.93a10 10 0 010 14.14" })
5329
5336
  ])
5330
5337
  ], -1)),
5331
- l("span", xa, v(n.t("moreMenu.sound")), 1),
5338
+ l("span", xa, y(n.t("moreMenu.sound")), 1),
5332
5339
  l("span", {
5333
5340
  class: x(["wm-mm__toggle", { "wm-mm__toggle--on": i.soundOn }])
5334
5341
  }, [...t[9] || (t[9] = [
@@ -5359,7 +5366,7 @@ function Ea(e, t, s, r, i, n) {
5359
5366
  l("path", { d: "M18 10a8 8 0 11-16 0 8 8 0 0116 0zM10 6v4l3 2" })
5360
5367
  ])
5361
5368
  ], -1)),
5362
- l("span", Ra, v(n.t("moreMenu.serviceStatus")), 1)
5369
+ l("span", Ra, y(n.t("moreMenu.serviceStatus")), 1)
5363
5370
  ])) : b("", !0),
5364
5371
  s.helpUrl ? (c(), d("button", {
5365
5372
  key: 1,
@@ -5382,7 +5389,7 @@ function Ea(e, t, s, r, i, n) {
5382
5389
  l("path", { d: "M9 11a3 3 0 116 0c0 2-3 2-3 5M12 19h.01M12 22a10 10 0 110-20 10 10 0 010 20z" })
5383
5390
  ])
5384
5391
  ], -1)),
5385
- l("span", La, v(n.t("moreMenu.helpCenter")), 1)
5392
+ l("span", La, y(n.t("moreMenu.helpCenter")), 1)
5386
5393
  ])) : b("", !0)
5387
5394
  ])
5388
5395
  ])
@@ -5443,7 +5450,7 @@ function Va(e, t, s, r, i, n) {
5443
5450
  }),
5444
5451
  l("div", Ua, [
5445
5452
  l("div", Da, [
5446
- l("div", Fa, v(s.title || n.t("rename.title")), 1),
5453
+ l("div", Fa, y(s.title || n.t("rename.title")), 1),
5447
5454
  l("button", {
5448
5455
  type: "button",
5449
5456
  class: "wm-dialog__close",
@@ -5486,13 +5493,13 @@ function Va(e, t, s, r, i, n) {
5486
5493
  type: "button",
5487
5494
  class: "wm-dialog__btn",
5488
5495
  onClick: t[5] || (t[5] = (a) => e.$emit("close"))
5489
- }, v(n.t("common.cancel")), 1),
5496
+ }, y(n.t("common.cancel")), 1),
5490
5497
  l("button", {
5491
5498
  type: "button",
5492
5499
  class: "wm-dialog__btn wm-dialog__btn--primary",
5493
5500
  disabled: !n.canSubmit,
5494
5501
  onClick: t[6] || (t[6] = (...a) => n.onSubmit && n.onSubmit(...a))
5495
- }, v(n.t("common.save")), 9, qa)
5502
+ }, y(n.t("common.save")), 9, qa)
5496
5503
  ])
5497
5504
  ])
5498
5505
  ]);
@@ -5736,8 +5743,8 @@ const Ka = /* @__PURE__ */ U(Ba, [["render", Va], ["__scopeId", "data-v-6d5f94a8
5736
5743
  var k;
5737
5744
  const i = e[r.id] || [], n = Y(r.last_read_message_id);
5738
5745
  let a = 0, o = null;
5739
- for (let y = i.length - 1; y >= 0; y--) {
5740
- const T = i[y];
5746
+ for (let v = i.length - 1; v >= 0; v--) {
5747
+ const T = i[v];
5741
5748
  if (!T) continue;
5742
5749
  if (((k = T.author) == null ? void 0 : k.type) === "user") break;
5743
5750
  const E = Y(T.id);
@@ -5747,11 +5754,11 @@ const Ka = /* @__PURE__ */ U(Ba, [["render", Va], ["__scopeId", "data-v-6d5f94a8
5747
5754
  }
5748
5755
  }
5749
5756
  if (!i.length) {
5750
- const y = Y(r.last_message_id);
5751
- y != null && (n == null || y > n) && (a = 1, o = r.last_message_author || null);
5757
+ const v = Y(r.last_message_id);
5758
+ v != null && (n == null || v > n) && (a = 1, o = r.last_message_author || null);
5752
5759
  }
5753
5760
  const f = i.filter(
5754
- (y) => !((y == null ? void 0 : y.id) != null && t[y.id] === 0)
5761
+ (v) => !((v == null ? void 0 : v.id) != null && t[v.id] === 0)
5755
5762
  );
5756
5763
  return {
5757
5764
  ...r,
@@ -5977,8 +5984,8 @@ const Ka = /* @__PURE__ */ U(Ba, [["render", Va], ["__scopeId", "data-v-6d5f94a8
5977
5984
  if (!(a != null && a.loaded)) return t;
5978
5985
  }
5979
5986
  const s = this.revealedAt, r = (this.s.messagesByConv[e.id] || []).filter((a) => {
5980
- var o, f, k, y, T;
5981
- return (a == null ? void 0 : a.type) === "action" && ((o = a == null ? void 0 : a.payload) == null ? void 0 : o.state) === "pending" || he(a) && !(s[a.id] > 0) ? !1 : (a == null ? void 0 : a.type) === "action" || (a == null ? void 0 : a.type) === "system" || ((f = a == null ? void 0 : a.payload) == null ? void 0 : f.type) === "system" || Array.isArray((k = a == null ? void 0 : a.payload) == null ? void 0 : k.attachments) && a.payload.attachments.length || (y = a == null ? void 0 : a.metadata) != null && y.artifact || (T = a == null ? void 0 : a.metadata) != null && T.form || Array.isArray(a == null ? void 0 : a.callbacks) && a.callbacks.some((E) => (E == null ? void 0 : E.intent) === "submit_form") ? !0 : typeof (a == null ? void 0 : a.text_md) == "string" && a.text_md.trim().length > 0;
5987
+ var o, f, k, v, T;
5988
+ return (a == null ? void 0 : a.type) === "action" && ((o = a == null ? void 0 : a.payload) == null ? void 0 : o.state) === "pending" || he(a) && !(s[a.id] > 0) ? !1 : (a == null ? void 0 : a.type) === "action" || (a == null ? void 0 : a.type) === "system" || ((f = a == null ? void 0 : a.payload) == null ? void 0 : f.type) === "system" || Array.isArray((k = a == null ? void 0 : a.payload) == null ? void 0 : k.attachments) && a.payload.attachments.length || (v = a == null ? void 0 : a.metadata) != null && v.artifact || (T = a == null ? void 0 : a.metadata) != null && T.form || Array.isArray(a == null ? void 0 : a.callbacks) && a.callbacks.some((E) => (E == null ? void 0 : E.intent) === "submit_form") ? !0 : typeof (a == null ? void 0 : a.text_md) == "string" && a.text_md.trim().length > 0;
5982
5989
  });
5983
5990
  return t.length ? [...t, ...r] : r;
5984
5991
  },
@@ -6394,9 +6401,9 @@ const Ka = /* @__PURE__ */ U(Ba, [["render", Va], ["__scopeId", "data-v-6d5f94a8
6394
6401
  this.launcherHovered = e, this.sendCurrentLauncherSize();
6395
6402
  },
6396
6403
  sendCurrentLauncherSize() {
6397
- var y, T, E, S, z, M, D;
6404
+ var v, T, E, S, z, M, D;
6398
6405
  if (this.isOpen) return;
6399
- const e = (T = (y = this.$el) == null ? void 0 : y.querySelector) == null ? void 0 : T.call(y, ".wm-launcherWrap");
6406
+ const e = (T = (v = this.$el) == null ? void 0 : v.querySelector) == null ? void 0 : T.call(v, ".wm-launcherWrap");
6400
6407
  if (!e) return;
6401
6408
  const t = e.getBoundingClientRect();
6402
6409
  if (!t.width || !t.height) return;
@@ -6845,7 +6852,7 @@ const Ka = /* @__PURE__ */ U(Ba, [["render", Va], ["__scopeId", "data-v-6d5f94a8
6845
6852
  "aria-live": "polite"
6846
6853
  }, mo = { class: "wm-ended__lbl" };
6847
6854
  function fo(e, t, s, r, i, n) {
6848
- const a = P("Launcher"), o = P("Header"), f = P("History"), k = P("Onboarding"), y = P("MessageList"), T = P("InlineCallbacks"), E = P("FormCard"), S = P("Feedback"), z = P("Composer"), M = P("MoreMenu"), D = P("RenameDialog");
6855
+ const a = P("Launcher"), o = P("Header"), f = P("History"), k = P("Onboarding"), v = P("MessageList"), T = P("InlineCallbacks"), E = P("FormCard"), S = P("Feedback"), z = P("Composer"), M = P("MoreMenu"), D = P("RenameDialog");
6849
6856
  return c(), d("div", {
6850
6857
  class: x(["wm-root", `wm-root--${s.displayMode}`]),
6851
6858
  style: N(n.rootStyle)
@@ -6863,7 +6870,8 @@ function fo(e, t, s, r, i, n) {
6863
6870
  class: x([
6864
6871
  "wm-panel",
6865
6872
  `wm-panel--${s.displayMode}`,
6866
- { "wm-panel--welcome": n.ready && !n.error && !n.currentConv }
6873
+ { "wm-panel--welcome": n.ready && !n.error && !n.currentConv },
6874
+ { "wm-panel--launching": i.launching }
6867
6875
  ]),
6868
6876
  style: N(i.floatHeight ? { "--wm-float-h": i.floatHeight + "px" } : null),
6869
6877
  role: "dialog",
@@ -6932,8 +6940,8 @@ function fo(e, t, s, r, i, n) {
6932
6940
  ])
6933
6941
  ], -1)),
6934
6942
  l("div", null, [
6935
- l("div", Qa, v(n.t("error.connectionFailed")), 1),
6936
- l("div", Za, v(n.error), 1)
6943
+ l("div", Qa, y(n.t("error.connectionFailed")), 1),
6944
+ l("div", Za, y(n.error), 1)
6937
6945
  ])
6938
6946
  ])
6939
6947
  ])) : !n.currentConv && i.showHistory ? (c(), B(f, {
@@ -6945,7 +6953,7 @@ function fo(e, t, s, r, i, n) {
6945
6953
  key: "chat",
6946
6954
  class: x(["wm-screen wm-screen--chat", { "wm-screen--launching": i.launching }])
6947
6955
  }, [
6948
- K(y, {
6956
+ K(v, {
6949
6957
  ref: "messageList",
6950
6958
  messages: n.displayedMessages,
6951
6959
  "streaming-active": n.streamingActive,
@@ -6993,7 +7001,7 @@ function fo(e, t, s, r, i, n) {
6993
7001
  class: "wm-actionWait__spinner",
6994
7002
  "aria-hidden": "true"
6995
7003
  }, null, -1)),
6996
- l("span", so, v(n.t("action.inProgress", {
7004
+ l("span", so, y(n.t("action.inProgress", {
6997
7005
  name: n.actionInFlightName
6998
7006
  })), 1)
6999
7007
  ])) : b("", !0),
@@ -7025,8 +7033,8 @@ function fo(e, t, s, r, i, n) {
7025
7033
  ])
7026
7034
  ], -1)),
7027
7035
  l("span", oo, [
7028
- l("span", lo, v(O.name), 1),
7029
- n.formatAttachmentSize(O.size_bytes) ? (c(), d("span", co, v(n.formatAttachmentSize(
7036
+ l("span", lo, y(O.name), 1),
7037
+ n.formatAttachmentSize(O.size_bytes) ? (c(), d("span", co, y(n.formatAttachmentSize(
7030
7038
  O.size_bytes
7031
7039
  )), 1)) : b("", !0)
7032
7040
  ])
@@ -7054,12 +7062,12 @@ function fo(e, t, s, r, i, n) {
7054
7062
  ]))), 128))
7055
7063
  ])) : b("", !0),
7056
7064
  n.endedBlockVisible ? (c(), d("div", ho, [
7057
- l("span", mo, v(n.isClosed ? n.t("composer.conversationClosed") : n.t("composer.conversationEnded")), 1),
7065
+ l("span", mo, y(n.isClosed ? n.t("composer.conversationClosed") : n.t("composer.conversationEnded")), 1),
7058
7066
  l("button", {
7059
7067
  type: "button",
7060
7068
  class: "wm-ended__btn",
7061
7069
  onClick: t[2] || (t[2] = (O) => n.isClosed ? n.onReopen() : n.startConv())
7062
- }, v(n.isClosed ? n.t("composer.reopen") : n.t("composer.newConversation")), 1)
7070
+ }, y(n.isClosed ? n.t("composer.reopen") : n.t("composer.newConversation")), 1)
7063
7071
  ])) : n.actionInFlight ? b("", !0) : (c(), B(z, {
7064
7072
  key: 4,
7065
7073
  ref: "composer",
@@ -7127,7 +7135,7 @@ function fo(e, t, s, r, i, n) {
7127
7135
  ], 6)) : b("", !0)
7128
7136
  ], 6);
7129
7137
  }
7130
- const vo = /* @__PURE__ */ U(Wa, [["render", fo], ["__scopeId", "data-v-20b36fa2"]]), yo = "0.6.12";
7138
+ const yo = /* @__PURE__ */ U(Wa, [["render", fo], ["__scopeId", "data-v-505609ba"]]), vo = "0.6.13";
7131
7139
  export {
7132
7140
  me as AIAvatar,
7133
7141
  be as AVATAR_COLORS,
@@ -7144,19 +7152,19 @@ export {
7144
7152
  pa as Feedback,
7145
7153
  ia as FormCard,
7146
7154
  _n as Header,
7147
- ve as HumanAvatar,
7155
+ ye as HumanAvatar,
7148
7156
  Ei as InlineCallbacks,
7149
7157
  qt as Launcher,
7150
7158
  Le as MEDIA_RECORDER_SUPPORTED,
7151
7159
  ai as MessageList,
7152
- vo as Messenger,
7160
+ yo as Messenger,
7153
7161
  Ia as MoreMenu,
7154
7162
  Qn as Onboarding,
7155
7163
  ge as SCREEN_CAPTURE_SUPPORTED,
7156
7164
  ht as SUPPORTED_LANGUAGES,
7157
7165
  tn as TeamAvatars,
7158
7166
  Ir as Typing,
7159
- yo as VERSION,
7167
+ vo as VERSION,
7160
7168
  xe as avatarColor,
7161
7169
  Oe as avatarInitials,
7162
7170
  li as captureScreenshotFile,
@@ -7165,7 +7173,7 @@ export {
7165
7173
  H as createTranslator,
7166
7174
  tt as createTransport,
7167
7175
  re as dateLocale,
7168
- vo as default,
7176
+ yo as default,
7169
7177
  Ce as formatTime,
7170
7178
  go as guessAttachmentKind,
7171
7179
  oi as pickRecorderMime,