@neuctra/authix 1.2.2 → 1.2.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- import Te, { forwardRef as zt, createElement as Ke, createContext as cr, useContext as dr, useState as P, useEffect as ee, useRef as dt } from "react";
1
+ import Ce, { forwardRef as zt, createElement as Ke, createContext as cr, useContext as dr, useState as P, useEffect as ee, useRef as dt } from "react";
2
2
  function At(t, e) {
3
3
  return function() {
4
4
  return t.apply(e, arguments);
@@ -8,7 +8,7 @@ const { toString: ur } = Object.prototype, { getPrototypeOf: rt } = Object, { it
8
8
  const n = ur.call(e);
9
9
  return t[n] || (t[n] = n.slice(8, -1).toLowerCase());
10
10
  })(/* @__PURE__ */ Object.create(null)), ae = (t) => (t = t.toLowerCase(), (e) => Le(e) === t), qe = (t) => (e) => typeof e === t, { isArray: je } = Array, be = qe("undefined");
11
- function Ce(t) {
11
+ function Te(t) {
12
12
  return t !== null && !be(t) && t.constructor !== null && !be(t.constructor) && te(t.constructor.isBuffer) && t.constructor.isBuffer(t);
13
13
  }
14
14
  const Ut = ae("ArrayBuffer");
@@ -22,7 +22,7 @@ const fr = qe("string"), te = qe("function"), $t = qe("number"), Re = (t) => t !
22
22
  const e = rt(t);
23
23
  return (e === null || e === Object.prototype || Object.getPrototypeOf(e) === null) && !(_t in t) && !(Fe in t);
24
24
  }, hr = (t) => {
25
- if (!Re(t) || Ce(t))
25
+ if (!Re(t) || Te(t))
26
26
  return !1;
27
27
  try {
28
28
  return Object.keys(t).length === 0 && Object.getPrototypeOf(t) === Object.prototype;
@@ -33,7 +33,7 @@ const fr = qe("string"), te = qe("function"), $t = qe("number"), Re = (t) => t !
33
33
  let e;
34
34
  return t && (typeof FormData == "function" && t instanceof FormData || te(t.append) && ((e = Le(t)) === "formdata" || // detect form-data instance
35
35
  e === "object" && te(t.toString) && t.toString() === "[object FormData]"));
36
- }, vr = ae("URLSearchParams"), [Sr, Er, kr, Tr] = ["ReadableStream", "Request", "Response", "Headers"].map(ae), Cr = (t) => t.trim ? t.trim() : t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
36
+ }, vr = ae("URLSearchParams"), [Sr, kr, Er, Cr] = ["ReadableStream", "Request", "Response", "Headers"].map(ae), Tr = (t) => t.trim ? t.trim() : t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g, "");
37
37
  function Pe(t, e, { allOwnKeys: n = !1 } = {}) {
38
38
  if (t === null || typeof t > "u")
39
39
  return;
@@ -42,7 +42,7 @@ function Pe(t, e, { allOwnKeys: n = !1 } = {}) {
42
42
  for (s = 0, i = t.length; s < i; s++)
43
43
  e.call(null, t[s], s, t);
44
44
  else {
45
- if (Ce(t))
45
+ if (Te(t))
46
46
  return;
47
47
  const a = n ? Object.getOwnPropertyNames(t) : Object.keys(t), o = a.length;
48
48
  let c;
@@ -51,7 +51,7 @@ function Pe(t, e, { allOwnKeys: n = !1 } = {}) {
51
51
  }
52
52
  }
53
53
  function Dt(t, e) {
54
- if (Ce(t))
54
+ if (Te(t))
55
55
  return null;
56
56
  e = e.toLowerCase();
57
57
  const n = Object.keys(t);
@@ -61,7 +61,7 @@ function Dt(t, e) {
61
61
  return i;
62
62
  return null;
63
63
  }
64
- const fe = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, Nt = (t) => !be(t) && t !== fe;
64
+ const xe = typeof globalThis < "u" ? globalThis : typeof self < "u" ? self : typeof window < "u" ? window : global, Nt = (t) => !be(t) && t !== xe;
65
65
  function Ge() {
66
66
  const { caseless: t, skipUndefined: e } = Nt(this) && this || {}, n = {}, s = (i, a) => {
67
67
  const o = t && Dt(n, a) || a;
@@ -156,7 +156,7 @@ const Hr = (t) => {
156
156
  if (Re(s)) {
157
157
  if (e.indexOf(s) >= 0)
158
158
  return;
159
- if (Ce(s))
159
+ if (Te(s))
160
160
  return s;
161
161
  if (!("toJSON" in s)) {
162
162
  e[i] = s;
@@ -170,17 +170,17 @@ const Hr = (t) => {
170
170
  return s;
171
171
  };
172
172
  return n(t, 0);
173
- }, Vr = ae("AsyncFunction"), Yr = (t) => t && (Re(t) || te(t)) && te(t.then) && te(t.catch), Lt = ((t, e) => t ? setImmediate : e ? ((n, s) => (fe.addEventListener("message", ({ source: i, data: a }) => {
174
- i === fe && a === n && s.length && s.shift()();
173
+ }, Vr = ae("AsyncFunction"), Yr = (t) => t && (Re(t) || te(t)) && te(t.then) && te(t.catch), Lt = ((t, e) => t ? setImmediate : e ? ((n, s) => (xe.addEventListener("message", ({ source: i, data: a }) => {
174
+ i === xe && a === n && s.length && s.shift()();
175
175
  }, !1), (i) => {
176
- s.push(i), fe.postMessage(n, "*");
176
+ s.push(i), xe.postMessage(n, "*");
177
177
  }))(`axios@${Math.random()}`, []) : (n) => setTimeout(n))(
178
178
  typeof setImmediate == "function",
179
- te(fe.postMessage)
180
- ), Jr = typeof queueMicrotask < "u" ? queueMicrotask.bind(fe) : typeof process < "u" && process.nextTick || Lt, Kr = (t) => t != null && te(t[Fe]), f = {
179
+ te(xe.postMessage)
180
+ ), Jr = typeof queueMicrotask < "u" ? queueMicrotask.bind(xe) : typeof process < "u" && process.nextTick || Lt, Kr = (t) => t != null && te(t[Fe]), f = {
181
181
  isArray: je,
182
182
  isArrayBuffer: Ut,
183
- isBuffer: Ce,
183
+ isBuffer: Te,
184
184
  isFormData: jr,
185
185
  isArrayBufferView: pr,
186
186
  isString: fr,
@@ -190,9 +190,9 @@ const Hr = (t) => {
190
190
  isPlainObject: _e,
191
191
  isEmptyObject: hr,
192
192
  isReadableStream: Sr,
193
- isRequest: Er,
194
- isResponse: kr,
195
- isHeaders: Tr,
193
+ isRequest: kr,
194
+ isResponse: Er,
195
+ isHeaders: Cr,
196
196
  isUndefined: be,
197
197
  isDate: mr,
198
198
  isFile: gr,
@@ -206,7 +206,7 @@ const Hr = (t) => {
206
206
  forEach: Pe,
207
207
  merge: Ge,
208
208
  extend: Rr,
209
- trim: Cr,
209
+ trim: Tr,
210
210
  stripBOM: Pr,
211
211
  inherits: Or,
212
212
  toFlatObject: Ir,
@@ -227,7 +227,7 @@ const Hr = (t) => {
227
227
  noop: Mr,
228
228
  toFiniteNumber: Wr,
229
229
  findKey: Dt,
230
- global: fe,
230
+ global: xe,
231
231
  isContextDefined: Nt,
232
232
  isSpecCompliantForm: Br,
233
233
  toJSONObject: Hr,
@@ -285,7 +285,7 @@ $.from = (t, e, n, s, i, a) => {
285
285
  const o = Object.create(qt);
286
286
  f.toFlatObject(t, o, function(x) {
287
287
  return x !== Error.prototype;
288
- }, (u) => u !== "isAxiosError");
288
+ }, (p) => p !== "isAxiosError");
289
289
  const c = t && t.message ? t.message : "Error", d = e == null && t ? t.code : e;
290
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;
291
291
  };
@@ -320,55 +320,55 @@ function Me(t, e, n) {
320
320
  const s = n.metaTokens, i = n.visitor || x, a = n.dots, o = n.indexes, d = (n.Blob || typeof Blob < "u" && Blob) && f.isSpecCompliantForm(e);
321
321
  if (!f.isFunction(i))
322
322
  throw new TypeError("visitor must be a function");
323
- function u(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 (!d && f.isBlob(p))
323
+ function p(u) {
324
+ if (u === null) return "";
325
+ if (f.isDate(u))
326
+ return u.toISOString();
327
+ if (f.isBoolean(u))
328
+ return u.toString();
329
+ if (!d && f.isBlob(u))
330
330
  throw new $("Blob is not supported. Use a Buffer instead.");
331
- return f.isArrayBuffer(p) || f.isTypedArray(p) ? d && typeof Blob == "function" ? new Blob([p]) : Buffer.from(p) : p;
331
+ return f.isArrayBuffer(u) || f.isTypedArray(u) ? d && typeof Blob == "function" ? new Blob([u]) : Buffer.from(u) : u;
332
332
  }
333
- function x(p, w, h) {
334
- let O = p;
335
- if (p && !h && typeof p == "object") {
333
+ function x(u, w, h) {
334
+ let O = u;
335
+ if (u && !h && typeof u == "object") {
336
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)))
337
+ w = s ? w : w.slice(0, -2), u = JSON.stringify(u);
338
+ else if (f.isArray(u) && Xr(u) || (f.isFileList(u) || f.endsWith(w, "[]")) && (O = f.toArray(u)))
339
339
  return w = Wt(w), O.forEach(function(g, A) {
340
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
- u(g)
343
+ p(g)
344
344
  );
345
345
  }), !1;
346
346
  }
347
- return Xe(p) ? !0 : (e.append(pt(h, w, a), u(p)), !1);
347
+ return Xe(u) ? !0 : (e.append(pt(h, w, a), p(u)), !1);
348
348
  }
349
- const y = [], E = Object.assign(Zr, {
349
+ const y = [], k = Object.assign(Zr, {
350
350
  defaultVisitor: x,
351
- convertValue: u,
351
+ convertValue: p,
352
352
  isVisitable: Xe
353
353
  });
354
- function k(p, w) {
355
- if (!f.isUndefined(p)) {
356
- if (y.indexOf(p) !== -1)
354
+ function E(u, w) {
355
+ if (!f.isUndefined(u)) {
356
+ if (y.indexOf(u) !== -1)
357
357
  throw Error("Circular reference detected in " + w.join("."));
358
- y.push(p), f.forEach(p, function(O, T) {
358
+ y.push(u), f.forEach(u, function(O, C) {
359
359
  (!(f.isUndefined(O) || O === null) && i.call(
360
360
  e,
361
361
  O,
362
- f.isString(T) ? T.trim() : T,
362
+ f.isString(C) ? C.trim() : C,
363
363
  w,
364
- E
365
- )) === !0 && k(O, w ? w.concat(T) : [T]);
364
+ k
365
+ )) === !0 && E(O, w ? w.concat(C) : [C]);
366
366
  }), y.pop();
367
367
  }
368
368
  }
369
369
  if (!f.isObject(t))
370
370
  throw new TypeError("data must be an object");
371
- return k(t), e;
371
+ return E(t), e;
372
372
  }
373
373
  function ft(t) {
374
374
  const e = {
@@ -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, u) {
682
+ function a(c, d, p) {
683
683
  const x = Se(d);
684
684
  if (!x)
685
685
  throw new Error("header name must be a non-empty string");
686
686
  const y = f.findKey(i, x);
687
- (!y || i[y] === void 0 || u === !0 || u === void 0 && i[y] !== !1) && (i[y || d] = Ue(c));
687
+ (!y || i[y] === void 0 || p === !0 || p === void 0 && i[y] !== !1) && (i[y || d] = Ue(c));
688
688
  }
689
- const o = (c, d) => f.forEach(c, (u, x) => a(u, x, d));
689
+ const o = (c, d) => f.forEach(c, (p, x) => a(p, x, d));
690
690
  if (f.isPlainObject(e) || e instanceof this.constructor)
691
691
  o(e, n);
692
692
  else if (f.isString(e) && (e = e.trim()) && !mn(e))
693
693
  o(xn(e), n);
694
694
  else if (f.isObject(e) && f.isIterable(e)) {
695
- let c = {}, d, u;
695
+ let c = {}, d, p;
696
696
  for (const x of e) {
697
697
  if (!f.isArray(x))
698
698
  throw TypeError("Object iterator must return a key-value pair");
699
- c[u = x[0]] = (d = c[u]) ? f.isArray(d) ? [...d, x[1]] : [d, x[1]] : x[1];
699
+ c[p = x[0]] = (d = c[p]) ? f.isArray(d) ? [...d, x[1]] : [d, x[1]] : x[1];
700
700
  }
701
701
  o(c, n);
702
702
  } else
@@ -845,25 +845,25 @@ function wn(t, e) {
845
845
  const n = new Array(t), s = new Array(t);
846
846
  let i = 0, a = 0, o;
847
847
  return e = e !== void 0 ? e : 1e3, function(d) {
848
- const u = Date.now(), x = s[a];
849
- o || (o = u), n[i] = d, s[i] = u;
850
- let y = a, E = 0;
848
+ const p = Date.now(), x = s[a];
849
+ o || (o = p), n[i] = d, s[i] = p;
850
+ let y = a, k = 0;
851
851
  for (; y !== i; )
852
- E += n[y++], y = y % t;
853
- if (i = (i + 1) % t, i === a && (a = (a + 1) % t), u - o < e)
852
+ k += n[y++], y = y % t;
853
+ if (i = (i + 1) % t, i === a && (a = (a + 1) % t), p - o < e)
854
854
  return;
855
- const k = x && u - x;
856
- return k ? Math.round(E * 1e3 / k) : void 0;
855
+ const E = x && p - x;
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 = (u, x = Date.now()) => {
862
- n = x, i = null, a && (clearTimeout(a), a = null), t(...u);
861
+ const o = (p, x = Date.now()) => {
862
+ n = x, i = null, a && (clearTimeout(a), a = null), t(...p);
863
863
  };
864
- return [(...u) => {
864
+ return [(...p) => {
865
865
  const x = Date.now(), y = x - n;
866
- y >= s ? o(u, x) : (i = u, a || (a = setTimeout(() => {
866
+ y >= s ? o(p, x) : (i = p, 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, u = i(d), x = o <= c;
875
+ const o = a.loaded, c = a.lengthComputable ? a.total : void 0, d = o - s, p = i(d), x = 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
881
  bytes: d,
882
- rate: u || void 0,
883
- estimated: u && c && x ? (c - o) / u : void 0,
882
+ rate: p || void 0,
883
+ estimated: p && c && x ? (c - o) / p : void 0,
884
884
  event: a,
885
885
  lengthComputable: c != null,
886
886
  [e ? "download" : "upload"]: !0
@@ -924,44 +924,44 @@ const Ne = (t, e, n = 3) => {
924
924
  }
925
925
  }
926
926
  );
927
- function En(t) {
927
+ function kn(t) {
928
928
  return /^([a-z][a-z\d+\-.]*:)?\/\//i.test(t);
929
929
  }
930
- function kn(t, e) {
930
+ function En(t, e) {
931
931
  return e ? t.replace(/\/?\/$/, "") + "/" + e.replace(/^\/+/, "") : t;
932
932
  }
933
933
  function Gt(t, e, n) {
934
- let s = !En(e);
935
- return t && (s || n == !1) ? kn(t, e) : e;
934
+ let s = !kn(e);
935
+ return t && (s || n == !1) ? En(t, e) : e;
936
936
  }
937
937
  const yt = (t) => t instanceof re ? { ...t } : t;
938
- function he(t, e) {
938
+ function me(t, e) {
939
939
  e = e || {};
940
940
  const n = {};
941
- function s(u, x, y, E) {
942
- return f.isPlainObject(u) && f.isPlainObject(x) ? f.merge.call({ caseless: E }, u, x) : f.isPlainObject(x) ? f.merge({}, x) : f.isArray(x) ? x.slice() : x;
941
+ function s(p, x, y, k) {
942
+ return f.isPlainObject(p) && f.isPlainObject(x) ? f.merge.call({ caseless: k }, p, x) : f.isPlainObject(x) ? f.merge({}, x) : f.isArray(x) ? x.slice() : x;
943
943
  }
944
- function i(u, x, y, E) {
944
+ function i(p, x, y, k) {
945
945
  if (f.isUndefined(x)) {
946
- if (!f.isUndefined(u))
947
- return s(void 0, u, y, E);
948
- } else return s(u, x, y, E);
946
+ if (!f.isUndefined(p))
947
+ return s(void 0, p, y, k);
948
+ } else return s(p, x, y, k);
949
949
  }
950
- function a(u, x) {
950
+ function a(p, x) {
951
951
  if (!f.isUndefined(x))
952
952
  return s(void 0, x);
953
953
  }
954
- function o(u, x) {
954
+ function o(p, x) {
955
955
  if (f.isUndefined(x)) {
956
- if (!f.isUndefined(u))
957
- return s(void 0, u);
956
+ if (!f.isUndefined(p))
957
+ return s(void 0, p);
958
958
  } else return s(void 0, x);
959
959
  }
960
- function c(u, x, y) {
960
+ function c(p, x, y) {
961
961
  if (y in e)
962
- return s(u, x);
962
+ return s(p, x);
963
963
  if (y in t)
964
- return s(void 0, u);
964
+ return s(void 0, p);
965
965
  }
966
966
  const d = {
967
967
  url: a,
@@ -992,15 +992,15 @@ function he(t, e) {
992
992
  socketPath: o,
993
993
  responseEncoding: o,
994
994
  validateStatus: c,
995
- headers: (u, x, y) => i(yt(u), yt(x), y, !0)
995
+ headers: (p, x, y) => i(yt(p), yt(x), y, !0)
996
996
  };
997
997
  return f.forEach(Object.keys({ ...t, ...e }), function(x) {
998
- const y = d[x] || i, E = y(t[x], e[x], x);
999
- f.isUndefined(E) && y !== c || (n[x] = E);
998
+ const y = d[x] || i, k = y(t[x], e[x], x);
999
+ f.isUndefined(k) && y !== c || (n[x] = k);
1000
1000
  }), n;
1001
1001
  }
1002
1002
  const Xt = (t) => {
1003
- const e = he({}, t);
1003
+ const e = me({}, t);
1004
1004
  let { data: n, withXSRFToken: s, xsrfHeaderName: i, xsrfCookieName: a, headers: o, auth: c } = e;
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",
@@ -1009,9 +1009,9 @@ const Xt = (t) => {
1009
1009
  if (Q.hasStandardBrowserEnv || Q.hasStandardBrowserWebWorkerEnv)
1010
1010
  o.setContentType(void 0);
1011
1011
  else if (f.isFunction(n.getHeaders)) {
1012
- const d = n.getHeaders(), u = ["content-type", "content-length"];
1012
+ const d = n.getHeaders(), p = ["content-type", "content-length"];
1013
1013
  Object.entries(d).forEach(([x, y]) => {
1014
- u.includes(x.toLowerCase()) && o.set(x, y);
1014
+ p.includes(x.toLowerCase()) && o.set(x, y);
1015
1015
  });
1016
1016
  }
1017
1017
  }
@@ -1020,14 +1020,14 @@ const Xt = (t) => {
1020
1020
  d && o.set(i, d);
1021
1021
  }
1022
1022
  return e;
1023
- }, Tn = typeof XMLHttpRequest < "u", Cn = Tn && function(t) {
1023
+ }, Cn = typeof XMLHttpRequest < "u", Tn = Cn && function(t) {
1024
1024
  return new Promise(function(n, s) {
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: u } = i, x, y, E, k, p;
1028
+ let { responseType: c, onUploadProgress: d, onDownloadProgress: p } = i, x, y, k, E, u;
1029
1029
  function w() {
1030
- k && k(), p && p(), i.cancelToken && i.cancelToken.unsubscribe(x), i.signal && i.signal.removeEventListener("abort", x);
1030
+ E && E(), u && u(), i.cancelToken && i.cancelToken.unsubscribe(x), i.signal && i.signal.removeEventListener("abort", x);
1031
1031
  }
1032
1032
  let h = new XMLHttpRequest();
1033
1033
  h.open(i.method.toUpperCase(), i.url, !0), h.timeout = i.timeout;
@@ -1068,12 +1068,12 @@ const Xt = (t) => {
1068
1068
  )), h = null;
1069
1069
  }, a === void 0 && o.setContentType(null), "setRequestHeader" in h && f.forEach(o.toJSON(), function(A, N) {
1070
1070
  h.setRequestHeader(N, A);
1071
- }), f.isUndefined(i.withCredentials) || (h.withCredentials = !!i.withCredentials), c && c !== "json" && (h.responseType = i.responseType), u && ([E, p] = Ne(u, !0), h.addEventListener("progress", E)), d && h.upload && ([y, k] = Ne(d), h.upload.addEventListener("progress", y), h.upload.addEventListener("loadend", k)), (i.cancelToken || i.signal) && (x = (g) => {
1071
+ }), f.isUndefined(i.withCredentials) || (h.withCredentials = !!i.withCredentials), c && c !== "json" && (h.responseType = i.responseType), p && ([k, u] = Ne(p, !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) && (x = (g) => {
1072
1072
  h && (s(!g || g.type ? new ve(null, t, h) : g), h.abort(), h = null);
1073
1073
  }, i.cancelToken && i.cancelToken.subscribe(x), i.signal && (i.signal.aborted ? x() : i.signal.addEventListener("abort", x)));
1074
- const T = bn(i.url);
1075
- if (T && Q.protocols.indexOf(T) === -1) {
1076
- s(new $("Unsupported protocol " + T + ":", $.ERR_BAD_REQUEST, t));
1074
+ const C = bn(i.url);
1075
+ if (C && Q.protocols.indexOf(C) === -1) {
1076
+ s(new $("Unsupported protocol " + C + ":", $.ERR_BAD_REQUEST, t));
1077
1077
  return;
1078
1078
  }
1079
1079
  h.send(a || null);
@@ -1082,10 +1082,10 @@ 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(u) {
1085
+ const a = function(p) {
1086
1086
  if (!i) {
1087
1087
  i = !0, c();
1088
- const x = u instanceof Error ? u : this.reason;
1088
+ const x = p instanceof Error ? p : this.reason;
1089
1089
  s.abort(x instanceof $ ? x : new ve(x instanceof Error ? x.message : x));
1090
1090
  }
1091
1091
  };
@@ -1093,11 +1093,11 @@ const Xt = (t) => {
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((u) => {
1097
- u.unsubscribe ? u.unsubscribe(a) : u.removeEventListener("abort", a);
1096
+ t && (o && clearTimeout(o), o = null, t.forEach((p) => {
1097
+ p.unsubscribe ? p.unsubscribe(a) : p.removeEventListener("abort", a);
1098
1098
  }), t = null);
1099
1099
  };
1100
- t.forEach((u) => u.addEventListener("abort", a));
1100
+ t.forEach((p) => p.addEventListener("abort", a));
1101
1101
  const { signal: d } = s;
1102
1102
  return d.unsubscribe = () => f.asap(c), d;
1103
1103
  }
@@ -1137,19 +1137,19 @@ const Xt = (t) => {
1137
1137
  return new ReadableStream({
1138
1138
  async pull(d) {
1139
1139
  try {
1140
- const { done: u, value: x } = await i.next();
1141
- if (u) {
1140
+ const { done: p, value: x } = await i.next();
1141
+ if (p) {
1142
1142
  c(), d.close();
1143
1143
  return;
1144
1144
  }
1145
1145
  let y = x.byteLength;
1146
1146
  if (n) {
1147
- let E = a += y;
1148
- n(E);
1147
+ let k = a += y;
1148
+ n(k);
1149
1149
  }
1150
1150
  d.enqueue(new Uint8Array(x));
1151
- } catch (u) {
1152
- throw c(u), u;
1151
+ } catch (p) {
1152
+ throw c(p), p;
1153
1153
  }
1154
1154
  },
1155
1155
  cancel(d) {
@@ -1177,51 +1177,51 @@ const Xt = (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__ */ ((p) => (w) => p.encode(w))(new vt()) : async (p) => new Uint8Array(await new n(p).arrayBuffer())), u = a && c && St(() => {
1181
- let p = !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())), p = a && c && St(() => {
1181
+ let u = !1;
1182
1182
  const w = new n(Q.origin, {
1183
1183
  body: new jt(),
1184
1184
  method: "POST",
1185
1185
  get duplex() {
1186
- return p = !0, "half";
1186
+ return u = !0, "half";
1187
1187
  }
1188
1188
  }).headers.has("Content-Type");
1189
- return p && !w;
1189
+ return u && !w;
1190
1190
  }), x = o && c && St(() => f.isReadableStream(new s("").body)), y = {
1191
- stream: x && ((p) => p.body)
1191
+ stream: x && ((u) => u.body)
1192
1192
  };
1193
- i && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((p) => {
1194
- !y[p] && (y[p] = (w, h) => {
1195
- let O = w && w[p];
1193
+ i && ["text", "arrayBuffer", "blob", "formData", "stream"].forEach((u) => {
1194
+ !y[u] && (y[u] = (w, h) => {
1195
+ let O = w && w[u];
1196
1196
  if (O)
1197
1197
  return O.call(w);
1198
- throw new $(`Response type '${p}' is not supported`, $.ERR_NOT_SUPPORT, h);
1198
+ throw new $(`Response type '${u}' is not supported`, $.ERR_NOT_SUPPORT, h);
1199
1199
  });
1200
1200
  });
1201
- const E = async (p) => {
1202
- if (p == null)
1201
+ const k = async (u) => {
1202
+ if (u == null)
1203
1203
  return 0;
1204
- if (f.isBlob(p))
1205
- return p.size;
1206
- if (f.isSpecCompliantForm(p))
1204
+ if (f.isBlob(u))
1205
+ return u.size;
1206
+ if (f.isSpecCompliantForm(u))
1207
1207
  return (await new n(Q.origin, {
1208
1208
  method: "POST",
1209
- body: p
1209
+ body: u
1210
1210
  }).arrayBuffer()).byteLength;
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 d(p)).byteLength;
1215
- }, k = async (p, w) => {
1216
- const h = f.toFiniteNumber(p.getContentLength());
1217
- return h ?? E(w);
1211
+ if (f.isArrayBufferView(u) || f.isArrayBuffer(u))
1212
+ return u.byteLength;
1213
+ if (f.isURLSearchParams(u) && (u = u + ""), f.isString(u))
1214
+ return (await d(u)).byteLength;
1215
+ }, E = async (u, w) => {
1216
+ const h = f.toFiniteNumber(u.getContentLength());
1217
+ return h ?? k(w);
1218
1218
  };
1219
- return async (p) => {
1219
+ return async (u) => {
1220
1220
  let {
1221
1221
  url: w,
1222
1222
  method: h,
1223
1223
  data: O,
1224
- signal: T,
1224
+ signal: C,
1225
1225
  cancelToken: g,
1226
1226
  timeout: A,
1227
1227
  onDownloadProgress: N,
@@ -1230,15 +1230,15 @@ const Xt = (t) => {
1230
1230
  headers: q,
1231
1231
  withCredentials: I = "same-origin",
1232
1232
  fetchOptions: X
1233
- } = Xt(p), W = e || fetch;
1233
+ } = Xt(u), W = e || fetch;
1234
1234
  j = j ? (j + "").toLowerCase() : "text";
1235
- let C = Rn([T, g && g.toAbortSignal()], A), G = null;
1236
- const R = C && C.unsubscribe && (() => {
1237
- C.unsubscribe();
1235
+ let T = Rn([C, g && g.toAbortSignal()], A), G = null;
1236
+ const R = T && T.unsubscribe && (() => {
1237
+ T.unsubscribe();
1238
1238
  });
1239
1239
  let z;
1240
1240
  try {
1241
- if (b && u && h !== "get" && h !== "head" && (z = await k(q, O)) !== 0) {
1241
+ if (b && p && 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,
@@ -1255,7 +1255,7 @@ const Xt = (t) => {
1255
1255
  f.isString(I) || (I = I ? "include" : "omit");
1256
1256
  const M = a && "credentials" in n.prototype, K = {
1257
1257
  ...X,
1258
- signal: C,
1258
+ signal: T,
1259
1259
  method: h.toUpperCase(),
1260
1260
  headers: q.normalize().toJSON(),
1261
1261
  body: O,
@@ -1282,24 +1282,24 @@ const Xt = (t) => {
1282
1282
  );
1283
1283
  }
1284
1284
  j = j || "text";
1285
- let Y = await y[f.findKey(y, j) || "text"](H, p);
1285
+ let Y = await y[f.findKey(y, j) || "text"](H, u);
1286
1286
  return !F && 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: p,
1292
+ config: u,
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, p, G),
1298
+ new $("Network Error", $.ERR_NETWORK, u, G),
1299
1299
  {
1300
1300
  cause: M.cause || M
1301
1301
  }
1302
- ) : $.from(M, M && M.code, p, G);
1302
+ ) : $.from(M, M && M.code, u, G);
1303
1303
  }
1304
1304
  };
1305
1305
  }, _n = /* @__PURE__ */ new Map(), Zt = (t) => {
@@ -1309,15 +1309,15 @@ const Xt = (t) => {
1309
1309
  i,
1310
1310
  n
1311
1311
  ];
1312
- let o = a.length, c = o, d, u, x = _n;
1312
+ let o = a.length, c = o, d, p, x = _n;
1313
1313
  for (; c--; )
1314
- d = a[c], u = x.get(d), u === void 0 && x.set(d, u = c ? /* @__PURE__ */ new Map() : An(e)), x = u;
1315
- return u;
1314
+ d = a[c], p = x.get(d), p === void 0 && x.set(d, p = c ? /* @__PURE__ */ new Map() : An(e)), x = p;
1315
+ return p;
1316
1316
  };
1317
1317
  Zt();
1318
1318
  const Qe = {
1319
1319
  http: Gr,
1320
- xhr: Cn,
1320
+ xhr: Tn,
1321
1321
  fetch: {
1322
1322
  get: Zt
1323
1323
  }
@@ -1331,7 +1331,7 @@ f.forEach(Qe, (t, e) => {
1331
1331
  Object.defineProperty(t, "adapterName", { value: e });
1332
1332
  }
1333
1333
  });
1334
- const Et = (t) => `- ${t}`, Un = (t) => f.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
1336
  t = f.isArray(t) ? t : [t];
1337
1337
  const { length: n } = t;
@@ -1348,11 +1348,11 @@ const Et = (t) => `- ${t}`, Un = (t) => f.isFunction(t) || t === null || t === !
1348
1348
  }
1349
1349
  if (!i) {
1350
1350
  const o = Object.entries(a).map(
1351
- ([d, u]) => `adapter ${d} ` + (u === !1 ? "is not supported by the environment" : "is not available in the build")
1351
+ ([d, p]) => `adapter ${d} ` + (p === !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
- ` + o.map(Et).join(`
1355
- `) : " " + Et(o[0]) : "as no adapter specified";
1354
+ ` + o.map(kt).join(`
1355
+ `) : " " + kt(o[0]) : "as no adapter specified";
1356
1356
  throw new $(
1357
1357
  "There is no suitable adapter to dispatch the request " + c,
1358
1358
  "ERR_NOT_SUPPORT"
@@ -1366,7 +1366,7 @@ function Ye(t) {
1366
1366
  if (t.cancelToken && t.cancelToken.throwIfRequested(), t.signal && t.signal.aborted)
1367
1367
  throw new ve(null, t);
1368
1368
  }
1369
- function kt(t) {
1369
+ function Et(t) {
1370
1370
  return Ye(t), t.headers = re.from(t.headers), t.data = Ve.call(
1371
1371
  t,
1372
1372
  t.transformRequest
@@ -1390,7 +1390,7 @@ const er = "1.12.2", We = {};
1390
1390
  return typeof s === t || "a" + (e < 1 ? "n " : " ") + t;
1391
1391
  };
1392
1392
  });
1393
- const Tt = {};
1393
+ const Ct = {};
1394
1394
  We.transitional = function(e, n, s) {
1395
1395
  function i(a, o) {
1396
1396
  return "[Axios v" + er + "] Transitional option '" + a + "'" + o + (s ? ". " + s : "");
@@ -1401,7 +1401,7 @@ We.transitional = function(e, n, s) {
1401
1401
  i(o, " has been removed" + (n ? " in " + n : "")),
1402
1402
  $.ERR_DEPRECATED
1403
1403
  );
1404
- return n && !Tt[o] && (Tt[o] = !0, console.warn(
1404
+ return n && !Ct[o] && (Ct[o] = !0, console.warn(
1405
1405
  i(
1406
1406
  o,
1407
1407
  " has been deprecated since v" + n + " and will be removed in the near future"
@@ -1433,7 +1433,7 @@ const $e = {
1433
1433
  assertOptions: $n,
1434
1434
  validators: We
1435
1435
  }, ce = $e.validators;
1436
- let xe = class {
1436
+ let he = class {
1437
1437
  constructor(e) {
1438
1438
  this.defaults = e || {}, this.interceptors = {
1439
1439
  request: new xt(),
@@ -1466,7 +1466,7 @@ let xe = class {
1466
1466
  }
1467
1467
  }
1468
1468
  _request(e, n) {
1469
- typeof e == "string" ? (n = n || {}, n.url = e) : n = e || {}, n = he(this.defaults, n);
1469
+ typeof e == "string" ? (n = n || {}, n.url = e) : n = e || {}, n = me(this.defaults, n);
1470
1470
  const { transitional: s, paramsSerializer: i, headers: a } = n;
1471
1471
  s !== void 0 && $e.assertOptions(s, {
1472
1472
  silentJSONParsing: ce.transitional(ce.boolean),
@@ -1487,8 +1487,8 @@ let xe = class {
1487
1487
  );
1488
1488
  a && f.forEach(
1489
1489
  ["delete", "get", "head", "post", "put", "patch", "common"],
1490
- (p) => {
1491
- delete a[p];
1490
+ (u) => {
1491
+ delete a[u];
1492
1492
  }
1493
1493
  ), n.headers = re.concat(o, a);
1494
1494
  const c = [];
@@ -1496,46 +1496,46 @@ let xe = class {
1496
1496
  this.interceptors.request.forEach(function(w) {
1497
1497
  typeof w.runWhen == "function" && w.runWhen(n) === !1 || (d = d && w.synchronous, c.unshift(w.fulfilled, w.rejected));
1498
1498
  });
1499
- const u = [];
1499
+ const p = [];
1500
1500
  this.interceptors.response.forEach(function(w) {
1501
- u.push(w.fulfilled, w.rejected);
1501
+ p.push(w.fulfilled, w.rejected);
1502
1502
  });
1503
- let x, y = 0, E;
1503
+ let x, y = 0, k;
1504
1504
  if (!d) {
1505
- const p = [kt.bind(this), void 0];
1506
- for (p.unshift(...c), p.push(...u), E = p.length, x = Promise.resolve(n); y < E; )
1507
- x = x.then(p[y++], p[y++]);
1505
+ const u = [Et.bind(this), void 0];
1506
+ for (u.unshift(...c), u.push(...p), k = u.length, x = Promise.resolve(n); y < k; )
1507
+ x = x.then(u[y++], u[y++]);
1508
1508
  return x;
1509
1509
  }
1510
- E = c.length;
1511
- let k = n;
1512
- for (; y < E; ) {
1513
- const p = c[y++], w = c[y++];
1510
+ k = c.length;
1511
+ let E = n;
1512
+ for (; y < k; ) {
1513
+ const u = c[y++], w = c[y++];
1514
1514
  try {
1515
- k = p(k);
1515
+ E = u(E);
1516
1516
  } catch (h) {
1517
1517
  w.call(this, h);
1518
1518
  break;
1519
1519
  }
1520
1520
  }
1521
1521
  try {
1522
- x = kt.call(this, k);
1523
- } catch (p) {
1524
- return Promise.reject(p);
1522
+ x = Et.call(this, E);
1523
+ } catch (u) {
1524
+ return Promise.reject(u);
1525
1525
  }
1526
- for (y = 0, E = u.length; y < E; )
1527
- x = x.then(u[y++], u[y++]);
1526
+ for (y = 0, k = p.length; y < k; )
1527
+ x = x.then(p[y++], p[y++]);
1528
1528
  return x;
1529
1529
  }
1530
1530
  getUri(e) {
1531
- e = he(this.defaults, e);
1531
+ e = me(this.defaults, e);
1532
1532
  const n = Gt(e.baseURL, e.url, e.allowAbsoluteUrls);
1533
1533
  return Ht(n, e.params, e.paramsSerializer);
1534
1534
  }
1535
1535
  };
1536
1536
  f.forEach(["delete", "get", "head", "options"], function(e) {
1537
- xe.prototype[e] = function(n, s) {
1538
- return this.request(he(s || {}, {
1537
+ he.prototype[e] = function(n, s) {
1538
+ return this.request(me(s || {}, {
1539
1539
  method: e,
1540
1540
  url: n,
1541
1541
  data: (s || {}).data
@@ -1545,7 +1545,7 @@ f.forEach(["delete", "get", "head", "options"], function(e) {
1545
1545
  f.forEach(["post", "put", "patch"], function(e) {
1546
1546
  function n(s) {
1547
1547
  return function(a, o, c) {
1548
- return this.request(he(c || {}, {
1548
+ return this.request(me(c || {}, {
1549
1549
  method: e,
1550
1550
  headers: s ? {
1551
1551
  "Content-Type": "multipart/form-data"
@@ -1555,7 +1555,7 @@ f.forEach(["post", "put", "patch"], function(e) {
1555
1555
  }));
1556
1556
  };
1557
1557
  }
1558
- xe.prototype[e] = n(), xe.prototype[e + "Form"] = n(!0);
1558
+ he.prototype[e] = n(), he.prototype[e + "Form"] = n(!0);
1559
1559
  });
1560
1560
  let Dn = class tr {
1561
1561
  constructor(e) {
@@ -1707,13 +1707,13 @@ Object.entries(et).forEach(([t, e]) => {
1707
1707
  et[e] = t;
1708
1708
  });
1709
1709
  function rr(t) {
1710
- const e = new xe(t), n = At(xe.prototype.request, e);
1711
- return f.extend(n, xe.prototype, e, { allOwnKeys: !0 }), f.extend(n, e, null, { allOwnKeys: !0 }), n.create = function(i) {
1712
- return rr(he(t, i));
1710
+ const e = new he(t), n = At(he.prototype.request, e);
1711
+ return f.extend(n, he.prototype, e, { allOwnKeys: !0 }), f.extend(n, e, null, { allOwnKeys: !0 }), n.create = function(i) {
1712
+ return rr(me(t, i));
1713
1713
  }, n;
1714
1714
  }
1715
1715
  const J = rr(Oe);
1716
- J.Axios = xe;
1716
+ J.Axios = he;
1717
1717
  J.CanceledError = ve;
1718
1718
  J.CancelToken = Dn;
1719
1719
  J.isCancel = Jt;
@@ -1726,7 +1726,7 @@ J.all = function(e) {
1726
1726
  };
1727
1727
  J.spread = Nn;
1728
1728
  J.isAxiosError = Fn;
1729
- J.mergeConfig = he;
1729
+ J.mergeConfig = me;
1730
1730
  J.AxiosHeaders = re;
1731
1731
  J.formToJSON = (t) => Yt(f.isHTMLForm(t) ? new FormData(t) : t);
1732
1732
  J.getAdapter = Qt.getAdapter;
@@ -2275,7 +2275,7 @@ class li {
2275
2275
  );
2276
2276
  }
2277
2277
  }
2278
- var Ae = { exports: {} }, Ee = {};
2278
+ var Ae = { exports: {} }, ke = {};
2279
2279
  /**
2280
2280
  * @license React
2281
2281
  * react-jsx-runtime.production.js
@@ -2285,10 +2285,10 @@ var Ae = { exports: {} }, Ee = {};
2285
2285
  * This source code is licensed under the MIT license found in the
2286
2286
  * LICENSE file in the root directory of this source tree.
2287
2287
  */
2288
- var Ct;
2288
+ var Tt;
2289
2289
  function Ln() {
2290
- if (Ct) return Ee;
2291
- Ct = 1;
2290
+ if (Tt) return ke;
2291
+ Tt = 1;
2292
2292
  var t = Symbol.for("react.transitional.element"), e = Symbol.for("react.fragment");
2293
2293
  function n(s, i, a) {
2294
2294
  var o = null;
@@ -2305,9 +2305,9 @@ function Ln() {
2305
2305
  props: a
2306
2306
  };
2307
2307
  }
2308
- return Ee.Fragment = e, Ee.jsx = n, Ee.jsxs = n, Ee;
2308
+ return ke.Fragment = e, ke.jsx = n, ke.jsxs = n, ke;
2309
2309
  }
2310
- var ke = {};
2310
+ var Ee = {};
2311
2311
  /**
2312
2312
  * @license React
2313
2313
  * react-jsx-runtime.development.js
@@ -2328,7 +2328,7 @@ function qn() {
2328
2328
  switch (l) {
2329
2329
  case h:
2330
2330
  return "Fragment";
2331
- case T:
2331
+ case C:
2332
2332
  return "Profiler";
2333
2333
  case O:
2334
2334
  return "StrictMode";
@@ -2395,7 +2395,7 @@ function qn() {
2395
2395
  }
2396
2396
  }
2397
2397
  function i() {
2398
- var l = C.A;
2398
+ var l = T.A;
2399
2399
  return l === null ? null : l.getOwner();
2400
2400
  }
2401
2401
  function a() {
@@ -2426,10 +2426,10 @@ function qn() {
2426
2426
  "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."
2427
2427
  )), l = this.props.ref, l !== void 0 ? l : null;
2428
2428
  }
2429
- function u(l, m, S, D, ne, oe) {
2429
+ function p(l, m, S, D, ne, oe) {
2430
2430
  var B = S.ref;
2431
2431
  return l = {
2432
- $$typeof: p,
2432
+ $$typeof: u,
2433
2433
  type: l,
2434
2434
  key: m,
2435
2435
  props: S,
@@ -2498,7 +2498,7 @@ React keys must be passed directly to JSX without using spread:
2498
2498
  return B && c(
2499
2499
  S,
2500
2500
  typeof l == "function" ? l.displayName || l.name || "Unknown" : l
2501
- ), u(
2501
+ ), p(
2502
2502
  l,
2503
2503
  B,
2504
2504
  S,
@@ -2508,25 +2508,25 @@ React keys must be passed directly to JSX without using spread:
2508
2508
  );
2509
2509
  }
2510
2510
  function y(l) {
2511
- E(l) ? l._store && (l._store.validated = 1) : typeof l == "object" && l !== null && l.$$typeof === I && (l._payload.status === "fulfilled" ? E(l._payload.value) && l._payload.value._store && (l._payload.value._store.validated = 1) : l._store && (l._store.validated = 1));
2511
+ 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));
2512
2512
  }
2513
- function E(l) {
2514
- return typeof l == "object" && l !== null && l.$$typeof === p;
2513
+ function k(l) {
2514
+ return typeof l == "object" && l !== null && l.$$typeof === u;
2515
2515
  }
2516
- var k = Te, p = Symbol.for("react.transitional.element"), w = Symbol.for("react.portal"), h = Symbol.for("react.fragment"), O = Symbol.for("react.strict_mode"), T = 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"), C = k.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, G = Object.prototype.hasOwnProperty, R = Array.isArray, z = console.createTask ? console.createTask : function() {
2516
+ 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() {
2517
2517
  return null;
2518
2518
  };
2519
- k = {
2519
+ E = {
2520
2520
  react_stack_bottom_frame: function(l) {
2521
2521
  return l();
2522
2522
  }
2523
2523
  };
2524
- var M, K = {}, H = k.react_stack_bottom_frame.bind(
2525
- k,
2524
+ var M, K = {}, H = E.react_stack_bottom_frame.bind(
2525
+ E,
2526
2526
  a
2527
2527
  )(), F = z(s(a)), Y = {};
2528
- ke.Fragment = h, ke.jsx = function(l, m, S) {
2529
- var D = 1e4 > C.recentlyCreatedOwnerStacks++;
2528
+ Ee.Fragment = h, Ee.jsx = function(l, m, S) {
2529
+ var D = 1e4 > T.recentlyCreatedOwnerStacks++;
2530
2530
  return x(
2531
2531
  l,
2532
2532
  m,
@@ -2535,8 +2535,8 @@ React keys must be passed directly to JSX without using spread:
2535
2535
  D ? Error("react-stack-top-frame") : H,
2536
2536
  D ? z(s(l)) : F
2537
2537
  );
2538
- }, ke.jsxs = function(l, m, S) {
2539
- var D = 1e4 > C.recentlyCreatedOwnerStacks++;
2538
+ }, Ee.jsxs = function(l, m, S) {
2539
+ var D = 1e4 > T.recentlyCreatedOwnerStacks++;
2540
2540
  return x(
2541
2541
  l,
2542
2542
  m,
@@ -2546,7 +2546,7 @@ React keys must be passed directly to JSX without using spread:
2546
2546
  D ? z(s(l)) : F
2547
2547
  );
2548
2548
  };
2549
- })()), ke;
2549
+ })()), Ee;
2550
2550
  }
2551
2551
  var Pt;
2552
2552
  function Mn() {
@@ -2617,7 +2617,7 @@ const Yn = zt(
2617
2617
  ...c
2618
2618
  },
2619
2619
  [
2620
- ...o.map(([u, x]) => Ke(u, x)),
2620
+ ...o.map(([p, x]) => Ke(p, x)),
2621
2621
  ...Array.isArray(a) ? a : [a]
2622
2622
  ]
2623
2623
  )
@@ -2925,14 +2925,14 @@ const Ss = [
2925
2925
  key: "1a8usu"
2926
2926
  }
2927
2927
  ]
2928
- ], Es = L("pen-line", Ss);
2928
+ ], ks = L("pen-line", Ss);
2929
2929
  /**
2930
2930
  * @license lucide-react v0.544.0 - ISC
2931
2931
  *
2932
2932
  * This source code is licensed under the ISC license.
2933
2933
  * See the LICENSE file in the root directory of this source tree.
2934
2934
  */
2935
- const ks = [
2935
+ const Es = [
2936
2936
  [
2937
2937
  "path",
2938
2938
  {
@@ -2940,14 +2940,14 @@ const ks = [
2940
2940
  key: "9njp5v"
2941
2941
  }
2942
2942
  ]
2943
- ], Ts = L("phone", ks);
2943
+ ], Cs = L("phone", Es);
2944
2944
  /**
2945
2945
  * @license lucide-react v0.544.0 - ISC
2946
2946
  *
2947
2947
  * This source code is licensed under the ISC license.
2948
2948
  * See the LICENSE file in the root directory of this source tree.
2949
2949
  */
2950
- const Cs = [
2950
+ const Ts = [
2951
2951
  [
2952
2952
  "path",
2953
2953
  {
@@ -2957,7 +2957,7 @@ const Cs = [
2957
2957
  ],
2958
2958
  ["path", { d: "M17 21v-7a1 1 0 0 0-1-1H8a1 1 0 0 0-1 1v7", key: "1ydtos" }],
2959
2959
  ["path", { d: "M7 3v4a1 1 0 0 0 1 1h7", key: "t51u73" }]
2960
- ], Rs = L("save", Cs);
2960
+ ], Rs = L("save", Ts);
2961
2961
  /**
2962
2962
  * @license lucide-react v0.544.0 - ISC
2963
2963
  *
@@ -3069,7 +3069,7 @@ const Ns = [
3069
3069
  ], Ie = L("x", Ns), or = cr(null), ci = ({
3070
3070
  authix: t,
3071
3071
  children: e
3072
- }) => /* @__PURE__ */ r.jsx(or.Provider, { value: t, children: e }), me = () => {
3072
+ }) => /* @__PURE__ */ r.jsx(or.Provider, { value: t, children: e }), fe = () => {
3073
3073
  const t = dr(or);
3074
3074
  if (!t)
3075
3075
  throw new Error("useAuthix must be used inside <AuthixProvider />");
@@ -3086,20 +3086,20 @@ const Ns = [
3086
3086
  showAvatar: c = !1,
3087
3087
  roles: d = [],
3088
3088
  // 🔥 FIXED
3089
- showRoleSelector: u = !1,
3089
+ showRoleSelector: p = !1,
3090
3090
  // 🔥 FIXED
3091
3091
  loginUrl: x,
3092
3092
  onSuccess: y,
3093
- onError: E
3093
+ onError: k
3094
3094
  }) => {
3095
- const k = me(), p = {
3095
+ const E = fe(), u = {
3096
3096
  name: "",
3097
3097
  email: "",
3098
3098
  password: "",
3099
3099
  role: d.length ? d[0] : "user",
3100
3100
  ...c && { avatarUrl: "" }
3101
- }, [w, h] = P(p), [O, T] = P(!1), [g, A] = P(!1), [N, b] = P(null), [j, q] = P({}), [I, X] = P(!1), W = o ? "#ffffff" : "#111827", C = 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)";
3102
- Te.useEffect(() => {
3101
+ }, [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)";
3102
+ Ce.useEffect(() => {
3103
3103
  if (typeof window < "u") {
3104
3104
  const F = () => X(window.innerWidth < 768);
3105
3105
  return F(), window.addEventListener("resize", F), () => window.removeEventListener("resize", F);
@@ -3121,16 +3121,16 @@ const Ns = [
3121
3121
  password: w.password,
3122
3122
  role: w.role,
3123
3123
  ...w.avatarUrl ? { avatarUrl: w.avatarUrl } : {}
3124
- }, l = await k.signupUser(Y);
3124
+ }, l = await E.signupUser(Y);
3125
3125
  l.success ? (b({
3126
3126
  type: "success",
3127
3127
  text: l.message || "Account created successfully!"
3128
- }), y?.(l.user)) : (b({ type: "error", text: l.message || "Signup failed" }), E?.(l));
3128
+ }), y?.(l.user)) : (b({ type: "error", text: l.message || "Signup failed" }), k?.(l));
3129
3129
  } catch (Y) {
3130
3130
  b({
3131
3131
  type: "error",
3132
3132
  text: Y.message || "Signup failed. Please try again."
3133
- }), E?.(Y);
3133
+ }), k?.(Y);
3134
3134
  } finally {
3135
3135
  A(!1);
3136
3136
  }
@@ -3221,7 +3221,7 @@ const Ns = [
3221
3221
  {
3222
3222
  style: {
3223
3223
  fontSize: "14px",
3224
- color: C
3224
+ color: T
3225
3225
  },
3226
3226
  children: s
3227
3227
  }
@@ -3263,7 +3263,7 @@ const Ns = [
3263
3263
  onSubmit: K,
3264
3264
  style: { display: "flex", flexDirection: "column", gap: "14px" },
3265
3265
  children: [
3266
- u && d && d.length === 2 && /* @__PURE__ */ r.jsxs(
3266
+ p && d && d.length === 2 && /* @__PURE__ */ r.jsxs(
3267
3267
  "div",
3268
3268
  {
3269
3269
  style: { display: "flex", flexDirection: "column", gap: "4px" },
@@ -3385,7 +3385,7 @@ const Ns = [
3385
3385
  left: "14px",
3386
3386
  top: "50%",
3387
3387
  transform: "translateY(-50%)",
3388
- color: C
3388
+ color: T
3389
3389
  }
3390
3390
  }
3391
3391
  ),
@@ -3440,7 +3440,7 @@ const Ns = [
3440
3440
  left: "14px",
3441
3441
  top: "50%",
3442
3442
  transform: "translateY(-50%)",
3443
- color: C
3443
+ color: T
3444
3444
  }
3445
3445
  }
3446
3446
  ),
@@ -3495,7 +3495,7 @@ const Ns = [
3495
3495
  left: "14px",
3496
3496
  top: "50%",
3497
3497
  transform: "translateY(-50%)",
3498
- color: C
3498
+ color: T
3499
3499
  }
3500
3500
  }
3501
3501
  ),
@@ -3518,7 +3518,7 @@ const Ns = [
3518
3518
  "button",
3519
3519
  {
3520
3520
  type: "button",
3521
- onClick: () => T(!O),
3521
+ onClick: () => C(!O),
3522
3522
  style: {
3523
3523
  position: "absolute",
3524
3524
  right: "14px",
@@ -3526,7 +3526,7 @@ const Ns = [
3526
3526
  transform: "translateY(-50%)",
3527
3527
  background: "transparent",
3528
3528
  border: "none",
3529
- color: C,
3529
+ color: T,
3530
3530
  cursor: "pointer",
3531
3531
  padding: "4px"
3532
3532
  },
@@ -3573,7 +3573,7 @@ const Ns = [
3573
3573
  left: "14px",
3574
3574
  top: "50%",
3575
3575
  transform: "translateY(-50%)",
3576
- color: C
3576
+ color: T
3577
3577
  }
3578
3578
  }
3579
3579
  ),
@@ -3676,7 +3676,7 @@ const Ns = [
3676
3676
  style: {
3677
3677
  textAlign: "center",
3678
3678
  fontSize: "12px",
3679
- color: C,
3679
+ color: T,
3680
3680
  marginTop: "16px",
3681
3681
  padding: "0 4px"
3682
3682
  },
@@ -3709,21 +3709,21 @@ const Ns = [
3709
3709
  darkMode: o = !0,
3710
3710
  signupUrl: c,
3711
3711
  onSuccess: d,
3712
- onError: u
3712
+ onError: p
3713
3713
  }) => {
3714
- const x = me(), [y, E] = P("login"), [k, p] = P(1), [w, h] = P(!1), [O, T] = P(!1), [g, A] = P(null), [N, b] = P(""), [j, q] = P(""), [I, X] = P({
3714
+ const x = 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({
3715
3715
  email: "",
3716
3716
  otp: "",
3717
3717
  newPassword: ""
3718
- }), [W, C] = P(!1), G = o ? "#ffffff" : "#111827", R = o ? "#a1a1aa" : "#6b7280", z = o ? "rgba(255,255,255,0.05)" : "rgba(0,0,0,0.02)", M = o ? "rgba(255,255,255,0.1)" : "rgba(0,0,0,0.1)";
3719
- Te.useEffect(() => {
3718
+ }), [W, T] = P(!1), G = o ? "#ffffff" : "#111827", R = o ? "#a1a1aa" : "#6b7280", z = o ? "rgba(255,255,255,0.05)" : "rgba(0,0,0,0.02)", M = o ? "rgba(255,255,255,0.1)" : "rgba(0,0,0,0.1)";
3719
+ Ce.useEffect(() => {
3720
3720
  if (typeof window < "u") {
3721
- const m = () => C(window.innerWidth < 768);
3721
+ const m = () => T(window.innerWidth < 768);
3722
3722
  return m(), window.addEventListener("resize", m), () => window.removeEventListener("resize", m);
3723
3723
  }
3724
3724
  }, []);
3725
3725
  const K = async (m) => {
3726
- m.preventDefault(), T(!0), A(null);
3726
+ m.preventDefault(), C(!0), A(null);
3727
3727
  try {
3728
3728
  const S = await x.loginUser({ email: N, password: j }), { user: D } = S;
3729
3729
  if (!D)
@@ -3735,19 +3735,19 @@ const Ns = [
3735
3735
  A({ type: "success", text: `Welcome ${D.name}` }), d?.(D);
3736
3736
  } catch (S) {
3737
3737
  const D = S.message || "Login failed";
3738
- A({ type: "error", text: D }), u?.(S);
3738
+ A({ type: "error", text: D }), p?.(S);
3739
3739
  } finally {
3740
- T(!1);
3740
+ C(!1);
3741
3741
  }
3742
3742
  }, H = (m) => {
3743
3743
  X({ ...I, [m.target.name]: m.target.value });
3744
3744
  }, F = async (m) => {
3745
- m.preventDefault(), T(!0), A(null);
3745
+ m.preventDefault(), C(!0), A(null);
3746
3746
  try {
3747
3747
  const S = await x.requestResetUserPasswordOTP({
3748
3748
  email: I.email
3749
3749
  });
3750
- S.success ? (p(2), A({
3750
+ S.success ? (u(2), A({
3751
3751
  type: "success",
3752
3752
  text: S.message || "OTP sent to your email"
3753
3753
  })) : A({
@@ -3760,10 +3760,10 @@ const Ns = [
3760
3760
  text: S.message || "Something went wrong"
3761
3761
  });
3762
3762
  } finally {
3763
- T(!1);
3763
+ C(!1);
3764
3764
  }
3765
3765
  }, Y = async (m) => {
3766
- m.preventDefault(), T(!0), A(null);
3766
+ m.preventDefault(), C(!0), A(null);
3767
3767
  try {
3768
3768
  const S = await x.resetUserPassword({
3769
3769
  email: I.email,
@@ -3773,14 +3773,14 @@ const Ns = [
3773
3773
  S.success ? (A({
3774
3774
  type: "success",
3775
3775
  text: S.message || "Password reset successfully!"
3776
- }), p(1), X({ email: "", otp: "", newPassword: "" }), E("login")) : A({ type: "error", text: S.message || "Reset failed" });
3776
+ }), u(1), X({ email: "", otp: "", newPassword: "" }), k("login")) : A({ type: "error", text: S.message || "Reset failed" });
3777
3777
  } catch (S) {
3778
3778
  A({
3779
3779
  type: "error",
3780
3780
  text: S.message || "Something went wrong"
3781
3781
  });
3782
3782
  } finally {
3783
- T(!1);
3783
+ C(!1);
3784
3784
  }
3785
3785
  }, l = {
3786
3786
  width: "100%",
@@ -3858,7 +3858,7 @@ const Ns = [
3858
3858
  color: G,
3859
3859
  margin: 0
3860
3860
  },
3861
- children: y === "login" ? n : k === 1 ? "Forgot Password" : "Reset Password"
3861
+ children: y === "login" ? n : E === 1 ? "Forgot Password" : "Reset Password"
3862
3862
  }
3863
3863
  ),
3864
3864
  /* @__PURE__ */ r.jsx(
@@ -4016,7 +4016,7 @@ const Ns = [
4016
4016
  "button",
4017
4017
  {
4018
4018
  type: "button",
4019
- onClick: () => E("forgot"),
4019
+ onClick: () => k("forgot"),
4020
4020
  style: {
4021
4021
  background: "none",
4022
4022
  border: "none",
@@ -4053,10 +4053,10 @@ const Ns = [
4053
4053
  y === "forgot" && /* @__PURE__ */ r.jsxs(
4054
4054
  "form",
4055
4055
  {
4056
- onSubmit: k === 1 ? F : Y,
4056
+ onSubmit: E === 1 ? F : Y,
4057
4057
  style: { display: "flex", flexDirection: "column", gap: "14px" },
4058
4058
  children: [
4059
- k === 1 ? /* @__PURE__ */ r.jsxs(
4059
+ E === 1 ? /* @__PURE__ */ r.jsxs(
4060
4060
  "div",
4061
4061
  {
4062
4062
  style: { display: "flex", flexDirection: "column", gap: "4px" },
@@ -4220,7 +4220,7 @@ const Ns = [
4220
4220
  borderRadius: "10px",
4221
4221
  fontWeight: 600
4222
4222
  },
4223
- children: O ? "Please wait..." : k === 1 ? "Send Reset OTP" : "Reset Password"
4223
+ children: O ? "Please wait..." : E === 1 ? "Send Reset OTP" : "Reset Password"
4224
4224
  }
4225
4225
  ),
4226
4226
  /* @__PURE__ */ r.jsx(
@@ -4228,7 +4228,7 @@ const Ns = [
4228
4228
  {
4229
4229
  type: "button",
4230
4230
  onClick: () => {
4231
- E("login"), p(1);
4231
+ k("login"), u(1);
4232
4232
  },
4233
4233
  style: {
4234
4234
  background: "none",
@@ -4291,14 +4291,22 @@ const Ns = [
4291
4291
  children: t,
4292
4292
  fallback: e = null
4293
4293
  }) => {
4294
- const [n, s] = P(!1), [i, a] = P(null);
4295
- if (ee(() => {
4296
- s(!0);
4297
- const d = document.cookie.split(";").map((u) => u.trim()).find((u) => u.startsWith("a_s_b="));
4298
- a(d?.split("=")[1] === "true");
4299
- }, []), !n) return null;
4300
- const o = (c) => typeof c == "function" ? c() : c;
4301
- return i === null ? o(e) ?? null : i ? /* @__PURE__ */ r.jsx(r.Fragment, { children: t }) : o(e);
4294
+ const n = fe(), [s, i] = P("loading");
4295
+ ee(() => {
4296
+ (async () => {
4297
+ try {
4298
+ if (!(document.cookie.split(";").map((y) => y.trim()).find((y) => y.startsWith("a_s_b="))?.split("=")[1] === "true")) {
4299
+ i("unauthenticated");
4300
+ return;
4301
+ }
4302
+ (await n.checkUserSession())?.user?.id ? i("authenticated") : (document.cookie = "a_s_b=false; path=/; max-age=0; SameSite=Lax", i("unauthenticated"));
4303
+ } catch {
4304
+ document.cookie = "a_s_b=false; path=/; max-age=0; SameSite=Lax", i("unauthenticated");
4305
+ }
4306
+ })();
4307
+ }, [n]);
4308
+ const a = (o) => typeof o == "function" ? o() : o;
4309
+ return s === "loading" ? null : s === "unauthenticated" ? a(e) ?? null : /* @__PURE__ */ r.jsx(r.Fragment, { children: t });
4302
4310
  }, fi = ({
4303
4311
  children: t,
4304
4312
  fallback: e = null
@@ -4306,7 +4314,7 @@ const Ns = [
4306
4314
  const [n, s] = P(!1), [i, a] = P(null);
4307
4315
  if (ee(() => {
4308
4316
  s(!0);
4309
- const d = document.cookie.split(";").map((u) => u.trim()).find((u) => u.startsWith("a_s_b="));
4317
+ const d = document.cookie.split(";").map((p) => p.trim()).find((p) => p.startsWith("a_s_b="));
4310
4318
  a(d?.split("=")[1] !== "true");
4311
4319
  }, []), !n) return null;
4312
4320
  const o = (c) => typeof c == "function" ? c() : c;
@@ -4319,31 +4327,31 @@ const Ns = [
4319
4327
  userId: i,
4320
4328
  colors: a
4321
4329
  }) => {
4322
- const o = me(), [c, d] = P(!1), [u, x] = P(""), [y, E] = P("warning"), [k, p] = P(!1);
4330
+ const o = fe(), [c, d] = P(!1), [p, x] = P(""), [y, k] = P("warning"), [E, u] = P(!1);
4323
4331
  if (ee(() => {
4324
4332
  if (typeof window > "u") return;
4325
4333
  const g = () => {
4326
- p(window.innerWidth < 640);
4334
+ u(window.innerWidth < 640);
4327
4335
  };
4328
4336
  return g(), window.addEventListener("resize", g), () => window.removeEventListener("resize", g);
4329
4337
  }, []), !t) return null;
4330
4338
  const w = async () => {
4331
- d(!0), E("processing");
4339
+ d(!0), k("processing");
4332
4340
  try {
4333
4341
  const g = await o.deleteUser({
4334
4342
  userId: i
4335
4343
  });
4336
- g.success ? (n(g.message || "Account deleted successfully"), E("success"), setTimeout(() => {
4344
+ g.success ? (n(g.message || "Account deleted successfully"), k("success"), setTimeout(() => {
4337
4345
  localStorage.removeItem("userInfo"), localStorage.removeItem("userToken"), window.location.href = "/";
4338
- }, 2e3)) : (s(g.message || "Failed to delete account"), E("warning"));
4346
+ }, 2e3)) : (s(g.message || "Failed to delete account"), k("warning"));
4339
4347
  } catch (g) {
4340
- s(g.response?.data?.message || "Something went wrong"), E("warning");
4348
+ s(g.response?.data?.message || "Something went wrong"), k("warning");
4341
4349
  } finally {
4342
4350
  d(!1);
4343
4351
  }
4344
- }, h = u.toLowerCase() === "delete my account", O = (g) => {
4352
+ }, h = p.toLowerCase() === "delete my account", O = (g) => {
4345
4353
  g.target === g.currentTarget && y !== "processing" && y !== "success" && e();
4346
- }, T = () => {
4354
+ }, C = () => {
4347
4355
  switch (y) {
4348
4356
  case "warning":
4349
4357
  return /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
@@ -4521,7 +4529,7 @@ const Ns = [
4521
4529
  style: {
4522
4530
  display: "flex",
4523
4531
  gap: "12px",
4524
- flexDirection: k ? "column-reverse" : "row",
4532
+ flexDirection: E ? "column-reverse" : "row",
4525
4533
  justifyContent: "flex-end",
4526
4534
  alignItems: "stretch"
4527
4535
  },
@@ -4539,8 +4547,8 @@ const Ns = [
4539
4547
  fontSize: "14px",
4540
4548
  fontWeight: 500,
4541
4549
  cursor: "pointer",
4542
- flex: k ? "none" : 1,
4543
- minWidth: k ? "100%" : "120px",
4550
+ flex: E ? "none" : 1,
4551
+ minWidth: E ? "100%" : "120px",
4544
4552
  transition: "all 0.2s ease"
4545
4553
  },
4546
4554
  onMouseOver: (g) => {
@@ -4555,7 +4563,7 @@ const Ns = [
4555
4563
  /* @__PURE__ */ r.jsxs(
4556
4564
  "button",
4557
4565
  {
4558
- onClick: () => E("confirmation"),
4566
+ onClick: () => k("confirmation"),
4559
4567
  style: {
4560
4568
  padding: "10px 24px",
4561
4569
  borderRadius: "10px",
@@ -4565,8 +4573,8 @@ const Ns = [
4565
4573
  fontSize: "14px",
4566
4574
  fontWeight: 600,
4567
4575
  cursor: "pointer",
4568
- flex: k ? "none" : 1,
4569
- minWidth: k ? "100%" : "140px",
4576
+ flex: E ? "none" : 1,
4577
+ minWidth: E ? "100%" : "140px",
4570
4578
  display: "flex",
4571
4579
  alignItems: "center",
4572
4580
  justifyContent: "center",
@@ -4658,7 +4666,7 @@ const Ns = [
4658
4666
  "input",
4659
4667
  {
4660
4668
  type: "text",
4661
- value: u,
4669
+ value: p,
4662
4670
  onChange: (g) => x(g.target.value),
4663
4671
  placeholder: "delete my account",
4664
4672
  style: {
@@ -4716,7 +4724,7 @@ const Ns = [
4716
4724
  "button",
4717
4725
  {
4718
4726
  onClick: () => {
4719
- E("warning"), x("");
4727
+ k("warning"), x("");
4720
4728
  },
4721
4729
  style: {
4722
4730
  padding: "10px 24px",
@@ -4727,8 +4735,8 @@ const Ns = [
4727
4735
  fontSize: "14px",
4728
4736
  fontWeight: 500,
4729
4737
  cursor: "pointer",
4730
- flex: k ? "none" : 1,
4731
- minWidth: k ? "100%" : "120px",
4738
+ flex: E ? "none" : 1,
4739
+ minWidth: E ? "100%" : "120px",
4732
4740
  transition: "all 0.2s ease"
4733
4741
  },
4734
4742
  onMouseOver: (g) => {
@@ -4754,8 +4762,8 @@ const Ns = [
4754
4762
  fontSize: "14px",
4755
4763
  fontWeight: 600,
4756
4764
  cursor: !h || c ? "not-allowed" : "pointer",
4757
- flex: k ? "none" : 1,
4758
- minWidth: k ? "100%" : "140px",
4765
+ flex: E ? "none" : 1,
4766
+ minWidth: E ? "100%" : "140px",
4759
4767
  opacity: !h || c ? 0.6 : 1,
4760
4768
  display: "flex",
4761
4769
  alignItems: "center",
@@ -5101,7 +5109,7 @@ const Ns = [
5101
5109
  animation: "scaleIn 0.3s ease-out"
5102
5110
  },
5103
5111
  className: "delete-modal-container",
5104
- children: T()
5112
+ children: C()
5105
5113
  }
5106
5114
  ),
5107
5115
  /* @__PURE__ */ r.jsx("style", { children: `
@@ -5168,20 +5176,20 @@ const Ns = [
5168
5176
  onUpdate: n,
5169
5177
  colors: s
5170
5178
  }) => {
5171
- const [i, a] = P(""), [o, c] = P(!1), [d, u] = P(!1), [x, y] = P({ isValid: !1, message: "", type: null });
5179
+ const [i, a] = P(""), [o, c] = P(!1), [d, p] = P(!1), [x, y] = P({ isValid: !1, message: "", type: null });
5172
5180
  if (ee(() => {
5173
5181
  if (typeof window > "u") return;
5174
- const p = () => {
5175
- u(window.innerWidth < 640);
5182
+ const u = () => {
5183
+ p(window.innerWidth < 640);
5176
5184
  };
5177
- return p(), window.addEventListener("resize", p), () => window.removeEventListener("resize", p);
5185
+ return u(), window.addEventListener("resize", u), () => window.removeEventListener("resize", u);
5178
5186
  }, []), ee(() => {
5179
5187
  if (!i.trim()) {
5180
5188
  y({ isValid: !1, message: "", type: null });
5181
5189
  return;
5182
5190
  }
5183
5191
  try {
5184
- const p = new URL(i), w = /\.(jpg|jpeg|png|gif|webp|svg)$/i.test(p.pathname);
5192
+ const u = new URL(i), w = /\.(jpg|jpeg|png|gif|webp|svg)$/i.test(u.pathname);
5185
5193
  y(w ? {
5186
5194
  isValid: !0,
5187
5195
  message: "Valid image URL",
@@ -5199,7 +5207,7 @@ const Ns = [
5199
5207
  });
5200
5208
  }
5201
5209
  }, [i]), !t) return null;
5202
- const E = async () => {
5210
+ const k = async () => {
5203
5211
  if (!(!i || !x.isValid)) {
5204
5212
  c(!0);
5205
5213
  try {
@@ -5208,8 +5216,8 @@ const Ns = [
5208
5216
  c(!1);
5209
5217
  }
5210
5218
  }
5211
- }, k = (p) => {
5212
- p.target === p.currentTarget && e();
5219
+ }, E = (u) => {
5220
+ u.target === u.currentTarget && e();
5213
5221
  };
5214
5222
  return /* @__PURE__ */ r.jsxs(
5215
5223
  "div",
@@ -5225,7 +5233,7 @@ const Ns = [
5225
5233
  padding: "16px",
5226
5234
  zIndex: 1e3
5227
5235
  },
5228
- onClick: k,
5236
+ onClick: E,
5229
5237
  children: [
5230
5238
  /* @__PURE__ */ r.jsxs(
5231
5239
  "div",
@@ -5316,11 +5324,11 @@ const Ns = [
5316
5324
  flexShrink: 0,
5317
5325
  transition: "all 0.2s ease"
5318
5326
  },
5319
- onMouseOver: (p) => {
5320
- p.currentTarget.style.backgroundColor = s.border, p.currentTarget.style.color = s.textPrimary;
5327
+ onMouseOver: (u) => {
5328
+ u.currentTarget.style.backgroundColor = s.border, u.currentTarget.style.color = s.textPrimary;
5321
5329
  },
5322
- onMouseOut: (p) => {
5323
- p.currentTarget.style.backgroundColor = "transparent", p.currentTarget.style.color = s.textTertiary;
5330
+ onMouseOut: (u) => {
5331
+ u.currentTarget.style.backgroundColor = "transparent", u.currentTarget.style.color = s.textTertiary;
5324
5332
  },
5325
5333
  children: /* @__PURE__ */ r.jsx(Ie, { size: 20 })
5326
5334
  }
@@ -5365,7 +5373,7 @@ const Ns = [
5365
5373
  id: "avatar-url",
5366
5374
  placeholder: "https://example.com/your-avatar.jpg",
5367
5375
  value: i,
5368
- onChange: (p) => a(p.target.value),
5376
+ onChange: (u) => a(u.target.value),
5369
5377
  style: {
5370
5378
  width: "100%",
5371
5379
  padding: "14px 16px",
@@ -5379,11 +5387,11 @@ const Ns = [
5379
5387
  transition: "all 0.2s ease",
5380
5388
  boxSizing: "border-box"
5381
5389
  },
5382
- onFocus: (p) => {
5383
- p.target.style.borderColor = s.accent, p.target.style.boxShadow = `0 0 0 3px ${s.accent}20`;
5390
+ onFocus: (u) => {
5391
+ u.target.style.borderColor = s.accent, u.target.style.boxShadow = `0 0 0 3px ${s.accent}20`;
5384
5392
  },
5385
- onBlur: (p) => {
5386
- p.target.style.borderColor = x.type === "error" ? s.error : x.type === "success" ? s.success : s.border, p.target.style.boxShadow = "none";
5393
+ onBlur: (u) => {
5394
+ u.target.style.borderColor = x.type === "error" ? s.error : x.type === "success" ? s.success : s.border, u.target.style.boxShadow = "none";
5387
5395
  },
5388
5396
  disabled: o
5389
5397
  }
@@ -5458,8 +5466,8 @@ const Ns = [
5458
5466
  border: `2px solid ${s.success}40`,
5459
5467
  margin: "0 auto"
5460
5468
  },
5461
- onError: (p) => {
5462
- p.currentTarget.style.display = "none";
5469
+ onError: (u) => {
5470
+ u.currentTarget.style.display = "none";
5463
5471
  }
5464
5472
  }
5465
5473
  )
@@ -5500,11 +5508,11 @@ const Ns = [
5500
5508
  opacity: o ? 0.6 : 1,
5501
5509
  transition: "all 0.2s ease"
5502
5510
  },
5503
- onMouseOver: (p) => {
5504
- o || (p.currentTarget.style.backgroundColor = s.border, p.currentTarget.style.transform = "translateY(-1px)");
5511
+ onMouseOver: (u) => {
5512
+ o || (u.currentTarget.style.backgroundColor = s.border, u.currentTarget.style.transform = "translateY(-1px)");
5505
5513
  },
5506
- onMouseOut: (p) => {
5507
- o || (p.currentTarget.style.backgroundColor = "transparent", p.currentTarget.style.transform = "translateY(0)");
5514
+ onMouseOut: (u) => {
5515
+ o || (u.currentTarget.style.backgroundColor = "transparent", u.currentTarget.style.transform = "translateY(0)");
5508
5516
  },
5509
5517
  children: "Cancel"
5510
5518
  }
@@ -5512,7 +5520,7 @@ const Ns = [
5512
5520
  /* @__PURE__ */ r.jsx(
5513
5521
  "button",
5514
5522
  {
5515
- onClick: E,
5523
+ onClick: k,
5516
5524
  disabled: o || !x.isValid,
5517
5525
  style: {
5518
5526
  padding: "10px 24px",
@@ -5533,11 +5541,11 @@ const Ns = [
5533
5541
  transition: "all 0.2s ease",
5534
5542
  boxShadow: o || !x.isValid ? "none" : `0 4px 12px ${s.accent}40`
5535
5543
  },
5536
- onMouseOver: (p) => {
5537
- !o && x.isValid && (p.currentTarget.style.transform = "translateY(-1px)", p.currentTarget.style.boxShadow = `0 6px 20px ${s.accent}60`);
5544
+ onMouseOver: (u) => {
5545
+ !o && x.isValid && (u.currentTarget.style.transform = "translateY(-1px)", u.currentTarget.style.boxShadow = `0 6px 20px ${s.accent}60`);
5538
5546
  },
5539
- onMouseOut: (p) => {
5540
- !o && x.isValid && (p.currentTarget.style.transform = "translateY(0)", p.currentTarget.style.boxShadow = `0 4px 12px ${s.accent}40`);
5547
+ onMouseOut: (u) => {
5548
+ !o && x.isValid && (u.currentTarget.style.transform = "translateY(0)", u.currentTarget.style.boxShadow = `0 4px 12px ${s.accent}40`);
5541
5549
  },
5542
5550
  children: o ? /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
5543
5551
  /* @__PURE__ */ r.jsx(
@@ -5622,16 +5630,16 @@ const Ns = [
5622
5630
  userId: i,
5623
5631
  colors: a
5624
5632
  }) => {
5625
- const o = me(), [c, d] = P({
5633
+ const o = fe(), [c, d] = P({
5626
5634
  currentPassword: "",
5627
5635
  newPassword: "",
5628
5636
  confirmPassword: ""
5629
- }), [u, x] = P({}), [y, E] = P(!1), [k, p] = P({
5637
+ }), [p, x] = P({}), [y, k] = P(!1), [E, u] = P({
5630
5638
  currentPassword: !1,
5631
5639
  newPassword: !1,
5632
5640
  confirmPassword: !1
5633
5641
  }), [w, h] = P(!1);
5634
- if (Te.useEffect(() => {
5642
+ if (Ce.useEffect(() => {
5635
5643
  if (typeof window > "u") return;
5636
5644
  const b = () => {
5637
5645
  h(window.innerWidth < 640);
@@ -5640,15 +5648,15 @@ const Ns = [
5640
5648
  }, []), !t) return null;
5641
5649
  const O = (b) => {
5642
5650
  const { name: j, value: q } = b.target;
5643
- d((I) => ({ ...I, [j]: q })), u[j] && x((I) => ({ ...I, [j]: "" }));
5644
- }, T = (b) => {
5645
- p((j) => ({ ...j, [b]: !j[b] }));
5651
+ d((I) => ({ ...I, [j]: q })), p[j] && x((I) => ({ ...I, [j]: "" }));
5652
+ }, C = (b) => {
5653
+ u((j) => ({ ...j, [b]: !j[b] }));
5646
5654
  }, g = () => {
5647
5655
  const b = {};
5648
5656
  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"), x(b), Object.keys(b).length === 0;
5649
5657
  }, A = async (b) => {
5650
5658
  if (b.preventDefault(), !!g()) {
5651
- E(!0);
5659
+ k(!0);
5652
5660
  try {
5653
5661
  const { data: j } = await o.changePassword({
5654
5662
  currentPassword: c.currentPassword,
@@ -5663,7 +5671,7 @@ const Ns = [
5663
5671
  } catch (j) {
5664
5672
  s(j.response?.data?.message || "Something went wrong");
5665
5673
  } finally {
5666
- E(!1);
5674
+ k(!1);
5667
5675
  }
5668
5676
  }
5669
5677
  }, N = [
@@ -5840,7 +5848,7 @@ const Ns = [
5840
5848
  /* @__PURE__ */ r.jsx(
5841
5849
  "input",
5842
5850
  {
5843
- type: k[b] ? "text" : "password",
5851
+ type: E[b] ? "text" : "password",
5844
5852
  id: b,
5845
5853
  name: b,
5846
5854
  placeholder: `Enter ${j.toLowerCase()}`,
@@ -5850,7 +5858,7 @@ const Ns = [
5850
5858
  width: "100%",
5851
5859
  padding: "14px 48px 14px 44px",
5852
5860
  borderRadius: "10px",
5853
- border: `1.5px solid ${u[b] ? a.error : a.border}`,
5861
+ border: `1.5px solid ${p[b] ? a.error : a.border}`,
5854
5862
  backgroundColor: "transparent",
5855
5863
  color: a.textPrimary,
5856
5864
  fontSize: "15px",
@@ -5862,7 +5870,7 @@ const Ns = [
5862
5870
  I.target.style.borderColor = a.accent, I.target.style.boxShadow = `0 0 0 3px ${a.accent}20`;
5863
5871
  },
5864
5872
  onBlur: (I) => {
5865
- I.target.style.borderColor = u[b] ? a.error : a.border, I.target.style.boxShadow = "none";
5873
+ I.target.style.borderColor = p[b] ? a.error : a.border, I.target.style.boxShadow = "none";
5866
5874
  }
5867
5875
  }
5868
5876
  ),
@@ -5870,7 +5878,7 @@ const Ns = [
5870
5878
  "button",
5871
5879
  {
5872
5880
  type: "button",
5873
- onClick: () => T(b),
5881
+ onClick: () => C(b),
5874
5882
  style: {
5875
5883
  position: "absolute",
5876
5884
  right: "14px",
@@ -5894,11 +5902,11 @@ const Ns = [
5894
5902
  onMouseOut: (I) => {
5895
5903
  I.currentTarget.style.backgroundColor = "transparent", I.currentTarget.style.color = a.textTertiary;
5896
5904
  },
5897
- children: k[b] ? /* @__PURE__ */ r.jsx(it, { size: 18 }) : /* @__PURE__ */ r.jsx(at, { size: 18 })
5905
+ children: E[b] ? /* @__PURE__ */ r.jsx(it, { size: 18 }) : /* @__PURE__ */ r.jsx(at, { size: 18 })
5898
5906
  }
5899
5907
  )
5900
5908
  ] }),
5901
- u[b] && /* @__PURE__ */ r.jsxs(
5909
+ p[b] && /* @__PURE__ */ r.jsxs(
5902
5910
  "div",
5903
5911
  {
5904
5912
  style: {
@@ -5911,7 +5919,7 @@ const Ns = [
5911
5919
  },
5912
5920
  children: [
5913
5921
  /* @__PURE__ */ r.jsx("span", { style: { fontSize: "16px" }, children: "⚠" }),
5914
- u[b]
5922
+ p[b]
5915
5923
  ]
5916
5924
  }
5917
5925
  )
@@ -6061,7 +6069,7 @@ const Ns = [
6061
6069
  otpSent: o,
6062
6070
  verifying: c,
6063
6071
  user: d,
6064
- colors: u,
6072
+ colors: p,
6065
6073
  darkMode: x
6066
6074
  }) => {
6067
6075
  if (!t) return null;
@@ -6081,18 +6089,18 @@ const Ns = [
6081
6089
  {
6082
6090
  className: "verify-email-modal",
6083
6091
  style: {
6084
- backgroundColor: u.surface,
6085
- border: `1px solid ${u.border}`
6092
+ backgroundColor: p.surface,
6093
+ border: `1px solid ${p.border}`
6086
6094
  },
6087
6095
  children: [
6088
6096
  /* @__PURE__ */ r.jsxs("div", { className: "modal-header", children: [
6089
- /* @__PURE__ */ r.jsx("h3", { style: { color: u.textPrimary }, children: "Verify Your Email" }),
6097
+ /* @__PURE__ */ r.jsx("h3", { style: { color: p.textPrimary }, children: "Verify Your Email" }),
6090
6098
  /* @__PURE__ */ r.jsx(
6091
6099
  "button",
6092
6100
  {
6093
6101
  onClick: y,
6094
6102
  className: "close-btn",
6095
- style: { color: u.textTertiary },
6103
+ style: { color: p.textTertiary },
6096
6104
  "aria-label": "Close verification modal",
6097
6105
  children: /* @__PURE__ */ r.jsx(Ie, { size: 20, "aria-hidden": "true" })
6098
6106
  }
@@ -6100,13 +6108,13 @@ const Ns = [
6100
6108
  ] }),
6101
6109
  /* @__PURE__ */ r.jsxs("form", { className: "verify-form", onSubmit: n, children: [
6102
6110
  /* @__PURE__ */ r.jsxs("div", { className: "form-group", children: [
6103
- /* @__PURE__ */ r.jsx("label", { style: { color: u.textSecondary }, children: "Email" }),
6111
+ /* @__PURE__ */ r.jsx("label", { style: { color: p.textSecondary }, children: "Email" }),
6104
6112
  /* @__PURE__ */ r.jsxs("div", { className: "input-container", children: [
6105
6113
  /* @__PURE__ */ r.jsx(
6106
6114
  pe,
6107
6115
  {
6108
6116
  size: 18,
6109
- style: { color: u.textTertiary },
6117
+ style: { color: p.textTertiary },
6110
6118
  "aria-hidden": "true"
6111
6119
  }
6112
6120
  ),
@@ -6115,15 +6123,15 @@ const Ns = [
6115
6123
  {
6116
6124
  type: "email",
6117
6125
  value: i.email,
6118
- onChange: (E) => a((k) => ({
6119
- ...k,
6120
- email: E.target.value
6126
+ onChange: (k) => a((E) => ({
6127
+ ...E,
6128
+ email: k.target.value
6121
6129
  })),
6122
6130
  placeholder: "Enter your email",
6123
6131
  style: {
6124
- backgroundColor: u.surfaceLight,
6125
- color: u.textPrimary,
6126
- borderColor: u.border
6132
+ backgroundColor: p.surfaceLight,
6133
+ color: p.textPrimary,
6134
+ borderColor: p.border
6127
6135
  },
6128
6136
  required: !0,
6129
6137
  "aria-required": "true",
@@ -6133,13 +6141,13 @@ const Ns = [
6133
6141
  ] })
6134
6142
  ] }),
6135
6143
  o && /* @__PURE__ */ r.jsxs("div", { className: "form-group", children: [
6136
- /* @__PURE__ */ r.jsx("label", { style: { color: u.textSecondary }, children: "OTP" }),
6144
+ /* @__PURE__ */ r.jsx("label", { style: { color: p.textSecondary }, children: "OTP" }),
6137
6145
  /* @__PURE__ */ r.jsxs("div", { className: "input-container", children: [
6138
6146
  /* @__PURE__ */ r.jsx(
6139
6147
  ir,
6140
6148
  {
6141
6149
  size: 18,
6142
- style: { color: u.textTertiary },
6150
+ style: { color: p.textTertiary },
6143
6151
  "aria-hidden": "true"
6144
6152
  }
6145
6153
  ),
@@ -6148,15 +6156,15 @@ const Ns = [
6148
6156
  {
6149
6157
  type: "text",
6150
6158
  value: i.otp,
6151
- onChange: (E) => a((k) => ({
6152
- ...k,
6153
- otp: E.target.value
6159
+ onChange: (k) => a((E) => ({
6160
+ ...E,
6161
+ otp: k.target.value
6154
6162
  })),
6155
6163
  placeholder: "Enter OTP",
6156
6164
  style: {
6157
- backgroundColor: u.surfaceLight,
6158
- color: u.textPrimary,
6159
- borderColor: u.border
6165
+ backgroundColor: p.surfaceLight,
6166
+ color: p.textPrimary,
6167
+ borderColor: p.border
6160
6168
  },
6161
6169
  required: !0,
6162
6170
  "aria-required": "true",
@@ -6172,7 +6180,7 @@ const Ns = [
6172
6180
  disabled: c,
6173
6181
  className: "btn-primary",
6174
6182
  style: {
6175
- background: `linear-gradient(to right, ${u.accent}, ${u.accentHover})`,
6183
+ background: `linear-gradient(to right, ${p.accent}, ${p.accentHover})`,
6176
6184
  opacity: c ? 0.7 : 1
6177
6185
  },
6178
6186
  "aria-label": c ? "Verifying email" : "Verify email",
@@ -6189,7 +6197,7 @@ const Ns = [
6189
6197
  disabled: c,
6190
6198
  className: "btn-primary",
6191
6199
  style: {
6192
- background: `linear-gradient(to right, ${u.accent}, ${u.accentHover})`,
6200
+ background: `linear-gradient(to right, ${p.accent}, ${p.accentHover})`,
6193
6201
  opacity: c ? 0.7 : 1
6194
6202
  },
6195
6203
  "aria-label": c ? "Sending OTP" : "Send OTP",
@@ -6296,8 +6304,8 @@ const Ns = [
6296
6304
  }
6297
6305
 
6298
6306
  .input-container input:focus {
6299
- border-color: ${u.accent};
6300
- box-shadow: 0 0 0 3px ${u.accent}20;
6307
+ border-color: ${p.accent};
6308
+ box-shadow: 0 0 0 3px ${p.accent}20;
6301
6309
  }
6302
6310
 
6303
6311
  .modal-actions {
@@ -6361,7 +6369,7 @@ const Ns = [
6361
6369
  onVerify: s,
6362
6370
  primaryColor: i = "#00C212"
6363
6371
  }) => {
6364
- const a = me(), [o, c] = P(null), [d, u] = P(), [x, y] = P(!0), [E, k] = P(!1), [p, w] = P(!1), [h, O] = P(!1), [T, g] = P(!1), [A, N] = P(!1), [b, j] = P(!1), [q, I] = P(!1), [X, W] = P(!1), [C, G] = P(null), [R, z] = P(!1), [M, K] = P({
6372
+ const a = fe(), [o, c] = P(null), [d, p] = P(), [x, 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({
6365
6373
  email: "",
6366
6374
  otp: ""
6367
6375
  }), [H, F] = P(!1), [Y, l] = P(!1);
@@ -6429,7 +6437,7 @@ const Ns = [
6429
6437
  if (V) {
6430
6438
  m("success", Z || "Email verified!");
6431
6439
  const de = { ...d, isVerified: !0 };
6432
- u(de), typeof s == "function" && s(de), K({ email: de.email, otp: "" }), F(!1), j?.(!1);
6440
+ p(de), typeof s == "function" && s(de), K({ email: de.email, otp: "" }), F(!1), j?.(!1);
6433
6441
  } else
6434
6442
  m("error", Z || "Verification failed");
6435
6443
  } catch (U) {
@@ -6453,7 +6461,7 @@ const Ns = [
6453
6461
  // 🔁 merge backend response if present
6454
6462
  avatarUrl: v
6455
6463
  };
6456
- return u(V), m("success", "Avatar updated successfully!"), !0;
6464
+ return p(V), m("success", "Avatar updated successfully!"), !0;
6457
6465
  }
6458
6466
  return m("error", U?.message || "Failed to update avatar"), !1;
6459
6467
  } catch (U) {
@@ -6475,10 +6483,10 @@ const Ns = [
6475
6483
  // overwrite updated fields
6476
6484
  isVerified: V ? !1 : d.isVerified
6477
6485
  };
6478
- u(Z), localStorage.setItem("userInfo", JSON.stringify(Z)), m(
6486
+ p(Z), localStorage.setItem("userInfo", JSON.stringify(Z)), m(
6479
6487
  "success",
6480
6488
  V ? "Email updated. Please verify your new email." : "Profile updated successfully"
6481
- ), k(!1);
6489
+ ), E(!1);
6482
6490
  } else
6483
6491
  m("error", U.message || "Update failed");
6484
6492
  } catch (v) {
@@ -6490,7 +6498,7 @@ const Ns = [
6490
6498
  }, le = async (v) => {
6491
6499
  try {
6492
6500
  const U = await a.checkIfUserExists(v);
6493
- U?.success === !0 && U?.exists === !1 && (console.warn("❌ User does not exist on server. Clearing session..."), localStorage.removeItem("userInfo"), u(null));
6501
+ U?.success === !0 && U?.exists === !1 && (console.warn("❌ User does not exist on server. Clearing session..."), localStorage.removeItem("userInfo"), p(null));
6494
6502
  } catch (U) {
6495
6503
  console.error("⚠️ User validation request failed:", U);
6496
6504
  }
@@ -6504,13 +6512,13 @@ const Ns = [
6504
6512
  const V = U.user.id, Z = await a.getUserProfile({ userId: V });
6505
6513
  if (Z.user) {
6506
6514
  const de = Z.user;
6507
- u(de), le(V);
6515
+ p(de), le(V);
6508
6516
  } else
6509
- u(null), localStorage.removeItem("userInfo");
6517
+ p(null), localStorage.removeItem("userInfo");
6510
6518
  } else
6511
- u(null), localStorage.removeItem("userInfo");
6519
+ p(null), localStorage.removeItem("userInfo");
6512
6520
  } catch (U) {
6513
- console.error("User init failed:", U), u(null), localStorage.removeItem("userInfo");
6521
+ console.error("User init failed:", U), p(null), localStorage.removeItem("userInfo");
6514
6522
  } finally {
6515
6523
  y(!1);
6516
6524
  }
@@ -6640,7 +6648,7 @@ const Ns = [
6640
6648
  value: d.phone || "Not set",
6641
6649
  name: "phone",
6642
6650
  type: "tel",
6643
- icon: Ts
6651
+ icon: Cs
6644
6652
  },
6645
6653
  {
6646
6654
  label: "Address",
@@ -6664,7 +6672,7 @@ const Ns = [
6664
6672
  minHeight: "80vh"
6665
6673
  },
6666
6674
  children: [
6667
- C && /* @__PURE__ */ r.jsxs(
6675
+ T && /* @__PURE__ */ r.jsxs(
6668
6676
  "div",
6669
6677
  {
6670
6678
  style: {
@@ -6684,7 +6692,7 @@ const Ns = [
6684
6692
  fontWeight: 500,
6685
6693
  maxWidth: "400px",
6686
6694
  animation: "slideIn 0.3s ease-out",
6687
- ...C.type === "success" ? {
6695
+ ...T.type === "success" ? {
6688
6696
  backgroundColor: t ? "rgba(16, 185, 129, 0.1)" : "rgba(16, 185, 129, 0.05)",
6689
6697
  borderColor: t ? "rgba(16, 185, 129, 0.3)" : "rgba(16, 185, 129, 0.2)",
6690
6698
  color: t ? "#34d399" : "#059669"
@@ -6697,8 +6705,8 @@ const Ns = [
6697
6705
  role: "alert",
6698
6706
  "aria-live": "polite",
6699
6707
  children: [
6700
- C.type === "success" ? /* @__PURE__ */ r.jsx(ue, { size: 20, "aria-hidden": "true" }) : /* @__PURE__ */ r.jsx(se, { size: 20, "aria-hidden": "true" }),
6701
- C.message
6708
+ T.type === "success" ? /* @__PURE__ */ r.jsx(ue, { size: 20, "aria-hidden": "true" }) : /* @__PURE__ */ r.jsx(se, { size: 20, "aria-hidden": "true" }),
6709
+ T.message
6702
6710
  ]
6703
6711
  }
6704
6712
  ),
@@ -6888,11 +6896,11 @@ const Ns = [
6888
6896
  flexDirection: "column",
6889
6897
  gap: "6px"
6890
6898
  },
6891
- children: E ? /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
6899
+ children: k ? /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
6892
6900
  /* @__PURE__ */ r.jsxs(
6893
6901
  "button",
6894
6902
  {
6895
- onClick: () => k(!1),
6903
+ onClick: () => E(!1),
6896
6904
  style: {
6897
6905
  backgroundColor: _.surfaceLight,
6898
6906
  border: `1px solid ${_.border}`,
@@ -6922,15 +6930,15 @@ const Ns = [
6922
6930
  "button",
6923
6931
  {
6924
6932
  onClick: B,
6925
- disabled: p,
6933
+ disabled: u,
6926
6934
  style: {
6927
6935
  background: `linear-gradient(to right, ${_.accent}, ${_.accentHover})`,
6928
- opacity: p ? 0.7 : 1,
6936
+ opacity: u ? 0.7 : 1,
6929
6937
  color: "white",
6930
6938
  padding: "10px 20px",
6931
6939
  borderRadius: "6px",
6932
6940
  border: "none",
6933
- cursor: p ? "not-allowed" : "pointer",
6941
+ cursor: u ? "not-allowed" : "pointer",
6934
6942
  transition: "all 0.2s ease",
6935
6943
  fontSize: "12px",
6936
6944
  fontWeight: 500,
@@ -6943,7 +6951,7 @@ const Ns = [
6943
6951
  flex: o && window.innerWidth < 1024 ? "1" : "auto"
6944
6952
  },
6945
6953
  children: [
6946
- p ? /* @__PURE__ */ r.jsx(
6954
+ u ? /* @__PURE__ */ r.jsx(
6947
6955
  ie,
6948
6956
  {
6949
6957
  size: 16,
@@ -6951,7 +6959,7 @@ const Ns = [
6951
6959
  "aria-hidden": "true"
6952
6960
  }
6953
6961
  ) : /* @__PURE__ */ r.jsx(Rs, { size: 16, "aria-hidden": "true" }),
6954
- p ? "Saving..." : "Save Changes"
6962
+ u ? "Saving..." : "Save Changes"
6955
6963
  ]
6956
6964
  }
6957
6965
  )
@@ -6959,7 +6967,7 @@ const Ns = [
6959
6967
  /* @__PURE__ */ r.jsxs(
6960
6968
  "button",
6961
6969
  {
6962
- onClick: () => k(!0),
6970
+ onClick: () => E(!0),
6963
6971
  style: {
6964
6972
  background: `linear-gradient(to right, ${_.accent}, ${_.accentHover})`,
6965
6973
  color: "white",
@@ -6979,7 +6987,7 @@ const Ns = [
6979
6987
  flex: o && window.innerWidth < 1024 ? "1" : "auto"
6980
6988
  },
6981
6989
  children: [
6982
- /* @__PURE__ */ r.jsx(Es, { size: 16, "aria-hidden": "true" }),
6990
+ /* @__PURE__ */ r.jsx(ks, { size: 16, "aria-hidden": "true" }),
6983
6991
  "Edit Profile"
6984
6992
  ]
6985
6993
  }
@@ -7249,13 +7257,13 @@ const Ns = [
7249
7257
  ]
7250
7258
  }
7251
7259
  ),
7252
- E ? /* @__PURE__ */ r.jsx(
7260
+ k ? /* @__PURE__ */ r.jsx(
7253
7261
  "input",
7254
7262
  {
7255
7263
  type: v.type,
7256
7264
  name: v.name,
7257
7265
  value: d[v.name],
7258
- onChange: (V) => u(
7266
+ onChange: (V) => p(
7259
7267
  (Z) => Z && { ...Z, [V.target.name]: V.target.value }
7260
7268
  ),
7261
7269
  style: {
@@ -7447,7 +7455,7 @@ const Ns = [
7447
7455
  qs,
7448
7456
  {
7449
7457
  userId: d.id,
7450
- isOpen: T,
7458
+ isOpen: C,
7451
7459
  onClose: () => g(!1),
7452
7460
  onSuccess: (v) => m("success", v),
7453
7461
  onError: (v) => m("error", v),
@@ -7587,15 +7595,15 @@ const Ns = [
7587
7595
  settingsUrl: c,
7588
7596
  // Menu item visibility with defaults
7589
7597
  showProfileMenuItem: d = !0,
7590
- showSettingsMenuItem: u = !0,
7598
+ showSettingsMenuItem: p = !0,
7591
7599
  showViewProfileMenuItem: x = !0,
7592
7600
  // Custom labels with defaults
7593
7601
  profileLabel: y = "My Profile",
7594
- settingsLabel: E = "Settings",
7595
- viewProfileLabel: k = "View Profile",
7596
- logoutLabel: p = "Sign Out"
7602
+ settingsLabel: k = "Settings",
7603
+ viewProfileLabel: E = "View Profile",
7604
+ logoutLabel: u = "Sign Out"
7597
7605
  }) => {
7598
- const w = me(), [h, O] = P(!1), [T, g] = P(null), [A, N] = P(!0), [b, j] = P(null), q = dt(null), I = dt(null), [X, W] = P(!1), [C, G] = P(!1);
7606
+ 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);
7599
7607
  ee(() => {
7600
7608
  if (typeof window > "u") return;
7601
7609
  const l = () => {
@@ -7689,19 +7697,19 @@ const Ns = [
7689
7697
  avatarButton: {
7690
7698
  display: "flex",
7691
7699
  alignItems: "center",
7692
- gap: C ? "6px" : "8px",
7693
- padding: C ? "6px 10px 6px 6px" : "8px 12px 8px 8px",
7700
+ gap: T ? "6px" : "8px",
7701
+ padding: T ? "6px 10px 6px 6px" : "8px 12px 8px 8px",
7694
7702
  borderRadius: "24px",
7695
7703
  backgroundColor: R.surface,
7696
7704
  cursor: "pointer",
7697
7705
  transition: "all 0.2s cubic-bezier(0.4, 0, 0.2, 1)",
7698
- minWidth: C ? "auto" : "140px",
7699
- maxWidth: C ? "200px" : "none",
7706
+ minWidth: T ? "auto" : "140px",
7707
+ maxWidth: T ? "200px" : "none",
7700
7708
  outline: "none"
7701
7709
  },
7702
7710
  avatarImage: {
7703
- width: C ? "28px" : "32px",
7704
- height: C ? "28px" : "32px",
7711
+ width: T ? "28px" : "32px",
7712
+ height: T ? "28px" : "32px",
7705
7713
  borderRadius: "50%",
7706
7714
  objectFit: "cover",
7707
7715
  border: `2px solid ${R.borderLight}`,
@@ -7716,23 +7724,23 @@ const Ns = [
7716
7724
  overflow: "hidden"
7717
7725
  },
7718
7726
  userName: {
7719
- fontSize: C ? "13px" : "14px",
7727
+ fontSize: T ? "13px" : "14px",
7720
7728
  fontWeight: 600,
7721
7729
  color: R.textPrimary,
7722
7730
  lineHeight: "1.2",
7723
7731
  whiteSpace: "nowrap",
7724
7732
  overflow: "hidden",
7725
7733
  textOverflow: "ellipsis",
7726
- maxWidth: C ? "80px" : "120px"
7734
+ maxWidth: T ? "80px" : "120px"
7727
7735
  },
7728
7736
  userEmail: {
7729
- fontSize: C ? "11px" : "12px",
7737
+ fontSize: T ? "11px" : "12px",
7730
7738
  color: R.textTertiary,
7731
7739
  lineHeight: "1.2",
7732
7740
  whiteSpace: "nowrap",
7733
7741
  overflow: "hidden",
7734
7742
  textOverflow: "ellipsis",
7735
- maxWidth: C ? "80px" : "120px"
7743
+ maxWidth: T ? "80px" : "120px"
7736
7744
  },
7737
7745
  chevron: {
7738
7746
  transition: "transform 0.2s ease",
@@ -7761,7 +7769,7 @@ const Ns = [
7761
7769
  overflow: "hidden"
7762
7770
  },
7763
7771
  dropdownSection: {
7764
- padding: C ? "10px 12px" : "0px 16px",
7772
+ padding: T ? "10px 12px" : "0px 16px",
7765
7773
  "&:last-child": {
7766
7774
  borderBottom: "none"
7767
7775
  }
@@ -7769,12 +7777,12 @@ const Ns = [
7769
7777
  userSection: {
7770
7778
  display: "flex",
7771
7779
  alignItems: "center",
7772
- gap: C ? "10px" : "12px",
7773
- padding: C ? "14px" : "16px"
7780
+ gap: T ? "10px" : "12px",
7781
+ padding: T ? "14px" : "16px"
7774
7782
  },
7775
7783
  dropdownAvatar: {
7776
- width: C ? "40px" : "48px",
7777
- height: C ? "40px" : "48px",
7784
+ width: T ? "40px" : "48px",
7785
+ height: T ? "40px" : "48px",
7778
7786
  borderRadius: "50%",
7779
7787
  objectFit: "cover",
7780
7788
  border: `2px solid ${R.borderLight}`,
@@ -7787,7 +7795,7 @@ const Ns = [
7787
7795
  minWidth: 0
7788
7796
  },
7789
7797
  dropdownUserName: {
7790
- fontSize: C ? "15px" : "16px",
7798
+ fontSize: T ? "15px" : "16px",
7791
7799
  fontWeight: 600,
7792
7800
  color: R.textPrimary,
7793
7801
  lineHeight: "1.2",
@@ -7796,7 +7804,7 @@ const Ns = [
7796
7804
  textOverflow: "ellipsis"
7797
7805
  },
7798
7806
  dropdownUserEmail: {
7799
- fontSize: C ? "13px" : "14px",
7807
+ fontSize: T ? "13px" : "14px",
7800
7808
  color: R.textSecondary,
7801
7809
  lineHeight: "1.2",
7802
7810
  overflow: "hidden",
@@ -7805,8 +7813,8 @@ const Ns = [
7805
7813
  menuItem: {
7806
7814
  display: "flex",
7807
7815
  alignItems: "center",
7808
- gap: C ? "10px" : "12px",
7809
- padding: C ? "10px 12px" : "12px 16px",
7816
+ gap: T ? "10px" : "12px",
7817
+ padding: T ? "10px 12px" : "12px 16px",
7810
7818
  borderRadius: "8px",
7811
7819
  cursor: "pointer",
7812
7820
  transition: "all 0.15s ease",
@@ -7815,7 +7823,7 @@ const Ns = [
7815
7823
  border: "none",
7816
7824
  background: "none",
7817
7825
  width: "100%",
7818
- fontSize: C ? "13px" : "14px",
7826
+ fontSize: T ? "13px" : "14px",
7819
7827
  textAlign: "left",
7820
7828
  outline: "none"
7821
7829
  },
@@ -7823,38 +7831,38 @@ const Ns = [
7823
7831
  flex: 1
7824
7832
  },
7825
7833
  icon: {
7826
- width: C ? "16px" : "18px",
7827
- height: C ? "16px" : "18px",
7834
+ width: T ? "16px" : "18px",
7835
+ height: T ? "16px" : "18px",
7828
7836
  color: R.textSecondary,
7829
7837
  flexShrink: 0
7830
7838
  },
7831
7839
  logoutButton: {
7832
7840
  display: "flex",
7833
7841
  alignItems: "center",
7834
- gap: C ? "10px" : "12px",
7835
- padding: C ? "10px 12px" : "12px 16px",
7842
+ gap: T ? "10px" : "12px",
7843
+ padding: T ? "10px 12px" : "12px 16px",
7836
7844
  borderRadius: "8px",
7837
7845
  cursor: "pointer",
7838
7846
  transition: "all 0.15s ease",
7839
7847
  background: "none",
7840
7848
  border: "none",
7841
7849
  width: "100%",
7842
- fontSize: C ? "13px" : "14px",
7850
+ fontSize: T ? "13px" : "14px",
7843
7851
  color: R.error,
7844
7852
  textAlign: "left",
7845
7853
  outline: "none"
7846
7854
  },
7847
7855
  loadingText: {
7848
- padding: C ? "16px 12px" : "20px 16px",
7856
+ padding: T ? "16px 12px" : "20px 16px",
7849
7857
  textAlign: "center",
7850
7858
  color: R.textSecondary,
7851
- fontSize: C ? "13px" : "14px"
7859
+ fontSize: T ? "13px" : "14px"
7852
7860
  },
7853
7861
  errorState: {
7854
- padding: C ? "16px 12px" : "20px 16px",
7862
+ padding: T ? "16px 12px" : "20px 16px",
7855
7863
  textAlign: "center",
7856
7864
  color: R.textSecondary,
7857
- fontSize: C ? "13px" : "14px",
7865
+ fontSize: T ? "13px" : "14px",
7858
7866
  display: "flex",
7859
7867
  alignItems: "center",
7860
7868
  justifyContent: "center",
@@ -7901,7 +7909,7 @@ const Ns = [
7901
7909
  }
7902
7910
  }, K = (l, m) => {
7903
7911
  (l.key === "Enter" || l.key === " ") && (l.preventDefault(), m());
7904
- }, H = () => o || T?.profileUrl, F = () => {
7912
+ }, H = () => o || C?.profileUrl, F = () => {
7905
7913
  const l = H();
7906
7914
  l && window.open(l, "_self", "noopener,noreferrer");
7907
7915
  }, Y = () => {
@@ -7927,14 +7935,14 @@ const Ns = [
7927
7935
  "aria-haspopup": "true",
7928
7936
  "aria-expanded": h,
7929
7937
  "aria-label": "Toggle user menu",
7930
- children: T?.avatarUrl ? /* @__PURE__ */ r.jsx(
7938
+ children: C?.avatarUrl ? /* @__PURE__ */ r.jsx(
7931
7939
  "img",
7932
7940
  {
7933
- src: T.avatarUrl,
7934
- alt: `${T?.name || "User"}'s avatar`,
7941
+ src: C.avatarUrl,
7942
+ alt: `${C?.name || "User"}'s avatar`,
7935
7943
  style: {
7936
- width: C ? "34px" : "36px",
7937
- height: C ? "34px" : "36px",
7944
+ width: T ? "34px" : "36px",
7945
+ height: T ? "34px" : "36px",
7938
7946
  borderRadius: "50%",
7939
7947
  objectFit: "cover",
7940
7948
  border: `2px solid ${R.borderLight}`,
@@ -7944,7 +7952,7 @@ const Ns = [
7944
7952
  onError: (l) => {
7945
7953
  const m = l.target;
7946
7954
  m.onerror = null, m.src = `https://api.dicebear.com/9.x/initials/svg?seed=${encodeURIComponent(
7947
- T?.name || "User"
7955
+ C?.name || "User"
7948
7956
  )}`;
7949
7957
  }
7950
7958
  }
@@ -7952,12 +7960,12 @@ const Ns = [
7952
7960
  "img",
7953
7961
  {
7954
7962
  src: `https://api.dicebear.com/9.x/initials/svg?seed=${encodeURIComponent(
7955
- T?.name || "User"
7963
+ C?.name || "User"
7956
7964
  )}`,
7957
7965
  alt: "Default user avatar",
7958
7966
  style: {
7959
- width: C ? "34px" : "40px",
7960
- height: C ? "34px" : "40px",
7967
+ width: T ? "34px" : "40px",
7968
+ height: T ? "34px" : "40px",
7961
7969
  borderRadius: "50%",
7962
7970
  objectFit: "cover",
7963
7971
  border: `2px solid ${R.borderLight}`,
@@ -7989,11 +7997,11 @@ const Ns = [
7989
7997
  l.currentTarget.style.outline = "none";
7990
7998
  },
7991
7999
  children: [
7992
- T?.avatarUrl ? /* @__PURE__ */ r.jsx(
8000
+ C?.avatarUrl ? /* @__PURE__ */ r.jsx(
7993
8001
  "img",
7994
8002
  {
7995
- src: T.avatarUrl,
7996
- alt: `${T.name}'s avatar`,
8003
+ src: C.avatarUrl,
8004
+ alt: `${C.name}'s avatar`,
7997
8005
  style: z.avatarImage,
7998
8006
  loading: "lazy",
7999
8007
  onError: (l) => {
@@ -8010,14 +8018,14 @@ const Ns = [
8010
8018
  loading: "lazy"
8011
8019
  }
8012
8020
  ),
8013
- !C && /* @__PURE__ */ r.jsxs("div", { style: z.userInfo, children: [
8014
- /* @__PURE__ */ r.jsx("div", { style: z.userName, title: T?.name, children: T?.name || "Guest" }),
8015
- T?.email && /* @__PURE__ */ r.jsx("div", { style: z.userEmail, title: T.email, children: T.email })
8021
+ !T && /* @__PURE__ */ r.jsxs("div", { style: z.userInfo, children: [
8022
+ /* @__PURE__ */ r.jsx("div", { style: z.userName, title: C?.name, children: C?.name || "Guest" }),
8023
+ C?.email && /* @__PURE__ */ r.jsx("div", { style: z.userEmail, title: C.email, children: C.email })
8016
8024
  ] }),
8017
8025
  /* @__PURE__ */ r.jsx(
8018
8026
  Zn,
8019
8027
  {
8020
- size: C ? 14 : 16,
8028
+ size: T ? 14 : 16,
8021
8029
  style: z.chevron,
8022
8030
  "aria-hidden": "true"
8023
8031
  }
@@ -8025,32 +8033,32 @@ const Ns = [
8025
8033
  ]
8026
8034
  }
8027
8035
  ),
8028
- h && /* @__PURE__ */ r.jsx("div", { style: z.dropdown, role: "menu", "aria-label": "User options", children: A ? /* @__PURE__ */ r.jsx("div", { style: z.loadingText, role: "status", "aria-live": "polite", children: "Loading user information..." }) : T ? /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
8036
+ h && /* @__PURE__ */ r.jsx("div", { style: z.dropdown, role: "menu", "aria-label": "User options", children: A ? /* @__PURE__ */ r.jsx("div", { style: z.loadingText, role: "status", "aria-live": "polite", children: "Loading user information..." }) : C ? /* @__PURE__ */ r.jsxs(r.Fragment, { children: [
8029
8037
  /* @__PURE__ */ r.jsxs("div", { style: z.userSection, children: [
8030
- T?.avatarUrl ? /* @__PURE__ */ r.jsx(
8038
+ C?.avatarUrl ? /* @__PURE__ */ r.jsx(
8031
8039
  "img",
8032
8040
  {
8033
- src: T.avatarUrl,
8034
- alt: `${T.name}'s profile picture`,
8041
+ src: C.avatarUrl,
8042
+ alt: `${C.name}'s profile picture`,
8035
8043
  style: z.dropdownAvatar,
8036
8044
  loading: "lazy",
8037
8045
  onError: (l) => {
8038
8046
  const m = l.target;
8039
- m.src = `https://api.dicebear.com/9.x/initials/svg?seed=${T.name}`;
8047
+ m.src = `https://api.dicebear.com/9.x/initials/svg?seed=${C.name}`;
8040
8048
  }
8041
8049
  }
8042
8050
  ) : /* @__PURE__ */ r.jsx(
8043
8051
  "img",
8044
8052
  {
8045
- src: `https://api.dicebear.com/9.x/initials/svg?seed=${T.name}`,
8046
- alt: `${T.name}'s default avatar`,
8053
+ src: `https://api.dicebear.com/9.x/initials/svg?seed=${C.name}`,
8054
+ alt: `${C.name}'s default avatar`,
8047
8055
  style: z.dropdownAvatar,
8048
8056
  loading: "lazy"
8049
8057
  }
8050
8058
  ),
8051
8059
  /* @__PURE__ */ r.jsxs("div", { style: z.dropdownUserInfo, children: [
8052
- /* @__PURE__ */ r.jsx("div", { style: z.dropdownUserName, title: T.name, children: T.name }),
8053
- /* @__PURE__ */ r.jsx("div", { style: z.dropdownUserEmail, title: T.email, children: T.email })
8060
+ /* @__PURE__ */ r.jsx("div", { style: z.dropdownUserName, title: C.name, children: C.name }),
8061
+ /* @__PURE__ */ r.jsx("div", { style: z.dropdownUserEmail, title: C.email, children: C.email })
8054
8062
  ] })
8055
8063
  ] }),
8056
8064
  /* @__PURE__ */ r.jsxs("div", { style: z.dropdownSection, children: [
@@ -8074,7 +8082,7 @@ const Ns = [
8074
8082
  ]
8075
8083
  }
8076
8084
  ),
8077
- u && c && /* @__PURE__ */ r.jsxs(
8085
+ p && c && /* @__PURE__ */ r.jsxs(
8078
8086
  "button",
8079
8087
  {
8080
8088
  style: z.menuItem,
@@ -8090,14 +8098,14 @@ const Ns = [
8090
8098
  tabIndex: 0,
8091
8099
  children: [
8092
8100
  /* @__PURE__ */ r.jsx(Is, { style: z.icon, "aria-hidden": "true" }),
8093
- /* @__PURE__ */ r.jsx("span", { style: z.menuItemText, children: E })
8101
+ /* @__PURE__ */ r.jsx("span", { style: z.menuItemText, children: k })
8094
8102
  ]
8095
8103
  }
8096
8104
  ),
8097
- x && T.profileUrl && /* @__PURE__ */ r.jsxs(
8105
+ x && C.profileUrl && /* @__PURE__ */ r.jsxs(
8098
8106
  "a",
8099
8107
  {
8100
- href: T.profileUrl,
8108
+ href: C.profileUrl,
8101
8109
  target: "_self",
8102
8110
  rel: "noopener noreferrer",
8103
8111
  style: z.menuItem,
@@ -8111,7 +8119,7 @@ const Ns = [
8111
8119
  tabIndex: 0,
8112
8120
  children: [
8113
8121
  /* @__PURE__ */ r.jsx(pe, { style: z.icon, "aria-hidden": "true" }),
8114
- /* @__PURE__ */ r.jsx("span", { style: z.menuItemText, children: k })
8122
+ /* @__PURE__ */ r.jsx("span", { style: z.menuItemText, children: E })
8115
8123
  ]
8116
8124
  }
8117
8125
  )
@@ -8138,7 +8146,7 @@ const Ns = [
8138
8146
  "aria-hidden": "true"
8139
8147
  }
8140
8148
  ),
8141
- /* @__PURE__ */ r.jsx("span", { style: z.menuItemText, children: p })
8149
+ /* @__PURE__ */ r.jsx("span", { style: z.menuItemText, children: u })
8142
8150
  ]
8143
8151
  }
8144
8152
  ) })
@@ -8177,7 +8185,7 @@ const Ns = [
8177
8185
  primaryColor: n = "#00C212",
8178
8186
  onVerify: s
8179
8187
  }) => {
8180
- const i = me();
8188
+ const i = fe();
8181
8189
  if (!t)
8182
8190
  return /* @__PURE__ */ r.jsxs(
8183
8191
  "div",
@@ -8204,8 +8212,8 @@ const Ns = [
8204
8212
  const [a, o] = P(!1), [c, d] = P({
8205
8213
  email: t?.email || "",
8206
8214
  otp: ""
8207
- }), [u, x] = P(!1), [y, E] = P(!1), [k, p] = P(null);
8208
- Te.useEffect(() => {
8215
+ }), [p, x] = P(!1), [y, k] = P(!1), [E, u] = P(null);
8216
+ Ce.useEffect(() => {
8209
8217
  if (typeof window < "u") {
8210
8218
  const b = () => o(window.innerWidth < 768);
8211
8219
  return b(), window.addEventListener("resize", b), () => window.removeEventListener("resize", b);
@@ -8239,8 +8247,8 @@ const Ns = [
8239
8247
  t?.email && d((b) => ({ ...b, email: t.email }));
8240
8248
  }, [t?.email]);
8241
8249
  const O = (b, j) => {
8242
- p({ type: b, message: j }), setTimeout(() => p(null), 3e3);
8243
- }, T = async () => {
8250
+ u({ type: b, message: j }), setTimeout(() => u(null), 3e3);
8251
+ }, C = async () => {
8244
8252
  if (!c.email || !/\S+@\S+\.\S+/.test(c.email)) {
8245
8253
  O("error", "Please enter a valid email");
8246
8254
  return;
@@ -8250,7 +8258,7 @@ const Ns = [
8250
8258
  return;
8251
8259
  }
8252
8260
  try {
8253
- E(!0);
8261
+ k(!0);
8254
8262
  const b = await i.requestEmailVerificationOTP({
8255
8263
  userId: t.id,
8256
8264
  email: c.email
@@ -8265,7 +8273,7 @@ const Ns = [
8265
8273
  } catch (b) {
8266
8274
  console.error("Send OTP error:", b), O("error", b.message || "Server error");
8267
8275
  } finally {
8268
- E(!1);
8276
+ k(!1);
8269
8277
  }
8270
8278
  }, g = async (b) => {
8271
8279
  if (b.preventDefault(), !c.email || !c.otp) {
@@ -8273,7 +8281,7 @@ const Ns = [
8273
8281
  return;
8274
8282
  }
8275
8283
  try {
8276
- E(!0);
8284
+ k(!0);
8277
8285
  const j = await i.verifyEmail({
8278
8286
  email: c.email,
8279
8287
  otp: c.otp
@@ -8286,7 +8294,7 @@ const Ns = [
8286
8294
  } catch (j) {
8287
8295
  O("error", j.message || "Server error");
8288
8296
  } finally {
8289
- E(!1);
8297
+ k(!1);
8290
8298
  }
8291
8299
  }, A = {
8292
8300
  width: "100%",
@@ -8368,7 +8376,7 @@ const Ns = [
8368
8376
  ]
8369
8377
  }
8370
8378
  ),
8371
- k && /* @__PURE__ */ r.jsxs(
8379
+ E && /* @__PURE__ */ r.jsxs(
8372
8380
  "div",
8373
8381
  {
8374
8382
  style: {
@@ -8376,16 +8384,16 @@ const Ns = [
8376
8384
  borderRadius: 12,
8377
8385
  fontSize: 13,
8378
8386
  fontWeight: 500,
8379
- color: k.type === "success" ? h.success : h.warning,
8380
- border: `1px solid ${k.type === "success" ? h.success : h.warning}`,
8381
- backgroundColor: k.type === "success" ? `${h.success}20` : `${h.warning}20`,
8387
+ color: E.type === "success" ? h.success : h.warning,
8388
+ border: `1px solid ${E.type === "success" ? h.success : h.warning}`,
8389
+ backgroundColor: E.type === "success" ? `${h.success}20` : `${h.warning}20`,
8382
8390
  display: "flex",
8383
8391
  alignItems: "center",
8384
8392
  gap: 8
8385
8393
  },
8386
8394
  children: [
8387
- k.type === "success" ? /* @__PURE__ */ r.jsx(ue, { size: 16 }) : /* @__PURE__ */ r.jsx(se, { size: 16 }),
8388
- k.message
8395
+ E.type === "success" ? /* @__PURE__ */ r.jsx(ue, { size: 16 }) : /* @__PURE__ */ r.jsx(se, { size: 16 }),
8396
+ E.message
8389
8397
  ]
8390
8398
  }
8391
8399
  ),
@@ -8440,7 +8448,7 @@ const Ns = [
8440
8448
  }
8441
8449
  )
8442
8450
  ] }),
8443
- u && /* @__PURE__ */ r.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: 4 }, children: [
8451
+ p && /* @__PURE__ */ r.jsxs("div", { style: { display: "flex", flexDirection: "column", gap: 4 }, children: [
8444
8452
  /* @__PURE__ */ r.jsxs(
8445
8453
  "div",
8446
8454
  {
@@ -8490,7 +8498,7 @@ const Ns = [
8490
8498
  }
8491
8499
  )
8492
8500
  ] }),
8493
- /* @__PURE__ */ r.jsx("div", { style: { display: "flex", gap: 12 }, children: u ? /* @__PURE__ */ r.jsxs(
8501
+ /* @__PURE__ */ r.jsx("div", { style: { display: "flex", gap: 12 }, children: p ? /* @__PURE__ */ r.jsxs(
8494
8502
  "button",
8495
8503
  {
8496
8504
  type: "submit",
@@ -8510,7 +8518,7 @@ const Ns = [
8510
8518
  "button",
8511
8519
  {
8512
8520
  type: "button",
8513
- onClick: T,
8521
+ onClick: C,
8514
8522
  disabled: y || !t?.id,
8515
8523
  style: {
8516
8524
  ...N(y),