@_solaris/messenger-widget 0.2.15 → 0.2.17
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 +8 -8
- package/dist/messenger.embed.js +8 -8
- package/dist/messenger.js +182 -182
- package/dist/style.css +1 -1
- package/package.json +1 -1
package/dist/messenger.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { reactive as Ae, openBlock as l, createElementBlock as d, createVNode as
|
|
1
|
+
import { reactive as Ae, openBlock as l, createElementBlock as d, createVNode as V, Transition as Se, withCtx as xe, withKeys as me, withModifiers as Q, createElementVNode as i, toDisplayString as b, createCommentVNode as y, normalizeStyle as q, normalizeClass as E, Fragment as M, renderList as j, resolveComponent as O, createBlock as $, createTextVNode as ae, resolveDynamicComponent as Me, renderSlot as Te, withDirectives as z, vModelText as Y, vModelCheckbox as Ie, vModelSelect as Oe, createStaticVNode as ue, markRaw as fe } from "vue";
|
|
2
2
|
const Ee = [
|
|
3
3
|
"connected",
|
|
4
4
|
"message",
|
|
@@ -108,13 +108,13 @@ function $e(t) {
|
|
|
108
108
|
const h = await o("GET", "/conversations");
|
|
109
109
|
return (h == null ? void 0 : h.conversations) ?? [];
|
|
110
110
|
}
|
|
111
|
-
async function
|
|
111
|
+
async function L(h = {}) {
|
|
112
112
|
return (await o("POST", "/conversations", h)).conversation;
|
|
113
113
|
}
|
|
114
114
|
async function A(h) {
|
|
115
115
|
return (await o("GET", `/conversations/${encodeURIComponent(h)}`)).conversation;
|
|
116
116
|
}
|
|
117
|
-
async function
|
|
117
|
+
async function N(h, f) {
|
|
118
118
|
return (await o("PATCH", `/conversations/${encodeURIComponent(h)}`, f)).conversation;
|
|
119
119
|
}
|
|
120
120
|
async function x(h, f = {}) {
|
|
@@ -126,8 +126,8 @@ function $e(t) {
|
|
|
126
126
|
`/conversations/${encodeURIComponent(h)}/messages${k}`
|
|
127
127
|
);
|
|
128
128
|
}
|
|
129
|
-
async function
|
|
130
|
-
|
|
129
|
+
async function U(h, f) {
|
|
130
|
+
K();
|
|
131
131
|
const _ = {
|
|
132
132
|
client_msg_id: f.client_msg_id,
|
|
133
133
|
type: "content",
|
|
@@ -142,7 +142,7 @@ function $e(t) {
|
|
|
142
142
|
);
|
|
143
143
|
}
|
|
144
144
|
async function F(h, f, _) {
|
|
145
|
-
return
|
|
145
|
+
return K(), o(
|
|
146
146
|
"POST",
|
|
147
147
|
`/messages/${encodeURIComponent(h)}/callbacks/${encodeURIComponent(f)}`,
|
|
148
148
|
_ ? { inputs: _ } : {}
|
|
@@ -173,13 +173,13 @@ function $e(t) {
|
|
|
173
173
|
size_bytes: k
|
|
174
174
|
};
|
|
175
175
|
}
|
|
176
|
-
async function
|
|
176
|
+
async function W(h) {
|
|
177
177
|
return o(
|
|
178
178
|
"GET",
|
|
179
179
|
`/attachments/sign?path=${encodeURIComponent(h)}`
|
|
180
180
|
);
|
|
181
181
|
}
|
|
182
|
-
function
|
|
182
|
+
function G() {
|
|
183
183
|
const h = new URLSearchParams({
|
|
184
184
|
userId: e.userId,
|
|
185
185
|
userHash: e.userHash,
|
|
@@ -187,18 +187,18 @@ function $e(t) {
|
|
|
187
187
|
}).toString();
|
|
188
188
|
return `${e.baseUrl}/stream?${h}`;
|
|
189
189
|
}
|
|
190
|
-
function
|
|
190
|
+
function H() {
|
|
191
191
|
if (!e.eventSource && !(typeof document < "u" && document.hidden))
|
|
192
192
|
try {
|
|
193
|
-
const h = new EventSource(
|
|
193
|
+
const h = new EventSource(G());
|
|
194
194
|
for (const f of Ee)
|
|
195
|
-
h.addEventListener(f, (_) =>
|
|
195
|
+
h.addEventListener(f, (_) => J(f, _.data));
|
|
196
196
|
h.addEventListener("error", () => a("error", new Error("SSE error"))), e.eventSource = h, r("open");
|
|
197
197
|
} catch (h) {
|
|
198
198
|
console.error("[transport] SSE open failed", h), a("error", h);
|
|
199
199
|
}
|
|
200
200
|
}
|
|
201
|
-
function
|
|
201
|
+
function J(h, f) {
|
|
202
202
|
try {
|
|
203
203
|
const _ = JSON.parse(f), k = _ && typeof _ == "object" && "data" in _ ? _.data : _;
|
|
204
204
|
a(h, k);
|
|
@@ -206,16 +206,16 @@ function $e(t) {
|
|
|
206
206
|
console.error("[transport] bad SSE payload", h, _);
|
|
207
207
|
}
|
|
208
208
|
}
|
|
209
|
-
function
|
|
209
|
+
function X() {
|
|
210
210
|
e.eventSource && (e.eventSource.close(), e.eventSource = null), e.connection !== "paused" && r("idle");
|
|
211
211
|
}
|
|
212
|
-
function
|
|
213
|
-
clearTimeout(e.burstTimer),
|
|
214
|
-
e.panelOpen ||
|
|
212
|
+
function K() {
|
|
213
|
+
clearTimeout(e.burstTimer), H(), e.panelOpen || (e.burstTimer = setTimeout(() => {
|
|
214
|
+
e.panelOpen || X();
|
|
215
215
|
}, Le));
|
|
216
216
|
}
|
|
217
217
|
function oe(h) {
|
|
218
|
-
e.panelOpen = !!h, e.panelOpen ? (clearTimeout(e.burstTimer),
|
|
218
|
+
e.panelOpen = !!h, e.panelOpen ? (clearTimeout(e.burstTimer), H()) : K();
|
|
219
219
|
}
|
|
220
220
|
async function le() {
|
|
221
221
|
try {
|
|
@@ -223,12 +223,12 @@ function $e(t) {
|
|
|
223
223
|
const T = I == null ? void 0 : I.last_message_at;
|
|
224
224
|
return T && (!k || T > k) ? T : k;
|
|
225
225
|
}, null);
|
|
226
|
-
f && (!e.lastActivityAt || f > e.lastActivityAt) && (e.lastActivityAt = f, a("activity", { conversations: h, latestAt: f }),
|
|
226
|
+
f && (!e.lastActivityAt || f > e.lastActivityAt) && (e.lastActivityAt = f, a("activity", { conversations: h, latestAt: f }), K());
|
|
227
227
|
} catch (h) {
|
|
228
228
|
console.error("[transport] poll failed", h);
|
|
229
229
|
}
|
|
230
230
|
}
|
|
231
|
-
function
|
|
231
|
+
function ee() {
|
|
232
232
|
u(), !(typeof document < "u" && document.hidden) && (e.pollTimer = setInterval(le, Be));
|
|
233
233
|
}
|
|
234
234
|
function u() {
|
|
@@ -237,14 +237,14 @@ function $e(t) {
|
|
|
237
237
|
function m() {
|
|
238
238
|
if (document.hidden)
|
|
239
239
|
clearTimeout(e.hiddenGraceTimer), e.hiddenGraceTimer = setTimeout(() => {
|
|
240
|
-
e.hiddenGraceTimer = null, document.hidden && (u(),
|
|
240
|
+
e.hiddenGraceTimer = null, document.hidden && (u(), X(), r("paused"));
|
|
241
241
|
}, Re);
|
|
242
242
|
else {
|
|
243
243
|
if (e.hiddenGraceTimer) {
|
|
244
244
|
clearTimeout(e.hiddenGraceTimer), e.hiddenGraceTimer = null;
|
|
245
245
|
return;
|
|
246
246
|
}
|
|
247
|
-
r("idle"),
|
|
247
|
+
r("idle"), ee(), e.panelOpen && H();
|
|
248
248
|
}
|
|
249
249
|
}
|
|
250
250
|
async function p() {
|
|
@@ -261,10 +261,10 @@ function $e(t) {
|
|
|
261
261
|
} catch (f) {
|
|
262
262
|
console.error("[transport] initial /conversations failed", f);
|
|
263
263
|
}
|
|
264
|
-
return typeof document < "u" && (e.visibilityHandler = m, document.addEventListener("visibilitychange", e.visibilityHandler)),
|
|
264
|
+
return typeof document < "u" && (e.visibilityHandler = m, document.addEventListener("visibilitychange", e.visibilityHandler)), ee(), h;
|
|
265
265
|
}
|
|
266
266
|
function g() {
|
|
267
|
-
u(), clearTimeout(e.burstTimer), clearTimeout(e.hiddenGraceTimer), e.hiddenGraceTimer = null,
|
|
267
|
+
u(), clearTimeout(e.burstTimer), clearTimeout(e.hiddenGraceTimer), e.hiddenGraceTimer = null, X(), e.visibilityHandler && (document.removeEventListener("visibilitychange", e.visibilityHandler), e.visibilityHandler = null), e.started = !1;
|
|
268
268
|
}
|
|
269
269
|
return {
|
|
270
270
|
on: n,
|
|
@@ -276,14 +276,14 @@ function $e(t) {
|
|
|
276
276
|
getCustomer: C,
|
|
277
277
|
patchCustomer: w,
|
|
278
278
|
listConversations: S,
|
|
279
|
-
createConversation:
|
|
279
|
+
createConversation: L,
|
|
280
280
|
getConversation: A,
|
|
281
|
-
patchConversation:
|
|
281
|
+
patchConversation: N,
|
|
282
282
|
listMessages: x,
|
|
283
|
-
postMessage:
|
|
283
|
+
postMessage: U,
|
|
284
284
|
postCallback: F,
|
|
285
285
|
uploadAttachment: P,
|
|
286
|
-
signAttachment:
|
|
286
|
+
signAttachment: W,
|
|
287
287
|
// Read-only state
|
|
288
288
|
get connection() {
|
|
289
289
|
return e.connection;
|
|
@@ -344,7 +344,7 @@ function De(t) {
|
|
|
344
344
|
e.connection = u;
|
|
345
345
|
})), n.push(t.on("message", (u) => {
|
|
346
346
|
const m = u == null ? void 0 : u.conversation_id, p = u == null ? void 0 : u.message;
|
|
347
|
-
!m || !(p != null && p.id) || (
|
|
347
|
+
!m || !(p != null && p.id) || (H(m, p), p.client_msg_id && delete e.streamingByMsgId[p.client_msg_id], K(m, p.created_at));
|
|
348
348
|
})), n.push(t.on("message_stream", (u) => {
|
|
349
349
|
const m = u == null ? void 0 : u.message_id, p = u == null ? void 0 : u.token;
|
|
350
350
|
!m || typeof p != "string" || (e.streamingByMsgId[m] = (e.streamingByMsgId[m] || "") + p);
|
|
@@ -413,13 +413,13 @@ function De(t) {
|
|
|
413
413
|
try {
|
|
414
414
|
let h = m.nextCursor, f = [], _ = 0;
|
|
415
415
|
for (; _ < 6 && h; _++) {
|
|
416
|
-
const
|
|
416
|
+
const R = await t.listMessages(u, {
|
|
417
417
|
before: h,
|
|
418
418
|
limit: c
|
|
419
|
-
}),
|
|
420
|
-
if (f = [...
|
|
419
|
+
}), te = (R == null ? void 0 : R.messages) ?? [];
|
|
420
|
+
if (f = [...te, ...f], h = (R == null ? void 0 : R.next_cursor) ?? null, !te.length || f.length >= 60) break;
|
|
421
421
|
}
|
|
422
|
-
const k = e.messagesByConv[u] || [], I = new Set(k.map((
|
|
422
|
+
const k = e.messagesByConv[u] || [], I = new Set(k.map((R) => String(R == null ? void 0 : R.id))), T = [...f.filter((R) => !I.has(String(R == null ? void 0 : R.id))), ...k];
|
|
423
423
|
e.messagesByConv[u] = T, w(u, {
|
|
424
424
|
nextCursor: h,
|
|
425
425
|
loading: !1,
|
|
@@ -437,11 +437,11 @@ function De(t) {
|
|
|
437
437
|
const p = await t.patchConversation(u, m), g = e.conversations.findIndex((h) => h.id === u);
|
|
438
438
|
g !== -1 && (e.conversations[g] = p);
|
|
439
439
|
}
|
|
440
|
-
async function
|
|
440
|
+
async function L(u, m, { attachments: p, metadata: g } = {}) {
|
|
441
441
|
var T;
|
|
442
442
|
const h = (m || "").trim(), f = Array.isArray(p) && p.length > 0;
|
|
443
443
|
if (!u || !h && !f) return;
|
|
444
|
-
const _ = Ue(), k =
|
|
444
|
+
const _ = Ue(), k = ee(u), I = {
|
|
445
445
|
id: _,
|
|
446
446
|
client_msg_id: _,
|
|
447
447
|
conversation_id: u,
|
|
@@ -457,7 +457,7 @@ function De(t) {
|
|
|
457
457
|
...f ? { payload: { type: "content", attachments: p } } : {},
|
|
458
458
|
...g && typeof g == "object" ? { metadata: g } : {}
|
|
459
459
|
};
|
|
460
|
-
|
|
460
|
+
H(u, I);
|
|
461
461
|
try {
|
|
462
462
|
await t.postMessage(u, {
|
|
463
463
|
client_msg_id: _,
|
|
@@ -466,8 +466,8 @@ function De(t) {
|
|
|
466
466
|
...f ? { attachments: p } : {},
|
|
467
467
|
...g && typeof g == "object" ? { metadata: g } : {}
|
|
468
468
|
});
|
|
469
|
-
} catch (
|
|
470
|
-
console.error("[store] send failed",
|
|
469
|
+
} catch (R) {
|
|
470
|
+
console.error("[store] send failed", R), X(u, _, { _failed: !0, _pending: !1 });
|
|
471
471
|
}
|
|
472
472
|
}
|
|
473
473
|
async function A(u, m, p) {
|
|
@@ -478,10 +478,10 @@ function De(t) {
|
|
|
478
478
|
console.error("[store] callback failed", g), u != null && delete e.awaitingCallback[u];
|
|
479
479
|
}
|
|
480
480
|
}
|
|
481
|
-
const
|
|
481
|
+
const N = /* @__PURE__ */ new Map();
|
|
482
482
|
async function x(u) {
|
|
483
483
|
if (!u) return null;
|
|
484
|
-
const m =
|
|
484
|
+
const m = N.get(u);
|
|
485
485
|
if (m != null && m.url) {
|
|
486
486
|
const p = m.expires_at ? Date.parse(m.expires_at) : 0;
|
|
487
487
|
if (!p || p - Date.now() > 6e4) return m.url;
|
|
@@ -489,13 +489,13 @@ function De(t) {
|
|
|
489
489
|
try {
|
|
490
490
|
const p = await t.signAttachment(u);
|
|
491
491
|
if (p != null && p.signed_url)
|
|
492
|
-
return
|
|
492
|
+
return N.set(u, { url: p.signed_url, expires_at: p.expires_at }), p.signed_url;
|
|
493
493
|
} catch (p) {
|
|
494
494
|
console.error("[store] sign attachment failed", p);
|
|
495
495
|
}
|
|
496
496
|
return null;
|
|
497
497
|
}
|
|
498
|
-
async function
|
|
498
|
+
async function U(u, { rating: m, comment: p } = {}) {
|
|
499
499
|
const g = e.conversations.find((_) => _.id === u), f = {
|
|
500
500
|
...(g == null ? void 0 : g.metadata) || {},
|
|
501
501
|
feedback: {
|
|
@@ -528,7 +528,7 @@ function De(t) {
|
|
|
528
528
|
}
|
|
529
529
|
return null;
|
|
530
530
|
}
|
|
531
|
-
function
|
|
531
|
+
function W(u) {
|
|
532
532
|
const m = e.runningActionsByConv[u];
|
|
533
533
|
if (!m) return null;
|
|
534
534
|
const p = Object.keys(m);
|
|
@@ -536,7 +536,7 @@ function De(t) {
|
|
|
536
536
|
const g = p[0];
|
|
537
537
|
return { id: g, payload: { name: m[g] } };
|
|
538
538
|
}
|
|
539
|
-
function
|
|
539
|
+
function G(u) {
|
|
540
540
|
var p, g, h, f;
|
|
541
541
|
const m = e.messagesByConv[u] || [];
|
|
542
542
|
for (let _ = m.length - 1; _ >= 0; _--) {
|
|
@@ -547,34 +547,34 @@ function De(t) {
|
|
|
547
547
|
const I = (f = k == null ? void 0 : k.metadata) == null ? void 0 : f.suggested_replies;
|
|
548
548
|
return Array.isArray(I) && I.length ? I.map((T) => {
|
|
549
549
|
if (typeof T == "string") {
|
|
550
|
-
const
|
|
551
|
-
return
|
|
550
|
+
const R = T.trim();
|
|
551
|
+
return R ? { label: R, kind: null } : null;
|
|
552
552
|
}
|
|
553
553
|
if (T && typeof T == "object" && typeof T.label == "string") {
|
|
554
|
-
const
|
|
555
|
-
if (!
|
|
556
|
-
const
|
|
557
|
-
return { label:
|
|
554
|
+
const R = T.label.trim();
|
|
555
|
+
if (!R) return null;
|
|
556
|
+
const te = T.kind === "cta" || T.kind === "choice" || T.kind === "followup" ? T.kind : null;
|
|
557
|
+
return { label: R, kind: te };
|
|
558
558
|
}
|
|
559
559
|
return null;
|
|
560
560
|
}).filter(Boolean).slice(0, 4) : [];
|
|
561
561
|
}
|
|
562
562
|
return [];
|
|
563
563
|
}
|
|
564
|
-
function
|
|
564
|
+
function H(u, m) {
|
|
565
565
|
var f;
|
|
566
566
|
const p = e.messagesByConv[u] || [];
|
|
567
567
|
let g = -1;
|
|
568
568
|
m != null && m.client_msg_id && (g = p.findIndex(
|
|
569
569
|
(_) => (_ == null ? void 0 : _.client_msg_id) && _.client_msg_id === m.client_msg_id
|
|
570
|
-
)), g === -1 && (m == null ? void 0 : m.id) !== void 0 && (m == null ? void 0 : m.id) !== null && (g = p.findIndex((_) =>
|
|
570
|
+
)), g === -1 && (m == null ? void 0 : m.id) !== void 0 && (m == null ? void 0 : m.id) !== null && (g = p.findIndex((_) => J(_ == null ? void 0 : _.id, m.id)));
|
|
571
571
|
let h;
|
|
572
572
|
g === -1 ? h = [...p, m].sort(oe) : (h = p.slice(), h[g] = { ...p[g], ...m, _pending: !1, _failed: !1 }), e.messagesByConv[u] = h, (m == null ? void 0 : m.type) === "action" && ((f = m == null ? void 0 : m.payload) != null && f.state) && m.payload.state !== "pending" && (m == null ? void 0 : m.id) != null && e.awaitingCallback[m.id] && delete e.awaitingCallback[m.id];
|
|
573
573
|
}
|
|
574
|
-
function
|
|
574
|
+
function J(u, m) {
|
|
575
575
|
return u === m ? !0 : u == null || m == null ? !1 : String(u) === String(m);
|
|
576
576
|
}
|
|
577
|
-
function
|
|
577
|
+
function X(u, m, p) {
|
|
578
578
|
const g = e.messagesByConv[u];
|
|
579
579
|
if (!g) return;
|
|
580
580
|
const h = g.findIndex((_) => _.id === m);
|
|
@@ -582,7 +582,7 @@ function De(t) {
|
|
|
582
582
|
const f = g.slice();
|
|
583
583
|
f[h] = { ...g[h], ...p }, e.messagesByConv[u] = f;
|
|
584
584
|
}
|
|
585
|
-
function
|
|
585
|
+
function K(u, m) {
|
|
586
586
|
const p = e.conversations.findIndex((h) => h.id === u);
|
|
587
587
|
if (p === -1) return;
|
|
588
588
|
const g = e.conversations[p];
|
|
@@ -603,7 +603,7 @@ function De(t) {
|
|
|
603
603
|
h !== void 0 && (g === "name" || g === "email" ? h != null && String(h).trim() !== "" && (m[g] = h) : (g === "values" || g === "metadata") && h && typeof h == "object" ? Object.assign(p, h) : p[g] = h);
|
|
604
604
|
return Object.keys(p).length && (m.values = p), Object.keys(m).length ? m : null;
|
|
605
605
|
}
|
|
606
|
-
function
|
|
606
|
+
function ee(u) {
|
|
607
607
|
const m = e.messagesByConv[u] || [];
|
|
608
608
|
let p = "";
|
|
609
609
|
for (const f of m)
|
|
@@ -620,19 +620,19 @@ function De(t) {
|
|
|
620
620
|
openConversation: v,
|
|
621
621
|
loadMore: C,
|
|
622
622
|
patchConversation: S,
|
|
623
|
-
send:
|
|
623
|
+
send: L,
|
|
624
624
|
clickCallback: A,
|
|
625
625
|
signAttachment: x,
|
|
626
|
-
submitFeedback:
|
|
626
|
+
submitFeedback: U,
|
|
627
627
|
getPendingApproval: F,
|
|
628
|
-
getActionInFlight:
|
|
629
|
-
getLatestSuggestions:
|
|
628
|
+
getActionInFlight: W,
|
|
629
|
+
getLatestSuggestions: G,
|
|
630
630
|
getLatestForm: P,
|
|
631
631
|
// Pass-through for panel open/close (controls SSE burst).
|
|
632
632
|
setPanelOpen: t.setPanelOpen
|
|
633
633
|
};
|
|
634
634
|
}
|
|
635
|
-
const
|
|
635
|
+
const D = {
|
|
636
636
|
w: "#ffffff",
|
|
637
637
|
g50: "#F9F9F7",
|
|
638
638
|
g100: "#F2F1EE",
|
|
@@ -664,21 +664,21 @@ const Ne = `
|
|
|
664
664
|
.wm-root {
|
|
665
665
|
--wm-f: 'Geist', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
|
|
666
666
|
--wm-fm: 'Geist Mono', ui-monospace, SFMono-Regular, Menlo, monospace;
|
|
667
|
-
--wm-w: ${
|
|
668
|
-
--wm-g50: ${
|
|
669
|
-
--wm-g100: ${
|
|
670
|
-
--wm-g150: ${
|
|
671
|
-
--wm-g200: ${
|
|
672
|
-
--wm-g300: ${
|
|
673
|
-
--wm-g400: ${
|
|
674
|
-
--wm-g500: ${
|
|
675
|
-
--wm-g700: ${
|
|
676
|
-
--wm-g900: ${
|
|
677
|
-
--wm-a: ${
|
|
678
|
-
--wm-al: ${
|
|
679
|
-
--wm-green: ${
|
|
680
|
-
--wm-red: ${
|
|
681
|
-
--wm-redBg: ${
|
|
667
|
+
--wm-w: ${D.w};
|
|
668
|
+
--wm-g50: ${D.g50};
|
|
669
|
+
--wm-g100: ${D.g100};
|
|
670
|
+
--wm-g150: ${D.g150};
|
|
671
|
+
--wm-g200: ${D.g200};
|
|
672
|
+
--wm-g300: ${D.g300};
|
|
673
|
+
--wm-g400: ${D.g400};
|
|
674
|
+
--wm-g500: ${D.g500};
|
|
675
|
+
--wm-g700: ${D.g700};
|
|
676
|
+
--wm-g900: ${D.g900};
|
|
677
|
+
--wm-a: ${D.accent};
|
|
678
|
+
--wm-al: ${D.accentLight};
|
|
679
|
+
--wm-green: ${D.green};
|
|
680
|
+
--wm-red: ${D.red};
|
|
681
|
+
--wm-redBg: ${D.redBg};
|
|
682
682
|
--wm-sh1: 0 1px 3px rgba(0,0,0,.06);
|
|
683
683
|
--wm-sh2: 0 4px 24px rgba(0,0,0,.09), 0 1px 4px rgba(0,0,0,.05);
|
|
684
684
|
--wm-shPanel: 0 12px 40px rgba(0,0,0,.13), 0 2px 8px rgba(0,0,0,.06);
|
|
@@ -722,7 +722,7 @@ const Ne = `
|
|
|
722
722
|
}, ze = { class: "wm-launcherWrap" }, Ve = { class: "wm-peek__text" }, qe = ["aria-label"];
|
|
723
723
|
function We(t, e, n, a, r, s) {
|
|
724
724
|
return l(), d("div", ze, [
|
|
725
|
-
|
|
725
|
+
V(Se, { name: "wm-peek" }, {
|
|
726
726
|
default: xe(() => [
|
|
727
727
|
n.peek ? (l(), d("div", {
|
|
728
728
|
key: 0,
|
|
@@ -732,8 +732,8 @@ function We(t, e, n, a, r, s) {
|
|
|
732
732
|
"aria-label": "Ouvrir le messenger sur le dernier message",
|
|
733
733
|
onClick: e[1] || (e[1] = (o) => t.$emit("open")),
|
|
734
734
|
onKeydown: [
|
|
735
|
-
e[2] || (e[2] = me(
|
|
736
|
-
e[3] || (e[3] = me(
|
|
735
|
+
e[2] || (e[2] = me(Q((o) => t.$emit("open"), ["prevent"]), ["enter"])),
|
|
736
|
+
e[3] || (e[3] = me(Q((o) => t.$emit("open"), ["prevent"]), ["space"]))
|
|
737
737
|
]
|
|
738
738
|
}, [
|
|
739
739
|
i("p", Ve, b(n.peek), 1),
|
|
@@ -741,7 +741,7 @@ function We(t, e, n, a, r, s) {
|
|
|
741
741
|
type: "button",
|
|
742
742
|
class: "wm-peek__close",
|
|
743
743
|
"aria-label": "Ignorer",
|
|
744
|
-
onClick: e[0] || (e[0] =
|
|
744
|
+
onClick: e[0] || (e[0] = Q((o) => t.$emit("dismiss"), ["stop"]))
|
|
745
745
|
}, [...e[5] || (e[5] = [
|
|
746
746
|
i("svg", {
|
|
747
747
|
width: "11",
|
|
@@ -807,7 +807,7 @@ const Ge = /* @__PURE__ */ B(He, [["render", We], ["__scopeId", "data-v-fabef371
|
|
|
807
807
|
function Xe(t, e, n, a, r, s) {
|
|
808
808
|
return l(), d("div", {
|
|
809
809
|
class: E(["wm-aiav", { "wm-aiav--tail": n.tail }]),
|
|
810
|
-
style:
|
|
810
|
+
style: q({ width: n.size + "px", height: n.size + "px", "--wm-avr": n.size * 0.32 + "px" })
|
|
811
811
|
}, [
|
|
812
812
|
n.pulse ? (l(), d("div", Ye)) : y("", !0),
|
|
813
813
|
i("div", {
|
|
@@ -843,7 +843,7 @@ function Xe(t, e, n, a, r, s) {
|
|
|
843
843
|
], 2)
|
|
844
844
|
], 6);
|
|
845
845
|
}
|
|
846
|
-
const
|
|
846
|
+
const Z = /* @__PURE__ */ B(Ke, [["render", Xe], ["__scopeId", "data-v-8c924688"]]), Qe = {
|
|
847
847
|
name: "WmHumanAvatar",
|
|
848
848
|
props: {
|
|
849
849
|
name: { type: String, default: "" },
|
|
@@ -862,7 +862,7 @@ const Q = /* @__PURE__ */ B(Ke, [["render", Xe], ["__scopeId", "data-v-8c924688"
|
|
|
862
862
|
function et(t, e, n, a, r, s) {
|
|
863
863
|
return l(), d("div", {
|
|
864
864
|
class: "wm-huav",
|
|
865
|
-
style:
|
|
865
|
+
style: q({
|
|
866
866
|
width: n.size + "px",
|
|
867
867
|
height: n.size + "px",
|
|
868
868
|
"--wm-avr": Math.round(n.size * 0.32) + "px",
|
|
@@ -875,7 +875,7 @@ function et(t, e, n, a, r, s) {
|
|
|
875
875
|
alt: n.name || ""
|
|
876
876
|
}, null, 8, Ze)) : (l(), d("span", {
|
|
877
877
|
key: 1,
|
|
878
|
-
style:
|
|
878
|
+
style: q({ fontSize: n.size * 0.36 + "px" })
|
|
879
879
|
}, b(s.initials), 5))
|
|
880
880
|
], 4);
|
|
881
881
|
}
|
|
@@ -912,12 +912,12 @@ function at(t, e, n, a, r, s) {
|
|
|
912
912
|
return s.visible ? (l(), d("div", nt, [
|
|
913
913
|
i("div", {
|
|
914
914
|
class: "wm-team__stack",
|
|
915
|
-
style:
|
|
915
|
+
style: q({ width: s.stackWidth + "px" })
|
|
916
916
|
}, [
|
|
917
917
|
(l(!0), d(M, null, j(n.members.slice(0, 3), (o, c) => (l(), d("div", {
|
|
918
918
|
key: c,
|
|
919
919
|
class: "wm-team__pill",
|
|
920
|
-
style:
|
|
920
|
+
style: q({ left: c * 13 + "px", zIndex: 3 - c, background: s.colorFor(o) })
|
|
921
921
|
}, [
|
|
922
922
|
o.avatar_url ? (l(), d("img", {
|
|
923
923
|
key: 0,
|
|
@@ -931,7 +931,7 @@ function at(t, e, n, a, r, s) {
|
|
|
931
931
|
}
|
|
932
932
|
const ot = /* @__PURE__ */ B(tt, [["render", at], ["__scopeId", "data-v-3659b9c1"]]), lt = {
|
|
933
933
|
name: "WmHeader",
|
|
934
|
-
components: { AIAvatar:
|
|
934
|
+
components: { AIAvatar: Z, HumanAvatar: ke, TeamAvatars: ot },
|
|
935
935
|
props: {
|
|
936
936
|
title: { type: String, default: "Nouvelle conversation" },
|
|
937
937
|
escalated: { type: Boolean, default: !1 },
|
|
@@ -998,12 +998,12 @@ function gt(t, e, n, a, r, s) {
|
|
|
998
998
|
])])) : (l(), d("div", dt)),
|
|
999
999
|
n.showIdentity ? (l(), d(M, { key: 2 }, [
|
|
1000
1000
|
i("div", ut, [
|
|
1001
|
-
n.escalated ? (l(),
|
|
1001
|
+
n.escalated ? (l(), $(o, {
|
|
1002
1002
|
key: 0,
|
|
1003
1003
|
name: n.agentName,
|
|
1004
1004
|
"avatar-url": n.agentAvatarUrl,
|
|
1005
1005
|
size: 34
|
|
1006
|
-
}, null, 8, ["name", "avatar-url"])) : (l(),
|
|
1006
|
+
}, null, 8, ["name", "avatar-url"])) : (l(), $(c, {
|
|
1007
1007
|
key: 1,
|
|
1008
1008
|
size: 34
|
|
1009
1009
|
}))
|
|
@@ -1011,14 +1011,14 @@ function gt(t, e, n, a, r, s) {
|
|
|
1011
1011
|
i("div", ht, [
|
|
1012
1012
|
i("div", mt, b(n.title), 1),
|
|
1013
1013
|
s.showPresence ? (l(), d("div", ft, [
|
|
1014
|
-
s.hasTeam ? (l(),
|
|
1014
|
+
s.hasTeam ? (l(), $(v, {
|
|
1015
1015
|
key: 0,
|
|
1016
1016
|
members: n.teamMembers,
|
|
1017
1017
|
"response-label": n.responseLabel
|
|
1018
1018
|
}, null, 8, ["members", "response-label"])) : y("", !0),
|
|
1019
1019
|
i("span", pt, [
|
|
1020
1020
|
e[4] || (e[4] = i("span", { class: "wm-header__dot" }, null, -1)),
|
|
1021
|
-
|
|
1021
|
+
ae(" " + b(s.statusText), 1)
|
|
1022
1022
|
])
|
|
1023
1023
|
])) : y("", !0)
|
|
1024
1024
|
])
|
|
@@ -1089,7 +1089,7 @@ const yt = /* @__PURE__ */ B(lt, [["render", gt], ["__scopeId", "data-v-b5f5f6a9
|
|
|
1089
1089
|
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"
|
|
1090
1090
|
}, wt = {
|
|
1091
1091
|
name: "WmOnboarding",
|
|
1092
|
-
components: { AIAvatar:
|
|
1092
|
+
components: { AIAvatar: Z },
|
|
1093
1093
|
props: {
|
|
1094
1094
|
welcomeMessage: { type: String, default: "" },
|
|
1095
1095
|
agentName: { type: String, default: "" },
|
|
@@ -1133,7 +1133,7 @@ function Nt(t, e, n, a, r, s) {
|
|
|
1133
1133
|
const o = O("AIAvatar");
|
|
1134
1134
|
return l(), d("div", bt, [
|
|
1135
1135
|
i("div", kt, [
|
|
1136
|
-
|
|
1136
|
+
V(o, {
|
|
1137
1137
|
size: 56,
|
|
1138
1138
|
pulse: !0
|
|
1139
1139
|
}),
|
|
@@ -1366,7 +1366,7 @@ function an(t, e, n, a, r, s) {
|
|
|
1366
1366
|
}, [
|
|
1367
1367
|
i("polyline", { points: "20 6 9 17 4 12" })
|
|
1368
1368
|
]),
|
|
1369
|
-
|
|
1369
|
+
ae(" Envoyé ")
|
|
1370
1370
|
], -1))
|
|
1371
1371
|
]),
|
|
1372
1372
|
i("div", sn, [
|
|
@@ -1519,7 +1519,7 @@ function Ln(t, e, n, a, r, s) {
|
|
|
1519
1519
|
class: "wm-tk__dot",
|
|
1520
1520
|
"aria-hidden": "true"
|
|
1521
1521
|
}, null, -1)),
|
|
1522
|
-
|
|
1522
|
+
ae(" " + b(n.data.status.label), 1)
|
|
1523
1523
|
], 2)
|
|
1524
1524
|
]),
|
|
1525
1525
|
n.data.body ? (l(), d("div", Tn, b(n.data.body), 1)) : y("", !0)
|
|
@@ -1613,7 +1613,7 @@ const Rn = /* @__PURE__ */ B(kn, [["render", Ln], ["__scopeId", "data-v-97001af0
|
|
|
1613
1613
|
}
|
|
1614
1614
|
};
|
|
1615
1615
|
function jn(t, e, n, a, r, s) {
|
|
1616
|
-
return s.component ? (l(),
|
|
1616
|
+
return s.component ? (l(), $(Me(s.component), {
|
|
1617
1617
|
key: 0,
|
|
1618
1618
|
data: n.artifact.data
|
|
1619
1619
|
}, null, 8, ["data"])) : y("", !0);
|
|
@@ -1747,7 +1747,7 @@ function Qn(t) {
|
|
|
1747
1747
|
return /^(https?:\/\/|mailto:|tel:)/i.test(String(t).trim());
|
|
1748
1748
|
}
|
|
1749
1749
|
const _e = "";
|
|
1750
|
-
function
|
|
1750
|
+
function ne(t) {
|
|
1751
1751
|
let e = t;
|
|
1752
1752
|
const n = [];
|
|
1753
1753
|
return e = e.replace(/`([^`\n]+)`/g, (a, r) => {
|
|
@@ -1781,7 +1781,7 @@ function Zn(t) {
|
|
|
1781
1781
|
if (!S) break;
|
|
1782
1782
|
C.push(S[1]), a++;
|
|
1783
1783
|
}
|
|
1784
|
-
const w = C.map((S) => `<li>${
|
|
1784
|
+
const w = C.map((S) => `<li>${ne(S)}</li>`).join("");
|
|
1785
1785
|
n.push({ type: "block", html: `<ul class="wm-md-ul">${w}</ul>` });
|
|
1786
1786
|
continue;
|
|
1787
1787
|
}
|
|
@@ -1793,8 +1793,8 @@ function Zn(t) {
|
|
|
1793
1793
|
if (!A) break;
|
|
1794
1794
|
w.push(A[1]), a++;
|
|
1795
1795
|
}
|
|
1796
|
-
const S = w.map((A) => `<li>${
|
|
1797
|
-
n.push({ type: "block", html: `<ol class="wm-md-ol"${
|
|
1796
|
+
const S = w.map((A) => `<li>${ne(A)}</li>`).join(""), L = C !== 1 ? ` start="${C}"` : "";
|
|
1797
|
+
n.push({ type: "block", html: `<ol class="wm-md-ol"${L}>${S}</ol>` });
|
|
1798
1798
|
continue;
|
|
1799
1799
|
}
|
|
1800
1800
|
const v = /^(#{1,6})\s+(.*)$/.exec(s);
|
|
@@ -1802,11 +1802,11 @@ function Zn(t) {
|
|
|
1802
1802
|
const C = v[1].length;
|
|
1803
1803
|
n.push({
|
|
1804
1804
|
type: "block",
|
|
1805
|
-
html: `<h${C} class="wm-md-h wm-md-h${C}">${
|
|
1805
|
+
html: `<h${C} class="wm-md-h wm-md-h${C}">${ne(v[2])}</h${C}>`
|
|
1806
1806
|
}), a++;
|
|
1807
1807
|
continue;
|
|
1808
1808
|
}
|
|
1809
|
-
n.push({ type: "text", html:
|
|
1809
|
+
n.push({ type: "text", html: ne(s) }), a++;
|
|
1810
1810
|
}
|
|
1811
1811
|
let r = "";
|
|
1812
1812
|
for (let s = 0; s < n.length; s++) {
|
|
@@ -1849,7 +1849,7 @@ function as(t, e, n, a, r, s) {
|
|
|
1849
1849
|
])]);
|
|
1850
1850
|
}
|
|
1851
1851
|
const os = /* @__PURE__ */ B(rs, [["render", as], ["__scopeId", "data-v-df2447fd"]]);
|
|
1852
|
-
function
|
|
1852
|
+
function se(t) {
|
|
1853
1853
|
return t ? t.client_msg_id || t.id : "";
|
|
1854
1854
|
}
|
|
1855
1855
|
const ls = {
|
|
@@ -1861,7 +1861,7 @@ const ls = {
|
|
|
1861
1861
|
idle: "Conversation en pause"
|
|
1862
1862
|
}, cs = 80, ds = 200, us = {
|
|
1863
1863
|
name: "WmMessageList",
|
|
1864
|
-
components: { AIAvatar:
|
|
1864
|
+
components: { AIAvatar: Z, HumanAvatar: ke, Bubble: ss, Typing: os, ActionResult: Qt, AttachmentPreview: Jn, ArtifactRenderer: Un },
|
|
1865
1865
|
props: {
|
|
1866
1866
|
messages: { type: Array, default: () => [] },
|
|
1867
1867
|
streamingActive: { type: Boolean, default: !1 },
|
|
@@ -1902,7 +1902,7 @@ const ls = {
|
|
|
1902
1902
|
if (((e = s == null ? void 0 : s.payload) == null ? void 0 : e.event) === "action_admin_pending") {
|
|
1903
1903
|
const C = t[t.length - 1];
|
|
1904
1904
|
C && C.role === "ai" ? C.messages.push(s) : t.push({
|
|
1905
|
-
key: `g-${
|
|
1905
|
+
key: `g-${se(s)}`,
|
|
1906
1906
|
role: "ai",
|
|
1907
1907
|
agentName: "",
|
|
1908
1908
|
agentAvatarUrl: null,
|
|
@@ -1912,7 +1912,7 @@ const ls = {
|
|
|
1912
1912
|
continue;
|
|
1913
1913
|
}
|
|
1914
1914
|
t.push({
|
|
1915
|
-
key: `sys-${
|
|
1915
|
+
key: `sys-${se(s)}`,
|
|
1916
1916
|
role: o,
|
|
1917
1917
|
messages: [s],
|
|
1918
1918
|
items: [],
|
|
@@ -1922,7 +1922,7 @@ const ls = {
|
|
|
1922
1922
|
}
|
|
1923
1923
|
const c = t[t.length - 1];
|
|
1924
1924
|
c && c.role === o && (o === "ai" || c.agentName === (((n = s == null ? void 0 : s.author) == null ? void 0 : n.name) || "")) ? c.messages.push(s) : t.push({
|
|
1925
|
-
key: `g-${
|
|
1925
|
+
key: `g-${se(s)}`,
|
|
1926
1926
|
role: o,
|
|
1927
1927
|
agentName: ((a = s == null ? void 0 : s.author) == null ? void 0 : a.name) || "",
|
|
1928
1928
|
agentAvatarUrl: ((r = s == null ? void 0 : s.author) == null ? void 0 : r.avatar_url) || null,
|
|
@@ -1966,7 +1966,7 @@ const ls = {
|
|
|
1966
1966
|
this._lastSeenConvId = this.conversationId, this.scrollToBottom();
|
|
1967
1967
|
},
|
|
1968
1968
|
methods: {
|
|
1969
|
-
messageKey:
|
|
1969
|
+
messageKey: se,
|
|
1970
1970
|
isAtBottom(t) {
|
|
1971
1971
|
return t.scrollHeight - t.scrollTop - t.clientHeight <= cs;
|
|
1972
1972
|
},
|
|
@@ -2133,10 +2133,10 @@ const ls = {
|
|
|
2133
2133
|
// they're the last item of the cluster — BL for ai/human, BR for
|
|
2134
2134
|
// user.
|
|
2135
2135
|
cornersFor(t, e) {
|
|
2136
|
-
var
|
|
2137
|
-
const n = t.items, a = (
|
|
2138
|
-
let
|
|
2139
|
-
return o ? (w && (
|
|
2136
|
+
var P, W, G;
|
|
2137
|
+
const n = t.items, a = (P = n[e]) == null ? void 0 : P.kind, r = (W = n[e - 1]) == null ? void 0 : W.kind, s = (G = n[e + 1]) == null ? void 0 : G.kind, o = t.role === "user", c = 14, v = 4, C = (H, J) => H === "card" && J === "bubble", w = r ? r.bottom : null, S = s ? s.top : null, L = C(w, a.top), A = C(S, a.bottom);
|
|
2138
|
+
let N = c, x = c, U = c, F = c;
|
|
2139
|
+
return o ? (w && (x = v, (L || A && a.top === "bubble") && (N = v)), S && (U = v, (A || L && a.bottom === "bubble") && (F = v)), !S && a.bottom === "bubble" && (U = v)) : (w && (N = v, (L || A && a.top === "bubble") && (x = v)), S && (F = v, (A || L && a.bottom === "bubble") && (U = v)), !S && a.bottom === "bubble" && (F = v)), { tl: N, tr: x, br: U, bl: F };
|
|
2140
2140
|
},
|
|
2141
2141
|
// Inline style emitting the four corner CSS variables. Set on
|
|
2142
2142
|
// `.wm-list__row` so they cascade to Bubble/ActionResult/
|
|
@@ -2230,7 +2230,7 @@ const ls = {
|
|
|
2230
2230
|
class: "wm-list__row wm-list__row--ai fade-up"
|
|
2231
2231
|
}, Ss = { class: "wm-list__avatarSlot" };
|
|
2232
2232
|
function xs(t, e, n, a, r, s) {
|
|
2233
|
-
const o = O("AIAvatar"), c = O("HumanAvatar"), v = O("ActionResult"), C = O("ArtifactRenderer"), w = O("Bubble"), S = O("AttachmentPreview"),
|
|
2233
|
+
const o = O("AIAvatar"), c = O("HumanAvatar"), v = O("ActionResult"), C = O("ArtifactRenderer"), w = O("Bubble"), S = O("AttachmentPreview"), L = O("Typing");
|
|
2234
2234
|
return l(), d("div", {
|
|
2235
2235
|
ref: "scrollEl",
|
|
2236
2236
|
class: E(["wm-list", { "wm-list--silent": r.silentFades }]),
|
|
@@ -2248,7 +2248,7 @@ function xs(t, e, n, a, r, s) {
|
|
|
2248
2248
|
i("span", ps, b(n.dateLabel), 1),
|
|
2249
2249
|
e[3] || (e[3] = i("div", { class: "wm-list__line" }, null, -1))
|
|
2250
2250
|
])) : y("", !0),
|
|
2251
|
-
(l(!0), d(M, null, j(s.groups, (A,
|
|
2251
|
+
(l(!0), d(M, null, j(s.groups, (A, N) => (l(), d(M, {
|
|
2252
2252
|
key: A.key
|
|
2253
2253
|
}, [
|
|
2254
2254
|
A.key === s.unreadGroupKey ? (l(), d("div", _s, [...e[4] || (e[4] = [
|
|
@@ -2264,18 +2264,18 @@ function xs(t, e, n, a, r, s) {
|
|
|
2264
2264
|
i("span", gs, b(A.systemLabel), 1),
|
|
2265
2265
|
e[6] || (e[6] = i("div", { class: "wm-list__line wm-list__line--strong" }, null, -1))
|
|
2266
2266
|
])) : (l(), d(M, { key: 1 }, [
|
|
2267
|
-
(l(!0), d(M, null, j(A.items, (x,
|
|
2267
|
+
(l(!0), d(M, null, j(A.items, (x, U) => (l(), d("div", {
|
|
2268
2268
|
key: `${s.messageKey(x.message)}-${x.partKey}`,
|
|
2269
2269
|
class: E(["wm-list__row fade-up", ["wm-list__row--" + A.role, { "is-pending": x.message._pending, "is-failed": x.message._failed }]]),
|
|
2270
|
-
style:
|
|
2270
|
+
style: q(s.cornersStyle(A, U))
|
|
2271
2271
|
}, [
|
|
2272
2272
|
A.role !== "user" ? (l(), d("div", ys, [
|
|
2273
|
-
|
|
2274
|
-
A.role === "ai" ? (l(),
|
|
2273
|
+
U === A.items.length - 1 ? (l(), d(M, { key: 0 }, [
|
|
2274
|
+
A.role === "ai" ? (l(), $(o, {
|
|
2275
2275
|
key: 0,
|
|
2276
2276
|
size: 26,
|
|
2277
2277
|
tail: !0
|
|
2278
|
-
})) : (l(),
|
|
2278
|
+
})) : (l(), $(c, {
|
|
2279
2279
|
key: 1,
|
|
2280
2280
|
name: A.agentName,
|
|
2281
2281
|
"avatar-url": A.agentAvatarUrl,
|
|
@@ -2283,24 +2283,24 @@ function xs(t, e, n, a, r, s) {
|
|
|
2283
2283
|
}, null, 8, ["name", "avatar-url"]))
|
|
2284
2284
|
], 64)) : y("", !0)
|
|
2285
2285
|
])) : y("", !0),
|
|
2286
|
-
x.renderAs === "action" ? (l(),
|
|
2286
|
+
x.renderAs === "action" ? (l(), $(v, {
|
|
2287
2287
|
key: 1,
|
|
2288
2288
|
state: x.message.payload.state,
|
|
2289
2289
|
label: s.actionLabel(x.message),
|
|
2290
2290
|
detail: s.actionDetail(x.message)
|
|
2291
|
-
}, null, 8, ["state", "label", "detail"])) : x.renderAs === "admin-pending" ? (l(),
|
|
2291
|
+
}, null, 8, ["state", "label", "detail"])) : x.renderAs === "admin-pending" ? (l(), $(v, {
|
|
2292
2292
|
key: 2,
|
|
2293
2293
|
state: "awaiting",
|
|
2294
2294
|
label: "Demande d'approbation envoyée",
|
|
2295
2295
|
detail: x.message.text_md || ""
|
|
2296
|
-
}, null, 8, ["detail"])) : x.renderAs === "artifact-of-action" ? (l(),
|
|
2296
|
+
}, null, 8, ["detail"])) : x.renderAs === "artifact-of-action" ? (l(), $(C, {
|
|
2297
2297
|
key: 3,
|
|
2298
2298
|
artifact: s.actionArtifact(x.message)
|
|
2299
|
-
}, null, 8, ["artifact"])) : x.renderAs === "artifact" ? (l(),
|
|
2299
|
+
}, null, 8, ["artifact"])) : x.renderAs === "artifact" ? (l(), $(C, {
|
|
2300
2300
|
key: 4,
|
|
2301
2301
|
artifact: s.artifactOf(x.message)
|
|
2302
2302
|
}, null, 8, ["artifact"])) : (l(), d("div", ws, [
|
|
2303
|
-
x.message.text_md ? (l(),
|
|
2303
|
+
x.message.text_md ? (l(), $(w, {
|
|
2304
2304
|
key: 0,
|
|
2305
2305
|
role: A.role,
|
|
2306
2306
|
text: x.message.text_md
|
|
@@ -2309,7 +2309,7 @@ function xs(t, e, n, a, r, s) {
|
|
|
2309
2309
|
key: 1,
|
|
2310
2310
|
class: E(["wm-list__atts", { "wm-list__atts--align-end": A.role === "user" }])
|
|
2311
2311
|
}, [
|
|
2312
|
-
(l(!0), d(M, null, j(s.attachmentsOf(x.message), (F, P) => (l(),
|
|
2312
|
+
(l(!0), d(M, null, j(s.attachmentsOf(x.message), (F, P) => (l(), $(S, {
|
|
2313
2313
|
key: `${s.messageKey(x.message)}-att-${P}`,
|
|
2314
2314
|
attachment: F
|
|
2315
2315
|
}, null, 8, ["attachment"]))), 128))
|
|
@@ -2329,16 +2329,16 @@ function xs(t, e, n, a, r, s) {
|
|
|
2329
2329
|
], 64))), 128)),
|
|
2330
2330
|
n.streamingActive ? (l(), d("div", As, [
|
|
2331
2331
|
i("div", Ss, [
|
|
2332
|
-
|
|
2332
|
+
V(o, {
|
|
2333
2333
|
size: 26,
|
|
2334
2334
|
tail: !0
|
|
2335
2335
|
})
|
|
2336
2336
|
]),
|
|
2337
|
-
|
|
2337
|
+
V(L)
|
|
2338
2338
|
])) : y("", !0)
|
|
2339
2339
|
], 34);
|
|
2340
2340
|
}
|
|
2341
|
-
const Ms = /* @__PURE__ */ B(us, [["render", xs], ["__scopeId", "data-v-
|
|
2341
|
+
const Ms = /* @__PURE__ */ B(us, [["render", xs], ["__scopeId", "data-v-508689eb"]]), re = typeof navigator < "u" && !!navigator.mediaDevices && typeof navigator.mediaDevices.getDisplayMedia == "function", he = typeof window < "u" && typeof window.MediaRecorder < "u";
|
|
2342
2342
|
function Ts() {
|
|
2343
2343
|
return he && [
|
|
2344
2344
|
"video/webm;codecs=vp9,opus",
|
|
@@ -2363,7 +2363,7 @@ function Ni(t) {
|
|
|
2363
2363
|
return t ? t.startsWith("image/") ? "image" : t.startsWith("video/") ? "video" : "file" : "file";
|
|
2364
2364
|
}
|
|
2365
2365
|
async function Is() {
|
|
2366
|
-
if (!
|
|
2366
|
+
if (!re) return null;
|
|
2367
2367
|
let t;
|
|
2368
2368
|
try {
|
|
2369
2369
|
t = await navigator.mediaDevices.getDisplayMedia(Ce({ audio: !1 }));
|
|
@@ -2392,7 +2392,7 @@ async function Os(t) {
|
|
|
2392
2392
|
}
|
|
2393
2393
|
async function Es(t = {}) {
|
|
2394
2394
|
var C;
|
|
2395
|
-
if (!
|
|
2395
|
+
if (!re || !he) return null;
|
|
2396
2396
|
let e;
|
|
2397
2397
|
try {
|
|
2398
2398
|
e = await navigator.mediaDevices.getDisplayMedia(Ce({ audio: !0 }));
|
|
@@ -2414,11 +2414,11 @@ async function Es(t = {}) {
|
|
|
2414
2414
|
w.data && w.data.size > 0 && r.push(w.data);
|
|
2415
2415
|
}), a.addEventListener("stop", () => {
|
|
2416
2416
|
var w, S;
|
|
2417
|
-
if (s && clearInterval(s), e.getTracks().forEach((
|
|
2418
|
-
|
|
2417
|
+
if (s && clearInterval(s), e.getTracks().forEach((L) => {
|
|
2418
|
+
L.stop();
|
|
2419
2419
|
}), r.length) {
|
|
2420
|
-
const
|
|
2421
|
-
(w = t.onfinalize) == null || w.call(t,
|
|
2420
|
+
const L = a.mimeType || n || "video/webm", A = new Blob(r, { type: L }), N = /mp4/.test(L) ? "mp4" : "webm", x = (/* @__PURE__ */ new Date()).toISOString().replace(/[:.]/g, "-").slice(0, 19), U = new File([A], `ecran-${x}.${N}`, { type: L });
|
|
2421
|
+
(w = t.onfinalize) == null || w.call(t, U);
|
|
2422
2422
|
} else
|
|
2423
2423
|
(S = t.oncancel) == null || S.call(t);
|
|
2424
2424
|
}), e.getVideoTracks().forEach((w) => {
|
|
@@ -2492,7 +2492,7 @@ const Bs = [
|
|
|
2492
2492
|
attachItems() {
|
|
2493
2493
|
return Bs.map((t) => ({
|
|
2494
2494
|
...t,
|
|
2495
|
-
disabled: t.action === "screenshot" && !
|
|
2495
|
+
disabled: t.action === "screenshot" && !re || t.action === "record" && (!re || !he)
|
|
2496
2496
|
}));
|
|
2497
2497
|
},
|
|
2498
2498
|
recordingElapsedLabel() {
|
|
@@ -2622,7 +2622,7 @@ function Ws(t, e, n, a, r, s) {
|
|
|
2622
2622
|
])) : y("", !0),
|
|
2623
2623
|
i("form", {
|
|
2624
2624
|
class: E(["wm-compose", { "has-attach": r.attachOpen }]),
|
|
2625
|
-
onSubmit: e[7] || (e[7] =
|
|
2625
|
+
onSubmit: e[7] || (e[7] = Q((...o) => s.onSubmit && s.onSubmit(...o), ["prevent"]))
|
|
2626
2626
|
}, [
|
|
2627
2627
|
i("input", {
|
|
2628
2628
|
ref: "fileEl",
|
|
@@ -2659,7 +2659,7 @@ function Ws(t, e, n, a, r, s) {
|
|
|
2659
2659
|
i("span", null, b(o.label), 1)
|
|
2660
2660
|
], 8, Us))), 128))
|
|
2661
2661
|
])) : y("", !0),
|
|
2662
|
-
|
|
2662
|
+
z(i("textarea", {
|
|
2663
2663
|
ref: "inputEl",
|
|
2664
2664
|
"onUpdate:modelValue": e[3] || (e[3] = (o) => r.local = o),
|
|
2665
2665
|
class: "wm-compose__input",
|
|
@@ -2669,7 +2669,7 @@ function Ws(t, e, n, a, r, s) {
|
|
|
2669
2669
|
onKeydown: e[4] || (e[4] = (...o) => s.onKeydown && s.onKeydown(...o)),
|
|
2670
2670
|
onInput: e[5] || (e[5] = (...o) => s.autosize && s.autosize(...o))
|
|
2671
2671
|
}, null, 40, Hs), [
|
|
2672
|
-
[
|
|
2672
|
+
[Y, r.local]
|
|
2673
2673
|
]),
|
|
2674
2674
|
i("div", zs, [
|
|
2675
2675
|
i("button", {
|
|
@@ -2745,14 +2745,14 @@ function Js(t, e, n, a, r, s) {
|
|
|
2745
2745
|
key: c,
|
|
2746
2746
|
type: "button",
|
|
2747
2747
|
class: "wm-chip",
|
|
2748
|
-
style:
|
|
2748
|
+
style: q({ animationDelay: n.baseDelay + c * n.stepDelay + "ms" }),
|
|
2749
2749
|
onClick: (v) => t.$emit("select", o)
|
|
2750
2750
|
}, b(o.label), 13, Ys))), 128))
|
|
2751
2751
|
])) : y("", !0);
|
|
2752
2752
|
}
|
|
2753
2753
|
const Xs = /* @__PURE__ */ B(Ks, [["render", Js], ["__scopeId", "data-v-55aa529d"]]), Qs = {
|
|
2754
2754
|
name: "WmApprovalCard",
|
|
2755
|
-
components: { AIAvatar:
|
|
2755
|
+
components: { AIAvatar: Z },
|
|
2756
2756
|
props: {
|
|
2757
2757
|
action: { type: String, required: !0 },
|
|
2758
2758
|
detail: { type: String, default: "" },
|
|
@@ -2792,7 +2792,7 @@ function ar(t, e, n, a, r, s) {
|
|
|
2792
2792
|
return l(), d("div", Zs, [
|
|
2793
2793
|
i("div", er, [
|
|
2794
2794
|
i("div", tr, [
|
|
2795
|
-
|
|
2795
|
+
V(o, { size: 24 })
|
|
2796
2796
|
]),
|
|
2797
2797
|
i("div", nr, [
|
|
2798
2798
|
i("div", sr, b(n.action), 1),
|
|
@@ -2827,7 +2827,7 @@ const lr = /* @__PURE__ */ new Set([
|
|
|
2827
2827
|
"date"
|
|
2828
2828
|
]), cr = {
|
|
2829
2829
|
name: "WmFormCard",
|
|
2830
|
-
components: { AIAvatar:
|
|
2830
|
+
components: { AIAvatar: Z },
|
|
2831
2831
|
props: {
|
|
2832
2832
|
form: { type: Object, required: !0 },
|
|
2833
2833
|
readOnly: { type: Boolean, default: !1 },
|
|
@@ -2931,7 +2931,7 @@ function Lr(t, e, n, a, r, s) {
|
|
|
2931
2931
|
return l(), d("div", dr, [
|
|
2932
2932
|
i("div", ur, [
|
|
2933
2933
|
i("div", hr, [
|
|
2934
|
-
|
|
2934
|
+
V(o, { size: 24 })
|
|
2935
2935
|
]),
|
|
2936
2936
|
i("div", mr, [
|
|
2937
2937
|
i("div", fr, b(n.form.title || "Formulaire"), 1),
|
|
@@ -2940,7 +2940,7 @@ function Lr(t, e, n, a, r, s) {
|
|
|
2940
2940
|
]),
|
|
2941
2941
|
i("form", {
|
|
2942
2942
|
class: "wm-form__body",
|
|
2943
|
-
onSubmit: e[0] || (e[0] =
|
|
2943
|
+
onSubmit: e[0] || (e[0] = Q((...c) => s.onSubmit && s.onSubmit(...c), ["prevent"]))
|
|
2944
2944
|
}, [
|
|
2945
2945
|
(l(!0), d(M, null, j(s.normalizedFields, (c) => (l(), d("div", {
|
|
2946
2946
|
key: c.key,
|
|
@@ -2950,10 +2950,10 @@ function Lr(t, e, n, a, r, s) {
|
|
|
2950
2950
|
for: `wm-f-${r._uid}-${c.key}`,
|
|
2951
2951
|
class: "wm-form__label"
|
|
2952
2952
|
}, [
|
|
2953
|
-
|
|
2953
|
+
ae(b(c.label), 1),
|
|
2954
2954
|
c.required ? (l(), d("span", vr, "*")) : y("", !0)
|
|
2955
2955
|
], 8, _r),
|
|
2956
|
-
c.type === "text" ?
|
|
2956
|
+
c.type === "text" ? z((l(), d("input", {
|
|
2957
2957
|
key: 0,
|
|
2958
2958
|
id: `wm-f-${r._uid}-${c.key}`,
|
|
2959
2959
|
"onUpdate:modelValue": (v) => r.values[c.key] = v,
|
|
@@ -2963,8 +2963,8 @@ function Lr(t, e, n, a, r, s) {
|
|
|
2963
2963
|
required: c.required,
|
|
2964
2964
|
disabled: n.readOnly || r.busy
|
|
2965
2965
|
}, null, 8, gr)), [
|
|
2966
|
-
[
|
|
2967
|
-
]) : c.type === "textarea" ?
|
|
2966
|
+
[Y, r.values[c.key]]
|
|
2967
|
+
]) : c.type === "textarea" ? z((l(), d("textarea", {
|
|
2968
2968
|
key: 1,
|
|
2969
2969
|
id: `wm-f-${r._uid}-${c.key}`,
|
|
2970
2970
|
"onUpdate:modelValue": (v) => r.values[c.key] = v,
|
|
@@ -2974,8 +2974,8 @@ function Lr(t, e, n, a, r, s) {
|
|
|
2974
2974
|
required: c.required,
|
|
2975
2975
|
disabled: n.readOnly || r.busy
|
|
2976
2976
|
}, null, 8, yr)), [
|
|
2977
|
-
[
|
|
2978
|
-
]) : c.type === "number" ?
|
|
2977
|
+
[Y, r.values[c.key]]
|
|
2978
|
+
]) : c.type === "number" ? z((l(), d("input", {
|
|
2979
2979
|
key: 2,
|
|
2980
2980
|
id: `wm-f-${r._uid}-${c.key}`,
|
|
2981
2981
|
"onUpdate:modelValue": (v) => r.values[c.key] = v,
|
|
@@ -2986,12 +2986,12 @@ function Lr(t, e, n, a, r, s) {
|
|
|
2986
2986
|
disabled: n.readOnly || r.busy
|
|
2987
2987
|
}, null, 8, wr)), [
|
|
2988
2988
|
[
|
|
2989
|
-
|
|
2989
|
+
Y,
|
|
2990
2990
|
r.values[c.key],
|
|
2991
2991
|
void 0,
|
|
2992
2992
|
{ number: !0 }
|
|
2993
2993
|
]
|
|
2994
|
-
]) : c.type === "date" ?
|
|
2994
|
+
]) : c.type === "date" ? z((l(), d("input", {
|
|
2995
2995
|
key: 3,
|
|
2996
2996
|
id: `wm-f-${r._uid}-${c.key}`,
|
|
2997
2997
|
"onUpdate:modelValue": (v) => r.values[c.key] = v,
|
|
@@ -3000,9 +3000,9 @@ function Lr(t, e, n, a, r, s) {
|
|
|
3000
3000
|
required: c.required,
|
|
3001
3001
|
disabled: n.readOnly || r.busy
|
|
3002
3002
|
}, null, 8, br)), [
|
|
3003
|
-
[
|
|
3003
|
+
[Y, r.values[c.key]]
|
|
3004
3004
|
]) : c.type === "boolean" ? (l(), d("label", kr, [
|
|
3005
|
-
|
|
3005
|
+
z(i("input", {
|
|
3006
3006
|
id: `wm-f-${r._uid}-${c.key}`,
|
|
3007
3007
|
"onUpdate:modelValue": (v) => r.values[c.key] = v,
|
|
3008
3008
|
type: "checkbox",
|
|
@@ -3011,7 +3011,7 @@ function Lr(t, e, n, a, r, s) {
|
|
|
3011
3011
|
[Ie, r.values[c.key]]
|
|
3012
3012
|
]),
|
|
3013
3013
|
i("span", null, b(c.placeholder || "Oui"), 1)
|
|
3014
|
-
])) : c.type === "select" ?
|
|
3014
|
+
])) : c.type === "select" ? z((l(), d("select", {
|
|
3015
3015
|
key: 5,
|
|
3016
3016
|
id: `wm-f-${r._uid}-${c.key}`,
|
|
3017
3017
|
"onUpdate:modelValue": (v) => r.values[c.key] = v,
|
|
@@ -3254,13 +3254,13 @@ function di(t, e, n, a, r, s) {
|
|
|
3254
3254
|
i("path", { d: "M21 21l-4.35-4.35M11 17a6 6 0 100-12 6 6 0 000 12z" })
|
|
3255
3255
|
])
|
|
3256
3256
|
], -1)),
|
|
3257
|
-
|
|
3257
|
+
z(i("input", {
|
|
3258
3258
|
"onUpdate:modelValue": e[3] || (e[3] = (o) => r.query = o),
|
|
3259
3259
|
type: "text",
|
|
3260
3260
|
placeholder: "Rechercher dans vos messages",
|
|
3261
3261
|
"aria-label": "Rechercher dans vos messages"
|
|
3262
3262
|
}, null, 512), [
|
|
3263
|
-
[
|
|
3263
|
+
[Y, r.query]
|
|
3264
3264
|
])
|
|
3265
3265
|
])
|
|
3266
3266
|
]),
|
|
@@ -3509,8 +3509,8 @@ function wi(t, e) {
|
|
|
3509
3509
|
if (s == null || s === "") continue;
|
|
3510
3510
|
let o;
|
|
3511
3511
|
if (Array.isArray(s)) {
|
|
3512
|
-
if (o = s.map((c) =>
|
|
3513
|
-
} else typeof s == "boolean" ? o = s ? "Oui" : "Non" : o =
|
|
3512
|
+
if (o = s.map((c) => ie(r, String(c))).join(", "), !o) continue;
|
|
3513
|
+
} else typeof s == "boolean" ? o = s ? "Oui" : "Non" : o = ie(r, String(s));
|
|
3514
3514
|
a.push(`${r.label} :
|
|
3515
3515
|
${o}`);
|
|
3516
3516
|
}
|
|
@@ -3518,7 +3518,7 @@ ${o}`);
|
|
|
3518
3518
|
|
|
3519
3519
|
`);
|
|
3520
3520
|
}
|
|
3521
|
-
function
|
|
3521
|
+
function ie(t, e) {
|
|
3522
3522
|
if (!Array.isArray(t == null ? void 0 : t.options)) return e;
|
|
3523
3523
|
const n = t.options.find((a) => (a == null ? void 0 : a.value) === e);
|
|
3524
3524
|
return (n == null ? void 0 : n.label) || e;
|
|
@@ -3531,8 +3531,8 @@ function bi(t, e) {
|
|
|
3531
3531
|
if (s == null || s === "") continue;
|
|
3532
3532
|
let o;
|
|
3533
3533
|
if (Array.isArray(s)) {
|
|
3534
|
-
if (o = s.map((v) =>
|
|
3535
|
-
} else typeof s == "boolean" ? o = s ? "Oui" : "Non" : o =
|
|
3534
|
+
if (o = s.map((v) => ie(r, String(v))).join(", "), !o) continue;
|
|
3535
|
+
} else typeof s == "boolean" ? o = s ? "Oui" : "Non" : o = ie(r, String(s));
|
|
3536
3536
|
const c = r.type === "textarea" || typeof o == "string" && (o.length > 60 || o.includes(`
|
|
3537
3537
|
`));
|
|
3538
3538
|
n.push({ label: r.label, value: o, multiline: c });
|
|
@@ -4411,8 +4411,8 @@ const ki = 450, Ci = 50, Ai = 900, Si = 12e3, xi = 300, Mi = {
|
|
|
4411
4411
|
];
|
|
4412
4412
|
for (const w of e) {
|
|
4413
4413
|
if (!w) continue;
|
|
4414
|
-
const S = ((o = w.author) == null ? void 0 : o.name) || (((c = w.author) == null ? void 0 : c.type) === "user" ? "Vous" : ((v = w.author) == null ? void 0 : v.type) === "agent_human" ? "Agent" : ((C = w.author) == null ? void 0 : C.type) === "agent_ia" ? "Assistant IA" : "Système"),
|
|
4415
|
-
A && (n.push(`[${
|
|
4414
|
+
const S = ((o = w.author) == null ? void 0 : o.name) || (((c = w.author) == null ? void 0 : c.type) === "user" ? "Vous" : ((v = w.author) == null ? void 0 : v.type) === "agent_human" ? "Agent" : ((C = w.author) == null ? void 0 : C.type) === "agent_ia" ? "Assistant IA" : "Système"), L = w.created_at ? new Date(w.created_at).toLocaleString("fr-FR") : "", A = (w.text_md || "").trim();
|
|
4415
|
+
A && (n.push(`[${L}] ${S} :`), n.push(A), n.push(""));
|
|
4416
4416
|
}
|
|
4417
4417
|
const a = new Blob([n.join(`
|
|
4418
4418
|
`)], { type: "text/plain;charset=utf-8" });
|
|
@@ -4517,11 +4517,11 @@ const ki = 450, Ci = 50, Ai = 900, Si = 12e3, xi = 300, Mi = {
|
|
|
4517
4517
|
class: "wm-attached"
|
|
4518
4518
|
}, ji = ["onClick"];
|
|
4519
4519
|
function Ui(t, e, n, a, r, s) {
|
|
4520
|
-
const o = O("Launcher"), c = O("Header"), v = O("Onboarding"), C = O("MessageList"), w = O("ApprovalCard"), S = O("FormCard"),
|
|
4520
|
+
const o = O("Launcher"), c = O("Header"), v = O("Onboarding"), C = O("MessageList"), w = O("ApprovalCard"), S = O("FormCard"), L = O("Feedback"), A = O("SuggestionChips"), N = O("Composer"), x = O("MoreMenu"), U = O("HistoryDrawer");
|
|
4521
4521
|
return l(), d("div", {
|
|
4522
4522
|
class: E(["wm-root", `wm-root--${n.displayMode}`])
|
|
4523
4523
|
}, [
|
|
4524
|
-
!r.isOpen && !s.isEmbedded ? (l(),
|
|
4524
|
+
!r.isOpen && !s.isEmbedded ? (l(), $(o, {
|
|
4525
4525
|
key: 0,
|
|
4526
4526
|
"unread-count": s.unreadCount,
|
|
4527
4527
|
peek: s.launcherPeek,
|
|
@@ -4531,7 +4531,7 @@ function Ui(t, e, n, a, r, s) {
|
|
|
4531
4531
|
r.isOpen || s.isEmbedded ? (l(), d("section", {
|
|
4532
4532
|
key: 1,
|
|
4533
4533
|
class: E(["wm-panel", `wm-panel--${n.displayMode}`]),
|
|
4534
|
-
style:
|
|
4534
|
+
style: q(r.floatHeight ? { "--wm-float-h": r.floatHeight + "px" } : null),
|
|
4535
4535
|
role: "dialog",
|
|
4536
4536
|
"aria-label": "Messenger"
|
|
4537
4537
|
}, [
|
|
@@ -4562,7 +4562,7 @@ function Ui(t, e, n, a, r, s) {
|
|
|
4562
4562
|
"aria-hidden": "true"
|
|
4563
4563
|
}, null, -1))
|
|
4564
4564
|
])) : (l(), d(M, { key: 1 }, [
|
|
4565
|
-
|
|
4565
|
+
V(c, {
|
|
4566
4566
|
title: s.headerTitle,
|
|
4567
4567
|
escalated: s.isEscalated,
|
|
4568
4568
|
"agent-name": s.humanAgentName,
|
|
@@ -4600,7 +4600,7 @@ function Ui(t, e, n, a, r, s) {
|
|
|
4600
4600
|
])
|
|
4601
4601
|
])
|
|
4602
4602
|
])) : s.currentConv ? (l(), d(M, { key: 2 }, [
|
|
4603
|
-
|
|
4603
|
+
V(C, {
|
|
4604
4604
|
ref: "messageList",
|
|
4605
4605
|
messages: s.displayedMessages,
|
|
4606
4606
|
"streaming-active": s.streamingActive,
|
|
@@ -4613,22 +4613,22 @@ function Ui(t, e, n, a, r, s) {
|
|
|
4613
4613
|
}, null, 8, ["messages", "streaming-active", "date-label", "conversation-id", "loading-more", "has-more", "unread-anchor-ts", "onLoadMore"]),
|
|
4614
4614
|
i("div", Bi, [
|
|
4615
4615
|
s.floatVisible ? (l(), d("div", Li, [
|
|
4616
|
-
s.approvalReady ? (l(),
|
|
4616
|
+
s.approvalReady ? (l(), $(w, {
|
|
4617
4617
|
key: 0,
|
|
4618
4618
|
action: s.approvalTitle,
|
|
4619
4619
|
detail: s.approvalDetail,
|
|
4620
4620
|
callbacks: s.pendingApproval.callbacks,
|
|
4621
4621
|
onCallback: s.onApprovalCallback
|
|
4622
|
-
}, null, 8, ["action", "detail", "callbacks", "onCallback"])) : s.pendingForm ? (l(),
|
|
4622
|
+
}, null, 8, ["action", "detail", "callbacks", "onCallback"])) : s.pendingForm ? (l(), $(S, {
|
|
4623
4623
|
key: s.pendingForm.message && s.pendingForm.message.id,
|
|
4624
4624
|
form: s.pendingForm.form,
|
|
4625
4625
|
onSubmit: s.onFormSubmit
|
|
4626
|
-
}, null, 8, ["form", "onSubmit"])) : s.showFeedback ? (l(),
|
|
4626
|
+
}, null, 8, ["form", "onSubmit"])) : s.showFeedback ? (l(), $(L, {
|
|
4627
4627
|
key: 2,
|
|
4628
4628
|
busy: r.feedbackBusy,
|
|
4629
4629
|
done: r.feedbackDone,
|
|
4630
4630
|
onSubmit: s.onFeedback
|
|
4631
|
-
}, null, 8, ["busy", "done", "onSubmit"])) : (l(),
|
|
4631
|
+
}, null, 8, ["busy", "done", "onSubmit"])) : (l(), $(A, {
|
|
4632
4632
|
key: 3,
|
|
4633
4633
|
items: s.suggestions,
|
|
4634
4634
|
onSelect: s.onSuggestion
|
|
@@ -4640,7 +4640,7 @@ function Ui(t, e, n, a, r, s) {
|
|
|
4640
4640
|
"aria-hidden": "true"
|
|
4641
4641
|
}, null, -1)),
|
|
4642
4642
|
i("span", $i, b(s.actionInFlightName) + " en cours, veuillez patienter…", 1)
|
|
4643
|
-
])) : (l(),
|
|
4643
|
+
])) : (l(), $(N, {
|
|
4644
4644
|
key: 2,
|
|
4645
4645
|
ref: "composer",
|
|
4646
4646
|
modelValue: r.draft,
|
|
@@ -4652,7 +4652,7 @@ function Ui(t, e, n, a, r, s) {
|
|
|
4652
4652
|
onAttach: s.onAttach
|
|
4653
4653
|
}, null, 8, ["modelValue", "placeholder", "disabled", "onSend", "onAttach"]))
|
|
4654
4654
|
]),
|
|
4655
|
-
r.moreOpen ? (l(),
|
|
4655
|
+
r.moreOpen ? (l(), $(x, {
|
|
4656
4656
|
key: 0,
|
|
4657
4657
|
"can-rename": !!s.currentConv,
|
|
4658
4658
|
"can-clear": !!s.currentConv,
|
|
@@ -4686,7 +4686,7 @@ function Ui(t, e, n, a, r, s) {
|
|
|
4686
4686
|
i("button", {
|
|
4687
4687
|
type: "button",
|
|
4688
4688
|
"aria-label": "Retirer",
|
|
4689
|
-
onClick: (
|
|
4689
|
+
onClick: (W) => r.pendingAttachments.splice(P, 1)
|
|
4690
4690
|
}, [...e[11] || (e[11] = [
|
|
4691
4691
|
i("svg", {
|
|
4692
4692
|
width: "10",
|
|
@@ -4704,7 +4704,7 @@ function Ui(t, e, n, a, r, s) {
|
|
|
4704
4704
|
])], 8, ji)
|
|
4705
4705
|
]))), 128))
|
|
4706
4706
|
])) : y("", !0)
|
|
4707
|
-
], 64)) : (l(),
|
|
4707
|
+
], 64)) : (l(), $(v, {
|
|
4708
4708
|
key: 1,
|
|
4709
4709
|
"welcome-message": s.widgetWelcomeMessage,
|
|
4710
4710
|
"agent-name": s.agentName,
|
|
@@ -4715,7 +4715,7 @@ function Ui(t, e, n, a, r, s) {
|
|
|
4715
4715
|
onSelect: s.onQuickLink,
|
|
4716
4716
|
onResume: s.onDrawerPick
|
|
4717
4717
|
}, null, 8, ["welcome-message", "agent-name", "quick-links", "unread-threads", "busy", "onStart", "onSelect", "onResume"])),
|
|
4718
|
-
r.historyOpen ? (l(),
|
|
4718
|
+
r.historyOpen ? (l(), $(U, {
|
|
4719
4719
|
key: 3,
|
|
4720
4720
|
conversations: s.drawerConversations,
|
|
4721
4721
|
"active-id": s.currentConv ? s.currentConv.id : null,
|
|
@@ -4723,7 +4723,7 @@ function Ui(t, e, n, a, r, s) {
|
|
|
4723
4723
|
onNew: s.onDrawerNew,
|
|
4724
4724
|
onPick: s.onDrawerPick
|
|
4725
4725
|
}, null, 8, ["conversations", "active-id", "onNew", "onPick"])) : y("", !0),
|
|
4726
|
-
r.moreOpen && !s.currentConv ? (l(),
|
|
4726
|
+
r.moreOpen && !s.currentConv ? (l(), $(x, {
|
|
4727
4727
|
key: 4,
|
|
4728
4728
|
"can-rename": !1,
|
|
4729
4729
|
"can-clear": !1,
|
|
@@ -4739,9 +4739,9 @@ function Ui(t, e, n, a, r, s) {
|
|
|
4739
4739
|
], 6)) : y("", !0)
|
|
4740
4740
|
], 2);
|
|
4741
4741
|
}
|
|
4742
|
-
const Pi = /* @__PURE__ */ B(Mi, [["render", Ui], ["__scopeId", "data-v-8264e504"]]), Hi = "0.2.
|
|
4742
|
+
const Pi = /* @__PURE__ */ B(Mi, [["render", Ui], ["__scopeId", "data-v-8264e504"]]), Hi = "0.2.17";
|
|
4743
4743
|
export {
|
|
4744
|
-
|
|
4744
|
+
Z as AIAvatar,
|
|
4745
4745
|
ce as AVATAR_COLORS,
|
|
4746
4746
|
Qt as ActionResult,
|
|
4747
4747
|
or as ApprovalCard,
|
|
@@ -4764,7 +4764,7 @@ export {
|
|
|
4764
4764
|
Pi as Messenger,
|
|
4765
4765
|
yi as MoreMenu,
|
|
4766
4766
|
Pt as Onboarding,
|
|
4767
|
-
|
|
4767
|
+
re as SCREEN_CAPTURE_SUPPORTED,
|
|
4768
4768
|
Xs as SuggestionChips,
|
|
4769
4769
|
ot as TeamAvatars,
|
|
4770
4770
|
os as Typing,
|
|
@@ -4772,7 +4772,7 @@ export {
|
|
|
4772
4772
|
ye as avatarColor,
|
|
4773
4773
|
we as avatarInitials,
|
|
4774
4774
|
Is as captureScreenshotFile,
|
|
4775
|
-
|
|
4775
|
+
D as colors,
|
|
4776
4776
|
De as createStore,
|
|
4777
4777
|
$e as createTransport,
|
|
4778
4778
|
Pi as default,
|