@voxket-ai/voxket-live 1.1.38 → 1.1.40
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.cjs +28 -28
- package/dist/index.css +1 -1
- package/dist/index.js +224 -219
- package/package.json +2 -1
package/dist/index.js
CHANGED
|
@@ -3207,21 +3207,21 @@ function Mx(e) {
|
|
|
3207
3207
|
$ && ($.liveStyle = !1);
|
|
3208
3208
|
};
|
|
3209
3209
|
for (const te in L) {
|
|
3210
|
-
const $ = M[te],
|
|
3210
|
+
const $ = M[te], V = O[te];
|
|
3211
3211
|
if (h.hasOwnProperty(te))
|
|
3212
3212
|
continue;
|
|
3213
3213
|
let x = !1;
|
|
3214
|
-
Cs($) && Cs(
|
|
3214
|
+
Cs($) && Cs(V) ? x = !Zh($, V) : x = $ !== V, x ? $ != null ? B(te) : f.add(te) : $ !== void 0 && f.has(te) ? B(te) : E.protectedKeys[te] = !0;
|
|
3215
3215
|
}
|
|
3216
3216
|
E.prevProp = v, E.prevResolvedValues = M, E.isActive && (h = { ...h, ...M }), r && e.blockInitialAnimation && (A = !1);
|
|
3217
3217
|
const W = T && R;
|
|
3218
3218
|
A && (!W || I) && d.push(...b.map((te) => {
|
|
3219
3219
|
const $ = { type: y };
|
|
3220
3220
|
if (typeof te == "string" && r && !W && e.manuallyAnimateOnMount && e.parent) {
|
|
3221
|
-
const { parent:
|
|
3222
|
-
if (
|
|
3221
|
+
const { parent: V } = e, x = Mr(V, te);
|
|
3222
|
+
if (V.enteringChildren && x) {
|
|
3223
3223
|
const { delayChildren: U } = x.transition || {};
|
|
3224
|
-
$.delay = Yh(
|
|
3224
|
+
$.delay = Yh(V.enteringChildren, e, U);
|
|
3225
3225
|
}
|
|
3226
3226
|
}
|
|
3227
3227
|
return {
|
|
@@ -5274,7 +5274,7 @@ const vt = (e) => {
|
|
|
5274
5274
|
"left-bottom"
|
|
5275
5275
|
], _ = () => [...C(), fe, de], T = () => ["auto", "hidden", "clip", "visible", "scroll"], R = () => ["auto", "contain", "none"], A = () => [fe, de, l], I = () => [dr, "full", "auto", ...A()], b = () => [Dn, "none", "subgrid", fe, de], M = () => ["auto", {
|
|
5276
5276
|
span: ["full", Dn, fe, de]
|
|
5277
|
-
}, Dn, fe, de], O = () => [Dn, "auto", fe, de], L = () => ["auto", "min", "max", "fr", fe, de], B = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], W = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], oe = () => ["auto", ...A()], te = () => [dr, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...A()], $ = () => [e, fe, de],
|
|
5277
|
+
}, Dn, fe, de], O = () => [Dn, "auto", fe, de], L = () => ["auto", "min", "max", "fr", fe, de], B = () => ["start", "end", "center", "between", "around", "evenly", "stretch", "baseline", "center-safe", "end-safe"], W = () => ["start", "end", "center", "stretch", "center-safe", "end-safe"], oe = () => ["auto", ...A()], te = () => [dr, "auto", "full", "dvw", "dvh", "lvw", "lvh", "svw", "svh", "min", "max", "fit", ...A()], $ = () => [e, fe, de], V = () => [...C(), $u, Bu, {
|
|
5278
5278
|
position: [fe, de]
|
|
5279
5279
|
}], x = () => ["no-repeat", {
|
|
5280
5280
|
repeat: ["", "x", "y", "space", "round"]
|
|
@@ -6247,7 +6247,7 @@ const vt = (e) => {
|
|
|
6247
6247
|
* @see https://tailwindcss.com/docs/background-position
|
|
6248
6248
|
*/
|
|
6249
6249
|
"bg-position": [{
|
|
6250
|
-
bg:
|
|
6250
|
+
bg: V()
|
|
6251
6251
|
}],
|
|
6252
6252
|
/**
|
|
6253
6253
|
* Background Repeat
|
|
@@ -6924,7 +6924,7 @@ const vt = (e) => {
|
|
|
6924
6924
|
* @see https://tailwindcss.com/docs/mask-position
|
|
6925
6925
|
*/
|
|
6926
6926
|
"mask-position": [{
|
|
6927
|
-
mask:
|
|
6927
|
+
mask: V()
|
|
6928
6928
|
}],
|
|
6929
6929
|
/**
|
|
6930
6930
|
* Mask Repeat
|
|
@@ -8531,7 +8531,7 @@ function $o({
|
|
|
8531
8531
|
showEndCall: R = !0,
|
|
8532
8532
|
onEndCall: A
|
|
8533
8533
|
}) {
|
|
8534
|
-
var
|
|
8534
|
+
var V;
|
|
8535
8535
|
const I = $t(t), [b, M] = Ae.useState(""), O = Ae.useRef(null), L = () => {
|
|
8536
8536
|
const x = b.trim();
|
|
8537
8537
|
x && C && (C(x), M(""));
|
|
@@ -8611,7 +8611,7 @@ function $o({
|
|
|
8611
8611
|
disabled: n || !b.trim(),
|
|
8612
8612
|
className: ze(
|
|
8613
8613
|
"p-2 rounded-full transition-all duration-200",
|
|
8614
|
-
b.trim() ? ((
|
|
8614
|
+
b.trim() ? ((V = I.video) == null ? void 0 : V.controlEnabled) || "bg-blue-500 text-white hover:bg-blue-600" : t === "light" ? "bg-gray-200 text-gray-400" : "bg-gray-700 text-gray-500",
|
|
8615
8615
|
n && "opacity-50 cursor-not-allowed",
|
|
8616
8616
|
b.trim() && !n && "hover:scale-105"
|
|
8617
8617
|
),
|
|
@@ -12046,7 +12046,7 @@ function qS(e, t, n) {
|
|
|
12046
12046
|
return k === null || xe(k) ? O(k) : De(k) ? (e.consume(k), M) : n(k);
|
|
12047
12047
|
}
|
|
12048
12048
|
function O(k) {
|
|
12049
|
-
return k === 45 && i === 2 ? (e.consume(k), oe) : k === 60 && i === 1 ? (e.consume(k), te) : k === 62 && i === 4 ? (e.consume(k), U) : k === 63 && i === 3 ? (e.consume(k), x) : k === 93 && i === 5 ? (e.consume(k),
|
|
12049
|
+
return k === 45 && i === 2 ? (e.consume(k), oe) : k === 60 && i === 1 ? (e.consume(k), te) : k === 62 && i === 4 ? (e.consume(k), U) : k === 63 && i === 3 ? (e.consume(k), x) : k === 93 && i === 5 ? (e.consume(k), V) : xe(k) && (i === 6 || i === 7) ? (e.exit("htmlFlowData"), e.check(WS, G, L)(k)) : k === null || xe(k) ? (e.exit("htmlFlowData"), L(k)) : (e.consume(k), O);
|
|
12050
12050
|
}
|
|
12051
12051
|
function L(k) {
|
|
12052
12052
|
return e.check(GS, B, G)(k);
|
|
@@ -12070,7 +12070,7 @@ function qS(e, t, n) {
|
|
|
12070
12070
|
}
|
|
12071
12071
|
return Ft(k) && a.length < 8 ? (e.consume(k), a += String.fromCharCode(k), $) : O(k);
|
|
12072
12072
|
}
|
|
12073
|
-
function
|
|
12073
|
+
function V(k) {
|
|
12074
12074
|
return k === 93 ? (e.consume(k), x) : O(k);
|
|
12075
12075
|
}
|
|
12076
12076
|
function x(k) {
|
|
@@ -12190,9 +12190,9 @@ function QS(e, t, n) {
|
|
|
12190
12190
|
return e.exit("htmlTextData"), e.enter("lineEnding"), e.consume(x), e.exit("lineEnding"), $;
|
|
12191
12191
|
}
|
|
12192
12192
|
function $(x) {
|
|
12193
|
-
return De(x) ? Be(e,
|
|
12193
|
+
return De(x) ? Be(e, V, "linePrefix", r.parser.constructs.disable.null.includes("codeIndented") ? void 0 : 4)(x) : V(x);
|
|
12194
12194
|
}
|
|
12195
|
-
function
|
|
12195
|
+
function V(x) {
|
|
12196
12196
|
return e.enter("htmlTextData"), a(x);
|
|
12197
12197
|
}
|
|
12198
12198
|
}
|
|
@@ -12814,7 +12814,7 @@ function $k(e, t, n) {
|
|
|
12814
12814
|
function R(M, O) {
|
|
12815
12815
|
return L;
|
|
12816
12816
|
function L(B, W, oe) {
|
|
12817
|
-
let te, $,
|
|
12817
|
+
let te, $, V, x;
|
|
12818
12818
|
return Array.isArray(B) ? (
|
|
12819
12819
|
/* c8 ignore next 1 */
|
|
12820
12820
|
G(B)
|
|
@@ -12843,7 +12843,7 @@ function $k(e, t, n) {
|
|
|
12843
12843
|
function k(X) {
|
|
12844
12844
|
return ie;
|
|
12845
12845
|
function ie(Y) {
|
|
12846
|
-
return x = I(),
|
|
12846
|
+
return x = I(), V = X, X.partial || (c.currentConstruct = X), X.name && c.parser.constructs.disable.null.includes(X.name) ? Z() : X.tokenize.call(
|
|
12847
12847
|
// If we do have fields, create an object w/ `context` as its
|
|
12848
12848
|
// prototype.
|
|
12849
12849
|
// This allows a “live binding”, which is needed for `interrupt`.
|
|
@@ -12855,7 +12855,7 @@ function $k(e, t, n) {
|
|
|
12855
12855
|
}
|
|
12856
12856
|
}
|
|
12857
12857
|
function K(X) {
|
|
12858
|
-
return M(
|
|
12858
|
+
return M(V, x), W;
|
|
12859
12859
|
}
|
|
12860
12860
|
function Z(X) {
|
|
12861
12861
|
return x.restore(), ++$ < te.length ? k(te[$]) : oe;
|
|
@@ -13093,7 +13093,7 @@ function Yk(e) {
|
|
|
13093
13093
|
htmlText: l(B),
|
|
13094
13094
|
htmlTextData: b,
|
|
13095
13095
|
image: l(te),
|
|
13096
|
-
label:
|
|
13096
|
+
label: V,
|
|
13097
13097
|
labelText: $,
|
|
13098
13098
|
lineEnding: M,
|
|
13099
13099
|
link: l(oe),
|
|
@@ -13115,7 +13115,7 @@ function Yk(e) {
|
|
|
13115
13115
|
Zp(t, (e || {}).mdastExtensions || []);
|
|
13116
13116
|
const n = {};
|
|
13117
13117
|
return r;
|
|
13118
|
-
function r(
|
|
13118
|
+
function r(z) {
|
|
13119
13119
|
let J = {
|
|
13120
13120
|
type: "root",
|
|
13121
13121
|
children: []
|
|
@@ -13131,31 +13131,31 @@ function Yk(e) {
|
|
|
13131
13131
|
data: n
|
|
13132
13132
|
}, Pe = [];
|
|
13133
13133
|
let $e = -1;
|
|
13134
|
-
for (; ++$e <
|
|
13135
|
-
if (
|
|
13136
|
-
if (
|
|
13134
|
+
for (; ++$e < z.length; )
|
|
13135
|
+
if (z[$e][1].type === "listOrdered" || z[$e][1].type === "listUnordered")
|
|
13136
|
+
if (z[$e][0] === "enter")
|
|
13137
13137
|
Pe.push($e);
|
|
13138
13138
|
else {
|
|
13139
13139
|
const Dt = Pe.pop();
|
|
13140
|
-
$e = i(
|
|
13140
|
+
$e = i(z, Dt, $e);
|
|
13141
13141
|
}
|
|
13142
|
-
for ($e = -1; ++$e <
|
|
13143
|
-
const Dt = t[
|
|
13144
|
-
Yp.call(Dt,
|
|
13145
|
-
sliceSerialize:
|
|
13146
|
-
}, we),
|
|
13142
|
+
for ($e = -1; ++$e < z.length; ) {
|
|
13143
|
+
const Dt = t[z[$e][0]];
|
|
13144
|
+
Yp.call(Dt, z[$e][1].type) && Dt[z[$e][1].type].call(Object.assign({
|
|
13145
|
+
sliceSerialize: z[$e][2].sliceSerialize
|
|
13146
|
+
}, we), z[$e][1]);
|
|
13147
13147
|
}
|
|
13148
13148
|
if (we.tokenStack.length > 0) {
|
|
13149
13149
|
const Dt = we.tokenStack[we.tokenStack.length - 1];
|
|
13150
13150
|
(Dt[1] || cd).call(we, void 0, Dt[0]);
|
|
13151
13151
|
}
|
|
13152
13152
|
for (J.position = {
|
|
13153
|
-
start: Ln(
|
|
13153
|
+
start: Ln(z.length > 0 ? z[0][1].start : {
|
|
13154
13154
|
line: 1,
|
|
13155
13155
|
column: 1,
|
|
13156
13156
|
offset: 0
|
|
13157
13157
|
}),
|
|
13158
|
-
end: Ln(
|
|
13158
|
+
end: Ln(z.length > 0 ? z[z.length - 2][1].end : {
|
|
13159
13159
|
line: 1,
|
|
13160
13160
|
column: 1,
|
|
13161
13161
|
offset: 0
|
|
@@ -13164,10 +13164,10 @@ function Yk(e) {
|
|
|
13164
13164
|
J = t.transforms[$e](J) || J;
|
|
13165
13165
|
return J;
|
|
13166
13166
|
}
|
|
13167
|
-
function i(
|
|
13167
|
+
function i(z, J, we) {
|
|
13168
13168
|
let Pe = J - 1, $e = -1, Dt = !1, an, jt, Vt, Xt;
|
|
13169
13169
|
for (; ++Pe <= we; ) {
|
|
13170
|
-
const Tt =
|
|
13170
|
+
const Tt = z[Pe];
|
|
13171
13171
|
switch (Tt[1].type) {
|
|
13172
13172
|
case "listUnordered":
|
|
13173
13173
|
case "listOrdered":
|
|
@@ -13192,13 +13192,13 @@ function Yk(e) {
|
|
|
13192
13192
|
if (an) {
|
|
13193
13193
|
let dn = Pe;
|
|
13194
13194
|
for (jt = void 0; dn--; ) {
|
|
13195
|
-
const Nt =
|
|
13195
|
+
const Nt = z[dn];
|
|
13196
13196
|
if (Nt[1].type === "lineEnding" || Nt[1].type === "lineEndingBlank") {
|
|
13197
13197
|
if (Nt[0] === "exit") continue;
|
|
13198
|
-
jt && (
|
|
13198
|
+
jt && (z[jt][1].type = "lineEndingBlank", Dt = !0), Nt[1].type = "lineEnding", jt = dn;
|
|
13199
13199
|
} else if (!(Nt[1].type === "linePrefix" || Nt[1].type === "blockQuotePrefix" || Nt[1].type === "blockQuotePrefixWhitespace" || Nt[1].type === "blockQuoteMarker" || Nt[1].type === "listItemIndent")) break;
|
|
13200
13200
|
}
|
|
13201
|
-
Vt && (!jt || Vt < jt) && (an._spread = !0), an.end = Object.assign({}, jt ?
|
|
13201
|
+
Vt && (!jt || Vt < jt) && (an._spread = !0), an.end = Object.assign({}, jt ? z[jt][1].start : Tt[1].end), z.splice(jt || Pe, 0, ["exit", an, Tt[2]]), Pe++, we++;
|
|
13202
13202
|
}
|
|
13203
13203
|
if (Tt[1].type === "listItemPrefix") {
|
|
13204
13204
|
const dn = {
|
|
@@ -13208,16 +13208,16 @@ function Yk(e) {
|
|
|
13208
13208
|
// @ts-expect-error: we’ll add `end` in a second.
|
|
13209
13209
|
end: void 0
|
|
13210
13210
|
};
|
|
13211
|
-
an = dn,
|
|
13211
|
+
an = dn, z.splice(Pe, 0, ["enter", dn, Tt[2]]), Pe++, we++, Vt = void 0, Xt = !0;
|
|
13212
13212
|
}
|
|
13213
13213
|
}
|
|
13214
13214
|
}
|
|
13215
|
-
return
|
|
13215
|
+
return z[J][1]._spread = Dt, we;
|
|
13216
13216
|
}
|
|
13217
|
-
function o(
|
|
13217
|
+
function o(z, J) {
|
|
13218
13218
|
return we;
|
|
13219
13219
|
function we(Pe) {
|
|
13220
|
-
s.call(this,
|
|
13220
|
+
s.call(this, z(Pe), Pe), J && J.call(this, Pe);
|
|
13221
13221
|
}
|
|
13222
13222
|
}
|
|
13223
13223
|
function a() {
|
|
@@ -13226,28 +13226,28 @@ function Yk(e) {
|
|
|
13226
13226
|
children: []
|
|
13227
13227
|
});
|
|
13228
13228
|
}
|
|
13229
|
-
function s(
|
|
13230
|
-
this.stack[this.stack.length - 1].children.push(
|
|
13229
|
+
function s(z, J, we) {
|
|
13230
|
+
this.stack[this.stack.length - 1].children.push(z), this.stack.push(z), this.tokenStack.push([J, we || void 0]), z.position = {
|
|
13231
13231
|
start: Ln(J.start),
|
|
13232
13232
|
// @ts-expect-error: `end` will be patched later.
|
|
13233
13233
|
end: void 0
|
|
13234
13234
|
};
|
|
13235
13235
|
}
|
|
13236
|
-
function l(
|
|
13236
|
+
function l(z) {
|
|
13237
13237
|
return J;
|
|
13238
13238
|
function J(we) {
|
|
13239
|
-
|
|
13239
|
+
z && z.call(this, we), c.call(this, we);
|
|
13240
13240
|
}
|
|
13241
13241
|
}
|
|
13242
|
-
function c(
|
|
13242
|
+
function c(z, J) {
|
|
13243
13243
|
const we = this.stack.pop(), Pe = this.tokenStack.pop();
|
|
13244
13244
|
if (Pe)
|
|
13245
|
-
Pe[0].type !==
|
|
13246
|
-
else throw new Error("Cannot close `" +
|
|
13247
|
-
start:
|
|
13248
|
-
end:
|
|
13245
|
+
Pe[0].type !== z.type && (J ? J.call(this, z, Pe[0]) : (Pe[1] || cd).call(this, z, Pe[0]));
|
|
13246
|
+
else throw new Error("Cannot close `" + z.type + "` (" + di({
|
|
13247
|
+
start: z.start,
|
|
13248
|
+
end: z.end
|
|
13249
13249
|
}) + "): it’s not open");
|
|
13250
|
-
we.position.end = Ln(
|
|
13250
|
+
we.position.end = Ln(z.end);
|
|
13251
13251
|
}
|
|
13252
13252
|
function u() {
|
|
13253
13253
|
return Vl(this.stack.pop());
|
|
@@ -13255,134 +13255,134 @@ function Yk(e) {
|
|
|
13255
13255
|
function d() {
|
|
13256
13256
|
this.data.expectingFirstListItemValue = !0;
|
|
13257
13257
|
}
|
|
13258
|
-
function f(
|
|
13258
|
+
function f(z) {
|
|
13259
13259
|
if (this.data.expectingFirstListItemValue) {
|
|
13260
13260
|
const J = this.stack[this.stack.length - 2];
|
|
13261
|
-
J.start = Number.parseInt(this.sliceSerialize(
|
|
13261
|
+
J.start = Number.parseInt(this.sliceSerialize(z), 10), this.data.expectingFirstListItemValue = void 0;
|
|
13262
13262
|
}
|
|
13263
13263
|
}
|
|
13264
13264
|
function h() {
|
|
13265
|
-
const
|
|
13266
|
-
J.lang =
|
|
13265
|
+
const z = this.resume(), J = this.stack[this.stack.length - 1];
|
|
13266
|
+
J.lang = z;
|
|
13267
13267
|
}
|
|
13268
13268
|
function m() {
|
|
13269
|
-
const
|
|
13270
|
-
J.meta =
|
|
13269
|
+
const z = this.resume(), J = this.stack[this.stack.length - 1];
|
|
13270
|
+
J.meta = z;
|
|
13271
13271
|
}
|
|
13272
13272
|
function p() {
|
|
13273
13273
|
this.data.flowCodeInside || (this.buffer(), this.data.flowCodeInside = !0);
|
|
13274
13274
|
}
|
|
13275
13275
|
function w() {
|
|
13276
|
-
const
|
|
13277
|
-
J.value =
|
|
13276
|
+
const z = this.resume(), J = this.stack[this.stack.length - 1];
|
|
13277
|
+
J.value = z.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g, ""), this.data.flowCodeInside = void 0;
|
|
13278
13278
|
}
|
|
13279
13279
|
function y() {
|
|
13280
|
-
const
|
|
13281
|
-
J.value =
|
|
13280
|
+
const z = this.resume(), J = this.stack[this.stack.length - 1];
|
|
13281
|
+
J.value = z.replace(/(\r?\n|\r)$/g, "");
|
|
13282
13282
|
}
|
|
13283
|
-
function E(
|
|
13283
|
+
function E(z) {
|
|
13284
13284
|
const J = this.resume(), we = this.stack[this.stack.length - 1];
|
|
13285
|
-
we.label = J, we.identifier = un(this.sliceSerialize(
|
|
13285
|
+
we.label = J, we.identifier = un(this.sliceSerialize(z)).toLowerCase();
|
|
13286
13286
|
}
|
|
13287
13287
|
function v() {
|
|
13288
|
-
const
|
|
13289
|
-
J.title =
|
|
13288
|
+
const z = this.resume(), J = this.stack[this.stack.length - 1];
|
|
13289
|
+
J.title = z;
|
|
13290
13290
|
}
|
|
13291
13291
|
function C() {
|
|
13292
|
-
const
|
|
13293
|
-
J.url =
|
|
13292
|
+
const z = this.resume(), J = this.stack[this.stack.length - 1];
|
|
13293
|
+
J.url = z;
|
|
13294
13294
|
}
|
|
13295
|
-
function _(
|
|
13295
|
+
function _(z) {
|
|
13296
13296
|
const J = this.stack[this.stack.length - 1];
|
|
13297
13297
|
if (!J.depth) {
|
|
13298
|
-
const we = this.sliceSerialize(
|
|
13298
|
+
const we = this.sliceSerialize(z).length;
|
|
13299
13299
|
J.depth = we;
|
|
13300
13300
|
}
|
|
13301
13301
|
}
|
|
13302
13302
|
function T() {
|
|
13303
13303
|
this.data.setextHeadingSlurpLineEnding = !0;
|
|
13304
13304
|
}
|
|
13305
|
-
function R(
|
|
13305
|
+
function R(z) {
|
|
13306
13306
|
const J = this.stack[this.stack.length - 1];
|
|
13307
|
-
J.depth = this.sliceSerialize(
|
|
13307
|
+
J.depth = this.sliceSerialize(z).codePointAt(0) === 61 ? 1 : 2;
|
|
13308
13308
|
}
|
|
13309
13309
|
function A() {
|
|
13310
13310
|
this.data.setextHeadingSlurpLineEnding = void 0;
|
|
13311
13311
|
}
|
|
13312
|
-
function I(
|
|
13312
|
+
function I(z) {
|
|
13313
13313
|
const we = this.stack[this.stack.length - 1].children;
|
|
13314
13314
|
let Pe = we[we.length - 1];
|
|
13315
13315
|
(!Pe || Pe.type !== "text") && (Pe = xt(), Pe.position = {
|
|
13316
|
-
start: Ln(
|
|
13316
|
+
start: Ln(z.start),
|
|
13317
13317
|
// @ts-expect-error: we’ll add `end` later.
|
|
13318
13318
|
end: void 0
|
|
13319
13319
|
}, we.push(Pe)), this.stack.push(Pe);
|
|
13320
13320
|
}
|
|
13321
|
-
function b(
|
|
13321
|
+
function b(z) {
|
|
13322
13322
|
const J = this.stack.pop();
|
|
13323
|
-
J.value += this.sliceSerialize(
|
|
13323
|
+
J.value += this.sliceSerialize(z), J.position.end = Ln(z.end);
|
|
13324
13324
|
}
|
|
13325
|
-
function M(
|
|
13325
|
+
function M(z) {
|
|
13326
13326
|
const J = this.stack[this.stack.length - 1];
|
|
13327
13327
|
if (this.data.atHardBreak) {
|
|
13328
13328
|
const we = J.children[J.children.length - 1];
|
|
13329
|
-
we.position.end = Ln(
|
|
13329
|
+
we.position.end = Ln(z.end), this.data.atHardBreak = void 0;
|
|
13330
13330
|
return;
|
|
13331
13331
|
}
|
|
13332
|
-
!this.data.setextHeadingSlurpLineEnding && t.canContainEols.includes(J.type) && (I.call(this,
|
|
13332
|
+
!this.data.setextHeadingSlurpLineEnding && t.canContainEols.includes(J.type) && (I.call(this, z), b.call(this, z));
|
|
13333
13333
|
}
|
|
13334
13334
|
function O() {
|
|
13335
13335
|
this.data.atHardBreak = !0;
|
|
13336
13336
|
}
|
|
13337
13337
|
function L() {
|
|
13338
|
-
const
|
|
13339
|
-
J.value =
|
|
13338
|
+
const z = this.resume(), J = this.stack[this.stack.length - 1];
|
|
13339
|
+
J.value = z;
|
|
13340
13340
|
}
|
|
13341
13341
|
function B() {
|
|
13342
|
-
const
|
|
13343
|
-
J.value =
|
|
13342
|
+
const z = this.resume(), J = this.stack[this.stack.length - 1];
|
|
13343
|
+
J.value = z;
|
|
13344
13344
|
}
|
|
13345
13345
|
function W() {
|
|
13346
|
-
const
|
|
13347
|
-
J.value =
|
|
13346
|
+
const z = this.resume(), J = this.stack[this.stack.length - 1];
|
|
13347
|
+
J.value = z;
|
|
13348
13348
|
}
|
|
13349
13349
|
function oe() {
|
|
13350
|
-
const
|
|
13350
|
+
const z = this.stack[this.stack.length - 1];
|
|
13351
13351
|
if (this.data.inReference) {
|
|
13352
13352
|
const J = this.data.referenceType || "shortcut";
|
|
13353
|
-
|
|
13353
|
+
z.type += "Reference", z.referenceType = J, delete z.url, delete z.title;
|
|
13354
13354
|
} else
|
|
13355
|
-
delete
|
|
13355
|
+
delete z.identifier, delete z.label;
|
|
13356
13356
|
this.data.referenceType = void 0;
|
|
13357
13357
|
}
|
|
13358
13358
|
function te() {
|
|
13359
|
-
const
|
|
13359
|
+
const z = this.stack[this.stack.length - 1];
|
|
13360
13360
|
if (this.data.inReference) {
|
|
13361
13361
|
const J = this.data.referenceType || "shortcut";
|
|
13362
|
-
|
|
13362
|
+
z.type += "Reference", z.referenceType = J, delete z.url, delete z.title;
|
|
13363
13363
|
} else
|
|
13364
|
-
delete
|
|
13364
|
+
delete z.identifier, delete z.label;
|
|
13365
13365
|
this.data.referenceType = void 0;
|
|
13366
13366
|
}
|
|
13367
|
-
function $(
|
|
13368
|
-
const J = this.sliceSerialize(
|
|
13367
|
+
function $(z) {
|
|
13368
|
+
const J = this.sliceSerialize(z), we = this.stack[this.stack.length - 2];
|
|
13369
13369
|
we.label = Gk(J), we.identifier = un(J).toLowerCase();
|
|
13370
13370
|
}
|
|
13371
|
-
function
|
|
13372
|
-
const
|
|
13371
|
+
function V() {
|
|
13372
|
+
const z = this.stack[this.stack.length - 1], J = this.resume(), we = this.stack[this.stack.length - 1];
|
|
13373
13373
|
if (this.data.inReference = !0, we.type === "link") {
|
|
13374
|
-
const Pe =
|
|
13374
|
+
const Pe = z.children;
|
|
13375
13375
|
we.children = Pe;
|
|
13376
13376
|
} else
|
|
13377
13377
|
we.alt = J;
|
|
13378
13378
|
}
|
|
13379
13379
|
function x() {
|
|
13380
|
-
const
|
|
13381
|
-
J.url =
|
|
13380
|
+
const z = this.resume(), J = this.stack[this.stack.length - 1];
|
|
13381
|
+
J.url = z;
|
|
13382
13382
|
}
|
|
13383
13383
|
function U() {
|
|
13384
|
-
const
|
|
13385
|
-
J.title =
|
|
13384
|
+
const z = this.resume(), J = this.stack[this.stack.length - 1];
|
|
13385
|
+
J.title = z;
|
|
13386
13386
|
}
|
|
13387
13387
|
function G() {
|
|
13388
13388
|
this.data.inReference = void 0;
|
|
@@ -13390,33 +13390,33 @@ function Yk(e) {
|
|
|
13390
13390
|
function k() {
|
|
13391
13391
|
this.data.referenceType = "collapsed";
|
|
13392
13392
|
}
|
|
13393
|
-
function K(
|
|
13393
|
+
function K(z) {
|
|
13394
13394
|
const J = this.resume(), we = this.stack[this.stack.length - 1];
|
|
13395
|
-
we.label = J, we.identifier = un(this.sliceSerialize(
|
|
13395
|
+
we.label = J, we.identifier = un(this.sliceSerialize(z)).toLowerCase(), this.data.referenceType = "full";
|
|
13396
13396
|
}
|
|
13397
|
-
function Z(
|
|
13398
|
-
this.data.characterReferenceType =
|
|
13397
|
+
function Z(z) {
|
|
13398
|
+
this.data.characterReferenceType = z.type;
|
|
13399
13399
|
}
|
|
13400
|
-
function X(
|
|
13401
|
-
const J = this.sliceSerialize(
|
|
13400
|
+
function X(z) {
|
|
13401
|
+
const J = this.sliceSerialize(z), we = this.data.characterReferenceType;
|
|
13402
13402
|
let Pe;
|
|
13403
13403
|
we ? (Pe = $p(J, we === "characterReferenceMarkerNumeric" ? 10 : 16), this.data.characterReferenceType = void 0) : Pe = zl(J);
|
|
13404
13404
|
const $e = this.stack[this.stack.length - 1];
|
|
13405
13405
|
$e.value += Pe;
|
|
13406
13406
|
}
|
|
13407
|
-
function ie(
|
|
13407
|
+
function ie(z) {
|
|
13408
13408
|
const J = this.stack.pop();
|
|
13409
|
-
J.position.end = Ln(
|
|
13409
|
+
J.position.end = Ln(z.end);
|
|
13410
13410
|
}
|
|
13411
|
-
function Y(
|
|
13412
|
-
b.call(this,
|
|
13411
|
+
function Y(z) {
|
|
13412
|
+
b.call(this, z);
|
|
13413
13413
|
const J = this.stack[this.stack.length - 1];
|
|
13414
|
-
J.url = this.sliceSerialize(
|
|
13414
|
+
J.url = this.sliceSerialize(z);
|
|
13415
13415
|
}
|
|
13416
|
-
function re(
|
|
13417
|
-
b.call(this,
|
|
13416
|
+
function re(z) {
|
|
13417
|
+
b.call(this, z);
|
|
13418
13418
|
const J = this.stack[this.stack.length - 1];
|
|
13419
|
-
J.url = "mailto:" + this.sliceSerialize(
|
|
13419
|
+
J.url = "mailto:" + this.sliceSerialize(z);
|
|
13420
13420
|
}
|
|
13421
13421
|
function j() {
|
|
13422
13422
|
return {
|
|
@@ -13488,19 +13488,19 @@ function Yk(e) {
|
|
|
13488
13488
|
children: []
|
|
13489
13489
|
};
|
|
13490
13490
|
}
|
|
13491
|
-
function ft(
|
|
13491
|
+
function ft(z) {
|
|
13492
13492
|
return {
|
|
13493
13493
|
type: "list",
|
|
13494
|
-
ordered:
|
|
13494
|
+
ordered: z.type === "listOrdered",
|
|
13495
13495
|
start: null,
|
|
13496
|
-
spread:
|
|
13496
|
+
spread: z._spread,
|
|
13497
13497
|
children: []
|
|
13498
13498
|
};
|
|
13499
13499
|
}
|
|
13500
|
-
function _t(
|
|
13500
|
+
function _t(z) {
|
|
13501
13501
|
return {
|
|
13502
13502
|
type: "listItem",
|
|
13503
|
-
spread:
|
|
13503
|
+
spread: z._spread,
|
|
13504
13504
|
checked: null,
|
|
13505
13505
|
children: []
|
|
13506
13506
|
};
|
|
@@ -22074,9 +22074,9 @@ const Bd = "[A-Za-z$_][0-9A-Za-z$_]*", cN = [
|
|
|
22074
22074
|
Pg
|
|
22075
22075
|
);
|
|
22076
22076
|
function hN(e) {
|
|
22077
|
-
const t = e.regex, n = ($, { after:
|
|
22077
|
+
const t = e.regex, n = ($, { after: V }) => {
|
|
22078
22078
|
const x = "</" + $[0].slice(1);
|
|
22079
|
-
return $.input.indexOf(x,
|
|
22079
|
+
return $.input.indexOf(x, V) !== -1;
|
|
22080
22080
|
}, r = Bd, i = {
|
|
22081
22081
|
begin: "<>",
|
|
22082
22082
|
end: "</>"
|
|
@@ -22087,7 +22087,7 @@ function hN(e) {
|
|
|
22087
22087
|
* @param {RegExpMatchArray} match
|
|
22088
22088
|
* @param {CallbackResponse} response
|
|
22089
22089
|
*/
|
|
22090
|
-
isTrulyOpeningTag: ($,
|
|
22090
|
+
isTrulyOpeningTag: ($, V) => {
|
|
22091
22091
|
const x = $[0].length + $.index, U = $.input[x];
|
|
22092
22092
|
if (
|
|
22093
22093
|
// HTML should not include another raw `<` inside a tag
|
|
@@ -22097,18 +22097,18 @@ function hN(e) {
|
|
|
22097
22097
|
// `<T, A extends keyof T, V>`
|
|
22098
22098
|
U === ","
|
|
22099
22099
|
) {
|
|
22100
|
-
|
|
22100
|
+
V.ignoreMatch();
|
|
22101
22101
|
return;
|
|
22102
22102
|
}
|
|
22103
|
-
U === ">" && (n($, { after: x }) ||
|
|
22103
|
+
U === ">" && (n($, { after: x }) || V.ignoreMatch());
|
|
22104
22104
|
let G;
|
|
22105
22105
|
const k = $.input.substring(x);
|
|
22106
22106
|
if (G = k.match(/^\s*=/)) {
|
|
22107
|
-
|
|
22107
|
+
V.ignoreMatch();
|
|
22108
22108
|
return;
|
|
22109
22109
|
}
|
|
22110
22110
|
if ((G = k.match(/^\s+extends\s+/)) && G.index === 0) {
|
|
22111
|
-
|
|
22111
|
+
V.ignoreMatch();
|
|
22112
22112
|
return;
|
|
22113
22113
|
}
|
|
22114
22114
|
}
|
|
@@ -28857,7 +28857,7 @@ function nA(e) {
|
|
|
28857
28857
|
]
|
|
28858
28858
|
}
|
|
28859
28859
|
] }
|
|
28860
|
-
},
|
|
28860
|
+
}, V = {
|
|
28861
28861
|
scope: "keyword",
|
|
28862
28862
|
match: qe(/@/, Lt(...eA), ni(Lt(/\(/, /\s+/)))
|
|
28863
28863
|
}, x = {
|
|
@@ -28865,7 +28865,7 @@ function nA(e) {
|
|
|
28865
28865
|
match: qe(/@/, gn)
|
|
28866
28866
|
}, U = [
|
|
28867
28867
|
$,
|
|
28868
|
-
|
|
28868
|
+
V,
|
|
28869
28869
|
x
|
|
28870
28870
|
], G = {
|
|
28871
28871
|
match: ni(/\b[A-Z]/),
|
|
@@ -29287,9 +29287,9 @@ const Ao = "[A-Za-z$_][0-9A-Za-z$_]*", Ug = [
|
|
|
29287
29287
|
Wg
|
|
29288
29288
|
);
|
|
29289
29289
|
function rA(e) {
|
|
29290
|
-
const t = e.regex, n = ($, { after:
|
|
29290
|
+
const t = e.regex, n = ($, { after: V }) => {
|
|
29291
29291
|
const x = "</" + $[0].slice(1);
|
|
29292
|
-
return $.input.indexOf(x,
|
|
29292
|
+
return $.input.indexOf(x, V) !== -1;
|
|
29293
29293
|
}, r = Ao, i = {
|
|
29294
29294
|
begin: "<>",
|
|
29295
29295
|
end: "</>"
|
|
@@ -29300,7 +29300,7 @@ function rA(e) {
|
|
|
29300
29300
|
* @param {RegExpMatchArray} match
|
|
29301
29301
|
* @param {CallbackResponse} response
|
|
29302
29302
|
*/
|
|
29303
|
-
isTrulyOpeningTag: ($,
|
|
29303
|
+
isTrulyOpeningTag: ($, V) => {
|
|
29304
29304
|
const x = $[0].length + $.index, U = $.input[x];
|
|
29305
29305
|
if (
|
|
29306
29306
|
// HTML should not include another raw `<` inside a tag
|
|
@@ -29310,18 +29310,18 @@ function rA(e) {
|
|
|
29310
29310
|
// `<T, A extends keyof T, V>`
|
|
29311
29311
|
U === ","
|
|
29312
29312
|
) {
|
|
29313
|
-
|
|
29313
|
+
V.ignoreMatch();
|
|
29314
29314
|
return;
|
|
29315
29315
|
}
|
|
29316
|
-
U === ">" && (n($, { after: x }) ||
|
|
29316
|
+
U === ">" && (n($, { after: x }) || V.ignoreMatch());
|
|
29317
29317
|
let G;
|
|
29318
29318
|
const k = $.input.substring(x);
|
|
29319
29319
|
if (G = k.match(/^\s*=/)) {
|
|
29320
|
-
|
|
29320
|
+
V.ignoreMatch();
|
|
29321
29321
|
return;
|
|
29322
29322
|
}
|
|
29323
29323
|
if ((G = k.match(/^\s+extends\s+/)) && G.index === 0) {
|
|
29324
|
-
|
|
29324
|
+
V.ignoreMatch();
|
|
29325
29325
|
return;
|
|
29326
29326
|
}
|
|
29327
29327
|
}
|
|
@@ -30894,7 +30894,7 @@ function uA() {
|
|
|
30894
30894
|
// look for 3 words in a row
|
|
30895
30895
|
}
|
|
30896
30896
|
), le;
|
|
30897
|
-
},
|
|
30897
|
+
}, V = $("//", "$"), x = $("/\\*", "\\*/"), U = $("#", "$"), G = {
|
|
30898
30898
|
scope: "number",
|
|
30899
30899
|
begin: I,
|
|
30900
30900
|
relevance: 0
|
|
@@ -30940,7 +30940,7 @@ function uA() {
|
|
|
30940
30940
|
BINARY_NUMBER_RE: M,
|
|
30941
30941
|
COMMENT: $,
|
|
30942
30942
|
C_BLOCK_COMMENT_MODE: x,
|
|
30943
|
-
C_LINE_COMMENT_MODE:
|
|
30943
|
+
C_LINE_COMMENT_MODE: V,
|
|
30944
30944
|
C_NUMBER_MODE: k,
|
|
30945
30945
|
C_NUMBER_RE: b,
|
|
30946
30946
|
END_SAME_AS_BEGIN: function(S) {
|
|
@@ -31047,7 +31047,7 @@ function uA() {
|
|
|
31047
31047
|
console.error(S);
|
|
31048
31048
|
}, Xe = (S, ...F) => {
|
|
31049
31049
|
console.log(`WARN: ${S}`, ...F);
|
|
31050
|
-
},
|
|
31050
|
+
}, z = (S, F) => {
|
|
31051
31051
|
ce[`${S}/${F}`] || (console.log(`Deprecated as of ${S}. ${F}`), ce[`${S}/${F}`] = !0);
|
|
31052
31052
|
}, J = new Error();
|
|
31053
31053
|
function we(S, F, { key: q }) {
|
|
@@ -31234,7 +31234,7 @@ function uA() {
|
|
|
31234
31234
|
}
|
|
31235
31235
|
function mt(ee, ye, Fe) {
|
|
31236
31236
|
let nt = "", wt = "";
|
|
31237
|
-
typeof ye == "object" ? (nt = ee, Fe = ye.ignoreIllegals, wt = ye.language) : (
|
|
31237
|
+
typeof ye == "object" ? (nt = ee, Fe = ye.ignoreIllegals, wt = ye.language) : (z("10.7.0", "highlight(lang, code, ...args) has been deprecated."), z("10.7.0", `Please use highlight(code, options) instead.
|
|
31238
31238
|
https://github.com/highlightjs/highlight.js/issues/2277`), wt = ee, nt = ye), Fe === void 0 && (Fe = !0);
|
|
31239
31239
|
const sn = {
|
|
31240
31240
|
code: nt,
|
|
@@ -31503,10 +31503,10 @@ https://github.com/highlightjs/highlight.js/issues/2277`), wt = ee, nt = ye), Fe
|
|
|
31503
31503
|
ue = cr(ue, ee);
|
|
31504
31504
|
}
|
|
31505
31505
|
const Cm = () => {
|
|
31506
|
-
Pi(),
|
|
31506
|
+
Pi(), z("10.6.0", "initHighlighting() deprecated. Use highlightAll() now.");
|
|
31507
31507
|
};
|
|
31508
31508
|
function Tm() {
|
|
31509
|
-
Pi(),
|
|
31509
|
+
Pi(), z("10.6.0", "initHighlightingOnLoad() deprecated. Use highlightAll() now.");
|
|
31510
31510
|
}
|
|
31511
31511
|
let dc = !1;
|
|
31512
31512
|
function Pi() {
|
|
@@ -31577,7 +31577,7 @@ https://github.com/highlightjs/highlight.js/issues/2277`), wt = ee, nt = ye), Fe
|
|
|
31577
31577
|
});
|
|
31578
31578
|
}
|
|
31579
31579
|
function Pm(ee) {
|
|
31580
|
-
return
|
|
31580
|
+
return z("10.7.0", "highlightBlock will be removed entirely in v12.0"), z("10.7.0", "Please use highlightElement now."), aa(ee);
|
|
31581
31581
|
}
|
|
31582
31582
|
Object.assign(S, {
|
|
31583
31583
|
highlight: mt,
|
|
@@ -31864,7 +31864,7 @@ function xA({ message: e, theme: t, isOwn: n, isStreaming: r = !1 }) {
|
|
|
31864
31864
|
var d, f;
|
|
31865
31865
|
return ((d = e == null ? void 0 : e.metadata) == null ? void 0 : d.format) === "markdown" || ((f = e == null ? void 0 : e.metadata) == null ? void 0 : f.markdown) === !0 || iE(e.content);
|
|
31866
31866
|
}, [e.content, e.metadata]), s = D.useMemo(() => a ? oE(e.content) : e.content, [e.content, a]), l = D.useMemo(() => nE(t), [t]);
|
|
31867
|
-
return /* @__PURE__ */ g("div", { className: `flex w-full ${n ? "justify-end" : "justify-start"} mb-4 px-
|
|
31867
|
+
return /* @__PURE__ */ g("div", { className: `flex w-full ${n ? "justify-end" : "justify-start"} mb-4 px-3`, children: /* @__PURE__ */ N("div", { className: `relative group ${n ? "flex-row-reverse" : "flex-row"} flex items-end gap-3 w-full min-w-0`, children: [
|
|
31868
31868
|
/* @__PURE__ */ g(
|
|
31869
31869
|
"div",
|
|
31870
31870
|
{
|
|
@@ -31876,14 +31876,14 @@ function xA({ message: e, theme: t, isOwn: n, isStreaming: r = !1 }) {
|
|
|
31876
31876
|
"div",
|
|
31877
31877
|
{
|
|
31878
31878
|
className: `
|
|
31879
|
-
relative px-3 py-2 rounded-2xl break-words shadow-lg backdrop-blur-sm message-bubble message-hover min-w-0 max-w-
|
|
31879
|
+
relative px-3 py-2 rounded-2xl break-words shadow-lg backdrop-blur-sm message-bubble message-hover min-w-0 max-w-[85%] overflow-hidden
|
|
31880
31880
|
${n ? `${i.chatMessage.own} rounded-br-md` : `${i.chatMessage.other} rounded-bl-md`}
|
|
31881
31881
|
${r ? "shimmer" : ""}
|
|
31882
31882
|
transition-all duration-200 group-hover:scale-[1.02]
|
|
31883
31883
|
`,
|
|
31884
31884
|
style: { wordWrap: "break-word", overflowWrap: "anywhere", wordBreak: "break-word", hyphens: "auto" },
|
|
31885
31885
|
children: [
|
|
31886
|
-
/* @__PURE__ */ g("div", { className: "leading-relaxed text-sm overflow-hidden", children: ((c = e.metadata) == null ? void 0 : c.type) === "attachment" ? /* @__PURE__ */ g(tE, { message: e, theme: t, isOwn: n }) : r && !n ? /* @__PURE__ */ g(
|
|
31886
|
+
/* @__PURE__ */ g("div", { className: "leading-relaxed text-sm overflow-hidden min-w-0", children: ((c = e.metadata) == null ? void 0 : c.type) === "attachment" ? /* @__PURE__ */ g(tE, { message: e, theme: t, isOwn: n }) : r && !n ? /* @__PURE__ */ g(
|
|
31887
31887
|
Qv,
|
|
31888
31888
|
{
|
|
31889
31889
|
text: e.content,
|
|
@@ -31899,7 +31899,7 @@ function xA({ message: e, theme: t, isOwn: n, isStreaming: r = !1 }) {
|
|
|
31899
31899
|
components: l,
|
|
31900
31900
|
children: s
|
|
31901
31901
|
}
|
|
31902
|
-
) : /* @__PURE__ */ g("span", { className: "whitespace-pre-wrap break-words", children: rE(e.content, t) }) }),
|
|
31902
|
+
) : /* @__PURE__ */ g("span", { className: "whitespace-pre-wrap break-words", style: { overflowWrap: "anywhere", wordBreak: "break-word" }, children: rE(e.content, t) }) }),
|
|
31903
31903
|
/* @__PURE__ */ g("div", { className: "text-xs", children: e.timestamp.toLocaleTimeString([], {
|
|
31904
31904
|
hour: "2-digit",
|
|
31905
31905
|
minute: "2-digit"
|
|
@@ -32095,7 +32095,7 @@ function Jl({
|
|
|
32095
32095
|
smartScrollToBottom: I,
|
|
32096
32096
|
handleScroll: b,
|
|
32097
32097
|
scrollToBottom: M
|
|
32098
|
-
} = TA(), { isMobile: O, isFullscreen: L, setIsFullscreen: B } = NA(), [W, oe] = D.useState(/* @__PURE__ */ new Set()), [te, $] = D.useState([]),
|
|
32098
|
+
} = TA(), { isMobile: O, isFullscreen: L, setIsFullscreen: B } = NA(), [W, oe] = D.useState(/* @__PURE__ */ new Set()), [te, $] = D.useState([]), V = $t(t);
|
|
32099
32099
|
D.useEffect(() => (L && O && (document.body.style.overflow = "hidden", document.body.style.position = "fixed", document.body.style.width = "100%", document.body.style.height = "100%", document.documentElement.requestFullscreen && document.documentElement.requestFullscreen().catch(console.log)), () => {
|
|
32100
32100
|
L && O && (document.body.style.overflow = "unset", document.body.style.position = "unset", document.body.style.width = "unset", document.body.style.height = "unset", document.fullscreenElement && document.exitFullscreen().catch(console.log));
|
|
32101
32101
|
}), [L, O]);
|
|
@@ -32348,7 +32348,7 @@ function Jl({
|
|
|
32348
32348
|
e.off("suggested.response", P);
|
|
32349
32349
|
};
|
|
32350
32350
|
}, [e]);
|
|
32351
|
-
const X = L && O ? "fullscreen" : i, ie = X === "fullscreen" ? L && O ?
|
|
32351
|
+
const X = L && O ? "fullscreen" : i, ie = X === "fullscreen" ? L && O ? `fixed inset-0 z-[9999] flex flex-col h-[100svh] w-screen min-h-0 ${V.main}` : "flex flex-col h-full w-full max-w-none" : "flex flex-col h-full w-full backdrop-blur-sm max-h-full overflow-hidden contain-layout", Y = X === "fullscreen" ? L && O ? `flex items-center w-full justify-between px-3 h-11 ${V.chatHeader.container} border-b` : `flex items-center w-full justify-between px-5 h-12 border-b ${V.chatHeader.container}` : `flex items-center w-full justify-between px-4 h-12 border-b ${V.chatHeader.container}`, re = X === "fullscreen" ? L && O ? "flex-1 overflow-y-auto overflow-x-hidden scrollbar-hide p-4 w-full max-w-none chat-scrollable min-h-0" : "flex-1 overflow-y-auto overflow-x-hidden scrollbar-hide p-6 w-full max-w-none chat-scrollable min-h-0" : "flex-1 overflow-y-auto overflow-x-hidden scrollbar-hide w-full p-4 chat-scrollable min-h-0", j = "flex-shrink-0 !w-full", ve = () => {
|
|
32352
32352
|
B(!1), n && n();
|
|
32353
32353
|
};
|
|
32354
32354
|
return /* @__PURE__ */ N("div", { className: `${ie} relative`, children: [
|
|
@@ -32357,8 +32357,8 @@ function Jl({
|
|
|
32357
32357
|
/* @__PURE__ */ g(
|
|
32358
32358
|
"h3",
|
|
32359
32359
|
{
|
|
32360
|
-
className: `!font-semibold !text-sm leading-tight ${L && O ? "
|
|
32361
|
-
children: "
|
|
32360
|
+
className: `!font-semibold !text-sm pl-3 leading-tight ${L && O ? "" : V.text.primary}`,
|
|
32361
|
+
children: "Transcription"
|
|
32362
32362
|
}
|
|
32363
32363
|
),
|
|
32364
32364
|
E === "idle" && /* @__PURE__ */ g("span", { className: `px-2 py-1 text-xs rounded-full ${t === "light" ? "bg-gray-100 text-gray-600" : "bg-gray-700 text-gray-400"}`, children: "Idle" })
|
|
@@ -32408,7 +32408,7 @@ function Jl({
|
|
|
32408
32408
|
"div",
|
|
32409
32409
|
{
|
|
32410
32410
|
ref: T,
|
|
32411
|
-
className: `${re}
|
|
32411
|
+
className: `${re}`,
|
|
32412
32412
|
style: {
|
|
32413
32413
|
scrollBehavior: "smooth",
|
|
32414
32414
|
scrollbarWidth: "none",
|
|
@@ -32416,7 +32416,7 @@ function Jl({
|
|
|
32416
32416
|
overscrollBehavior: "contain"
|
|
32417
32417
|
},
|
|
32418
32418
|
onScroll: b,
|
|
32419
|
-
children: d.length === 0 ? /* @__PURE__ */ N("div", { className: "flex flex-col items-center justify-center
|
|
32419
|
+
children: d.length === 0 ? /* @__PURE__ */ N("div", { className: "flex flex-col items-center justify-center h-full text-center py-12", children: [
|
|
32420
32420
|
/* @__PURE__ */ g(
|
|
32421
32421
|
Re.div,
|
|
32422
32422
|
{
|
|
@@ -32432,15 +32432,15 @@ function Jl({
|
|
|
32432
32432
|
children: G
|
|
32433
32433
|
}
|
|
32434
32434
|
),
|
|
32435
|
-
/* @__PURE__ */ N("p", { className: `text-base mb-2 ${L && O ? "text-white" :
|
|
32435
|
+
/* @__PURE__ */ N("p", { className: `text-base mb-2 ${L && O ? "text-white" : V.text.secondary}`, children: [
|
|
32436
32436
|
U,
|
|
32437
32437
|
" is joining..."
|
|
32438
32438
|
] }),
|
|
32439
|
-
/* @__PURE__ */ g("p", { className: `text-xs ${L && O ? "text-gray-300" :
|
|
32440
|
-
] }) : /* @__PURE__ */ g("div", { className: "w-full space-y-3 py-4
|
|
32439
|
+
/* @__PURE__ */ g("p", { className: `text-xs ${L && O ? "text-gray-300" : V.text.muted}`, children: "Your conversation will begin shortly" })
|
|
32440
|
+
] }) : /* @__PURE__ */ g("div", { className: "w-full space-y-3 py-4 px-2", children: /* @__PURE__ */ N("div", { className: "space-y-3", children: [
|
|
32441
32441
|
d.map((P, ne) => {
|
|
32442
32442
|
var Ee, he, ae, me;
|
|
32443
|
-
return /* @__PURE__ */ g("div", { children: ((Ee = P.metadata) == null ? void 0 : Ee.type) === "successView" ? /* @__PURE__ */ g("div", { className: "flex w-full justify-end mb-4 px-
|
|
32443
|
+
return /* @__PURE__ */ g("div", { children: ((Ee = P.metadata) == null ? void 0 : Ee.type) === "successView" ? /* @__PURE__ */ g("div", { className: "flex w-full justify-end mb-4 px-3", children: /* @__PURE__ */ N("div", { className: "relative group flex-row-reverse flex items-end gap-3 w-full min-w-0", children: [
|
|
32444
32444
|
/* @__PURE__ */ g(
|
|
32445
32445
|
Re.div,
|
|
32446
32446
|
{
|
|
@@ -32451,36 +32451,36 @@ function Jl({
|
|
|
32451
32451
|
children: G
|
|
32452
32452
|
}
|
|
32453
32453
|
),
|
|
32454
|
-
/* @__PURE__ */ N("div", { className: `flex h-full flex-col justify-between border px-3 py-2 rounded-2xl shadow-lg backdrop-bl-sm message-bubble rounded-br-md message-hover border-gray-200 dark:border-gray-700 ${
|
|
32454
|
+
/* @__PURE__ */ N("div", { className: `flex h-full flex-col justify-between border px-3 py-2 rounded-2xl shadow-lg backdrop-bl-sm message-bubble rounded-br-md message-hover border-gray-200 dark:border-gray-700 ${V.chatMessage.own} min-w-0 max-w-[85%] break-words overflow-hidden`, style: { overflowWrap: "anywhere", wordBreak: "break-word", hyphens: "auto" }, children: [
|
|
32455
32455
|
P.metadata.view,
|
|
32456
|
-
/* @__PURE__ */ g("div", { className: `text-xs ${
|
|
32456
|
+
/* @__PURE__ */ g("div", { className: `text-xs ${V.text.muted} mt-1 opacity-0 group-hover:opacity-100 transition-opacity duration-200`, children: P.timestamp.toLocaleTimeString([], {
|
|
32457
32457
|
hour: "2-digit",
|
|
32458
32458
|
minute: "2-digit"
|
|
32459
32459
|
}) })
|
|
32460
32460
|
] })
|
|
32461
|
-
] }) }) : ((he = P.metadata) == null ? void 0 : he.type) === "timeoutView" ? /* @__PURE__ */ g("div", { className: "flex w-full justify-start mb-4 px-
|
|
32461
|
+
] }) }) : ((he = P.metadata) == null ? void 0 : he.type) === "timeoutView" ? /* @__PURE__ */ g("div", { className: "flex w-full justify-start mb-4 px-3", children: /* @__PURE__ */ N("div", { className: "relative group flex-row flex items-end gap-3 w-full min-w-0", children: [
|
|
32462
32462
|
/* @__PURE__ */ g("div", { className: `w-6 h-6 rounded-full flex items-center justify-center text-white text-xs font-semibold flex-shrink-0 shadow-lg ${t === "light" ? "bg-gradient-to-br from-blue-500 to-purple-600" : "bg-gradient-to-br from-gray-600 to_gray-700"}`, children: G }),
|
|
32463
|
-
/* @__PURE__ */ N("div", { className: `flex h-full flex-col justify-between border px-3 py-2 rounded-2xl shadow-lg backdrop-bl-sm message-bubble rounded-bl-md message-hover border-gray-200 dark:border-gray-700 ${
|
|
32463
|
+
/* @__PURE__ */ N("div", { className: `flex h-full flex-col justify-between border px-3 py-2 rounded-2xl shadow-lg backdrop-bl-sm message-bubble rounded-bl-md message-hover border-gray-200 dark:border-gray-700 ${V.chatMessage.other} min-w-0 max-w-[85%] break-words overflow-hidden`, style: { overflowWrap: "anywhere", wordBreak: "break-word", hyphens: "auto" }, children: [
|
|
32464
32464
|
P.metadata.view,
|
|
32465
|
-
/* @__PURE__ */ g("div", { className: `text-xs ${
|
|
32465
|
+
/* @__PURE__ */ g("div", { className: `text-xs ${V.text.muted} mt-1 opacity-0 group-hover:opacity-100 transition-opacity duration-200`, children: P.timestamp.toLocaleTimeString([], {
|
|
32466
32466
|
hour: "2-digit",
|
|
32467
32467
|
minute: "2-digit"
|
|
32468
32468
|
}) })
|
|
32469
32469
|
] })
|
|
32470
|
-
] }) }) : ((ae = P.metadata) == null ? void 0 : ae.type) === "visualization" ? /* @__PURE__ */ g("div", { className: "flex w-full justify-start mb-4 px-
|
|
32470
|
+
] }) }) : ((ae = P.metadata) == null ? void 0 : ae.type) === "visualization" ? /* @__PURE__ */ g("div", { className: "flex w-full justify-start mb-4 px-3", children: /* @__PURE__ */ N("div", { className: "relative group flex-row flex items-end gap-3 w-full min-w-0", children: [
|
|
32471
32471
|
/* @__PURE__ */ g("div", { className: `w-6 h-6 rounded-full flex items-center justify-center text-white text-xs font-semibold flex-shrink-0 shadow-lg ${t === "light" ? "bg-gradient-to-br from-blue-500 to-purple-600" : "bg-gradient-to-br from-gray-600 to_gray-700"}`, children: G }),
|
|
32472
|
-
/* @__PURE__ */ N("div", { className: `flex h-full flex-col justify-between border px-3 py-2 rounded-2xl shadow-lg backdrop-bl-sm message-bubble rounded-bl-md message-hover border-gray-200 dark:border-gray-700 ${
|
|
32472
|
+
/* @__PURE__ */ N("div", { className: `flex h-full flex-col justify-between border px-3 py-2 rounded-2xl shadow-lg backdrop-bl-sm message-bubble rounded-bl-md message-hover border-gray-200 dark:border-gray-700 ${V.chatMessage.other} min-w-0 max-w-[85%] break-words overflow-hidden`, style: { overflowWrap: "anywhere", wordBreak: "break-word", hyphens: "auto" }, children: [
|
|
32473
32473
|
P.metadata.view,
|
|
32474
|
-
/* @__PURE__ */ g("div", { className: `text-xs ${
|
|
32474
|
+
/* @__PURE__ */ g("div", { className: `text-xs ${V.text.muted} mt-1 opacity-70 transition-opacity duration-200`, children: P.timestamp.toLocaleTimeString([], {
|
|
32475
32475
|
hour: "2-digit",
|
|
32476
32476
|
minute: "2-digit"
|
|
32477
32477
|
}) })
|
|
32478
32478
|
] })
|
|
32479
|
-
] }) }) : ((me = P.metadata) == null ? void 0 : me.type) === "toolExecution" ? /* @__PURE__ */ g("div", { className: "flex w-full justify-start mb-4 px-
|
|
32479
|
+
] }) }) : ((me = P.metadata) == null ? void 0 : me.type) === "toolExecution" ? /* @__PURE__ */ g("div", { className: "flex w-full justify-start mb-4 px-3", children: /* @__PURE__ */ N("div", { className: "relative group flex-row flex items-end gap-3 w-full min-w-0", children: [
|
|
32480
32480
|
/* @__PURE__ */ g("div", { className: `w-6 h-6 rounded-full flex items-center justify-center text-white text-xs font-semibold flex-shrink-0 shadow-lg ${t === "light" ? "bg-gradient-to-br from-blue-500 to-purple-600" : "bg-gradient-to-br from-gray-600 to_gray-700"}`, children: G }),
|
|
32481
|
-
/* @__PURE__ */ N("div", { className: `flex h-full flex-col justify-between border px-3 py-2 rounded-2xl shadow-lg backdrop-bl-sm message-bubble rounded-bl-md message-hover border-gray-200 dark:border-gray-700 ${
|
|
32481
|
+
/* @__PURE__ */ N("div", { className: `flex h-full flex-col justify-between border px-3 py-2 rounded-2xl shadow-lg backdrop-bl-sm message-bubble rounded-bl-md message-hover border-gray-200 dark:border-gray-700 ${V.chatMessage.other} min-w-0 max-w-[85%] break-words overflow-hidden`, style: { overflowWrap: "anywhere", wordBreak: "break-word", hyphens: "auto" }, children: [
|
|
32482
32482
|
P.metadata.view,
|
|
32483
|
-
/* @__PURE__ */ g("div", { className: `text-xs ${
|
|
32483
|
+
/* @__PURE__ */ g("div", { className: `text-xs ${V.text.muted} mt-1 opacity-70 transition-opacity duration-200`, children: P.timestamp.toLocaleTimeString([], {
|
|
32484
32484
|
hour: "2-digit",
|
|
32485
32485
|
minute: "2-digit"
|
|
32486
32486
|
}) })
|
|
@@ -32516,7 +32516,7 @@ function Jl({
|
|
|
32516
32516
|
children: G
|
|
32517
32517
|
}
|
|
32518
32518
|
),
|
|
32519
|
-
/* @__PURE__ */ N("div", { className: `flex h-full flex-col justify-between border px-3 py-2 rounded-2xl shadow-lg backdrop-bl-sm message-bubble rounded-bl-md message-hover border-gray-200 dark:border-gray-700 ${
|
|
32519
|
+
/* @__PURE__ */ N("div", { className: `flex h-full flex-col justify-between border px-3 py-2 rounded-2xl shadow-lg backdrop-bl-sm message-bubble rounded-bl-md message-hover border-gray-200 dark:border-gray-700 ${V.chatMessage.other} min-w-0 max-w-full break-words overflow-hidden`, style: { overflowWrap: "anywhere", wordBreak: "break-word", hyphens: "auto" }, children: [
|
|
32520
32520
|
/* @__PURE__ */ g(
|
|
32521
32521
|
vo,
|
|
32522
32522
|
{
|
|
@@ -32534,7 +32534,7 @@ function Jl({
|
|
|
32534
32534
|
initial: { opacity: 0 },
|
|
32535
32535
|
animate: { opacity: 1 },
|
|
32536
32536
|
transition: { delay: 0.2 },
|
|
32537
|
-
className: `text-xs ${
|
|
32537
|
+
className: `text-xs ${V.text.muted} mt-1 opacity-0 group-hover:opacity-100 transition-opacity duration-200`,
|
|
32538
32538
|
children: (/* @__PURE__ */ new Date()).toLocaleTimeString([], {
|
|
32539
32539
|
hour: "2-digit",
|
|
32540
32540
|
minute: "2-digit"
|
|
@@ -32560,13 +32560,13 @@ function Jl({
|
|
|
32560
32560
|
children: /* @__PURE__ */ g("svg", { className: "w-5 h-5", fill: "none", stroke: "currentColor", viewBox: "0 0 24 24", children: /* @__PURE__ */ g("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M19 14l-7 7m0 0l-7-7m7 7V3" }) })
|
|
32561
32561
|
}
|
|
32562
32562
|
),
|
|
32563
|
-
l && te.length > 0 && /* @__PURE__ */ g("div", { className: "w-full flex overflow-x-auto gap-2 px-4 py-2 mb-1 scrollbar-hide", children: te.map((P, ne) => {
|
|
32563
|
+
l && te.length > 0 && /* @__PURE__ */ g("div", { className: "w-full flex overflow-x-auto gap-2 px-4 py-2 mb-1 scrollbar-hide flex-shrink-0", children: te.map((P, ne) => {
|
|
32564
32564
|
var Ee;
|
|
32565
32565
|
return /* @__PURE__ */ g(
|
|
32566
32566
|
"button",
|
|
32567
32567
|
{
|
|
32568
32568
|
className: `whitespace-nowrap px-3 py-1 rounded-full border shadow-sm flex-shrink-0 transition-all duration-150 font-medium text-sm focus:outline-none focus:ring-2 focus:ring-blue-400/40
|
|
32569
|
-
${t === "light" ? "bg-white text-blue-700 border-blue-200 hover:bg-blue-50 hover:text-blue-900" : t === "dark" ? "bg-gray-800 text-blue-300 border-gray-700 hover:bg-gray-700 hover:text-white" : ((Ee =
|
|
32569
|
+
${t === "light" ? "bg-white text-blue-700 border-blue-200 hover:bg-blue-50 hover:text-blue-900" : t === "dark" ? "bg-gray-800 text-blue-300 border-gray-700 hover:bg-gray-700 hover:text-white" : ((Ee = V.suggestedResponse) == null ? void 0 : Ee.container) || "bg-gradient-to-br from-blue-500 to-purple-600 text-white border-blue-400 hover:from-blue-600 hover:to-purple-700"}
|
|
32570
32570
|
`,
|
|
32571
32571
|
style: {
|
|
32572
32572
|
boxShadow: t === "vox" ? "0 2px 8px 0 rgba(80,60,200,0.10)" : void 0,
|
|
@@ -32718,7 +32718,7 @@ const Yg = Ae.forwardRef(({
|
|
|
32718
32718
|
M.main,
|
|
32719
32719
|
a === "fullscreen" ? "max-w-none" : "",
|
|
32720
32720
|
"overflow-hidden h-full"
|
|
32721
|
-
), $ = s && (a === "popup" || a === "fullscreen"),
|
|
32721
|
+
), $ = s && (a === "popup" || a === "fullscreen"), V = Ae.useMemo(() => d ? "Agent is taking longer than expected..." : O ? "Room connected. Waiting for agent..." : r, [d, O, r]), x = Ae.useMemo(() => d ? "Please check your connection or try again." : O ? "The agent will join shortly." : "Agent is connecting... This may take a moment.", [d, O]), U = o.getCurrentAgentInfo();
|
|
32722
32722
|
return y ? /* @__PURE__ */ N("main", { ref: l, className: ze(te, "relative", e && "pointer-events-none opacity-50"), children: [
|
|
32723
32723
|
($ || _) && /* @__PURE__ */ N("div", { className: `flex items-center justify-between w-full p-4 border-b ${((G = M.chatHeader) == null ? void 0 : G.container) || "border-gray-200"}`, children: [
|
|
32724
32724
|
/* @__PURE__ */ g("div", { children: /* @__PURE__ */ g("h3", { className: `font-semibold ${M.text.primary}`, children: (U == null ? void 0 : U.agentName) || "Voice Session" }) }),
|
|
@@ -32735,7 +32735,7 @@ const Yg = Ae.forwardRef(({
|
|
|
32735
32735
|
] }),
|
|
32736
32736
|
/* @__PURE__ */ g("div", { className: "flex-1 flex items-center justify-center w-full", children: /* @__PURE__ */ N("div", { className: "flex flex-col items-center justify-center w-full h-full min-h-[180px]", children: [
|
|
32737
32737
|
/* @__PURE__ */ g(Re.div, { animate: { rotate: 360, scale: [1, 1.1, 1] }, transition: { rotate: { duration: 2, repeat: 1 / 0, ease: "linear" }, scale: { duration: 1, repeat: 1 / 0, ease: "easeInOut" } }, className: "w-12 h-12 mb-4", children: /* @__PURE__ */ g(So, { className: M.spinner, weight: "bold" }) }),
|
|
32738
|
-
/* @__PURE__ */ g(Re.span, { initial: { opacity: 0, y: 10 }, animate: { opacity: 1, y: 0 }, className: `text-sm opacity-80 ${M.text.muted} text-center max-w-xs`, children:
|
|
32738
|
+
/* @__PURE__ */ g(Re.span, { initial: { opacity: 0, y: 10 }, animate: { opacity: 1, y: 0 }, className: `text-sm opacity-80 ${M.text.muted} text-center max-w-xs`, children: V }),
|
|
32739
32739
|
/* @__PURE__ */ g(Re.p, { initial: { opacity: 0 }, animate: { opacity: 1 }, transition: { delay: 2 }, className: `text-xs ${M.text.muted} mt-2 text-center opacity-60`, children: x }),
|
|
32740
32740
|
d && s && /* @__PURE__ */ g(Re.button, { initial: { opacity: 0, scale: 0.9 }, animate: { opacity: 1, scale: 1 }, transition: { delay: 0.5 }, onClick: s, className: `mt-4 px-4 py-2 rounded-lg ${((k = M.chatHeader) == null ? void 0 : k.backButton) || "bg-gray-100 hover:bg-gray-200"} transition-colors`, children: "Go Back" })
|
|
32741
32741
|
] }) })
|
|
@@ -32753,24 +32753,29 @@ const Yg = Ae.forwardRef(({
|
|
|
32753
32753
|
}
|
|
32754
32754
|
)
|
|
32755
32755
|
] }),
|
|
32756
|
-
/* @__PURE__ */ N("div", { className: "w-full flex-1 flex flex-col items-center px-0 min-h-0 overflow-hidden", children: [
|
|
32756
|
+
/* @__PURE__ */ N("div", { className: "w-full flex-1 flex flex-col items-center px-0 min-h-0 overflow-hidden relative", children: [
|
|
32757
32757
|
!B && /* @__PURE__ */ N("div", { className: "flex flex-col items-center justify-center w-full h-full min-h-[180px]", children: [
|
|
32758
32758
|
/* @__PURE__ */ g(Re.div, { animate: { rotate: 360, scale: [1, 1.1, 1] }, transition: { rotate: { duration: 2, repeat: 1 / 0, ease: "linear" }, scale: { duration: 1, repeat: 1 / 0, ease: "easeInOut" } }, className: "w-12 h-12 mb-4", children: /* @__PURE__ */ g(So, { className: M.spinner, weight: "bold" }) }),
|
|
32759
|
-
/* @__PURE__ */ g(Re.span, { initial: { opacity: 0, y: 10 }, animate: { opacity: 1, y: 0 }, className: `text-sm opacity-80 ${M.text.muted} text-center max-w-xs`, children:
|
|
32759
|
+
/* @__PURE__ */ g(Re.span, { initial: { opacity: 0, y: 10 }, animate: { opacity: 1, y: 0 }, className: `text-sm opacity-80 ${M.text.muted} text-center max-w-xs`, children: V }),
|
|
32760
32760
|
/* @__PURE__ */ g(Re.p, { initial: { opacity: 0 }, animate: { opacity: 1 }, transition: { delay: 2 }, className: `text-xs ${M.text.muted} mt-2 text-center opacity-60`, children: x }),
|
|
32761
32761
|
d && s && /* @__PURE__ */ g(Re.button, { initial: { opacity: 0, scale: 0.9 }, animate: { opacity: 1, scale: 1 }, transition: { delay: 0.5 }, onClick: s, className: `mt-4 px-4 py-2 rounded-lg ${((Z = M.chatHeader) == null ? void 0 : Z.backButton) || "bg-gray-100 hover:bg-gray-200"} transition-colors`, children: "Go Back" })
|
|
32762
32762
|
] }),
|
|
32763
32763
|
B && /* @__PURE__ */ N(St, { children: [
|
|
32764
|
-
c && // Chat overlay
|
|
32764
|
+
c && // Chat overlay - fills the content area above controls
|
|
32765
32765
|
/* @__PURE__ */ g(
|
|
32766
32766
|
"div",
|
|
32767
32767
|
{
|
|
32768
32768
|
className: ze(
|
|
32769
|
-
|
|
32770
|
-
|
|
32771
|
-
|
|
32769
|
+
// min-h-0 is critical so nested flex + overflow containers can scroll on mobile
|
|
32770
|
+
"absolute inset-0 flex flex-col min-h-0 transition-[opacity,transform] duration-300 ease-out z-10",
|
|
32771
|
+
M.main
|
|
32772
32772
|
),
|
|
32773
|
-
style: {
|
|
32773
|
+
style: {
|
|
32774
|
+
bottom: 0,
|
|
32775
|
+
top: 0,
|
|
32776
|
+
left: 0,
|
|
32777
|
+
right: 0
|
|
32778
|
+
},
|
|
32774
32779
|
children: /* @__PURE__ */ g(Jl, { client: o, theme: i, displayType: a === "fullscreen" ? "fullscreen" : "widget", disabled: e, onBack: () => u(!1), showTimer: !1 })
|
|
32775
32780
|
}
|
|
32776
32781
|
),
|
|
@@ -32888,9 +32893,9 @@ function AA({
|
|
|
32888
32893
|
};
|
|
32889
32894
|
}
|
|
32890
32895
|
}, [A]);
|
|
32891
|
-
const
|
|
32892
|
-
(Z) => Z.participant !==
|
|
32893
|
-
)[0], k = D.useMemo(() => (R || []).find((Z) => Z.participant ===
|
|
32896
|
+
const V = _ == null ? void 0 : _.localParticipant, x = D.useMemo(() => (e ? e.getCameraTrackRefs() : []).find((Z) => Z.participant === V), [e, V]), G = T.filter(
|
|
32897
|
+
(Z) => Z.participant !== V
|
|
32898
|
+
)[0], k = D.useMemo(() => (R || []).find((Z) => Z.participant === V), [R, V]);
|
|
32894
32899
|
return /* @__PURE__ */ N("div", { className: `flex flex-col h-full ${a.video.container} relative`, children: [
|
|
32895
32900
|
/* @__PURE__ */ N("div", { className: `flex items-center justify-between p-4 border-b ${a.video.header}`, children: [
|
|
32896
32901
|
/* @__PURE__ */ N("div", { className: "flex items-center gap-3", children: [
|
|
@@ -33010,7 +33015,7 @@ function AA({
|
|
|
33010
33015
|
jd,
|
|
33011
33016
|
{
|
|
33012
33017
|
trackRef: x,
|
|
33013
|
-
participant:
|
|
33018
|
+
participant: V || void 0,
|
|
33014
33019
|
isLocal: !0,
|
|
33015
33020
|
theme: t,
|
|
33016
33021
|
className: "w-full h-full"
|
|
@@ -33218,7 +33223,7 @@ function OA() {
|
|
|
33218
33223
|
}
|
|
33219
33224
|
}
|
|
33220
33225
|
var _ = l, T = c, R = s, A = a, I = t, b = u, M = r, O = m, L = h, B = n, W = o, oe = i, te = d, $ = !1;
|
|
33221
|
-
function
|
|
33226
|
+
function V(P) {
|
|
33222
33227
|
return $ || ($ = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), x(P) || C(P) === l;
|
|
33223
33228
|
}
|
|
33224
33229
|
function x(P) {
|
|
@@ -33257,7 +33262,7 @@ function OA() {
|
|
|
33257
33262
|
function ve(P) {
|
|
33258
33263
|
return C(P) === d;
|
|
33259
33264
|
}
|
|
33260
|
-
He.AsyncMode = _, He.ConcurrentMode = T, He.ContextConsumer = R, He.ContextProvider = A, He.Element = I, He.ForwardRef = b, He.Fragment = M, He.Lazy = O, He.Memo = L, He.Portal = B, He.Profiler = W, He.StrictMode = oe, He.Suspense = te, He.isAsyncMode =
|
|
33265
|
+
He.AsyncMode = _, He.ConcurrentMode = T, He.ContextConsumer = R, He.ContextProvider = A, He.Element = I, He.ForwardRef = b, He.Fragment = M, He.Lazy = O, He.Memo = L, He.Portal = B, He.Profiler = W, He.StrictMode = oe, He.Suspense = te, He.isAsyncMode = V, He.isConcurrentMode = x, He.isContextConsumer = U, He.isContextProvider = G, He.isElement = k, He.isForwardRef = K, He.isFragment = Z, He.isLazy = X, He.isMemo = ie, He.isPortal = Y, He.isProfiler = re, He.isStrictMode = j, He.isSuspense = ve, He.isValidElementType = v, He.typeOf = C;
|
|
33261
33266
|
}()), He;
|
|
33262
33267
|
}
|
|
33263
33268
|
var qd;
|
|
@@ -33510,7 +33515,7 @@ function LA() {
|
|
|
33510
33515
|
function T(x) {
|
|
33511
33516
|
function U(G, k, K, Z, X) {
|
|
33512
33517
|
if (!(G[k] instanceof x)) {
|
|
33513
|
-
var ie = x.name || f, Y =
|
|
33518
|
+
var ie = x.name || f, Y = V(G[k]);
|
|
33514
33519
|
return new p("Invalid " + Z + " `" + X + "` of type " + ("`" + Y + "` supplied to `" + K + "`, expected ") + ("instance of `" + ie + "`."));
|
|
33515
33520
|
}
|
|
33516
33521
|
return null;
|
|
@@ -33690,7 +33695,7 @@ Valid keys: ` + JSON.stringify(Object.keys(x), null, " ")
|
|
|
33690
33695
|
return U;
|
|
33691
33696
|
}
|
|
33692
33697
|
}
|
|
33693
|
-
function
|
|
33698
|
+
function V(x) {
|
|
33694
33699
|
return !x.constructor || !x.constructor.name ? f : x.constructor.name;
|
|
33695
33700
|
}
|
|
33696
33701
|
return h.checkPropTypes = i, h.resetWarningCache = i.resetWarningCache, h.PropTypes = h, h;
|
|
@@ -35199,8 +35204,8 @@ function eR(e = {}) {
|
|
|
35199
35204
|
if (!W)
|
|
35200
35205
|
return null;
|
|
35201
35206
|
const oe = {};
|
|
35202
|
-
for (const
|
|
35203
|
-
oe[
|
|
35207
|
+
for (const V in W)
|
|
35208
|
+
oe[V] = po(L, W[V], L.theme.modularCssLayers ? "theme" : void 0);
|
|
35204
35209
|
return h(L, oe);
|
|
35205
35210
|
}), c && !w && I.push(function(L) {
|
|
35206
35211
|
var oe, te;
|
|
@@ -38799,14 +38804,14 @@ function os({
|
|
|
38799
38804
|
}) {
|
|
38800
38805
|
const [i, o] = Ce(null), [a, s] = Ce(!1), [l, c] = Ce(!1), [u, d] = Ce(null), [f, h] = Ce(null), [m, p] = Ce("idle"), [w, y] = Ce(null), [E, v] = Ce([]), [C, _] = Ce([]), [T, R] = Ce([]);
|
|
38801
38806
|
kt(() => {
|
|
38802
|
-
const
|
|
38803
|
-
o(
|
|
38804
|
-
const x = A(
|
|
38805
|
-
return n && !r && I(
|
|
38806
|
-
x(), r ||
|
|
38807
|
+
const V = r || new cc(e);
|
|
38808
|
+
o(V);
|
|
38809
|
+
const x = A(V);
|
|
38810
|
+
return n && !r && I(V), () => {
|
|
38811
|
+
x(), r || V.disconnect().catch(console.error);
|
|
38807
38812
|
};
|
|
38808
38813
|
}, [e, n, r]);
|
|
38809
|
-
const A = (
|
|
38814
|
+
const A = (V) => {
|
|
38810
38815
|
const x = () => {
|
|
38811
38816
|
c(!0), d(null);
|
|
38812
38817
|
}, U = () => {
|
|
@@ -38834,11 +38839,11 @@ function os({
|
|
|
38834
38839
|
}, P = () => {
|
|
38835
38840
|
console.log("🧹 VoxketProvider: Clearing chat messages and transcriptions"), _([]), R([]);
|
|
38836
38841
|
};
|
|
38837
|
-
return
|
|
38838
|
-
console.log("📝 VoxketProvider: Cleaning up event listeners"),
|
|
38842
|
+
return V.on("connection.connecting", x), V.on("connection.connected", U), V.on("connection.disconnected", G), V.on("connection.error", k), V.on("session.created", K), V.on("session.state.changed", Z), V.on("session.ended", X), V.on("participant.joined", ie), V.on("participant.left", Y), V.on("chat.message.received", re), V.on("chat.message.sent", j), V.on("transcription.received", ve), V.on("chat.history.cleared", P), () => {
|
|
38843
|
+
console.log("📝 VoxketProvider: Cleaning up event listeners"), V.off("connection.connecting", x), V.off("connection.connected", U), V.off("connection.disconnected", G), V.off("connection.error", k), V.off("session.created", K), V.off("session.state.changed", Z), V.off("session.ended", X), V.off("participant.joined", ie), V.off("participant.left", Y), V.off("chat.message.received", re), V.off("chat.message.sent", j), V.off("chat.history.cleared", P), V.off("transcription.received", ve);
|
|
38839
38844
|
};
|
|
38840
|
-
}, I = async (
|
|
38841
|
-
const x =
|
|
38845
|
+
}, I = async (V) => {
|
|
38846
|
+
const x = V || i;
|
|
38842
38847
|
if (x)
|
|
38843
38848
|
try {
|
|
38844
38849
|
await x.connect();
|
|
@@ -38861,15 +38866,15 @@ function os({
|
|
|
38861
38866
|
if (i)
|
|
38862
38867
|
try {
|
|
38863
38868
|
await i.disconnect();
|
|
38864
|
-
} catch (
|
|
38865
|
-
console.error("Failed to disconnect:",
|
|
38869
|
+
} catch (V) {
|
|
38870
|
+
console.error("Failed to disconnect:", V);
|
|
38866
38871
|
}
|
|
38867
38872
|
},
|
|
38868
|
-
createSession: async (
|
|
38873
|
+
createSession: async (V, x = {}) => {
|
|
38869
38874
|
if (!i)
|
|
38870
38875
|
throw new Error("Client not initialized");
|
|
38871
38876
|
const U = {
|
|
38872
|
-
agentId:
|
|
38877
|
+
agentId: V,
|
|
38873
38878
|
participantName: x.participantName || "User",
|
|
38874
38879
|
metadata: x.metadata,
|
|
38875
38880
|
modalities: x.modalities || ["voice"]
|
|
@@ -38877,20 +38882,20 @@ function os({
|
|
|
38877
38882
|
return await i.createSession(U);
|
|
38878
38883
|
},
|
|
38879
38884
|
endSession: async () => i ? await i.endSession() : null,
|
|
38880
|
-
sendChatMessage: async (
|
|
38885
|
+
sendChatMessage: async (V) => {
|
|
38881
38886
|
if (!i)
|
|
38882
38887
|
throw new Error("Client not initialized");
|
|
38883
|
-
await i.sendChatMessage(
|
|
38888
|
+
await i.sendChatMessage(V);
|
|
38884
38889
|
},
|
|
38885
|
-
setMicrophoneEnabled: async (
|
|
38890
|
+
setMicrophoneEnabled: async (V) => {
|
|
38886
38891
|
if (!i)
|
|
38887
38892
|
throw new Error("Client not initialized");
|
|
38888
|
-
await i.setMicrophoneEnabled(
|
|
38893
|
+
await i.setMicrophoneEnabled(V);
|
|
38889
38894
|
},
|
|
38890
|
-
setCameraEnabled: async (
|
|
38895
|
+
setCameraEnabled: async (V) => {
|
|
38891
38896
|
if (!i)
|
|
38892
38897
|
throw new Error("Client not initialized");
|
|
38893
|
-
await i.setCameraEnabled(
|
|
38898
|
+
await i.setCameraEnabled(V);
|
|
38894
38899
|
},
|
|
38895
38900
|
startScreenShare: async () => {
|
|
38896
38901
|
if (!i)
|
|
@@ -39885,7 +39890,7 @@ function NI(e) {
|
|
|
39885
39890
|
participantMetadata: W,
|
|
39886
39891
|
popupModalityMode: oe = "all",
|
|
39887
39892
|
popupTriggerLogoUrl: te
|
|
39888
|
-
} = e, [$,
|
|
39893
|
+
} = e, [$, V] = D.useState(!1), [x, U] = D.useState(null), [G, k] = D.useState(() => {
|
|
39889
39894
|
try {
|
|
39890
39895
|
if (L)
|
|
39891
39896
|
return !!L.getCurrentSession();
|
|
@@ -39932,7 +39937,7 @@ function NI(e) {
|
|
|
39932
39937
|
console.log("🔄 Using existing VoxketClient to preserve session state"), Ze.current = L;
|
|
39933
39938
|
else if (!a && (!o || !i)) {
|
|
39934
39939
|
const S = "Missing required props: Either provide 'authToken' or both 'appId' and 'appSecret'";
|
|
39935
|
-
console.error("❌ VoxketClient creation failed:", S), U(new Error(S)),
|
|
39940
|
+
console.error("❌ VoxketClient creation failed:", S), U(new Error(S)), V(!0);
|
|
39936
39941
|
} else if (r) {
|
|
39937
39942
|
const S = {
|
|
39938
39943
|
...a ? { authToken: a } : { appId: o, appSecret: i },
|
|
@@ -39953,10 +39958,10 @@ function NI(e) {
|
|
|
39953
39958
|
}), Ze.current = new cc(S);
|
|
39954
39959
|
} else {
|
|
39955
39960
|
const S = "Missing required prop: baseUrl";
|
|
39956
|
-
console.error("❌ VoxketClient creation failed:", S), U(new Error(S)),
|
|
39961
|
+
console.error("❌ VoxketClient creation failed:", S), U(new Error(S)), V(!0);
|
|
39957
39962
|
}
|
|
39958
39963
|
} catch (S) {
|
|
39959
|
-
console.error("❌ Failed to create VoxketClient:", S), U(S),
|
|
39964
|
+
console.error("❌ Failed to create VoxketClient:", S), U(S), V(!0);
|
|
39960
39965
|
}
|
|
39961
39966
|
const ce = Ze.current;
|
|
39962
39967
|
D.useEffect(() => {
|
|
@@ -40009,7 +40014,7 @@ function NI(e) {
|
|
|
40009
40014
|
}, [P, K, G]), D.useEffect(() => {
|
|
40010
40015
|
(P === "voice" || P === "video" || P === "chat") && !j && !G && !K && ce && !ce.connected && (console.log("🔄 Auto-correcting: Found orphaned mode without session, returning to welcome"), ne("welcome"), Z(!1));
|
|
40011
40016
|
}, [P, j, G, K, ce]);
|
|
40012
|
-
const { sessionMetrics:
|
|
40017
|
+
const { sessionMetrics: z, sessionLogs: J, logEvent: we } = hI({
|
|
40013
40018
|
room: Xe,
|
|
40014
40019
|
onSessionStart: v,
|
|
40015
40020
|
onSessionEnd: C,
|
|
@@ -40020,8 +40025,8 @@ function NI(e) {
|
|
|
40020
40025
|
D.useEffect(() => {
|
|
40021
40026
|
T && T(J);
|
|
40022
40027
|
}, [J, T]), D.useEffect(() => {
|
|
40023
|
-
R &&
|
|
40024
|
-
}, [
|
|
40028
|
+
R && z && R(z);
|
|
40029
|
+
}, [z, R]), D.useEffect(() => {
|
|
40025
40030
|
if (!ce) return;
|
|
40026
40031
|
const S = (F, q) => {
|
|
40027
40032
|
console.log("📊 Widget: Session state changed:", {
|
|
@@ -40071,13 +40076,13 @@ function NI(e) {
|
|
|
40071
40076
|
const Dt = async () => {
|
|
40072
40077
|
try {
|
|
40073
40078
|
if (!ce) {
|
|
40074
|
-
console.error("❌ VoxketClient not available"), U(new Error("VoxketClient not initialized")),
|
|
40079
|
+
console.error("❌ VoxketClient not available"), U(new Error("VoxketClient not initialized")), V(!0);
|
|
40075
40080
|
return;
|
|
40076
40081
|
}
|
|
40077
40082
|
Z(!0), ne("voice"), console.log("🎤 Starting voice session...", { agentId: X, participantName: Y }), console.log("🎤 Pre-start state:", { currentMode: "voice", sessionStarted: !1, loading: !0 }), we("USER_STARTED_VOICE_SESSION", { agentId: X, participantName: Y });
|
|
40078
40083
|
const S = await ce.startSession(X, {
|
|
40079
40084
|
participantName: Y || "User",
|
|
40080
|
-
modalities:
|
|
40085
|
+
modalities: ["voice"],
|
|
40081
40086
|
participantMetadata: ce.getParticipantMetadata() || W
|
|
40082
40087
|
// Use client metadata first, then props
|
|
40083
40088
|
});
|
|
@@ -40088,7 +40093,7 @@ function NI(e) {
|
|
|
40088
40093
|
}, an = async () => {
|
|
40089
40094
|
try {
|
|
40090
40095
|
if (!ce) {
|
|
40091
|
-
console.error("❌ VoxketClient not available"), U(new Error("VoxketClient not initialized")),
|
|
40096
|
+
console.error("❌ VoxketClient not available"), U(new Error("VoxketClient not initialized")), V(!0);
|
|
40092
40097
|
return;
|
|
40093
40098
|
}
|
|
40094
40099
|
Z(!0), ne("chat"), console.log("💬 Starting chat session...", { agentId: X, participantName: Y }), we("USER_STARTED_CHAT_SESSION", { agentId: X, participantName: Y });
|
|
@@ -40105,7 +40110,7 @@ function NI(e) {
|
|
|
40105
40110
|
}, jt = async () => {
|
|
40106
40111
|
try {
|
|
40107
40112
|
if (!ce) {
|
|
40108
|
-
console.error("❌ VoxketClient not available"), U(new Error("VoxketClient not initialized")),
|
|
40113
|
+
console.error("❌ VoxketClient not available"), U(new Error("VoxketClient not initialized")), V(!0);
|
|
40109
40114
|
return;
|
|
40110
40115
|
}
|
|
40111
40116
|
Z(!0), ne("video"), console.log("📺 Starting video session...", { agentId: X, participantName: Y }), console.log("📺 Pre-start state:", { currentMode: "video", sessionStarted: !1, loading: !0 }), we("USER_STARTED_VIDEO_SESSION", { agentId: X, participantName: Y });
|
|
@@ -40259,7 +40264,7 @@ function NI(e) {
|
|
|
40259
40264
|
"button",
|
|
40260
40265
|
{
|
|
40261
40266
|
onClick: () => {
|
|
40262
|
-
|
|
40267
|
+
V(!1), U(null), window.location.reload();
|
|
40263
40268
|
},
|
|
40264
40269
|
className: "px-4 py-2 bg-blue-600 text-white rounded hover:bg-blue-700 transition-colors",
|
|
40265
40270
|
children: "Retry"
|