@carto/ps-react-ui 4.11.3 → 4.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chat.js +962 -733
- package/dist/chat.js.map +1 -1
- package/dist/csv-item-hH_Gt7ur.js +32 -0
- package/dist/csv-item-hH_Gt7ur.js.map +1 -0
- package/dist/png-item-9dNbB37T.js +57 -0
- package/dist/png-item-9dNbB37T.js.map +1 -0
- package/dist/table-B3ZWWhJt.js +383 -0
- package/dist/table-B3ZWWhJt.js.map +1 -0
- package/dist/types/chat/containers/chat-footer.d.ts +1 -1
- package/dist/types/chat/containers/styles.d.ts +79 -12
- package/dist/types/chat/index.d.ts +1 -1
- package/dist/types/chat/types.d.ts +21 -0
- package/dist/types/chat/use-typewriter.d.ts +5 -3
- package/dist/types/widgets-v2/actions/download/constants.d.ts +12 -0
- package/dist/types/widgets-v2/actions/download/csv-item.d.ts +38 -0
- package/dist/types/widgets-v2/actions/download/icons.d.ts +6 -0
- package/dist/types/widgets-v2/actions/download/index.d.ts +3 -1
- package/dist/types/widgets-v2/actions/index.d.ts +1 -1
- package/dist/widgets-v2/actions.js +40 -36
- package/dist/widgets-v2/actions.js.map +1 -1
- package/dist/widgets-v2/bar.js +77 -84
- package/dist/widgets-v2/bar.js.map +1 -1
- package/dist/widgets-v2/category.js +50 -55
- package/dist/widgets-v2/category.js.map +1 -1
- package/dist/widgets-v2/formula.js +37 -43
- package/dist/widgets-v2/formula.js.map +1 -1
- package/dist/widgets-v2/histogram.js +138 -144
- package/dist/widgets-v2/histogram.js.map +1 -1
- package/dist/widgets-v2/markdown.js +18 -17
- package/dist/widgets-v2/markdown.js.map +1 -1
- package/dist/widgets-v2/pie.js +67 -73
- package/dist/widgets-v2/pie.js.map +1 -1
- package/dist/widgets-v2/scatterplot.js +75 -81
- package/dist/widgets-v2/scatterplot.js.map +1 -1
- package/dist/widgets-v2/spread.js +36 -41
- package/dist/widgets-v2/spread.js.map +1 -1
- package/dist/widgets-v2/table.js +46 -55
- package/dist/widgets-v2/table.js.map +1 -1
- package/dist/widgets-v2/timeseries.js +81 -87
- package/dist/widgets-v2/timeseries.js.map +1 -1
- package/dist/widgets-v2.js +1 -1
- package/package.json +1 -1
- package/src/chat/bubbles/styles.ts +5 -1
- package/src/chat/containers/chat-content.tsx +4 -1
- package/src/chat/containers/chat-footer.test.tsx +59 -0
- package/src/chat/containers/chat-footer.tsx +124 -36
- package/src/chat/containers/styles.ts +107 -16
- package/src/chat/feedback/styles.ts +11 -4
- package/src/chat/index.ts +1 -0
- package/src/chat/types.ts +22 -0
- package/src/chat/use-typewriter.ts +32 -24
- package/src/widgets-v2/actions/download/constants.ts +14 -0
- package/src/widgets-v2/actions/download/csv-item.test.tsx +77 -0
- package/src/widgets-v2/actions/download/csv-item.tsx +71 -0
- package/src/widgets-v2/actions/download/icons.tsx +10 -1
- package/src/widgets-v2/actions/download/index.ts +3 -1
- package/src/widgets-v2/actions/download/png-item.tsx +2 -1
- package/src/widgets-v2/actions/index.ts +5 -0
- package/src/widgets-v2/bar/download.tsx +16 -22
- package/src/widgets-v2/category/download.test.ts +9 -0
- package/src/widgets-v2/category/download.ts +16 -20
- package/src/widgets-v2/formula/download.tsx +23 -29
- package/src/widgets-v2/histogram/download.ts +22 -26
- package/src/widgets-v2/markdown/{download.ts → download.tsx} +5 -2
- package/src/widgets-v2/pie/download.ts +16 -20
- package/src/widgets-v2/scatterplot/download.ts +16 -20
- package/src/widgets-v2/spread/download.ts +23 -27
- package/src/widgets-v2/table/download.test.ts +10 -0
- package/src/widgets-v2/table/download.ts +11 -15
- package/src/widgets-v2/table/helpers.test.ts +19 -0
- package/src/widgets-v2/table/helpers.ts +7 -12
- package/src/widgets-v2/timeseries/download.ts +36 -40
- package/dist/png-item-BE9uEqlD.js +0 -45
- package/dist/png-item-BE9uEqlD.js.map +0 -1
- package/dist/table-C9IMbTr0.js +0 -385
- package/dist/table-C9IMbTr0.js.map +0 -1
- package/dist/types/chat/feedback/styles.d.ts +0 -211
package/dist/chat.js
CHANGED
|
@@ -1,50 +1,68 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import { styled as ae, Typography as
|
|
5
|
-
import { ErrorOutline as
|
|
1
|
+
import { c as P } from "react/compiler-runtime";
|
|
2
|
+
import { useState as te, useRef as ne, useEffect as re, forwardRef as we, useImperativeHandle as Te } from "react";
|
|
3
|
+
import { jsx as a, jsxs as S, Fragment as he } from "react/jsx-runtime";
|
|
4
|
+
import { styled as ae, Typography as z, Box as v, Link as ke, ButtonBase as _e, Fab as Ae, IconButton as oe, Button as le, Menu as Ie, MenuItem as Le, InputBase as $e, FormHelperText as Ee, FormControl as Re, DialogTitle as Be, DialogContent as De, Dialog as Me, Tooltip as ze, Collapse as se, CircularProgress as We } from "@mui/material";
|
|
5
|
+
import { ErrorOutline as ge, ArrowUpward as Fe, KeyboardArrowDown as xe, Close as be, StopCircleOutlined as Oe, ArrowUpwardOutlined as He, ThumbUp as Pe, ThumbUpOutlined as Ve, ThumbDown as je, ThumbDownOutlined as Ue, ArrowRight as ye, Error as Ne, CheckCircle as Ge, ChevronRight as Xe } from "@mui/icons-material";
|
|
6
6
|
import { keyframes as ce } from "@mui/material/styles";
|
|
7
|
-
import { C as
|
|
8
|
-
import { OpenDiagonallyRight as
|
|
9
|
-
const
|
|
10
|
-
function
|
|
11
|
-
const
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
7
|
+
import { C as Ke } from "./copy-button-DGL1tyli.js";
|
|
8
|
+
import { OpenDiagonallyRight as Ye, McpTool as qe } from "@carto/meridian-ds/custom-icons";
|
|
9
|
+
const ie = 768, $t = 300, Et = 100, Je = 126;
|
|
10
|
+
function Rt(t, e) {
|
|
11
|
+
const o = P(17);
|
|
12
|
+
let n;
|
|
13
|
+
o[0] !== e ? (n = e === void 0 ? {} : e, o[0] = e, o[1] = n) : n = o[1];
|
|
14
|
+
const i = n, {
|
|
15
|
+
speed: r,
|
|
16
|
+
skipAnimation: u
|
|
17
|
+
} = i, s = r === void 0 ? 500 : r, l = u === void 0 ? !1 : u;
|
|
18
|
+
let c;
|
|
19
|
+
o[2] !== t || o[3] !== l ? (c = () => l ? t.length : 0, o[2] = t, o[3] = l, o[4] = c) : c = o[4];
|
|
20
|
+
const [f, m] = te(c), h = ne(f);
|
|
21
|
+
let b, p;
|
|
22
|
+
o[5] !== t || o[6] !== l || o[7] !== s ? (b = () => {
|
|
23
|
+
if (l || h.current >= t.length)
|
|
18
24
|
return;
|
|
25
|
+
const y = 1e3 / s;
|
|
26
|
+
let C, w = null;
|
|
27
|
+
function _(L) {
|
|
28
|
+
w = w ?? L;
|
|
29
|
+
const $ = Math.floor((L - w) / y);
|
|
30
|
+
if ($ > 0) {
|
|
31
|
+
w = L;
|
|
32
|
+
const A = Math.min(h.current + $, t.length);
|
|
33
|
+
if (h.current = A, m(A), A >= t.length)
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
C = requestAnimationFrame(_);
|
|
19
37
|
}
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
}, [t, o, n]), {
|
|
31
|
-
displayedText: t.slice(0, o),
|
|
32
|
-
isTyping: o < t.length
|
|
33
|
-
};
|
|
38
|
+
return C = requestAnimationFrame(_), () => cancelAnimationFrame(C);
|
|
39
|
+
}, p = [t, s, l], o[5] = t, o[6] = l, o[7] = s, o[8] = b, o[9] = p) : (b = o[8], p = o[9]), re(b, p);
|
|
40
|
+
let g;
|
|
41
|
+
o[10] !== f || o[11] !== t || o[12] !== l ? (g = l ? t : t.slice(0, f), o[10] = f, o[11] = t, o[12] = l, o[13] = g) : g = o[13];
|
|
42
|
+
const d = !l && f < t.length;
|
|
43
|
+
let x;
|
|
44
|
+
return o[14] !== g || o[15] !== d ? (x = {
|
|
45
|
+
displayedText: g,
|
|
46
|
+
isTyping: d
|
|
47
|
+
}, o[14] = g, o[15] = d, o[16] = x) : x = o[16], x;
|
|
34
48
|
}
|
|
35
|
-
const
|
|
49
|
+
const Ce = ae(z)(() => ({
|
|
36
50
|
whiteSpace: "pre-wrap",
|
|
37
51
|
overflowX: "clip",
|
|
38
52
|
overflowWrap: "break-word",
|
|
39
53
|
maxWidth: "100%"
|
|
40
54
|
}));
|
|
41
|
-
|
|
42
|
-
const
|
|
55
|
+
Ce.displayName = "ChatMessageOverflow";
|
|
56
|
+
const ee = {
|
|
43
57
|
agentMessageContainer: (t) => ({
|
|
58
|
+
...t.typography.body2,
|
|
44
59
|
width: "100%",
|
|
45
60
|
display: "flex",
|
|
46
61
|
flexDirection: "column",
|
|
47
62
|
alignItems: "flex-start",
|
|
63
|
+
// Separate the stacked turn blocks (tools → answer text → actions) per the
|
|
64
|
+
// Figma "Chat Turn" spec (gap-8).
|
|
65
|
+
gap: t.spacing(1),
|
|
48
66
|
paddingRight: t.spacing(4),
|
|
49
67
|
"& + .PsChat--agent-message": {
|
|
50
68
|
marginTop: t.spacing(1)
|
|
@@ -131,7 +149,7 @@ const O = {
|
|
|
131
149
|
}) => `1px solid ${t.divider}`,
|
|
132
150
|
backgroundColor: ({
|
|
133
151
|
palette: t
|
|
134
|
-
}) => t.background.
|
|
152
|
+
}) => t.background.paper,
|
|
135
153
|
color: ({
|
|
136
154
|
palette: t
|
|
137
155
|
}) => t.text.primary,
|
|
@@ -231,125 +249,125 @@ const O = {
|
|
|
231
249
|
}
|
|
232
250
|
}
|
|
233
251
|
};
|
|
234
|
-
function
|
|
235
|
-
const e =
|
|
236
|
-
children:
|
|
237
|
-
muted:
|
|
238
|
-
topContext:
|
|
239
|
-
sx:
|
|
240
|
-
} = t,
|
|
252
|
+
function Bt(t) {
|
|
253
|
+
const e = P(11), {
|
|
254
|
+
children: o,
|
|
255
|
+
muted: n,
|
|
256
|
+
topContext: i,
|
|
257
|
+
sx: r
|
|
258
|
+
} = t, u = n === void 0 ? !1 : n;
|
|
241
259
|
let s;
|
|
242
|
-
e[0] !==
|
|
243
|
-
const
|
|
244
|
-
let
|
|
245
|
-
e[2] !==
|
|
246
|
-
...
|
|
247
|
-
...
|
|
248
|
-
...
|
|
249
|
-
}, e[2] =
|
|
250
|
-
let
|
|
251
|
-
e[5] !==
|
|
260
|
+
e[0] !== i ? (s = i && /* @__PURE__ */ a(v, { sx: ee.userMessageTop, children: i }), e[0] = i, e[1] = s) : s = e[1];
|
|
261
|
+
const l = u ? ee.muted : void 0;
|
|
262
|
+
let c;
|
|
263
|
+
e[2] !== r || e[3] !== l ? (c = {
|
|
264
|
+
...ee.userMessage,
|
|
265
|
+
...l,
|
|
266
|
+
...r
|
|
267
|
+
}, e[2] = r, e[3] = l, e[4] = c) : c = e[4];
|
|
268
|
+
let f;
|
|
269
|
+
e[5] !== o || e[6] !== c ? (f = /* @__PURE__ */ a(Ce, { className: "PsChat--user-message-inner", variant: "body2", sx: c, children: o }), e[5] = o, e[6] = c, e[7] = f) : f = e[7];
|
|
252
270
|
let m;
|
|
253
|
-
return e[8] !== s || e[9] !==
|
|
271
|
+
return e[8] !== s || e[9] !== f ? (m = /* @__PURE__ */ S(v, { className: "PsChat--user-message", sx: ee.userMessageContainer, children: [
|
|
254
272
|
s,
|
|
255
|
-
|
|
256
|
-
] }), e[8] = s, e[9] =
|
|
273
|
+
f
|
|
274
|
+
] }), e[8] = s, e[9] = f, e[10] = m) : m = e[10], m;
|
|
257
275
|
}
|
|
258
|
-
const
|
|
259
|
-
const e =
|
|
260
|
-
let
|
|
276
|
+
const Qe = (t) => {
|
|
277
|
+
const e = P(6);
|
|
278
|
+
let o, n;
|
|
261
279
|
e[0] !== t ? ({
|
|
262
|
-
className:
|
|
263
|
-
...
|
|
264
|
-
} = t, e[0] = t, e[1] =
|
|
265
|
-
const
|
|
266
|
-
let
|
|
267
|
-
return e[3] !==
|
|
268
|
-
},
|
|
280
|
+
className: o,
|
|
281
|
+
...n
|
|
282
|
+
} = t, e[0] = t, e[1] = o, e[2] = n) : (o = e[1], n = e[2]);
|
|
283
|
+
const i = `PsChat--agent-message ${o ?? ""}`;
|
|
284
|
+
let r;
|
|
285
|
+
return e[3] !== n || e[4] !== i ? (r = /* @__PURE__ */ a(v, { className: i, ...n }), e[3] = n, e[4] = i, e[5] = r) : r = e[5], r;
|
|
286
|
+
}, Ze = ae(Qe)(({
|
|
269
287
|
theme: t
|
|
270
|
-
}) =>
|
|
271
|
-
|
|
272
|
-
function
|
|
273
|
-
const e =
|
|
274
|
-
errors:
|
|
275
|
-
icon:
|
|
276
|
-
actions:
|
|
277
|
-
sx:
|
|
288
|
+
}) => ee.agentMessageContainer(t));
|
|
289
|
+
Ze.displayName = "ChatAgentMessage";
|
|
290
|
+
function Dt(t) {
|
|
291
|
+
const e = P(13), {
|
|
292
|
+
errors: o,
|
|
293
|
+
icon: n,
|
|
294
|
+
actions: i,
|
|
295
|
+
sx: r
|
|
278
296
|
} = t;
|
|
279
|
-
let
|
|
280
|
-
e[0] !==
|
|
281
|
-
...
|
|
282
|
-
...
|
|
283
|
-
}, e[0] =
|
|
297
|
+
let u;
|
|
298
|
+
e[0] !== r ? (u = {
|
|
299
|
+
...ee.errorMessage,
|
|
300
|
+
...r
|
|
301
|
+
}, e[0] = r, e[1] = u) : u = e[1];
|
|
284
302
|
let s;
|
|
285
|
-
e[2] !==
|
|
286
|
-
let
|
|
287
|
-
e[4] !==
|
|
288
|
-
let
|
|
289
|
-
e[6] !==
|
|
290
|
-
let
|
|
291
|
-
return e[8] !==
|
|
303
|
+
e[2] !== n ? (s = n ?? /* @__PURE__ */ a(ge, { fontSize: "medium", color: "error" }), e[2] = n, e[3] = s) : s = e[3];
|
|
304
|
+
let l;
|
|
305
|
+
e[4] !== o ? (l = o.map(tt), e[4] = o, e[5] = l) : l = e[5];
|
|
306
|
+
let c;
|
|
307
|
+
e[6] !== i ? (c = i?.length ? /* @__PURE__ */ a(v, { sx: ee.errorActions, children: (i ?? []).map(et) }) : null, e[6] = i, e[7] = c) : c = e[7];
|
|
308
|
+
let f;
|
|
309
|
+
return e[8] !== u || e[9] !== s || e[10] !== l || e[11] !== c ? (f = /* @__PURE__ */ S(v, { sx: u, children: [
|
|
292
310
|
s,
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
] }), e[8] =
|
|
311
|
+
l,
|
|
312
|
+
c
|
|
313
|
+
] }), e[8] = u, e[9] = s, e[10] = l, e[11] = c, e[12] = f) : f = e[12], f;
|
|
296
314
|
}
|
|
297
|
-
function
|
|
298
|
-
return /* @__PURE__ */
|
|
299
|
-
e > 0 && /* @__PURE__ */
|
|
300
|
-
/* @__PURE__ */
|
|
315
|
+
function et(t, e) {
|
|
316
|
+
return /* @__PURE__ */ S("span", { children: [
|
|
317
|
+
e > 0 && /* @__PURE__ */ a(z, { component: "span", variant: "body2", sx: ee.errorActionSeparator, children: "·" }),
|
|
318
|
+
/* @__PURE__ */ a(ke, { component: "button", variant: "body2", onClick: t.onClick, sx: ee.errorAction, children: t.label })
|
|
301
319
|
] }, e);
|
|
302
320
|
}
|
|
303
|
-
function
|
|
304
|
-
return /* @__PURE__ */
|
|
321
|
+
function tt(t, e) {
|
|
322
|
+
return /* @__PURE__ */ a(z, { variant: "subtitle2", color: "error.relatedDark", children: t }, e);
|
|
305
323
|
}
|
|
306
|
-
function
|
|
307
|
-
const e =
|
|
308
|
-
let
|
|
324
|
+
function ot(t) {
|
|
325
|
+
const e = P(17);
|
|
326
|
+
let o, n, i, r;
|
|
309
327
|
e[0] !== t ? ({
|
|
310
|
-
label:
|
|
311
|
-
color:
|
|
312
|
-
sx:
|
|
313
|
-
...
|
|
314
|
-
} = t, e[0] = t, e[1] =
|
|
315
|
-
let
|
|
316
|
-
e[5] !==
|
|
317
|
-
backgroundColor:
|
|
318
|
-
} : void 0, e[5] =
|
|
328
|
+
label: n,
|
|
329
|
+
color: o,
|
|
330
|
+
sx: r,
|
|
331
|
+
...i
|
|
332
|
+
} = t, e[0] = t, e[1] = o, e[2] = n, e[3] = i, e[4] = r) : (o = e[1], n = e[2], i = e[3], r = e[4]);
|
|
333
|
+
let u;
|
|
334
|
+
e[5] !== o ? (u = o ? {
|
|
335
|
+
backgroundColor: o
|
|
336
|
+
} : void 0, e[5] = o, e[6] = u) : u = e[6];
|
|
319
337
|
let s;
|
|
320
|
-
e[7] !==
|
|
321
|
-
...
|
|
322
|
-
...
|
|
323
|
-
...
|
|
324
|
-
}, e[7] =
|
|
325
|
-
let
|
|
326
|
-
e[10] !==
|
|
327
|
-
let
|
|
328
|
-
e[12] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
329
|
-
let
|
|
330
|
-
return e[13] !==
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
] }), e[13] =
|
|
338
|
+
e[7] !== r || e[8] !== u ? (s = {
|
|
339
|
+
...ee.suggestionButton,
|
|
340
|
+
...u,
|
|
341
|
+
...r
|
|
342
|
+
}, e[7] = r, e[8] = u, e[9] = s) : s = e[9];
|
|
343
|
+
let l;
|
|
344
|
+
e[10] !== n ? (l = /* @__PURE__ */ a(z, { color: "inherit", variant: "body2", children: n }), e[10] = n, e[11] = l) : l = e[11];
|
|
345
|
+
let c;
|
|
346
|
+
e[12] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (c = /* @__PURE__ */ a(Fe, {}), e[12] = c) : c = e[12];
|
|
347
|
+
let f;
|
|
348
|
+
return e[13] !== i || e[14] !== s || e[15] !== l ? (f = /* @__PURE__ */ S(_e, { sx: s, ...i, children: [
|
|
349
|
+
l,
|
|
350
|
+
c
|
|
351
|
+
] }), e[13] = i, e[14] = s, e[15] = l, e[16] = f) : f = e[16], f;
|
|
334
352
|
}
|
|
335
|
-
const
|
|
353
|
+
const nt = ce`
|
|
336
354
|
0% {
|
|
337
355
|
background-position: 150% 0;
|
|
338
356
|
}
|
|
339
357
|
100% {
|
|
340
358
|
background-position: -50% 0;
|
|
341
359
|
}
|
|
342
|
-
`,
|
|
360
|
+
`, rt = ce`
|
|
343
361
|
0% { transform: scale(0.68); opacity: 0.7; }
|
|
344
362
|
40% { transform: scale(1); opacity: 1; }
|
|
345
363
|
80% { transform: scale(0.6); opacity: 0.65; }
|
|
346
364
|
100% { transform: scale(0.68); opacity: 0.7; }
|
|
347
|
-
`,
|
|
365
|
+
`, lt = ce`
|
|
348
366
|
0% { transform: scale(1); }
|
|
349
367
|
40% { transform: scale(0.75); }
|
|
350
368
|
80% { transform: scale(1.125); }
|
|
351
369
|
100% { transform: scale(1); }
|
|
352
|
-
`,
|
|
370
|
+
`, T = {
|
|
353
371
|
thinking: {
|
|
354
372
|
display: "flex",
|
|
355
373
|
alignItems: "center",
|
|
@@ -368,7 +386,7 @@ const tt = ce`
|
|
|
368
386
|
backgroundClip: "text",
|
|
369
387
|
WebkitBackgroundClip: "text",
|
|
370
388
|
WebkitTextFillColor: "transparent",
|
|
371
|
-
animation: `${
|
|
389
|
+
animation: `${nt} 2s ease-in-out infinite`,
|
|
372
390
|
animationDuration: "2s"
|
|
373
391
|
},
|
|
374
392
|
loader: {
|
|
@@ -386,7 +404,7 @@ const tt = ce`
|
|
|
386
404
|
backgroundColor: ({
|
|
387
405
|
palette: t
|
|
388
406
|
}) => t.action.disabled,
|
|
389
|
-
animation: `${
|
|
407
|
+
animation: `${rt} 1s ease-in-out infinite`
|
|
390
408
|
},
|
|
391
409
|
loaderInnerCircle: {
|
|
392
410
|
position: "absolute",
|
|
@@ -396,7 +414,7 @@ const tt = ce`
|
|
|
396
414
|
backgroundColor: ({
|
|
397
415
|
palette: t
|
|
398
416
|
}) => t.text.primary,
|
|
399
|
-
animation: `${
|
|
417
|
+
animation: `${lt} 1s ease-in-out infinite`
|
|
400
418
|
},
|
|
401
419
|
// --- Tool Trace styles ---
|
|
402
420
|
traceHeader: {
|
|
@@ -492,8 +510,15 @@ const tt = ce`
|
|
|
492
510
|
backgroundColor: ({
|
|
493
511
|
palette: t
|
|
494
512
|
}) => t.background.default,
|
|
495
|
-
|
|
496
|
-
|
|
513
|
+
fontFamily: ({
|
|
514
|
+
typography: t
|
|
515
|
+
}) => t.code3?.fontFamily ?? t.code1?.fontFamily ?? "monospace",
|
|
516
|
+
fontSize: ({
|
|
517
|
+
typography: t
|
|
518
|
+
}) => t.code3?.fontSize ?? "0.75rem",
|
|
519
|
+
lineHeight: ({
|
|
520
|
+
typography: t
|
|
521
|
+
}) => t.code3?.lineHeight ?? 1.333,
|
|
497
522
|
whiteSpace: "pre-wrap",
|
|
498
523
|
wordBreak: "break-word",
|
|
499
524
|
overflowY: "auto"
|
|
@@ -549,8 +574,12 @@ const tt = ce`
|
|
|
549
574
|
palette: t,
|
|
550
575
|
spacing: e
|
|
551
576
|
}) => `linear-gradient(to right, ${t.action.hover} calc(${e(1)} + 3em), ${t.background.default} calc(${e(1)} + 3em))`,
|
|
552
|
-
fontFamily:
|
|
553
|
-
|
|
577
|
+
fontFamily: ({
|
|
578
|
+
typography: t
|
|
579
|
+
}) => t.code3?.fontFamily ?? t.code1?.fontFamily ?? "monospace",
|
|
580
|
+
fontSize: ({
|
|
581
|
+
typography: t
|
|
582
|
+
}) => t.code3?.fontSize ?? "0.75rem",
|
|
554
583
|
whiteSpace: "pre-wrap",
|
|
555
584
|
wordBreak: "break-word",
|
|
556
585
|
lineHeight: 1.6,
|
|
@@ -630,58 +659,58 @@ const tt = ce`
|
|
|
630
659
|
}
|
|
631
660
|
}
|
|
632
661
|
};
|
|
633
|
-
function
|
|
634
|
-
const e =
|
|
635
|
-
children:
|
|
636
|
-
duration:
|
|
637
|
-
sx:
|
|
638
|
-
} = t,
|
|
639
|
-
let
|
|
640
|
-
e[0] !== s || e[1] !==
|
|
641
|
-
...
|
|
662
|
+
function it(t) {
|
|
663
|
+
const e = P(6), {
|
|
664
|
+
children: o,
|
|
665
|
+
duration: n,
|
|
666
|
+
sx: i
|
|
667
|
+
} = t, r = o === void 0 ? "Thinking..." : o, s = `${(n === void 0 ? 2e3 : n) / 1e3}s`;
|
|
668
|
+
let l;
|
|
669
|
+
e[0] !== s || e[1] !== i ? (l = {
|
|
670
|
+
...T.thinking,
|
|
642
671
|
animationDuration: s,
|
|
643
|
-
...
|
|
644
|
-
}, e[0] = s, e[1] =
|
|
645
|
-
let
|
|
646
|
-
return e[3] !==
|
|
672
|
+
...i
|
|
673
|
+
}, e[0] = s, e[1] = i, e[2] = l) : l = e[2];
|
|
674
|
+
let c;
|
|
675
|
+
return e[3] !== r || e[4] !== l ? (c = /* @__PURE__ */ a(z, { variant: "body2", sx: l, children: r }), e[3] = r, e[4] = l, e[5] = c) : c = e[5], c;
|
|
647
676
|
}
|
|
648
|
-
function
|
|
649
|
-
const e =
|
|
650
|
-
size:
|
|
651
|
-
labels:
|
|
652
|
-
sx:
|
|
653
|
-
} = t,
|
|
654
|
-
let d;
|
|
655
|
-
e[0] !== r ? (d = r === void 0 ? {} : r, e[0] = r, e[1] = d) : d = e[1];
|
|
656
|
-
const i = d.loading ?? "Loading";
|
|
657
|
-
let a;
|
|
658
|
-
e[2] !== o || e[3] !== l ? (a = {
|
|
659
|
-
...w.loader,
|
|
660
|
-
width: o,
|
|
661
|
-
height: o,
|
|
662
|
-
...l
|
|
663
|
-
}, e[2] = o, e[3] = l, e[4] = a) : a = e[4];
|
|
664
|
-
const p = o * 0.75, m = o * 0.75;
|
|
665
|
-
let g;
|
|
666
|
-
e[5] !== p || e[6] !== m ? (g = /* @__PURE__ */ c(C, { component: "span", sx: {
|
|
667
|
-
...w.loaderOuterCircle,
|
|
668
|
-
width: p,
|
|
669
|
-
height: m
|
|
670
|
-
} }), e[5] = p, e[6] = m, e[7] = g) : g = e[7];
|
|
671
|
-
const x = o * 0.32, h = o * 0.32;
|
|
677
|
+
function Mt(t) {
|
|
678
|
+
const e = P(16), {
|
|
679
|
+
size: o,
|
|
680
|
+
labels: n,
|
|
681
|
+
sx: i
|
|
682
|
+
} = t, r = o === void 0 ? 24 : o;
|
|
672
683
|
let u;
|
|
673
|
-
e[
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
684
|
+
e[0] !== n ? (u = n === void 0 ? {} : n, e[0] = n, e[1] = u) : u = e[1];
|
|
685
|
+
const l = u.loading ?? "Loading";
|
|
686
|
+
let c;
|
|
687
|
+
e[2] !== r || e[3] !== i ? (c = {
|
|
688
|
+
...T.loader,
|
|
689
|
+
width: r,
|
|
690
|
+
height: r,
|
|
691
|
+
...i
|
|
692
|
+
}, e[2] = r, e[3] = i, e[4] = c) : c = e[4];
|
|
693
|
+
const f = r * 0.75, m = r * 0.75;
|
|
694
|
+
let h;
|
|
695
|
+
e[5] !== f || e[6] !== m ? (h = /* @__PURE__ */ a(v, { component: "span", sx: {
|
|
696
|
+
...T.loaderOuterCircle,
|
|
697
|
+
width: f,
|
|
698
|
+
height: m
|
|
699
|
+
} }), e[5] = f, e[6] = m, e[7] = h) : h = e[7];
|
|
700
|
+
const b = r * 0.32, p = r * 0.32;
|
|
701
|
+
let g;
|
|
702
|
+
e[8] !== p || e[9] !== b ? (g = /* @__PURE__ */ a(v, { component: "span", sx: {
|
|
703
|
+
...T.loaderInnerCircle,
|
|
704
|
+
width: b,
|
|
705
|
+
height: p
|
|
706
|
+
} }), e[8] = p, e[9] = b, e[10] = g) : g = e[10];
|
|
707
|
+
let d;
|
|
708
|
+
return e[11] !== g || e[12] !== l || e[13] !== c || e[14] !== h ? (d = /* @__PURE__ */ S(v, { role: "status", "aria-busy": !0, "aria-label": l, sx: c, children: [
|
|
709
|
+
h,
|
|
710
|
+
g
|
|
711
|
+
] }), e[11] = g, e[12] = l, e[13] = c, e[14] = h, e[15] = d) : d = e[15], d;
|
|
683
712
|
}
|
|
684
|
-
const
|
|
713
|
+
const H = {
|
|
685
714
|
header: {
|
|
686
715
|
display: "flex",
|
|
687
716
|
alignItems: "center",
|
|
@@ -709,27 +738,146 @@ const z = {
|
|
|
709
738
|
footerWrapper: {
|
|
710
739
|
padding: ({
|
|
711
740
|
spacing: t
|
|
712
|
-
}) => t(1)
|
|
713
|
-
position: "relative"
|
|
714
|
-
},
|
|
715
|
-
footerCorner: {
|
|
716
|
-
position: "absolute",
|
|
717
|
-
bottom: "38px",
|
|
718
|
-
right: `max(16px, calc(50% - ${Q / 2}px + 6px))`,
|
|
719
|
-
margin: "0 auto"
|
|
741
|
+
}) => t(1)
|
|
720
742
|
},
|
|
721
|
-
|
|
722
|
-
|
|
743
|
+
/**
|
|
744
|
+
* Rounded input box, matching the reference ChatFooter. A two-column grid:
|
|
745
|
+
* main column (input + optional slots) | send button, bottom-aligned so it
|
|
746
|
+
* stays at the end as the input grows. NO vertical padding — the textarea's own
|
|
747
|
+
* padding sets the ~32px single-line height, so the box hugs the input.
|
|
748
|
+
*/
|
|
749
|
+
footerBox: {
|
|
750
|
+
maxWidth: ie,
|
|
751
|
+
width: "100%",
|
|
723
752
|
margin: "0 auto",
|
|
724
|
-
|
|
753
|
+
display: "grid",
|
|
754
|
+
gridTemplateColumns: "1fr auto",
|
|
755
|
+
alignItems: "end",
|
|
756
|
+
columnGap: ({
|
|
757
|
+
spacing: t
|
|
758
|
+
}) => t(0.5),
|
|
759
|
+
backgroundColor: ({
|
|
760
|
+
palette: t
|
|
761
|
+
}) => t.default?.background ?? "rgba(44, 48, 50, 0.04)",
|
|
762
|
+
borderRadius: ({
|
|
763
|
+
spacing: t
|
|
764
|
+
}) => t(0.5),
|
|
765
|
+
paddingInline: ({
|
|
766
|
+
spacing: t
|
|
767
|
+
}) => t(0.5)
|
|
768
|
+
},
|
|
769
|
+
/** Main grid area: input stacked above the (optional) slots row. */
|
|
770
|
+
footerMain: {
|
|
771
|
+
minWidth: 0,
|
|
772
|
+
display: "flex",
|
|
773
|
+
flexDirection: "column",
|
|
774
|
+
gap: ({
|
|
775
|
+
spacing: t
|
|
776
|
+
}) => t(0.5)
|
|
777
|
+
},
|
|
778
|
+
/**
|
|
779
|
+
* Send-button grid area, bottom-aligned (matches the reference flex-end row) so
|
|
780
|
+
* the button stays at the bottom as the input grows. The small bottom padding
|
|
781
|
+
* keeps it off the box edge — in the single-line state it reads as vertically
|
|
782
|
+
* centered (4px top / 4px bottom around the 24px button in the 32px row).
|
|
783
|
+
*/
|
|
784
|
+
footerSend: {
|
|
785
|
+
alignSelf: "end",
|
|
786
|
+
paddingBottom: ({
|
|
787
|
+
spacing: t
|
|
788
|
+
}) => t(0.5),
|
|
789
|
+
"& .MuiIconButton-root": {
|
|
790
|
+
padding: ({
|
|
791
|
+
spacing: t
|
|
792
|
+
}) => t(0.5)
|
|
793
|
+
}
|
|
794
|
+
},
|
|
795
|
+
/** The chrome-less multiline input (no underline / no filled affordance). */
|
|
796
|
+
footerInput: {
|
|
797
|
+
width: "100%",
|
|
798
|
+
typography: "body2",
|
|
799
|
+
// The Meridian theme styles multiline InputBase as a tall "comment field"
|
|
800
|
+
// (min-height: 96px on the root, 12px/14px textarea padding). Override both to
|
|
801
|
+
// get the compact chat field: kill the root min-height and use the reference's
|
|
802
|
+
// 6px/10px padding — both need !important to beat the theme override. Height
|
|
803
|
+
// then comes from MUI's TextareaAutosize (minRows=1/maxRows=8): one line
|
|
804
|
+
// (~32px) → grows → scrolls.
|
|
805
|
+
//
|
|
806
|
+
// TextareaAutosize renders a hidden shadow <textarea> (it carries
|
|
807
|
+
// `aria-hidden="true"`, the same class, and an inline `padding: 0`) to measure
|
|
808
|
+
// the content height; MUI then applies that height to the visible input. Getting
|
|
809
|
+
// the compact ~32px single line right needs the two rules below split apart:
|
|
810
|
+
//
|
|
811
|
+
// • Font metrics (size/line-height/letter-spacing) go on BOTH textareas. The
|
|
812
|
+
// shadow measures with its own CSS, so if it isn't pinned to body2 it
|
|
813
|
+
// measures at the default ~24px line-height and the box ends up too tall.
|
|
814
|
+
// • Padding goes on the VISIBLE input ONLY (`:not([aria-hidden])`). A
|
|
815
|
+
// `!important` padding that also hit the shadow would clobber its measurement
|
|
816
|
+
// `padding: 0`, double-counting the padding (~44px instead of 32px).
|
|
817
|
+
//
|
|
818
|
+
// `!important` is required on both to beat the Meridian theme's tall
|
|
819
|
+
// "comment field" multiline overrides (12px/14px padding, larger metrics); the
|
|
820
|
+
// root `min-height: 0` kills that theme's 96px min-height.
|
|
821
|
+
minHeight: "0 !important",
|
|
822
|
+
"& textarea": {
|
|
823
|
+
fontSize: ({
|
|
824
|
+
typography: t
|
|
825
|
+
}) => `${t.body2.fontSize} !important`,
|
|
826
|
+
lineHeight: ({
|
|
827
|
+
typography: t
|
|
828
|
+
}) => `${t.body2.lineHeight} !important`,
|
|
829
|
+
letterSpacing: ({
|
|
830
|
+
typography: t
|
|
831
|
+
}) => `${t.body2.letterSpacing} !important`
|
|
832
|
+
},
|
|
833
|
+
"& textarea:not([aria-hidden])": {
|
|
725
834
|
resize: "none",
|
|
726
|
-
|
|
727
|
-
overflowY: "auto !important",
|
|
728
|
-
paddingRight: ({
|
|
835
|
+
padding: ({
|
|
729
836
|
spacing: t
|
|
730
|
-
}) => t(
|
|
837
|
+
}) => `${t(0.75, 1.25)} !important`
|
|
731
838
|
}
|
|
732
839
|
},
|
|
840
|
+
/**
|
|
841
|
+
* Slots row under the input: start slot + model selector + end slot. The left
|
|
842
|
+
* padding lines the row's content up with the input text above it: the input
|
|
843
|
+
* text is inset ~12px from the box edge (InputBase root padding + the textarea's
|
|
844
|
+
* 10px left padding) while the model-selector text button only insets ~8px, so a
|
|
845
|
+
* 4px indent here makes the slot label share the placeholder's left edge instead
|
|
846
|
+
* of sitting further out.
|
|
847
|
+
*/
|
|
848
|
+
footerSlots: {
|
|
849
|
+
display: "flex",
|
|
850
|
+
alignItems: "center",
|
|
851
|
+
gap: ({
|
|
852
|
+
spacing: t
|
|
853
|
+
}) => t(0.5),
|
|
854
|
+
minWidth: 0,
|
|
855
|
+
flexWrap: "wrap",
|
|
856
|
+
paddingLeft: ({
|
|
857
|
+
spacing: t
|
|
858
|
+
}) => t(0.5),
|
|
859
|
+
paddingBottom: ({
|
|
860
|
+
spacing: t
|
|
861
|
+
}) => t(0.5)
|
|
862
|
+
},
|
|
863
|
+
modelSelector: {
|
|
864
|
+
textTransform: "none",
|
|
865
|
+
color: ({
|
|
866
|
+
palette: t
|
|
867
|
+
}) => t.text.secondary,
|
|
868
|
+
maxWidth: "100%",
|
|
869
|
+
minWidth: 0,
|
|
870
|
+
"& .MuiButton-endIcon": {
|
|
871
|
+
marginLeft: ({
|
|
872
|
+
spacing: t
|
|
873
|
+
}) => t(0.25)
|
|
874
|
+
}
|
|
875
|
+
},
|
|
876
|
+
modelSelectorLabel: {
|
|
877
|
+
overflow: "hidden",
|
|
878
|
+
textOverflow: "ellipsis",
|
|
879
|
+
whiteSpace: "nowrap"
|
|
880
|
+
},
|
|
733
881
|
footerCaption: {
|
|
734
882
|
textAlign: "center"
|
|
735
883
|
},
|
|
@@ -738,11 +886,11 @@ const z = {
|
|
|
738
886
|
flex: 1,
|
|
739
887
|
position: "relative",
|
|
740
888
|
mx: "auto",
|
|
741
|
-
maxWidth:
|
|
889
|
+
maxWidth: ie,
|
|
742
890
|
width: "100%",
|
|
743
891
|
maxHeight: "100%",
|
|
744
892
|
pt: 1,
|
|
745
|
-
pb:
|
|
893
|
+
pb: 3,
|
|
746
894
|
px: 2,
|
|
747
895
|
display: "flex",
|
|
748
896
|
flexDirection: "column",
|
|
@@ -777,7 +925,7 @@ const z = {
|
|
|
777
925
|
spacing: t
|
|
778
926
|
}) => t(3),
|
|
779
927
|
textAlign: "center",
|
|
780
|
-
maxWidth:
|
|
928
|
+
maxWidth: ie,
|
|
781
929
|
margin: "0 auto"
|
|
782
930
|
},
|
|
783
931
|
starterItems: {
|
|
@@ -790,164 +938,245 @@ const z = {
|
|
|
790
938
|
starterItemsTwoCol: {
|
|
791
939
|
gridTemplateColumns: "repeat(2, 1fr)"
|
|
792
940
|
}
|
|
793
|
-
},
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
941
|
+
}, st = 32, at = we(function(e, o) {
|
|
942
|
+
const n = P(34), {
|
|
943
|
+
children: i,
|
|
944
|
+
autoScroll: r,
|
|
945
|
+
labels: u,
|
|
946
|
+
sx: s
|
|
947
|
+
} = e, l = r === void 0 ? !0 : r;
|
|
948
|
+
let c;
|
|
949
|
+
n[0] !== u ? (c = u === void 0 ? {} : u, n[0] = u, n[1] = c) : c = n[1];
|
|
950
|
+
const f = c, m = ne(null), h = ne(null), b = ne(null), [p, g] = te(!0), [d, x] = te(!0);
|
|
951
|
+
let y;
|
|
952
|
+
n[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (y = () => {
|
|
953
|
+
m.current?.scrollTo({
|
|
954
|
+
top: m.current.scrollHeight,
|
|
802
955
|
behavior: "smooth"
|
|
803
956
|
});
|
|
804
|
-
},
|
|
805
|
-
|
|
957
|
+
}, n[2] = y) : y = n[2];
|
|
958
|
+
const C = y;
|
|
959
|
+
let w;
|
|
960
|
+
n[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (w = () => {
|
|
961
|
+
m.current?.scrollTo({
|
|
806
962
|
top: 0,
|
|
807
963
|
behavior: "smooth"
|
|
808
964
|
});
|
|
809
|
-
};
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
|
|
821
|
-
|
|
965
|
+
}, n[3] = w) : w = n[3];
|
|
966
|
+
const _ = w;
|
|
967
|
+
let L, $;
|
|
968
|
+
n[4] !== d || n[5] !== p ? (L = () => ({
|
|
969
|
+
scrollToBottom: C,
|
|
970
|
+
scrollToTop: _,
|
|
971
|
+
isAtBottom: d,
|
|
972
|
+
isAtTop: p
|
|
973
|
+
}), $ = [d, p], n[4] = d, n[5] = p, n[6] = L, n[7] = $) : (L = n[6], $ = n[7]), Te(o, L, $);
|
|
974
|
+
let A, M;
|
|
975
|
+
n[8] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (A = () => {
|
|
976
|
+
const I = m.current, F = h.current, W = b.current;
|
|
977
|
+
if (!I || !F || !W)
|
|
978
|
+
return;
|
|
979
|
+
const X = new IntersectionObserver((k) => {
|
|
980
|
+
const [E] = k;
|
|
981
|
+
return g(E?.isIntersecting ?? !0);
|
|
982
|
+
}, {
|
|
983
|
+
root: I
|
|
984
|
+
}), N = new IntersectionObserver((k) => {
|
|
985
|
+
const [E] = k;
|
|
986
|
+
return x(E?.isIntersecting ?? !0);
|
|
987
|
+
}, {
|
|
988
|
+
root: I
|
|
822
989
|
});
|
|
823
|
-
return
|
|
824
|
-
|
|
990
|
+
return X.observe(F), N.observe(W), () => {
|
|
991
|
+
X.disconnect(), N.disconnect();
|
|
825
992
|
};
|
|
826
|
-
}, []),
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
if (!
|
|
830
|
-
|
|
831
|
-
const
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
993
|
+
}, M = [], n[8] = A, n[9] = M) : (A = n[8], M = n[9]), re(A, M);
|
|
994
|
+
let R, O;
|
|
995
|
+
n[10] !== l ? (R = () => {
|
|
996
|
+
if (!l)
|
|
997
|
+
return;
|
|
998
|
+
const I = m.current;
|
|
999
|
+
if (!I)
|
|
1000
|
+
return;
|
|
1001
|
+
let F = I.scrollHeight, W = null;
|
|
1002
|
+
const X = () => {
|
|
1003
|
+
W = null;
|
|
1004
|
+
const k = I.scrollHeight;
|
|
1005
|
+
if (k > F) {
|
|
1006
|
+
const E = k - F;
|
|
1007
|
+
k - I.scrollTop - I.clientHeight <= E + st && I.scrollTo({
|
|
1008
|
+
top: k,
|
|
838
1009
|
behavior: "smooth"
|
|
839
1010
|
});
|
|
840
1011
|
}
|
|
841
|
-
|
|
842
|
-
},
|
|
843
|
-
|
|
1012
|
+
F = k;
|
|
1013
|
+
}, N = new MutationObserver(() => {
|
|
1014
|
+
W = W ?? requestAnimationFrame(X);
|
|
844
1015
|
});
|
|
845
|
-
return
|
|
1016
|
+
return N.observe(I, {
|
|
846
1017
|
childList: !0,
|
|
847
1018
|
subtree: !0,
|
|
848
1019
|
characterData: !0
|
|
849
1020
|
}), () => {
|
|
850
|
-
|
|
1021
|
+
N.disconnect(), W !== null && cancelAnimationFrame(W);
|
|
851
1022
|
};
|
|
852
|
-
}, [n]
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
1023
|
+
}, O = [l], n[10] = l, n[11] = R, n[12] = O) : (R = n[11], O = n[12]), re(R, O);
|
|
1024
|
+
let B;
|
|
1025
|
+
n[13] !== p ? (B = (I) => {
|
|
1026
|
+
const {
|
|
1027
|
+
palette: F
|
|
1028
|
+
} = I;
|
|
1029
|
+
return p ? "transparent" : F.divider;
|
|
1030
|
+
}, n[13] = p, n[14] = B) : B = n[14];
|
|
1031
|
+
let D;
|
|
1032
|
+
n[15] !== d ? (D = (I) => {
|
|
1033
|
+
const {
|
|
1034
|
+
palette: F
|
|
1035
|
+
} = I;
|
|
1036
|
+
return d ? "transparent" : F.divider;
|
|
1037
|
+
}, n[15] = d, n[16] = D) : D = n[16];
|
|
1038
|
+
let j;
|
|
1039
|
+
n[17] !== s || n[18] !== B || n[19] !== D ? (j = {
|
|
1040
|
+
...H.content,
|
|
1041
|
+
borderTopColor: B,
|
|
1042
|
+
borderBottomColor: D,
|
|
1043
|
+
...s
|
|
1044
|
+
}, n[17] = s, n[18] = B, n[19] = D, n[20] = j) : j = n[20];
|
|
1045
|
+
let K;
|
|
1046
|
+
n[21] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (K = /* @__PURE__ */ a(v, { ref: h, sx: H.sentinel, "aria-hidden": !0 }), n[21] = K) : K = n[21];
|
|
1047
|
+
let G;
|
|
1048
|
+
n[22] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (G = /* @__PURE__ */ a(v, { ref: b, sx: H.sentinel, "aria-hidden": !0 }), n[22] = G) : G = n[22];
|
|
1049
|
+
const J = f.jumpToLatest ?? "Jump to latest", Q = d ? 0 : 1, Z = d ? "none" : "auto";
|
|
1050
|
+
let U;
|
|
1051
|
+
n[23] !== Q || n[24] !== Z ? (U = {
|
|
1052
|
+
...H.jumpToLatest,
|
|
1053
|
+
opacity: Q,
|
|
1054
|
+
pointerEvents: Z
|
|
1055
|
+
}, n[23] = Q, n[24] = Z, n[25] = U) : U = n[25];
|
|
1056
|
+
let Y;
|
|
1057
|
+
n[26] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (Y = /* @__PURE__ */ a(xe, {}), n[26] = Y) : Y = n[26];
|
|
1058
|
+
let q;
|
|
1059
|
+
n[27] !== J || n[28] !== U ? (q = /* @__PURE__ */ a(v, { sx: H.jumpToLatestWrapper, children: /* @__PURE__ */ a(Ae, { size: "small", onClick: C, "aria-label": J, sx: U, children: Y }) }), n[27] = J, n[28] = U, n[29] = q) : q = n[29];
|
|
1060
|
+
let V;
|
|
1061
|
+
return n[30] !== i || n[31] !== j || n[32] !== q ? (V = /* @__PURE__ */ S(v, { ref: m, sx: j, children: [
|
|
1062
|
+
K,
|
|
1063
|
+
i,
|
|
1064
|
+
G,
|
|
1065
|
+
q
|
|
1066
|
+
] }), n[30] = i, n[31] = j, n[32] = q, n[33] = V) : V = n[33], V;
|
|
871
1067
|
});
|
|
872
|
-
|
|
873
|
-
function
|
|
874
|
-
const e =
|
|
875
|
-
leftSlot:
|
|
876
|
-
title:
|
|
877
|
-
rightSlot:
|
|
878
|
-
onClose:
|
|
879
|
-
sx:
|
|
1068
|
+
at.displayName = "ChatContent";
|
|
1069
|
+
function zt(t) {
|
|
1070
|
+
const e = P(14), {
|
|
1071
|
+
leftSlot: o,
|
|
1072
|
+
title: n,
|
|
1073
|
+
rightSlot: i,
|
|
1074
|
+
onClose: r,
|
|
1075
|
+
sx: u
|
|
880
1076
|
} = t;
|
|
881
1077
|
let s;
|
|
882
|
-
e[0] !==
|
|
883
|
-
...
|
|
884
|
-
...
|
|
885
|
-
}, e[0] =
|
|
886
|
-
let
|
|
887
|
-
e[2] !==
|
|
888
|
-
let
|
|
889
|
-
e[4] !==
|
|
890
|
-
let
|
|
891
|
-
e[6] !==
|
|
892
|
-
l,
|
|
893
|
-
a
|
|
894
|
-
] }), e[6] = l, e[7] = a, e[8] = p) : p = e[8];
|
|
895
|
-
let m;
|
|
896
|
-
return e[9] !== n || e[10] !== s || e[11] !== i || e[12] !== p ? (m = /* @__PURE__ */ k(C, { sx: s, children: [
|
|
897
|
-
n,
|
|
1078
|
+
e[0] !== u ? (s = {
|
|
1079
|
+
...H.header,
|
|
1080
|
+
...u
|
|
1081
|
+
}, e[0] = u, e[1] = s) : s = e[1];
|
|
1082
|
+
let l;
|
|
1083
|
+
e[2] !== n ? (l = /* @__PURE__ */ a(z, { variant: "subtitle2", sx: H.headerTitle, children: n }), e[2] = n, e[3] = l) : l = e[3];
|
|
1084
|
+
let c;
|
|
1085
|
+
e[4] !== r ? (c = r && /* @__PURE__ */ a(oe, { size: "medium", onClick: r, "aria-label": "Close", children: /* @__PURE__ */ a(be, {}) }), e[4] = r, e[5] = c) : c = e[5];
|
|
1086
|
+
let f;
|
|
1087
|
+
e[6] !== i || e[7] !== c ? (f = /* @__PURE__ */ S(v, { sx: H.headerActions, children: [
|
|
898
1088
|
i,
|
|
899
|
-
|
|
900
|
-
] }), e[
|
|
1089
|
+
c
|
|
1090
|
+
] }), e[6] = i, e[7] = c, e[8] = f) : f = e[8];
|
|
1091
|
+
let m;
|
|
1092
|
+
return e[9] !== o || e[10] !== s || e[11] !== l || e[12] !== f ? (m = /* @__PURE__ */ S(v, { sx: s, children: [
|
|
1093
|
+
o,
|
|
1094
|
+
l,
|
|
1095
|
+
f
|
|
1096
|
+
] }), e[9] = o, e[10] = s, e[11] = l, e[12] = f, e[13] = m) : m = e[13], m;
|
|
901
1097
|
}
|
|
902
|
-
const
|
|
903
|
-
function
|
|
904
|
-
const e =
|
|
905
|
-
value:
|
|
906
|
-
onChange:
|
|
907
|
-
onSend:
|
|
908
|
-
onStop:
|
|
909
|
-
isGenerating:
|
|
1098
|
+
const ct = "Responses are AI-generated. Please verify key information.";
|
|
1099
|
+
function Wt(t) {
|
|
1100
|
+
const e = P(58), {
|
|
1101
|
+
value: o,
|
|
1102
|
+
onChange: n,
|
|
1103
|
+
onSend: i,
|
|
1104
|
+
onStop: r,
|
|
1105
|
+
isGenerating: u,
|
|
910
1106
|
disabled: s,
|
|
911
|
-
placeholder:
|
|
912
|
-
labels:
|
|
913
|
-
caption:
|
|
914
|
-
|
|
915
|
-
|
|
916
|
-
|
|
917
|
-
|
|
918
|
-
|
|
919
|
-
|
|
920
|
-
|
|
921
|
-
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
926
|
-
const
|
|
927
|
-
let _;
|
|
928
|
-
e[9] !== m ? (_ = {
|
|
929
|
-
...z.footerWrapper,
|
|
930
|
-
...m
|
|
931
|
-
}, e[9] = m, e[10] = _) : _ = e[10];
|
|
932
|
-
let E;
|
|
933
|
-
e[11] !== r ? (E = (M) => r(M.target.value), e[11] = r, e[12] = E) : E = e[12];
|
|
934
|
-
const L = x || g;
|
|
935
|
-
let $;
|
|
936
|
-
e[13] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? ($ = {
|
|
937
|
-
minHeight: 0
|
|
938
|
-
}, e[13] = $) : $ = e[13];
|
|
939
|
-
let I;
|
|
940
|
-
e[14] !== S || e[15] !== h || e[16] !== E || e[17] !== L || e[18] !== n ? (I = /* @__PURE__ */ c(_e, { multiline: !0, value: n, onChange: E, onKeyDown: S, placeholder: h, disabled: L, sx: z.footer, style: $, fullWidth: !0, size: "small" }), e[14] = S, e[15] = h, e[16] = E, e[17] = L, e[18] = n, e[19] = I) : I = e[19];
|
|
941
|
-
let B;
|
|
942
|
-
e[20] !== y || e[21] !== x || e[22] !== g || e[23] !== f.send || e[24] !== f.stop || e[25] !== l || e[26] !== o ? (B = /* @__PURE__ */ c(C, { sx: z.footerCorner, children: g && o ? /* @__PURE__ */ c(H, { size: "small", onClick: o, disabled: x, "aria-label": f.stop ?? "Stop", children: /* @__PURE__ */ c(ze, {}) }) : /* @__PURE__ */ c(H, { size: "small", variant: "contained", onClick: l, disabled: !y, "aria-label": f.send ?? "Send", children: /* @__PURE__ */ c(Me, {}) }) }), e[20] = y, e[21] = x, e[22] = g, e[23] = f.send, e[24] = f.stop, e[25] = l, e[26] = o, e[27] = B) : B = e[27];
|
|
943
|
-
let R;
|
|
944
|
-
e[28] !== b ? (R = b ? /* @__PURE__ */ c(Ie, { sx: z.footerCaption, children: b }) : null, e[28] = b, e[29] = R) : R = e[29];
|
|
1107
|
+
placeholder: l,
|
|
1108
|
+
labels: c,
|
|
1109
|
+
caption: f,
|
|
1110
|
+
models: m,
|
|
1111
|
+
selectedModel: h,
|
|
1112
|
+
onModelChange: b,
|
|
1113
|
+
startToolbarSlot: p,
|
|
1114
|
+
endToolbarSlot: g,
|
|
1115
|
+
sx: d
|
|
1116
|
+
} = t, x = u === void 0 ? !1 : u, y = s === void 0 ? !1 : s, C = l === void 0 ? "Type a message..." : l;
|
|
1117
|
+
let w;
|
|
1118
|
+
e[0] !== c ? (w = c === void 0 ? {} : c, e[0] = c, e[1] = w) : w = e[1];
|
|
1119
|
+
const _ = w, L = f === void 0 ? ct : f, [$, A] = te(null);
|
|
1120
|
+
let M;
|
|
1121
|
+
e[2] !== y || e[3] !== x || e[4] !== o ? (M = o.trim() && !y && !x, e[2] = y, e[3] = x, e[4] = o, e[5] = M) : M = e[5];
|
|
1122
|
+
const R = M, O = (m?.length ?? 0) > 1, B = _.model ?? "Select model";
|
|
945
1123
|
let D;
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
1124
|
+
e[6] !== B || e[7] !== m || e[8] !== h ? (D = m?.find((E) => E.value === h)?.label ?? (h && h.length > 0 ? h : B), e[6] = B, e[7] = m, e[8] = h, e[9] = D) : D = e[9];
|
|
1125
|
+
const j = D, K = O || !!p || !!g;
|
|
1126
|
+
let G;
|
|
1127
|
+
e[10] !== R || e[11] !== i ? (G = (E) => {
|
|
1128
|
+
E.key === "Enter" && !E.shiftKey && (E.preventDefault(), R && i());
|
|
1129
|
+
}, e[10] = R, e[11] = i, e[12] = G) : G = e[12];
|
|
1130
|
+
const J = G;
|
|
1131
|
+
let Q;
|
|
1132
|
+
e[13] !== R || e[14] !== y || e[15] !== x || e[16] !== _.send || e[17] !== _.stop || e[18] !== i || e[19] !== r ? (Q = x && r ? /* @__PURE__ */ a(oe, { size: "small", onClick: r, disabled: y, "aria-label": _.stop ?? "Stop", children: /* @__PURE__ */ a(Oe, {}) }) : /* @__PURE__ */ a(oe, { size: "small", variant: "contained", color: "primary", onClick: i, disabled: !R, "aria-label": _.send ?? "Send", children: /* @__PURE__ */ a(He, {}) }), e[13] = R, e[14] = y, e[15] = x, e[16] = _.send, e[17] = _.stop, e[18] = i, e[19] = r, e[20] = Q) : Q = e[20];
|
|
1133
|
+
const Z = Q;
|
|
1134
|
+
let U;
|
|
1135
|
+
e[21] !== d ? (U = {
|
|
1136
|
+
...H.footerWrapper,
|
|
1137
|
+
...d
|
|
1138
|
+
}, e[21] = d, e[22] = U) : U = e[22];
|
|
1139
|
+
let Y;
|
|
1140
|
+
e[23] !== n ? (Y = (E) => n(E.target.value), e[23] = n, e[24] = Y) : Y = e[24];
|
|
1141
|
+
const q = y || x;
|
|
1142
|
+
let V;
|
|
1143
|
+
e[25] !== J || e[26] !== C || e[27] !== Y || e[28] !== q || e[29] !== o ? (V = /* @__PURE__ */ a($e, { multiline: !0, minRows: 1, maxRows: 8, value: o, onChange: Y, onKeyDown: J, placeholder: C, disabled: q, sx: H.footerInput }), e[25] = J, e[26] = C, e[27] = Y, e[28] = q, e[29] = o, e[30] = V) : V = e[30];
|
|
1144
|
+
let I;
|
|
1145
|
+
e[31] !== y || e[32] !== g || e[33] !== K || e[34] !== x || e[35] !== $ || e[36] !== B || e[37] !== m || e[38] !== b || e[39] !== j || e[40] !== h || e[41] !== O || e[42] !== p ? (I = K && /* @__PURE__ */ S(v, { sx: H.footerSlots, children: [
|
|
1146
|
+
p,
|
|
1147
|
+
O && /* @__PURE__ */ S(he, { children: [
|
|
1148
|
+
/* @__PURE__ */ a(le, { size: "small", variant: "text", color: "inherit", disabled: y || x, onClick: (E) => A(E.currentTarget), "aria-label": B, "aria-haspopup": "menu", "aria-expanded": $ ? "true" : void 0, endIcon: /* @__PURE__ */ a(xe, {}), sx: H.modelSelector, children: /* @__PURE__ */ a(z, { variant: "caption", component: "span", color: "inherit", sx: H.modelSelectorLabel, children: j }) }),
|
|
1149
|
+
/* @__PURE__ */ a(Ie, { anchorEl: $, open: !!$, onClose: () => A(null), variant: "menu", elevation: 8, anchorOrigin: {
|
|
1150
|
+
vertical: "top",
|
|
1151
|
+
horizontal: "left"
|
|
1152
|
+
}, transformOrigin: {
|
|
1153
|
+
vertical: "bottom",
|
|
1154
|
+
horizontal: "left"
|
|
1155
|
+
}, children: m?.map((E) => /* @__PURE__ */ a(Le, { selected: E.value === h, onClick: () => {
|
|
1156
|
+
b?.(E.value), A(null);
|
|
1157
|
+
}, children: E.label }, E.value)) })
|
|
1158
|
+
] }),
|
|
1159
|
+
g
|
|
1160
|
+
] }), e[31] = y, e[32] = g, e[33] = K, e[34] = x, e[35] = $, e[36] = B, e[37] = m, e[38] = b, e[39] = j, e[40] = h, e[41] = O, e[42] = p, e[43] = I) : I = e[43];
|
|
1161
|
+
let F;
|
|
1162
|
+
e[44] !== V || e[45] !== I ? (F = /* @__PURE__ */ S(v, { sx: H.footerMain, children: [
|
|
1163
|
+
V,
|
|
1164
|
+
I
|
|
1165
|
+
] }), e[44] = V, e[45] = I, e[46] = F) : F = e[46];
|
|
1166
|
+
let W;
|
|
1167
|
+
e[47] !== Z ? (W = /* @__PURE__ */ a(v, { sx: H.footerSend, children: Z }), e[47] = Z, e[48] = W) : W = e[48];
|
|
1168
|
+
let X;
|
|
1169
|
+
e[49] !== F || e[50] !== W ? (X = /* @__PURE__ */ S(v, { sx: H.footerBox, children: [
|
|
1170
|
+
F,
|
|
1171
|
+
W
|
|
1172
|
+
] }), e[49] = F, e[50] = W, e[51] = X) : X = e[51];
|
|
1173
|
+
let N;
|
|
1174
|
+
e[52] !== L ? (N = L ? /* @__PURE__ */ a(Ee, { sx: H.footerCaption, children: L }) : null, e[52] = L, e[53] = N) : N = e[53];
|
|
1175
|
+
let k;
|
|
1176
|
+
return e[54] !== U || e[55] !== X || e[56] !== N ? (k = /* @__PURE__ */ S(Re, { fullWidth: !0, sx: U, children: [
|
|
1177
|
+
X,
|
|
1178
|
+
N
|
|
1179
|
+
] }), e[54] = U, e[55] = X, e[56] = N, e[57] = k) : k = e[57], k;
|
|
951
1180
|
}
|
|
952
1181
|
const de = [
|
|
953
1182
|
"#C9DB7440",
|
|
@@ -960,46 +1189,46 @@ const de = [
|
|
|
960
1189
|
// pastel yellow
|
|
961
1190
|
];
|
|
962
1191
|
function Ft(t) {
|
|
963
|
-
const e =
|
|
964
|
-
icon:
|
|
965
|
-
title:
|
|
966
|
-
description:
|
|
967
|
-
items:
|
|
968
|
-
size:
|
|
1192
|
+
const e = P(40), {
|
|
1193
|
+
icon: o,
|
|
1194
|
+
title: n,
|
|
1195
|
+
description: i,
|
|
1196
|
+
items: r,
|
|
1197
|
+
size: u,
|
|
969
1198
|
onSelect: s,
|
|
970
|
-
sx:
|
|
971
|
-
} = t,
|
|
972
|
-
let
|
|
973
|
-
if (e[0] !==
|
|
974
|
-
const
|
|
975
|
-
m =
|
|
976
|
-
const
|
|
977
|
-
e[15] !==
|
|
978
|
-
...
|
|
979
|
-
gap: S,
|
|
980
|
-
...i
|
|
981
|
-
}, e[15] = i, e[16] = S, e[17] = h) : h = e[17], u = n, e[18] !== a || e[19] !== r ? (f = r && /* @__PURE__ */ c(A, { variant: a === "small" ? "h6" : "h5", children: r }), e[18] = a, e[19] = r, e[20] = f) : f = e[20], e[21] !== l || e[22] !== a ? (b = l && /* @__PURE__ */ c(A, { variant: a === "small" ? "body2" : "body1", color: "text.secondary", children: l }), e[21] = l, e[22] = a, e[23] = b) : b = e[23], p = C;
|
|
982
|
-
const _ = a === "small" ? 1 : 2, E = o.length > 2 ? z.starterItemsTwoCol : void 0;
|
|
983
|
-
e[24] !== E || e[25] !== _ ? (g = {
|
|
984
|
-
...z.starterItems,
|
|
1199
|
+
sx: l
|
|
1200
|
+
} = t, c = u === void 0 ? "small" : u;
|
|
1201
|
+
let f, m, h, b, p, g, d, x;
|
|
1202
|
+
if (e[0] !== i || e[1] !== o || e[2] !== r || e[3] !== s || e[4] !== c || e[5] !== l || e[6] !== n) {
|
|
1203
|
+
const w = r.map(dt);
|
|
1204
|
+
m = v;
|
|
1205
|
+
const _ = c === "small" ? 1 : 2;
|
|
1206
|
+
e[15] !== l || e[16] !== _ ? (p = {
|
|
1207
|
+
...H.starter,
|
|
985
1208
|
gap: _,
|
|
986
|
-
...
|
|
987
|
-
}, e[
|
|
988
|
-
|
|
989
|
-
e[
|
|
1209
|
+
...l
|
|
1210
|
+
}, e[15] = l, e[16] = _, e[17] = p) : p = e[17], g = o, e[18] !== c || e[19] !== n ? (d = n && /* @__PURE__ */ a(z, { variant: c === "small" ? "h6" : "h5", children: n }), e[18] = c, e[19] = n, e[20] = d) : d = e[20], e[21] !== i || e[22] !== c ? (x = i && /* @__PURE__ */ a(z, { variant: c === "small" ? "body2" : "body1", color: "text.secondary", children: i }), e[21] = i, e[22] = c, e[23] = x) : x = e[23], f = v;
|
|
1211
|
+
const L = c === "small" ? 1 : 2, $ = r.length > 2 ? H.starterItemsTwoCol : void 0;
|
|
1212
|
+
e[24] !== $ || e[25] !== L ? (h = {
|
|
1213
|
+
...H.starterItems,
|
|
1214
|
+
gap: L,
|
|
1215
|
+
...$
|
|
1216
|
+
}, e[24] = $, e[25] = L, e[26] = h) : h = e[26];
|
|
1217
|
+
let A;
|
|
1218
|
+
e[27] !== s ? (A = (M, R) => /* @__PURE__ */ a(ot, { label: M.label, onClick: () => s?.(M.label), color: M.color }, R), e[27] = s, e[28] = A) : A = e[28], b = w.map(A), e[0] = i, e[1] = o, e[2] = r, e[3] = s, e[4] = c, e[5] = l, e[6] = n, e[7] = f, e[8] = m, e[9] = h, e[10] = b, e[11] = p, e[12] = g, e[13] = d, e[14] = x;
|
|
990
1219
|
} else
|
|
991
|
-
|
|
992
|
-
let v;
|
|
993
|
-
e[29] !== p || e[30] !== g || e[31] !== x ? (v = /* @__PURE__ */ c(p, { sx: g, children: x }), e[29] = p, e[30] = g, e[31] = x, e[32] = v) : v = e[32];
|
|
1220
|
+
f = e[7], m = e[8], h = e[9], b = e[10], p = e[11], g = e[12], d = e[13], x = e[14];
|
|
994
1221
|
let y;
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1222
|
+
e[29] !== f || e[30] !== h || e[31] !== b ? (y = /* @__PURE__ */ a(f, { sx: h, children: b }), e[29] = f, e[30] = h, e[31] = b, e[32] = y) : y = e[32];
|
|
1223
|
+
let C;
|
|
1224
|
+
return e[33] !== m || e[34] !== p || e[35] !== g || e[36] !== d || e[37] !== x || e[38] !== y ? (C = /* @__PURE__ */ S(m, { sx: p, children: [
|
|
1225
|
+
g,
|
|
1226
|
+
d,
|
|
1227
|
+
x,
|
|
1228
|
+
y
|
|
1229
|
+
] }), e[33] = m, e[34] = p, e[35] = g, e[36] = d, e[37] = x, e[38] = y, e[39] = C) : C = e[39], C;
|
|
1001
1230
|
}
|
|
1002
|
-
function
|
|
1231
|
+
function dt(t, e) {
|
|
1003
1232
|
return typeof t == "string" ? {
|
|
1004
1233
|
label: t,
|
|
1005
1234
|
color: de[e]
|
|
@@ -1008,500 +1237,500 @@ function at(t, e) {
|
|
|
1008
1237
|
color: t.color ?? de[e]
|
|
1009
1238
|
};
|
|
1010
1239
|
}
|
|
1011
|
-
const
|
|
1240
|
+
const Ot = ae(v)(({
|
|
1012
1241
|
theme: t
|
|
1013
1242
|
}) => ({
|
|
1014
1243
|
display: "flex",
|
|
1015
1244
|
alignItems: "center",
|
|
1016
1245
|
gap: t.spacing(0.5)
|
|
1017
1246
|
}));
|
|
1018
|
-
function
|
|
1019
|
-
const e =
|
|
1020
|
-
rating:
|
|
1021
|
-
onRatingChange:
|
|
1022
|
-
labels:
|
|
1247
|
+
function Ht(t) {
|
|
1248
|
+
const e = P(25), {
|
|
1249
|
+
rating: o,
|
|
1250
|
+
onRatingChange: n,
|
|
1251
|
+
labels: i
|
|
1023
1252
|
} = t;
|
|
1024
|
-
let
|
|
1025
|
-
e[0] !==
|
|
1026
|
-
const
|
|
1253
|
+
let r;
|
|
1254
|
+
e[0] !== i ? (r = i === void 0 ? {} : i, e[0] = i, e[1] = r) : r = e[1];
|
|
1255
|
+
const u = r;
|
|
1027
1256
|
let s;
|
|
1028
|
-
e[2] !==
|
|
1029
|
-
const
|
|
1030
|
-
let
|
|
1031
|
-
e[5] !==
|
|
1257
|
+
e[2] !== n || e[3] !== o ? (s = () => n?.(o === "up" ? null : "up"), e[2] = n, e[3] = o, e[4] = s) : s = e[4];
|
|
1258
|
+
const l = u.thumbUp ?? "Thumbs up", c = o === "up" ? "primary" : void 0;
|
|
1259
|
+
let f;
|
|
1260
|
+
e[5] !== o ? (f = o === "up" ? /* @__PURE__ */ a(Pe, { fontSize: "small" }) : /* @__PURE__ */ a(Ve, { fontSize: "small" }), e[5] = o, e[6] = f) : f = e[6];
|
|
1032
1261
|
let m;
|
|
1033
|
-
e[7] !== s || e[8] !==
|
|
1262
|
+
e[7] !== s || e[8] !== l || e[9] !== c || e[10] !== f ? (m = /* @__PURE__ */ a(oe, { size: "small", onClick: s, "aria-label": l, color: c, children: f }), e[7] = s, e[8] = l, e[9] = c, e[10] = f, e[11] = m) : m = e[11];
|
|
1263
|
+
let h;
|
|
1264
|
+
e[12] !== n || e[13] !== o ? (h = () => n?.(o === "down" ? null : "down"), e[12] = n, e[13] = o, e[14] = h) : h = e[14];
|
|
1265
|
+
const b = u.thumbDown ?? "Thumbs down", p = o === "down" ? "primary" : void 0;
|
|
1034
1266
|
let g;
|
|
1035
|
-
e[
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
e[17] !== h || e[18] !== u || e[19] !== g || e[20] !== x ? (f = /* @__PURE__ */ c(H, { size: "small", onClick: g, "aria-label": x, color: h, children: u }), e[17] = h, e[18] = u, e[19] = g, e[20] = x, e[21] = f) : f = e[21];
|
|
1041
|
-
let b;
|
|
1042
|
-
return e[22] !== f || e[23] !== m ? (b = /* @__PURE__ */ k(we, { children: [
|
|
1267
|
+
e[15] !== o ? (g = o === "down" ? /* @__PURE__ */ a(je, { fontSize: "small" }) : /* @__PURE__ */ a(Ue, { fontSize: "small" }), e[15] = o, e[16] = g) : g = e[16];
|
|
1268
|
+
let d;
|
|
1269
|
+
e[17] !== p || e[18] !== g || e[19] !== h || e[20] !== b ? (d = /* @__PURE__ */ a(oe, { size: "small", onClick: h, "aria-label": b, color: p, children: g }), e[17] = p, e[18] = g, e[19] = h, e[20] = b, e[21] = d) : d = e[21];
|
|
1270
|
+
let x;
|
|
1271
|
+
return e[22] !== d || e[23] !== m ? (x = /* @__PURE__ */ S(he, { children: [
|
|
1043
1272
|
m,
|
|
1044
|
-
|
|
1045
|
-
] }), e[22] =
|
|
1273
|
+
d
|
|
1274
|
+
] }), e[22] = d, e[23] = m, e[24] = x) : x = e[24], x;
|
|
1046
1275
|
}
|
|
1047
|
-
const
|
|
1048
|
-
function
|
|
1276
|
+
const ut = /^-?\d/;
|
|
1277
|
+
function ft(t) {
|
|
1049
1278
|
const e = [];
|
|
1050
|
-
let
|
|
1051
|
-
const
|
|
1052
|
-
let
|
|
1053
|
-
for (; (
|
|
1054
|
-
|
|
1279
|
+
let o = 0, n;
|
|
1280
|
+
const i = /* @__PURE__ */ new Set(), r = /("(?:[^"\\]|\\.)*")\s*:/g;
|
|
1281
|
+
let u;
|
|
1282
|
+
for (; (u = r.exec(t)) !== null; )
|
|
1283
|
+
i.add(u.index);
|
|
1055
1284
|
const s = (
|
|
1056
1285
|
// eslint-disable-next-line no-useless-escape
|
|
1057
1286
|
/"(?:[^"\\]|\\.)*"|\b(?:true|false)\b|\bnull\b|-?\d+(?:\.\d+)?(?:[eE][+-]?\d+)?|[{}\[\]:,]/g
|
|
1058
1287
|
);
|
|
1059
|
-
for (; (
|
|
1060
|
-
|
|
1061
|
-
const
|
|
1062
|
-
|
|
1288
|
+
for (; (n = s.exec(t)) !== null; ) {
|
|
1289
|
+
n.index > o && e.push(t.slice(o, n.index));
|
|
1290
|
+
const l = n[0];
|
|
1291
|
+
l.startsWith('"') ? i.has(n.index) ? e.push({
|
|
1063
1292
|
type: "key",
|
|
1064
|
-
value:
|
|
1293
|
+
value: l
|
|
1065
1294
|
}) : e.push({
|
|
1066
1295
|
type: "string",
|
|
1067
|
-
value:
|
|
1068
|
-
}) :
|
|
1296
|
+
value: l
|
|
1297
|
+
}) : ut.test(l) ? e.push({
|
|
1069
1298
|
type: "number",
|
|
1070
|
-
value:
|
|
1071
|
-
}) :
|
|
1299
|
+
value: l
|
|
1300
|
+
}) : l === "true" || l === "false" ? e.push({
|
|
1072
1301
|
type: "boolean",
|
|
1073
|
-
value:
|
|
1074
|
-
}) :
|
|
1302
|
+
value: l
|
|
1303
|
+
}) : l === "null" ? e.push({
|
|
1075
1304
|
type: "null",
|
|
1076
|
-
value:
|
|
1305
|
+
value: l
|
|
1077
1306
|
}) : e.push({
|
|
1078
1307
|
type: "punctuation",
|
|
1079
|
-
value:
|
|
1080
|
-
}),
|
|
1308
|
+
value: l
|
|
1309
|
+
}), o = n.index + l.length;
|
|
1081
1310
|
}
|
|
1082
|
-
return
|
|
1311
|
+
return o < t.length && e.push(t.slice(o)), e;
|
|
1083
1312
|
}
|
|
1084
|
-
function
|
|
1085
|
-
const e =
|
|
1086
|
-
open:
|
|
1087
|
-
onClose:
|
|
1088
|
-
title:
|
|
1089
|
-
content:
|
|
1313
|
+
function pt(t) {
|
|
1314
|
+
const e = P(24), {
|
|
1315
|
+
open: o,
|
|
1316
|
+
onClose: n,
|
|
1317
|
+
title: i,
|
|
1318
|
+
content: r
|
|
1090
1319
|
} = t;
|
|
1091
|
-
let
|
|
1092
|
-
e[0] !==
|
|
1093
|
-
`).map(
|
|
1094
|
-
const s =
|
|
1095
|
-
let
|
|
1096
|
-
e[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
1097
|
-
sx:
|
|
1098
|
-
}, e[2] =
|
|
1099
|
-
let
|
|
1100
|
-
e[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
1320
|
+
let u;
|
|
1321
|
+
e[0] !== r ? (u = r.split(`
|
|
1322
|
+
`).map(gt), e[0] = r, e[1] = u) : u = e[1];
|
|
1323
|
+
const s = u;
|
|
1324
|
+
let l;
|
|
1325
|
+
e[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (l = {
|
|
1326
|
+
sx: T.fullViewPaper
|
|
1327
|
+
}, e[2] = l) : l = e[2];
|
|
1328
|
+
let c;
|
|
1329
|
+
e[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (c = {
|
|
1101
1330
|
display: "flex",
|
|
1102
1331
|
alignItems: "center",
|
|
1103
1332
|
gap: 0.5
|
|
1104
|
-
}, e[3] =
|
|
1105
|
-
let
|
|
1106
|
-
e[4] !==
|
|
1333
|
+
}, e[3] = c) : c = e[3];
|
|
1334
|
+
let f;
|
|
1335
|
+
e[4] !== r ? (f = /* @__PURE__ */ a(Ke, { copyText: r, "aria-label": "Copy content" }), e[4] = r, e[5] = f) : f = e[5];
|
|
1107
1336
|
let m;
|
|
1108
|
-
e[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (m = /* @__PURE__ */
|
|
1337
|
+
e[6] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (m = /* @__PURE__ */ a(be, {}), e[6] = m) : m = e[6];
|
|
1338
|
+
let h;
|
|
1339
|
+
e[7] !== n ? (h = /* @__PURE__ */ a(oe, { onClick: n, "aria-label": "close", children: m }), e[7] = n, e[8] = h) : h = e[8];
|
|
1340
|
+
let b;
|
|
1341
|
+
e[9] !== f || e[10] !== h ? (b = /* @__PURE__ */ S(v, { sx: c, children: [
|
|
1342
|
+
f,
|
|
1343
|
+
h
|
|
1344
|
+
] }), e[9] = f, e[10] = h, e[11] = b) : b = e[11];
|
|
1345
|
+
let p;
|
|
1346
|
+
e[12] !== b || e[13] !== i ? (p = /* @__PURE__ */ S(Be, { sx: T.fullViewTitle, children: [
|
|
1347
|
+
i,
|
|
1348
|
+
b
|
|
1349
|
+
] }), e[12] = b, e[13] = i, e[14] = p) : p = e[14];
|
|
1109
1350
|
let g;
|
|
1110
|
-
e[
|
|
1351
|
+
e[15] !== s ? (g = s.map(mt), e[15] = s, e[16] = g) : g = e[16];
|
|
1352
|
+
let d;
|
|
1353
|
+
e[17] !== g ? (d = /* @__PURE__ */ a(De, { sx: T.fullViewDialogContent, children: /* @__PURE__ */ a(v, { component: "pre", sx: T.fullViewPre, children: g }) }), e[17] = g, e[18] = d) : d = e[18];
|
|
1111
1354
|
let x;
|
|
1112
|
-
e[
|
|
1355
|
+
return e[19] !== n || e[20] !== o || e[21] !== d || e[22] !== p ? (x = /* @__PURE__ */ S(Me, { open: o, onClose: n, sx: T.fullViewDialog, PaperProps: l, fullScreen: !0, children: [
|
|
1113
1356
|
p,
|
|
1114
|
-
|
|
1115
|
-
] }), e[
|
|
1116
|
-
let h;
|
|
1117
|
-
e[12] !== x || e[13] !== l ? (h = /* @__PURE__ */ k(Le, { sx: w.fullViewTitle, children: [
|
|
1118
|
-
l,
|
|
1119
|
-
x
|
|
1120
|
-
] }), e[12] = x, e[13] = l, e[14] = h) : h = e[14];
|
|
1121
|
-
let u;
|
|
1122
|
-
e[15] !== s ? (u = s.map(ft), e[15] = s, e[16] = u) : u = e[16];
|
|
1123
|
-
let f;
|
|
1124
|
-
e[17] !== u ? (f = /* @__PURE__ */ c($e, { sx: w.fullViewDialogContent, children: /* @__PURE__ */ c(C, { component: "pre", sx: w.fullViewPre, children: u }) }), e[17] = u, e[18] = f) : f = e[18];
|
|
1125
|
-
let b;
|
|
1126
|
-
return e[19] !== r || e[20] !== n || e[21] !== f || e[22] !== h ? (b = /* @__PURE__ */ k(Re, { open: n, onClose: r, sx: w.fullViewDialog, PaperProps: i, fullScreen: !0, children: [
|
|
1127
|
-
h,
|
|
1128
|
-
f
|
|
1129
|
-
] }), e[19] = r, e[20] = n, e[21] = f, e[22] = h, e[23] = b) : b = e[23], b;
|
|
1357
|
+
d
|
|
1358
|
+
] }), e[19] = n, e[20] = o, e[21] = d, e[22] = p, e[23] = x) : x = e[23], x;
|
|
1130
1359
|
}
|
|
1131
|
-
function
|
|
1132
|
-
return /* @__PURE__ */
|
|
1133
|
-
t.map(
|
|
1360
|
+
function mt(t, e) {
|
|
1361
|
+
return /* @__PURE__ */ S(v, { component: "span", sx: T.fullViewLine, children: [
|
|
1362
|
+
t.map(ht),
|
|
1134
1363
|
`
|
|
1135
1364
|
`
|
|
1136
1365
|
] }, e);
|
|
1137
1366
|
}
|
|
1138
|
-
function
|
|
1139
|
-
return typeof t == "string" ? t : /* @__PURE__ */
|
|
1367
|
+
function ht(t, e) {
|
|
1368
|
+
return typeof t == "string" ? t : /* @__PURE__ */ a(v, { component: "span", sx: T[`syntaxToken_${t.type}`], children: t.value }, e);
|
|
1140
1369
|
}
|
|
1141
|
-
function
|
|
1142
|
-
return
|
|
1370
|
+
function gt(t) {
|
|
1371
|
+
return ft(t);
|
|
1143
1372
|
}
|
|
1144
1373
|
function ue(t) {
|
|
1145
|
-
const e =
|
|
1146
|
-
content:
|
|
1147
|
-
title:
|
|
1148
|
-
isError:
|
|
1149
|
-
labels:
|
|
1150
|
-
sx:
|
|
1151
|
-
} = t, s =
|
|
1152
|
-
let
|
|
1153
|
-
e[0] !==
|
|
1154
|
-
const
|
|
1155
|
-
let
|
|
1156
|
-
e[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
1374
|
+
const e = P(28), {
|
|
1375
|
+
content: o,
|
|
1376
|
+
title: n,
|
|
1377
|
+
isError: i,
|
|
1378
|
+
labels: r,
|
|
1379
|
+
sx: u
|
|
1380
|
+
} = t, s = n === void 0 ? "" : n, l = i === void 0 ? !1 : i;
|
|
1381
|
+
let c;
|
|
1382
|
+
e[0] !== r ? (c = r === void 0 ? {} : r, e[0] = r, e[1] = c) : c = e[1];
|
|
1383
|
+
const f = c, m = ne(null), [h, b] = te(!1), [p, g] = te(!1);
|
|
1384
|
+
let d;
|
|
1385
|
+
e[2] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (d = () => {
|
|
1157
1386
|
const D = m.current;
|
|
1158
|
-
D &&
|
|
1159
|
-
}, e[2] =
|
|
1160
|
-
const
|
|
1161
|
-
let
|
|
1162
|
-
e[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
1163
|
-
|
|
1387
|
+
D && b(D.scrollHeight > D.clientHeight);
|
|
1388
|
+
}, e[2] = d) : d = e[2];
|
|
1389
|
+
const x = d;
|
|
1390
|
+
let y;
|
|
1391
|
+
e[3] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (y = () => {
|
|
1392
|
+
x();
|
|
1164
1393
|
const D = m.current;
|
|
1165
1394
|
if (!D)
|
|
1166
1395
|
return;
|
|
1167
|
-
const
|
|
1168
|
-
return
|
|
1169
|
-
}, e[3] =
|
|
1170
|
-
let
|
|
1171
|
-
e[4] !==
|
|
1172
|
-
const
|
|
1173
|
-
let S;
|
|
1174
|
-
e[6] !== d ? (S = {
|
|
1175
|
-
...w.codeArea,
|
|
1176
|
-
...d
|
|
1177
|
-
}, e[6] = d, e[7] = S) : S = e[7];
|
|
1396
|
+
const j = new ResizeObserver(x);
|
|
1397
|
+
return j.observe(D), () => j.disconnect();
|
|
1398
|
+
}, e[3] = y) : y = e[3];
|
|
1399
|
+
let C;
|
|
1400
|
+
e[4] !== o ? (C = [x, o], e[4] = o, e[5] = C) : C = e[5], re(y, C);
|
|
1401
|
+
const w = f.fullView ?? "Full view";
|
|
1178
1402
|
let _;
|
|
1179
|
-
e[
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
maxHeight: Ke,
|
|
1184
|
-
..._
|
|
1185
|
-
}, e[10] = _, e[11] = E) : E = e[11];
|
|
1403
|
+
e[6] !== u ? (_ = {
|
|
1404
|
+
...T.codeArea,
|
|
1405
|
+
...u
|
|
1406
|
+
}, e[6] = u, e[7] = _) : _ = e[7];
|
|
1186
1407
|
let L;
|
|
1187
|
-
e[
|
|
1408
|
+
e[8] !== l ? (L = l ? T.codeAreaPreError : {}, e[8] = l, e[9] = L) : L = e[9];
|
|
1188
1409
|
let $;
|
|
1189
|
-
e[
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1410
|
+
e[10] !== L ? ($ = {
|
|
1411
|
+
...T.codeAreaPre,
|
|
1412
|
+
maxHeight: Je,
|
|
1413
|
+
...L
|
|
1414
|
+
}, e[10] = L, e[11] = $) : $ = e[11];
|
|
1415
|
+
let A;
|
|
1416
|
+
e[12] !== o || e[13] !== $ ? (A = /* @__PURE__ */ a(v, { component: "pre", ref: m, sx: $, children: o }), e[12] = o, e[13] = $, e[14] = A) : A = e[14];
|
|
1417
|
+
let M;
|
|
1418
|
+
e[15] !== w || e[16] !== h ? (M = h && /* @__PURE__ */ a(ze, { title: w, children: /* @__PURE__ */ a(oe, { size: "small", onClick: () => g(!0), sx: T.codeAreaFullViewButton, children: /* @__PURE__ */ a(Ye, {}) }) }), e[15] = w, e[16] = h, e[17] = M) : M = e[17];
|
|
1194
1419
|
let R;
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1420
|
+
e[18] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (R = () => g(!1), e[18] = R) : R = e[18];
|
|
1421
|
+
let O;
|
|
1422
|
+
e[19] !== o || e[20] !== p || e[21] !== s ? (O = /* @__PURE__ */ a(pt, { open: p, onClose: R, title: s, content: o }), e[19] = o, e[20] = p, e[21] = s, e[22] = O) : O = e[22];
|
|
1423
|
+
let B;
|
|
1424
|
+
return e[23] !== A || e[24] !== M || e[25] !== O || e[26] !== _ ? (B = /* @__PURE__ */ S(v, { sx: _, children: [
|
|
1425
|
+
A,
|
|
1426
|
+
M,
|
|
1427
|
+
O
|
|
1428
|
+
] }), e[23] = A, e[24] = M, e[25] = O, e[26] = _, e[27] = B) : B = e[27], B;
|
|
1200
1429
|
}
|
|
1201
1430
|
function fe(t) {
|
|
1202
1431
|
const e = t.replace(/_/g, " ");
|
|
1203
1432
|
return e.charAt(0).toUpperCase() + e.slice(1);
|
|
1204
1433
|
}
|
|
1205
|
-
function
|
|
1434
|
+
function ve(t) {
|
|
1206
1435
|
return t.status === "running" ? t.runningLabel ?? fe(t.name) : t.label ?? fe(t.name);
|
|
1207
1436
|
}
|
|
1208
|
-
function
|
|
1209
|
-
const e =
|
|
1210
|
-
status:
|
|
1211
|
-
labels:
|
|
1437
|
+
function xt(t) {
|
|
1438
|
+
const e = P(9), {
|
|
1439
|
+
status: o,
|
|
1440
|
+
labels: n
|
|
1212
1441
|
} = t;
|
|
1213
|
-
switch (
|
|
1442
|
+
switch (o) {
|
|
1214
1443
|
case "complete": {
|
|
1215
|
-
let
|
|
1216
|
-
e[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
1444
|
+
let i;
|
|
1445
|
+
e[0] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (i = {
|
|
1217
1446
|
display: "flex",
|
|
1218
1447
|
alignItems: "center",
|
|
1219
1448
|
gap: 0.5
|
|
1220
|
-
}, e[0] =
|
|
1221
|
-
let
|
|
1222
|
-
e[1] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
1449
|
+
}, e[0] = i) : i = e[0];
|
|
1450
|
+
let r;
|
|
1451
|
+
e[1] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (r = /* @__PURE__ */ a(Ge, { sx: {
|
|
1223
1452
|
fontSize: 12
|
|
1224
|
-
}, color: "success" }), e[1] =
|
|
1225
|
-
const
|
|
1453
|
+
}, color: "success" }), e[1] = r) : r = e[1];
|
|
1454
|
+
const u = n?.success ?? "Success";
|
|
1226
1455
|
let s;
|
|
1227
|
-
return e[2] !==
|
|
1228
|
-
|
|
1229
|
-
/* @__PURE__ */
|
|
1230
|
-
] }), e[2] =
|
|
1456
|
+
return e[2] !== u ? (s = /* @__PURE__ */ S(v, { sx: i, children: [
|
|
1457
|
+
r,
|
|
1458
|
+
/* @__PURE__ */ a(z, { variant: "caption", children: u })
|
|
1459
|
+
] }), e[2] = u, e[3] = s) : s = e[3], s;
|
|
1231
1460
|
}
|
|
1232
1461
|
case "error": {
|
|
1233
|
-
let
|
|
1234
|
-
e[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
1462
|
+
let i;
|
|
1463
|
+
e[4] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (i = {
|
|
1235
1464
|
display: "flex",
|
|
1236
1465
|
alignItems: "center",
|
|
1237
1466
|
gap: 0.5
|
|
1238
|
-
}, e[4] =
|
|
1239
|
-
let
|
|
1240
|
-
e[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
1467
|
+
}, e[4] = i) : i = e[4];
|
|
1468
|
+
let r;
|
|
1469
|
+
e[5] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (r = /* @__PURE__ */ a(Ne, { sx: {
|
|
1241
1470
|
fontSize: 12
|
|
1242
|
-
}, color: "error" }), e[5] =
|
|
1243
|
-
const
|
|
1471
|
+
}, color: "error" }), e[5] = r) : r = e[5];
|
|
1472
|
+
const u = n?.error ?? "Error";
|
|
1244
1473
|
let s;
|
|
1245
|
-
return e[6] !==
|
|
1246
|
-
|
|
1247
|
-
/* @__PURE__ */
|
|
1248
|
-
] }), e[6] =
|
|
1474
|
+
return e[6] !== u ? (s = /* @__PURE__ */ S(v, { sx: i, children: [
|
|
1475
|
+
r,
|
|
1476
|
+
/* @__PURE__ */ a(z, { variant: "code3", children: u })
|
|
1477
|
+
] }), e[6] = u, e[7] = s) : s = e[7], s;
|
|
1249
1478
|
}
|
|
1250
1479
|
case "running": {
|
|
1251
|
-
let
|
|
1252
|
-
return e[8] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
1480
|
+
let i;
|
|
1481
|
+
return e[8] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (i = /* @__PURE__ */ a(We, { size: 14 }), e[8] = i) : i = e[8], i;
|
|
1253
1482
|
}
|
|
1254
1483
|
default:
|
|
1255
1484
|
return null;
|
|
1256
1485
|
}
|
|
1257
1486
|
}
|
|
1258
|
-
function
|
|
1259
|
-
const e =
|
|
1260
|
-
tool:
|
|
1261
|
-
labels:
|
|
1487
|
+
function Se(t) {
|
|
1488
|
+
const e = P(33), {
|
|
1489
|
+
tool: o,
|
|
1490
|
+
labels: n
|
|
1262
1491
|
} = t;
|
|
1263
|
-
let
|
|
1264
|
-
e[0] !==
|
|
1265
|
-
const
|
|
1266
|
-
let
|
|
1267
|
-
e[2] !==
|
|
1268
|
-
/* @__PURE__ */
|
|
1269
|
-
/* @__PURE__ */
|
|
1270
|
-
/* @__PURE__ */
|
|
1271
|
-
/* @__PURE__ */
|
|
1492
|
+
let i;
|
|
1493
|
+
e[0] !== n ? (i = n === void 0 ? {} : n, e[0] = n, e[1] = i) : i = e[1];
|
|
1494
|
+
const r = i, u = o.status === "error", s = r.toolExecuted ?? "Tool executed", l = r.reference ?? "Reference:", c = r.duration ?? "Duration:", f = r.status ?? "Status:", m = r.inputArguments ?? "Input arguments:", h = r.output ?? "Output:";
|
|
1495
|
+
let b;
|
|
1496
|
+
e[2] !== l || e[3] !== o.reference ? (b = o.reference && /* @__PURE__ */ S(v, { sx: T.traceField, children: [
|
|
1497
|
+
/* @__PURE__ */ a(z, { variant: "code3", fontWeight: 600, color: "text.secondary", sx: T.traceFieldLabel, children: l }),
|
|
1498
|
+
/* @__PURE__ */ S(v, { sx: T.traceReference, children: [
|
|
1499
|
+
/* @__PURE__ */ a(qe, { color: "success" }),
|
|
1500
|
+
/* @__PURE__ */ a(z, { variant: "code3", fontWeight: 600, children: o.reference })
|
|
1272
1501
|
] })
|
|
1273
|
-
] }), e[2] =
|
|
1274
|
-
let
|
|
1275
|
-
e[5] !==
|
|
1276
|
-
/* @__PURE__ */
|
|
1277
|
-
/* @__PURE__ */
|
|
1278
|
-
|
|
1502
|
+
] }), e[2] = l, e[3] = o.reference, e[4] = b) : b = e[4];
|
|
1503
|
+
let p;
|
|
1504
|
+
e[5] !== c || e[6] !== o.duration ? (p = o.duration != null && /* @__PURE__ */ S(v, { sx: T.traceField, children: [
|
|
1505
|
+
/* @__PURE__ */ a(z, { variant: "code3", fontWeight: 600, color: "text.secondary", sx: T.traceFieldLabel, children: c }),
|
|
1506
|
+
/* @__PURE__ */ S(z, { variant: "code3", children: [
|
|
1507
|
+
o.duration,
|
|
1279
1508
|
"s"
|
|
1280
1509
|
] })
|
|
1281
|
-
] }), e[5] =
|
|
1282
|
-
let
|
|
1283
|
-
e[8] !==
|
|
1284
|
-
let
|
|
1285
|
-
e[10] !==
|
|
1286
|
-
let
|
|
1287
|
-
e[13] !==
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
] }), e[13] =
|
|
1291
|
-
let v;
|
|
1292
|
-
e[16] !== m || e[17] !== d || e[18] !== n.inputArguments || e[19] !== n.output || e[20] !== s ? (v = n.inputArguments && /* @__PURE__ */ k(C, { children: [
|
|
1293
|
-
/* @__PURE__ */ c(A, { variant: "code3", fontWeight: 600, color: "text.secondary", sx: w.traceField, children: m }),
|
|
1294
|
-
/* @__PURE__ */ c(ue, { sx: {
|
|
1295
|
-
mt: 0.5,
|
|
1296
|
-
mb: n.output ? 1.5 : 0
|
|
1297
|
-
}, content: n.inputArguments, title: `${s}: ${m}`, isError: d })
|
|
1298
|
-
] }), e[16] = m, e[17] = d, e[18] = n.inputArguments, e[19] = n.output, e[20] = s, e[21] = v) : v = e[21];
|
|
1510
|
+
] }), e[5] = c, e[6] = o.duration, e[7] = p) : p = e[7];
|
|
1511
|
+
let g;
|
|
1512
|
+
e[8] !== f ? (g = /* @__PURE__ */ a(z, { variant: "code3", fontWeight: 600, color: "text.secondary", sx: T.traceFieldLabel, children: f }), e[8] = f, e[9] = g) : g = e[9];
|
|
1513
|
+
let d;
|
|
1514
|
+
e[10] !== r || e[11] !== o.status ? (d = /* @__PURE__ */ a(xt, { status: o.status, labels: r }), e[10] = r, e[11] = o.status, e[12] = d) : d = e[12];
|
|
1515
|
+
let x;
|
|
1516
|
+
e[13] !== g || e[14] !== d ? (x = /* @__PURE__ */ S(v, { sx: T.traceField, children: [
|
|
1517
|
+
g,
|
|
1518
|
+
d
|
|
1519
|
+
] }), e[13] = g, e[14] = d, e[15] = x) : x = e[15];
|
|
1299
1520
|
let y;
|
|
1300
|
-
e[
|
|
1301
|
-
/* @__PURE__ */
|
|
1302
|
-
/* @__PURE__ */
|
|
1521
|
+
e[16] !== m || e[17] !== u || e[18] !== o.inputArguments || e[19] !== o.output || e[20] !== s ? (y = o.inputArguments && /* @__PURE__ */ S(v, { children: [
|
|
1522
|
+
/* @__PURE__ */ a(z, { variant: "code3", fontWeight: 600, color: "text.secondary", sx: T.traceField, children: m }),
|
|
1523
|
+
/* @__PURE__ */ a(ue, { sx: {
|
|
1524
|
+
mt: 0.5,
|
|
1525
|
+
mb: o.output ? 1.5 : 0
|
|
1526
|
+
}, content: o.inputArguments, title: `${s}: ${m}`, isError: u })
|
|
1527
|
+
] }), e[16] = m, e[17] = u, e[18] = o.inputArguments, e[19] = o.output, e[20] = s, e[21] = y) : y = e[21];
|
|
1528
|
+
let C;
|
|
1529
|
+
e[22] !== u || e[23] !== h || e[24] !== o.output || e[25] !== s ? (C = o.output && /* @__PURE__ */ S(v, { children: [
|
|
1530
|
+
/* @__PURE__ */ a(z, { variant: "code3", fontWeight: 600, color: "text.secondary", sx: T.traceField, children: h }),
|
|
1531
|
+
/* @__PURE__ */ a(ue, { sx: {
|
|
1303
1532
|
mt: 0.5
|
|
1304
|
-
}, content:
|
|
1305
|
-
] }), e[22] =
|
|
1306
|
-
let
|
|
1307
|
-
return e[27] !==
|
|
1308
|
-
x,
|
|
1309
|
-
h,
|
|
1533
|
+
}, content: o.output, title: `${s}: ${h}`, isError: u })
|
|
1534
|
+
] }), e[22] = u, e[23] = h, e[24] = o.output, e[25] = s, e[26] = C) : C = e[26];
|
|
1535
|
+
let w;
|
|
1536
|
+
return e[27] !== b || e[28] !== p || e[29] !== x || e[30] !== y || e[31] !== C ? (w = /* @__PURE__ */ S(v, { children: [
|
|
1310
1537
|
b,
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1538
|
+
p,
|
|
1539
|
+
x,
|
|
1540
|
+
y,
|
|
1541
|
+
C
|
|
1542
|
+
] }), e[27] = b, e[28] = p, e[29] = x, e[30] = y, e[31] = C, e[32] = w) : w = e[32], w;
|
|
1314
1543
|
}
|
|
1315
1544
|
function pe(t) {
|
|
1316
|
-
const e =
|
|
1317
|
-
tool:
|
|
1318
|
-
expanded:
|
|
1319
|
-
onExpandedChange:
|
|
1320
|
-
labels:
|
|
1321
|
-
sx:
|
|
1545
|
+
const e = P(29), {
|
|
1546
|
+
tool: o,
|
|
1547
|
+
expanded: n,
|
|
1548
|
+
onExpandedChange: i,
|
|
1549
|
+
labels: r,
|
|
1550
|
+
sx: u
|
|
1322
1551
|
} = t;
|
|
1323
1552
|
let s;
|
|
1324
|
-
e[0] !==
|
|
1325
|
-
const
|
|
1326
|
-
if (
|
|
1327
|
-
let
|
|
1328
|
-
e[2] !==
|
|
1329
|
-
let
|
|
1330
|
-
return e[4] !==
|
|
1553
|
+
e[0] !== r ? (s = r === void 0 ? {} : r, e[0] = r, e[1] = s) : s = e[1];
|
|
1554
|
+
const l = s, c = o.status === "running", f = l.toolExecuted ?? "Tool executed";
|
|
1555
|
+
if (c) {
|
|
1556
|
+
let C;
|
|
1557
|
+
e[2] !== o ? (C = ve(o), e[2] = o, e[3] = C) : C = e[3];
|
|
1558
|
+
let w;
|
|
1559
|
+
return e[4] !== C ? (w = /* @__PURE__ */ a(it, { children: C }), e[4] = C, e[5] = w) : w = e[5], w;
|
|
1331
1560
|
}
|
|
1332
1561
|
let m;
|
|
1333
|
-
e[6] !==
|
|
1334
|
-
let g;
|
|
1335
|
-
e[9] !== p ? (g = /* @__PURE__ */ c(A, { variant: "caption", fontWeight: 600, color: "text.secondary", children: p }), e[9] = p, e[10] = g) : g = e[10];
|
|
1336
|
-
const x = r ? "rotate(90deg)" : "rotate(0deg)";
|
|
1562
|
+
e[6] !== n || e[7] !== i ? (m = () => i?.(!n), e[6] = n, e[7] = i, e[8] = m) : m = e[8];
|
|
1337
1563
|
let h;
|
|
1338
|
-
e[
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1564
|
+
e[9] !== f ? (h = /* @__PURE__ */ a(z, { variant: "caption", fontWeight: 600, color: "text.secondary", children: f }), e[9] = f, e[10] = h) : h = e[10];
|
|
1565
|
+
const b = n ? "rotate(90deg)" : "rotate(0deg)";
|
|
1566
|
+
let p;
|
|
1567
|
+
e[11] !== b ? (p = /* @__PURE__ */ a(ye, { sx: {
|
|
1568
|
+
...T.traceChevron,
|
|
1569
|
+
transform: b
|
|
1570
|
+
} }), e[11] = b, e[12] = p) : p = e[12];
|
|
1571
|
+
let g;
|
|
1572
|
+
e[13] !== n || e[14] !== m || e[15] !== h || e[16] !== p ? (g = /* @__PURE__ */ S(le, { size: "small", variant: "text", onClick: m, "aria-expanded": n, sx: T.traceHeader, children: [
|
|
1573
|
+
h,
|
|
1574
|
+
p
|
|
1575
|
+
] }), e[13] = n, e[14] = m, e[15] = h, e[16] = p, e[17] = g) : g = e[17];
|
|
1576
|
+
let d;
|
|
1577
|
+
e[18] !== l || e[19] !== o ? (d = /* @__PURE__ */ a(v, { sx: T.traceDetailsWrapper, children: /* @__PURE__ */ a(Se, { tool: o, labels: l }) }), e[18] = l, e[19] = o, e[20] = d) : d = e[20];
|
|
1578
|
+
let x;
|
|
1579
|
+
e[21] !== n || e[22] !== d ? (x = /* @__PURE__ */ a(se, { in: n, unmountOnExit: !0, children: d }), e[21] = n, e[22] = d, e[23] = x) : x = e[23];
|
|
1580
|
+
let y;
|
|
1581
|
+
return e[24] !== u || e[25] !== g || e[26] !== x || e[27] !== o.name ? (y = /* @__PURE__ */ S(v, { width: "100%", sx: u, "data-tool": o.name, className: "PsChat--tool-trace", children: [
|
|
1344
1582
|
g,
|
|
1345
|
-
|
|
1346
|
-
] }), e[
|
|
1347
|
-
let f;
|
|
1348
|
-
e[18] !== i || e[19] !== n ? (f = /* @__PURE__ */ c(C, { sx: w.traceDetailsWrapper, children: /* @__PURE__ */ c(Ce, { tool: n, labels: i }) }), e[18] = i, e[19] = n, e[20] = f) : f = e[20];
|
|
1349
|
-
let b;
|
|
1350
|
-
e[21] !== r || e[22] !== f ? (b = /* @__PURE__ */ c(se, { in: r, unmountOnExit: !0, children: f }), e[21] = r, e[22] = f, e[23] = b) : b = e[23];
|
|
1351
|
-
let v;
|
|
1352
|
-
return e[24] !== d || e[25] !== u || e[26] !== b || e[27] !== n.name ? (v = /* @__PURE__ */ k(C, { width: "100%", sx: d, "data-tool": n.name, className: "PsChat--tool-trace", children: [
|
|
1353
|
-
u,
|
|
1354
|
-
b
|
|
1355
|
-
] }), e[24] = d, e[25] = u, e[26] = b, e[27] = n.name, e[28] = v) : v = e[28], v;
|
|
1583
|
+
x
|
|
1584
|
+
] }), e[24] = u, e[25] = g, e[26] = x, e[27] = o.name, e[28] = y) : y = e[28], y;
|
|
1356
1585
|
}
|
|
1357
1586
|
function me(t, e) {
|
|
1358
|
-
const
|
|
1587
|
+
const o = P(5), [n, i] = te(t);
|
|
1359
1588
|
if (e) {
|
|
1360
|
-
let
|
|
1361
|
-
return
|
|
1589
|
+
let r;
|
|
1590
|
+
return o[0] !== e || o[1] !== t ? (r = [t, e], o[0] = e, o[1] = t, o[2] = r) : r = o[2], r;
|
|
1362
1591
|
} else {
|
|
1363
|
-
let
|
|
1364
|
-
return
|
|
1592
|
+
let r;
|
|
1593
|
+
return o[3] !== n ? (r = [n, i], o[3] = n, o[4] = r) : r = o[4], r;
|
|
1365
1594
|
}
|
|
1366
1595
|
}
|
|
1367
|
-
function
|
|
1368
|
-
const e =
|
|
1369
|
-
tools:
|
|
1370
|
-
expanded:
|
|
1371
|
-
onExpandedChange:
|
|
1372
|
-
expandedTools:
|
|
1373
|
-
onToolExpandedChange:
|
|
1596
|
+
function Pt(t) {
|
|
1597
|
+
const e = P(61), {
|
|
1598
|
+
tools: o,
|
|
1599
|
+
expanded: n,
|
|
1600
|
+
onExpandedChange: i,
|
|
1601
|
+
expandedTools: r,
|
|
1602
|
+
onToolExpandedChange: u,
|
|
1374
1603
|
labels: s,
|
|
1375
|
-
sx:
|
|
1376
|
-
} = t,
|
|
1377
|
-
let
|
|
1378
|
-
e[0] !==
|
|
1379
|
-
const m =
|
|
1380
|
-
let
|
|
1381
|
-
e[2] !== s ? (
|
|
1382
|
-
const
|
|
1383
|
-
let
|
|
1384
|
-
e[4] !==
|
|
1385
|
-
const
|
|
1386
|
-
let
|
|
1387
|
-
if (e[6] !==
|
|
1388
|
-
|
|
1604
|
+
sx: l
|
|
1605
|
+
} = t, c = n === void 0 ? !1 : n;
|
|
1606
|
+
let f;
|
|
1607
|
+
e[0] !== r ? (f = r === void 0 ? {} : r, e[0] = r, e[1] = f) : f = e[1];
|
|
1608
|
+
const m = f;
|
|
1609
|
+
let h;
|
|
1610
|
+
e[2] !== s ? (h = s === void 0 ? {} : s, e[2] = s, e[3] = h) : h = e[3];
|
|
1611
|
+
const b = h, [p, g] = me(c, i), [d, x] = me(m, u);
|
|
1612
|
+
let y;
|
|
1613
|
+
e[4] !== o ? (y = o.filter(Ct), e[4] = o, e[5] = y) : y = e[5];
|
|
1614
|
+
const C = y.length;
|
|
1615
|
+
let w, _;
|
|
1616
|
+
if (e[6] !== p || e[7] !== d || e[8] !== b || e[9] !== C || e[10] !== g || e[11] !== x || e[12] !== l || e[13] !== o) {
|
|
1617
|
+
_ = /* @__PURE__ */ Symbol.for("react.early_return_sentinel");
|
|
1389
1618
|
e: {
|
|
1390
|
-
const
|
|
1391
|
-
if (
|
|
1392
|
-
let
|
|
1393
|
-
e[16] !==
|
|
1619
|
+
const L = o.filter(yt), $ = o.filter(bt), A = b.toolsUsed ?? "tools used", M = b.error ?? "Error";
|
|
1620
|
+
if (o.length === 1) {
|
|
1621
|
+
let k;
|
|
1622
|
+
e[16] !== p || e[17] !== b || e[18] !== g || e[19] !== l || e[20] !== o[0] ? (k = /* @__PURE__ */ a(pe, { tool: o[0], expanded: p, onExpandedChange: g, labels: b, sx: l }), e[16] = p, e[17] = b, e[18] = g, e[19] = l, e[20] = o[0], e[21] = k) : k = e[21], _ = k;
|
|
1394
1623
|
break e;
|
|
1395
1624
|
}
|
|
1396
|
-
let I;
|
|
1397
|
-
e[22] !== h || e[23] !== u ? (I = () => u(!h), e[22] = h, e[23] = u, e[24] = I) : I = e[24];
|
|
1398
|
-
const B = y > 0 ? 0.5 : 0;
|
|
1399
1625
|
let R;
|
|
1400
|
-
e[
|
|
1401
|
-
|
|
1402
|
-
|
|
1403
|
-
|
|
1626
|
+
e[22] !== p || e[23] !== g ? (R = () => g(!p), e[22] = p, e[23] = g, e[24] = R) : R = e[24];
|
|
1627
|
+
const O = C > 0 ? 0.5 : 0;
|
|
1628
|
+
let B;
|
|
1629
|
+
e[25] !== O ? (B = {
|
|
1630
|
+
...T.traceHeader,
|
|
1631
|
+
pr: O
|
|
1632
|
+
}, e[25] = O, e[26] = B) : B = e[26];
|
|
1404
1633
|
let D;
|
|
1405
|
-
e[27] !==
|
|
1406
|
-
|
|
1634
|
+
e[27] !== o.length || e[28] !== A ? (D = /* @__PURE__ */ S(z, { variant: "caption", fontWeight: 600, color: "text.secondary", children: [
|
|
1635
|
+
o.length,
|
|
1407
1636
|
" ",
|
|
1408
|
-
|
|
1409
|
-
] }), e[27] =
|
|
1410
|
-
const
|
|
1411
|
-
let
|
|
1412
|
-
e[30] !==
|
|
1413
|
-
...
|
|
1414
|
-
transform:
|
|
1415
|
-
} }), e[30] =
|
|
1416
|
-
let
|
|
1417
|
-
e[32] !==
|
|
1418
|
-
|
|
1419
|
-
/* @__PURE__ */
|
|
1637
|
+
A
|
|
1638
|
+
] }), e[27] = o.length, e[28] = A, e[29] = D) : D = e[29];
|
|
1639
|
+
const j = p ? "rotate(90deg)" : "rotate(0deg)";
|
|
1640
|
+
let K;
|
|
1641
|
+
e[30] !== j ? (K = /* @__PURE__ */ a(ye, { sx: {
|
|
1642
|
+
...T.traceChevron,
|
|
1643
|
+
transform: j
|
|
1644
|
+
} }), e[30] = j, e[31] = K) : K = e[31];
|
|
1645
|
+
let G;
|
|
1646
|
+
e[32] !== C ? (G = C > 0 && /* @__PURE__ */ S(z, { variant: "code3", sx: T.errorBadge, children: [
|
|
1647
|
+
C,
|
|
1648
|
+
/* @__PURE__ */ a(ge, { sx: {
|
|
1420
1649
|
fontSize: 12
|
|
1421
1650
|
}, color: "error" })
|
|
1422
|
-
] }), e[32] =
|
|
1423
|
-
let
|
|
1424
|
-
e[34] !==
|
|
1651
|
+
] }), e[32] = C, e[33] = G) : G = e[33];
|
|
1652
|
+
let J;
|
|
1653
|
+
e[34] !== p || e[35] !== B || e[36] !== D || e[37] !== K || e[38] !== G || e[39] !== R ? (J = /* @__PURE__ */ S(le, { size: "small", variant: "text", onClick: R, "aria-expanded": p, sx: B, children: [
|
|
1425
1654
|
D,
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
] }), e[34] =
|
|
1429
|
-
const
|
|
1430
|
-
let
|
|
1431
|
-
e[41] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (
|
|
1432
|
-
...
|
|
1655
|
+
K,
|
|
1656
|
+
G
|
|
1657
|
+
] }), e[34] = p, e[35] = B, e[36] = D, e[37] = K, e[38] = G, e[39] = R, e[40] = J) : J = e[40];
|
|
1658
|
+
const Q = se, Z = p, U = !0, Y = v, q = "ul";
|
|
1659
|
+
let V;
|
|
1660
|
+
e[41] === /* @__PURE__ */ Symbol.for("react.memo_cache_sentinel") ? (V = {
|
|
1661
|
+
...T.traceDetailsWrapper,
|
|
1433
1662
|
p: 0,
|
|
1434
1663
|
listStyle: "none"
|
|
1435
|
-
}, e[41] =
|
|
1436
|
-
let
|
|
1437
|
-
e[42] !==
|
|
1438
|
-
const
|
|
1439
|
-
return /* @__PURE__ */
|
|
1440
|
-
/* @__PURE__ */
|
|
1441
|
-
...
|
|
1442
|
-
[
|
|
1443
|
-
}), "aria-expanded":
|
|
1444
|
-
/* @__PURE__ */
|
|
1445
|
-
|
|
1446
|
-
/* @__PURE__ */
|
|
1447
|
-
...
|
|
1448
|
-
transform:
|
|
1664
|
+
}, e[41] = V) : V = e[41];
|
|
1665
|
+
let I;
|
|
1666
|
+
e[42] !== M || e[43] !== d || e[44] !== b || e[45] !== x ? (I = (k) => {
|
|
1667
|
+
const E = d[k.id] ?? !1;
|
|
1668
|
+
return /* @__PURE__ */ S(v, { component: "li", sx: T.groupListItem, "aria-expanded": E, children: [
|
|
1669
|
+
/* @__PURE__ */ S(le, { variant: "text", color: "inherit", fullWidth: !0, onClick: () => x({
|
|
1670
|
+
...d,
|
|
1671
|
+
[k.id]: !E
|
|
1672
|
+
}), "aria-expanded": E, sx: T.groupHeader, children: [
|
|
1673
|
+
/* @__PURE__ */ a(z, { flexGrow: 1, flexShrink: 0, variant: "caption", color: "text.secondary", children: ve(k) }),
|
|
1674
|
+
k.status === "error" && /* @__PURE__ */ a(z, { variant: "code3", color: "error.main", children: M }),
|
|
1675
|
+
/* @__PURE__ */ a(Xe, { sx: {
|
|
1676
|
+
...T.traceChevron,
|
|
1677
|
+
transform: E ? "rotate(90deg)" : "rotate(0deg)"
|
|
1449
1678
|
} })
|
|
1450
1679
|
] }),
|
|
1451
|
-
/* @__PURE__ */
|
|
1452
|
-
] },
|
|
1453
|
-
}, e[42] =
|
|
1454
|
-
const
|
|
1455
|
-
let
|
|
1456
|
-
e[47] !==
|
|
1457
|
-
let
|
|
1458
|
-
e[52] !==
|
|
1459
|
-
let
|
|
1460
|
-
e[57] !==
|
|
1461
|
-
...
|
|
1462
|
-
[
|
|
1463
|
-
}) },
|
|
1464
|
-
|
|
1465
|
-
|
|
1466
|
-
|
|
1680
|
+
/* @__PURE__ */ a(se, { in: E, unmountOnExit: !0, children: /* @__PURE__ */ a(v, { px: 1.5, py: 1, children: /* @__PURE__ */ a(Se, { tool: k, labels: b }) }) })
|
|
1681
|
+
] }, k.id);
|
|
1682
|
+
}, e[42] = M, e[43] = d, e[44] = b, e[45] = x, e[46] = I) : I = e[46];
|
|
1683
|
+
const F = $.map(I);
|
|
1684
|
+
let W;
|
|
1685
|
+
e[47] !== Y || e[48] !== q || e[49] !== V || e[50] !== F ? (W = /* @__PURE__ */ a(Y, { component: q, sx: V, children: F }), e[47] = Y, e[48] = q, e[49] = V, e[50] = F, e[51] = W) : W = e[51];
|
|
1686
|
+
let X;
|
|
1687
|
+
e[52] !== Q || e[53] !== Z || e[54] !== U || e[55] !== W ? (X = /* @__PURE__ */ a(Q, { in: Z, unmountOnExit: U, children: W }), e[52] = Q, e[53] = Z, e[54] = U, e[55] = W, e[56] = X) : X = e[56];
|
|
1688
|
+
let N;
|
|
1689
|
+
e[57] !== d || e[58] !== b || e[59] !== x ? (N = (k) => /* @__PURE__ */ a(pe, { tool: k, labels: b, expanded: d[k.id], onExpandedChange: () => x({
|
|
1690
|
+
...d,
|
|
1691
|
+
[k.id]: !d[k.id]
|
|
1692
|
+
}) }, k.id), e[57] = d, e[58] = b, e[59] = x, e[60] = N) : N = e[60], w = /* @__PURE__ */ S(v, { width: "100%", sx: l, className: "PsChat--tool-group", children: [
|
|
1693
|
+
J,
|
|
1694
|
+
X,
|
|
1695
|
+
L.map(N)
|
|
1467
1696
|
] });
|
|
1468
1697
|
}
|
|
1469
|
-
e[6] =
|
|
1698
|
+
e[6] = p, e[7] = d, e[8] = b, e[9] = C, e[10] = g, e[11] = x, e[12] = l, e[13] = o, e[14] = w, e[15] = _;
|
|
1470
1699
|
} else
|
|
1471
|
-
|
|
1472
|
-
return
|
|
1700
|
+
w = e[14], _ = e[15];
|
|
1701
|
+
return _ !== /* @__PURE__ */ Symbol.for("react.early_return_sentinel") ? _ : w;
|
|
1473
1702
|
}
|
|
1474
|
-
function
|
|
1703
|
+
function bt(t) {
|
|
1475
1704
|
return t.status !== "running";
|
|
1476
1705
|
}
|
|
1477
|
-
function
|
|
1706
|
+
function yt(t) {
|
|
1478
1707
|
return t.status === "running";
|
|
1479
1708
|
}
|
|
1480
|
-
function
|
|
1709
|
+
function Ct(t) {
|
|
1481
1710
|
return t.status === "error";
|
|
1482
1711
|
}
|
|
1483
1712
|
export {
|
|
1484
|
-
|
|
1485
|
-
|
|
1486
|
-
|
|
1487
|
-
|
|
1488
|
-
|
|
1489
|
-
|
|
1490
|
-
|
|
1491
|
-
|
|
1492
|
-
|
|
1493
|
-
|
|
1494
|
-
|
|
1495
|
-
|
|
1496
|
-
|
|
1713
|
+
Et as CHAT_DIVIDER_DELAY,
|
|
1714
|
+
ie as CHAT_MAX_WIDTH,
|
|
1715
|
+
$t as CHAT_SCROLL_DELAY,
|
|
1716
|
+
Je as CHAT_TOOL_CODE_AREA_MAX_HEIGHT,
|
|
1717
|
+
Ot as ChatActionsContainer,
|
|
1718
|
+
Ze as ChatAgentMessage,
|
|
1719
|
+
at as ChatContent,
|
|
1720
|
+
Dt as ChatErrorMessage,
|
|
1721
|
+
Wt as ChatFooter,
|
|
1722
|
+
zt as ChatHeader,
|
|
1723
|
+
Mt as ChatLoader,
|
|
1724
|
+
Ce as ChatMessageOverflow,
|
|
1725
|
+
Ht as ChatRatingAction,
|
|
1497
1726
|
Ft as ChatStarter,
|
|
1498
|
-
|
|
1499
|
-
|
|
1727
|
+
ot as ChatSuggestionButton,
|
|
1728
|
+
it as ChatThinking,
|
|
1500
1729
|
ue as ChatToolCodeArea,
|
|
1501
|
-
|
|
1502
|
-
|
|
1730
|
+
pt as ChatToolFullViewDialog,
|
|
1731
|
+
Pt as ChatToolGroup,
|
|
1503
1732
|
pe as ChatToolTrace,
|
|
1504
|
-
|
|
1505
|
-
|
|
1733
|
+
Bt as ChatUserMessage,
|
|
1734
|
+
Rt as useTypewriter
|
|
1506
1735
|
};
|
|
1507
1736
|
//# sourceMappingURL=chat.js.map
|