@_solaris/messenger-widget 0.4.5 → 0.4.6
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.cjs +10 -10
- package/dist/messenger.embed.js +10 -10
- package/dist/messenger.js +269 -227
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/messenger.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { reactive as
|
|
1
|
+
import { reactive as Ue, openBlock as c, createElementBlock as u, normalizeStyle as z, normalizeClass as x, toDisplayString as v, resolveComponent as L, createVNode as $, Transition as Fe, withCtx as je, Fragment as I, renderList as F, withKeys as ue, withModifiers as X, createElementVNode as o, createCommentVNode as b, createBlock as R, withDirectives as K, vModelText as ee, createTextVNode as ge, resolveDynamicComponent as Pe, renderSlot as De, vModelCheckbox as He, vModelSelect as ze, markRaw as we } from "vue";
|
|
2
2
|
const qe = [
|
|
3
3
|
"connected",
|
|
4
4
|
"message",
|
|
@@ -6,7 +6,7 @@ const qe = [
|
|
|
6
6
|
"conversation_updated",
|
|
7
7
|
"config_updated",
|
|
8
8
|
"action_status"
|
|
9
|
-
],
|
|
9
|
+
], ke = "/client", $e = 5 * 60 * 1e3, Ve = 10 * 60 * 1e3, Ke = 5 * 60 * 1e3;
|
|
10
10
|
function We(e) {
|
|
11
11
|
const t = {
|
|
12
12
|
baseUrl: Ge(e.baseUrl || ""),
|
|
@@ -55,7 +55,7 @@ function We(e) {
|
|
|
55
55
|
};
|
|
56
56
|
}
|
|
57
57
|
async function a(d, f, _) {
|
|
58
|
-
const y = await fetch(`${t.baseUrl}${
|
|
58
|
+
const y = await fetch(`${t.baseUrl}${ke}${f}`, {
|
|
59
59
|
method: d,
|
|
60
60
|
headers: { "Content-Type": "application/json", ...s() },
|
|
61
61
|
body: _ !== void 0 ? JSON.stringify(_) : void 0
|
|
@@ -121,7 +121,7 @@ function We(e) {
|
|
|
121
121
|
`/conversations/${encodeURIComponent(d)}`
|
|
122
122
|
)).conversation;
|
|
123
123
|
}
|
|
124
|
-
async function
|
|
124
|
+
async function q(d, f) {
|
|
125
125
|
return (await a(
|
|
126
126
|
"PATCH",
|
|
127
127
|
`/conversations/${encodeURIComponent(d)}`,
|
|
@@ -145,7 +145,7 @@ function We(e) {
|
|
|
145
145
|
);
|
|
146
146
|
}
|
|
147
147
|
async function N(d, f) {
|
|
148
|
-
|
|
148
|
+
V();
|
|
149
149
|
const _ = {
|
|
150
150
|
client_msg_id: f.client_msg_id,
|
|
151
151
|
type: "content",
|
|
@@ -159,8 +159,8 @@ function We(e) {
|
|
|
159
159
|
_
|
|
160
160
|
);
|
|
161
161
|
}
|
|
162
|
-
async function
|
|
163
|
-
return
|
|
162
|
+
async function H(d, f, _) {
|
|
163
|
+
return V(), a(
|
|
164
164
|
"POST",
|
|
165
165
|
`/messages/${encodeURIComponent(d)}/callbacks/${encodeURIComponent(f)}`,
|
|
166
166
|
_ ? { inputs: _ } : {}
|
|
@@ -203,7 +203,7 @@ function We(e) {
|
|
|
203
203
|
userHash: t.userHash,
|
|
204
204
|
widgetId: t.widgetId
|
|
205
205
|
}).toString();
|
|
206
|
-
return `${t.baseUrl}${
|
|
206
|
+
return `${t.baseUrl}${ke}/stream?${d}`;
|
|
207
207
|
}
|
|
208
208
|
function G() {
|
|
209
209
|
if (!t.eventSource && !(typeof document < "u" && document.hidden))
|
|
@@ -230,13 +230,13 @@ function We(e) {
|
|
|
230
230
|
function Q() {
|
|
231
231
|
t.eventSource && (t.eventSource.close(), t.eventSource = null), t.connection !== "paused" && r("idle");
|
|
232
232
|
}
|
|
233
|
-
function
|
|
233
|
+
function V() {
|
|
234
234
|
clearTimeout(t.burstTimer), G(), t.panelOpen || (t.burstTimer = setTimeout(() => {
|
|
235
235
|
t.panelOpen || Q();
|
|
236
236
|
}, Ve));
|
|
237
237
|
}
|
|
238
238
|
function he(d) {
|
|
239
|
-
t.panelOpen = !!d, t.panelOpen ? (clearTimeout(t.burstTimer), G()) :
|
|
239
|
+
t.panelOpen = !!d, t.panelOpen ? (clearTimeout(t.burstTimer), G()) : V();
|
|
240
240
|
}
|
|
241
241
|
async function ce() {
|
|
242
242
|
try {
|
|
@@ -244,13 +244,13 @@ function We(e) {
|
|
|
244
244
|
const S = w == null ? void 0 : w.last_message_at;
|
|
245
245
|
return S && (!y || S > y) ? S : y;
|
|
246
246
|
}, null);
|
|
247
|
-
f && (!t.lastActivityAt || f > t.lastActivityAt) && (t.lastActivityAt = f, i("activity", { conversations: d, latestAt: f }),
|
|
247
|
+
f && (!t.lastActivityAt || f > t.lastActivityAt) && (t.lastActivityAt = f, i("activity", { conversations: d, latestAt: f }), V());
|
|
248
248
|
} catch (d) {
|
|
249
249
|
console.error("[transport] poll failed", d);
|
|
250
250
|
}
|
|
251
251
|
}
|
|
252
252
|
function de() {
|
|
253
|
-
se(), !(typeof document < "u" && document.hidden) && (t.pollTimer = setInterval(ce,
|
|
253
|
+
se(), !(typeof document < "u" && document.hidden) && (t.pollTimer = setInterval(ce, $e));
|
|
254
254
|
}
|
|
255
255
|
function se() {
|
|
256
256
|
t.pollTimer && (clearInterval(t.pollTimer), t.pollTimer = null);
|
|
@@ -305,11 +305,11 @@ function We(e) {
|
|
|
305
305
|
listConversations: T,
|
|
306
306
|
createConversation: E,
|
|
307
307
|
getConversation: A,
|
|
308
|
-
patchConversation:
|
|
308
|
+
patchConversation: q,
|
|
309
309
|
markConversationRead: M,
|
|
310
310
|
listMessages: P,
|
|
311
311
|
postMessage: N,
|
|
312
|
-
postCallback:
|
|
312
|
+
postCallback: H,
|
|
313
313
|
uploadAttachment: W,
|
|
314
314
|
signAttachment: te,
|
|
315
315
|
// Read-only state
|
|
@@ -337,7 +337,7 @@ function Qe() {
|
|
|
337
337
|
return t.slice(0, 4).join("") + "-" + t.slice(4, 6).join("") + "-" + t.slice(6, 8).join("") + "-" + t.slice(8, 10).join("") + "-" + t.slice(10, 16).join("");
|
|
338
338
|
}
|
|
339
339
|
function Xe(e) {
|
|
340
|
-
const t =
|
|
340
|
+
const t = Ue({
|
|
341
341
|
ready: !1,
|
|
342
342
|
error: null,
|
|
343
343
|
config: null,
|
|
@@ -493,8 +493,8 @@ function Xe(e) {
|
|
|
493
493
|
}), y = (_ == null ? void 0 : _.messages) ?? [], w = t.messagesByConv[m] || [], S = /* @__PURE__ */ new Set();
|
|
494
494
|
for (const O of w)
|
|
495
495
|
(O == null ? void 0 : O.id) != null && S.add(`id:${String(O.id)}`), O != null && O.client_msg_id && S.add(`c:${O.client_msg_id}`);
|
|
496
|
-
const
|
|
497
|
-
t.messagesByConv[m] = [...
|
|
496
|
+
const U = y.filter((O) => !((O == null ? void 0 : O.id) != null && S.has(`id:${String(O.id)}`) || O != null && O.client_msg_id && S.has(`c:${O.client_msg_id}`)));
|
|
497
|
+
t.messagesByConv[m] = [...U, ...w], k(m, {
|
|
498
498
|
nextCursor: (_ == null ? void 0 : _.next_cursor) ?? null,
|
|
499
499
|
loading: !1,
|
|
500
500
|
loaded: !0
|
|
@@ -528,8 +528,8 @@ function Xe(e) {
|
|
|
528
528
|
(S == null ? void 0 : S.id) != null && _.add(String(S.id)), S != null && S.client_msg_id && y.add(S.client_msg_id);
|
|
529
529
|
const w = [];
|
|
530
530
|
for (const S of f) {
|
|
531
|
-
const
|
|
532
|
-
Y(m, S),
|
|
531
|
+
const U = (S == null ? void 0 : S.id) != null && _.has(String(S.id)) || (S == null ? void 0 : S.client_msg_id) && y.has(S.client_msg_id);
|
|
532
|
+
Y(m, S), U || w.push(S);
|
|
533
533
|
}
|
|
534
534
|
return w;
|
|
535
535
|
} catch (d) {
|
|
@@ -548,8 +548,8 @@ function Xe(e) {
|
|
|
548
548
|
console.error("[store] markConversationRead failed", g);
|
|
549
549
|
}
|
|
550
550
|
}
|
|
551
|
-
async function
|
|
552
|
-
var
|
|
551
|
+
async function q(m, h, { attachments: g, metadata: d } = {}) {
|
|
552
|
+
var U;
|
|
553
553
|
const f = (h || "").trim(), _ = Array.isArray(g) && g.length > 0;
|
|
554
554
|
if (!m || !f && !_) return;
|
|
555
555
|
const y = Qe(), w = se(m), S = {
|
|
@@ -560,7 +560,7 @@ function Xe(e) {
|
|
|
560
560
|
text_md: f,
|
|
561
561
|
author: {
|
|
562
562
|
type: "user",
|
|
563
|
-
id: ((
|
|
563
|
+
id: ((U = t.customer) == null ? void 0 : U.external_id) || null
|
|
564
564
|
},
|
|
565
565
|
created_at: w,
|
|
566
566
|
// Local-only flag — UI may render dimmed until the SSE echo lands.
|
|
@@ -578,7 +578,7 @@ function Xe(e) {
|
|
|
578
578
|
...d && typeof d == "object" ? { metadata: d } : {}
|
|
579
579
|
});
|
|
580
580
|
} catch (O) {
|
|
581
|
-
console.error("[store] send failed", O),
|
|
581
|
+
console.error("[store] send failed", O), V(m, y, {
|
|
582
582
|
_failed: !0,
|
|
583
583
|
_pending: !1
|
|
584
584
|
});
|
|
@@ -612,7 +612,7 @@ function Xe(e) {
|
|
|
612
612
|
}
|
|
613
613
|
return null;
|
|
614
614
|
}
|
|
615
|
-
async function
|
|
615
|
+
async function H(m, { rating: h, comment: g } = {}) {
|
|
616
616
|
const d = t.conversations.find((y) => y.id === m), _ = {
|
|
617
617
|
...(d == null ? void 0 : d.metadata) || {},
|
|
618
618
|
feedback: {
|
|
@@ -664,15 +664,15 @@ function Xe(e) {
|
|
|
664
664
|
return [];
|
|
665
665
|
if (((f = w == null ? void 0 : w.author) == null ? void 0 : f.type) !== "agent_ia") continue;
|
|
666
666
|
const S = (_ = w == null ? void 0 : w.metadata) == null ? void 0 : _.suggested_replies;
|
|
667
|
-
return Array.isArray(S) && S.length ? S.map((
|
|
668
|
-
if (typeof
|
|
669
|
-
const O =
|
|
667
|
+
return Array.isArray(S) && S.length ? S.map((U) => {
|
|
668
|
+
if (typeof U == "string") {
|
|
669
|
+
const O = U.trim();
|
|
670
670
|
return O ? { label: O, kind: null } : null;
|
|
671
671
|
}
|
|
672
|
-
if (
|
|
673
|
-
const O =
|
|
672
|
+
if (U && typeof U == "object" && typeof U.label == "string") {
|
|
673
|
+
const O = U.label.trim();
|
|
674
674
|
if (!O) return null;
|
|
675
|
-
const Ne =
|
|
675
|
+
const Ne = U.kind === "cta" || U.kind === "choice" || U.kind === "followup" ? U.kind : null;
|
|
676
676
|
return { label: O, kind: Ne };
|
|
677
677
|
}
|
|
678
678
|
return null;
|
|
@@ -698,7 +698,7 @@ function Xe(e) {
|
|
|
698
698
|
function Q(m, h) {
|
|
699
699
|
return m === h ? !0 : m == null || h == null ? !1 : String(m) === String(h);
|
|
700
700
|
}
|
|
701
|
-
function
|
|
701
|
+
function V(m, h, g) {
|
|
702
702
|
const d = t.messagesByConv[m];
|
|
703
703
|
if (!d) return;
|
|
704
704
|
const f = d.findIndex((y) => y.id === h);
|
|
@@ -746,10 +746,10 @@ function Xe(e) {
|
|
|
746
746
|
fetchSinceLast: E,
|
|
747
747
|
patchConversation: T,
|
|
748
748
|
markConversationRead: A,
|
|
749
|
-
send:
|
|
749
|
+
send: q,
|
|
750
750
|
clickCallback: M,
|
|
751
751
|
signAttachment: N,
|
|
752
|
-
submitFeedback:
|
|
752
|
+
submitFeedback: H,
|
|
753
753
|
getPendingApproval: W,
|
|
754
754
|
getActionInFlight: ne,
|
|
755
755
|
getLatestSuggestions: G,
|
|
@@ -782,10 +782,10 @@ const D = {
|
|
|
782
782
|
"#D97706",
|
|
783
783
|
"#059669"
|
|
784
784
|
];
|
|
785
|
-
function
|
|
785
|
+
function pe(e = "") {
|
|
786
786
|
return e ? fe[e.charCodeAt(0) % fe.length] : fe[0];
|
|
787
787
|
}
|
|
788
|
-
function
|
|
788
|
+
function ve(e = "") {
|
|
789
789
|
return e.split(" ").map((t) => t[0] || "").join("").toUpperCase().slice(0, 2);
|
|
790
790
|
}
|
|
791
791
|
function Ie(e = /* @__PURE__ */ new Date(), t = "fr-FR") {
|
|
@@ -837,7 +837,7 @@ const Je = `
|
|
|
837
837
|
0% { transform: translateX(110%); opacity: 0; }
|
|
838
838
|
100% { transform: translateX(0); opacity: 1; }
|
|
839
839
|
}
|
|
840
|
-
`, Ze = "https://api.messenger.victorc.fr", ie = "fr", et = ["fr", "en"],
|
|
840
|
+
`, Ze = "https://api.messenger.victorc.fr", ie = "fr", et = ["fr", "en"], Ce = { fr: "fr-FR", en: "en-US" }, _e = {
|
|
841
841
|
fr: {
|
|
842
842
|
// ── Common ───────────────────────────────────────────────────────
|
|
843
843
|
"common.newConversation": "Nouvelle conversation",
|
|
@@ -1079,16 +1079,16 @@ I reply within seconds.`,
|
|
|
1079
1079
|
"export.createdOn": "Created on: {date}"
|
|
1080
1080
|
}
|
|
1081
1081
|
};
|
|
1082
|
-
function
|
|
1082
|
+
function ye(e) {
|
|
1083
1083
|
if (typeof e != "string") return ie;
|
|
1084
1084
|
const t = e.trim().toLowerCase().slice(0, 2);
|
|
1085
1085
|
return et.includes(t) ? t : ie;
|
|
1086
1086
|
}
|
|
1087
1087
|
function oe(e) {
|
|
1088
|
-
return
|
|
1088
|
+
return Ce[ye(e)] || Ce[ie];
|
|
1089
1089
|
}
|
|
1090
|
-
function
|
|
1091
|
-
const t =
|
|
1090
|
+
function j(e) {
|
|
1091
|
+
const t = ye(e), n = _e[t] || _e[ie], i = _e[ie];
|
|
1092
1092
|
return function(s, a) {
|
|
1093
1093
|
let l = n[s];
|
|
1094
1094
|
return l == null && (l = i[s]), l == null ? s : (a && (l = l.replace(
|
|
@@ -1097,15 +1097,15 @@ function U(e) {
|
|
|
1097
1097
|
)), l);
|
|
1098
1098
|
};
|
|
1099
1099
|
}
|
|
1100
|
-
function
|
|
1100
|
+
function Ae(e, t) {
|
|
1101
1101
|
if (!Array.isArray(e == null ? void 0 : e.options)) return t;
|
|
1102
1102
|
const n = e.options.find((i) => (i == null ? void 0 : i.value) === t);
|
|
1103
1103
|
return (n == null ? void 0 : n.label) || t;
|
|
1104
1104
|
}
|
|
1105
1105
|
function Le(e, t, n) {
|
|
1106
|
-
return Array.isArray(t) ? t.map((i) =>
|
|
1106
|
+
return Array.isArray(t) ? t.map((i) => Ae(e, String(i))).join(", ") : typeof t == "boolean" ? n(t ? "common.yes" : "common.no") : Ae(e, String(t));
|
|
1107
1107
|
}
|
|
1108
|
-
function tt(e, t, n =
|
|
1108
|
+
function tt(e, t, n = j()) {
|
|
1109
1109
|
if (!e || !t) return "";
|
|
1110
1110
|
const i = Array.isArray(e.fields) ? e.fields : [], r = [];
|
|
1111
1111
|
for (const s of i) {
|
|
@@ -1120,7 +1120,7 @@ ${l}`);
|
|
|
1120
1120
|
|
|
1121
1121
|
`);
|
|
1122
1122
|
}
|
|
1123
|
-
function nt(e, t, n =
|
|
1123
|
+
function nt(e, t, n = j()) {
|
|
1124
1124
|
const i = [], r = Array.isArray(e == null ? void 0 : e.fields) ? e.fields : [];
|
|
1125
1125
|
for (const s of r) {
|
|
1126
1126
|
if (!(s != null && s.key) || !(s != null && s.label)) continue;
|
|
@@ -1150,7 +1150,7 @@ function J(e) {
|
|
|
1150
1150
|
const t = typeof e == "number" ? e : Number(e);
|
|
1151
1151
|
return Number.isFinite(t) ? t : null;
|
|
1152
1152
|
}
|
|
1153
|
-
function
|
|
1153
|
+
function Se(e, t) {
|
|
1154
1154
|
let n = (e == null ? void 0 : e.last_message_at) || (e == null ? void 0 : e.updated_at) || (e == null ? void 0 : e.created_at) || "";
|
|
1155
1155
|
for (const i of t)
|
|
1156
1156
|
i != null && i.created_at && i.created_at > n && (n = i.created_at);
|
|
@@ -1190,7 +1190,7 @@ function it(e, t, n, i) {
|
|
|
1190
1190
|
return r.join(`
|
|
1191
1191
|
`);
|
|
1192
1192
|
}
|
|
1193
|
-
function at(e, t, n =
|
|
1193
|
+
function at(e, t, n = j(), i) {
|
|
1194
1194
|
if (!e) return;
|
|
1195
1195
|
const r = it(e, t || [], n, oe(i)), s = new Blob([r], { type: "text/plain;charset=utf-8" });
|
|
1196
1196
|
try {
|
|
@@ -1634,17 +1634,17 @@ const B = (e, t) => {
|
|
|
1634
1634
|
},
|
|
1635
1635
|
computed: {
|
|
1636
1636
|
bg() {
|
|
1637
|
-
return this.avatarUrl ? "transparent" :
|
|
1637
|
+
return this.avatarUrl ? "transparent" : pe(this.name);
|
|
1638
1638
|
},
|
|
1639
1639
|
initials() {
|
|
1640
|
-
return
|
|
1640
|
+
return ve(this.name);
|
|
1641
1641
|
}
|
|
1642
1642
|
}
|
|
1643
1643
|
}, yt = ["src", "alt"];
|
|
1644
1644
|
function bt(e, t, n, i, r, s) {
|
|
1645
1645
|
return c(), u("div", {
|
|
1646
1646
|
class: x(["wm-huav", { "wm-huav--tail": n.tail }]),
|
|
1647
|
-
style:
|
|
1647
|
+
style: z({
|
|
1648
1648
|
width: n.size + "px",
|
|
1649
1649
|
height: n.size + "px",
|
|
1650
1650
|
"--wm-avr": Math.round(n.size * 0.32) + "px",
|
|
@@ -1657,7 +1657,7 @@ function bt(e, t, n, i, r, s) {
|
|
|
1657
1657
|
alt: n.name || ""
|
|
1658
1658
|
}, null, 8, yt)) : (c(), u("span", {
|
|
1659
1659
|
key: 1,
|
|
1660
|
-
style:
|
|
1660
|
+
style: z({ fontSize: n.size * 0.36 + "px" })
|
|
1661
1661
|
}, v(s.initials), 5))
|
|
1662
1662
|
], 6);
|
|
1663
1663
|
}
|
|
@@ -1667,7 +1667,7 @@ const Be = /* @__PURE__ */ B(vt, [["render", bt], ["__scopeId", "data-v-14e10c0d
|
|
|
1667
1667
|
inject: {
|
|
1668
1668
|
// Translator shared by the Messenger shell; French fallback when
|
|
1669
1669
|
// the component is used standalone.
|
|
1670
|
-
t: { default: () =>
|
|
1670
|
+
t: { default: () => j() }
|
|
1671
1671
|
},
|
|
1672
1672
|
props: {
|
|
1673
1673
|
// Nombre de conversations non lues — pilote la pastille.
|
|
@@ -1688,19 +1688,19 @@ const Be = /* @__PURE__ */ B(vt, [["render", bt], ["__scopeId", "data-v-14e10c0d
|
|
|
1688
1688
|
}
|
|
1689
1689
|
}
|
|
1690
1690
|
}, Ct = { class: "wm-launcherWrap" }, At = ["aria-label", "onClick", "onKeydown"], St = ["aria-label", "onClick"], Mt = { class: "wm-peek__avatar" }, Tt = ["aria-label"], xt = { class: "wm-peek__body" }, Ot = { class: "wm-peek__head" }, It = { class: "wm-peek__name" }, Lt = { class: "wm-peek__action" }, Bt = { class: "wm-peek__text" }, Et = ["onClick"], Rt = ["aria-label"], Nt = ["aria-label"];
|
|
1691
|
-
function
|
|
1691
|
+
function Ut(e, t, n, i, r, s) {
|
|
1692
1692
|
const a = L("HumanAvatar");
|
|
1693
1693
|
return c(), u("div", Ct, [
|
|
1694
|
-
|
|
1695
|
-
default:
|
|
1694
|
+
$(Fe, { name: "wm-peek" }, {
|
|
1695
|
+
default: je(() => [
|
|
1696
1696
|
s.visiblePeeks.length ? (c(), u("div", {
|
|
1697
1697
|
key: 0,
|
|
1698
1698
|
class: x(["wm-peekStack", { "wm-peekStack--multi": s.visiblePeeks.length > 1 }])
|
|
1699
1699
|
}, [
|
|
1700
|
-
(c(!0), u(I, null,
|
|
1700
|
+
(c(!0), u(I, null, F(s.visiblePeeks, (l, p) => (c(), u("div", {
|
|
1701
1701
|
key: l.convId,
|
|
1702
1702
|
class: "wm-peek",
|
|
1703
|
-
style:
|
|
1703
|
+
style: z({
|
|
1704
1704
|
"--depth": s.visiblePeeks.length - 1 - p,
|
|
1705
1705
|
zIndex: p + 1
|
|
1706
1706
|
}),
|
|
@@ -1736,7 +1736,7 @@ function Ft(e, t, n, i, r, s) {
|
|
|
1736
1736
|
], -1)
|
|
1737
1737
|
])], 8, St),
|
|
1738
1738
|
o("div", Mt, [
|
|
1739
|
-
|
|
1739
|
+
$(a, {
|
|
1740
1740
|
name: l.senderName,
|
|
1741
1741
|
"avatar-url": l.senderAvatarUrl,
|
|
1742
1742
|
size: 34
|
|
@@ -1795,7 +1795,7 @@ function Ft(e, t, n, i, r, s) {
|
|
|
1795
1795
|
], 8, Rt)
|
|
1796
1796
|
]);
|
|
1797
1797
|
}
|
|
1798
|
-
const
|
|
1798
|
+
const Ft = /* @__PURE__ */ B(kt, [["render", Ut], ["__scopeId", "data-v-5193a529"]]), jt = {
|
|
1799
1799
|
name: "WmAIAvatar",
|
|
1800
1800
|
props: {
|
|
1801
1801
|
size: { type: Number, default: 26 },
|
|
@@ -1806,19 +1806,32 @@ const jt = /* @__PURE__ */ B(kt, [["render", Ft], ["__scopeId", "data-v-5193a529
|
|
|
1806
1806
|
// (Header, Onboarding, ApprovalCard, FormCard…) → laissé à false
|
|
1807
1807
|
// pour garder l'avatar pleinement arrondi.
|
|
1808
1808
|
tail: { type: Boolean, default: !1 },
|
|
1809
|
+
// Nom de l'agent IA. Quand renseigné (et sans `imageUrl`), rend
|
|
1810
|
+
// les initiales sur fond déterministe à partir du nom — même
|
|
1811
|
+
// logique que `HumanAvatar` pour les agents humains. L'étoile SVG
|
|
1812
|
+
// ne reste que comme fallback si ni `imageUrl` ni `name`.
|
|
1813
|
+
name: { type: String, default: "" },
|
|
1809
1814
|
// Image distante (avatar de l'agent ou `default_icon_url` du
|
|
1810
|
-
// widget). Quand renseignée, remplace
|
|
1811
|
-
// le même container arrondi.
|
|
1815
|
+
// widget). Quand renseignée, remplace les initiales / l'étoile
|
|
1816
|
+
// par l'image dans le même container arrondi.
|
|
1812
1817
|
imageUrl: { type: String, default: null }
|
|
1818
|
+
},
|
|
1819
|
+
computed: {
|
|
1820
|
+
initials() {
|
|
1821
|
+
return ve(this.name);
|
|
1822
|
+
},
|
|
1823
|
+
bgColor() {
|
|
1824
|
+
return pe(this.name);
|
|
1825
|
+
}
|
|
1813
1826
|
}
|
|
1814
1827
|
}, Pt = {
|
|
1815
1828
|
key: 0,
|
|
1816
1829
|
class: "wm-aiav__pulse"
|
|
1817
|
-
}, Dt = ["src"],
|
|
1818
|
-
function
|
|
1830
|
+
}, Dt = ["src", "alt"], Ht = ["width", "height"];
|
|
1831
|
+
function zt(e, t, n, i, r, s) {
|
|
1819
1832
|
return c(), u("div", {
|
|
1820
1833
|
class: x(["wm-aiav", { "wm-aiav--tail": n.tail }]),
|
|
1821
|
-
style:
|
|
1834
|
+
style: z({
|
|
1822
1835
|
width: n.size + "px",
|
|
1823
1836
|
height: n.size + "px",
|
|
1824
1837
|
"--wm-avr": n.size * 0.32 + "px"
|
|
@@ -1828,15 +1841,22 @@ function Ht(e, t, n, i, r, s) {
|
|
|
1828
1841
|
o("div", {
|
|
1829
1842
|
class: x(["wm-aiav__inner", {
|
|
1830
1843
|
"wm-aiav__inner--glow": n.pulse,
|
|
1831
|
-
"wm-aiav__inner--img": !!n.imageUrl
|
|
1832
|
-
|
|
1844
|
+
"wm-aiav__inner--img": !!n.imageUrl,
|
|
1845
|
+
"wm-aiav__inner--initials": !n.imageUrl && !!s.initials
|
|
1846
|
+
}]),
|
|
1847
|
+
style: z(
|
|
1848
|
+
!n.imageUrl && s.initials ? { background: s.bgColor } : null
|
|
1849
|
+
)
|
|
1833
1850
|
}, [
|
|
1834
1851
|
n.imageUrl ? (c(), u("img", {
|
|
1835
1852
|
key: 0,
|
|
1836
1853
|
src: n.imageUrl,
|
|
1837
|
-
alt: ""
|
|
1838
|
-
}, null, 8, Dt)) : (c(), u("
|
|
1854
|
+
alt: n.name || ""
|
|
1855
|
+
}, null, 8, Dt)) : s.initials ? (c(), u("span", {
|
|
1839
1856
|
key: 1,
|
|
1857
|
+
style: z({ fontSize: n.size * 0.36 + "px" })
|
|
1858
|
+
}, v(s.initials), 5)) : (c(), u("svg", {
|
|
1859
|
+
key: 2,
|
|
1840
1860
|
width: n.size * 0.5,
|
|
1841
1861
|
height: n.size * 0.5,
|
|
1842
1862
|
viewBox: "0 0 24 24",
|
|
@@ -1862,11 +1882,11 @@ function Ht(e, t, n, i, r, s) {
|
|
|
1862
1882
|
fill: "white",
|
|
1863
1883
|
opacity: "0.38"
|
|
1864
1884
|
}, null, -1)
|
|
1865
|
-
])], 8,
|
|
1866
|
-
],
|
|
1885
|
+
])], 8, Ht))
|
|
1886
|
+
], 6)
|
|
1867
1887
|
], 6);
|
|
1868
1888
|
}
|
|
1869
|
-
const le = /* @__PURE__ */ B(
|
|
1889
|
+
const le = /* @__PURE__ */ B(jt, [["render", zt], ["__scopeId", "data-v-a91a2925"]]), qt = {
|
|
1870
1890
|
name: "WmTeamAvatars",
|
|
1871
1891
|
props: {
|
|
1872
1892
|
members: { type: Array, default: () => [] },
|
|
@@ -1882,13 +1902,13 @@ const le = /* @__PURE__ */ B(Ut, [["render", Ht], ["__scopeId", "data-v-99d8093a
|
|
|
1882
1902
|
},
|
|
1883
1903
|
methods: {
|
|
1884
1904
|
colorFor(e) {
|
|
1885
|
-
return e.avatar_url ? "transparent" :
|
|
1905
|
+
return e.avatar_url ? "transparent" : pe(e.name || "");
|
|
1886
1906
|
},
|
|
1887
1907
|
initialsFor(e) {
|
|
1888
|
-
return
|
|
1908
|
+
return ve(e.name || "");
|
|
1889
1909
|
}
|
|
1890
1910
|
}
|
|
1891
|
-
},
|
|
1911
|
+
}, $t = {
|
|
1892
1912
|
key: 0,
|
|
1893
1913
|
class: "wm-team"
|
|
1894
1914
|
}, Vt = ["src", "alt"], Kt = { key: 1 }, Wt = {
|
|
@@ -1896,15 +1916,15 @@ const le = /* @__PURE__ */ B(Ut, [["render", Ht], ["__scopeId", "data-v-99d8093a
|
|
|
1896
1916
|
class: "wm-team__label"
|
|
1897
1917
|
};
|
|
1898
1918
|
function Gt(e, t, n, i, r, s) {
|
|
1899
|
-
return s.visible ? (c(), u("div",
|
|
1919
|
+
return s.visible ? (c(), u("div", $t, [
|
|
1900
1920
|
o("div", {
|
|
1901
1921
|
class: "wm-team__stack",
|
|
1902
|
-
style:
|
|
1922
|
+
style: z({ width: s.stackWidth + "px" })
|
|
1903
1923
|
}, [
|
|
1904
|
-
(c(!0), u(I, null,
|
|
1924
|
+
(c(!0), u(I, null, F(n.members.slice(0, 3), (a, l) => (c(), u("div", {
|
|
1905
1925
|
key: l,
|
|
1906
1926
|
class: "wm-team__pill",
|
|
1907
|
-
style:
|
|
1927
|
+
style: z({
|
|
1908
1928
|
left: l * 13 + "px",
|
|
1909
1929
|
zIndex: 3 - l,
|
|
1910
1930
|
background: s.colorFor(a)
|
|
@@ -1926,7 +1946,7 @@ const Yt = /* @__PURE__ */ B(qt, [["render", Gt], ["__scopeId", "data-v-e49a9063
|
|
|
1926
1946
|
inject: {
|
|
1927
1947
|
// Translator shared by the Messenger shell. Falls back to a French
|
|
1928
1948
|
// translator when the component is used standalone (no provider).
|
|
1929
|
-
t: { default: () =>
|
|
1949
|
+
t: { default: () => j() }
|
|
1930
1950
|
},
|
|
1931
1951
|
props: {
|
|
1932
1952
|
title: { type: String, default: "Nouvelle conversation" },
|
|
@@ -1939,6 +1959,7 @@ const Yt = /* @__PURE__ */ B(qt, [["render", Gt], ["__scopeId", "data-v-e49a9063
|
|
|
1939
1959
|
// When false (welcome / no conversation) the avatar + title + status
|
|
1940
1960
|
// block is hidden so the header stays a minimal action bar.
|
|
1941
1961
|
showIdentity: { type: Boolean, default: !0 },
|
|
1962
|
+
agentName: { type: String, default: "" },
|
|
1942
1963
|
agentAvatarUrl: { type: String, default: null }
|
|
1943
1964
|
},
|
|
1944
1965
|
emits: ["back", "close", "more"],
|
|
@@ -1991,10 +2012,11 @@ function ln(e, t, n, i, r, s) {
|
|
|
1991
2012
|
])], 8, Jt)) : (c(), u("div", Zt)),
|
|
1992
2013
|
n.showIdentity ? (c(), u(I, { key: 2 }, [
|
|
1993
2014
|
o("div", en, [
|
|
1994
|
-
|
|
2015
|
+
$(a, {
|
|
1995
2016
|
size: 30,
|
|
2017
|
+
name: n.agentName,
|
|
1996
2018
|
"image-url": n.agentAvatarUrl
|
|
1997
|
-
}, null, 8, ["image-url"])
|
|
2019
|
+
}, null, 8, ["name", "image-url"])
|
|
1998
2020
|
]),
|
|
1999
2021
|
o("div", tn, [
|
|
2000
2022
|
o("div", nn, v(n.title), 1)
|
|
@@ -2063,20 +2085,20 @@ function ln(e, t, n, i, r, s) {
|
|
|
2063
2085
|
])
|
|
2064
2086
|
]);
|
|
2065
2087
|
}
|
|
2066
|
-
const cn = /* @__PURE__ */ B(Qt, [["render", ln], ["__scopeId", "data-v-
|
|
2088
|
+
const cn = /* @__PURE__ */ B(Qt, [["render", ln], ["__scopeId", "data-v-925c9e94"]]);
|
|
2067
2089
|
function Ee(e) {
|
|
2068
2090
|
return String(e).replace(/&/g, "&").replace(/</g, "<").replace(/>/g, ">").replace(/"/g, """).replace(/'/g, "'");
|
|
2069
2091
|
}
|
|
2070
2092
|
function dn(e) {
|
|
2071
2093
|
return /^(https?:\/\/|mailto:|tel:)/i.test(String(e).trim());
|
|
2072
2094
|
}
|
|
2073
|
-
const
|
|
2095
|
+
const Me = "";
|
|
2074
2096
|
function re(e) {
|
|
2075
2097
|
let t = e;
|
|
2076
2098
|
const n = [];
|
|
2077
2099
|
return t = t.replace(/`([^`\n]+)`/g, (i, r) => {
|
|
2078
2100
|
const s = n.length;
|
|
2079
|
-
return n.push(r), `${
|
|
2101
|
+
return n.push(r), `${Me}CODE${s}${Me}`;
|
|
2080
2102
|
}), t = t.replace(/\[([^\]\n]+)\]\(([^)\s]+)\)/g, (i, r, s) => dn(s) ? `<a href="${s}" target="_blank" rel="noopener noreferrer">${r}</a>` : r), t = t.replace(/\*\*([^\n*][^\n]*?)\*\*/g, "<strong>$1</strong>"), t = t.replace(/__([^\n_][^\n]*?)__/g, "<u>$1</u>"), t = t.replace(/~~([^\n~][^\n]*?)~~/g, "<s>$1</s>"), t = t.replace(/(^|[^\w*])\*([^\n*]+?)\*(?!\w)/g, "$1<em>$2</em>"), t = t.replace(/(^|[^\w_])_([^\n_]+?)_(?!\w)/g, "$1<em>$2</em>"), t = t.replace(/CODE(\d+)/g, (i, r) => `<code class="wm-md-code">${n[+r]}</code>`), t;
|
|
2081
2103
|
}
|
|
2082
2104
|
function un(e) {
|
|
@@ -2153,7 +2175,7 @@ function mn(e) {
|
|
|
2153
2175
|
}
|
|
2154
2176
|
return r;
|
|
2155
2177
|
}
|
|
2156
|
-
const
|
|
2178
|
+
const Te = {
|
|
2157
2179
|
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",
|
|
2158
2180
|
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",
|
|
2159
2181
|
status: "M9 12l2 2 4-4m6 2a9 9 0 11-18 0 9 9 0 0118 0z",
|
|
@@ -2165,7 +2187,7 @@ const Se = {
|
|
|
2165
2187
|
inject: {
|
|
2166
2188
|
// Translator + resolved-language getter shared by the Messenger
|
|
2167
2189
|
// shell. Fall back to French wording when used standalone.
|
|
2168
|
-
t: { default: () =>
|
|
2190
|
+
t: { default: () => j() },
|
|
2169
2191
|
wmLocale: { default: () => () => "fr" }
|
|
2170
2192
|
},
|
|
2171
2193
|
props: {
|
|
@@ -2203,7 +2225,7 @@ const Se = {
|
|
|
2203
2225
|
},
|
|
2204
2226
|
methods: {
|
|
2205
2227
|
iconPath(e) {
|
|
2206
|
-
return
|
|
2228
|
+
return Te[e] || Te.link;
|
|
2207
2229
|
},
|
|
2208
2230
|
renderPreview(e) {
|
|
2209
2231
|
return un(e);
|
|
@@ -2247,22 +2269,23 @@ const Se = {
|
|
|
2247
2269
|
}, On = {
|
|
2248
2270
|
key: 1,
|
|
2249
2271
|
class: "wm-onb__section"
|
|
2250
|
-
}, In = { class: "wm-onb__section-title" }, Ln = { class: "wm-onb__search" }, Bn = ["placeholder", "aria-label"], En = { class: "wm-onb__list" }, Rn = ["onClick"], Nn = ["aria-label"],
|
|
2272
|
+
}, In = { class: "wm-onb__section-title" }, Ln = { class: "wm-onb__search" }, Bn = ["placeholder", "aria-label"], En = { class: "wm-onb__list" }, Rn = ["onClick"], Nn = ["aria-label"], Un = { class: "wm-onb__thread-body" }, Fn = { class: "wm-onb__thread-title" }, jn = ["innerHTML"], Pn = { class: "wm-onb__thread-meta" }, Dn = {
|
|
2251
2273
|
key: 0,
|
|
2252
2274
|
class: "wm-onb__thread-time"
|
|
2253
|
-
},
|
|
2275
|
+
}, Hn = {
|
|
2254
2276
|
key: 0,
|
|
2255
2277
|
class: "wm-onb__empty"
|
|
2256
2278
|
};
|
|
2257
|
-
function
|
|
2279
|
+
function zn(e, t, n, i, r, s) {
|
|
2258
2280
|
const a = L("AIAvatar");
|
|
2259
2281
|
return c(), u("div", fn, [
|
|
2260
2282
|
o("div", _n, [
|
|
2261
|
-
|
|
2283
|
+
$(a, {
|
|
2262
2284
|
size: 56,
|
|
2263
2285
|
pulse: !0,
|
|
2286
|
+
name: n.agentName,
|
|
2264
2287
|
"image-url": n.defaultIconUrl
|
|
2265
|
-
}, null, 8, ["image-url"]),
|
|
2288
|
+
}, null, 8, ["name", "image-url"]),
|
|
2266
2289
|
o("div", gn, v(s.heroTitle), 1),
|
|
2267
2290
|
o("div", pn, v(s.heroSub), 1)
|
|
2268
2291
|
]),
|
|
@@ -2296,7 +2319,7 @@ function Hn(e, t, n, i, r, s) {
|
|
|
2296
2319
|
o("div", {
|
|
2297
2320
|
class: x(s.quickLinksLayout)
|
|
2298
2321
|
}, [
|
|
2299
|
-
(c(!0), u(I, null,
|
|
2322
|
+
(c(!0), u(I, null, F(n.quickLinks, (l, p) => (c(), u("button", {
|
|
2300
2323
|
key: p,
|
|
2301
2324
|
type: "button",
|
|
2302
2325
|
class: x(["wm-onb__card", { "wm-onb__card--row": s.isOddQuickLinks }]),
|
|
@@ -2334,7 +2357,7 @@ function Hn(e, t, n, i, r, s) {
|
|
|
2334
2357
|
o("path", { d: "M21 21l-4.35-4.35M11 17a6 6 0 100-12 6 6 0 000 12z" })
|
|
2335
2358
|
])
|
|
2336
2359
|
], -1)),
|
|
2337
|
-
|
|
2360
|
+
K(o("input", {
|
|
2338
2361
|
"onUpdate:modelValue": t[1] || (t[1] = (l) => r.query = l),
|
|
2339
2362
|
type: "text",
|
|
2340
2363
|
placeholder: s.t("onboarding.search"),
|
|
@@ -2344,7 +2367,7 @@ function Hn(e, t, n, i, r, s) {
|
|
|
2344
2367
|
])
|
|
2345
2368
|
]),
|
|
2346
2369
|
o("div", En, [
|
|
2347
|
-
(c(!0), u(I, null,
|
|
2370
|
+
(c(!0), u(I, null, F(s.filteredThreads, (l) => (c(), u("button", {
|
|
2348
2371
|
key: l.id,
|
|
2349
2372
|
type: "button",
|
|
2350
2373
|
class: "wm-onb__thread",
|
|
@@ -2372,12 +2395,12 @@ function Hn(e, t, n, i, r, s) {
|
|
|
2372
2395
|
"aria-label": s.t("onboarding.unread")
|
|
2373
2396
|
}, null, 8, Nn)) : b("", !0)
|
|
2374
2397
|
], 2),
|
|
2375
|
-
o("span",
|
|
2376
|
-
o("span",
|
|
2398
|
+
o("span", Un, [
|
|
2399
|
+
o("span", Fn, v(l.title), 1),
|
|
2377
2400
|
o("span", {
|
|
2378
2401
|
class: "wm-onb__thread-preview",
|
|
2379
2402
|
innerHTML: s.renderPreview(l.preview)
|
|
2380
|
-
}, null, 8,
|
|
2403
|
+
}, null, 8, jn)
|
|
2381
2404
|
]),
|
|
2382
2405
|
o("span", Pn, [
|
|
2383
2406
|
s.formatTs(l._ts) ? (c(), u("span", Dn, v(s.formatTs(l._ts)), 1)) : b("", !0),
|
|
@@ -2397,13 +2420,13 @@ function Hn(e, t, n, i, r, s) {
|
|
|
2397
2420
|
], -1))
|
|
2398
2421
|
])
|
|
2399
2422
|
], 8, Rn))), 128)),
|
|
2400
|
-
s.filteredThreads.length ? b("", !0) : (c(), u("div",
|
|
2423
|
+
s.filteredThreads.length ? b("", !0) : (c(), u("div", Hn, v(s.t("onboarding.noResults", { query: r.query })), 1))
|
|
2401
2424
|
])
|
|
2402
2425
|
])) : b("", !0)
|
|
2403
2426
|
]);
|
|
2404
2427
|
}
|
|
2405
|
-
const qn = /* @__PURE__ */ B(hn, [["render",
|
|
2406
|
-
function
|
|
2428
|
+
const qn = /* @__PURE__ */ B(hn, [["render", zn], ["__scopeId", "data-v-8d8bd2ac"]]);
|
|
2429
|
+
function $n(e) {
|
|
2407
2430
|
return typeof e != "string" ? "" : e.replace(/`([^`]+)`/g, "$1").replace(/\*\*([^*]+)\*\*/g, "$1").replace(new RegExp("(?<!\\*)\\*([^*]+)\\*(?!\\*)", "g"), "$1").replace(/__([^_]+)__/g, "$1").replace(/\[([^\]]+)\]\([^)]+\)/g, "$1").replace(/\s+/g, " ").trim();
|
|
2408
2431
|
}
|
|
2409
2432
|
const Vn = {
|
|
@@ -2416,7 +2439,7 @@ const Vn = {
|
|
|
2416
2439
|
},
|
|
2417
2440
|
computed: {
|
|
2418
2441
|
detailText() {
|
|
2419
|
-
return
|
|
2442
|
+
return $n(this.detail);
|
|
2420
2443
|
}
|
|
2421
2444
|
}
|
|
2422
2445
|
}, Kn = {
|
|
@@ -2512,7 +2535,7 @@ const ts = /* @__PURE__ */ B(Vn, [["render", es], ["__scopeId", "data-v-7284acd0
|
|
|
2512
2535
|
inject: {
|
|
2513
2536
|
// Translator shared by the Messenger shell; French fallback when
|
|
2514
2537
|
// the component is used standalone.
|
|
2515
|
-
t: { default: () =>
|
|
2538
|
+
t: { default: () => j() }
|
|
2516
2539
|
},
|
|
2517
2540
|
props: {
|
|
2518
2541
|
data: { type: Object, required: !0 }
|
|
@@ -2546,7 +2569,7 @@ function cs(e, t, n, i, r, s) {
|
|
|
2546
2569
|
])
|
|
2547
2570
|
]),
|
|
2548
2571
|
o("div", os, [
|
|
2549
|
-
(c(!0), u(I, null,
|
|
2572
|
+
(c(!0), u(I, null, F(s.fields, (a, l) => (c(), u("div", {
|
|
2550
2573
|
key: l,
|
|
2551
2574
|
class: "wm-art__field"
|
|
2552
2575
|
}, [
|
|
@@ -2613,7 +2636,7 @@ function ks(e, t, n, i, r, s) {
|
|
|
2613
2636
|
]),
|
|
2614
2637
|
s.hasBody ? (c(), u("div", ys, [
|
|
2615
2638
|
n.data.body ? (c(), u("div", bs, v(n.data.body), 1)) : b("", !0),
|
|
2616
|
-
s.fields.length ? (c(!0), u(I, { key: 1 },
|
|
2639
|
+
s.fields.length ? (c(!0), u(I, { key: 1 }, F(s.fields, (a, l) => (c(), u("div", {
|
|
2617
2640
|
key: l,
|
|
2618
2641
|
class: "wm-art__field"
|
|
2619
2642
|
}, [
|
|
@@ -2648,7 +2671,7 @@ const Ss = {
|
|
|
2648
2671
|
inject: {
|
|
2649
2672
|
// Translator + resolved-language getter shared by the Messenger
|
|
2650
2673
|
// shell. Fall back to French wording when used standalone.
|
|
2651
|
-
t: { default: () =>
|
|
2674
|
+
t: { default: () => j() },
|
|
2652
2675
|
wmLocale: { default: () => () => "fr" }
|
|
2653
2676
|
},
|
|
2654
2677
|
props: {
|
|
@@ -2707,11 +2730,11 @@ const Ss = {
|
|
|
2707
2730
|
"stroke-linecap": "round",
|
|
2708
2731
|
"stroke-linejoin": "round",
|
|
2709
2732
|
"aria-hidden": "true"
|
|
2710
|
-
},
|
|
2733
|
+
}, Us = {
|
|
2711
2734
|
key: 1,
|
|
2712
2735
|
class: "wm-art__footer wm-tk__footer"
|
|
2713
2736
|
};
|
|
2714
|
-
function
|
|
2737
|
+
function Fs(e, t, n, i, r, s) {
|
|
2715
2738
|
return c(), u("div", Ms, [
|
|
2716
2739
|
o("div", Ts, [
|
|
2717
2740
|
o("div", xs, v(n.data.title), 1),
|
|
@@ -2750,7 +2773,7 @@ function js(e, t, n, i, r, s) {
|
|
|
2750
2773
|
n.data.body ? (c(), u("div", Ls, v(n.data.body), 1)) : b("", !0)
|
|
2751
2774
|
]),
|
|
2752
2775
|
s.fields.length ? (c(), u("div", Bs, [
|
|
2753
|
-
(c(!0), u(I, null,
|
|
2776
|
+
(c(!0), u(I, null, F(s.fields, (a, l) => (c(), u("div", {
|
|
2754
2777
|
key: l,
|
|
2755
2778
|
class: "wm-art__field"
|
|
2756
2779
|
}, [
|
|
@@ -2805,7 +2828,7 @@ function js(e, t, n, i, r, s) {
|
|
|
2805
2828
|
], 2)
|
|
2806
2829
|
]))), 128))
|
|
2807
2830
|
])) : b("", !0),
|
|
2808
|
-
n.data.created_at ? (c(), u("div",
|
|
2831
|
+
n.data.created_at ? (c(), u("div", Us, [
|
|
2809
2832
|
t[4] || (t[4] = o("svg", {
|
|
2810
2833
|
width: "11",
|
|
2811
2834
|
height: "11",
|
|
@@ -2830,10 +2853,10 @@ function js(e, t, n, i, r, s) {
|
|
|
2830
2853
|
])) : b("", !0)
|
|
2831
2854
|
]);
|
|
2832
2855
|
}
|
|
2833
|
-
const
|
|
2856
|
+
const js = /* @__PURE__ */ B(Ss, [["render", Fs], ["__scopeId", "data-v-5f30c914"]]), Ps = {
|
|
2834
2857
|
form_response: ds,
|
|
2835
2858
|
info_card: Cs,
|
|
2836
|
-
ticket:
|
|
2859
|
+
ticket: js
|
|
2837
2860
|
}, Ds = {
|
|
2838
2861
|
name: "WmArtifactRenderer",
|
|
2839
2862
|
props: {
|
|
@@ -2849,19 +2872,19 @@ const Us = /* @__PURE__ */ B(Ss, [["render", js], ["__scopeId", "data-v-5f30c914
|
|
|
2849
2872
|
}
|
|
2850
2873
|
}
|
|
2851
2874
|
};
|
|
2852
|
-
function
|
|
2875
|
+
function Hs(e, t, n, i, r, s) {
|
|
2853
2876
|
return s.component ? (c(), R(Pe(s.component), {
|
|
2854
2877
|
key: 0,
|
|
2855
2878
|
data: n.artifact.data
|
|
2856
2879
|
}, null, 8, ["data"])) : b("", !0);
|
|
2857
2880
|
}
|
|
2858
|
-
const
|
|
2881
|
+
const zs = /* @__PURE__ */ B(Ds, [["render", Hs]]), qs = {
|
|
2859
2882
|
name: "WmAttachmentPreview",
|
|
2860
2883
|
inject: {
|
|
2861
2884
|
signAttachmentFn: { default: null },
|
|
2862
2885
|
// Translator shared by the Messenger shell; French fallback when
|
|
2863
2886
|
// the component is used standalone.
|
|
2864
|
-
t: { default: () =>
|
|
2887
|
+
t: { default: () => j() }
|
|
2865
2888
|
},
|
|
2866
2889
|
props: {
|
|
2867
2890
|
attachment: { type: Object, required: !0 }
|
|
@@ -2919,7 +2942,7 @@ const Hs = /* @__PURE__ */ B(Ds, [["render", $s]]), qs = {
|
|
|
2919
2942
|
this.url || e.preventDefault();
|
|
2920
2943
|
}
|
|
2921
2944
|
}
|
|
2922
|
-
},
|
|
2945
|
+
}, $s = ["href"], Vs = ["src", "alt"], Ks = ["src"], Ws = ["src"], Gs = ["href", "download"], Ys = { class: "wm-att__main" }, Qs = { class: "wm-att__name" }, Xs = {
|
|
2923
2946
|
key: 0,
|
|
2924
2947
|
class: "wm-att__meta"
|
|
2925
2948
|
}, Js = {
|
|
@@ -2943,7 +2966,7 @@ function Zs(e, t, n, i, r, s) {
|
|
|
2943
2966
|
alt: s.displayName,
|
|
2944
2967
|
loading: "lazy"
|
|
2945
2968
|
}, null, 8, Vs)
|
|
2946
|
-
], 8,
|
|
2969
|
+
], 8, $s)) : s.kind === "audio" && r.url ? (c(), u("audio", {
|
|
2947
2970
|
key: 1,
|
|
2948
2971
|
src: r.url,
|
|
2949
2972
|
controls: "",
|
|
@@ -3036,12 +3059,12 @@ const cr = {
|
|
|
3036
3059
|
Typing: lr,
|
|
3037
3060
|
ActionResult: ts,
|
|
3038
3061
|
AttachmentPreview: er,
|
|
3039
|
-
ArtifactRenderer:
|
|
3062
|
+
ArtifactRenderer: zs
|
|
3040
3063
|
},
|
|
3041
3064
|
inject: {
|
|
3042
3065
|
// Translator + resolved-language getter shared by the Messenger
|
|
3043
3066
|
// shell. Fall back to French wording when used standalone.
|
|
3044
|
-
t: { default: () =>
|
|
3067
|
+
t: { default: () => j() },
|
|
3045
3068
|
wmLocale: { default: () => () => "fr" }
|
|
3046
3069
|
},
|
|
3047
3070
|
props: {
|
|
@@ -3421,9 +3444,9 @@ const cr = {
|
|
|
3421
3444
|
// doit garder son arrondi.
|
|
3422
3445
|
cornersFor(e, t) {
|
|
3423
3446
|
var te, ne, G;
|
|
3424
|
-
const n = e.items, i = (te = n[t]) == null ? void 0 : te.kind, r = (ne = n[t - 1]) == null ? void 0 : ne.kind, s = (G = n[t + 1]) == null ? void 0 : G.kind, a = e.role === "user", l = 14, p = 4, C = r == null ? void 0 : r.bottom, k = s == null ? void 0 : s.top, T = this.widthByKey[this.rowKeyOf(e, t)], E = this.widthByKey[this.rowKeyOf(e, t - 1)], A = this.widthByKey[this.rowKeyOf(e, t + 1)],
|
|
3425
|
-
let P = l, N = l,
|
|
3426
|
-
return a ? (C && (N = p), (k || !s) && (
|
|
3447
|
+
const n = e.items, i = (te = n[t]) == null ? void 0 : te.kind, r = (ne = n[t - 1]) == null ? void 0 : ne.kind, s = (G = n[t + 1]) == null ? void 0 : G.kind, a = e.role === "user", l = 14, p = 4, C = r == null ? void 0 : r.bottom, k = s == null ? void 0 : s.top, T = this.widthByKey[this.rowKeyOf(e, t)], E = this.widthByKey[this.rowKeyOf(e, t - 1)], A = this.widthByKey[this.rowKeyOf(e, t + 1)], q = 0.5, M = (Y, Q, V) => Y != null && T != null ? Y + q >= T : Q === V || Q === "card" && V === "bubble";
|
|
3448
|
+
let P = l, N = l, H = l, W = l;
|
|
3449
|
+
return a ? (C && (N = p), (k || !s) && (H = p), C && M(E, C, i == null ? void 0 : i.top) && (P = p), k && M(A, k, i == null ? void 0 : i.bottom) && (W = p)) : (C && (P = p), (k || !s) && (W = p), C && M(E, C, i == null ? void 0 : i.top) && (N = p), k && M(A, k, i == null ? void 0 : i.bottom) && (H = p)), { tl: P, tr: N, br: H, bl: W };
|
|
3427
3450
|
},
|
|
3428
3451
|
// Inline style emitting the four corner CSS variables. Set on
|
|
3429
3452
|
// `.wm-list__row` so they cascade to Bubble/ActionResult/
|
|
@@ -3593,7 +3616,7 @@ function Ir(e, t, n, i, r, s) {
|
|
|
3593
3616
|
o("span", pr, v(n.dateLabel), 1),
|
|
3594
3617
|
t[3] || (t[3] = o("div", { class: "wm-list__line" }, null, -1))
|
|
3595
3618
|
])) : b("", !0),
|
|
3596
|
-
(c(!0), u(I, null,
|
|
3619
|
+
(c(!0), u(I, null, F(s.groups, (A, q) => (c(), u(I, {
|
|
3597
3620
|
key: A.key
|
|
3598
3621
|
}, [
|
|
3599
3622
|
A.key === s.unreadGroupKey ? (c(), u("div", vr, [
|
|
@@ -3610,7 +3633,7 @@ function Ir(e, t, n, i, r, s) {
|
|
|
3610
3633
|
o("span", wr, v(A.systemLabel), 1),
|
|
3611
3634
|
t[7] || (t[7] = o("div", { class: "wm-list__line wm-list__line--strong" }, null, -1))
|
|
3612
3635
|
])) : (c(), u(I, { key: 1 }, [
|
|
3613
|
-
(c(!0), u(I, null,
|
|
3636
|
+
(c(!0), u(I, null, F(A.items, (M, P) => (c(), u("div", {
|
|
3614
3637
|
key: `${s.messageKey(M.message)}-${M.partKey}`,
|
|
3615
3638
|
"data-row-key": `${s.messageKey(M.message)}-${M.partKey}`,
|
|
3616
3639
|
class: x(["wm-list__row fade-up", [
|
|
@@ -3620,7 +3643,7 @@ function Ir(e, t, n, i, r, s) {
|
|
|
3620
3643
|
"is-failed": M.message._failed
|
|
3621
3644
|
}
|
|
3622
3645
|
]]),
|
|
3623
|
-
style:
|
|
3646
|
+
style: z(s.cornersStyle(A, P))
|
|
3624
3647
|
}, [
|
|
3625
3648
|
A.role !== "user" ? (c(), u("div", Cr, [
|
|
3626
3649
|
P === A.items.length - 1 ? (c(), u(I, { key: 0 }, [
|
|
@@ -3628,8 +3651,9 @@ function Ir(e, t, n, i, r, s) {
|
|
|
3628
3651
|
key: 0,
|
|
3629
3652
|
size: 26,
|
|
3630
3653
|
tail: !0,
|
|
3654
|
+
name: n.aiAgentName,
|
|
3631
3655
|
"image-url": n.aiAgentAvatarUrl
|
|
3632
|
-
}, null, 8, ["image-url"])) : (c(), R(l, {
|
|
3656
|
+
}, null, 8, ["name", "image-url"])) : (c(), R(l, {
|
|
3633
3657
|
key: 1,
|
|
3634
3658
|
name: A.agentName,
|
|
3635
3659
|
"avatar-url": A.agentAvatarUrl,
|
|
@@ -3666,10 +3690,10 @@ function Ir(e, t, n, i, r, s) {
|
|
|
3666
3690
|
"wm-list__atts--align-end": A.role === "user"
|
|
3667
3691
|
}])
|
|
3668
3692
|
}, [
|
|
3669
|
-
(c(!0), u(I, null,
|
|
3693
|
+
(c(!0), u(I, null, F(s.attachmentsOf(
|
|
3670
3694
|
M.message
|
|
3671
|
-
), (N,
|
|
3672
|
-
key: `${s.messageKey(M.message)}-att-${
|
|
3695
|
+
), (N, H) => (c(), R(T, {
|
|
3696
|
+
key: `${s.messageKey(M.message)}-att-${H}`,
|
|
3673
3697
|
attachment: N
|
|
3674
3698
|
}, null, 8, ["attachment"]))), 128))
|
|
3675
3699
|
], 2)) : b("", !0)
|
|
@@ -3688,19 +3712,20 @@ function Ir(e, t, n, i, r, s) {
|
|
|
3688
3712
|
], 64))), 128)),
|
|
3689
3713
|
n.streamingActive ? (c(), u("div", xr, [
|
|
3690
3714
|
o("div", Or, [
|
|
3691
|
-
|
|
3715
|
+
$(a, {
|
|
3692
3716
|
size: 26,
|
|
3693
3717
|
tail: !0,
|
|
3718
|
+
name: n.aiAgentName,
|
|
3694
3719
|
"image-url": n.aiAgentAvatarUrl
|
|
3695
|
-
}, null, 8, ["image-url"])
|
|
3720
|
+
}, null, 8, ["name", "image-url"])
|
|
3696
3721
|
]),
|
|
3697
|
-
|
|
3722
|
+
$(E)
|
|
3698
3723
|
])) : b("", !0)
|
|
3699
3724
|
], 34);
|
|
3700
3725
|
}
|
|
3701
|
-
const Lr = /* @__PURE__ */ B(mr, [["render", Ir], ["__scopeId", "data-v-
|
|
3726
|
+
const Lr = /* @__PURE__ */ B(mr, [["render", Ir], ["__scopeId", "data-v-d769b193"]]), me = typeof navigator < "u" && !!navigator.mediaDevices && typeof navigator.mediaDevices.getDisplayMedia == "function", be = typeof window < "u" && typeof window.MediaRecorder < "u";
|
|
3702
3727
|
function Br() {
|
|
3703
|
-
return
|
|
3728
|
+
return be && [
|
|
3704
3729
|
"video/webm;codecs=vp9,opus",
|
|
3705
3730
|
"video/webm;codecs=vp8,opus",
|
|
3706
3731
|
"video/webm",
|
|
@@ -3719,7 +3744,7 @@ function Re({ audio: e }) {
|
|
|
3719
3744
|
systemAudio: e ? "include" : "exclude"
|
|
3720
3745
|
};
|
|
3721
3746
|
}
|
|
3722
|
-
function
|
|
3747
|
+
function Ha(e) {
|
|
3723
3748
|
return e ? e.startsWith("image/") ? "image" : e.startsWith("video/") ? "video" : "file" : "file";
|
|
3724
3749
|
}
|
|
3725
3750
|
async function Er() {
|
|
@@ -3757,7 +3782,7 @@ async function Rr(e) {
|
|
|
3757
3782
|
}
|
|
3758
3783
|
async function Nr(e = {}) {
|
|
3759
3784
|
var C;
|
|
3760
|
-
if (!me || !
|
|
3785
|
+
if (!me || !be) return null;
|
|
3761
3786
|
let t;
|
|
3762
3787
|
try {
|
|
3763
3788
|
t = await navigator.mediaDevices.getDisplayMedia(
|
|
@@ -3784,7 +3809,7 @@ async function Nr(e = {}) {
|
|
|
3784
3809
|
if (s && clearInterval(s), t.getTracks().forEach((E) => {
|
|
3785
3810
|
E.stop();
|
|
3786
3811
|
}), r.length) {
|
|
3787
|
-
const E = i.mimeType || n || "video/webm", A = new Blob(r, { type: E }),
|
|
3812
|
+
const E = i.mimeType || n || "video/webm", A = new Blob(r, { type: E }), q = /mp4/.test(E) ? "mp4" : "webm", M = (/* @__PURE__ */ new Date()).toISOString().replace(/[:.]/g, "-").slice(0, 19), P = new File([A], `ecran-${M}.${q}`, {
|
|
3788
3813
|
type: E
|
|
3789
3814
|
});
|
|
3790
3815
|
(k = e.onfinalize) == null || k.call(e, P);
|
|
@@ -3820,7 +3845,7 @@ async function Nr(e = {}) {
|
|
|
3820
3845
|
}
|
|
3821
3846
|
};
|
|
3822
3847
|
}
|
|
3823
|
-
const
|
|
3848
|
+
const Ur = [
|
|
3824
3849
|
{
|
|
3825
3850
|
action: "file",
|
|
3826
3851
|
labelKey: "composer.attachFile",
|
|
@@ -3836,12 +3861,12 @@ const Fr = [
|
|
|
3836
3861
|
labelKey: "composer.recordScreen",
|
|
3837
3862
|
path: "M23 7l-7 5 7 5V7z M1 5a2 2 0 012-2h12a2 2 0 012 2v14a2 2 0 01-2 2H3a2 2 0 01-2-2V5z"
|
|
3838
3863
|
}
|
|
3839
|
-
],
|
|
3864
|
+
], Fr = {
|
|
3840
3865
|
name: "WmComposer",
|
|
3841
3866
|
inject: {
|
|
3842
3867
|
// Translator shared by the Messenger shell; French fallback when
|
|
3843
3868
|
// the component is used standalone.
|
|
3844
|
-
t: { default: () =>
|
|
3869
|
+
t: { default: () => j() }
|
|
3845
3870
|
},
|
|
3846
3871
|
props: {
|
|
3847
3872
|
modelValue: { type: String, default: "" },
|
|
@@ -3864,10 +3889,10 @@ const Fr = [
|
|
|
3864
3889
|
return !this.disabled && !!this.local.trim();
|
|
3865
3890
|
},
|
|
3866
3891
|
attachItems() {
|
|
3867
|
-
return
|
|
3892
|
+
return Ur.map((e) => ({
|
|
3868
3893
|
...e,
|
|
3869
3894
|
label: this.t(e.labelKey),
|
|
3870
|
-
disabled: e.action === "screenshot" && !me || e.action === "record" && (!me || !
|
|
3895
|
+
disabled: e.action === "screenshot" && !me || e.action === "record" && (!me || !be)
|
|
3871
3896
|
}));
|
|
3872
3897
|
},
|
|
3873
3898
|
recordingElapsedLabel() {
|
|
@@ -3968,21 +3993,21 @@ const Fr = [
|
|
|
3968
3993
|
}
|
|
3969
3994
|
}
|
|
3970
3995
|
}
|
|
3971
|
-
},
|
|
3996
|
+
}, jr = { class: "wm-compose-wrap" }, Pr = {
|
|
3972
3997
|
key: 0,
|
|
3973
3998
|
class: "wm-rec"
|
|
3974
|
-
}, Dr = { class: "wm-rec__lbl" },
|
|
3999
|
+
}, Dr = { class: "wm-rec__lbl" }, Hr = {
|
|
3975
4000
|
key: 1,
|
|
3976
4001
|
class: "wm-compose__menu",
|
|
3977
4002
|
role: "menu"
|
|
3978
|
-
},
|
|
4003
|
+
}, zr = ["disabled", "onClick"], qr = { class: "wm-compose__menuIcon" }, $r = {
|
|
3979
4004
|
viewBox: "0 0 24 24",
|
|
3980
4005
|
width: "14",
|
|
3981
4006
|
height: "14",
|
|
3982
4007
|
"aria-hidden": "true"
|
|
3983
4008
|
}, Vr = ["d"], Kr = ["placeholder", "disabled"], Wr = { class: "wm-compose__actions" }, Gr = ["title", "aria-label", "disabled"], Yr = ["disabled", "aria-label"];
|
|
3984
4009
|
function Qr(e, t, n, i, r, s) {
|
|
3985
|
-
return c(), u("div",
|
|
4010
|
+
return c(), u("div", jr, [
|
|
3986
4011
|
r.recording ? (c(), u("div", Pr, [
|
|
3987
4012
|
t[8] || (t[8] = o("span", {
|
|
3988
4013
|
class: "wm-rec__dot",
|
|
@@ -4011,8 +4036,8 @@ function Qr(e, t, n, i, r, s) {
|
|
|
4011
4036
|
class: "wm-compose__overlay",
|
|
4012
4037
|
onClick: t[2] || (t[2] = (a) => r.attachOpen = !1)
|
|
4013
4038
|
})) : b("", !0),
|
|
4014
|
-
r.attachOpen ? (c(), u("div",
|
|
4015
|
-
(c(!0), u(I, null,
|
|
4039
|
+
r.attachOpen ? (c(), u("div", Hr, [
|
|
4040
|
+
(c(!0), u(I, null, F(s.attachItems, (a) => (c(), u("button", {
|
|
4016
4041
|
key: a.action,
|
|
4017
4042
|
type: "button",
|
|
4018
4043
|
class: "wm-compose__menuItem",
|
|
@@ -4020,7 +4045,7 @@ function Qr(e, t, n, i, r, s) {
|
|
|
4020
4045
|
onClick: (l) => s.onAttachAction(a.action)
|
|
4021
4046
|
}, [
|
|
4022
4047
|
o("span", qr, [
|
|
4023
|
-
(c(), u("svg",
|
|
4048
|
+
(c(), u("svg", $r, [
|
|
4024
4049
|
o("path", {
|
|
4025
4050
|
d: a.path,
|
|
4026
4051
|
stroke: "currentColor",
|
|
@@ -4032,9 +4057,9 @@ function Qr(e, t, n, i, r, s) {
|
|
|
4032
4057
|
]))
|
|
4033
4058
|
]),
|
|
4034
4059
|
o("span", null, v(a.label), 1)
|
|
4035
|
-
], 8,
|
|
4060
|
+
], 8, zr))), 128))
|
|
4036
4061
|
])) : b("", !0),
|
|
4037
|
-
|
|
4062
|
+
K(o("textarea", {
|
|
4038
4063
|
ref: "inputEl",
|
|
4039
4064
|
"onUpdate:modelValue": t[3] || (t[3] = (a) => r.local = a),
|
|
4040
4065
|
class: "wm-compose__input",
|
|
@@ -4093,7 +4118,7 @@ function Qr(e, t, n, i, r, s) {
|
|
|
4093
4118
|
], 34)
|
|
4094
4119
|
]);
|
|
4095
4120
|
}
|
|
4096
|
-
const Xr = /* @__PURE__ */ B(
|
|
4121
|
+
const Xr = /* @__PURE__ */ B(Fr, [["render", Qr], ["__scopeId", "data-v-aa81dbb8"]]), Jr = {
|
|
4097
4122
|
name: "WmSuggestionChips",
|
|
4098
4123
|
props: {
|
|
4099
4124
|
items: { type: Array, default: () => [] },
|
|
@@ -4116,11 +4141,11 @@ function ei(e, t, n, i, r, s) {
|
|
|
4116
4141
|
key: s.batchKey,
|
|
4117
4142
|
class: "wm-chips"
|
|
4118
4143
|
}, [
|
|
4119
|
-
(c(!0), u(I, null,
|
|
4144
|
+
(c(!0), u(I, null, F(n.items, (a, l) => (c(), u("button", {
|
|
4120
4145
|
key: l,
|
|
4121
4146
|
type: "button",
|
|
4122
4147
|
class: "wm-chip",
|
|
4123
|
-
style:
|
|
4148
|
+
style: z({ animationDelay: n.baseDelay + l * n.stepDelay + "ms" }),
|
|
4124
4149
|
onClick: (p) => e.$emit("select", a)
|
|
4125
4150
|
}, v(a.label), 13, Zr))), 128))
|
|
4126
4151
|
])) : b("", !0);
|
|
@@ -4131,12 +4156,14 @@ const ti = /* @__PURE__ */ B(Jr, [["render", ei], ["__scopeId", "data-v-47ad8085
|
|
|
4131
4156
|
inject: {
|
|
4132
4157
|
// Translator shared by the Messenger shell; French fallback when
|
|
4133
4158
|
// the component is used standalone.
|
|
4134
|
-
t: { default: () =>
|
|
4159
|
+
t: { default: () => j() }
|
|
4135
4160
|
},
|
|
4136
4161
|
props: {
|
|
4137
4162
|
action: { type: String, required: !0 },
|
|
4138
4163
|
detail: { type: String, default: "" },
|
|
4139
|
-
callbacks: { type: Array, default: () => [] }
|
|
4164
|
+
callbacks: { type: Array, default: () => [] },
|
|
4165
|
+
agentName: { type: String, default: "" },
|
|
4166
|
+
agentAvatarUrl: { type: String, default: null }
|
|
4140
4167
|
},
|
|
4141
4168
|
emits: ["callback"],
|
|
4142
4169
|
computed: {
|
|
@@ -4176,7 +4203,11 @@ function di(e, t, n, i, r, s) {
|
|
|
4176
4203
|
return c(), u("div", si, [
|
|
4177
4204
|
o("div", ri, [
|
|
4178
4205
|
o("div", ii, [
|
|
4179
|
-
|
|
4206
|
+
$(a, {
|
|
4207
|
+
size: 24,
|
|
4208
|
+
name: n.agentName,
|
|
4209
|
+
"image-url": n.agentAvatarUrl
|
|
4210
|
+
}, null, 8, ["name", "image-url"])
|
|
4180
4211
|
]),
|
|
4181
4212
|
o("div", ai, [
|
|
4182
4213
|
o("div", oi, v(n.action), 1),
|
|
@@ -4199,8 +4230,8 @@ function di(e, t, n, i, r, s) {
|
|
|
4199
4230
|
])
|
|
4200
4231
|
]);
|
|
4201
4232
|
}
|
|
4202
|
-
const ui = /* @__PURE__ */ B(ni, [["render", di], ["__scopeId", "data-v-
|
|
4203
|
-
let
|
|
4233
|
+
const ui = /* @__PURE__ */ B(ni, [["render", di], ["__scopeId", "data-v-a2bed37e"]]);
|
|
4234
|
+
let xe = 0;
|
|
4204
4235
|
const mi = /* @__PURE__ */ new Set([
|
|
4205
4236
|
"text",
|
|
4206
4237
|
"textarea",
|
|
@@ -4215,17 +4246,19 @@ const mi = /* @__PURE__ */ new Set([
|
|
|
4215
4246
|
inject: {
|
|
4216
4247
|
// Translator shared by the Messenger shell; French fallback when
|
|
4217
4248
|
// the component is used standalone.
|
|
4218
|
-
t: { default: () =>
|
|
4249
|
+
t: { default: () => j() }
|
|
4219
4250
|
},
|
|
4220
4251
|
props: {
|
|
4221
4252
|
form: { type: Object, required: !0 },
|
|
4222
4253
|
readOnly: { type: Boolean, default: !1 },
|
|
4223
|
-
initialValues: { type: Object, default: null }
|
|
4254
|
+
initialValues: { type: Object, default: null },
|
|
4255
|
+
agentName: { type: String, default: "" },
|
|
4256
|
+
agentAvatarUrl: { type: String, default: null }
|
|
4224
4257
|
},
|
|
4225
4258
|
emits: ["submit"],
|
|
4226
4259
|
data() {
|
|
4227
|
-
return
|
|
4228
|
-
_uid:
|
|
4260
|
+
return xe += 1, {
|
|
4261
|
+
_uid: xe,
|
|
4229
4262
|
values: {},
|
|
4230
4263
|
busy: !1,
|
|
4231
4264
|
error: ""
|
|
@@ -4313,16 +4346,20 @@ const mi = /* @__PURE__ */ new Set([
|
|
|
4313
4346
|
key: 0,
|
|
4314
4347
|
class: "wm-form__spinner",
|
|
4315
4348
|
"aria-hidden": "true"
|
|
4316
|
-
},
|
|
4349
|
+
}, Ui = {
|
|
4317
4350
|
key: 2,
|
|
4318
4351
|
class: "wm-form__doneLbl"
|
|
4319
4352
|
};
|
|
4320
|
-
function
|
|
4353
|
+
function Fi(e, t, n, i, r, s) {
|
|
4321
4354
|
const a = L("AIAvatar");
|
|
4322
4355
|
return c(), u("div", fi, [
|
|
4323
4356
|
o("div", _i, [
|
|
4324
4357
|
o("div", gi, [
|
|
4325
|
-
|
|
4358
|
+
$(a, {
|
|
4359
|
+
size: 24,
|
|
4360
|
+
name: n.agentName,
|
|
4361
|
+
"image-url": n.agentAvatarUrl
|
|
4362
|
+
}, null, 8, ["name", "image-url"])
|
|
4326
4363
|
]),
|
|
4327
4364
|
o("div", pi, [
|
|
4328
4365
|
o("div", vi, v(n.form.title || s.t("form.title")), 1),
|
|
@@ -4333,7 +4370,7 @@ function ji(e, t, n, i, r, s) {
|
|
|
4333
4370
|
class: "wm-form__body",
|
|
4334
4371
|
onSubmit: t[0] || (t[0] = X((...l) => s.onSubmit && s.onSubmit(...l), ["prevent"]))
|
|
4335
4372
|
}, [
|
|
4336
|
-
(c(!0), u(I, null,
|
|
4373
|
+
(c(!0), u(I, null, F(s.normalizedFields, (l) => (c(), u("div", {
|
|
4337
4374
|
key: l.key,
|
|
4338
4375
|
class: "wm-form__field"
|
|
4339
4376
|
}, [
|
|
@@ -4344,7 +4381,7 @@ function ji(e, t, n, i, r, s) {
|
|
|
4344
4381
|
ge(v(l.label), 1),
|
|
4345
4382
|
l.required ? (c(), u("span", wi, "*")) : b("", !0)
|
|
4346
4383
|
], 8, bi),
|
|
4347
|
-
l.type === "text" ?
|
|
4384
|
+
l.type === "text" ? K((c(), u("input", {
|
|
4348
4385
|
key: 0,
|
|
4349
4386
|
id: `wm-f-${r._uid}-${l.key}`,
|
|
4350
4387
|
"onUpdate:modelValue": (p) => r.values[l.key] = p,
|
|
@@ -4355,7 +4392,7 @@ function ji(e, t, n, i, r, s) {
|
|
|
4355
4392
|
disabled: n.readOnly || r.busy
|
|
4356
4393
|
}, null, 8, ki)), [
|
|
4357
4394
|
[ee, r.values[l.key]]
|
|
4358
|
-
]) : l.type === "textarea" ?
|
|
4395
|
+
]) : l.type === "textarea" ? K((c(), u("textarea", {
|
|
4359
4396
|
key: 1,
|
|
4360
4397
|
id: `wm-f-${r._uid}-${l.key}`,
|
|
4361
4398
|
"onUpdate:modelValue": (p) => r.values[l.key] = p,
|
|
@@ -4366,7 +4403,7 @@ function ji(e, t, n, i, r, s) {
|
|
|
4366
4403
|
disabled: n.readOnly || r.busy
|
|
4367
4404
|
}, null, 8, Ci)), [
|
|
4368
4405
|
[ee, r.values[l.key]]
|
|
4369
|
-
]) : l.type === "number" ?
|
|
4406
|
+
]) : l.type === "number" ? K((c(), u("input", {
|
|
4370
4407
|
key: 2,
|
|
4371
4408
|
id: `wm-f-${r._uid}-${l.key}`,
|
|
4372
4409
|
"onUpdate:modelValue": (p) => r.values[l.key] = p,
|
|
@@ -4382,7 +4419,7 @@ function ji(e, t, n, i, r, s) {
|
|
|
4382
4419
|
void 0,
|
|
4383
4420
|
{ number: !0 }
|
|
4384
4421
|
]
|
|
4385
|
-
]) : l.type === "date" ?
|
|
4422
|
+
]) : l.type === "date" ? K((c(), u("input", {
|
|
4386
4423
|
key: 3,
|
|
4387
4424
|
id: `wm-f-${r._uid}-${l.key}`,
|
|
4388
4425
|
"onUpdate:modelValue": (p) => r.values[l.key] = p,
|
|
@@ -4393,16 +4430,16 @@ function ji(e, t, n, i, r, s) {
|
|
|
4393
4430
|
}, null, 8, Si)), [
|
|
4394
4431
|
[ee, r.values[l.key]]
|
|
4395
4432
|
]) : l.type === "boolean" ? (c(), u("label", Mi, [
|
|
4396
|
-
|
|
4433
|
+
K(o("input", {
|
|
4397
4434
|
id: `wm-f-${r._uid}-${l.key}`,
|
|
4398
4435
|
"onUpdate:modelValue": (p) => r.values[l.key] = p,
|
|
4399
4436
|
type: "checkbox",
|
|
4400
4437
|
disabled: n.readOnly || r.busy
|
|
4401
4438
|
}, null, 8, Ti), [
|
|
4402
|
-
[
|
|
4439
|
+
[He, r.values[l.key]]
|
|
4403
4440
|
]),
|
|
4404
4441
|
o("span", null, v(l.placeholder || s.t("common.yes")), 1)
|
|
4405
|
-
])) : l.type === "select" ?
|
|
4442
|
+
])) : l.type === "select" ? K((c(), u("select", {
|
|
4406
4443
|
key: 5,
|
|
4407
4444
|
id: `wm-f-${r._uid}-${l.key}`,
|
|
4408
4445
|
"onUpdate:modelValue": (p) => r.values[l.key] = p,
|
|
@@ -4411,14 +4448,14 @@ function ji(e, t, n, i, r, s) {
|
|
|
4411
4448
|
disabled: n.readOnly || r.busy
|
|
4412
4449
|
}, [
|
|
4413
4450
|
o("option", Oi, v(l.placeholder || s.t("form.choose")), 1),
|
|
4414
|
-
(c(!0), u(I, null,
|
|
4451
|
+
(c(!0), u(I, null, F(l.options, (p) => (c(), u("option", {
|
|
4415
4452
|
key: p.value,
|
|
4416
4453
|
value: p.value
|
|
4417
4454
|
}, v(p.label), 9, Ii))), 128))
|
|
4418
4455
|
], 8, xi)), [
|
|
4419
|
-
[
|
|
4456
|
+
[ze, r.values[l.key]]
|
|
4420
4457
|
]) : l.type === "multiselect" ? (c(), u("div", Li, [
|
|
4421
|
-
(c(!0), u(I, null,
|
|
4458
|
+
(c(!0), u(I, null, F(l.options, (p) => (c(), u("label", {
|
|
4422
4459
|
key: p.value,
|
|
4423
4460
|
class: "wm-form__multiItem"
|
|
4424
4461
|
}, [
|
|
@@ -4438,7 +4475,7 @@ function ji(e, t, n, i, r, s) {
|
|
|
4438
4475
|
])) : b("", !0)
|
|
4439
4476
|
]))), 128)),
|
|
4440
4477
|
r.error ? (c(), u("div", Ei, v(r.error), 1)) : b("", !0),
|
|
4441
|
-
n.readOnly ? (c(), u("div",
|
|
4478
|
+
n.readOnly ? (c(), u("div", Ui, v(s.t("form.responseSent")), 1)) : (c(), u("button", {
|
|
4442
4479
|
key: 1,
|
|
4443
4480
|
type: "submit",
|
|
4444
4481
|
class: "wm-form__submit",
|
|
@@ -4450,12 +4487,12 @@ function ji(e, t, n, i, r, s) {
|
|
|
4450
4487
|
], 32)
|
|
4451
4488
|
]);
|
|
4452
4489
|
}
|
|
4453
|
-
const
|
|
4490
|
+
const ji = /* @__PURE__ */ B(hi, [["render", Fi], ["__scopeId", "data-v-fe65cc56"]]), Pi = {
|
|
4454
4491
|
name: "WmFeedback",
|
|
4455
4492
|
inject: {
|
|
4456
4493
|
// Translator shared by the Messenger shell; French fallback when
|
|
4457
4494
|
// the component is used standalone.
|
|
4458
|
-
t: { default: () =>
|
|
4495
|
+
t: { default: () => j() }
|
|
4459
4496
|
},
|
|
4460
4497
|
props: {
|
|
4461
4498
|
busy: { type: Boolean, default: !1 },
|
|
@@ -4484,7 +4521,7 @@ const Ui = /* @__PURE__ */ B(hi, [["render", ji], ["__scopeId", "data-v-75332dad
|
|
|
4484
4521
|
!this.sel || this.busy || this.$emit("submit", { rating: this.sel });
|
|
4485
4522
|
}
|
|
4486
4523
|
}
|
|
4487
|
-
}, Di = { class: "wm-fb" },
|
|
4524
|
+
}, Di = { class: "wm-fb" }, Hi = { class: "wm-fb__title" }, zi = { class: "wm-fb__sub" }, qi = { class: "wm-fb__row" }, $i = ["onClick"], Vi = { class: "wm-fb__emoji" }, Ki = { class: "wm-fb__label" }, Wi = ["disabled"], Gi = {
|
|
4488
4525
|
key: 1,
|
|
4489
4526
|
class: "wm-fb__done"
|
|
4490
4527
|
}, Yi = { class: "wm-fb__doneTitle" }, Qi = { class: "wm-fb__doneSub" };
|
|
@@ -4509,10 +4546,10 @@ function Xi(e, t, n, i, r, s) {
|
|
|
4509
4546
|
o("div", Yi, v(s.t("feedback.doneTitle")), 1),
|
|
4510
4547
|
o("div", Qi, v(s.t("feedback.doneSubtitle")), 1)
|
|
4511
4548
|
])) : (c(), u(I, { key: 0 }, [
|
|
4512
|
-
o("div",
|
|
4513
|
-
o("div",
|
|
4549
|
+
o("div", Hi, v(s.t("feedback.question")), 1),
|
|
4550
|
+
o("div", zi, v(s.t("feedback.subtitle")), 1),
|
|
4514
4551
|
o("div", qi, [
|
|
4515
|
-
(c(!0), u(I, null,
|
|
4552
|
+
(c(!0), u(I, null, F(s.options, (a) => (c(), u("button", {
|
|
4516
4553
|
key: a.v,
|
|
4517
4554
|
type: "button",
|
|
4518
4555
|
class: x(["wm-fb__opt", { "is-selected": r.sel === a.v }]),
|
|
@@ -4520,7 +4557,7 @@ function Xi(e, t, n, i, r, s) {
|
|
|
4520
4557
|
}, [
|
|
4521
4558
|
o("span", Vi, v(a.e), 1),
|
|
4522
4559
|
o("span", Ki, v(a.l), 1)
|
|
4523
|
-
], 10,
|
|
4560
|
+
], 10, $i))), 128))
|
|
4524
4561
|
]),
|
|
4525
4562
|
o("button", {
|
|
4526
4563
|
type: "button",
|
|
@@ -4536,7 +4573,7 @@ const Ji = /* @__PURE__ */ B(Pi, [["render", Xi], ["__scopeId", "data-v-9b630564
|
|
|
4536
4573
|
inject: {
|
|
4537
4574
|
// Translator shared by the Messenger shell; French fallback when
|
|
4538
4575
|
// the component is used standalone.
|
|
4539
|
-
t: { default: () =>
|
|
4576
|
+
t: { default: () => j() }
|
|
4540
4577
|
},
|
|
4541
4578
|
props: {
|
|
4542
4579
|
canRename: { type: Boolean, default: !0 },
|
|
@@ -4756,7 +4793,7 @@ const ha = /* @__PURE__ */ B(Zi, [["render", ma], ["__scopeId", "data-v-76281e95
|
|
|
4756
4793
|
inject: {
|
|
4757
4794
|
// Translator shared by the Messenger shell; French fallback when
|
|
4758
4795
|
// the component is used standalone.
|
|
4759
|
-
t: { default: () =>
|
|
4796
|
+
t: { default: () => j() }
|
|
4760
4797
|
},
|
|
4761
4798
|
props: {
|
|
4762
4799
|
// Empty defaults: the resolved fallback comes from the translator
|
|
@@ -4829,7 +4866,7 @@ function Aa(e, t, n, i, r, s) {
|
|
|
4829
4866
|
])], 8, ya)
|
|
4830
4867
|
]),
|
|
4831
4868
|
o("div", ba, [
|
|
4832
|
-
|
|
4869
|
+
K(o("input", {
|
|
4833
4870
|
ref: "input",
|
|
4834
4871
|
"onUpdate:modelValue": t[2] || (t[2] = (a) => r.value = a),
|
|
4835
4872
|
type: "text",
|
|
@@ -4860,17 +4897,17 @@ function Aa(e, t, n, i, r, s) {
|
|
|
4860
4897
|
])
|
|
4861
4898
|
]);
|
|
4862
4899
|
}
|
|
4863
|
-
const Sa = /* @__PURE__ */ B(fa, [["render", Aa], ["__scopeId", "data-v-6d5f94a8"]]),
|
|
4900
|
+
const Sa = /* @__PURE__ */ B(fa, [["render", Aa], ["__scopeId", "data-v-6d5f94a8"]]), Oe = "ww-messenger-tokens", Ma = {
|
|
4864
4901
|
name: "Messenger",
|
|
4865
4902
|
components: {
|
|
4866
|
-
Launcher:
|
|
4903
|
+
Launcher: Ft,
|
|
4867
4904
|
Header: cn,
|
|
4868
4905
|
Onboarding: qn,
|
|
4869
4906
|
MessageList: Lr,
|
|
4870
4907
|
Composer: Xr,
|
|
4871
4908
|
SuggestionChips: ti,
|
|
4872
4909
|
ApprovalCard: ui,
|
|
4873
|
-
FormCard:
|
|
4910
|
+
FormCard: ji,
|
|
4874
4911
|
Feedback: Ji,
|
|
4875
4912
|
MoreMenu: ha,
|
|
4876
4913
|
RenameDialog: Sa
|
|
@@ -4994,7 +5031,7 @@ const Sa = /* @__PURE__ */ B(fa, [["render", Aa], ["__scopeId", "data-v-6d5f94a8
|
|
|
4994
5031
|
// 4. French.
|
|
4995
5032
|
locale() {
|
|
4996
5033
|
var e;
|
|
4997
|
-
return
|
|
5034
|
+
return ye(
|
|
4998
5035
|
this.language || this.customerLanguage || ((e = this.widget) == null ? void 0 : e.default_language) || ""
|
|
4999
5036
|
);
|
|
5000
5037
|
},
|
|
@@ -5002,7 +5039,7 @@ const Sa = /* @__PURE__ */ B(fa, [["render", Aa], ["__scopeId", "data-v-6d5f94a8
|
|
|
5002
5039
|
// `locale` changes. `t()` below (and the provided closure) delegate
|
|
5003
5040
|
// to it so every string resolves against the current language.
|
|
5004
5041
|
translator() {
|
|
5005
|
-
return
|
|
5042
|
+
return j(this.locale);
|
|
5006
5043
|
},
|
|
5007
5044
|
error() {
|
|
5008
5045
|
var e;
|
|
@@ -5074,7 +5111,7 @@ const Sa = /* @__PURE__ */ B(fa, [["render", Aa], ["__scopeId", "data-v-6d5f94a8
|
|
|
5074
5111
|
title: n.name || this.t("common.newConversation"),
|
|
5075
5112
|
preview: n._preview || this.t("onboarding.newMessage"),
|
|
5076
5113
|
unread: !!n._unread,
|
|
5077
|
-
_ts:
|
|
5114
|
+
_ts: Se(n, e[n.id] || [])
|
|
5078
5115
|
})).sort((n, i) => n._ts < i._ts ? 1 : n._ts > i._ts ? -1 : 0);
|
|
5079
5116
|
},
|
|
5080
5117
|
// Unread threads (one entry per conv with unseen agent/human
|
|
@@ -5086,7 +5123,7 @@ const Sa = /* @__PURE__ */ B(fa, [["render", Aa], ["__scopeId", "data-v-6d5f94a8
|
|
|
5086
5123
|
const e = ((n = this.s) == null ? void 0 : n.messagesByConv) || {}, t = [];
|
|
5087
5124
|
for (const i of this.drawerConversations) {
|
|
5088
5125
|
if (!i._unread) continue;
|
|
5089
|
-
const r =
|
|
5126
|
+
const r = Se(i, e[i.id] || []), s = i._lastAuthor, a = !s || s.type === "agent_ia", l = (s == null ? void 0 : s.name) || (a ? this.agentName : "") || "", p = (s == null ? void 0 : s.avatar_url) || (a ? this.agentAvatarUrl : null);
|
|
5090
5127
|
t.push({
|
|
5091
5128
|
convId: i.id,
|
|
5092
5129
|
preview: i._preview || this.t("notification.youHaveNewMessage"),
|
|
@@ -5423,9 +5460,9 @@ const Sa = /* @__PURE__ */ B(fa, [["render", Aa], ["__scopeId", "data-v-6d5f94a8
|
|
|
5423
5460
|
}
|
|
5424
5461
|
},
|
|
5425
5462
|
async mounted() {
|
|
5426
|
-
if (typeof document < "u" && !document.getElementById(
|
|
5463
|
+
if (typeof document < "u" && !document.getElementById(Oe)) {
|
|
5427
5464
|
const e = document.createElement("style");
|
|
5428
|
-
e.id =
|
|
5465
|
+
e.id = Oe, e.textContent = Je, document.head.appendChild(e);
|
|
5429
5466
|
}
|
|
5430
5467
|
await this.boot(), this.isEmbedded && this.store && await this.open();
|
|
5431
5468
|
},
|
|
@@ -5447,14 +5484,14 @@ const Sa = /* @__PURE__ */ B(fa, [["render", Aa], ["__scopeId", "data-v-6d5f94a8
|
|
|
5447
5484
|
return;
|
|
5448
5485
|
}
|
|
5449
5486
|
try {
|
|
5450
|
-
this.transport =
|
|
5487
|
+
this.transport = we(
|
|
5451
5488
|
We({
|
|
5452
5489
|
baseUrl: this.baseUrl,
|
|
5453
5490
|
widgetId: this.widgetId,
|
|
5454
5491
|
userId: this.userId,
|
|
5455
5492
|
userHash: this.userHash
|
|
5456
5493
|
})
|
|
5457
|
-
), this.store =
|
|
5494
|
+
), this.store = we(Xe(this.transport)), this.hydrateNotifPref(), await this.store.start(), this.setupLiveReveal();
|
|
5458
5495
|
const t = (e = this.context) == null ? void 0 : e.customer;
|
|
5459
5496
|
t && typeof t == "object" && await this.store.applyCustomer(t);
|
|
5460
5497
|
} catch (t) {
|
|
@@ -5731,12 +5768,12 @@ const Sa = /* @__PURE__ */ B(fa, [["render", Aa], ["__scopeId", "data-v-6d5f94a8
|
|
|
5731
5768
|
class: "wm-actionWait",
|
|
5732
5769
|
role: "status",
|
|
5733
5770
|
"aria-live": "polite"
|
|
5734
|
-
},
|
|
5771
|
+
}, Ua = { class: "wm-actionWait__lbl" }, Fa = {
|
|
5735
5772
|
key: 2,
|
|
5736
5773
|
class: "wm-attached"
|
|
5737
|
-
},
|
|
5774
|
+
}, ja = ["aria-label", "onClick"];
|
|
5738
5775
|
function Pa(e, t, n, i, r, s) {
|
|
5739
|
-
const a = L("Launcher"), l = L("Header"), p = L("Onboarding"), C = L("MessageList"), k = L("ApprovalCard"), T = L("FormCard"), E = L("Feedback"), A = L("SuggestionChips"),
|
|
5776
|
+
const a = L("Launcher"), l = L("Header"), p = L("Onboarding"), C = L("MessageList"), k = L("ApprovalCard"), T = L("FormCard"), E = L("Feedback"), A = L("SuggestionChips"), q = L("Composer"), M = L("MoreMenu"), P = L("RenameDialog");
|
|
5740
5777
|
return c(), u("div", {
|
|
5741
5778
|
class: x(["wm-root", `wm-root--${n.displayMode}`])
|
|
5742
5779
|
}, [
|
|
@@ -5750,7 +5787,7 @@ function Pa(e, t, n, i, r, s) {
|
|
|
5750
5787
|
r.isOpen || s.isEmbedded ? (c(), u("section", {
|
|
5751
5788
|
key: 1,
|
|
5752
5789
|
class: x(["wm-panel", `wm-panel--${n.displayMode}`]),
|
|
5753
|
-
style:
|
|
5790
|
+
style: z(r.floatHeight ? { "--wm-float-h": r.floatHeight + "px" } : null),
|
|
5754
5791
|
role: "dialog",
|
|
5755
5792
|
"aria-label": "Messenger"
|
|
5756
5793
|
}, [
|
|
@@ -5781,7 +5818,7 @@ function Pa(e, t, n, i, r, s) {
|
|
|
5781
5818
|
"aria-hidden": "true"
|
|
5782
5819
|
}, null, -1))
|
|
5783
5820
|
])) : (c(), u(I, { key: 1 }, [
|
|
5784
|
-
|
|
5821
|
+
$(l, {
|
|
5785
5822
|
title: s.headerTitle,
|
|
5786
5823
|
"team-members": s.teamMembers,
|
|
5787
5824
|
"response-label": s.responseLabel,
|
|
@@ -5789,11 +5826,12 @@ function Pa(e, t, n, i, r, s) {
|
|
|
5789
5826
|
"show-back": s.canBack,
|
|
5790
5827
|
"show-close": !s.isEmbedded,
|
|
5791
5828
|
"more-active": r.moreOpen,
|
|
5829
|
+
"agent-name": s.agentName,
|
|
5792
5830
|
"agent-avatar-url": s.agentAvatarUrl,
|
|
5793
5831
|
onBack: s.goHome,
|
|
5794
5832
|
onMore: s.toggleMore,
|
|
5795
5833
|
onClose: s.close
|
|
5796
|
-
}, null, 8, ["title", "team-members", "response-label", "show-identity", "show-back", "show-close", "more-active", "agent-avatar-url", "onBack", "onMore", "onClose"]),
|
|
5834
|
+
}, null, 8, ["title", "team-members", "response-label", "show-identity", "show-back", "show-close", "more-active", "agent-name", "agent-avatar-url", "onBack", "onMore", "onClose"]),
|
|
5797
5835
|
s.error ? (c(), u("div", Oa, [
|
|
5798
5836
|
o("div", Ia, [
|
|
5799
5837
|
t[7] || (t[7] = o("div", { class: "wm-state__errIcon" }, [
|
|
@@ -5817,7 +5855,7 @@ function Pa(e, t, n, i, r, s) {
|
|
|
5817
5855
|
])
|
|
5818
5856
|
])
|
|
5819
5857
|
])) : s.currentConv ? (c(), u(I, { key: 2 }, [
|
|
5820
|
-
|
|
5858
|
+
$(C, {
|
|
5821
5859
|
ref: "messageList",
|
|
5822
5860
|
messages: s.displayedMessages,
|
|
5823
5861
|
"streaming-active": s.streamingActive,
|
|
@@ -5838,12 +5876,16 @@ function Pa(e, t, n, i, r, s) {
|
|
|
5838
5876
|
action: s.approvalTitle,
|
|
5839
5877
|
detail: s.approvalDetail,
|
|
5840
5878
|
callbacks: s.pendingApproval.callbacks,
|
|
5879
|
+
"agent-name": s.agentName,
|
|
5880
|
+
"agent-avatar-url": s.agentAvatarUrl,
|
|
5841
5881
|
onCallback: s.onApprovalCallback
|
|
5842
|
-
}, null, 8, ["action", "detail", "callbacks", "onCallback"])) : s.pendingForm ? (c(), R(T, {
|
|
5882
|
+
}, null, 8, ["action", "detail", "callbacks", "agent-name", "agent-avatar-url", "onCallback"])) : s.pendingForm ? (c(), R(T, {
|
|
5843
5883
|
key: s.pendingForm.message && s.pendingForm.message.id,
|
|
5844
5884
|
form: s.pendingForm.form,
|
|
5885
|
+
"agent-name": s.agentName,
|
|
5886
|
+
"agent-avatar-url": s.agentAvatarUrl,
|
|
5845
5887
|
onSubmit: s.onFormSubmit
|
|
5846
|
-
}, null, 8, ["form", "onSubmit"])) : s.showFeedback ? (c(), R(E, {
|
|
5888
|
+
}, null, 8, ["form", "agent-name", "agent-avatar-url", "onSubmit"])) : s.showFeedback ? (c(), R(E, {
|
|
5847
5889
|
key: 2,
|
|
5848
5890
|
busy: r.feedbackBusy,
|
|
5849
5891
|
done: r.feedbackDone,
|
|
@@ -5859,10 +5901,10 @@ function Pa(e, t, n, i, r, s) {
|
|
|
5859
5901
|
class: "wm-actionWait__spinner",
|
|
5860
5902
|
"aria-hidden": "true"
|
|
5861
5903
|
}, null, -1)),
|
|
5862
|
-
o("span",
|
|
5904
|
+
o("span", Ua, v(s.t("action.inProgress", {
|
|
5863
5905
|
name: s.actionInFlightName
|
|
5864
5906
|
})), 1)
|
|
5865
|
-
])) : (c(), R(
|
|
5907
|
+
])) : (c(), R(q, {
|
|
5866
5908
|
key: 2,
|
|
5867
5909
|
ref: "composer",
|
|
5868
5910
|
modelValue: r.draft,
|
|
@@ -5894,9 +5936,9 @@ function Pa(e, t, n, i, r, s) {
|
|
|
5894
5936
|
onClose: t[3] || (t[3] = (N) => r.renameDialogOpen = !1),
|
|
5895
5937
|
onSubmit: s.onRenameSubmit
|
|
5896
5938
|
}, null, 8, ["initial-value", "title", "onSubmit"])) : b("", !0),
|
|
5897
|
-
r.pendingAttachments.length ? (c(), u("div",
|
|
5898
|
-
(c(!0), u(I, null,
|
|
5899
|
-
key:
|
|
5939
|
+
r.pendingAttachments.length ? (c(), u("div", Fa, [
|
|
5940
|
+
(c(!0), u(I, null, F(r.pendingAttachments, (N, H) => (c(), u("div", {
|
|
5941
|
+
key: H,
|
|
5900
5942
|
class: "wm-attached__chip"
|
|
5901
5943
|
}, [
|
|
5902
5944
|
t[10] || (t[10] = o("svg", {
|
|
@@ -5916,7 +5958,7 @@ function Pa(e, t, n, i, r, s) {
|
|
|
5916
5958
|
o("button", {
|
|
5917
5959
|
type: "button",
|
|
5918
5960
|
"aria-label": s.t("attachment.remove"),
|
|
5919
|
-
onClick: (W) => r.pendingAttachments.splice(
|
|
5961
|
+
onClick: (W) => r.pendingAttachments.splice(H, 1)
|
|
5920
5962
|
}, [...t[9] || (t[9] = [
|
|
5921
5963
|
o("svg", {
|
|
5922
5964
|
width: "10",
|
|
@@ -5931,7 +5973,7 @@ function Pa(e, t, n, i, r, s) {
|
|
|
5931
5973
|
}, [
|
|
5932
5974
|
o("path", { d: "M18 6L6 18M6 6l12 12" })
|
|
5933
5975
|
], -1)
|
|
5934
|
-
])], 8,
|
|
5976
|
+
])], 8, ja)
|
|
5935
5977
|
]))), 128))
|
|
5936
5978
|
])) : b("", !0)
|
|
5937
5979
|
], 64)) : (c(), R(p, {
|
|
@@ -5964,7 +6006,7 @@ function Pa(e, t, n, i, r, s) {
|
|
|
5964
6006
|
], 6)) : b("", !0)
|
|
5965
6007
|
], 2);
|
|
5966
6008
|
}
|
|
5967
|
-
const
|
|
6009
|
+
const za = /* @__PURE__ */ B(Ma, [["render", Pa], ["__scopeId", "data-v-0bf94dbd"]]), qa = "0.4.6";
|
|
5968
6010
|
export {
|
|
5969
6011
|
le as AIAvatar,
|
|
5970
6012
|
fe as AVATAR_COLORS,
|
|
@@ -5972,21 +6014,21 @@ export {
|
|
|
5972
6014
|
ui as ApprovalCard,
|
|
5973
6015
|
ds as ArtifactFormResponse,
|
|
5974
6016
|
Cs as ArtifactInfoCard,
|
|
5975
|
-
|
|
5976
|
-
|
|
6017
|
+
zs as ArtifactRenderer,
|
|
6018
|
+
js as ArtifactTicket,
|
|
5977
6019
|
er as AttachmentPreview,
|
|
5978
6020
|
rr as Bubble,
|
|
5979
6021
|
Xr as Composer,
|
|
5980
6022
|
Ze as DEFAULT_BASE_URL,
|
|
5981
6023
|
ie as DEFAULT_LANGUAGE,
|
|
5982
6024
|
Ji as Feedback,
|
|
5983
|
-
|
|
6025
|
+
ji as FormCard,
|
|
5984
6026
|
cn as Header,
|
|
5985
6027
|
Be as HumanAvatar,
|
|
5986
|
-
|
|
5987
|
-
|
|
6028
|
+
Ft as Launcher,
|
|
6029
|
+
be as MEDIA_RECORDER_SUPPORTED,
|
|
5988
6030
|
Lr as MessageList,
|
|
5989
|
-
|
|
6031
|
+
za as Messenger,
|
|
5990
6032
|
ha as MoreMenu,
|
|
5991
6033
|
qn as Onboarding,
|
|
5992
6034
|
me as SCREEN_CAPTURE_SUPPORTED,
|
|
@@ -5995,21 +6037,21 @@ export {
|
|
|
5995
6037
|
Yt as TeamAvatars,
|
|
5996
6038
|
lr as Typing,
|
|
5997
6039
|
qa as VERSION,
|
|
5998
|
-
|
|
5999
|
-
|
|
6040
|
+
pe as avatarColor,
|
|
6041
|
+
ve as avatarInitials,
|
|
6000
6042
|
Er as captureScreenshotFile,
|
|
6001
6043
|
D as colors,
|
|
6002
6044
|
Xe as createStore,
|
|
6003
|
-
|
|
6045
|
+
j as createTranslator,
|
|
6004
6046
|
We as createTransport,
|
|
6005
6047
|
oe as dateLocale,
|
|
6006
|
-
|
|
6048
|
+
za as default,
|
|
6007
6049
|
Ie as formatTime,
|
|
6008
|
-
|
|
6050
|
+
Ha as guessAttachmentKind,
|
|
6009
6051
|
Br as pickRecorderMime,
|
|
6010
6052
|
un as renderInlineMarkdown,
|
|
6011
6053
|
mn as renderMarkdown,
|
|
6012
|
-
|
|
6054
|
+
ye as resolveLanguage,
|
|
6013
6055
|
Nr as startScreenRecording,
|
|
6014
6056
|
Je as tokensCss,
|
|
6015
6057
|
Qe as uuid,
|