@versini/sassysaint 8.25.1 → 8.26.1
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/chunks/{AboutChangelog.DZ1-iJ5A.js → AboutChangelog.fPm3gI00.js} +2 -2
- package/dist/chunks/{AboutEntry.Okn300Ka.js → AboutEntry.DjhRth-z.js} +8 -8
- package/dist/chunks/{App.BeMVpu5U.js → App.DbygaIrB.js} +10 -10
- package/dist/chunks/{Chart.Bpkp6pxX.js → Chart._Tvo0S4j.js} +2 -2
- package/dist/chunks/{ChatBubbleAssistant.C2qF6aep.js → ChatBubbleAssistant.DYFOu2XG.js} +3 -3
- package/dist/chunks/{HistoryEntry.BMFZA7sy.js → HistoryEntry.CzztrsT8.js} +2 -2
- package/dist/chunks/{I3HPI4QX.CZKfF4QS.js → I3HPI4QX.DOFYXVAs.js} +1 -1
- package/dist/chunks/{ProfileEntry.CvSmmgnk.js → ProfileEntry.CLcppi7c.js} +2 -2
- package/dist/chunks/{SettingsEntry.zQ7rDphM.js → SettingsEntry.BuQugXrn.js} +342 -316
- package/dist/chunks/{UsageEntry.DjUX5B6l.js → UsageEntry.CTkFvezM.js} +3 -3
- package/dist/chunks/{index.C6GUxeYR.js → index.Ba2QYmfS.js} +3 -3
- package/dist/chunks/{index.Cdwqyz44.js → index.BjPCAoKi.js} +2 -2
- package/dist/chunks/{index.CWHaDvJC.js → index.C1ZqtpyV.js} +1 -1
- package/dist/chunks/{index.Dw1w26Sa.js → index.DTtF9vXS.js} +1 -1
- package/dist/chunks/{index.DoY59F_M.js → index.DkYq9tSt.js} +1 -1
- package/dist/chunks/{index.Ryu4fNCl.js → index.lk6de5-T.js} +1130 -1031
- package/dist/chunks/{useMarkdown.DzobZvVM.js → useMarkdown.CBUUpWkp.js} +6 -6
- package/dist/components/SassySaint/SassySaint.js +1 -1
- package/dist/index.js +4 -4
- package/package.json +3 -3
@@ -1,24 +1,24 @@
|
|
1
|
-
import { jsxs as
|
2
|
-
import { n as
|
3
|
-
import { useUserPreferences as
|
4
|
-
import
|
1
|
+
import { jsxs as N, jsx as l } from "react/jsx-runtime";
|
2
|
+
import { n as ve, LOCAL_STORAGE_PREFIX as se, LOCAL_STORAGE_CHAT_DETAILS as _e, LOCAL_STORAGE_SERVICE_WORKER as we, isServiceWorkerEnabled as Ce, isStandaloneMode as Se, SETTINGS_TITLE as Ie, S as U, CARDS as P, APP_NAME as Ae, C as ae, PROMPTS_DESCRIPTION as Re, L as Le, j as ce, getCurrentGeoLocation as Oe, handleServiceWorkerToggle as Me } from "./index.lk6de5-T.js";
|
3
|
+
import { useUserPreferences as De, E as ie, rr as Pe, mutateCall as de, SERVICE_TYPES as ue } from "./App.DbygaIrB.js";
|
4
|
+
import Ge, { useRef as v, useState as y, useLayoutEffect as z, useMemo as pe, useEffect as j, useId as Be, useReducer as He, useCallback as Ve } from "react";
|
5
5
|
import i from "clsx";
|
6
|
-
const
|
7
|
-
function
|
8
|
-
const e =
|
9
|
-
return
|
6
|
+
const he = "av-text-area", Ue = "av-text-area-wrapper", oe = "av-text-area-helper-text", $e = "av-text-area__control--right", Fe = "av-text-area__control--left";
|
7
|
+
function We() {
|
8
|
+
const e = v(!1);
|
9
|
+
return j(() => (e.current = !0, () => {
|
10
10
|
e.current = !1;
|
11
|
-
}), []),
|
11
|
+
}), []), Ve(() => e.current, []);
|
12
12
|
}
|
13
|
-
function
|
14
|
-
return
|
13
|
+
function ze(e) {
|
14
|
+
return pe(() => e.every((r) => r == null) ? () => {
|
15
15
|
} : (r) => {
|
16
16
|
e.forEach((a) => {
|
17
17
|
typeof a == "function" ? a(r) : a != null && (a.current = r);
|
18
18
|
});
|
19
19
|
}, [...e]);
|
20
20
|
}
|
21
|
-
const
|
21
|
+
const je = {
|
22
22
|
x: 0,
|
23
23
|
y: 0,
|
24
24
|
width: 0,
|
@@ -28,18 +28,18 @@ const Ve = {
|
|
28
28
|
bottom: 0,
|
29
29
|
right: 0
|
30
30
|
};
|
31
|
-
function
|
32
|
-
const r =
|
33
|
-
const
|
34
|
-
|
35
|
-
o.current && r() && s(
|
31
|
+
function me(e) {
|
32
|
+
const r = We(), a = v(0), o = v(null), [t, s] = y(je), c = pe(() => typeof ResizeObserver > "u" ? null : new ResizeObserver((d) => {
|
33
|
+
const u = d[0];
|
34
|
+
u && (cancelAnimationFrame(a.current), a.current = requestAnimationFrame(() => {
|
35
|
+
o.current && r() && s(u.contentRect);
|
36
36
|
}));
|
37
37
|
}), [r]);
|
38
|
-
return
|
38
|
+
return j(() => (o.current && c?.observe(o.current, e), () => {
|
39
39
|
c?.disconnect(), a.current && cancelAnimationFrame(a.current);
|
40
40
|
}), [c, e]), [o, t];
|
41
41
|
}
|
42
|
-
function
|
42
|
+
function Xe({
|
43
43
|
value: e,
|
44
44
|
defaultValue: r,
|
45
45
|
finalValue: a,
|
@@ -47,19 +47,19 @@ function Fe({
|
|
47
47
|
},
|
48
48
|
initialControlledDelay: t = 0
|
49
49
|
}) {
|
50
|
-
const [s, c] =
|
50
|
+
const [s, c] = y(!1), [d, u] = y(
|
51
51
|
r !== void 0 ? r : a
|
52
|
-
),
|
53
|
-
|
52
|
+
), m = (p) => {
|
53
|
+
u(p), o?.(p);
|
54
54
|
};
|
55
|
-
return
|
55
|
+
return j(() => {
|
56
56
|
(async () => e !== void 0 && !s && t > 0 && (await new Promise(
|
57
|
-
(
|
57
|
+
(p) => setTimeout(p, t)
|
58
58
|
), c(!0)))();
|
59
|
-
}, [e, t, s]), e !== void 0 ? !s && t > 0 ? ["", o, !0] : [e, o, !0] : [d,
|
59
|
+
}, [e, t, s]), e !== void 0 ? !s && t > 0 ? ["", o, !0] : [e, o, !0] : [d, m, !1];
|
60
60
|
}
|
61
|
-
function
|
62
|
-
const r =
|
61
|
+
function Ye(e) {
|
62
|
+
const r = Be();
|
63
63
|
if (!e)
|
64
64
|
return r;
|
65
65
|
if (typeof e == "number" || typeof e == "string")
|
@@ -69,7 +69,7 @@ function ze(e) {
|
|
69
69
|
return typeof a == "number" || typeof a == "string" ? `${o}${a}` : `${o}${r}`;
|
70
70
|
}
|
71
71
|
}
|
72
|
-
const
|
72
|
+
const ge = "SET_ANNOUNCEMENT", ye = "CLEAR_ANNOUNCEMENT", qe = {
|
73
73
|
alert: null,
|
74
74
|
alertdialog: null,
|
75
75
|
log: "polite",
|
@@ -77,14 +77,14 @@ const me = "SET_ANNOUNCEMENT", fe = "CLEAR_ANNOUNCEMENT", je = {
|
|
77
77
|
progressbar: null,
|
78
78
|
status: "polite",
|
79
79
|
timer: "assertive"
|
80
|
-
},
|
80
|
+
}, Ke = (e, r) => {
|
81
81
|
switch (r?.type) {
|
82
|
-
case
|
82
|
+
case ge:
|
83
83
|
return {
|
84
84
|
...e,
|
85
85
|
announcement: r.payload
|
86
86
|
};
|
87
|
-
case
|
87
|
+
case ye:
|
88
88
|
return {
|
89
89
|
...e,
|
90
90
|
announcement: null
|
@@ -92,14 +92,14 @@ const me = "SET_ANNOUNCEMENT", fe = "CLEAR_ANNOUNCEMENT", je = {
|
|
92
92
|
default:
|
93
93
|
return e;
|
94
94
|
}
|
95
|
-
},
|
95
|
+
}, Qe = ({
|
96
96
|
onAnnouncementClear: e,
|
97
97
|
dispatch: r
|
98
98
|
}) => {
|
99
99
|
r({
|
100
|
-
type:
|
100
|
+
type: ye
|
101
101
|
}), typeof e == "function" && e();
|
102
|
-
},
|
102
|
+
}, fe = ({
|
103
103
|
children: e,
|
104
104
|
clearAnnouncementDelay: r,
|
105
105
|
clearAnnouncementTimeoutRef: a,
|
@@ -107,16 +107,16 @@ const me = "SET_ANNOUNCEMENT", fe = "CLEAR_ANNOUNCEMENT", je = {
|
|
107
107
|
dispatch: t
|
108
108
|
}) => {
|
109
109
|
clearTimeout(a.current), e !== null && t({
|
110
|
-
type:
|
110
|
+
type: ge,
|
111
111
|
payload: e
|
112
112
|
}), r && (a.current = setTimeout(
|
113
|
-
() =>
|
113
|
+
() => Qe({
|
114
114
|
onAnnouncementClear: o,
|
115
115
|
dispatch: t
|
116
116
|
}),
|
117
117
|
r
|
118
118
|
));
|
119
|
-
},
|
119
|
+
}, Je = ({
|
120
120
|
children: e,
|
121
121
|
announcementTimeoutRef: r,
|
122
122
|
announcementDelay: a,
|
@@ -125,13 +125,13 @@ const me = "SET_ANNOUNCEMENT", fe = "CLEAR_ANNOUNCEMENT", je = {
|
|
125
125
|
onAnnouncementClear: s,
|
126
126
|
dispatch: c
|
127
127
|
}) => {
|
128
|
-
clearTimeout(r.current), a ? r.current = setTimeout(
|
128
|
+
clearTimeout(r.current), a ? r.current = setTimeout(fe, a, {
|
129
129
|
children: e,
|
130
130
|
clearAnnouncementDelay: o,
|
131
131
|
clearAnnouncementTimeoutRef: t,
|
132
132
|
onAnnouncementClear: s,
|
133
133
|
dispatch: c
|
134
|
-
}) :
|
134
|
+
}) : fe({
|
135
135
|
children: e,
|
136
136
|
clearAnnouncementDelay: o,
|
137
137
|
clearAnnouncementTimeoutRef: t,
|
@@ -139,7 +139,7 @@ const me = "SET_ANNOUNCEMENT", fe = "CLEAR_ANNOUNCEMENT", je = {
|
|
139
139
|
dispatch: c
|
140
140
|
});
|
141
141
|
};
|
142
|
-
function
|
142
|
+
function Ze({
|
143
143
|
children: e,
|
144
144
|
className: r,
|
145
145
|
politeness: a,
|
@@ -148,21 +148,21 @@ function Ke({
|
|
148
148
|
clearAnnouncementDelay: s,
|
149
149
|
onAnnouncementClear: c,
|
150
150
|
visible: d,
|
151
|
-
...
|
151
|
+
...u
|
152
152
|
}) {
|
153
|
-
const
|
153
|
+
const m = v(null), p = v(null), [k, A] = He(Ke, {
|
154
154
|
announcement: null
|
155
155
|
});
|
156
156
|
let _ = a;
|
157
|
-
typeof _ > "u" && (_ = o ?
|
158
|
-
|
159
|
-
announcementTimeoutRef:
|
157
|
+
typeof _ > "u" && (_ = o ? qe[o] : "assertive"), j(() => {
|
158
|
+
Je({
|
159
|
+
announcementTimeoutRef: m,
|
160
160
|
announcementDelay: t,
|
161
161
|
children: e,
|
162
162
|
clearAnnouncementDelay: s,
|
163
|
-
clearAnnouncementTimeoutRef:
|
163
|
+
clearAnnouncementTimeoutRef: p,
|
164
164
|
onAnnouncementClear: c,
|
165
|
-
dispatch:
|
165
|
+
dispatch: A
|
166
166
|
});
|
167
167
|
}, [
|
168
168
|
e,
|
@@ -170,7 +170,7 @@ function Ke({
|
|
170
170
|
s,
|
171
171
|
c
|
172
172
|
]);
|
173
|
-
const
|
173
|
+
const f = i(r, {
|
174
174
|
"sr-only": !d
|
175
175
|
});
|
176
176
|
return /* @__PURE__ */ l(
|
@@ -178,9 +178,9 @@ function Ke({
|
|
178
178
|
{
|
179
179
|
"aria-live": _,
|
180
180
|
...o && { role: o },
|
181
|
-
className:
|
182
|
-
...
|
183
|
-
children:
|
181
|
+
className: f,
|
182
|
+
...u,
|
183
|
+
children: k.announcement
|
184
184
|
}
|
185
185
|
);
|
186
186
|
}
|
@@ -197,19 +197,19 @@ try {
|
|
197
197
|
});
|
198
198
|
} catch {
|
199
199
|
}
|
200
|
-
const
|
200
|
+
const et = () => "rounded-md text-base h-20 min-h-[80px] resize-none overflow-hidden px-4 py-7", tt = ({ mode: e }) => i({
|
201
201
|
"bg-surface-darker text-copy-lighter caret-copy-light": e === "dark",
|
202
202
|
"bg-surface-lighter text-copy-dark caret-copy-dark": e === "light",
|
203
203
|
"bg-surface-lighter text-copy-dark caret-copy-dark dark:bg-surface-darker dark:text-copy-lighter dark:caret-copy-light": e === "system",
|
204
204
|
"bg-surface-darker text-copy-lighter caret-copy-light dark:bg-surface-lighter dark:text-copy-dark dark:caret-copy-dark": e === "alt-system"
|
205
|
-
}),
|
205
|
+
}), rt = ({
|
206
206
|
focusMode: e
|
207
207
|
}) => i("focus:outline focus:outline-2 focus:outline-offset-2", {
|
208
208
|
"focus:outline-focus-dark": e === "dark",
|
209
209
|
"focus:outline-focus-light": e === "light",
|
210
210
|
"focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
|
211
211
|
"focus:outline-focus-dark dark:focus:outline-focus-light": e === "system"
|
212
|
-
}),
|
212
|
+
}), at = ({
|
213
213
|
noBorder: e,
|
214
214
|
error: r
|
215
215
|
}) => i("border-2", {
|
@@ -217,7 +217,7 @@ const We = () => "rounded-md text-base h-20 min-h-[80px] resize-none overflow-hi
|
|
217
217
|
"focus:border-border-dark": !e && r,
|
218
218
|
"border-border-error-dark": !e && r,
|
219
219
|
"border-transparent": e
|
220
|
-
}),
|
220
|
+
}), ot = ({
|
221
221
|
disabled: e,
|
222
222
|
raw: r,
|
223
223
|
error: a,
|
@@ -256,7 +256,7 @@ const We = () => "rounded-md text-base h-20 min-h-[80px] resize-none overflow-hi
|
|
256
256
|
"text-copy-medium dark:text-copy-error-dark": o === "alt-system"
|
257
257
|
}
|
258
258
|
);
|
259
|
-
},
|
259
|
+
}, nt = ({
|
260
260
|
error: e,
|
261
261
|
raw: r,
|
262
262
|
mode: a,
|
@@ -266,24 +266,24 @@ const We = () => "rounded-md text-base h-20 min-h-[80px] resize-none overflow-hi
|
|
266
266
|
return "";
|
267
267
|
if (o)
|
268
268
|
return i(
|
269
|
-
|
269
|
+
oe,
|
270
270
|
"absolute px-2 cursor-not-allowed opacity-50 font-medium"
|
271
271
|
);
|
272
272
|
if (!e)
|
273
|
-
return i(
|
273
|
+
return i(oe, "absolute px-2 font-medium", {
|
274
274
|
"text-copy-medium": a === "dark",
|
275
275
|
"text-copy-dark": a === "light",
|
276
276
|
"text-copy-dark dark:text-copy-medium": a === "system",
|
277
277
|
"text-copy-medium dark:text-copy-dark": a === "alt-system"
|
278
278
|
});
|
279
279
|
if (e)
|
280
|
-
return i(
|
280
|
+
return i(oe, "absolute px-2 font-medium", {
|
281
281
|
"text-copy-error-light": a === "dark",
|
282
282
|
"text-copy-error-dark": a === "light",
|
283
283
|
"text-copy-error-dark dark:text-copy-error-light": a === "system",
|
284
284
|
"dark:text-copy-error-dark text-copy-error-light": a === "alt-system"
|
285
285
|
});
|
286
|
-
},
|
286
|
+
}, lt = ({
|
287
287
|
className: e,
|
288
288
|
textAreaClassName: r,
|
289
289
|
raw: a,
|
@@ -292,49 +292,49 @@ const We = () => "rounded-md text-base h-20 min-h-[80px] resize-none overflow-hi
|
|
292
292
|
noBorder: s,
|
293
293
|
error: c,
|
294
294
|
mode: d,
|
295
|
-
leftElement:
|
296
|
-
rightElement:
|
295
|
+
leftElement: u,
|
296
|
+
rightElement: m
|
297
297
|
}) => {
|
298
|
-
const
|
298
|
+
const p = a ? e : i(
|
299
299
|
"relative flex w-full flex-col justify-center",
|
300
|
-
|
300
|
+
Ue,
|
301
301
|
e
|
302
|
-
),
|
303
|
-
|
302
|
+
), k = a ? i(r) : i(
|
303
|
+
he,
|
304
304
|
r,
|
305
|
-
|
306
|
-
|
307
|
-
|
308
|
-
|
305
|
+
et(),
|
306
|
+
tt({ mode: d }),
|
307
|
+
rt({ focusMode: o }),
|
308
|
+
at({
|
309
309
|
noBorder: s,
|
310
310
|
error: c
|
311
311
|
}),
|
312
312
|
{
|
313
313
|
"disabled:cursor-not-allowed disabled:opacity-50": t
|
314
314
|
}
|
315
|
-
),
|
315
|
+
), A = a ? void 0 : "sr-only", _ = ot({
|
316
316
|
disabled: t,
|
317
317
|
raw: a,
|
318
318
|
error: c,
|
319
319
|
mode: d,
|
320
|
-
rightElement:
|
321
|
-
leftElement:
|
322
|
-
}),
|
320
|
+
rightElement: m,
|
321
|
+
leftElement: u
|
322
|
+
}), f = nt({
|
323
323
|
error: c,
|
324
324
|
raw: a,
|
325
325
|
mode: d,
|
326
326
|
disabled: t
|
327
|
-
}),
|
327
|
+
}), R = a ? void 0 : i($e, "absolute"), x = a ? void 0 : i(Fe, "absolute");
|
328
328
|
return {
|
329
|
-
wrapper:
|
330
|
-
textArea:
|
331
|
-
accessibleLabel:
|
329
|
+
wrapper: p,
|
330
|
+
textArea: k,
|
331
|
+
accessibleLabel: A,
|
332
332
|
visibleLabel: _,
|
333
|
-
helperText:
|
334
|
-
rightElement:
|
335
|
-
leftElement:
|
333
|
+
helperText: f,
|
334
|
+
rightElement: R,
|
335
|
+
leftElement: x
|
336
336
|
};
|
337
|
-
},
|
337
|
+
}, st = ({
|
338
338
|
scrollHeight: e,
|
339
339
|
currentHeight: r,
|
340
340
|
currentLabelOffset: a = 0,
|
@@ -350,7 +350,7 @@ const We = () => "rounded-md text-base h-20 min-h-[80px] resize-none overflow-hi
|
|
350
350
|
helperTextOffset: s,
|
351
351
|
scrollHeight: e
|
352
352
|
};
|
353
|
-
},
|
353
|
+
}, ne = Ge.forwardRef(
|
354
354
|
({
|
355
355
|
id: e,
|
356
356
|
name: r,
|
@@ -360,164 +360,164 @@ const We = () => "rounded-md text-base h-20 min-h-[80px] resize-none overflow-hi
|
|
360
360
|
className: s,
|
361
361
|
textAreaClassName: c,
|
362
362
|
mode: d = "system",
|
363
|
-
focusMode:
|
364
|
-
value:
|
365
|
-
defaultValue:
|
366
|
-
disabled:
|
367
|
-
noBorder:
|
363
|
+
focusMode: u = "system",
|
364
|
+
value: m,
|
365
|
+
defaultValue: p,
|
366
|
+
disabled: k = !1,
|
367
|
+
noBorder: A = !1,
|
368
368
|
labelId: _,
|
369
|
-
helperText:
|
370
|
-
helperTextOnFocus:
|
371
|
-
rightElement:
|
372
|
-
leftElement:
|
373
|
-
onChange:
|
374
|
-
onFocus:
|
375
|
-
onBlur:
|
376
|
-
...
|
377
|
-
},
|
378
|
-
var
|
379
|
-
const
|
380
|
-
!!(!
|
381
|
-
),
|
369
|
+
helperText: f = "",
|
370
|
+
helperTextOnFocus: R = !1,
|
371
|
+
rightElement: x,
|
372
|
+
leftElement: w,
|
373
|
+
onChange: $,
|
374
|
+
onFocus: X,
|
375
|
+
onBlur: F,
|
376
|
+
...K
|
377
|
+
}, Q) => {
|
378
|
+
var Y;
|
379
|
+
const E = v(null), J = ze([Q, E]), [Z, B] = me(), [ee, L] = me(), H = v(80), V = v(-25), n = v(null), h = v(30), C = v(null), S = Ye({ id: e, prefix: `${he}-` }), [I, T] = y(0), [b, M] = y(0), [W, q] = y(
|
380
|
+
!!(!R && f)
|
381
|
+
), be = `${r} error, ${f}`, D = lt({
|
382
382
|
className: s,
|
383
383
|
textAreaClassName: c,
|
384
384
|
error: o,
|
385
385
|
raw: t,
|
386
|
-
focusMode:
|
387
|
-
disabled:
|
388
|
-
noBorder:
|
386
|
+
focusMode: u,
|
387
|
+
disabled: k,
|
388
|
+
noBorder: A,
|
389
389
|
mode: d,
|
390
|
-
rightElement: !!
|
391
|
-
leftElement: !!
|
392
|
-
}), [
|
393
|
-
value:
|
390
|
+
rightElement: !!x,
|
391
|
+
leftElement: !!w
|
392
|
+
}), [O, ke] = Xe({
|
393
|
+
value: m,
|
394
394
|
initialControlledDelay: 20,
|
395
|
-
defaultValue:
|
396
|
-
onChange: (
|
397
|
-
|
395
|
+
defaultValue: p,
|
396
|
+
onChange: (g) => {
|
397
|
+
$ && $({
|
398
398
|
target: {
|
399
|
-
value:
|
399
|
+
value: g
|
400
400
|
}
|
401
401
|
});
|
402
402
|
}
|
403
|
-
}),
|
404
|
-
|
405
|
-
},
|
406
|
-
|
407
|
-
},
|
408
|
-
|
403
|
+
}), xe = (g) => {
|
404
|
+
ke(g.target.value);
|
405
|
+
}, Ee = (g) => {
|
406
|
+
R && f && q(!0), X && X(g);
|
407
|
+
}, Te = (g) => {
|
408
|
+
R && f && !O && q(!1), F && F(g);
|
409
409
|
};
|
410
|
-
return
|
411
|
-
|
412
|
-
}, [
|
413
|
-
|
414
|
-
}, [
|
415
|
-
t ||
|
416
|
-
}, [
|
410
|
+
return z(() => {
|
411
|
+
B && B.width && T(B.width + 18 + 10);
|
412
|
+
}, [B]), z(() => {
|
413
|
+
L && L.width && M(L.width + 18 + 10);
|
414
|
+
}, [L]), z(() => {
|
415
|
+
t || E && E.current && O !== void 0 && (E.current.style.height = "inherit", E.current.style.height = E.current.scrollHeight + "px");
|
416
|
+
}, [O, t]), z(() => {
|
417
417
|
t || setTimeout(() => {
|
418
|
-
var
|
419
|
-
(
|
418
|
+
var g;
|
419
|
+
(g = n?.current) == null || g.style.setProperty(
|
420
420
|
"--av-text-area-wrapper-transition",
|
421
|
-
|
421
|
+
O ? "none" : "all 0.2s ease-out"
|
422
422
|
);
|
423
423
|
}, 0);
|
424
|
-
}, [
|
425
|
-
var
|
426
|
-
if (!t &&
|
427
|
-
const { labelOffset:
|
428
|
-
scrollHeight:
|
429
|
-
currentHeight:
|
430
|
-
currentLabelOffset:
|
431
|
-
currentHelperTextOffset:
|
424
|
+
}, [O, t]), z(() => {
|
425
|
+
var g, le;
|
426
|
+
if (!t && E && E.current && O !== void 0) {
|
427
|
+
const { labelOffset: te, helperTextOffset: re, scrollHeight: Ne } = st({
|
428
|
+
scrollHeight: E.current.scrollHeight,
|
429
|
+
currentHeight: H.current,
|
430
|
+
currentLabelOffset: V.current,
|
431
|
+
currentHelperTextOffset: h.current
|
432
432
|
});
|
433
|
-
|
433
|
+
te && (V.current = te, (g = n?.current) == null || g.style.setProperty(
|
434
434
|
"--av-text-area-label",
|
435
|
-
`${
|
436
|
-
)),
|
435
|
+
`${te}px`
|
436
|
+
)), re && (h.current = re, (le = C?.current) == null || le.style.setProperty(
|
437
437
|
"--av-text-area-helper-text",
|
438
|
-
`${
|
439
|
-
)),
|
438
|
+
`${re}px`
|
439
|
+
)), H.current = Ne || H.current;
|
440
440
|
}
|
441
|
-
}, [
|
441
|
+
}, [O, t]), L.width > 0 && ((Y = n?.current) == null || Y.style.setProperty(
|
442
442
|
"--tw-translate-x",
|
443
|
-
`${12 +
|
444
|
-
)), /* @__PURE__ */
|
443
|
+
`${12 + L.width + 5}px`
|
444
|
+
)), /* @__PURE__ */ N("div", { className: D.wrapper, children: [
|
445
445
|
/* @__PURE__ */ l(
|
446
446
|
"label",
|
447
447
|
{
|
448
|
-
htmlFor:
|
448
|
+
htmlFor: S,
|
449
449
|
id: _,
|
450
|
-
className:
|
450
|
+
className: D.accessibleLabel,
|
451
451
|
children: a
|
452
452
|
}
|
453
453
|
),
|
454
|
-
|
454
|
+
w && /* @__PURE__ */ l(
|
455
455
|
"div",
|
456
456
|
{
|
457
|
-
ref:
|
458
|
-
className:
|
459
|
-
children:
|
457
|
+
ref: ee,
|
458
|
+
className: D.leftElement,
|
459
|
+
children: w
|
460
460
|
}
|
461
461
|
),
|
462
462
|
/* @__PURE__ */ l(
|
463
463
|
"textarea",
|
464
464
|
{
|
465
|
-
ref:
|
466
|
-
id:
|
465
|
+
ref: J,
|
466
|
+
id: S,
|
467
467
|
name: r,
|
468
|
-
disabled:
|
468
|
+
disabled: k,
|
469
469
|
placeholder: t ? void 0 : " ",
|
470
|
-
className:
|
470
|
+
className: D.textArea,
|
471
471
|
rows: 1,
|
472
|
-
...
|
472
|
+
...f && { "aria-describedby": `${S}-helper` },
|
473
473
|
...o && { "aria-invalid": "true" },
|
474
|
-
...
|
475
|
-
...
|
476
|
-
...
|
474
|
+
...x && !w && !t && { style: { paddingRight: I } },
|
475
|
+
...w && !x && !t && { style: { paddingLeft: b } },
|
476
|
+
...x && w && !t && {
|
477
477
|
style: {
|
478
|
-
paddingRight:
|
479
|
-
paddingLeft:
|
478
|
+
paddingRight: I,
|
479
|
+
paddingLeft: b
|
480
480
|
}
|
481
481
|
},
|
482
|
-
value:
|
483
|
-
onChange:
|
484
|
-
onFocus:
|
485
|
-
onBlur:
|
486
|
-
...
|
482
|
+
value: O,
|
483
|
+
onChange: xe,
|
484
|
+
onFocus: Ee,
|
485
|
+
onBlur: Te,
|
486
|
+
...K
|
487
487
|
}
|
488
488
|
),
|
489
489
|
!t && /* @__PURE__ */ l(
|
490
490
|
"label",
|
491
491
|
{
|
492
|
-
ref:
|
492
|
+
ref: n,
|
493
493
|
"aria-hidden": !0,
|
494
|
-
htmlFor:
|
495
|
-
className: `${
|
494
|
+
htmlFor: S,
|
495
|
+
className: `${D.visibleLabel}`,
|
496
496
|
children: a
|
497
497
|
}
|
498
498
|
),
|
499
|
-
|
499
|
+
W && /* @__PURE__ */ l(
|
500
500
|
"div",
|
501
501
|
{
|
502
|
-
ref:
|
503
|
-
id: `${
|
504
|
-
className:
|
505
|
-
children:
|
502
|
+
ref: C,
|
503
|
+
id: `${S}-helper`,
|
504
|
+
className: D.helperText,
|
505
|
+
children: f
|
506
506
|
}
|
507
507
|
),
|
508
|
-
|
508
|
+
x && /* @__PURE__ */ l(
|
509
509
|
"div",
|
510
510
|
{
|
511
|
-
ref:
|
512
|
-
className:
|
513
|
-
children:
|
511
|
+
ref: Z,
|
512
|
+
className: D.rightElement,
|
513
|
+
children: x
|
514
514
|
}
|
515
515
|
),
|
516
|
-
o &&
|
516
|
+
o && f && /* @__PURE__ */ l(Ze, { politeness: "polite", clearAnnouncementDelay: 500, children: be })
|
517
517
|
] });
|
518
518
|
}
|
519
519
|
);
|
520
|
-
|
520
|
+
ne.displayName = "TextArea";
|
521
521
|
/*!
|
522
522
|
@versini/ui-textarea v4.0.5
|
523
523
|
© 2025 gizmette.com
|
@@ -531,7 +531,7 @@ try {
|
|
531
531
|
});
|
532
532
|
} catch {
|
533
533
|
}
|
534
|
-
const
|
534
|
+
const ct = "av-toggle", it = () => i("peer", "h-6", "w-11", "rounded-full"), dt = ({
|
535
535
|
focusMode: e
|
536
536
|
}) => i(
|
537
537
|
"peer-focus:outline",
|
@@ -543,14 +543,14 @@ const ot = "av-toggle", nt = () => i("peer", "h-6", "w-11", "rounded-full"), lt
|
|
543
543
|
"peer-focus:outline-focus-light dark:peer-focus:outline-focus-dark": e === "alt-system",
|
544
544
|
"peer-focus:outline-focus-dark dark:peer-focus:outline-focus-light": e === "system"
|
545
545
|
}
|
546
|
-
),
|
546
|
+
), ut = () => i(
|
547
547
|
"peer-checked:after:translate-x-full",
|
548
548
|
// background color when checked
|
549
549
|
"peer-checked:bg-violet-500",
|
550
550
|
// knob circle and border color when checked
|
551
551
|
"peer-checked:after:bg-white",
|
552
552
|
"peer-checked:after:border-white"
|
553
|
-
),
|
553
|
+
), mt = () => i(
|
554
554
|
"after:left-[2px]",
|
555
555
|
"after:top-[2px]",
|
556
556
|
"after:border",
|
@@ -562,7 +562,7 @@ const ot = "av-toggle", nt = () => i("peer", "h-6", "w-11", "rounded-full"), lt
|
|
562
562
|
"after:rounded-full",
|
563
563
|
"after:transition-all",
|
564
564
|
"after:content-['']"
|
565
|
-
),
|
565
|
+
), ft = ({
|
566
566
|
mode: e,
|
567
567
|
noBorder: r
|
568
568
|
}) => i({
|
@@ -571,7 +571,7 @@ const ot = "av-toggle", nt = () => i("peer", "h-6", "w-11", "rounded-full"), lt
|
|
571
571
|
"border-border-light bg-surface-darker": e === "dark",
|
572
572
|
"border-border-light bg-surface-darker dark:border-border-dark dark:bg-surface-medium": e === "alt-system",
|
573
573
|
"border-border-dark bg-surface-medium dark:border-border-light dark:bg-surface-darker": e === "system"
|
574
|
-
}),
|
574
|
+
}), pt = ({
|
575
575
|
mode: e,
|
576
576
|
labelHidden: r
|
577
577
|
}) => r ? "sr-only" : i("ml-2 text-sm", {
|
@@ -579,11 +579,11 @@ const ot = "av-toggle", nt = () => i("peer", "h-6", "w-11", "rounded-full"), lt
|
|
579
579
|
"text-copy-lighter": e === "dark",
|
580
580
|
"text-copy-lighter dark:text-copy-dark": e === "alt-system",
|
581
581
|
"text-copy-dark dark:text-copy-lighter": e === "system"
|
582
|
-
}),
|
583
|
-
|
582
|
+
}), ht = ({ className: e }) => i(
|
583
|
+
ct,
|
584
584
|
"relative flex cursor-pointer items-center",
|
585
585
|
e
|
586
|
-
),
|
586
|
+
), gt = ({
|
587
587
|
mode: e,
|
588
588
|
focusMode: r,
|
589
589
|
labelHidden: a,
|
@@ -591,16 +591,16 @@ const ot = "av-toggle", nt = () => i("peer", "h-6", "w-11", "rounded-full"), lt
|
|
591
591
|
noBorder: t
|
592
592
|
}) => ({
|
593
593
|
toggle: i(
|
594
|
-
|
595
|
-
|
596
|
-
|
597
|
-
|
598
|
-
|
594
|
+
it(),
|
595
|
+
ft({ mode: e, noBorder: t }),
|
596
|
+
dt({ focusMode: r }),
|
597
|
+
mt(),
|
598
|
+
ut()
|
599
599
|
),
|
600
|
-
label:
|
600
|
+
label: pt({ mode: e, labelHidden: a }),
|
601
601
|
input: "peer sr-only",
|
602
|
-
wrapper:
|
603
|
-
}),
|
602
|
+
wrapper: ht({ className: o })
|
603
|
+
}), G = ({
|
604
604
|
checked: e = !1,
|
605
605
|
onChange: r,
|
606
606
|
label: a,
|
@@ -609,30 +609,30 @@ const ot = "av-toggle", nt = () => i("peer", "h-6", "w-11", "rounded-full"), lt
|
|
609
609
|
mode: s = "system",
|
610
610
|
focusMode: c = "system",
|
611
611
|
className: d,
|
612
|
-
noBorder:
|
612
|
+
noBorder: u = !1
|
613
613
|
}) => {
|
614
|
-
const
|
614
|
+
const m = gt({
|
615
615
|
mode: s,
|
616
616
|
focusMode: c,
|
617
617
|
labelHidden: o,
|
618
618
|
className: d,
|
619
|
-
noBorder:
|
620
|
-
}),
|
621
|
-
r?.(
|
619
|
+
noBorder: u
|
620
|
+
}), p = (k) => {
|
621
|
+
r?.(k.target.checked);
|
622
622
|
};
|
623
|
-
return /* @__PURE__ */
|
623
|
+
return /* @__PURE__ */ N("label", { className: m.wrapper, children: [
|
624
624
|
/* @__PURE__ */ l(
|
625
625
|
"input",
|
626
626
|
{
|
627
627
|
name: t,
|
628
628
|
checked: e,
|
629
629
|
type: "checkbox",
|
630
|
-
className:
|
631
|
-
onChange:
|
630
|
+
className: m.input,
|
631
|
+
onChange: p
|
632
632
|
}
|
633
633
|
),
|
634
|
-
/* @__PURE__ */ l("div", { className:
|
635
|
-
/* @__PURE__ */ l("span", { className:
|
634
|
+
/* @__PURE__ */ l("div", { className: m.toggle }),
|
635
|
+
/* @__PURE__ */ l("span", { className: m.label, children: a })
|
636
636
|
] });
|
637
637
|
};
|
638
638
|
/*!
|
@@ -648,133 +648,138 @@ try {
|
|
648
648
|
});
|
649
649
|
} catch {
|
650
650
|
}
|
651
|
-
const
|
651
|
+
const Tt = ({
|
652
652
|
open: e,
|
653
653
|
onOpenChange: r
|
654
654
|
}) => {
|
655
|
-
const { getAccessToken: a, user: o } =
|
655
|
+
const { getAccessToken: a, user: o } = ve(), {
|
656
656
|
data: t,
|
657
657
|
isSuccess: s,
|
658
658
|
refetch: c
|
659
|
-
} =
|
659
|
+
} = De({
|
660
660
|
user: o?.username,
|
661
661
|
getAccessToken: a
|
662
|
-
}), [d,
|
662
|
+
}), [d, u] = y({
|
663
663
|
loadingLocation: !1
|
664
|
-
}), [
|
664
|
+
}), [m, p] = y({
|
665
665
|
prompts: []
|
666
|
-
}), [
|
667
|
-
key:
|
666
|
+
}), [k, A] = y(""), [_, f] = y(""), [R, x] = y(!1), [w, $] = y(!1), [X, F] = y(!1), [K, Q] = ie({
|
667
|
+
key: se + _e,
|
668
|
+
initialValue: !1
|
669
|
+
}), [, Y] = ie({
|
670
|
+
key: se + we,
|
668
671
|
initialValue: !1
|
669
|
-
}),
|
670
|
-
|
671
|
-
},
|
672
|
-
|
673
|
-
},
|
674
|
-
|
675
|
-
},
|
672
|
+
}), E = (n) => {
|
673
|
+
Q(n);
|
674
|
+
}, J = (n) => {
|
675
|
+
x(n);
|
676
|
+
}, Z = (n) => {
|
677
|
+
$(n);
|
678
|
+
}, B = async (n) => {
|
679
|
+
Y(n), F(n), await Me(n);
|
680
|
+
}, ee = async (n) => {
|
676
681
|
n.preventDefault();
|
677
682
|
try {
|
678
|
-
await
|
683
|
+
await de({
|
679
684
|
accessToken: await a(),
|
680
|
-
type:
|
685
|
+
type: ue.SET_USER_PREFERENCES,
|
681
686
|
params: {
|
682
687
|
user: o?.username,
|
683
|
-
instructions:
|
688
|
+
instructions: k,
|
684
689
|
location: _,
|
685
690
|
provider: t?.provider,
|
686
|
-
tags:
|
687
|
-
sendOnEnter:
|
688
|
-
useMemory:
|
691
|
+
tags: m.prompts,
|
692
|
+
sendOnEnter: R,
|
693
|
+
useMemory: w
|
689
694
|
}
|
690
|
-
}), c(),
|
695
|
+
}), c(), u({
|
691
696
|
loadingLocation: !1
|
692
697
|
});
|
693
698
|
} catch {
|
694
699
|
}
|
695
|
-
},
|
696
|
-
|
700
|
+
}, L = async () => {
|
701
|
+
u({
|
697
702
|
loadingLocation: !0
|
698
|
-
}),
|
703
|
+
}), f("...");
|
699
704
|
try {
|
700
|
-
const n = Date.now(),
|
705
|
+
const n = Date.now(), h = await Oe(), C = await de({
|
701
706
|
accessToken: await a(),
|
702
|
-
type:
|
707
|
+
type: ue.GET_LOCATION,
|
703
708
|
params: {
|
704
|
-
latitude:
|
705
|
-
longitude:
|
709
|
+
latitude: h.latitude,
|
710
|
+
longitude: h.longitude
|
706
711
|
}
|
707
|
-
}),
|
708
|
-
if (
|
709
|
-
const { city:
|
710
|
-
|
712
|
+
}), I = Date.now() - n;
|
713
|
+
if (I < 2e3 && await new Promise((T) => setTimeout(T, 2e3 - I)), C.status === 200) {
|
714
|
+
const { city: T, state: b, country: M, displayName: W } = C.data, q = T && b && M ? `${T}, ${b}, ${M}` : W;
|
715
|
+
u({
|
711
716
|
loadingLocation: !1
|
712
|
-
}),
|
717
|
+
}), f(q);
|
713
718
|
} else
|
714
|
-
|
719
|
+
u({
|
715
720
|
loadingLocation: !1
|
716
721
|
});
|
717
722
|
} catch {
|
718
723
|
}
|
719
|
-
},
|
724
|
+
}, H = () => {
|
720
725
|
c(), r(!1);
|
721
|
-
},
|
726
|
+
}, V = ({
|
722
727
|
enabled: n = !1,
|
723
|
-
privateChat:
|
724
|
-
clipboardAccess:
|
725
|
-
...
|
728
|
+
privateChat: h = !1,
|
729
|
+
clipboardAccess: C = !1,
|
730
|
+
...S
|
726
731
|
}) => {
|
727
|
-
|
728
|
-
const
|
729
|
-
...
|
732
|
+
p((I) => {
|
733
|
+
const T = I.prompts, b = {
|
734
|
+
...S,
|
730
735
|
enabled: n,
|
731
|
-
privateChat:
|
732
|
-
clipboardAccess:
|
736
|
+
privateChat: h,
|
737
|
+
clipboardAccess: C
|
733
738
|
};
|
734
|
-
|
735
|
-
const
|
736
|
-
return
|
737
|
-
...
|
738
|
-
prompts: [...
|
739
|
-
} : (
|
740
|
-
...
|
741
|
-
prompts: [...
|
739
|
+
C ? b.content = b.content.replace(/{{clipboard}}/g, "") + " {{clipboard}}" : b.content = b.content.replace(/{{clipboard}}/g, "");
|
740
|
+
const M = T.findIndex((W) => W.slot === S.slot);
|
741
|
+
return M === -1 ? {
|
742
|
+
...I,
|
743
|
+
prompts: [...T, { ...b }]
|
744
|
+
} : (T[M] = b, {
|
745
|
+
...I,
|
746
|
+
prompts: [...T]
|
742
747
|
});
|
743
748
|
});
|
744
749
|
};
|
745
|
-
return
|
746
|
-
t?.instructions &&
|
747
|
-
}, [t]), s ? /* @__PURE__ */
|
748
|
-
|
750
|
+
return j(() => {
|
751
|
+
t?.instructions && A(t.instructions), t?.location && f(t.location), t?.tags && p({ prompts: t.tags }), t?.sendOnEnter !== void 0 && x(t.sendOnEnter), t?.useMemory !== void 0 && $(t.useMemory), F(Ce());
|
752
|
+
}, [t]), s ? /* @__PURE__ */ N(
|
753
|
+
Pe,
|
749
754
|
{
|
750
755
|
open: e,
|
751
|
-
onOpenChange:
|
752
|
-
title:
|
753
|
-
footer: /* @__PURE__ */
|
754
|
-
|
756
|
+
onOpenChange: H,
|
757
|
+
title: Ie,
|
758
|
+
footer: /* @__PURE__ */ N(
|
759
|
+
Le,
|
755
760
|
{
|
756
761
|
columnGap: 2,
|
757
762
|
alignHorizontal: "flex-end",
|
758
763
|
className: "pb-8 sm:pb-0",
|
759
764
|
children: [
|
760
|
-
/* @__PURE__ */ l(
|
761
|
-
|
765
|
+
/* @__PURE__ */ l(ce, { children: /* @__PURE__ */ l(
|
766
|
+
ae,
|
762
767
|
{
|
763
768
|
mode: "dark",
|
764
769
|
variant: "secondary",
|
765
770
|
focusMode: "light",
|
766
|
-
onClick:
|
771
|
+
onClick: H,
|
767
772
|
children: "Cancel"
|
768
773
|
}
|
769
774
|
) }),
|
770
|
-
/* @__PURE__ */ l(
|
771
|
-
|
775
|
+
/* @__PURE__ */ l(ce, { children: /* @__PURE__ */ l(
|
776
|
+
ae,
|
772
777
|
{
|
773
778
|
mode: "dark",
|
774
779
|
variant: "danger",
|
775
780
|
focusMode: "light",
|
776
781
|
onClick: async (n) => {
|
777
|
-
r(!1), await
|
782
|
+
r(!1), await ee(n);
|
778
783
|
},
|
779
784
|
children: "Save"
|
780
785
|
}
|
@@ -783,64 +788,64 @@ const bt = ({
|
|
783
788
|
}
|
784
789
|
),
|
785
790
|
children: [
|
786
|
-
/* @__PURE__ */
|
787
|
-
|
791
|
+
/* @__PURE__ */ N(
|
792
|
+
U,
|
788
793
|
{
|
789
|
-
header:
|
794
|
+
header: P.SETTINGS_DETAILS.TITLE,
|
790
795
|
className: "prose-dark dark:prose-lighter",
|
791
796
|
children: [
|
792
|
-
/* @__PURE__ */ l("p", { className: "text-sm", children:
|
797
|
+
/* @__PURE__ */ l("p", { className: "text-sm", children: P.SETTINGS_DETAILS.DETAILS }),
|
793
798
|
/* @__PURE__ */ l(
|
794
|
-
|
799
|
+
G,
|
795
800
|
{
|
796
801
|
className: "mt-2",
|
797
802
|
noBorder: !0,
|
798
803
|
label: "Show Message Statistics",
|
799
804
|
name: "show-message-statistics",
|
800
|
-
onChange:
|
801
|
-
checked:
|
805
|
+
onChange: E,
|
806
|
+
checked: K
|
802
807
|
}
|
803
808
|
),
|
804
|
-
/* @__PURE__ */ l("p", { className: "text-sm mt-5", children:
|
809
|
+
/* @__PURE__ */ l("p", { className: "text-sm mt-5", children: P.SETTINGS_DETAILS.SEND_ON_ENTER }),
|
805
810
|
/* @__PURE__ */ l(
|
806
|
-
|
811
|
+
G,
|
807
812
|
{
|
808
813
|
className: "mt-2",
|
809
814
|
noBorder: !0,
|
810
815
|
label: "Send Message on Enter",
|
811
816
|
name: "send-message-on-enter",
|
812
|
-
onChange:
|
813
|
-
checked:
|
817
|
+
onChange: J,
|
818
|
+
checked: R
|
814
819
|
}
|
815
820
|
),
|
816
|
-
/* @__PURE__ */ l("p", { className: "text-sm mt-5", children:
|
821
|
+
/* @__PURE__ */ l("p", { className: "text-sm mt-5", children: P.SETTINGS_DETAILS.USE_MEMORY }),
|
817
822
|
/* @__PURE__ */ l(
|
818
|
-
|
823
|
+
G,
|
819
824
|
{
|
820
825
|
className: "mt-2",
|
821
826
|
noBorder: !0,
|
822
827
|
label: "Use Memory",
|
823
828
|
name: "use-memory",
|
824
|
-
onChange:
|
825
|
-
checked:
|
829
|
+
onChange: Z,
|
830
|
+
checked: w
|
826
831
|
}
|
827
832
|
)
|
828
833
|
]
|
829
834
|
}
|
830
835
|
),
|
831
|
-
/* @__PURE__ */
|
832
|
-
|
836
|
+
/* @__PURE__ */ N(
|
837
|
+
U,
|
833
838
|
{
|
834
839
|
header: "Custom Instructions",
|
835
840
|
className: "prose-dark dark:prose-lighter mt-4",
|
836
841
|
children: [
|
837
|
-
/* @__PURE__ */
|
842
|
+
/* @__PURE__ */ N("p", { className: "text-sm", children: [
|
838
843
|
"What would you like ",
|
839
|
-
/* @__PURE__ */ l("em", { children:
|
844
|
+
/* @__PURE__ */ l("em", { children: Ae }),
|
840
845
|
" to know about you to provide better responses?"
|
841
846
|
] }),
|
842
847
|
/* @__PURE__ */ l(
|
843
|
-
|
848
|
+
ne,
|
844
849
|
{
|
845
850
|
mode: "alt-system",
|
846
851
|
autoCapitalize: "off",
|
@@ -848,9 +853,9 @@ const bt = ({
|
|
848
853
|
autoCorrect: "off",
|
849
854
|
name: "customInstructions",
|
850
855
|
label: "Custom Instructions",
|
851
|
-
value:
|
856
|
+
value: k,
|
852
857
|
onChange: (n) => {
|
853
|
-
|
858
|
+
A(n.target.value);
|
854
859
|
},
|
855
860
|
helperText: "Press ENTER to add a new line."
|
856
861
|
}
|
@@ -858,42 +863,63 @@ const bt = ({
|
|
858
863
|
]
|
859
864
|
}
|
860
865
|
),
|
861
|
-
/* @__PURE__ */
|
866
|
+
/* @__PURE__ */ N(U, { header: "Location", className: "prose-dark dark:prose-lighter mt-4", children: [
|
862
867
|
/* @__PURE__ */ l("p", { className: "text-sm", children: "You can share your location to receive customized responses based on your area." }),
|
863
868
|
/* @__PURE__ */ l(
|
864
|
-
|
869
|
+
ne,
|
865
870
|
{
|
866
871
|
mode: "alt-system",
|
867
872
|
name: "location",
|
868
873
|
label: "Location",
|
869
874
|
value: _,
|
870
875
|
onChange: (n) => {
|
871
|
-
|
876
|
+
f(n.target.value);
|
872
877
|
},
|
873
878
|
helperText: "Enter your location or press auto-detect."
|
874
879
|
}
|
875
880
|
),
|
876
881
|
/* @__PURE__ */ l(
|
877
|
-
|
882
|
+
ae,
|
878
883
|
{
|
879
884
|
className: "mt-2",
|
880
885
|
size: "small",
|
881
886
|
noBorder: !0,
|
882
887
|
disabled: d.loadingLocation,
|
883
|
-
onClick:
|
888
|
+
onClick: L,
|
884
889
|
children: d.loadingLocation ? "Detecting..." : "Auto-detect"
|
885
890
|
}
|
886
891
|
)
|
887
892
|
] }),
|
888
|
-
/* @__PURE__ */
|
889
|
-
|
893
|
+
Se() && /* @__PURE__ */ N(
|
894
|
+
U,
|
890
895
|
{
|
891
|
-
header:
|
896
|
+
header: P.SETTINGS_CACHING.TITLE,
|
892
897
|
className: "prose-dark dark:prose-lighter mt-4",
|
893
898
|
children: [
|
894
|
-
/* @__PURE__ */ l("p", { className: "text-sm", children:
|
895
|
-
|
899
|
+
/* @__PURE__ */ l("p", { className: "text-sm", children: P.SETTINGS_CACHING.DESCRIPTION }),
|
900
|
+
/* @__PURE__ */ l(
|
896
901
|
G,
|
902
|
+
{
|
903
|
+
className: "mt-2",
|
904
|
+
noBorder: !0,
|
905
|
+
label: "Enable App Caching",
|
906
|
+
name: "enable-service-worker",
|
907
|
+
onChange: B,
|
908
|
+
checked: X
|
909
|
+
}
|
910
|
+
)
|
911
|
+
]
|
912
|
+
}
|
913
|
+
),
|
914
|
+
/* @__PURE__ */ N(
|
915
|
+
U,
|
916
|
+
{
|
917
|
+
header: P.SETTINGS_PROMPTS.TITLE,
|
918
|
+
className: "prose-dark dark:prose-lighter mt-4",
|
919
|
+
children: [
|
920
|
+
/* @__PURE__ */ l("p", { className: "text-sm", children: Re }),
|
921
|
+
m.prompts && m.prompts.slice(0, 3).map((n) => /* @__PURE__ */ N(
|
922
|
+
U,
|
897
923
|
{
|
898
924
|
mode: "dark",
|
899
925
|
noBorder: !0,
|
@@ -902,51 +928,51 @@ const bt = ({
|
|
902
928
|
children: [
|
903
929
|
/* @__PURE__ */ l("p", { className: "text-sm", children: n.description }),
|
904
930
|
/* @__PURE__ */ l(
|
905
|
-
|
931
|
+
G,
|
906
932
|
{
|
907
933
|
mode: "dark",
|
908
934
|
className: "mt-2",
|
909
935
|
noBorder: !0,
|
910
936
|
label: "Enabled",
|
911
937
|
name: n.slot.toString(),
|
912
|
-
onChange: (
|
913
|
-
|
938
|
+
onChange: (h) => {
|
939
|
+
V({
|
914
940
|
...n,
|
915
|
-
enabled:
|
941
|
+
enabled: h
|
916
942
|
});
|
917
943
|
},
|
918
944
|
checked: n.enabled
|
919
945
|
}
|
920
946
|
),
|
921
947
|
/* @__PURE__ */ l(
|
922
|
-
|
948
|
+
G,
|
923
949
|
{
|
924
950
|
mode: "dark",
|
925
951
|
className: "mt-2",
|
926
952
|
noBorder: !0,
|
927
953
|
label: "Private Chat",
|
928
954
|
name: `private-${n.slot.toString()}`,
|
929
|
-
onChange: (
|
930
|
-
|
955
|
+
onChange: (h) => {
|
956
|
+
V({
|
931
957
|
...n,
|
932
|
-
privateChat:
|
958
|
+
privateChat: h
|
933
959
|
});
|
934
960
|
},
|
935
961
|
checked: n.privateChat
|
936
962
|
}
|
937
963
|
),
|
938
964
|
/* @__PURE__ */ l(
|
939
|
-
|
965
|
+
G,
|
940
966
|
{
|
941
967
|
mode: "dark",
|
942
968
|
className: "mt-2",
|
943
969
|
noBorder: !0,
|
944
970
|
label: "Use Clipboard",
|
945
971
|
name: `clipboard-${n.slot.toString()}`,
|
946
|
-
onChange: (
|
947
|
-
|
972
|
+
onChange: (h) => {
|
973
|
+
V({
|
948
974
|
...n,
|
949
|
-
clipboardAccess:
|
975
|
+
clipboardAccess: h
|
950
976
|
});
|
951
977
|
},
|
952
978
|
checked: n.clipboardAccess
|
@@ -964,5 +990,5 @@ const bt = ({
|
|
964
990
|
) : null;
|
965
991
|
};
|
966
992
|
export {
|
967
|
-
|
993
|
+
Tt as SettingsPanel
|
968
994
|
};
|