@versini/sassysaint 8.62.3 → 8.63.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.DGB_6XWF.js → AboutChangelog.COOGja4L.js} +2 -2
- package/dist/chunks/{AboutEntry.Bi3Rtvax.js → AboutEntry.7ncF_DIc.js} +7 -7
- package/dist/chunks/{App.cuOjKevV.js → App.DoVbmL2p.js} +1584 -1573
- package/dist/chunks/{Chart.D8o0MX15.js → Chart.z1dHEeK6.js} +2 -2
- package/dist/chunks/{ChatBubbleAssistant.BsGW6-uz.js → ChatBubbleAssistant.DVMPxg2S.js} +16 -16
- package/dist/chunks/{ChatBubbleUser.5klvBcRZ.js → ChatBubbleUser.BH4pmGH0.js} +6 -6
- package/dist/chunks/{ChatHistoryTable.Btl5R3g_.js → ChatHistoryTable.DZZj5eGe.js} +15 -15
- package/dist/chunks/{HistoryEntry.Dd9wepcS.js → HistoryEntry.BJMwUkDf.js} +30 -30
- package/dist/chunks/ProfileEntry.OkDRtUl8.js +158 -0
- package/dist/chunks/{SettingsEntry.DJ6HHl3_.js → SettingsEntry.D1ZU-gPR.js} +107 -108
- package/dist/chunks/{Table.B9Dh8yT5.js → Table.BfS9Q50S.js} +22 -22
- package/dist/chunks/{UsageEntry.BBHtbgZr.js → UsageEntry.D0J4ZEpB.js} +3 -3
- package/dist/chunks/{UserMemoriesPanel.B2rrpuxL.js → UserMemoriesPanel.D_wyyDyJ.js} +3 -3
- package/dist/chunks/{index.BwP0kG4H.js → index.790ujKXR.js} +15 -15
- package/dist/chunks/{index.BoS9FOuX.js → index.B__EFtnc.js} +1 -1
- package/dist/chunks/{index.EtY2KRYo.js → index.Bng14czd.js} +3 -3
- package/dist/chunks/{index.CXN6Kb5s.js → index.BnidGtMy.js} +1 -1
- package/dist/chunks/{index.Chm9CISa.js → index.CRxV0D78.js} +2 -2
- package/dist/chunks/{index.C1SMMUJo.js → index.DCbJZ9UB.js} +1032 -970
- package/dist/chunks/{index.BWJ8ML3P.js → index.DrNBEhtX.js} +1 -1
- package/dist/chunks/{index.DJTHwROE.js → index.Ok5GIj4k.js} +12 -12
- package/dist/chunks/{useMarkdown.Bw-tEpSM.js → useMarkdown.CpO2Waej.js} +12 -12
- package/dist/components/SassySaint/SassySaint.js +1 -1
- package/dist/index.js +4 -4
- package/dist/style.css +2 -2
- package/package.json +5 -5
- package/dist/chunks/ProfileEntry.y2zGAvLi.js +0 -60
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { jsxs as u, jsx as r, Fragment as ue } from "react/jsx-runtime";
|
|
2
|
-
import { o as
|
|
3
|
-
import { useCapability as ye, oe as
|
|
4
|
-
import
|
|
2
|
+
import { o as Ee, h as me, i as Ne, x as Te, n as we, useUserPreferences as ve, Se as he, getCacheInfo as Se, isServiceWorkerEnabled as Ce, SETTINGS_TITLE as Ie, S as H, CARDS as C, _e, C as le, PROMPTS_DESCRIPTION as Le, L as Re, j as pe, getCurrentGeoLocation as Ae, mutateCall as fe, handleServiceWorkerToggle as De, SERVICE_TYPES as ge } from "./index.DCbJZ9UB.js";
|
|
3
|
+
import { useCapability as ye, oe as Oe, O as I } from "./App.DoVbmL2p.js";
|
|
4
|
+
import Me, { useState as d, useEffect as ie, useRef as V, useLayoutEffect as J, useCallback as Be } from "react";
|
|
5
5
|
import p from "clsx";
|
|
6
|
-
function
|
|
6
|
+
function Pe({
|
|
7
7
|
value: a,
|
|
8
8
|
defaultValue: n,
|
|
9
9
|
finalValue: o,
|
|
@@ -11,30 +11,30 @@ function Be({
|
|
|
11
11
|
},
|
|
12
12
|
initialControlledDelay: t = 0
|
|
13
13
|
}) {
|
|
14
|
-
const [
|
|
14
|
+
const [l, m] = d(!1), [f, k] = d(
|
|
15
15
|
n !== void 0 ? n : o
|
|
16
16
|
), N = (x) => {
|
|
17
17
|
k(x), s?.(x);
|
|
18
18
|
};
|
|
19
19
|
return ie(() => {
|
|
20
|
-
(async () => a !== void 0 && !
|
|
20
|
+
(async () => a !== void 0 && !l && t > 0 && (await new Promise(
|
|
21
21
|
(x) => setTimeout(x, t)
|
|
22
22
|
), m(!0)))();
|
|
23
|
-
}, [a, t,
|
|
23
|
+
}, [a, t, l]), a !== void 0 ? !l && t > 0 ? ["", s, !0] : [a, s, !0] : [f, N, !1];
|
|
24
24
|
}
|
|
25
|
-
const xe = "av-text-area",
|
|
25
|
+
const xe = "av-text-area", $e = "av-text-area-wrapper", ce = "av-text-area-helper-text", Ge = "av-text-area__control--right", Ue = "av-text-area__control--left", He = () => "rounded-md text-base h-20 min-h-[80px] resize-none overflow-hidden px-4 py-7", Ve = ({ mode: a }) => p({
|
|
26
26
|
"bg-surface-darker text-copy-lighter caret-copy-light": a === "dark",
|
|
27
27
|
"bg-surface-lighter text-copy-dark caret-copy-dark": a === "light",
|
|
28
28
|
"bg-surface-lighter text-copy-dark caret-copy-dark dark:bg-surface-darker dark:text-copy-lighter dark:caret-copy-light": a === "system",
|
|
29
29
|
"bg-surface-darker text-copy-lighter caret-copy-light dark:bg-surface-lighter dark:text-copy-dark dark:caret-copy-dark": a === "alt-system"
|
|
30
|
-
}),
|
|
30
|
+
}), We = ({
|
|
31
31
|
focusMode: a
|
|
32
32
|
}) => p("focus:outline focus:outline-2 focus:outline-offset-2", {
|
|
33
33
|
"focus:outline-focus-dark": a === "dark",
|
|
34
34
|
"focus:outline-focus-light": a === "light",
|
|
35
35
|
"focus:outline-focus-light dark:focus:outline-focus-dark": a === "alt-system",
|
|
36
36
|
"focus:outline-focus-dark dark:focus:outline-focus-light": a === "system"
|
|
37
|
-
}),
|
|
37
|
+
}), ze = ({
|
|
38
38
|
noBorder: a,
|
|
39
39
|
error: n
|
|
40
40
|
}) => p("border-2", {
|
|
@@ -42,13 +42,13 @@ const xe = "av-text-area", Pe = "av-text-area-wrapper", ce = "av-text-area-helpe
|
|
|
42
42
|
"focus:border-border-dark": !a && n,
|
|
43
43
|
"border-border-error-dark": !a && n,
|
|
44
44
|
"border-transparent": a
|
|
45
|
-
}),
|
|
45
|
+
}), Fe = ({
|
|
46
46
|
disabled: a,
|
|
47
47
|
raw: n,
|
|
48
48
|
error: o,
|
|
49
49
|
mode: s,
|
|
50
50
|
leftElement: t,
|
|
51
|
-
rightElement:
|
|
51
|
+
rightElement: l
|
|
52
52
|
}) => {
|
|
53
53
|
if (n)
|
|
54
54
|
return "";
|
|
@@ -56,14 +56,14 @@ const xe = "av-text-area", Pe = "av-text-area-wrapper", ce = "av-text-area-helpe
|
|
|
56
56
|
return p(
|
|
57
57
|
"transform translate-y-0 scale-100 absolute px-2 cursor-not-allowed opacity-50 font-medium",
|
|
58
58
|
{
|
|
59
|
-
"translate-x-[10px]":
|
|
59
|
+
"translate-x-[10px]": l === !0 && !t || !l && !t
|
|
60
60
|
}
|
|
61
61
|
);
|
|
62
62
|
if (!o)
|
|
63
63
|
return p(
|
|
64
64
|
"absolute px-2 cursor-text font-medium transform translate-y-0 scale-100",
|
|
65
65
|
{
|
|
66
|
-
"translate-x-[10px]":
|
|
66
|
+
"translate-x-[10px]": l === !0 && !t || !l && !t,
|
|
67
67
|
"text-copy-medium": s === "dark",
|
|
68
68
|
"text-copy-dark": s === "light",
|
|
69
69
|
"text-copy-dark dark:text-copy-medium": s === "system",
|
|
@@ -74,14 +74,14 @@ const xe = "av-text-area", Pe = "av-text-area-wrapper", ce = "av-text-area-helpe
|
|
|
74
74
|
return p(
|
|
75
75
|
"absolute px-2 cursor-text font-medium transform translate-y-0 scale-100",
|
|
76
76
|
{
|
|
77
|
-
"translate-x-[10px]":
|
|
77
|
+
"translate-x-[10px]": l === !0 && !t || !l && !t,
|
|
78
78
|
"text-copy-medium": s === "dark",
|
|
79
79
|
"text-copy-error-dark": s === "light",
|
|
80
80
|
"text-copy-error-dark dark:text-copy-error-light": s === "system",
|
|
81
81
|
"text-copy-medium dark:text-copy-error-dark": s === "alt-system"
|
|
82
82
|
}
|
|
83
83
|
);
|
|
84
|
-
},
|
|
84
|
+
}, je = ({
|
|
85
85
|
error: a,
|
|
86
86
|
raw: n,
|
|
87
87
|
mode: o,
|
|
@@ -108,13 +108,13 @@ const xe = "av-text-area", Pe = "av-text-area-wrapper", ce = "av-text-area-helpe
|
|
|
108
108
|
"text-copy-error-dark dark:text-copy-error-light": o === "system",
|
|
109
109
|
"dark:text-copy-error-dark text-copy-error-light": o === "alt-system"
|
|
110
110
|
});
|
|
111
|
-
},
|
|
111
|
+
}, Xe = ({
|
|
112
112
|
className: a,
|
|
113
113
|
textAreaClassName: n,
|
|
114
114
|
raw: o,
|
|
115
115
|
focusMode: s,
|
|
116
116
|
disabled: t,
|
|
117
|
-
noBorder:
|
|
117
|
+
noBorder: l,
|
|
118
118
|
error: m,
|
|
119
119
|
mode: f,
|
|
120
120
|
leftElement: k,
|
|
@@ -122,29 +122,29 @@ const xe = "av-text-area", Pe = "av-text-area-wrapper", ce = "av-text-area-helpe
|
|
|
122
122
|
}) => {
|
|
123
123
|
const x = o ? a : p(
|
|
124
124
|
"relative flex w-full flex-col justify-center",
|
|
125
|
-
|
|
125
|
+
$e,
|
|
126
126
|
a
|
|
127
127
|
), _ = o ? p(n) : p(
|
|
128
128
|
xe,
|
|
129
129
|
n,
|
|
130
130
|
He(),
|
|
131
131
|
Ve({ mode: f }),
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
noBorder:
|
|
132
|
+
We({ focusMode: s }),
|
|
133
|
+
ze({
|
|
134
|
+
noBorder: l,
|
|
135
135
|
error: m
|
|
136
136
|
}),
|
|
137
137
|
{
|
|
138
138
|
"disabled:cursor-not-allowed disabled:opacity-50": t
|
|
139
139
|
}
|
|
140
|
-
),
|
|
140
|
+
), B = o ? void 0 : "sr-only", P = Fe({
|
|
141
141
|
disabled: t,
|
|
142
142
|
raw: o,
|
|
143
143
|
error: m,
|
|
144
144
|
mode: f,
|
|
145
145
|
rightElement: N,
|
|
146
146
|
leftElement: k
|
|
147
|
-
}), h =
|
|
147
|
+
}), h = je({
|
|
148
148
|
error: m,
|
|
149
149
|
raw: o,
|
|
150
150
|
mode: f,
|
|
@@ -153,44 +153,44 @@ const xe = "av-text-area", Pe = "av-text-area-wrapper", ce = "av-text-area-helpe
|
|
|
153
153
|
return {
|
|
154
154
|
wrapper: x,
|
|
155
155
|
textArea: _,
|
|
156
|
-
accessibleLabel:
|
|
157
|
-
visibleLabel:
|
|
156
|
+
accessibleLabel: B,
|
|
157
|
+
visibleLabel: P,
|
|
158
158
|
helperText: h,
|
|
159
159
|
rightElement: v,
|
|
160
160
|
leftElement: b
|
|
161
161
|
};
|
|
162
|
-
},
|
|
162
|
+
}, Ye = ({
|
|
163
163
|
scrollHeight: a,
|
|
164
164
|
currentHeight: n,
|
|
165
165
|
currentLabelOffset: o = 0,
|
|
166
166
|
currentHelperTextOffset: s = 0
|
|
167
167
|
}) => {
|
|
168
|
-
let t,
|
|
168
|
+
let t, l;
|
|
169
169
|
if (a > 0 && a !== n) {
|
|
170
170
|
const m = a - n, f = Math.abs(m / 24);
|
|
171
|
-
t = o + -1 * Math.sign(m) * (12 * f),
|
|
171
|
+
t = o + -1 * Math.sign(m) * (12 * f), l = s + Math.sign(m) * (12 * f);
|
|
172
172
|
}
|
|
173
173
|
return {
|
|
174
174
|
labelOffset: t,
|
|
175
|
-
helperTextOffset:
|
|
175
|
+
helperTextOffset: l,
|
|
176
176
|
scrollHeight: a
|
|
177
177
|
};
|
|
178
|
-
}, de =
|
|
178
|
+
}, de = Me.forwardRef(
|
|
179
179
|
({
|
|
180
180
|
id: a,
|
|
181
181
|
name: n,
|
|
182
182
|
label: o,
|
|
183
183
|
error: s = !1,
|
|
184
184
|
raw: t = !1,
|
|
185
|
-
className:
|
|
185
|
+
className: l,
|
|
186
186
|
textAreaClassName: m,
|
|
187
187
|
mode: f = "system",
|
|
188
188
|
focusMode: k = "system",
|
|
189
189
|
value: N,
|
|
190
190
|
defaultValue: x,
|
|
191
191
|
disabled: _ = !1,
|
|
192
|
-
noBorder:
|
|
193
|
-
labelId:
|
|
192
|
+
noBorder: B = !1,
|
|
193
|
+
labelId: P,
|
|
194
194
|
helperText: h = "",
|
|
195
195
|
helperTextOnFocus: v = !1,
|
|
196
196
|
rightElement: b,
|
|
@@ -198,38 +198,38 @@ const xe = "av-text-area", Pe = "av-text-area-wrapper", ce = "av-text-area-helpe
|
|
|
198
198
|
onChange: W,
|
|
199
199
|
onFocus: L,
|
|
200
200
|
onBlur: z,
|
|
201
|
-
|
|
201
|
+
...$
|
|
202
202
|
}, K) => {
|
|
203
|
-
const y =
|
|
203
|
+
const y = V(null), Q = Ee([K, y]), [R, A] = me(), [Z, w] = me(), G = V(80), F = V(-25), D = V(null), j = V(30), ee = V(null), O = Ne({ id: a, prefix: `${xe}-` }), [te, ae] = d(0), [re, oe] = d(0), [se, X] = d(
|
|
204
204
|
!!(!v && h)
|
|
205
|
-
), Y = `${n} error, ${h}`, E =
|
|
206
|
-
className:
|
|
205
|
+
), Y = `${n} error, ${h}`, E = Xe({
|
|
206
|
+
className: l,
|
|
207
207
|
textAreaClassName: m,
|
|
208
208
|
error: s,
|
|
209
209
|
raw: t,
|
|
210
210
|
focusMode: k,
|
|
211
211
|
disabled: _,
|
|
212
|
-
noBorder:
|
|
212
|
+
noBorder: B,
|
|
213
213
|
mode: f,
|
|
214
214
|
rightElement: !!b,
|
|
215
215
|
leftElement: !!T
|
|
216
|
-
}), [e, i] =
|
|
216
|
+
}), [e, i] = Pe({
|
|
217
217
|
value: N,
|
|
218
218
|
initialControlledDelay: 20,
|
|
219
219
|
defaultValue: x,
|
|
220
|
-
onChange: (
|
|
220
|
+
onChange: (c) => {
|
|
221
221
|
W && W({
|
|
222
222
|
target: {
|
|
223
|
-
value:
|
|
223
|
+
value: c
|
|
224
224
|
}
|
|
225
225
|
});
|
|
226
226
|
}
|
|
227
|
-
}),
|
|
228
|
-
i(
|
|
229
|
-
}, q = (
|
|
230
|
-
v && h && X(!0), L && L(
|
|
231
|
-
}, S = (
|
|
232
|
-
v && h && !e && X(!1), z && z(
|
|
227
|
+
}), U = (c) => {
|
|
228
|
+
i(c.target.value);
|
|
229
|
+
}, q = (c) => {
|
|
230
|
+
v && h && X(!0), L && L(c);
|
|
231
|
+
}, S = (c) => {
|
|
232
|
+
v && h && !e && X(!1), z && z(c);
|
|
233
233
|
};
|
|
234
234
|
return J(() => {
|
|
235
235
|
A && A.width && ae(A.width + 18 + 10);
|
|
@@ -246,19 +246,19 @@ const xe = "av-text-area", Pe = "av-text-area-wrapper", ce = "av-text-area-helpe
|
|
|
246
246
|
}, 0);
|
|
247
247
|
}, [e, t]), J(() => {
|
|
248
248
|
if (!t && y && y.current && e !== void 0) {
|
|
249
|
-
const { labelOffset:
|
|
249
|
+
const { labelOffset: c, helperTextOffset: g, scrollHeight: M } = Ye({
|
|
250
250
|
scrollHeight: y.current.scrollHeight,
|
|
251
|
-
currentHeight:
|
|
251
|
+
currentHeight: G.current,
|
|
252
252
|
currentLabelOffset: F.current,
|
|
253
253
|
currentHelperTextOffset: j.current
|
|
254
254
|
});
|
|
255
|
-
|
|
255
|
+
c && (F.current = c, D?.current?.style.setProperty(
|
|
256
256
|
"--av-text-area-label",
|
|
257
|
-
`${
|
|
257
|
+
`${c}px`
|
|
258
258
|
)), g && (j.current = g, ee?.current?.style.setProperty(
|
|
259
259
|
"--av-text-area-helper-text",
|
|
260
260
|
`${g}px`
|
|
261
|
-
)),
|
|
261
|
+
)), G.current = M || G.current;
|
|
262
262
|
}
|
|
263
263
|
}, [e, t]), w.width > 0 && D?.current?.style.setProperty(
|
|
264
264
|
"--tw-translate-x",
|
|
@@ -268,7 +268,7 @@ const xe = "av-text-area", Pe = "av-text-area-wrapper", ce = "av-text-area-helpe
|
|
|
268
268
|
"label",
|
|
269
269
|
{
|
|
270
270
|
htmlFor: O,
|
|
271
|
-
id:
|
|
271
|
+
id: P,
|
|
272
272
|
className: E.accessibleLabel,
|
|
273
273
|
children: o
|
|
274
274
|
}
|
|
@@ -302,10 +302,10 @@ const xe = "av-text-area", Pe = "av-text-area-wrapper", ce = "av-text-area-helpe
|
|
|
302
302
|
}
|
|
303
303
|
},
|
|
304
304
|
value: e,
|
|
305
|
-
onChange:
|
|
305
|
+
onChange: U,
|
|
306
306
|
onFocus: q,
|
|
307
307
|
onBlur: S,
|
|
308
|
-
|
|
308
|
+
...$
|
|
309
309
|
}
|
|
310
310
|
),
|
|
311
311
|
!t && /* @__PURE__ */ r(
|
|
@@ -335,40 +335,40 @@ const xe = "av-text-area", Pe = "av-text-area-wrapper", ce = "av-text-area-helpe
|
|
|
335
335
|
children: b
|
|
336
336
|
}
|
|
337
337
|
),
|
|
338
|
-
s && h && /* @__PURE__ */ r(
|
|
338
|
+
s && h && /* @__PURE__ */ r(Te, { politeness: "polite", clearAnnouncementDelay: 500, children: Y })
|
|
339
339
|
] });
|
|
340
340
|
}
|
|
341
341
|
);
|
|
342
342
|
de.displayName = "TextArea";
|
|
343
343
|
/*!
|
|
344
|
-
@versini/ui-textarea v5.0.
|
|
344
|
+
@versini/ui-textarea v5.0.3
|
|
345
345
|
© 2025 gizmette.com
|
|
346
346
|
*/
|
|
347
347
|
try {
|
|
348
348
|
window.__VERSINI_UI_TEXTAREA__ || (window.__VERSINI_UI_TEXTAREA__ = {
|
|
349
|
-
version: "5.0.
|
|
350
|
-
buildTime: "10/
|
|
349
|
+
version: "5.0.3",
|
|
350
|
+
buildTime: "10/17/2025 12:52 PM EDT",
|
|
351
351
|
homepage: "https://github.com/aversini/ui-components",
|
|
352
352
|
license: "MIT"
|
|
353
353
|
});
|
|
354
354
|
} catch {
|
|
355
355
|
}
|
|
356
|
-
const
|
|
356
|
+
const et = ({
|
|
357
357
|
open: a,
|
|
358
358
|
onOpenChange: n
|
|
359
359
|
}) => {
|
|
360
|
-
const { getAccessToken: o, user: s } =
|
|
360
|
+
const { getAccessToken: o, user: s } = we(), {
|
|
361
361
|
data: t,
|
|
362
|
-
isSuccess:
|
|
362
|
+
isSuccess: l,
|
|
363
363
|
refetch: m
|
|
364
|
-
} =
|
|
364
|
+
} = ve({
|
|
365
365
|
user: s?.username,
|
|
366
366
|
getAccessToken: o
|
|
367
367
|
}), [f, k] = d({
|
|
368
368
|
loadingLocation: !1
|
|
369
369
|
}), [N, x] = d({
|
|
370
370
|
prompts: []
|
|
371
|
-
}), [_,
|
|
371
|
+
}), [_, B] = d(""), [P, h] = d(""), [v, b] = d(!1), [T, W] = d(!1), [L, z] = d(!1), [$, K] = d(!1), [y, Q] = d(!1), [R, A] = d(null), [Z, w] = d(!1), [G, F] = d(!1), D = ye(he.TOOL.MEMORIES), j = ye(he.ADDON.REASONING), ee = (e) => {
|
|
372
372
|
F(e);
|
|
373
373
|
}, O = (e) => {
|
|
374
374
|
b(e);
|
|
@@ -387,15 +387,15 @@ const Ze = ({
|
|
|
387
387
|
params: {
|
|
388
388
|
user: s?.username,
|
|
389
389
|
instructions: _,
|
|
390
|
-
location:
|
|
390
|
+
location: P,
|
|
391
391
|
provider: t?.provider,
|
|
392
392
|
tags: N.prompts,
|
|
393
393
|
sendOnEnter: v,
|
|
394
394
|
useMemory: T,
|
|
395
|
-
showDetails:
|
|
395
|
+
showDetails: G,
|
|
396
396
|
showReasoningButton: y
|
|
397
397
|
}
|
|
398
|
-
}),
|
|
398
|
+
}), $ !== L && (await De($), z($)), m(), k({
|
|
399
399
|
loadingLocation: !1
|
|
400
400
|
});
|
|
401
401
|
} catch {
|
|
@@ -405,7 +405,7 @@ const Ze = ({
|
|
|
405
405
|
loadingLocation: !0
|
|
406
406
|
}), h("...");
|
|
407
407
|
try {
|
|
408
|
-
const e = Date.now(), i = await
|
|
408
|
+
const e = Date.now(), i = await Ae(), U = await fe({
|
|
409
409
|
accessToken: await o(),
|
|
410
410
|
type: ge.GET_LOCATION,
|
|
411
411
|
params: {
|
|
@@ -413,46 +413,45 @@ const Ze = ({
|
|
|
413
413
|
longitude: i.longitude
|
|
414
414
|
}
|
|
415
415
|
}), S = Date.now() - e;
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
} else
|
|
422
|
-
k({
|
|
423
|
-
loadingLocation: !1
|
|
424
|
-
});
|
|
416
|
+
S < 2e3 && await new Promise((ke) => setTimeout(ke, 2e3 - S));
|
|
417
|
+
const { city: c, state: g, country: M, displayName: ne } = U.data, be = c && g && M ? `${c}, ${g}, ${M}` : ne;
|
|
418
|
+
k({
|
|
419
|
+
loadingLocation: !1
|
|
420
|
+
}), h(be);
|
|
425
421
|
} catch {
|
|
422
|
+
k({
|
|
423
|
+
loadingLocation: !1
|
|
424
|
+
});
|
|
426
425
|
}
|
|
427
426
|
}, X = () => {
|
|
428
427
|
m(), n(!1);
|
|
429
428
|
}, Y = ({
|
|
430
429
|
enabled: e = !1,
|
|
431
430
|
privateChat: i = !1,
|
|
432
|
-
clipboardAccess:
|
|
431
|
+
clipboardAccess: U = !1,
|
|
433
432
|
...q
|
|
434
433
|
}) => {
|
|
435
434
|
x((S) => {
|
|
436
|
-
const
|
|
435
|
+
const c = S.prompts, g = {
|
|
437
436
|
...q,
|
|
438
437
|
enabled: e,
|
|
439
438
|
privateChat: i,
|
|
440
|
-
clipboardAccess:
|
|
439
|
+
clipboardAccess: U
|
|
441
440
|
};
|
|
442
|
-
|
|
443
|
-
const
|
|
444
|
-
return
|
|
441
|
+
U ? g.content = g.content.replace(/{{clipboard}}/g, "") + " {{clipboard}}" : g.content = g.content.replace(/{{clipboard}}/g, "");
|
|
442
|
+
const M = c.findIndex((ne) => ne.slot === q.slot);
|
|
443
|
+
return M === -1 ? {
|
|
445
444
|
...S,
|
|
446
|
-
prompts: [...
|
|
447
|
-
} : (
|
|
445
|
+
prompts: [...c, { ...g }]
|
|
446
|
+
} : (c[M] = g, {
|
|
448
447
|
...S,
|
|
449
|
-
prompts: [...
|
|
448
|
+
prompts: [...c]
|
|
450
449
|
});
|
|
451
450
|
});
|
|
452
|
-
}, E =
|
|
451
|
+
}, E = Be(async () => {
|
|
453
452
|
try {
|
|
454
453
|
w(!0);
|
|
455
|
-
const e = await
|
|
454
|
+
const e = await Se();
|
|
456
455
|
A(e);
|
|
457
456
|
} catch {
|
|
458
457
|
} finally {
|
|
@@ -462,21 +461,21 @@ const Ze = ({
|
|
|
462
461
|
return ie(() => {
|
|
463
462
|
if (!t)
|
|
464
463
|
return;
|
|
465
|
-
t.instructions &&
|
|
466
|
-
const e =
|
|
464
|
+
t.instructions && B(t.instructions), t.location && h(t.location), t.tags && x({ prompts: t.tags }), t.sendOnEnter !== void 0 && b(t.sendOnEnter), t.useMemory !== void 0 && W(t.useMemory), t.showDetails !== void 0 && F(t.showDetails), t.showReasoningButton !== void 0 && Q(t.showReasoningButton);
|
|
465
|
+
const e = Ce();
|
|
467
466
|
z(e), K(e);
|
|
468
467
|
}, [t]), ie(() => {
|
|
469
468
|
L ? E() : A(null);
|
|
470
|
-
}, [L, E]),
|
|
471
|
-
|
|
469
|
+
}, [L, E]), l ? /* @__PURE__ */ u(
|
|
470
|
+
Oe,
|
|
472
471
|
{
|
|
473
472
|
open: a,
|
|
474
473
|
onOpenChange: X,
|
|
475
|
-
title:
|
|
474
|
+
title: Ie,
|
|
476
475
|
animation: !0,
|
|
477
476
|
animationType: "fade",
|
|
478
477
|
footer: /* @__PURE__ */ u(
|
|
479
|
-
|
|
478
|
+
Re,
|
|
480
479
|
{
|
|
481
480
|
columnGap: 2,
|
|
482
481
|
alignHorizontal: "flex-end",
|
|
@@ -509,7 +508,7 @@ const Ze = ({
|
|
|
509
508
|
),
|
|
510
509
|
children: [
|
|
511
510
|
/* @__PURE__ */ u(
|
|
512
|
-
|
|
511
|
+
H,
|
|
513
512
|
{
|
|
514
513
|
header: C.SETTINGS_DETAILS.TITLE,
|
|
515
514
|
className: "prose-dark dark:prose-lighter",
|
|
@@ -525,7 +524,7 @@ const Ze = ({
|
|
|
525
524
|
label: "Show Message Statistics",
|
|
526
525
|
name: "show-message-statistics",
|
|
527
526
|
onChange: ee,
|
|
528
|
-
checked:
|
|
527
|
+
checked: G
|
|
529
528
|
}
|
|
530
529
|
),
|
|
531
530
|
/* @__PURE__ */ r("p", { className: "text-sm mt-5", children: C.SETTINGS_DETAILS.SEND_ON_ENTER }),
|
|
@@ -560,7 +559,7 @@ const Ze = ({
|
|
|
560
559
|
}
|
|
561
560
|
),
|
|
562
561
|
/* @__PURE__ */ u(
|
|
563
|
-
|
|
562
|
+
H,
|
|
564
563
|
{
|
|
565
564
|
header: "Custom Instructions",
|
|
566
565
|
className: "prose-dark dark:prose-lighter mt-4",
|
|
@@ -568,7 +567,7 @@ const Ze = ({
|
|
|
568
567
|
children: [
|
|
569
568
|
/* @__PURE__ */ u("p", { className: "text-sm", children: [
|
|
570
569
|
"What would you like ",
|
|
571
|
-
/* @__PURE__ */ r("em", { children:
|
|
570
|
+
/* @__PURE__ */ r("em", { children: _e }),
|
|
572
571
|
" to know about you to provide better responses?"
|
|
573
572
|
] }),
|
|
574
573
|
/* @__PURE__ */ r(
|
|
@@ -582,7 +581,7 @@ const Ze = ({
|
|
|
582
581
|
label: "Custom Instructions",
|
|
583
582
|
value: _,
|
|
584
583
|
onChange: (e) => {
|
|
585
|
-
|
|
584
|
+
B(e.target.value);
|
|
586
585
|
},
|
|
587
586
|
helperText: "Press ENTER to add a new line."
|
|
588
587
|
}
|
|
@@ -591,7 +590,7 @@ const Ze = ({
|
|
|
591
590
|
}
|
|
592
591
|
),
|
|
593
592
|
/* @__PURE__ */ u(
|
|
594
|
-
|
|
593
|
+
H,
|
|
595
594
|
{
|
|
596
595
|
header: "Location",
|
|
597
596
|
className: "prose-dark dark:prose-lighter mt-4",
|
|
@@ -604,7 +603,7 @@ const Ze = ({
|
|
|
604
603
|
mode: "alt-system",
|
|
605
604
|
name: "location",
|
|
606
605
|
label: "Location",
|
|
607
|
-
value:
|
|
606
|
+
value: P,
|
|
608
607
|
onChange: (e) => {
|
|
609
608
|
h(e.target.value);
|
|
610
609
|
},
|
|
@@ -627,15 +626,15 @@ const Ze = ({
|
|
|
627
626
|
}
|
|
628
627
|
),
|
|
629
628
|
/* @__PURE__ */ u(
|
|
630
|
-
|
|
629
|
+
H,
|
|
631
630
|
{
|
|
632
631
|
header: C.SETTINGS_PROMPTS.TITLE,
|
|
633
632
|
className: "prose-dark dark:prose-lighter mt-4",
|
|
634
633
|
noBorder: !0,
|
|
635
634
|
children: [
|
|
636
|
-
/* @__PURE__ */ r("p", { className: "text-sm", children:
|
|
635
|
+
/* @__PURE__ */ r("p", { className: "text-sm", children: Le }),
|
|
637
636
|
N.prompts && N.prompts.slice(0, 3).map((e) => /* @__PURE__ */ u(
|
|
638
|
-
|
|
637
|
+
H,
|
|
639
638
|
{
|
|
640
639
|
mode: "dark",
|
|
641
640
|
noBorder: !0,
|
|
@@ -708,7 +707,7 @@ const Ze = ({
|
|
|
708
707
|
}
|
|
709
708
|
),
|
|
710
709
|
/* @__PURE__ */ u(
|
|
711
|
-
|
|
710
|
+
H,
|
|
712
711
|
{
|
|
713
712
|
header: C.SETTINGS_ADVANCED.TITLE,
|
|
714
713
|
className: "prose-dark dark:prose-lighter mt-4 ",
|
|
@@ -739,7 +738,7 @@ const Ze = ({
|
|
|
739
738
|
label: "Enable Assets Caching",
|
|
740
739
|
name: "enable-service-worker",
|
|
741
740
|
onChange: ae,
|
|
742
|
-
checked:
|
|
741
|
+
checked: $
|
|
743
742
|
}
|
|
744
743
|
),
|
|
745
744
|
L && /* @__PURE__ */ u("div", { className: "mt-4 p-3 border border-dashed border-neutral-700 dark:border-neutral-400 rounded @container/optimizations", children: [
|
|
@@ -773,5 +772,5 @@ const Ze = ({
|
|
|
773
772
|
) : null;
|
|
774
773
|
};
|
|
775
774
|
export {
|
|
776
|
-
|
|
775
|
+
et as SettingsPanel
|
|
777
776
|
};
|