@aaravpos/appointment-booking-plugin 4.0.8 → 4.0.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,13 +1,13 @@
1
- import j, { Component as Fl, PureComponent as Ll, createContext as jl, createElement as Fn, forwardRef as rs, useCallback as Be, useContext as Bl, useEffect as me, useMemo as ce, useRef as Ae, useState as H } from "react";
1
+ import j, { Component as Fl, PureComponent as Ll, createContext as jl, createElement as Fn, forwardRef as rs, useCallback as Be, useContext as Bl, useEffect as me, useMemo as ce, useRef as Ae, useState as q } from "react";
2
2
  import { Provider as Ul, useDispatch as Ie, useSelector as K } from "react-redux";
3
3
  import { applyMiddleware as Vl, combineReducers as ns, compose as yr, createStore as zl, isAction as Gr, isPlainObject as as } from "redux";
4
- import { FLUSH as Gl, PAUSE as Wl, PERSIST as Hl, PURGE as ql, REGISTER as Kl, REHYDRATE as Yl, persistReducer as Zl, persistStore as Xl } from "redux-persist";
4
+ import { FLUSH as Gl, PAUSE as Wl, PERSIST as ql, PURGE as Hl, REGISTER as Kl, REHYDRATE as Yl, persistReducer as Zl, persistStore as Xl } from "redux-persist";
5
5
  import { Fragment as X, jsx as d, jsxs as h } from "react/jsx-runtime";
6
6
  import { DateTime as be } from "luxon";
7
7
  import { ToastContainer as Jl, toast as ie } from "react-toastify";
8
8
  import { Controller as ot, useForm as ba } from "react-hook-form";
9
9
  import { debounce as Ql } from "lodash";
10
- import * as Hc from "redux";
10
+ import * as qc from "redux";
11
11
  var ec = Object.create, $r = Object.defineProperty, tc = Object.getOwnPropertyDescriptor, rc = Object.getOwnPropertyNames, nc = Object.getPrototypeOf, ac = Object.prototype.hasOwnProperty, xe = (e, t) => () => (t || (e((t = { exports: {} }).exports, t), e = null), t.exports), ic = (e, t) => {
12
12
  let r = {};
13
13
  for (var n in e)
@@ -154,7 +154,7 @@ function Pe(e, ...t) {
154
154
  }
155
155
  var Ee = Object, ht = Ee.getPrototypeOf, gr = "constructor", Wr = "prototype", Un = "configurable", br = "enumerable", cr = "writable", Tt = "value", _e = (e) => !!e && !!e[Ne];
156
156
  function Re(e) {
157
- return e ? ss(e) || qr(e) || !!e[ui] || !!e[gr]?.[ui] || Kr(e) || Yr(e) : !1;
157
+ return e ? ss(e) || Hr(e) || !!e[ui] || !!e[gr]?.[ui] || Kr(e) || Yr(e) : !1;
158
158
  }
159
159
  var fc = Ee[Wr][gr].toString(), fi = /* @__PURE__ */ new WeakMap();
160
160
  function ss(e) {
@@ -170,22 +170,22 @@ function ss(e) {
170
170
  function pc(e) {
171
171
  return _e(e) || Pe(15, e), e[Ne].base_;
172
172
  }
173
- function Hr(e, t, r = !0) {
174
- qt(e) === 0 ? (r ? Reflect.ownKeys(e) : Ee.keys(e)).forEach((n) => {
173
+ function qr(e, t, r = !0) {
174
+ Ht(e) === 0 ? (r ? Reflect.ownKeys(e) : Ee.keys(e)).forEach((n) => {
175
175
  t(n, e[n], e);
176
176
  }) : e.forEach((n, a) => t(a, n, e));
177
177
  }
178
- function qt(e) {
178
+ function Ht(e) {
179
179
  const t = e[Ne];
180
- return t ? t.type_ : qr(e) ? 1 : Kr(e) ? 2 : Yr(e) ? 3 : 0;
180
+ return t ? t.type_ : Hr(e) ? 1 : Kr(e) ? 2 : Yr(e) ? 3 : 0;
181
181
  }
182
- var pi = (e, t, r = qt(e)) => r === 2 ? e.has(t) : Ee[Wr].hasOwnProperty.call(e, t), Vn = (e, t, r = qt(e)) => r === 2 ? e.get(t) : e[t], Nr = (e, t, r, n = qt(e)) => {
182
+ var pi = (e, t, r = Ht(e)) => r === 2 ? e.has(t) : Ee[Wr].hasOwnProperty.call(e, t), Vn = (e, t, r = Ht(e)) => r === 2 ? e.get(t) : e[t], Nr = (e, t, r, n = Ht(e)) => {
183
183
  n === 2 ? e.set(t, r) : n === 3 ? e.add(r) : e[t] = r;
184
184
  };
185
185
  function mc(e, t) {
186
186
  return e === t ? e !== 0 || 1 / e === 1 / t : e !== e && t !== t;
187
187
  }
188
- var qr = Array.isArray, Kr = (e) => e instanceof Map, Yr = (e) => e instanceof Set, Ca = (e) => typeof e == "object", Ze = (e) => typeof e == "function", Pn = (e) => typeof e == "boolean";
188
+ var Hr = Array.isArray, Kr = (e) => e instanceof Map, Yr = (e) => e instanceof Set, Ca = (e) => typeof e == "object", Ze = (e) => typeof e == "function", Pn = (e) => typeof e == "boolean";
189
189
  function hc(e) {
190
190
  const t = +e;
191
191
  return Number.isInteger(t) && String(t) === e;
@@ -194,7 +194,7 @@ var Le = (e) => e.copy_ || e.base_, Sa = (e) => e.modified_ ? e.copy_ : e.base_;
194
194
  function zn(e, t) {
195
195
  if (Kr(e)) return new Map(e);
196
196
  if (Yr(e)) return new Set(e);
197
- if (qr(e)) return Array[Wr].slice.call(e);
197
+ if (Hr(e)) return Array[Wr].slice.call(e);
198
198
  const r = ss(e);
199
199
  if (t === !0 || t === "class_only" && !r) {
200
200
  const n = Ee.getOwnPropertyDescriptors(e);
@@ -218,12 +218,12 @@ function zn(e, t) {
218
218
  }
219
219
  }
220
220
  function Zr(e, t = !1) {
221
- return Xr(e) || _e(e) || !Re(e) || (qt(e) > 1 && Ee.defineProperties(e, {
221
+ return Xr(e) || _e(e) || !Re(e) || (Ht(e) > 1 && Ee.defineProperties(e, {
222
222
  set: Qt,
223
223
  add: Qt,
224
224
  clear: Qt,
225
225
  delete: Qt
226
- }), Ee.freeze(e), t && Hr(e, (r, n) => {
226
+ }), Ee.freeze(e), t && qr(e, (r, n) => {
227
227
  Zr(n, !0);
228
228
  }, !1)), e;
229
229
  }
@@ -254,9 +254,9 @@ function vi(e, t) {
254
254
  t && (e.patchPlugin_ = et(Gn), e.patches_ = [], e.inversePatches_ = [], e.patchListener_ = t);
255
255
  }
256
256
  function Wn(e) {
257
- Hn(e), e.drafts_.forEach($c), e.drafts_ = null;
257
+ qn(e), e.drafts_.forEach($c), e.drafts_ = null;
258
258
  }
259
- function Hn(e) {
259
+ function qn(e) {
260
260
  e === At && (At = e.parent_);
261
261
  }
262
262
  var yi = (e) => At = yc(At, e);
@@ -302,7 +302,7 @@ function us(e, t, r, n) {
302
302
  }
303
303
  if (!e.draftLocations_) {
304
304
  const s = e.draftLocations_ = /* @__PURE__ */ new Map();
305
- Hr(a, (l, c) => {
305
+ qr(a, (l, c) => {
306
306
  if (_e(c)) {
307
307
  const u = s.get(c) || [];
308
308
  u.push(l), s.set(c, u);
@@ -344,7 +344,7 @@ function Cc(e, t, r) {
344
344
  });
345
345
  }
346
346
  function Sr(e, t, r) {
347
- return !r.immer_.autoFreeze_ && r.unfinalizedDrafts_ < 1 || _e(e) || t.has(e) || !Re(e) || Xr(e) || (t.add(e), Hr(e, (n, a) => {
347
+ return !r.immer_.autoFreeze_ && r.unfinalizedDrafts_ < 1 || _e(e) || t.has(e) || !Re(e) || Xr(e) || (t.add(e), qr(e, (n, a) => {
348
348
  if (_e(a)) {
349
349
  const i = a[Ne];
350
350
  Jr(i, r) && (Nr(e, n, Sa(i), e.type_), cs(i));
@@ -352,7 +352,7 @@ function Sr(e, t, r) {
352
352
  })), e;
353
353
  }
354
354
  function Sc(e, t) {
355
- const r = qr(e), n = {
355
+ const r = Hr(e), n = {
356
356
  type_: r ? 1 : 0,
357
357
  scope_: t ? t.scope_ : ls(),
358
358
  modified_: !1,
@@ -404,12 +404,12 @@ var Pr = {
404
404
  if (i && i.base_ === r)
405
405
  return e.copy_[t] = r, e.assigned_.set(t, !1), !0;
406
406
  if (mc(r, a) && (r !== void 0 || pi(e.base_, t, e.type_))) return !0;
407
- ur(e), qn(e);
407
+ ur(e), Hn(e);
408
408
  }
409
409
  return e.copy_[t] === r && (r !== void 0 || t in e.copy_) || Number.isNaN(r) && Number.isNaN(e.copy_[t]) || (e.copy_[t] = r, e.assigned_.set(t, !0), Cc(e, t, r)), !0;
410
410
  },
411
411
  deleteProperty(e, t) {
412
- return ur(e), wn(e.base_, t) !== void 0 || t in e.base_ ? (e.assigned_.set(t, !1), qn(e)) : e.assigned_.delete(t), e.copy_ && delete e.copy_[t], !0;
412
+ return ur(e), wn(e.base_, t) !== void 0 || t in e.base_ ? (e.assigned_.set(t, !1), Hn(e)) : e.assigned_.delete(t), e.copy_ && delete e.copy_[t], !0;
413
413
  },
414
414
  getOwnPropertyDescriptor(e, t) {
415
415
  const r = Le(e), n = Reflect.getOwnPropertyDescriptor(r, t);
@@ -460,8 +460,8 @@ function ps(e, t) {
460
460
  r = ht(r);
461
461
  }
462
462
  }
463
- function qn(e) {
464
- e.modified_ || (e.modified_ = !0, e.parent_ && qn(e.parent_));
463
+ function Hn(e) {
464
+ e.modified_ || (e.modified_ = !0, e.parent_ && Hn(e.parent_));
465
465
  }
466
466
  function ur(e) {
467
467
  e.copy_ || (e.assigned_ = /* @__PURE__ */ new Map(), e.copy_ = zn(e.base_, e.scope_.immer_.useStrictShallowCopy_));
@@ -485,7 +485,7 @@ var wc = class {
485
485
  try {
486
486
  a = r(o), s = !1;
487
487
  } finally {
488
- s ? Wn(i) : Hn(i);
488
+ s ? Wn(i) : qn(i);
489
489
  }
490
490
  return vi(i, n), $i(a, i);
491
491
  } else if (!t || !Ca(t)) {
@@ -513,7 +513,7 @@ var wc = class {
513
513
  createDraft(e) {
514
514
  Re(e) || Pe(8), _e(e) && (e = Qr(e));
515
515
  const t = yi(this), r = Kn(t, e, void 0);
516
- return r[Ne].isManual_ = !0, Hn(t), r;
516
+ return r[Ne].isManual_ = !0, qn(t), r;
517
517
  }
518
518
  finishDraft(e, t) {
519
519
  const r = e && e[Ne];
@@ -566,7 +566,7 @@ function ms(e) {
566
566
  if (!t.modified_) return t.base_;
567
567
  t.finalized_ = !0, r = zn(e, t.scope_.immer_.useStrictShallowCopy_), n = t.scope_.immer_.shouldUseStrictIteration();
568
568
  } else r = zn(e, !0);
569
- return Hr(r, (a, i) => {
569
+ return qr(r, (a, i) => {
570
570
  Nr(r, a, ms(i));
571
571
  }, n), t && (t.finalized_ = !1), r;
572
572
  }
@@ -891,14 +891,14 @@ var Gc = vs(), Wc = vs, Yn = /* @__PURE__ */ ic({
891
891
  unwrapResult: () => Bs,
892
892
  weakMapMemoize: () => tn
893
893
  });
894
- oc(Yn, Hc);
894
+ oc(Yn, qc);
895
895
  var ys = (...e) => {
896
896
  const t = Pa(...e), r = Object.assign((...n) => {
897
897
  const a = t(...n), i = (o, ...s) => a(_e(o) ? Qr(o) : o, ...s);
898
898
  return Object.assign(i, a), i;
899
899
  }, { withTypes: () => r });
900
900
  return r;
901
- }, $s = /* @__PURE__ */ ys(tn), qc = typeof window < "u" && window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ ? window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ : function() {
901
+ }, $s = /* @__PURE__ */ ys(tn), Hc = typeof window < "u" && window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ ? window.__REDUX_DEVTOOLS_EXTENSION_COMPOSE__ : function() {
902
902
  if (arguments.length !== 0)
903
903
  return typeof arguments[0] == "object" ? yr : yr.apply(null, arguments);
904
904
  };
@@ -1192,7 +1192,7 @@ function As(e) {
1192
1192
  });
1193
1193
  }
1194
1194
  let u = yr;
1195
- a && (u = qc({
1195
+ a && (u = Hc({
1196
1196
  trace: process.env.NODE_ENV !== "production",
1197
1197
  ...typeof a == "object" && a
1198
1198
  }));
@@ -1907,7 +1907,7 @@ function bu(e = {}) {
1907
1907
  ...n
1908
1908
  };
1909
1909
  }
1910
- var Nu = "task", Hs = "listener", qs = "completed", Ea = "cancelled", Cu = `task-${Ea}`, Su = `task-${qs}`, Zn = `${Hs}-${Ea}`, Pu = `${Hs}-${qs}`, Zt = class {
1910
+ var Nu = "task", qs = "listener", Hs = "completed", Ea = "cancelled", Cu = `task-${Ea}`, Su = `task-${Hs}`, Zn = `${qs}-${Ea}`, Pu = `${qs}-${Hs}`, Zt = class {
1911
1911
  constructor(e) {
1912
1912
  this.code = e, this.message = `${Nu} ${Ea} (reason: ${e})`;
1913
1913
  }
@@ -2221,7 +2221,7 @@ function Wu(e) {
2221
2221
  var t = "".concat(e, "Storage");
2222
2222
  return Gu(t) ? self[t] : (process.env.NODE_ENV !== "production" && console.error("redux-persist failed to create sync storage. falling back to noop storage."), zu);
2223
2223
  }
2224
- function Hu(e) {
2224
+ function qu(e) {
2225
2225
  var t = Wu(e);
2226
2226
  return {
2227
2227
  getItem: function(n) {
@@ -2253,13 +2253,13 @@ var nr = (e) => e ? [
2253
2253
  "time",
2254
2254
  "confirm",
2255
2255
  "success"
2256
- ], qu = {
2256
+ ], Hu = {
2257
2257
  currentStep: "services",
2258
2258
  completedSteps: ["services"],
2259
2259
  isOrder: !0
2260
2260
  }, td = We({
2261
2261
  name: "breadcrumbs",
2262
- initialState: qu,
2262
+ initialState: Hu,
2263
2263
  reducers: {
2264
2264
  setIsOrder: (e, t) => {
2265
2265
  e.isOrder = t.payload;
@@ -2293,7 +2293,7 @@ var nr = (e) => e ? [
2293
2293
  e.completedSteps = e.completedSteps.filter((i) => n.indexOf(i) <= a);
2294
2294
  }
2295
2295
  }
2296
- }), { setIsOrder: Ku, goToStep: Jn, completeStep: Wv, nextStep: we, prevStep: Hv, clearSteps: qv, resetCompletedStepsFrom: Ti } = td.actions, Yu = td.reducer, Ai = {
2296
+ }), { setIsOrder: Ku, goToStep: Jn, completeStep: Wv, nextStep: we, prevStep: qv, clearSteps: Hv, resetCompletedStepsFrom: Ti } = td.actions, Yu = td.reducer, Ai = {
2297
2297
  id: "",
2298
2298
  outletName: "",
2299
2299
  timeZone: "",
@@ -2361,7 +2361,7 @@ var nr = (e) => e ? [
2361
2361
  e.selectedProfessional = null;
2362
2362
  }
2363
2363
  }
2364
- }), { setServicePayload: ef, setCategory: Kv, toggleService: Ar, clearSelectedServices: xi, clearSelectedProfessional: ki, incrementService: ad, decrementService: xr, toggleProfessional: id } = nd.actions, tf = nd.reducer, ze = "https://prod.aaravpos.com/api/v1", He = () => ({
2364
+ }), { setServicePayload: ef, setCategory: Kv, toggleService: Ar, clearSelectedServices: xi, clearSelectedProfessional: ki, incrementService: ad, decrementService: xr, toggleProfessional: id } = nd.actions, tf = nd.reducer, ze = "https://prod.aaravpos.com/api/v1", qe = () => ({
2365
2365
  "Content-Type": "application/json",
2366
2366
  Authorization: `Bearer ${an.getState()?.booking.outletDetails?.token}`
2367
2367
  }), Mi = async (e, t, r) => {
@@ -2379,14 +2379,14 @@ var nr = (e) => e ? [
2379
2379
  }, rf = async (e, t, r) => {
2380
2380
  const n = await fetch(`${ze}/integration/slot/tenant/${e}/staff/${t}/online?date=${r}`, {
2381
2381
  method: "GET",
2382
- headers: He()
2382
+ headers: qe()
2383
2383
  });
2384
2384
  if (!n.ok) throw new Error("Failed to fetch services");
2385
2385
  return await n.json();
2386
2386
  }, nf = async (e) => {
2387
2387
  const t = await fetch(`${ze}/integration/appointment/create`, {
2388
2388
  method: "POST",
2389
- headers: He(),
2389
+ headers: qe(),
2390
2390
  body: JSON.stringify(e)
2391
2391
  });
2392
2392
  if (!t.ok) throw new Error("Failed to fetch services");
@@ -2394,14 +2394,14 @@ var nr = (e) => e ? [
2394
2394
  }, af = async (e, t) => {
2395
2395
  const r = await fetch(`${ze}/integration/appointment/details?tenantId=${t}&appointmentId=${e}`, {
2396
2396
  method: "GET",
2397
- headers: He()
2397
+ headers: qe()
2398
2398
  });
2399
2399
  if (!r.ok) throw new Error("Failed to fetch appointment details");
2400
2400
  return await r.json();
2401
2401
  }, of = async ({ search: e, tenantId: t }) => {
2402
2402
  const r = await fetch(`${ze}/integration/customer/drop-down/list?tenantId=${t}&search=${encodeURIComponent(e || "")}`, {
2403
2403
  method: "GET",
2404
- headers: He()
2404
+ headers: qe()
2405
2405
  });
2406
2406
  if (!r.ok) throw new Error("Failed to fetch customers");
2407
2407
  return await r.json();
@@ -2409,7 +2409,7 @@ var nr = (e) => e ? [
2409
2409
  try {
2410
2410
  const t = await fetch(`${ze}/payment/pay/customer/direct`, {
2411
2411
  method: "POST",
2412
- headers: He(),
2412
+ headers: qe(),
2413
2413
  body: JSON.stringify(e)
2414
2414
  }), r = await t.json();
2415
2415
  if (!t.ok) throw r;
@@ -2421,7 +2421,7 @@ var nr = (e) => e ? [
2421
2421
  try {
2422
2422
  const t = await fetch(`${ze}/payment/orders/${e}/invoicing/finalize`, {
2423
2423
  method: "POST",
2424
- headers: He()
2424
+ headers: qe()
2425
2425
  }), r = await t.json();
2426
2426
  if (!t.ok) throw r;
2427
2427
  return r;
@@ -2440,7 +2440,7 @@ var nr = (e) => e ? [
2440
2440
  }, Fi = async (e, t, r) => {
2441
2441
  const n = await fetch(`${ze}/concent/check/${e}/${t}?serviceId=${r}`, {
2442
2442
  method: "GET",
2443
- headers: He()
2443
+ headers: qe()
2444
2444
  });
2445
2445
  if (!n.ok) throw new Error("Failed to check consent requirement");
2446
2446
  return n.json();
@@ -2459,7 +2459,7 @@ var nr = (e) => e ? [
2459
2459
  l === "CHECKBOX_ONLY" && (f.isChecked = c ?? !0), u && (f.typedName = u), p && (f.imageUrl = p);
2460
2460
  const v = await fetch(`${ze}/concent/customer-sign`, {
2461
2461
  method: "POST",
2462
- headers: He(),
2462
+ headers: qe(),
2463
2463
  body: JSON.stringify(f)
2464
2464
  }), m = await v.json();
2465
2465
  if (!v.ok) throw m;
@@ -2618,7 +2618,7 @@ var nr = (e) => e ? [
2618
2618
  }
2619
2619
  }), Cf = Zl({
2620
2620
  key: "booking",
2621
- storage: typeof window < "u" ? Hu("session") : Nf()
2621
+ storage: typeof window < "u" ? qu("session") : Nf()
2622
2622
  }, bf), an = As({
2623
2623
  reducer: Cf,
2624
2624
  devTools: process.env.NODE_ENV !== "production",
@@ -2626,8 +2626,8 @@ var nr = (e) => e ? [
2626
2626
  Gl,
2627
2627
  Yl,
2628
2628
  Wl,
2629
- Hl,
2630
2629
  ql,
2630
+ Hl,
2631
2631
  Kl
2632
2632
  ] } })
2633
2633
  }), Ma = Xl(an), Xv = an.getState;
@@ -2823,13 +2823,13 @@ var Pf = (e) => {
2823
2823
  d: "M9 13c6.667 0 6.667-10 0-10",
2824
2824
  key: "1nkvk2"
2825
2825
  }]
2826
- ], Wf = ee("indian-rupee", Gf), Hf = [["path", {
2826
+ ], Wf = ee("indian-rupee", Gf), qf = [["path", {
2827
2827
  d: "M5 12h14",
2828
2828
  key: "1ays0h"
2829
- }]], pd = ee("minus", Hf), qf = [["path", {
2829
+ }]], pd = ee("minus", qf), Hf = [["path", {
2830
2830
  d: "M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401",
2831
2831
  key: "kfwtm"
2832
- }]], Kf = ee("moon", qf), Yf = [["path", {
2832
+ }]], Kf = ee("moon", Hf), Yf = [["path", {
2833
2833
  d: "M6 8L2 12L6 16",
2834
2834
  key: "kyvwex"
2835
2835
  }], ["path", {
@@ -3032,7 +3032,7 @@ var Pf = (e) => {
3032
3032
  }], ["path", {
3033
3033
  d: "m6 6 12 12",
3034
3034
  key: "d8bk6v"
3035
- }]], qe = ee("x", h1), v1 = ({ status: e }) => /* @__PURE__ */ d("span", {
3035
+ }]], He = ee("x", h1), v1 = ({ status: e }) => /* @__PURE__ */ d("span", {
3036
3036
  className: `aaravpos-status-badge ${e ? "aaravpos-status-open" : "aaravpos-status-closed"}`,
3037
3037
  children: e ? "Open" : "Closed"
3038
3038
  }), y1 = ({ item: e, onSelect: t, selected: r }) => /* @__PURE__ */ h("div", {
@@ -3059,7 +3059,7 @@ var Pf = (e) => {
3059
3059
  })]
3060
3060
  });
3061
3061
  function $1({ outlets: e, onSelectOutlet: t }) {
3062
- const [r, n] = H(null), [a, i] = H(""), o = (l) => {
3062
+ const [r, n] = q(null), [a, i] = q(""), o = (l) => {
3063
3063
  n(l);
3064
3064
  const c = e.find((u) => u.id == l);
3065
3065
  c && setTimeout(() => {
@@ -3096,7 +3096,7 @@ function $1({ outlets: e, onSelectOutlet: t }) {
3096
3096
  children: a && /* @__PURE__ */ d("button", {
3097
3097
  onClick: () => i(""),
3098
3098
  className: "aaravpos-search-clear",
3099
- children: /* @__PURE__ */ d(qe, { size: 16 })
3099
+ children: /* @__PURE__ */ d(He, { size: 16 })
3100
3100
  })
3101
3101
  })
3102
3102
  ]
@@ -3142,7 +3142,7 @@ var g1 = {
3142
3142
  return !e.taxRows || !e.taxRows.length ? 0 : e.taxRows.reduce((a, i) => i.isActive ? i.taxType === "FIXED" ? a + (i.taxRate || 0) * n : i.taxType === "PERCENTAGE" ? a + r * n * (i.taxRate || 0) / 100 : a : a, 0);
3143
3143
  };
3144
3144
  function N1() {
3145
- const [e, t] = H({
3145
+ const [e, t] = q({
3146
3146
  width: 0,
3147
3147
  height: 0
3148
3148
  });
@@ -3333,7 +3333,7 @@ var vd = ({ pro: e, selectedStaffServices: t = [], totalPrice: r = 0, totalDurat
3333
3333
  /* @__PURE__ */ d("button", {
3334
3334
  className: "aaravpos-sidebar-close-btn",
3335
3335
  onClick: () => i(rt(!1)),
3336
- children: /* @__PURE__ */ d(qe, { size: 18 })
3336
+ children: /* @__PURE__ */ d(He, { size: 18 })
3337
3337
  })
3338
3338
  ]
3339
3339
  }), /* @__PURE__ */ h("div", {
@@ -3570,7 +3570,7 @@ var O1 = (e) => Number(e.price || e.min_price || 0), ea = (e, { perUnit: t = !1
3570
3570
  return !e.taxRows || !e.taxRows.length ? 0 : e.taxRows.reduce((a, i) => i.isActive ? i.taxType === "FIXED" ? a + i.taxRate * n : i.taxType === "PERCENTAGE" ? a + r * n * i.taxRate / 100 : a : a, 0);
3571
3571
  };
3572
3572
  function E1() {
3573
- const e = Ie(), { staff: t, selectedServices: r, selectedProfessional: n, loading: a } = K((m) => m.booking.service), [i, o] = H(!1), s = r.map((m) => m.id), l = ce(() => {
3573
+ const e = Ie(), { staff: t, selectedServices: r, selectedProfessional: n, loading: a } = K((m) => m.booking.service), [i, o] = q(!1), s = r.map((m) => m.id), l = ce(() => {
3574
3574
  if (!n?.id) return [];
3575
3575
  const m = t.find((y) => y.id === n.id);
3576
3576
  return m ? r.map((y) => {
@@ -3717,7 +3717,7 @@ function $d({ selectedServices: e, totalPrice: t, goToStep: r }) {
3717
3717
  /* @__PURE__ */ d("button", {
3718
3718
  className: "aaravpos-sidebar-close-btn",
3719
3719
  onClick: () => n(rt(!1)),
3720
- children: /* @__PURE__ */ d(qe, { size: 18 })
3720
+ children: /* @__PURE__ */ d(He, { size: 18 })
3721
3721
  })
3722
3722
  ]
3723
3723
  }), /* @__PURE__ */ h("div", {
@@ -3828,7 +3828,7 @@ function bd() {
3828
3828
  });
3829
3829
  }
3830
3830
  function I1() {
3831
- const e = Ie(), t = Ae(null), r = Ae(null), { superCategories: n, selectedServices: a, selectedProfessional: i, loading: o } = K((C) => C.booking.service), [s, l] = H(null), [c, u] = H(null), [p, f] = H(""), v = new Set(i ? i?.assignments?.map((C) => C.id) : []), m = new Set(i ? i?.assignments?.map((C) => C.categoryId) : []), y = n?.map((C) => ({
3831
+ const e = Ie(), t = Ae(null), r = Ae(null), { superCategories: n, selectedServices: a, selectedProfessional: i, loading: o } = K((C) => C.booking.service), [s, l] = q(null), [c, u] = q(null), [p, f] = q(""), v = new Set(i ? i?.assignments?.map((C) => C.id) : []), m = new Set(i ? i?.assignments?.map((C) => C.categoryId) : []), y = n?.map((C) => ({
3832
3832
  ...C,
3833
3833
  categories: C.categories?.map((N) => ({
3834
3834
  ...N,
@@ -3897,7 +3897,7 @@ function I1() {
3897
3897
  children: p && /* @__PURE__ */ d("button", {
3898
3898
  onClick: () => f(""),
3899
3899
  className: "aaravpos-search-clear",
3900
- children: /* @__PURE__ */ d(qe, { size: 16 })
3900
+ children: /* @__PURE__ */ d(He, { size: 16 })
3901
3901
  })
3902
3902
  })
3903
3903
  ]
@@ -4043,7 +4043,7 @@ function I1() {
4043
4043
  });
4044
4044
  }
4045
4045
  function T1() {
4046
- const e = Ie(), t = Ae(null), r = Ae(null), { superCategories: n, selectedServices: a, loading: i } = K((g) => g.booking.service), { outletName: o } = K((g) => g.booking?.outletDetails), [s, l] = H(null), [c, u] = H(null), [p, f] = H(""), v = ce(() => s ? c ? c?.services || [] : s?.categories?.flatMap((g) => g.services || []) || [] : [], [s, c]), m = ce(() => n?.flatMap((g) => g?.categories?.flatMap((S) => S.services || [])) || [], [n]), y = ce(() => {
4046
+ const e = Ie(), t = Ae(null), r = Ae(null), { superCategories: n, selectedServices: a, loading: i } = K((g) => g.booking.service), { outletName: o } = K((g) => g.booking?.outletDetails), [s, l] = q(null), [c, u] = q(null), [p, f] = q(""), v = ce(() => s ? c ? c?.services || [] : s?.categories?.flatMap((g) => g.services || []) || [] : [], [s, c]), m = ce(() => n?.flatMap((g) => g?.categories?.flatMap((S) => S.services || [])) || [], [n]), y = ce(() => {
4047
4047
  const g = p.trim().toLowerCase();
4048
4048
  return g ? m.filter((S) => S.name?.toLowerCase().includes(g) || S.description?.toLowerCase().includes(g)) : v;
4049
4049
  }, [
@@ -4108,7 +4108,7 @@ function T1() {
4108
4108
  children: p && /* @__PURE__ */ d("button", {
4109
4109
  onClick: () => f(""),
4110
4110
  className: "aaravpos-search-clear",
4111
- children: /* @__PURE__ */ d(qe, { size: 16 })
4111
+ children: /* @__PURE__ */ d(He, { size: 16 })
4112
4112
  })
4113
4113
  })
4114
4114
  ]
@@ -4256,7 +4256,7 @@ var A1 = [
4256
4256
  "Dec"
4257
4257
  ];
4258
4258
  function Nd({ buttonText: e, onButtonClick: t, showTaxesOnlyIfTime: r = !1, showTip: n = !1, tipPct: a = 0, onTipChange: i, consentRequired: o = !1, consentCompleted: s = 0, totalConsents: l = 0, checkingConsent: c = !1, loading: u = !1 }) {
4259
- const p = Ie(), { selectedSlotIndexes: f, slots: v, selectedDate: m } = K((x) => x.booking.slots), { staff: y, selectedServices: b, selectedProfessional: $ } = K((x) => x.booking.service), { timeZone: g } = K((x) => x.booking.outletDetails), S = be.now().setZone(g ?? "UTC"), [P, C] = H(""), [N, E] = H(!1), D = Ae(null), Z = Ae(null), [J, re] = H(0), ue = [
4259
+ const p = Ie(), { selectedSlotIndexes: f, slots: v, selectedDate: m } = K((x) => x.booking.slots), { staff: y, selectedServices: b, selectedProfessional: $ } = K((x) => x.booking.service), { timeZone: g } = K((x) => x.booking.outletDetails), S = be.now().setZone(g ?? "UTC"), [P, C] = q(""), [N, E] = q(!1), D = Ae(null), Z = Ae(null), [J, re] = q(0), ue = [
4260
4260
  0,
4261
4261
  5,
4262
4262
  10,
@@ -4270,10 +4270,10 @@ function Nd({ buttonText: e, onButtonClick: t, showTaxesOnlyIfTime: r = !1, show
4270
4270
  if (!$?.id) return [];
4271
4271
  const x = y?.find((M) => M.id === $.id);
4272
4272
  return x ? b.map((M) => {
4273
- const B = x.assignments?.find((te) => te.id === M.id), A = {
4273
+ const V = x.assignments?.find((te) => te.id === M.id), A = {
4274
4274
  ...M,
4275
- price: B?.price || M.price || M.min_price || 0,
4276
- duration: B?.duration || M.estimated_time || M.min_time || 0
4275
+ price: V?.price || M.price || M.min_price || 0,
4276
+ duration: V?.duration || M.estimated_time || M.min_time || 0
4277
4277
  };
4278
4278
  return {
4279
4279
  ...A,
@@ -4287,13 +4287,13 @@ function Nd({ buttonText: e, onButtonClick: t, showTaxesOnlyIfTime: r = !1, show
4287
4287
  b
4288
4288
  ]), ye = ve.reduce((x, M) => x + Number(M.price || M.min_price) * (M.qty || 1), 0), pe = ve.reduce((x, M) => x + Number(M.duration) * (M.qty || 1), 0), ne = Math.ceil(pe / fe), Ce = (x) => {
4289
4289
  if (!oe.length) return "";
4290
- const M = oe[x]?.start_time, B = oe[x + ne - 1];
4291
- return !M || !B ? "" : `${M} - ${B.end_time || B.start_time}`;
4290
+ const M = oe[x]?.start_time, V = oe[x + ne - 1];
4291
+ return !M || !V ? "" : `${M} - ${V.end_time || V.start_time}`;
4292
4292
  }, k = m || {
4293
4293
  day: S.day,
4294
4294
  month: S.month,
4295
4295
  year: S.year
4296
- }, R = f?.[0], w = R !== void 0 ? Ce(R) : null, I = k.month ?? 0, L = w ? `${A1[I - 1]} ${k.day} at ${w}` : null, z = ve.reduce((x, M) => x + M.tax, 0), F = Number(a) || 0, q = n ? ye * F / 100 : 0, G = ye + z + q;
4296
+ }, R = f?.[0], w = R !== void 0 ? Ce(R) : null, I = k.month ?? 0, L = w ? `${A1[I - 1]} ${k.day} at ${w}` : null, z = ve.reduce((x, M) => x + M.tax, 0), F = Number(a) || 0, H = n ? ye * F / 100 : 0, G = ye + z + H;
4297
4297
  me(() => {
4298
4298
  n && a == null && i?.(0);
4299
4299
  }, [
@@ -4311,7 +4311,7 @@ function Nd({ buttonText: e, onButtonClick: t, showTaxesOnlyIfTime: r = !1, show
4311
4311
  ]);
4312
4312
  return me(() => {
4313
4313
  const x = () => {
4314
- const B = D.current?.offsetHeight || 0, A = Z.current?.offsetHeight || 0, te = (B + (window.innerWidth <= 991 ? 190 : 205) || 0) + A;
4314
+ const V = D.current?.offsetHeight || 0, A = Z.current?.offsetHeight || 0, te = (V + (window.innerWidth <= 991 ? 190 : 205) || 0) + A;
4315
4315
  re(window.innerHeight - te);
4316
4316
  };
4317
4317
  x();
@@ -4338,7 +4338,7 @@ function Nd({ buttonText: e, onButtonClick: t, showTaxesOnlyIfTime: r = !1, show
4338
4338
  children: ["Your Order", /* @__PURE__ */ d("button", {
4339
4339
  className: "aaravpos-sidebar-close-btn",
4340
4340
  onClick: () => p(rt(!1)),
4341
- children: /* @__PURE__ */ d(qe, { size: 18 })
4341
+ children: /* @__PURE__ */ d(He, { size: 18 })
4342
4342
  })]
4343
4343
  }),
4344
4344
  $?.id && /* @__PURE__ */ h("div", {
@@ -4419,14 +4419,14 @@ function Nd({ buttonText: e, onButtonClick: t, showTaxesOnlyIfTime: r = !1, show
4419
4419
  /* @__PURE__ */ d("div", {
4420
4420
  className: "aaravpos-tip-options",
4421
4421
  children: [...ue, "custom"].map((x, M) => {
4422
- const B = x === "custom", A = B ? N : F === x, te = M === 0, $e = M === [...ue, "custom"].length - 1;
4422
+ const V = x === "custom", A = V ? N : F === x, te = M === 0, $e = M === [...ue, "custom"].length - 1;
4423
4423
  return /* @__PURE__ */ d("button", {
4424
4424
  onClick: () => {
4425
- B ? (E(!0), i?.(Number(P) || 0)) : (E(!1), C(""), i?.(Number(x)));
4425
+ V ? (E(!0), i?.(Number(P) || 0)) : (E(!1), C(""), i?.(Number(x)));
4426
4426
  },
4427
4427
  className: `aaravpos-tip-btn
4428
4428
  ${te || $e ? "aaravpos-tip-btn-fixed" : "aaravpos-tip-btn-flex"} ${A ? "aaravpos-tip-btn-active" : ""}`,
4429
- children: B ? "Custom" : x === 0 ? "No tip" : `${x}%`
4429
+ children: V ? "Custom" : x === 0 ? "No tip" : `${x}%`
4430
4430
  }, x);
4431
4431
  })
4432
4432
  }),
@@ -4475,7 +4475,7 @@ function Nd({ buttonText: e, onButtonClick: t, showTaxesOnlyIfTime: r = !1, show
4475
4475
  }),
4476
4476
  n && /* @__PURE__ */ d(Tn, {
4477
4477
  label: `Tip (${F}%)`,
4478
- value: /* @__PURE__ */ h(X, { children: [/* @__PURE__ */ d(de, { size: 14 }), q.toFixed(2)] })
4478
+ value: /* @__PURE__ */ h(X, { children: [/* @__PURE__ */ d(de, { size: 14 }), H.toFixed(2)] })
4479
4479
  }),
4480
4480
  (!r || w) && /* @__PURE__ */ d(Tn, {
4481
4481
  label: "Taxes",
@@ -4569,7 +4569,7 @@ var It = ({ dateObj: e, selectedProfessional: t, outletTimeZone: r }) => {
4569
4569
  "S"
4570
4570
  ];
4571
4571
  function M1({ isOpen: e, onClose: t }) {
4572
- const r = Ie(), { selectedDate: n } = K((f) => f.booking.slots), { selectedProfessional: a } = K((f) => f.booking.service), { timeZone: i } = K((f) => f.booking.outletDetails), [o] = H(x1(i || "")), [s, l] = H(0), c = o[s];
4572
+ const r = Ie(), { selectedDate: n } = K((f) => f.booking.slots), { selectedProfessional: a } = K((f) => f.booking.service), { timeZone: i } = K((f) => f.booking.outletDetails), [o] = q(x1(i || "")), [s, l] = q(0), c = o[s];
4573
4573
  if (!e) return null;
4574
4574
  const u = be.now().setZone(i ?? "UTC"), p = (f, v) => {
4575
4575
  const m = be.fromObject({
@@ -4605,7 +4605,7 @@ function M1({ isOpen: e, onClose: t }) {
4605
4605
  }), /* @__PURE__ */ d("button", {
4606
4606
  onClick: t,
4607
4607
  className: "aaravpos-date-close-btn",
4608
- children: /* @__PURE__ */ d(qe, {})
4608
+ children: /* @__PURE__ */ d(He, {})
4609
4609
  })]
4610
4610
  }), /* @__PURE__ */ h("div", {
4611
4611
  className: "aaravpos-date-modal-body",
@@ -4711,7 +4711,7 @@ var Gi = [
4711
4711
  "Sat"
4712
4712
  ], F1 = 15;
4713
4713
  function L1() {
4714
- const e = Ie(), [t, r] = H(11), { staff: n, selectedServices: a, selectedProfessional: i } = K((k) => k.booking.service), { tenantId: o, timeZone: s } = K((k) => k.booking?.outletDetails), { selectedSlotIndexes: l, selectedDate: c, selectedTime: u, slots: p, loading: f } = K((k) => k.booking.slots), [v, m] = H(!1), [y, b] = H(0), $ = ce(() => [
4714
+ const e = Ie(), [t, r] = q(11), { staff: n, selectedServices: a, selectedProfessional: i } = K((k) => k.booking.service), { tenantId: o, timeZone: s } = K((k) => k.booking?.outletDetails), { selectedSlotIndexes: l, selectedDate: c, selectedTime: u, slots: p, loading: f } = K((k) => k.booking.slots), [v, m] = q(!1), [y, b] = q(0), $ = ce(() => [
4715
4715
  p.morning,
4716
4716
  p.afternoon,
4717
4717
  p.evening
@@ -4832,7 +4832,7 @@ function L1() {
4832
4832
  };
4833
4833
  return k(), window.addEventListener("resize", k), () => window.removeEventListener("resize", k);
4834
4834
  }, []);
4835
- const ue = p?.morning || [], oe = p?.afternoon || [], fe = p?.evening || [], ve = (k) => k.some((R) => !R.isBooked && R.status === "AVAILABLE"), ye = () => ve(ue) ? "morning" : ve(oe) ? "afternoon" : ve(fe) ? "evening" : null, [pe, ne] = H(ye()), Ce = () => {
4835
+ const ue = p?.morning || [], oe = p?.afternoon || [], fe = p?.evening || [], ve = (k) => k.some((R) => !R.isBooked && R.status === "AVAILABLE"), ye = () => ve(ue) ? "morning" : ve(oe) ? "afternoon" : ve(fe) ? "evening" : null, [pe, ne] = q(ye()), Ce = () => {
4836
4836
  let k = null;
4837
4837
  for (let R = 1; R < P.length; R++) {
4838
4838
  const w = g.plus({ days: R });
@@ -12654,7 +12654,7 @@ var Cd = {
12654
12654
  function F(A) {
12655
12655
  return C(A) === a;
12656
12656
  }
12657
- function q(A) {
12657
+ function H(A) {
12658
12658
  return C(A) === y;
12659
12659
  }
12660
12660
  function G(A) {
@@ -12669,10 +12669,10 @@ var Cd = {
12669
12669
  function M(A) {
12670
12670
  return C(A) === i;
12671
12671
  }
12672
- function B(A) {
12672
+ function V(A) {
12673
12673
  return C(A) === f;
12674
12674
  }
12675
- e.AsyncMode = N, e.ConcurrentMode = E, e.ContextConsumer = D, e.ContextProvider = Z, e.Element = J, e.ForwardRef = re, e.Fragment = ue, e.Lazy = oe, e.Memo = fe, e.Portal = ve, e.Profiler = ye, e.StrictMode = pe, e.Suspense = ne, e.isAsyncMode = k, e.isConcurrentMode = R, e.isContextConsumer = w, e.isContextProvider = I, e.isElement = L, e.isForwardRef = z, e.isFragment = F, e.isLazy = q, e.isMemo = G, e.isPortal = W, e.isProfiler = x, e.isStrictMode = M, e.isSuspense = B, e.isValidElementType = P, e.typeOf = C;
12675
+ e.AsyncMode = N, e.ConcurrentMode = E, e.ContextConsumer = D, e.ContextProvider = Z, e.Element = J, e.ForwardRef = re, e.Fragment = ue, e.Lazy = oe, e.Memo = fe, e.Portal = ve, e.Profiler = ye, e.StrictMode = pe, e.Suspense = ne, e.isAsyncMode = k, e.isConcurrentMode = R, e.isContextConsumer = w, e.isContextProvider = I, e.isElement = L, e.isForwardRef = z, e.isFragment = F, e.isLazy = H, e.isMemo = G, e.isPortal = W, e.isProfiler = x, e.isStrictMode = M, e.isSuspense = V, e.isValidElementType = P, e.typeOf = C;
12676
12676
  })();
12677
12677
  })), Sd = /* @__PURE__ */ xe(((e, t) => {
12678
12678
  process.env.NODE_ENV === "production" ? t.exports = j1() : t.exports = B1();
@@ -12804,27 +12804,27 @@ var Cd = {
12804
12804
  function g(w) {
12805
12805
  if (process.env.NODE_ENV !== "production")
12806
12806
  var I = {}, L = 0;
12807
- function z(q, G, W, x, M, B, A) {
12808
- if (x = x || m, B = B || W, A !== a) {
12807
+ function z(H, G, W, x, M, V, A) {
12808
+ if (x = x || m, V = V || W, A !== a) {
12809
12809
  if (u) {
12810
12810
  var te = /* @__PURE__ */ new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");
12811
12811
  throw te.name = "Invariant Violation", te;
12812
12812
  } else if (process.env.NODE_ENV !== "production" && typeof console < "u") {
12813
12813
  var $e = x + ":" + W;
12814
- !I[$e] && L < 3 && (s("You are manually calling a React.PropTypes validation function for the `" + B + "` prop on `" + x + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."), I[$e] = !0, L++);
12814
+ !I[$e] && L < 3 && (s("You are manually calling a React.PropTypes validation function for the `" + V + "` prop on `" + x + "`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."), I[$e] = !0, L++);
12815
12815
  }
12816
12816
  }
12817
- return G[W] == null ? q ? G[W] === null ? new $("The " + M + " `" + B + "` is marked as required " + ("in `" + x + "`, but its value is `null`.")) : new $("The " + M + " `" + B + "` is marked as required in " + ("`" + x + "`, but its value is `undefined`.")) : null : w(G, W, x, M, B);
12817
+ return G[W] == null ? H ? G[W] === null ? new $("The " + M + " `" + V + "` is marked as required " + ("in `" + x + "`, but its value is `null`.")) : new $("The " + M + " `" + V + "` is marked as required in " + ("`" + x + "`, but its value is `undefined`.")) : null : w(G, W, x, M, V);
12818
12818
  }
12819
12819
  var F = z.bind(null, !1);
12820
12820
  return F.isRequired = z.bind(null, !0), F;
12821
12821
  }
12822
12822
  function S(w) {
12823
- function I(L, z, F, q, G, W) {
12823
+ function I(L, z, F, H, G, W) {
12824
12824
  var x = L[z];
12825
12825
  if (ne(x) !== w) {
12826
12826
  var M = Ce(x);
12827
- return new $("Invalid " + q + " `" + G + "` of type " + ("`" + M + "` supplied to `" + F + "`, expected ") + ("`" + w + "`."), { expectedType: w });
12827
+ return new $("Invalid " + H + " `" + G + "` of type " + ("`" + M + "` supplied to `" + F + "`, expected ") + ("`" + w + "`."), { expectedType: w });
12828
12828
  }
12829
12829
  return null;
12830
12830
  }
@@ -12834,48 +12834,48 @@ var Cd = {
12834
12834
  return g(l);
12835
12835
  }
12836
12836
  function C(w) {
12837
- function I(L, z, F, q, G) {
12837
+ function I(L, z, F, H, G) {
12838
12838
  if (typeof w != "function") return new $("Property `" + G + "` of component `" + F + "` has invalid PropType notation inside arrayOf.");
12839
12839
  var W = L[z];
12840
12840
  if (!Array.isArray(W)) {
12841
12841
  var x = ne(W);
12842
- return new $("Invalid " + q + " `" + G + "` of type " + ("`" + x + "` supplied to `" + F + "`, expected an array."));
12842
+ return new $("Invalid " + H + " `" + G + "` of type " + ("`" + x + "` supplied to `" + F + "`, expected an array."));
12843
12843
  }
12844
12844
  for (var M = 0; M < W.length; M++) {
12845
- var B = w(W, M, F, q, G + "[" + M + "]", a);
12846
- if (B instanceof Error) return B;
12845
+ var V = w(W, M, F, H, G + "[" + M + "]", a);
12846
+ if (V instanceof Error) return V;
12847
12847
  }
12848
12848
  return null;
12849
12849
  }
12850
12850
  return g(I);
12851
12851
  }
12852
12852
  function N() {
12853
- function w(I, L, z, F, q) {
12853
+ function w(I, L, z, F, H) {
12854
12854
  var G = I[L];
12855
12855
  if (!c(G)) {
12856
12856
  var W = ne(G);
12857
- return new $("Invalid " + F + " `" + q + "` of type " + ("`" + W + "` supplied to `" + z + "`, expected a single ReactElement."));
12857
+ return new $("Invalid " + F + " `" + H + "` of type " + ("`" + W + "` supplied to `" + z + "`, expected a single ReactElement."));
12858
12858
  }
12859
12859
  return null;
12860
12860
  }
12861
12861
  return g(w);
12862
12862
  }
12863
12863
  function E() {
12864
- function w(I, L, z, F, q) {
12864
+ function w(I, L, z, F, H) {
12865
12865
  var G = I[L];
12866
12866
  if (!r.isValidElementType(G)) {
12867
12867
  var W = ne(G);
12868
- return new $("Invalid " + F + " `" + q + "` of type " + ("`" + W + "` supplied to `" + z + "`, expected a single ReactElement type."));
12868
+ return new $("Invalid " + F + " `" + H + "` of type " + ("`" + W + "` supplied to `" + z + "`, expected a single ReactElement type."));
12869
12869
  }
12870
12870
  return null;
12871
12871
  }
12872
12872
  return g(w);
12873
12873
  }
12874
12874
  function D(w) {
12875
- function I(L, z, F, q, G) {
12875
+ function I(L, z, F, H, G) {
12876
12876
  if (!(L[z] instanceof w)) {
12877
12877
  var W = w.name || m, x = R(L[z]);
12878
- return new $("Invalid " + q + " `" + G + "` of type " + ("`" + x + "` supplied to `" + F + "`, expected ") + ("instance of `" + W + "`."));
12878
+ return new $("Invalid " + H + " `" + G + "` of type " + ("`" + x + "` supplied to `" + F + "`, expected ") + ("instance of `" + W + "`."));
12879
12879
  }
12880
12880
  return null;
12881
12881
  }
@@ -12884,23 +12884,23 @@ var Cd = {
12884
12884
  function Z(w) {
12885
12885
  if (!Array.isArray(w))
12886
12886
  return process.env.NODE_ENV !== "production" && (arguments.length > 1 ? s("Invalid arguments supplied to oneOf, expected an array, got " + arguments.length + " arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).") : s("Invalid argument supplied to oneOf, expected an array.")), l;
12887
- function I(L, z, F, q, G) {
12887
+ function I(L, z, F, H, G) {
12888
12888
  for (var W = L[z], x = 0; x < w.length; x++) if (b(W, w[x])) return null;
12889
12889
  var M = JSON.stringify(w, function(A, te) {
12890
12890
  return Ce(te) === "symbol" ? String(te) : te;
12891
12891
  });
12892
- return new $("Invalid " + q + " `" + G + "` of value `" + String(W) + "` " + ("supplied to `" + F + "`, expected one of " + M + "."));
12892
+ return new $("Invalid " + H + " `" + G + "` of value `" + String(W) + "` " + ("supplied to `" + F + "`, expected one of " + M + "."));
12893
12893
  }
12894
12894
  return g(I);
12895
12895
  }
12896
12896
  function J(w) {
12897
- function I(L, z, F, q, G) {
12897
+ function I(L, z, F, H, G) {
12898
12898
  if (typeof w != "function") return new $("Property `" + G + "` of component `" + F + "` has invalid PropType notation inside objectOf.");
12899
12899
  var W = L[z], x = ne(W);
12900
- if (x !== "object") return new $("Invalid " + q + " `" + G + "` of type " + ("`" + x + "` supplied to `" + F + "`, expected an object."));
12900
+ if (x !== "object") return new $("Invalid " + H + " `" + G + "` of type " + ("`" + x + "` supplied to `" + F + "`, expected an object."));
12901
12901
  for (var M in W) if (i(W, M)) {
12902
- var B = w(W, M, F, q, G + "." + M, a);
12903
- if (B instanceof Error) return B;
12902
+ var V = w(W, M, F, H, G + "." + M, a);
12903
+ if (V instanceof Error) return V;
12904
12904
  }
12905
12905
  return null;
12906
12906
  }
@@ -12914,9 +12914,9 @@ var Cd = {
12914
12914
  if (typeof L != "function")
12915
12915
  return s("Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + k(L) + " at index " + I + "."), l;
12916
12916
  }
12917
- function z(F, q, G, W, x) {
12918
- for (var M = [], B = 0; B < w.length; B++) {
12919
- var A = w[B], te = A(F, q, G, W, x, a);
12917
+ function z(F, H, G, W, x) {
12918
+ for (var M = [], V = 0; V < w.length; V++) {
12919
+ var A = w[V], te = A(F, H, G, W, x, a);
12920
12920
  if (te == null) return null;
12921
12921
  te.data && i(te.data, "expectedType") && M.push(te.data.expectedType);
12922
12922
  }
@@ -12926,8 +12926,8 @@ var Cd = {
12926
12926
  return g(z);
12927
12927
  }
12928
12928
  function ue() {
12929
- function w(I, L, z, F, q) {
12930
- return ye(I[L]) ? null : new $("Invalid " + F + " `" + q + "` supplied to " + ("`" + z + "`, expected a ReactNode."));
12929
+ function w(I, L, z, F, H) {
12930
+ return ye(I[L]) ? null : new $("Invalid " + F + " `" + H + "` supplied to " + ("`" + z + "`, expected a ReactNode."));
12931
12931
  }
12932
12932
  return g(w);
12933
12933
  }
@@ -12935,13 +12935,13 @@ var Cd = {
12935
12935
  return new $((w || "React class") + ": " + I + " type `" + L + "." + z + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + F + "`.");
12936
12936
  }
12937
12937
  function fe(w) {
12938
- function I(L, z, F, q, G) {
12938
+ function I(L, z, F, H, G) {
12939
12939
  var W = L[z], x = ne(W);
12940
- if (x !== "object") return new $("Invalid " + q + " `" + G + "` of type `" + x + "` " + ("supplied to `" + F + "`, expected `object`."));
12940
+ if (x !== "object") return new $("Invalid " + H + " `" + G + "` of type `" + x + "` " + ("supplied to `" + F + "`, expected `object`."));
12941
12941
  for (var M in w) {
12942
- var B = w[M];
12943
- if (typeof B != "function") return oe(F, q, G, M, Ce(B));
12944
- var A = B(W, M, F, q, G + "." + M, a);
12942
+ var V = w[M];
12943
+ if (typeof V != "function") return oe(F, H, G, M, Ce(V));
12944
+ var A = V(W, M, F, H, G + "." + M, a);
12945
12945
  if (A) return A;
12946
12946
  }
12947
12947
  return null;
@@ -12949,15 +12949,15 @@ var Cd = {
12949
12949
  return g(I);
12950
12950
  }
12951
12951
  function ve(w) {
12952
- function I(L, z, F, q, G) {
12952
+ function I(L, z, F, H, G) {
12953
12953
  var W = L[z], x = ne(W);
12954
- if (x !== "object") return new $("Invalid " + q + " `" + G + "` of type `" + x + "` " + ("supplied to `" + F + "`, expected `object`."));
12954
+ if (x !== "object") return new $("Invalid " + H + " `" + G + "` of type `" + x + "` " + ("supplied to `" + F + "`, expected `object`."));
12955
12955
  for (var M in n({}, L[z], w)) {
12956
- var B = w[M];
12957
- if (i(w, M) && typeof B != "function") return oe(F, q, G, M, Ce(B));
12958
- if (!B) return new $("Invalid " + q + " `" + G + "` key `" + M + "` supplied to `" + F + "`.\nBad object: " + JSON.stringify(L[z], null, " ") + `
12956
+ var V = w[M];
12957
+ if (i(w, M) && typeof V != "function") return oe(F, H, G, M, Ce(V));
12958
+ if (!V) return new $("Invalid " + H + " `" + G + "` key `" + M + "` supplied to `" + F + "`.\nBad object: " + JSON.stringify(L[z], null, " ") + `
12959
12959
  Valid keys: ` + JSON.stringify(Object.keys(w), null, " "));
12960
- var A = B(W, M, F, q, G + "." + M, a);
12960
+ var A = V(W, M, F, H, G + "." + M, a);
12961
12961
  if (A) return A;
12962
12962
  }
12963
12963
  return null;
@@ -13073,7 +13073,7 @@ Valid keys: ` + JSON.stringify(Object.keys(w), null, " "));
13073
13073
  var r = Sd(), n = !0;
13074
13074
  t.exports = z1()(r.isElement, n);
13075
13075
  } else t.exports = G1()();
13076
- })), H1 = /* @__PURE__ */ xe(((e, t) => {
13076
+ })), q1 = /* @__PURE__ */ xe(((e, t) => {
13077
13077
  (function() {
13078
13078
  "use strict";
13079
13079
  var r = {}.hasOwnProperty;
@@ -13101,7 +13101,7 @@ Valid keys: ` + JSON.stringify(Object.keys(w), null, " "));
13101
13101
  }) : window.classNames = n;
13102
13102
  })();
13103
13103
  }));
13104
- function q1(e, t, r) {
13104
+ function H1(e, t, r) {
13105
13105
  switch (r) {
13106
13106
  case "Backspace":
13107
13107
  t > 0 && (e = e.slice(0, t - 1) + e.slice(t), t--);
@@ -13143,13 +13143,13 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
13143
13143
  }
13144
13144
  function Z1(e, t) {
13145
13145
  if (e) {
13146
- if (typeof e == "string") return Hi(e, t);
13146
+ if (typeof e == "string") return qi(e, t);
13147
13147
  var r = Object.prototype.toString.call(e).slice(8, -1);
13148
13148
  if (r === "Object" && e.constructor && (r = e.constructor.name), r === "Map" || r === "Set") return Array.from(e);
13149
- if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return Hi(e, t);
13149
+ if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return qi(e, t);
13150
13150
  }
13151
13151
  }
13152
- function Hi(e, t) {
13152
+ function qi(e, t) {
13153
13153
  (t == null || t > e.length) && (t = e.length);
13154
13154
  for (var r = 0, n = new Array(t); r < t; r++) n[r] = e[r];
13155
13155
  return n;
@@ -13181,13 +13181,13 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
13181
13181
  }
13182
13182
  function Q1(e, t) {
13183
13183
  if (e) {
13184
- if (typeof e == "string") return qi(e, t);
13184
+ if (typeof e == "string") return Hi(e, t);
13185
13185
  var r = Object.prototype.toString.call(e).slice(8, -1);
13186
13186
  if (r === "Object" && e.constructor && (r = e.constructor.name), r === "Map" || r === "Set") return Array.from(e);
13187
- if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return qi(e, t);
13187
+ if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return Hi(e, t);
13188
13188
  }
13189
13189
  }
13190
- function qi(e, t) {
13190
+ function Hi(e, t) {
13191
13191
  (t == null || t > e.length) && (t = e.length);
13192
13192
  for (var r = 0, n = new Array(t); r < t; r++) n[r] = e[r];
13193
13193
  return n;
@@ -13297,7 +13297,7 @@ function c0(e, t) {
13297
13297
  function ra(e, t, r, n, a) {
13298
13298
  var i = K1(e.value, i0(e), t), o = i.value, s = i.caret;
13299
13299
  if (n) {
13300
- var l = q1(o, s, n);
13300
+ var l = H1(o, s, n);
13301
13301
  o = l.value, s = l.caret;
13302
13302
  }
13303
13303
  var c = t0(o, s, r), u = c.text;
@@ -14109,7 +14109,7 @@ function U0(e, t, r) {
14109
14109
  var n = new he(r);
14110
14110
  return n.selectNumberingPlan(t), n.numberingPlan.possibleLengths().indexOf(e.length) >= 0;
14111
14111
  }
14112
- var Se = "0-90-9٠-٩۰-۹", V0 = "-‐-―−ー-", z0 = "//", G0 = "..", W0 = "  ­​⁠ ", H0 = "()()[]\\[\\]", q0 = "~⁓∼~", De = "".concat(V0).concat(z0).concat(G0).concat(W0).concat(H0).concat(q0), ln = "++", K0 = new RegExp("([" + Se + "])");
14112
+ var Se = "0-90-9٠-٩۰-۹", V0 = "-‐-―−ー-", z0 = "//", G0 = "..", W0 = "  ­​⁠ ", q0 = "()()[]\\[\\]", H0 = "~⁓∼~", De = "".concat(V0).concat(z0).concat(G0).concat(W0).concat(q0).concat(H0), ln = "++", K0 = new RegExp("([" + Se + "])");
14113
14113
  function Ad(e, t, r, n) {
14114
14114
  if (t) {
14115
14115
  var a = new he(n);
@@ -14795,8 +14795,8 @@ function Ud(e, t, r) {
14795
14795
  }
14796
14796
  return Bd(e);
14797
14797
  }
14798
- var ho = "([" + Se + "]|[\\-\\.\\(\\)]?)", Bp = "^\\+" + ho + "*[" + Se + "]" + ho + "*$", Up = new RegExp(Bp, "g"), sa = Se, Vp = "[" + sa + "]+((\\-)*[" + sa + "])*", zp = "[a-zA-Z]+((\\-)*[" + sa + "])*", Gp = "^(" + Vp + "\\.)*" + zp + "\\.?$", Wp = new RegExp(Gp, "g"), vo = "tel:", da = ";phone-context=", Hp = ";isub=";
14799
- function qp(e) {
14798
+ var ho = "([" + Se + "]|[\\-\\.\\(\\)]?)", Bp = "^\\+" + ho + "*[" + Se + "]" + ho + "*$", Up = new RegExp(Bp, "g"), sa = Se, Vp = "[" + sa + "]+((\\-)*[" + sa + "])*", zp = "[a-zA-Z]+((\\-)*[" + sa + "])*", Gp = "^(" + Vp + "\\.)*" + zp + "\\.?$", Wp = new RegExp(Gp, "g"), vo = "tel:", da = ";phone-context=", qp = ";isub=";
14799
+ function Hp(e) {
14800
14800
  var t = e.indexOf(da);
14801
14801
  if (t < 0) return null;
14802
14802
  var r = t + da.length;
@@ -14808,7 +14808,7 @@ function Kp(e) {
14808
14808
  return e === null ? !0 : e.length === 0 ? !1 : Up.test(e) || Wp.test(e);
14809
14809
  }
14810
14810
  function Yp(e, t) {
14811
- var r = t.extractFormattedPhoneNumber, n = qp(e);
14811
+ var r = t.extractFormattedPhoneNumber, n = Hp(e);
14812
14812
  if (!Kp(n)) throw new je("NOT_A_NUMBER");
14813
14813
  var a;
14814
14814
  if (n === null) a = r(e) || "";
@@ -14819,7 +14819,7 @@ function Yp(e, t) {
14819
14819
  var s = e.indexOf(da);
14820
14820
  a += e.substring(o, s);
14821
14821
  }
14822
- var l = a.indexOf(Hp);
14822
+ var l = a.indexOf(qp);
14823
14823
  if (l > 0 && (a = a.substring(0, l)), a !== "") return a;
14824
14824
  }
14825
14825
  var Zp = 250, Xp = new RegExp("[" + ln + Se + "]"), Jp = new RegExp("[^" + Se + "#]+$"), Qp = !1;
@@ -15479,7 +15479,7 @@ var zm = /* @__PURE__ */ (function() {
15479
15479
  key: "parsePattern",
15480
15480
  value: function(r) {
15481
15481
  if (!r) throw new Error("Pattern is required");
15482
- var n = r.match(Hm);
15482
+ var n = r.match(qm);
15483
15483
  if (!n) {
15484
15484
  if (Wm.test(r)) throw new Error("Illegal characters found in a pattern: ".concat(r));
15485
15485
  this.getContext().instructions = this.getContext().instructions.concat(r.split(""));
@@ -15540,14 +15540,14 @@ function Gm(e) {
15540
15540
  }
15541
15541
  return t;
15542
15542
  }
15543
- var Wm = /[\(\)\[\]\?\:\|]/, Hm = new RegExp("(\\||\\(\\?\\:|\\)|\\[|\\])");
15543
+ var Wm = /[\(\)\[\]\?\:\|]/, qm = new RegExp("(\\||\\(\\?\\:|\\)|\\[|\\])");
15544
15544
  function Dn(e) {
15545
15545
  return e.length === 1 ? e[0] : e;
15546
15546
  }
15547
15547
  function To(e, t) {
15548
15548
  var r = typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
15549
15549
  if (r) return (r = r.call(e)).next.bind(r);
15550
- if (Array.isArray(e) || (r = qm(e)) || t && e && typeof e.length == "number") {
15550
+ if (Array.isArray(e) || (r = Hm(e)) || t && e && typeof e.length == "number") {
15551
15551
  r && (e = r);
15552
15552
  var n = 0;
15553
15553
  return function() {
@@ -15560,7 +15560,7 @@ function To(e, t) {
15560
15560
  throw new TypeError(`Invalid attempt to iterate non-iterable instance.
15561
15561
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
15562
15562
  }
15563
- function qm(e, t) {
15563
+ function Hm(e, t) {
15564
15564
  if (e) {
15565
15565
  if (typeof e == "string") return Ao(e, t);
15566
15566
  var r = {}.toString.call(e).slice(8, -1);
@@ -15725,23 +15725,23 @@ function Mo(e, t) {
15725
15725
  for (var r = 0, n = Array(t); r < t; r++) n[r] = e[r];
15726
15726
  return n;
15727
15727
  }
15728
- function e2(e, t) {
15728
+ function eh(e, t) {
15729
15729
  if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function");
15730
15730
  }
15731
15731
  function Do(e, t) {
15732
15732
  for (var r = 0; r < t.length; r++) {
15733
15733
  var n = t[r];
15734
- n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(e, r2(n.key), n);
15734
+ n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(e, rh(n.key), n);
15735
15735
  }
15736
15736
  }
15737
- function t2(e, t, r) {
15737
+ function th(e, t, r) {
15738
15738
  return t && Do(e.prototype, t), r && Do(e, r), Object.defineProperty(e, "prototype", { writable: !1 }), e;
15739
15739
  }
15740
- function r2(e) {
15741
- var t = n2(e, "string");
15740
+ function rh(e) {
15741
+ var t = nh(e, "string");
15742
15742
  return zt(t) == "symbol" ? t : t + "";
15743
15743
  }
15744
- function n2(e, t) {
15744
+ function nh(e, t) {
15745
15745
  if (zt(e) != "object" || !e) return e;
15746
15746
  var r = e[Symbol.toPrimitive];
15747
15747
  if (r !== void 0) {
@@ -15751,17 +15751,17 @@ function n2(e, t) {
15751
15751
  }
15752
15752
  return (t === "string" ? String : Number)(e);
15753
15753
  }
15754
- var ca = "9", a2 = vr(ca, 15), i2 = /[- ]/, Lr = !0, o2 = Lr && function() {
15754
+ var ca = "9", ah = vr(ca, 15), ih = /[- ]/, Lr = !0, oh = Lr && function() {
15755
15755
  return /\[([^\[\]])*\]/g;
15756
- }, s2 = Lr && function() {
15756
+ }, sh = Lr && function() {
15757
15757
  return /\d(?=[^,}][^,}])/g;
15758
- }, d2 = new RegExp("[" + De + "]*\\$1[" + De + "]*(\\$\\d[" + De + "]*)*$"), Ro = 3, l2 = /* @__PURE__ */ (function() {
15758
+ }, dh = new RegExp("[" + De + "]*\\$1[" + De + "]*(\\$\\d[" + De + "]*)*$"), Ro = 3, lh = /* @__PURE__ */ (function() {
15759
15759
  function e(t) {
15760
15760
  t.state;
15761
15761
  var r = t.metadata;
15762
- e2(this, e), this.metadata = r, this.resetFormat();
15762
+ eh(this, e), this.metadata = r, this.resetFormat();
15763
15763
  }
15764
- return t2(e, [
15764
+ return th(e, [
15765
15765
  {
15766
15766
  key: "resetFormat",
15767
15767
  value: function() {
@@ -15845,7 +15845,7 @@ var ca = "9", a2 = vr(ca, 15), i2 = /[- ]/, Lr = !0, o2 = Lr && function() {
15845
15845
  value: function(r) {
15846
15846
  for (var n = this, a = function() {
15847
15847
  var c = s.value;
15848
- return n.chosenFormat === c ? 0 : d2.test(n.getFormatFormat(c, r.international)) ? n.createTemplateForFormat(c, r) ? (n.chosenFormat = c, 0) : (n.matchingFormats = n.matchingFormats.filter(function(u) {
15848
+ return n.chosenFormat === c ? 0 : dh.test(n.getFormatFormat(c, r.international)) ? n.createTemplateForFormat(c, r) ? (n.chosenFormat = c, 0) : (n.matchingFormats = n.matchingFormats.filter(function(u) {
15849
15849
  return u !== c;
15850
15850
  }), 1) : 1;
15851
15851
  }, i, o = ko(this.matchingFormats.slice()), s; !(s = o()).done && (i = a(), i !== 0); )
@@ -15866,7 +15866,7 @@ var ca = "9", a2 = vr(ca, 15), i2 = /[- ]/, Lr = !0, o2 = Lr && function() {
15866
15866
  {
15867
15867
  key: "getSeparatorAfterNationalPrefix",
15868
15868
  value: function(r) {
15869
- return this.isNANP || r && r.nationalPrefixFormattingRule() && i2.test(r.nationalPrefixFormattingRule()) ? " " : "";
15869
+ return this.isNANP || r && r.nationalPrefixFormattingRule() && ih.test(r.nationalPrefixFormattingRule()) ? " " : "";
15870
15870
  }
15871
15871
  },
15872
15872
  {
@@ -15896,8 +15896,8 @@ var ca = "9", a2 = vr(ca, 15), i2 = /[- ]/, Lr = !0, o2 = Lr && function() {
15896
15896
  key: "getTemplateForFormat",
15897
15897
  value: function(r, n) {
15898
15898
  var a = n.nationalSignificantNumber, i = n.international, o = n.nationalPrefix, s = n.prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix, l = r.pattern();
15899
- Lr && (l = l.replace(o2(), "\\d").replace(s2(), "\\d"));
15900
- var c = a2.match(l)[0];
15899
+ Lr && (l = l.replace(oh(), "\\d").replace(sh(), "\\d"));
15900
+ var c = ah.match(l)[0];
15901
15901
  if (!(a.length > c.length)) {
15902
15902
  var u = new RegExp("^" + l + "$"), p = a.replace(/\d/g, ca);
15903
15903
  u.test(p) && (c = p);
@@ -15948,13 +15948,13 @@ function Gt(e) {
15948
15948
  }, Gt(e);
15949
15949
  }
15950
15950
  function Gd(e, t) {
15951
- return p2(e) || f2(e, t) || u2(e, t) || c2();
15951
+ return ph(e) || fh(e, t) || uh(e, t) || ch();
15952
15952
  }
15953
- function c2() {
15953
+ function ch() {
15954
15954
  throw new TypeError(`Invalid attempt to destructure non-iterable instance.
15955
15955
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
15956
15956
  }
15957
- function u2(e, t) {
15957
+ function uh(e, t) {
15958
15958
  if (e) {
15959
15959
  if (typeof e == "string") return Fo(e, t);
15960
15960
  var r = {}.toString.call(e).slice(8, -1);
@@ -15966,7 +15966,7 @@ function Fo(e, t) {
15966
15966
  for (var r = 0, n = Array(t); r < t; r++) n[r] = e[r];
15967
15967
  return n;
15968
15968
  }
15969
- function f2(e, t) {
15969
+ function fh(e, t) {
15970
15970
  var r = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
15971
15971
  if (r != null) {
15972
15972
  var n, a, i, o, s = [], l = !0, c = !1;
@@ -15987,26 +15987,26 @@ function f2(e, t) {
15987
15987
  return s;
15988
15988
  }
15989
15989
  }
15990
- function p2(e) {
15990
+ function ph(e) {
15991
15991
  if (Array.isArray(e)) return e;
15992
15992
  }
15993
- function m2(e, t) {
15993
+ function mh(e, t) {
15994
15994
  if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function");
15995
15995
  }
15996
15996
  function Lo(e, t) {
15997
15997
  for (var r = 0; r < t.length; r++) {
15998
15998
  var n = t[r];
15999
- n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(e, v2(n.key), n);
15999
+ n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(e, vh(n.key), n);
16000
16000
  }
16001
16001
  }
16002
- function h2(e, t, r) {
16002
+ function hh(e, t, r) {
16003
16003
  return t && Lo(e.prototype, t), r && Lo(e, r), Object.defineProperty(e, "prototype", { writable: !1 }), e;
16004
16004
  }
16005
- function v2(e) {
16006
- var t = y2(e, "string");
16005
+ function vh(e) {
16006
+ var t = yh(e, "string");
16007
16007
  return Gt(t) == "symbol" ? t : t + "";
16008
16008
  }
16009
- function y2(e, t) {
16009
+ function yh(e, t) {
16010
16010
  if (Gt(e) != "object" || !e) return e;
16011
16011
  var r = e[Symbol.toPrimitive];
16012
16012
  if (r !== void 0) {
@@ -16016,16 +16016,16 @@ function y2(e, t) {
16016
16016
  }
16017
16017
  return (t === "string" ? String : Number)(e);
16018
16018
  }
16019
- var $2 = "[" + De + Se + "]+", g2 = new RegExp("^" + $2 + "$", "i"), b2 = "(?:[" + ln + "][" + De + Se + "]*|[" + De + Se + "]+)", N2 = new RegExp("[^" + De + Se + "]+.*$"), C2 = /[^\d\[\]]/, S2 = /* @__PURE__ */ (function() {
16019
+ var $h = "[" + De + Se + "]+", gh = new RegExp("^" + $h + "$", "i"), bh = "(?:[" + ln + "][" + De + Se + "]*|[" + De + Se + "]+)", Nh = new RegExp("[^" + De + Se + "]+.*$"), Ch = /[^\d\[\]]/, Sh = /* @__PURE__ */ (function() {
16020
16020
  function e(t) {
16021
16021
  var r = t.defaultCountry, n = t.defaultCallingCode, a = t.metadata, i = t.onNationalSignificantNumberChange;
16022
- m2(this, e), this.defaultCountry = r, this.defaultCallingCode = n, this.metadata = a, this.onNationalSignificantNumberChange = i;
16022
+ mh(this, e), this.defaultCountry = r, this.defaultCallingCode = n, this.metadata = a, this.onNationalSignificantNumberChange = i;
16023
16023
  }
16024
- return h2(e, [
16024
+ return hh(e, [
16025
16025
  {
16026
16026
  key: "input",
16027
16027
  value: function(r, n) {
16028
- var a = Gd(_2(r), 2), i = a[0], o = a[1], s = Fr(i), l;
16028
+ var a = Gd(_h(r), 2), i = a[0], o = a[1], s = Fr(i), l;
16029
16029
  return o && (n.digits || (n.startInternationalNumber(void 0, void 0), s || (l = !0))), s && this.inputDigits(s, n), {
16030
16030
  digits: s,
16031
16031
  justLeadingPlus: l
@@ -16065,7 +16065,7 @@ var $2 = "[" + De + Se + "]+", g2 = new RegExp("^" + $2 + "$", "i"), b2 = "(?:["
16065
16065
  if (r) {
16066
16066
  this.hasSelectedNumberingPlan = !0;
16067
16067
  var n = r._nationalPrefixForParsing();
16068
- this.couldPossiblyExtractAnotherNationalSignificantNumber = n && C2.test(n);
16068
+ this.couldPossiblyExtractAnotherNationalSignificantNumber = n && Ch.test(n);
16069
16069
  } else
16070
16070
  this.hasSelectedNumberingPlan = void 0, this.couldPossiblyExtractAnotherNationalSignificantNumber = void 0;
16071
16071
  }
@@ -16165,21 +16165,21 @@ var $2 = "[" + De + Se + "]+", g2 = new RegExp("^" + $2 + "$", "i"), b2 = "(?:["
16165
16165
  }
16166
16166
  ]);
16167
16167
  })();
16168
- function P2(e) {
16169
- var t = e.search(b2);
16168
+ function Ph(e) {
16169
+ var t = e.search(bh);
16170
16170
  if (!(t < 0)) {
16171
16171
  e = e.slice(t);
16172
16172
  var r;
16173
- return e[0] === "+" && (r = !0, e = e.slice(1)), e = e.replace(N2, ""), r && (e = "+" + e), e;
16173
+ return e[0] === "+" && (r = !0, e = e.slice(1)), e = e.replace(Nh, ""), r && (e = "+" + e), e;
16174
16174
  }
16175
16175
  }
16176
- function w2(e) {
16177
- var t = P2(e) || "";
16176
+ function wh(e) {
16177
+ var t = Ph(e) || "";
16178
16178
  return t[0] === "+" ? [t.slice(1), !0] : [t];
16179
16179
  }
16180
- function _2(e) {
16181
- var t = Gd(w2(e), 2), r = t[0], n = t[1];
16182
- return g2.test(r) || (r = ""), [r, n];
16180
+ function _h(e) {
16181
+ var t = Gd(wh(e), 2), r = t[0], n = t[1];
16182
+ return gh.test(r) || (r = ""), [r, n];
16183
16183
  }
16184
16184
  function Wt(e) {
16185
16185
  "@babel/helpers - typeof";
@@ -16189,14 +16189,14 @@ function Wt(e) {
16189
16189
  return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
16190
16190
  }, Wt(e);
16191
16191
  }
16192
- function O2(e, t) {
16193
- return A2(e) || T2(e, t) || I2(e, t) || E2();
16192
+ function Oh(e, t) {
16193
+ return Ah(e) || Th(e, t) || Ih(e, t) || Eh();
16194
16194
  }
16195
- function E2() {
16195
+ function Eh() {
16196
16196
  throw new TypeError(`Invalid attempt to destructure non-iterable instance.
16197
16197
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
16198
16198
  }
16199
- function I2(e, t) {
16199
+ function Ih(e, t) {
16200
16200
  if (e) {
16201
16201
  if (typeof e == "string") return jo(e, t);
16202
16202
  var r = {}.toString.call(e).slice(8, -1);
@@ -16208,7 +16208,7 @@ function jo(e, t) {
16208
16208
  for (var r = 0, n = Array(t); r < t; r++) n[r] = e[r];
16209
16209
  return n;
16210
16210
  }
16211
- function T2(e, t) {
16211
+ function Th(e, t) {
16212
16212
  var r = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
16213
16213
  if (r != null) {
16214
16214
  var n, a, i, o, s = [], l = !0, c = !1;
@@ -16229,26 +16229,26 @@ function T2(e, t) {
16229
16229
  return s;
16230
16230
  }
16231
16231
  }
16232
- function A2(e) {
16232
+ function Ah(e) {
16233
16233
  if (Array.isArray(e)) return e;
16234
16234
  }
16235
- function x2(e, t) {
16235
+ function xh(e, t) {
16236
16236
  if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function");
16237
16237
  }
16238
16238
  function Bo(e, t) {
16239
16239
  for (var r = 0; r < t.length; r++) {
16240
16240
  var n = t[r];
16241
- n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(e, M2(n.key), n);
16241
+ n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(e, Mh(n.key), n);
16242
16242
  }
16243
16243
  }
16244
- function k2(e, t, r) {
16244
+ function kh(e, t, r) {
16245
16245
  return t && Bo(e.prototype, t), r && Bo(e, r), Object.defineProperty(e, "prototype", { writable: !1 }), e;
16246
16246
  }
16247
- function M2(e) {
16248
- var t = D2(e, "string");
16247
+ function Mh(e) {
16248
+ var t = Dh(e, "string");
16249
16249
  return Wt(t) == "symbol" ? t : t + "";
16250
16250
  }
16251
- function D2(e, t) {
16251
+ function Dh(e, t) {
16252
16252
  if (Wt(e) != "object" || !e) return e;
16253
16253
  var r = e[Symbol.toPrimitive];
16254
16254
  if (r !== void 0) {
@@ -16260,11 +16260,11 @@ function D2(e, t) {
16260
16260
  }
16261
16261
  var Uo = !1, _t = /* @__PURE__ */ (function() {
16262
16262
  function e(t, r) {
16263
- x2(this, e), this.metadata = new he(r);
16264
- var n = O2(this.getCountryAndCallingCode(t), 2), a = n[0], i = n[1];
16263
+ xh(this, e), this.metadata = new he(r);
16264
+ var n = Oh(this.getCountryAndCallingCode(t), 2), a = n[0], i = n[1];
16265
16265
  this.defaultCountry = a, this.defaultCallingCode = i, this.reset();
16266
16266
  }
16267
- return k2(e, [
16267
+ return kh(e, [
16268
16268
  {
16269
16269
  key: "getCountryAndCallingCode",
16270
16270
  value: function(r) {
@@ -16301,10 +16301,10 @@ var Uo = !1, _t = /* @__PURE__ */ (function() {
16301
16301
  onCallingCodeChange: function(a, i) {
16302
16302
  r.metadata.selectNumberingPlan(i, a), r.formatter.reset(r.metadata.numberingPlan, r.state), r.parser.reset(r.metadata.numberingPlan);
16303
16303
  }
16304
- }), this.formatter = new l2({
16304
+ }), this.formatter = new lh({
16305
16305
  state: this.state,
16306
16306
  metadata: this.metadata
16307
- }), this.parser = new S2({
16307
+ }), this.parser = new Sh({
16308
16308
  defaultCountry: this.defaultCountry,
16309
16309
  defaultCallingCode: this.defaultCallingCode,
16310
16310
  metadata: this.metadata,
@@ -16475,10 +16475,10 @@ var Uo = !1, _t = /* @__PURE__ */ (function() {
16475
16475
  function Vo(e) {
16476
16476
  return new he(e).getCountries();
16477
16477
  }
16478
- function R2(e, t, r) {
16478
+ function Rh(e, t, r) {
16479
16479
  return r || (r = t, t = void 0), new _t(t, r).input(e);
16480
16480
  }
16481
- var jr = /* @__PURE__ */ Na(H1(), 1);
16481
+ var jr = /* @__PURE__ */ Na(q1(), 1);
16482
16482
  function Wd(e) {
16483
16483
  var t = e.inputFormat, r = e.country, n = e.metadata;
16484
16484
  return t === "NATIONAL_PART_OF_INTERNATIONAL" ? "+".concat(Ke(r, n)) : "";
@@ -16486,26 +16486,26 @@ function Wd(e) {
16486
16486
  function ua(e, t) {
16487
16487
  return t && (e = e.slice(t.length), e[0] === " " && (e = e.slice(1))), e;
16488
16488
  }
16489
- function F2(e, t, r) {
16489
+ function Fh(e, t, r) {
16490
16490
  if (!(r && r.ignoreRest))
16491
16491
  return Ud(e, t, function(a) {
16492
16492
  r && a === "end" && (r.ignoreRest = !0);
16493
16493
  });
16494
16494
  }
16495
- function Hd(e) {
16495
+ function qd(e) {
16496
16496
  var t = e.onKeyDown, r = e.inputFormat;
16497
16497
  return Be(function(n) {
16498
- if (n.keyCode === j2 && r === "INTERNATIONAL" && n.target instanceof HTMLInputElement && L2(n.target) === B2.length) {
16498
+ if (n.keyCode === jh && r === "INTERNATIONAL" && n.target instanceof HTMLInputElement && Lh(n.target) === Bh.length) {
16499
16499
  n.preventDefault();
16500
16500
  return;
16501
16501
  }
16502
16502
  t && t(n);
16503
16503
  }, [t, r]);
16504
16504
  }
16505
- function L2(e) {
16505
+ function Lh(e) {
16506
16506
  return e.selectionStart;
16507
16507
  }
16508
- var j2 = 8, B2 = "+", U2 = [
16508
+ var jh = 8, Bh = "+", Uh = [
16509
16509
  "onKeyDown",
16510
16510
  "country",
16511
16511
  "inputFormat",
@@ -16522,9 +16522,9 @@ function fa() {
16522
16522
  return e;
16523
16523
  }, fa.apply(this, arguments);
16524
16524
  }
16525
- function V2(e, t) {
16525
+ function Vh(e, t) {
16526
16526
  if (e == null) return {};
16527
- var r = z2(e, t), n, a;
16527
+ var r = zh(e, t), n, a;
16528
16528
  if (Object.getOwnPropertySymbols) {
16529
16529
  var i = Object.getOwnPropertySymbols(e);
16530
16530
  for (a = 0; a < i.length; a++)
@@ -16532,18 +16532,18 @@ function V2(e, t) {
16532
16532
  }
16533
16533
  return r;
16534
16534
  }
16535
- function z2(e, t) {
16535
+ function zh(e, t) {
16536
16536
  if (e == null) return {};
16537
16537
  var r = {}, n = Object.keys(e), a, i;
16538
16538
  for (i = 0; i < n.length; i++)
16539
16539
  a = n[i], !(t.indexOf(a) >= 0) && (r[a] = e[a]);
16540
16540
  return r;
16541
16541
  }
16542
- function G2(e) {
16542
+ function Gh(e) {
16543
16543
  function t(r, n) {
16544
16544
  var a = r.onKeyDown, i = r.country, o = r.inputFormat, s = r.metadata, l = s === void 0 ? e : s;
16545
16545
  r.international, r.withCountryCallingCode;
16546
- var c = V2(r, U2), u = Be(function(f) {
16546
+ var c = Vh(r, Uh), u = Be(function(f) {
16547
16547
  var v = new _t(i, l), m = Wd({
16548
16548
  inputFormat: o,
16549
16549
  country: i,
@@ -16553,13 +16553,13 @@ function G2(e) {
16553
16553
  text: y,
16554
16554
  template: b
16555
16555
  };
16556
- }, [i, l]), p = Hd({
16556
+ }, [i, l]), p = qd({
16557
16557
  onKeyDown: a,
16558
16558
  inputFormat: o
16559
16559
  });
16560
16560
  return /* @__PURE__ */ j.createElement(N0, fa({}, c, {
16561
16561
  ref: n,
16562
- parse: F2,
16562
+ parse: Fh,
16563
16563
  format: u,
16564
16564
  onKeyDown: p
16565
16565
  }));
@@ -16578,7 +16578,7 @@ function G2(e) {
16578
16578
  metadata: O.default.object
16579
16579
  }, t;
16580
16580
  }
16581
- var W2 = G2(), H2 = [
16581
+ var Wh = Gh(), qh = [
16582
16582
  "value",
16583
16583
  "onChange",
16584
16584
  "onKeyDown",
@@ -16598,9 +16598,9 @@ function pa() {
16598
16598
  return e;
16599
16599
  }, pa.apply(this, arguments);
16600
16600
  }
16601
- function q2(e, t) {
16601
+ function Hh(e, t) {
16602
16602
  if (e == null) return {};
16603
- var r = K2(e, t), n, a;
16603
+ var r = Kh(e, t), n, a;
16604
16604
  if (Object.getOwnPropertySymbols) {
16605
16605
  var i = Object.getOwnPropertySymbols(e);
16606
16606
  for (a = 0; a < i.length; a++)
@@ -16608,18 +16608,18 @@ function q2(e, t) {
16608
16608
  }
16609
16609
  return r;
16610
16610
  }
16611
- function K2(e, t) {
16611
+ function Kh(e, t) {
16612
16612
  if (e == null) return {};
16613
16613
  var r = {}, n = Object.keys(e), a, i;
16614
16614
  for (i = 0; i < n.length; i++)
16615
16615
  a = n[i], !(t.indexOf(a) >= 0) && (r[a] = e[a]);
16616
16616
  return r;
16617
16617
  }
16618
- function Y2(e) {
16618
+ function Yh(e) {
16619
16619
  function t(r, n) {
16620
16620
  var a = r.value, i = r.onChange, o = r.onKeyDown, s = r.country, l = r.inputFormat, c = r.metadata, u = c === void 0 ? e : c, p = r.inputComponent, f = p === void 0 ? "input" : p;
16621
16621
  r.international, r.withCountryCallingCode;
16622
- var v = q2(r, H2), m = Wd({
16622
+ var v = Hh(r, qh), m = Wd({
16623
16623
  inputFormat: l,
16624
16624
  country: s,
16625
16625
  metadata: u
@@ -16632,7 +16632,7 @@ function Y2(e) {
16632
16632
  i,
16633
16633
  s,
16634
16634
  u
16635
- ]), b = Hd({
16635
+ ]), b = qd({
16636
16636
  onKeyDown: o,
16637
16637
  inputFormat: l
16638
16638
  });
@@ -16658,23 +16658,23 @@ function Y2(e) {
16658
16658
  inputComponent: O.default.elementType
16659
16659
  }, t;
16660
16660
  }
16661
- var Z2 = Y2();
16661
+ var Zh = Yh();
16662
16662
  function zo(e, t, r, n) {
16663
- return ua(R2(e + t, r, n), e);
16663
+ return ua(Rh(e + t, r, n), e);
16664
16664
  }
16665
- function X2(e) {
16665
+ function Xh(e) {
16666
16666
  return Go(e[0]) + Go(e[1]);
16667
16667
  }
16668
16668
  function Go(e) {
16669
16669
  return String.fromCodePoint(127397 + e.toUpperCase().charCodeAt(0));
16670
16670
  }
16671
- var J2 = [
16671
+ var Jh = [
16672
16672
  "value",
16673
16673
  "onChange",
16674
16674
  "options",
16675
16675
  "disabled",
16676
16676
  "readOnly"
16677
- ], Q2 = [
16677
+ ], Qh = [
16678
16678
  "value",
16679
16679
  "options",
16680
16680
  "className",
@@ -16683,10 +16683,10 @@ var J2 = [
16683
16683
  "arrowComponent",
16684
16684
  "unicodeFlags"
16685
16685
  ];
16686
- function eh(e, t) {
16686
+ function e2(e, t) {
16687
16687
  var r = typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
16688
16688
  if (r) return (r = r.call(e)).next.bind(r);
16689
- if (Array.isArray(e) || (r = th(e)) || t && e && typeof e.length == "number") {
16689
+ if (Array.isArray(e) || (r = t2(e)) || t && e && typeof e.length == "number") {
16690
16690
  r && (e = r);
16691
16691
  var n = 0;
16692
16692
  return function() {
@@ -16699,7 +16699,7 @@ function eh(e, t) {
16699
16699
  throw new TypeError(`Invalid attempt to iterate non-iterable instance.
16700
16700
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
16701
16701
  }
16702
- function th(e, t) {
16702
+ function t2(e, t) {
16703
16703
  if (e) {
16704
16704
  if (typeof e == "string") return Wo(e, t);
16705
16705
  var r = Object.prototype.toString.call(e).slice(8, -1);
@@ -16721,9 +16721,9 @@ function Br() {
16721
16721
  return e;
16722
16722
  }, Br.apply(this, arguments);
16723
16723
  }
16724
- function qd(e, t) {
16724
+ function Hd(e, t) {
16725
16725
  if (e == null) return {};
16726
- var r = rh(e, t), n, a;
16726
+ var r = r2(e, t), n, a;
16727
16727
  if (Object.getOwnPropertySymbols) {
16728
16728
  var i = Object.getOwnPropertySymbols(e);
16729
16729
  for (a = 0; a < i.length; a++)
@@ -16731,7 +16731,7 @@ function qd(e, t) {
16731
16731
  }
16732
16732
  return r;
16733
16733
  }
16734
- function rh(e, t) {
16734
+ function r2(e, t) {
16735
16735
  if (e == null) return {};
16736
16736
  var r = {}, n = Object.keys(e), a, i;
16737
16737
  for (i = 0; i < n.length; i++)
@@ -16739,7 +16739,7 @@ function rh(e, t) {
16739
16739
  return r;
16740
16740
  }
16741
16741
  function Kd(e) {
16742
- var t = e.value, r = e.onChange, n = e.options, a = e.disabled, i = e.readOnly, o = qd(e, J2), s = Be(function(l) {
16742
+ var t = e.value, r = e.onChange, n = e.options, a = e.disabled, i = e.readOnly, o = Hd(e, Jh), s = Be(function(l) {
16743
16743
  var c = l.target.value;
16744
16744
  r(c === "ZZ" ? void 0 : c);
16745
16745
  }, [r]);
@@ -16756,7 +16756,7 @@ function Kd(e) {
16756
16756
  key: p ? "|" : c || "ZZ",
16757
16757
  value: p ? "|" : c || "ZZ",
16758
16758
  disabled: !!p,
16759
- style: p ? nh : void 0
16759
+ style: p ? n2 : void 0
16760
16760
  }, u);
16761
16761
  }));
16762
16762
  }
@@ -16771,7 +16771,7 @@ Kd.propTypes = {
16771
16771
  disabled: O.default.bool,
16772
16772
  readOnly: O.default.bool
16773
16773
  };
16774
- var nh = {
16774
+ var n2 = {
16775
16775
  fontSize: "1px",
16776
16776
  backgroundColor: "currentColor",
16777
16777
  color: "inherit"
@@ -16779,14 +16779,14 @@ var nh = {
16779
16779
  function Yd(e) {
16780
16780
  var t = e.value, r = e.options, n = e.className, a = e.iconComponent;
16781
16781
  e.getIconAspectRatio;
16782
- var i = e.arrowComponent, o = i === void 0 ? ah : i, s = e.unicodeFlags, l = qd(e, Q2), c = ce(function() {
16782
+ var i = e.arrowComponent, o = i === void 0 ? a2 : i, s = e.unicodeFlags, l = Hd(e, Qh), c = ce(function() {
16783
16783
  return Zd(r, t);
16784
16784
  }, [r, t]);
16785
16785
  return /* @__PURE__ */ j.createElement("div", { className: "PhoneInputCountry" }, /* @__PURE__ */ j.createElement(Kd, Br({}, l, {
16786
16786
  value: t,
16787
16787
  options: r,
16788
16788
  className: (0, jr.default)("PhoneInputCountrySelect", n)
16789
- })), c && (s && t ? /* @__PURE__ */ j.createElement("div", { className: "PhoneInputCountryIconUnicode" }, X2(t)) : /* @__PURE__ */ j.createElement(a, {
16789
+ })), c && (s && t ? /* @__PURE__ */ j.createElement("div", { className: "PhoneInputCountryIconUnicode" }, Xh(t)) : /* @__PURE__ */ j.createElement(a, {
16790
16790
  "aria-hidden": !0,
16791
16791
  country: t,
16792
16792
  label: c.label,
@@ -16798,20 +16798,20 @@ Yd.propTypes = {
16798
16798
  arrowComponent: O.default.elementType,
16799
16799
  unicodeFlags: O.default.bool
16800
16800
  };
16801
- function ah() {
16801
+ function a2() {
16802
16802
  return /* @__PURE__ */ j.createElement("div", { className: "PhoneInputCountrySelectArrow" });
16803
16803
  }
16804
16804
  function Zd(e, t) {
16805
- for (var r = eh(e), n; !(n = r()).done; ) {
16805
+ for (var r = e2(e), n; !(n = r()).done; ) {
16806
16806
  var a = n.value;
16807
- if (!a.divider && ih(a.value, t))
16807
+ if (!a.divider && i2(a.value, t))
16808
16808
  return a;
16809
16809
  }
16810
16810
  }
16811
- function ih(e, t) {
16811
+ function i2(e, t) {
16812
16812
  return e == null ? t == null : e === t;
16813
16813
  }
16814
- var oh = [
16814
+ var o2 = [
16815
16815
  "country",
16816
16816
  "countryName",
16817
16817
  "flags",
@@ -16826,9 +16826,9 @@ function ma() {
16826
16826
  return e;
16827
16827
  }, ma.apply(this, arguments);
16828
16828
  }
16829
- function sh(e, t) {
16829
+ function s2(e, t) {
16830
16830
  if (e == null) return {};
16831
- var r = dh(e, t), n, a;
16831
+ var r = d2(e, t), n, a;
16832
16832
  if (Object.getOwnPropertySymbols) {
16833
16833
  var i = Object.getOwnPropertySymbols(e);
16834
16834
  for (a = 0; a < i.length; a++)
@@ -16836,7 +16836,7 @@ function sh(e, t) {
16836
16836
  }
16837
16837
  return r;
16838
16838
  }
16839
- function dh(e, t) {
16839
+ function d2(e, t) {
16840
16840
  if (e == null) return {};
16841
16841
  var r = {}, n = Object.keys(e), a, i;
16842
16842
  for (i = 0; i < n.length; i++)
@@ -16844,7 +16844,7 @@ function dh(e, t) {
16844
16844
  return r;
16845
16845
  }
16846
16846
  function za(e) {
16847
- var t = e.country, r = e.countryName, n = e.flags, a = e.flagUrl, i = sh(e, oh);
16847
+ var t = e.country, r = e.countryName, n = e.flags, a = e.flagUrl, i = s2(e, o2);
16848
16848
  return n && n[t] ? n[t]({ title: r }) : /* @__PURE__ */ j.createElement("img", ma({}, i, {
16849
16849
  alt: r,
16850
16850
  role: r ? void 0 : "presentation",
@@ -16857,7 +16857,7 @@ za.propTypes = {
16857
16857
  flags: O.default.objectOf(O.default.elementType),
16858
16858
  flagUrl: O.default.string.isRequired
16859
16859
  };
16860
- var lh = ["aspectRatio"], ch = ["title"], uh = ["title"];
16860
+ var l2 = ["aspectRatio"], c2 = ["title"], u2 = ["title"];
16861
16861
  function Ur() {
16862
16862
  return Ur = Object.assign ? Object.assign.bind() : function(e) {
16863
16863
  for (var t = 1; t < arguments.length; t++) {
@@ -16869,7 +16869,7 @@ function Ur() {
16869
16869
  }
16870
16870
  function Ga(e, t) {
16871
16871
  if (e == null) return {};
16872
- var r = fh(e, t), n, a;
16872
+ var r = f2(e, t), n, a;
16873
16873
  if (Object.getOwnPropertySymbols) {
16874
16874
  var i = Object.getOwnPropertySymbols(e);
16875
16875
  for (a = 0; a < i.length; a++)
@@ -16877,7 +16877,7 @@ function Ga(e, t) {
16877
16877
  }
16878
16878
  return r;
16879
16879
  }
16880
- function fh(e, t) {
16880
+ function f2(e, t) {
16881
16881
  if (e == null) return {};
16882
16882
  var r = {}, n = Object.keys(e), a, i;
16883
16883
  for (i = 0; i < n.length; i++)
@@ -16885,7 +16885,7 @@ function fh(e, t) {
16885
16885
  return r;
16886
16886
  }
16887
16887
  function cn(e) {
16888
- var t = e.aspectRatio, r = Ga(e, lh);
16888
+ var t = e.aspectRatio, r = Ga(e, l2);
16889
16889
  return t === 1 ? /* @__PURE__ */ j.createElement(Jd, r) : /* @__PURE__ */ j.createElement(Xd, r);
16890
16890
  }
16891
16891
  cn.propTypes = {
@@ -16893,7 +16893,7 @@ cn.propTypes = {
16893
16893
  aspectRatio: O.default.number
16894
16894
  };
16895
16895
  function Xd(e) {
16896
- var t = e.title, r = Ga(e, ch);
16896
+ var t = e.title, r = Ga(e, c2);
16897
16897
  return /* @__PURE__ */ j.createElement("svg", Ur({}, r, {
16898
16898
  xmlns: "http://www.w3.org/2000/svg",
16899
16899
  viewBox: "0 0 75 50"
@@ -16931,7 +16931,7 @@ function Xd(e) {
16931
16931
  }
16932
16932
  Xd.propTypes = { title: O.default.string.isRequired };
16933
16933
  function Jd(e) {
16934
- var t = e.title, r = Ga(e, uh);
16934
+ var t = e.title, r = Ga(e, u2);
16935
16935
  return /* @__PURE__ */ j.createElement("svg", Ur({}, r, {
16936
16936
  xmlns: "http://www.w3.org/2000/svg",
16937
16937
  viewBox: "0 0 50 50"
@@ -16959,7 +16959,7 @@ function Jd(e) {
16959
16959
  }));
16960
16960
  }
16961
16961
  Jd.propTypes = { title: O.default.string.isRequired };
16962
- function ph(e) {
16962
+ function p2(e) {
16963
16963
  if (e.length < 2 || e[0] !== "+") return !1;
16964
16964
  for (var t = 1; t < e.length; ) {
16965
16965
  var r = e.charCodeAt(t);
@@ -16970,12 +16970,12 @@ function ph(e) {
16970
16970
  return !0;
16971
16971
  }
16972
16972
  function Qd(e) {
16973
- ph(e) || console.error("[react-phone-number-input] Expected the initial `value` to be a E.164 phone number. Got", e);
16973
+ p2(e) || console.error("[react-phone-number-input] Expected the initial `value` to be a E.164 phone number. Got", e);
16974
16974
  }
16975
- function mh(e, t) {
16975
+ function m2(e, t) {
16976
16976
  var r = typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
16977
16977
  if (r) return (r = r.call(e)).next.bind(r);
16978
- if (Array.isArray(e) || (r = hh(e)) || t && e && typeof e.length == "number") {
16978
+ if (Array.isArray(e) || (r = h2(e)) || t && e && typeof e.length == "number") {
16979
16979
  r && (e = r);
16980
16980
  var n = 0;
16981
16981
  return function() {
@@ -16988,20 +16988,20 @@ function mh(e, t) {
16988
16988
  throw new TypeError(`Invalid attempt to iterate non-iterable instance.
16989
16989
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
16990
16990
  }
16991
- function hh(e, t) {
16991
+ function h2(e, t) {
16992
16992
  if (e) {
16993
- if (typeof e == "string") return Ho(e, t);
16993
+ if (typeof e == "string") return qo(e, t);
16994
16994
  var r = Object.prototype.toString.call(e).slice(8, -1);
16995
16995
  if (r === "Object" && e.constructor && (r = e.constructor.name), r === "Map" || r === "Set") return Array.from(e);
16996
- if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return Ho(e, t);
16996
+ if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return qo(e, t);
16997
16997
  }
16998
16998
  }
16999
- function Ho(e, t) {
16999
+ function qo(e, t) {
17000
17000
  (t == null || t > e.length) && (t = e.length);
17001
17001
  for (var r = 0, n = new Array(t); r < t; r++) n[r] = e[r];
17002
17002
  return n;
17003
17003
  }
17004
- function vh(e, t) {
17004
+ function v2(e, t) {
17005
17005
  if (!t) return e;
17006
17006
  for (var r = [], n = [], a = r, i = function() {
17007
17007
  var c = s.value;
@@ -17015,10 +17015,10 @@ function vh(e, t) {
17015
17015
  })[0]), f = e[p];
17016
17016
  e.splice(p, 1), a.push(f);
17017
17017
  }
17018
- }, o = mh(t), s; !(s = o()).done; ) i();
17018
+ }, o = m2(t), s; !(s = o()).done; ) i();
17019
17019
  return r.concat(e).concat(n);
17020
17020
  }
17021
- function yh(e, t) {
17021
+ function y2(e, t) {
17022
17022
  if (e && (e = e.filter(function(r) {
17023
17023
  switch (r) {
17024
17024
  case "🌐":
@@ -17040,7 +17040,7 @@ function el(e, t) {
17040
17040
  return un(r, t);
17041
17041
  }), e.length === 0 && (e = void 0)), e;
17042
17042
  }
17043
- var $h = [
17043
+ var $2 = [
17044
17044
  "country",
17045
17045
  "label",
17046
17046
  "aspectRatio"
@@ -17054,9 +17054,9 @@ function ha() {
17054
17054
  return e;
17055
17055
  }, ha.apply(this, arguments);
17056
17056
  }
17057
- function gh(e, t) {
17057
+ function g2(e, t) {
17058
17058
  if (e == null) return {};
17059
- var r = bh(e, t), n, a;
17059
+ var r = b2(e, t), n, a;
17060
17060
  if (Object.getOwnPropertySymbols) {
17061
17061
  var i = Object.getOwnPropertySymbols(e);
17062
17062
  for (a = 0; a < i.length; a++)
@@ -17064,7 +17064,7 @@ function gh(e, t) {
17064
17064
  }
17065
17065
  return r;
17066
17066
  }
17067
- function bh(e, t) {
17067
+ function b2(e, t) {
17068
17068
  if (e == null) return {};
17069
17069
  var r = {}, n = Object.keys(e), a, i;
17070
17070
  for (i = 0; i < n.length; i++)
@@ -17074,7 +17074,7 @@ function bh(e, t) {
17074
17074
  function tl(e) {
17075
17075
  var t = e.flags, r = e.flagUrl, n = e.flagComponent, a = e.internationalIcon;
17076
17076
  function i(o) {
17077
- var s = o.country, l = o.label, c = o.aspectRatio, u = gh(o, $h), p = a === cn ? c : void 0;
17077
+ var s = o.country, l = o.label, c = o.aspectRatio, u = g2(o, $2), p = a === cn ? c : void 0;
17078
17078
  return /* @__PURE__ */ j.createElement("div", ha({}, u, { className: (0, jr.default)("PhoneInputCountryIcon", {
17079
17079
  "PhoneInputCountryIcon--square": p === 1,
17080
17080
  "PhoneInputCountryIcon--border": s
@@ -17101,10 +17101,10 @@ var Jv = tl({
17101
17101
  flagComponent: za,
17102
17102
  internationalIcon: cn
17103
17103
  });
17104
- function Nh(e, t) {
17104
+ function N2(e, t) {
17105
17105
  var r = typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
17106
17106
  if (r) return (r = r.call(e)).next.bind(r);
17107
- if (Array.isArray(e) || (r = Ch(e)) || t && e && typeof e.length == "number") {
17107
+ if (Array.isArray(e) || (r = C2(e)) || t && e && typeof e.length == "number") {
17108
17108
  r && (e = r);
17109
17109
  var n = 0;
17110
17110
  return function() {
@@ -17117,26 +17117,26 @@ function Nh(e, t) {
17117
17117
  throw new TypeError(`Invalid attempt to iterate non-iterable instance.
17118
17118
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
17119
17119
  }
17120
- function Ch(e, t) {
17120
+ function C2(e, t) {
17121
17121
  if (e) {
17122
- if (typeof e == "string") return qo(e, t);
17122
+ if (typeof e == "string") return Ho(e, t);
17123
17123
  var r = Object.prototype.toString.call(e).slice(8, -1);
17124
17124
  if (r === "Object" && e.constructor && (r = e.constructor.name), r === "Map" || r === "Set") return Array.from(e);
17125
- if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return qo(e, t);
17125
+ if (r === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)) return Ho(e, t);
17126
17126
  }
17127
17127
  }
17128
- function qo(e, t) {
17128
+ function Ho(e, t) {
17129
17129
  (t == null || t > e.length) && (t = e.length);
17130
17130
  for (var r = 0, n = new Array(t); r < t; r++) n[r] = e[r];
17131
17131
  return n;
17132
17132
  }
17133
- function Sh(e, t) {
17134
- for (var r = Nh(e), n; !(n = r()).done; ) {
17133
+ function S2(e, t) {
17134
+ for (var r = N2(e), n; !(n = r()).done; ) {
17135
17135
  var a = n.value;
17136
- a && Ph(a, t);
17136
+ a && P2(a, t);
17137
17137
  }
17138
17138
  }
17139
- function Ph(e, t) {
17139
+ function P2(e, t) {
17140
17140
  typeof e == "function" ? e(t) : e.current = t;
17141
17141
  }
17142
17142
  var rl = O.default.shape({
@@ -17146,13 +17146,13 @@ var rl = O.default.shape({
17146
17146
  function Ue(e, t) {
17147
17147
  return "+" + Ke(e, t);
17148
17148
  }
17149
- function wh(e) {
17149
+ function w2(e) {
17150
17150
  var t = e.value, r = e.phoneNumber, n = e.defaultCountry, a = e.getAnyCountry, i = e.countries, o = e.required, s = e.metadata, l;
17151
17151
  return r && r.country ? l = r.country : n && (!t || pt(t, n, s)) && (l = n), i && i.indexOf(l) < 0 && (l = void 0), !l && o && i && i.length > 0 && (l = a()), l;
17152
17152
  }
17153
- function _h(e) {
17153
+ function _2(e) {
17154
17154
  var t = e.countries, r = e.countryNames, n = e.addInternationalOption, a = e.compareStringsLocales, i = e.compareStrings;
17155
- i || (i = kh);
17155
+ i || (i = k2);
17156
17156
  var o = t.map(function(s) {
17157
17157
  return {
17158
17158
  value: s,
@@ -17166,17 +17166,17 @@ function _h(e) {
17166
17166
  function al(e, t) {
17167
17167
  return Nm(e || "", t);
17168
17168
  }
17169
- function Oh(e) {
17169
+ function O2(e) {
17170
17170
  return e.formatNational().replace(/\D/g, "");
17171
17171
  }
17172
- function Eh(e, t) {
17172
+ function E2(e, t) {
17173
17173
  var r = t.prevCountry, n = t.newCountry, a = t.metadata, i = t.useNationalFormat;
17174
17174
  if (r === n) return e;
17175
17175
  if (!e) return i ? "" : n ? Ue(n, a) : "";
17176
17176
  if (n) {
17177
17177
  if (e[0] === "+") {
17178
17178
  if (i)
17179
- return e.indexOf("+" + Ke(n, a)) === 0 ? Mh(e, n, a) : "";
17179
+ return e.indexOf("+" + Ke(n, a)) === 0 ? M2(e, n, a) : "";
17180
17180
  if (r) {
17181
17181
  var o = Ue(n, a);
17182
17182
  return e.indexOf(o) === 0 ? e : o;
@@ -17202,21 +17202,21 @@ function dt(e, t, r) {
17202
17202
  }
17203
17203
  }
17204
17204
  }
17205
- function Ih(e, t, r) {
17205
+ function I2(e, t, r) {
17206
17206
  var n = ol(e, t, r);
17207
17207
  if (n) {
17208
- var a = n.length - Th(t, r);
17208
+ var a = n.length - T2(t, r);
17209
17209
  if (a > 0) return e.slice(0, e.length - a);
17210
17210
  }
17211
17211
  return e;
17212
17212
  }
17213
- function Th(e, t) {
17213
+ function T2(e, t) {
17214
17214
  return t = new he(t), t.selectNumberingPlan(e), t.numberingPlan.possibleLengths()[t.numberingPlan.possibleLengths().length - 1];
17215
17215
  }
17216
17216
  function il(e, t) {
17217
17217
  var r = t.country, n = t.countries, a = t.defaultCountry, i = t.latestCountrySelectedByUser, o = t.required, s = t.metadata;
17218
17218
  if (e === "+") return r;
17219
- var l = xh(e, s);
17219
+ var l = x2(e, s);
17220
17220
  if (l) return !n || n.indexOf(l) >= 0 ? l : void 0;
17221
17221
  if (r) {
17222
17222
  if (pt(e, r, s)) {
@@ -17227,7 +17227,7 @@ function il(e, t) {
17227
17227
  }
17228
17228
  return r;
17229
17229
  }
17230
- function Ah(e, t) {
17230
+ function A2(e, t) {
17231
17231
  var r = t.prevPhoneDigits, n = t.country, a = t.defaultCountry, i = t.latestCountrySelectedByUser, o = t.countryRequired, s = t.getAnyCountry, l = t.countries, c = t.international, u = t.limitMaxLength, p = t.countryCallingCodeEditable, f = t.metadata;
17232
17232
  if (c && p === !1 && n) {
17233
17233
  var v = Ue(n, f);
@@ -17240,7 +17240,7 @@ function Ah(e, t) {
17240
17240
  };
17241
17241
  }
17242
17242
  }
17243
- c === !1 && n && e && e[0] === "+" && (e = Ko(e, n, f)), e && n && u && (e = Ih(e, n, f)), e && e[0] !== "+" && (!n || c) && (e = "+" + e), !e && r && r[0] === "+" && (c ? n = void 0 : n = a), e === "+" && r && r[0] === "+" && r.length > 1 && (n = void 0);
17243
+ c === !1 && n && e && e[0] === "+" && (e = Ko(e, n, f)), e && n && u && (e = I2(e, n, f)), e && e[0] !== "+" && (!n || c) && (e = "+" + e), !e && r && r[0] === "+" && (c ? n = void 0 : n = a), e === "+" && r && r[0] === "+" && r.length > 1 && (n = void 0);
17244
17244
  var y;
17245
17245
  return e && (e[0] === "+" && (e === "+" || n && Ue(n, f).indexOf(e) === 0) ? y = void 0 : y = dt(e, n, f)), y && (n = il(y, {
17246
17246
  country: n,
@@ -17263,14 +17263,14 @@ function Ko(e, t, r) {
17263
17263
  return a ? a.formatNational().replace(/\D/g, "") : "";
17264
17264
  } else return e.replace(/\D/g, "");
17265
17265
  }
17266
- function xh(e, t) {
17266
+ function x2(e, t) {
17267
17267
  var r = new _t(null, t);
17268
17268
  return r.input(e), r.getCountry();
17269
17269
  }
17270
- function kh(e, t, r) {
17270
+ function k2(e, t, r) {
17271
17271
  return String.prototype.localeCompare ? e.localeCompare(t, r) : e < t ? -1 : e > t ? 1 : 0;
17272
17272
  }
17273
- function Mh(e, t, r) {
17273
+ function M2(e, t, r) {
17274
17274
  if (t) {
17275
17275
  var n = "+" + Ke(t, r);
17276
17276
  if (e.length < n.length) {
@@ -17298,15 +17298,15 @@ function pt(e, t, r) {
17298
17298
  }
17299
17299
  function sl(e) {
17300
17300
  var t = e.value, r = e.phoneNumber, n = e.defaultCountry, a = e.international, i = e.useNationalFormat, o = e.metadata;
17301
- return (a === !1 || i) && r && r.country ? Oh(r) : !t && a && n ? Ue(n, o) : t;
17301
+ return (a === !1 || i) && r && r.country ? O2(r) : !t && a && n ? Ue(n, o) : t;
17302
17302
  }
17303
- function Ht(e) {
17303
+ function qt(e) {
17304
17304
  "@babel/helpers - typeof";
17305
- return Ht = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
17305
+ return qt = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
17306
17306
  return typeof t;
17307
17307
  } : function(t) {
17308
17308
  return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
17309
- }, Ht(e);
17309
+ }, qt(e);
17310
17310
  }
17311
17311
  function Yo(e, t) {
17312
17312
  var r = Object.keys(e);
@@ -17322,36 +17322,36 @@ function ir(e) {
17322
17322
  for (var t = 1; t < arguments.length; t++) {
17323
17323
  var r = arguments[t] != null ? arguments[t] : {};
17324
17324
  t % 2 ? Yo(Object(r), !0).forEach(function(n) {
17325
- Dh(e, n, r[n]);
17325
+ D2(e, n, r[n]);
17326
17326
  }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(r)) : Yo(Object(r)).forEach(function(n) {
17327
17327
  Object.defineProperty(e, n, Object.getOwnPropertyDescriptor(r, n));
17328
17328
  });
17329
17329
  }
17330
17330
  return e;
17331
17331
  }
17332
- function Dh(e, t, r) {
17333
- return t = Rh(t), t in e ? Object.defineProperty(e, t, {
17332
+ function D2(e, t, r) {
17333
+ return t = R2(t), t in e ? Object.defineProperty(e, t, {
17334
17334
  value: r,
17335
17335
  enumerable: !0,
17336
17336
  configurable: !0,
17337
17337
  writable: !0
17338
17338
  }) : e[t] = r, e;
17339
17339
  }
17340
- function Rh(e) {
17341
- var t = Fh(e, "string");
17342
- return Ht(t) == "symbol" ? t : t + "";
17340
+ function R2(e) {
17341
+ var t = F2(e, "string");
17342
+ return qt(t) == "symbol" ? t : t + "";
17343
17343
  }
17344
- function Fh(e, t) {
17345
- if (Ht(e) != "object" || !e) return e;
17344
+ function F2(e, t) {
17345
+ if (qt(e) != "object" || !e) return e;
17346
17346
  var r = e[Symbol.toPrimitive];
17347
17347
  if (r !== void 0) {
17348
17348
  var n = r.call(e, t || "default");
17349
- if (Ht(n) != "object") return n;
17349
+ if (qt(n) != "object") return n;
17350
17350
  throw new TypeError("@@toPrimitive must return a primitive value.");
17351
17351
  }
17352
17352
  return (t === "string" ? String : Number)(e);
17353
17353
  }
17354
- function Lh(e, t, r) {
17354
+ function L2(e, t, r) {
17355
17355
  var n = e.metadata, a = e.countries, i = e.defaultCountry, o = e.value, s = e.reset, l = e.international, c = e.displayInitialValueAsLocalNumber, u = e.initialValueFormat, p = t.defaultCountry, f = t.value, v = t.reset;
17356
17356
  r.country;
17357
17357
  var m = r.value, y = r.hasUserSelectedACountry, b = r.latestCountrySelectedByUser, $ = function(Z) {
@@ -17414,7 +17414,7 @@ function Lh(e, t, r) {
17414
17414
  function Zo(e, t) {
17415
17415
  return e === null && (e = void 0), t === null && (t = void 0), e === t;
17416
17416
  }
17417
- var jh = [
17417
+ var j2 = [
17418
17418
  "name",
17419
17419
  "disabled",
17420
17420
  "readOnly",
@@ -17487,9 +17487,9 @@ function mt() {
17487
17487
  return e;
17488
17488
  }, mt.apply(this, arguments);
17489
17489
  }
17490
- function Bh(e, t) {
17490
+ function B2(e, t) {
17491
17491
  if (e == null) return {};
17492
- var r = Uh(e, t), n, a;
17492
+ var r = U2(e, t), n, a;
17493
17493
  if (Object.getOwnPropertySymbols) {
17494
17494
  var i = Object.getOwnPropertySymbols(e);
17495
17495
  for (a = 0; a < i.length; a++)
@@ -17497,14 +17497,14 @@ function Bh(e, t) {
17497
17497
  }
17498
17498
  return r;
17499
17499
  }
17500
- function Uh(e, t) {
17500
+ function U2(e, t) {
17501
17501
  if (e == null) return {};
17502
17502
  var r = {}, n = Object.keys(e), a, i;
17503
17503
  for (i = 0; i < n.length; i++)
17504
17504
  a = n[i], !(t.indexOf(a) >= 0) && (r[a] = e[a]);
17505
17505
  return r;
17506
17506
  }
17507
- function Vh(e, t) {
17507
+ function V2(e, t) {
17508
17508
  if (!(e instanceof t)) throw new TypeError("Cannot call a class as a function");
17509
17509
  }
17510
17510
  function Jo(e, t) {
@@ -17513,18 +17513,18 @@ function Jo(e, t) {
17513
17513
  n.enumerable = n.enumerable || !1, n.configurable = !0, "value" in n && (n.writable = !0), Object.defineProperty(e, cl(n.key), n);
17514
17514
  }
17515
17515
  }
17516
- function zh(e, t, r) {
17516
+ function z2(e, t, r) {
17517
17517
  return t && Jo(e.prototype, t), r && Jo(e, r), Object.defineProperty(e, "prototype", { writable: !1 }), e;
17518
17518
  }
17519
- function Gh(e, t, r) {
17520
- return t = Vr(t), Wh(e, ll() ? Reflect.construct(t, r || [], Vr(e).constructor) : t.apply(e, r));
17519
+ function G2(e, t, r) {
17520
+ return t = Vr(t), W2(e, ll() ? Reflect.construct(t, r || [], Vr(e).constructor) : t.apply(e, r));
17521
17521
  }
17522
- function Wh(e, t) {
17522
+ function W2(e, t) {
17523
17523
  if (t && (gt(t) === "object" || typeof t == "function")) return t;
17524
17524
  if (t !== void 0) throw new TypeError("Derived constructors may only return object or undefined");
17525
- return Hh(e);
17525
+ return q2(e);
17526
17526
  }
17527
- function Hh(e) {
17527
+ function q2(e) {
17528
17528
  if (e === void 0) throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
17529
17529
  return e;
17530
17530
  }
@@ -17543,7 +17543,7 @@ function Vr(e) {
17543
17543
  return r.__proto__ || Object.getPrototypeOf(r);
17544
17544
  }, Vr(e);
17545
17545
  }
17546
- function qh(e, t) {
17546
+ function H2(e, t) {
17547
17547
  if (typeof t != "function" && t !== null) throw new TypeError("Super expression must either be null or a function");
17548
17548
  e.prototype = Object.create(t && t.prototype, { constructor: {
17549
17549
  value: e,
@@ -17565,10 +17565,10 @@ function ke(e, t, r) {
17565
17565
  }) : e[t] = r, e;
17566
17566
  }
17567
17567
  function cl(e) {
17568
- var t = Kh(e, "string");
17568
+ var t = K2(e, "string");
17569
17569
  return gt(t) == "symbol" ? t : t + "";
17570
17570
  }
17571
- function Kh(e, t) {
17571
+ function K2(e, t) {
17572
17572
  if (gt(e) != "object" || !e) return e;
17573
17573
  var r = e[Symbol.toPrimitive];
17574
17574
  if (r !== void 0) {
@@ -17578,16 +17578,16 @@ function Kh(e, t) {
17578
17578
  }
17579
17579
  return (t === "string" ? String : Number)(e);
17580
17580
  }
17581
- var Yh = /* @__PURE__ */ (function(e) {
17581
+ var Y2 = /* @__PURE__ */ (function(e) {
17582
17582
  function t(r) {
17583
17583
  var n;
17584
- Vh(this, t), n = Gh(this, t, [r]), ke(n, "setInputRef", function(b) {
17585
- Sh([n.props.inputRef, n.inputRef], b);
17584
+ V2(this, t), n = G2(this, t, [r]), ke(n, "setInputRef", function(b) {
17585
+ S2([n.props.inputRef, n.inputRef], b);
17586
17586
  }), ke(n, "isCountrySupportedWithError", function(b) {
17587
17587
  var $ = n.props.metadata;
17588
17588
  return un(b, $);
17589
17589
  }), ke(n, "onCountryChange", function(b) {
17590
- var $ = n.props, g = $.international, S = $.metadata, P = $.onChange, C = $.focusInputOnCountrySelection, N = n.state, E = N.phoneDigits, D = N.country, Z = Eh(E, {
17590
+ var $ = n.props, g = $.international, S = $.metadata, P = $.onChange, C = $.focusInputOnCountrySelection, N = n.state, E = N.phoneDigits, D = N.country, Z = E2(E, {
17591
17591
  prevCountry: D,
17592
17592
  newCountry: b,
17593
17593
  metadata: S,
@@ -17603,7 +17603,7 @@ var Yh = /* @__PURE__ */ (function(e) {
17603
17603
  P(J);
17604
17604
  });
17605
17605
  }), ke(n, "onChange", function(b) {
17606
- var $ = n.props, g = $.defaultCountry, S = $.onChange, P = $.addInternationalOption, C = $.international, N = $.limitMaxLength, E = $.countryCallingCodeEditable, D = $.metadata, Z = n.state, J = Z.countries, re = Z.phoneDigits, ue = Z.country, oe = Z.latestCountrySelectedByUser, fe = Ah(b, {
17606
+ var $ = n.props, g = $.defaultCountry, S = $.onChange, P = $.addInternationalOption, C = $.international, N = $.limitMaxLength, E = $.countryCallingCodeEditable, D = $.metadata, Z = n.state, J = Z.countries, re = Z.phoneDigits, ue = Z.country, oe = Z.latestCountrySelectedByUser, fe = A2(b, {
17607
17607
  prevPhoneDigits: re,
17608
17608
  country: ue,
17609
17609
  countryRequired: !P,
@@ -17657,7 +17657,7 @@ var Yh = /* @__PURE__ */ (function(e) {
17657
17657
  f && (n.isCountrySupportedWithError(f) || (f = void 0)), i && Qd(i), v = el(v, u);
17658
17658
  var m = al(i, u);
17659
17659
  n.CountryIcon = tl(n.props);
17660
- var y = wh({
17660
+ var y = w2({
17661
17661
  value: i,
17662
17662
  phoneNumber: m,
17663
17663
  defaultCountry: f,
@@ -17683,7 +17683,7 @@ var Yh = /* @__PURE__ */ (function(e) {
17683
17683
  value: i
17684
17684
  }, n;
17685
17685
  }
17686
- return qh(t, e), zh(t, [
17686
+ return H2(t, e), z2(t, [
17687
17687
  {
17688
17688
  key: "componentDidMount",
17689
17689
  value: function() {
@@ -17703,12 +17703,12 @@ var Yh = /* @__PURE__ */ (function(e) {
17703
17703
  value: function(n) {
17704
17704
  var a = n.countries, i = this.props, o = i.international, s = i.countryCallingCodeEditable, l = i.countryOptionsOrder, c = i.addInternationalOption, u = i.labels, p = i.locales, f = i.metadata;
17705
17705
  return this.useMemoCountrySelectOptions(function() {
17706
- return vh(_h({
17706
+ return v2(_2({
17707
17707
  countries: a || Vo(f),
17708
17708
  countryNames: u,
17709
17709
  addInternationalOption: o && s === !1 ? !1 : c,
17710
17710
  compareStringsLocales: p
17711
- }), yh(l, f));
17711
+ }), y2(l, f));
17712
17712
  }, [
17713
17713
  a,
17714
17714
  l,
@@ -17721,7 +17721,7 @@ var Yh = /* @__PURE__ */ (function(e) {
17721
17721
  {
17722
17722
  key: "useMemoCountrySelectOptions",
17723
17723
  value: function(n, a) {
17724
- return (!this.countrySelectOptionsMemoDependencies || !Xh(a, this.countrySelectOptionsMemoDependencies)) && (this.countrySelectOptionsMemo = n(), this.countrySelectOptionsMemoDependencies = a), this.countrySelectOptionsMemo;
17724
+ return (!this.countrySelectOptionsMemoDependencies || !X2(a, this.countrySelectOptionsMemoDependencies)) && (this.countrySelectOptionsMemo = n(), this.countrySelectOptionsMemoDependencies = a), this.countrySelectOptionsMemo;
17725
17725
  }
17726
17726
  },
17727
17727
  {
@@ -17742,7 +17742,7 @@ var Yh = /* @__PURE__ */ (function(e) {
17742
17742
  n.flags, n.flagComponent, n.flagUrl, n.addInternationalOption, n.internationalIcon, n.displayInitialValueAsLocalNumber, n.initialValueFormat, n.onCountryChange, n.limitMaxLength, n.countryCallingCodeEditable, n.focusInputOnCountrySelection, n.reset;
17743
17743
  var g = n.metadata, S = n.international;
17744
17744
  n.locales;
17745
- var P = Bh(n, jh), C = this.state, N = C.country, E = C.countries, D = C.phoneDigits, Z = C.isFocused, J = f ? W2 : Z2, re = this.getCountrySelectOptions({ countries: E });
17745
+ var P = B2(n, j2), C = this.state, N = C.country, E = C.countries, D = C.phoneDigits, Z = C.isFocused, J = f ? Wh : Zh, re = this.getCountrySelectOptions({ countries: E });
17746
17746
  return /* @__PURE__ */ j.createElement(y, mt({
17747
17747
  style: l,
17748
17748
  className: (0, jr.default)(c, "PhoneInput", {
@@ -17787,11 +17787,11 @@ var Yh = /* @__PURE__ */ (function(e) {
17787
17787
  ], [{
17788
17788
  key: "getDerivedStateFromProps",
17789
17789
  value: function(n, a) {
17790
- return dl({ props: n }, Lh(n, a.props, a));
17790
+ return dl({ props: n }, L2(n, a.props, a));
17791
17791
  }
17792
17792
  }]);
17793
17793
  })(j.PureComponent), ul = /* @__PURE__ */ j.forwardRef(function(e, t) {
17794
- return /* @__PURE__ */ j.createElement(Yh, mt({}, Zh(e), { inputRef: t }));
17794
+ return /* @__PURE__ */ j.createElement(Y2, mt({}, Z2(e), { inputRef: t }));
17795
17795
  });
17796
17796
  ul.propTypes = {
17797
17797
  value: O.default.string,
@@ -17843,12 +17843,12 @@ var Qo = {
17843
17843
  countryCallingCodeEditable: !0,
17844
17844
  focusInputOnCountrySelection: !0
17845
17845
  };
17846
- function Zh(e) {
17846
+ function Z2(e) {
17847
17847
  e = dl({}, e);
17848
17848
  for (var t in Qo) e[t] === void 0 && (e[t] = Qo[t]);
17849
17849
  return e;
17850
17850
  }
17851
- function Xh(e, t) {
17851
+ function X2(e, t) {
17852
17852
  if (e.length !== t.length) return !1;
17853
17853
  for (var r = 0; r < e.length; ) {
17854
17854
  if (e[r] !== t[r]) return !1;
@@ -17856,7 +17856,7 @@ function Xh(e, t) {
17856
17856
  }
17857
17857
  return !0;
17858
17858
  }
17859
- var Jh = {
17859
+ var J2 = {
17860
17860
  ext: "ext.",
17861
17861
  country: "Phone number country",
17862
17862
  phone: "Phone",
@@ -18115,7 +18115,7 @@ var Jh = {
18115
18115
  ZM: "Zambia",
18116
18116
  ZW: "Zimbabwe",
18117
18117
  ZZ: "International"
18118
- }, Qh = ["metadata", "labels"];
18118
+ }, Q2 = ["metadata", "labels"];
18119
18119
  function ya() {
18120
18120
  return ya = Object.assign ? Object.assign.bind() : function(e) {
18121
18121
  for (var t = 1; t < arguments.length; t++) {
@@ -18144,7 +18144,7 @@ function tv(e, t) {
18144
18144
  }
18145
18145
  function fl(e) {
18146
18146
  var t = /* @__PURE__ */ j.forwardRef(function(r, n) {
18147
- var a = r.metadata, i = a === void 0 ? e : a, o = r.labels, s = o === void 0 ? Jh : o, l = ev(r, Qh);
18147
+ var a = r.metadata, i = a === void 0 ? e : a, o = r.labels, s = o === void 0 ? J2 : o, l = ev(r, Q2);
18148
18148
  return /* @__PURE__ */ j.createElement(ul, ya({}, l, {
18149
18149
  ref: n,
18150
18150
  metadata: i,
@@ -18896,7 +18896,7 @@ var Cv = ({ onClose: e, onConfirm: t, enforcement: r, heading: n, consent: a })
18896
18896
  }), /* @__PURE__ */ d("button", {
18897
18897
  onClick: g,
18898
18898
  className: "arravpos-consent-close-btn",
18899
- children: /* @__PURE__ */ d(qe, {})
18899
+ children: /* @__PURE__ */ d(He, {})
18900
18900
  })]
18901
18901
  }),
18902
18902
  /* @__PURE__ */ d("div", {
@@ -19045,17 +19045,17 @@ var Cv = ({ onClose: e, onConfirm: t, enforcement: r, heading: n, consent: a })
19045
19045
  return +`${t}${r}`;
19046
19046
  };
19047
19047
  function Ov() {
19048
- const e = Ie(), { tenantId: t, id: r, timeZone: n, image: a, outletName: i, address: o } = K((_) => _.booking.outletDetails), { staff: s, selectedServices: l, selectedProfessional: c } = K((_) => _.booking.service), { selectedSlotIds: u, selectedDate: p, selectedTime: f, selectedSlotIndexes: v, slots: m } = K((_) => _.booking.slots), { userDetails: y, bookingMode: b, tipPct: $, payType: g } = K((_) => _.booking.appointment), S = Ae(!1), P = Ae(""), C = be.now().setZone(n ?? "UTC"), N = Array.isArray(l) ? l : [l], [E, D] = H(!1), [Z, J] = H(!1), [re, ue] = H(null), [oe, fe] = H(!1), [ve, ye] = H(""), [pe, ne] = H(""), [Ce, k] = H(null), [R, w] = H(null), [I, L] = H({}), [z, F] = H({}), [q, G] = H(!1), [W, x] = H(!1), [M, B] = H(null), [A, te] = H(!1), $e = Ae(""), Ye = Ae(null), pn = N.map((_) => {
19049
- const T = s?.find((V) => V.id === c?.id)?.assignments?.find((V) => V.id === _.id), U = {
19048
+ const e = Ie(), { tenantId: t, id: r, timeZone: n, image: a, outletName: i, address: o } = K((_) => _.booking.outletDetails), { staff: s, selectedServices: l, selectedProfessional: c } = K((_) => _.booking.service), { selectedSlotIds: u, selectedDate: p, selectedTime: f, selectedSlotIndexes: v, slots: m } = K((_) => _.booking.slots), { userDetails: y, bookingMode: b, tipPct: $, payType: g } = K((_) => _.booking.appointment), S = Ae(!1), P = Ae(""), C = be.now().setZone(n ?? "UTC"), N = Array.isArray(l) ? l : [l], [E, D] = q(!1), [Z, J] = q(!1), [re, ue] = q(null), [oe, fe] = q(!1), [ve, ye] = q(""), [pe, ne] = q(""), [Ce, k] = q(null), [R, w] = q(null), [I, L] = q({}), [z, F] = q({}), [H, G] = q(!1), [W, x] = q(!1), [M, V] = q(null), [A, te] = q(!1), $e = Ae(""), Ye = Ae(null), pn = N.map((_) => {
19049
+ const T = s?.find((U) => U.id === c?.id)?.assignments?.find((U) => U.id === _.id), B = {
19050
19050
  ..._,
19051
19051
  price: T?.price ?? _.price ?? _.min_price ?? 0,
19052
19052
  duration: T?.duration ?? _.estimated_time ?? _.min_time ?? 0
19053
19053
  };
19054
19054
  return {
19055
- ...U,
19055
+ ...B,
19056
19056
  duration: T?.duration ?? _.estimated_time ?? _.min_time ?? 0,
19057
- tax: zi(U),
19058
- unitTax: zi(U, { perUnit: !0 })
19057
+ tax: zi(B),
19058
+ unitTax: zi(B, { perUnit: !0 })
19059
19059
  };
19060
19060
  }), mn = [
19061
19061
  ...m?.morning ?? [],
@@ -19063,13 +19063,13 @@ function Ov() {
19063
19063
  ...m?.evening ?? []
19064
19064
  ], ml = pn.reduce((_, T) => _ + Number(T.duration ?? 0), 0), hl = Math.ceil(ml / wv), vl = (_) => {
19065
19065
  if (!mn.length) return "";
19066
- const T = mn[_]?.start_time, U = mn[_ + hl - 1];
19067
- return !T || !U ? "" : `${T} - ${U.end_time ?? U.start_time}`;
19068
- }, Ha = {
19066
+ const T = mn[_]?.start_time, B = mn[_ + hl - 1];
19067
+ return !T || !B ? "" : `${T} - ${B.end_time ?? B.start_time}`;
19068
+ }, qa = {
19069
19069
  day: Number(p?.day ?? C.day),
19070
19070
  month: Number(p?.month ?? C.month),
19071
19071
  year: Number(p?.year ?? C.year)
19072
- }, qa = v?.[0], Ka = qa !== void 0 ? vl(qa) : null, yl = Ka ? `${Pv[Ha.month - 1]} ${Ha.day} at ${Ka}` : null, hn = pn.reduce((_, T) => _ + Number(T.price || T.min_price) * (T.qty ?? 1), 0), Ya = pn.reduce((_, T) => _ + T.tax, 0), $l = Math.round(Ya * 100), Za = hn * $ / 100, gl = Math.round(Za * 100), Xa = hn + Za + Ya, Te = ce(() => N.filter((_) => !(!ka(_) || (_?.consent_rule?.enforcementMode ?? _?.enforcementMode) === "FIXED")), [N]), bl = ce(() => Te.map((_) => String(_.id)).filter(Boolean), [Te]), Nl = (_) => {
19072
+ }, Ha = v?.[0], Ka = Ha !== void 0 ? vl(Ha) : null, yl = Ka ? `${Pv[qa.month - 1]} ${qa.day} at ${Ka}` : null, hn = pn.reduce((_, T) => _ + Number(T.price || T.min_price) * (T.qty ?? 1), 0), Ya = pn.reduce((_, T) => _ + T.tax, 0), $l = Math.round(Ya * 100), Za = hn * $ / 100, gl = Math.round(Za * 100), Xa = hn + Za + Ya, Te = ce(() => N.filter((_) => !(!ka(_) || (_?.consent_rule?.enforcementMode ?? _?.enforcementMode) === "FIXED")), [N]), bl = ce(() => Te.map((_) => String(_.id)).filter(Boolean), [Te]), Nl = (_) => {
19073
19073
  const T = _?.consent_template ?? _?.consentTemplate ?? null;
19074
19074
  return {
19075
19075
  heading: String(T?.heading ?? "").trim(),
@@ -19087,7 +19087,8 @@ function Ov() {
19087
19087
  phone: "",
19088
19088
  email: ""
19089
19089
  },
19090
- mode: "onSubmit"
19090
+ mode: "onChange",
19091
+ reValidateMode: "onChange"
19091
19092
  });
19092
19093
  me(() => {
19093
19094
  y && Te?.length > 0 && Pl();
@@ -19098,22 +19099,22 @@ function Ov() {
19098
19099
  G(!0);
19099
19100
  try {
19100
19101
  const T = {};
19101
- for (const U of Te) {
19102
- const V = String(U.id), se = String(U.consent_form_id ?? "");
19103
- if (!V || !se) continue;
19104
- const ae = Di(U);
19102
+ for (const B of Te) {
19103
+ const U = String(B.id), se = String(B.consent_form_id ?? "");
19104
+ if (!U || !se) continue;
19105
+ const ae = Di(B);
19105
19106
  if (!(ae === "EVERY_X_DAYS" || ae === "ONCE_PER_CUSTOMER")) {
19106
- T[V] = { data: {
19107
+ T[U] = { data: {
19107
19108
  checked: !0,
19108
19109
  needsSignature: !0
19109
19110
  } };
19110
19111
  continue;
19111
19112
  }
19112
- const Oe = !!(await Fi(_, se, V))?.data?.needsSignature;
19113
- T[V] = { data: {
19113
+ const Oe = !!(await Fi(_, se, U))?.data?.needsSignature;
19114
+ T[U] = { data: {
19114
19115
  checked: !0,
19115
19116
  needsSignature: Oe
19116
- } }, Oe || vn(V);
19117
+ } }, Oe || vn(U);
19117
19118
  }
19118
19119
  F(T);
19119
19120
  } catch (T) {
@@ -19125,8 +19126,8 @@ function Ov() {
19125
19126
  }, gn = ce(() => Te.filter((_) => {
19126
19127
  const T = String(_.id);
19127
19128
  if (I[T]) return !1;
19128
- const U = z[T];
19129
- return !(U?.data?.checked && U?.data?.needsSignature === !1);
19129
+ const B = z[T];
19130
+ return !(B?.data?.checked && B?.data?.needsSignature === !1);
19130
19131
  }), [
19131
19132
  Te,
19132
19133
  I,
@@ -19143,19 +19144,19 @@ function Ov() {
19143
19144
  const T = String(_.id);
19144
19145
  if (P.current === T && oe) return;
19145
19146
  P.current = T;
19146
- const U = String(_.consent_form_id ?? "");
19147
- if (!U) {
19147
+ const B = String(_.consent_form_id ?? "");
19148
+ if (!B) {
19148
19149
  ie.error("Consent form missing.");
19149
19150
  return;
19150
19151
  }
19151
- const V = Ri(_);
19152
- if (!V) {
19152
+ const U = Ri(_);
19153
+ if (!U) {
19153
19154
  ie.error("Consent enforcement method not found.");
19154
19155
  return;
19155
19156
  }
19156
19157
  const se = y?.id;
19157
19158
  if (Di(_) !== "EVERY_VISIT" && se) {
19158
- const Fe = !!(await Fi(se, U, T))?.data?.needsSignature;
19159
+ const Fe = !!(await Fi(se, B, T))?.data?.needsSignature;
19159
19160
  if (F((Jt) => ({
19160
19161
  ...Jt,
19161
19162
  [T]: { data: {
@@ -19178,7 +19179,7 @@ function Ov() {
19178
19179
  ie.error("Consent template missing.");
19179
19180
  return;
19180
19181
  }
19181
- ye(ae), ne(ge), k(V), w(T), fe(!0);
19182
+ ye(ae), ne(ge), k(U), w(T), fe(!0);
19182
19183
  } catch (_) {
19183
19184
  console.error(_), ie.error(_?.message ?? "Consent check failed");
19184
19185
  } finally {
@@ -19187,10 +19188,10 @@ function Ov() {
19187
19188
  }
19188
19189
  }, wl = (_, T) => {
19189
19190
  try {
19190
- const U = localStorage.getItem(or), V = U ? JSON.parse(U) : {};
19191
- V[String(_)] = T, localStorage.setItem(or, JSON.stringify(V));
19192
- } catch (U) {
19193
- console.error("Failed to save consent draft", U);
19191
+ const B = localStorage.getItem(or), U = B ? JSON.parse(B) : {};
19192
+ U[String(_)] = T, localStorage.setItem(or, JSON.stringify(U));
19193
+ } catch (B) {
19194
+ console.error("Failed to save consent draft", B);
19194
19195
  }
19195
19196
  }, _l = () => {
19196
19197
  try {
@@ -19201,17 +19202,17 @@ function Ov() {
19201
19202
  }, Ol = (_) => {
19202
19203
  const T = String(R);
19203
19204
  if (!T) return;
19204
- const U = Te.find((ge) => String(ge.id) === T);
19205
- if (!U) return;
19206
- const V = String(U.consent_form_id ?? ""), se = Ri(U);
19207
- if (!V || !se) {
19205
+ const B = Te.find((ge) => String(ge.id) === T);
19206
+ if (!B) return;
19207
+ const U = String(B.consent_form_id ?? ""), se = Ri(B);
19208
+ if (!U || !se) {
19208
19209
  ie.error("Consent form/method missing.");
19209
19210
  return;
19210
19211
  }
19211
19212
  let ae = "CHECKBOX_ONLY";
19212
19213
  se === "TYPED_NAME" ? ae = "TYPED_NAME" : se === "DRAW_SIGNATURE" && (ae = "SIGNATURE_IMAGE"), wl(T, {
19213
19214
  serviceId: T,
19214
- concentFormId: V,
19215
+ concentFormId: U,
19215
19216
  signatureType: ae,
19216
19217
  typedName: _?.typedName,
19217
19218
  isChecked: _?.accepted,
@@ -19220,8 +19221,8 @@ function Ov() {
19220
19221
  }), vn(T), fe(!1), P.current = "", ie.success("Consent captured.");
19221
19222
  }, El = () => {
19222
19223
  fe(!1), w(null);
19223
- }, Il = async (_, T, U) => {
19224
- const V = _l(), se = Object.entries(V).map(([ae, ge]) => ({
19224
+ }, Il = async (_, T, B) => {
19225
+ const U = _l(), se = Object.entries(U).map(([ae, ge]) => ({
19225
19226
  serviceId: ae,
19226
19227
  concentFormId: ge.concentFormId,
19227
19228
  captured: ge
@@ -19234,7 +19235,7 @@ function Ov() {
19234
19235
  customerId: T,
19235
19236
  serviceId: ge,
19236
19237
  formId: Oe,
19237
- staffId: U,
19238
+ staffId: B,
19238
19239
  signatureType: Jt,
19239
19240
  typedName: Fe.typedName,
19240
19241
  imageUrl: Fe.signatureDataUrl
@@ -19246,13 +19247,13 @@ function Ov() {
19246
19247
  let oi = "";
19247
19248
  p && (oi = `${p?.year}-${String(p?.month).padStart(2, "0")}-${String(p?.day).padStart(2, "0")}`);
19248
19249
  const bn = async (_) => {
19249
- const T = _ || y, U = {
19250
+ const T = _ || y, B = {
19250
19251
  tenantId: t,
19251
19252
  outletId: r,
19252
19253
  staffId: c?.id,
19253
19254
  date: oi,
19254
19255
  startTime: f,
19255
- serviceIds: N.map((V) => V.id),
19256
+ serviceIds: N.map((U) => U.id),
19256
19257
  slotIds: u,
19257
19258
  isWalkIn: !1,
19258
19259
  requiresConsent: Te.length > 0,
@@ -19269,13 +19270,13 @@ function Ov() {
19269
19270
  }
19270
19271
  try {
19271
19272
  D(!0);
19272
- const V = await e(hr(U)).unwrap(), se = V?.data ?? V, ae = se.id || "", ge = se.customerId || se.customer?.id || "", Oe = se.staffId || c?.id || "";
19273
+ const U = await e(hr(B)).unwrap(), se = U?.data ?? U, ae = se.id || "", ge = se.customerId || se.customer?.id || "", Oe = se.staffId || c?.id || "";
19273
19274
  b === "booking" && ni > 0 && await Il(ae, ge, Oe), g === "card" ? (ue({
19274
19275
  appointmentId: ae,
19275
19276
  customerId: ge
19276
19277
  }), J(!0)) : (e(ar(String(ae))), e(we()));
19277
- } catch (V) {
19278
- const se = V?.payload?.message || V?.data?.message || V?.message || "Staff not working on this day";
19278
+ } catch (U) {
19279
+ const se = U?.payload?.message || U?.data?.message || U?.message || "Staff not working on this day";
19279
19280
  ie.error(se);
19280
19281
  } finally {
19281
19282
  D(!1);
@@ -19314,12 +19315,12 @@ function Ov() {
19314
19315
  }, kl = async (_) => {
19315
19316
  try {
19316
19317
  D(!0);
19317
- const T = re?.appointmentId, U = String(re?.customerId);
19318
+ const T = re?.appointmentId, B = String(re?.customerId);
19318
19319
  if (!T || !r)
19319
19320
  return ie.error("Something went wrong."), !1;
19320
- const V = xl(_.number), se = await sf({
19321
+ const U = xl(_.number), se = await sf({
19321
19322
  appointmentId: T,
19322
- customerId: U,
19323
+ customerId: B,
19323
19324
  outletId: r,
19324
19325
  referenceNo: T,
19325
19326
  currency: "USD",
@@ -19335,7 +19336,7 @@ function Ov() {
19335
19336
  tenderInfo: {
19336
19337
  cardHolderName: _.name,
19337
19338
  cardNumber: _.number.replace(/\s/g, ""),
19338
- cardType: V,
19339
+ cardType: U,
19339
19340
  cardExpiry: _v(_.expiry),
19340
19341
  cvData: _.cvv
19341
19342
  },
@@ -19365,32 +19366,32 @@ function Ov() {
19365
19366
  J(!1), ie.warning("Appointment booked. Payment was cancelled."), e(ar(String(re?.appointmentId))), e(we());
19366
19367
  }, si = Be(async ({ value: _, type: T }) => {
19367
19368
  if (!_) return;
19368
- let U = "";
19369
+ let B = "";
19369
19370
  if (T === "phone") {
19370
19371
  if (!Rn(_)) return;
19371
- U = Sn(_);
19372
+ B = Sn(_);
19372
19373
  }
19373
19374
  if (T === "email") {
19374
19375
  if (!Rl(_)) return;
19375
- U = _.trim();
19376
+ B = _.trim();
19376
19377
  }
19377
- if (U && !($e.current === U && A)) {
19378
- $e.current = U, x(!0), B(T);
19378
+ if (B && !($e.current === B && A)) {
19379
+ $e.current = B, x(!0), V(T);
19379
19380
  try {
19380
- const V = (await of({
19381
- search: U,
19381
+ const U = (await of({
19382
+ search: B,
19382
19383
  tenantId: t
19383
19384
  }))?.data?.[0];
19384
- V ? (Ot("firstName", V.first_name || "", { shouldValidate: !0 }), Ot("lastName", V.last_name || ""), V.phone && Rn(V.phone) && Ot("phone", V.phone), V.email && Ot("email", V.email), e(En({
19385
- email: V.email,
19386
- firstName: V.first_name,
19387
- lastName: V.last_name,
19388
- phone: V.phone
19385
+ U ? (Ot("firstName", U.first_name || "", { shouldValidate: !0 }), Ot("lastName", U.last_name || ""), U.phone && Rn(U.phone) && Ot("phone", U.phone), U.email && Ot("email", U.email), e(En({
19386
+ email: U.email,
19387
+ firstName: U.first_name,
19388
+ lastName: U.last_name,
19389
+ phone: U.phone
19389
19390
  })), te(!0)) : te(!1);
19390
- } catch (V) {
19391
- console.error(V);
19391
+ } catch (U) {
19392
+ console.error(U);
19392
19393
  } finally {
19393
- x(!1), B(null);
19394
+ x(!1), V(null);
19394
19395
  }
19395
19396
  }
19396
19397
  }, [
@@ -19408,14 +19409,14 @@ function Ov() {
19408
19409
  me(() => (Ye.current = Ql(si, 800), () => {
19409
19410
  Ye.current?.cancel?.();
19410
19411
  }), [si]);
19411
- const di = (_, T, U) => {
19412
+ const di = (_, T, B) => {
19412
19413
  if (T && T(_), !_) {
19413
- Ye.current?.cancel?.(), $e.current = "", te(!1), B(null);
19414
+ Ye.current?.cancel?.(), $e.current = "", te(!1), V(null);
19414
19415
  return;
19415
19416
  }
19416
- B(U), Ye.current?.({
19417
+ V(B), Ye.current?.({
19417
19418
  value: _,
19418
- type: U
19419
+ type: B
19419
19420
  });
19420
19421
  }, Nn = Qa("phone"), Cn = Qa("email");
19421
19422
  me(() => {
@@ -19447,7 +19448,7 @@ function Ov() {
19447
19448
  consentRequired: Te?.length > 0,
19448
19449
  consentCompleted: ni,
19449
19450
  totalConsents: ri,
19450
- checkingConsent: q,
19451
+ checkingConsent: H,
19451
19452
  loading: E
19452
19453
  })
19453
19454
  }),
@@ -19546,8 +19547,8 @@ function Ov() {
19546
19547
  control: Cl,
19547
19548
  name: "phone",
19548
19549
  rules: { validate: (_) => {
19549
- const T = !!Sn(_), U = !!Cn?.trim();
19550
- return !T && !U ? "Enter phone or email" : T && !Rn(_) ? "Enter valid phone number" : !0;
19550
+ const T = Sn(_), B = !!T, U = !!Cn?.trim();
19551
+ return !B && !U ? "Enter phone or email" : B && T.length < 8 ? "Phone number must be minimum 8 digits" : B && T.length > 16 ? "Phone number must be maximum 16 digits" : B && !Rn(_) ? "Enter valid phone number" : !0;
19551
19552
  } },
19552
19553
  render: ({ field: _ }) => /* @__PURE__ */ h("div", {
19553
19554
  className: "arravpos-input-wrapper",
@@ -19594,13 +19595,23 @@ function Ov() {
19594
19595
  }),
19595
19596
  /* @__PURE__ */ d("input", {
19596
19597
  id: "email",
19598
+ minLength: 10,
19599
+ maxLength: 50,
19597
19600
  ...yn("email", {
19598
19601
  validate: (_) => {
19599
- const T = !!_?.trim(), U = !!Sn(Nn);
19600
- return !T && !U ? "Enter phone or email" : T && !/^\S+@\S+\.\S+$/.test(_) ? "Invalid email" : !0;
19602
+ const T = !!_?.trim(), B = !!Sn(Nn);
19603
+ return !T && !B ? "Enter phone or email" : T && !/^\S+@\S+\.\S+$/.test(_) ? "Invalid email" : !0;
19601
19604
  },
19602
19605
  onChange: (_) => {
19603
19606
  di(_.target.value, null, "email");
19607
+ },
19608
+ minLength: {
19609
+ value: 10,
19610
+ message: "Minimum 2 characters required"
19611
+ },
19612
+ maxLength: {
19613
+ value: 50,
19614
+ message: "Email must be maximum 50 characters"
19604
19615
  }
19605
19616
  }),
19606
19617
  autoComplete: "email",
@@ -19617,7 +19628,7 @@ function Ov() {
19617
19628
  className: "arravpos-form-group",
19618
19629
  children: [
19619
19630
  /* @__PURE__ */ h("label", {
19620
- htmlFor: "first_name",
19631
+ htmlFor: "firstName",
19621
19632
  className: "arravpos-form-label",
19622
19633
  children: [
19623
19634
  "First Name",
@@ -19630,9 +19641,19 @@ function Ov() {
19630
19641
  ]
19631
19642
  }),
19632
19643
  /* @__PURE__ */ d("input", {
19633
- id: "first_name",
19644
+ id: "firstName",
19645
+ minLength: 2,
19646
+ maxLength: 30,
19634
19647
  ...yn("firstName", {
19635
19648
  required: "First name required",
19649
+ minLength: {
19650
+ value: 2,
19651
+ message: "Minimum 2 characters required"
19652
+ },
19653
+ maxLength: {
19654
+ value: 30,
19655
+ message: "Maximum 30 characters allowed"
19656
+ },
19636
19657
  pattern: {
19637
19658
  value: /^[A-Za-z\s]+$/,
19638
19659
  message: "Only letters are allowed"
@@ -19651,13 +19672,28 @@ function Ov() {
19651
19672
  /* @__PURE__ */ h("div", {
19652
19673
  className: "arravpos-form-group",
19653
19674
  children: [/* @__PURE__ */ d("label", {
19654
- htmlFor: "last_name",
19675
+ htmlFor: "lastName",
19655
19676
  className: "arravpos-form-label",
19656
19677
  children: "Last Name"
19657
19678
  }), /* @__PURE__ */ d("input", {
19658
- id: "last_name",
19679
+ id: "lastName",
19659
19680
  autoComplete: "family-name",
19660
- ...yn("lastName"),
19681
+ minLength: 2,
19682
+ maxLength: 20,
19683
+ ...yn("lastName", {
19684
+ minLength: {
19685
+ value: 2,
19686
+ message: "Last name must be at least 2 characters"
19687
+ },
19688
+ maxLength: {
19689
+ value: 30,
19690
+ message: "Last name cannot exceed 30 characters"
19691
+ },
19692
+ pattern: {
19693
+ value: /^[A-Za-z\s]+$/,
19694
+ message: "Only letters are allowed"
19695
+ }
19696
+ }),
19661
19697
  placeholder: "Last Name",
19662
19698
  className: "arravpos-custom-input"
19663
19699
  })]
@@ -19753,7 +19789,7 @@ function Tv({ icon: e, label: t, selected: r, onClick: n }) {
19753
19789
  });
19754
19790
  }
19755
19791
  function Av() {
19756
- const e = Ie(), t = K((N) => N.booking.appointment.appointmentId), { tenantId: r } = K((N) => N.booking.outletDetails), [n, a] = H(null), [i, o] = H(!0), [s, l] = H(null), [c, u] = H(!1);
19792
+ const e = Ie(), t = K((N) => N.booking.appointment.appointmentId), { tenantId: r } = K((N) => N.booking.outletDetails), [n, a] = q(null), [i, o] = q(!0), [s, l] = q(null), [c, u] = q(!1);
19757
19793
  me(() => {
19758
19794
  if (!t) {
19759
19795
  l("No appointment ID provided"), o(!1);
@@ -19967,7 +20003,7 @@ function Mv() {
19967
20003
  });
19968
20004
  }
19969
20005
  var Dv = ({ bookingCode: e }) => {
19970
- const t = Ie(), r = K((f) => f.booking.outletList.outlets), n = K((f) => f.booking.theme), [a, i] = H(!1), [o, s] = H(null), { id: l } = K((f) => f.booking.outletDetails), c = Be(async () => {
20006
+ const t = Ie(), r = K((f) => f.booking.outletList.outlets), n = K((f) => f.booking.theme), [a, i] = q(!1), [o, s] = q(null), { id: l } = K((f) => f.booking.outletDetails), c = Be(async () => {
19971
20007
  try {
19972
20008
  i(!0), s(null);
19973
20009
  const f = await Mi(e);