@neuctra/authix 1.2.7 → 1.2.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.
@@ -162,8 +162,8 @@ const Hr = (t) => {
162
162
  e[i] = s;
163
163
  const a = je(s) ? [] : {};
164
164
  return Pe(s, (o, c) => {
165
- const d = n(o, i + 1);
166
- !be(d) && (a[c] = d);
165
+ const u = n(o, i + 1);
166
+ !be(u) && (a[c] = u);
167
167
  }), e[i] = void 0, a;
168
168
  }
169
169
  }
@@ -177,7 +177,7 @@ const Hr = (t) => {
177
177
  }))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(
178
178
  typeof setImmediate == "function",
179
179
  te(xe.postMessage)
180
- ), Jr = typeof queueMicrotask < "u" ? queueMicrotask.bind(xe) : typeof process < "u" && process.nextTick || Ft, Kr = (t) => t != null && te(t[Le]), x = {
180
+ ), Jr = typeof queueMicrotask < "u" ? queueMicrotask.bind(xe) : typeof process < "u" && process.nextTick || Ft, Kr = (t) => t != null && te(t[Le]), f = {
181
181
  isArray: je,
182
182
  isArrayBuffer: Ut,
183
183
  isBuffer: Te,
@@ -240,7 +240,7 @@ const Hr = (t) => {
240
240
  function $(t, e, n, s, i) {
241
241
  Error.call(this), Error.captureStackTrace ? Error.captureStackTrace(this, this.constructor) : this.stack = new Error().stack, this.message = t, this.name = "AxiosError", e && (this.code = e), n && (this.config = n), s && (this.request = s), i && (this.response = i, this.status = i.status ? i.status : null);
242
242
  }
243
- x.inherits($, Error, {
243
+ f.inherits($, Error, {
244
244
  toJSON: function() {
245
245
  return {
246
246
  // Standard
@@ -255,7 +255,7 @@ x.inherits($, Error, {
255
255
  columnNumber: this.columnNumber,
256
256
  stack: this.stack,
257
257
  // Axios
258
- config: x.toJSONObject(this.config),
258
+ config: f.toJSONObject(this.config),
259
259
  code: this.code,
260
260
  status: this.status
261
261
  };
@@ -283,18 +283,18 @@ Object.defineProperties($, Mt);
283
283
  Object.defineProperty(qt, "isAxiosError", { value: !0 });
284
284
  $.from = (t, e, n, s, i, a) => {
285
285
  const o = Object.create(qt);
286
- x.toFlatObject(t, o, function(p) {
287
- return p !== Error.prototype;
288
- }, (f) => f !== "isAxiosError");
289
- const c = t && t.message ? t.message : "Error", d = e == null && t ? t.code : e;
290
- return $.call(o, c, d, n, s, i), t && o.cause == null && Object.defineProperty(o, "cause", { value: t, configurable: !0 }), o.name = t && t.name || "Error", a && Object.assign(o, a), o;
286
+ f.toFlatObject(t, o, function(d) {
287
+ return d !== Error.prototype;
288
+ }, (x) => x !== "isAxiosError");
289
+ const c = t && t.message ? t.message : "Error", u = e == null && t ? t.code : e;
290
+ return $.call(o, c, u, n, s, i), t && o.cause == null && Object.defineProperty(o, "cause", { value: t, configurable: !0 }), o.name = t && t.name || "Error", a && Object.assign(o, a), o;
291
291
  };
292
292
  const Gr = null;
293
293
  function Xe(t) {
294
- return x.isPlainObject(t) || x.isArray(t);
294
+ return f.isPlainObject(t) || f.isArray(t);
295
295
  }
296
296
  function Wt(t) {
297
- return x.endsWith(t, "[]") ? t.slice(0, -2) : t;
297
+ return f.endsWith(t, "[]") ? t.slice(0, -2) : t;
298
298
  }
299
299
  function pt(t, e, n) {
300
300
  return t ? t.concat(e).map(function(i, a) {
@@ -302,71 +302,71 @@ function pt(t, e, n) {
302
302
  }).join(n ? "." : "") : e;
303
303
  }
304
304
  function Xr(t) {
305
- return x.isArray(t) && !t.some(Xe);
305
+ return f.isArray(t) && !t.some(Xe);
306
306
  }
307
- const Zr = x.toFlatObject(x, {}, null, function(e) {
307
+ const Zr = f.toFlatObject(f, {}, null, function(e) {
308
308
  return /^is[A-Z]/.test(e);
309
309
  });
310
310
  function Me(t, e, n) {
311
- if (!x.isObject(t))
311
+ if (!f.isObject(t))
312
312
  throw new TypeError("target must be an object");
313
- e = e || new FormData(), n = x.toFlatObject(n, {
313
+ e = e || new FormData(), n = f.toFlatObject(n, {
314
314
  metaTokens: !0,
315
315
  dots: !1,
316
316
  indexes: !1
317
317
  }, !1, function(w, h) {
318
- return !x.isUndefined(h[w]);
318
+ return !f.isUndefined(h[w]);
319
319
  });
320
- const s = n.metaTokens, i = n.visitor || p, a = n.dots, o = n.indexes, d = (n.Blob || typeof Blob < "u" && Blob) && x.isSpecCompliantForm(e);
321
- if (!x.isFunction(i))
320
+ const s = n.metaTokens, i = n.visitor || d, a = n.dots, o = n.indexes, u = (n.Blob || typeof Blob < "u" && Blob) && f.isSpecCompliantForm(e);
321
+ if (!f.isFunction(i))
322
322
  throw new TypeError("visitor must be a function");
323
- function f(u) {
324
- if (u === null) return "";
325
- if (x.isDate(u))
326
- return u.toISOString();
327
- if (x.isBoolean(u))
328
- return u.toString();
329
- if (!d && x.isBlob(u))
323
+ function x(p) {
324
+ if (p === null) return "";
325
+ if (f.isDate(p))
326
+ return p.toISOString();
327
+ if (f.isBoolean(p))
328
+ return p.toString();
329
+ if (!u && f.isBlob(p))
330
330
  throw new $("Blob is not supported. Use a Buffer instead.");
331
- return x.isArrayBuffer(u) || x.isTypedArray(u) ? d && typeof Blob == "function" ? new Blob([u]) : Buffer.from(u) : u;
331
+ return f.isArrayBuffer(p) || f.isTypedArray(p) ? u && typeof Blob == "function" ? new Blob([p]) : Buffer.from(p) : p;
332
332
  }
333
- function p(u, w, h) {
334
- let O = u;
335
- if (u && !h && typeof u == "object") {
336
- if (x.endsWith(w, "{}"))
337
- w = s ? w : w.slice(0, -2), u = JSON.stringify(u);
338
- else if (x.isArray(u) && Xr(u) || (x.isFileList(u) || x.endsWith(w, "[]")) && (O = x.toArray(u)))
333
+ function d(p, w, h) {
334
+ let O = p;
335
+ if (p && !h && typeof p == "object") {
336
+ if (f.endsWith(w, "{}"))
337
+ w = s ? w : w.slice(0, -2), p = JSON.stringify(p);
338
+ else if (f.isArray(p) && Xr(p) || (f.isFileList(p) || f.endsWith(w, "[]")) && (O = f.toArray(p)))
339
339
  return w = Wt(w), O.forEach(function(g, A) {
340
- !(x.isUndefined(g) || g === null) && e.append(
340
+ !(f.isUndefined(g) || g === null) && e.append(
341
341
  // eslint-disable-next-line no-nested-ternary
342
342
  o === !0 ? pt([w], A, a) : o === null ? w : w + "[]",
343
- f(g)
343
+ x(g)
344
344
  );
345
345
  }), !1;
346
346
  }
347
- return Xe(u) ? !0 : (e.append(pt(h, w, a), f(u)), !1);
347
+ return Xe(p) ? !0 : (e.append(pt(h, w, a), x(p)), !1);
348
348
  }
349
349
  const y = [], k = Object.assign(Zr, {
350
- defaultVisitor: p,
351
- convertValue: f,
350
+ defaultVisitor: d,
351
+ convertValue: x,
352
352
  isVisitable: Xe
353
353
  });
354
- function E(u, w) {
355
- if (!x.isUndefined(u)) {
356
- if (y.indexOf(u) !== -1)
354
+ function E(p, w) {
355
+ if (!f.isUndefined(p)) {
356
+ if (y.indexOf(p) !== -1)
357
357
  throw Error("Circular reference detected in " + w.join("."));
358
- y.push(u), x.forEach(u, function(O, C) {
359
- (!(x.isUndefined(O) || O === null) && i.call(
358
+ y.push(p), f.forEach(p, function(O, C) {
359
+ (!(f.isUndefined(O) || O === null) && i.call(
360
360
  e,
361
361
  O,
362
- x.isString(C) ? C.trim() : C,
362
+ f.isString(C) ? C.trim() : C,
363
363
  w,
364
364
  k
365
365
  )) === !0 && E(O, w ? w.concat(C) : [C]);
366
366
  }), y.pop();
367
367
  }
368
368
  }
369
- if (!x.isObject(t))
369
+ if (!f.isObject(t))
370
370
  throw new TypeError("data must be an object");
371
371
  return E(t), e;
372
372
  }
@@ -406,12 +406,12 @@ function Ht(t, e, n) {
406
406
  if (!e)
407
407
  return t;
408
408
  const s = n && n.encode || Qr;
409
- x.isFunction(n) && (n = {
409
+ f.isFunction(n) && (n = {
410
410
  serialize: n
411
411
  });
412
412
  const i = n && n.serialize;
413
413
  let a;
414
- if (i ? a = i(e, n) : a = x.isURLSearchParams(e) ? e.toString() : new nt(e, n).toString(s), a) {
414
+ if (i ? a = i(e, n) : a = f.isURLSearchParams(e) ? e.toString() : new nt(e, n).toString(s), a) {
415
415
  const o = t.indexOf("#");
416
416
  o !== -1 && (t = t.slice(0, o)), t += (t.indexOf("?") === -1 ? "?" : "&") + a;
417
417
  }
@@ -466,7 +466,7 @@ class xt {
466
466
  * @returns {void}
467
467
  */
468
468
  forEach(e) {
469
- x.forEach(this.handlers, function(s) {
469
+ f.forEach(this.handlers, function(s) {
470
470
  s !== null && e(s);
471
471
  });
472
472
  }
@@ -498,13 +498,13 @@ self instanceof WorkerGlobalScope && typeof self.importScripts == "function", on
498
498
  function cn(t, e) {
499
499
  return Me(t, new Q.classes.URLSearchParams(), {
500
500
  visitor: function(n, s, i, a) {
501
- return Q.isNode && x.isBuffer(n) ? (this.append(s, n.toString("base64")), !1) : a.defaultVisitor.apply(this, arguments);
501
+ return Q.isNode && f.isBuffer(n) ? (this.append(s, n.toString("base64")), !1) : a.defaultVisitor.apply(this, arguments);
502
502
  },
503
503
  ...e
504
504
  });
505
505
  }
506
506
  function dn(t) {
507
- return x.matchAll(/\w+|\[(\w*)]/g, t).map((e) => e[0] === "[]" ? "" : e[1] || e[0]);
507
+ return f.matchAll(/\w+|\[(\w*)]/g, t).map((e) => e[0] === "[]" ? "" : e[1] || e[0]);
508
508
  }
509
509
  function un(t) {
510
510
  const e = {}, n = Object.keys(t);
@@ -519,21 +519,21 @@ function Yt(t) {
519
519
  function e(n, s, i, a) {
520
520
  let o = n[a++];
521
521
  if (o === "__proto__") return !0;
522
- const c = Number.isFinite(+o), d = a >= n.length;
523
- return o = !o && x.isArray(i) ? i.length : o, d ? (x.hasOwnProp(i, o) ? i[o] = [i[o], s] : i[o] = s, !c) : ((!i[o] || !x.isObject(i[o])) && (i[o] = []), e(n, s, i[o], a) && x.isArray(i[o]) && (i[o] = un(i[o])), !c);
522
+ const c = Number.isFinite(+o), u = a >= n.length;
523
+ return o = !o && f.isArray(i) ? i.length : o, u ? (f.hasOwnProp(i, o) ? i[o] = [i[o], s] : i[o] = s, !c) : ((!i[o] || !f.isObject(i[o])) && (i[o] = []), e(n, s, i[o], a) && f.isArray(i[o]) && (i[o] = un(i[o])), !c);
524
524
  }
525
- if (x.isFormData(t) && x.isFunction(t.entries)) {
525
+ if (f.isFormData(t) && f.isFunction(t.entries)) {
526
526
  const n = {};
527
- return x.forEachEntry(t, (s, i) => {
527
+ return f.forEachEntry(t, (s, i) => {
528
528
  e(dn(s), i, n, 0);
529
529
  }), n;
530
530
  }
531
531
  return null;
532
532
  }
533
533
  function pn(t, e, n) {
534
- if (x.isString(t))
534
+ if (f.isString(t))
535
535
  try {
536
- return (e || JSON.parse)(t), x.trim(t);
536
+ return (e || JSON.parse)(t), f.trim(t);
537
537
  } catch (s) {
538
538
  if (s.name !== "SyntaxError")
539
539
  throw s;
@@ -544,24 +544,24 @@ const Oe = {
544
544
  transitional: Vt,
545
545
  adapter: ["xhr", "http", "fetch"],
546
546
  transformRequest: [function(e, n) {
547
- const s = n.getContentType() || "", i = s.indexOf("application/json") > -1, a = x.isObject(e);
548
- if (a && x.isHTMLForm(e) && (e = new FormData(e)), x.isFormData(e))
547
+ const s = n.getContentType() || "", i = s.indexOf("application/json") > -1, a = f.isObject(e);
548
+ if (a && f.isHTMLForm(e) && (e = new FormData(e)), f.isFormData(e))
549
549
  return i ? JSON.stringify(Yt(e)) : e;
550
- if (x.isArrayBuffer(e) || x.isBuffer(e) || x.isStream(e) || x.isFile(e) || x.isBlob(e) || x.isReadableStream(e))
550
+ if (f.isArrayBuffer(e) || f.isBuffer(e) || f.isStream(e) || f.isFile(e) || f.isBlob(e) || f.isReadableStream(e))
551
551
  return e;
552
- if (x.isArrayBufferView(e))
552
+ if (f.isArrayBufferView(e))
553
553
  return e.buffer;
554
- if (x.isURLSearchParams(e))
554
+ if (f.isURLSearchParams(e))
555
555
  return n.setContentType("application/x-www-form-urlencoded;charset=utf-8", !1), e.toString();
556
556
  let c;
557
557
  if (a) {
558
558
  if (s.indexOf("application/x-www-form-urlencoded") > -1)
559
559
  return cn(e, this.formSerializer).toString();
560
- if ((c = x.isFileList(e)) || s.indexOf("multipart/form-data") > -1) {
561
- const d = this.env && this.env.FormData;
560
+ if ((c = f.isFileList(e)) || s.indexOf("multipart/form-data") > -1) {
561
+ const u = this.env && this.env.FormData;
562
562
  return Me(
563
563
  c ? { "files[]": e } : e,
564
- d && new d(),
564
+ u && new u(),
565
565
  this.formSerializer
566
566
  );
567
567
  }
@@ -570,9 +570,9 @@ const Oe = {
570
570
  }],
571
571
  transformResponse: [function(e) {
572
572
  const n = this.transitional || Oe.transitional, s = n && n.forcedJSONParsing, i = this.responseType === "json";
573
- if (x.isResponse(e) || x.isReadableStream(e))
573
+ if (f.isResponse(e) || f.isReadableStream(e))
574
574
  return e;
575
- if (e && x.isString(e) && (s && !this.responseType || i)) {
575
+ if (e && f.isString(e) && (s && !this.responseType || i)) {
576
576
  const o = !(n && n.silentJSONParsing) && i;
577
577
  try {
578
578
  return JSON.parse(e, this.parseReviver);
@@ -606,10 +606,10 @@ const Oe = {
606
606
  }
607
607
  }
608
608
  };
609
- x.forEach(["delete", "get", "head", "post", "put", "patch"], (t) => {
609
+ f.forEach(["delete", "get", "head", "post", "put", "patch"], (t) => {
610
610
  Oe.headers[t] = {};
611
611
  });
612
- const fn = x.toObjectSet([
612
+ const fn = f.toObjectSet([
613
613
  "age",
614
614
  "authorization",
615
615
  "content-length",
@@ -639,7 +639,7 @@ function Se(t) {
639
639
  return t && String(t).trim().toLowerCase();
640
640
  }
641
641
  function Ue(t) {
642
- return t === !1 || t == null ? t : x.isArray(t) ? t.map(Ue) : String(t);
642
+ return t === !1 || t == null ? t : f.isArray(t) ? t.map(Ue) : String(t);
643
643
  }
644
644
  function hn(t) {
645
645
  const e = /* @__PURE__ */ Object.create(null), n = /([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;
@@ -650,12 +650,12 @@ function hn(t) {
650
650
  }
651
651
  const mn = (t) => /^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());
652
652
  function He(t, e, n, s, i) {
653
- if (x.isFunction(s))
653
+ if (f.isFunction(s))
654
654
  return s.call(this, e, n);
655
- if (i && (e = n), !!x.isString(e)) {
656
- if (x.isString(s))
655
+ if (i && (e = n), !!f.isString(e)) {
656
+ if (f.isString(s))
657
657
  return e.indexOf(s) !== -1;
658
- if (x.isRegExp(s))
658
+ if (f.isRegExp(s))
659
659
  return s.test(e);
660
660
  }
661
661
  }
@@ -663,7 +663,7 @@ function gn(t) {
663
663
  return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g, (e, n, s) => n.toUpperCase() + s);
664
664
  }
665
665
  function yn(t, e) {
666
- const n = x.toCamelCase(" " + e);
666
+ const n = f.toCamelCase(" " + e);
667
667
  ["get", "set", "has"].forEach((s) => {
668
668
  Object.defineProperty(t, s + n, {
669
669
  value: function(i, a, o) {
@@ -679,24 +679,24 @@ let re = class {
679
679
  }
680
680
  set(e, n, s) {
681
681
  const i = this;
682
- function a(c, d, f) {
683
- const p = Se(d);
684
- if (!p)
682
+ function a(c, u, x) {
683
+ const d = Se(u);
684
+ if (!d)
685
685
  throw new Error("header name must be a non-empty string");
686
- const y = x.findKey(i, p);
687
- (!y || i[y] === void 0 || f === !0 || f === void 0 && i[y] !== !1) && (i[y || d] = Ue(c));
686
+ const y = f.findKey(i, d);
687
+ (!y || i[y] === void 0 || x === !0 || x === void 0 && i[y] !== !1) && (i[y || u] = Ue(c));
688
688
  }
689
- const o = (c, d) => x.forEach(c, (f, p) => a(f, p, d));
690
- if (x.isPlainObject(e) || e instanceof this.constructor)
689
+ const o = (c, u) => f.forEach(c, (x, d) => a(x, d, u));
690
+ if (f.isPlainObject(e) || e instanceof this.constructor)
691
691
  o(e, n);
692
- else if (x.isString(e) && (e = e.trim()) && !mn(e))
692
+ else if (f.isString(e) && (e = e.trim()) && !mn(e))
693
693
  o(xn(e), n);
694
- else if (x.isObject(e) && x.isIterable(e)) {
695
- let c = {}, d, f;
696
- for (const p of e) {
697
- if (!x.isArray(p))
694
+ else if (f.isObject(e) && f.isIterable(e)) {
695
+ let c = {}, u, x;
696
+ for (const d of e) {
697
+ if (!f.isArray(d))
698
698
  throw TypeError("Object iterator must return a key-value pair");
699
- c[f = p[0]] = (d = c[f]) ? x.isArray(d) ? [...d, p[1]] : [d, p[1]] : p[1];
699
+ c[x = d[0]] = (u = c[x]) ? f.isArray(u) ? [...u, d[1]] : [u, d[1]] : d[1];
700
700
  }
701
701
  o(c, n);
702
702
  } else
@@ -705,16 +705,16 @@ let re = class {
705
705
  }
706
706
  get(e, n) {
707
707
  if (e = Se(e), e) {
708
- const s = x.findKey(this, e);
708
+ const s = f.findKey(this, e);
709
709
  if (s) {
710
710
  const i = this[s];
711
711
  if (!n)
712
712
  return i;
713
713
  if (n === !0)
714
714
  return hn(i);
715
- if (x.isFunction(n))
715
+ if (f.isFunction(n))
716
716
  return n.call(this, i, s);
717
- if (x.isRegExp(n))
717
+ if (f.isRegExp(n))
718
718
  return n.exec(i);
719
719
  throw new TypeError("parser must be boolean|regexp|function");
720
720
  }
@@ -722,7 +722,7 @@ let re = class {
722
722
  }
723
723
  has(e, n) {
724
724
  if (e = Se(e), e) {
725
- const s = x.findKey(this, e);
725
+ const s = f.findKey(this, e);
726
726
  return !!(s && this[s] !== void 0 && (!n || He(this, this[s], s, n)));
727
727
  }
728
728
  return !1;
@@ -732,11 +732,11 @@ let re = class {
732
732
  let i = !1;
733
733
  function a(o) {
734
734
  if (o = Se(o), o) {
735
- const c = x.findKey(s, o);
735
+ const c = f.findKey(s, o);
736
736
  c && (!n || He(s, s[c], c, n)) && (delete s[c], i = !0);
737
737
  }
738
738
  }
739
- return x.isArray(e) ? e.forEach(a) : a(e), i;
739
+ return f.isArray(e) ? e.forEach(a) : a(e), i;
740
740
  }
741
741
  clear(e) {
742
742
  const n = Object.keys(this);
@@ -749,8 +749,8 @@ let re = class {
749
749
  }
750
750
  normalize(e) {
751
751
  const n = this, s = {};
752
- return x.forEach(this, (i, a) => {
753
- const o = x.findKey(s, a);
752
+ return f.forEach(this, (i, a) => {
753
+ const o = f.findKey(s, a);
754
754
  if (o) {
755
755
  n[o] = Ue(i), delete n[a];
756
756
  return;
@@ -764,8 +764,8 @@ let re = class {
764
764
  }
765
765
  toJSON(e) {
766
766
  const n = /* @__PURE__ */ Object.create(null);
767
- return x.forEach(this, (s, i) => {
768
- s != null && s !== !1 && (n[i] = e && x.isArray(s) ? s.join(", ") : s);
767
+ return f.forEach(this, (s, i) => {
768
+ s != null && s !== !1 && (n[i] = e && f.isArray(s) ? s.join(", ") : s);
769
769
  }), n;
770
770
  }
771
771
  [Symbol.iterator]() {
@@ -796,11 +796,11 @@ let re = class {
796
796
  const c = Se(o);
797
797
  s[c] || (yn(i, o), s[c] = !0);
798
798
  }
799
- return x.isArray(e) ? e.forEach(a) : a(e), this;
799
+ return f.isArray(e) ? e.forEach(a) : a(e), this;
800
800
  }
801
801
  };
802
802
  re.accessor(["Content-Type", "Content-Length", "Accept", "Accept-Encoding", "User-Agent", "Authorization"]);
803
- x.reduceDescriptors(re.prototype, ({ value: t }, e) => {
803
+ f.reduceDescriptors(re.prototype, ({ value: t }, e) => {
804
804
  let n = e[0].toUpperCase() + e.slice(1);
805
805
  return {
806
806
  get: () => t,
@@ -809,11 +809,11 @@ x.reduceDescriptors(re.prototype, ({ value: t }, e) => {
809
809
  }
810
810
  };
811
811
  });
812
- x.freezeMethods(re);
812
+ f.freezeMethods(re);
813
813
  function Ve(t, e) {
814
814
  const n = this || Oe, s = e || n, i = re.from(s.headers);
815
815
  let a = s.data;
816
- return x.forEach(t, function(c) {
816
+ return f.forEach(t, function(c) {
817
817
  a = c.call(n, a, i.normalize(), e ? e.status : void 0);
818
818
  }), i.normalize(), a;
819
819
  }
@@ -823,7 +823,7 @@ function Jt(t) {
823
823
  function ve(t, e, n) {
824
824
  $.call(this, t ?? "canceled", $.ERR_CANCELED, e, n), this.name = "CanceledError";
825
825
  }
826
- x.inherits(ve, $, {
826
+ f.inherits(ve, $, {
827
827
  __CANCEL__: !0
828
828
  });
829
829
  function Kt(t, e, n) {
@@ -844,26 +844,26 @@ function wn(t, e) {
844
844
  t = t || 10;
845
845
  const n = new Array(t), s = new Array(t);
846
846
  let i = 0, a = 0, o;
847
- return e = e !== void 0 ? e : 1e3, function(d) {
848
- const f = Date.now(), p = s[a];
849
- o || (o = f), n[i] = d, s[i] = f;
847
+ return e = e !== void 0 ? e : 1e3, function(u) {
848
+ const x = Date.now(), d = s[a];
849
+ o || (o = x), n[i] = u, s[i] = x;
850
850
  let y = a, k = 0;
851
851
  for (; y !== i; )
852
852
  k += n[y++], y = y % t;
853
- if (i = (i + 1) % t, i === a && (a = (a + 1) % t), f - o < e)
853
+ if (i = (i + 1) % t, i === a && (a = (a + 1) % t), x - o < e)
854
854
  return;
855
- const E = p && f - p;
855
+ const E = d && x - d;
856
856
  return E ? Math.round(k * 1e3 / E) : void 0;
857
857
  };
858
858
  }
859
859
  function jn(t, e) {
860
860
  let n = 0, s = 1e3 / e, i, a;
861
- const o = (f, p = Date.now()) => {
862
- n = p, i = null, a && (clearTimeout(a), a = null), t(...f);
861
+ const o = (x, d = Date.now()) => {
862
+ n = d, i = null, a && (clearTimeout(a), a = null), t(...x);
863
863
  };
864
- return [(...f) => {
865
- const p = Date.now(), y = p - n;
866
- y >= s ? o(f, p) : (i = f, a || (a = setTimeout(() => {
864
+ return [(...x) => {
865
+ const d = Date.now(), y = d - n;
866
+ y >= s ? o(x, d) : (i = x, a || (a = setTimeout(() => {
867
867
  a = null, o(i);
868
868
  }, s - y)));
869
869
  }, () => i && o(i)];
@@ -872,15 +872,15 @@ const Ne = (t, e, n = 3) => {
872
872
  let s = 0;
873
873
  const i = wn(50, 250);
874
874
  return jn((a) => {
875
- const o = a.loaded, c = a.lengthComputable ? a.total : void 0, d = o - s, f = i(d), p = o <= c;
875
+ const o = a.loaded, c = a.lengthComputable ? a.total : void 0, u = o - s, x = i(u), d = o <= c;
876
876
  s = o;
877
877
  const y = {
878
878
  loaded: o,
879
879
  total: c,
880
880
  progress: c ? o / c : void 0,
881
- bytes: d,
882
- rate: f || void 0,
883
- estimated: f && c && p ? (c - o) / f : void 0,
881
+ bytes: u,
882
+ rate: x || void 0,
883
+ estimated: x && c && d ? (c - o) / x : void 0,
884
884
  event: a,
885
885
  lengthComputable: c != null,
886
886
  [e ? "download" : "upload"]: !0
@@ -894,7 +894,7 @@ const Ne = (t, e, n = 3) => {
894
894
  total: t,
895
895
  loaded: s
896
896
  }), e[1]];
897
- }, gt = (t) => (...e) => x.asap(() => t(...e)), vn = Q.hasStandardBrowserEnv ? /* @__PURE__ */ ((t, e) => (n) => (n = new URL(n, Q.origin), t.protocol === n.protocol && t.host === n.host && (e || t.port === n.port)))(
897
+ }, gt = (t) => (...e) => f.asap(() => t(...e)), vn = Q.hasStandardBrowserEnv ? /* @__PURE__ */ ((t, e) => (n) => (n = new URL(n, Q.origin), t.protocol === n.protocol && t.host === n.host && (e || t.port === n.port)))(
898
898
  new URL(Q.origin),
899
899
  Q.navigator && /(msie|trident)/i.test(Q.navigator.userAgent)
900
900
  ) : () => !0, Sn = Q.hasStandardBrowserEnv ? (
@@ -902,7 +902,7 @@ const Ne = (t, e, n = 3) => {
902
902
  {
903
903
  write(t, e, n, s, i, a) {
904
904
  const o = [t + "=" + encodeURIComponent(e)];
905
- x.isNumber(n) && o.push("expires=" + new Date(n).toGMTString()), x.isString(s) && o.push("path=" + s), x.isString(i) && o.push("domain=" + i), a === !0 && o.push("secure"), document.cookie = o.join("; ");
905
+ f.isNumber(n) && o.push("expires=" + new Date(n).toGMTString()), f.isString(s) && o.push("path=" + s), f.isString(i) && o.push("domain=" + i), a === !0 && o.push("secure"), document.cookie = o.join("; ");
906
906
  },
907
907
  read(t) {
908
908
  const e = document.cookie.match(new RegExp("(^|;\\s*)(" + t + ")=([^;]*)"));
@@ -938,32 +938,32 @@ const yt = (t) => t instanceof re ? { ...t } : t;
938
938
  function me(t, e) {
939
939
  e = e || {};
940
940
  const n = {};
941
- function s(f, p, y, k) {
942
- return x.isPlainObject(f) && x.isPlainObject(p) ? x.merge.call({ caseless: k }, f, p) : x.isPlainObject(p) ? x.merge({}, p) : x.isArray(p) ? p.slice() : p;
941
+ function s(x, d, y, k) {
942
+ return f.isPlainObject(x) && f.isPlainObject(d) ? f.merge.call({ caseless: k }, x, d) : f.isPlainObject(d) ? f.merge({}, d) : f.isArray(d) ? d.slice() : d;
943
943
  }
944
- function i(f, p, y, k) {
945
- if (x.isUndefined(p)) {
946
- if (!x.isUndefined(f))
947
- return s(void 0, f, y, k);
948
- } else return s(f, p, y, k);
944
+ function i(x, d, y, k) {
945
+ if (f.isUndefined(d)) {
946
+ if (!f.isUndefined(x))
947
+ return s(void 0, x, y, k);
948
+ } else return s(x, d, y, k);
949
949
  }
950
- function a(f, p) {
951
- if (!x.isUndefined(p))
952
- return s(void 0, p);
950
+ function a(x, d) {
951
+ if (!f.isUndefined(d))
952
+ return s(void 0, d);
953
953
  }
954
- function o(f, p) {
955
- if (x.isUndefined(p)) {
956
- if (!x.isUndefined(f))
957
- return s(void 0, f);
958
- } else return s(void 0, p);
954
+ function o(x, d) {
955
+ if (f.isUndefined(d)) {
956
+ if (!f.isUndefined(x))
957
+ return s(void 0, x);
958
+ } else return s(void 0, d);
959
959
  }
960
- function c(f, p, y) {
960
+ function c(x, d, y) {
961
961
  if (y in e)
962
- return s(f, p);
962
+ return s(x, d);
963
963
  if (y in t)
964
- return s(void 0, f);
964
+ return s(void 0, x);
965
965
  }
966
- const d = {
966
+ const u = {
967
967
  url: a,
968
968
  method: a,
969
969
  data: a,
@@ -992,11 +992,11 @@ function me(t, e) {
992
992
  socketPath: o,
993
993
  responseEncoding: o,
994
994
  validateStatus: c,
995
- headers: (f, p, y) => i(yt(f), yt(p), y, !0)
995
+ headers: (x, d, y) => i(yt(x), yt(d), y, !0)
996
996
  };
997
- return x.forEach(Object.keys({ ...t, ...e }), function(p) {
998
- const y = d[p] || i, k = y(t[p], e[p], p);
999
- x.isUndefined(k) && y !== c || (n[p] = k);
997
+ return f.forEach(Object.keys({ ...t, ...e }), function(d) {
998
+ const y = u[d] || i, k = y(t[d], e[d], d);
999
+ f.isUndefined(k) && y !== c || (n[d] = k);
1000
1000
  }), n;
1001
1001
  }
1002
1002
  const Xt = (t) => {
@@ -1005,19 +1005,19 @@ const Xt = (t) => {
1005
1005
  if (e.headers = o = re.from(o), e.url = Ht(Gt(e.baseURL, e.url, e.allowAbsoluteUrls), t.params, t.paramsSerializer), c && o.set(
1006
1006
  "Authorization",
1007
1007
  "Basic " + btoa((c.username || "") + ":" + (c.password ? unescape(encodeURIComponent(c.password)) : ""))
1008
- ), x.isFormData(n)) {
1008
+ ), f.isFormData(n)) {
1009
1009
  if (Q.hasStandardBrowserEnv || Q.hasStandardBrowserWebWorkerEnv)
1010
1010
  o.setContentType(void 0);
1011
- else if (x.isFunction(n.getHeaders)) {
1012
- const d = n.getHeaders(), f = ["content-type", "content-length"];
1013
- Object.entries(d).forEach(([p, y]) => {
1014
- f.includes(p.toLowerCase()) && o.set(p, y);
1011
+ else if (f.isFunction(n.getHeaders)) {
1012
+ const u = n.getHeaders(), x = ["content-type", "content-length"];
1013
+ Object.entries(u).forEach(([d, y]) => {
1014
+ x.includes(d.toLowerCase()) && o.set(d, y);
1015
1015
  });
1016
1016
  }
1017
1017
  }
1018
- if (Q.hasStandardBrowserEnv && (s && x.isFunction(s) && (s = s(e)), s || s !== !1 && vn(e.url))) {
1019
- const d = i && a && Sn.read(a);
1020
- d && o.set(i, d);
1018
+ if (Q.hasStandardBrowserEnv && (s && f.isFunction(s) && (s = s(e)), s || s !== !1 && vn(e.url))) {
1019
+ const u = i && a && Sn.read(a);
1020
+ u && o.set(i, u);
1021
1021
  }
1022
1022
  return e;
1023
1023
  }, Cn = typeof XMLHttpRequest < "u", Tn = Cn && function(t) {
@@ -1025,9 +1025,9 @@ const Xt = (t) => {
1025
1025
  const i = Xt(t);
1026
1026
  let a = i.data;
1027
1027
  const o = re.from(i.headers).normalize();
1028
- let { responseType: c, onUploadProgress: d, onDownloadProgress: f } = i, p, y, k, E, u;
1028
+ let { responseType: c, onUploadProgress: u, onDownloadProgress: x } = i, d, y, k, E, p;
1029
1029
  function w() {
1030
- E && E(), u && u(), i.cancelToken && i.cancelToken.unsubscribe(p), i.signal && i.signal.removeEventListener("abort", p);
1030
+ E && E(), p && p(), i.cancelToken && i.cancelToken.unsubscribe(d), i.signal && i.signal.removeEventListener("abort", d);
1031
1031
  }
1032
1032
  let h = new XMLHttpRequest();
1033
1033
  h.open(i.method.toUpperCase(), i.url, !0), h.timeout = i.timeout;
@@ -1066,11 +1066,11 @@ const Xt = (t) => {
1066
1066
  t,
1067
1067
  h
1068
1068
  )), h = null;
1069
- }, a === void 0 && o.setContentType(null), "setRequestHeader" in h && x.forEach(o.toJSON(), function(A, N) {
1069
+ }, a === void 0 && o.setContentType(null), "setRequestHeader" in h && f.forEach(o.toJSON(), function(A, N) {
1070
1070
  h.setRequestHeader(N, A);
1071
- }), x.isUndefined(i.withCredentials) || (h.withCredentials = !!i.withCredentials), c && c !== "json" && (h.responseType = i.responseType), f && ([k, u] = Ne(f, !0), h.addEventListener("progress", k)), d && h.upload && ([y, E] = Ne(d), h.upload.addEventListener("progress", y), h.upload.addEventListener("loadend", E)), (i.cancelToken || i.signal) && (p = (g) => {
1071
+ }), f.isUndefined(i.withCredentials) || (h.withCredentials = !!i.withCredentials), c && c !== "json" && (h.responseType = i.responseType), x && ([k, p] = Ne(x, !0), h.addEventListener("progress", k)), u && h.upload && ([y, E] = Ne(u), h.upload.addEventListener("progress", y), h.upload.addEventListener("loadend", E)), (i.cancelToken || i.signal) && (d = (g) => {
1072
1072
  h && (s(!g || g.type ? new ve(null, t, h) : g), h.abort(), h = null);
1073
- }, i.cancelToken && i.cancelToken.subscribe(p), i.signal && (i.signal.aborted ? p() : i.signal.addEventListener("abort", p)));
1073
+ }, i.cancelToken && i.cancelToken.subscribe(d), i.signal && (i.signal.aborted ? d() : i.signal.addEventListener("abort", d)));
1074
1074
  const C = bn(i.url);
1075
1075
  if (C && Q.protocols.indexOf(C) === -1) {
1076
1076
  s(new $("Unsupported protocol " + C + ":", $.ERR_BAD_REQUEST, t));
@@ -1082,24 +1082,24 @@ const Xt = (t) => {
1082
1082
  const { length: n } = t = t ? t.filter(Boolean) : [];
1083
1083
  if (e || n) {
1084
1084
  let s = new AbortController(), i;
1085
- const a = function(f) {
1085
+ const a = function(x) {
1086
1086
  if (!i) {
1087
1087
  i = !0, c();
1088
- const p = f instanceof Error ? f : this.reason;
1089
- s.abort(p instanceof $ ? p : new ve(p instanceof Error ? p.message : p));
1088
+ const d = x instanceof Error ? x : this.reason;
1089
+ s.abort(d instanceof $ ? d : new ve(d instanceof Error ? d.message : d));
1090
1090
  }
1091
1091
  };
1092
1092
  let o = e && setTimeout(() => {
1093
1093
  o = null, a(new $(`timeout ${e} of ms exceeded`, $.ETIMEDOUT));
1094
1094
  }, e);
1095
1095
  const c = () => {
1096
- t && (o && clearTimeout(o), o = null, t.forEach((f) => {
1097
- f.unsubscribe ? f.unsubscribe(a) : f.removeEventListener("abort", a);
1096
+ t && (o && clearTimeout(o), o = null, t.forEach((x) => {
1097
+ x.unsubscribe ? x.unsubscribe(a) : x.removeEventListener("abort", a);
1098
1098
  }), t = null);
1099
1099
  };
1100
- t.forEach((f) => f.addEventListener("abort", a));
1101
- const { signal: d } = s;
1102
- return d.unsubscribe = () => x.asap(c), d;
1100
+ t.forEach((x) => x.addEventListener("abort", a));
1101
+ const { signal: u } = s;
1102
+ return u.unsubscribe = () => f.asap(c), u;
1103
1103
  }
1104
1104
  }, Pn = function* (t, e) {
1105
1105
  let n = t.byteLength;
@@ -1131,92 +1131,92 @@ const Xt = (t) => {
1131
1131
  }
1132
1132
  }, bt = (t, e, n, s) => {
1133
1133
  const i = On(t, e);
1134
- let a = 0, o, c = (d) => {
1135
- o || (o = !0, s && s(d));
1134
+ let a = 0, o, c = (u) => {
1135
+ o || (o = !0, s && s(u));
1136
1136
  };
1137
1137
  return new ReadableStream({
1138
- async pull(d) {
1138
+ async pull(u) {
1139
1139
  try {
1140
- const { done: f, value: p } = await i.next();
1141
- if (f) {
1142
- c(), d.close();
1140
+ const { done: x, value: d } = await i.next();
1141
+ if (x) {
1142
+ c(), u.close();
1143
1143
  return;
1144
1144
  }
1145
- let y = p.byteLength;
1145
+ let y = d.byteLength;
1146
1146
  if (n) {
1147
1147
  let k = a += y;
1148
1148
  n(k);
1149
1149
  }
1150
- d.enqueue(new Uint8Array(p));
1151
- } catch (f) {
1152
- throw c(f), f;
1150
+ u.enqueue(new Uint8Array(d));
1151
+ } catch (x) {
1152
+ throw c(x), x;
1153
1153
  }
1154
1154
  },
1155
- cancel(d) {
1156
- return c(d), i.return();
1155
+ cancel(u) {
1156
+ return c(u), i.return();
1157
1157
  }
1158
1158
  }, {
1159
1159
  highWaterMark: 2
1160
1160
  });
1161
- }, wt = 64 * 1024, { isFunction: ze } = x, zn = (({ Request: t, Response: e }) => ({
1161
+ }, wt = 64 * 1024, { isFunction: ze } = f, zn = (({ Request: t, Response: e }) => ({
1162
1162
  Request: t,
1163
1163
  Response: e
1164
- }))(x.global), {
1164
+ }))(f.global), {
1165
1165
  ReadableStream: jt,
1166
1166
  TextEncoder: vt
1167
- } = x.global, St = (t, ...e) => {
1167
+ } = f.global, St = (t, ...e) => {
1168
1168
  try {
1169
1169
  return !!t(...e);
1170
1170
  } catch {
1171
1171
  return !1;
1172
1172
  }
1173
1173
  }, An = (t) => {
1174
- t = x.merge.call({
1174
+ t = f.merge.call({
1175
1175
  skipUndefined: !0
1176
1176
  }, zn, t);
1177
1177
  const { fetch: e, Request: n, Response: s } = t, i = e ? ze(e) : typeof fetch == "function", a = ze(n), o = ze(s);
1178
1178
  if (!i)
1179
1179
  return !1;
1180
- const c = i && ze(jt), d = i && (typeof vt == "function" ? /* @__PURE__ */ ((u) => (w) => u.encode(w))(new vt()) : async (u) => new Uint8Array(await new n(u).arrayBuffer())), f = a && c && St(() => {
1181
- let u = !1;
1180
+ const c = i && ze(jt), u = i && (typeof vt == "function" ? /* @__PURE__ */ ((p) => (w) => p.encode(w))(new vt()) : async (p) => new Uint8Array(await new n(p).arrayBuffer())), x = a && c && St(() => {
1181
+ let p = !1;
1182
1182
  const w = new n(Q.origin, {
1183
1183
  body: new jt(),
1184
1184
  method: "POST",
1185
1185
  get duplex() {
1186
- return u = !0, "half";
1186
+ return p = !0, "half";
1187
1187
  }
1188
1188
  }).headers.has("Content-Type");
1189
- return u && !w;
1190
- }), p = o && c && St(() => x.isReadableStream(new s("").body)), y = {
1191
- stream: p && ((u) => u.body)
1189
+ return p && !w;
1190
+ }), d = o && c && St(() => f.isReadableStream(new s("").body)), y = {
1191
+ stream: d && ((p) => p.body)
1192
1192
  };
1193
- i && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((u) => {
1194
- !y[u] && (y[u] = (w, h) => {
1195
- let O = w && w[u];
1193
+ i && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((p) => {
1194
+ !y[p] && (y[p] = (w, h) => {
1195
+ let O = w && w[p];
1196
1196
  if (O)
1197
1197
  return O.call(w);
1198
- throw new $(`Response type '${u}' is not supported`, $.ERR_NOT_SUPPORT, h);
1198
+ throw new $(`Response type '${p}' is not supported`, $.ERR_NOT_SUPPORT, h);
1199
1199
  });
1200
1200
  });
1201
- const k = async (u) => {
1202
- if (u == null)
1201
+ const k = async (p) => {
1202
+ if (p == null)
1203
1203
  return 0;
1204
- if (x.isBlob(u))
1205
- return u.size;
1206
- if (x.isSpecCompliantForm(u))
1204
+ if (f.isBlob(p))
1205
+ return p.size;
1206
+ if (f.isSpecCompliantForm(p))
1207
1207
  return (await new n(Q.origin, {
1208
1208
  method: "POST",
1209
- body: u
1209
+ body: p
1210
1210
  }).arrayBuffer()).byteLength;
1211
- if (x.isArrayBufferView(u) || x.isArrayBuffer(u))
1212
- return u.byteLength;
1213
- if (x.isURLSearchParams(u) && (u = u + ""), x.isString(u))
1214
- return (await d(u)).byteLength;
1215
- }, E = async (u, w) => {
1216
- const h = x.toFiniteNumber(u.getContentLength());
1211
+ if (f.isArrayBufferView(p) || f.isArrayBuffer(p))
1212
+ return p.byteLength;
1213
+ if (f.isURLSearchParams(p) && (p = p + ""), f.isString(p))
1214
+ return (await u(p)).byteLength;
1215
+ }, E = async (p, w) => {
1216
+ const h = f.toFiniteNumber(p.getContentLength());
1217
1217
  return h ?? k(w);
1218
1218
  };
1219
- return async (u) => {
1219
+ return async (p) => {
1220
1220
  let {
1221
1221
  url: w,
1222
1222
  method: h,
@@ -1230,7 +1230,7 @@ const Xt = (t) => {
1230
1230
  headers: q,
1231
1231
  withCredentials: I = "same-origin",
1232
1232
  fetchOptions: X
1233
- } = Xt(u), W = e || fetch;
1233
+ } = Xt(p), W = e || fetch;
1234
1234
  j = j ? (j + "").toLowerCase() : "text";
1235
1235
  let T = Rn([C, g && g.toAbortSignal()], A), G = null;
1236
1236
  const R = T && T.unsubscribe && (() => {
@@ -1238,13 +1238,13 @@ const Xt = (t) => {
1238
1238
  });
1239
1239
  let z;
1240
1240
  try {
1241
- if (b && f && h !== "get" && h !== "head" && (z = await E(q, O)) !== 0) {
1241
+ if (b && x && h !== "get" && h !== "head" && (z = await E(q, O)) !== 0) {
1242
1242
  let l = new n(w, {
1243
1243
  method: "POST",
1244
1244
  body: O,
1245
1245
  duplex: "half"
1246
1246
  }), m;
1247
- if (x.isFormData(O) && (m = l.headers.get("content-type")) && q.setContentType(m), l.body) {
1247
+ if (f.isFormData(O) && (m = l.headers.get("content-type")) && q.setContentType(m), l.body) {
1248
1248
  const [S, D] = mt(
1249
1249
  z,
1250
1250
  Ne(gt(b))
@@ -1252,7 +1252,7 @@ const Xt = (t) => {
1252
1252
  O = bt(l.body, wt, S, D);
1253
1253
  }
1254
1254
  }
1255
- x.isString(I) || (I = I ? "include" : "omit");
1255
+ f.isString(I) || (I = I ? "include" : "omit");
1256
1256
  const M = a && "credentials" in n.prototype, K = {
1257
1257
  ...X,
1258
1258
  signal: T,
@@ -1264,13 +1264,13 @@ const Xt = (t) => {
1264
1264
  };
1265
1265
  G = a && new n(w, K);
1266
1266
  let H = await (a ? W(G, X) : W(w, K));
1267
- const L = p && (j === "stream" || j === "response");
1268
- if (p && (N || L && R)) {
1267
+ const L = d && (j === "stream" || j === "response");
1268
+ if (d && (N || L && R)) {
1269
1269
  const l = {};
1270
1270
  ["status", "statusText", "headers"].forEach((ne) => {
1271
1271
  l[ne] = H[ne];
1272
1272
  });
1273
- const m = x.toFiniteNumber(H.headers.get("content-length")), [S, D] = N && mt(
1273
+ const m = f.toFiniteNumber(H.headers.get("content-length")), [S, D] = N && mt(
1274
1274
  m,
1275
1275
  Ne(gt(N), !0)
1276
1276
  ) || [];
@@ -1282,24 +1282,24 @@ const Xt = (t) => {
1282
1282
  );
1283
1283
  }
1284
1284
  j = j || "text";
1285
- let Y = await y[x.findKey(y, j) || "text"](H, u);
1285
+ let Y = await y[f.findKey(y, j) || "text"](H, p);
1286
1286
  return !L && R && R(), await new Promise((l, m) => {
1287
1287
  Kt(l, m, {
1288
1288
  data: Y,
1289
1289
  headers: re.from(H.headers),
1290
1290
  status: H.status,
1291
1291
  statusText: H.statusText,
1292
- config: u,
1292
+ config: p,
1293
1293
  request: G
1294
1294
  });
1295
1295
  });
1296
1296
  } catch (M) {
1297
1297
  throw R && R(), M && M.name === "TypeError" && /Load failed|fetch/i.test(M.message) ? Object.assign(
1298
- new $("Network Error", $.ERR_NETWORK, u, G),
1298
+ new $("Network Error", $.ERR_NETWORK, p, G),
1299
1299
  {
1300
1300
  cause: M.cause || M
1301
1301
  }
1302
- ) : $.from(M, M && M.code, u, G);
1302
+ ) : $.from(M, M && M.code, p, G);
1303
1303
  }
1304
1304
  };
1305
1305
  }, _n = /* @__PURE__ */ new Map(), Zt = (t) => {
@@ -1309,10 +1309,10 @@ const Xt = (t) => {
1309
1309
  i,
1310
1310
  n
1311
1311
  ];
1312
- let o = a.length, c = o, d, f, p = _n;
1312
+ let o = a.length, c = o, u, x, d = _n;
1313
1313
  for (; c--; )
1314
- d = a[c], f = p.get(d), f === void 0 && p.set(d, f = c ? /* @__PURE__ */ new Map() : An(e)), p = f;
1315
- return f;
1314
+ u = a[c], x = d.get(u), x === void 0 && d.set(u, x = c ? /* @__PURE__ */ new Map() : An(e)), d = x;
1315
+ return x;
1316
1316
  };
1317
1317
  Zt();
1318
1318
  const Qe = {
@@ -1322,7 +1322,7 @@ const Qe = {
1322
1322
  get: Zt
1323
1323
  }
1324
1324
  };
1325
- x.forEach(Qe, (t, e) => {
1325
+ f.forEach(Qe, (t, e) => {
1326
1326
  if (t) {
1327
1327
  try {
1328
1328
  Object.defineProperty(t, "name", { value: e });
@@ -1331,9 +1331,9 @@ x.forEach(Qe, (t, e) => {
1331
1331
  Object.defineProperty(t, "adapterName", { value: e });
1332
1332
  }
1333
1333
  });
1334
- const kt = (t) => `- ${t}`, Un = (t) => x.isFunction(t) || t === null || t === !1, Qt = {
1334
+ const kt = (t) => `- ${t}`, Un = (t) => f.isFunction(t) || t === null || t === !1, Qt = {
1335
1335
  getAdapter: (t, e) => {
1336
- t = x.isArray(t) ? t : [t];
1336
+ t = f.isArray(t) ? t : [t];
1337
1337
  const { length: n } = t;
1338
1338
  let s, i;
1339
1339
  const a = {};
@@ -1342,13 +1342,13 @@ const kt = (t) => `- ${t}`, Un = (t) => x.isFunction(t) || t === null || t === !
1342
1342
  let c;
1343
1343
  if (i = s, !Un(s) && (i = Qe[(c = String(s)).toLowerCase()], i === void 0))
1344
1344
  throw new $(`Unknown adapter '${c}'`);
1345
- if (i && (x.isFunction(i) || (i = i.get(e))))
1345
+ if (i && (f.isFunction(i) || (i = i.get(e))))
1346
1346
  break;
1347
1347
  a[c || "#" + o] = i;
1348
1348
  }
1349
1349
  if (!i) {
1350
1350
  const o = Object.entries(a).map(
1351
- ([d, f]) => `adapter ${d} ` + (f === !1 ? "is not supported by the environment" : "is not available in the build")
1351
+ ([u, x]) => `adapter ${u} ` + (x === !1 ? "is not supported by the environment" : "is not available in the build")
1352
1352
  );
1353
1353
  let c = n ? o.length > 1 ? `since :
1354
1354
  ` + o.map(kt).join(`
@@ -1420,9 +1420,9 @@ function $n(t, e, n) {
1420
1420
  for (; i-- > 0; ) {
1421
1421
  const a = s[i], o = e[a];
1422
1422
  if (o) {
1423
- const c = t[a], d = c === void 0 || o(c, a, t);
1424
- if (d !== !0)
1425
- throw new $("option " + a + " must be " + d, $.ERR_BAD_OPTION_VALUE);
1423
+ const c = t[a], u = c === void 0 || o(c, a, t);
1424
+ if (u !== !0)
1425
+ throw new $("option " + a + " must be " + u, $.ERR_BAD_OPTION_VALUE);
1426
1426
  continue;
1427
1427
  }
1428
1428
  if (n !== !0)
@@ -1472,7 +1472,7 @@ let he = class {
1472
1472
  silentJSONParsing: ce.transitional(ce.boolean),
1473
1473
  forcedJSONParsing: ce.transitional(ce.boolean),
1474
1474
  clarifyTimeoutError: ce.transitional(ce.boolean)
1475
- }, !1), i != null && (x.isFunction(i) ? n.paramsSerializer = {
1475
+ }, !1), i != null && (f.isFunction(i) ? n.paramsSerializer = {
1476
1476
  serialize: i
1477
1477
  } : $e.assertOptions(i, {
1478
1478
  encode: ce.function,
@@ -1481,51 +1481,51 @@ let he = class {
1481
1481
  baseUrl: ce.spelling("baseURL"),
1482
1482
  withXsrfToken: ce.spelling("withXSRFToken")
1483
1483
  }, !0), n.method = (n.method || this.defaults.method || "get").toLowerCase();
1484
- let o = a && x.merge(
1484
+ let o = a && f.merge(
1485
1485
  a.common,
1486
1486
  a[n.method]
1487
1487
  );
1488
- a && x.forEach(
1488
+ a && f.forEach(
1489
1489
  ["delete", "get", "head", "post", "put", "patch", "common"],
1490
- (u) => {
1491
- delete a[u];
1490
+ (p) => {
1491
+ delete a[p];
1492
1492
  }
1493
1493
  ), n.headers = re.concat(o, a);
1494
1494
  const c = [];
1495
- let d = !0;
1495
+ let u = !0;
1496
1496
  this.interceptors.request.forEach(function(w) {
1497
- typeof w.runWhen == "function" && w.runWhen(n) === !1 || (d = d && w.synchronous, c.unshift(w.fulfilled, w.rejected));
1497
+ typeof w.runWhen == "function" && w.runWhen(n) === !1 || (u = u && w.synchronous, c.unshift(w.fulfilled, w.rejected));
1498
1498
  });
1499
- const f = [];
1499
+ const x = [];
1500
1500
  this.interceptors.response.forEach(function(w) {
1501
- f.push(w.fulfilled, w.rejected);
1501
+ x.push(w.fulfilled, w.rejected);
1502
1502
  });
1503
- let p, y = 0, k;
1504
- if (!d) {
1505
- const u = [Et.bind(this), void 0];
1506
- for (u.unshift(...c), u.push(...f), k = u.length, p = Promise.resolve(n); y < k; )
1507
- p = p.then(u[y++], u[y++]);
1508
- return p;
1503
+ let d, y = 0, k;
1504
+ if (!u) {
1505
+ const p = [Et.bind(this), void 0];
1506
+ for (p.unshift(...c), p.push(...x), k = p.length, d = Promise.resolve(n); y < k; )
1507
+ d = d.then(p[y++], p[y++]);
1508
+ return d;
1509
1509
  }
1510
1510
  k = c.length;
1511
1511
  let E = n;
1512
1512
  for (; y < k; ) {
1513
- const u = c[y++], w = c[y++];
1513
+ const p = c[y++], w = c[y++];
1514
1514
  try {
1515
- E = u(E);
1515
+ E = p(E);
1516
1516
  } catch (h) {
1517
1517
  w.call(this, h);
1518
1518
  break;
1519
1519
  }
1520
1520
  }
1521
1521
  try {
1522
- p = Et.call(this, E);
1523
- } catch (u) {
1524
- return Promise.reject(u);
1522
+ d = Et.call(this, E);
1523
+ } catch (p) {
1524
+ return Promise.reject(p);
1525
1525
  }
1526
- for (y = 0, k = f.length; y < k; )
1527
- p = p.then(f[y++], f[y++]);
1528
- return p;
1526
+ for (y = 0, k = x.length; y < k; )
1527
+ d = d.then(x[y++], x[y++]);
1528
+ return d;
1529
1529
  }
1530
1530
  getUri(e) {
1531
1531
  e = me(this.defaults, e);
@@ -1533,7 +1533,7 @@ let he = class {
1533
1533
  return Ht(n, e.params, e.paramsSerializer);
1534
1534
  }
1535
1535
  };
1536
- x.forEach(["delete", "get", "head", "options"], function(e) {
1536
+ f.forEach(["delete", "get", "head", "options"], function(e) {
1537
1537
  he.prototype[e] = function(n, s) {
1538
1538
  return this.request(me(s || {}, {
1539
1539
  method: e,
@@ -1542,7 +1542,7 @@ x.forEach(["delete", "get", "head", "options"], function(e) {
1542
1542
  }));
1543
1543
  };
1544
1544
  });
1545
- x.forEach(["post", "put", "patch"], function(e) {
1545
+ f.forEach(["post", "put", "patch"], function(e) {
1546
1546
  function n(s) {
1547
1547
  return function(a, o, c) {
1548
1548
  return this.request(me(c || {}, {
@@ -1636,7 +1636,7 @@ function Nn(t) {
1636
1636
  };
1637
1637
  }
1638
1638
  function Ln(t) {
1639
- return x.isObject(t) && t.isAxiosError === !0;
1639
+ return f.isObject(t) && t.isAxiosError === !0;
1640
1640
  }
1641
1641
  const et = {
1642
1642
  Continue: 100,
@@ -1708,7 +1708,7 @@ Object.entries(et).forEach(([t, e]) => {
1708
1708
  });
1709
1709
  function rr(t) {
1710
1710
  const e = new he(t), n = At(he.prototype.request, e);
1711
- return x.extend(n, he.prototype, e, { allOwnKeys: !0 }), x.extend(n, e, null, { allOwnKeys: !0 }), n.create = function(i) {
1711
+ return f.extend(n, he.prototype, e, { allOwnKeys: !0 }), f.extend(n, e, null, { allOwnKeys: !0 }), n.create = function(i) {
1712
1712
  return rr(me(t, i));
1713
1713
  }, n;
1714
1714
  }
@@ -1728,7 +1728,7 @@ J.spread = Nn;
1728
1728
  J.isAxiosError = Ln;
1729
1729
  J.mergeConfig = me;
1730
1730
  J.AxiosHeaders = re;
1731
- J.formToJSON = (t) => Yt(x.isHTMLForm(t) ? new FormData(t) : t);
1731
+ J.formToJSON = (t) => Yt(f.isHTMLForm(t) ? new FormData(t) : t);
1732
1732
  J.getAdapter = Qt.getAdapter;
1733
1733
  J.HttpStatusCode = et;
1734
1734
  J.default = J;
@@ -2411,23 +2411,23 @@ function qn() {
2411
2411
  configurable: !0
2412
2412
  });
2413
2413
  }
2414
- function d() {
2414
+ function u() {
2415
2415
  var l = t(this.type);
2416
2416
  return K[l] || (K[l] = !0, console.error(
2417
2417
  "Accessing element.ref was removed in React 19. ref is now a regular prop. It will be removed from the JSX Element type in a future release."
2418
2418
  )), l = this.props.ref, l !== void 0 ? l : null;
2419
2419
  }
2420
- function f(l, m, S, D, ne, oe) {
2420
+ function x(l, m, S, D, ne, oe) {
2421
2421
  var B = S.ref;
2422
2422
  return l = {
2423
- $$typeof: u,
2423
+ $$typeof: p,
2424
2424
  type: l,
2425
2425
  key: m,
2426
2426
  props: S,
2427
2427
  _owner: D
2428
2428
  }, (B !== void 0 ? B : null) !== null ? Object.defineProperty(l, "ref", {
2429
2429
  enumerable: !1,
2430
- get: d
2430
+ get: u
2431
2431
  }) : Object.defineProperty(l, "ref", { enumerable: !1, value: null }), l._store = {}, Object.defineProperty(l._store, "validated", {
2432
2432
  configurable: !1,
2433
2433
  enumerable: !1,
@@ -2450,7 +2450,7 @@ function qn() {
2450
2450
  value: oe
2451
2451
  }), Object.freeze && (Object.freeze(l.props), Object.freeze(l)), l;
2452
2452
  }
2453
- function p(l, m, S, D, ne, oe) {
2453
+ function d(l, m, S, D, ne, oe) {
2454
2454
  var B = m.children;
2455
2455
  if (B !== void 0)
2456
2456
  if (D)
@@ -2489,7 +2489,7 @@ React keys must be passed directly to JSX without using spread:
2489
2489
  return B && c(
2490
2490
  S,
2491
2491
  typeof l == "function" ? l.displayName || l.name || "Unknown" : l
2492
- ), f(
2492
+ ), x(
2493
2493
  l,
2494
2494
  B,
2495
2495
  S,
@@ -2502,9 +2502,9 @@ React keys must be passed directly to JSX without using spread:
2502
2502
  k(l) ? l._store && (l._store.validated = 1) : typeof l == "object" && l !== null && l.$$typeof === I && (l._payload.status === "fulfilled" ? k(l._payload.value) && l._payload.value._store && (l._payload.value._store.validated = 1) : l._store && (l._store.validated = 1));
2503
2503
  }
2504
2504
  function k(l) {
2505
- return typeof l == "object" && l !== null && l.$$typeof === u;
2505
+ return typeof l == "object" && l !== null && l.$$typeof === p;
2506
2506
  }
2507
- var E = Ce, u = Symbol.for("react.transitional.element"), w = Symbol.for("react.portal"), h = Symbol.for("react.fragment"), O = Symbol.for("react.strict_mode"), C = Symbol.for("react.profiler"), g = Symbol.for("react.consumer"), A = Symbol.for("react.context"), N = Symbol.for("react.forward_ref"), b = Symbol.for("react.suspense"), j = Symbol.for("react.suspense_list"), q = Symbol.for("react.memo"), I = Symbol.for("react.lazy"), X = Symbol.for("react.activity"), W = Symbol.for("react.client.reference"), T = E.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, G = Object.prototype.hasOwnProperty, R = Array.isArray, z = console.createTask ? console.createTask : function() {
2507
+ var E = Ce, p = Symbol.for("react.transitional.element"), w = Symbol.for("react.portal"), h = Symbol.for("react.fragment"), O = Symbol.for("react.strict_mode"), C = Symbol.for("react.profiler"), g = Symbol.for("react.consumer"), A = Symbol.for("react.context"), N = Symbol.for("react.forward_ref"), b = Symbol.for("react.suspense"), j = Symbol.for("react.suspense_list"), q = Symbol.for("react.memo"), I = Symbol.for("react.lazy"), X = Symbol.for("react.activity"), W = Symbol.for("react.client.reference"), T = E.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, G = Object.prototype.hasOwnProperty, R = Array.isArray, z = console.createTask ? console.createTask : function() {
2508
2508
  return null;
2509
2509
  };
2510
2510
  E = {
@@ -2518,7 +2518,7 @@ React keys must be passed directly to JSX without using spread:
2518
2518
  )(), L = z(s(a)), Y = {};
2519
2519
  Ee.Fragment = h, Ee.jsx = function(l, m, S) {
2520
2520
  var D = 1e4 > T.recentlyCreatedOwnerStacks++;
2521
- return p(
2521
+ return d(
2522
2522
  l,
2523
2523
  m,
2524
2524
  S,
@@ -2528,7 +2528,7 @@ React keys must be passed directly to JSX without using spread:
2528
2528
  );
2529
2529
  }, Ee.jsxs = function(l, m, S) {
2530
2530
  var D = 1e4 > T.recentlyCreatedOwnerStacks++;
2531
- return p(
2531
+ return d(
2532
2532
  l,
2533
2533
  m,
2534
2534
  S,
@@ -2594,10 +2594,10 @@ const Yn = zt(
2594
2594
  children: a,
2595
2595
  iconNode: o,
2596
2596
  ...c
2597
- }, d) => Ke(
2597
+ }, u) => Ke(
2598
2598
  "svg",
2599
2599
  {
2600
- ref: d,
2600
+ ref: u,
2601
2601
  ...Vn,
2602
2602
  width: e,
2603
2603
  height: e,
@@ -2608,7 +2608,7 @@ const Yn = zt(
2608
2608
  ...c
2609
2609
  },
2610
2610
  [
2611
- ...o.map(([f, p]) => Ke(f, p)),
2611
+ ...o.map(([x, d]) => Ke(x, d)),
2612
2612
  ...Array.isArray(a) ? a : [a]
2613
2613
  ]
2614
2614
  )
@@ -2884,7 +2884,7 @@ const bs = [
2884
2884
  const ws = [
2885
2885
  ["path", { d: "m22 7-8.991 5.727a2 2 0 0 1-2.009 0L2 7", key: "132q7q" }],
2886
2886
  ["rect", { x: "2", y: "4", width: "20", height: "16", rx: "2", key: "izxlao" }]
2887
- ], pe = F("mail", ws);
2887
+ ], fe = F("mail", ws);
2888
2888
  /**
2889
2889
  * @license lucide-react v0.544.0 - ISC
2890
2890
  *
@@ -3060,7 +3060,7 @@ const Ns = [
3060
3060
  ], Ie = F("x", Ns), or = cr(null), ci = ({
3061
3061
  authix: t,
3062
3062
  children: e
3063
- }) => /* @__PURE__ */ r.jsx(or.Provider, { value: t, children: e }), fe = () => {
3063
+ }) => /* @__PURE__ */ r.jsx(or.Provider, { value: t, children: e }), pe = () => {
3064
3064
  const t = dr(or);
3065
3065
  if (!t)
3066
3066
  throw new Error("useAuthix must be used inside <AuthixProvider />");
@@ -3075,21 +3075,21 @@ const Ns = [
3075
3075
  darkMode: o = !0,
3076
3076
  // Only avatar is optional
3077
3077
  showAvatar: c = !1,
3078
- roles: d = [],
3078
+ roles: u = [],
3079
3079
  // 🔥 FIXED
3080
- showRoleSelector: f = !1,
3080
+ showRoleSelector: x = !1,
3081
3081
  // 🔥 FIXED
3082
- loginUrl: p,
3082
+ loginUrl: d,
3083
3083
  onSuccess: y,
3084
3084
  onError: k
3085
3085
  }) => {
3086
- const E = fe(), u = {
3086
+ const E = pe(), p = {
3087
3087
  name: "",
3088
3088
  email: "",
3089
3089
  password: "",
3090
- role: d.length ? d[0] : "user",
3090
+ role: u.length ? u[0] : "user",
3091
3091
  ...c && { avatarUrl: "" }
3092
- }, [w, h] = P(u), [O, C] = P(!1), [g, A] = P(!1), [N, b] = P(null), [j, q] = P({}), [I, X] = P(!1), W = o ? "#ffffff" : "#111827", T = o ? "#a1a1aa" : "#6b7280", G = o ? "rgba(255,255,255,0.05)" : "rgba(0,0,0,0.02)", R = o ? "rgba(255,255,255,0.1)" : "rgba(0,0,0,0.1)";
3092
+ }, [w, h] = P(p), [O, C] = P(!1), [g, A] = P(!1), [N, b] = P(null), [j, q] = P({}), [I, X] = P(!1), W = o ? "#ffffff" : "#111827", T = o ? "#a1a1aa" : "#6b7280", G = o ? "rgba(255,255,255,0.05)" : "rgba(0,0,0,0.02)", R = o ? "rgba(255,255,255,0.1)" : "rgba(0,0,0,0.1)";
3093
3093
  Ce.useEffect(() => {
3094
3094
  if (typeof window < "u") {
3095
3095
  const L = () => X(window.innerWidth < 768);
@@ -3254,7 +3254,7 @@ const Ns = [
3254
3254
  onSubmit: K,
3255
3255
  style: { display: "flex", flexDirection: "column", gap: "14px" },
3256
3256
  children: [
3257
- f && d && d.length === 2 && /* @__PURE__ */ r.jsxs(
3257
+ x && u && u.length === 2 && /* @__PURE__ */ r.jsxs(
3258
3258
  "div",
3259
3259
  {
3260
3260
  style: { display: "flex", flexDirection: "column", gap: "4px" },
@@ -3299,7 +3299,7 @@ const Ns = [
3299
3299
  // subtle shadow
3300
3300
  borderRadius: "10px",
3301
3301
  transition: "transform 0.3s ease, background-color 0.3s ease",
3302
- transform: w.role === d[1] ? "translateX(100%)" : "translateX(0)",
3302
+ transform: w.role === u[1] ? "translateX(100%)" : "translateX(0)",
3303
3303
  zIndex: 0
3304
3304
  }
3305
3305
  }
@@ -3308,43 +3308,43 @@ const Ns = [
3308
3308
  "button",
3309
3309
  {
3310
3310
  type: "button",
3311
- onClick: () => h((L) => ({ ...L, role: d[0] })),
3311
+ onClick: () => h((L) => ({ ...L, role: u[0] })),
3312
3312
  style: {
3313
3313
  flex: 1,
3314
3314
  zIndex: 10,
3315
3315
  border: "none",
3316
3316
  background: "transparent",
3317
- color: w.role === d[0] ? i : o ? "#9ca3af" : "#6b7280",
3317
+ color: w.role === u[0] ? i : o ? "#9ca3af" : "#6b7280",
3318
3318
  // theme-aware inactive color
3319
- fontWeight: w.role === d[0] ? 600 : 500,
3319
+ fontWeight: w.role === u[0] ? 600 : 500,
3320
3320
  fontSize: "14px",
3321
3321
  display: "flex",
3322
3322
  alignItems: "center",
3323
3323
  justifyContent: "center",
3324
3324
  transition: "color 0.2s ease"
3325
3325
  },
3326
- children: d[0].charAt(0).toUpperCase() + d[0].slice(1)
3326
+ children: u[0].charAt(0).toUpperCase() + u[0].slice(1)
3327
3327
  }
3328
3328
  ),
3329
3329
  /* @__PURE__ */ r.jsx(
3330
3330
  "button",
3331
3331
  {
3332
3332
  type: "button",
3333
- onClick: () => h((L) => ({ ...L, role: d[1] })),
3333
+ onClick: () => h((L) => ({ ...L, role: u[1] })),
3334
3334
  style: {
3335
3335
  flex: 1,
3336
3336
  zIndex: 10,
3337
3337
  border: "none",
3338
3338
  background: "transparent",
3339
- color: w.role === d[1] ? i : o ? "#9ca3af" : "#6b7280",
3340
- fontWeight: w.role === d[1] ? 600 : 500,
3339
+ color: w.role === u[1] ? i : o ? "#9ca3af" : "#6b7280",
3340
+ fontWeight: w.role === u[1] ? 600 : 500,
3341
3341
  fontSize: "14px",
3342
3342
  display: "flex",
3343
3343
  alignItems: "center",
3344
3344
  justifyContent: "center",
3345
3345
  transition: "color 0.2s ease"
3346
3346
  },
3347
- children: d[1].charAt(0).toUpperCase() + d[1].slice(1)
3347
+ children: u[1].charAt(0).toUpperCase() + u[1].slice(1)
3348
3348
  }
3349
3349
  )
3350
3350
  ]
@@ -3423,7 +3423,7 @@ const Ns = [
3423
3423
  ),
3424
3424
  /* @__PURE__ */ r.jsxs("div", { style: { position: "relative" }, children: [
3425
3425
  /* @__PURE__ */ r.jsx(
3426
- pe,
3426
+ fe,
3427
3427
  {
3428
3428
  size: 20,
3429
3429
  style: {
@@ -3584,7 +3584,7 @@ const Ns = [
3584
3584
  ]
3585
3585
  }
3586
3586
  ),
3587
- p && /* @__PURE__ */ r.jsx(
3587
+ d && /* @__PURE__ */ r.jsx(
3588
3588
  "div",
3589
3589
  {
3590
3590
  style: {
@@ -3595,7 +3595,7 @@ const Ns = [
3595
3595
  children: /* @__PURE__ */ r.jsx(
3596
3596
  "a",
3597
3597
  {
3598
- href: p,
3598
+ href: d,
3599
3599
  style: {
3600
3600
  color: i,
3601
3601
  textDecoration: "none",
@@ -3699,10 +3699,10 @@ const Ns = [
3699
3699
  gradient: a = "linear-gradient(135deg, #22c55e, #00C214)",
3700
3700
  darkMode: o = !0,
3701
3701
  signupUrl: c,
3702
- onSuccess: d,
3703
- onError: f
3702
+ onSuccess: u,
3703
+ onError: x
3704
3704
  }) => {
3705
- const p = fe(), [y, k] = P("login"), [E, u] = P(1), [w, h] = P(!1), [O, C] = P(!1), [g, A] = P(null), [N, b] = P(""), [j, q] = P(""), [I, X] = P({
3705
+ const d = pe(), [y, k] = P("login"), [E, p] = P(1), [w, h] = P(!1), [O, C] = P(!1), [g, A] = P(null), [N, b] = P(""), [j, q] = P(""), [I, X] = P({
3706
3706
  email: "",
3707
3707
  otp: "",
3708
3708
  newPassword: ""
@@ -3716,17 +3716,17 @@ const Ns = [
3716
3716
  const K = async (m) => {
3717
3717
  m.preventDefault(), C(!0), A(null);
3718
3718
  try {
3719
- const S = await p.loginUser({ email: N, password: j }), { user: D } = S;
3719
+ const S = await d.loginUser({ email: N, password: j }), { user: D } = S;
3720
3720
  if (!D)
3721
3721
  throw new Error(S.message || "Login failed");
3722
3722
  if (typeof document < "u") {
3723
3723
  const ne = "a_s_b", oe = "true", B = /* @__PURE__ */ new Date();
3724
3724
  B.setTime(B.getTime() + 1440 * 60 * 1e3), document.cookie = `${ne}=${oe}; path=/; expires=${B.toUTCString()}; SameSite=Lax`;
3725
3725
  }
3726
- A({ type: "success", text: `Welcome ${D.name}` }), d?.(D), typeof window < "u" && window.location.reload();
3726
+ A({ type: "success", text: `Welcome ${D.name}` }), u?.(D), typeof window < "u" && window.location.reload();
3727
3727
  } catch (S) {
3728
3728
  const D = S.message || "Login failed";
3729
- A({ type: "error", text: D }), f?.(S);
3729
+ A({ type: "error", text: D }), x?.(S);
3730
3730
  } finally {
3731
3731
  C(!1);
3732
3732
  }
@@ -3735,10 +3735,10 @@ const Ns = [
3735
3735
  }, L = async (m) => {
3736
3736
  m.preventDefault(), C(!0), A(null);
3737
3737
  try {
3738
- const S = await p.requestResetUserPasswordOTP({
3738
+ const S = await d.requestResetUserPasswordOTP({
3739
3739
  email: I.email
3740
3740
  });
3741
- S.success ? (u(2), A({
3741
+ S.success ? (p(2), A({
3742
3742
  type: "success",
3743
3743
  text: S.message || "OTP sent to your email"
3744
3744
  })) : A({
@@ -3756,7 +3756,7 @@ const Ns = [
3756
3756
  }, Y = async (m) => {
3757
3757
  m.preventDefault(), C(!0), A(null);
3758
3758
  try {
3759
- const S = await p.resetUserPassword({
3759
+ const S = await d.resetUserPassword({
3760
3760
  email: I.email,
3761
3761
  otp: I.otp,
3762
3762
  newPassword: I.newPassword
@@ -3764,7 +3764,7 @@ const Ns = [
3764
3764
  S.success ? (A({
3765
3765
  type: "success",
3766
3766
  text: S.message || "Password reset successfully!"
3767
- }), u(1), X({ email: "", otp: "", newPassword: "" }), k("login")) : A({ type: "error", text: S.message || "Reset failed" });
3767
+ }), p(1), X({ email: "", otp: "", newPassword: "" }), k("login")) : A({ type: "error", text: S.message || "Reset failed" });
3768
3768
  } catch (S) {
3769
3769
  A({
3770
3770
  type: "error",
@@ -3890,7 +3890,7 @@ const Ns = [
3890
3890
  ),
3891
3891
  /* @__PURE__ */ r.jsxs("div", { style: { position: "relative" }, children: [
3892
3892
  /* @__PURE__ */ r.jsx(
3893
- pe,
3893
+ fe,
3894
3894
  {
3895
3895
  size: 20,
3896
3896
  style: {
@@ -4066,7 +4066,7 @@ const Ns = [
4066
4066
  ),
4067
4067
  /* @__PURE__ */ r.jsxs("div", { style: { position: "relative" }, children: [
4068
4068
  /* @__PURE__ */ r.jsx(
4069
- pe,
4069
+ fe,
4070
4070
  {
4071
4071
  size: 20,
4072
4072
  style: {
@@ -4219,7 +4219,7 @@ const Ns = [
4219
4219
  {
4220
4220
  type: "button",
4221
4221
  onClick: () => {
4222
- k("login"), u(1);
4222
+ k("login"), p(1);
4223
4223
  },
4224
4224
  style: {
4225
4225
  background: "none",
@@ -4282,17 +4282,17 @@ const Ns = [
4282
4282
  children: t,
4283
4283
  fallback: e = null
4284
4284
  }) => {
4285
- const n = fe(), [s, i] = P("loading");
4285
+ const n = pe(), [s, i] = P("loading");
4286
4286
  ee(() => {
4287
4287
  (async () => {
4288
- if (!(document.cookie.split(";").map((p) => p.trim()).find((p) => p.startsWith("a_s_b="))?.split("=")[1] === "true")) {
4288
+ if (!(document.cookie.split(";").map((d) => d.trim()).find((d) => d.startsWith("a_s_b="))?.split("=")[1] === "true")) {
4289
4289
  i("unauthenticated");
4290
4290
  return;
4291
4291
  }
4292
4292
  try {
4293
4293
  (await n.checkUserSession())?.user?.id ? i("authenticated") : (document.cookie = "a_s_b=false; path=/; max-age=0; SameSite=Lax", i("unauthenticated"));
4294
- } catch (p) {
4295
- console.error("Session validation failed:", p), document.cookie = "a_s_b=false; path=/; max-age=0; SameSite=Lax", i("unauthenticated");
4294
+ } catch (d) {
4295
+ console.error("Session validation failed:", d), document.cookie = "a_s_b=false; path=/; max-age=0; SameSite=Lax", i("unauthenticated");
4296
4296
  }
4297
4297
  })();
4298
4298
  }, [n]);
@@ -4302,14 +4302,22 @@ const Ns = [
4302
4302
  children: t,
4303
4303
  fallback: e = null
4304
4304
  }) => {
4305
- const [n, s] = P(!1), [i, a] = P(null);
4306
- if (ee(() => {
4307
- s(!0);
4308
- const d = document.cookie.split(";").map((f) => f.trim()).find((f) => f.startsWith("a_s_b="));
4309
- a(d?.split("=")[1] !== "true");
4310
- }, []), !n) return null;
4311
- const o = (c) => typeof c == "function" ? c() : c;
4312
- return i === null ? o(e) ?? null : i ? /* @__PURE__ */ r.jsx(r.Fragment, { children: t }) : o(e);
4305
+ const n = pe(), [s, i] = P("loading");
4306
+ ee(() => {
4307
+ (async () => {
4308
+ if (!(document.cookie.split(";").map((d) => d.trim()).find((d) => d.startsWith("a_s_b="))?.split("=")[1] === "true")) {
4309
+ i("unauthenticated");
4310
+ return;
4311
+ }
4312
+ try {
4313
+ (await n.checkUserSession())?.user?.id ? i("authenticated") : (document.cookie = "a_s_b=false; path=/; max-age=0; SameSite=Lax", i("unauthenticated"));
4314
+ } catch (d) {
4315
+ console.error("Session validation failed:", d), document.cookie = "a_s_b=false; path=/; max-age=0; SameSite=Lax", i("unauthenticated");
4316
+ }
4317
+ })();
4318
+ }, [n]);
4319
+ const a = (o) => typeof o == "function" ? o() : o;
4320
+ return s === "loading" ? null : s === "authenticated" ? a(e) ?? null : /* @__PURE__ */ r.jsx(r.Fragment, { children: t });
4313
4321
  }, Ls = ({
4314
4322
  isOpen: t,
4315
4323
  onClose: e,
@@ -4318,16 +4326,16 @@ const Ns = [
4318
4326
  userId: i,
4319
4327
  colors: a
4320
4328
  }) => {
4321
- const o = fe(), [c, d] = P(!1), [f, p] = P(""), [y, k] = P("warning"), [E, u] = P(!1);
4329
+ const o = pe(), [c, u] = P(!1), [x, d] = P(""), [y, k] = P("warning"), [E, p] = P(!1);
4322
4330
  if (ee(() => {
4323
4331
  if (typeof window > "u") return;
4324
4332
  const g = () => {
4325
- u(window.innerWidth < 640);
4333
+ p(window.innerWidth < 640);
4326
4334
  };
4327
4335
  return g(), window.addEventListener("resize", g), () => window.removeEventListener("resize", g);
4328
4336
  }, []), !t) return null;
4329
4337
  const w = async () => {
4330
- d(!0), k("processing");
4338
+ u(!0), k("processing");
4331
4339
  try {
4332
4340
  const g = await o.deleteUser({
4333
4341
  userId: i
@@ -4338,9 +4346,9 @@ const Ns = [
4338
4346
  } catch (g) {
4339
4347
  s(g.response?.data?.message || "Something went wrong"), k("warning");
4340
4348
  } finally {
4341
- d(!1);
4349
+ u(!1);
4342
4350
  }
4343
- }, h = f.toLowerCase() === "delete my account", O = (g) => {
4351
+ }, h = x.toLowerCase() === "delete my account", O = (g) => {
4344
4352
  g.target === g.currentTarget && y !== "processing" && y !== "success" && e();
4345
4353
  }, C = () => {
4346
4354
  switch (y) {
@@ -4657,8 +4665,8 @@ const Ns = [
4657
4665
  "input",
4658
4666
  {
4659
4667
  type: "text",
4660
- value: f,
4661
- onChange: (g) => p(g.target.value),
4668
+ value: x,
4669
+ onChange: (g) => d(g.target.value),
4662
4670
  placeholder: "delete my account",
4663
4671
  style: {
4664
4672
  width: "100%",
@@ -4715,7 +4723,7 @@ const Ns = [
4715
4723
  "button",
4716
4724
  {
4717
4725
  onClick: () => {
4718
- k("warning"), p("");
4726
+ k("warning"), d("");
4719
4727
  },
4720
4728
  style: {
4721
4729
  padding: "10px 24px",
@@ -5167,20 +5175,20 @@ const Ns = [
5167
5175
  onUpdate: n,
5168
5176
  colors: s
5169
5177
  }) => {
5170
- const [i, a] = P(""), [o, c] = P(!1), [d, f] = P(!1), [p, y] = P({ isValid: !1, message: "", type: null });
5178
+ const [i, a] = P(""), [o, c] = P(!1), [u, x] = P(!1), [d, y] = P({ isValid: !1, message: "", type: null });
5171
5179
  if (ee(() => {
5172
5180
  if (typeof window > "u") return;
5173
- const u = () => {
5174
- f(window.innerWidth < 640);
5181
+ const p = () => {
5182
+ x(window.innerWidth < 640);
5175
5183
  };
5176
- return u(), window.addEventListener("resize", u), () => window.removeEventListener("resize", u);
5184
+ return p(), window.addEventListener("resize", p), () => window.removeEventListener("resize", p);
5177
5185
  }, []), ee(() => {
5178
5186
  if (!i.trim()) {
5179
5187
  y({ isValid: !1, message: "", type: null });
5180
5188
  return;
5181
5189
  }
5182
5190
  try {
5183
- const u = new URL(i), w = /\.(jpg|jpeg|png|gif|webp|svg)$/i.test(u.pathname);
5191
+ const p = new URL(i), w = /\.(jpg|jpeg|png|gif|webp|svg)$/i.test(p.pathname);
5184
5192
  y(w ? {
5185
5193
  isValid: !0,
5186
5194
  message: "Valid image URL",
@@ -5199,7 +5207,7 @@ const Ns = [
5199
5207
  }
5200
5208
  }, [i]), !t) return null;
5201
5209
  const k = async () => {
5202
- if (!(!i || !p.isValid)) {
5210
+ if (!(!i || !d.isValid)) {
5203
5211
  c(!0);
5204
5212
  try {
5205
5213
  await n(i) && (a(""), e());
@@ -5207,8 +5215,8 @@ const Ns = [
5207
5215
  c(!1);
5208
5216
  }
5209
5217
  }
5210
- }, E = (u) => {
5211
- u.target === u.currentTarget && e();
5218
+ }, E = (p) => {
5219
+ p.target === p.currentTarget && e();
5212
5220
  };
5213
5221
  return /* @__PURE__ */ r.jsxs(
5214
5222
  "div",
@@ -5315,11 +5323,11 @@ const Ns = [
5315
5323
  flexShrink: 0,
5316
5324
  transition: "all 0.2s ease"
5317
5325
  },
5318
- onMouseOver: (u) => {
5319
- u.currentTarget.style.backgroundColor = s.border, u.currentTarget.style.color = s.textPrimary;
5326
+ onMouseOver: (p) => {
5327
+ p.currentTarget.style.backgroundColor = s.border, p.currentTarget.style.color = s.textPrimary;
5320
5328
  },
5321
- onMouseOut: (u) => {
5322
- u.currentTarget.style.backgroundColor = "transparent", u.currentTarget.style.color = s.textTertiary;
5329
+ onMouseOut: (p) => {
5330
+ p.currentTarget.style.backgroundColor = "transparent", p.currentTarget.style.color = s.textTertiary;
5323
5331
  },
5324
5332
  children: /* @__PURE__ */ r.jsx(Ie, { size: 20 })
5325
5333
  }
@@ -5364,13 +5372,13 @@ const Ns = [
5364
5372
  id: "avatar-url",
5365
5373
  placeholder: "https://example.com/your-avatar.jpg",
5366
5374
  value: i,
5367
- onChange: (u) => a(u.target.value),
5375
+ onChange: (p) => a(p.target.value),
5368
5376
  style: {
5369
5377
  width: "100%",
5370
5378
  padding: "14px 16px",
5371
5379
  paddingLeft: "44px",
5372
5380
  borderRadius: "12px",
5373
- border: `1.5px solid ${p.type === "error" ? s.error : p.type === "success" ? s.success : s.border}`,
5381
+ border: `1.5px solid ${d.type === "error" ? s.error : d.type === "success" ? s.success : s.border}`,
5374
5382
  backgroundColor: "transparent",
5375
5383
  color: s.textPrimary,
5376
5384
  fontSize: "15px",
@@ -5378,11 +5386,11 @@ const Ns = [
5378
5386
  transition: "all 0.2s ease",
5379
5387
  boxSizing: "border-box"
5380
5388
  },
5381
- onFocus: (u) => {
5382
- u.target.style.borderColor = s.accent, u.target.style.boxShadow = `0 0 0 3px ${s.accent}20`;
5389
+ onFocus: (p) => {
5390
+ p.target.style.borderColor = s.accent, p.target.style.boxShadow = `0 0 0 3px ${s.accent}20`;
5383
5391
  },
5384
- onBlur: (u) => {
5385
- u.target.style.borderColor = p.type === "error" ? s.error : p.type === "success" ? s.success : s.border, u.target.style.boxShadow = "none";
5392
+ onBlur: (p) => {
5393
+ p.target.style.borderColor = d.type === "error" ? s.error : d.type === "success" ? s.success : s.border, p.target.style.boxShadow = "none";
5386
5394
  },
5387
5395
  disabled: o
5388
5396
  }
@@ -5401,7 +5409,7 @@ const Ns = [
5401
5409
  }
5402
5410
  )
5403
5411
  ] }),
5404
- p.message && /* @__PURE__ */ r.jsxs(
5412
+ d.message && /* @__PURE__ */ r.jsxs(
5405
5413
  "div",
5406
5414
  {
5407
5415
  style: {
@@ -5410,18 +5418,18 @@ const Ns = [
5410
5418
  gap: "6px",
5411
5419
  marginTop: "8px",
5412
5420
  fontSize: "13px",
5413
- color: p.type === "success" ? s.success : p.type === "error" ? s.error : s.textTertiary
5421
+ color: d.type === "success" ? s.success : d.type === "error" ? s.error : s.textTertiary
5414
5422
  },
5415
5423
  children: [
5416
- p.type === "success" && /* @__PURE__ */ r.jsx(ue, { size: 14 }),
5417
- p.type === "error" && /* @__PURE__ */ r.jsx(se, { size: 14 }),
5418
- p.type === "warning" && /* @__PURE__ */ r.jsx(se, { size: 14 }),
5419
- p.message
5424
+ d.type === "success" && /* @__PURE__ */ r.jsx(ue, { size: 14 }),
5425
+ d.type === "error" && /* @__PURE__ */ r.jsx(se, { size: 14 }),
5426
+ d.type === "warning" && /* @__PURE__ */ r.jsx(se, { size: 14 }),
5427
+ d.message
5420
5428
  ]
5421
5429
  }
5422
5430
  )
5423
5431
  ] }),
5424
- i && p.type === "success" && /* @__PURE__ */ r.jsxs(
5432
+ i && d.type === "success" && /* @__PURE__ */ r.jsxs(
5425
5433
  "div",
5426
5434
  {
5427
5435
  style: {
@@ -5457,8 +5465,8 @@ const Ns = [
5457
5465
  border: `2px solid ${s.success}40`,
5458
5466
  margin: "0 auto"
5459
5467
  },
5460
- onError: (u) => {
5461
- u.currentTarget.style.display = "none";
5468
+ onError: (p) => {
5469
+ p.currentTarget.style.display = "none";
5462
5470
  }
5463
5471
  }
5464
5472
  )
@@ -5474,7 +5482,7 @@ const Ns = [
5474
5482
  style: {
5475
5483
  display: "flex",
5476
5484
  gap: "12px",
5477
- flexDirection: d ? "column-reverse" : "row",
5485
+ flexDirection: u ? "column-reverse" : "row",
5478
5486
  justifyContent: "flex-end",
5479
5487
  alignItems: "stretch",
5480
5488
  marginTop: "24px"
@@ -5494,16 +5502,16 @@ const Ns = [
5494
5502
  fontSize: "14px",
5495
5503
  fontWeight: 500,
5496
5504
  cursor: o ? "not-allowed" : "pointer",
5497
- flex: d ? "none" : 1,
5498
- minWidth: d ? "100%" : "120px",
5505
+ flex: u ? "none" : 1,
5506
+ minWidth: u ? "100%" : "120px",
5499
5507
  opacity: o ? 0.6 : 1,
5500
5508
  transition: "all 0.2s ease"
5501
5509
  },
5502
- onMouseOver: (u) => {
5503
- o || (u.currentTarget.style.backgroundColor = s.border, u.currentTarget.style.transform = "translateY(-1px)");
5510
+ onMouseOver: (p) => {
5511
+ o || (p.currentTarget.style.backgroundColor = s.border, p.currentTarget.style.transform = "translateY(-1px)");
5504
5512
  },
5505
- onMouseOut: (u) => {
5506
- o || (u.currentTarget.style.backgroundColor = "transparent", u.currentTarget.style.transform = "translateY(0)");
5513
+ onMouseOut: (p) => {
5514
+ o || (p.currentTarget.style.backgroundColor = "transparent", p.currentTarget.style.transform = "translateY(0)");
5507
5515
  },
5508
5516
  children: "Cancel"
5509
5517
  }
@@ -5512,7 +5520,7 @@ const Ns = [
5512
5520
  "button",
5513
5521
  {
5514
5522
  onClick: k,
5515
- disabled: o || !p.isValid,
5523
+ disabled: o || !d.isValid,
5516
5524
  style: {
5517
5525
  padding: "10px 24px",
5518
5526
  borderRadius: "10px",
@@ -5521,22 +5529,22 @@ const Ns = [
5521
5529
  color: "#fff",
5522
5530
  fontSize: "14px",
5523
5531
  fontWeight: 600,
5524
- cursor: o || !p.isValid ? "not-allowed" : "pointer",
5525
- flex: d ? "none" : 1,
5526
- minWidth: d ? "100%" : "140px",
5527
- opacity: o || !p.isValid ? 0.6 : 1,
5532
+ cursor: o || !d.isValid ? "not-allowed" : "pointer",
5533
+ flex: u ? "none" : 1,
5534
+ minWidth: u ? "100%" : "140px",
5535
+ opacity: o || !d.isValid ? 0.6 : 1,
5528
5536
  display: "flex",
5529
5537
  alignItems: "center",
5530
5538
  justifyContent: "center",
5531
5539
  gap: "8px",
5532
5540
  transition: "all 0.2s ease",
5533
- boxShadow: o || !p.isValid ? "none" : `0 4px 12px ${s.accent}40`
5541
+ boxShadow: o || !d.isValid ? "none" : `0 4px 12px ${s.accent}40`
5534
5542
  },
5535
- onMouseOver: (u) => {
5536
- !o && p.isValid && (u.currentTarget.style.transform = "translateY(-1px)", u.currentTarget.style.boxShadow = `0 6px 20px ${s.accent}60`);
5543
+ onMouseOver: (p) => {
5544
+ !o && d.isValid && (p.currentTarget.style.transform = "translateY(-1px)", p.currentTarget.style.boxShadow = `0 6px 20px ${s.accent}60`);
5537
5545
  },
5538
- onMouseOut: (u) => {
5539
- !o && p.isValid && (u.currentTarget.style.transform = "translateY(0)", u.currentTarget.style.boxShadow = `0 4px 12px ${s.accent}40`);
5546
+ onMouseOut: (p) => {
5547
+ !o && d.isValid && (p.currentTarget.style.transform = "translateY(0)", p.currentTarget.style.boxShadow = `0 4px 12px ${s.accent}40`);
5540
5548
  },
5541
5549
  children: o ? /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
5542
5550
  /* @__PURE__ */ r.jsx(
@@ -5621,11 +5629,11 @@ const Ns = [
5621
5629
  userId: i,
5622
5630
  colors: a
5623
5631
  }) => {
5624
- const o = fe(), [c, d] = P({
5632
+ const o = pe(), [c, u] = P({
5625
5633
  currentPassword: "",
5626
5634
  newPassword: "",
5627
5635
  confirmPassword: ""
5628
- }), [f, p] = P({}), [y, k] = P(!1), [E, u] = P({
5636
+ }), [x, d] = P({}), [y, k] = P(!1), [E, p] = P({
5629
5637
  currentPassword: !1,
5630
5638
  newPassword: !1,
5631
5639
  confirmPassword: !1
@@ -5639,12 +5647,12 @@ const Ns = [
5639
5647
  }, []), !t) return null;
5640
5648
  const O = (b) => {
5641
5649
  const { name: j, value: q } = b.target;
5642
- d((I) => ({ ...I, [j]: q })), f[j] && p((I) => ({ ...I, [j]: "" }));
5650
+ u((I) => ({ ...I, [j]: q })), x[j] && d((I) => ({ ...I, [j]: "" }));
5643
5651
  }, C = (b) => {
5644
- u((j) => ({ ...j, [b]: !j[b] }));
5652
+ p((j) => ({ ...j, [b]: !j[b] }));
5645
5653
  }, g = () => {
5646
5654
  const b = {};
5647
- return c.currentPassword || (b.currentPassword = "Current password is required"), c.newPassword ? c.newPassword.length < 6 && (b.newPassword = "Password must be at least 6 characters") : b.newPassword = "New password is required", c.newPassword !== c.confirmPassword && (b.confirmPassword = "Passwords do not match"), p(b), Object.keys(b).length === 0;
5655
+ return c.currentPassword || (b.currentPassword = "Current password is required"), c.newPassword ? c.newPassword.length < 6 && (b.newPassword = "Password must be at least 6 characters") : b.newPassword = "New password is required", c.newPassword !== c.confirmPassword && (b.confirmPassword = "Passwords do not match"), d(b), Object.keys(b).length === 0;
5648
5656
  }, A = async (b) => {
5649
5657
  if (b.preventDefault(), !!g()) {
5650
5658
  k(!0);
@@ -5654,7 +5662,7 @@ const Ns = [
5654
5662
  newPassword: c.newPassword,
5655
5663
  userId: i
5656
5664
  });
5657
- j.success ? (n(j.message || "Password updated successfully"), d({
5665
+ j.success ? (n(j.message || "Password updated successfully"), u({
5658
5666
  currentPassword: "",
5659
5667
  newPassword: "",
5660
5668
  confirmPassword: ""
@@ -5849,7 +5857,7 @@ const Ns = [
5849
5857
  width: "100%",
5850
5858
  padding: "14px 48px 14px 44px",
5851
5859
  borderRadius: "10px",
5852
- border: `1.5px solid ${f[b] ? a.error : a.border}`,
5860
+ border: `1.5px solid ${x[b] ? a.error : a.border}`,
5853
5861
  backgroundColor: "transparent",
5854
5862
  color: a.textPrimary,
5855
5863
  fontSize: "15px",
@@ -5861,7 +5869,7 @@ const Ns = [
5861
5869
  I.target.style.borderColor = a.accent, I.target.style.boxShadow = `0 0 0 3px ${a.accent}20`;
5862
5870
  },
5863
5871
  onBlur: (I) => {
5864
- I.target.style.borderColor = f[b] ? a.error : a.border, I.target.style.boxShadow = "none";
5872
+ I.target.style.borderColor = x[b] ? a.error : a.border, I.target.style.boxShadow = "none";
5865
5873
  }
5866
5874
  }
5867
5875
  ),
@@ -5897,7 +5905,7 @@ const Ns = [
5897
5905
  }
5898
5906
  )
5899
5907
  ] }),
5900
- f[b] && /* @__PURE__ */ r.jsxs(
5908
+ x[b] && /* @__PURE__ */ r.jsxs(
5901
5909
  "div",
5902
5910
  {
5903
5911
  style: {
@@ -5910,7 +5918,7 @@ const Ns = [
5910
5918
  },
5911
5919
  children: [
5912
5920
  /* @__PURE__ */ r.jsx("span", { style: { fontSize: "16px" }, children: "⚠" }),
5913
- f[b]
5921
+ x[b]
5914
5922
  ]
5915
5923
  }
5916
5924
  )
@@ -6059,20 +6067,20 @@ const Ns = [
6059
6067
  setVerifyFormData: a,
6060
6068
  otpSent: o,
6061
6069
  verifying: c,
6062
- user: d,
6063
- colors: f,
6064
- darkMode: p
6070
+ user: u,
6071
+ colors: x,
6072
+ darkMode: d
6065
6073
  }) => {
6066
6074
  if (!t) return null;
6067
6075
  const y = () => {
6068
- e(), a({ email: d?.email || "", otp: "" });
6076
+ e(), a({ email: u?.email || "", otp: "" });
6069
6077
  };
6070
6078
  return /* @__PURE__ */ r.jsxs(
6071
6079
  "div",
6072
6080
  {
6073
6081
  className: "modal-overlay",
6074
6082
  style: {
6075
- backgroundColor: p ? "rgba(0, 0, 0, 0.8)" : "rgba(0, 0, 0, 0.5)"
6083
+ backgroundColor: d ? "rgba(0, 0, 0, 0.8)" : "rgba(0, 0, 0, 0.5)"
6076
6084
  },
6077
6085
  children: [
6078
6086
  /* @__PURE__ */ r.jsxs(
@@ -6080,18 +6088,18 @@ const Ns = [
6080
6088
  {
6081
6089
  className: "verify-email-modal",
6082
6090
  style: {
6083
- backgroundColor: f.surface,
6084
- border: `1px solid ${f.border}`
6091
+ backgroundColor: x.surface,
6092
+ border: `1px solid ${x.border}`
6085
6093
  },
6086
6094
  children: [
6087
6095
  /* @__PURE__ */ r.jsxs("div", { className: "modal-header", children: [
6088
- /* @__PURE__ */ r.jsx("h3", { style: { color: f.textPrimary }, children: "Verify Your Email" }),
6096
+ /* @__PURE__ */ r.jsx("h3", { style: { color: x.textPrimary }, children: "Verify Your Email" }),
6089
6097
  /* @__PURE__ */ r.jsx(
6090
6098
  "button",
6091
6099
  {
6092
6100
  onClick: y,
6093
6101
  className: "close-btn",
6094
- style: { color: f.textTertiary },
6102
+ style: { color: x.textTertiary },
6095
6103
  "aria-label": "Close verification modal",
6096
6104
  children: /* @__PURE__ */ r.jsx(Ie, { size: 20, "aria-hidden": "true" })
6097
6105
  }
@@ -6099,13 +6107,13 @@ const Ns = [
6099
6107
  ] }),
6100
6108
  /* @__PURE__ */ r.jsxs("form", { className: "verify-form", onSubmit: n, children: [
6101
6109
  /* @__PURE__ */ r.jsxs("div", { className: "form-group", children: [
6102
- /* @__PURE__ */ r.jsx("label", { style: { color: f.textSecondary }, children: "Email" }),
6110
+ /* @__PURE__ */ r.jsx("label", { style: { color: x.textSecondary }, children: "Email" }),
6103
6111
  /* @__PURE__ */ r.jsxs("div", { className: "input-container", children: [
6104
6112
  /* @__PURE__ */ r.jsx(
6105
- pe,
6113
+ fe,
6106
6114
  {
6107
6115
  size: 18,
6108
- style: { color: f.textTertiary },
6116
+ style: { color: x.textTertiary },
6109
6117
  "aria-hidden": "true"
6110
6118
  }
6111
6119
  ),
@@ -6120,9 +6128,9 @@ const Ns = [
6120
6128
  })),
6121
6129
  placeholder: "Enter your email",
6122
6130
  style: {
6123
- backgroundColor: f.surfaceLight,
6124
- color: f.textPrimary,
6125
- borderColor: f.border
6131
+ backgroundColor: x.surfaceLight,
6132
+ color: x.textPrimary,
6133
+ borderColor: x.border
6126
6134
  },
6127
6135
  required: !0,
6128
6136
  "aria-required": "true",
@@ -6132,13 +6140,13 @@ const Ns = [
6132
6140
  ] })
6133
6141
  ] }),
6134
6142
  o && /* @__PURE__ */ r.jsxs("div", { className: "form-group", children: [
6135
- /* @__PURE__ */ r.jsx("label", { style: { color: f.textSecondary }, children: "OTP" }),
6143
+ /* @__PURE__ */ r.jsx("label", { style: { color: x.textSecondary }, children: "OTP" }),
6136
6144
  /* @__PURE__ */ r.jsxs("div", { className: "input-container", children: [
6137
6145
  /* @__PURE__ */ r.jsx(
6138
6146
  ir,
6139
6147
  {
6140
6148
  size: 18,
6141
- style: { color: f.textTertiary },
6149
+ style: { color: x.textTertiary },
6142
6150
  "aria-hidden": "true"
6143
6151
  }
6144
6152
  ),
@@ -6153,9 +6161,9 @@ const Ns = [
6153
6161
  })),
6154
6162
  placeholder: "Enter OTP",
6155
6163
  style: {
6156
- backgroundColor: f.surfaceLight,
6157
- color: f.textPrimary,
6158
- borderColor: f.border
6164
+ backgroundColor: x.surfaceLight,
6165
+ color: x.textPrimary,
6166
+ borderColor: x.border
6159
6167
  },
6160
6168
  required: !0,
6161
6169
  "aria-required": "true",
@@ -6171,7 +6179,7 @@ const Ns = [
6171
6179
  disabled: c,
6172
6180
  className: "btn-primary",
6173
6181
  style: {
6174
- background: `linear-gradient(to right, ${f.accent}, ${f.accentHover})`,
6182
+ background: `linear-gradient(to right, ${x.accent}, ${x.accentHover})`,
6175
6183
  opacity: c ? 0.7 : 1
6176
6184
  },
6177
6185
  "aria-label": c ? "Verifying email" : "Verify email",
@@ -6188,7 +6196,7 @@ const Ns = [
6188
6196
  disabled: c,
6189
6197
  className: "btn-primary",
6190
6198
  style: {
6191
- background: `linear-gradient(to right, ${f.accent}, ${f.accentHover})`,
6199
+ background: `linear-gradient(to right, ${x.accent}, ${x.accentHover})`,
6192
6200
  opacity: c ? 0.7 : 1
6193
6201
  },
6194
6202
  "aria-label": c ? "Sending OTP" : "Send OTP",
@@ -6251,7 +6259,7 @@ const Ns = [
6251
6259
  }
6252
6260
 
6253
6261
  .close-btn:hover {
6254
- background-color: ${p ? "rgba(255,255,255,0.1)" : "rgba(0,0,0,0.1)"};
6262
+ background-color: ${d ? "rgba(255,255,255,0.1)" : "rgba(0,0,0,0.1)"};
6255
6263
  }
6256
6264
 
6257
6265
  .verify-form {
@@ -6295,8 +6303,8 @@ const Ns = [
6295
6303
  }
6296
6304
 
6297
6305
  .input-container input:focus {
6298
- border-color: ${f.accent};
6299
- box-shadow: 0 0 0 3px ${f.accent}20;
6306
+ border-color: ${x.accent};
6307
+ box-shadow: 0 0 0 3px ${x.accent}20;
6300
6308
  }
6301
6309
 
6302
6310
  .modal-actions {
@@ -6360,7 +6368,7 @@ const Ns = [
6360
6368
  onVerify: s,
6361
6369
  primaryColor: i = "#00C212"
6362
6370
  }) => {
6363
- const a = fe(), [o, c] = P(null), [d, f] = P(), [p, y] = P(!0), [k, E] = P(!1), [u, w] = P(!1), [h, O] = P(!1), [C, g] = P(!1), [A, N] = P(!1), [b, j] = P(!1), [q, I] = P(!1), [X, W] = P(!1), [T, G] = P(null), [R, z] = P(!1), [M, K] = P({
6371
+ const a = pe(), [o, c] = P(null), [u, x] = P(), [d, y] = P(!0), [k, E] = P(!1), [p, w] = P(!1), [h, O] = P(!1), [C, g] = P(!1), [A, N] = P(!1), [b, j] = P(!1), [q, I] = P(!1), [X, W] = P(!1), [T, G] = P(null), [R, z] = P(!1), [M, K] = P({
6364
6372
  email: "",
6365
6373
  otp: ""
6366
6374
  }), [H, L] = P(!1), [Y, l] = P(!1);
@@ -6393,14 +6401,14 @@ const Ns = [
6393
6401
  m("error", "Please enter a valid email");
6394
6402
  return;
6395
6403
  }
6396
- if (!d?.id) {
6404
+ if (!u?.id) {
6397
6405
  m("error", "User not found. Cannot send OTP.");
6398
6406
  return;
6399
6407
  }
6400
6408
  try {
6401
6409
  l(!0);
6402
6410
  const v = await a.requestEmailVerificationOTP({
6403
- userId: d.id,
6411
+ userId: u.id,
6404
6412
  email: M.email
6405
6413
  }), U = v?.data?.success ?? v?.success, V = v?.data?.message ?? v?.message;
6406
6414
  U ? (m("success", V || "OTP sent to email!"), L(!0)) : m("error", V || "Failed to send OTP");
@@ -6415,7 +6423,7 @@ const Ns = [
6415
6423
  m("error", "Please fill in all fields");
6416
6424
  return;
6417
6425
  }
6418
- if (!d) {
6426
+ if (!u) {
6419
6427
  m("error", "User not found");
6420
6428
  return;
6421
6429
  }
@@ -6427,8 +6435,8 @@ const Ns = [
6427
6435
  }), V = U?.data?.success ?? U?.success, Z = U?.data?.message ?? U?.message;
6428
6436
  if (V) {
6429
6437
  m("success", Z || "Email verified!");
6430
- const de = { ...d, isVerified: !0 };
6431
- f(de), typeof s == "function" && s(de), K({ email: de.email, otp: "" }), L(!1), j?.(!1);
6438
+ const de = { ...u, isVerified: !0 };
6439
+ x(de), typeof s == "function" && s(de), K({ email: de.email, otp: "" }), L(!1), j?.(!1);
6432
6440
  } else
6433
6441
  m("error", Z || "Verification failed");
6434
6442
  } catch (U) {
@@ -6438,43 +6446,43 @@ const Ns = [
6438
6446
  l(!1);
6439
6447
  }
6440
6448
  }, oe = async (v) => {
6441
- if (!d) return !1;
6449
+ if (!u) return !1;
6442
6450
  try {
6443
6451
  const U = await a.updateUser({
6444
- userId: d.id,
6452
+ userId: u.id,
6445
6453
  avatarUrl: v
6446
6454
  });
6447
6455
  if (U?.success) {
6448
6456
  const V = {
6449
- ...d,
6457
+ ...u,
6450
6458
  // 🔒 keep existing auth fields
6451
6459
  ...U.user,
6452
6460
  // 🔁 merge backend response if present
6453
6461
  avatarUrl: v
6454
6462
  };
6455
- return f(V), m("success", "Avatar updated successfully!"), !0;
6463
+ return x(V), m("success", "Avatar updated successfully!"), !0;
6456
6464
  }
6457
6465
  return m("error", U?.message || "Failed to update avatar"), !1;
6458
6466
  } catch (U) {
6459
6467
  return console.error("Avatar update error:", U), m("error", "Failed to update avatar"), !1;
6460
6468
  }
6461
6469
  }, B = async () => {
6462
- if (d) {
6470
+ if (u) {
6463
6471
  w(!0);
6464
6472
  try {
6465
- const v = d.email, U = await a.updateUser({
6466
- userId: d.id,
6467
- ...d
6473
+ const v = u.email, U = await a.updateUser({
6474
+ userId: u.id,
6475
+ ...u
6468
6476
  });
6469
6477
  if (U.success && U.user) {
6470
6478
  const V = U.user.email !== v, Z = {
6471
- ...d,
6479
+ ...u,
6472
6480
  // keep old state
6473
6481
  ...U.user,
6474
6482
  // overwrite updated fields
6475
- isVerified: V ? !1 : d.isVerified
6483
+ isVerified: V ? !1 : u.isVerified
6476
6484
  };
6477
- f(Z), localStorage.setItem("userInfo", JSON.stringify(Z)), m(
6485
+ x(Z), localStorage.setItem("userInfo", JSON.stringify(Z)), m(
6478
6486
  "success",
6479
6487
  V ? "Email updated. Please verify your new email." : "Profile updated successfully"
6480
6488
  ), E(!1);
@@ -6489,7 +6497,7 @@ const Ns = [
6489
6497
  }, le = async (v) => {
6490
6498
  try {
6491
6499
  const U = await a.checkIfUserExists(v);
6492
- U?.success === !0 && U?.exists === !1 && (console.warn("❌ User does not exist on server. Clearing session..."), localStorage.removeItem("userInfo"), f(null));
6500
+ U?.success === !0 && U?.exists === !1 && (console.warn("❌ User does not exist on server. Clearing session..."), localStorage.removeItem("userInfo"), x(null));
6493
6501
  } catch (U) {
6494
6502
  console.error("⚠️ User validation request failed:", U);
6495
6503
  }
@@ -6503,20 +6511,20 @@ const Ns = [
6503
6511
  const V = U.user.id, Z = await a.getUserProfile({ userId: V });
6504
6512
  if (Z.user) {
6505
6513
  const de = Z.user;
6506
- f(de), le(V);
6514
+ x(de), le(V);
6507
6515
  } else
6508
- f(null), localStorage.removeItem("userInfo");
6516
+ x(null), localStorage.removeItem("userInfo");
6509
6517
  } else
6510
- f(null), localStorage.removeItem("userInfo");
6518
+ x(null), localStorage.removeItem("userInfo");
6511
6519
  } catch (U) {
6512
- console.error("User init failed:", U), f(null), localStorage.removeItem("userInfo");
6520
+ console.error("User init failed:", U), x(null), localStorage.removeItem("userInfo");
6513
6521
  } finally {
6514
6522
  y(!1);
6515
6523
  }
6516
6524
  })();
6517
6525
  }, []), ee(() => {
6518
- d?.email && K((v) => ({ ...v, email: d.email }));
6519
- }, [d?.email]);
6526
+ u?.email && K((v) => ({ ...v, email: u.email }));
6527
+ }, [u?.email]);
6520
6528
  const ge = (v, U) => {
6521
6529
  let V = parseInt(v.replace("#", ""), 16), Z = (V >> 16) + U, de = (V >> 8 & 255) + U, Be = (V & 255) + U;
6522
6530
  return Z = Math.min(255, Math.max(0, Z)), de = Math.min(255, Math.max(0, de)), Be = Math.min(255, Math.max(0, Be)), `#${(Be | de << 8 | Z << 16).toString(16).padStart(6, "0")}`;
@@ -6549,7 +6557,7 @@ const Ns = [
6549
6557
  border: "#e4e4e7",
6550
6558
  warning: "#d97706"
6551
6559
  };
6552
- if (p)
6560
+ if (d)
6553
6561
  return /* @__PURE__ */ r.jsx(
6554
6562
  "div",
6555
6563
  {
@@ -6588,7 +6596,7 @@ const Ns = [
6588
6596
  )
6589
6597
  }
6590
6598
  );
6591
- if (!d)
6599
+ if (!u)
6592
6600
  return /* @__PURE__ */ r.jsx(
6593
6601
  "div",
6594
6602
  {
@@ -6622,28 +6630,28 @@ const Ns = [
6622
6630
  const lr = [
6623
6631
  {
6624
6632
  label: "Full Name",
6625
- value: d.name,
6633
+ value: u.name,
6626
6634
  name: "name",
6627
6635
  type: "text",
6628
6636
  icon: we
6629
6637
  },
6630
6638
  {
6631
6639
  label: "Email Address",
6632
- value: d.email,
6640
+ value: u.email,
6633
6641
  name: "email",
6634
6642
  type: "email",
6635
- icon: pe
6643
+ icon: fe
6636
6644
  },
6637
6645
  {
6638
6646
  label: "Phone Number",
6639
- value: d.phone || "Not set",
6647
+ value: u.phone || "Not set",
6640
6648
  name: "phone",
6641
6649
  type: "tel",
6642
6650
  icon: Cs
6643
6651
  },
6644
6652
  {
6645
6653
  label: "Address",
6646
- value: d.address || "Not provided",
6654
+ value: u.address || "Not provided",
6647
6655
  name: "address",
6648
6656
  type: "text",
6649
6657
  icon: vs
@@ -6787,10 +6795,10 @@ const Ns = [
6787
6795
  /* @__PURE__ */ r.jsx(
6788
6796
  "img",
6789
6797
  {
6790
- src: d.avatarUrl || `https://api.dicebear.com/9.x/initials/svg?seed=${encodeURIComponent(
6791
- d.name
6798
+ src: u.avatarUrl || `https://api.dicebear.com/9.x/initials/svg?seed=${encodeURIComponent(
6799
+ u.name
6792
6800
  )}`,
6793
- alt: `Profile avatar of ${d.name}`,
6801
+ alt: `Profile avatar of ${u.name}`,
6794
6802
  style: {
6795
6803
  width: "128px",
6796
6804
  height: "128px",
@@ -6841,7 +6849,7 @@ const Ns = [
6841
6849
  margin: "0 0 4px 0",
6842
6850
  color: _.textPrimary
6843
6851
  },
6844
- children: d.name
6852
+ children: u.name
6845
6853
  }
6846
6854
  ),
6847
6855
  /* @__PURE__ */ r.jsx(
@@ -6851,16 +6859,16 @@ const Ns = [
6851
6859
  color: _.textTertiary,
6852
6860
  margin: "0 0 8px 0"
6853
6861
  },
6854
- children: d.email
6862
+ children: u.email
6855
6863
  }
6856
6864
  ),
6857
6865
  /* @__PURE__ */ r.jsxs(
6858
6866
  "div",
6859
6867
  {
6860
6868
  style: {
6861
- backgroundColor: d.isVerified ? t ? "rgba(16, 185, 129, 0.1)" : "rgba(16, 185, 129, 0.05)" : t ? "rgba(245, 158, 11, 0.1)" : "rgba(245, 158, 11, 0.05)",
6862
- color: d.isVerified ? _.success : _.warning,
6863
- border: `1px solid ${d.isVerified ? t ? "rgba(16, 185, 129, 0.3)" : "rgba(16, 185, 129, 0.2)" : t ? "rgba(245, 158, 11, 0.3)" : "rgba(245, 158, 11, 0.2)"}`,
6869
+ backgroundColor: u.isVerified ? t ? "rgba(16, 185, 129, 0.1)" : "rgba(16, 185, 129, 0.05)" : t ? "rgba(245, 158, 11, 0.1)" : "rgba(245, 158, 11, 0.05)",
6870
+ color: u.isVerified ? _.success : _.warning,
6871
+ border: `1px solid ${u.isVerified ? t ? "rgba(16, 185, 129, 0.3)" : "rgba(16, 185, 129, 0.2)" : t ? "rgba(245, 158, 11, 0.3)" : "rgba(245, 158, 11, 0.2)"}`,
6864
6872
  padding: "6px 12px",
6865
6873
  borderRadius: "20px",
6866
6874
  fontSize: "12px",
@@ -6871,8 +6879,8 @@ const Ns = [
6871
6879
  marginTop: "8px"
6872
6880
  },
6873
6881
  children: [
6874
- d.isVerified ? /* @__PURE__ */ r.jsx(ue, { size: 16, "aria-hidden": "true" }) : /* @__PURE__ */ r.jsx(se, { size: 16, "aria-hidden": "true" }),
6875
- d.isVerified ? "Email Verified" : "Not Verified"
6882
+ u.isVerified ? /* @__PURE__ */ r.jsx(ue, { size: 16, "aria-hidden": "true" }) : /* @__PURE__ */ r.jsx(se, { size: 16, "aria-hidden": "true" }),
6883
+ u.isVerified ? "Email Verified" : "Not Verified"
6876
6884
  ]
6877
6885
  }
6878
6886
  )
@@ -6921,15 +6929,15 @@ const Ns = [
6921
6929
  "button",
6922
6930
  {
6923
6931
  onClick: B,
6924
- disabled: u,
6932
+ disabled: p,
6925
6933
  style: {
6926
6934
  background: `linear-gradient(to right, ${_.accent}, ${_.accentHover})`,
6927
- opacity: u ? 0.7 : 1,
6935
+ opacity: p ? 0.7 : 1,
6928
6936
  color: "white",
6929
6937
  padding: "10px 20px",
6930
6938
  borderRadius: "6px",
6931
6939
  border: "none",
6932
- cursor: u ? "not-allowed" : "pointer",
6940
+ cursor: p ? "not-allowed" : "pointer",
6933
6941
  transition: "all 0.2s ease",
6934
6942
  fontSize: "12px",
6935
6943
  fontWeight: 500,
@@ -6942,7 +6950,7 @@ const Ns = [
6942
6950
  flex: o && window.innerWidth < 1024 ? "1" : "auto"
6943
6951
  },
6944
6952
  children: [
6945
- u ? /* @__PURE__ */ r.jsx(
6953
+ p ? /* @__PURE__ */ r.jsx(
6946
6954
  ie,
6947
6955
  {
6948
6956
  size: 16,
@@ -6950,7 +6958,7 @@ const Ns = [
6950
6958
  "aria-hidden": "true"
6951
6959
  }
6952
6960
  ) : /* @__PURE__ */ r.jsx(Rs, { size: 16, "aria-hidden": "true" }),
6953
- u ? "Saving..." : "Save Changes"
6961
+ p ? "Saving..." : "Save Changes"
6954
6962
  ]
6955
6963
  }
6956
6964
  )
@@ -6983,7 +6991,7 @@ const Ns = [
6983
6991
  ]
6984
6992
  }
6985
6993
  ),
6986
- !d.isVerified && /* @__PURE__ */ r.jsxs(
6994
+ !u.isVerified && /* @__PURE__ */ r.jsxs(
6987
6995
  "button",
6988
6996
  {
6989
6997
  onClick: () => j(!0),
@@ -7253,8 +7261,8 @@ const Ns = [
7253
7261
  {
7254
7262
  type: v.type,
7255
7263
  name: v.name,
7256
- value: d[v.name],
7257
- onChange: (V) => f(
7264
+ value: u[v.name],
7265
+ onChange: (V) => x(
7258
7266
  (Z) => Z && { ...Z, [V.target.name]: V.target.value }
7259
7267
  ),
7260
7268
  style: {
@@ -7358,7 +7366,7 @@ const Ns = [
7358
7366
  color: _.textSecondary
7359
7367
  },
7360
7368
  children: [
7361
- /* @__PURE__ */ r.jsx(pe, { size: 16, "aria-hidden": "true" }),
7369
+ /* @__PURE__ */ r.jsx(fe, { size: 16, "aria-hidden": "true" }),
7362
7370
  /* @__PURE__ */ r.jsx("span", { children: "Email Verification" })
7363
7371
  ]
7364
7372
  }
@@ -7374,7 +7382,7 @@ const Ns = [
7374
7382
  display: "flex",
7375
7383
  alignItems: "center",
7376
7384
  gap: "6px",
7377
- ...d.isVerified ? {
7385
+ ...u.isVerified ? {
7378
7386
  backgroundColor: t ? "rgba(16, 185, 129, 0.1)" : "rgba(16, 185, 129, 0.05)",
7379
7387
  color: _.success,
7380
7388
  border: `1px solid ${t ? "rgba(16, 185, 129, 0.3)" : "rgba(16, 185, 129, 0.2)"}`
@@ -7384,7 +7392,7 @@ const Ns = [
7384
7392
  border: `1px solid ${t ? "rgba(245, 158, 11, 0.3)" : "rgba(245, 158, 11, 0.2)"}`
7385
7393
  }
7386
7394
  },
7387
- children: d.isVerified ? /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
7395
+ children: u.isVerified ? /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
7388
7396
  /* @__PURE__ */ r.jsx(ue, { size: 16, "aria-hidden": "true" }),
7389
7397
  "Verified"
7390
7398
  ] }) : /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
@@ -7396,7 +7404,7 @@ const Ns = [
7396
7404
  ]
7397
7405
  }
7398
7406
  ),
7399
- !d.isVerified && /* @__PURE__ */ r.jsx(
7407
+ !u.isVerified && /* @__PURE__ */ r.jsx(
7400
7408
  "div",
7401
7409
  {
7402
7410
  style: {
@@ -7445,7 +7453,7 @@ const Ns = [
7445
7453
  /* @__PURE__ */ r.jsx(
7446
7454
  qs,
7447
7455
  {
7448
- userId: d.id,
7456
+ userId: u.id,
7449
7457
  isOpen: C,
7450
7458
  onClose: () => g(!1),
7451
7459
  onSuccess: (v) => m("success", v),
@@ -7456,7 +7464,7 @@ const Ns = [
7456
7464
  /* @__PURE__ */ r.jsx(
7457
7465
  Ls,
7458
7466
  {
7459
- userId: d.id,
7467
+ userId: u.id,
7460
7468
  isOpen: A,
7461
7469
  onClose: () => N(!1),
7462
7470
  onSuccess: (v) => m("success", v),
@@ -7469,7 +7477,7 @@ const Ns = [
7469
7477
  {
7470
7478
  isOpen: b,
7471
7479
  onClose: () => {
7472
- j(!1), L(!1), K({ email: d?.email || "", otp: "" });
7480
+ j(!1), L(!1), K({ email: u?.email || "", otp: "" });
7473
7481
  },
7474
7482
  onVerify: ne,
7475
7483
  onSendOTP: D,
@@ -7477,7 +7485,7 @@ const Ns = [
7477
7485
  setVerifyFormData: K,
7478
7486
  otpSent: H,
7479
7487
  verifying: Y,
7480
- user: d,
7488
+ user: u,
7481
7489
  colors: _,
7482
7490
  darkMode: t
7483
7491
  }
@@ -7585,16 +7593,16 @@ const Ns = [
7585
7593
  profileUrl: o,
7586
7594
  settingsUrl: c,
7587
7595
  // Menu item visibility with defaults
7588
- showProfileMenuItem: d = !0,
7589
- showSettingsMenuItem: f = !0,
7590
- showViewProfileMenuItem: p = !0,
7596
+ showProfileMenuItem: u = !0,
7597
+ showSettingsMenuItem: x = !0,
7598
+ showViewProfileMenuItem: d = !0,
7591
7599
  // Custom labels with defaults
7592
7600
  profileLabel: y = "My Profile",
7593
7601
  settingsLabel: k = "Settings",
7594
7602
  viewProfileLabel: E = "View Profile",
7595
- logoutLabel: u = "Sign Out"
7603
+ logoutLabel: p = "Sign Out"
7596
7604
  }) => {
7597
- const w = fe(), [h, O] = P(!1), [C, g] = P(null), [A, N] = P(!0), [b, j] = P(null), q = dt(null), I = dt(null), [X, W] = P(!1), [T, G] = P(!1);
7605
+ const w = pe(), [h, O] = P(!1), [C, g] = P(null), [A, N] = P(!0), [b, j] = P(null), q = dt(null), I = dt(null), [X, W] = P(!1), [T, G] = P(!1);
7598
7606
  ee(() => {
7599
7607
  if (typeof window > "u") return;
7600
7608
  const l = () => {
@@ -8053,7 +8061,7 @@ const Ns = [
8053
8061
  ] })
8054
8062
  ] }),
8055
8063
  /* @__PURE__ */ r.jsxs("div", { style: z.dropdownSection, children: [
8056
- d && H() && /* @__PURE__ */ r.jsxs(
8064
+ u && H() && /* @__PURE__ */ r.jsxs(
8057
8065
  "button",
8058
8066
  {
8059
8067
  style: z.menuItem,
@@ -8073,7 +8081,7 @@ const Ns = [
8073
8081
  ]
8074
8082
  }
8075
8083
  ),
8076
- f && c && /* @__PURE__ */ r.jsxs(
8084
+ x && c && /* @__PURE__ */ r.jsxs(
8077
8085
  "button",
8078
8086
  {
8079
8087
  style: z.menuItem,
@@ -8093,7 +8101,7 @@ const Ns = [
8093
8101
  ]
8094
8102
  }
8095
8103
  ),
8096
- p && C.profileUrl && /* @__PURE__ */ r.jsxs(
8104
+ d && C.profileUrl && /* @__PURE__ */ r.jsxs(
8097
8105
  "a",
8098
8106
  {
8099
8107
  href: C.profileUrl,
@@ -8109,7 +8117,7 @@ const Ns = [
8109
8117
  role: "menuitem",
8110
8118
  tabIndex: 0,
8111
8119
  children: [
8112
- /* @__PURE__ */ r.jsx(pe, { style: z.icon, "aria-hidden": "true" }),
8120
+ /* @__PURE__ */ r.jsx(fe, { style: z.icon, "aria-hidden": "true" }),
8113
8121
  /* @__PURE__ */ r.jsx("span", { style: z.menuItemText, children: E })
8114
8122
  ]
8115
8123
  }
@@ -8137,7 +8145,7 @@ const Ns = [
8137
8145
  "aria-hidden": "true"
8138
8146
  }
8139
8147
  ),
8140
- /* @__PURE__ */ r.jsx("span", { style: z.menuItemText, children: u })
8148
+ /* @__PURE__ */ r.jsx("span", { style: z.menuItemText, children: p })
8141
8149
  ]
8142
8150
  }
8143
8151
  ) })
@@ -8176,7 +8184,7 @@ const Ns = [
8176
8184
  primaryColor: n = "#00C212",
8177
8185
  onVerify: s
8178
8186
  }) => {
8179
- const i = fe();
8187
+ const i = pe();
8180
8188
  if (!t)
8181
8189
  return /* @__PURE__ */ r.jsxs(
8182
8190
  "div",
@@ -8200,10 +8208,10 @@ const Ns = [
8200
8208
  ]
8201
8209
  }
8202
8210
  );
8203
- const [a, o] = P(!1), [c, d] = P({
8211
+ const [a, o] = P(!1), [c, u] = P({
8204
8212
  email: t?.email || "",
8205
8213
  otp: ""
8206
- }), [f, p] = P(!1), [y, k] = P(!1), [E, u] = P(null);
8214
+ }), [x, d] = P(!1), [y, k] = P(!1), [E, p] = P(null);
8207
8215
  Ce.useEffect(() => {
8208
8216
  if (typeof window < "u") {
8209
8217
  const b = () => o(window.innerWidth < 768);
@@ -8235,10 +8243,10 @@ const Ns = [
8235
8243
  warning: "#d97706"
8236
8244
  };
8237
8245
  ee(() => {
8238
- t?.email && d((b) => ({ ...b, email: t.email }));
8246
+ t?.email && u((b) => ({ ...b, email: t.email }));
8239
8247
  }, [t?.email]);
8240
8248
  const O = (b, j) => {
8241
- u({ type: b, message: j }), setTimeout(() => u(null), 3e3);
8249
+ p({ type: b, message: j }), setTimeout(() => p(null), 3e3);
8242
8250
  }, C = async () => {
8243
8251
  if (!c.email || !/\S+@\S+\.\S+/.test(c.email)) {
8244
8252
  O("error", "Please enter a valid email");
@@ -8256,7 +8264,7 @@ const Ns = [
8256
8264
  });
8257
8265
  if (console.log("Send OTP response:", b), b.success || b.data?.success) {
8258
8266
  const j = b.message || b.data?.message || "OTP sent!";
8259
- O("success", j), p(!0);
8267
+ O("success", j), d(!0);
8260
8268
  } else {
8261
8269
  const j = b.message || b.data?.message || "Failed to send OTP";
8262
8270
  O("error", j);
@@ -8279,7 +8287,7 @@ const Ns = [
8279
8287
  });
8280
8288
  if (j.success) {
8281
8289
  const q = { ...t, isVerified: !0 };
8282
- s?.(q), O("success", j.message || "Email verified!"), p(!1), d({ email: t.email, otp: "" });
8290
+ s?.(q), O("success", j.message || "Email verified!"), d(!1), u({ email: t.email, otp: "" });
8283
8291
  } else
8284
8292
  O("error", j.message || "Verification failed");
8285
8293
  } catch (j) {
@@ -8399,7 +8407,7 @@ const Ns = [
8399
8407
  },
8400
8408
  children: [
8401
8409
  /* @__PURE__ */ r.jsx(
8402
- pe,
8410
+ fe,
8403
8411
  {
8404
8412
  size: 18,
8405
8413
  style: {
@@ -8415,7 +8423,7 @@ const Ns = [
8415
8423
  {
8416
8424
  type: "email",
8417
8425
  value: c.email,
8418
- onChange: (b) => d((j) => ({ ...j, email: b.target.value })),
8426
+ onChange: (b) => u((j) => ({ ...j, email: b.target.value })),
8419
8427
  placeholder: "Enter your email",
8420
8428
  style: {
8421
8429
  ...A,
@@ -8439,7 +8447,7 @@ const Ns = [
8439
8447
  }
8440
8448
  )
8441
8449
  ] }),
8442
- f && /* @__PURE__ */ r.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: 4 }, children: [
8450
+ x && /* @__PURE__ */ r.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: 4 }, children: [
8443
8451
  /* @__PURE__ */ r.jsxs(
8444
8452
  "div",
8445
8453
  {
@@ -8466,7 +8474,7 @@ const Ns = [
8466
8474
  {
8467
8475
  type: "text",
8468
8476
  value: c.otp,
8469
- onChange: (b) => d((j) => ({ ...j, otp: b.target.value })),
8477
+ onChange: (b) => u((j) => ({ ...j, otp: b.target.value })),
8470
8478
  placeholder: "Enter OTP",
8471
8479
  style: {
8472
8480
  ...A,
@@ -8489,7 +8497,7 @@ const Ns = [
8489
8497
  }
8490
8498
  )
8491
8499
  ] }),
8492
- /* @__PURE__ */ r.jsx("div", { style: { display: "flex", gap: 12 }, children: f ? /* @__PURE__ */ r.jsxs(
8500
+ /* @__PURE__ */ r.jsx("div", { style: { display: "flex", gap: 12 }, children: x ? /* @__PURE__ */ r.jsxs(
8493
8501
  "button",
8494
8502
  {
8495
8503
  type: "submit",