@versini/sassysaint 5.4.4 → 5.4.6

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.
@@ -1,5 +1,5 @@
1
1
  import { jsx as bs } from "react/jsx-runtime";
2
- import { convert as vs, getDefaultExportFromCjs as ys, visit as ws, find as Es, parse as xn, parse$1 as _n, normalize as Sn, svg as xs, html as _s, visitParents as Ss, SKIP as Ns, longestStreak as ks, factorySpace as Er, markdownLineEnding as Ht, Markdown as Ts, remarkGfm as Ms } from "./LazyMessageAssistant.cGZrKUGF.js";
2
+ import { convert as vs, getDefaultExportFromCjs as ys, visit as ws, find as Es, parse as xn, parse$1 as _n, normalize as Sn, svg as xs, html as _s, visitParents as Ss, SKIP as Ns, longestStreak as ks, factorySpace as Er, markdownLineEnding as Ht, Markdown as Ts, remarkGfm as Ms } from "./LazyMessageAssistant.sDgYeEsY.js";
3
3
  const Nn = (
4
4
  // Note: overloads like this are needed to support optional generics.
5
5
  /**
@@ -1,9 +1,9 @@
1
1
  import { jsxs as He, jsx as re, Fragment as Zt } from "react/jsx-runtime";
2
- import { le as at } from "./LazyApp.cIKe00HD.js";
3
- import { E as hi } from "./index.DTvyH-fG.js";
2
+ import { le as at } from "./LazyApp.B-F4mWWU.js";
3
+ import { E as hi } from "./index.CTDNajS_.js";
4
4
  import sn from "clsx";
5
5
  import { lazy as mi, useContext as gi, Suspense as di } from "react";
6
- import { AppContext as yi, LOCAL_STORAGE_PREFIX as ki, LOCAL_STORAGE_CHAT_DETAILS as xi, durationFormatter as bi } from "./index.7zCJNQU6.js";
6
+ import { AppContext as yi, LOCAL_STORAGE_PREFIX as ki, LOCAL_STORAGE_CHAT_DETAILS as xi, durationFormatter as bi } from "./index.sbHwdUKv.js";
7
7
  /*!
8
8
  @versini/ui-spinner v1.4.0
9
9
  © 2024 gizmette.com
@@ -8675,7 +8675,7 @@ function $c(e) {
8675
8675
  const qc = mi(
8676
8676
  () => import(
8677
8677
  /* webpackChunkName: "LazyMarkdownWithExtra" */
8678
- "./LazyMarkdownWithExtra.BEPUVoKN.js"
8678
+ "./LazyMarkdownWithExtra.CW5V1fRn.js"
8679
8679
  )
8680
8680
  ), Tn = {
8681
8681
  MODEL: "Model",
@@ -1,5 +1,5 @@
1
1
  import { jsxs as x, jsx as c, Fragment as Te } from "react/jsx-runtime";
2
- import { g as Se } from "./index.7zCJNQU6.js";
2
+ import { g as Se } from "./index.sbHwdUKv.js";
3
3
  import O, { useSyncExternalStore as Ie, useCallback as P, useEffect as A, useContext as R, useRef as f, useState as $, useLayoutEffect as U, useMemo as ie, useId as Ce, useReducer as $e } from "react";
4
4
  import s from "clsx";
5
5
  const $t = ({
@@ -78,8 +78,8 @@ const k = {
78
78
  displayName
79
79
  }
80
80
  }`,
81
- GET_CHATS: `query GetChats($userId: String!) {
82
- chats(user: $userId) {
81
+ GET_CHATS: `query GetChats($userId: String!, $searchString: String, $limit: Float) {
82
+ chats(user: $userId, searchString: $searchString, limit: $limit) {
83
83
  timestamp
84
84
  id
85
85
  model
@@ -2073,7 +2073,12 @@ const jo = (e, t) => t && t.messages.length > 0 && t.messages[t.messages.length
2073
2073
  }) : "N/A", qa = (e) => y(
2074
2074
  "flex-1 space-y-6 overflow-y-auto rounded-md bg-slate-900 px-4 pb-10 text-base leading-6 text-slate-300 shadow-sm sm:text-base sm:leading-7",
2075
2075
  e || tt ? "pt-4" : "pt-10"
2076
- ), Qo = (e, t) => t === 1 ? e : `${e}s`, Et = "av-button";
2076
+ ), Qo = (e, t) => t === 1 ? e : `${e}s`, Zo = (e, t) => {
2077
+ let r;
2078
+ return (...a) => {
2079
+ window.clearTimeout(r), r = window.setTimeout(() => e(...a), t);
2080
+ };
2081
+ }, Et = "av-button";
2077
2082
  /*!
2078
2083
  @versini/ui-spacing v1.1.0
2079
2084
  © 2024 gizmette.com
@@ -3608,14 +3613,14 @@ try {
3608
3613
  });
3609
3614
  } catch {
3610
3615
  }
3611
- const Bn = "ASK! ME! ANYTHING!", sr = "LeeLou", Jn = "gizmette.com", Yn = "Log in", Fn = "Sign in with a Passkey", Zo = "Log out", zn = "Password", jn = "Powered by ", es = "Send", ts = "Profile", rs = "Statistics", as = "Chat history", ns = "About", os = "Type your question here", ss = "<clipboard>", is = {
3616
+ const Bn = "ASK! ME! ANYTHING!", sr = "LeeLou", Jn = "gizmette.com", Yn = "Log in", Fn = "Sign in with a Passkey", es = "Log out", zn = "Password", jn = "Powered by ", ts = "Send", rs = "Profile", as = "Statistics", ns = "Chat history", os = "About", ss = "Type your question here", is = "<clipboard>", cs = {
3612
3617
  ACTION_WHILE_STREAMING: {
3613
3618
  content: "Cancel chat"
3614
3619
  },
3615
3620
  ACTION_WHILE_NOT_STREAMING: {
3616
3621
  content: "New chat"
3617
3622
  }
3618
- }, cs = "N/A", ls = "Tags are pre-filled buttons available on the main screen, to help you quickly start requests. The label is used for the button, and the content is what will be inserted in the chat when the button is pressed. You can use the special placeholder <clipboard> to automatically insert the content of your clipboard.", ds = {
3623
+ }, ls = "N/A", ds = "Tags are pre-filled buttons available on the main screen, to help you quickly start requests. The label is used for the button, and the content is what will be inserted in the chat when the button is pressed. You can use the special placeholder <clipboard> to automatically insert the content of your clipboard.", us = {
3619
3624
  PREFERENCES: {
3620
3625
  TITLE: "User settings",
3621
3626
  NAME: "Name",
@@ -3726,11 +3731,11 @@ const Xn = (e) => {
3726
3731
  engine: Je,
3727
3732
  engines: []
3728
3733
  }
3729
- }), us = P.createContext({
3734
+ }), ms = P.createContext({
3730
3735
  state: { searchString: "", sortedCell: "", sortDirection: "" },
3731
3736
  dispatch: () => {
3732
3737
  }
3733
- }), ms = P.createContext({
3738
+ }), hs = P.createContext({
3734
3739
  state: { tag: "" },
3735
3740
  dispatch: () => {
3736
3741
  }
@@ -3745,7 +3750,7 @@ const Xn = (e) => {
3745
3750
  row1: /* @__PURE__ */ _("div", { children: [
3746
3751
  sr,
3747
3752
  " v",
3748
- "5.8.1",
3753
+ "5.9.0",
3749
3754
  " - ",
3750
3755
  jn,
3751
3756
  t && t.engine,
@@ -3762,7 +3767,7 @@ const Xn = (e) => {
3762
3767
  }, to = vt(
3763
3768
  () => import(
3764
3769
  /* webpackChunkName: "LazyHeader" */
3765
- "./LazyHeader.C-PVExEQ.js"
3770
+ "./LazyHeader.PqNNzUEq.js"
3766
3771
  )
3767
3772
  ), ro = () => {
3768
3773
  const { isAuthenticated: e } = et();
@@ -3874,7 +3879,7 @@ const Xn = (e) => {
3874
3879
  }, no = new URL(document.location.href).searchParams, oo = !!no.get("debug") || !1, so = vt(
3875
3880
  () => import(
3876
3881
  /* webpackChunkName: "LazyApp" */
3877
- "./LazyApp.cIKe00HD.js"
3882
+ "./LazyApp.B-F4mWWU.js"
3878
3883
  ).then((e) => e.LazyApp)
3879
3884
  ), io = ({ isComponent: e }) => {
3880
3885
  const { isAuthenticated: t } = et();
@@ -3882,9 +3887,9 @@ const Xn = (e) => {
3882
3887
  }, co = ({
3883
3888
  isComponent: e = !1,
3884
3889
  domain: t = ja
3885
- }) => /* @__PURE__ */ l(fe, { children: /* @__PURE__ */ l(Ua, { clientId: Ka, domain: t, debug: oo, children: /* @__PURE__ */ l(io, { isComponent: e }) }) }), hs = ({ domain: e }) => /* @__PURE__ */ l(co, { isComponent: !0, domain: e });
3890
+ }) => /* @__PURE__ */ l(fe, { children: /* @__PURE__ */ l(Ua, { clientId: Ka, domain: t, debug: oo, children: /* @__PURE__ */ l(io, { isComponent: e }) }) }), ps = ({ domain: e }) => /* @__PURE__ */ l(co, { isComponent: !0, domain: e });
3886
3891
  export {
3887
- ns as ABOUT_TITLE,
3892
+ os as ABOUT_TITLE,
3888
3893
  Po as ACTION_ENGINE,
3889
3894
  No as ACTION_MESSAGE,
3890
3895
  xo as ACTION_MODEL,
@@ -3899,43 +3904,44 @@ export {
3899
3904
  sr as APP_NAME,
3900
3905
  Zn as AppContext,
3901
3906
  eo as AppFooter,
3902
- ds as CARDS,
3903
- ss as CLIPBOARD_TAG,
3907
+ us as CARDS,
3908
+ is as CLIPBOARD_TAG,
3904
3909
  Je as DEFAULT_AI_ENGINE,
3905
3910
  mn as E,
3906
3911
  Ao as ENGINE_ANTHROPIC,
3907
3912
  vo as ENGINE_OPENAI,
3908
3913
  So as ERROR_MESSAGE,
3909
3914
  ko as GPT4_MAX_TOKENS,
3910
- as as HISTORY_TITLE,
3911
- us as HistoryContext,
3915
+ ns as HISTORY_TITLE,
3916
+ ms as HistoryContext,
3912
3917
  Ho as LOCAL_STORAGE_CHAT_DETAILS,
3913
3918
  Vo as LOCAL_STORAGE_ENGINE_TOGGLE,
3914
3919
  Ko as LOCAL_STORAGE_PREFIX,
3915
3920
  Go as LOCAL_STORAGE_SEARCH,
3916
3921
  Wo as LOCAL_STORAGE_SORT,
3917
- Zo as LOG_OUT,
3922
+ es as LOG_OUT,
3918
3923
  ue as M,
3919
3924
  ro as MessagesContainerHeader,
3920
- cs as NA,
3925
+ ls as NA,
3921
3926
  qe as O,
3922
- ts as PROFILE_TITLE,
3927
+ rs as PROFILE_TITLE,
3923
3928
  Zt as R,
3924
3929
  wo as ROLE_ASSISTANT,
3925
3930
  To as ROLE_HIDDEN,
3926
3931
  _o as ROLE_INTERNAL,
3927
3932
  Io as ROLE_SYSTEM,
3928
3933
  Eo as ROLE_USER,
3929
- es as SEND,
3930
- rs as STATS,
3934
+ ts as SEND,
3935
+ as as STATS,
3931
3936
  Bo as STATS_SEPARATOR,
3932
- hs as SassySaint,
3933
- ls as TAGS_DESCRIPTION,
3934
- is as TOOLBOX,
3935
- os as TYPE_QUESTION,
3936
- ms as TagsContext,
3937
+ ps as SassySaint,
3938
+ ds as TAGS_DESCRIPTION,
3939
+ cs as TOOLBOX,
3940
+ ss as TYPE_QUESTION,
3941
+ hs as TagsContext,
3937
3942
  wt as b,
3938
3943
  wn as c,
3944
+ Zo as debounce,
3939
3945
  Xo as durationFormatter,
3940
3946
  zo as extractAverage,
3941
3947
  nt as fe,
@@ -1,5 +1,5 @@
1
1
  import "react/jsx-runtime";
2
- import { SassySaint as a } from "../../chunks/index.7zCJNQU6.js";
2
+ import { SassySaint as a } from "../../chunks/index.sbHwdUKv.js";
3
3
  export {
4
4
  a as SassySaint
5
5
  };
package/dist/index.js CHANGED
@@ -1,12 +1,12 @@
1
- import { SassySaint as r } from "./chunks/index.7zCJNQU6.js";
1
+ import { SassySaint as r } from "./chunks/index.sbHwdUKv.js";
2
2
  /*!
3
- @sassysaint/client v5.8.1
3
+ @sassysaint/client v5.9.0
4
4
  © 2024 gizmette.com
5
5
  */
6
6
  try {
7
7
  window.__VERSINI_SASSY_GLOBAL__ || (window.__VERSINI_SASSY_GLOBAL__ = {
8
- version: "5.8.1",
9
- buildTime: "12/27/2024 02:06 PM EST",
8
+ version: "5.9.0",
9
+ buildTime: "12/28/2024 10:44 AM EST",
10
10
  license: "MIT"
11
11
  });
12
12
  } catch {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@versini/sassysaint",
3
- "version": "5.4.4",
3
+ "version": "5.4.6",
4
4
  "license": "MIT",
5
5
  "author": "Arno Versini",
6
6
  "publishConfig": {
@@ -30,7 +30,7 @@
30
30
  "react-dom": "^18.3.1 || ^19.0.0"
31
31
  },
32
32
  "devDependencies": {
33
- "@sassysaint/client": "5.8.1",
33
+ "@sassysaint/client": "5.9.0",
34
34
  "@versini/ui-styles": "1.14.0"
35
35
  },
36
36
  "dependencies": {
@@ -41,5 +41,5 @@
41
41
  "sideEffects": [
42
42
  "**/*.css"
43
43
  ],
44
- "gitHead": "0b8ee203910b9ed2f25fbb9a0dee148bf14f9794"
44
+ "gitHead": "27cc45fba47bef1ddb40c4c2c21d204a11ea6f35"
45
45
  }
@@ -1,99 +0,0 @@
1
- import { jsx as l } from "react/jsx-runtime";
2
- import { useMergeRefs as _, FloatingPortal as C, FloatingOverlay as E, FloatingFocusManager as O, useFloating as R, useClick as k, useDismiss as x, useRole as y, useInteractions as F } from "@floating-ui/react";
3
- import L from "clsx";
4
- import * as t from "react";
5
- import { useId as h } from "react";
6
- const b = t.createContext(null);
7
- function S({
8
- initialOpen: n = !1,
9
- open: s,
10
- onOpenChange: o
11
- } = {}) {
12
- const [e, r] = t.useState(n), [i, a] = t.useState(), [c, I] = t.useState(), u = s ?? e, f = o ?? r, p = R({
13
- open: u,
14
- onOpenChange: f
15
- }), m = p.context, M = k(m, {
16
- enabled: s == null
17
- }), v = x(m, {
18
- outsidePress: !1,
19
- outsidePressEvent: "mousedown"
20
- }), w = y(m), g = F([M, v, w]);
21
- return t.useMemo(
22
- () => ({
23
- open: u,
24
- setOpen: f,
25
- ...g,
26
- ...p,
27
- labelId: i,
28
- descriptionId: c,
29
- setLabelId: a,
30
- setDescriptionId: I
31
- }),
32
- [u, f, g, p, i, c]
33
- );
34
- }
35
- const d = () => {
36
- const n = t.useContext(b);
37
- if (n == null)
38
- throw new Error("Modal components must be wrapped in <Modal />");
39
- return n;
40
- };
41
- function A({
42
- children: n,
43
- ...s
44
- }) {
45
- const o = S(s);
46
- return /* @__PURE__ */ l(b.Provider, { value: o, children: n });
47
- }
48
- const U = t.forwardRef(function(n, s) {
49
- const { context: o, ...e } = d(), r = _([e.refs.setFloating, s]);
50
- if (!o.open)
51
- return null;
52
- const { overlayBackground: i, ...a } = n, c = L("grid place-items-center", {
53
- [`${i}`]: i,
54
- "bg-black sm:bg-black/[.8]": !i
55
- });
56
- return /* @__PURE__ */ l(C, { children: /* @__PURE__ */ l(E, { className: c, lockScroll: !0, children: /* @__PURE__ */ l(O, { context: o, children: /* @__PURE__ */ l(
57
- "div",
58
- {
59
- ref: r,
60
- "aria-labelledby": e.labelId,
61
- "aria-describedby": e.descriptionId,
62
- ...e.getFloatingProps(a),
63
- children: a.children
64
- }
65
- ) }) }) });
66
- }), V = t.forwardRef(function({ children: n, ...s }, o) {
67
- const { setLabelId: e } = d(), r = h();
68
- return t.useLayoutEffect(() => (e(r), () => e(void 0)), [r, e]), /* @__PURE__ */ l("h1", { ...s, ref: o, id: r, children: n });
69
- }), $ = t.forwardRef(function({ children: n, ...s }, o) {
70
- const { setDescriptionId: e } = d(), r = h();
71
- return t.useLayoutEffect(() => (e(r), () => e(void 0)), [r, e]), /* @__PURE__ */ l("div", { ...s, ref: o, id: r, children: n });
72
- }), j = t.forwardRef(function(n, s) {
73
- const { setOpen: o } = d(), { trigger: e, className: r, ...i } = n, a = t.useCallback(() => o(!1), [o]);
74
- return /* @__PURE__ */ l("div", { className: r, children: t.cloneElement(e, {
75
- ref: s,
76
- onClick: a,
77
- ...i
78
- }) });
79
- });
80
- /*!
81
- @versini/ui-modal v1.1.0
82
- © 2024 gizmette.com
83
- */
84
- try {
85
- window.__VERSINI_UI_MODAL__ || (window.__VERSINI_UI_MODAL__ = {
86
- version: "1.1.0",
87
- buildTime: "12/26/2024 06:05 PM EST",
88
- homepage: "https://github.com/aversini/ui-components",
89
- license: "MIT"
90
- });
91
- } catch {
92
- }
93
- export {
94
- A as Modal,
95
- j as ModalClose,
96
- U as ModalContent,
97
- $ as ModalDescription,
98
- V as ModalHeading
99
- };