@versini/sassysaint 5.4.6 → 5.4.8

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,6 +1,6 @@
1
- import { jsx as l, jsxs as _, Fragment as fe } from "react/jsx-runtime";
2
- import P, { createContext as cr, useReducer as _t, useRef as K, useCallback as X, useEffect as Z, useContext as Xe, useSyncExternalStore as lr, useId as Tt, useState as q, useLayoutEffect as st, useMemo as St, lazy as vt, Suspense as At } from "react";
3
- import y from "clsx";
1
+ import { jsx as l, jsxs as I, Fragment as fe } from "react/jsx-runtime";
2
+ import P, { createContext as cr, useReducer as _t, useRef as $, useCallback as q, useEffect as Q, useContext as Qe, useSyncExternalStore as lr, useId as kt, useState as j, useLayoutEffect as it, useMemo as St, lazy as At, Suspense as vt } from "react";
3
+ import g from "clsx";
4
4
  var dr = Object.defineProperty, ur = (e, t, r) => t in e ? dr(e, t, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[t] = r, Ue = (e, t, r) => ur(e, typeof t != "symbol" ? t + "" : t, r);
5
5
  /*!
6
6
  @versini/auth-provider v7.4.0
@@ -28,10 +28,10 @@ function Ne(e) {
28
28
  s[i] = n.charCodeAt(i);
29
29
  return o;
30
30
  }
31
- function Qe() {
31
+ function Ze() {
32
32
  return (window == null ? void 0 : window.PublicKeyCredential) !== void 0 && typeof window.PublicKeyCredential == "function";
33
33
  }
34
- function kt(e) {
34
+ function Nt(e) {
35
35
  const { id: t } = e;
36
36
  return {
37
37
  ...e,
@@ -39,85 +39,85 @@ function kt(e) {
39
39
  transports: e.transports
40
40
  };
41
41
  }
42
- function Nt(e) {
42
+ function Rt(e) {
43
43
  return e === "localhost" || /^([a-z0-9]+(-[a-z0-9]+)*\.)+[a-z]{2,}$/i.test(e);
44
44
  }
45
- let x = class extends Error {
45
+ let R = class extends Error {
46
46
  constructor({ message: t, code: r, cause: a, name: n }) {
47
47
  super(t, { cause: a }), this.name = n ?? a.name, this.code = r;
48
48
  }
49
49
  };
50
- function mr({ error: e, options: t }) {
50
+ function hr({ error: e, options: t }) {
51
51
  var a, n;
52
52
  const { publicKey: r } = t;
53
53
  if (!r)
54
54
  throw Error("options was missing required publicKey property");
55
55
  if (e.name === "AbortError") {
56
56
  if (t.signal instanceof AbortSignal)
57
- return new x({
57
+ return new R({
58
58
  message: "Registration ceremony was sent an abort signal",
59
59
  code: "ERROR_CEREMONY_ABORTED",
60
60
  cause: e
61
61
  });
62
62
  } else if (e.name === "ConstraintError") {
63
63
  if (((a = r.authenticatorSelection) == null ? void 0 : a.requireResidentKey) === !0)
64
- return new x({
64
+ return new R({
65
65
  message: "Discoverable credentials were required but no available authenticator supported it",
66
66
  code: "ERROR_AUTHENTICATOR_MISSING_DISCOVERABLE_CREDENTIAL_SUPPORT",
67
67
  cause: e
68
68
  });
69
69
  if (((n = r.authenticatorSelection) == null ? void 0 : n.userVerification) === "required")
70
- return new x({
70
+ return new R({
71
71
  message: "User verification was required but no available authenticator supported it",
72
72
  code: "ERROR_AUTHENTICATOR_MISSING_USER_VERIFICATION_SUPPORT",
73
73
  cause: e
74
74
  });
75
75
  } else {
76
76
  if (e.name === "InvalidStateError")
77
- return new x({
77
+ return new R({
78
78
  message: "The authenticator was previously registered",
79
79
  code: "ERROR_AUTHENTICATOR_PREVIOUSLY_REGISTERED",
80
80
  cause: e
81
81
  });
82
82
  if (e.name === "NotAllowedError")
83
- return new x({
83
+ return new R({
84
84
  message: e.message,
85
85
  code: "ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",
86
86
  cause: e
87
87
  });
88
88
  if (e.name === "NotSupportedError")
89
- return r.pubKeyCredParams.filter((o) => o.type === "public-key").length === 0 ? new x({
89
+ return r.pubKeyCredParams.filter((o) => o.type === "public-key").length === 0 ? new R({
90
90
  message: 'No entry in pubKeyCredParams was of type "public-key"',
91
91
  code: "ERROR_MALFORMED_PUBKEYCREDPARAMS",
92
92
  cause: e
93
- }) : new x({
93
+ }) : new R({
94
94
  message: "No available authenticator supported any of the specified pubKeyCredParams algorithms",
95
95
  code: "ERROR_AUTHENTICATOR_NO_SUPPORTED_PUBKEYCREDPARAMS_ALG",
96
96
  cause: e
97
97
  });
98
98
  if (e.name === "SecurityError") {
99
99
  const o = window.location.hostname;
100
- if (Nt(o)) {
100
+ if (Rt(o)) {
101
101
  if (r.rp.id !== o)
102
- return new x({
102
+ return new R({
103
103
  message: `The RP ID "${r.rp.id}" is invalid for this domain`,
104
104
  code: "ERROR_INVALID_RP_ID",
105
105
  cause: e
106
106
  });
107
- } else return new x({
107
+ } else return new R({
108
108
  message: `${window.location.hostname} is an invalid domain`,
109
109
  code: "ERROR_INVALID_DOMAIN",
110
110
  cause: e
111
111
  });
112
112
  } else if (e.name === "TypeError") {
113
113
  if (r.user.id.byteLength < 1 || r.user.id.byteLength > 64)
114
- return new x({
114
+ return new R({
115
115
  message: "User ID was not between 1 and 64 characters",
116
116
  code: "ERROR_INVALID_USER_ID_LENGTH",
117
117
  cause: e
118
118
  });
119
119
  } else if (e.name === "UnknownError")
120
- return new x({
120
+ return new R({
121
121
  message: "The authenticator was unable to process the specified options, or could not create a new credential",
122
122
  code: "ERROR_AUTHENTICATOR_GENERAL_ERROR",
123
123
  cause: e
@@ -125,7 +125,7 @@ function mr({ error: e, options: t }) {
125
125
  }
126
126
  return e;
127
127
  }
128
- class hr {
128
+ class mr {
129
129
  createNewAbortSignal() {
130
130
  if (this.controller) {
131
131
  const r = new Error("Cancelling existing WebAuthn API call for new one");
@@ -141,14 +141,14 @@ class hr {
141
141
  }
142
142
  }
143
143
  }
144
- const Rt = new hr(), pr = ["cross-platform", "platform"];
145
- function xt(e) {
144
+ const xt = new mr(), pr = ["cross-platform", "platform"];
145
+ function Ct(e) {
146
146
  if (e && !(pr.indexOf(e) < 0))
147
147
  return e;
148
148
  }
149
149
  async function gr(e) {
150
- var m;
151
- if (!Qe())
150
+ var u;
151
+ if (!Ze())
152
152
  throw new Error("WebAuthn is not supported in this browser");
153
153
  const t = { publicKey: {
154
154
  ...e,
@@ -157,32 +157,32 @@ async function gr(e) {
157
157
  ...e.user,
158
158
  id: Ne(e.user.id)
159
159
  },
160
- excludeCredentials: (m = e.excludeCredentials) == null ? void 0 : m.map(kt)
160
+ excludeCredentials: (u = e.excludeCredentials) == null ? void 0 : u.map(Nt)
161
161
  } };
162
- t.signal = Rt.createNewAbortSignal();
162
+ t.signal = xt.createNewAbortSignal();
163
163
  let r;
164
164
  try {
165
165
  r = await navigator.credentials.create(t);
166
166
  } catch (c) {
167
- throw mr({ error: c, options: t });
167
+ throw hr({ error: c, options: t });
168
168
  }
169
169
  if (!r)
170
170
  throw new Error("Registration was not completed");
171
171
  const { id: a, rawId: n, response: o, type: s } = r;
172
172
  let i;
173
173
  typeof o.getTransports == "function" && (i = o.getTransports());
174
- let u;
174
+ let d;
175
175
  if (typeof o.getPublicKeyAlgorithm == "function")
176
176
  try {
177
- u = o.getPublicKeyAlgorithm();
177
+ d = o.getPublicKeyAlgorithm();
178
178
  } catch (c) {
179
179
  Ke("getPublicKeyAlgorithm()", c);
180
180
  }
181
- let h;
181
+ let m;
182
182
  if (typeof o.getPublicKey == "function")
183
183
  try {
184
184
  const c = o.getPublicKey();
185
- c !== null && (h = V(c));
185
+ c !== null && (m = V(c));
186
186
  } catch (c) {
187
187
  Ke("getPublicKey()", c);
188
188
  }
@@ -200,13 +200,13 @@ async function gr(e) {
200
200
  attestationObject: V(o.attestationObject),
201
201
  clientDataJSON: V(o.clientDataJSON),
202
202
  transports: i,
203
- publicKeyAlgorithm: u,
204
- publicKey: h,
203
+ publicKeyAlgorithm: d,
204
+ publicKey: m,
205
205
  authenticatorData: p
206
206
  },
207
207
  type: s,
208
208
  clientExtensionResults: r.getClientExtensionResults(),
209
- authenticatorAttachment: xt(r.authenticatorAttachment)
209
+ authenticatorAttachment: Ct(r.authenticatorAttachment)
210
210
  };
211
211
  }
212
212
  function Ke(e, t) {
@@ -214,7 +214,7 @@ function Ke(e, t) {
214
214
  `, t);
215
215
  }
216
216
  function yr() {
217
- if (!Qe())
217
+ if (!Ze())
218
218
  return new Promise((t) => t(!1));
219
219
  const e = window.PublicKeyCredential;
220
220
  return e.isConditionalMediationAvailable === void 0 ? new Promise((t) => t(!1)) : e.isConditionalMediationAvailable();
@@ -225,34 +225,34 @@ function fr({ error: e, options: t }) {
225
225
  throw Error("options was missing required publicKey property");
226
226
  if (e.name === "AbortError") {
227
227
  if (t.signal instanceof AbortSignal)
228
- return new x({
228
+ return new R({
229
229
  message: "Authentication ceremony was sent an abort signal",
230
230
  code: "ERROR_CEREMONY_ABORTED",
231
231
  cause: e
232
232
  });
233
233
  } else {
234
234
  if (e.name === "NotAllowedError")
235
- return new x({
235
+ return new R({
236
236
  message: e.message,
237
237
  code: "ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",
238
238
  cause: e
239
239
  });
240
240
  if (e.name === "SecurityError") {
241
241
  const a = window.location.hostname;
242
- if (Nt(a)) {
242
+ if (Rt(a)) {
243
243
  if (r.rpId !== a)
244
- return new x({
244
+ return new R({
245
245
  message: `The RP ID "${r.rpId}" is invalid for this domain`,
246
246
  code: "ERROR_INVALID_RP_ID",
247
247
  cause: e
248
248
  });
249
- } else return new x({
249
+ } else return new R({
250
250
  message: `${window.location.hostname} is an invalid domain`,
251
251
  code: "ERROR_INVALID_DOMAIN",
252
252
  cause: e
253
253
  });
254
254
  } else if (e.name === "UnknownError")
255
- return new x({
255
+ return new R({
256
256
  message: "The authenticator was unable to process the specified options, or could not create a new assertion signature",
257
257
  code: "ERROR_AUTHENTICATOR_GENERAL_ERROR",
258
258
  cause: e
@@ -261,11 +261,11 @@ function fr({ error: e, options: t }) {
261
261
  return e;
262
262
  }
263
263
  async function br(e, t = !1) {
264
- var m, c;
265
- if (!Qe())
264
+ var u, c;
265
+ if (!Ze())
266
266
  throw new Error("WebAuthn is not supported in this browser");
267
267
  let r;
268
- ((m = e.allowCredentials) == null ? void 0 : m.length) !== 0 && (r = (c = e.allowCredentials) == null ? void 0 : c.map(kt));
268
+ ((u = e.allowCredentials) == null ? void 0 : u.length) !== 0 && (r = (c = e.allowCredentials) == null ? void 0 : c.map(Nt));
269
269
  const a = {
270
270
  ...e,
271
271
  challenge: Ne(e.challenge),
@@ -278,29 +278,29 @@ async function br(e, t = !1) {
278
278
  throw Error('No <input> with "webauthn" as the only or last value in its `autocomplete` attribute was detected');
279
279
  n.mediation = "conditional", a.allowCredentials = [];
280
280
  }
281
- n.publicKey = a, n.signal = Rt.createNewAbortSignal();
281
+ n.publicKey = a, n.signal = xt.createNewAbortSignal();
282
282
  let o;
283
283
  try {
284
284
  o = await navigator.credentials.get(n);
285
- } catch (d) {
286
- throw fr({ error: d, options: n });
285
+ } catch (h) {
286
+ throw fr({ error: h, options: n });
287
287
  }
288
288
  if (!o)
289
289
  throw new Error("Authentication was not completed");
290
- const { id: s, rawId: i, response: u, type: h } = o;
290
+ const { id: s, rawId: i, response: d, type: m } = o;
291
291
  let p;
292
- return u.userHandle && (p = V(u.userHandle)), {
292
+ return d.userHandle && (p = V(d.userHandle)), {
293
293
  id: s,
294
294
  rawId: V(i),
295
295
  response: {
296
- authenticatorData: V(u.authenticatorData),
297
- clientDataJSON: V(u.clientDataJSON),
298
- signature: V(u.signature),
296
+ authenticatorData: V(d.authenticatorData),
297
+ clientDataJSON: V(d.clientDataJSON),
298
+ signature: V(d.signature),
299
299
  userHandle: p
300
300
  },
301
- type: h,
301
+ type: m,
302
302
  clientExtensionResults: o.getClientExtensionResults(),
303
- authenticatorAttachment: xt(o.authenticatorAttachment)
303
+ authenticatorAttachment: Ct(o.authenticatorAttachment)
304
304
  };
305
305
  }
306
306
  /*!
@@ -323,9 +323,9 @@ const ue = {
323
323
  CODE: "code",
324
324
  REFRESH_TOKEN: "refresh_token",
325
325
  PASSKEY: "passkey"
326
- }, Ct = {
326
+ }, Ot = {
327
327
  CLIENT_ID: "X-Auth-ClientId"
328
- }, k = {
328
+ }, v = {
329
329
  ALG: "RS256",
330
330
  USER_ID_KEY: "sub",
331
331
  USERNAME_KEY: "username",
@@ -351,7 +351,7 @@ awIDAQAB
351
351
  LOGOUT: "logout",
352
352
  LOGIN: "login",
353
353
  REFRESH: "refresh"
354
- }, De = crypto, Ot = (e) => e instanceof CryptoKey, we = new TextEncoder(), be = new TextDecoder();
354
+ }, De = crypto, Pt = (e) => e instanceof CryptoKey, we = new TextEncoder(), be = new TextDecoder();
355
355
  function wr(...e) {
356
356
  const t = e.reduce((n, { length: o }) => n + o, 0), r = new Uint8Array(t);
357
357
  let a = 0;
@@ -359,115 +359,115 @@ function wr(...e) {
359
359
  r.set(n, a), a += n.length;
360
360
  return r;
361
361
  }
362
- const Ir = (e) => {
362
+ const Tr = (e) => {
363
363
  const t = atob(e), r = new Uint8Array(t.length);
364
364
  for (let a = 0; a < t.length; a++)
365
365
  r[a] = t.charCodeAt(a);
366
366
  return r;
367
- }, Q = (e) => {
367
+ }, X = (e) => {
368
368
  let t = e;
369
369
  t instanceof Uint8Array && (t = be.decode(t)), t = t.replace(/-/g, "+").replace(/_/g, "/").replace(/\s/g, "");
370
370
  try {
371
- return Ir(t);
371
+ return Tr(t);
372
372
  } catch {
373
373
  throw new TypeError("The input to be decoded is not correctly encoded.");
374
374
  }
375
375
  };
376
- let O = class extends Error {
376
+ let C = class extends Error {
377
377
  constructor(t, r) {
378
378
  var a;
379
379
  super(t, r), this.code = "ERR_JOSE_GENERIC", this.name = this.constructor.name, (a = Error.captureStackTrace) == null || a.call(Error, this, this.constructor);
380
380
  }
381
381
  };
382
- O.code = "ERR_JOSE_GENERIC";
383
- let M = class extends O {
382
+ C.code = "ERR_JOSE_GENERIC";
383
+ let L = class extends C {
384
384
  constructor(t, r, a = "unspecified", n = "unspecified") {
385
385
  super(t, { cause: { claim: a, reason: n, payload: r } }), this.code = "ERR_JWT_CLAIM_VALIDATION_FAILED", this.claim = a, this.reason = n, this.payload = r;
386
386
  }
387
387
  };
388
- M.code = "ERR_JWT_CLAIM_VALIDATION_FAILED";
389
- class ze extends O {
388
+ L.code = "ERR_JWT_CLAIM_VALIDATION_FAILED";
389
+ class ze extends C {
390
390
  constructor(t, r, a = "unspecified", n = "unspecified") {
391
391
  super(t, { cause: { claim: a, reason: n, payload: r } }), this.code = "ERR_JWT_EXPIRED", this.claim = a, this.reason = n, this.payload = r;
392
392
  }
393
393
  }
394
394
  ze.code = "ERR_JWT_EXPIRED";
395
- class Pt extends O {
395
+ class Dt extends C {
396
396
  constructor() {
397
397
  super(...arguments), this.code = "ERR_JOSE_ALG_NOT_ALLOWED";
398
398
  }
399
399
  }
400
- Pt.code = "ERR_JOSE_ALG_NOT_ALLOWED";
401
- let U = class extends O {
400
+ Dt.code = "ERR_JOSE_ALG_NOT_ALLOWED";
401
+ let M = class extends C {
402
402
  constructor() {
403
403
  super(...arguments), this.code = "ERR_JOSE_NOT_SUPPORTED";
404
404
  }
405
405
  };
406
- U.code = "ERR_JOSE_NOT_SUPPORTED";
407
- class _r extends O {
406
+ M.code = "ERR_JOSE_NOT_SUPPORTED";
407
+ class Ir extends C {
408
408
  constructor(t = "decryption operation failed", r) {
409
409
  super(t, r), this.code = "ERR_JWE_DECRYPTION_FAILED";
410
410
  }
411
411
  }
412
- _r.code = "ERR_JWE_DECRYPTION_FAILED";
413
- class Tr extends O {
412
+ Ir.code = "ERR_JWE_DECRYPTION_FAILED";
413
+ class _r extends C {
414
414
  constructor() {
415
415
  super(...arguments), this.code = "ERR_JWE_INVALID";
416
416
  }
417
417
  }
418
- Tr.code = "ERR_JWE_INVALID";
419
- let S = class extends O {
418
+ _r.code = "ERR_JWE_INVALID";
419
+ let k = class extends C {
420
420
  constructor() {
421
421
  super(...arguments), this.code = "ERR_JWS_INVALID";
422
422
  }
423
423
  };
424
- S.code = "ERR_JWS_INVALID";
425
- let W = class extends O {
424
+ k.code = "ERR_JWS_INVALID";
425
+ let J = class extends C {
426
426
  constructor() {
427
427
  super(...arguments), this.code = "ERR_JWT_INVALID";
428
428
  }
429
429
  };
430
- W.code = "ERR_JWT_INVALID";
431
- class Sr extends O {
430
+ J.code = "ERR_JWT_INVALID";
431
+ class kr extends C {
432
432
  constructor() {
433
433
  super(...arguments), this.code = "ERR_JWK_INVALID";
434
434
  }
435
435
  }
436
- Sr.code = "ERR_JWK_INVALID";
437
- class vr extends O {
436
+ kr.code = "ERR_JWK_INVALID";
437
+ class Sr extends C {
438
438
  constructor() {
439
439
  super(...arguments), this.code = "ERR_JWKS_INVALID";
440
440
  }
441
441
  }
442
- vr.code = "ERR_JWKS_INVALID";
443
- class Ar extends O {
442
+ Sr.code = "ERR_JWKS_INVALID";
443
+ class Ar extends C {
444
444
  constructor(t = "no applicable key found in the JSON Web Key Set", r) {
445
445
  super(t, r), this.code = "ERR_JWKS_NO_MATCHING_KEY";
446
446
  }
447
447
  }
448
448
  Ar.code = "ERR_JWKS_NO_MATCHING_KEY";
449
- class kr extends O {
449
+ class vr extends C {
450
450
  constructor(t = "multiple matching keys found in the JSON Web Key Set", r) {
451
451
  super(t, r), this.code = "ERR_JWKS_MULTIPLE_MATCHING_KEYS";
452
452
  }
453
453
  }
454
- kr.code = "ERR_JWKS_MULTIPLE_MATCHING_KEYS";
455
- class Nr extends O {
454
+ vr.code = "ERR_JWKS_MULTIPLE_MATCHING_KEYS";
455
+ class Nr extends C {
456
456
  constructor(t = "request timed out", r) {
457
457
  super(t, r), this.code = "ERR_JWKS_TIMEOUT";
458
458
  }
459
459
  }
460
460
  Nr.code = "ERR_JWKS_TIMEOUT";
461
- class Dt extends O {
461
+ class Lt extends C {
462
462
  constructor(t = "signature verification failed", r) {
463
463
  super(t, r), this.code = "ERR_JWS_SIGNATURE_VERIFICATION_FAILED";
464
464
  }
465
465
  }
466
- Dt.code = "ERR_JWS_SIGNATURE_VERIFICATION_FAILED";
466
+ Lt.code = "ERR_JWS_SIGNATURE_VERIFICATION_FAILED";
467
467
  function F(e, t = "algorithm.name") {
468
468
  return new TypeError(`CryptoKey does not support this operation, its ${t} must be ${e}`);
469
469
  }
470
- function Ie(e, t) {
470
+ function Te(e, t) {
471
471
  return e.name === t;
472
472
  }
473
473
  function He(e) {
@@ -500,7 +500,7 @@ function Cr(e, t, ...r) {
500
500
  case "HS256":
501
501
  case "HS384":
502
502
  case "HS512": {
503
- if (!Ie(e.algorithm, "HMAC"))
503
+ if (!Te(e.algorithm, "HMAC"))
504
504
  throw F("HMAC");
505
505
  const a = parseInt(t.slice(2), 10);
506
506
  if (He(e.algorithm.hash) !== a)
@@ -510,7 +510,7 @@ function Cr(e, t, ...r) {
510
510
  case "RS256":
511
511
  case "RS384":
512
512
  case "RS512": {
513
- if (!Ie(e.algorithm, "RSASSA-PKCS1-v1_5"))
513
+ if (!Te(e.algorithm, "RSASSA-PKCS1-v1_5"))
514
514
  throw F("RSASSA-PKCS1-v1_5");
515
515
  const a = parseInt(t.slice(2), 10);
516
516
  if (He(e.algorithm.hash) !== a)
@@ -520,7 +520,7 @@ function Cr(e, t, ...r) {
520
520
  case "PS256":
521
521
  case "PS384":
522
522
  case "PS512": {
523
- if (!Ie(e.algorithm, "RSA-PSS"))
523
+ if (!Te(e.algorithm, "RSA-PSS"))
524
524
  throw F("RSA-PSS");
525
525
  const a = parseInt(t.slice(2), 10);
526
526
  if (He(e.algorithm.hash) !== a)
@@ -535,7 +535,7 @@ function Cr(e, t, ...r) {
535
535
  case "ES256":
536
536
  case "ES384":
537
537
  case "ES512": {
538
- if (!Ie(e.algorithm, "ECDSA"))
538
+ if (!Te(e.algorithm, "ECDSA"))
539
539
  throw F("ECDSA");
540
540
  const a = Rr(t);
541
541
  if (e.algorithm.namedCurve !== a)
@@ -547,7 +547,7 @@ function Cr(e, t, ...r) {
547
547
  }
548
548
  xr(e, r);
549
549
  }
550
- function $t(e, t, ...r) {
550
+ function Mt(e, t, ...r) {
551
551
  var a;
552
552
  if (r = r.filter(Boolean), r.length > 2) {
553
553
  const n = r.pop();
@@ -555,11 +555,11 @@ function $t(e, t, ...r) {
555
555
  } else r.length === 2 ? e += `one of type ${r[0]} or ${r[1]}.` : e += `of type ${r[0]}.`;
556
556
  return t == null ? e += ` Received ${t}` : typeof t == "function" && t.name ? e += ` Received function ${t.name}` : typeof t == "object" && t != null && (a = t.constructor) != null && a.name && (e += ` Received an instance of ${t.constructor.name}`), e;
557
557
  }
558
- const it = (e, ...t) => $t("Key must be ", e, ...t);
559
- function Lt(e, t, ...r) {
560
- return $t(`Key for the ${e} algorithm must be `, t, ...r);
558
+ const ct = (e, ...t) => Mt("Key must be ", e, ...t);
559
+ function $t(e, t, ...r) {
560
+ return Mt(`Key for the ${e} algorithm must be `, t, ...r);
561
561
  }
562
- const Mt = (e) => Ot(e) ? !0 : (e == null ? void 0 : e[Symbol.toStringTag]) === "KeyObject", Re = ["CryptoKey"], Or = (...e) => {
562
+ const Ut = (e) => Pt(e) ? !0 : (e == null ? void 0 : e[Symbol.toStringTag]) === "KeyObject", Re = ["CryptoKey"], Or = (...e) => {
563
563
  const t = e.filter(Boolean);
564
564
  if (t.length === 0 || t.length === 1)
565
565
  return !0;
@@ -581,7 +581,7 @@ const Mt = (e) => Ot(e) ? !0 : (e == null ? void 0 : e[Symbol.toStringTag]) ===
581
581
  function Pr(e) {
582
582
  return typeof e == "object" && e !== null;
583
583
  }
584
- function me(e) {
584
+ function he(e) {
585
585
  if (!Pr(e) || Object.prototype.toString.call(e) !== "[object Object]")
586
586
  return !1;
587
587
  if (Object.getPrototypeOf(e) === null)
@@ -598,17 +598,17 @@ const Dr = (e, t) => {
598
598
  throw new TypeError(`${e} requires key modulusLength to be 2048 bits or larger`);
599
599
  }
600
600
  };
601
- function he(e) {
602
- return me(e) && typeof e.kty == "string";
601
+ function me(e) {
602
+ return he(e) && typeof e.kty == "string";
603
603
  }
604
- function $r(e) {
604
+ function Lr(e) {
605
605
  return e.kty !== "oct" && typeof e.d == "string";
606
606
  }
607
- function Lr(e) {
607
+ function Mr(e) {
608
608
  return e.kty !== "oct" && typeof e.d > "u";
609
609
  }
610
- function Mr(e) {
611
- return he(e) && e.kty === "oct" && typeof e.k == "string";
610
+ function $r(e) {
611
+ return me(e) && e.kty === "oct" && typeof e.k == "string";
612
612
  }
613
613
  function Ur(e) {
614
614
  let t, r;
@@ -635,7 +635,7 @@ function Ur(e) {
635
635
  }, r = e.d ? ["decrypt", "unwrapKey"] : ["encrypt", "wrapKey"];
636
636
  break;
637
637
  default:
638
- throw new U('Invalid or unsupported JWK "alg" (Algorithm) Parameter value');
638
+ throw new M('Invalid or unsupported JWK "alg" (Algorithm) Parameter value');
639
639
  }
640
640
  break;
641
641
  }
@@ -657,7 +657,7 @@ function Ur(e) {
657
657
  t = { name: "ECDH", namedCurve: e.crv }, r = e.d ? ["deriveBits"] : [];
658
658
  break;
659
659
  default:
660
- throw new U('Invalid or unsupported JWK "alg" (Algorithm) Parameter value');
660
+ throw new M('Invalid or unsupported JWK "alg" (Algorithm) Parameter value');
661
661
  }
662
662
  break;
663
663
  }
@@ -673,16 +673,16 @@ function Ur(e) {
673
673
  t = { name: e.crv }, r = e.d ? ["deriveBits"] : [];
674
674
  break;
675
675
  default:
676
- throw new U('Invalid or unsupported JWK "alg" (Algorithm) Parameter value');
676
+ throw new M('Invalid or unsupported JWK "alg" (Algorithm) Parameter value');
677
677
  }
678
678
  break;
679
679
  }
680
680
  default:
681
- throw new U('Invalid or unsupported JWK "kty" (Key Type) Parameter value');
681
+ throw new M('Invalid or unsupported JWK "kty" (Key Type) Parameter value');
682
682
  }
683
683
  return { algorithm: t, keyUsages: r };
684
684
  }
685
- const Ut = async (e) => {
685
+ const Kt = async (e) => {
686
686
  if (!e.alg)
687
687
  throw new TypeError('"alg" argument is required when "jwk.alg" is not present');
688
688
  const { algorithm: t, keyUsages: r } = Ur(e), a = [
@@ -691,55 +691,55 @@ const Ut = async (e) => {
691
691
  e.key_ops ?? r
692
692
  ], n = { ...e };
693
693
  return delete n.alg, delete n.use, De.subtle.importKey("jwk", n, ...a);
694
- }, Kt = (e) => Q(e);
694
+ }, Ht = (e) => X(e);
695
695
  let ae, ne;
696
- const Ht = (e) => (e == null ? void 0 : e[Symbol.toStringTag]) === "KeyObject", xe = async (e, t, r, a, n = !1) => {
696
+ const Wt = (e) => (e == null ? void 0 : e[Symbol.toStringTag]) === "KeyObject", xe = async (e, t, r, a, n = !1) => {
697
697
  let o = e.get(t);
698
698
  if (o != null && o[a])
699
699
  return o[a];
700
- const s = await Ut({ ...r, alg: a });
700
+ const s = await Kt({ ...r, alg: a });
701
701
  return n && Object.freeze(t), o ? o[a] = s : e.set(t, { [a]: s }), s;
702
702
  }, Kr = (e, t) => {
703
- if (Ht(e)) {
703
+ if (Wt(e)) {
704
704
  let r = e.export({ format: "jwk" });
705
- return delete r.d, delete r.dp, delete r.dq, delete r.p, delete r.q, delete r.qi, r.k ? Kt(r.k) : (ne || (ne = /* @__PURE__ */ new WeakMap()), xe(ne, e, r, t));
705
+ return delete r.d, delete r.dp, delete r.dq, delete r.p, delete r.q, delete r.qi, r.k ? Ht(r.k) : (ne || (ne = /* @__PURE__ */ new WeakMap()), xe(ne, e, r, t));
706
706
  }
707
- return he(e) ? e.k ? Q(e.k) : (ne || (ne = /* @__PURE__ */ new WeakMap()), xe(ne, e, e, t, !0)) : e;
707
+ return me(e) ? e.k ? X(e.k) : (ne || (ne = /* @__PURE__ */ new WeakMap()), xe(ne, e, e, t, !0)) : e;
708
708
  }, Hr = (e, t) => {
709
- if (Ht(e)) {
709
+ if (Wt(e)) {
710
710
  let r = e.export({ format: "jwk" });
711
- return r.k ? Kt(r.k) : (ae || (ae = /* @__PURE__ */ new WeakMap()), xe(ae, e, r, t));
711
+ return r.k ? Ht(r.k) : (ae || (ae = /* @__PURE__ */ new WeakMap()), xe(ae, e, r, t));
712
712
  }
713
- return he(e) ? e.k ? Q(e.k) : (ae || (ae = /* @__PURE__ */ new WeakMap()), xe(ae, e, e, t, !0)) : e;
714
- }, Gr = { normalizePublicKey: Kr, normalizePrivateKey: Hr }, j = (e, t, r = 0) => {
713
+ return me(e) ? e.k ? X(e.k) : (ae || (ae = /* @__PURE__ */ new WeakMap()), xe(ae, e, e, t, !0)) : e;
714
+ }, Wr = { normalizePublicKey: Kr, normalizePrivateKey: Hr }, z = (e, t, r = 0) => {
715
715
  r === 0 && (t.unshift(t.length), t.unshift(6));
716
716
  const a = e.indexOf(t[0], r);
717
717
  if (a === -1)
718
718
  return !1;
719
719
  const n = e.subarray(a, a + t.length);
720
- return n.length !== t.length ? !1 : n.every((o, s) => o === t[s]) || j(e, t, a + 1);
721
- }, ct = (e) => {
720
+ return n.length !== t.length ? !1 : n.every((o, s) => o === t[s]) || z(e, t, a + 1);
721
+ }, lt = (e) => {
722
722
  switch (!0) {
723
- case j(e, [42, 134, 72, 206, 61, 3, 1, 7]):
723
+ case z(e, [42, 134, 72, 206, 61, 3, 1, 7]):
724
724
  return "P-256";
725
- case j(e, [43, 129, 4, 0, 34]):
725
+ case z(e, [43, 129, 4, 0, 34]):
726
726
  return "P-384";
727
- case j(e, [43, 129, 4, 0, 35]):
727
+ case z(e, [43, 129, 4, 0, 35]):
728
728
  return "P-521";
729
- case j(e, [43, 101, 110]):
729
+ case z(e, [43, 101, 110]):
730
730
  return "X25519";
731
- case j(e, [43, 101, 111]):
731
+ case z(e, [43, 101, 111]):
732
732
  return "X448";
733
- case j(e, [43, 101, 112]):
733
+ case z(e, [43, 101, 112]):
734
734
  return "Ed25519";
735
- case j(e, [43, 101, 113]):
735
+ case z(e, [43, 101, 113]):
736
736
  return "Ed448";
737
737
  default:
738
- throw new U("Invalid or unsupported EC Key Curve or OKP Key Sub Type");
738
+ throw new M("Invalid or unsupported EC Key Curve or OKP Key Sub Type");
739
739
  }
740
- }, Wr = async (e, t, r, a, n) => {
740
+ }, Gr = async (e, t, r, a, n) => {
741
741
  let o, s;
742
- const i = new Uint8Array(atob(r.replace(e, "")).split("").map((u) => u.charCodeAt(0)));
742
+ const i = new Uint8Array(atob(r.replace(e, "")).split("").map((d) => d.charCodeAt(0)));
743
743
  switch (a) {
744
744
  case "PS256":
745
745
  case "PS384":
@@ -773,39 +773,39 @@ const Ht = (e) => (e == null ? void 0 : e[Symbol.toStringTag]) === "KeyObject",
773
773
  case "ECDH-ES+A128KW":
774
774
  case "ECDH-ES+A192KW":
775
775
  case "ECDH-ES+A256KW": {
776
- const u = ct(i);
777
- o = u.startsWith("P-") ? { name: "ECDH", namedCurve: u } : { name: u }, s = [];
776
+ const d = lt(i);
777
+ o = d.startsWith("P-") ? { name: "ECDH", namedCurve: d } : { name: d }, s = [];
778
778
  break;
779
779
  }
780
780
  case "EdDSA":
781
- o = { name: ct(i) }, s = ["verify"];
781
+ o = { name: lt(i) }, s = ["verify"];
782
782
  break;
783
783
  default:
784
- throw new U('Invalid or unsupported "alg" (Algorithm) value');
784
+ throw new M('Invalid or unsupported "alg" (Algorithm) value');
785
785
  }
786
786
  return De.subtle.importKey(t, i, o, !1, s);
787
- }, Vr = (e, t, r) => Wr(/(?:-----(?:BEGIN|END) PUBLIC KEY-----|\s)/g, "spki", e, t);
788
- async function Br(e, t, r) {
787
+ }, Br = (e, t, r) => Gr(/(?:-----(?:BEGIN|END) PUBLIC KEY-----|\s)/g, "spki", e, t);
788
+ async function Jr(e, t, r) {
789
789
  if (e.indexOf("-----BEGIN PUBLIC KEY-----") !== 0)
790
790
  throw new TypeError('"spki" must be SPKI formatted string');
791
- return Vr(e, t);
791
+ return Br(e, t);
792
792
  }
793
- async function Jr(e, t) {
794
- if (!me(e))
793
+ async function Vr(e, t) {
794
+ if (!he(e))
795
795
  throw new TypeError("JWK must be an object");
796
796
  switch (t || (t = e.alg), e.kty) {
797
797
  case "oct":
798
798
  if (typeof e.k != "string" || !e.k)
799
799
  throw new TypeError('missing "k" (Key Value) Parameter value');
800
- return Q(e.k);
800
+ return X(e.k);
801
801
  case "RSA":
802
802
  if (e.oth !== void 0)
803
- throw new U('RSA JWK "oth" (Other Primes Info) Parameter value is not supported');
803
+ throw new M('RSA JWK "oth" (Other Primes Info) Parameter value is not supported');
804
804
  case "EC":
805
805
  case "OKP":
806
- return Ut({ ...e, alg: t });
806
+ return Kt({ ...e, alg: t });
807
807
  default:
808
- throw new U('Unsupported "kty" (Key Type) Parameter value');
808
+ throw new M('Unsupported "kty" (Key Type) Parameter value');
809
809
  }
810
810
  }
811
811
  const de = (e) => e == null ? void 0 : e[Symbol.toStringTag], je = (e, t, r) => {
@@ -819,30 +819,30 @@ const de = (e) => e == null ? void 0 : e[Symbol.toStringTag], je = (e, t, r) =>
819
819
  return !0;
820
820
  }, Yr = (e, t, r, a) => {
821
821
  if (!(t instanceof Uint8Array)) {
822
- if (a && he(t)) {
823
- if (Mr(t) && je(e, t, r))
822
+ if (a && me(t)) {
823
+ if ($r(t) && je(e, t, r))
824
824
  return;
825
825
  throw new TypeError('JSON Web Key for symmetric algorithms must have JWK "kty" (Key Type) equal to "oct" and the JWK "k" (Key Value) present');
826
826
  }
827
- if (!Mt(t))
828
- throw new TypeError(Lt(e, t, ...Re, "Uint8Array", a ? "JSON Web Key" : null));
827
+ if (!Ut(t))
828
+ throw new TypeError($t(e, t, ...Re, "Uint8Array", a ? "JSON Web Key" : null));
829
829
  if (t.type !== "secret")
830
830
  throw new TypeError(`${de(t)} instances for symmetric algorithms must be of type "secret"`);
831
831
  }
832
832
  }, Fr = (e, t, r, a) => {
833
- if (a && he(t))
833
+ if (a && me(t))
834
834
  switch (r) {
835
835
  case "sign":
836
- if ($r(t) && je(e, t, r))
836
+ if (Lr(t) && je(e, t, r))
837
837
  return;
838
838
  throw new TypeError("JSON Web Key for this operation be a private JWK");
839
839
  case "verify":
840
- if (Lr(t) && je(e, t, r))
840
+ if (Mr(t) && je(e, t, r))
841
841
  return;
842
842
  throw new TypeError("JSON Web Key for this operation be a public JWK");
843
843
  }
844
- if (!Mt(t))
845
- throw new TypeError(Lt(e, t, ...Re, a ? "JSON Web Key" : null));
844
+ if (!Ut(t))
845
+ throw new TypeError($t(e, t, ...Re, a ? "JSON Web Key" : null));
846
846
  if (t.type === "secret")
847
847
  throw new TypeError(`${de(t)} instances for asymmetric algorithms must not be of type "secret"`);
848
848
  if (r === "sign" && t.type === "public")
@@ -858,7 +858,7 @@ function Gt(e, t, r, a) {
858
858
  t.startsWith("HS") || t === "dir" || t.startsWith("PBES2") || /^A\d{3}(?:GCM)?KW$/.test(t) ? Yr(t, r, a, e) : Fr(t, r, a, e);
859
859
  }
860
860
  Gt.bind(void 0, !1);
861
- const lt = Gt.bind(void 0, !0);
861
+ const dt = Gt.bind(void 0, !0);
862
862
  function zr(e, t, r, a, n) {
863
863
  if (n.crit !== void 0 && (a == null ? void 0 : a.crit) === void 0)
864
864
  throw new e('"crit" (Critical) Header Parameter MUST be integrity protected');
@@ -870,7 +870,7 @@ function zr(e, t, r, a, n) {
870
870
  r !== void 0 ? o = new Map([...Object.entries(r), ...t.entries()]) : o = t;
871
871
  for (const s of a.crit) {
872
872
  if (!o.has(s))
873
- throw new U(`Extension Header Parameter "${s}" is not recognized`);
873
+ throw new M(`Extension Header Parameter "${s}" is not recognized`);
874
874
  if (n[s] === void 0)
875
875
  throw new e(`Extension Header Parameter "${s}" is missing`);
876
876
  if (o.get(s) && a[s] === void 0)
@@ -906,18 +906,18 @@ function qr(e, t) {
906
906
  case "EdDSA":
907
907
  return { name: t.name };
908
908
  default:
909
- throw new U(`alg ${e} is not supported either by JOSE or your javascript runtime`);
909
+ throw new M(`alg ${e} is not supported either by JOSE or your javascript runtime`);
910
910
  }
911
911
  }
912
912
  async function Xr(e, t, r) {
913
- if (t = await Gr.normalizePublicKey(t, e), Ot(t))
913
+ if (t = await Wr.normalizePublicKey(t, e), Pt(t))
914
914
  return Cr(t, e, r), t;
915
915
  if (t instanceof Uint8Array) {
916
916
  if (!e.startsWith("HS"))
917
- throw new TypeError(it(t, ...Re));
917
+ throw new TypeError(ct(t, ...Re));
918
918
  return De.subtle.importKey("raw", t, { hash: `SHA-${e.slice(-3)}`, name: "HMAC" }, !1, [r]);
919
919
  }
920
- throw new TypeError(it(t, ...Re, "Uint8Array", "JSON Web Key"));
920
+ throw new TypeError(ct(t, ...Re, "Uint8Array", "JSON Web Key"));
921
921
  }
922
922
  const Qr = async (e, t, r, a) => {
923
923
  const n = await Xr(e, t, "verify");
@@ -930,78 +930,78 @@ const Qr = async (e, t, r, a) => {
930
930
  }
931
931
  };
932
932
  async function Zr(e, t, r) {
933
- if (!me(e))
934
- throw new S("Flattened JWS must be an object");
933
+ if (!he(e))
934
+ throw new k("Flattened JWS must be an object");
935
935
  if (e.protected === void 0 && e.header === void 0)
936
- throw new S('Flattened JWS must have either of the "protected" or "header" members');
936
+ throw new k('Flattened JWS must have either of the "protected" or "header" members');
937
937
  if (e.protected !== void 0 && typeof e.protected != "string")
938
- throw new S("JWS Protected Header incorrect type");
938
+ throw new k("JWS Protected Header incorrect type");
939
939
  if (e.payload === void 0)
940
- throw new S("JWS Payload missing");
940
+ throw new k("JWS Payload missing");
941
941
  if (typeof e.signature != "string")
942
- throw new S("JWS Signature missing or incorrect type");
943
- if (e.header !== void 0 && !me(e.header))
944
- throw new S("JWS Unprotected Header incorrect type");
942
+ throw new k("JWS Signature missing or incorrect type");
943
+ if (e.header !== void 0 && !he(e.header))
944
+ throw new k("JWS Unprotected Header incorrect type");
945
945
  let a = {};
946
946
  if (e.protected)
947
947
  try {
948
- const f = Q(e.protected);
948
+ const f = X(e.protected);
949
949
  a = JSON.parse(be.decode(f));
950
950
  } catch {
951
- throw new S("JWS Protected Header is invalid");
951
+ throw new k("JWS Protected Header is invalid");
952
952
  }
953
953
  if (!Or(a, e.header))
954
- throw new S("JWS Protected and JWS Unprotected Header Parameter names must be disjoint");
954
+ throw new k("JWS Protected and JWS Unprotected Header Parameter names must be disjoint");
955
955
  const n = {
956
956
  ...a,
957
957
  ...e.header
958
- }, o = zr(S, /* @__PURE__ */ new Map([["b64", !0]]), r == null ? void 0 : r.crit, a, n);
958
+ }, o = zr(k, /* @__PURE__ */ new Map([["b64", !0]]), r == null ? void 0 : r.crit, a, n);
959
959
  let s = !0;
960
960
  if (o.has("b64") && (s = a.b64, typeof s != "boolean"))
961
- throw new S('The "b64" (base64url-encode payload) Header Parameter must be a boolean');
961
+ throw new k('The "b64" (base64url-encode payload) Header Parameter must be a boolean');
962
962
  const { alg: i } = n;
963
963
  if (typeof i != "string" || !i)
964
- throw new S('JWS "alg" (Algorithm) Header Parameter missing or invalid');
965
- const u = jr("algorithms", r.algorithms);
966
- if (u && !u.has(i))
967
- throw new Pt('"alg" (Algorithm) Header Parameter value not allowed');
964
+ throw new k('JWS "alg" (Algorithm) Header Parameter missing or invalid');
965
+ const d = jr("algorithms", r.algorithms);
966
+ if (d && !d.has(i))
967
+ throw new Dt('"alg" (Algorithm) Header Parameter value not allowed');
968
968
  if (s) {
969
969
  if (typeof e.payload != "string")
970
- throw new S("JWS Payload must be a string");
970
+ throw new k("JWS Payload must be a string");
971
971
  } else if (typeof e.payload != "string" && !(e.payload instanceof Uint8Array))
972
- throw new S("JWS Payload must be a string or an Uint8Array instance");
973
- let h = !1;
974
- typeof t == "function" ? (t = await t(a, e), h = !0, lt(i, t, "verify"), he(t) && (t = await Jr(t, i))) : lt(i, t, "verify");
972
+ throw new k("JWS Payload must be a string or an Uint8Array instance");
973
+ let m = !1;
974
+ typeof t == "function" ? (t = await t(a, e), m = !0, dt(i, t, "verify"), me(t) && (t = await Vr(t, i))) : dt(i, t, "verify");
975
975
  const p = wr(we.encode(e.protected ?? ""), we.encode("."), typeof e.payload == "string" ? we.encode(e.payload) : e.payload);
976
- let m;
976
+ let u;
977
977
  try {
978
- m = Q(e.signature);
978
+ u = X(e.signature);
979
979
  } catch {
980
- throw new S("Failed to base64url decode the signature");
980
+ throw new k("Failed to base64url decode the signature");
981
981
  }
982
- if (!await Qr(i, t, m, p))
983
- throw new Dt();
982
+ if (!await Qr(i, t, u, p))
983
+ throw new Lt();
984
984
  let c;
985
985
  if (s)
986
986
  try {
987
- c = Q(e.payload);
987
+ c = X(e.payload);
988
988
  } catch {
989
- throw new S("Failed to base64url decode the payload");
989
+ throw new k("Failed to base64url decode the payload");
990
990
  }
991
991
  else typeof e.payload == "string" ? c = we.encode(e.payload) : c = e.payload;
992
- const d = { payload: c };
993
- return e.protected !== void 0 && (d.protectedHeader = a), e.header !== void 0 && (d.unprotectedHeader = e.header), h ? { ...d, key: t } : d;
992
+ const h = { payload: c };
993
+ return e.protected !== void 0 && (h.protectedHeader = a), e.header !== void 0 && (h.unprotectedHeader = e.header), m ? { ...h, key: t } : h;
994
994
  }
995
995
  async function ea(e, t, r) {
996
996
  if (e instanceof Uint8Array && (e = be.decode(e)), typeof e != "string")
997
- throw new S("Compact JWS must be a string or Uint8Array");
997
+ throw new k("Compact JWS must be a string or Uint8Array");
998
998
  const { 0: a, 1: n, 2: o, length: s } = e.split(".");
999
999
  if (s !== 3)
1000
- throw new S("Invalid Compact JWS");
1001
- const i = await Zr({ payload: n, protected: a, signature: o }, t, r), u = { payload: i.payload, protectedHeader: i.protectedHeader };
1002
- return typeof t == "function" ? { ...u, key: i.key } : u;
1000
+ throw new k("Invalid Compact JWS");
1001
+ const i = await Zr({ payload: n, protected: a, signature: o }, t, r), d = { payload: i.payload, protectedHeader: i.protectedHeader };
1002
+ return typeof t == "function" ? { ...d, key: i.key } : d;
1003
1003
  }
1004
- const ta = (e) => Math.floor(e.getTime() / 1e3), Wt = 60, Vt = Wt * 60, Ze = Vt * 24, ra = Ze * 7, aa = Ze * 365.25, na = /^(\+|\-)? ?(\d+|\d+\.\d+) ?(seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)(?: (ago|from now))?$/i, dt = (e) => {
1004
+ const ta = (e) => Math.floor(e.getTime() / 1e3), Bt = 60, Jt = Bt * 60, et = Jt * 24, ra = et * 7, aa = et * 365.25, na = /^(\+|\-)? ?(\d+|\d+\.\d+) ?(seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)(?: (ago|from now))?$/i, ut = (e) => {
1005
1005
  const t = na.exec(e);
1006
1006
  if (!t || t[4] && t[1])
1007
1007
  throw new TypeError("Invalid time period format");
@@ -1020,19 +1020,19 @@ const ta = (e) => Math.floor(e.getTime() / 1e3), Wt = 60, Vt = Wt * 60, Ze = Vt
1020
1020
  case "min":
1021
1021
  case "mins":
1022
1022
  case "m":
1023
- n = Math.round(r * Wt);
1023
+ n = Math.round(r * Bt);
1024
1024
  break;
1025
1025
  case "hour":
1026
1026
  case "hours":
1027
1027
  case "hr":
1028
1028
  case "hrs":
1029
1029
  case "h":
1030
- n = Math.round(r * Vt);
1030
+ n = Math.round(r * Jt);
1031
1031
  break;
1032
1032
  case "day":
1033
1033
  case "days":
1034
1034
  case "d":
1035
- n = Math.round(r * Ze);
1035
+ n = Math.round(r * et);
1036
1036
  break;
1037
1037
  case "week":
1038
1038
  case "weeks":
@@ -1044,63 +1044,63 @@ const ta = (e) => Math.floor(e.getTime() / 1e3), Wt = 60, Vt = Wt * 60, Ze = Vt
1044
1044
  break;
1045
1045
  }
1046
1046
  return t[1] === "-" || t[4] === "ago" ? -n : n;
1047
- }, ut = (e) => e.toLowerCase().replace(/^application\//, ""), oa = (e, t) => typeof e == "string" ? t.includes(e) : Array.isArray(e) ? t.some(Set.prototype.has.bind(new Set(e))) : !1, sa = (e, t, r = {}) => {
1047
+ }, ht = (e) => e.toLowerCase().replace(/^application\//, ""), oa = (e, t) => typeof e == "string" ? t.includes(e) : Array.isArray(e) ? t.some(Set.prototype.has.bind(new Set(e))) : !1, sa = (e, t, r = {}) => {
1048
1048
  let a;
1049
1049
  try {
1050
1050
  a = JSON.parse(be.decode(t));
1051
1051
  } catch {
1052
1052
  }
1053
- if (!me(a))
1054
- throw new W("JWT Claims Set must be a top-level JSON object");
1053
+ if (!he(a))
1054
+ throw new J("JWT Claims Set must be a top-level JSON object");
1055
1055
  const { typ: n } = r;
1056
- if (n && (typeof e.typ != "string" || ut(e.typ) !== ut(n)))
1057
- throw new M('unexpected "typ" JWT header value', a, "typ", "check_failed");
1058
- const { requiredClaims: o = [], issuer: s, subject: i, audience: u, maxTokenAge: h } = r, p = [...o];
1059
- h !== void 0 && p.push("iat"), u !== void 0 && p.push("aud"), i !== void 0 && p.push("sub"), s !== void 0 && p.push("iss");
1056
+ if (n && (typeof e.typ != "string" || ht(e.typ) !== ht(n)))
1057
+ throw new L('unexpected "typ" JWT header value', a, "typ", "check_failed");
1058
+ const { requiredClaims: o = [], issuer: s, subject: i, audience: d, maxTokenAge: m } = r, p = [...o];
1059
+ m !== void 0 && p.push("iat"), d !== void 0 && p.push("aud"), i !== void 0 && p.push("sub"), s !== void 0 && p.push("iss");
1060
1060
  for (const f of new Set(p.reverse()))
1061
1061
  if (!(f in a))
1062
- throw new M(`missing required "${f}" claim`, a, f, "missing");
1062
+ throw new L(`missing required "${f}" claim`, a, f, "missing");
1063
1063
  if (s && !(Array.isArray(s) ? s : [s]).includes(a.iss))
1064
- throw new M('unexpected "iss" claim value', a, "iss", "check_failed");
1064
+ throw new L('unexpected "iss" claim value', a, "iss", "check_failed");
1065
1065
  if (i && a.sub !== i)
1066
- throw new M('unexpected "sub" claim value', a, "sub", "check_failed");
1067
- if (u && !oa(a.aud, typeof u == "string" ? [u] : u))
1068
- throw new M('unexpected "aud" claim value', a, "aud", "check_failed");
1069
- let m;
1066
+ throw new L('unexpected "sub" claim value', a, "sub", "check_failed");
1067
+ if (d && !oa(a.aud, typeof d == "string" ? [d] : d))
1068
+ throw new L('unexpected "aud" claim value', a, "aud", "check_failed");
1069
+ let u;
1070
1070
  switch (typeof r.clockTolerance) {
1071
1071
  case "string":
1072
- m = dt(r.clockTolerance);
1072
+ u = ut(r.clockTolerance);
1073
1073
  break;
1074
1074
  case "number":
1075
- m = r.clockTolerance;
1075
+ u = r.clockTolerance;
1076
1076
  break;
1077
1077
  case "undefined":
1078
- m = 0;
1078
+ u = 0;
1079
1079
  break;
1080
1080
  default:
1081
1081
  throw new TypeError("Invalid clockTolerance option type");
1082
1082
  }
1083
- const { currentDate: c } = r, d = ta(c || /* @__PURE__ */ new Date());
1084
- if ((a.iat !== void 0 || h) && typeof a.iat != "number")
1085
- throw new M('"iat" claim must be a number', a, "iat", "invalid");
1083
+ const { currentDate: c } = r, h = ta(c || /* @__PURE__ */ new Date());
1084
+ if ((a.iat !== void 0 || m) && typeof a.iat != "number")
1085
+ throw new L('"iat" claim must be a number', a, "iat", "invalid");
1086
1086
  if (a.nbf !== void 0) {
1087
1087
  if (typeof a.nbf != "number")
1088
- throw new M('"nbf" claim must be a number', a, "nbf", "invalid");
1089
- if (a.nbf > d + m)
1090
- throw new M('"nbf" claim timestamp check failed', a, "nbf", "check_failed");
1088
+ throw new L('"nbf" claim must be a number', a, "nbf", "invalid");
1089
+ if (a.nbf > h + u)
1090
+ throw new L('"nbf" claim timestamp check failed', a, "nbf", "check_failed");
1091
1091
  }
1092
1092
  if (a.exp !== void 0) {
1093
1093
  if (typeof a.exp != "number")
1094
- throw new M('"exp" claim must be a number', a, "exp", "invalid");
1095
- if (a.exp <= d - m)
1094
+ throw new L('"exp" claim must be a number', a, "exp", "invalid");
1095
+ if (a.exp <= h - u)
1096
1096
  throw new ze('"exp" claim timestamp check failed', a, "exp", "check_failed");
1097
1097
  }
1098
- if (h) {
1099
- const f = d - a.iat, b = typeof h == "number" ? h : dt(h);
1100
- if (f - m > b)
1098
+ if (m) {
1099
+ const f = h - a.iat, E = typeof m == "number" ? m : ut(m);
1100
+ if (f - u > E)
1101
1101
  throw new ze('"iat" claim timestamp check failed (too far in the past)', a, "iat", "check_failed");
1102
- if (f < 0 - m)
1103
- throw new M('"iat" claim timestamp check failed (it should be in the past)', a, "iat", "check_failed");
1102
+ if (f < 0 - u)
1103
+ throw new L('"iat" claim timestamp check failed (it should be in the past)', a, "iat", "check_failed");
1104
1104
  }
1105
1105
  return a;
1106
1106
  };
@@ -1108,42 +1108,42 @@ async function ia(e, t, r) {
1108
1108
  var a;
1109
1109
  const n = await ea(e, t, r);
1110
1110
  if ((a = n.protectedHeader.crit) != null && a.includes("b64") && n.protectedHeader.b64 === !1)
1111
- throw new W("JWTs MUST NOT use unencoded payload");
1111
+ throw new J("JWTs MUST NOT use unencoded payload");
1112
1112
  const o = { payload: sa(n.protectedHeader, n.payload, r), protectedHeader: n.protectedHeader };
1113
1113
  return typeof t == "function" ? { ...o, key: n.key } : o;
1114
1114
  }
1115
- const ca = Q;
1115
+ const ca = X;
1116
1116
  function la(e) {
1117
1117
  if (typeof e != "string")
1118
- throw new W("JWTs must use Compact JWS serialization, JWT must be a string");
1118
+ throw new J("JWTs must use Compact JWS serialization, JWT must be a string");
1119
1119
  const { 1: t, length: r } = e.split(".");
1120
1120
  if (r === 5)
1121
- throw new W("Only JWTs using Compact JWS serialization can be decoded");
1121
+ throw new J("Only JWTs using Compact JWS serialization can be decoded");
1122
1122
  if (r !== 3)
1123
- throw new W("Invalid JWT");
1123
+ throw new J("Invalid JWT");
1124
1124
  if (!t)
1125
- throw new W("JWTs must contain a payload");
1125
+ throw new J("JWTs must contain a payload");
1126
1126
  let a;
1127
1127
  try {
1128
1128
  a = ca(t);
1129
1129
  } catch {
1130
- throw new W("Failed to base64url decode the payload");
1130
+ throw new J("Failed to base64url decode the payload");
1131
1131
  }
1132
1132
  let n;
1133
1133
  try {
1134
1134
  n = JSON.parse(be.decode(a));
1135
1135
  } catch {
1136
- throw new W("Failed to parse the decoded payload as JSON");
1136
+ throw new J("Failed to parse the decoded payload as JSON");
1137
1137
  }
1138
- if (!me(n))
1139
- throw new W("Invalid JWT Claims Set");
1138
+ if (!he(n))
1139
+ throw new J("Invalid JWT Claims Set");
1140
1140
  return n;
1141
1141
  }
1142
1142
  const ye = async (e) => {
1143
1143
  try {
1144
- const t = k.ALG, r = await Br(Er, t);
1144
+ const t = v.ALG, r = await Jr(Er, t);
1145
1145
  return await ia(e, r, {
1146
- issuer: k.ISSUER
1146
+ issuer: v.ISSUER
1147
1147
  });
1148
1148
  } catch {
1149
1149
  return;
@@ -1154,39 +1154,39 @@ const ye = async (e) => {
1154
1154
  } catch {
1155
1155
  return;
1156
1156
  }
1157
- }, v = [];
1157
+ }, S = [];
1158
1158
  for (let e = 0; e < 256; ++e)
1159
- v.push((e + 256).toString(16).slice(1));
1159
+ S.push((e + 256).toString(16).slice(1));
1160
1160
  function ua(e, t = 0) {
1161
- return (v[e[t + 0]] + v[e[t + 1]] + v[e[t + 2]] + v[e[t + 3]] + "-" + v[e[t + 4]] + v[e[t + 5]] + "-" + v[e[t + 6]] + v[e[t + 7]] + "-" + v[e[t + 8]] + v[e[t + 9]] + "-" + v[e[t + 10]] + v[e[t + 11]] + v[e[t + 12]] + v[e[t + 13]] + v[e[t + 14]] + v[e[t + 15]]).toLowerCase();
1161
+ return (S[e[t + 0]] + S[e[t + 1]] + S[e[t + 2]] + S[e[t + 3]] + "-" + S[e[t + 4]] + S[e[t + 5]] + "-" + S[e[t + 6]] + S[e[t + 7]] + "-" + S[e[t + 8]] + S[e[t + 9]] + "-" + S[e[t + 10]] + S[e[t + 11]] + S[e[t + 12]] + S[e[t + 13]] + S[e[t + 14]] + S[e[t + 15]]).toLowerCase();
1162
1162
  }
1163
- let Ge;
1164
- const ma = new Uint8Array(16);
1165
- function ha() {
1166
- if (!Ge) {
1163
+ let We;
1164
+ const ha = new Uint8Array(16);
1165
+ function ma() {
1166
+ if (!We) {
1167
1167
  if (typeof crypto > "u" || !crypto.getRandomValues)
1168
1168
  throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
1169
- Ge = crypto.getRandomValues.bind(crypto);
1169
+ We = crypto.getRandomValues.bind(crypto);
1170
1170
  }
1171
- return Ge(ma);
1171
+ return We(ha);
1172
1172
  }
1173
1173
  const pa = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), mt = { randomUUID: pa };
1174
- function ht(e, t, r) {
1174
+ function pt(e, t, r) {
1175
1175
  if (mt.randomUUID && !t && !e)
1176
1176
  return mt.randomUUID();
1177
1177
  e = e || {};
1178
- const a = e.random || (e.rng || ha)();
1178
+ const a = e.random || (e.rng || ma)();
1179
1179
  return a[6] = a[6] & 15 | 64, a[8] = a[8] & 63 | 128, ua(a);
1180
1180
  }
1181
- const pt = globalThis.crypto, ga = (e) => `${ht()}${ht()}`.slice(0, e), ya = (e) => btoa(
1181
+ const gt = globalThis.crypto, ga = (e) => `${pt()}${pt()}`.slice(0, e), ya = (e) => btoa(
1182
1182
  [...new Uint8Array(e)].map((t) => String.fromCharCode(t)).join("")
1183
1183
  );
1184
1184
  async function fa(e) {
1185
- if (!pt.subtle)
1185
+ if (!gt.subtle)
1186
1186
  throw new Error(
1187
1187
  "crypto.subtle is available only in secure contexts (HTTPS)."
1188
1188
  );
1189
- const t = new TextEncoder().encode(e), r = await pt.subtle.digest("SHA-256", t);
1189
+ const t = new TextEncoder().encode(e), r = await gt.subtle.digest("SHA-256", t);
1190
1190
  return ya(r).replace(/\+/g, "-").replace(/\//g, "_").replace(/=+$/, "");
1191
1191
  }
1192
1192
  async function ba(e) {
@@ -1196,39 +1196,39 @@ async function ba(e) {
1196
1196
  code_challenge: r
1197
1197
  };
1198
1198
  }
1199
- function Bt(e, t) {
1199
+ function Vt(e, t) {
1200
1200
  window.dispatchEvent(new StorageEvent("storage", { key: e, newValue: t }));
1201
1201
  }
1202
- const gt = (e, t) => {
1202
+ const yt = (e, t) => {
1203
1203
  const r = JSON.stringify(
1204
1204
  typeof t == "function" ? t() : t
1205
1205
  );
1206
- window.localStorage.setItem(e, r), Bt(e, r);
1206
+ window.localStorage.setItem(e, r), Vt(e, r);
1207
1207
  }, Ea = (e) => {
1208
- window.localStorage.removeItem(e), Bt(e, null);
1209
- }, yt = (e) => window.localStorage.getItem(e), wa = (e) => (window.addEventListener("storage", e), () => window.removeEventListener("storage", e));
1210
- function _e({
1208
+ window.localStorage.removeItem(e), Vt(e, null);
1209
+ }, ft = (e) => window.localStorage.getItem(e), wa = (e) => (window.addEventListener("storage", e), () => window.removeEventListener("storage", e));
1210
+ function Ie({
1211
1211
  key: e,
1212
1212
  initialValue: t
1213
1213
  }) {
1214
- const r = lr(wa, () => yt(e)), a = X(
1214
+ const r = lr(wa, () => ft(e)), a = q(
1215
1215
  (s) => {
1216
1216
  try {
1217
1217
  const i = typeof s == "function" ? s(JSON.parse(r)) : s;
1218
- i == null ? Ea(e) : gt(e, i);
1218
+ i == null ? Ea(e) : yt(e, i);
1219
1219
  } catch (i) {
1220
1220
  console.warn(i);
1221
1221
  }
1222
1222
  },
1223
1223
  [e, r]
1224
- ), n = X(() => {
1224
+ ), n = q(() => {
1225
1225
  a(t);
1226
- }, [t, a]), o = X(() => {
1226
+ }, [t, a]), o = q(() => {
1227
1227
  a(null);
1228
1228
  }, [a]);
1229
- return Z(() => {
1229
+ return Q(() => {
1230
1230
  try {
1231
- yt(e) === null && typeof t < "u" && gt(e, t);
1231
+ ft(e) === null && typeof t < "u" && yt(e, t);
1232
1232
  } catch (s) {
1233
1233
  console.warn(s);
1234
1234
  }
@@ -1237,31 +1237,31 @@ function _e({
1237
1237
  const A = [];
1238
1238
  for (let e = 0; e < 256; ++e)
1239
1239
  A.push((e + 256).toString(16).slice(1));
1240
- function Ia(e, t = 0) {
1240
+ function Ta(e, t = 0) {
1241
1241
  return (A[e[t + 0]] + A[e[t + 1]] + A[e[t + 2]] + A[e[t + 3]] + "-" + A[e[t + 4]] + A[e[t + 5]] + "-" + A[e[t + 6]] + A[e[t + 7]] + "-" + A[e[t + 8]] + A[e[t + 9]] + "-" + A[e[t + 10]] + A[e[t + 11]] + A[e[t + 12]] + A[e[t + 13]] + A[e[t + 14]] + A[e[t + 15]]).toLowerCase();
1242
1242
  }
1243
- let We;
1244
- const _a = new Uint8Array(16);
1245
- function Ta() {
1246
- if (!We) {
1243
+ let Ge;
1244
+ const Ia = new Uint8Array(16);
1245
+ function _a() {
1246
+ if (!Ge) {
1247
1247
  if (typeof crypto > "u" || !crypto.getRandomValues)
1248
1248
  throw new Error("crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported");
1249
- We = crypto.getRandomValues.bind(crypto);
1249
+ Ge = crypto.getRandomValues.bind(crypto);
1250
1250
  }
1251
- return We(_a);
1251
+ return Ge(Ia);
1252
1252
  }
1253
- const Sa = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), ft = { randomUUID: Sa };
1254
- function Ve(e, t, r) {
1255
- if (ft.randomUUID && !t && !e)
1256
- return ft.randomUUID();
1253
+ const ka = typeof crypto < "u" && crypto.randomUUID && crypto.randomUUID.bind(crypto), bt = { randomUUID: ka };
1254
+ function Be(e, t, r) {
1255
+ if (bt.randomUUID && !t && !e)
1256
+ return bt.randomUUID();
1257
1257
  e = e || {};
1258
- const a = e.random || (e.rng || Ta)();
1259
- return a[6] = a[6] & 15 | 64, a[8] = a[8] & 63 | 128, Ia(a);
1258
+ const a = e.random || (e.rng || _a)();
1259
+ return a[6] = a[6] & 15 | 64, a[8] = a[8] & 63 | 128, Ta(a);
1260
1260
  }
1261
- const oe = "Your session has expired. For your security, please log in again to continue.", va = "Your session has been successfully terminated.", Be = "Login failed. Please try again.", Aa = "Error getting access token, please re-authenticate.", ka = "You forgot to wrap your component in <AuthProvider>.", Ce = {
1261
+ const oe = "Your session has expired. For your security, please log in again to continue.", Sa = "Your session has been successfully terminated.", Je = "Login failed. Please try again.", Aa = "Error getting access token, please re-authenticate.", va = "You forgot to wrap your component in <AuthProvider>.", Ce = {
1262
1262
  dev: "https://auth.gizmette.local.com:3003",
1263
1263
  prod: "https://mylogin.gizmette.com/auth"
1264
- }, Te = "@@auth@@", ge = "LOADING", Ae = "LOGIN", Jt = "LOGOUT", Ee = "success", B = "failure", Yt = "include", Ft = "POST", zt = "application/json", Se = {
1264
+ }, _e = "@@auth@@", ge = "LOADING", Ae = "LOGIN", Yt = "LOGOUT", Ee = "success", Y = "failure", Ft = "include", zt = "POST", jt = "application/json", ke = {
1265
1265
  GET_REGISTRATION_OPTIONS: `mutation GetPasskeyRegistrationOptions(
1266
1266
  $clientId: String!,
1267
1267
  $username: String!,
@@ -1344,19 +1344,19 @@ const oe = "Your session has expired. For your security, please log in again to
1344
1344
  }`
1345
1345
  }, se = {
1346
1346
  GET_REGISTRATION_OPTIONS: {
1347
- schema: Se.GET_REGISTRATION_OPTIONS,
1347
+ schema: ke.GET_REGISTRATION_OPTIONS,
1348
1348
  method: "getPasskeyRegistrationOptions"
1349
1349
  },
1350
1350
  VERIFY_REGISTRATION: {
1351
- schema: Se.VERIFY_REGISTRATION,
1351
+ schema: ke.VERIFY_REGISTRATION,
1352
1352
  method: "verifyPasskeyRegistration"
1353
1353
  },
1354
1354
  GET_AUTHENTICATION_OPTIONS: {
1355
- schema: Se.GET_AUTHENTICATION_OPTIONS,
1355
+ schema: ke.GET_AUTHENTICATION_OPTIONS,
1356
1356
  method: "getPasskeyAuthenticationOptions"
1357
1357
  },
1358
1358
  VERIFY_AUTHENTICATION: {
1359
- schema: Se.VERIFY_AUTHENTICATION,
1359
+ schema: ke.VERIFY_AUTHENTICATION,
1360
1360
  method: "verifyPasskeyAuthentication"
1361
1361
  }
1362
1362
  }, ie = async ({
@@ -1367,14 +1367,14 @@ const oe = "Your session has expired. For your security, please log in again to
1367
1367
  }) => {
1368
1368
  try {
1369
1369
  const n = `Bearer ${e}`, o = await fetch(
1370
- jt ? `${Ce.dev}/graphql` : `${Ce.prod}/graphql`,
1370
+ qt ? `${Ce.dev}/graphql` : `${Ce.prod}/graphql`,
1371
1371
  {
1372
- credentials: Yt,
1373
- method: Ft,
1372
+ credentials: Ft,
1373
+ method: zt,
1374
1374
  headers: {
1375
1375
  authorization: n,
1376
- "Content-Type": zt,
1377
- [Ct.CLIENT_ID]: `${r}`
1376
+ "Content-Type": jt,
1377
+ [Ot.CLIENT_ID]: `${r}`
1378
1378
  },
1379
1379
  body: JSON.stringify({
1380
1380
  query: t.schema,
@@ -1383,44 +1383,44 @@ const oe = "Your session has expired. For your security, please log in again to
1383
1383
  }
1384
1384
  );
1385
1385
  if (o.status !== 200)
1386
- return { status: B, data: [] };
1386
+ return { status: Y, data: [] };
1387
1387
  const { data: s } = await o.json();
1388
1388
  return {
1389
1389
  status: Ee,
1390
1390
  data: s[t.method]
1391
1391
  };
1392
1392
  } catch (n) {
1393
- return console.error(n), { status: B, data: [] };
1393
+ return console.error(n), { status: Y, data: [] };
1394
1394
  }
1395
- }, $e = async ({
1395
+ }, Le = async ({
1396
1396
  type: e,
1397
1397
  clientId: t,
1398
1398
  params: r = {}
1399
1399
  }) => {
1400
1400
  try {
1401
1401
  const a = await fetch(
1402
- jt ? `${Ce.dev}/${e}` : `${Ce.prod}/${e}`,
1402
+ qt ? `${Ce.dev}/${e}` : `${Ce.prod}/${e}`,
1403
1403
  {
1404
- credentials: Yt,
1405
- method: Ft,
1404
+ credentials: Ft,
1405
+ method: zt,
1406
1406
  headers: {
1407
- "Content-Type": zt,
1408
- [Ct.CLIENT_ID]: `${t}`
1407
+ "Content-Type": jt,
1408
+ [Ot.CLIENT_ID]: `${t}`
1409
1409
  },
1410
1410
  body: JSON.stringify(r)
1411
1411
  }
1412
1412
  );
1413
1413
  if (a.status !== 200)
1414
- return { status: B, data: [] };
1414
+ return { status: Y, data: [] };
1415
1415
  const { data: n } = await a.json();
1416
1416
  return {
1417
1417
  status: Ee,
1418
1418
  data: n || []
1419
1419
  };
1420
1420
  } catch (a) {
1421
- return console.error(a), { status: B, data: [] };
1421
+ return console.error(a), { status: Y, data: [] };
1422
1422
  }
1423
- }, Na = process.env.NODE_ENV === "production", jt = !Na, qt = {
1423
+ }, Na = process.env.NODE_ENV === "production", qt = !Na, Xt = {
1424
1424
  isLoading: !0,
1425
1425
  isAuthenticated: !1,
1426
1426
  user: void 0,
@@ -1430,7 +1430,7 @@ const oe = "Your session has expired. For your security, please log in again to
1430
1430
  }, Ra = (e) => {
1431
1431
  try {
1432
1432
  const t = da(e);
1433
- return t ? t[k.USER_ID_KEY] : "";
1433
+ return t ? t[v.USER_ID_KEY] : "";
1434
1434
  } catch {
1435
1435
  return "";
1436
1436
  }
@@ -1443,7 +1443,7 @@ const oe = "Your session has expired. For your security, please log in again to
1443
1443
  var n;
1444
1444
  try {
1445
1445
  return {
1446
- status: ((n = await $e({
1446
+ status: ((n = await Le({
1447
1447
  type: Pe.LOGOUT,
1448
1448
  clientId: t,
1449
1449
  params: {
@@ -1451,11 +1451,11 @@ const oe = "Your session has expired. For your security, please log in again to
1451
1451
  domain: r,
1452
1452
  idToken: a
1453
1453
  }
1454
- })) == null ? void 0 : n.status) || B
1454
+ })) == null ? void 0 : n.status) || Y
1455
1455
  };
1456
1456
  } catch {
1457
1457
  return {
1458
- status: B
1458
+ status: Y
1459
1459
  };
1460
1460
  }
1461
1461
  }, Ca = async ({
@@ -1467,12 +1467,12 @@ const oe = "Your session has expired. For your security, please log in again to
1467
1467
  sessionExpiration: o,
1468
1468
  code: s,
1469
1469
  code_verifier: i,
1470
- domain: u,
1471
- ua: h
1470
+ domain: d,
1471
+ ua: m
1472
1472
  }) => {
1473
1473
  var p;
1474
1474
  try {
1475
- const m = await $e({
1475
+ const u = await Le({
1476
1476
  type: Pe.LOGIN,
1477
1477
  clientId: r,
1478
1478
  params: {
@@ -1483,16 +1483,16 @@ const oe = "Your session has expired. For your security, please log in again to
1483
1483
  nonce: a,
1484
1484
  code: s,
1485
1485
  code_verifier: i,
1486
- domain: u,
1487
- ua: h
1486
+ domain: d,
1487
+ ua: m
1488
1488
  }
1489
- }), c = await ye((p = m == null ? void 0 : m.data) == null ? void 0 : p.idToken);
1490
- return c && c.payload[k.USER_ID_KEY] !== "" && c.payload[k.NONCE_KEY] === a ? {
1491
- idToken: m.data.idToken,
1492
- accessToken: m.data.accessToken,
1493
- refreshToken: m.data.refreshToken,
1494
- userId: c.payload[k.USER_ID_KEY],
1495
- email: c.payload[k.EMAIL_KEY],
1489
+ }), c = await ye((p = u == null ? void 0 : u.data) == null ? void 0 : p.idToken);
1490
+ return c && c.payload[v.USER_ID_KEY] !== "" && c.payload[v.NONCE_KEY] === a ? {
1491
+ idToken: u.data.idToken,
1492
+ accessToken: u.data.accessToken,
1493
+ refreshToken: u.data.refreshToken,
1494
+ userId: c.payload[v.USER_ID_KEY],
1495
+ email: c.payload[v.EMAIL_KEY],
1496
1496
  status: !0
1497
1497
  } : {
1498
1498
  status: !1
@@ -1509,7 +1509,7 @@ const oe = "Your session has expired. For your security, please log in again to
1509
1509
  }) => {
1510
1510
  var a;
1511
1511
  try {
1512
- const n = await $e({
1512
+ const n = await Le({
1513
1513
  type: Pe.CODE,
1514
1514
  clientId: t,
1515
1515
  params: {
@@ -1522,12 +1522,12 @@ const oe = "Your session has expired. For your security, please log in again to
1522
1522
  status: Ee,
1523
1523
  data: n.data.code
1524
1524
  } : {
1525
- status: B,
1525
+ status: Y,
1526
1526
  data: ""
1527
1527
  };
1528
1528
  } catch {
1529
1529
  return {
1530
- status: B,
1530
+ status: Y,
1531
1531
  data: ""
1532
1532
  };
1533
1533
  }
@@ -1541,7 +1541,7 @@ const oe = "Your session has expired. For your security, please log in again to
1541
1541
  }) => {
1542
1542
  var s;
1543
1543
  try {
1544
- const i = await $e({
1544
+ const i = await Le({
1545
1545
  type: Pe.REFRESH,
1546
1546
  clientId: e,
1547
1547
  params: {
@@ -1552,11 +1552,11 @@ const oe = "Your session has expired. For your security, please log in again to
1552
1552
  accessToken: n,
1553
1553
  domain: o
1554
1554
  }
1555
- }), u = await ye((s = i == null ? void 0 : i.data) == null ? void 0 : s.accessToken);
1556
- return u && u.payload[k.USER_ID_KEY] !== "" && u.payload[k.NONCE_KEY] === r ? {
1555
+ }), d = await ye((s = i == null ? void 0 : i.data) == null ? void 0 : s.accessToken);
1556
+ return d && d.payload[v.USER_ID_KEY] !== "" && d.payload[v.NONCE_KEY] === r ? {
1557
1557
  accessToken: i.data.accessToken,
1558
1558
  refreshToken: i.data.refreshToken,
1559
- userId: u.payload[k.USER_ID_KEY],
1559
+ userId: d.payload[v.USER_ID_KEY],
1560
1560
  status: !0
1561
1561
  } : {
1562
1562
  status: !1
@@ -1596,7 +1596,7 @@ class Da {
1596
1596
  domain: n
1597
1597
  }) {
1598
1598
  const o = await ye(this.refreshToken);
1599
- if (o && o.payload[k.USER_ID_KEY] !== "") {
1599
+ if (o && o.payload[v.USER_ID_KEY] !== "") {
1600
1600
  const s = await Pa({
1601
1601
  clientId: t,
1602
1602
  userId: r,
@@ -1610,22 +1610,22 @@ class Da {
1610
1610
  newAccessToken: s.accessToken,
1611
1611
  newRefreshToken: s.refreshToken
1612
1612
  }) : {
1613
- status: B
1613
+ status: Y
1614
1614
  };
1615
1615
  } else
1616
1616
  return {
1617
- status: B
1617
+ status: Y
1618
1618
  };
1619
1619
  }
1620
1620
  }
1621
- const $a = (e) => X(
1621
+ const La = (e) => q(
1622
1622
  (...t) => {
1623
1623
  e && console.info(`==> [Auth ${Date.now()}]: `, ...t);
1624
1624
  },
1625
1625
  [e]
1626
1626
  ), ce = () => {
1627
- throw new Error(ka);
1628
- }, Xt = cr({
1627
+ throw new Error(va);
1628
+ }, Qt = cr({
1629
1629
  isAuthenticated: !1,
1630
1630
  isLoading: !1,
1631
1631
  login: ce,
@@ -1636,11 +1636,11 @@ const $a = (e) => X(
1636
1636
  loginWithPasskey: ce,
1637
1637
  logoutReason: "",
1638
1638
  authenticationType: ""
1639
- }), La = P.createContext({
1640
- state: qt,
1639
+ }), Ma = P.createContext({
1640
+ state: Xt,
1641
1641
  dispatch: () => {
1642
1642
  }
1643
- }), Ma = (e, t) => (t == null ? void 0 : t.type) === ge ? {
1643
+ }), $a = (e, t) => (t == null ? void 0 : t.type) === ge ? {
1644
1644
  ...e,
1645
1645
  isLoading: t.payload.isLoading
1646
1646
  } : (t == null ? void 0 : t.type) === Ae ? {
@@ -1650,7 +1650,7 @@ const $a = (e) => X(
1650
1650
  user: t.payload.user,
1651
1651
  authenticationType: t.payload.authenticationType,
1652
1652
  logoutReason: ""
1653
- } : (t == null ? void 0 : t.type) === Jt ? {
1653
+ } : (t == null ? void 0 : t.type) === Yt ? {
1654
1654
  ...e,
1655
1655
  isLoading: !1,
1656
1656
  isAuthenticated: !1,
@@ -1664,172 +1664,172 @@ const $a = (e) => X(
1664
1664
  domain: a = "",
1665
1665
  debug: n = !1
1666
1666
  }) => {
1667
- const [o, s] = _t(Ma, {
1668
- ...qt,
1667
+ const [o, s] = _t($a, {
1668
+ ...Xt,
1669
1669
  debug: n
1670
- }), i = $a(n), u = K(!1), [h, p, , m] = _e({
1671
- key: `${Te}::${r}::@@user@@`
1672
- }), [c, d, , f] = _e({
1673
- key: `${Te}::${r}::@@access@@`
1674
- }), [b, T, , w] = _e(
1670
+ }), i = La(n), d = $(!1), [m, p, , u] = Ie({
1671
+ key: `${_e}::${r}::@@user@@`
1672
+ }), [c, h, , f] = Ie({
1673
+ key: `${_e}::${r}::@@access@@`
1674
+ }), [E, w, , _] = Ie(
1675
1675
  {
1676
- key: `${Te}::${r}::@@refresh@@`
1676
+ key: `${_e}::${r}::@@refresh@@`
1677
1677
  }
1678
- ), [C, $, , H] = _e({
1679
- key: `${Te}::${r}::@@nonce@@`
1680
- }), ee = new Da(c, b), N = X(() => {
1681
- i("removeLocalStorage: removing local storage"), m(), f(), w(), H();
1678
+ ), [U, K, , H] = Ie({
1679
+ key: `${_e}::${r}::@@nonce@@`
1680
+ }), O = new Da(c, E), W = q(() => {
1681
+ i("removeLocalStorage: removing local storage"), u(), f(), _(), H();
1682
1682
  }, [
1683
1683
  f,
1684
- m,
1684
+ u,
1685
1685
  H,
1686
- w,
1686
+ _,
1687
1687
  i
1688
- ]), J = X(
1689
- (g) => {
1688
+ ]), G = q(
1689
+ (y) => {
1690
1690
  i(
1691
1691
  "removeStateAndLocalStorage: removing state and local storage with reason: ",
1692
- g
1692
+ y
1693
1693
  ), s({
1694
- type: Jt,
1694
+ type: Yt,
1695
1695
  payload: {
1696
- logoutReason: g || oe
1696
+ logoutReason: y || oe
1697
1697
  }
1698
- }), N(), s({ type: ge, payload: { isLoading: !1 } });
1698
+ }), W(), s({ type: ge, payload: { isLoading: !1 } });
1699
1699
  },
1700
- [N, i]
1701
- ), D = X(
1702
- async (g) => {
1700
+ [W, i]
1701
+ ), x = q(
1702
+ async (y) => {
1703
1703
  i("invalidateAndLogout: invalidating and logging out");
1704
- const { user: I } = o, E = (I == null ? void 0 : I.userId) || Ra(h);
1705
- E || i(
1704
+ const { user: T } = o, b = (T == null ? void 0 : T.userId) || Ra(m);
1705
+ b || i(
1706
1706
  "invalidateAndLogout: user cannot be identified, logging out without userId"
1707
1707
  ), await xa({
1708
- userId: E,
1708
+ userId: b,
1709
1709
  clientId: r,
1710
1710
  domain: a,
1711
- idToken: h
1712
- }), J(g || oe);
1711
+ idToken: m
1712
+ }), G(y || oe);
1713
1713
  },
1714
- [h, o, r, a, J, i]
1714
+ [m, o, r, a, G, i]
1715
1715
  );
1716
- Z(() => {
1717
- if (!u.current)
1718
- return o.isLoading && h !== null ? (async () => {
1716
+ Q(() => {
1717
+ if (!d.current)
1718
+ return o.isLoading && m !== null ? (async () => {
1719
1719
  try {
1720
- const g = await ye(h);
1721
- g && g.payload[k.USER_ID_KEY] !== "" ? (i("useEffect: setting the authentication state"), s({
1720
+ const y = await ye(m);
1721
+ y && y.payload[v.USER_ID_KEY] !== "" ? (i("useEffect: setting the authentication state"), s({
1722
1722
  type: Ae,
1723
1723
  payload: {
1724
- authenticationType: g.payload[k.AUTH_TYPE_KEY],
1724
+ authenticationType: y.payload[v.AUTH_TYPE_KEY],
1725
1725
  user: {
1726
- userId: g.payload[k.USER_ID_KEY],
1727
- username: g.payload[k.USERNAME_KEY],
1728
- email: g.payload[k.EMAIL_KEY]
1726
+ userId: y.payload[v.USER_ID_KEY],
1727
+ username: y.payload[v.USERNAME_KEY],
1728
+ email: y.payload[v.EMAIL_KEY]
1729
1729
  }
1730
1730
  }
1731
- })) : (i("useEffect: invalid JWT, invalidating and logging out"), await D(oe));
1731
+ })) : (i("useEffect: invalid JWT, invalidating and logging out"), await x(oe));
1732
1732
  } catch {
1733
1733
  i(
1734
1734
  "useEffect: exception validating JWT, invalidating and logging out"
1735
- ), await D(oe);
1735
+ ), await x(oe);
1736
1736
  }
1737
1737
  })() : (i("useEffect: setting the loading state to false"), s({ type: ge, payload: { isLoading: !1 } })), () => {
1738
- u.current = !0;
1738
+ d.current = !0;
1739
1739
  };
1740
- }, [o.isLoading, h, D, i]);
1741
- const Y = async (g, I) => {
1742
- s({ type: ge, payload: { isLoading: !0 } }), N();
1743
- const E = Ve();
1744
- $(E), i("login: Logging in with password");
1745
- const { code_verifier: z, code_challenge: ir } = await ba(), ot = await Oa({
1746
- nonce: E,
1740
+ }, [o.isLoading, m, x, i]);
1741
+ const pe = async (y, T) => {
1742
+ s({ type: ge, payload: { isLoading: !0 } }), W();
1743
+ const b = Be();
1744
+ K(b), i("login: Logging in with password");
1745
+ const { code_verifier: te, code_challenge: ir } = await ba(), st = await Oa({
1746
+ nonce: b,
1747
1747
  clientId: r,
1748
1748
  code_challenge: ir
1749
1749
  });
1750
- if (ot.status) {
1750
+ if (st.status) {
1751
1751
  const re = await Ca({
1752
- username: g,
1753
- password: I,
1752
+ username: y,
1753
+ password: T,
1754
1754
  clientId: r,
1755
1755
  sessionExpiration: t,
1756
- nonce: E,
1756
+ nonce: b,
1757
1757
  type: ue.CODE,
1758
- code: ot.data,
1759
- code_verifier: z,
1758
+ code: st.data,
1759
+ code_verifier: te,
1760
1760
  domain: a,
1761
1761
  ua: navigator.userAgent
1762
1762
  });
1763
- return re.status ? (p(re.idToken), d(re.accessToken), T(re.refreshToken), s({
1763
+ return re.status ? (p(re.idToken), h(re.accessToken), w(re.refreshToken), s({
1764
1764
  type: Ae,
1765
1765
  payload: {
1766
1766
  authenticationType: ue.CODE,
1767
1767
  user: {
1768
1768
  userId: re.userId,
1769
- username: g,
1769
+ username: y,
1770
1770
  email: re.email
1771
1771
  }
1772
1772
  }
1773
- }), !0) : (J(Be), !1);
1773
+ }), !0) : (G(Je), !1);
1774
1774
  }
1775
1775
  return !1;
1776
- }, pe = async (g) => {
1777
- g == null || g.preventDefault(), await D(va);
1778
- }, te = async () => {
1779
- const { isAuthenticated: g, user: I } = o;
1776
+ }, Z = async (y) => {
1777
+ y == null || y.preventDefault(), await x(Sa);
1778
+ }, N = async () => {
1779
+ const { isAuthenticated: y, user: T } = o;
1780
1780
  try {
1781
- if (g && I && I.userId) {
1781
+ if (y && T && T.userId) {
1782
1782
  if (c) {
1783
1783
  i("getAccessToken");
1784
- const z = await ye(c);
1785
- if (z && z.payload[k.USER_ID_KEY] !== "")
1784
+ const te = await ye(c);
1785
+ if (te && te.payload[v.USER_ID_KEY] !== "")
1786
1786
  return c;
1787
1787
  }
1788
1788
  i("getAccessToken: invalid access token, trying to refresh it");
1789
- const E = await ee.refreshtoken({
1789
+ const b = await O.refreshtoken({
1790
1790
  clientId: r,
1791
- userId: I.userId,
1792
- nonce: C,
1791
+ userId: T.userId,
1792
+ nonce: U,
1793
1793
  domain: a
1794
1794
  });
1795
- return E.status && E.status === "success" && E.newAccessToken ? (d(E.newAccessToken), T(E.newRefreshToken), E.newAccessToken) : (i(
1795
+ return b.status && b.status === "success" && b.newAccessToken ? (h(b.newAccessToken), w(b.newRefreshToken), b.newAccessToken) : (i(
1796
1796
  "getAccessToken: invalid refresh token, need to re-authenticate"
1797
- ), await D(oe), "");
1797
+ ), await x(oe), "");
1798
1798
  }
1799
1799
  return i(
1800
1800
  "getAccessToken: user is not authenticated, cannot get access token"
1801
- ), await D(oe), "";
1801
+ ), await x(oe), "";
1802
1802
  } catch {
1803
1803
  return i(
1804
1804
  "getAccessToken: exception occurred, invalidating and logging out"
1805
- ), await D(Aa), "";
1805
+ ), await x(Aa), "";
1806
1806
  }
1807
- }, R = () => o.isAuthenticated && h ? h : "", L = async () => {
1808
- const { user: g } = o;
1809
- let I = await ie({
1807
+ }, D = () => o.isAuthenticated && m ? m : "", B = async () => {
1808
+ const { user: y } = o;
1809
+ let T = await ie({
1810
1810
  accessToken: c,
1811
1811
  clientId: r,
1812
1812
  type: se.GET_REGISTRATION_OPTIONS,
1813
1813
  params: {
1814
1814
  clientId: r,
1815
- id: g == null ? void 0 : g.userId,
1816
- username: g == null ? void 0 : g.username
1815
+ id: y == null ? void 0 : y.userId,
1816
+ username: y == null ? void 0 : y.username
1817
1817
  }
1818
1818
  });
1819
- if (I.status)
1819
+ if (T.status)
1820
1820
  try {
1821
- const E = await gr(I.data);
1822
- return I = await ie({
1821
+ const b = await gr(T.data);
1822
+ return T = await ie({
1823
1823
  accessToken: c,
1824
1824
  clientId: r,
1825
1825
  type: se.VERIFY_REGISTRATION,
1826
1826
  params: {
1827
1827
  clientId: r,
1828
- id: g == null ? void 0 : g.userId,
1829
- username: g == null ? void 0 : g.username,
1830
- registration: E
1828
+ id: y == null ? void 0 : y.userId,
1829
+ username: y == null ? void 0 : y.username,
1830
+ registration: b
1831
1831
  }
1832
- }), !!(I.status && I.data.length > 0);
1832
+ }), !!(T.status && T.data.length > 0);
1833
1833
  } catch {
1834
1834
  return await ie({
1835
1835
  accessToken: c,
@@ -1837,54 +1837,54 @@ const $a = (e) => X(
1837
1837
  type: se.VERIFY_REGISTRATION,
1838
1838
  params: {
1839
1839
  clientId: r,
1840
- id: g == null ? void 0 : g.userId,
1841
- username: g == null ? void 0 : g.username,
1840
+ id: y == null ? void 0 : y.userId,
1841
+ username: y == null ? void 0 : y.username,
1842
1842
  registration: {}
1843
1843
  }
1844
1844
  }), !1;
1845
1845
  }
1846
1846
  return !1;
1847
- }, G = async () => {
1848
- s({ type: ge, payload: { isLoading: !0 } }), N();
1849
- const g = Ve();
1850
- $(g), i("loginWithPasskey");
1851
- const I = Ve();
1852
- let E = await ie({
1847
+ }, ee = async () => {
1848
+ s({ type: ge, payload: { isLoading: !0 } }), W();
1849
+ const y = Be();
1850
+ K(y), i("loginWithPasskey");
1851
+ const T = Be();
1852
+ let b = await ie({
1853
1853
  accessToken: c,
1854
1854
  clientId: r,
1855
1855
  type: se.GET_AUTHENTICATION_OPTIONS,
1856
1856
  params: {
1857
- id: I,
1857
+ id: T,
1858
1858
  clientId: r
1859
1859
  }
1860
1860
  });
1861
- if (E.status)
1861
+ if (b.status)
1862
1862
  try {
1863
- const z = await br(E.data);
1864
- return E = await ie({
1863
+ const te = await br(b.data);
1864
+ return b = await ie({
1865
1865
  accessToken: c,
1866
1866
  clientId: r,
1867
1867
  type: se.VERIFY_AUTHENTICATION,
1868
1868
  params: {
1869
1869
  clientId: r,
1870
- id: I,
1871
- authentication: z,
1872
- nonce: g,
1870
+ id: T,
1871
+ authentication: te,
1872
+ nonce: y,
1873
1873
  domain: a,
1874
1874
  sessionExpiration: t,
1875
1875
  ua: navigator.userAgent
1876
1876
  }
1877
- }), E.data.status === Ee ? (p(E.data.idToken), d(E.data.accessToken), T(E.data.refreshToken), s({
1877
+ }), b.data.status === Ee ? (p(b.data.idToken), h(b.data.accessToken), w(b.data.refreshToken), s({
1878
1878
  type: Ae,
1879
1879
  payload: {
1880
1880
  authenticationType: ue.PASSKEY,
1881
1881
  user: {
1882
- userId: E.data.userId,
1883
- username: E.data.username,
1884
- email: E.data.email
1882
+ userId: b.data.userId,
1883
+ username: b.data.username,
1884
+ email: b.data.email
1885
1885
  }
1886
1886
  }
1887
- }), !0) : (J(Be), !1);
1887
+ }), !0) : (G(Je), !1);
1888
1888
  } catch {
1889
1889
  return await ie({
1890
1890
  accessToken: c,
@@ -1892,32 +1892,32 @@ const $a = (e) => X(
1892
1892
  type: se.VERIFY_AUTHENTICATION,
1893
1893
  params: {
1894
1894
  clientId: r,
1895
- id: I,
1895
+ id: T,
1896
1896
  authentication: {},
1897
- nonce: g,
1897
+ nonce: y,
1898
1898
  domain: a,
1899
1899
  sessionExpiration: t
1900
1900
  }
1901
- }), J(Be), !1;
1901
+ }), G(Je), !1;
1902
1902
  }
1903
1903
  return !1;
1904
1904
  };
1905
- return /* @__PURE__ */ l(La.Provider, { value: { state: o, dispatch: s }, children: /* @__PURE__ */ l(
1906
- Xt.Provider,
1905
+ return /* @__PURE__ */ l(Ma.Provider, { value: { state: o, dispatch: s }, children: /* @__PURE__ */ l(
1906
+ Qt.Provider,
1907
1907
  {
1908
1908
  value: {
1909
1909
  ...o,
1910
- login: Y,
1911
- logout: pe,
1912
- getAccessToken: te,
1913
- getIdToken: R,
1914
- registeringForPasskey: L,
1915
- loginWithPasskey: G
1910
+ login: pe,
1911
+ logout: Z,
1912
+ getAccessToken: N,
1913
+ getIdToken: D,
1914
+ registeringForPasskey: B,
1915
+ loginWithPasskey: ee
1916
1916
  },
1917
1917
  children: e
1918
1918
  }
1919
1919
  ) });
1920
- }, et = (e = Xt) => Xe(e), Eo = "user", wo = "assistant", Io = "system", _o = "internal", To = "hidden", So = "I'm having trouble right now. Please try again later.", Je = "OpenAI", vo = "OpenAI", Ao = "Anthropic", ko = 128e3, No = "action-message", Ro = "action-reset", xo = "action-model", Co = "action-restore", Oo = "action-streaming", Po = "action-engine", Do = "action-search", $o = "action-sort", Lo = "action-toggle-tag", Mo = "action-reset-tags", Uo = "action-set-tags", Ko = "sassy-saint-", Ho = "details", Go = "search", Wo = "sort", Vo = "engine-toggle", Bo = "==stats==", Ka = "b44c68f0-e5b3-4a1d-a3e3-df8632b0223b", bt = (e) => Number.isFinite(e) ? e : 0;
1920
+ }, tt = (e = Qt) => Qe(e), uo = "user", ho = "assistant", mo = "system", po = "internal", go = "hidden", yo = "I'm having trouble right now. Please try again later.", Ve = "OpenAI", fo = "OpenAI", bo = "Anthropic", Eo = 128e3, wo = "action-message", To = "action-reset", Io = "action-model", _o = "action-restore", ko = "action-streaming", So = "action-engine", Ao = "action-search", vo = "action-sort", No = "action-toggle-tag", Ro = "action-reset-tags", xo = "action-set-tags", Co = "sassy-saint-", Oo = "details", Po = "search", Do = "sort", Lo = "engine-toggle", Mo = "==stats==", Ka = "b44c68f0-e5b3-4a1d-a3e3-df8632b0223b", Et = (e) => Number.isFinite(e) ? e : 0;
1921
1921
  function Ha(e) {
1922
1922
  return {
1923
1923
  days: Math.trunc(e / 864e5),
@@ -1925,11 +1925,11 @@ function Ha(e) {
1925
1925
  minutes: Math.trunc(e / 6e4 % 60),
1926
1926
  seconds: Math.trunc(e / 1e3 % 60),
1927
1927
  milliseconds: Math.trunc(e % 1e3),
1928
- microseconds: Math.trunc(bt(e * 1e3) % 1e3),
1929
- nanoseconds: Math.trunc(bt(e * 1e6) % 1e3)
1928
+ microseconds: Math.trunc(Et(e * 1e3) % 1e3),
1929
+ nanoseconds: Math.trunc(Et(e * 1e6) % 1e3)
1930
1930
  };
1931
1931
  }
1932
- function Ga(e) {
1932
+ function Wa(e) {
1933
1933
  return {
1934
1934
  days: e / 86400000n,
1935
1935
  hours: e / 3600000n % 24n,
@@ -1940,7 +1940,7 @@ function Ga(e) {
1940
1940
  nanoseconds: 0n
1941
1941
  };
1942
1942
  }
1943
- function Wa(e) {
1943
+ function Ga(e) {
1944
1944
  switch (typeof e) {
1945
1945
  case "number": {
1946
1946
  if (Number.isFinite(e))
@@ -1948,11 +1948,11 @@ function Wa(e) {
1948
1948
  break;
1949
1949
  }
1950
1950
  case "bigint":
1951
- return Ga(e);
1951
+ return Wa(e);
1952
1952
  }
1953
1953
  throw new TypeError("Expected a finite number or bigint");
1954
1954
  }
1955
- const Va = (e) => e === 0 || e === 0n, Ba = (e, t) => t === 1 || t === 1n ? e : `${e}s`, Ja = 1e-7, Ya = 24n * 60n * 60n * 1000n;
1955
+ const Ba = (e) => e === 0 || e === 0n, Ja = (e, t) => t === 1 || t === 1n ? e : `${e}s`, Va = 1e-7, Ya = 24n * 60n * 60n * 1000n;
1956
1956
  function Fa(e, t) {
1957
1957
  const r = typeof e == "bigint";
1958
1958
  if (!r && !Number.isFinite(e))
@@ -1961,43 +1961,43 @@ function Fa(e, t) {
1961
1961
  const a = e < 0 ? "-" : "";
1962
1962
  e = e < 0 ? -e : e, t.colonNotation && (t.compact = !1, t.formatSubMilliseconds = !1, t.separateMilliseconds = !1, t.verbose = !1), t.compact && (t.unitCount = 1, t.secondsDecimalDigits = 0, t.millisecondsDecimalDigits = 0);
1963
1963
  let n = [];
1964
- const o = (p, m) => {
1965
- const c = Math.floor(p * 10 ** m + Ja);
1966
- return (Math.round(c) / 10 ** m).toFixed(m);
1967
- }, s = (p, m, c, d) => {
1968
- if (!((n.length === 0 || !t.colonNotation) && Va(p) && !(t.colonNotation && c === "m"))) {
1969
- if (d ?? (d = String(p)), t.colonNotation) {
1970
- const f = d.includes(".") ? d.split(".")[0].length : d.length, b = n.length > 0 ? 2 : 1;
1971
- d = "0".repeat(Math.max(0, b - f)) + d;
1964
+ const o = (p, u) => {
1965
+ const c = Math.floor(p * 10 ** u + Va);
1966
+ return (Math.round(c) / 10 ** u).toFixed(u);
1967
+ }, s = (p, u, c, h) => {
1968
+ if (!((n.length === 0 || !t.colonNotation) && Ba(p) && !(t.colonNotation && c === "m"))) {
1969
+ if (h ?? (h = String(p)), t.colonNotation) {
1970
+ const f = h.includes(".") ? h.split(".")[0].length : h.length, E = n.length > 0 ? 2 : 1;
1971
+ h = "0".repeat(Math.max(0, E - f)) + h;
1972
1972
  } else
1973
- d += t.verbose ? " " + Ba(m, p) : c;
1974
- n.push(d);
1973
+ h += t.verbose ? " " + Ja(u, p) : c;
1974
+ n.push(h);
1975
1975
  }
1976
- }, i = Wa(e), u = BigInt(i.days);
1977
- if (t.hideYearAndDays ? s(BigInt(u) * 24n + BigInt(i.hours), "hour", "h") : (t.hideYear ? s(u, "day", "d") : (s(u / 365n, "year", "y"), s(u % 365n, "day", "d")), s(Number(i.hours), "hour", "h")), s(Number(i.minutes), "minute", "m"), !t.hideSeconds)
1976
+ }, i = Ga(e), d = BigInt(i.days);
1977
+ if (t.hideYearAndDays ? s(BigInt(d) * 24n + BigInt(i.hours), "hour", "h") : (t.hideYear ? s(d, "day", "d") : (s(d / 365n, "year", "y"), s(d % 365n, "day", "d")), s(Number(i.hours), "hour", "h")), s(Number(i.minutes), "minute", "m"), !t.hideSeconds)
1978
1978
  if (t.separateMilliseconds || t.formatSubMilliseconds || !t.colonNotation && e < 1e3) {
1979
- const p = Number(i.seconds), m = Number(i.milliseconds), c = Number(i.microseconds), d = Number(i.nanoseconds);
1979
+ const p = Number(i.seconds), u = Number(i.milliseconds), c = Number(i.microseconds), h = Number(i.nanoseconds);
1980
1980
  if (s(p, "second", "s"), t.formatSubMilliseconds)
1981
- s(m, "millisecond", "ms"), s(c, "microsecond", "µs"), s(d, "nanosecond", "ns");
1981
+ s(u, "millisecond", "ms"), s(c, "microsecond", "µs"), s(h, "nanosecond", "ns");
1982
1982
  else {
1983
- const f = m + c / 1e3 + d / 1e6, b = typeof t.millisecondsDecimalDigits == "number" ? t.millisecondsDecimalDigits : 0, T = f >= 1 ? Math.round(f) : Math.ceil(f), w = b ? f.toFixed(b) : T;
1983
+ const f = u + c / 1e3 + h / 1e6, E = typeof t.millisecondsDecimalDigits == "number" ? t.millisecondsDecimalDigits : 0, w = f >= 1 ? Math.round(f) : Math.ceil(f), _ = E ? f.toFixed(E) : w;
1984
1984
  s(
1985
- Number.parseFloat(w),
1985
+ Number.parseFloat(_),
1986
1986
  "millisecond",
1987
1987
  "ms",
1988
- w
1988
+ _
1989
1989
  );
1990
1990
  }
1991
1991
  } else {
1992
- const p = (r ? Number(e % Ya) : e) / 1e3 % 60, m = typeof t.secondsDecimalDigits == "number" ? t.secondsDecimalDigits : 1, c = o(p, m), d = t.keepDecimalsOnWholeSeconds ? c : c.replace(/\.0+$/, "");
1993
- s(Number.parseFloat(d), "second", "s", d);
1992
+ const p = (r ? Number(e % Ya) : e) / 1e3 % 60, u = typeof t.secondsDecimalDigits == "number" ? t.secondsDecimalDigits : 1, c = o(p, u), h = t.keepDecimalsOnWholeSeconds ? c : c.replace(/\.0+$/, "");
1993
+ s(Number.parseFloat(h), "second", "s", h);
1994
1994
  }
1995
1995
  if (n.length === 0)
1996
1996
  return a + "0" + (t.verbose ? " milliseconds" : "ms");
1997
- const h = t.colonNotation ? ":" : " ";
1998
- return typeof t.unitCount == "number" && (n = n.slice(0, Math.max(t.unitCount, 1))), a + n.join(h);
1997
+ const m = t.colonNotation ? ":" : " ";
1998
+ return typeof t.unitCount == "number" && (n = n.slice(0, Math.max(t.unitCount, 1))), a + n.join(m);
1999
1999
  }
2000
- const za = process.env.NODE_ENV === "production", tt = !za, ja = tt ? "gizmette.local.com" : "gizmette.com", Jo = (e, t) => e.length > t ? e.substring(0, t) + "..." : e, Yo = async () => {
2000
+ const za = process.env.NODE_ENV === "production", rt = !za, ja = rt ? "gizmette.local.com" : "gizmette.com", $o = async () => {
2001
2001
  const e = {
2002
2002
  /**
2003
2003
  * A boolean value that indicates the application would
@@ -2046,11 +2046,11 @@ const za = process.env.NODE_ENV === "production", tt = !za, ja = tt ? "gizmette.
2046
2046
  e
2047
2047
  );
2048
2048
  });
2049
- }, Fo = (e, t) => t ? Object.keys(t).map((r) => /* @__PURE__ */ l("dl", { className: "my-0", children: /* @__PURE__ */ _("div", { className: "flex items-center justify-between", children: [
2049
+ }, Uo = (e, t) => t ? Object.keys(t).map((r) => /* @__PURE__ */ l("dl", { className: "my-0", children: /* @__PURE__ */ I("div", { className: "flex items-center justify-between", children: [
2050
2050
  /* @__PURE__ */ l("dt", { className: "my-1 inline-block font-bold text-copy-dark dark:text-copy-lighter", children: r }),
2051
2051
  /* @__PURE__ */ l("dd", { className: "my-1 inline-block", children: t[r] })
2052
2052
  ] }) }, `${e}-${r}`)) : null;
2053
- function zo({
2053
+ function Ko({
2054
2054
  data: e,
2055
2055
  formatter: t = (r) => r
2056
2056
  }) {
@@ -2062,46 +2062,23 @@ function zo({
2062
2062
  );
2063
2063
  return t(a ? a / r.length : 0);
2064
2064
  }
2065
- const jo = (e, t) => t && t.messages.length > 0 && t.messages[t.messages.length - 1].message.role === e, qo = new Intl.NumberFormat("en", {
2065
+ const Ho = (e, t) => t && t.messages.length > 0 && t.messages[t.messages.length - 1].message.role === e, Wo = new Intl.NumberFormat("en", {
2066
2066
  style: "decimal",
2067
2067
  signDisplay: "never",
2068
2068
  minimumFractionDigits: 0,
2069
2069
  maximumFractionDigits: 0
2070
- }), Xo = (e) => e > 0 ? Fa(e, {
2070
+ }), Go = (e) => e > 0 ? Fa(e, {
2071
2071
  secondsDecimalDigits: 2,
2072
2072
  unitCount: 2
2073
- }) : "N/A", qa = (e) => y(
2073
+ }) : "N/A", qa = (e) => g(
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
- e || tt ? "pt-4" : "pt-10"
2076
- ), Qo = (e, t) => t === 1 ? e : `${e}s`, Zo = (e, t) => {
2075
+ e || rt ? "pt-4" : "pt-10"
2076
+ ), Bo = (e, t) => t === 1 ? e : `${e}s`, Jo = (e, t) => {
2077
2077
  let r;
2078
2078
  return (...a) => {
2079
2079
  window.clearTimeout(r), r = window.setTimeout(() => e(...a), t);
2080
2080
  };
2081
- }, Et = "av-button";
2082
- /*!
2083
- @versini/ui-spacing v1.1.0
2084
- © 2024 gizmette.com
2085
- */
2086
- try {
2087
- window.__VERSINI_UI_SPACING__ || (window.__VERSINI_UI_SPACING__ = {
2088
- version: "1.1.0",
2089
- buildTime: "12/26/2024 06:05 PM EST",
2090
- homepage: "https://github.com/aversini/ui-components",
2091
- license: "MIT"
2092
- });
2093
- } catch {
2094
- }
2095
- const Xa = (e) => {
2096
- let t = "";
2097
- if (typeof e == "number" || typeof e == "string")
2098
- t = "m-" + e;
2099
- else {
2100
- const r = [];
2101
- (e == null ? void 0 : e.t) !== void 0 && r.push(`mt-${e.t}`), (e == null ? void 0 : e.r) !== void 0 && r.push(`mr-${e.r}`), (e == null ? void 0 : e.b) !== void 0 && r.push(`mb-${e.b}`), (e == null ? void 0 : e.l) !== void 0 && r.push(`ml-${e.l}`), t = r.join(" ");
2102
- }
2103
- return t;
2104
- }, rt = "icon", Qt = "button", Qa = "link", Za = ({
2081
+ }, wt = "av-button", at = "icon", Zt = "button", Xa = "link", Qa = ({
2105
2082
  type: e,
2106
2083
  size: t,
2107
2084
  labelRight: r,
@@ -2110,20 +2087,20 @@ const Xa = (e) => {
2110
2087
  }) => {
2111
2088
  const o = "text-sm font-medium max-h-8 py-0", s = "text-base font-medium max-h-9 py-1", i = "text-lg font-medium max-h-12 py-2";
2112
2089
  switch (e) {
2113
- case Qt:
2114
- return y("px-4", {
2090
+ case Zt:
2091
+ return g("px-4", {
2115
2092
  [o]: t === "small",
2116
2093
  [s]: t === "medium",
2117
2094
  [i]: t === "large"
2118
2095
  });
2119
- case Qa:
2120
- return y("px-4 text-center", {
2096
+ case Xa:
2097
+ return g("px-4 text-center", {
2121
2098
  [o]: t === "small",
2122
2099
  [s]: t === "medium",
2123
2100
  [i]: t === "large"
2124
2101
  });
2125
- case rt:
2126
- return y("inline-flex items-center", {
2102
+ case at:
2103
+ return g("inline-flex items-center", {
2127
2104
  "justify-center": n === "center",
2128
2105
  "justify-start": n === "left",
2129
2106
  "justify-end": n === "right",
@@ -2135,16 +2112,24 @@ const Xa = (e) => {
2135
2112
  "h-12 px-4 text-lg font-medium": t === "large" && (r || a)
2136
2113
  });
2137
2114
  }
2138
- }, en = ({
2115
+ }, Za = ({
2139
2116
  mode: e,
2140
2117
  noBackground: t,
2141
2118
  noTruncate: r,
2142
- variant: a
2119
+ variant: a,
2120
+ radius: n
2143
2121
  }) => {
2144
2122
  if (t)
2145
- return "not-prose rounded-full";
2123
+ return g("not-prose", {
2124
+ "rounded-full": n === "large",
2125
+ "rounded-md": n === "medium",
2126
+ "rounded-sm": n === "small"
2127
+ });
2146
2128
  if (a === "primary")
2147
- return y("not-prose rounded-full", {
2129
+ return g("not-prose", {
2130
+ "rounded-full": n === "large",
2131
+ "rounded-md": n === "medium",
2132
+ "rounded-sm": n === "small",
2148
2133
  truncate: !r,
2149
2134
  "bg-action-dark text-copy-light": e === "dark",
2150
2135
  "bg-action-light text-copy-lighter": e === "light",
@@ -2152,7 +2137,10 @@ const Xa = (e) => {
2152
2137
  "bg-action-light text-copy-lighter dark:bg-action-dark dark:text-copy-light": e === "alt-system"
2153
2138
  });
2154
2139
  if (a === "secondary")
2155
- return y("not-prose rounded-full", {
2140
+ return g("not-prose", {
2141
+ "rounded-full": n === "large",
2142
+ "rounded-md": n === "medium",
2143
+ "rounded-sm": n === "small",
2156
2144
  truncate: !r,
2157
2145
  "bg-action-dark text-copy-light": e === "light",
2158
2146
  "bg-action-light text-copy-lighter": e === "dark",
@@ -2160,14 +2148,28 @@ const Xa = (e) => {
2160
2148
  "bg-action-light text-copy-lighter dark:bg-action-dark dark:text-copy-light": e === "system"
2161
2149
  });
2162
2150
  if (a === "danger")
2163
- return y("not-prose rounded-full", {
2151
+ return g("not-prose", {
2152
+ "rounded-full": n === "large",
2153
+ "rounded-md": n === "medium",
2154
+ "rounded-sm": n === "small",
2164
2155
  truncate: !r,
2165
2156
  "bg-action-danger-dark text-copy-light": e === "dark",
2166
2157
  "bg-action-danger-light text-copy-lighter": e === "light",
2167
2158
  "bg-action-danger-dark text-copy-light dark:bg-action-danger-light dark:text-copy-lighter": e === "system",
2168
2159
  "bg-action-danger-light text-copy-lighter dark:bg-action-danger-dark dark:text-copy-light": e === "alt-system"
2169
2160
  });
2170
- }, tn = ({
2161
+ if (a === "selected")
2162
+ return g("not-prose", {
2163
+ "rounded-full": n === "large",
2164
+ "rounded-md": n === "medium",
2165
+ "rounded-sm": n === "small",
2166
+ truncate: !r,
2167
+ "bg-action-selected-dark text-copy-light": e === "dark",
2168
+ "bg-action-selected-light text-copy-lighter": e === "light",
2169
+ "bg-action-selected-dark text-copy-light dark:bg-action-selected-light dark:text-copy-lighter": e === "system",
2170
+ "bg-action-selected-light text-copy-lighter dark:bg-action-selected-dark dark:text-copy-light": e === "alt-system"
2171
+ });
2172
+ }, en = ({
2171
2173
  mode: e,
2172
2174
  disabled: t,
2173
2175
  variant: r
@@ -2175,27 +2177,34 @@ const Xa = (e) => {
2175
2177
  if (t)
2176
2178
  return "";
2177
2179
  if (r === "primary")
2178
- return y("hover:text-copy-light-hover", {
2180
+ return g("hover:text-copy-light-hover", {
2179
2181
  "hover:bg-action-dark-hover": e === "dark",
2180
2182
  "hover:bg-action-light-hover": e === "light",
2181
2183
  "hover:bg-action-dark-hover dark:hover:bg-action-light-hover": e === "system",
2182
2184
  "hover:bg-action-light-hover dark:hover:bg-action-dark-hover": e === "alt-system"
2183
2185
  });
2184
2186
  if (r === "secondary")
2185
- return y("hover:text-copy-light-hover", {
2187
+ return g("hover:text-copy-light-hover", {
2186
2188
  "hover:bg-action-dark-hover": e === "light",
2187
2189
  "hover:bg-action-light-hover": e === "dark",
2188
2190
  "hover:bg-action-dark-hover dark:hover:bg-action-light-hover": e === "alt-system",
2189
2191
  "hover:bg-action-light-hover dark:hover:bg-action-dark-hover": e === "system"
2190
2192
  });
2191
2193
  if (r === "danger")
2192
- return y("hover:text-copy-light-hover", {
2194
+ return g("hover:text-copy-light-hover", {
2193
2195
  "hover:bg-action-danger-dark-hover": e === "dark",
2194
2196
  "hover:bg-action-danger-light-hover": e === "light",
2195
2197
  "hover:bg-action-danger-dark-hover dark:hover:bg-action-danger-light-hover": e === "system",
2196
2198
  "hover:bg-action-danger-light-hover dark:hover:bg-action-danger-dark-hover": e === "alt-system"
2197
2199
  });
2198
- }, rn = ({
2200
+ if (r === "selected")
2201
+ return g("hover:text-copy-light-hover", {
2202
+ "hover:bg-action-selected-dark-hover": e === "dark",
2203
+ "hover:bg-action-selected-light-hover": e === "light",
2204
+ "hover:bg-action-selected-dark-hover dark:hover:bg-action-selected-light-hover": e === "system",
2205
+ "hover:bg-action-selected-light-hover dark:hover:bg-action-selected-dark-hover": e === "alt-system"
2206
+ });
2207
+ }, tn = ({
2199
2208
  mode: e,
2200
2209
  disabled: t,
2201
2210
  variant: r
@@ -2203,27 +2212,34 @@ const Xa = (e) => {
2203
2212
  if (t)
2204
2213
  return "";
2205
2214
  if (r === "primary")
2206
- return y("active:text-copy-light-active", {
2215
+ return g("active:text-copy-light-active", {
2207
2216
  "active:bg-action-dark-active": e === "dark",
2208
2217
  "active:bg-action-light-active": e === "light",
2209
2218
  "active:bg-action-dark-active dark:active:bg-action-light-active": e === "system",
2210
2219
  "active:bg-action-light-active dark:active:bg-action-dark-active": e === "alt-system"
2211
2220
  });
2212
2221
  if (r === "secondary")
2213
- return y("active:text-copy-light-active", {
2222
+ return g("active:text-copy-light-active", {
2214
2223
  "active:bg-action-dark-active": e === "light",
2215
2224
  "active:bg-action-light-active": e === "dark",
2216
2225
  "active:bg-action-dark-active dark:active:bg-action-light-active": e === "alt-system",
2217
2226
  "active:bg-action-light-active dark:active:bg-action-dark-active": e === "system"
2218
2227
  });
2219
2228
  if (r === "danger")
2220
- return y("active:text-copy-lighter-active", {
2229
+ return g("active:text-copy-lighter-active", {
2221
2230
  "active:bg-action-danger-dark-active": e === "dark",
2222
2231
  "active:bg-action-danger-light-active": e === "light",
2223
2232
  "active:bg-action-danger-dark-active dark:active:bg-action-danger-light-active": e === "system",
2224
2233
  "active:bg-action-danger-light-active dark:active:bg-action-danger-dark-active": e === "alt-system"
2225
2234
  });
2226
- }, an = ({
2235
+ if (r === "selected")
2236
+ return g("active:text-copy-lighter-active", {
2237
+ "active:bg-action-selected-dark-active": e === "dark",
2238
+ "active:bg-action-selected-light-active": e === "light",
2239
+ "active:bg-action-selected-dark-active dark:active:bg-action-selected-light-active": e === "system",
2240
+ "active:bg-action-selected-light-active dark:active:bg-action-selected-dark-active": e === "alt-system"
2241
+ });
2242
+ }, rn = ({
2227
2243
  mode: e,
2228
2244
  noBorder: t,
2229
2245
  variant: r
@@ -2231,32 +2247,41 @@ const Xa = (e) => {
2231
2247
  if (t)
2232
2248
  return "border border-transparent";
2233
2249
  if (r === "primary")
2234
- return y("border", {
2250
+ return g("border", {
2235
2251
  "border-border-dark": e === "dark",
2236
2252
  "border-border-accent": e === "light",
2237
2253
  "border-border-dark dark:border-border-accent": e === "system",
2238
2254
  "border-border-accent dark:border-border-dark": e === "alt-system"
2239
2255
  });
2240
2256
  if (r === "secondary")
2241
- return y("border", {
2257
+ return g("border", {
2242
2258
  "border-border-dark": e === "light",
2243
2259
  "border-border-accent": e === "dark",
2244
2260
  "border-border-dark dark:border-border-accent": e === "alt-system",
2245
2261
  "border-border-accent dark:border-border-dark": e === "system"
2246
2262
  });
2247
2263
  if (r === "danger")
2248
- return y("border", {
2264
+ return g("border", {
2249
2265
  "border-border-danger-dark": e === "dark",
2250
2266
  "border-border-danger-medium": e === "light",
2251
2267
  "border-border-danger-dark dark:border-border-danger-medium": e === "system",
2252
2268
  "border-border-danger-medium dark:border-border-danger-dark": e === "alt-system"
2253
2269
  });
2254
- }, nn = ({ focusMode: e }) => y("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
2270
+ if (r === "selected")
2271
+ return g("border", {
2272
+ "border-border-selected-dark": e === "dark",
2273
+ "border-border-selected-medium": e === "light",
2274
+ "border-border-selected-dark dark:border-border-selected-medium": e === "system",
2275
+ "border-border-selected-medium dark:border-border-selected-dark": e === "alt-system"
2276
+ });
2277
+ }, an = ({
2278
+ focusMode: e
2279
+ }) => g("focus:outline", "focus:outline-2", "focus:outline-offset-2", {
2255
2280
  "focus:outline-focus-dark": e === "dark",
2256
2281
  "focus:outline-focus-light": e === "light",
2257
2282
  "focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
2258
2283
  "focus:outline-focus-dark dark:focus:outline-focus-light": e === "system"
2259
- }), at = ({
2284
+ }), nt = ({
2260
2285
  type: e,
2261
2286
  className: t,
2262
2287
  raw: r,
@@ -2265,46 +2290,51 @@ const Xa = (e) => {
2265
2290
  disabled: o,
2266
2291
  fullWidth: s,
2267
2292
  size: i,
2268
- noBorder: u,
2269
- labelRight: h,
2293
+ noBorder: d,
2294
+ labelRight: m,
2270
2295
  labelLeft: p,
2271
- spacing: m,
2272
- noBackground: c,
2273
- variant: d,
2274
- noTruncate: f,
2275
- align: b
2276
- }) => (d || (d = "primary"), r ? y(Et, t) : y(
2277
- Et,
2278
- t,
2279
- Xa(m),
2280
- en({ mode: a, variant: d, noBackground: c, noTruncate: f }),
2281
- Za({ type: e, size: i, labelRight: h, labelLeft: p, align: b }),
2282
- an({ mode: a, variant: d, noBorder: u }),
2283
- nn({ focusMode: n }),
2284
- tn({ mode: a, variant: d, disabled: o }),
2285
- rn({ mode: a, variant: d, disabled: o }),
2296
+ noBackground: u,
2297
+ variant: c,
2298
+ noTruncate: h,
2299
+ align: f,
2300
+ radius: E
2301
+ }) => (c || (c = "primary"), r ? g(wt, t) : g(
2302
+ wt,
2303
+ Za({
2304
+ mode: a,
2305
+ variant: c,
2306
+ noBackground: u,
2307
+ noTruncate: h,
2308
+ radius: E
2309
+ }),
2310
+ Qa({ type: e, size: i, labelRight: m, labelLeft: p, align: f }),
2311
+ rn({ mode: a, variant: c, noBorder: d }),
2312
+ an({ focusMode: n }),
2313
+ en({ mode: a, variant: c, disabled: o }),
2314
+ tn({ mode: a, variant: c, disabled: o }),
2286
2315
  {
2287
2316
  "w-full": s,
2288
2317
  "disabled:cursor-not-allowed disabled:opacity-50": o
2289
- }
2290
- )), on = (e, t, r) => {
2318
+ },
2319
+ t
2320
+ )), nn = (e, t, r) => {
2291
2321
  var a;
2292
2322
  !t && (!document.activeElement || document.activeElement !== e.currentTarget) && typeof ((a = e == null ? void 0 : e.currentTarget) == null ? void 0 : a.focus) == "function" && e.currentTarget.focus(), typeof r == "function" && r(e);
2293
- }, Le = P.forwardRef((e, t) => {
2323
+ }, Me = P.forwardRef((e, t) => {
2294
2324
  const { onClick: r, noInternalClick: a = !1, ...n } = e;
2295
2325
  return /* @__PURE__ */ l(
2296
2326
  "button",
2297
2327
  {
2298
2328
  ref: t,
2299
2329
  onClick: (o) => {
2300
- on(o, a, r);
2330
+ nn(o, a, r);
2301
2331
  },
2302
2332
  ...n
2303
2333
  }
2304
2334
  );
2305
2335
  });
2306
- Le.displayName = "BaseButton";
2307
- const Zt = P.forwardRef(
2336
+ Me.displayName = "BaseButton";
2337
+ const er = P.forwardRef(
2308
2338
  ({
2309
2339
  children: e,
2310
2340
  disabled: t = !1,
@@ -2314,14 +2344,14 @@ const Zt = P.forwardRef(
2314
2344
  className: o,
2315
2345
  size: s = "medium",
2316
2346
  raw: i = !1,
2317
- noBorder: u = !1,
2318
- spacing: h,
2319
- variant: p = "primary",
2320
- noTruncate: m = !1,
2347
+ noBorder: d = !1,
2348
+ variant: m = "primary",
2349
+ noTruncate: p = !1,
2350
+ radius: u = "large",
2321
2351
  ...c
2322
- }, d) => {
2323
- const f = at({
2324
- type: Qt,
2352
+ }, h) => {
2353
+ const f = nt({
2354
+ type: Zt,
2325
2355
  mode: r,
2326
2356
  focusMode: a,
2327
2357
  fullWidth: n,
@@ -2329,15 +2359,15 @@ const Zt = P.forwardRef(
2329
2359
  raw: i,
2330
2360
  className: o,
2331
2361
  size: s,
2332
- noBorder: u,
2333
- spacing: h,
2334
- variant: p,
2335
- noTruncate: m
2362
+ noBorder: d,
2363
+ variant: m,
2364
+ noTruncate: p,
2365
+ radius: u
2336
2366
  });
2337
2367
  return /* @__PURE__ */ l(
2338
- Le,
2368
+ Me,
2339
2369
  {
2340
- ref: d,
2370
+ ref: h,
2341
2371
  className: f,
2342
2372
  disabled: t,
2343
2373
  ...c,
@@ -2346,7 +2376,7 @@ const Zt = P.forwardRef(
2346
2376
  );
2347
2377
  }
2348
2378
  );
2349
- Zt.displayName = "Button";
2379
+ er.displayName = "Button";
2350
2380
  const qe = P.forwardRef(
2351
2381
  ({
2352
2382
  children: e,
@@ -2357,49 +2387,49 @@ const qe = P.forwardRef(
2357
2387
  className: o,
2358
2388
  type: s = "button",
2359
2389
  raw: i = !1,
2360
- noBorder: u = !1,
2361
- "aria-label": h,
2390
+ noBorder: d = !1,
2391
+ "aria-label": m,
2362
2392
  label: p,
2363
- size: m = "medium",
2393
+ size: u = "medium",
2364
2394
  labelRight: c,
2365
- labelLeft: d,
2366
- spacing: f,
2367
- noBackground: b = !1,
2368
- align: T = "center",
2369
- ...w
2370
- }, C) => {
2371
- const $ = at({
2372
- type: rt,
2395
+ labelLeft: h,
2396
+ noBackground: f = !1,
2397
+ align: E = "center",
2398
+ radius: w = "large",
2399
+ ..._
2400
+ }, U) => {
2401
+ const K = nt({
2402
+ type: at,
2373
2403
  mode: r,
2374
2404
  focusMode: a,
2375
2405
  fullWidth: n,
2376
2406
  disabled: t,
2377
2407
  raw: i,
2378
2408
  className: o,
2379
- noBorder: u,
2380
- size: m,
2409
+ noBorder: d,
2410
+ size: u,
2381
2411
  labelRight: c,
2382
- labelLeft: d,
2383
- spacing: f,
2384
- noBackground: b,
2385
- align: T
2386
- }), H = y({
2412
+ labelLeft: h,
2413
+ noBackground: f,
2414
+ align: E,
2415
+ radius: w
2416
+ }), H = g({
2387
2417
  "text-copy-accent-dark": r === "light" && !i,
2388
2418
  "text-copy-light": r === "dark" && !i,
2389
2419
  "text-copy-accent-dark dark:text-copy-light": r === "alt-system" && !i,
2390
2420
  "text-copy-light dark:text-copy-accent-dark": r === "system" && !i
2391
2421
  });
2392
- return /* @__PURE__ */ _(
2393
- Le,
2422
+ return /* @__PURE__ */ I(
2423
+ Me,
2394
2424
  {
2395
- ref: C,
2396
- className: $,
2425
+ ref: U,
2426
+ className: K,
2397
2427
  disabled: t,
2398
2428
  type: s,
2399
- "aria-label": h || p,
2400
- ...w,
2429
+ "aria-label": m || p,
2430
+ ..._,
2401
2431
  children: [
2402
- d && /* @__PURE__ */ l("span", { className: "pr-2", children: d }),
2432
+ h && /* @__PURE__ */ l("span", { className: "pr-2", children: h }),
2403
2433
  /* @__PURE__ */ l("div", { className: H, children: e }),
2404
2434
  c && /* @__PURE__ */ l("span", { className: "pl-2", children: c })
2405
2435
  ]
@@ -2409,19 +2439,19 @@ const qe = P.forwardRef(
2409
2439
  );
2410
2440
  qe.displayName = "ButtonIcon";
2411
2441
  /*!
2412
- @versini/ui-button v1.6.0
2442
+ @versini/ui-button v2.0.0
2413
2443
  © 2024 gizmette.com
2414
2444
  */
2415
2445
  try {
2416
2446
  window.__VERSINI_UI_BUTTON__ || (window.__VERSINI_UI_BUTTON__ = {
2417
- version: "1.6.0",
2418
- buildTime: "12/26/2024 06:05 PM EST",
2447
+ version: "2.0.0",
2448
+ buildTime: "12/29/2024 04:16 PM EST",
2419
2449
  homepage: "https://github.com/aversini/ui-components",
2420
2450
  license: "MIT"
2421
2451
  });
2422
2452
  } catch {
2423
2453
  }
2424
- const sn = P.forwardRef(
2454
+ const on = P.forwardRef(
2425
2455
  ({
2426
2456
  children: e,
2427
2457
  disabled: t = !1,
@@ -2431,39 +2461,39 @@ const sn = P.forwardRef(
2431
2461
  className: o,
2432
2462
  type: s = "button",
2433
2463
  raw: i = !1,
2434
- noBorder: u = !1,
2435
- "aria-label": h,
2464
+ noBorder: d = !1,
2465
+ "aria-label": m,
2436
2466
  label: p,
2437
- size: m = "medium",
2467
+ size: u = "medium",
2438
2468
  labelRight: c,
2439
- labelLeft: d,
2440
- spacing: f,
2441
- noBackground: b = !1,
2442
- align: T = "center",
2469
+ labelLeft: h,
2470
+ noBackground: f = !1,
2471
+ align: E = "center",
2443
2472
  active: w = !1,
2444
- ...C
2445
- }, $) => {
2446
- const H = at({
2447
- type: rt,
2473
+ radius: _ = "large",
2474
+ ...U
2475
+ }, K) => {
2476
+ const H = nt({
2477
+ type: at,
2448
2478
  mode: r,
2449
2479
  focusMode: a,
2450
2480
  fullWidth: n,
2451
2481
  disabled: t,
2452
2482
  raw: i,
2453
2483
  className: o,
2454
- noBorder: u,
2455
- size: m,
2484
+ noBorder: d,
2485
+ size: u,
2456
2486
  labelRight: c,
2457
- labelLeft: d,
2458
- spacing: f,
2459
- noBackground: b,
2460
- align: T
2461
- }), ee = y({
2487
+ labelLeft: h,
2488
+ noBackground: f,
2489
+ align: E,
2490
+ radius: _
2491
+ }), O = g({
2462
2492
  "text-copy-accent-dark": r === "light" && !i,
2463
2493
  "text-copy-light": r === "dark" && !i,
2464
2494
  "text-copy-accent-dark dark:text-copy-light": r === "alt-system" && !i,
2465
2495
  "text-copy-light dark:text-copy-accent-dark": r === "system" && !i
2466
- }), N = w ? y(
2496
+ }), W = w ? g(
2467
2497
  "relative",
2468
2498
  "focus-within:static",
2469
2499
  "focus-within:after:border-transparent",
@@ -2480,108 +2510,84 @@ const sn = P.forwardRef(
2480
2510
  "after:border-table-light dark:after:border-table-dark": r === "alt-system"
2481
2511
  }
2482
2512
  ) : "";
2483
- return /* @__PURE__ */ l("div", { className: N, children: /* @__PURE__ */ _(
2484
- Le,
2513
+ return /* @__PURE__ */ l("div", { className: W, children: /* @__PURE__ */ I(
2514
+ Me,
2485
2515
  {
2486
- ref: $,
2516
+ ref: K,
2487
2517
  className: H,
2488
2518
  disabled: t,
2489
2519
  type: s,
2490
- "aria-label": h || p,
2491
- ...C,
2520
+ "aria-label": m || p,
2521
+ ...U,
2492
2522
  children: [
2493
- d && /* @__PURE__ */ l("span", { className: "pr-2", children: d }),
2494
- /* @__PURE__ */ l("div", { className: ee, children: e }),
2523
+ h && /* @__PURE__ */ l("span", { className: "pr-2", children: h }),
2524
+ /* @__PURE__ */ l("div", { className: O, children: e }),
2495
2525
  c && /* @__PURE__ */ l("span", { className: "pl-2", children: c })
2496
2526
  ]
2497
2527
  }
2498
2528
  ) });
2499
2529
  }
2500
2530
  );
2501
- sn.displayName = "ButtonSort";
2531
+ on.displayName = "ButtonSort";
2502
2532
  /*!
2503
- @versini/ui-card v1.4.0
2533
+ @versini/ui-card v2.0.0
2504
2534
  © 2024 gizmette.com
2505
2535
  */
2506
2536
  try {
2507
2537
  window.__VERSINI_UI_CARD__ || (window.__VERSINI_UI_CARD__ = {
2508
- version: "1.4.0",
2509
- buildTime: "12/26/2024 06:05 PM EST",
2538
+ version: "2.0.0",
2539
+ buildTime: "12/29/2024 04:16 PM EST",
2510
2540
  homepage: "https://github.com/aversini/ui-components",
2511
2541
  license: "MIT"
2512
2542
  });
2513
2543
  } catch {
2514
2544
  }
2515
- const ke = "av-card";
2516
- function cn(e) {
2517
- const t = Tt();
2545
+ const ve = "av-card";
2546
+ function sn(e) {
2547
+ const t = kt();
2518
2548
  return `${e}${t}`;
2519
2549
  }
2520
- /*!
2521
- @versini/ui-spacing v1.1.0
2522
- © 2024 gizmette.com
2523
- */
2524
- try {
2525
- window.__VERSINI_UI_SPACING__ || (window.__VERSINI_UI_SPACING__ = {
2526
- version: "1.1.0",
2527
- buildTime: "12/26/2024 06:05 PM EST",
2528
- homepage: "https://github.com/aversini/ui-components",
2529
- license: "MIT"
2530
- });
2531
- } catch {
2532
- }
2533
- const ln = (e) => {
2534
- let t = "";
2535
- if (typeof e == "number" || typeof e == "string")
2536
- t = "m-" + e;
2537
- else {
2538
- const r = [];
2539
- (e == null ? void 0 : e.t) !== void 0 && r.push(`mt-${e.t}`), (e == null ? void 0 : e.r) !== void 0 && r.push(`mr-${e.r}`), (e == null ? void 0 : e.b) !== void 0 && r.push(`mb-${e.b}`), (e == null ? void 0 : e.l) !== void 0 && r.push(`ml-${e.l}`), t = r.join(" ");
2540
- }
2541
- return t;
2542
- }, dn = ({
2550
+ const cn = ({
2543
2551
  className: e,
2544
2552
  headerClassName: t,
2545
2553
  bodyClassName: r,
2546
2554
  footerClassName: a,
2547
- spacing: n,
2548
- mode: o,
2549
- compact: s,
2550
- noBorder: i
2555
+ mode: n,
2556
+ compact: o,
2557
+ noBorder: s
2551
2558
  }) => {
2552
- const u = y(
2553
- ke,
2554
- e,
2559
+ const i = g(
2560
+ ve,
2555
2561
  "rounded-md",
2556
- ln(n),
2557
2562
  {
2558
- "border-none": i,
2559
- "border-2": !i,
2560
- "p-4": !s,
2561
- "p-1 sm:p-2": s,
2562
- "border-border-accent bg-surface-darker text-copy-light": o === "darker",
2563
- "border-border-accent bg-surface-dark text-copy-light": o === "dark",
2564
- "border-border-dark bg-surface-lighter text-copy-dark": o === "light",
2565
- "border-border-dark bg-surface-lighter text-copy-dark dark:border-border-accent dark:bg-surface-dark dark:text-copy-light": o === "system",
2566
- "border-border-accent bg-surface-dark text-copy-light dark:border-border-dark dark:bg-surface-lighter dark:text-copy-dark": o === "alt-system"
2567
- }
2568
- ), h = t || y(`${ke}__header mt-0 border-b-2`, {
2569
- "text-copy-light border-border-accent": o === "darker",
2570
- "border-border-accent": o === "dark",
2571
- "border-border-medium": o === "light",
2572
- "border-border-medium dark:border-border-accent": o === "system",
2573
- "border-border-accent dark:border-border-medium": o === "alt-system",
2574
- "mb-4": !s,
2575
- "mb-2": s
2576
- }), p = y(r), m = a || y(`${ke}__footer pt-2`);
2563
+ "border-none": s,
2564
+ "border-2": !s,
2565
+ "p-4": !o,
2566
+ "p-1 sm:p-2": o,
2567
+ "border-border-accent bg-surface-darker text-copy-light": n === "darker",
2568
+ "border-border-accent bg-surface-dark text-copy-light": n === "dark",
2569
+ "border-border-dark bg-surface-lighter text-copy-dark": n === "light",
2570
+ "border-border-dark bg-surface-lighter text-copy-dark dark:border-border-accent dark:bg-surface-dark dark:text-copy-light": n === "system",
2571
+ "border-border-accent bg-surface-dark text-copy-light dark:border-border-dark dark:bg-surface-lighter dark:text-copy-dark": n === "alt-system"
2572
+ },
2573
+ e
2574
+ ), d = t || g(`${ve}__header mt-0 border-b-2`, {
2575
+ "text-copy-light border-border-accent": n === "darker",
2576
+ "border-border-accent": n === "dark",
2577
+ "border-border-medium": n === "light",
2578
+ "border-border-medium dark:border-border-accent": n === "system",
2579
+ "border-border-accent dark:border-border-medium": n === "alt-system",
2580
+ "mb-4": !o,
2581
+ "mb-2": o
2582
+ }), m = g(r), p = a || g(`${ve}__footer pt-2`);
2577
2583
  return {
2578
- wrapper: u,
2579
- header: h,
2580
- body: p,
2581
- footer: m
2584
+ wrapper: i,
2585
+ header: d,
2586
+ body: m,
2587
+ footer: p
2582
2588
  };
2583
2589
  };
2584
- function un({
2590
+ function ln({
2585
2591
  id: e,
2586
2592
  content: t,
2587
2593
  userAriaLabelledby: r,
@@ -2589,7 +2595,7 @@ function un({
2589
2595
  }) {
2590
2596
  return typeof t == "string" ? /* @__PURE__ */ l("h2", { id: e, className: a, children: t }) : r ? /* @__PURE__ */ l("div", { className: a, children: t }) : t ? /* @__PURE__ */ l("div", { className: a, id: e, children: t }) : null;
2591
2597
  }
2592
- const mn = ({
2598
+ const dn = ({
2593
2599
  header: e,
2594
2600
  headerClassName: t,
2595
2601
  footer: r,
@@ -2598,36 +2604,34 @@ const mn = ({
2598
2604
  className: o,
2599
2605
  bodyClassName: s,
2600
2606
  "aria-labelledby": i,
2601
- spacing: u,
2602
- mode: h = "system",
2603
- compact: p = !1,
2604
- noBorder: m = !1,
2605
- ...c
2607
+ mode: d = "system",
2608
+ compact: m = !1,
2609
+ noBorder: p = !1,
2610
+ ...u
2606
2611
  }) => {
2607
- let d = null, f = null;
2608
- const b = typeof e == "string", T = cn(ke), w = dn({
2612
+ let c = null, h = null;
2613
+ const f = typeof e == "string", E = sn(ve), w = cn({
2609
2614
  className: o,
2610
2615
  headerClassName: t,
2611
2616
  bodyClassName: s,
2612
2617
  footerClassName: a,
2613
- spacing: u,
2614
- mode: h,
2615
- compact: p,
2616
- noBorder: m
2618
+ mode: d,
2619
+ compact: m,
2620
+ noBorder: p
2617
2621
  });
2618
- return b ? (d = T, f = d) : !b && e && i ? (d = null, f = i) : !b && e && !i ? (d = T, f = d) : (d = null, f = i || null), /* @__PURE__ */ l("div", { className: w.wrapper, children: /* @__PURE__ */ _(
2622
+ return f ? (c = E, h = c) : !f && e && i ? (c = null, h = i) : !f && e && !i ? (c = E, h = c) : (c = null, h = i || null), /* @__PURE__ */ l("div", { className: w.wrapper, children: /* @__PURE__ */ I(
2619
2623
  "section",
2620
2624
  {
2621
- ...f && {
2622
- "aria-labelledby": f
2625
+ ...h && {
2626
+ "aria-labelledby": h
2623
2627
  },
2624
2628
  className: w.body,
2625
- ...c,
2629
+ ...u,
2626
2630
  children: [
2627
2631
  /* @__PURE__ */ l(
2628
- un,
2632
+ ln,
2629
2633
  {
2630
- ...d && { id: d },
2634
+ ...c && { id: c },
2631
2635
  content: e,
2632
2636
  className: w.header,
2633
2637
  userAriaLabelledby: i
@@ -2638,46 +2642,19 @@ const mn = ({
2638
2642
  ]
2639
2643
  }
2640
2644
  ) });
2641
- };
2642
- /*!
2643
- @versini/ui-spacing v1.1.0
2644
- © 2024 gizmette.com
2645
- */
2646
- try {
2647
- window.__VERSINI_UI_SPACING__ || (window.__VERSINI_UI_SPACING__ = {
2648
- version: "1.1.0",
2649
- buildTime: "12/26/2024 06:05 PM EST",
2650
- homepage: "https://github.com/aversini/ui-components",
2651
- license: "MIT"
2652
- });
2653
- } catch {
2654
- }
2655
- const hn = (e) => {
2656
- let t = "";
2657
- if (typeof e == "number" || typeof e == "string")
2658
- t = "m-" + e;
2659
- else {
2660
- const r = [];
2661
- (e == null ? void 0 : e.t) !== void 0 && r.push(`mt-${e.t}`), (e == null ? void 0 : e.r) !== void 0 && r.push(`mr-${e.r}`), (e == null ? void 0 : e.b) !== void 0 && r.push(`mb-${e.b}`), (e == null ? void 0 : e.l) !== void 0 && r.push(`ml-${e.l}`), t = r.join(" ");
2662
- }
2663
- return t;
2664
- }, Me = ({
2645
+ }, $e = ({
2665
2646
  children: e,
2666
2647
  fill: t,
2667
2648
  viewBox: r,
2668
2649
  className: a,
2669
2650
  defaultViewBox: n,
2670
2651
  defaultClassName: o,
2671
- spacing: s,
2672
- title: i,
2673
- semantic: u = !1,
2674
- ...h
2652
+ title: s,
2653
+ semantic: i = !1,
2654
+ ...d
2675
2655
  }) => {
2676
- const p = hn(s), m = y(
2677
- p,
2678
- a || o
2679
- );
2680
- return /* @__PURE__ */ _(fe, { children: [
2656
+ const m = g(a || o);
2657
+ return /* @__PURE__ */ I(fe, { children: [
2681
2658
  /* @__PURE__ */ l(
2682
2659
  "svg",
2683
2660
  {
@@ -2686,43 +2663,37 @@ const hn = (e) => {
2686
2663
  viewBox: r || n,
2687
2664
  fill: t || "currentColor",
2688
2665
  role: "img",
2689
- "aria-hidden": !u,
2666
+ "aria-hidden": !i,
2690
2667
  focusable: !1,
2691
- ...h,
2668
+ ...d,
2692
2669
  children: e
2693
2670
  }
2694
2671
  ),
2695
- i && u && /* @__PURE__ */ l("span", { className: "sr-only", children: i })
2672
+ s && i && /* @__PURE__ */ l("span", { className: "sr-only", children: s })
2696
2673
  ] });
2697
2674
  };
2698
2675
  /*!
2699
- @versini/ui-svgicon v1.1.0
2676
+ @versini/ui-svgicon v2.0.0
2700
2677
  © 2024 gizmette.com
2701
2678
  */
2702
2679
  try {
2703
2680
  window.__VERSINI_UI_SVGICON__ || (window.__VERSINI_UI_SVGICON__ = {
2704
- version: "1.1.0",
2705
- buildTime: "12/26/2024 06:05 PM EST",
2681
+ version: "2.0.0",
2682
+ buildTime: "12/29/2024 04:16 PM EST",
2706
2683
  homepage: "https://github.com/aversini/ui-components",
2707
2684
  license: "MIT"
2708
2685
  });
2709
2686
  } catch {
2710
2687
  }
2711
- const pn = ({
2712
- className: e,
2713
- viewBox: t,
2714
- spacing: r,
2715
- ...a
2716
- }) => /* @__PURE__ */ l(
2717
- Me,
2688
+ const un = ({ className: e, viewBox: t, ...r }) => /* @__PURE__ */ l(
2689
+ $e,
2718
2690
  {
2719
2691
  defaultViewBox: "0 0 1200 500",
2720
2692
  defaultClassName: "w-full",
2721
2693
  viewBox: t,
2722
2694
  className: e,
2723
- spacing: r,
2724
2695
  title: "Sassy Dog",
2725
- ...a,
2696
+ ...r,
2726
2697
  children: /* @__PURE__ */ l("g", { transform: "matrix(11.9092 0 0 11.9092 470.0017 250.0009)", id: "879221", children: /* @__PURE__ */ l(
2727
2698
  "path",
2728
2699
  {
@@ -2733,65 +2704,61 @@ const pn = ({
2733
2704
  }
2734
2705
  ) })
2735
2706
  }
2736
- ), gn = ({
2707
+ ), hn = ({
2737
2708
  className: e,
2738
2709
  viewBox: t,
2739
- spacing: r,
2740
- title: a,
2741
- monotone: n,
2742
- ...o
2743
- }) => /* @__PURE__ */ _(
2744
- Me,
2710
+ title: r,
2711
+ monotone: a,
2712
+ ...n
2713
+ }) => /* @__PURE__ */ I(
2714
+ $e,
2745
2715
  {
2746
2716
  defaultViewBox: "0 0 640 512",
2747
2717
  defaultClassName: "size-5",
2748
2718
  viewBox: t,
2749
2719
  className: e,
2750
- spacing: r,
2751
- title: a || "Hide",
2752
- ...o,
2720
+ title: r || "Hide",
2721
+ ...n,
2753
2722
  children: [
2754
2723
  /* @__PURE__ */ l(
2755
2724
  "path",
2756
2725
  {
2757
- opacity: n ? "1" : "0.4",
2726
+ opacity: a ? "1" : "0.4",
2758
2727
  d: "M360.8 380.3C339.4 392.8 314.6 400 288 400c-79.5 0-144-64.5-144-144c0-14.5 2.1-28.5 6.1-41.7L63.5 146c-29.4 34.7-49.9 70.8-61.1 97.6c-3.3 7.9-3.3 16.7 0 24.6C17.3 304 48.6 356 95.4 399.4C142.5 443.2 207.2 480 288 480c56.1 0 104.4-17.8 144.5-43.2l-71.7-56.5zM198.5 252.4c-3.7 .8-6.7 3.7-6.5 7.7c.3 6.9 1.3 13.8 3.2 20.7c13.7 51.2 66.4 81.6 117.6 67.9c1.9-.5 3.9-1.1 5.7-1.7l-120-94.6zm89-52.4l94.8 74.3c2.7-13.9 2.4-28.6-1.5-43.2c-11.1-41.5-47.8-69.4-88.6-71.1c-5.8-.2-9.2 6.1-7.4 11.7c2.1 6.4 3.3 13.2 3.3 20.3c0 2.7-.2 5.4-.5 8zM432 256c0 17.7-3.2 34.6-9 50.2l84.1 65.9c32.3-36.6 54.6-75.4 66.4-103.9c3.3-7.9 3.3-16.7 0-24.6c-14.9-35.7-46.2-87.7-93-131.1C433.5 68.8 368.8 32 288 32c-60 0-111.1 20.3-152.8 48.7L207 136.9c23.1-15.7 51-24.9 81-24.9c79.5 0 144 64.5 144 144z"
2759
2728
  }
2760
2729
  ),
2761
2730
  /* @__PURE__ */ l("path", { d: "M5.1 9.2C13.3-1.2 28.4-3.1 38.8 5.1l592 464c10.4 8.2 12.3 23.3 4.1 33.7s-23.3 12.3-33.7 4.1L9.2 42.9C-1.2 34.7-3.1 19.6 5.1 9.2z" })
2762
2731
  ]
2763
2732
  }
2764
- ), yn = ({
2733
+ ), mn = ({
2765
2734
  className: e,
2766
2735
  viewBox: t,
2767
- spacing: r,
2768
- title: a,
2769
- monotone: n,
2770
- ...o
2736
+ title: r,
2737
+ monotone: a,
2738
+ ...n
2771
2739
  }) => {
2772
- const s = n ? "1" : "0.4";
2773
- return /* @__PURE__ */ _(
2774
- Me,
2740
+ const o = a ? "1" : "0.4";
2741
+ return /* @__PURE__ */ I(
2742
+ $e,
2775
2743
  {
2776
2744
  defaultViewBox: "0 0 190 190",
2777
2745
  defaultClassName: "size-5",
2778
2746
  viewBox: t,
2779
2747
  className: e,
2780
- spacing: r,
2781
- title: a || "Passkey",
2782
- ...o,
2748
+ title: r || "Passkey",
2749
+ ...n,
2783
2750
  children: [
2784
2751
  /* @__PURE__ */ l(
2785
2752
  "path",
2786
2753
  {
2787
- opacity: s,
2754
+ opacity: o,
2788
2755
  d: "M172.32,96.79c0,13.78-8.48,25.5-20.29,29.78l7.14,11.83l-10.57,13l10.57,12.71l-17.04,22.87l-12.01-12.82 v-25.9v-22.56c-10.68-4.85-18.15-15.97-18.15-28.91c0-17.4,13.51-31.51,30.18-31.51C158.81,65.28,172.32,79.39,172.32,96.79z M142.14,101.61c4.02,0,7.28-3.4,7.28-7.6c0-4.2-3.26-7.61-7.28-7.61s-7.28,3.4-7.28,7.61 C134.85,98.21,138.12,101.61,142.14,101.61z"
2789
2756
  }
2790
2757
  ),
2791
2758
  /* @__PURE__ */ l(
2792
2759
  "path",
2793
2760
  {
2794
- opacity: s,
2761
+ opacity: o,
2795
2762
  d: "M172.41,96.88c0,13.62-8.25,25.23-19.83,29.67l6.58,11.84l-9.73,13l9.73,12.71l-17.03,23.05v-25.9v-32.77 v-26.87c4.02,0,7.28-3.41,7.28-7.6c0-4.2-3.26-7.61-7.28-7.61V65.28C158.86,65.28,172.41,79.43,172.41,96.88z"
2796
2763
  }
2797
2764
  ),
@@ -2800,28 +2767,26 @@ const pn = ({
2800
2767
  ]
2801
2768
  }
2802
2769
  );
2803
- }, fn = ({
2770
+ }, pn = ({
2804
2771
  className: e,
2805
2772
  viewBox: t,
2806
- spacing: r,
2807
- title: a,
2808
- monotone: n,
2809
- ...o
2810
- }) => /* @__PURE__ */ _(
2811
- Me,
2773
+ title: r,
2774
+ monotone: a,
2775
+ ...n
2776
+ }) => /* @__PURE__ */ I(
2777
+ $e,
2812
2778
  {
2813
2779
  defaultViewBox: "0 0 576 512",
2814
2780
  defaultClassName: "size-5",
2815
2781
  viewBox: t,
2816
2782
  className: e,
2817
- spacing: r,
2818
- title: a || "Show",
2819
- ...o,
2783
+ title: r || "Show",
2784
+ ...n,
2820
2785
  children: [
2821
2786
  /* @__PURE__ */ l(
2822
2787
  "path",
2823
2788
  {
2824
- opacity: n ? "1" : "0.4",
2789
+ opacity: a ? "1" : "0.4",
2825
2790
  d: "M95.4 112.6C142.5 68.8 207.2 32 288 32s145.5 36.8 192.6 80.6c46.8 43.5 78.1 95.4 93 131.1c3.3 7.9 3.3 16.7 0 24.6c-14.9 35.7-46.2 87.7-93 131.1C433.5 443.2 368.8 480 288 480s-145.5-36.8-192.6-80.6C48.6 356 17.3 304 2.5 268.3c-3.3-7.9-3.3-16.7 0-24.6C17.3 208 48.6 156 95.4 112.6zM288 400a144 144 0 1 0 0-288 144 144 0 1 0 0 288z"
2826
2791
  }
2827
2792
  ),
@@ -2830,91 +2795,44 @@ const pn = ({
2830
2795
  }
2831
2796
  );
2832
2797
  /*!
2833
- @versini/ui-icons v1.19.0
2798
+ @versini/ui-icons v2.0.0
2834
2799
  © 2024 gizmette.com
2835
2800
  */
2836
2801
  try {
2837
2802
  window.__VERSINI_UI_ICONS__ || (window.__VERSINI_UI_ICONS__ = {
2838
- version: "1.19.0",
2839
- buildTime: "12/26/2024 06:05 PM EST",
2803
+ version: "2.0.0",
2804
+ buildTime: "12/29/2024 04:16 PM EST",
2840
2805
  homepage: "https://github.com/aversini/ui-components",
2841
2806
  license: "MIT"
2842
2807
  });
2843
2808
  } catch {
2844
2809
  }
2845
2810
  /*!
2846
- @versini/ui-main v1.4.0
2811
+ @versini/ui-main v2.0.0
2847
2812
  © 2024 gizmette.com
2848
2813
  */
2849
2814
  try {
2850
2815
  window.__VERSINI_UI_MAIN__ || (window.__VERSINI_UI_MAIN__ = {
2851
- version: "1.4.0",
2852
- buildTime: "12/26/2024 06:05 PM EST",
2853
- homepage: "https://github.com/aversini/ui-components",
2854
- license: "MIT"
2855
- });
2856
- } catch {
2857
- }
2858
- const bn = "av-main";
2859
- /*!
2860
- @versini/ui-spacing v1.1.0
2861
- © 2024 gizmette.com
2862
- */
2863
- try {
2864
- window.__VERSINI_UI_SPACING__ || (window.__VERSINI_UI_SPACING__ = {
2865
- version: "1.1.0",
2866
- buildTime: "12/26/2024 06:05 PM EST",
2816
+ version: "2.0.0",
2817
+ buildTime: "12/29/2024 04:16 PM EST",
2867
2818
  homepage: "https://github.com/aversini/ui-components",
2868
2819
  license: "MIT"
2869
2820
  });
2870
2821
  } catch {
2871
2822
  }
2872
- const En = (e) => {
2873
- let t = "";
2874
- if (typeof e == "number" || typeof e == "string")
2875
- t = "m-" + e;
2876
- else {
2877
- const r = [];
2878
- (e == null ? void 0 : e.t) !== void 0 && r.push(`mt-${e.t}`), (e == null ? void 0 : e.r) !== void 0 && r.push(`mr-${e.r}`), (e == null ? void 0 : e.b) !== void 0 && r.push(`mb-${e.b}`), (e == null ? void 0 : e.l) !== void 0 && r.push(`ml-${e.l}`), t = r.join(" ");
2879
- }
2880
- return t;
2881
- }, wn = ({
2882
- children: e,
2883
- className: t,
2884
- raw: r = !1,
2885
- spacing: a
2886
- }) => {
2887
- const n = y(t, bn, En(a), {
2888
- "mt-2 flex w-full flex-col p-2 sm:mt-3 md:mx-auto md:max-w-4xl": !r
2889
- });
2890
- return /* @__PURE__ */ l("main", { className: n, children: e });
2891
- };
2892
- /*!
2893
- @versini/ui-spacing v1.1.0
2894
- © 2024 gizmette.com
2895
- */
2896
- try {
2897
- window.__VERSINI_UI_SPACING__ || (window.__VERSINI_UI_SPACING__ = {
2898
- version: "1.1.0",
2899
- buildTime: "12/26/2024 06:05 PM EST",
2900
- homepage: "https://github.com/aversini/ui-components",
2901
- license: "MIT"
2902
- });
2903
- } catch {
2904
- }
2905
- const In = (e) => {
2906
- let t = "";
2907
- if (typeof e == "number" || typeof e == "string")
2908
- t = "m-" + e;
2909
- else {
2910
- const r = [];
2911
- (e == null ? void 0 : e.t) !== void 0 && r.push(`mt-${e.t}`), (e == null ? void 0 : e.r) !== void 0 && r.push(`mr-${e.r}`), (e == null ? void 0 : e.b) !== void 0 && r.push(`mb-${e.b}`), (e == null ? void 0 : e.l) !== void 0 && r.push(`ml-${e.l}`), t = r.join(" ");
2912
- }
2913
- return t;
2914
- }, _n = "av-flexgrid", ve = "av-flexgrid-item", Oe = 0.25, er = P.createContext({
2823
+ const gn = "av-main", yn = ({ children: e, className: t, raw: r = !1 }) => {
2824
+ const a = g(
2825
+ gn,
2826
+ {
2827
+ "mt-2 flex w-full flex-col p-2 sm:mt-3 md:mx-auto md:max-w-4xl": !r
2828
+ },
2829
+ t
2830
+ );
2831
+ return /* @__PURE__ */ l("main", { className: a, children: e });
2832
+ }, fn = "av-flexgrid", Se = "av-flexgrid-item", Oe = 0.25, Xe = P.createContext({
2915
2833
  columnGap: 0,
2916
2834
  rowGap: 0
2917
- }), wt = ({
2835
+ }), Tt = ({
2918
2836
  children: e,
2919
2837
  className: t,
2920
2838
  columnGap: r = 1,
@@ -2923,14 +2841,13 @@ const In = (e) => {
2923
2841
  width: o = "auto",
2924
2842
  direction: s = "row",
2925
2843
  alignHorizontal: i = "normal",
2926
- alignVertical: u = "normal",
2927
- spacing: h,
2928
- ...p
2844
+ alignVertical: d = "normal",
2845
+ ...m
2929
2846
  }) => {
2930
- const m = {
2847
+ const p = {
2931
2848
  flexDirection: s,
2932
2849
  justifyContent: i,
2933
- alignItems: u,
2850
+ alignItems: d,
2934
2851
  height: n,
2935
2852
  width: o,
2936
2853
  /**
@@ -2940,13 +2857,12 @@ const In = (e) => {
2940
2857
  */
2941
2858
  marginLeft: r * -1 * Oe + "rem",
2942
2859
  marginTop: a * -1 * Oe + "rem"
2943
- }, c = y(
2944
- _n,
2945
- t,
2860
+ }, u = g(
2861
+ fn,
2946
2862
  "box-border flex flex-wrap"
2947
- ), d = { columnGap: r, rowGap: a }, f = h ? "div" : P.Fragment;
2948
- return /* @__PURE__ */ l(f, { ...h ? { className: In(h) } : {}, children: /* @__PURE__ */ l("div", { className: c, style: m, ...p, children: /* @__PURE__ */ l(er.Provider, { value: d, children: e }) }) });
2949
- }, Ye = (e, t) => y({
2863
+ ), c = { columnGap: r, rowGap: a };
2864
+ return t ? /* @__PURE__ */ l("div", { className: t, children: /* @__PURE__ */ l("div", { className: u, style: p, ...m, children: /* @__PURE__ */ l(Xe.Provider, { value: c, children: e }) }) }) : /* @__PURE__ */ l("div", { className: u, style: p, ...m, children: /* @__PURE__ */ l(Xe.Provider, { value: c, children: e }) });
2865
+ }, Ye = (e, t) => g({
2950
2866
  "basis-1/12": e === 1 && !t,
2951
2867
  "sm:basis-1/12": e === 1 && t === "sm",
2952
2868
  "md:basis-1/12": e === 1 && t === "md",
@@ -3019,25 +2935,25 @@ const In = (e) => {
3019
2935
  "lg:basis-full": e === 12 && t === "lg",
3020
2936
  "xl:basis-full": e === 12 && t === "xl",
3021
2937
  "2xl:basis-full": e === 12 && t === "2xl"
3022
- }), Tn = ({
2938
+ }), bn = ({
3023
2939
  className: e,
3024
2940
  span: t
3025
2941
  }) => {
3026
2942
  if (!t)
3027
- return y(e, ve, "box-border basis-auto");
2943
+ return g(e, Se, "box-border basis-auto");
3028
2944
  if (typeof t == "number")
3029
- return y(e, ve, "box-border max-w-full", {
2945
+ return g(e, Se, "box-border max-w-full", {
3030
2946
  [`${Ye(t)}`]: !0
3031
2947
  });
3032
2948
  if (typeof t == "string")
3033
- return y(e, ve, "box-border basis-auto", {
2949
+ return g(e, Se, "box-border basis-auto", {
3034
2950
  "max-w-full grow": t === "auto"
3035
2951
  });
3036
2952
  if (typeof t == "object") {
3037
2953
  const r = Object.entries(t).map(([a, n]) => a === "fallback" ? Ye(n) : Ye(n, a));
3038
- return y(
2954
+ return g(
3039
2955
  e,
3040
- ve,
2956
+ Se,
3041
2957
  "box-border",
3042
2958
  r
3043
2959
  );
@@ -3048,36 +2964,36 @@ const In = (e) => {
3048
2964
  span: r,
3049
2965
  ...a
3050
2966
  }) => {
3051
- const { columnGap: n, rowGap: o } = Xe(er), s = {
2967
+ const { columnGap: n, rowGap: o } = Qe(Xe), s = {
3052
2968
  paddingLeft: n * Oe + "rem",
3053
2969
  paddingTop: o * Oe + "rem"
3054
- }, i = Tn({
2970
+ }, i = bn({
3055
2971
  className: t,
3056
2972
  span: r
3057
2973
  });
3058
2974
  return /* @__PURE__ */ l("div", { className: i, style: s, ...a, children: e });
3059
2975
  };
3060
2976
  /*!
3061
- @versini/ui-system v1.8.0
2977
+ @versini/ui-system v2.0.1
3062
2978
  © 2024 gizmette.com
3063
2979
  */
3064
2980
  try {
3065
2981
  window.__VERSINI_UI_SYSTEM__ || (window.__VERSINI_UI_SYSTEM__ = {
3066
- version: "1.8.0",
3067
- buildTime: "12/26/2024 06:05 PM EST",
2982
+ version: "2.0.1",
2983
+ buildTime: "12/29/2024 06:28 PM EST",
3068
2984
  homepage: "https://github.com/aversini/ui-components",
3069
2985
  license: "MIT"
3070
2986
  });
3071
2987
  } catch {
3072
2988
  }
3073
- const tr = "av-text-input", Sn = "av-text-input-wrapper", Fe = "av-text-input-helper-text";
3074
- function vn() {
3075
- const e = K(!1);
3076
- return Z(() => (e.current = !0, () => {
2989
+ const tr = "av-text-input", En = "av-text-input-wrapper", Fe = "av-text-input-helper-text";
2990
+ function wn() {
2991
+ const e = $(!1);
2992
+ return Q(() => (e.current = !0, () => {
3077
2993
  e.current = !1;
3078
- }), []), X(() => e.current, []);
2994
+ }), []), q(() => e.current, []);
3079
2995
  }
3080
- const An = {
2996
+ const Tn = {
3081
2997
  x: 0,
3082
2998
  y: 0,
3083
2999
  width: 0,
@@ -3087,19 +3003,19 @@ const An = {
3087
3003
  bottom: 0,
3088
3004
  right: 0
3089
3005
  };
3090
- function kn(e) {
3091
- const t = vn(), r = K(0), a = K(null), [n, o] = q(An), s = St(() => typeof ResizeObserver > "u" ? null : new ResizeObserver((i) => {
3092
- const u = i[0];
3093
- u && (cancelAnimationFrame(r.current), r.current = requestAnimationFrame(() => {
3094
- a.current && t() && o(u.contentRect);
3006
+ function In(e) {
3007
+ const t = wn(), r = $(0), a = $(null), [n, o] = j(Tn), s = St(() => typeof ResizeObserver > "u" ? null : new ResizeObserver((i) => {
3008
+ const d = i[0];
3009
+ d && (cancelAnimationFrame(r.current), r.current = requestAnimationFrame(() => {
3010
+ a.current && t() && o(d.contentRect);
3095
3011
  }));
3096
3012
  }), [t]);
3097
- return Z(() => (a.current && (s == null || s.observe(a.current, e)), () => {
3013
+ return Q(() => (a.current && (s == null || s.observe(a.current, e)), () => {
3098
3014
  s == null || s.disconnect(), r.current && cancelAnimationFrame(r.current);
3099
3015
  }), [s, e]), [a, n];
3100
3016
  }
3101
- function Nn(e) {
3102
- const t = Tt();
3017
+ function _n(e) {
3018
+ const t = kt();
3103
3019
  if (!e)
3104
3020
  return t;
3105
3021
  if (typeof e == "number" || typeof e == "string")
@@ -3109,7 +3025,7 @@ function Nn(e) {
3109
3025
  return typeof r == "number" || typeof r == "string" ? `${a}${r}` : `${a}${t}`;
3110
3026
  }
3111
3027
  }
3112
- const rr = "SET_ANNOUNCEMENT", ar = "CLEAR_ANNOUNCEMENT", Rn = {
3028
+ const rr = "SET_ANNOUNCEMENT", ar = "CLEAR_ANNOUNCEMENT", kn = {
3113
3029
  alert: null,
3114
3030
  alertdialog: null,
3115
3031
  log: "polite",
@@ -3117,7 +3033,7 @@ const rr = "SET_ANNOUNCEMENT", ar = "CLEAR_ANNOUNCEMENT", Rn = {
3117
3033
  progressbar: null,
3118
3034
  status: "polite",
3119
3035
  timer: "assertive"
3120
- }, xn = (e, t) => {
3036
+ }, Sn = (e, t) => {
3121
3037
  switch (t == null ? void 0 : t.type) {
3122
3038
  case rr:
3123
3039
  return {
@@ -3132,7 +3048,7 @@ const rr = "SET_ANNOUNCEMENT", ar = "CLEAR_ANNOUNCEMENT", Rn = {
3132
3048
  default:
3133
3049
  return e;
3134
3050
  }
3135
- }, Cn = ({
3051
+ }, An = ({
3136
3052
  onAnnouncementClear: e,
3137
3053
  dispatch: t
3138
3054
  }) => {
@@ -3150,13 +3066,13 @@ const rr = "SET_ANNOUNCEMENT", ar = "CLEAR_ANNOUNCEMENT", Rn = {
3150
3066
  type: rr,
3151
3067
  payload: e
3152
3068
  }), t && (r.current = setTimeout(
3153
- () => Cn({
3069
+ () => An({
3154
3070
  onAnnouncementClear: a,
3155
3071
  dispatch: n
3156
3072
  }),
3157
3073
  t
3158
3074
  ));
3159
- }, On = ({
3075
+ }, vn = ({
3160
3076
  children: e,
3161
3077
  announcementTimeoutRef: t,
3162
3078
  announcementDelay: r,
@@ -3188,15 +3104,15 @@ function nr({
3188
3104
  clearAnnouncementDelay: o,
3189
3105
  onAnnouncementClear: s,
3190
3106
  visible: i,
3191
- ...u
3107
+ ...d
3192
3108
  }) {
3193
- const h = K(null), p = K(null), [m, c] = _t(xn, {
3109
+ const m = $(null), p = $(null), [u, c] = _t(Sn, {
3194
3110
  announcement: null
3195
3111
  });
3196
- let d = r;
3197
- typeof d > "u" && (d = a ? Rn[a] : "assertive"), Z(() => {
3198
- On({
3199
- announcementTimeoutRef: h,
3112
+ let h = r;
3113
+ typeof h > "u" && (h = a ? kn[a] : "assertive"), Q(() => {
3114
+ vn({
3115
+ announcementTimeoutRef: m,
3200
3116
  announcementDelay: n,
3201
3117
  children: e,
3202
3118
  clearAnnouncementDelay: o,
@@ -3210,78 +3126,56 @@ function nr({
3210
3126
  o,
3211
3127
  s
3212
3128
  ]);
3213
- const f = y(t, {
3129
+ const f = g(t, {
3214
3130
  "sr-only": !i
3215
3131
  });
3216
3132
  return /* @__PURE__ */ l(
3217
3133
  "div",
3218
3134
  {
3219
- "aria-live": d,
3135
+ "aria-live": h,
3220
3136
  ...a && { role: a },
3221
3137
  className: f,
3222
- ...u,
3223
- children: m.announcement
3138
+ ...d,
3139
+ children: u.announcement
3224
3140
  }
3225
3141
  );
3226
3142
  }
3227
3143
  /*!
3228
- @versini/ui-liveregion v1.2.0
3144
+ @versini/ui-liveregion v1.2.2
3229
3145
  © 2024 gizmette.com
3230
3146
  */
3231
3147
  try {
3232
3148
  window.__VERSINI_UI_LIVEREGION__ || (window.__VERSINI_UI_LIVEREGION__ = {
3233
- version: "1.2.0",
3234
- buildTime: "12/26/2024 06:05 PM EST",
3149
+ version: "1.2.2",
3150
+ buildTime: "12/29/2024 04:16 PM EST",
3235
3151
  homepage: "https://github.com/aversini/ui-components",
3236
3152
  license: "MIT"
3237
3153
  });
3238
3154
  } catch {
3239
3155
  }
3240
- /*!
3241
- @versini/ui-spacing v1.1.0
3242
- © 2024 gizmette.com
3243
- */
3244
- try {
3245
- window.__VERSINI_UI_SPACING__ || (window.__VERSINI_UI_SPACING__ = {
3246
- version: "1.1.0",
3247
- buildTime: "12/26/2024 06:05 PM EST",
3248
- homepage: "https://github.com/aversini/ui-components",
3249
- license: "MIT"
3250
- });
3251
- } catch {
3252
- }
3253
- const Pn = (e) => {
3254
- let t = "";
3255
- if (typeof e == "number" || typeof e == "string")
3256
- t = "m-" + e;
3257
- else {
3258
- const r = [];
3259
- (e == null ? void 0 : e.t) !== void 0 && r.push(`mt-${e.t}`), (e == null ? void 0 : e.r) !== void 0 && r.push(`mr-${e.r}`), (e == null ? void 0 : e.b) !== void 0 && r.push(`mb-${e.b}`), (e == null ? void 0 : e.l) !== void 0 && r.push(`ml-${e.l}`), t = r.join(" ");
3260
- }
3261
- return t;
3262
- }, Dn = ({
3156
+ const Nn = ({
3263
3157
  mode: e
3264
- }) => y({
3158
+ }) => g({
3265
3159
  "bg-surface-darker text-copy-lighter caret-copy-light": e === "dark",
3266
3160
  "bg-surface-lighter text-copy-dark caret-copy-dark": e === "light",
3267
3161
  "bg-surface-lighter text-copy-dark caret-copy-dark dark:bg-surface-darker dark:text-copy-lighter dark:caret-copy-light": e === "system",
3268
3162
  "bg-surface-darker text-copy-lighter caret-copy-light dark:bg-surface-lighter dark:text-copy-dark dark:caret-copy-dark": e === "alt-system"
3269
- }), $n = ({
3163
+ }), Rn = ({
3270
3164
  focusMode: e
3271
- }) => y("focus:outline focus:outline-2 focus:outline-offset-2", {
3165
+ }) => g("focus:outline focus:outline-2 focus:outline-offset-2", {
3272
3166
  "focus:outline-focus-dark": e === "dark",
3273
3167
  "focus:outline-focus-light": e === "light",
3274
3168
  "focus:outline-focus-light dark:focus:outline-focus-dark": e === "alt-system",
3275
3169
  "focus:outline-focus-dark dark:focus:outline-focus-light": e === "system"
3276
- }), Ln = ({
3170
+ }), xn = ({
3277
3171
  noBorder: e,
3278
3172
  error: t
3279
- }) => y("border-2", {
3173
+ }) => g("border-2", {
3280
3174
  "border-border-dark": !e && !t,
3281
3175
  "focus:border-border-dark": !e && t,
3282
3176
  "border-border-error-dark": !e && t,
3283
3177
  "border-transparent": e
3284
- }), Mn = ({
3178
+ }), Cn = ({
3285
3179
  disabled: e,
3286
3180
  raw: t,
3287
3181
  error: r,
@@ -3290,22 +3184,22 @@ const Pn = (e) => {
3290
3184
  if (t)
3291
3185
  return "";
3292
3186
  if (e)
3293
- return y("absolute px-2 cursor-not-allowed opacity-50 font-medium");
3187
+ return g("absolute px-2 cursor-not-allowed opacity-50 font-medium");
3294
3188
  if (!r)
3295
- return y("absolute px-2 cursor-text font-medium", {
3189
+ return g("absolute px-2 cursor-text font-medium", {
3296
3190
  "text-copy-lighter": a === "dark",
3297
3191
  "text-copy-dark": a === "light",
3298
3192
  "text-copy-dark dark:text-copy-lighter": a === "system",
3299
3193
  "text-copy-lighter dark:text-copy-dark": a === "alt-system"
3300
3194
  });
3301
3195
  if (r)
3302
- return y("absolute px-2 cursor-text font-medium", {
3196
+ return g("absolute px-2 cursor-text font-medium", {
3303
3197
  "text-copy-lighter": a === "dark",
3304
3198
  "text-copy-error-dark": a === "light",
3305
3199
  "text-copy-error-dark dark:text-copy-error-light dark:bg-surface-darker": a === "system",
3306
3200
  "text-copy-lighter dark:text-copy-error-dark": a === "alt-system"
3307
3201
  });
3308
- }, Un = ({
3202
+ }, On = ({
3309
3203
  error: e,
3310
3204
  raw: t,
3311
3205
  mode: r,
@@ -3314,92 +3208,90 @@ const Pn = (e) => {
3314
3208
  if (t)
3315
3209
  return "";
3316
3210
  if (a)
3317
- return y(
3211
+ return g(
3318
3212
  Fe,
3319
3213
  "absolute px-2 cursor-not-allowed opacity-50 font-medium"
3320
3214
  );
3321
3215
  if (!e)
3322
- return y(Fe, "absolute px-2 font-medium", {
3216
+ return g(Fe, "absolute px-2 font-medium", {
3323
3217
  "text-copy-lighter": r === "dark",
3324
3218
  "text-copy-dark": r === "light",
3325
3219
  "text-copy-dark dark:text-copy-lighter": r === "system",
3326
3220
  "text-copy-lighter dark:text-copy-dark": r === "alt-system"
3327
3221
  });
3328
3222
  if (e)
3329
- return y(Fe, "absolute px-2 font-medium", {
3223
+ return g(Fe, "absolute px-2 font-medium", {
3330
3224
  "text-copy-error-light bg-surface-darker": r === "dark",
3331
3225
  "text-copy-error-dark": r === "light",
3332
3226
  "text-copy-error-dark dark:text-copy-error-light dark:bg-surface-darker": r === "system",
3333
3227
  "dark:text-copy-error-dark text-copy-error-light bg-surface-darker": r === "alt-system"
3334
3228
  });
3335
- }, Kn = ({
3229
+ }, Pn = ({
3336
3230
  className: e,
3337
3231
  inputClassName: t,
3338
3232
  raw: r,
3339
3233
  disabled: a,
3340
3234
  noBorder: n,
3341
3235
  error: o,
3342
- spacing: s,
3343
- mode: i,
3344
- focusMode: u,
3345
- size: h,
3346
- rightElementClassName: p
3236
+ mode: s,
3237
+ focusMode: i,
3238
+ size: d,
3239
+ rightElementClassName: m
3347
3240
  }) => {
3348
- const m = r ? e : y(
3241
+ const p = r ? e : g(
3349
3242
  "relative flex w-full flex-col justify-center",
3350
- Sn,
3351
- e,
3352
- Pn(s)
3243
+ En,
3244
+ e
3353
3245
  );
3354
- let c = "";
3355
- switch (h) {
3246
+ let u = "";
3247
+ switch (d) {
3356
3248
  case "xs":
3357
- c = "h-8";
3249
+ u = "h-8";
3358
3250
  break;
3359
3251
  case "sm":
3360
- c = "h-10";
3252
+ u = "h-10";
3361
3253
  break;
3362
3254
  case "lg":
3363
- c = "h-14";
3255
+ u = "h-14";
3364
3256
  break;
3365
3257
  case "xl":
3366
- c = "h-16";
3258
+ u = "h-16";
3367
3259
  break;
3368
3260
  default:
3369
- c = "h-12";
3261
+ u = "h-12";
3370
3262
  break;
3371
3263
  }
3372
- const d = r ? y(t) : y(
3264
+ const c = r ? g(t) : g(
3373
3265
  tr,
3374
- t,
3375
- c,
3266
+ u,
3376
3267
  "rounded-md text-base px-4",
3377
- Dn({ mode: i }),
3378
- $n({ focusMode: u }),
3379
- Ln({ noBorder: n, error: o }),
3268
+ Nn({ mode: s }),
3269
+ Rn({ focusMode: i }),
3270
+ xn({ noBorder: n, error: o }),
3380
3271
  {
3381
3272
  "disabled:cursor-not-allowed disabled:opacity-50": a
3382
- }
3383
- ), f = r ? void 0 : "sr-only", b = Mn({
3273
+ },
3274
+ t
3275
+ ), h = r ? void 0 : "sr-only", f = Cn({
3384
3276
  disabled: a,
3385
3277
  raw: r,
3386
3278
  error: o,
3387
- mode: i
3388
- }), T = Un({
3279
+ mode: s
3280
+ }), E = On({
3389
3281
  error: o,
3390
3282
  raw: r,
3391
- mode: i,
3283
+ mode: s,
3392
3284
  disabled: a
3393
- }), w = r ? void 0 : y("absolute right-3", p);
3285
+ }), w = r ? void 0 : g("absolute right-3", m);
3394
3286
  return {
3395
- wrapper: m,
3396
- input: d,
3397
- accessibleLabel: f,
3398
- visibleLabel: b,
3399
- helperText: T,
3287
+ wrapper: p,
3288
+ input: c,
3289
+ accessibleLabel: h,
3290
+ visibleLabel: f,
3291
+ helperText: E,
3400
3292
  rightElement: w
3401
3293
  };
3402
- }, nt = P.forwardRef(
3294
+ }, ot = P.forwardRef(
3403
3295
  ({
3404
3296
  id: e,
3405
3297
  name: t,
@@ -3409,106 +3301,104 @@ const Pn = (e) => {
3409
3301
  className: o,
3410
3302
  inputClassName: s,
3411
3303
  mode: i = "system",
3412
- focusMode: u = "system",
3413
- disabled: h = !1,
3304
+ focusMode: d = "system",
3305
+ disabled: m = !1,
3414
3306
  noBorder: p = !1,
3415
- labelId: m,
3307
+ labelId: u,
3416
3308
  labelHidden: c = !1,
3417
- type: d = "text",
3309
+ type: h = "text",
3418
3310
  helperText: f = "",
3419
- rightElement: b,
3420
- rightElementClassName: T,
3421
- spacing: w,
3422
- size: C = "md",
3423
- ...$
3424
- }, H) => {
3425
- const [ee, N] = kn(), [J, D] = q(0), Y = Nn({ id: e, prefix: `${tr}-` }), pe = `${t} error, ${f}`, te = K(null), R = K(null), L = {
3311
+ rightElement: E,
3312
+ rightElementClassName: w,
3313
+ size: _ = "md",
3314
+ ...U
3315
+ }, K) => {
3316
+ const [H, O] = In(), [W, G] = j(0), x = _n({ id: e, prefix: `${tr}-` }), pe = `${t} error, ${f}`, Z = $(null), N = $(null), D = {
3426
3317
  xs: { label: "-25px", helperText: "30px" },
3427
3318
  sm: { label: "-29px", helperText: "34px" },
3428
3319
  md: { label: "-33px", helperText: "38px" },
3429
3320
  lg: { label: "-15px", helperText: "22px" },
3430
3321
  xl: { label: "-19px", helperText: "25px" }
3431
- }, G = Kn({
3322
+ }, B = Pn({
3432
3323
  className: o,
3433
3324
  inputClassName: s,
3434
3325
  error: a,
3435
3326
  raw: n,
3436
- focusMode: u,
3437
- disabled: h,
3327
+ focusMode: d,
3328
+ disabled: m,
3438
3329
  noBorder: p,
3439
- spacing: w,
3440
3330
  mode: i,
3441
- size: C,
3442
- rightElementClassName: T
3331
+ size: _,
3332
+ rightElementClassName: w
3443
3333
  });
3444
- return st(() => {
3445
- N && N.width && D(N.width + 18 + 10);
3446
- }, [N]), st(() => {
3447
- var g, I;
3448
- const { label: E, helperText: z } = L[C];
3449
- (g = te == null ? void 0 : te.current) == null || g.style.setProperty("--av-text-input-label", E), (I = R == null ? void 0 : R.current) == null || I.style.setProperty(
3334
+ return it(() => {
3335
+ O && O.width && G(O.width + 18 + 10);
3336
+ }, [O]), it(() => {
3337
+ var ee, y;
3338
+ const { label: T, helperText: b } = D[_];
3339
+ (ee = Z == null ? void 0 : Z.current) == null || ee.style.setProperty("--av-text-input-label", T), (y = N == null ? void 0 : N.current) == null || y.style.setProperty(
3450
3340
  "--av-text-input-helper-text",
3451
- z
3341
+ b
3452
3342
  );
3453
- }, [C]), /* @__PURE__ */ _("div", { className: G.wrapper, children: [
3343
+ }, [_]), /* @__PURE__ */ I("div", { className: B.wrapper, children: [
3454
3344
  /* @__PURE__ */ l(
3455
3345
  "label",
3456
3346
  {
3457
- htmlFor: Y,
3458
- id: m,
3459
- className: G.accessibleLabel,
3347
+ htmlFor: x,
3348
+ id: u,
3349
+ className: B.accessibleLabel,
3460
3350
  children: r
3461
3351
  }
3462
3352
  ),
3463
3353
  /* @__PURE__ */ l(
3464
3354
  "input",
3465
3355
  {
3466
- ref: H,
3467
- id: Y,
3356
+ ref: K,
3357
+ id: x,
3468
3358
  name: t,
3469
- type: d,
3470
- disabled: h,
3359
+ type: h,
3360
+ disabled: m,
3471
3361
  placeholder: n ? void 0 : " ",
3472
- className: G.input,
3473
- ...f && { "aria-describedby": `${Y}-helper` },
3362
+ className: B.input,
3363
+ ...f && { "aria-describedby": `${x}-helper` },
3474
3364
  ...a && { "aria-invalid": "true" },
3475
- ...b && !n && { style: { paddingRight: J } },
3476
- ...$
3365
+ ...E && !n && { style: { paddingRight: W } },
3366
+ ...U
3477
3367
  }
3478
3368
  ),
3479
3369
  !n && !c && /* @__PURE__ */ l(
3480
3370
  "label",
3481
3371
  {
3482
- ref: te,
3372
+ ref: Z,
3483
3373
  "aria-hidden": !0,
3484
- htmlFor: Y,
3485
- className: G.visibleLabel,
3374
+ htmlFor: x,
3375
+ className: B.visibleLabel,
3486
3376
  children: r
3487
3377
  }
3488
3378
  ),
3489
3379
  f && /* @__PURE__ */ l(
3490
3380
  "div",
3491
3381
  {
3492
- ref: R,
3493
- id: `${Y}-helper`,
3494
- className: G.helperText,
3382
+ ref: N,
3383
+ id: `${x}-helper`,
3384
+ className: B.helperText,
3495
3385
  children: f
3496
3386
  }
3497
3387
  ),
3498
- b && /* @__PURE__ */ l(
3388
+ E && /* @__PURE__ */ l(
3499
3389
  "div",
3500
3390
  {
3501
- ref: ee,
3502
- className: G.rightElement,
3503
- children: b
3391
+ ref: H,
3392
+ className: B.rightElement,
3393
+ children: E
3504
3394
  }
3505
3395
  ),
3506
3396
  a && f && /* @__PURE__ */ l(nr, { politeness: "polite", clearAnnouncementDelay: 500, children: pe })
3507
3397
  ] });
3508
3398
  }
3509
3399
  );
3510
- nt.displayName = "TextInput";
3511
- function Hn(e) {
3400
+ ot.displayName = "TextInput";
3401
+ function Dn(e) {
3512
3402
  return St(() => e.every((t) => t == null) ? () => {
3513
3403
  } : (t) => {
3514
3404
  e.forEach((r) => {
@@ -3516,7 +3406,7 @@ function Hn(e) {
3516
3406
  });
3517
3407
  }, e);
3518
3408
  }
3519
- const Gn = 500, Wn = 5e3, Vn = 2e4, or = P.forwardRef(
3409
+ const Ln = 500, Mn = 5e3, $n = 2e4, or = P.forwardRef(
3520
3410
  ({
3521
3411
  name: e,
3522
3412
  disabled: t,
@@ -3526,74 +3416,72 @@ const Gn = 500, Wn = 5e3, Vn = 2e4, or = P.forwardRef(
3526
3416
  onChange: o,
3527
3417
  onBlur: s,
3528
3418
  onFocus: i,
3529
- onTextInputMaskBlur: u,
3530
- rightElement: h,
3531
- spacing: p,
3532
- ...m
3533
- }, c) => {
3534
- const [d, f] = q(!0), [b, T] = q({
3419
+ onTextInputMaskBlur: d,
3420
+ rightElement: m,
3421
+ ...p
3422
+ }, u) => {
3423
+ const [c, h] = j(!0), [f, E] = j({
3535
3424
  message: null,
3536
3425
  politeness: null
3537
- }), w = K(!0), C = K(null), $ = K(null), H = Hn([c, $]), ee = d ? "Show" : "Hide", N = () => {
3538
- C.current && clearTimeout(C.current), w.current || (C.current = setTimeout(() => {
3539
- w.current = !0, f(!0), T({
3540
- announcementTimeout: Wn,
3426
+ }), w = $(!0), _ = $(null), U = $(null), K = Dn([u, U]), H = c ? "Show" : "Hide", O = () => {
3427
+ _.current && clearTimeout(_.current), w.current || (_.current = setTimeout(() => {
3428
+ w.current = !0, h(!0), E({
3429
+ announcementTimeout: Mn,
3541
3430
  politeness: "polite",
3542
3431
  message: `${r} hiding characters`
3543
3432
  }), n && n(!0);
3544
- }, Vn));
3545
- }, J = (R) => {
3546
- R.preventDefault();
3547
- const L = !w.current;
3548
- w.current = L, N(), f(L), T({
3549
- announcementTimeout: Gn,
3433
+ }, $n));
3434
+ }, W = (N) => {
3435
+ N.preventDefault();
3436
+ const D = !w.current;
3437
+ w.current = D, O(), h(D), E({
3438
+ announcementTimeout: Ln,
3550
3439
  politeness: "assertive",
3551
- message: L ? "Characters hidden" : "Characters showing"
3552
- }), n && n(L);
3553
- }, D = (R) => {
3554
- var L;
3555
- const { relatedTarget: G } = R, g = (L = $.current) == null ? void 0 : L.parentElement;
3556
- g != null && g.contains(G) || u && u();
3557
- }, Y = (R) => {
3558
- N(), s && s(R), D(R);
3559
- }, pe = (R) => {
3560
- N(), i && i(R);
3561
- }, te = (R) => {
3562
- N(), o && o(R);
3440
+ message: D ? "Characters hidden" : "Characters showing"
3441
+ }), n && n(D);
3442
+ }, G = (N) => {
3443
+ var D;
3444
+ const { relatedTarget: B } = N, ee = (D = U.current) == null ? void 0 : D.parentElement;
3445
+ ee != null && ee.contains(B) || d && d();
3446
+ }, x = (N) => {
3447
+ O(), s && s(N), G(N);
3448
+ }, pe = (N) => {
3449
+ O(), i && i(N);
3450
+ }, Z = (N) => {
3451
+ O(), o && o(N);
3563
3452
  };
3564
- return Z(() => () => {
3565
- C.current && clearTimeout(C.current);
3566
- }, []), /* @__PURE__ */ _(fe, { children: [
3453
+ return Q(() => () => {
3454
+ _.current && clearTimeout(_.current);
3455
+ }, []), /* @__PURE__ */ I(fe, { children: [
3567
3456
  /* @__PURE__ */ l(
3568
- nt,
3457
+ ot,
3569
3458
  {
3570
- ref: H,
3459
+ ref: K,
3571
3460
  name: e,
3572
3461
  label: r,
3573
3462
  labelHidden: a,
3574
- type: d ? "password" : "text",
3463
+ type: c ? "password" : "text",
3575
3464
  disabled: t,
3576
- spacing: p,
3577
- onBlur: Y,
3465
+ onBlur: x,
3578
3466
  onFocus: pe,
3579
- onChange: te,
3580
- rightElement: P.cloneElement(h, {
3581
- ref: c,
3582
- label: ee,
3583
- onClick: J,
3584
- onBlur: D,
3467
+ onChange: Z,
3468
+ rightElement: P.cloneElement(m, {
3469
+ ref: u,
3470
+ label: H,
3471
+ onClick: W,
3472
+ onBlur: G,
3585
3473
  disabled: t
3586
3474
  }),
3587
- ...m
3475
+ ...p
3588
3476
  }
3589
3477
  ),
3590
3478
  /* @__PURE__ */ l(
3591
3479
  nr,
3592
3480
  {
3593
3481
  role: "status",
3594
- politeness: b.politeness,
3595
- clearAnnouncementDelay: b.announcementTimeout,
3596
- children: b.message
3482
+ politeness: f.politeness,
3483
+ clearAnnouncementDelay: f.announcementTimeout,
3484
+ children: f.message
3597
3485
  }
3598
3486
  )
3599
3487
  ] });
@@ -3601,26 +3489,26 @@ const Gn = 500, Wn = 5e3, Vn = 2e4, or = P.forwardRef(
3601
3489
  );
3602
3490
  or.displayName = "TextInputMask";
3603
3491
  /*!
3604
- @versini/ui-textinput v1.6.0
3492
+ @versini/ui-textinput v2.0.0
3605
3493
  © 2024 gizmette.com
3606
3494
  */
3607
3495
  try {
3608
3496
  window.__VERSINI_UI_TEXTINPUT__ || (window.__VERSINI_UI_TEXTINPUT__ = {
3609
- version: "1.6.0",
3610
- buildTime: "12/26/2024 06:05 PM EST",
3497
+ version: "2.0.0",
3498
+ buildTime: "12/29/2024 04:16 PM EST",
3611
3499
  homepage: "https://github.com/aversini/ui-components",
3612
3500
  license: "MIT"
3613
3501
  });
3614
3502
  } catch {
3615
3503
  }
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 = {
3504
+ const Un = "ASK! ME! ANYTHING!", sr = "LeeLou", Kn = "gizmette.com", Hn = "Log in", Wn = "Sign in with a Passkey", Vo = "Log out", Gn = "Password", Bn = "Powered by ", Yo = "Send", Fo = "Profile", zo = "Statistics", jo = "Chat history", qo = "About", Xo = "Type your question here", Qo = "<clipboard>", Zo = {
3617
3505
  ACTION_WHILE_STREAMING: {
3618
3506
  content: "Cancel chat"
3619
3507
  },
3620
3508
  ACTION_WHILE_NOT_STREAMING: {
3621
3509
  content: "New chat"
3622
3510
  }
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 = {
3511
+ }, es = "N/A", ts = "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.", rs = {
3624
3512
  PREFERENCES: {
3625
3513
  TITLE: "User settings",
3626
3514
  NAME: "Name",
@@ -3656,67 +3544,47 @@ const Bn = "ASK! ME! ANYTHING!", sr = "LeeLou", Jn = "gizmette.com", Yn = "Log i
3656
3544
  }
3657
3545
  };
3658
3546
  /*!
3659
- @versini/ui-footer v1.4.0
3547
+ @versini/ui-footer v2.0.0
3660
3548
  © 2024 gizmette.com
3661
3549
  */
3662
3550
  try {
3663
3551
  window.__VERSINI_UI_FOOTER__ || (window.__VERSINI_UI_FOOTER__ = {
3664
- version: "1.4.0",
3665
- buildTime: "12/26/2024 06:05 PM EST",
3552
+ version: "2.0.0",
3553
+ buildTime: "12/29/2024 04:16 PM EST",
3666
3554
  homepage: "https://github.com/aversini/ui-components",
3667
3555
  license: "MIT"
3668
3556
  });
3669
3557
  } catch {
3670
3558
  }
3671
- const qn = "av-footer";
3672
- /*!
3673
- @versini/ui-spacing v1.1.0
3674
- © 2024 gizmette.com
3675
- */
3676
- try {
3677
- window.__VERSINI_UI_SPACING__ || (window.__VERSINI_UI_SPACING__ = {
3678
- version: "1.1.0",
3679
- buildTime: "12/26/2024 06:05 PM EST",
3680
- homepage: "https://github.com/aversini/ui-components",
3681
- license: "MIT"
3682
- });
3683
- } catch {
3684
- }
3685
- const Xn = (e) => {
3686
- let t = "";
3687
- if (typeof e == "number" || typeof e == "string")
3688
- t = "m-" + e;
3689
- else {
3690
- const r = [];
3691
- (e == null ? void 0 : e.t) !== void 0 && r.push(`mt-${e.t}`), (e == null ? void 0 : e.r) !== void 0 && r.push(`mr-${e.r}`), (e == null ? void 0 : e.b) !== void 0 && r.push(`mb-${e.b}`), (e == null ? void 0 : e.l) !== void 0 && r.push(`ml-${e.l}`), t = r.join(" ");
3692
- }
3693
- return t;
3694
- }, Qn = ({
3559
+ const Jn = "av-footer", Vn = ({
3695
3560
  className: e,
3696
3561
  mode: t = "system",
3697
3562
  row1: r,
3698
3563
  row2: a,
3699
3564
  noMargins: n = !1,
3700
- spacing: o,
3701
- raw: s = !1
3565
+ raw: o = !1
3702
3566
  }) => {
3703
- const i = y(qn, e, Xn(o), {
3704
- "text-copy-dark": !s && t === "dark",
3705
- "text-copy-lighter": !s && t === "light",
3706
- "text-copy-dark dark:text-copy-lighter": !s && t === "system",
3707
- "text-copy-lighter dark:text-copy-dark": !s && t === "alt-system",
3708
- "mb-[100px]": !n && !s,
3709
- "mt-0 flex w-full flex-col p-2 text-center text-xs sm:mt-3 md:mx-auto md:max-w-4xl": !s
3710
- });
3711
- return /* @__PURE__ */ _("footer", { className: i, children: [
3567
+ const s = g(
3568
+ Jn,
3569
+ {
3570
+ "text-copy-dark": !o && t === "dark",
3571
+ "text-copy-lighter": !o && t === "light",
3572
+ "text-copy-dark dark:text-copy-lighter": !o && t === "system",
3573
+ "text-copy-lighter dark:text-copy-dark": !o && t === "alt-system",
3574
+ "mb-[100px]": !n && !o,
3575
+ "mt-0 flex w-full flex-col p-2 text-center text-xs sm:mt-3 md:mx-auto md:max-w-4xl": !o
3576
+ },
3577
+ e
3578
+ );
3579
+ return /* @__PURE__ */ I("footer", { className: s, children: [
3712
3580
  r && /* @__PURE__ */ l("div", { children: r }),
3713
3581
  a && /* @__PURE__ */ l("div", { children: a })
3714
3582
  ] });
3715
- }, Zn = P.createContext({
3583
+ }, Yn = P.createContext({
3716
3584
  state: {
3717
3585
  id: "",
3718
- model: Je,
3719
- engine: Je,
3586
+ model: Ve,
3587
+ engine: Ve,
3720
3588
  usage: 0,
3721
3589
  messages: [],
3722
3590
  isComponent: !1,
@@ -3728,82 +3596,82 @@ const Xn = (e) => {
3728
3596
  version: "",
3729
3597
  models: [],
3730
3598
  plugins: [],
3731
- engine: Je,
3599
+ engine: Ve,
3732
3600
  engines: []
3733
3601
  }
3734
- }), ms = P.createContext({
3602
+ }), as = P.createContext({
3735
3603
  state: { searchString: "", sortedCell: "", sortDirection: "" },
3736
3604
  dispatch: () => {
3737
3605
  }
3738
- }), hs = P.createContext({
3606
+ }), ns = P.createContext({
3739
3607
  state: { tag: "" },
3740
3608
  dispatch: () => {
3741
3609
  }
3742
- }), eo = ({
3610
+ }), Fn = ({
3743
3611
  serverStats: e
3744
3612
  }) => {
3745
- const { state: t } = Xe(Zn);
3613
+ const { state: t } = Qe(Yn);
3746
3614
  return /* @__PURE__ */ l(
3747
- Qn,
3615
+ Vn,
3748
3616
  {
3749
3617
  mode: "light",
3750
- row1: /* @__PURE__ */ _("div", { children: [
3618
+ row1: /* @__PURE__ */ I("div", { children: [
3751
3619
  sr,
3752
3620
  " v",
3753
- "5.9.0",
3621
+ "5.10.1",
3754
3622
  " - ",
3755
- jn,
3623
+ Bn,
3756
3624
  t && t.engine,
3757
- tt && e && e.models.length > 0 && e.models[0] === "development" ? " - Development Mode" : ""
3625
+ rt && e && e.models.length > 0 && e.models[0] === "development" ? " - Development Mode" : ""
3758
3626
  ] }),
3759
- row2: /* @__PURE__ */ _("div", { children: [
3627
+ row2: /* @__PURE__ */ I("div", { children: [
3760
3628
  "© ",
3761
3629
  (/* @__PURE__ */ new Date()).getFullYear(),
3762
3630
  " ",
3763
- Jn
3631
+ Kn
3764
3632
  ] })
3765
3633
  }
3766
3634
  );
3767
- }, to = vt(
3635
+ }, zn = At(
3768
3636
  () => import(
3769
3637
  /* webpackChunkName: "LazyHeader" */
3770
- "./LazyHeader.PqNNzUEq.js"
3638
+ "./LazyHeader.DIS3Kdsm.js"
3771
3639
  )
3772
- ), ro = () => {
3773
- const { isAuthenticated: e } = et();
3774
- return /* @__PURE__ */ _(fe, { children: [
3775
- e && /* @__PURE__ */ l(At, { fallback: /* @__PURE__ */ l("div", {}), children: /* @__PURE__ */ l(to, {}) }),
3776
- /* @__PURE__ */ _("div", { className: "flex items-center justify-center", children: [
3777
- /* @__PURE__ */ l("div", { className: "basis-1/4", children: /* @__PURE__ */ l(pn, {}) }),
3778
- /* @__PURE__ */ _("div", { className: "prose prose-sm prose-light md:prose-base prose-h1:mb-0 prose-h2:mt-0", children: [
3640
+ ), jn = () => {
3641
+ const { isAuthenticated: e } = tt();
3642
+ return /* @__PURE__ */ I(fe, { children: [
3643
+ e && /* @__PURE__ */ l(vt, { fallback: /* @__PURE__ */ l("div", {}), children: /* @__PURE__ */ l(zn, {}) }),
3644
+ /* @__PURE__ */ I("div", { className: "flex items-center justify-center", children: [
3645
+ /* @__PURE__ */ l("div", { className: "basis-1/4", children: /* @__PURE__ */ l(un, {}) }),
3646
+ /* @__PURE__ */ I("div", { className: "prose prose-sm prose-light md:prose-base prose-h1:mb-0 prose-h2:mt-0", children: [
3779
3647
  /* @__PURE__ */ l("h1", { children: sr }),
3780
- /* @__PURE__ */ l("h2", { children: Bn })
3648
+ /* @__PURE__ */ l("h2", { children: Un })
3781
3649
  ] })
3782
3650
  ] })
3783
3651
  ] });
3784
- }, ao = () => {
3785
- const { login: e, logoutReason: t, loginWithPasskey: r } = et(), [a, n] = q(""), [o, s] = q(""), [i, u] = q(!0), [h, p] = q({
3652
+ }, qn = () => {
3653
+ const { login: e, logoutReason: t, loginWithPasskey: r } = tt(), [a, n] = j(""), [o, s] = j(""), [i, d] = j(!0), [m, p] = j({
3786
3654
  username: "",
3787
3655
  password: ""
3788
- }), m = async (c) => {
3789
- c.preventDefault(), await e(h.username, h.password) || (s(""), n("Invalid username or password"));
3656
+ }), u = async (c) => {
3657
+ c.preventDefault(), await e(m.username, m.password) || (s(""), n("Invalid username or password"));
3790
3658
  };
3791
- return Z(() => {
3659
+ return Q(() => {
3792
3660
  var c;
3793
3661
  (c = document.getElementById("logo")) == null || c.classList.add("fadeOut"), setTimeout(() => {
3794
- var d;
3795
- (d = document.getElementById("root")) == null || d.classList.replace("app-hidden", "fadeIn");
3662
+ var h;
3663
+ (h = document.getElementById("root")) == null || h.classList.replace("app-hidden", "fadeIn");
3796
3664
  }, 500);
3797
- }), Z(() => {
3665
+ }), Q(() => {
3798
3666
  t && s(t);
3799
- }, [t]), /* @__PURE__ */ _(fe, { children: [
3800
- /* @__PURE__ */ _(wn, { children: [
3801
- /* @__PURE__ */ l("div", { className: qa(), children: /* @__PURE__ */ l(ro, {}) }),
3802
- /* @__PURE__ */ _("form", { className: "mt-5", onSubmit: m, children: [
3803
- /* @__PURE__ */ l(wt, { alignHorizontal: "center", rowGap: 7, children: /* @__PURE__ */ l(le, { span: 6, children: /* @__PURE__ */ _(mn, { mode: "dark", children: [
3667
+ }, [t]), /* @__PURE__ */ I(fe, { children: [
3668
+ /* @__PURE__ */ I(yn, { children: [
3669
+ /* @__PURE__ */ l("div", { className: qa(), children: /* @__PURE__ */ l(jn, {}) }),
3670
+ /* @__PURE__ */ I("form", { className: "mt-5", onSubmit: u, children: [
3671
+ /* @__PURE__ */ l(Tt, { alignHorizontal: "center", rowGap: 7, children: /* @__PURE__ */ l(le, { span: 6, children: /* @__PURE__ */ I(dn, { mode: "dark", children: [
3804
3672
  /* @__PURE__ */ l(le, { span: 12, children: o && /* @__PURE__ */ l("div", { className: "p-2 text-sm text-center text-copy-error-light bg-surface-darker", children: o }) }),
3805
3673
  /* @__PURE__ */ l(le, { span: 12, children: /* @__PURE__ */ l(
3806
- nt,
3674
+ ot,
3807
3675
  {
3808
3676
  required: !0,
3809
3677
  autoCapitalize: "off",
@@ -3815,7 +3683,7 @@ const Xn = (e) => {
3815
3683
  label: "Username",
3816
3684
  onChange: (c) => {
3817
3685
  p({
3818
- ...h,
3686
+ ...m,
3819
3687
  username: c.target.value
3820
3688
  }), n("");
3821
3689
  },
@@ -3832,12 +3700,12 @@ const Xn = (e) => {
3832
3700
  mode: "dark",
3833
3701
  focusMode: "light",
3834
3702
  name: "password",
3835
- label: zn,
3836
- rightElement: /* @__PURE__ */ l(qe, { focusMode: "light", mode: "dark", children: i ? /* @__PURE__ */ l(fn, {}) : /* @__PURE__ */ l(gn, {}) }),
3837
- onMaskChange: u,
3703
+ label: Gn,
3704
+ rightElement: /* @__PURE__ */ l(qe, { focusMode: "light", mode: "dark", children: i ? /* @__PURE__ */ l(pn, {}) : /* @__PURE__ */ l(hn, {}) }),
3705
+ onMaskChange: d,
3838
3706
  onChange: (c) => {
3839
3707
  p({
3840
- ...h,
3708
+ ...m,
3841
3709
  password: c.target.value
3842
3710
  }), n("");
3843
3711
  },
@@ -3846,7 +3714,7 @@ const Xn = (e) => {
3846
3714
  }
3847
3715
  ) }),
3848
3716
  /* @__PURE__ */ l(le, { span: 12, children: /* @__PURE__ */ l(
3849
- Zt,
3717
+ er,
3850
3718
  {
3851
3719
  mode: "light",
3852
3720
  focusMode: "light",
@@ -3854,12 +3722,12 @@ const Xn = (e) => {
3854
3722
  noBorder: !0,
3855
3723
  type: "submit",
3856
3724
  className: "mb-4 mt-6",
3857
- children: Yn
3725
+ children: Hn
3858
3726
  }
3859
3727
  ) })
3860
3728
  ] }) }) }),
3861
3729
  /* @__PURE__ */ l("div", { className: "text-center text-copy-light", children: "or" }),
3862
- /* @__PURE__ */ l(wt, { alignHorizontal: "center", children: /* @__PURE__ */ l(le, { span: 6, children: /* @__PURE__ */ l(
3730
+ /* @__PURE__ */ l(Tt, { alignHorizontal: "center", children: /* @__PURE__ */ l(le, { span: 6, children: /* @__PURE__ */ l(
3863
3731
  qe,
3864
3732
  {
3865
3733
  mode: "dark",
@@ -3867,93 +3735,92 @@ const Xn = (e) => {
3867
3735
  fullWidth: !0,
3868
3736
  noBorder: !0,
3869
3737
  className: "mb-4 mt-1",
3870
- labelRight: Fn,
3738
+ labelRight: Wn,
3871
3739
  onClick: r,
3872
- children: /* @__PURE__ */ l(yn, { className: "size-7" })
3740
+ children: /* @__PURE__ */ l(mn, { className: "size-7" })
3873
3741
  }
3874
3742
  ) }) })
3875
3743
  ] })
3876
3744
  ] }),
3877
- /* @__PURE__ */ l(eo, {})
3745
+ /* @__PURE__ */ l(Fn, {})
3878
3746
  ] });
3879
- }, no = new URL(document.location.href).searchParams, oo = !!no.get("debug") || !1, so = vt(
3747
+ }, Xn = new URL(document.location.href).searchParams, Qn = !!Xn.get("debug") || !1, Zn = At(
3880
3748
  () => import(
3881
3749
  /* webpackChunkName: "LazyApp" */
3882
- "./LazyApp.B-F4mWWU.js"
3750
+ "./LazyApp.VKko0dy2.js"
3883
3751
  ).then((e) => e.LazyApp)
3884
- ), io = ({ isComponent: e }) => {
3885
- const { isAuthenticated: t } = et();
3886
- return t ? /* @__PURE__ */ l(At, { fallback: /* @__PURE__ */ l("div", {}), children: /* @__PURE__ */ l(so, { isComponent: e }) }) : /* @__PURE__ */ l(ao, {});
3887
- }, co = ({
3752
+ ), eo = ({ isComponent: e }) => {
3753
+ const { isAuthenticated: t } = tt();
3754
+ return t ? /* @__PURE__ */ l(vt, { fallback: /* @__PURE__ */ l("div", {}), children: /* @__PURE__ */ l(Zn, { isComponent: e }) }) : /* @__PURE__ */ l(qn, {});
3755
+ }, to = ({
3888
3756
  isComponent: e = !1,
3889
3757
  domain: t = ja
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 });
3758
+ }) => /* @__PURE__ */ l(fe, { children: /* @__PURE__ */ l(Ua, { clientId: Ka, domain: t, debug: Qn, children: /* @__PURE__ */ l(eo, { isComponent: e }) }) }), os = ({ domain: e }) => /* @__PURE__ */ l(to, { isComponent: !0, domain: e });
3891
3759
  export {
3892
- os as ABOUT_TITLE,
3893
- Po as ACTION_ENGINE,
3894
- No as ACTION_MESSAGE,
3895
- xo as ACTION_MODEL,
3896
- Ro as ACTION_RESET,
3897
- Mo as ACTION_RESET_TAGS,
3898
- Co as ACTION_RESTORE,
3899
- Do as ACTION_SEARCH,
3900
- Uo as ACTION_SET_TAGS,
3901
- $o as ACTION_SORT,
3902
- Oo as ACTION_STREAMING,
3903
- Lo as ACTION_TOGGLE_TAG,
3760
+ qo as ABOUT_TITLE,
3761
+ So as ACTION_ENGINE,
3762
+ wo as ACTION_MESSAGE,
3763
+ Io as ACTION_MODEL,
3764
+ To as ACTION_RESET,
3765
+ Ro as ACTION_RESET_TAGS,
3766
+ _o as ACTION_RESTORE,
3767
+ Ao as ACTION_SEARCH,
3768
+ xo as ACTION_SET_TAGS,
3769
+ vo as ACTION_SORT,
3770
+ ko as ACTION_STREAMING,
3771
+ No as ACTION_TOGGLE_TAG,
3904
3772
  sr as APP_NAME,
3905
- Zn as AppContext,
3906
- eo as AppFooter,
3907
- us as CARDS,
3908
- is as CLIPBOARD_TAG,
3909
- Je as DEFAULT_AI_ENGINE,
3910
- mn as E,
3911
- Ao as ENGINE_ANTHROPIC,
3912
- vo as ENGINE_OPENAI,
3913
- So as ERROR_MESSAGE,
3914
- ko as GPT4_MAX_TOKENS,
3915
- ns as HISTORY_TITLE,
3916
- ms as HistoryContext,
3917
- Ho as LOCAL_STORAGE_CHAT_DETAILS,
3918
- Vo as LOCAL_STORAGE_ENGINE_TOGGLE,
3919
- Ko as LOCAL_STORAGE_PREFIX,
3920
- Go as LOCAL_STORAGE_SEARCH,
3921
- Wo as LOCAL_STORAGE_SORT,
3922
- es as LOG_OUT,
3773
+ Yn as AppContext,
3774
+ Fn as AppFooter,
3775
+ er as C,
3776
+ rs as CARDS,
3777
+ Qo as CLIPBOARD_TAG,
3778
+ Ve as DEFAULT_AI_ENGINE,
3779
+ bo as ENGINE_ANTHROPIC,
3780
+ fo as ENGINE_OPENAI,
3781
+ yo as ERROR_MESSAGE,
3782
+ Eo as GPT4_MAX_TOKENS,
3783
+ jo as HISTORY_TITLE,
3784
+ as as HistoryContext,
3785
+ Tt as L,
3786
+ Oo as LOCAL_STORAGE_CHAT_DETAILS,
3787
+ Lo as LOCAL_STORAGE_ENGINE_TOGGLE,
3788
+ Co as LOCAL_STORAGE_PREFIX,
3789
+ Po as LOCAL_STORAGE_SEARCH,
3790
+ Do as LOCAL_STORAGE_SORT,
3791
+ Vo as LOG_OUT,
3923
3792
  ue as M,
3924
- ro as MessagesContainerHeader,
3925
- ls as NA,
3793
+ jn as MessagesContainerHeader,
3794
+ es as NA,
3926
3795
  qe as O,
3927
- rs as PROFILE_TITLE,
3928
- Zt as R,
3929
- wo as ROLE_ASSISTANT,
3930
- To as ROLE_HIDDEN,
3931
- _o as ROLE_INTERNAL,
3932
- Io as ROLE_SYSTEM,
3933
- Eo as ROLE_USER,
3934
- ts as SEND,
3935
- as as STATS,
3936
- Bo as STATS_SEPARATOR,
3937
- ps as SassySaint,
3938
- ds as TAGS_DESCRIPTION,
3939
- cs as TOOLBOX,
3940
- ss as TYPE_QUESTION,
3941
- hs as TagsContext,
3942
- wt as b,
3943
- wn as c,
3944
- Zo as debounce,
3945
- Xo as durationFormatter,
3946
- zo as extractAverage,
3947
- nt as fe,
3948
- Me as g,
3949
- Yo as getCurrentGeoLocation,
3796
+ Fo as PROFILE_TITLE,
3797
+ dn as R,
3798
+ ho as ROLE_ASSISTANT,
3799
+ go as ROLE_HIDDEN,
3800
+ po as ROLE_INTERNAL,
3801
+ mo as ROLE_SYSTEM,
3802
+ uo as ROLE_USER,
3803
+ Yo as SEND,
3804
+ zo as STATS,
3805
+ Mo as STATS_SEPARATOR,
3806
+ os as SassySaint,
3807
+ ts as TAGS_DESCRIPTION,
3808
+ Zo as TOOLBOX,
3809
+ Xo as TYPE_QUESTION,
3810
+ ns as TagsContext,
3811
+ yn as _,
3812
+ Jo as debounce,
3813
+ Go as durationFormatter,
3814
+ Ko as extractAverage,
3815
+ $e as g,
3816
+ $o as getCurrentGeoLocation,
3950
3817
  qa as getMessageContaintWrapperClass,
3951
- jo as isLastMessageFromRole,
3818
+ mn as i,
3819
+ Ho as isLastMessageFromRole,
3952
3820
  le as j,
3953
- qo as numberFormatter,
3954
- Qo as pluralize,
3955
- Fo as renderDataAsList,
3956
- Jo as truncate,
3957
- et as un,
3958
- yn as v
3821
+ Wo as numberFormatter,
3822
+ Bo as pluralize,
3823
+ Uo as renderDataAsList,
3824
+ tt as un,
3825
+ ot as ye
3959
3826
  };