@versini/sassysaint 8.59.3 → 8.60.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/chunks/{AboutChangelog.Dox-NMAe.js → AboutChangelog.D7rARJQu.js} +2 -2
- package/dist/chunks/{AboutEntry.CVFfQ1yk.js → AboutEntry.2nf0TV4n.js} +5 -5
- package/dist/chunks/{App.BI1AgnoF.js → App.Ch8FU2zW.js} +17 -17
- package/dist/chunks/{Chart.DHXouvK2.js → Chart.Iz1BoL-_.js} +2 -2
- package/dist/chunks/{ChatBubbleAssistant.DDzr5AUP.js → ChatBubbleAssistant.M4WRDuaw.js} +4 -4
- package/dist/chunks/{ChatBubbleUser.Dg11mYO3.js → ChatBubbleUser.CJHFRmMF.js} +3 -3
- package/dist/chunks/{ChatHistoryTable.82jyjrx0.js → ChatHistoryTable.B2mRc_wV.js} +9 -9
- package/dist/chunks/{HistoryEntry.muPSI9qn.js → HistoryEntry.71E6Pz_O.js} +3 -3
- package/dist/chunks/{ProfileEntry.Bov4_Y_K.js → ProfileEntry.BWsYCeof.js} +2 -2
- package/dist/chunks/SettingsEntry.Qi5gQD0-.js +781 -0
- package/dist/chunks/{Table.BkWkQP0Y.js → Table.SHD8KKEE.js} +2 -2
- package/dist/chunks/{UsageEntry.CRs1WXat.js → UsageEntry.DPhNHm9B.js} +3 -3
- package/dist/chunks/UserMemoriesPanel.CT_7TJ_Z.js +208 -0
- package/dist/chunks/{index.BGpoRXQk.js → index.BBAApLM_.js} +1 -1
- package/dist/chunks/{index.CZQODsrP.js → index.BJqzFaBo.js} +2 -2
- package/dist/chunks/{index.eMp9_gI5.js → index.CEgF3L_6.js} +3 -3
- package/dist/chunks/{index.DCZKUmgB.js → index.CqKtw4TJ.js} +1 -1
- package/dist/chunks/{index.DDJOJ-SM.js → index.DG2NgWZ6.js} +1 -1
- package/dist/chunks/{index.D97kQsNo.js → index.DnHjiSVh.js} +604 -637
- package/dist/chunks/{index.dN-7mPvm.js → index.HkxzuofI.js} +1 -1
- package/dist/chunks/{useMarkdown.wJ9LWx_X.js → useMarkdown.BBFa2GkT.js} +6 -6
- package/dist/components/SassySaint/SassySaint.js +1 -1
- package/dist/index.js +4 -4
- package/package.json +3 -3
- package/dist/chunks/SettingsEntry.BnCkBWa0.js +0 -430
- package/dist/chunks/UserMemoriesPanel.CoNs_q02.js +0 -693
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsxs as _, jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { I as f, b as v } from "./index.
|
|
2
|
+
import { I as f, b as v } from "./index.DnHjiSVh.js";
|
|
3
3
|
import C, { useContext as b } from "react";
|
|
4
4
|
import o from "clsx";
|
|
5
|
-
import { e as k } from "./App.
|
|
5
|
+
import { e as k } from "./App.Ch8FU2zW.js";
|
|
6
6
|
const A = ({
|
|
7
7
|
className: e,
|
|
8
8
|
viewBox: a,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { jsxs as l, jsx as e } from "react/jsx-runtime";
|
|
2
|
-
import { n as f, i as U, useUserChatStats as v, useChatsUsage as E, USAGE_TITLE as L, S as h, renderDataAsList as M, CARDS as n, L as _, j as D, C as m, pluralize as i } from "./index.
|
|
3
|
-
import { oe as z } from "./App.
|
|
2
|
+
import { n as f, i as U, useUserChatStats as v, useChatsUsage as E, USAGE_TITLE as L, S as h, renderDataAsList as M, CARDS as n, L as _, j as D, C as m, pluralize as i } from "./index.DnHjiSVh.js";
|
|
3
|
+
import { oe as z } from "./App.Ch8FU2zW.js";
|
|
4
4
|
import { useState as O, Suspense as P, lazy as B } from "react";
|
|
5
5
|
const t = [0, 3, 6, 9], j = B(() => import(
|
|
6
6
|
/* webpackChunkName: "LazyChart" */
|
|
7
|
-
"./Chart.
|
|
7
|
+
"./Chart.Iz1BoL-_.js"
|
|
8
8
|
)), b = ({
|
|
9
9
|
open: S,
|
|
10
10
|
onOpenChange: I
|
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
import { jsxs as r, Fragment as B, jsx as e } from "react/jsx-runtime";
|
|
2
|
+
import { n as V, LOCAL_STORAGE_PREFIX as N, LOCAL_STORAGE_SORT_MEMORY_DIRECTION as Y, LOCAL_STORAGE_SORT_MEMORY_COLUMN as X, useUserMemories as $, useDeleteMemory as J, useDeleteAllMemories as K, L as O, j as u, te as Q, C as M } from "./index.DnHjiSVh.js";
|
|
3
|
+
import { E as T, e as c, ConfirmationPanel as R, oe as W, st as Z } from "./App.Ch8FU2zW.js";
|
|
4
|
+
import f from "clsx";
|
|
5
|
+
import { useState as a, useRef as ee } from "react";
|
|
6
|
+
import { j as te, D as re, G as x, M as n, F as oe, H as ne, l as ie, U as le } from "./Table.SHD8KKEE.js";
|
|
7
|
+
const ue = ({
|
|
8
|
+
open: A,
|
|
9
|
+
onOpenChange: C,
|
|
10
|
+
user: s
|
|
11
|
+
}) => {
|
|
12
|
+
const { getAccessToken: h } = V(), [E] = a(void 0), [L, _] = T({
|
|
13
|
+
key: N + Y,
|
|
14
|
+
initialValue: c.DESC
|
|
15
|
+
}), [b, v] = T({
|
|
16
|
+
key: N + X,
|
|
17
|
+
initialValue: "createdAt"
|
|
18
|
+
}), [p, I] = a(L || c.DESC), [G, j] = a(
|
|
19
|
+
b || "createdAt"
|
|
20
|
+
), { data: l, isLoading: D, isError: y } = $({
|
|
21
|
+
user: s,
|
|
22
|
+
query: E,
|
|
23
|
+
getAccessToken: h,
|
|
24
|
+
enabled: A
|
|
25
|
+
}), g = J({ getAccessToken: h }), S = K({ getAccessToken: h }), [F, w] = a(!1), i = ee(null), [P, k] = a(!1), U = (t, o, m, d) => {
|
|
26
|
+
i.current = { id: t, text: o, description: m, createdAt: d }, w(!0);
|
|
27
|
+
}, z = () => {
|
|
28
|
+
i.current && g.mutate({ user: s, memoryId: i.current.id });
|
|
29
|
+
}, H = () => {
|
|
30
|
+
s && k(!0);
|
|
31
|
+
}, q = () => {
|
|
32
|
+
s && S.mutate({ user: s });
|
|
33
|
+
};
|
|
34
|
+
return /* @__PURE__ */ r(B, { children: [
|
|
35
|
+
/* @__PURE__ */ r(
|
|
36
|
+
R,
|
|
37
|
+
{
|
|
38
|
+
showConfirmation: F,
|
|
39
|
+
setShowConfirmation: w,
|
|
40
|
+
action: z,
|
|
41
|
+
customStrings: {
|
|
42
|
+
title: "Delete memory",
|
|
43
|
+
confirmAction: "Delete",
|
|
44
|
+
cancelAction: "Cancel"
|
|
45
|
+
},
|
|
46
|
+
children: [
|
|
47
|
+
/* @__PURE__ */ e("p", { className: "m-0", children: "Are you sure you want to delete this memory?" }),
|
|
48
|
+
/* @__PURE__ */ r("ul", { className: "m-0 mt-2 list-disc list-inside text-xs opacity-80", children: [
|
|
49
|
+
/* @__PURE__ */ r("li", { children: [
|
|
50
|
+
"Excerpt:",
|
|
51
|
+
" ",
|
|
52
|
+
(i.current?.description || i.current?.text || "").slice(0, 80)
|
|
53
|
+
] }),
|
|
54
|
+
/* @__PURE__ */ r("li", { children: [
|
|
55
|
+
"Created:",
|
|
56
|
+
" ",
|
|
57
|
+
i.current?.createdAt ? new Date(i.current.createdAt).toLocaleString() : "-"
|
|
58
|
+
] })
|
|
59
|
+
] })
|
|
60
|
+
]
|
|
61
|
+
}
|
|
62
|
+
),
|
|
63
|
+
/* @__PURE__ */ e(
|
|
64
|
+
R,
|
|
65
|
+
{
|
|
66
|
+
showConfirmation: P,
|
|
67
|
+
setShowConfirmation: k,
|
|
68
|
+
action: q,
|
|
69
|
+
customStrings: {
|
|
70
|
+
title: "Delete all memories",
|
|
71
|
+
confirmAction: "Delete all",
|
|
72
|
+
cancelAction: "Cancel"
|
|
73
|
+
},
|
|
74
|
+
children: /* @__PURE__ */ e("p", { className: "m-0", children: "This will permanently delete all memories for this user. This action cannot be undone." })
|
|
75
|
+
}
|
|
76
|
+
),
|
|
77
|
+
/* @__PURE__ */ e(
|
|
78
|
+
W,
|
|
79
|
+
{
|
|
80
|
+
open: A,
|
|
81
|
+
onOpenChange: (t) => C(t),
|
|
82
|
+
title: "User Memories",
|
|
83
|
+
animation: !0,
|
|
84
|
+
animationType: "fade",
|
|
85
|
+
footer: /* @__PURE__ */ r(O, { columnGap: 2, alignHorizontal: "flex-end", children: [
|
|
86
|
+
/* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(
|
|
87
|
+
M,
|
|
88
|
+
{
|
|
89
|
+
mode: "dark",
|
|
90
|
+
variant: "secondary",
|
|
91
|
+
noBorder: !0,
|
|
92
|
+
focusMode: "light",
|
|
93
|
+
onClick: () => C(!1),
|
|
94
|
+
children: "Close"
|
|
95
|
+
}
|
|
96
|
+
) }),
|
|
97
|
+
/* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(
|
|
98
|
+
M,
|
|
99
|
+
{
|
|
100
|
+
mode: "dark",
|
|
101
|
+
focusMode: "light",
|
|
102
|
+
variant: "danger",
|
|
103
|
+
disabled: S.isPending || (l?.total ?? 0) === 0,
|
|
104
|
+
onClick: H,
|
|
105
|
+
children: "Delete All"
|
|
106
|
+
}
|
|
107
|
+
) })
|
|
108
|
+
] }),
|
|
109
|
+
children: /* @__PURE__ */ r("div", { className: "flex flex-col sm:flex-row max-h-[75vh] min-h-[60vh] pt-2", children: [
|
|
110
|
+
D && /* @__PURE__ */ e("p", { className: "m-0", children: "Loading memories..." }),
|
|
111
|
+
y && /* @__PURE__ */ e("p", { className: "m-0 text-red-500", children: "Failed to load memories." }),
|
|
112
|
+
!D && !y && (l && l.items.length > 0 ? /* @__PURE__ */ r(te, { stickyHeader: !0, stickyFooter: !0, compact: !0, mode: "alt-system", children: [
|
|
113
|
+
/* @__PURE__ */ e(re, { children: /* @__PURE__ */ r(x, { children: [
|
|
114
|
+
/* @__PURE__ */ e(n, { className: "sr-only", children: "Row" }),
|
|
115
|
+
/* @__PURE__ */ e(n, { children: "Memory" }),
|
|
116
|
+
/* @__PURE__ */ e(
|
|
117
|
+
oe,
|
|
118
|
+
{
|
|
119
|
+
focusMode: "system",
|
|
120
|
+
buttonClassName: "text-xs sm:text-sm",
|
|
121
|
+
cellId: "createdAt",
|
|
122
|
+
align: "left",
|
|
123
|
+
sortDirection: p,
|
|
124
|
+
sortedCell: G,
|
|
125
|
+
onClick: () => {
|
|
126
|
+
j("createdAt"), v("createdAt"), I((t) => {
|
|
127
|
+
const o = t === c.ASC ? c.DESC : c.ASC;
|
|
128
|
+
return _(o), o;
|
|
129
|
+
});
|
|
130
|
+
},
|
|
131
|
+
children: "Date"
|
|
132
|
+
}
|
|
133
|
+
),
|
|
134
|
+
/* @__PURE__ */ e(n, { align: "right", children: "Actions" })
|
|
135
|
+
] }) }),
|
|
136
|
+
/* @__PURE__ */ e(ne, { children: [...l.items].sort((t, o) => {
|
|
137
|
+
const m = t.createdAt ? new Date(t.createdAt).getTime() : 0, d = o.createdAt ? new Date(o.createdAt).getTime() : 0;
|
|
138
|
+
return p === c.ASC ? m - d : d - m;
|
|
139
|
+
}).map((t, o) => /* @__PURE__ */ r(x, { children: [
|
|
140
|
+
/* @__PURE__ */ e(n, { className: f("dark:text-gray-400"), children: o + 1 }),
|
|
141
|
+
/* @__PURE__ */ e(
|
|
142
|
+
n,
|
|
143
|
+
{
|
|
144
|
+
className: f(
|
|
145
|
+
"dark:text-white",
|
|
146
|
+
"max-w-[100px] sm:max-w-[400px]",
|
|
147
|
+
"text-xs sm:text-sm"
|
|
148
|
+
),
|
|
149
|
+
style: {
|
|
150
|
+
wordBreak: "break-word"
|
|
151
|
+
},
|
|
152
|
+
children: t.description || t.text
|
|
153
|
+
}
|
|
154
|
+
),
|
|
155
|
+
/* @__PURE__ */ e(
|
|
156
|
+
n,
|
|
157
|
+
{
|
|
158
|
+
component: "th",
|
|
159
|
+
scope: "row",
|
|
160
|
+
className: f(
|
|
161
|
+
"dark:text-gray-400",
|
|
162
|
+
"sm:whitespace-nowrap text-xs sm:text-sm max-w-20 sm:max-w-none"
|
|
163
|
+
),
|
|
164
|
+
children: t.createdAt ? new Date(t.createdAt).toLocaleDateString() : "-"
|
|
165
|
+
}
|
|
166
|
+
),
|
|
167
|
+
/* @__PURE__ */ e(n, { className: "align-top", align: "right", children: /* @__PURE__ */ e(O, { columnGap: 1, alignHorizontal: "flex-end", children: /* @__PURE__ */ e(u, { children: /* @__PURE__ */ e(
|
|
168
|
+
Z,
|
|
169
|
+
{
|
|
170
|
+
label: "Delete memory",
|
|
171
|
+
mode: "system",
|
|
172
|
+
placement: "top",
|
|
173
|
+
trigger: /* @__PURE__ */ e(
|
|
174
|
+
Q,
|
|
175
|
+
{
|
|
176
|
+
focusMode: "system",
|
|
177
|
+
noBorder: !0,
|
|
178
|
+
label: "Delete memory",
|
|
179
|
+
variant: "primary",
|
|
180
|
+
iconClassName: "text-red-700 dark:text-red-500",
|
|
181
|
+
disabled: g.isPending,
|
|
182
|
+
onClick: () => U(
|
|
183
|
+
t.memoryId,
|
|
184
|
+
t.text,
|
|
185
|
+
t.description,
|
|
186
|
+
t.createdAt
|
|
187
|
+
),
|
|
188
|
+
children: /* @__PURE__ */ e(ie, { size: "size-3", monotone: !0 })
|
|
189
|
+
}
|
|
190
|
+
)
|
|
191
|
+
}
|
|
192
|
+
) }) }) })
|
|
193
|
+
] }, t.memoryId)) }),
|
|
194
|
+
/* @__PURE__ */ e(le, { children: /* @__PURE__ */ e(x, { children: /* @__PURE__ */ r(n, { colSpan: 4, children: [
|
|
195
|
+
l.total,
|
|
196
|
+
" memor",
|
|
197
|
+
l.total === 1 ? "y" : "ies"
|
|
198
|
+
] }) }) })
|
|
199
|
+
] }) : /* @__PURE__ */ e("p", { className: "m-0 italic opacity-70", children: "No memories stored." }))
|
|
200
|
+
] })
|
|
201
|
+
}
|
|
202
|
+
)
|
|
203
|
+
] });
|
|
204
|
+
};
|
|
205
|
+
export {
|
|
206
|
+
ue as UserMemoriesPanel,
|
|
207
|
+
ue as default
|
|
208
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { find as Aa, parse as Ft, parse$1 as Ht, normalize as Pt, html as Ta, svg as Ba, visitParents as Na, SKIP as Da } from "./useMarkdown.
|
|
2
|
-
import { toText as Ca } from "./index.
|
|
1
|
+
import { find as Aa, parse as Ft, parse$1 as Ht, normalize as Pt, html as Ta, svg as Ba, visitParents as Na, SKIP as Da } from "./useMarkdown.BBFa2GkT.js";
|
|
2
|
+
import { toText as Ca } from "./index.HkxzuofI.js";
|
|
3
3
|
const Gt = /[#.]/g;
|
|
4
4
|
function qa(r, e) {
|
|
5
5
|
const t = r || "", a = {};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { getDefaultExportFromCjs as kn } from "./App.
|
|
2
|
-
import { visit as In } from "./useMarkdown.
|
|
3
|
-
import { toText as Cn } from "./index.
|
|
1
|
+
import { getDefaultExportFromCjs as kn } from "./App.Ch8FU2zW.js";
|
|
2
|
+
import { visit as In } from "./useMarkdown.BBFa2GkT.js";
|
|
3
|
+
import { toText as Cn } from "./index.HkxzuofI.js";
|
|
4
4
|
function xn(e) {
|
|
5
5
|
const t = e.regex, i = e.COMMENT("//", "$", { contains: [{ begin: /\\\n/ }] }), a = "decltype\\(auto\\)", r = "[a-zA-Z_]\\w*::", d = "(?!struct)(" + a + "|" + t.optional(r) + "[a-zA-Z_]\\w*" + t.optional("<[^<>]+>") + ")", c = {
|
|
6
6
|
className: "type",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { convert as se, visitParents as Me, unicodeWhitespace as I, unicodePunctuation as N, normalizeIdentifier as _, classifyCharacter as W, visit as _e, toString as ce, EXIT as Oe, asciiAlphanumeric as Z, asciiAlpha as P, markdownLineEndingOrSpace as A, asciiControl as je, blankLine as Be, factorySpace as S, splice as q, resolveAll as We, markdownLineEnding as R, markdownSpace as T, combineExtensions as $e } from "./useMarkdown.
|
|
1
|
+
import { convert as se, visitParents as Me, unicodeWhitespace as I, unicodePunctuation as N, normalizeIdentifier as _, classifyCharacter as W, visit as _e, toString as ce, EXIT as Oe, asciiAlphanumeric as Z, asciiAlpha as P, markdownLineEndingOrSpace as A, asciiControl as je, blankLine as Be, factorySpace as S, splice as q, resolveAll as We, markdownLineEnding as R, markdownSpace as T, combineExtensions as $e } from "./useMarkdown.BBFa2GkT.js";
|
|
2
2
|
import { longestStreak as qe } from "./index.Cyw5OC0t.js";
|
|
3
3
|
function ne(e, n) {
|
|
4
4
|
const t = String(e);
|