@wix/bookings 1.0.1785 → 1.0.1787

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.
Files changed (51) hide show
  1. package/build/cjs/context-booking-checkout.d.ts +22 -6
  2. package/build/cjs/context-booking-checkout.js +2296 -2253
  3. package/build/cjs/context-booking-checkout.js.map +1 -1
  4. package/build/cjs/context-categories.js +285 -275
  5. package/build/cjs/context-categories.js.map +1 -1
  6. package/build/cjs/context-locations.js +465 -455
  7. package/build/cjs/context-locations.js.map +1 -1
  8. package/build/cjs/context-service-addons.js +964 -917
  9. package/build/cjs/context-service-addons.js.map +1 -1
  10. package/build/cjs/context-service.d.ts +14 -5
  11. package/build/cjs/context-service.js +3514 -3337
  12. package/build/cjs/context-service.js.map +1 -1
  13. package/build/cjs/context-services.js +878 -832
  14. package/build/cjs/context-services.js.map +1 -1
  15. package/build/cjs/context-time-slots.d.ts +10 -0
  16. package/build/cjs/context-time-slots.js +1202 -1159
  17. package/build/cjs/context-time-slots.js.map +1 -1
  18. package/build/es/context-booking-checkout.d.mts +22 -6
  19. package/build/es/context-booking-checkout.mjs +2304 -2261
  20. package/build/es/context-booking-checkout.mjs.map +1 -1
  21. package/build/es/context-categories.mjs +285 -275
  22. package/build/es/context-categories.mjs.map +1 -1
  23. package/build/es/context-locations.mjs +465 -455
  24. package/build/es/context-locations.mjs.map +1 -1
  25. package/build/es/context-service-addons.mjs +971 -924
  26. package/build/es/context-service-addons.mjs.map +1 -1
  27. package/build/es/context-service.d.mts +14 -5
  28. package/build/es/context-service.mjs +3383 -3206
  29. package/build/es/context-service.mjs.map +1 -1
  30. package/build/es/context-services.mjs +878 -832
  31. package/build/es/context-services.mjs.map +1 -1
  32. package/build/es/context-time-slots.d.mts +10 -0
  33. package/build/es/context-time-slots.mjs +1222 -1179
  34. package/build/es/context-time-slots.mjs.map +1 -1
  35. package/build/internal/cjs/context-booking-checkout.d.ts +22 -6
  36. package/build/internal/cjs/context-service.d.ts +14 -5
  37. package/build/internal/cjs/context-time-slots.d.ts +10 -0
  38. package/build/internal/es/context-booking-checkout.d.mts +22 -6
  39. package/build/internal/es/context-service.d.mts +14 -5
  40. package/build/internal/es/context-time-slots.d.mts +10 -0
  41. package/context-runtime/context-booking-checkout/runtime.d.ts +22 -6
  42. package/context-runtime/context-booking-checkout/runtime.js +3 -3
  43. package/context-runtime/context-categories/runtime.js +2 -2
  44. package/context-runtime/context-locations/runtime.js +2 -2
  45. package/context-runtime/context-service/runtime.d.ts +14 -5
  46. package/context-runtime/context-service/runtime.js +3 -3
  47. package/context-runtime/context-service-addons/runtime.js +2 -2
  48. package/context-runtime/context-services/runtime.js +3 -3
  49. package/context-runtime/context-time-slots/runtime.d.ts +10 -0
  50. package/context-runtime/context-time-slots/runtime.js +3 -3
  51. package/package.json +3 -3
@@ -20,12 +20,12 @@ var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: tru
20
20
  // context-services.ts
21
21
  var context_services_exports = {};
22
22
  __export(context_services_exports, {
23
- SERVICES_CONTEXT_MISSING_PROVIDER_ERROR: () => Lc,
24
- ServicesContextProvider: () => Uc,
25
- default: () => Uc,
26
- injectAccessTokenGetter: () => Wc,
27
- servicesContext: () => Ic,
28
- useServicesContext: () => Rc
23
+ SERVICES_CONTEXT_MISSING_PROVIDER_ERROR: () => Yc,
24
+ ServicesContextProvider: () => tl,
25
+ default: () => tl,
26
+ injectAccessTokenGetter: () => nl,
27
+ servicesContext: () => Jc,
28
+ useServicesContext: () => Xc
29
29
  });
30
30
  module.exports = __toCommonJS(context_services_exports);
31
31
 
@@ -84,7 +84,7 @@ var y = (e5) => (t2) => async (n2) => {
84
84
  var b = (e5) => e5.__isAmbassador ? true : !!e5().__isAmbassador;
85
85
  var x = `__metadata`;
86
86
  var S = `edge.wixapis.com`;
87
- var ee = class extends Error {
87
+ var C = class extends Error {
88
88
  message;
89
89
  response;
90
90
  constructor(e5, t2) {
@@ -92,24 +92,24 @@ var ee = class extends Error {
92
92
  }
93
93
  async details() {
94
94
  let e5 = await this.response.json();
95
- return C(this.response.status, e5?.message, e5?.details, { requestId: this.response.headers.get(`X-Wix-Request-Id`), details: e5 });
95
+ return w(this.response.status, e5?.message, e5?.details, { requestId: this.response.headers.get(`X-Wix-Request-Id`), details: e5 });
96
96
  }
97
97
  };
98
- var C = (e5, t2, n2, r2) => ({ details: { ...!n2?.validationError && { applicationError: { description: t2, code: e5, data: r2 } }, ...n2 }, message: t2, requestId: r2?.requestId });
99
- var w = (e5) => e5?.method && [`post`, `put`, `patch`].includes(e5.method.toLocaleLowerCase()) && e5.body ? { "Content-Type": `application/json` } : {};
100
- var T = (e5) => e5 && typeof e5 == `object` && !Array.isArray(e5);
101
- var E = (e5) => e5.__type === `host`;
102
- function D(e5, t2) {
98
+ var w = (e5, t2, n2, r2) => ({ details: { ...!n2?.validationError && { applicationError: { description: t2, code: e5, data: r2 } }, ...n2 }, message: t2, requestId: r2?.requestId });
99
+ var T = (e5) => e5?.method && [`post`, `put`, `patch`].includes(e5.method.toLocaleLowerCase()) && e5.body ? { "Content-Type": `application/json` } : {};
100
+ var E = (e5) => e5 && typeof e5 == `object` && !Array.isArray(e5);
101
+ var D = (e5) => e5.__type === `host`;
102
+ function O(e5, t2) {
103
103
  return e5.create(t2);
104
104
  }
105
- var O = `x-wix-bi-gateway`;
106
- function te(e5, t2, n2) {
107
- return { [O]: ne({ environment: `js-sdk${n2 ? `-${n2}` : ``}`, "package-name": e5.packageName ?? t2?.PACKAGE_NAME, "method-fqn": e5.methodFqn, entity: e5.entityFqdn }) };
105
+ var ee = `x-wix-bi-gateway`;
106
+ function k(e5, t2, n2) {
107
+ return { [ee]: te({ environment: `js-sdk${n2 ? `-${n2}` : ``}`, "package-name": e5.packageName ?? t2?.PACKAGE_NAME, "method-fqn": e5.methodFqn, entity: e5.entityFqdn }) };
108
108
  }
109
- function ne(e5) {
109
+ function te(e5) {
110
110
  return Object.entries(e5).filter(([e6, t2]) => !!t2).map(([e6, t2]) => `${e6}=${t2}`).join(`,`);
111
111
  }
112
- function re(e5) {
112
+ function ne(e5) {
113
113
  let t2 = globalThis.__wix_context__, n2 = { client: g.client, elevatedClient: g.elevatedClient }, r2;
114
114
  globalThis.__wix_context__ = void 0, g.client = void 0, g.elevatedClient = void 0, typeof $wixContext < `u` && (r2 = { client: $wixContext?.client, elevatedClient: $wixContext?.elevatedClient }, delete $wixContext.client, delete $wixContext.elevatedClient);
115
115
  try {
@@ -118,82 +118,82 @@ function re(e5) {
118
118
  globalThis.__wix_context__ = t2, g.client = n2.client, g.elevatedClient = n2.elevatedClient, typeof $wixContext < `u` && ($wixContext.client = r2.client, $wixContext.elevatedClient = r2.elevatedClient);
119
119
  }
120
120
  }
121
- var ie = { id: `_id`, createdDate: `_createdDate`, updatedDate: `_updatedDate` };
122
- function ae(e5) {
123
- return ue(e5).map((e6) => e6.toLocaleUpperCase()).join(`_`);
121
+ var re = { id: `_id`, createdDate: `_createdDate`, updatedDate: `_updatedDate` };
122
+ function A(e5) {
123
+ return ce(e5).map((e6) => e6.toLocaleUpperCase()).join(`_`);
124
124
  }
125
- var oe = /([\p{Ll}\d])(\p{Lu})/gu;
126
- var se = /(\p{Lu})([\p{Lu}][\p{Ll}])/gu;
127
- var ce = `$1\0$2`;
128
- var le = /[^\p{L}\d]+/giu;
129
- function ue(e5) {
125
+ var ie = /([\p{Ll}\d])(\p{Lu})/gu;
126
+ var ae = /(\p{Lu})([\p{Lu}][\p{Ll}])/gu;
127
+ var oe = `$1\0$2`;
128
+ var se = /[^\p{L}\d]+/giu;
129
+ function ce(e5) {
130
130
  let t2 = e5.trim();
131
- t2 = t2.replace(oe, ce).replace(se, ce), t2 = t2.replace(le, `\0`);
131
+ t2 = t2.replace(ie, oe).replace(ae, oe), t2 = t2.replace(se, `\0`);
132
132
  let n2 = 0, r2 = t2.length;
133
133
  for (; t2.charAt(n2) === `\0`; ) n2++;
134
134
  if (n2 === r2) return [];
135
135
  for (; t2.charAt(r2 - 1) === `\0`; ) r2--;
136
136
  return t2.slice(n2, r2).split(/\0/g);
137
137
  }
138
- var de = (e5) => `validationError` in (e5.response?.data?.details ?? {});
139
- var fe = (e5) => `applicationError` in (e5.response?.data?.details ?? {});
140
- var pe = (e5) => (e5.response?.status ?? -1) >= 400 && (e5.response?.status ?? -1) < 500;
141
- function me(e5, t2 = { explicitPathsToArguments: {}, spreadPathsToArguments: {}, singleArgumentUnchanged: false }, n2 = []) {
138
+ var le = (e5) => `validationError` in (e5.response?.data?.details ?? {});
139
+ var ue = (e5) => `applicationError` in (e5.response?.data?.details ?? {});
140
+ var de = (e5) => (e5.response?.status ?? -1) >= 400 && (e5.response?.status ?? -1) < 500;
141
+ function fe(e5, t2 = { explicitPathsToArguments: {}, spreadPathsToArguments: {}, singleArgumentUnchanged: false }, n2 = []) {
142
142
  if (typeof e5 != `object` || !e5) throw e5;
143
- if (de(e5)) return he(e5, t2, n2);
144
- if (fe(e5)) return _e(e5);
145
- if (pe(e5)) {
146
- let t3 = e5.response?.status, n3 = e5.response?.statusText ?? `UNKNOWN`, r2 = e5.response?.data?.message ?? n3, i2 = { applicationError: { description: n3, code: ae(n3), data: {} }, requestId: e5.requestId };
147
- return ge(e5, { message: JSON.stringify({ message: r2, details: i2 }, null, 2), extraProperties: { details: i2, status: t3 } });
143
+ if (le(e5)) return pe(e5, t2, n2);
144
+ if (ue(e5)) return he(e5);
145
+ if (de(e5)) {
146
+ let t3 = e5.response?.status, n3 = e5.response?.statusText ?? `UNKNOWN`, r2 = e5.response?.data?.message ?? n3, i2 = { applicationError: { description: n3, code: A(n3), data: {} }, requestId: e5.requestId };
147
+ return me(e5, { message: JSON.stringify({ message: r2, details: i2 }, null, 2), extraProperties: { details: i2, status: t3 } });
148
148
  }
149
- return ve(e5);
149
+ return ge(e5);
150
150
  }
151
- var he = (e5, t2, n2) => {
152
- let r2 = e5.response?.data, i2 = e5.requestId, { fieldViolations: a2 } = r2.details.validationError, o2 = ye(t2, a2, n2)?.sort((e6, t3) => e6.field < t3.field ? -1 : 1), s2 = `INVALID_ARGUMENT: ${o2?.map(({ field: e6, description: t3 }) => `"${e6}" ${t3}`)?.join(`, `)}`, c2 = { validationError: { fieldViolations: o2 }, requestId: i2 };
153
- return ge(e5, { message: JSON.stringify({ message: s2, details: c2 }, null, 2), extraProperties: { details: c2, status: e5.response?.status, requestId: i2 } });
151
+ var pe = (e5, t2, n2) => {
152
+ let r2 = e5.response?.data, i2 = e5.requestId, { fieldViolations: a2 } = r2.details.validationError, o2 = _e(t2, a2, n2)?.sort((e6, t3) => e6.field < t3.field ? -1 : 1), s2 = `INVALID_ARGUMENT: ${o2?.map(({ field: e6, description: t3 }) => `"${e6}" ${t3}`)?.join(`, `)}`, c2 = { validationError: { fieldViolations: o2 }, requestId: i2 };
153
+ return me(e5, { message: JSON.stringify({ message: s2, details: c2 }, null, 2), extraProperties: { details: c2, status: e5.response?.status, requestId: i2 } });
154
154
  };
155
- var ge = (e5, { message: t2, extraProperties: n2 }) => Object.assign(e5, { ...n2, message: t2 });
156
- var _e = (e5) => {
157
- let t2 = e5.response?.status, n2 = e5.response?.statusText ?? `UNKNOWN`, r2 = e5.response?.data?.message ?? n2, i2 = e5.response?.data?.details?.applicationError?.description ?? n2, a2 = e5.response?.data?.details?.applicationError?.code ?? ae(n2), o2 = e5.response?.data?.details?.applicationError?.data ?? {}, s2 = r2 === i2 ? r2 : `${r2}: ${i2}`, c2 = { applicationError: { description: i2, code: a2, data: o2 }, requestId: e5.requestId };
158
- return ge(e5, { message: JSON.stringify({ message: s2, details: c2 }, null, 2), extraProperties: { details: c2, status: t2, requestId: e5.requestId } });
155
+ var me = (e5, { message: t2, extraProperties: n2 }) => Object.assign(e5, { ...n2, message: t2 });
156
+ var he = (e5) => {
157
+ let t2 = e5.response?.status, n2 = e5.response?.statusText ?? `UNKNOWN`, r2 = e5.response?.data?.message ?? n2, i2 = e5.response?.data?.details?.applicationError?.description ?? n2, a2 = e5.response?.data?.details?.applicationError?.code ?? A(n2), o2 = e5.response?.data?.details?.applicationError?.data ?? {}, s2 = r2 === i2 ? r2 : `${r2}: ${i2}`, c2 = { applicationError: { description: i2, code: a2, data: o2 }, requestId: e5.requestId };
158
+ return me(e5, { message: JSON.stringify({ message: s2, details: c2 }, null, 2), extraProperties: { details: c2, status: t2, requestId: e5.requestId } });
159
159
  };
160
- var ve = (e5) => ge(e5, { message: e5.requestId ? `System error occurred, request-id: ${e5.requestId}` : `System error occurred: ${JSON.stringify(e5)}`, extraProperties: { requestId: e5.requestId, status: e5.response?.status, code: ae(e5.response?.statusText ?? `UNKNOWN`), ...!e5.response && { runtimeError: e5 } } });
161
- var ye = ({ spreadPathsToArguments: e5, explicitPathsToArguments: t2, singleArgumentUnchanged: n2 }, r2, i2) => {
160
+ var ge = (e5) => me(e5, { message: e5.requestId ? `System error occurred, request-id: ${e5.requestId}` : `System error occurred: ${JSON.stringify(e5)}`, extraProperties: { requestId: e5.requestId, status: e5.response?.status, code: A(e5.response?.statusText ?? `UNKNOWN`), ...!e5.response && { runtimeError: e5 } } });
161
+ var _e = ({ spreadPathsToArguments: e5, explicitPathsToArguments: t2, singleArgumentUnchanged: n2 }, r2, i2) => {
162
162
  let a2 = { ...e5, ...t2 }, o2 = Object.keys(a2);
163
163
  return r2?.filter((e6) => !r2.some((t3) => t3.field.length > e6.field.length && t3.field.startsWith(e6.field) && o2.includes(t3.field))).map((e6) => {
164
164
  let r3 = t2[e6.field];
165
- if (r3) return { ...e6, field: be(r3, i2) };
165
+ if (r3) return { ...e6, field: ve(r3, i2) };
166
166
  let s2 = o2?.sort((e7, t3) => t3.length - e7.length)?.find((t3) => e6.field.startsWith(t3));
167
167
  if (s2) {
168
168
  let t3 = a2[s2];
169
- if (t3) return { ...e6, field: e6.field.replace(s2, be(t3, i2)) };
169
+ if (t3) return { ...e6, field: e6.field.replace(s2, ve(t3, i2)) };
170
170
  }
171
171
  return n2 ? { ...e6, field: `${i2[0]}.${e6.field}` } : e6;
172
172
  });
173
173
  };
174
- var be = (e5, t2) => {
175
- let n2 = xe(e5);
174
+ var ve = (e5, t2) => {
175
+ let n2 = ye(e5);
176
176
  return n2 == null ? e5 : e5.replace(`$[${n2}]`, t2[n2]);
177
177
  };
178
- var xe = (e5) => {
178
+ var ye = (e5) => {
179
179
  let t2 = e5.match(/\$\[(?<argIndex>\d+)\]/);
180
180
  return t2 && t2.groups && Number(t2.groups.argIndex);
181
181
  };
182
- function Se(e5, t2, n2, r2, i2, a2, o2, s2, c2, l2, u2) {
183
- return re(() => e5({ request: async (e6) => {
182
+ function be(e5, t2, n2, r2, i2, a2, o2, s2, c2, l2, u2) {
183
+ return ne(() => e5({ request: async (e6) => {
184
184
  let i3 = e6({ host: s2?.HTTPHost || `www.wixapis.com` }), a3 = i3;
185
185
  a3.method === `GET` && a3.fallback?.length && (a3.params?.toString().length ?? 0) > 4e3 && (a3 = i3.fallback[0]);
186
186
  let o3 = s2?.HTTPHost ?? `www.wixapis.com`, u3 = `https://${l2 ? S : o3}${a3.url}`;
187
187
  a3.params && a3.params.toString() && (u3 += `?${a3.params.toString()}`);
188
188
  try {
189
- let e7 = te(i3, t2, c2), o4 = { method: a3.method, ...a3.data && { body: JSON.stringify(a3.data) }, headers: { ...e7 } }, s3 = await n2(u3, o4);
189
+ let e7 = k(i3, t2, c2), o4 = { method: a3.method, ...a3.data && { body: JSON.stringify(a3.data) }, headers: { ...e7 } }, s3 = await n2(u3, o4);
190
190
  if (s3.status !== 200) {
191
191
  let e8 = null;
192
192
  try {
193
193
  e8 = await s3.json();
194
194
  } catch {
195
195
  }
196
- let t3 = we(s3.status, e8?.message ?? s3.statusText, e8?.details, { requestId: s3.headers.get(`X-Wix-Request-Id`), details: e8 }), n3 = me(t3);
196
+ let t3 = Se(s3.status, e8?.message ?? s3.statusText, e8?.details, { requestId: s3.headers.get(`X-Wix-Request-Id`), details: e8 }), n3 = fe(t3);
197
197
  throw r2?.handleError(n3, { requestOptions: { url: a3.url, method: a3.method, entityFqdn: i3.entityFqdn, methodFqn: i3.methodFqn } }), t3;
198
198
  }
199
199
  let l3 = await s3.json();
@@ -203,18 +203,18 @@ function Se(e5, t2, n2, r2, i2, a2, o2, s2, c2, l2, u2) {
203
203
  }
204
204
  }, fetchWithAuth: n2, wixAPIFetch: i2, getActiveToken: a2, getAuthHeaders: o2 }, { validateRequestSchema: u2 }));
205
205
  }
206
- var Ce = class extends Error {
206
+ var xe = class extends Error {
207
207
  response;
208
208
  requestId;
209
209
  constructor(e5) {
210
210
  super(), this.response = e5.response, this.requestId = e5.requestId;
211
211
  }
212
212
  };
213
- var we = (e5, t2, n2, r2) => new Ce({ response: { data: { details: { ...!n2?.validationError && { applicationError: { description: t2, code: e5, data: r2 } }, ...n2 }, message: t2 }, status: e5 }, requestId: r2?.requestId });
214
- var Te = `.`;
215
- function Ee(e5, t2, n2) {
213
+ var Se = (e5, t2, n2, r2) => new xe({ response: { data: { details: { ...!n2?.validationError && { applicationError: { description: t2, code: e5, data: r2 } }, ...n2 }, message: t2 }, status: e5 }, requestId: r2?.requestId });
214
+ var Ce = `.`;
215
+ function we(e5, t2, n2) {
216
216
  if (e5 == null) throw Error(`Cannot set value on null or undefined`);
217
- let r2 = De(t2), i2 = e5;
217
+ let r2 = Te(t2), i2 = e5;
218
218
  for (let e6 = 0; e6 < r2.length; e6++) {
219
219
  let t3 = r2[e6];
220
220
  if (e6 === r2.length - 1) {
@@ -226,21 +226,21 @@ function Ee(e5, t2, n2) {
226
226
  }
227
227
  return e5;
228
228
  }
229
- function De(e5) {
230
- return Array.isArray(e5) ? e5 : e5.split(Te).map((e6) => Oe(e6) ? Number(e6) : e6);
229
+ function Te(e5) {
230
+ return Array.isArray(e5) ? e5 : e5.split(Ce).map((e6) => Ee(e6) ? Number(e6) : e6);
231
231
  }
232
- function Oe(e5) {
232
+ function Ee(e5) {
233
233
  return /^\d+$/.test(e5);
234
234
  }
235
- function ke(e5) {
235
+ function De(e5) {
236
236
  let t2 = {};
237
- for (let [n2, r2] of Object.entries(e5)) Ae(n2) || Ee(t2, De(n2), r2);
237
+ for (let [n2, r2] of Object.entries(e5)) Oe(n2) || we(t2, Te(n2), r2);
238
238
  return t2;
239
239
  }
240
- function Ae(e5) {
240
+ function Oe(e5) {
241
241
  return e5 === `__proto__` || e5 === `constructor` || e5 === `prototype`;
242
242
  }
243
- var je = class {
243
+ var ke = class {
244
244
  BRACKET_PATTERN = /\[(\d+)\]/g;
245
245
  NUMERIC_PATTERN = /^\d+$/;
246
246
  ESCAPED_DOT_PATTERN = /\\\./g;
@@ -263,7 +263,7 @@ var je = class {
263
263
  return e5.replace(this.ESCAPED_DOT_PLACEHOLDER, `\\.`).replace(this.ESCAPED_RIGHT_BRACKET_PLACEHOLDER, `\\]`).replace(this.ESCAPED_LEFT_BRACKET_PLACEHOLDER, `\\[`);
264
264
  }
265
265
  unflatten() {
266
- return this.cleanedModifiedFields = Object.fromEntries(Object.entries(this.modifiedFields).map(([e5, t2]) => [this.replaceEscapedCharacters(this.bracketToDotNotation(e5)), t2])), ke(this.cleanedModifiedFields);
266
+ return this.cleanedModifiedFields = Object.fromEntries(Object.entries(this.modifiedFields).map(([e5, t2]) => [this.replaceEscapedCharacters(this.bracketToDotNotation(e5)), t2])), De(this.cleanedModifiedFields);
267
267
  }
268
268
  flatten(e5) {
269
269
  let t2 = {};
@@ -283,12 +283,12 @@ var je = class {
283
283
  if (!Array.isArray(n2)) throw Error(`Expected array at path ${this.buildPathString(r2)}, but got ${typeof n2}`);
284
284
  r2.push(`[${e6}]`), n2 = n2[parseInt(e6, 10)];
285
285
  }, a2 = (e6, t3) => {
286
- let i3 = e6 in ie ? ie[e6] : void 0;
286
+ let i3 = e6 in re ? re[e6] : void 0;
287
287
  if (i3 && i3 in t3) {
288
288
  r2.push(i3), n2 = t3[i3];
289
289
  return;
290
290
  }
291
- let a3 = Fe(e6);
291
+ let a3 = Ne(e6);
292
292
  if (a3 && a3 in t3) {
293
293
  r2.push(a3), n2 = t3[a3];
294
294
  return;
@@ -319,28 +319,28 @@ var je = class {
319
319
  return e5.replace(this.BRACKET_PATTERN, (t2, n2, r2) => r2 > 0 && e5[r2 - 1] === `\\` ? t2 : `.` + n2);
320
320
  }
321
321
  };
322
- function Me(e5, t2) {
322
+ function Ae(e5, t2) {
323
323
  let n2 = e5?.modifiedFields;
324
324
  if (!n2) return null;
325
- let r2 = Ne(n2);
325
+ let r2 = je(n2);
326
326
  if (!r2) return null;
327
327
  let { unflattenedModifiedFields: i2, modifiedFieldsManipulator: a2 } = r2;
328
328
  e5 = { ...e5, modifiedFields: i2 };
329
329
  let o2 = t2(e5), s2 = o2?.modifiedFields;
330
330
  if (!s2) return null;
331
- let c2 = Pe(s2, a2);
331
+ let c2 = Me(s2, a2);
332
332
  return c2 === null ? null : (o2.modifiedFields = c2, o2);
333
333
  }
334
- function Ne(e5) {
334
+ function je(e5) {
335
335
  if (typeof e5 == `object` && e5 && !Array.isArray(e5)) try {
336
- let t2 = new je(e5);
336
+ let t2 = new ke(e5);
337
337
  return { unflattenedModifiedFields: t2.unflatten(), modifiedFieldsManipulator: t2 };
338
338
  } catch {
339
339
  return null;
340
340
  }
341
341
  return null;
342
342
  }
343
- function Pe(e5, t2) {
343
+ function Me(e5, t2) {
344
344
  if (typeof e5 == `object` && e5 && !Array.isArray(e5)) try {
345
345
  return t2.flatten(e5);
346
346
  } catch {
@@ -348,10 +348,10 @@ function Pe(e5, t2) {
348
348
  }
349
349
  return null;
350
350
  }
351
- function Fe(e5) {
351
+ function Ne(e5) {
352
352
  return e5.replace(/[-_\s]+(.)?/g, (e6, t2) => t2 ? t2.toUpperCase() : ``).replace(/^./, (e6) => e6.toLowerCase());
353
353
  }
354
- function Ie() {
354
+ function Pe() {
355
355
  return { emit(e5, ...t2) {
356
356
  for (let n2 = 0, r2 = this.events[e5] || [], i2 = r2.length; n2 < i2; n2++) r2[n2](...t2);
357
357
  }, events: {}, on(e5, t2) {
@@ -360,8 +360,8 @@ function Ie() {
360
360
  };
361
361
  } };
362
362
  }
363
- var Le = (e5) => e5.__type === `event-definition`;
364
- function Re(e5, t2, n2, r2) {
363
+ var Fe = (e5) => e5.__type === `event-definition`;
364
+ function Ie(e5, t2, n2, r2) {
365
365
  let i2;
366
366
  if (e5.isDomainEvent) {
367
367
  let { deletedEvent: e6, actionEvent: t3, createdEvent: a3, updatedEvent: o3, ...s3 } = n2, c2 = { ...r2, ...s3 };
@@ -372,14 +372,14 @@ function Re(e5, t2, n2, r2) {
372
372
  let e6 = s2.modifiedFields;
373
373
  if (typeof e6 == `object` && e6 && !Array.isArray(e6)) {
374
374
  o2 = structuredClone(i2);
375
- let e7 = Me(s2, a2);
375
+ let e7 = Ae(s2, a2);
376
376
  if (e7) return t2(e7);
377
377
  }
378
378
  }
379
379
  return t2(a2(o2));
380
380
  }
381
- function ze(e5) {
382
- let t2 = /* @__PURE__ */ new Map(), n2 = Ie();
381
+ function Le(e5) {
382
+ let t2 = /* @__PURE__ */ new Map(), n2 = Pe();
383
383
  return { initModule(e6) {
384
384
  return (r2) => {
385
385
  let i2 = t2.get(e6.type) ?? [];
@@ -389,7 +389,7 @@ function ze(e5) {
389
389
  let { eventType: r2, identity: i2, instanceId: a2, payload: o2, accountInfo: s2 } = await this.parseJWT(e6), c2 = [...n3.expectedEvents, ...Array.from(t2.keys()).map((e7) => ({ type: e7 }))];
390
390
  if (c2.length > 0 && !c2.some(({ type: e7 }) => e7 === r2)) throw Error(`Unexpected event type: ${r2}. Expected one of: ${c2.map((e7) => e7.type).join(`, `)}`);
391
391
  let l2 = t2.get(r2) ?? [];
392
- return await Promise.all(l2.map(({ eventDefinition: e7, handler: t3 }) => Re(e7, t3, o2, { instanceId: a2, identity: i2, accountInfo: s2 }))), { instanceId: a2, eventType: r2, payload: o2, identity: i2, accountInfo: s2 };
392
+ return await Promise.all(l2.map(({ eventDefinition: e7, handler: t3 }) => Ie(e7, t3, o2, { instanceId: a2, identity: i2, accountInfo: s2 }))), { instanceId: a2, eventType: r2, payload: o2, identity: i2, accountInfo: s2 };
393
393
  }, async processRequest(e6, t3) {
394
394
  let n3 = await e6.text();
395
395
  return this.process(n3, t3);
@@ -408,12 +408,12 @@ function ze(e5) {
408
408
  let n3 = Array.from(t2.keys()).map((e7) => ({ type: e7 }));
409
409
  if (n3.length > 0 && !n3.some(({ type: t3 }) => t3 === e6.eventType)) throw Error(`Unexpected event type: ${e6.eventType}. Expected one of: ${n3.map((e7) => e7.type).join(`, `)}`);
410
410
  let r2 = t2.get(e6.eventType) ?? [];
411
- await Promise.all(r2.map(({ eventDefinition: t3, handler: n4 }) => Re(t3, n4, e6.payload, { instanceId: e6.instanceId, identity: e6.identity })));
411
+ await Promise.all(r2.map(({ eventDefinition: t3, handler: n4 }) => Ie(t3, n4, e6.payload, { instanceId: e6.instanceId, identity: e6.identity })));
412
412
  }, apps: { AppInstalled: _(`AppInstalled`)(), AppRemoved: _(`AppRemoved`)() } } };
413
413
  }
414
- var Be = (e5) => e5.__type === `service-plugin-definition`;
415
- function Ve(e5) {
416
- let t2 = /* @__PURE__ */ new Map(), n2 = Ie();
414
+ var Re = (e5) => e5.__type === `service-plugin-definition`;
415
+ function ze(e5) {
416
+ let t2 = /* @__PURE__ */ new Map(), n2 = Pe();
417
417
  return { initModule(e6) {
418
418
  return (r2) => {
419
419
  let i2 = t2.get(e6.componentType.toLowerCase()) ?? [];
@@ -454,43 +454,43 @@ function Ve(e5) {
454
454
  return s2.transformations.toREST(await c2(s2.transformations.fromREST(e6)));
455
455
  } } };
456
456
  }
457
- var k = `X-Wix-Consistent`;
458
- function He(e5) {
457
+ var j = `X-Wix-Consistent`;
458
+ function Be(e5) {
459
459
  let t2 = e5.headers || { Authorization: `` }, n2 = { getAuthHeaders: (e6) => Promise.resolve({ headers: {} }) }, r2 = e5.auth, i2 = typeof r2 == `function` ? r2 : () => r2 ?? n2, a2 = () => i2().getAuthHeaders(e5.host), o2 = () => e5.fetch ?? fetch, s2 = async (n3, r3) => {
460
- let i3 = o2(), s3 = await a2(), c3 = { ...r3?.headers ?? {}, ...s3.headers, ...e5.host?.essentials?.passThroughHeaders, ...t2[`X-Wix-Consistent`] ? { [k]: t2[k] } : {} }, l3 = e5.host?.getErrorHandler?.();
460
+ let i3 = o2(), s3 = await a2(), c3 = { ...r3?.headers ?? {}, ...s3.headers, ...e5.host?.essentials?.passThroughHeaders, ...t2[`X-Wix-Consistent`] ? { [j]: t2[j] } : {} }, l3 = e5.host?.getErrorHandler?.();
461
461
  try {
462
462
  if (typeof n3 == `string` || n3 instanceof URL) {
463
463
  let e6 = await i3(n3, { ...r3, headers: c3 });
464
464
  l3?.handleError(e6, { requestOptions: { url: n3.toString(), method: r3?.method } });
465
- let a3 = Ue(e6);
466
- return a3 && (t2[k] = a3), e6;
465
+ let a3 = Ve(e6);
466
+ return a3 && (t2[j] = a3), e6;
467
467
  }
468
468
  {
469
469
  for (let [e7, t3] of Object.entries(c3)) typeof t3 == `string` && n3.headers.set(e7, t3);
470
470
  let e6 = await i3(n3, r3);
471
471
  l3?.handleError(e6, { requestOptions: { url: n3.url, method: r3?.method } });
472
- let a3 = Ue(e6);
473
- return a3 && (t2[k] = a3), e6;
472
+ let a3 = Ve(e6);
473
+ return a3 && (t2[j] = a3), e6;
474
474
  }
475
475
  } catch (e6) {
476
476
  throw l3?.handleError(e6, { requestOptions: { url: typeof n3 == `string` || n3 instanceof URL ? n3.toString() : n3.url, method: r3?.method } }), e6;
477
477
  }
478
- }, { client: c2, initModule: l2 } = Ve(i2), { client: u2, initModule: d2 } = ze(i2), f2 = async (n3, r3) => {
479
- let i3 = o2(), s3 = await a2(), c3 = w(r3), l3 = await i3(n3, { ...r3, headers: { ...c3, ...t2, ...s3?.headers, ...r3?.headers, ...e5.host?.essentials?.passThroughHeaders, ...t2[`X-Wix-Consistent`] ? { [k]: t2[k] } : {} } }), u3 = Ue(l3);
480
- return u3 && (t2[k] = u3), l3;
478
+ }, { client: c2, initModule: l2 } = ze(i2), { client: u2, initModule: d2 } = Le(i2), f2 = async (n3, r3) => {
479
+ let i3 = o2(), s3 = await a2(), c3 = T(r3), l3 = await i3(n3, { ...r3, headers: { ...c3, ...t2, ...s3?.headers, ...r3?.headers, ...e5.host?.essentials?.passThroughHeaders, ...t2[`X-Wix-Consistent`] ? { [j]: t2[j] } : {} } }), u3 = Ve(l3);
480
+ return u3 && (t2[j] = u3), l3;
481
481
  }, p2 = (t3, n3) => {
482
- if (Le(t3)) return d2(t3);
483
- if (Be(t3)) return l2(t3);
484
- if (E(t3) && e5.host) return D(t3, e5.host);
482
+ if (Fe(t3)) return d2(t3);
483
+ if (Re(t3)) return l2(t3);
484
+ if (D(t3) && e5.host) return O(t3, e5.host);
485
485
  if (typeof t3 == `function`) {
486
486
  if (`__type` in t3 && t3.__type === `wix_spi_error`) return t3;
487
487
  let r3 = e5.host?.apiBaseUrl ?? `www.wixapis.com`, o3 = e5.useCDN === void 0 ? i2().shouldUseCDN : e5.useCDN;
488
- return Se(re(() => b(t3)) ? y(t3) : t3, n3 ?? {}, f2, e5.host?.getErrorHandler?.(), (e6, t4) => {
488
+ return be(ne(() => b(t3)) ? y(t3) : t3, n3 ?? {}, f2, e5.host?.getErrorHandler?.(), (e6, t4) => {
489
489
  let n4 = new URL(e6, `https://${r3}`);
490
490
  return n4.host = r3, n4.protocol = `https`, f2(n4.toString(), t4);
491
491
  }, i2().getActiveToken, async () => a2(), { HTTPHost: r3 }, e5.host?.name, o3, e5.validateRequestSchema);
492
492
  }
493
- return T(t3) ? Object.fromEntries(Object.entries(t3).map(([e6, n4]) => [e6, p2(n4, t3[x])])) : t3;
493
+ return E(t3) ? Object.fromEntries(Object.entries(t3).map(([e6, n4]) => [e6, p2(n4, t3[x])])) : t3;
494
494
  }, m2 = (e6) => {
495
495
  for (let n3 in e6) t2[n3] = e6[n3];
496
496
  };
@@ -504,30 +504,30 @@ function He(e5) {
504
504
  return i3.host = r3, i3.protocol = `https`, f2(i3.toString(), n3);
505
505
  }, fetchWithAuth: s2, async graphql(t3, n3, r3 = { apiVersion: `alpha` }) {
506
506
  let i3 = e5?.host?.apiBaseUrl ?? `www.wixapis.com`, a3 = await f2(`https://${i3}/graphql/${r3.apiVersion}`, { method: `POST`, headers: { "Content-Type": `application/json` }, body: JSON.stringify({ query: t3, variables: n3 }) });
507
- if (a3.status !== 200) throw new ee(`GraphQL request failed with status ${a3.status}`, a3);
507
+ if (a3.status !== 200) throw new C(`GraphQL request failed with status ${a3.status}`, a3);
508
508
  let { data: o3, errors: s3 } = await a3.json();
509
509
  return { data: o3 ?? {}, errors: s3 };
510
510
  }, webhooks: u2, servicePlugins: c2 };
511
511
  }
512
- function Ue(e5) {
512
+ function Ve(e5) {
513
513
  return e5.headers?.get(`X-Wix-Consistent`) ?? e5.headers?.get(`x-wix-consistent`);
514
514
  }
515
- var We = { _id: `id`, _createdDate: `createdDate`, _updatedDate: `updatedDate` };
516
- var Ge = { id: `_id`, createdDate: `_createdDate`, updatedDate: `_updatedDate` };
517
- var Ke = `items`;
518
- var qe = `pagingMetadata`;
519
- var Je = We;
520
- function Ye(e5, t2) {
515
+ var He = { _id: `id`, _createdDate: `createdDate`, _updatedDate: `updatedDate` };
516
+ var Ue = { id: `_id`, createdDate: `_createdDate`, updatedDate: `_updatedDate` };
517
+ var We = `items`;
518
+ var Ge = `pagingMetadata`;
519
+ var Ke = He;
520
+ function qe(e5, t2) {
521
521
  return e5?.split(`.`).map((e6) => t2?.[e6] ?? e6).join(`.`);
522
522
  }
523
- function Xe(e5, { transformSystemFields: t2 = true } = {}) {
524
- return t2 ? Ye(e5, Je) : e5;
523
+ function Je(e5, { transformSystemFields: t2 = true } = {}) {
524
+ return t2 ? qe(e5, Ke) : e5;
525
525
  }
526
- var Ze = `sort.fieldName`;
527
- function Qe(e5, t2, n2) {
528
- return (e5 === Ze || e5.endsWith(`.${Ze}`)) && typeof t2 == `string` ? Ye(t2, n2) : t2;
526
+ var Ye = `sort.fieldName`;
527
+ function Xe(e5, t2, n2) {
528
+ return (e5 === Ye || e5.endsWith(`.${Ye}`)) && typeof t2 == `string` ? qe(t2, n2) : t2;
529
529
  }
530
- function $e(e5, t2, n2) {
530
+ function Ze(e5, t2, n2) {
531
531
  let r2 = (e6) => n2.includes(e6), i2 = (e6, n3) => {
532
532
  if (Array.isArray(e6)) e6.forEach((e7) => {
533
533
  i2(e7, n3);
@@ -537,147 +537,147 @@ function $e(e5, t2, n2) {
537
537
  Object.keys(a2).forEach((e7) => {
538
538
  let o2 = n3 === `` ? e7 : `${n3}.${e7}`;
539
539
  if (r2(o2)) return;
540
- let s2 = et(e7, t2);
541
- s2 !== e7 && !(s2 in a2) && (a2[s2] = a2[e7], delete a2[e7]), a2[s2] = Qe(o2, a2[s2], t2), i2(a2[s2], o2);
540
+ let s2 = Qe(e7, t2);
541
+ s2 !== e7 && !(s2 in a2) && (a2[s2] = a2[e7], delete a2[e7]), a2[s2] = Xe(o2, a2[s2], t2), i2(a2[s2], o2);
542
542
  });
543
543
  }
544
544
  };
545
545
  return i2(e5, ``), e5;
546
546
  }
547
- function et(e5, t2) {
547
+ function Qe(e5, t2) {
548
548
  let n2;
549
549
  return n2 = e5.includes(`.`) ? e5.split(`.`).map((e6) => t2[e6] ?? e6).join(`.`) : t2[e5] ?? e5, n2;
550
550
  }
551
- function A(e5, t2 = []) {
552
- return $e(e5, We, t2);
551
+ function M(e5, t2 = []) {
552
+ return Ze(e5, He, t2);
553
553
  }
554
- function j(e5, t2 = []) {
555
- return $e(e5, Ge, t2);
554
+ function N(e5, t2 = []) {
555
+ return Ze(e5, Ue, t2);
556
556
  }
557
- function M(e5) {
557
+ function P(e5) {
558
558
  return e5 ? new Date(e5) : void 0;
559
559
  }
560
- var tt = /* @__PURE__ */ new WeakMap();
561
- function nt() {
560
+ var $e = /* @__PURE__ */ new WeakMap();
561
+ function et() {
562
562
  return { leaves: void 0, fields: void 0, mapFields: void 0, anyField: void 0 };
563
563
  }
564
- function rt(e5, t2) {
564
+ function tt(e5, t2) {
565
565
  let n2 = e5.get(t2);
566
- return n2 || (n2 = nt(), e5.set(t2, n2)), n2;
566
+ return n2 || (n2 = et(), e5.set(t2, n2)), n2;
567
567
  }
568
- function it(e5, t2) {
569
- return t2 === `*` ? (e5.anyField ??= nt(), e5.anyField) : t2.endsWith(`{}`) ? (e5.mapFields ??= /* @__PURE__ */ new Map(), rt(e5.mapFields, t2.slice(0, -2))) : (e5.fields ??= /* @__PURE__ */ new Map(), rt(e5.fields, t2));
568
+ function nt(e5, t2) {
569
+ return t2 === `*` ? (e5.anyField ??= et(), e5.anyField) : t2.endsWith(`{}`) ? (e5.mapFields ??= /* @__PURE__ */ new Map(), tt(e5.mapFields, t2.slice(0, -2))) : (e5.fields ??= /* @__PURE__ */ new Map(), tt(e5.fields, t2));
570
570
  }
571
- function at(e5) {
572
- let t2 = nt();
571
+ function rt(e5) {
572
+ let t2 = et();
573
573
  for (let n2 of e5) {
574
- let e6 = n2.path.split(`.`).reduce(it, t2);
574
+ let e6 = n2.path.split(`.`).reduce(nt, t2);
575
575
  e6.leaves ??= [], e6.leaves.push(n2);
576
576
  }
577
577
  return t2;
578
578
  }
579
- function ot(e5) {
580
- let t2 = tt.get(e5);
581
- return t2 || (t2 = at(e5), tt.set(e5, t2)), t2;
579
+ function it(e5) {
580
+ let t2 = $e.get(e5);
581
+ return t2 || (t2 = rt(e5), $e.set(e5, t2)), t2;
582
582
  }
583
- function st(e5) {
583
+ function at(e5) {
584
584
  return typeof e5 == `object` && !!e5;
585
585
  }
586
- function ct(e5, { isRepeated: t2, isMap: n2 }, r2) {
587
- return t2 ? Array.isArray(e5) ? e5.map(r2) : e5 : n2 ? st(e5) ? Object.fromEntries(Object.entries(e5).map(([e6, t3]) => [e6, r2(t3)])) : e5 : r2(e5);
586
+ function ot(e5, { isRepeated: t2, isMap: n2 }, r2) {
587
+ return t2 ? Array.isArray(e5) ? e5.map(r2) : e5 : n2 ? at(e5) ? Object.fromEntries(Object.entries(e5).map(([e6, t3]) => [e6, r2(t3)])) : e5 : r2(e5);
588
588
  }
589
- function lt(e5, t2, n2) {
590
- st(e5) && ft(e5, t2, n2);
589
+ function st(e5, t2, n2) {
590
+ at(e5) && ut(e5, t2, n2);
591
591
  }
592
- function ut(e5, t2, n2) {
592
+ function ct(e5, t2, n2) {
593
593
  for (let [r2, i2] of t2) {
594
594
  if (!(r2 in e5)) continue;
595
- if (i2.leaves) for (let t4 of i2.leaves) e5[r2] = ct(e5[r2], t4, n2);
595
+ if (i2.leaves) for (let t4 of i2.leaves) e5[r2] = ot(e5[r2], t4, n2);
596
596
  let t3 = e5[r2];
597
- Array.isArray(t3) ? t3.forEach((e6) => lt(e6, i2, n2)) : lt(t3, i2, n2);
597
+ Array.isArray(t3) ? t3.forEach((e6) => st(e6, i2, n2)) : st(t3, i2, n2);
598
598
  }
599
599
  }
600
- function dt(e5, t2, n2) {
600
+ function lt(e5, t2, n2) {
601
601
  for (let [r2, i2] of t2) {
602
602
  let t3 = e5[r2];
603
- st(t3) && Object.values(t3).forEach((e6) => lt(e6, i2, n2));
603
+ at(t3) && Object.values(t3).forEach((e6) => st(e6, i2, n2));
604
604
  }
605
605
  }
606
- function ft(e5, { fields: t2, mapFields: n2, anyField: r2 }, i2) {
607
- t2 && ut(e5, t2, i2), n2 && dt(e5, n2, i2), r2 && Object.values(e5).forEach((e6) => lt(e6, r2, i2));
606
+ function ut(e5, { fields: t2, mapFields: n2, anyField: r2 }, i2) {
607
+ t2 && ct(e5, t2, i2), n2 && lt(e5, n2, i2), r2 && Object.values(e5).forEach((e6) => st(e6, r2, i2));
608
608
  }
609
- function N(e5, t2) {
610
- if (!st(e5)) return e5;
611
- for (let { paths: n2, transformFn: r2 } of t2) ft(e5, ot(n2), r2);
609
+ function F(e5, t2) {
610
+ if (!at(e5)) return e5;
611
+ for (let { paths: n2, transformFn: r2 } of t2) ut(e5, it(n2), r2);
612
612
  return e5;
613
613
  }
614
- function pt(e5) {
614
+ function dt(e5) {
615
615
  return Object.fromEntries(Object.entries(e5).filter(([, e6]) => e6 !== void 0));
616
616
  }
617
- function mt(e5) {
618
- return yt(e5).map((e6) => e6.toLocaleUpperCase()).join(`_`);
617
+ function ft(e5) {
618
+ return _t(e5).map((e6) => e6.toLocaleUpperCase()).join(`_`);
619
619
  }
620
- var ht = /([\p{Ll}\d])(\p{Lu})/gu;
621
- var gt = /(\p{Lu})([\p{Lu}][\p{Ll}])/gu;
622
- var _t = `$1\0$2`;
623
- var vt = /[^\p{L}\d]+/giu;
624
- function yt(e5) {
620
+ var pt = /([\p{Ll}\d])(\p{Lu})/gu;
621
+ var mt = /(\p{Lu})([\p{Lu}][\p{Ll}])/gu;
622
+ var ht = `$1\0$2`;
623
+ var gt = /[^\p{L}\d]+/giu;
624
+ function _t(e5) {
625
625
  let t2 = e5.trim();
626
- t2 = t2.replace(ht, _t).replace(gt, _t), t2 = t2.replace(vt, `\0`);
626
+ t2 = t2.replace(pt, ht).replace(mt, ht), t2 = t2.replace(gt, `\0`);
627
627
  let n2 = 0, r2 = t2.length;
628
628
  for (; t2.charAt(n2) === `\0`; ) n2++;
629
629
  if (n2 === r2) return [];
630
630
  for (; t2.charAt(r2 - 1) === `\0`; ) r2--;
631
631
  return t2.slice(n2, r2).split(/\0/g);
632
632
  }
633
- var bt = (e5) => `validationError` in (e5.response?.data?.details ?? {});
634
- var xt = (e5) => `applicationError` in (e5.response?.data?.details ?? {});
635
- var St = (e5) => (e5.response?.status ?? -1) >= 400 && (e5.response?.status ?? -1) < 500;
636
- function P(e5, t2 = { explicitPathsToArguments: {}, spreadPathsToArguments: {}, singleArgumentUnchanged: false }, n2 = []) {
633
+ var vt = (e5) => `validationError` in (e5.response?.data?.details ?? {});
634
+ var yt = (e5) => `applicationError` in (e5.response?.data?.details ?? {});
635
+ var bt = (e5) => (e5.response?.status ?? -1) >= 400 && (e5.response?.status ?? -1) < 500;
636
+ function I(e5, t2 = { explicitPathsToArguments: {}, spreadPathsToArguments: {}, singleArgumentUnchanged: false }, n2 = []) {
637
637
  if (typeof e5 != `object` || !e5) throw e5;
638
- if (bt(e5)) return Ct(e5, t2, n2);
639
- if (xt(e5)) return Tt(e5);
640
- if (St(e5)) {
641
- let t3 = e5.response?.status, n3 = e5.response?.statusText ?? `UNKNOWN`, r2 = e5.response?.data?.message ?? n3, i2 = { applicationError: { description: n3, code: mt(n3), data: {} }, requestId: e5.requestId };
642
- return wt(e5, { message: JSON.stringify({ message: r2, details: i2 }, null, 2), extraProperties: { details: i2, status: t3 } });
638
+ if (vt(e5)) return xt(e5, t2, n2);
639
+ if (yt(e5)) return Ct(e5);
640
+ if (bt(e5)) {
641
+ let t3 = e5.response?.status, n3 = e5.response?.statusText ?? `UNKNOWN`, r2 = e5.response?.data?.message ?? n3, i2 = { applicationError: { description: n3, code: ft(n3), data: {} }, requestId: e5.requestId };
642
+ return St(e5, { message: JSON.stringify({ message: r2, details: i2 }, null, 2), extraProperties: { details: i2, status: t3 } });
643
643
  }
644
- return Et(e5);
644
+ return wt(e5);
645
645
  }
646
- var Ct = (e5, t2, n2) => {
647
- let r2 = e5.response?.data, i2 = e5.requestId, { fieldViolations: a2 } = r2.details.validationError, o2 = Dt(t2, a2, n2)?.sort((e6, t3) => e6.field < t3.field ? -1 : 1), s2 = `INVALID_ARGUMENT: ${o2?.map(({ field: e6, description: t3 }) => `"${e6}" ${t3}`)?.join(`, `)}`, c2 = { validationError: { fieldViolations: o2 }, requestId: i2 };
648
- return wt(e5, { message: JSON.stringify({ message: s2, details: c2 }, null, 2), extraProperties: { details: c2, status: e5.response?.status, requestId: i2 } });
646
+ var xt = (e5, t2, n2) => {
647
+ let r2 = e5.response?.data, i2 = e5.requestId, { fieldViolations: a2 } = r2.details.validationError, o2 = Tt(t2, a2, n2)?.sort((e6, t3) => e6.field < t3.field ? -1 : 1), s2 = `INVALID_ARGUMENT: ${o2?.map(({ field: e6, description: t3 }) => `"${e6}" ${t3}`)?.join(`, `)}`, c2 = { validationError: { fieldViolations: o2 }, requestId: i2 };
648
+ return St(e5, { message: JSON.stringify({ message: s2, details: c2 }, null, 2), extraProperties: { details: c2, status: e5.response?.status, requestId: i2 } });
649
649
  };
650
- var wt = (e5, { message: t2, extraProperties: n2 }) => Object.assign(e5, { ...n2, message: t2 });
651
- var Tt = (e5) => {
652
- let t2 = e5.response?.status, n2 = e5.response?.statusText ?? `UNKNOWN`, r2 = e5.response?.data?.message ?? n2, i2 = e5.response?.data?.details?.applicationError?.description ?? n2, a2 = e5.response?.data?.details?.applicationError?.code ?? mt(n2), o2 = e5.response?.data?.details?.applicationError?.data ?? {}, s2 = r2 === i2 ? r2 : `${r2}: ${i2}`, c2 = { applicationError: { description: i2, code: a2, data: o2 }, requestId: e5.requestId };
653
- return wt(e5, { message: JSON.stringify({ message: s2, details: c2 }, null, 2), extraProperties: { details: c2, status: t2, requestId: e5.requestId } });
650
+ var St = (e5, { message: t2, extraProperties: n2 }) => Object.assign(e5, { ...n2, message: t2 });
651
+ var Ct = (e5) => {
652
+ let t2 = e5.response?.status, n2 = e5.response?.statusText ?? `UNKNOWN`, r2 = e5.response?.data?.message ?? n2, i2 = e5.response?.data?.details?.applicationError?.description ?? n2, a2 = e5.response?.data?.details?.applicationError?.code ?? ft(n2), o2 = e5.response?.data?.details?.applicationError?.data ?? {}, s2 = r2 === i2 ? r2 : `${r2}: ${i2}`, c2 = { applicationError: { description: i2, code: a2, data: o2 }, requestId: e5.requestId };
653
+ return St(e5, { message: JSON.stringify({ message: s2, details: c2 }, null, 2), extraProperties: { details: c2, status: t2, requestId: e5.requestId } });
654
654
  };
655
- var Et = (e5) => wt(e5, { message: e5.requestId ? `System error occurred, request-id: ${e5.requestId}` : `System error occurred: ${JSON.stringify(e5)}`, extraProperties: { requestId: e5.requestId, status: e5.response?.status, code: mt(e5.response?.statusText ?? `UNKNOWN`), ...!e5.response && { runtimeError: e5 } } });
656
- var Dt = ({ spreadPathsToArguments: e5, explicitPathsToArguments: t2, singleArgumentUnchanged: n2 }, r2, i2) => {
655
+ var wt = (e5) => St(e5, { message: e5.requestId ? `System error occurred, request-id: ${e5.requestId}` : `System error occurred: ${JSON.stringify(e5)}`, extraProperties: { requestId: e5.requestId, status: e5.response?.status, code: ft(e5.response?.statusText ?? `UNKNOWN`), ...!e5.response && { runtimeError: e5 } } });
656
+ var Tt = ({ spreadPathsToArguments: e5, explicitPathsToArguments: t2, singleArgumentUnchanged: n2 }, r2, i2) => {
657
657
  let a2 = { ...e5, ...t2 }, o2 = Object.keys(a2);
658
658
  return r2?.filter((e6) => !r2.some((t3) => t3.field.length > e6.field.length && t3.field.startsWith(e6.field) && o2.includes(t3.field))).map((e6) => {
659
659
  let r3 = t2[e6.field];
660
- if (r3) return { ...e6, field: Ot(r3, i2) };
660
+ if (r3) return { ...e6, field: Et(r3, i2) };
661
661
  let s2 = o2?.sort((e7, t3) => t3.length - e7.length)?.find((t3) => e6.field.startsWith(t3));
662
662
  if (s2) {
663
663
  let t3 = a2[s2];
664
- if (t3) return { ...e6, field: e6.field.replace(s2, Ot(t3, i2)) };
664
+ if (t3) return { ...e6, field: e6.field.replace(s2, Et(t3, i2)) };
665
665
  }
666
666
  return n2 ? { ...e6, field: `${i2[0]}.${e6.field}` } : e6;
667
667
  });
668
668
  };
669
- var Ot = (e5, t2) => {
670
- let n2 = kt(e5);
669
+ var Et = (e5, t2) => {
670
+ let n2 = Dt(e5);
671
671
  return n2 == null ? e5 : e5.replace(`$[${n2}]`, t2[n2]);
672
672
  };
673
- var kt = (e5) => {
673
+ var Dt = (e5) => {
674
674
  let t2 = e5.match(/\$\[(?<argIndex>\d+)\]/);
675
675
  return t2 && t2.groups && Number(t2.groups.argIndex);
676
676
  };
677
- function At() {
677
+ function Ot() {
678
678
  let e5 = typeof $wixContext < `u` && $wixContext.initWixModules ? $wixContext.initWixModules : globalThis.__wix_context__ !== void 0 && globalThis.__wix_context__.initWixModules ? globalThis.__wix_context__.initWixModules : void 0;
679
679
  if (e5) return { initWixModules(t3, n3) {
680
- return jt(() => e5(t3, n3));
680
+ return kt(() => e5(t3, n3));
681
681
  }, fetchWithAuth() {
682
682
  throw Error(`fetchWithAuth is not available in this context`);
683
683
  }, graphql() {
@@ -687,10 +687,10 @@ function At() {
687
687
  if (t2 || n2) return { initWixModules(e6, r2) {
688
688
  if (r2) {
689
689
  if (!n2) throw Error(`An elevated client is required to use elevated modules. Make sure to initialize the Wix context with an elevated client before using elevated SDK modules`);
690
- return jt(() => n2.use(e6));
690
+ return kt(() => n2.use(e6));
691
691
  }
692
692
  if (!t2) throw Error(`Wix context is not available. Make sure to initialize the Wix context before using SDK modules`);
693
- return jt(() => t2.use(e6));
693
+ return kt(() => t2.use(e6));
694
694
  }, fetchWithAuth: (e6, n3) => {
695
695
  if (!t2) throw Error(`Wix context is not available. Make sure to initialize the Wix context before using SDK modules`);
696
696
  return t2.fetchWithAuth(e6, n3);
@@ -702,7 +702,7 @@ function At() {
702
702
  return t2.graphql(e6, n3, r2);
703
703
  } };
704
704
  }
705
- function jt(e5) {
705
+ function kt(e5) {
706
706
  let t2 = globalThis.__wix_context__, n2 = { client: g.client, elevatedClient: g.elevatedClient }, r2;
707
707
  globalThis.__wix_context__ = void 0, g.client = void 0, g.elevatedClient = void 0, typeof $wixContext < `u` && (r2 = { client: $wixContext?.client, elevatedClient: $wixContext?.elevatedClient }, delete $wixContext.client, delete $wixContext.elevatedClient);
708
708
  try {
@@ -711,108 +711,108 @@ function jt(e5) {
711
711
  globalThis.__wix_context__ = t2, g.client = n2.client, g.elevatedClient = n2.elevatedClient, typeof $wixContext < `u` && ($wixContext.client = r2.client, $wixContext.elevatedClient = r2.elevatedClient);
712
712
  }
713
713
  }
714
- function Mt(e5, t2) {
714
+ function At(e5, t2) {
715
715
  return (...n2) => {
716
- let r2 = At();
716
+ let r2 = Ot();
717
717
  return r2 ? r2.initWixModules(e5, t2).apply(void 0, n2) : e5.apply(void 0, n2);
718
718
  };
719
719
  }
720
- function Nt(e5) {
720
+ function jt(e5) {
721
721
  let t2 = (...t3) => {
722
- let n2 = At();
722
+ let n2 = Ot();
723
723
  return n2 ? n2.initWixModules(e5).apply(void 0, t3) : () => ({ slug: e5.type });
724
724
  };
725
725
  return t2.__type = e5.__type, t2.type = e5.type, t2.isDomainEvent = e5.isDomainEvent, t2.transformations = e5.transformations, t2;
726
726
  }
727
- function Pt(e5, t2 = false) {
728
- return Mt(e5, t2);
727
+ function Mt(e5, t2 = false) {
728
+ return At(e5, t2);
729
729
  }
730
- function Ft(e5, t2) {
731
- let n2 = Lt(e5), r2 = Object.entries(n2).some(([e6, t3]) => e6.includes(`.`) || Array.isArray(t3) && t3.some((e7) => typeof e7 == `object`));
732
- return t2 && r2 ? new URLSearchParams({ ".r": zt(JSON.stringify(e5)) }) : Object.entries(n2).reduce((e6, [t3, n3]) => ((Array.isArray(n3) ? n3 : [n3]).forEach((r3) => {
730
+ function Nt(e5, t2) {
731
+ let n2 = Ft(e5), r2 = Object.entries(n2).some(([e6, t3]) => e6.includes(`.`) || Array.isArray(t3) && t3.some((e7) => typeof e7 == `object`));
732
+ return t2 && r2 ? new URLSearchParams({ ".r": Lt(JSON.stringify(e5)) }) : Object.entries(n2).reduce((e6, [t3, n3]) => ((Array.isArray(n3) ? n3 : [n3]).forEach((r3) => {
733
733
  r3 == null || Array.isArray(n3) && typeof r3 == `object` || e6.append(t3, r3);
734
734
  }), e6), new URLSearchParams());
735
735
  }
736
- function It(e5) {
737
- let t2 = Qt(Xt(e5.host), e5.domainToMappings);
738
- return cn(an(e5.protoPath, e5.data || {}), t2);
736
+ function Pt(e5) {
737
+ let t2 = Xt(Jt(e5.host), e5.domainToMappings);
738
+ return on(nn(e5.protoPath, e5.data || {}), t2);
739
739
  }
740
- function Lt(e5, t2 = ``) {
740
+ function Ft(e5, t2 = ``) {
741
741
  let n2 = {};
742
742
  return Object.entries(e5).forEach(([e6, r2]) => {
743
- let i2 = typeof r2 == `object` && !!r2 && !Array.isArray(r2), a2 = Rt(t2, e6);
743
+ let i2 = typeof r2 == `object` && !!r2 && !Array.isArray(r2), a2 = It(t2, e6);
744
744
  if (i2) {
745
- let e7 = Lt(r2, a2);
745
+ let e7 = Ft(r2, a2);
746
746
  Object.assign(n2, e7);
747
747
  } else n2[a2] = r2;
748
748
  }), n2;
749
749
  }
750
- function Rt(e5, t2) {
750
+ function It(e5, t2) {
751
751
  return `${e5}${e5 ? `.` : ``}${t2}`;
752
752
  }
753
- var zt = (e5) => {
753
+ var Lt = (e5) => {
754
754
  let t2 = new TextEncoder().encode(e5);
755
755
  return (typeof btoa < `u` ? btoa(String.fromCodePoint(...t2)) : Buffer.from(e5, `utf-8`).toString(`base64`)).replace(/=/g, ``).replace(/\+/g, `-`).replace(/\//g, `_`);
756
756
  };
757
- var Bt = [`wix.com`, `editorx.com`];
758
- var Vt = `_`;
759
- var Ht = `*.`;
760
- var Ut = RegExp(`\\.(${Bt.join(`|`)})$`);
761
- var Wt = [`42.wixprod.net`, `uw2-edt-1.wixprod.net`, `virginia-edt.wixprod.net`];
762
- var Gt = { "payments.base44.com": `manage.wix.com`, "create.editorx.com": `editor.editorx.com` };
763
- var Kt = `dev.wix-code.com`;
764
- var qt = /{(.*)}/;
765
- var Jt = RegExp(`\\.(${Wt.join(`|`)})$`);
766
- var Yt = RegExp(`.*\\.${Kt}$`);
767
- function Xt(e5) {
768
- return Zt(e5).replace(Ut, `._base_domain_`).replace(Jt, `._api_base_domain_`).replace(Yt, `*.dev.wix-code.com`);
769
- }
770
- function Zt(e5) {
771
- return Gt[e5] ?? e5;
772
- }
773
- function Qt(e5, t2) {
757
+ var Rt = [`wix.com`, `editorx.com`];
758
+ var zt = `_`;
759
+ var Bt = `*.`;
760
+ var Vt = RegExp(`\\.(${Rt.join(`|`)})$`);
761
+ var Ht = [`42.wixprod.net`, `uw2-edt-1.wixprod.net`, `virginia-edt.wixprod.net`];
762
+ var Ut = { "payments.base44.com": `manage.wix.com`, "create.editorx.com": `editor.editorx.com` };
763
+ var Wt = `dev.wix-code.com`;
764
+ var Gt = /{(.*)}/;
765
+ var Kt = RegExp(`\\.(${Ht.join(`|`)})$`);
766
+ var qt = RegExp(`.*\\.${Wt}$`);
767
+ function Jt(e5) {
768
+ return Yt(e5).replace(Vt, `._base_domain_`).replace(Kt, `._api_base_domain_`).replace(qt, `*.dev.wix-code.com`);
769
+ }
770
+ function Yt(e5) {
771
+ return Ut[e5] ?? e5;
772
+ }
773
+ function Xt(e5, t2) {
774
774
  let n2 = t2[e5];
775
775
  if (n2) return n2;
776
- let r2 = $t(e5, t2) ?? en(e5, t2);
776
+ let r2 = Zt(e5, t2) ?? Qt(e5, t2);
777
777
  if (!r2) {
778
- if (nn(e5)) {
779
- let e6 = t2[rn];
778
+ if (en(e5)) {
779
+ let e6 = t2[tn];
780
780
  if (e6) return e6;
781
781
  }
782
- let n3 = t2[Vt];
782
+ let n3 = t2[zt];
783
783
  if (n3) return n3;
784
784
  }
785
785
  return r2 ?? [];
786
786
  }
787
- function $t(e5, t2) {
787
+ function Zt(e5, t2) {
788
788
  return Object.entries(t2).find(([t3]) => {
789
789
  let [, ...n2] = e5.split(`.`);
790
790
  return n2.join(`.`) === t3;
791
791
  })?.[1];
792
792
  }
793
- function en(e5, t2) {
794
- let [n2] = Object.entries(t2).filter(([t3]) => tn(e5, t3)).sort(([e6], [t3]) => t3.length - e6.length);
793
+ function Qt(e5, t2) {
794
+ let [n2] = Object.entries(t2).filter(([t3]) => $t(e5, t3)).sort(([e6], [t3]) => t3.length - e6.length);
795
795
  if (!n2) return;
796
796
  let [, r2] = n2;
797
797
  return r2;
798
798
  }
799
- function tn(e5, t2) {
800
- if (!t2.startsWith(Ht)) return false;
799
+ function $t(e5, t2) {
800
+ if (!t2.startsWith(Bt)) return false;
801
801
  let n2 = t2.slice(1);
802
802
  return e5.length > n2.length && e5.endsWith(n2);
803
803
  }
804
- function nn(e5) {
804
+ function en(e5) {
805
805
  return !!e5.match(/\._base_domain_$/);
806
806
  }
807
- var rn = `www._base_domain_`;
808
- function an(e5, t2) {
809
- return e5.split(`/`).map((e6) => on(e6, t2)).join(`/`);
807
+ var tn = `www._base_domain_`;
808
+ function nn(e5, t2) {
809
+ return e5.split(`/`).map((e6) => rn(e6, t2)).join(`/`);
810
810
  }
811
- function on(e5, t2) {
812
- let n2 = e5.match(qt) || [], r2 = n2[1];
813
- return r2 ? sn(t2, r2, e5, e5.replace(n2[0], ``)) : e5;
811
+ function rn(e5, t2) {
812
+ let n2 = e5.match(Gt) || [], r2 = n2[1];
813
+ return r2 ? an(t2, r2, e5, e5.replace(n2[0], ``)) : e5;
814
814
  }
815
- function sn(e5, t2, n2, r2) {
815
+ function an(e5, t2, n2, r2) {
816
816
  let i2 = e5;
817
817
  for (let e6 of t2.split(`.`)) {
818
818
  if (!i2) return n2;
@@ -820,40 +820,40 @@ function sn(e5, t2, n2, r2) {
820
820
  }
821
821
  return `${i2}${r2}`;
822
822
  }
823
- function cn(e5, t2) {
823
+ function on(e5, t2) {
824
824
  let n2 = t2?.find((t3) => e5.startsWith(t3.destPath));
825
825
  return n2 ? n2.srcPath + e5.slice(n2.destPath.length) : e5;
826
826
  }
827
- function ln(e5) {
828
- return Nt(e5);
827
+ function sn(e5) {
828
+ return jt(e5);
829
829
  }
830
- function un(e5) {
830
+ function cn(e5) {
831
831
  return e5 === `NaN` ? NaN : e5 === `Infinity` ? 1 / 0 : e5 === `-Infinity` ? -1 / 0 : e5;
832
832
  }
833
- function dn(e5) {
834
- return e5 && pt({ formatted: e5.formattedAddress, location: e5.geocode, addressLine1: e5.addressLine, addressLine2: e5.addressLine2, streetAddress: e5.streetAddress && { name: e5.streetAddress.name, number: e5.streetAddress.number, apt: e5.streetAddress.apt, formattedAddressLine: e5.streetAddress.formattedAddressLine }, hint: e5.hint, city: e5.city, subdivision: e5.subdivision, country: e5.country, postalCode: e5.postalCode, countryFullname: e5.countryFullname, subdivisionFullname: e5.subdivisionFullname });
833
+ function ln(e5) {
834
+ return e5 && dt({ formatted: e5.formattedAddress, location: e5.geocode, addressLine1: e5.addressLine, addressLine2: e5.addressLine2, streetAddress: e5.streetAddress && { name: e5.streetAddress.name, number: e5.streetAddress.number, apt: e5.streetAddress.apt, formattedAddressLine: e5.streetAddress.formattedAddressLine }, hint: e5.hint, city: e5.city, subdivision: e5.subdivision, country: e5.country, postalCode: e5.postalCode, countryFullname: e5.countryFullname, subdivisionFullname: e5.subdivisionFullname });
835
835
  }
836
- var fn;
836
+ var un;
837
837
  (function(e5) {
838
838
  e5.QUERY_PARAM = `QUERY_PARAM`, e5.SUBDOMAIN = `SUBDOMAIN`, e5.SUBDIRECTORY = `SUBDIRECTORY`;
839
- })(fn ||= {});
840
- var pn = { cs: `\u010Ce\u0161tina`, da: `Dansk`, de: `Deutsch`, en: `English`, es: `Espa\xF1ol`, fr: `Fran\xE7ais`, hi: `\u0939\u093F\u0928\u094D\u0926\u0940`, id: `Bahasa Indonesia`, it: `Italiano`, ja: `\u65E5\u672C\u8A9E`, ko: `\uD55C\uAD6D\uC5B4`, nl: `Nederlands`, no: `Norsk`, pl: `Polski`, pt: `Portugu\xEAs`, ru: `\u0420\u0443\u0441\u0441\u043A\u0438\u0439`, sv: `Svenska`, th: `\u0E44\u0E17\u0E22`, tr: `T\xFCrk\xE7e`, uk: `\u0423\u043A\u0440\u0430\u0457\u043D\u0441\u044C\u043A\u0430`, vi: `Ti\u1EBFng Vi\u1EC7t`, zh: `\u7E41\u9AD4\u4E2D\u6587`, sq: `Shqip`, am: `\u12A0\u121B\u122D\u129B`, ar: `\u0627\u0644\u0639\u0631\u0628\u064A\u0629`, hy: `\u0540\u0561\u0575\u0565\u0580\u0565\u0576`, az: `Az\u0259rbaycan dili`, eu: `Euskara`, be: `\u0411\u0435\u043B\u0430\u0440\u0443\u0441\u043A\u0430\u044F`, bn: `\u09AC\u09BE\u0982\u09B2\u09BE`, bs: `Bosanski`, bg: `\u0411\u044A\u043B\u0433\u0430\u0440\u0441\u043A\u0438`, ca: `Catal\xE0`, ny: `ChiChe\u0175a`, co: `Corsu`, hr: `Hrvatski`, et: `Eesti`, fj: `Vosa Vakaviti`, fi: `Suomi`, ga: `Gaeilge`, gl: `Galego`, ka: `\u10E5\u10D0\u10E0\u10D7\u10E3\u10DA\u10D8`, el: `\u0395\u03BB\u03BB\u03B7\u03BD\u03B9\u03BA\u03AC`, gu: `\u0A97\u0AC1\u0A9C\u0AB0\u0ABE\u0AA4\u0AC0`, ht: `Krey\xF2l Ayisyen`, ha: `Hausa`, he: `\u05E2\u05D1\u05E8\u05D9\u05EA`, hu: `Magyar`, is: `\xCDslenska`, ig: `Igbo`, kn: `\u0C95\u0CA8\u0CCD\u0CA8\u0CA1`, kk: `\u049A\u0430\u0437\u0430\u049B \u0442\u0456\u043B\u0456`, km: `\u1797\u17B6\u179F\u17B6\u1781\u17D2\u1798\u17C2\u179A`, ku: `Kurd\xEE`, ky: `\u041A\u044B\u0440\u0433\u044B\u0437\u0447\u0430`, lb: `L\xEBtzebuergesch`, lo: `\u0EA5\u0EB2\u0EA7`, la: `Latina`, lv: `Latvie\u0161u`, lt: `Lietuvi\u0173`, mk: `\u041C\u0430\u043A\u0435\u0434\u043E\u043D\u0441\u043A\u0438`, mg: `Malagasy`, ms: `Bahasa Melayu`, ml: `\u0D2E\u0D32\u0D2F\u0D3E\u0D33\u0D02`, mt: `Malti`, mn: `\u041C\u043E\u043D\u0433\u043E\u043B`, ne: `\u0928\u0947\u092A\u093E\u0932\u0940`, ps: `\u067E\u069A\u062A\u0648`, fa: `\u0641\u0627\u0631\u0633\u06CC`, ro: `Rom\xE2n\u0103`, sm: `Gagana Samoa`, sr: `\u0421\u0440\u043F\u0441\u043A\u0438`, sn: `Shona`, sd: `\u0633\u0646\u068C\u064A`, si: `\u0DC3\u0DD2\u0D82\u0DC4\u0DBD`, sk: `Sloven\u010Dina`, sl: `Sloven\u0161\u010Dina`, so: `Soomaaliga`, su: `Basa Sunda`, sw: `Kiswahili`, tl: `Filipino`, tg: `\u0422\u043E\u04B7\u0438\u043A\u04E3`, ta: `\u0BA4\u0BAE\u0BBF\u0BB4\u0BCD`, te: `\u0C24\u0C46\u0C32\u0C41\u0C17\u0C41`, tk: `T\xFCrkmen`, ur: `\u0627\u0631\u062F\u0648`, uz: `O'zbek`, cy: `Cymraeg`, xh: `isiXhosa`, yi: `\u05D9\u05D9\u05B4\u05D3\u05D9\u05E9`, yo: `Yor\xF9b\xE1`, zu: `isiZulu`, kl: `Kalaallisut`, fo: `F\xF8royskt`, ln: `Ling\xE1la`, mi: `M\u0101ori`, mr: `\u092E\u0930\u093E\u0920\u0940`, my: `\u1019\u103C\u1014\u103A\u1019\u102C`, se: `S\xE1megiella`, ug: `\u0626\u06C7\u064A\u063A\u06C7\u0631\u0686\u06D5`, qu: `Runa Simi`, aa: `Afar`, ab: `\u0410\u04A7\u0441\u0443\u0430`, ae: `Avestan`, ak: `Akan`, an: `Aragon\xE9s`, as: `\u0985\u09B8\u09AE\u09C0\u09AF\u09BC\u09BE`, av: `\u0410\u0432\u0430\u0440`, ay: `Aymar aru`, ba: `\u0411\u0430\u0448\u04A1\u043E\u0440\u0442\u0441\u0430`, bh: `\u092D\u094B\u091C\u092A\u0941\u0930\u0940`, bi: `Bislama`, bm: `Bamanankan`, bo: `\u0F56\u0F7C\u0F51\u0F0B\u0F66\u0F90\u0F51\u0F0B`, br: `Brezhoneg`, ce: `\u041D\u043E\u0445\u0447\u0438\u0439\u043D`, ch: `Chamoru`, cr: `\u14C0\u1426\u1403\u152D\u140D\u140F\u1423`, cu: `\u0426\u0440\u044C\u043A\u044A\u0432\u044C\u043D\u043E\u0441\u043B\u043E\u0432\u0463\u043D\u044C\u0441\u043A\u044A`, cv: `\u0427\u04D1\u0432\u0430\u0448\u043B\u0430`, dv: `\u078B\u07A8\u0788\u07AC\u0780\u07A8\u0784\u07A6\u0790\u07B0`, dz: `\u0F62\u0FAB\u0F7C\u0F44\u0F0B\u0F41`, ee: `E\u028Begbe`, eo: `Esperanto`, ff: `Fulah`, fy: `Frysk`, gd: `G\xE0idhlig`, gn: `Ava\xF1e'\u1EBD`, gv: `Gaelg`, ho: `Hiri Motu`, hz: `Otjiherero`, ia: `Interlingua`, ie: `Interlingue`, ii: `\uA188\uA320\uA259`, ik: `I\xF1upiaq`, io: `Ido`, iu: `\u1403\u14C4\u1483\u144E\u1450\u1466`, jv: `Basa Jawa`, ki: `Gikuyu`, kr: `Kanuri`, ks: `\u06A9\u0672\u0634\u064F\u0631`, kw: `Kernewek`, lg: `Luganda`, li: `Limburgs`, lu: `Tshiluba`, mh: `Kajin M\u0327aje\u013C`, na: `Dorerin Naoero`, nb: `Norsk Bokm\xE5l`, nd: `isiNdebele`, ng: `Oshiwambo`, nn: `Norsk Nynorsk`, nr: `isiNdebele (South)`, nv: `Din\xE9 Bizaad`, oc: `Occitan`, oj: `Anishinaabemowin`, om: `Afaan Oromoo`, or: `\u0B13\u0B21\u0B3C\u0B3F\u0B06`, os: `\u0418\u0440\u043E\u043D`, pa: `\u0A2A\u0A70\u0A1C\u0A3E\u0A2C\u0A40`, pi: `\u{11005}\u{1102F}\u{11022}`, rm: `Rumantsch`, rn: `Ikirundi`, rw: `Kinyarwanda`, sa: `\u0938\u0902\u0938\u094D\u0915\u0943\u0924\u092E\u094D`, sc: `Sardu`, sg: `S\xE4ng\xF6`, ss: `SiSwati`, st: `Sesotho`, ti: `\u1275\u130D\u122D\u129B`, tn: `Setswana`, to: `Faka Tonga`, ts: `Xitsonga`, tt: `\u0422\u0430\u0442\u0430\u0440\u0447\u0430`, tw: `Twi`, ty: `Reo Tahiti`, ve: `Tshiven\u1E13a`, vo: `Volap\xFCk`, wa: `Walon`, wo: `Wolof`, za: `Sa\u026F cue\u014B\u0185` };
841
- var mn = (e5, t2) => {
839
+ })(un ||= {});
840
+ var dn = { cs: `\u010Ce\u0161tina`, da: `Dansk`, de: `Deutsch`, en: `English`, es: `Espa\xF1ol`, fr: `Fran\xE7ais`, hi: `\u0939\u093F\u0928\u094D\u0926\u0940`, id: `Bahasa Indonesia`, it: `Italiano`, ja: `\u65E5\u672C\u8A9E`, ko: `\uD55C\uAD6D\uC5B4`, nl: `Nederlands`, no: `Norsk`, pl: `Polski`, pt: `Portugu\xEAs`, ru: `\u0420\u0443\u0441\u0441\u043A\u0438\u0439`, sv: `Svenska`, th: `\u0E44\u0E17\u0E22`, tr: `T\xFCrk\xE7e`, uk: `\u0423\u043A\u0440\u0430\u0457\u043D\u0441\u044C\u043A\u0430`, vi: `Ti\u1EBFng Vi\u1EC7t`, zh: `\u7E41\u9AD4\u4E2D\u6587`, sq: `Shqip`, am: `\u12A0\u121B\u122D\u129B`, ar: `\u0627\u0644\u0639\u0631\u0628\u064A\u0629`, hy: `\u0540\u0561\u0575\u0565\u0580\u0565\u0576`, az: `Az\u0259rbaycan dili`, eu: `Euskara`, be: `\u0411\u0435\u043B\u0430\u0440\u0443\u0441\u043A\u0430\u044F`, bn: `\u09AC\u09BE\u0982\u09B2\u09BE`, bs: `Bosanski`, bg: `\u0411\u044A\u043B\u0433\u0430\u0440\u0441\u043A\u0438`, ca: `Catal\xE0`, ny: `ChiChe\u0175a`, co: `Corsu`, hr: `Hrvatski`, et: `Eesti`, fj: `Vosa Vakaviti`, fi: `Suomi`, ga: `Gaeilge`, gl: `Galego`, ka: `\u10E5\u10D0\u10E0\u10D7\u10E3\u10DA\u10D8`, el: `\u0395\u03BB\u03BB\u03B7\u03BD\u03B9\u03BA\u03AC`, gu: `\u0A97\u0AC1\u0A9C\u0AB0\u0ABE\u0AA4\u0AC0`, ht: `Krey\xF2l Ayisyen`, ha: `Hausa`, he: `\u05E2\u05D1\u05E8\u05D9\u05EA`, hu: `Magyar`, is: `\xCDslenska`, ig: `Igbo`, kn: `\u0C95\u0CA8\u0CCD\u0CA8\u0CA1`, kk: `\u049A\u0430\u0437\u0430\u049B \u0442\u0456\u043B\u0456`, km: `\u1797\u17B6\u179F\u17B6\u1781\u17D2\u1798\u17C2\u179A`, ku: `Kurd\xEE`, ky: `\u041A\u044B\u0440\u0433\u044B\u0437\u0447\u0430`, lb: `L\xEBtzebuergesch`, lo: `\u0EA5\u0EB2\u0EA7`, la: `Latina`, lv: `Latvie\u0161u`, lt: `Lietuvi\u0173`, mk: `\u041C\u0430\u043A\u0435\u0434\u043E\u043D\u0441\u043A\u0438`, mg: `Malagasy`, ms: `Bahasa Melayu`, ml: `\u0D2E\u0D32\u0D2F\u0D3E\u0D33\u0D02`, mt: `Malti`, mn: `\u041C\u043E\u043D\u0433\u043E\u043B`, ne: `\u0928\u0947\u092A\u093E\u0932\u0940`, ps: `\u067E\u069A\u062A\u0648`, fa: `\u0641\u0627\u0631\u0633\u06CC`, ro: `Rom\xE2n\u0103`, sm: `Gagana Samoa`, sr: `\u0421\u0440\u043F\u0441\u043A\u0438`, sn: `Shona`, sd: `\u0633\u0646\u068C\u064A`, si: `\u0DC3\u0DD2\u0D82\u0DC4\u0DBD`, sk: `Sloven\u010Dina`, sl: `Sloven\u0161\u010Dina`, so: `Soomaaliga`, su: `Basa Sunda`, sw: `Kiswahili`, tl: `Filipino`, tg: `\u0422\u043E\u04B7\u0438\u043A\u04E3`, ta: `\u0BA4\u0BAE\u0BBF\u0BB4\u0BCD`, te: `\u0C24\u0C46\u0C32\u0C41\u0C17\u0C41`, tk: `T\xFCrkmen`, ur: `\u0627\u0631\u062F\u0648`, uz: `O'zbek`, cy: `Cymraeg`, xh: `isiXhosa`, yi: `\u05D9\u05D9\u05B4\u05D3\u05D9\u05E9`, yo: `Yor\xF9b\xE1`, zu: `isiZulu`, kl: `Kalaallisut`, fo: `F\xF8royskt`, ln: `Ling\xE1la`, mi: `M\u0101ori`, mr: `\u092E\u0930\u093E\u0920\u0940`, my: `\u1019\u103C\u1014\u103A\u1019\u102C`, se: `S\xE1megiella`, ug: `\u0626\u06C7\u064A\u063A\u06C7\u0631\u0686\u06D5`, qu: `Runa Simi`, aa: `Afar`, ab: `\u0410\u04A7\u0441\u0443\u0430`, ae: `Avestan`, ak: `Akan`, an: `Aragon\xE9s`, as: `\u0985\u09B8\u09AE\u09C0\u09AF\u09BC\u09BE`, av: `\u0410\u0432\u0430\u0440`, ay: `Aymar aru`, ba: `\u0411\u0430\u0448\u04A1\u043E\u0440\u0442\u0441\u0430`, bh: `\u092D\u094B\u091C\u092A\u0941\u0930\u0940`, bi: `Bislama`, bm: `Bamanankan`, bo: `\u0F56\u0F7C\u0F51\u0F0B\u0F66\u0F90\u0F51\u0F0B`, br: `Brezhoneg`, ce: `\u041D\u043E\u0445\u0447\u0438\u0439\u043D`, ch: `Chamoru`, cr: `\u14C0\u1426\u1403\u152D\u140D\u140F\u1423`, cu: `\u0426\u0440\u044C\u043A\u044A\u0432\u044C\u043D\u043E\u0441\u043B\u043E\u0432\u0463\u043D\u044C\u0441\u043A\u044A`, cv: `\u0427\u04D1\u0432\u0430\u0448\u043B\u0430`, dv: `\u078B\u07A8\u0788\u07AC\u0780\u07A8\u0784\u07A6\u0790\u07B0`, dz: `\u0F62\u0FAB\u0F7C\u0F44\u0F0B\u0F41`, ee: `E\u028Begbe`, eo: `Esperanto`, ff: `Fulah`, fy: `Frysk`, gd: `G\xE0idhlig`, gn: `Ava\xF1e'\u1EBD`, gv: `Gaelg`, ho: `Hiri Motu`, hz: `Otjiherero`, ia: `Interlingua`, ie: `Interlingue`, ii: `\uA188\uA320\uA259`, ik: `I\xF1upiaq`, io: `Ido`, iu: `\u1403\u14C4\u1483\u144E\u1450\u1466`, jv: `Basa Jawa`, ki: `Gikuyu`, kr: `Kanuri`, ks: `\u06A9\u0672\u0634\u064F\u0631`, kw: `Kernewek`, lg: `Luganda`, li: `Limburgs`, lu: `Tshiluba`, mh: `Kajin M\u0327aje\u013C`, na: `Dorerin Naoero`, nb: `Norsk Bokm\xE5l`, nd: `isiNdebele`, ng: `Oshiwambo`, nn: `Norsk Nynorsk`, nr: `isiNdebele (South)`, nv: `Din\xE9 Bizaad`, oc: `Occitan`, oj: `Anishinaabemowin`, om: `Afaan Oromoo`, or: `\u0B13\u0B21\u0B3C\u0B3F\u0B06`, os: `\u0418\u0440\u043E\u043D`, pa: `\u0A2A\u0A70\u0A1C\u0A3E\u0A2C\u0A40`, pi: `\u{11005}\u{1102F}\u{11022}`, rm: `Rumantsch`, rn: `Ikirundi`, rw: `Kinyarwanda`, sa: `\u0938\u0902\u0938\u094D\u0915\u0943\u0924\u092E\u094D`, sc: `Sardu`, sg: `S\xE4ng\xF6`, ss: `SiSwati`, st: `Sesotho`, ti: `\u1275\u130D\u122D\u129B`, tn: `Setswana`, to: `Faka Tonga`, ts: `Xitsonga`, tt: `\u0422\u0430\u0442\u0430\u0440\u0447\u0430`, tw: `Twi`, ty: `Reo Tahiti`, ve: `Tshiven\u1E13a`, vo: `Volap\xFCk`, wa: `Walon`, wo: `Wolof`, za: `Sa\u026F cue\u014B\u0185` };
841
+ var fn = (e5, t2) => {
842
842
  e5.searchParams.set(`lang`, t2);
843
843
  };
844
- var hn = (e5, t2) => {
844
+ var pn = (e5, t2) => {
845
845
  let n2 = e5.hostname.split(`.`);
846
846
  n2[0] === `www` && (n2 = n2.slice(1)), n2 = [t2, ...n2], e5.hostname = n2.join(`.`);
847
847
  };
848
- var gn = (e5, t2) => {
848
+ var mn = (e5, t2) => {
849
849
  e5.pathname = `/${t2}${e5.pathname}`;
850
850
  };
851
- var _n = (e5, t2) => {
851
+ var hn = (e5, t2) => {
852
852
  if (!t2.languageCode || !t2?.resolutionMethod) return e5;
853
853
  let n2 = new URL(e5);
854
- return (t2?.resolutionMethod === `QUERY_PARAM` ? mn : t2?.resolutionMethod === `SUBDOMAIN` ? hn : gn)(n2, t2.languageCode), n2.href;
854
+ return (t2?.resolutionMethod === `QUERY_PARAM` ? fn : t2?.resolutionMethod === `SUBDOMAIN` ? pn : mn)(n2, t2.languageCode), n2.href;
855
855
  };
856
- var vn = (e5, t2) => {
856
+ var gn = (e5, t2) => {
857
857
  if (!e5?.length) return e5;
858
858
  let n2;
859
859
  try {
@@ -874,67 +874,72 @@ var vn = (e5, t2) => {
874
874
  }
875
875
  return n2.href;
876
876
  };
877
- function yn() {
878
- let e5 = bn();
879
- return e5 ? xn(e5) : [];
877
+ function _n() {
878
+ let e5 = vn();
879
+ return e5 ? yn(e5) : [];
880
880
  }
881
- function bn() {
881
+ function vn() {
882
882
  let e5 = typeof globals < `u` ? globals?.$ns?.[`wix-window`]?.multilingual : void 0, t2 = typeof window < `u` ? window?.essentials?.multilingual : void 0;
883
883
  return e5 ?? t2 ?? globalThis?.__wix_site_metadata__?.multilingual;
884
884
  }
885
- function xn(e5) {
885
+ function yn(e5) {
886
886
  try {
887
887
  if (e5?.supportedLanguages?.length) {
888
- let t2 = e5.supportedLanguages, n2 = t2.map((e6) => e6.languageCode).filter(Boolean), r2 = e5.cleanUrl ?? Tn(n2);
889
- return t2.map((e6) => ({ id: e6.languageCode, displayName: Sn(e6), regionalFormat: [e6.locale?.languageCode, e6.locale?.country].filter(Boolean).join(`-`), url: Cn(e6, r2), primary: e6.isPrimary, resolutionMethod: e6.resolutionMethod }));
888
+ let t2 = e5.supportedLanguages, n2 = t2.map((e6) => e6.languageCode).filter(Boolean), r2 = e5.cleanUrl ?? Cn(n2);
889
+ return t2.map((e6) => ({ id: e6.languageCode, displayName: bn(e6), regionalFormat: [e6.locale?.languageCode, e6.locale?.country].filter(Boolean).join(`-`), url: xn(e6, r2), primary: e6.isPrimary, resolutionMethod: e6.resolutionMethod }));
890
890
  }
891
891
  if (e5?.siteLanguages?.length) {
892
- let t2 = e5.siteLanguages, n2 = Tn(t2.map((e6) => e6.languageCode).filter(Boolean));
893
- return t2.map((e6) => ({ id: e6.languageCode, displayName: Sn(e6), regionalFormat: e6.locale, url: Cn(e6, n2), primary: e6.isPrimaryLanguage, resolutionMethod: e6.resolutionMethod ? wn(e6.resolutionMethod) : void 0 }));
892
+ let t2 = e5.siteLanguages, n2 = Cn(t2.map((e6) => e6.languageCode).filter(Boolean));
893
+ return t2.map((e6) => ({ id: e6.languageCode, displayName: bn(e6), regionalFormat: e6.locale, url: xn(e6, n2), primary: e6.isPrimaryLanguage, resolutionMethod: e6.resolutionMethod ? Sn(e6.resolutionMethod) : void 0 }));
894
894
  }
895
895
  } catch (e6) {
896
896
  return console.warn(`[Multilingual Manager] listSupportedLanguages failed`, e6), [];
897
897
  }
898
898
  return console.warn(`[Multilingual Manager] listSupportedLanguages is not available`), [];
899
899
  }
900
- function Sn(e5) {
901
- let t2 = pn[e5.languageCode];
900
+ function bn(e5) {
901
+ let t2 = dn[e5.languageCode];
902
902
  if (t2) return t2;
903
903
  let n2 = e5.name ?? e5.countryCode;
904
904
  if (n2) return n2;
905
905
  }
906
- function Cn(e5, t2) {
906
+ function xn(e5, t2) {
907
907
  if (e5.url || !t2 || !e5.resolutionMethod) return e5.url;
908
908
  if (e5.languageCode) try {
909
- return _n(t2, { languageCode: e5.languageCode, countryCode: e5.countryCode, resolutionMethod: wn(e5.resolutionMethod), locale: { languageCode: e5.languageCode, country: e5.countryCode } });
909
+ return hn(t2, { languageCode: e5.languageCode, countryCode: e5.countryCode, resolutionMethod: Sn(e5.resolutionMethod), locale: { languageCode: e5.languageCode, country: e5.countryCode } });
910
910
  } catch (e6) {
911
911
  console.warn(`[Multilingual Manager] buildUrlForLanguage failed`, e6);
912
912
  return;
913
913
  }
914
914
  }
915
- function wn(e5) {
915
+ function Sn(e5) {
916
916
  switch (e5) {
917
917
  case `QUERY_PARAM`:
918
918
  case `QueryParam`:
919
- return fn.QUERY_PARAM;
919
+ return un.QUERY_PARAM;
920
920
  case `SUBDOMAIN`:
921
921
  case `Subdomain`:
922
- return fn.SUBDOMAIN;
922
+ return un.SUBDOMAIN;
923
923
  case `SUBDIRECTORY`:
924
924
  case `Subdirectory`:
925
- return fn.SUBDIRECTORY;
925
+ return un.SUBDIRECTORY;
926
926
  default:
927
927
  return;
928
928
  }
929
929
  }
930
- function Tn(e5) {
930
+ function Cn(e5) {
931
931
  let t2 = typeof window < `u` && window.location?.href ? window.location.href : ``;
932
932
  try {
933
- return vn(t2, e5);
933
+ return gn(t2, e5);
934
934
  } catch (e6) {
935
935
  return console.warn(`[Multilingual Manager] cleanCurrentUrl failed`, e6), t2;
936
936
  }
937
937
  }
938
+ var wn = `x-wix-currency`;
939
+ var Tn = () => {
940
+ let e5 = Mn(`currency`);
941
+ if (e5) return { [wn]: e5 };
942
+ };
938
943
  var En = `x-wix-linguist`;
939
944
  var Dn = `00000000-0000-0000-0000-000000000000`;
940
945
  var On = `false`;
@@ -953,7 +958,8 @@ var Mn = (e5) => jn()?.[e5];
953
958
  var Nn = ({ createHost: e5 }) => ({ __type: `host`, create: (e6) => ({}), host: (t2) => {
954
959
  let { applicationId: n2, componentId: r2 } = t2 ?? {}, i2 = typeof window < `u` ? window.wixEmbedsAPI : void 0, a2 = e5(t2), o2 = Fn();
955
960
  return { ...a2, apiBaseUrl: o2, getMonitoringClient: i2?.getMonitoringClientFunction?.(n2, r2), essentials: { language: Mn(`language`), locale: Mn(`locale`), get passThroughHeaders() {
956
- return kn();
961
+ let e6 = { ...kn(), ...Tn() };
962
+ return Object.keys(e6).length > 0 ? e6 : void 0;
957
963
  } } };
958
964
  }, auth: (e6) => {
959
965
  let t2 = typeof window < `u` ? window.wixEmbedsAPI : void 0;
@@ -990,7 +996,7 @@ var Ln = Nn({ createHost: function(e5) {
990
996
  } });
991
997
  var Rn = (e5, t2) => {
992
998
  let n2 = Ln.host({ applicationId: e5, componentId: t2 }), r2 = Ln.auth();
993
- return He({ auth: r2, host: n2 }).enableContext(`module`), r2.getAccessTokenInjector();
999
+ return Be({ auth: r2, host: n2 }).enableContext(`module`), r2.getAccessTokenInjector();
994
1000
  };
995
1001
  var zn = (e5) => Rn(`13d21c63-b5ec-5912-8397-c3a5ddb27a97`, e5);
996
1002
  function Bn() {
@@ -1040,7 +1046,7 @@ function Hn(e5, t2) {
1040
1046
  function Un(e5) {
1041
1047
  return Hn({ __type: `host`, create: (t2) => Object.entries(e5).reduce((e6, [n2, r2]) => ({ ...e6, [n2]: r2(t2) }), {}) }, Object.keys(e5));
1042
1048
  }
1043
- var F = (e5) => typeof e5 == `string`;
1049
+ var L = (e5) => typeof e5 == `string`;
1044
1050
  var Wn = () => {
1045
1051
  let e5, t2, n2 = new Promise((n3, r2) => {
1046
1052
  e5 = n3, t2 = r2;
@@ -1055,9 +1061,9 @@ var Kn = (e5, t2, n2) => {
1055
1061
  };
1056
1062
  var qn = /###/g;
1057
1063
  var Jn = (e5) => e5 && e5.indexOf(`###`) > -1 ? e5.replace(qn, `.`) : e5;
1058
- var Yn = (e5) => !e5 || F(e5);
1064
+ var Yn = (e5) => !e5 || L(e5);
1059
1065
  var Xn = (e5, t2, n2) => {
1060
- let r2 = F(t2) ? t2.split(`.`) : t2, i2 = 0;
1066
+ let r2 = L(t2) ? t2.split(`.`) : t2, i2 = 0;
1061
1067
  for (; i2 < r2.length - 1; ) {
1062
1068
  if (Yn(e5)) return {};
1063
1069
  let t3 = Jn(r2[i2]);
@@ -1088,12 +1094,12 @@ var er = (e5, t2, n2) => {
1088
1094
  return r2 === void 0 ? $n(t2, n2) : r2;
1089
1095
  };
1090
1096
  var tr = (e5, t2, n2) => {
1091
- for (let r2 in t2) r2 !== `__proto__` && r2 !== `constructor` && (r2 in e5 ? F(e5[r2]) || e5[r2] instanceof String || F(t2[r2]) || t2[r2] instanceof String ? n2 && (e5[r2] = t2[r2]) : tr(e5[r2], t2[r2], n2) : e5[r2] = t2[r2]);
1097
+ for (let r2 in t2) r2 !== `__proto__` && r2 !== `constructor` && (r2 in e5 ? L(e5[r2]) || e5[r2] instanceof String || L(t2[r2]) || t2[r2] instanceof String ? n2 && (e5[r2] = t2[r2]) : tr(e5[r2], t2[r2], n2) : e5[r2] = t2[r2]);
1092
1098
  return e5;
1093
1099
  };
1094
- var I = (e5) => e5.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, `\\$&`);
1100
+ var R = (e5) => e5.replace(/[\-\[\]\/\{\}\(\)\*\+\?\.\\\^\$\|]/g, `\\$&`);
1095
1101
  var nr = { "&": `&amp;`, "<": `&lt;`, ">": `&gt;`, '"': `&quot;`, "'": `&#39;`, "/": `&#x2F;` };
1096
- var rr = (e5) => F(e5) ? e5.replace(/[&<>"'\/]/g, (e6) => nr[e6]) : e5;
1102
+ var rr = (e5) => L(e5) ? e5.replace(/[&<>"'\/]/g, (e6) => nr[e6]) : e5;
1097
1103
  var ir = class {
1098
1104
  constructor(e5) {
1099
1105
  this.capacity = e5, this.regExpMap = /* @__PURE__ */ new Map(), this.regExpQueue = [];
@@ -1144,7 +1150,7 @@ var ur = { type: `logger`, log(e5) {
1144
1150
  }, output(e5, t2) {
1145
1151
  console?.[e5]?.apply?.(console, t2);
1146
1152
  } };
1147
- var L = new class e2 {
1153
+ var z = new class e2 {
1148
1154
  constructor(e5, t2 = {}) {
1149
1155
  this.init(e5, t2);
1150
1156
  }
@@ -1164,7 +1170,7 @@ var L = new class e2 {
1164
1170
  return this.forward(e5, `warn`, `WARNING DEPRECATED: `, true);
1165
1171
  }
1166
1172
  forward(e5, t2, n2, r2) {
1167
- return r2 && !this.debug ? null : (F(e5[0]) && (e5[0] = `${n2}${this.prefix} ${e5[0]}`), this.logger[t2](e5));
1173
+ return r2 && !this.debug ? null : (L(e5[0]) && (e5[0] = `${n2}${this.prefix} ${e5[0]}`), this.logger[t2](e5));
1168
1174
  }
1169
1175
  create(t2) {
1170
1176
  return new e2(this.logger, { prefix: `${this.prefix}:${t2}:`, ...this.options });
@@ -1214,16 +1220,16 @@ var fr = class extends dr {
1214
1220
  }
1215
1221
  getResource(e5, t2, n2, r2 = {}) {
1216
1222
  let i2 = r2.keySeparator === void 0 ? this.options.keySeparator : r2.keySeparator, a2 = r2.ignoreJSONStructure === void 0 ? this.options.ignoreJSONStructure : r2.ignoreJSONStructure, o2;
1217
- e5.indexOf(`.`) > -1 ? o2 = e5.split(`.`) : (o2 = [e5, t2], n2 && (Array.isArray(n2) ? o2.push(...n2) : F(n2) && i2 ? o2.push(...n2.split(i2)) : o2.push(n2)));
1223
+ e5.indexOf(`.`) > -1 ? o2 = e5.split(`.`) : (o2 = [e5, t2], n2 && (Array.isArray(n2) ? o2.push(...n2) : L(n2) && i2 ? o2.push(...n2.split(i2)) : o2.push(n2)));
1218
1224
  let s2 = $n(this.data, o2);
1219
- return !s2 && !t2 && !n2 && e5.indexOf(`.`) > -1 && (e5 = o2[0], t2 = o2[1], n2 = o2.slice(2).join(`.`)), s2 || !a2 || !F(n2) ? s2 : cr(this.data?.[e5]?.[t2], n2, i2);
1225
+ return !s2 && !t2 && !n2 && e5.indexOf(`.`) > -1 && (e5 = o2[0], t2 = o2[1], n2 = o2.slice(2).join(`.`)), s2 || !a2 || !L(n2) ? s2 : cr(this.data?.[e5]?.[t2], n2, i2);
1220
1226
  }
1221
1227
  addResource(e5, t2, n2, r2, i2 = { silent: false }) {
1222
1228
  let a2 = i2.keySeparator === void 0 ? this.options.keySeparator : i2.keySeparator, o2 = [e5, t2];
1223
1229
  n2 && (o2 = o2.concat(a2 ? n2.split(a2) : n2)), e5.indexOf(`.`) > -1 && (o2 = e5.split(`.`), r2 = t2, t2 = o2[1]), this.addNamespaces(t2), Zn(this.data, o2, r2), i2.silent || this.emit(`added`, e5, t2, n2, r2);
1224
1230
  }
1225
1231
  addResources(e5, t2, n2, r2 = { silent: false }) {
1226
- for (let r3 in n2) (F(n2[r3]) || Array.isArray(n2[r3])) && this.addResource(e5, t2, r3, n2[r3], { silent: true });
1232
+ for (let r3 in n2) (L(n2[r3]) || Array.isArray(n2[r3])) && this.addResource(e5, t2, r3, n2[r3], { silent: true });
1227
1233
  r2.silent || this.emit(`added`, e5, t2, n2);
1228
1234
  }
1229
1235
  addResourceBundle(e5, t2, n2, r2, i2, a2 = { silent: false, skipCopy: false }) {
@@ -1264,7 +1270,7 @@ function hr() {
1264
1270
  let e5 = [], t2 = /* @__PURE__ */ Object.create(null), n2;
1265
1271
  return t2.get = (r2, i2) => (n2?.revoke?.(), i2 === mr ? e5 : (e5.push(i2), n2 = Proxy.revocable(r2, t2), n2.proxy)), Proxy.revocable(/* @__PURE__ */ Object.create(null), t2).proxy;
1266
1272
  }
1267
- function R(e5, t2) {
1273
+ function B(e5, t2) {
1268
1274
  let { [mr]: n2 } = e5(hr()), r2 = t2?.keySeparator ?? `.`, i2 = t2?.nsSeparator ?? `:`;
1269
1275
  if (n2.length > 1 && i2) {
1270
1276
  let e6 = t2?.ns, a2 = Array.isArray(e6) ? e6 : null;
@@ -1273,10 +1279,10 @@ function R(e5, t2) {
1273
1279
  return n2.join(r2);
1274
1280
  }
1275
1281
  var gr = {};
1276
- var _r = (e5) => !F(e5) && typeof e5 != `boolean` && typeof e5 != `number`;
1282
+ var _r = (e5) => !L(e5) && typeof e5 != `boolean` && typeof e5 != `number`;
1277
1283
  var vr = class e3 extends dr {
1278
1284
  constructor(e5, t2 = {}) {
1279
- super(), Kn([`resourceStore`, `languageUtils`, `pluralResolver`, `interpolator`, `backendConnector`, `i18nFormat`, `utils`], e5, this), this.options = t2, this.options.keySeparator === void 0 && (this.options.keySeparator = `.`), this.logger = L.create(`translator`);
1285
+ super(), Kn([`resourceStore`, `languageUtils`, `pluralResolver`, `interpolator`, `backendConnector`, `i18nFormat`, `utils`], e5, this), this.options = t2, this.options.keySeparator === void 0 && (this.options.keySeparator = `.`), this.logger = z.create(`translator`);
1280
1286
  }
1281
1287
  changeLanguage(e5) {
1282
1288
  e5 && (this.language = e5);
@@ -1295,44 +1301,44 @@ var vr = class e3 extends dr {
1295
1301
  let r2 = t2.keySeparator === void 0 ? this.options.keySeparator : t2.keySeparator, i2 = t2.ns || this.options.defaultNS || [], a2 = n2 && e5.indexOf(n2) > -1, o2 = !this.options.userDefinedKeySeparator && !t2.keySeparator && !this.options.userDefinedNsSeparator && !t2.nsSeparator && !sr(e5, n2, r2);
1296
1302
  if (a2 && !o2) {
1297
1303
  let t3 = e5.match(this.interpolator.nestingRegexp);
1298
- if (t3 && t3.length > 0) return { key: e5, namespaces: F(i2) ? [i2] : i2 };
1304
+ if (t3 && t3.length > 0) return { key: e5, namespaces: L(i2) ? [i2] : i2 };
1299
1305
  let a3 = e5.split(n2);
1300
1306
  (n2 !== r2 || n2 === r2 && this.options.ns.indexOf(a3[0]) > -1) && (i2 = a3.shift()), e5 = a3.join(r2);
1301
1307
  }
1302
- return { key: e5, namespaces: F(i2) ? [i2] : i2 };
1308
+ return { key: e5, namespaces: L(i2) ? [i2] : i2 };
1303
1309
  }
1304
1310
  translate(t2, n2, r2) {
1305
1311
  let i2 = typeof n2 == `object` ? { ...n2 } : n2;
1306
1312
  if (typeof i2 != `object` && this.options.overloadTranslationOptionHandler && (i2 = this.options.overloadTranslationOptionHandler(arguments)), typeof i2 == `object` && (i2 = { ...i2 }), i2 ||= {}, t2 == null) return ``;
1307
- typeof t2 == `function` && (t2 = R(t2, { ...this.options, ...i2 })), Array.isArray(t2) || (t2 = [String(t2)]), t2 = t2.map((e5) => typeof e5 == `function` ? R(e5, { ...this.options, ...i2 }) : String(e5));
1313
+ typeof t2 == `function` && (t2 = B(t2, { ...this.options, ...i2 })), Array.isArray(t2) || (t2 = [String(t2)]), t2 = t2.map((e5) => typeof e5 == `function` ? B(e5, { ...this.options, ...i2 }) : String(e5));
1308
1314
  let a2 = i2.returnDetails === void 0 ? this.options.returnDetails : i2.returnDetails, o2 = i2.keySeparator === void 0 ? this.options.keySeparator : i2.keySeparator, { key: s2, namespaces: c2 } = this.extractFromKey(t2[t2.length - 1], i2), l2 = c2[c2.length - 1], u2 = i2.nsSeparator === void 0 ? this.options.nsSeparator : i2.nsSeparator;
1309
1315
  u2 === void 0 && (u2 = `:`);
1310
1316
  let d2 = i2.lng || this.language, f2 = i2.appendNamespaceToCIMode || this.options.appendNamespaceToCIMode;
1311
1317
  if (d2?.toLowerCase() === `cimode`) return f2 ? a2 ? { res: `${l2}${u2}${s2}`, usedKey: s2, exactUsedKey: s2, usedLng: d2, usedNS: l2, usedParams: this.getUsedParamsDetails(i2) } : `${l2}${u2}${s2}` : a2 ? { res: s2, usedKey: s2, exactUsedKey: s2, usedLng: d2, usedNS: l2, usedParams: this.getUsedParamsDetails(i2) } : s2;
1312
- let p2 = this.resolve(t2, i2), m2 = p2?.res, h2 = p2?.usedKey || s2, g2 = p2?.exactUsedKey || s2, _2 = [`[object Number]`, `[object Function]`, `[object RegExp]`], v2 = i2.joinArrays === void 0 ? this.options.joinArrays : i2.joinArrays, y2 = !this.i18nFormat || this.i18nFormat.handleAsObject, b2 = i2.count !== void 0 && !F(i2.count), x2 = e3.hasDefaultValue(i2), S2 = b2 ? this.pluralResolver.getSuffix(d2, i2.count, i2) : ``, ee2 = i2.ordinal && b2 ? this.pluralResolver.getSuffix(d2, i2.count, { ordinal: false }) : ``, C2 = b2 && !i2.ordinal && i2.count === 0, w2 = C2 && i2[`defaultValue${this.options.pluralSeparator}zero`] || i2[`defaultValue${S2}`] || i2[`defaultValue${ee2}`] || i2.defaultValue, T2 = m2;
1313
- y2 && !m2 && x2 && (T2 = w2);
1314
- let E2 = _r(T2), D2 = Object.prototype.toString.apply(T2);
1315
- if (y2 && T2 && E2 && _2.indexOf(D2) < 0 && !(F(v2) && Array.isArray(T2))) {
1318
+ let p2 = this.resolve(t2, i2), m2 = p2?.res, h2 = p2?.usedKey || s2, g2 = p2?.exactUsedKey || s2, _2 = [`[object Number]`, `[object Function]`, `[object RegExp]`], v2 = i2.joinArrays === void 0 ? this.options.joinArrays : i2.joinArrays, y2 = !this.i18nFormat || this.i18nFormat.handleAsObject, b2 = i2.count !== void 0 && !L(i2.count), x2 = e3.hasDefaultValue(i2), S2 = b2 ? this.pluralResolver.getSuffix(d2, i2.count, i2) : ``, C2 = i2.ordinal && b2 ? this.pluralResolver.getSuffix(d2, i2.count, { ordinal: false }) : ``, w2 = b2 && !i2.ordinal && i2.count === 0, T2 = w2 && i2[`defaultValue${this.options.pluralSeparator}zero`] || i2[`defaultValue${S2}`] || i2[`defaultValue${C2}`] || i2.defaultValue, E2 = m2;
1319
+ y2 && !m2 && x2 && (E2 = T2);
1320
+ let D2 = _r(E2), O2 = Object.prototype.toString.apply(E2);
1321
+ if (y2 && E2 && D2 && _2.indexOf(O2) < 0 && !(L(v2) && Array.isArray(E2))) {
1316
1322
  if (!i2.returnObjects && !this.options.returnObjects) {
1317
1323
  this.options.returnedObjectHandler || this.logger.warn(`accessing an object - but returnObjects options is not enabled!`);
1318
- let e5 = this.options.returnedObjectHandler ? this.options.returnedObjectHandler(h2, T2, { ...i2, ns: c2 }) : `key '${s2} (${this.language})' returned an object instead of string.`;
1324
+ let e5 = this.options.returnedObjectHandler ? this.options.returnedObjectHandler(h2, E2, { ...i2, ns: c2 }) : `key '${s2} (${this.language})' returned an object instead of string.`;
1319
1325
  return a2 ? (p2.res = e5, p2.usedParams = this.getUsedParamsDetails(i2), p2) : e5;
1320
1326
  }
1321
1327
  if (o2) {
1322
- let e5 = Array.isArray(T2), t3 = e5 ? [] : {}, n3 = e5 ? g2 : h2;
1323
- for (let e6 in T2) if (Object.prototype.hasOwnProperty.call(T2, e6)) {
1328
+ let e5 = Array.isArray(E2), t3 = e5 ? [] : {}, n3 = e5 ? g2 : h2;
1329
+ for (let e6 in E2) if (Object.prototype.hasOwnProperty.call(E2, e6)) {
1324
1330
  let r3 = `${n3}${o2}${e6}`;
1325
- t3[e6] = x2 && !m2 ? this.translate(r3, { ...i2, defaultValue: _r(w2) ? w2[e6] : void 0, joinArrays: false, ns: c2 }) : this.translate(r3, { ...i2, joinArrays: false, ns: c2 }), t3[e6] === r3 && (t3[e6] = T2[e6]);
1331
+ t3[e6] = x2 && !m2 ? this.translate(r3, { ...i2, defaultValue: _r(T2) ? T2[e6] : void 0, joinArrays: false, ns: c2 }) : this.translate(r3, { ...i2, joinArrays: false, ns: c2 }), t3[e6] === r3 && (t3[e6] = E2[e6]);
1326
1332
  }
1327
1333
  m2 = t3;
1328
1334
  }
1329
- } else if (y2 && F(v2) && Array.isArray(m2)) m2 = m2.join(v2), m2 &&= this.extendTranslation(m2, t2, i2, r2);
1335
+ } else if (y2 && L(v2) && Array.isArray(m2)) m2 = m2.join(v2), m2 &&= this.extendTranslation(m2, t2, i2, r2);
1330
1336
  else {
1331
1337
  let e5 = false, n3 = false;
1332
- !this.isValidLookup(m2) && x2 && (e5 = true, m2 = w2), this.isValidLookup(m2) || (n3 = true, m2 = s2);
1333
- let a3 = (i2.missingKeyNoValueFallbackToKey || this.options.missingKeyNoValueFallbackToKey) && n3 ? void 0 : m2, c3 = x2 && w2 !== m2 && this.options.updateMissing;
1338
+ !this.isValidLookup(m2) && x2 && (e5 = true, m2 = T2), this.isValidLookup(m2) || (n3 = true, m2 = s2);
1339
+ let a3 = (i2.missingKeyNoValueFallbackToKey || this.options.missingKeyNoValueFallbackToKey) && n3 ? void 0 : m2, c3 = x2 && T2 !== m2 && this.options.updateMissing;
1334
1340
  if (n3 || e5 || c3) {
1335
- if (this.logger.log(c3 ? `updateKey` : `missingKey`, d2, l2, s2, c3 ? w2 : m2), o2) {
1341
+ if (this.logger.log(c3 ? `updateKey` : `missingKey`, d2, l2, s2, c3 ? T2 : m2), o2) {
1336
1342
  let e7 = this.resolve(s2, { ...i2, keySeparator: false });
1337
1343
  e7 && e7.res && this.logger.warn(`Seems the loaded translations were in flat JSON format instead of nested. Either set keySeparator: false on init or make sure your translations are published in nested format.`);
1338
1344
  }
@@ -1345,10 +1351,10 @@ var vr = class e3 extends dr {
1345
1351
  };
1346
1352
  this.options.saveMissing && (this.options.saveMissingPlurals && b2 ? e6.forEach((e7) => {
1347
1353
  let t4 = this.pluralResolver.getSuffixes(e7, i2);
1348
- C2 && i2[`defaultValue${this.options.pluralSeparator}zero`] && t4.indexOf(`${this.options.pluralSeparator}zero`) < 0 && t4.push(`${this.options.pluralSeparator}zero`), t4.forEach((t5) => {
1349
- n4([e7], s2 + t5, i2[`defaultValue${t5}`] || w2);
1354
+ w2 && i2[`defaultValue${this.options.pluralSeparator}zero`] && t4.indexOf(`${this.options.pluralSeparator}zero`) < 0 && t4.push(`${this.options.pluralSeparator}zero`), t4.forEach((t5) => {
1355
+ n4([e7], s2 + t5, i2[`defaultValue${t5}`] || T2);
1350
1356
  });
1351
- }) : n4(e6, s2, w2));
1357
+ }) : n4(e6, s2, T2));
1352
1358
  }
1353
1359
  m2 = this.extendTranslation(m2, t2, i2, p2, r2), n3 && m2 === s2 && this.options.appendNamespaceToMissingKey && (m2 = `${l2}${u2}${s2}`), (n3 || e5) && this.options.parseMissingKeyHandler && (m2 = this.options.parseMissingKeyHandler(this.options.appendNamespaceToMissingKey ? `${l2}${u2}${s2}` : s2, e5 ? m2 : void 0, i2));
1354
1360
  }
@@ -1358,30 +1364,30 @@ var vr = class e3 extends dr {
1358
1364
  if (this.i18nFormat?.parse) e5 = this.i18nFormat.parse(e5, { ...this.options.interpolation.defaultVariables, ...n2 }, n2.lng || this.language || r2.usedLng, r2.usedNS, r2.usedKey, { resolved: r2 });
1359
1365
  else if (!n2.skipInterpolation) {
1360
1366
  n2.interpolation && this.interpolator.init({ ...n2, interpolation: { ...this.options.interpolation, ...n2.interpolation } });
1361
- let a3 = F(e5) && (n2?.interpolation?.skipOnVariables === void 0 ? this.options.interpolation.skipOnVariables : n2.interpolation.skipOnVariables), o3;
1367
+ let a3 = L(e5) && (n2?.interpolation?.skipOnVariables === void 0 ? this.options.interpolation.skipOnVariables : n2.interpolation.skipOnVariables), o3;
1362
1368
  if (a3) {
1363
1369
  let t3 = e5.match(this.interpolator.nestingRegexp);
1364
1370
  o3 = t3 && t3.length;
1365
1371
  }
1366
- let s2 = n2.replace && !F(n2.replace) ? n2.replace : n2;
1372
+ let s2 = n2.replace && !L(n2.replace) ? n2.replace : n2;
1367
1373
  if (this.options.interpolation.defaultVariables && (s2 = { ...this.options.interpolation.defaultVariables, ...s2 }), e5 = this.interpolator.interpolate(e5, s2, n2.lng || this.language || r2.usedLng, n2), a3) {
1368
1374
  let t3 = e5.match(this.interpolator.nestingRegexp), r3 = t3 && t3.length;
1369
1375
  o3 < r3 && (n2.nest = false);
1370
1376
  }
1371
1377
  !n2.lng && r2 && r2.res && (n2.lng = this.language || r2.usedLng), n2.nest !== false && (e5 = this.interpolator.nest(e5, (...e6) => i2?.[0] === e6[0] && !n2.context ? (this.logger.warn(`It seems you are nesting recursively key: ${e6[0]} in key: ${t2[0]}`), null) : this.translate(...e6, t2), n2)), n2.interpolation && this.interpolator.reset();
1372
1378
  }
1373
- let a2 = n2.postProcess || this.options.postProcess, o2 = F(a2) ? [a2] : a2;
1379
+ let a2 = n2.postProcess || this.options.postProcess, o2 = L(a2) ? [a2] : a2;
1374
1380
  return e5 != null && o2?.length && n2.applyPostProcessor !== false && (e5 = pr.handle(o2, e5, t2, this.options && this.options.postProcessPassResolved ? { i18nResolved: { ...r2, usedParams: this.getUsedParamsDetails(n2) }, ...n2 } : n2, this)), e5;
1375
1381
  }
1376
1382
  resolve(e5, t2 = {}) {
1377
1383
  let n2, r2, i2, a2, o2;
1378
- return F(e5) && (e5 = [e5]), Array.isArray(e5) && (e5 = e5.map((e6) => typeof e6 == `function` ? R(e6, { ...this.options, ...t2 }) : e6)), e5.forEach((e6) => {
1384
+ return L(e5) && (e5 = [e5]), Array.isArray(e5) && (e5 = e5.map((e6) => typeof e6 == `function` ? B(e6, { ...this.options, ...t2 }) : e6)), e5.forEach((e6) => {
1379
1385
  if (this.isValidLookup(n2)) return;
1380
1386
  let s2 = this.extractFromKey(e6, t2), c2 = s2.key;
1381
1387
  r2 = c2;
1382
1388
  let l2 = s2.namespaces;
1383
1389
  this.options.fallbackNS && (l2 = l2.concat(this.options.fallbackNS));
1384
- let u2 = t2.count !== void 0 && !F(t2.count), d2 = u2 && !t2.ordinal && t2.count === 0, f2 = t2.context !== void 0 && (F(t2.context) || typeof t2.context == `number`) && t2.context !== ``, p2 = t2.lngs ? t2.lngs : this.languageUtils.toResolveHierarchy(t2.lng || this.language, t2.fallbackLng);
1390
+ let u2 = t2.count !== void 0 && !L(t2.count), d2 = u2 && !t2.ordinal && t2.count === 0, f2 = t2.context !== void 0 && (L(t2.context) || typeof t2.context == `number`) && t2.context !== ``, p2 = t2.lngs ? t2.lngs : this.languageUtils.toResolveHierarchy(t2.lng || this.language, t2.fallbackLng);
1385
1391
  l2.forEach((e7) => {
1386
1392
  this.isValidLookup(n2) || (o2 = e7, !gr[`${p2[0]}-${e7}`] && this.utils?.hasLoadedNamespace && !this.utils?.hasLoadedNamespace(o2) && (gr[`${p2[0]}-${e7}`] = true, this.logger.warn(`key "${r2}" for languages "${p2.join(`, `)}" won't get resolved as namespace "${o2}" was not yet loaded`, `This means something IS WRONG in your setup. You access the t function before i18next.init / i18next.loadNamespace / i18next.changeLanguage was done. Wait for the callback or Promise to resolve before accessing it!!!`)), p2.forEach((r3) => {
1387
1393
  if (this.isValidLookup(n2)) return;
@@ -1410,7 +1416,7 @@ var vr = class e3 extends dr {
1410
1416
  return this.i18nFormat?.getResource ? this.i18nFormat.getResource(e5, t2, n2, r2) : this.resourceStore.getResource(e5, t2, n2, r2);
1411
1417
  }
1412
1418
  getUsedParamsDetails(e5 = {}) {
1413
- let t2 = [`defaultValue`, `ordinal`, `context`, `replace`, `lng`, `lngs`, `fallbackLng`, `ns`, `keySeparator`, `nsSeparator`, `returnObjects`, `returnDetails`, `joinArrays`, `postProcess`, `interpolation`], n2 = e5.replace && !F(e5.replace), r2 = n2 ? e5.replace : e5;
1419
+ let t2 = [`defaultValue`, `ordinal`, `context`, `replace`, `lng`, `lngs`, `fallbackLng`, `ns`, `keySeparator`, `nsSeparator`, `returnObjects`, `returnDetails`, `joinArrays`, `postProcess`, `interpolation`], n2 = e5.replace && !L(e5.replace), r2 = n2 ? e5.replace : e5;
1414
1420
  if (n2 && e5.count !== void 0 && (r2.count = e5.count), this.options.interpolation.defaultVariables && (r2 = { ...this.options.interpolation.defaultVariables, ...r2 }), !n2) {
1415
1421
  r2 = { ...r2 };
1416
1422
  for (let e6 of t2) delete r2[e6];
@@ -1424,7 +1430,7 @@ var vr = class e3 extends dr {
1424
1430
  };
1425
1431
  var yr = class {
1426
1432
  constructor(e5) {
1427
- this.options = e5, this.supportedLngs = this.options.supportedLngs || false, this.logger = L.create(`languageUtils`);
1433
+ this.options = e5, this.supportedLngs = this.options.supportedLngs || false, this.logger = z.create(`languageUtils`);
1428
1434
  }
1429
1435
  getScriptPartFromCode(e5) {
1430
1436
  if (e5 = lr(e5), !e5 || e5.indexOf(`-`) < 0) return null;
@@ -1437,7 +1443,7 @@ var yr = class {
1437
1443
  return this.formatLanguageCode(t2[0]);
1438
1444
  }
1439
1445
  formatLanguageCode(e5) {
1440
- if (F(e5) && e5.indexOf(`-`) > -1) {
1446
+ if (L(e5) && e5.indexOf(`-`) > -1) {
1441
1447
  let t2;
1442
1448
  try {
1443
1449
  t2 = Intl.getCanonicalLocales(e5)[0];
@@ -1470,7 +1476,7 @@ var yr = class {
1470
1476
  }
1471
1477
  getFallbackCodes(e5, t2) {
1472
1478
  if (!e5) return [];
1473
- if (typeof e5 == `function` && (e5 = e5(t2)), F(e5) && (e5 = [e5]), Array.isArray(e5)) return e5;
1479
+ if (typeof e5 == `function` && (e5 = e5(t2)), L(e5) && (e5 = [e5]), Array.isArray(e5)) return e5;
1474
1480
  if (!t2) return e5.default || [];
1475
1481
  let n2 = e5[t2];
1476
1482
  return n2 ||= e5[this.getScriptPartFromCode(t2)], n2 ||= e5[this.formatLanguageCode(t2)], n2 ||= e5[this.getLanguagePartFromCode(t2)], n2 ||= e5.default, n2 || [];
@@ -1479,7 +1485,7 @@ var yr = class {
1479
1485
  let n2 = this.getFallbackCodes((t2 === false ? [] : t2) || this.options.fallbackLng || [], e5), r2 = [], i2 = (e6) => {
1480
1486
  e6 && (this.isSupportedCode(e6) ? r2.push(e6) : this.logger.warn(`rejecting language code not found in supportedLngs: ${e6}`));
1481
1487
  };
1482
- return F(e5) && (e5.indexOf(`-`) > -1 || e5.indexOf(`_`) > -1) ? (this.options.load !== `languageOnly` && i2(this.formatLanguageCode(e5)), this.options.load !== `languageOnly` && this.options.load !== `currentOnly` && i2(this.getScriptPartFromCode(e5)), this.options.load !== `currentOnly` && i2(this.getLanguagePartFromCode(e5))) : F(e5) && i2(this.formatLanguageCode(e5)), n2.forEach((e6) => {
1488
+ return L(e5) && (e5.indexOf(`-`) > -1 || e5.indexOf(`_`) > -1) ? (this.options.load !== `languageOnly` && i2(this.formatLanguageCode(e5)), this.options.load !== `languageOnly` && this.options.load !== `currentOnly` && i2(this.getScriptPartFromCode(e5)), this.options.load !== `currentOnly` && i2(this.getLanguagePartFromCode(e5))) : L(e5) && i2(this.formatLanguageCode(e5)), n2.forEach((e6) => {
1483
1489
  r2.indexOf(e6) < 0 && i2(this.formatLanguageCode(e6));
1484
1490
  }), r2;
1485
1491
  }
@@ -1488,7 +1494,7 @@ var br = { zero: 0, one: 1, two: 2, few: 3, many: 4, other: 5 };
1488
1494
  var xr = { select: (e5) => e5 === 1 ? `one` : `other`, resolvedOptions: () => ({ pluralCategories: [`one`, `other`] }) };
1489
1495
  var Sr = class {
1490
1496
  constructor(e5, t2 = {}) {
1491
- this.languageUtils = e5, this.options = t2, this.logger = L.create(`pluralResolver`), this.pluralRulesCache = {};
1497
+ this.languageUtils = e5, this.options = t2, this.logger = z.create(`pluralResolver`), this.pluralRulesCache = {};
1492
1498
  }
1493
1499
  clearCache() {
1494
1500
  this.pluralRulesCache = {};
@@ -1525,17 +1531,17 @@ var Sr = class {
1525
1531
  };
1526
1532
  var Cr = (e5, t2, n2, r2 = `.`, i2 = true) => {
1527
1533
  let a2 = er(e5, t2, n2);
1528
- return !a2 && i2 && F(n2) && (a2 = cr(e5, n2, r2), a2 === void 0 && (a2 = cr(t2, n2, r2))), a2;
1534
+ return !a2 && i2 && L(n2) && (a2 = cr(e5, n2, r2), a2 === void 0 && (a2 = cr(t2, n2, r2))), a2;
1529
1535
  };
1530
1536
  var wr = (e5) => e5.replace(/\$/g, `$$$$`);
1531
1537
  var Tr = class {
1532
1538
  constructor(e5 = {}) {
1533
- this.logger = L.create(`interpolator`), this.options = e5, this.format = e5?.interpolation?.format || ((e6) => e6), this.init(e5);
1539
+ this.logger = z.create(`interpolator`), this.options = e5, this.format = e5?.interpolation?.format || ((e6) => e6), this.init(e5);
1534
1540
  }
1535
1541
  init(e5 = {}) {
1536
1542
  e5.interpolation ||= { escapeValue: true };
1537
1543
  let { escape: t2, escapeValue: n2, useRawValueToEscape: r2, prefix: i2, prefixEscaped: a2, suffix: o2, suffixEscaped: s2, formatSeparator: c2, unescapeSuffix: l2, unescapePrefix: u2, nestingPrefix: d2, nestingPrefixEscaped: f2, nestingSuffix: p2, nestingSuffixEscaped: m2, nestingOptionsSeparator: h2, maxReplaces: g2, alwaysFormat: _2 } = e5.interpolation;
1538
- this.escape = t2 === void 0 ? rr : t2, this.escapeValue = n2 === void 0 || n2, this.useRawValueToEscape = r2 !== void 0 && r2, this.prefix = i2 ? I(i2) : a2 || `{{`, this.suffix = o2 ? I(o2) : s2 || `}}`, this.formatSeparator = c2 || `,`, this.unescapePrefix = l2 ? `` : u2 || `-`, this.unescapeSuffix = this.unescapePrefix ? `` : l2 || ``, this.nestingPrefix = d2 ? I(d2) : f2 || I(`$t(`), this.nestingSuffix = p2 ? I(p2) : m2 || I(`)`), this.nestingOptionsSeparator = h2 || `,`, this.maxReplaces = g2 || 1e3, this.alwaysFormat = _2 !== void 0 && _2, this.resetRegExp();
1544
+ this.escape = t2 === void 0 ? rr : t2, this.escapeValue = n2 === void 0 || n2, this.useRawValueToEscape = r2 !== void 0 && r2, this.prefix = i2 ? R(i2) : a2 || `{{`, this.suffix = o2 ? R(o2) : s2 || `}}`, this.formatSeparator = c2 || `,`, this.unescapePrefix = l2 ? `` : u2 || `-`, this.unescapeSuffix = this.unescapePrefix ? `` : l2 || ``, this.nestingPrefix = d2 ? R(d2) : f2 || R(`$t(`), this.nestingSuffix = p2 ? R(p2) : m2 || R(`)`), this.nestingOptionsSeparator = h2 || `,`, this.maxReplaces = g2 || 1e3, this.alwaysFormat = _2 !== void 0 && _2, this.resetRegExp();
1539
1545
  }
1540
1546
  reset() {
1541
1547
  this.options && this.init(this.options);
@@ -1561,13 +1567,13 @@ var Tr = class {
1561
1567
  if (a2 = c2(n3), a2 === void 0) {
1562
1568
  if (typeof l2 == `function`) {
1563
1569
  let t4 = l2(e5, i2, r2);
1564
- a2 = F(t4) ? t4 : ``;
1570
+ a2 = L(t4) ? t4 : ``;
1565
1571
  } else if (r2 && Object.prototype.hasOwnProperty.call(r2, n3)) a2 = ``;
1566
1572
  else if (u2) {
1567
1573
  a2 = i2[0];
1568
1574
  continue;
1569
1575
  } else this.logger.warn(`missed to pass in variable ${n3} for interpolating ${e5}`), a2 = ``;
1570
- } else !F(a2) && !this.useRawValueToEscape && (a2 = Gn(a2));
1576
+ } else !L(a2) && !this.useRawValueToEscape && (a2 = Gn(a2));
1571
1577
  let s3 = t3.safeValue(a2);
1572
1578
  if (e5 = e5.replace(i2[0], s3), u2 ? (t3.regex.lastIndex += a2.length, t3.regex.lastIndex -= i2[0].length) : t3.regex.lastIndex = 0, o2++, o2 >= this.maxReplaces) break;
1573
1579
  }
@@ -1577,7 +1583,7 @@ var Tr = class {
1577
1583
  let r2, i2, a2, o2 = (e6, t3) => {
1578
1584
  let n3 = this.nestingOptionsSeparator;
1579
1585
  if (e6.indexOf(n3) < 0) return e6;
1580
- let r3 = e6.split(RegExp(`${I(n3)}[ ]*{`)), i3 = `{${r3[1]}`;
1586
+ let r3 = e6.split(RegExp(`${R(n3)}[ ]*{`)), i3 = `{${r3[1]}`;
1581
1587
  e6 = r3[0], i3 = this.interpolate(i3, a2);
1582
1588
  let o3 = i3.match(/'/g), s2 = i3.match(/"/g);
1583
1589
  ((o3?.length ?? 0) % 2 == 0 && !s2 || (s2?.length ?? 0) % 2 != 0) && (i3 = i3.replace(/'/g, `"`));
@@ -1590,10 +1596,10 @@ var Tr = class {
1590
1596
  };
1591
1597
  for (; r2 = this.nestingRegexp.exec(e5); ) {
1592
1598
  let s2 = [];
1593
- a2 = { ...n2 }, a2 = a2.replace && !F(a2.replace) ? a2.replace : a2, a2.applyPostProcessor = false, delete a2.defaultValue;
1599
+ a2 = { ...n2 }, a2 = a2.replace && !L(a2.replace) ? a2.replace : a2, a2.applyPostProcessor = false, delete a2.defaultValue;
1594
1600
  let c2 = /{.*}/.test(r2[1]) ? r2[1].lastIndexOf(`}`) + 1 : r2[1].indexOf(this.formatSeparator);
1595
- if (c2 !== -1 && (s2 = r2[1].slice(c2).split(this.formatSeparator).map((e6) => e6.trim()).filter(Boolean), r2[1] = r2[1].slice(0, c2)), i2 = t2(o2.call(this, r2[1].trim(), a2), a2), i2 && r2[0] === e5 && !F(i2)) return i2;
1596
- F(i2) || (i2 = Gn(i2)), i2 ||= (this.logger.warn(`missed to resolve ${r2[1]} for nesting ${e5}`), ``), s2.length && (i2 = s2.reduce((e6, t3) => this.format(e6, t3, n2.lng, { ...n2, interpolationkey: r2[1].trim() }), i2.trim())), e5 = e5.replace(r2[0], i2), this.regexp.lastIndex = 0;
1601
+ if (c2 !== -1 && (s2 = r2[1].slice(c2).split(this.formatSeparator).map((e6) => e6.trim()).filter(Boolean), r2[1] = r2[1].slice(0, c2)), i2 = t2(o2.call(this, r2[1].trim(), a2), a2), i2 && r2[0] === e5 && !L(i2)) return i2;
1602
+ L(i2) || (i2 = Gn(i2)), i2 ||= (this.logger.warn(`missed to resolve ${r2[1]} for nesting ${e5}`), ``), s2.length && (i2 = s2.reduce((e6, t3) => this.format(e6, t3, n2.lng, { ...n2, interpolationkey: r2[1].trim() }), i2.trim())), e5 = e5.replace(r2[0], i2), this.regexp.lastIndex = 0;
1597
1603
  }
1598
1604
  return e5;
1599
1605
  }
@@ -1625,7 +1631,7 @@ var Dr = (e5) => {
1625
1631
  var Or = (e5) => (t2, n2, r2) => e5(lr(n2), r2)(t2);
1626
1632
  var kr = class {
1627
1633
  constructor(e5 = {}) {
1628
- this.logger = L.create(`formatter`), this.options = e5, this.init(e5);
1634
+ this.logger = z.create(`formatter`), this.options = e5, this.init(e5);
1629
1635
  }
1630
1636
  init(e5, t2 = { interpolation: {} }) {
1631
1637
  this.formatSeparator = t2.interpolation.formatSeparator || `,`;
@@ -1680,7 +1686,7 @@ var Ar = (e5, t2) => {
1680
1686
  };
1681
1687
  var jr = class extends dr {
1682
1688
  constructor(e5, t2, n2, r2 = {}) {
1683
- super(), this.backend = e5, this.store = t2, this.services = n2, this.languageUtils = n2.languageUtils, this.options = r2, this.logger = L.create(`backendConnector`), this.waitingReads = [], this.maxParallelReads = r2.maxParallelReads || 10, this.readingCalls = 0, this.maxRetries = r2.maxRetries >= 0 ? r2.maxRetries : 5, this.retryTimeout = r2.retryTimeout >= 1 ? r2.retryTimeout : 350, this.state = {}, this.queue = [], this.backend?.init?.(n2, r2.backend, r2);
1689
+ super(), this.backend = e5, this.store = t2, this.services = n2, this.languageUtils = n2.languageUtils, this.options = r2, this.logger = z.create(`backendConnector`), this.waitingReads = [], this.maxParallelReads = r2.maxParallelReads || 10, this.readingCalls = 0, this.maxRetries = r2.maxRetries >= 0 ? r2.maxRetries : 5, this.retryTimeout = r2.retryTimeout >= 1 ? r2.retryTimeout : 350, this.state = {}, this.queue = [], this.backend?.init?.(n2, r2.backend, r2);
1684
1690
  }
1685
1691
  queueLoad(e5, t2, n2, r2) {
1686
1692
  let i2 = {}, a2 = {}, o2 = {}, s2 = {};
@@ -1739,7 +1745,7 @@ var jr = class extends dr {
1739
1745
  }
1740
1746
  prepareLoading(e5, t2, n2 = {}, r2) {
1741
1747
  if (!this.backend) return this.logger.warn(`No backend was added via i18next.use. Will not load resources.`), r2 && r2();
1742
- F(e5) && (e5 = this.languageUtils.toResolveHierarchy(e5)), F(t2) && (t2 = [t2]);
1748
+ L(e5) && (e5 = this.languageUtils.toResolveHierarchy(e5)), L(t2) && (t2 = [t2]);
1743
1749
  let i2 = this.queueLoad(e5, t2, n2, r2);
1744
1750
  if (!i2.toLoad.length) return i2.pending.length || r2(), null;
1745
1751
  i2.toLoad.forEach((e6) => {
@@ -1781,7 +1787,7 @@ var jr = class extends dr {
1781
1787
  };
1782
1788
  var Mr = () => ({ debug: false, initAsync: true, ns: [`translation`], defaultNS: [`translation`], fallbackLng: [`dev`], fallbackNS: false, supportedLngs: false, nonExplicitSupportedLngs: false, load: `all`, preload: false, simplifyPluralSuffix: true, keySeparator: `.`, nsSeparator: `:`, pluralSeparator: `_`, contextSeparator: `_`, partialBundledLanguages: false, saveMissing: false, updateMissing: false, saveMissingTo: `fallback`, saveMissingPlurals: true, missingKeyHandler: false, missingInterpolationHandler: false, postProcess: false, postProcessPassResolved: false, returnNull: false, returnEmptyString: true, returnObjects: false, joinArrays: false, returnedObjectHandler: false, parseMissingKeyHandler: false, appendNamespaceToMissingKey: false, appendNamespaceToCIMode: false, overloadTranslationOptionHandler: (e5) => {
1783
1789
  let t2 = {};
1784
- if (typeof e5[1] == `object` && (t2 = e5[1]), F(e5[1]) && (t2.defaultValue = e5[1]), F(e5[2]) && (t2.tDescription = e5[2]), typeof e5[2] == `object` || typeof e5[3] == `object`) {
1790
+ if (typeof e5[1] == `object` && (t2 = e5[1]), L(e5[1]) && (t2.defaultValue = e5[1]), L(e5[2]) && (t2.tDescription = e5[2]), typeof e5[2] == `object` || typeof e5[3] == `object`) {
1785
1791
  let n2 = e5[3] || e5[2];
1786
1792
  Object.keys(n2).forEach((e6) => {
1787
1793
  t2[e6] = n2[e6];
@@ -1789,7 +1795,7 @@ var Mr = () => ({ debug: false, initAsync: true, ns: [`translation`], defaultNS:
1789
1795
  }
1790
1796
  return t2;
1791
1797
  }, interpolation: { escapeValue: true, format: (e5) => e5, prefix: `{{`, suffix: `}}`, formatSeparator: `,`, unescapePrefix: `-`, nestingPrefix: `$t(`, nestingSuffix: `)`, nestingOptionsSeparator: `,`, maxReplaces: 1e3, skipOnVariables: true }, cacheInBuiltFormats: true });
1792
- var Nr = (e5) => (F(e5.ns) && (e5.ns = [e5.ns]), F(e5.fallbackLng) && (e5.fallbackLng = [e5.fallbackLng]), F(e5.fallbackNS) && (e5.fallbackNS = [e5.fallbackNS]), e5.supportedLngs?.indexOf?.(`cimode`) < 0 && (e5.supportedLngs = e5.supportedLngs.concat([`cimode`])), typeof e5.initImmediate == `boolean` && (e5.initAsync = e5.initImmediate), e5);
1798
+ var Nr = (e5) => (L(e5.ns) && (e5.ns = [e5.ns]), L(e5.fallbackLng) && (e5.fallbackLng = [e5.fallbackLng]), L(e5.fallbackNS) && (e5.fallbackNS = [e5.fallbackNS]), e5.supportedLngs?.indexOf?.(`cimode`) < 0 && (e5.supportedLngs = e5.supportedLngs.concat([`cimode`])), typeof e5.initImmediate == `boolean` && (e5.initAsync = e5.initImmediate), e5);
1793
1799
  var Pr = () => {
1794
1800
  };
1795
1801
  var Fr = (e5) => {
@@ -1803,9 +1809,9 @@ var Rr = () => {
1803
1809
  typeof globalThis < `u` && (globalThis[Ir] = true);
1804
1810
  };
1805
1811
  var zr = (e5) => !!(e5?.modules?.backend?.name?.indexOf(`Locize`) > 0 || e5?.modules?.backend?.constructor?.name?.indexOf(`Locize`) > 0 || e5?.options?.backend?.backends && e5.options.backend.backends.some((e6) => e6?.name?.indexOf(`Locize`) > 0 || e6?.constructor?.name?.indexOf(`Locize`) > 0) || e5?.options?.backend?.projectId || e5?.options?.backend?.backendOptions && e5.options.backend.backendOptions.some((e6) => e6?.projectId));
1806
- var z = class e4 extends dr {
1812
+ var V = class e4 extends dr {
1807
1813
  constructor(e5 = {}, t2) {
1808
- if (super(), this.options = Nr(e5), this.services = {}, this.logger = L, this.modules = { external: [] }, Fr(this), t2 && !this.isInitialized && !e5.isClone) {
1814
+ if (super(), this.options = Nr(e5), this.services = {}, this.logger = z, this.modules = { external: [] }, Fr(this), t2 && !this.isInitialized && !e5.isClone) {
1809
1815
  if (!this.options.initAsync) return this.init(e5, t2), this;
1810
1816
  setTimeout(() => {
1811
1817
  this.init(e5, t2);
@@ -1813,18 +1819,18 @@ var z = class e4 extends dr {
1813
1819
  }
1814
1820
  }
1815
1821
  init(e5 = {}, t2) {
1816
- this.isInitializing = true, typeof e5 == `function` && (t2 = e5, e5 = {}), e5.defaultNS == null && e5.ns && (F(e5.ns) ? e5.defaultNS = e5.ns : e5.ns.indexOf(`translation`) < 0 && (e5.defaultNS = e5.ns[0]));
1822
+ this.isInitializing = true, typeof e5 == `function` && (t2 = e5, e5 = {}), e5.defaultNS == null && e5.ns && (L(e5.ns) ? e5.defaultNS = e5.ns : e5.ns.indexOf(`translation`) < 0 && (e5.defaultNS = e5.ns[0]));
1817
1823
  let n2 = Mr();
1818
1824
  this.options = { ...n2, ...this.options, ...Nr(e5) }, this.options.interpolation = { ...n2.interpolation, ...this.options.interpolation }, e5.keySeparator !== void 0 && (this.options.userDefinedKeySeparator = e5.keySeparator), e5.nsSeparator !== void 0 && (this.options.userDefinedNsSeparator = e5.nsSeparator), typeof this.options.overloadTranslationOptionHandler != `function` && (this.options.overloadTranslationOptionHandler = n2.overloadTranslationOptionHandler), this.options.showSupportNotice !== false && !zr(this) && !Lr() && (typeof console < `u` && console.info !== void 0 && console.info(`\u{1F310} i18next is made possible by our own product, Locize \u2014 consider powering your project with managed localization (AI, CDN, integrations): https://locize.com \u{1F499}`), Rr());
1819
1825
  let r2 = (e6) => e6 ? typeof e6 == `function` ? new e6() : e6 : null;
1820
1826
  if (!this.options.isClone) {
1821
- this.modules.logger ? L.init(r2(this.modules.logger), this.options) : L.init(null, this.options);
1827
+ this.modules.logger ? z.init(r2(this.modules.logger), this.options) : z.init(null, this.options);
1822
1828
  let e6;
1823
1829
  e6 = this.modules.formatter ? this.modules.formatter : kr;
1824
1830
  let t3 = new yr(this.options);
1825
1831
  this.store = new fr(this.options.resources, this.options);
1826
1832
  let i3 = this.services;
1827
- i3.logger = L, i3.resourceStore = this.store, i3.languageUtils = t3, i3.pluralResolver = new Sr(t3, { prepend: this.options.pluralSeparator, simplifyPluralSuffix: this.options.simplifyPluralSuffix }), this.options.interpolation.format && this.options.interpolation.format !== n2.interpolation.format && this.logger.deprecate(`init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting`), e6 && (!this.options.interpolation.format || this.options.interpolation.format === n2.interpolation.format) && (i3.formatter = r2(e6), i3.formatter.init && i3.formatter.init(i3, this.options), this.options.interpolation.format = i3.formatter.format.bind(i3.formatter)), i3.interpolator = new Tr(this.options), i3.utils = { hasLoadedNamespace: this.hasLoadedNamespace.bind(this) }, i3.backendConnector = new jr(r2(this.modules.backend), i3.resourceStore, i3, this.options), i3.backendConnector.on(`*`, (e7, ...t4) => {
1833
+ i3.logger = z, i3.resourceStore = this.store, i3.languageUtils = t3, i3.pluralResolver = new Sr(t3, { prepend: this.options.pluralSeparator, simplifyPluralSuffix: this.options.simplifyPluralSuffix }), this.options.interpolation.format && this.options.interpolation.format !== n2.interpolation.format && this.logger.deprecate(`init: you are still using the legacy format function, please use the new approach: https://www.i18next.com/translation-function/formatting`), e6 && (!this.options.interpolation.format || this.options.interpolation.format === n2.interpolation.format) && (i3.formatter = r2(e6), i3.formatter.init && i3.formatter.init(i3, this.options), this.options.interpolation.format = i3.formatter.format.bind(i3.formatter)), i3.interpolator = new Tr(this.options), i3.utils = { hasLoadedNamespace: this.hasLoadedNamespace.bind(this) }, i3.backendConnector = new jr(r2(this.modules.backend), i3.resourceStore, i3, this.options), i3.backendConnector.on(`*`, (e7, ...t4) => {
1828
1834
  this.emit(e7, ...t4);
1829
1835
  }), this.modules.languageDetector && (i3.languageDetector = r2(this.modules.languageDetector), i3.languageDetector.init && i3.languageDetector.init(i3, this.options.detection, this.options)), this.modules.i18nFormat && (i3.i18nFormat = r2(this.modules.i18nFormat), i3.i18nFormat.init && i3.i18nFormat.init(this)), this.translator = new vr(this.services, this.options), this.translator.on(`*`, (e7, ...t4) => {
1830
1836
  this.emit(e7, ...t4);
@@ -1851,7 +1857,7 @@ var z = class e4 extends dr {
1851
1857
  return this.options.resources || !this.options.initAsync ? a2() : setTimeout(a2, 0), i2;
1852
1858
  }
1853
1859
  loadResources(e5, t2 = Pr) {
1854
- let n2 = t2, r2 = F(e5) ? e5 : this.language;
1860
+ let n2 = t2, r2 = L(e5) ? e5 : this.language;
1855
1861
  if (typeof e5 == `function` && (n2 = e5), !this.options.resources || this.options.partialBundledLanguages) {
1856
1862
  if (r2?.toLowerCase() === `cimode` && (!this.options.preload || this.options.preload.length === 0)) return n2();
1857
1863
  let e6 = [], t3 = (t4) => {
@@ -1897,7 +1903,7 @@ var z = class e4 extends dr {
1897
1903
  a3 ? this.isLanguageChangingTo === e5 && (r2(a3), this.translator.changeLanguage(a3), this.isLanguageChangingTo = void 0, this.emit(`languageChanged`, a3), this.logger.log(`languageChanged`, a3)) : this.isLanguageChangingTo = void 0, n2.resolve((...e6) => this.t(...e6)), t2 && t2(i3, (...e6) => this.t(...e6));
1898
1904
  }, a2 = (t3) => {
1899
1905
  !e5 && !t3 && this.services.languageDetector && (t3 = []);
1900
- let n3 = F(t3) ? t3 : t3 && t3[0], a3 = this.store.hasLanguageSomeTranslations(n3) ? n3 : this.services.languageUtils.getBestMatchFromCodes(F(t3) ? [t3] : t3);
1906
+ let n3 = L(t3) ? t3 : t3 && t3[0], a3 = this.store.hasLanguageSomeTranslations(n3) ? n3 : this.services.languageUtils.getBestMatchFromCodes(L(t3) ? [t3] : t3);
1901
1907
  a3 && (this.language || r2(a3), this.translator.language || this.translator.changeLanguage(a3), this.services.languageDetector?.cacheUserLanguage?.(a3)), this.loadResources(a3, (e6) => {
1902
1908
  i2(e6, a3);
1903
1909
  });
@@ -1909,11 +1915,11 @@ var z = class e4 extends dr {
1909
1915
  let a2;
1910
1916
  a2 = typeof t3 == `object` ? { ...t3 } : this.options.overloadTranslationOptionHandler([e6, t3].concat(i2)), a2.lng = a2.lng || r2.lng, a2.lngs = a2.lngs || r2.lngs, a2.ns = a2.ns || r2.ns, a2.keyPrefix !== `` && (a2.keyPrefix = a2.keyPrefix || n2 || r2.keyPrefix);
1911
1917
  let o2 = { ...this.options, ...a2 };
1912
- typeof a2.keyPrefix == `function` && (a2.keyPrefix = R(a2.keyPrefix, o2));
1918
+ typeof a2.keyPrefix == `function` && (a2.keyPrefix = B(a2.keyPrefix, o2));
1913
1919
  let s2 = this.options.keySeparator || `.`, c2;
1914
- return a2.keyPrefix && Array.isArray(e6) ? c2 = e6.map((e7) => (typeof e7 == `function` && (e7 = R(e7, o2)), `${a2.keyPrefix}${s2}${e7}`)) : (typeof e6 == `function` && (e6 = R(e6, o2)), c2 = a2.keyPrefix ? `${a2.keyPrefix}${s2}${e6}` : e6), this.t(c2, a2);
1920
+ return a2.keyPrefix && Array.isArray(e6) ? c2 = e6.map((e7) => (typeof e7 == `function` && (e7 = B(e7, o2)), `${a2.keyPrefix}${s2}${e7}`)) : (typeof e6 == `function` && (e6 = B(e6, o2)), c2 = a2.keyPrefix ? `${a2.keyPrefix}${s2}${e6}` : e6), this.t(c2, a2);
1915
1921
  };
1916
- return F(e5) ? r2.lng = e5 : r2.lngs = e5, r2.ns = t2, r2.keyPrefix = n2, r2;
1922
+ return L(e5) ? r2.lng = e5 : r2.lngs = e5, r2.ns = t2, r2.keyPrefix = n2, r2;
1917
1923
  }
1918
1924
  t(...e5) {
1919
1925
  return this.translator?.translate(...e5);
@@ -1941,7 +1947,7 @@ var z = class e4 extends dr {
1941
1947
  }
1942
1948
  loadNamespaces(e5, t2) {
1943
1949
  let n2 = Wn();
1944
- return this.options.ns ? (F(e5) && (e5 = [e5]), e5.forEach((e6) => {
1950
+ return this.options.ns ? (L(e5) && (e5 = [e5]), e5.forEach((e6) => {
1945
1951
  this.options.ns.indexOf(e6) < 0 && this.options.ns.push(e6);
1946
1952
  }), this.loadResources((e6) => {
1947
1953
  n2.resolve(), t2 && t2(e6);
@@ -1949,7 +1955,7 @@ var z = class e4 extends dr {
1949
1955
  }
1950
1956
  loadLanguages(e5, t2) {
1951
1957
  let n2 = Wn();
1952
- F(e5) && (e5 = [e5]);
1958
+ L(e5) && (e5 = [e5]);
1953
1959
  let r2 = this.options.preload || [], i2 = e5.filter((e6) => r2.indexOf(e6) < 0 && this.services.languageUtils.isSupportedCode(e6));
1954
1960
  return i2.length ? (this.options.preload = r2.concat(i2), this.loadResources((e6) => {
1955
1961
  n2.resolve(), t2 && t2(e6);
@@ -1990,7 +1996,7 @@ var z = class e4 extends dr {
1990
1996
  return { options: this.options, store: this.store, language: this.language, languages: this.languages, resolvedLanguage: this.resolvedLanguage };
1991
1997
  }
1992
1998
  }.createInstance();
1993
- z.createInstance, z.dir, z.init, z.loadResources, z.reloadResources, z.use, z.changeLanguage, z.getFixedT, z.t, z.exists, z.setDefaultNamespace, z.hasLoadedNamespace, z.loadNamespaces, z.loadLanguages;
1999
+ V.createInstance, V.dir, V.init, V.loadResources, V.reloadResources, V.use, V.changeLanguage, V.getFixedT, V.t, V.exists, V.setDefaultNamespace, V.hasLoadedNamespace, V.loadNamespaces, V.loadLanguages;
1994
2000
  var Br = function() {
1995
2001
  return Br = Object.assign || function(e5) {
1996
2002
  for (var t2, n2 = 1, r2 = arguments.length; n2 < r2; n2++) for (var i2 in t2 = arguments[n2], t2) Object.prototype.hasOwnProperty.call(t2, i2) && (e5[i2] = t2[i2]);
@@ -2005,7 +2011,7 @@ function Vr(e5) {
2005
2011
  } };
2006
2012
  throw TypeError(t2 ? `Object is not iterable.` : `Symbol.iterator is not defined.`);
2007
2013
  }
2008
- function B(e5, t2) {
2014
+ function H(e5, t2) {
2009
2015
  var n2 = typeof Symbol == `function` && e5[Symbol.iterator];
2010
2016
  if (!n2) return e5;
2011
2017
  var r2 = n2.call(e5), i2, a2 = [], o2;
@@ -2065,7 +2071,7 @@ function ii(e5, { value: t2, currency: n2 }, r2 = {}) {
2065
2071
  return ei(t2), ni(e5, n2, r2).formatToParts(t2);
2066
2072
  }
2067
2073
  function ai(e5) {
2068
- return yn().find((e6) => e6.primary)?.id ?? e5;
2074
+ return _n().find((e6) => e6.primary)?.id ?? e5;
2069
2075
  }
2070
2076
  function oi(e5, t2) {
2071
2077
  let { locale: n2, ...r2 } = t2 ?? {}, i2 = n2 ?? e5.essentials?.locale;
@@ -2089,7 +2095,7 @@ var si = Un({ getLanguage: (e5) => () => {
2089
2095
  }, getTranslationFunction: (e5) => () => {
2090
2096
  let t2 = e5.translations?.();
2091
2097
  if (!t2) throw Error(`Host translation resources are not available.`);
2092
- let n2 = z.createInstance(), r2 = ai(e5.essentials?.language) || `en`, i2 = { lng: e5.essentials?.language || r2, fallbackLng: r2, resources: t2 };
2098
+ let n2 = V.createInstance(), r2 = ai(e5.essentials?.language) || `en`, i2 = { lng: e5.essentials?.language || r2, fallbackLng: r2, resources: t2 };
2093
2099
  return n2.use(Jr).init(i2, (e6) => {
2094
2100
  if (e6) throw e6;
2095
2101
  }), n2.t.bind(n2);
@@ -2111,7 +2117,7 @@ var ci = class {
2111
2117
  };
2112
2118
  var li = (e5) => new ci(e5);
2113
2119
  var ui = Un({ getMonitoringClient: (e5) => () => e5.getMonitoringClient ? e5.getMonitoringClient() : li(`Host monitoring client is not available on the current host. Make sure to use an updated version of the host initialization package.`) });
2114
- var V = { service: `service`, services: `services`, categories: `categories`, locations: `locations`, sessions: `sessions`, timeSlots: `time-slots`, serviceAddOns: `service-addons`, bookingsSettings: `bookings-settings`, serviceCta: `service-cta`, preferences: `preferences`, bookingSummary: `booking-summary`, bookingCheckout: `booking-checkout`, formValues: `form-values`, paymentOptions: `payment-options`, seo: `seo`, warmup: `warmup`, reschedule: `reschedule` };
2120
+ var U = { service: `service`, services: `services`, categories: `categories`, locations: `locations`, sessions: `sessions`, timeSlots: `time-slots`, serviceAddOns: `service-addons`, bookingsSettings: `bookings-settings`, serviceCta: `service-cta`, preferences: `preferences`, bookingSummary: `booking-summary`, bookingCheckout: `booking-checkout`, formValues: `form-values`, paymentOptions: `payment-options`, seo: `seo`, warmup: `warmup`, reschedule: `reschedule` };
2115
2121
  function di(e5) {
2116
2122
  try {
2117
2123
  let t2 = ui.getMonitoringClient?.();
@@ -2120,70 +2126,74 @@ function di(e5) {
2120
2126
  return null;
2121
2127
  }
2122
2128
  }
2123
- function H(e5, { feature: t2, action: n2, level: r2 = `error`, contexts: i2 }) {
2129
+ function fi(e5, { feature: t2, action: n2, level: r2 = `error`, contexts: i2 }) {
2124
2130
  let a2 = di(`captureException`);
2125
2131
  if (!a2) return;
2126
2132
  let o2 = e5 instanceof Error ? e5 : Error(String(e5));
2127
2133
  a2.captureException(o2, { level: r2, tags: { feature: t2, action: n2 }, ...i2 ? { contexts: i2 } : {} });
2128
2134
  }
2129
- function fi(e5, { feature: t2, tags: n2 }, r2) {
2135
+ function pi(e5, { feature: t2, tags: n2 }, r2) {
2130
2136
  let i2 = di(`startSpanManual`);
2131
2137
  if (!i2) return r2;
2132
2138
  let a2 = i2.startSpanManual({ name: e5, tags: { feature: t2, ...n2 } });
2133
2139
  return r2.then(() => a2.end(), (e6) => a2.fail(e6)), r2;
2134
2140
  }
2135
- var pi = class extends import_react.Component {
2141
+ var mi = class extends import_react.Component {
2136
2142
  state = { hasError: false };
2137
2143
  static getDerivedStateFromError() {
2138
2144
  return { hasError: true };
2139
2145
  }
2140
2146
  componentDidCatch(e5, t2) {
2141
- H(e5, { feature: this.props.feature ?? `service`, action: `render`, contexts: { react: { componentStack: t2.componentStack } } });
2147
+ fi(e5, { feature: this.props.feature ?? `service`, action: `render`, contexts: { react: { componentStack: t2.componentStack } } });
2142
2148
  }
2143
2149
  render() {
2144
2150
  return this.state.hasError ? this.props.fallback : this.props.children;
2145
2151
  }
2146
2152
  };
2147
- function mi(e5) {
2153
+ function hi(e5) {
2148
2154
  let t2 = e5;
2149
- if (t2.__state || (t2.__state = { status: `pending` }, t2.then((e6) => {
2155
+ return t2.__state || (t2.__state = { status: `pending` }, t2.then((e6) => {
2150
2156
  t2.__state = { status: `fulfilled`, value: e6 };
2151
2157
  }, (e6) => {
2152
2158
  t2.__state = { status: `rejected`, reason: e6 };
2153
- })), t2.__state.status === `fulfilled`) return t2.__state.value;
2154
- throw t2.__state.status === `rejected` ? t2.__state.reason : t2;
2159
+ })), t2.__state;
2155
2160
  }
2156
- function hi(e5) {
2161
+ function gi(e5) {
2162
+ let t2 = hi(e5);
2163
+ if (t2.status === `fulfilled`) return t2.value;
2164
+ throw t2.status === `rejected` ? t2.reason : e5;
2165
+ }
2166
+ function _i(e5) {
2157
2167
  let t2 = Promise.resolve(e5);
2158
2168
  return t2.__state = { status: `fulfilled`, value: e5 }, t2;
2159
2169
  }
2160
- var gi = /* @__PURE__ */ new WeakMap();
2161
- function _i(e5, t2, n2) {
2162
- let r2 = gi.get(e5);
2163
- r2 || (r2 = /* @__PURE__ */ new WeakMap(), gi.set(e5, r2));
2170
+ var vi = /* @__PURE__ */ new WeakMap();
2171
+ function yi(e5, t2, n2) {
2172
+ let r2 = vi.get(e5);
2173
+ r2 || (r2 = /* @__PURE__ */ new WeakMap(), vi.set(e5, r2));
2164
2174
  let i2 = r2.get(t2);
2165
2175
  i2 || (i2 = /* @__PURE__ */ new WeakMap(), r2.set(t2, i2));
2166
2176
  let a2 = i2.get(n2);
2167
2177
  if (!a2) {
2168
2178
  let r3 = e5;
2169
- a2 = r3.__state?.status === `fulfilled` ? hi(t2(r3.__state.value)) : r3.__state?.status === `rejected` ? hi(n2(r3.__state.reason)) : e5.then(t2, n2), i2.set(n2, a2);
2179
+ a2 = r3.__state?.status === `fulfilled` ? _i(t2(r3.__state.value)) : r3.__state?.status === `rejected` ? _i(n2(r3.__state.reason)) : e5.then(t2, n2), i2.set(n2, a2);
2170
2180
  }
2171
2181
  return a2;
2172
2182
  }
2173
- function U(e5) {
2183
+ function W(e5) {
2174
2184
  return e5;
2175
2185
  }
2176
- var vi = U(`@wix/site-service-url`);
2177
- var yi = `appSectionParams`;
2178
- function bi(e5) {
2179
- let t2 = e5.searchParams.get(yi);
2186
+ var bi = W(`@wix/site-service-url`);
2187
+ var xi = `appSectionParams`;
2188
+ function Si(e5) {
2189
+ let t2 = e5.searchParams.get(xi);
2180
2190
  if (t2 === null) return e5;
2181
2191
  let n2 = new URL(e5);
2182
- n2.searchParams.delete(yi);
2183
- for (let [e6, r2] of Object.entries(xi(t2))) typeof r2 == `string` && !n2.searchParams.has(e6) && n2.searchParams.set(e6, r2);
2192
+ n2.searchParams.delete(xi);
2193
+ for (let [e6, r2] of Object.entries(Ci(t2))) typeof r2 == `string` && !n2.searchParams.has(e6) && n2.searchParams.set(e6, r2);
2184
2194
  return n2;
2185
2195
  }
2186
- function xi(e5) {
2196
+ function Ci(e5) {
2187
2197
  try {
2188
2198
  let t2 = JSON.parse(e5);
2189
2199
  return t2 && typeof t2 == `object` && !Array.isArray(t2) ? t2 : {};
@@ -2191,16 +2201,16 @@ function xi(e5) {
2191
2201
  return {};
2192
2202
  }
2193
2203
  }
2194
- var Si = `bookings-uou:url-change`;
2195
- var Ci = (e5) => {
2204
+ var wi = `bookings-uou:url-change`;
2205
+ var Ti = (e5) => {
2196
2206
  let t2 = new URL(e5);
2197
2207
  return t2.searchParams.sort(), t2.href;
2198
2208
  };
2199
- function wi(e5, { disableScrollToTop: t2, skipHistory: n2 } = {}) {
2209
+ function Ei(e5, { disableScrollToTop: t2, skipHistory: n2 } = {}) {
2200
2210
  let r2 = globalThis.window;
2201
2211
  if (!r2?.history) return;
2202
2212
  let i2 = new URL(r2.location.href);
2203
- if (Ci(i2) === Ci(e5)) return;
2213
+ if (Ti(i2) === Ti(e5)) return;
2204
2214
  let a2 = { scrollY: r2.scrollY };
2205
2215
  if (n2) r2.history.replaceState(a2, ``, e5.href);
2206
2216
  else {
@@ -2211,251 +2221,251 @@ function wi(e5, { disableScrollToTop: t2, skipHistory: n2 } = {}) {
2211
2221
  return;
2212
2222
  }
2213
2223
  }
2214
- r2.dispatchEvent(new Event(Si));
2224
+ r2.dispatchEvent(new Event(wi));
2215
2225
  }
2216
- function Ti(e5) {
2226
+ function Di(e5) {
2217
2227
  let t2 = globalThis.window;
2218
- return t2 ? (t2.addEventListener(Si, e5), t2.addEventListener(`popstate`, e5), () => {
2219
- t2.removeEventListener(Si, e5), t2.removeEventListener(`popstate`, e5);
2228
+ return t2 ? (t2.addEventListener(wi, e5), t2.addEventListener(`popstate`, e5), () => {
2229
+ t2.removeEventListener(wi, e5), t2.removeEventListener(`popstate`, e5);
2220
2230
  }) : () => {
2221
2231
  };
2222
2232
  }
2223
- var Ei = (e5) => {
2233
+ var Oi = (e5) => {
2224
2234
  try {
2225
2235
  return decodeURIComponent(e5);
2226
2236
  } catch {
2227
2237
  return e5;
2228
2238
  }
2229
2239
  };
2230
- function Di(e5, t2) {
2240
+ function ki(e5, t2) {
2231
2241
  let n2 = t2 ? new URL(t2).pathname : `/`;
2232
- return `./${Ei(new URL(e5).pathname.replace(n2, ``).replace(/^\/|\/$/g, ``))}`;
2233
- }
2234
- function Oi() {
2235
- let e5 = (0, import_services_manager_react.useService)(vi), t2 = (0, import_react.useCallback)(() => e5.currentUrl, [e5]), n2 = (0, import_react.useSyncExternalStore)(Ti, t2, t2), r2 = (0, import_react.useMemo)(() => bi(new URL(n2)), [n2]), a2 = e5.siteUrl.replace(/\/$/, ``);
2236
- return { pathname: r2.pathname, search: r2.search, searchParams: r2.searchParams, href: r2.href, getParsedUrl: () => bi(new URL(e5.currentUrl)), getRelativeUrl: () => Di(e5.currentUrl, a2), getExternalBaseUrl: () => a2, pushUrl: wi };
2237
- }
2238
- var ki = U(`@wix/site-service-editor-context`);
2239
- var Ai = U(`@wix/site-service-pages`);
2240
- var ji = U(`@wix/site-service-router`);
2241
- var Mi = U(`@wix/site-service-renderer-configuration`);
2242
- var Ni = `13d21c63-b5ec-5912-8397-c3a5ddb27a97`;
2243
- var Pi = `shopping_cart`;
2244
- var Fi = `thank_you_page`;
2245
- var W = function(e5) {
2242
+ return `./${Oi(new URL(e5).pathname.replace(n2, ``).replace(/^\/|\/$/g, ``))}`;
2243
+ }
2244
+ function Ai() {
2245
+ let e5 = (0, import_services_manager_react.useService)(bi), t2 = (0, import_react.useCallback)(() => e5.currentUrl, [e5]), n2 = (0, import_react.useSyncExternalStore)(Di, t2, t2), r2 = (0, import_react.useMemo)(() => Si(new URL(n2)), [n2]), a2 = e5.siteUrl.replace(/\/$/, ``);
2246
+ return { pathname: r2.pathname, search: r2.search, searchParams: r2.searchParams, href: r2.href, getParsedUrl: () => Si(new URL(e5.currentUrl)), getRelativeUrl: () => ki(e5.currentUrl, a2), getExternalBaseUrl: () => a2, pushUrl: Ei };
2247
+ }
2248
+ var ji = W(`@wix/site-service-editor-context`);
2249
+ var Mi = W(`@wix/site-service-pages`);
2250
+ var Ni = W(`@wix/site-service-router`);
2251
+ var Pi = W(`@wix/site-service-renderer-configuration`);
2252
+ var Fi = `13d21c63-b5ec-5912-8397-c3a5ddb27a97`;
2253
+ var Ii = `shopping_cart`;
2254
+ var Li = `thank_you_page`;
2255
+ var G = function(e5) {
2246
2256
  return e5.BOOK_ONLINE = `bookingsBookOnline`, e5.SERVICE_PAGE = `bookingsServicePage`, e5.CALENDAR_PAGE = `bookingsCalendar`, e5.FORM_PAGE = `bookingsForm`, e5;
2247
2257
  }({});
2248
- var Ii = `{{(.*?)}}`;
2249
- var Li = `[{{}}]`;
2250
- var Ri = `([^/]+)`;
2251
- var G;
2258
+ var Ri = `{{(.*?)}}`;
2259
+ var zi = `[{{}}]`;
2260
+ var Bi = `([^/]+)`;
2261
+ var K;
2252
2262
  (function(e5) {
2253
2263
  e5.product_page = `product_page`, e5.blog = `blog`, e5.post = `post`, e5.forum = `forum`, e5.group = `group`, e5.bookings = `Booking Service Page`, e5.challenges = `challenge_page`;
2254
- })(G ||= {});
2255
- var K;
2264
+ })(K ||= {});
2265
+ var q;
2256
2266
  (function(e5) {
2257
2267
  e5.PRODUCT_PAGE = `wix.stores.sub_pages.product`, e5.BLOG_POST = `wix.blog.sub_pages.post`, e5.BLOG_POST_EDIT = `wix.blog.sub_pages.post.edit`, e5.BLOG_POST_PREVIEW = `wix.blog.sub_pages.post.preview`, e5.BLOG_CATEGORY = `wix.blog.sub_pages.category`, e5.FORUM_CATEGORY = `wix.forum.sub_pages.category`, e5.FORUM_CATEGORY_PAGINATION = `wix.forum.sub_pages.category.pagination`, e5.FORUM_CATEGORY_CREATE_POST = `wix.forum.sub_pages.category.create-post`, e5.FORUM_CATEGORY_CREATE_QUESTION = `wix.forum.sub_pages.category.create-question`, e5.FORUM_POST = `wix.forum.sub_pages.post`, e5.FORUM_POST_EDIT = `wix.forum.sub_pages.post.edit`, e5.FORUM_POST_PAGINATION = `wix.forum.sub_pages.post.pagination`, e5.FORUM_POST_DEEP_LINK_DATA = `wix.forum.sub_pages.post.deep-link-data`, e5.FORUM_POST_PAGINATION_AND_DEEP_LINK_DATA = `wix.forum.sub_pages.post.pagination-and-deep-link-data`, e5.GROUP = `wix.groups.sub_pages.group`, e5.GROUP_POST = `wix.groups.sub_pages.post`, e5.BOOKINGS_SERVICE = `wix.bookings.sub_pages.service_page`, e5.CHALLENGES_PAGE = `wix.online_programs.sub_pages.online_program`;
2258
- })(K ||= {});
2259
- var zi = {};
2260
- var Bi = (zi[K.PRODUCT_PAGE] = { variables: [`slug`], required: [`slug`] }, zi);
2261
- var q = `{{main-mapping}}`;
2268
+ })(q ||= {});
2262
2269
  var Vi = {};
2263
- var Hi;
2264
- var Ui = (Vi[K.BLOG_POST] = { variables: [`slug`], required: [`slug`], subMappings: (Hi = {}, Hi[K.BLOG_POST_EDIT] = { defaultMapping: `${q}/edit` }, Hi[K.BLOG_POST_PREVIEW] = { required: [`instance`], defaultMapping: `${q}/preview/{{instance}}` }, Hi) }, Vi);
2265
- var Wi = {};
2266
- var Gi = (Wi[K.BLOG_CATEGORY] = { variables: [`slug`], required: [`slug`], defaultPrefix: `categories` }, Wi);
2270
+ var Hi = (Vi[q.PRODUCT_PAGE] = { variables: [`slug`], required: [`slug`] }, Vi);
2271
+ var J = `{{main-mapping}}`;
2272
+ var Ui = {};
2273
+ var Wi;
2274
+ var Gi = (Ui[q.BLOG_POST] = { variables: [`slug`], required: [`slug`], subMappings: (Wi = {}, Wi[q.BLOG_POST_EDIT] = { defaultMapping: `${J}/edit` }, Wi[q.BLOG_POST_PREVIEW] = { required: [`instance`], defaultMapping: `${J}/preview/{{instance}}` }, Wi) }, Ui);
2267
2275
  var Ki = {};
2268
- var J;
2269
- var qi;
2270
- var Ji = (Ki[K.FORUM_POST] = { variables: [`categorySlug`, `postSlug`], required: [`categorySlug`, `postSlug`], subMappings: (J = {}, J[K.FORUM_POST_EDIT] = { defaultMapping: `${q}/edit` }, J[K.FORUM_POST_PAGINATION] = { required: [`page`], defaultMapping: `${q}/p-{{page}}` }, J[K.FORUM_POST_DEEP_LINK_DATA] = { required: [`deepLinkData`], defaultMapping: `${q}/dl-{{deepLinkData}}` }, J[K.FORUM_POST_PAGINATION_AND_DEEP_LINK_DATA] = { required: [`page`, `deepLinkData`], defaultMapping: `${q}/p-{{page}}/dl-{{deepLinkData}}` }, J) }, Ki[K.FORUM_CATEGORY] = { variables: [`slug`], required: [`slug`], subMappings: (qi = {}, qi[K.FORUM_CATEGORY_CREATE_POST] = { defaultMapping: `${q}/create-post` }, qi[K.FORUM_CATEGORY_CREATE_QUESTION] = { defaultMapping: `${q}/create-question` }, qi[K.FORUM_CATEGORY_PAGINATION] = { required: [`page`], defaultMapping: `${q}/p-{{page}}` }, qi) }, Ki);
2271
- var Yi = {};
2272
- var Xi = (Yi[K.GROUP] = { variables: [`groupId`, `tabName`], required: [`groupId`, `tabName`] }, Yi[K.GROUP_POST] = { variables: [`groupId`, `tabName`, `postId`], required: [`groupId`, `tabName`, `postId`] }, Yi);
2273
- var Zi = {};
2274
- var Qi = (Zi[K.BOOKINGS_SERVICE] = { variables: [`slug`], required: [`slug`], defaultPrefix: `service-page` }, Zi);
2275
- var $i = {};
2276
- var ea = ($i[K.CHALLENGES_PAGE] = { variables: [`slug`], required: [`slug`], defaultPrefix: `challenge-page` }, $i);
2276
+ var qi = (Ki[q.BLOG_CATEGORY] = { variables: [`slug`], required: [`slug`], defaultPrefix: `categories` }, Ki);
2277
+ var Ji = {};
2278
+ var Yi;
2279
+ var Xi;
2280
+ var Zi = (Ji[q.FORUM_POST] = { variables: [`categorySlug`, `postSlug`], required: [`categorySlug`, `postSlug`], subMappings: (Yi = {}, Yi[q.FORUM_POST_EDIT] = { defaultMapping: `${J}/edit` }, Yi[q.FORUM_POST_PAGINATION] = { required: [`page`], defaultMapping: `${J}/p-{{page}}` }, Yi[q.FORUM_POST_DEEP_LINK_DATA] = { required: [`deepLinkData`], defaultMapping: `${J}/dl-{{deepLinkData}}` }, Yi[q.FORUM_POST_PAGINATION_AND_DEEP_LINK_DATA] = { required: [`page`, `deepLinkData`], defaultMapping: `${J}/p-{{page}}/dl-{{deepLinkData}}` }, Yi) }, Ji[q.FORUM_CATEGORY] = { variables: [`slug`], required: [`slug`], subMappings: (Xi = {}, Xi[q.FORUM_CATEGORY_CREATE_POST] = { defaultMapping: `${J}/create-post` }, Xi[q.FORUM_CATEGORY_CREATE_QUESTION] = { defaultMapping: `${J}/create-question` }, Xi[q.FORUM_CATEGORY_PAGINATION] = { required: [`page`], defaultMapping: `${J}/p-{{page}}` }, Xi) }, Ji);
2281
+ var Qi = {};
2282
+ var $i = (Qi[q.GROUP] = { variables: [`groupId`, `tabName`], required: [`groupId`, `tabName`] }, Qi[q.GROUP_POST] = { variables: [`groupId`, `tabName`, `postId`], required: [`groupId`, `tabName`, `postId`] }, Qi);
2283
+ var ea = {};
2284
+ var ta = (ea[q.BOOKINGS_SERVICE] = { variables: [`slug`], required: [`slug`], defaultPrefix: `service-page` }, ea);
2285
+ var na = {};
2286
+ var ra = (na[q.CHALLENGES_PAGE] = { variables: [`slug`], required: [`slug`], defaultPrefix: `challenge-page` }, na);
2277
2287
  var Y = {};
2278
- var ta = (Y[G.product_page] = Bi, Y[G.post] = Ui, Y[G.blog] = Gi, Y[G.forum] = Ji, Y[G.group] = Xi, Y[G.bookings] = Qi, Y[G.challenges] = ea, Y);
2279
- var na = function(e5) {
2280
- return Object.values(ra()).some(function(t2) {
2288
+ var ia = (Y[K.product_page] = Hi, Y[K.post] = Gi, Y[K.blog] = qi, Y[K.forum] = Zi, Y[K.group] = $i, Y[K.bookings] = ta, Y[K.challenges] = ra, Y);
2289
+ var aa = function(e5) {
2290
+ return Object.values(oa()).some(function(t2) {
2281
2291
  return !!t2?.subMappings?.[e5];
2282
2292
  });
2283
2293
  };
2284
- var ra = function() {
2285
- return Object.values(ta).reduce(function(e5, t2) {
2294
+ var oa = function() {
2295
+ return Object.values(ia).reduce(function(e5, t2) {
2286
2296
  return Br(Br({}, e5), t2);
2287
2297
  }, {}) || {};
2288
2298
  };
2289
- var ia = function(e5) {
2290
- var t2 = ra()[e5];
2291
- return !t2 && na(e5) && console.warn(`You cannot get variables schema for subMappings key (${e5}).`), t2;
2299
+ var sa = function(e5) {
2300
+ var t2 = oa()[e5];
2301
+ return !t2 && aa(e5) && console.warn(`You cannot get variables schema for subMappings key (${e5}).`), t2;
2292
2302
  };
2293
- var aa = function(e5) {
2294
- return Object.entries(ta).filter(function(t2) {
2295
- var n2 = B(t2, 2)[1];
2303
+ var ca = function(e5) {
2304
+ return Object.entries(ia).filter(function(t2) {
2305
+ var n2 = H(t2, 2)[1];
2296
2306
  return Object.keys(n2).includes(e5);
2297
2307
  }).map(function(e6) {
2298
- return B(e6, 1)[0];
2308
+ return H(e6, 1)[0];
2299
2309
  })[0];
2300
2310
  };
2301
- var oa = function(e5) {
2302
- return Object.entries(ra()).find(function(t2) {
2303
- var n2 = B(t2, 2);
2311
+ var la = function(e5) {
2312
+ return Object.entries(oa()).find(function(t2) {
2313
+ var n2 = H(t2, 2);
2304
2314
  return n2[0], !!n2[1]?.subMappings?.[e5];
2305
2315
  });
2306
2316
  };
2307
- var sa = function(e5) {
2317
+ var ua = function(e5) {
2308
2318
  var t2 = [];
2309
- if (na(e5)) {
2310
- var n2 = B(oa(e5), 2);
2319
+ if (aa(e5)) {
2320
+ var n2 = H(la(e5), 2);
2311
2321
  n2[0];
2312
2322
  var r2 = n2[1];
2313
- t2.push.apply(t2, Hr(Hr([], B(r2?.required || []), false), B(r2?.subMappings?.[e5]?.required || []), false));
2314
- } else t2.push.apply(t2, Hr([], B(ia(e5)?.required || []), false));
2323
+ t2.push.apply(t2, Hr(Hr([], H(r2?.required || []), false), H(r2?.subMappings?.[e5]?.required || []), false));
2324
+ } else t2.push.apply(t2, Hr([], H(sa(e5)?.required || []), false));
2315
2325
  return t2;
2316
2326
  };
2317
- var ca = function(e5, t2) {
2327
+ var da = function(e5, t2) {
2318
2328
  var n2;
2319
2329
  return t2 === void 0 && (t2 = ``), (n2 = e5?.main)?.find?.call(n2, function(e6) {
2320
2330
  return e6.key === t2;
2321
2331
  });
2322
2332
  };
2323
- var la = function(e5, t2) {
2333
+ var fa = function(e5, t2) {
2324
2334
  return Error(`Url Mappings Error - [${e5}]: ${t2}`);
2325
2335
  };
2326
- var ua = Object.values(K);
2327
- var da = la(`key`, `must be one of: ${ua.toString()}`);
2328
- var fa = function(e5) {
2329
- if (typeof e5 != `string` || !ua.includes(e5)) return da;
2336
+ var pa = Object.values(q);
2337
+ var ma = fa(`key`, `must be one of: ${pa.toString()}`);
2338
+ var ha = function(e5) {
2339
+ if (typeof e5 != `string` || !pa.includes(e5)) return ma;
2330
2340
  };
2331
- var pa = la(`itemData`, `must be on object with string as value, for example: { "slug": "shoes" }`);
2332
- var ma = function(e5) {
2341
+ var ga = fa(`itemData`, `must be on object with string as value, for example: { "slug": "shoes" }`);
2342
+ var _a = function(e5) {
2333
2343
  if (typeof e5 != `object` || !e5 || !Object.values(e5).every(function(e6) {
2334
2344
  return typeof e6 == `string`;
2335
- }) || Array.isArray(e5)) return pa;
2345
+ }) || Array.isArray(e5)) return ga;
2336
2346
  };
2337
- var ha = la(`itemData`, `must have required variables, for example: { "slug": "shoes" }`);
2338
- var ga = function(e5, t2) {
2347
+ var va = fa(`itemData`, `must have required variables, for example: { "slug": "shoes" }`);
2348
+ var ya = function(e5, t2) {
2339
2349
  try {
2340
- var n2 = sa(e5);
2350
+ var n2 = ua(e5);
2341
2351
  if (!n2.every(function(e6) {
2342
2352
  return !!t2[e6];
2343
2353
  }) || !n2.length) throw Error();
2344
2354
  } catch {
2345
- return ha;
2355
+ return va;
2346
2356
  }
2347
2357
  };
2348
- var _a = function(e5) {
2358
+ var ba = function(e5) {
2349
2359
  var t2 = e5.key, n2 = e5.itemData;
2350
- return [fa(t2), ma(n2), ga(t2, n2)].find(Boolean);
2360
+ return [ha(t2), _a(n2), ya(t2, n2)].find(Boolean);
2351
2361
  };
2352
- var va = function(e5) {
2362
+ var xa = function(e5) {
2353
2363
  return function(t2) {
2354
- var n2 = new RegExp(Li, `g`), r2 = t2.replace(n2, ``);
2364
+ var n2 = new RegExp(zi, `g`), r2 = t2.replace(n2, ``);
2355
2365
  return e5?.[r2];
2356
2366
  };
2357
2367
  };
2358
- var ya = function(e5, t2, n2, r2) {
2368
+ var Sa = function(e5, t2, n2, r2) {
2359
2369
  e5 === void 0 && (e5 = { main: [] }), r2 === void 0 && (r2 = {});
2360
- var i2 = _a({ key: t2, itemData: n2 });
2370
+ var i2 = ba({ key: t2, itemData: n2 });
2361
2371
  if (i2) throw i2;
2362
- var a2 = (ca(e5, t2) || {}).mapping, o2 = (r2 || {}).baseUrl;
2372
+ var a2 = (da(e5, t2) || {}).mapping, o2 = (r2 || {}).baseUrl;
2363
2373
  if (o2 ??= ``, o2 = o2.endsWith(`/`) ? o2?.slice(0, -1) : o2, a2 && typeof a2 == `string`) {
2364
- var s2 = new RegExp(Ii, `g`), c2 = a2.replace(s2, va(n2));
2374
+ var s2 = new RegExp(Ri, `g`), c2 = a2.replace(s2, xa(n2));
2365
2375
  return o2.concat(`/${c2}`);
2366
2376
  }
2367
2377
  };
2368
- var ba = /[.*+?^$()|]/g;
2369
- var xa = function(e5) {
2370
- var t2 = e5.replace(ba, `\\$&`).replace(new RegExp(Ii, `g`), Ri);
2378
+ var Ca = /[.*+?^$()|]/g;
2379
+ var wa = function(e5) {
2380
+ var t2 = e5.replace(Ca, `\\$&`).replace(new RegExp(Ri, `g`), Bi);
2371
2381
  return RegExp(`^${t2}$`);
2372
2382
  };
2373
- var Sa = function(e5, t2) {
2383
+ var Ta = function(e5, t2) {
2374
2384
  return e5 === void 0 && (e5 = []), e5.find(function(e6) {
2375
- return xa(e6).test(t2);
2385
+ return wa(e6).test(t2);
2376
2386
  });
2377
2387
  };
2378
- la(`url`, `Url must be a string`);
2379
- var Ca = function(e5) {
2388
+ fa(`url`, `Url must be a string`);
2389
+ var Ea = function(e5) {
2380
2390
  return [` `, ` `, `
2381
2391
  `].every(function(t2) {
2382
2392
  return !e5?.includes?.call(e5, t2);
2383
2393
  });
2384
2394
  };
2385
- var wa = function(e5) {
2386
- return e5?.length <= Ia.MAX_URL_MAPPING_LENGTH;
2395
+ var Da = function(e5) {
2396
+ return e5?.length <= za.MAX_URL_MAPPING_LENGTH;
2387
2397
  };
2388
- var Ta = function(e5) {
2398
+ var Oa = function(e5) {
2389
2399
  return e5?.split(`/`).every(Boolean);
2390
2400
  };
2391
- var Ea = function(e5, t2) {
2401
+ var ka = function(e5, t2) {
2392
2402
  var n2 = t2.urlMappingKey;
2393
- return sa(n2)?.every(function(t3) {
2403
+ return ua(n2)?.every(function(t3) {
2394
2404
  return e5?.includes(`{{${t3}}}`);
2395
2405
  });
2396
2406
  };
2397
- var Da = function(e5) {
2398
- return (e5.match(new RegExp(Ii, `g`))?.length || 0) <= 1;
2407
+ var Aa = function(e5) {
2408
+ return (e5.match(new RegExp(Ri, `g`))?.length || 0) <= 1;
2399
2409
  };
2400
- var Oa = function(e5) {
2401
- return e5?.split(`/`).every(Da);
2410
+ var ja = function(e5) {
2411
+ return e5?.split(`/`).every(Aa);
2402
2412
  };
2403
- var ka = function(e5) {
2413
+ var Ma = function(e5) {
2404
2414
  return [e5.publishedPrefix, e5.savedPrefix].filter(Boolean);
2405
2415
  };
2406
- var Aa = function(e5, t2) {
2416
+ var Na = function(e5, t2) {
2407
2417
  return t2 === void 0 && (t2 = []), function(n2, r2) {
2408
2418
  var i2 = n2.split(`/`), a2 = n2 === r2;
2409
2419
  if (i2.length < 1 || a2) return true;
2410
- var o2 = B(r2.split(`/`), 1)[0], s2 = B(i2, 1)[0];
2420
+ var o2 = H(r2.split(`/`), 1)[0], s2 = H(i2, 1)[0];
2411
2421
  return t2.includes(s2) ? true : e5.every(function(e6) {
2412
2422
  return e6 === o2 || e6 !== s2;
2413
2423
  });
2414
2424
  };
2415
2425
  };
2416
- var ja = function(e5, t2) {
2426
+ var Pa = function(e5, t2) {
2417
2427
  var n2 = t2.pathPrefixes;
2418
- return Aa(Object.values(n2).map(function(e6) {
2428
+ return Na(Object.values(n2).map(function(e6) {
2419
2429
  return e6.publishedPrefix;
2420
- }).filter(Boolean), ka(t2.pathPrefix))(e5, t2.defaultMapping.defaultPublished);
2430
+ }).filter(Boolean), Ma(t2.pathPrefix))(e5, t2.defaultMapping.defaultPublished);
2421
2431
  };
2422
- var Ma = function(e5, t2) {
2432
+ var Fa = function(e5, t2) {
2423
2433
  var n2 = t2.urlMappingKey, r2 = t2.urlMappings;
2424
- return !Sa(r2.main?.filter(function(e6) {
2434
+ return !Ta(r2.main?.filter(function(e6) {
2425
2435
  return n2 !== e6.key;
2426
2436
  }).map(function(e6) {
2427
2437
  return e6.mapping;
2428
2438
  }), e5);
2429
2439
  };
2430
- var Na = function(e5) {
2431
- e5 = e5.replace(new RegExp(Ii, `ig`), ``);
2440
+ var Ia = function(e5) {
2441
+ e5 = e5.replace(new RegExp(Ri, `ig`), ``);
2432
2442
  var t2 = new RegExp(/[^\]_.~!*'();:@&=+$,<>\\#^%?`"]/, `g`), n2 = !/(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff]|[\u0023-\u0039]\ufe0f?\u20e3|\u3299|\u3297|\u303d|\u3030|\u24c2|\ud83c[\udd70-\udd71]|\ud83c[\udd7e-\udd7f]|\ud83c\udd8e|\ud83c[\udd91-\udd9a]|\ud83c[\udde6-\uddff]|[\ud83c[\ude01-\ude02]|\ud83c\ude1a|\ud83c\ude2f|[\ud83c[\ude32-\ude3a]|[\ud83c[\ude50-\ude51]|\u203c|\u2049|[\u25aa-\u25ab]|\u25b6|\u25c0|[\u25fb-\u25fe]|\u00a9|\u00ae|\u2122|\u2139|\ud83c\udc04|[\u2600-\u26FF]|\u2b05|\u2b06|\u2b07|\u2b1b|\u2b1c|\u2b50|\u2b55|\u231a|\u231b|\u2328|\u23cf|[\u23e9-\u23f3]|[\u23f8-\u23fa]|\ud83c\udccf|\u2934|\u2935|[\u2190-\u21ff])/g.test(e5), r2 = !e5.replace(t2, ``);
2433
2443
  return n2 && r2;
2434
2444
  };
2435
- var Pa = function(e5) {
2436
- var t2 = B(e5, 1)[0], n2 = e5.slice(-1);
2445
+ var La = function(e5) {
2446
+ var t2 = H(e5, 1)[0], n2 = e5.slice(-1);
2437
2447
  return t2 !== `/` && n2 !== `/`;
2438
2448
  };
2439
- var Fa = function(e5, t2) {
2449
+ var Ra = function(e5, t2) {
2440
2450
  var n2 = t2.pathPrefixes;
2441
- return Aa(Object.values(n2).map(function(e6) {
2451
+ return Na(Object.values(n2).map(function(e6) {
2442
2452
  return e6.savedPrefix;
2443
- }).filter(Boolean), ka(t2.pathPrefix))(e5, t2.defaultMapping.defaultSaved);
2453
+ }).filter(Boolean), Ma(t2.pathPrefix))(e5, t2.defaultMapping.defaultSaved);
2444
2454
  };
2445
2455
  var X;
2446
2456
  (function(e5) {
2447
2457
  e5.MAX_LENGTH_ERROR = `MAX_LENGTH_ERROR`, e5.NO_SPACES_ERROR = `NO_SPACES_ERROR`, e5.NO_EMPTY_SEGMENT_ERROR = `NO_EMPTY_SEGMENT_ERROR`, e5.CONTAIN_MAIN_VARIABLE_ERROR = `CONTAIN_MAIN_VARIABLE_ERROR`, e5.ONLY_ONE_VARIABLE_PER_SEGMENT_ERROR = `ONLY_ONE_VARIABLE_PER_SEGMENT_ERROR`, e5.ONLY_UNIQUE_PUBLISHED_URL_ERROR = `ONLY_UNIQUE_PUBLISHED_URL_ERROR`, e5.ONLY_UNIQUE_SAVED_URL_ERROR = `ONLY_UNIQUE_SAVED_URL_ERROR`, e5.ONLY_UNIQUE_MAPPING_ERROR = `ONLY_UNIQUE_MAPPING_ERROR`, e5.NO_INVALID_CHARACTERS_ERROR = `NO_INVALID_CHARACTERS_ERROR`, e5.NO_STARTING_OR_ENDING_SLASH_ERROR = `NO_STARTING_OR_ENDING_SLASH_ERROR`;
2448
2458
  })(X ||= {});
2449
- var Ia = function() {
2459
+ var za = function() {
2450
2460
  function e5(e6) {
2451
2461
  var t2 = e6.urlMappingKey, n2 = e6.pathPrefixes, r2 = e6.urlMappings, i2 = this;
2452
2462
  this.initValidators = function() {
2453
- i2.validators = [[wa, X.MAX_LENGTH_ERROR], [Ca, X.NO_SPACES_ERROR], [Pa, X.NO_STARTING_OR_ENDING_SLASH_ERROR], [Ta, X.NO_EMPTY_SEGMENT_ERROR], [Na, X.NO_INVALID_CHARACTERS_ERROR], [Ea, X.CONTAIN_MAIN_VARIABLE_ERROR], [Oa, X.ONLY_ONE_VARIABLE_PER_SEGMENT_ERROR], [ja, X.ONLY_UNIQUE_PUBLISHED_URL_ERROR], [Fa, X.ONLY_UNIQUE_SAVED_URL_ERROR], [Ma, X.ONLY_UNIQUE_MAPPING_ERROR]];
2454
- }, this.urlMappings = r2, this.pathPrefixes = n2, this.urlMappingKey = t2, this.pathPrefix = this.getPathPrefix(), this.defaultMapping = La(t2, this.pathPrefix), this.initValidators();
2463
+ i2.validators = [[Da, X.MAX_LENGTH_ERROR], [Ea, X.NO_SPACES_ERROR], [La, X.NO_STARTING_OR_ENDING_SLASH_ERROR], [Oa, X.NO_EMPTY_SEGMENT_ERROR], [Ia, X.NO_INVALID_CHARACTERS_ERROR], [ka, X.CONTAIN_MAIN_VARIABLE_ERROR], [ja, X.ONLY_ONE_VARIABLE_PER_SEGMENT_ERROR], [Pa, X.ONLY_UNIQUE_PUBLISHED_URL_ERROR], [Ra, X.ONLY_UNIQUE_SAVED_URL_ERROR], [Fa, X.ONLY_UNIQUE_MAPPING_ERROR]];
2464
+ }, this.urlMappings = r2, this.pathPrefixes = n2, this.urlMappingKey = t2, this.pathPrefix = this.getPathPrefix(), this.defaultMapping = Ba(t2, this.pathPrefix), this.initValidators();
2455
2465
  }
2456
2466
  return e5.prototype.getPathPrefix = function() {
2457
- var t2 = aa(this.urlMappingKey);
2458
- if (!t2) throw na(this.urlMappingKey) ? Error(`Url Mapper Validator Error: Validator does not support sub mapping, please use the main url mapping key`) : Error(`Url Mapper Validator Error: Url mapping key is not supported (${this.urlMappingKey})`);
2467
+ var t2 = ca(this.urlMappingKey);
2468
+ if (!t2) throw aa(this.urlMappingKey) ? Error(`Url Mapper Validator Error: Validator does not support sub mapping, please use the main url mapping key`) : Error(`Url Mapper Validator Error: Url mapping key is not supported (${this.urlMappingKey})`);
2459
2469
  return this.pathPrefixes[t2] || e5.FALLBACK_PATH_PREFIX;
2460
2470
  }, Object.defineProperty(e5.prototype, "validatorProps", { get: function() {
2461
2471
  var e6 = this;
@@ -2464,7 +2474,7 @@ var Ia = function() {
2464
2474
  var t2, n2;
2465
2475
  try {
2466
2476
  for (var r2 = Vr(this.validators), i2 = r2.next(); !i2.done; i2 = r2.next()) {
2467
- var a2 = B(i2.value, 2), o2 = a2[0], s2 = a2[1], c2 = !!o2(e6, this.validatorProps);
2477
+ var a2 = H(i2.value, 2), o2 = a2[0], s2 = a2[1], c2 = !!o2(e6, this.validatorProps);
2468
2478
  if (!c2) return { isValid: c2, error: s2 };
2469
2479
  }
2470
2480
  } catch (e7) {
@@ -2479,41 +2489,41 @@ var Ia = function() {
2479
2489
  return { isValid: true };
2480
2490
  }, e5.errorArray = Object.values(X), e5.MAX_URL_MAPPING_LENGTH = 1e3, e5.FALLBACK_PATH_PREFIX = `unknown`, e5;
2481
2491
  }();
2482
- var La = function(e5, t2) {
2483
- var n2 = ra()[e5] || { required: [`slug`] }, r2 = n2.required, i2 = n2.defaultPrefix, a2 = {};
2484
- return t2 && typeof t2 == `object` ? (a2.savedPrefix = t2.savedPrefix ?? ``, a2.publishedPrefix = t2.publishedPrefix ?? ``) : (a2.savedPrefix = Ia.FALLBACK_PATH_PREFIX, a2.publishedPrefix = Ia.FALLBACK_PATH_PREFIX), { defaultSaved: Hr([a2.savedPrefix, i2], B(r2?.map(function(e6) {
2492
+ var Ba = function(e5, t2) {
2493
+ var n2 = oa()[e5] || { required: [`slug`] }, r2 = n2.required, i2 = n2.defaultPrefix, a2 = {};
2494
+ return t2 && typeof t2 == `object` ? (a2.savedPrefix = t2.savedPrefix ?? ``, a2.publishedPrefix = t2.publishedPrefix ?? ``) : (a2.savedPrefix = za.FALLBACK_PATH_PREFIX, a2.publishedPrefix = za.FALLBACK_PATH_PREFIX), { defaultSaved: Hr([a2.savedPrefix, i2], H(r2?.map(function(e6) {
2485
2495
  return `{{${e6}}}`;
2486
- })), false).filter(Boolean).join(`/`), defaultPublished: Hr([a2.publishedPrefix, i2], B(r2?.map(function(e6) {
2496
+ })), false).filter(Boolean).join(`/`), defaultPublished: Hr([a2.publishedPrefix, i2], H(r2?.map(function(e6) {
2487
2497
  return `{{${e6}}}`;
2488
2498
  })), false).filter(Boolean).join(`/`) };
2489
2499
  };
2490
- function Ra(e5, t2) {
2491
- return t2 ? ya(e5, K.BOOKINGS_SERVICE, { slug: t2 }, { baseUrl: `` }) : void 0;
2500
+ function Va(e5, t2) {
2501
+ return t2 ? Sa(e5, q.BOOKINGS_SERVICE, { slug: t2 }, { baseUrl: `` }) : void 0;
2492
2502
  }
2493
- function za(e5) {
2503
+ function Ha(e5) {
2494
2504
  if (!e5) return;
2495
2505
  let t2 = ``;
2496
2506
  return (e5.filename || e5.altText) && (t2 = `/${encodeURIComponent(e5.filename || e5.altText)}`), e5.id ? `wix:image://v1/${e5.id}${t2}#originWidth=${e5.width}&originHeight=${e5.height}` : e5.url;
2497
2507
  }
2498
- function Ba(e5) {
2508
+ function Ua(e5) {
2499
2509
  return Object.keys(e5).length === 1 && `$and` in e5 && Array.isArray(e5.$and);
2500
2510
  }
2501
- function Va(e5) {
2511
+ function Wa(e5) {
2502
2512
  return Object.keys(e5).length === 1 && `$or` in e5 && Array.isArray(e5.$or);
2503
2513
  }
2504
- function Ha(e5) {
2514
+ function Ga(e5) {
2505
2515
  return Object.keys(e5).length === 1 && `$not` in e5 && typeof e5.$not == `object`;
2506
2516
  }
2507
2517
  function Z(e5, t2) {
2508
- return e5 === void 0 || Object.keys(e5).length === 0 ? t2 : t2 === void 0 || Object.keys(t2).length === 0 ? e5 : { $and: [...Ba(e5) ? e5.$and : [e5], ...Ba(t2) ? t2.$and : [t2]] };
2518
+ return e5 === void 0 || Object.keys(e5).length === 0 ? t2 : t2 === void 0 || Object.keys(t2).length === 0 ? e5 : { $and: [...Ua(e5) ? e5.$and : [e5], ...Ua(t2) ? t2.$and : [t2]] };
2509
2519
  }
2510
- function Ua(e5, t2) {
2511
- return e5 === void 0 || Object.keys(e5).length === 0 ? t2 : t2 === void 0 || Object.keys(t2).length === 0 ? e5 : { $or: [...Va(e5) ? e5.$or : [e5], ...Va(t2) ? t2.$or : [t2]] };
2520
+ function Ka(e5, t2) {
2521
+ return e5 === void 0 || Object.keys(e5).length === 0 ? t2 : t2 === void 0 || Object.keys(t2).length === 0 ? e5 : { $or: [...Wa(e5) ? e5.$or : [e5], ...Wa(t2) ? t2.$or : [t2]] };
2512
2522
  }
2513
- function Wa(e5) {
2514
- if (e5 !== void 0 && Object.keys(e5).length !== 0) return Ha(e5) ? e5.$not : { $not: e5 };
2523
+ function qa(e5) {
2524
+ if (e5 !== void 0 && Object.keys(e5).length !== 0) return Ga(e5) ? e5.$not : { $not: e5 };
2515
2525
  }
2516
- var Ga = class {
2526
+ var Ja = class {
2517
2527
  _items;
2518
2528
  _fetchNextPage;
2519
2529
  _fetchPrevPage;
@@ -2543,7 +2553,7 @@ var Ga = class {
2543
2553
  return await this._fetchPrevPage();
2544
2554
  }
2545
2555
  };
2546
- var Ka = class extends Ga {
2556
+ var Ya = class extends Ja {
2547
2557
  _nextCursor;
2548
2558
  _prevCursor;
2549
2559
  cursors;
@@ -2557,7 +2567,7 @@ var Ka = class extends Ga {
2557
2567
  return !!this._prevCursor;
2558
2568
  }
2559
2569
  };
2560
- var qa = class extends Ga {
2570
+ var Xa = class extends Ja {
2561
2571
  _totalCount;
2562
2572
  _offset;
2563
2573
  _tooManyToCount;
@@ -2580,16 +2590,16 @@ var qa = class extends Ga {
2580
2590
  return !!(this._limit !== 0 && this.currentPage && this.currentPage > 0);
2581
2591
  }
2582
2592
  };
2583
- function Ja(e5) {
2593
+ function Za(e5) {
2584
2594
  let t2 = (n2) => ({ query: n2, async find() {
2585
2595
  try {
2586
- let r2 = e5.requestTransformer(e5.pagingMethod === `CURSOR` && n2.cursorPaging.cursor ? { cursorPaging: n2.cursorPaging } : n2), i2 = await e5.func(r2), { [Ke]: a2, [qe]: o2 } = e5.responseTransformer(i2);
2596
+ let r2 = e5.requestTransformer(e5.pagingMethod === `CURSOR` && n2.cursorPaging.cursor ? { cursorPaging: n2.cursorPaging } : n2), i2 = await e5.func(r2), { [We]: a2, [Ge]: o2 } = e5.responseTransformer(i2);
2587
2597
  if (e5.pagingMethod === `OFFSET`) {
2588
2598
  let e6 = n2;
2589
- return new qa({ items: a2 ?? [], fetchNextPage: () => t2({ ...e6, paging: { offset: e6.paging.offset + e6.paging.limit, limit: e6.paging.limit } }).find(), fetchPrevPage: () => t2({ ...n2, paging: { offset: Math.max(e6.paging.offset - e6.paging.limit, 0), limit: e6.paging.limit } }).find(), offset: e6.paging.offset, limit: e6.paging.limit, totalCount: o2?.total, tooManyToCount: o2?.tooManyToCount, originQuery: this });
2599
+ return new Xa({ items: a2 ?? [], fetchNextPage: () => t2({ ...e6, paging: { offset: e6.paging.offset + e6.paging.limit, limit: e6.paging.limit } }).find(), fetchPrevPage: () => t2({ ...n2, paging: { offset: Math.max(e6.paging.offset - e6.paging.limit, 0), limit: e6.paging.limit } }).find(), offset: e6.paging.offset, limit: e6.paging.limit, totalCount: o2?.total, tooManyToCount: o2?.tooManyToCount, originQuery: this });
2590
2600
  }
2591
2601
  let s2 = n2.cursorPaging;
2592
- return new Ka({ items: a2 ?? [], limit: s2.limit, originQuery: this, fetchNextPage: () => t2({ ...n2, cursorPaging: { cursor: o2?.cursors?.next ?? void 0, limit: s2.limit } }).find(), fetchPrevPage: () => t2({ ...n2, cursorPaging: { cursor: o2?.cursors?.prev ?? void 0, limit: s2.limit } }).find(), prevCursor: o2?.cursors?.prev ?? void 0, nextCursor: o2?.cursors?.next ?? void 0 });
2602
+ return new Ya({ items: a2 ?? [], limit: s2.limit, originQuery: this, fetchNextPage: () => t2({ ...n2, cursorPaging: { cursor: o2?.cursors?.next ?? void 0, limit: s2.limit } }).find(), fetchPrevPage: () => t2({ ...n2, cursorPaging: { cursor: o2?.cursors?.prev ?? void 0, limit: s2.limit } }).find(), prevCursor: o2?.cursors?.prev ?? void 0, nextCursor: o2?.cursors?.next ?? void 0 });
2593
2603
  } catch (t3) {
2594
2604
  throw e5.errorTransformer(t3);
2595
2605
  }
@@ -2641,11 +2651,11 @@ function Ja(e5) {
2641
2651
  let a2 = { [Q(e5.transformationPaths, r2)]: { $exists: i2 } };
2642
2652
  return t2({ ...n2, filter: Z(n2.filter, a2) });
2643
2653
  }, or(e6) {
2644
- return t2({ ...n2, filter: Ua(n2.filter, e6.query.filter) });
2654
+ return t2({ ...n2, filter: Ka(n2.filter, e6.query.filter) });
2645
2655
  }, and(e6) {
2646
2656
  return t2({ ...n2, filter: Z(n2.filter, e6.query.filter) });
2647
2657
  }, not(e6) {
2648
- return t2({ ...n2, filter: Wa(e6.query.filter) });
2658
+ return t2({ ...n2, filter: qa(e6.query.filter) });
2649
2659
  }, ascending(...r2) {
2650
2660
  return t2({ ...n2, sort: [...n2.sort ?? [], ...r2.map((t3) => ({ fieldName: Q(e5.transformationPaths, t3), order: `ASC` }))] });
2651
2661
  }, descending(...r2) {
@@ -2664,26 +2674,26 @@ function Ja(e5) {
2664
2674
  }
2665
2675
  function Q(e5, t2) {
2666
2676
  let n2 = Object.entries(e5).find(([e6]) => e6 === t2 || t2.startsWith(`${e6}.`))?.[0];
2667
- return n2 ? t2.replace(n2, e5[n2]) : Ye(t2, { ...e5, ...Je });
2677
+ return n2 ? t2.replace(n2, e5[n2]) : qe(t2, { ...e5, ...Ke });
2668
2678
  }
2669
- function Ya(e5, t2, n2 = {}) {
2670
- let r2 = (r3, i3) => Ya(e5, t2, { ...n2, [r3]: i3 }), i2 = () => Object.keys(n2).length === 0 ? {} : { [Xe(e5, t2)]: n2 };
2679
+ function Qa(e5, t2, n2 = {}) {
2680
+ let r2 = (r3, i3) => Qa(e5, t2, { ...n2, [r3]: i3 }), i2 = () => Object.keys(n2).length === 0 ? {} : { [Je(e5, t2)]: n2 };
2671
2681
  return { get filter() {
2672
2682
  return i2();
2673
2683
  }, eq: (e6) => r2(`$eq`, e6), ne: (e6) => r2(`$ne`, e6), gt: (e6) => r2(`$gt`, e6), gte: (e6) => r2(`$gte`, e6), lt: (e6) => r2(`$lt`, e6), lte: (e6) => r2(`$lte`, e6), startsWith: (e6) => r2(`$startsWith`, e6), endsWith: (e6) => r2(`$endsWith`, e6), contains: (e6) => r2(`$contains`, e6), in: (e6) => r2(`$in`, e6), nin: (e6) => r2(`$nin`, e6), hasSome: (e6) => r2(`$hasSome`, e6), hasAll: (e6) => r2(`$hasAll`, e6), exists: (e6 = true) => r2(`$exists`, e6), isEmpty: (e6 = true) => r2(`$isEmpty`, e6), isNotEmpty: () => r2(`$ne`, null) };
2674
2684
  }
2675
- function Xa(e5) {
2676
- return Object.assign((t2) => Ya(t2, e5), { and: (...e6) => ({ filter: { $and: e6.map((e7) => e7.filter) } }), or: (...e6) => ({ filter: { $or: e6.map((e7) => e7.filter) } }), not: (e6) => ({ filter: { $not: e6.filter } }) });
2685
+ function $a(e5) {
2686
+ return Object.assign((t2) => Qa(t2, e5), { and: (...e6) => ({ filter: { $and: e6.map((e7) => e7.filter) } }), or: (...e6) => ({ filter: { $or: e6.map((e7) => e7.filter) } }), not: (e6) => ({ filter: { $not: e6.filter } }) });
2677
2687
  }
2678
- function Za(e5) {
2679
- return (t2) => ({ asc: () => ({ sort: { fieldName: Xe(t2, e5), order: `ASC` } }), desc: () => ({ sort: { fieldName: Xe(t2, e5), order: `DESC` } }) });
2688
+ function eo(e5) {
2689
+ return (t2) => ({ asc: () => ({ sort: { fieldName: Je(t2, e5), order: `ASC` } }), desc: () => ({ sort: { fieldName: Je(t2, e5), order: `DESC` } }) });
2680
2690
  }
2681
- function Qa(e5) {
2691
+ function to(e5) {
2682
2692
  return () => {
2683
2693
  let t2 = {}, n2 = { withFilter(e6) {
2684
2694
  return t2 = { ...t2, filter: e6.filter }, n2;
2685
2695
  }, withFields(...r2) {
2686
- return t2 = { ...t2, fields: r2.map((t3) => Xe(t3, e5)) }, n2;
2696
+ return t2 = { ...t2, fields: r2.map((t3) => Je(t3, e5)) }, n2;
2687
2697
  }, withSorting(...e6) {
2688
2698
  return t2 = { ...t2, sort: e6.map((e7) => e7.sort) }, n2;
2689
2699
  }, withPaging(e6) {
@@ -2694,57 +2704,57 @@ function Qa(e5) {
2694
2704
  return n2;
2695
2705
  };
2696
2706
  }
2697
- function $a(e5) {
2698
- return { QueryBuilder: Qa(e5), Filter: Xa(e5), Sort: Za(e5) };
2699
- }
2700
- var eo = `filter`;
2701
- var to = `sort`;
2702
- var no = `cursorPaging`;
2703
- var ro = `paging`;
2704
- var io = [eo, to, no];
2705
- var ao = [eo, to, ro];
2706
- function oo(e5, t2) {
2707
+ function no(e5) {
2708
+ return { QueryBuilder: to(e5), Filter: $a(e5), Sort: eo(e5) };
2709
+ }
2710
+ var ro = `filter`;
2711
+ var io = `sort`;
2712
+ var ao = `cursorPaging`;
2713
+ var oo = `paging`;
2714
+ var so = [ro, io, ao];
2715
+ var co = [ro, io, oo];
2716
+ function lo(e5, t2) {
2707
2717
  return !e5 || typeof e5 != `object` ? false : t2.some((t3) => e5.hasOwnProperty(t3));
2708
2718
  }
2709
- function so(e5) {
2710
- return oo(e5, io);
2719
+ function uo(e5) {
2720
+ return lo(e5, so);
2711
2721
  }
2712
- function co(e5) {
2713
- return oo(e5, ao);
2722
+ function fo(e5) {
2723
+ return lo(e5, co);
2714
2724
  }
2715
- function lo(e5) {
2725
+ function po(e5) {
2716
2726
  let { hasOptionsParameter: t2 } = e5;
2717
2727
  return function(...n2) {
2718
- return t2 ? fo(n2, e5) : uo(n2, e5);
2728
+ return t2 ? ho(n2, e5) : mo(n2, e5);
2719
2729
  };
2720
2730
  }
2721
- function uo(e5, t2) {
2731
+ function mo(e5, t2) {
2722
2732
  return e5.length === 0 ? t2.builderQueryFunction() : t2.typedQueryFunction(e5[0]);
2723
2733
  }
2724
- function fo(e5, t2) {
2734
+ function ho(e5, t2) {
2725
2735
  switch (e5.length) {
2726
2736
  case 0:
2727
2737
  return t2.builderQueryFunction();
2728
2738
  case 1:
2729
- return so(e5[0]) || co(e5[0]) ? t2.typedQueryFunction(e5[0]) : t2.builderQueryFunction(e5[0]);
2739
+ return uo(e5[0]) || fo(e5[0]) ? t2.typedQueryFunction(e5[0]) : t2.builderQueryFunction(e5[0]);
2730
2740
  default:
2731
2741
  return t2.typedQueryFunction(e5[0], e5[1]);
2732
2742
  }
2733
2743
  }
2734
- function po(e5) {
2735
- return It(Object.assign(e5, { domainToMappings: { "manage._base_domain_": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/v1/serviceOptionsAndVariants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/bookings/v1/service-options-and-variants`, destPath: `` }], _: [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/v1/serviceOptionsAndVariants`, destPath: `/v1/serviceOptionsAndVariants` }], "*.dev.wix-code.com": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }], "editor._base_domain_": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/bookings/v1/service-options-and-variants`, destPath: `` }], "blocks._base_domain_": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/bookings/v1/service-options-and-variants`, destPath: `` }], "create.editorx": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/bookings/v1/service-options-and-variants`, destPath: `` }], "www.wixapis.com": [{ srcPath: `/bookings/v1/serviceOptionsAndVariants`, destPath: `/v1/serviceOptionsAndVariants` }], "bo._base_domain_": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }], "wixbo.ai": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }], "wix-bo.com": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }], "www._base_domain_": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/service-options-and-variants` }] } }));
2744
+ function go(e5) {
2745
+ return Pt(Object.assign(e5, { domainToMappings: { "manage._base_domain_": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/v1/serviceOptionsAndVariants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/bookings/v1/service-options-and-variants`, destPath: `` }], _: [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/v1/serviceOptionsAndVariants`, destPath: `/v1/serviceOptionsAndVariants` }], "*.dev.wix-code.com": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }], "editor._base_domain_": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/bookings/v1/service-options-and-variants`, destPath: `` }], "blocks._base_domain_": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/bookings/v1/service-options-and-variants`, destPath: `` }], "create.editorx": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }, { srcPath: `/_api/bookings/v1/service-options-and-variants`, destPath: `` }], "www.wixapis.com": [{ srcPath: `/bookings/v1/serviceOptionsAndVariants`, destPath: `/v1/serviceOptionsAndVariants` }], "bo._base_domain_": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }], "wixbo.ai": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }], "wix-bo.com": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/serviceOptionsAndVariants` }], "www._base_domain_": [{ srcPath: `/_api/v1/service-options-and-variants`, destPath: `/v1/service-options-and-variants` }] } }));
2736
2746
  }
2737
- var mo = `@wix/auto_sdk_bookings_service-options-and-variants`;
2738
- function ho(e5) {
2747
+ var _o = `@wix/auto_sdk_bookings_service-options-and-variants`;
2748
+ function vo(e5) {
2739
2749
  function t2({ host: t3 }) {
2740
- return { entityFqdn: `wix.bookings.catalog.v1.service_options_and_variants`, method: `POST`, methodFqn: `wix.bookings.catalog.v1.ServiceOptionsAndVariantsService.QueryServiceOptionsAndVariants`, packageName: mo, migrationOptions: { optInTransformResponse: true }, url: po({ protoPath: `/v1/serviceOptionsAndVariants/query`, data: e5, host: t3 }), data: e5 };
2750
+ return { entityFqdn: `wix.bookings.catalog.v1.service_options_and_variants`, method: `POST`, methodFqn: `wix.bookings.catalog.v1.ServiceOptionsAndVariantsService.QueryServiceOptionsAndVariants`, packageName: _o, migrationOptions: { optInTransformResponse: true }, url: go({ protoPath: `/v1/serviceOptionsAndVariants/query`, data: e5, host: t3 }), data: e5 };
2741
2751
  }
2742
2752
  return t2;
2743
2753
  }
2744
- function go() {
2754
+ function yo() {
2745
2755
  let { httpClient: e5, sideEffects: t2 } = arguments[0];
2746
- return Ja({ func: async (n2) => {
2747
- let r2 = ho(n2);
2756
+ return Za({ func: async (n2) => {
2757
+ let r2 = vo(n2);
2748
2758
  t2?.onSiteCall?.();
2749
2759
  try {
2750
2760
  let n3 = await e5.request(r2);
@@ -2754,64 +2764,64 @@ function go() {
2754
2764
  }
2755
2765
  }, requestTransformer: (e6) => {
2756
2766
  let t3 = [e6, {}];
2757
- return A({ ...t3?.[1], query: t3?.[0] });
2767
+ return M({ ...t3?.[1], query: t3?.[0] });
2758
2768
  }, responseTransformer: ({ data: e6 }) => {
2759
- let t3 = j(N(e6, []));
2769
+ let t3 = N(F(e6, []));
2760
2770
  return { items: t3?.serviceOptionsAndVariantsList, pagingMetadata: t3?.pagingMetadata };
2761
2771
  }, errorTransformer: (e6) => {
2762
- throw P(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false });
2772
+ throw I(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false });
2763
2773
  }, pagingMethod: `CURSOR`, transformationPaths: {} });
2764
2774
  }
2765
- async function _o(e5) {
2766
- let { httpClient: t2, sideEffects: n2 } = arguments[1], r2 = ho(A({ query: e5 }));
2775
+ async function bo(e5) {
2776
+ let { httpClient: t2, sideEffects: n2 } = arguments[1], r2 = vo(M({ query: e5 }));
2767
2777
  n2?.onSiteCall?.();
2768
2778
  try {
2769
2779
  let e6 = await t2.request(r2);
2770
- return n2?.onSuccess?.(e6), j(e6.data);
2780
+ return n2?.onSuccess?.(e6), N(e6.data);
2771
2781
  } catch (e6) {
2772
- let t3 = P(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false }, [`query`]);
2782
+ let t3 = I(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false }, [`query`]);
2773
2783
  throw n2?.onError?.(e6), t3;
2774
2784
  }
2775
2785
  }
2776
- function vo(e5) {
2777
- return () => go({ httpClient: e5 });
2786
+ function xo(e5) {
2787
+ return () => yo({ httpClient: e5 });
2778
2788
  }
2779
- function yo(e5) {
2780
- return (t2) => _o(t2, { httpClient: e5 });
2789
+ function So(e5) {
2790
+ return (t2) => bo(t2, { httpClient: e5 });
2781
2791
  }
2782
- function bo(e5) {
2783
- let t2 = lo({ builderQueryFunction: () => vo(e5)(), typedQueryFunction: (t3) => yo(e5)(t3), hasOptionsParameter: false });
2792
+ function Co(e5) {
2793
+ let t2 = po({ builderQueryFunction: () => xo(e5)(), typedQueryFunction: (t3) => So(e5)(t3), hasOptionsParameter: false });
2784
2794
  function n2(e6) {
2785
2795
  return t2(...arguments);
2786
2796
  }
2787
2797
  return n2;
2788
2798
  }
2789
- var xo = Pt(bo);
2790
- function So(e5) {
2799
+ var wo = Mt(Co);
2800
+ function To(e5) {
2791
2801
  if (e5) return e5.url;
2792
2802
  }
2793
- var Co = [{ path: `services.createdDate` }, { path: `services.updatedDate` }, { path: `services.media.items.image.urlExpirationDate` }, { path: `services.media.mainMedia.image.urlExpirationDate` }, { path: `services.media.coverMedia.image.urlExpirationDate` }, { path: `services.payment.subscription.recurringStartDate` }, { path: `services.bookingPolicy.createdDate` }, { path: `services.bookingPolicy.updatedDate` }, { path: `services.schedule.firstSessionStart` }, { path: `services.schedule.lastSessionEnd` }, { path: `services.staffMembers.mainMedia.image.urlExpirationDate` }, { path: `services.staffMemberDetails.staffMembers.mainMedia.image.urlExpirationDate` }, { path: `services.supportedSlugs.createdDate` }, { path: `services.mainSlug.createdDate` }];
2794
- var wo = [{ path: `services.locations.business.address.geocode.latitude` }, { path: `services.locations.business.address.geocode.longitude` }, { path: `services.locations.custom.address.geocode.latitude` }, { path: `services.locations.custom.address.geocode.longitude` }, { path: `services.locations.calculatedAddress.geocode.latitude` }, { path: `services.locations.calculatedAddress.geocode.longitude` }];
2795
- function To(e5) {
2796
- return It(Object.assign(e5, { domainToMappings: { "*.dev.wix-code.com": [{ srcPath: `/_api/services-2`, destPath: `` }, { srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "www.wixapis.com": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/bookings/v2/bulk/services`, destPath: `/v2/bulk/services` }, { srcPath: `/bookings/services/v2/bulk/services`, destPath: `/v2/bulk/services` }], "manage._base_domain_": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/_api/bookings/v2/bulk/services`, destPath: `/v2/bulk/services` }], "editor._base_domain_": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/_api/bookings/v2/bulk/services`, destPath: `/v2/bulk/services` }], "blocks._base_domain_": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/_api/bookings/v2/bulk/services`, destPath: `/v2/bulk/services` }], "create.editorx": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/_api/bookings/v2/bulk/services`, destPath: `/v2/bulk/services` }], _: [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "www._base_domain_": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "bo._base_domain_": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "wixbo.ai": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "wix-bo.com": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "editor.wixapps.net": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "api._api_base_domain_": [{ srcPath: `/services-2`, destPath: `` }] } }));
2803
+ var Eo = [{ path: `services.createdDate` }, { path: `services.updatedDate` }, { path: `services.media.items.image.urlExpirationDate` }, { path: `services.media.mainMedia.image.urlExpirationDate` }, { path: `services.media.coverMedia.image.urlExpirationDate` }, { path: `services.payment.subscription.recurringStartDate` }, { path: `services.bookingPolicy.createdDate` }, { path: `services.bookingPolicy.updatedDate` }, { path: `services.schedule.firstSessionStart` }, { path: `services.schedule.lastSessionEnd` }, { path: `services.staffMembers.mainMedia.image.urlExpirationDate` }, { path: `services.staffMemberDetails.staffMembers.mainMedia.image.urlExpirationDate` }, { path: `services.supportedSlugs.createdDate` }, { path: `services.mainSlug.createdDate` }];
2804
+ var Do = [{ path: `services.locations.business.address.geocode.latitude` }, { path: `services.locations.business.address.geocode.longitude` }, { path: `services.locations.custom.address.geocode.latitude` }, { path: `services.locations.custom.address.geocode.longitude` }, { path: `services.locations.calculatedAddress.geocode.latitude` }, { path: `services.locations.calculatedAddress.geocode.longitude` }];
2805
+ function Oo(e5) {
2806
+ return Pt(Object.assign(e5, { domainToMappings: { "*.dev.wix-code.com": [{ srcPath: `/_api/services-2`, destPath: `` }, { srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "www.wixapis.com": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/bookings/v2/bulk/services`, destPath: `/v2/bulk/services` }, { srcPath: `/bookings/services/v2/bulk/services`, destPath: `/v2/bulk/services` }], "manage._base_domain_": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/_api/bookings/v2/bulk/services`, destPath: `/v2/bulk/services` }], "editor._base_domain_": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/_api/bookings/v2/bulk/services`, destPath: `/v2/bulk/services` }], "blocks._base_domain_": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/_api/bookings/v2/bulk/services`, destPath: `/v2/bulk/services` }], "create.editorx": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }, { srcPath: `/_api/bookings/v2/bulk/services`, destPath: `/v2/bulk/services` }], _: [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "www._base_domain_": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "bo._base_domain_": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "wixbo.ai": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "wix-bo.com": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "editor.wixapps.net": [{ srcPath: `/_api/bookings/v2/services`, destPath: `/v2/services` }], "api._api_base_domain_": [{ srcPath: `/services-2`, destPath: `` }] } }));
2797
2807
  }
2798
- var Eo = `@wix/auto_sdk_bookings_services`;
2799
- function Do(e5) {
2808
+ var ko = `@wix/auto_sdk_bookings_services`;
2809
+ function Ao(e5) {
2800
2810
  function t2({ host: t3 }) {
2801
- return { entityFqdn: `wix.bookings.services.v2.service`, method: `POST`, methodFqn: `wix.bookings.services.v2.ServicesService.QueryServices`, packageName: Eo, migrationOptions: { optInTransformResponse: true }, url: To({ protoPath: `/v2/services/query`, data: e5, host: t3 }), data: e5, transformResponse: (e6) => N(e6, [{ transformFn: M, paths: Co }, { transformFn: un, paths: wo }]) };
2811
+ return { entityFqdn: `wix.bookings.services.v2.service`, method: `POST`, methodFqn: `wix.bookings.services.v2.ServicesService.QueryServices`, packageName: ko, migrationOptions: { optInTransformResponse: true }, url: Oo({ protoPath: `/v2/services/query`, data: e5, host: t3 }), data: e5, transformResponse: (e6) => F(e6, [{ transformFn: P, paths: Eo }, { transformFn: cn, paths: Do }]) };
2802
2812
  }
2803
2813
  return t2;
2804
2814
  }
2805
- var Oo = [{ path: `services.media.items.image` }, { path: `services.media.mainMedia.image` }, { path: `services.media.coverMedia.image` }, { path: `services.staffMembers.mainMedia.image` }, { path: `services.staffMemberDetails.staffMembers.mainMedia.image` }];
2806
- var ko = [{ path: `services.locations.calculatedAddress` }, { path: `services.locations.business.address` }, { path: `services.locations.custom.address` }];
2807
- var Ao = [{ path: `services.urls.servicePage` }, { path: `services.urls.bookingPage` }, { path: `services.urls.calendarPage` }];
2808
- var jo = ((e5) => (e5.APPOINTMENT = `APPOINTMENT`, e5.CLASS = `CLASS`, e5.COURSE = `COURSE`, e5))(jo || {});
2809
- var Mo = ((e5) => (e5.FIXED = `FIXED`, e5.CUSTOM = `CUSTOM`, e5.VARIED = `VARIED`, e5.NO_FEE = `NO_FEE`, e5.SUBSCRIPTION = `SUBSCRIPTION`, e5))(Mo || {});
2810
- var No = ((e5) => (e5.CUSTOM = `CUSTOM`, e5.BUSINESS = `BUSINESS`, e5.CUSTOMER = `CUSTOMER`, e5))(No || {});
2811
- function Po(e5) {
2815
+ var jo = [{ path: `services.media.items.image` }, { path: `services.media.mainMedia.image` }, { path: `services.media.coverMedia.image` }, { path: `services.staffMembers.mainMedia.image` }, { path: `services.staffMemberDetails.staffMembers.mainMedia.image` }];
2816
+ var Mo = [{ path: `services.locations.calculatedAddress` }, { path: `services.locations.business.address` }, { path: `services.locations.custom.address` }];
2817
+ var No = [{ path: `services.urls.servicePage` }, { path: `services.urls.bookingPage` }, { path: `services.urls.calendarPage` }];
2818
+ var Po = ((e5) => (e5.APPOINTMENT = `APPOINTMENT`, e5.CLASS = `CLASS`, e5.COURSE = `COURSE`, e5))(Po || {});
2819
+ var Fo = ((e5) => (e5.FIXED = `FIXED`, e5.CUSTOM = `CUSTOM`, e5.VARIED = `VARIED`, e5.NO_FEE = `NO_FEE`, e5.SUBSCRIPTION = `SUBSCRIPTION`, e5))(Fo || {});
2820
+ var Io = ((e5) => (e5.CUSTOM = `CUSTOM`, e5.BUSINESS = `BUSINESS`, e5.CUSTOMER = `CUSTOMER`, e5))(Io || {});
2821
+ function Lo(e5) {
2812
2822
  let { httpClient: t2, sideEffects: n2 } = arguments[1];
2813
- return Ja({ func: async (r2) => {
2814
- let i2 = Do({ ...r2, ...e5 ?? {} });
2823
+ return Za({ func: async (r2) => {
2824
+ let i2 = Ao({ ...r2, ...e5 ?? {} });
2815
2825
  n2?.onSiteCall?.();
2816
2826
  try {
2817
2827
  let e6 = await t2.request(i2);
@@ -2821,146 +2831,146 @@ function Po(e5) {
2821
2831
  }
2822
2832
  }, requestTransformer: (t3) => {
2823
2833
  let n3 = [t3, e5];
2824
- return A({ ...n3?.[1], query: n3?.[0] });
2834
+ return M({ ...n3?.[1], query: n3?.[0] });
2825
2835
  }, responseTransformer: ({ data: e6 }) => {
2826
- let t3 = j(N(e6, [{ transformFn: za, paths: Oo }, { transformFn: dn, paths: ko }, { transformFn: So, paths: Ao }]));
2836
+ let t3 = N(F(e6, [{ transformFn: Ha, paths: jo }, { transformFn: ln, paths: Mo }, { transformFn: To, paths: No }]));
2827
2837
  return { items: t3?.services, pagingMetadata: t3?.pagingMetadata };
2828
2838
  }, errorTransformer: (e6) => {
2829
- throw P(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false });
2839
+ throw I(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false });
2830
2840
  }, pagingMethod: `OFFSET`, transformationPaths: {} });
2831
2841
  }
2832
- async function Fo(e5, t2) {
2833
- let { httpClient: n2, sideEffects: r2 } = arguments[2], i2 = Do(A({ query: e5, ...t2 }));
2842
+ async function Ro(e5, t2) {
2843
+ let { httpClient: n2, sideEffects: r2 } = arguments[2], i2 = Ao(M({ query: e5, ...t2 }));
2834
2844
  r2?.onSiteCall?.();
2835
2845
  try {
2836
2846
  let e6 = await n2.request(i2);
2837
- return r2?.onSuccess?.(e6), j(N(e6.data, [{ transformFn: za, paths: Oo }, { transformFn: dn, paths: ko }, { transformFn: So, paths: Ao }]));
2847
+ return r2?.onSuccess?.(e6), N(F(e6.data, [{ transformFn: Ha, paths: jo }, { transformFn: ln, paths: Mo }, { transformFn: To, paths: No }]));
2838
2848
  } catch (e6) {
2839
- let t3 = P(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false }, [`query`, `options`]);
2849
+ let t3 = I(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false }, [`query`, `options`]);
2840
2850
  throw r2?.onError?.(e6), t3;
2841
2851
  }
2842
2852
  }
2843
- function Io(e5) {
2844
- return (t2) => Po(t2, { httpClient: e5 });
2853
+ function zo(e5) {
2854
+ return (t2) => Lo(t2, { httpClient: e5 });
2845
2855
  }
2846
- function Lo(e5) {
2847
- return (t2, n2) => Fo(t2, n2, { httpClient: e5 });
2856
+ function Bo(e5) {
2857
+ return (t2, n2) => Ro(t2, n2, { httpClient: e5 });
2848
2858
  }
2849
- function Ro(e5) {
2850
- let t2 = lo({ builderQueryFunction: (t3) => Io(e5)(t3), typedQueryFunction: (t3, n3) => Lo(e5)(t3, n3), hasOptionsParameter: true });
2859
+ function Vo(e5) {
2860
+ let t2 = po({ builderQueryFunction: (t3) => zo(e5)(t3), typedQueryFunction: (t3, n3) => Bo(e5)(t3, n3), hasOptionsParameter: true });
2851
2861
  function n2(e6, n3) {
2852
2862
  return t2(...arguments);
2853
2863
  }
2854
2864
  return n2;
2855
2865
  }
2856
- var zo = Pt(Ro);
2857
- var Bo = [{ path: `bookingsSettings.createdDate` }, { path: `bookingsSettings.updatedDate` }];
2858
- var Vo = [{ path: `bookingsSettings.siteProperties.address.coordinates.latitude` }, { path: `bookingsSettings.siteProperties.address.coordinates.longitude` }];
2859
- function Ho(e5) {
2860
- return It(Object.assign(e5, { domainToMappings: { "manage._base_domain_": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "dev._base_domain_": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "*.dev.wix-code.com": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "www.wixapis.com": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], _: [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "api._api_base_domain_": [{ srcPath: `/bookings-settings`, destPath: `` }], "editor._base_domain_": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "blocks._base_domain_": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "create.editorx": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "editor.wixapps.net": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "www._base_domain_": [{ srcPath: `/_api/bookings-settings`, destPath: `` }] } }));
2866
+ var Ho = Mt(Vo);
2867
+ var Uo = [{ path: `bookingsSettings.createdDate` }, { path: `bookingsSettings.updatedDate` }];
2868
+ var Wo = [{ path: `bookingsSettings.siteProperties.address.coordinates.latitude` }, { path: `bookingsSettings.siteProperties.address.coordinates.longitude` }];
2869
+ function Go(e5) {
2870
+ return Pt(Object.assign(e5, { domainToMappings: { "manage._base_domain_": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "dev._base_domain_": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "*.dev.wix-code.com": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "www.wixapis.com": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], _: [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "api._api_base_domain_": [{ srcPath: `/bookings-settings`, destPath: `` }], "editor._base_domain_": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "blocks._base_domain_": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "create.editorx": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "editor.wixapps.net": [{ srcPath: `/_api/bookings-settings`, destPath: `` }], "www._base_domain_": [{ srcPath: `/_api/bookings-settings`, destPath: `` }] } }));
2861
2871
  }
2862
- var Uo = `@wix/auto_sdk_bookings_bookings-settings`;
2863
- function Wo(e5) {
2872
+ var Ko = `@wix/auto_sdk_bookings_bookings-settings`;
2873
+ function qo(e5) {
2864
2874
  function t2({ host: t3 }) {
2865
- return { entityFqdn: `wix.bookings.v2.bookings_settings`, method: `GET`, methodFqn: `wix.bookings.settings.v2.BookingsSettingsService.GetBookingsSettings`, packageName: Uo, migrationOptions: { optInTransformResponse: true }, url: Ho({ protoPath: `/v2/settings`, data: e5, host: t3 }), params: Ft(e5), transformResponse: (e6) => N(e6, [{ transformFn: M, paths: Bo }, { transformFn: un, paths: Vo }]), fallback: [{ method: `GET`, url: Ho({ protoPath: `/v2/settings`, data: e5, host: t3 }), params: Ft(e5) }] };
2875
+ return { entityFqdn: `wix.bookings.v2.bookings_settings`, method: `GET`, methodFqn: `wix.bookings.settings.v2.BookingsSettingsService.GetBookingsSettings`, packageName: Ko, migrationOptions: { optInTransformResponse: true }, url: Go({ protoPath: `/v2/settings`, data: e5, host: t3 }), params: Nt(e5), transformResponse: (e6) => F(e6, [{ transformFn: P, paths: Uo }, { transformFn: cn, paths: Wo }]), fallback: [{ method: `GET`, url: Go({ protoPath: `/v2/settings`, data: e5, host: t3 }), params: Nt(e5) }] };
2866
2876
  }
2867
2877
  return t2;
2868
2878
  }
2869
- var Go = ((e5) => (e5.BUSINESS_TIME_ZONE = `BUSINESS_TIME_ZONE`, e5.CUSTOMER_TIME_ZONE = `CUSTOMER_TIME_ZONE`, e5))(Go || {});
2870
- async function Ko() {
2871
- let { httpClient: e5, sideEffects: t2 } = arguments[0], n2 = Wo(A({}));
2879
+ var Jo = ((e5) => (e5.BUSINESS_TIME_ZONE = `BUSINESS_TIME_ZONE`, e5.CUSTOMER_TIME_ZONE = `CUSTOMER_TIME_ZONE`, e5))(Jo || {});
2880
+ async function Yo() {
2881
+ let { httpClient: e5, sideEffects: t2 } = arguments[0], n2 = qo(M({}));
2872
2882
  t2?.onSiteCall?.();
2873
2883
  try {
2874
2884
  let r2 = await e5.request(n2);
2875
- return t2?.onSuccess?.(r2), j(r2.data)?.bookingsSettings;
2885
+ return t2?.onSuccess?.(r2), N(r2.data)?.bookingsSettings;
2876
2886
  } catch (e6) {
2877
- let n3 = P(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: {}, singleArgumentUnchanged: false }, []);
2887
+ let n3 = I(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: {}, singleArgumentUnchanged: false }, []);
2878
2888
  throw t2?.onError?.(e6), n3;
2879
2889
  }
2880
2890
  }
2881
- function qo(e5) {
2882
- return () => Ko({ httpClient: e5 });
2891
+ function Xo(e5) {
2892
+ return () => Yo({ httpClient: e5 });
2883
2893
  }
2884
- var Jo = Pt(qo);
2885
- var Yo = (e5) => e5 === jo.APPOINTMENT;
2886
- var Xo = (e5) => e5.payment?.rateType === Mo.VARIED;
2887
- var Zo = [`STAFF_MEMBER_DETAILS`, `STAFF_WORKING_HOURS_LOCATIONS`, `DISCOUNT_INFO_DETAILS`];
2888
- function Qo() {
2889
- return zo({ conditionalFields: Zo }).eq(`appId`, Ni).eq(`hidden`, false);
2894
+ var Zo = Mt(Xo);
2895
+ var Qo = (e5) => e5 === Po.APPOINTMENT;
2896
+ var $o = (e5) => e5.payment?.rateType === Fo.VARIED;
2897
+ var es = [`STAFF_MEMBER_DETAILS`, `STAFF_WORKING_HOURS_LOCATIONS`, `DISCOUNT_INFO_DETAILS`];
2898
+ function ts() {
2899
+ return Ho({ conditionalFields: es }).eq(`appId`, Fi).eq(`hidden`, false);
2890
2900
  }
2891
- async function $o({ limit: e5, offset: t2, categoryId: n2, locationId: r2, serviceIds: i2, categoryIds: a2 }) {
2901
+ async function ns({ limit: e5, offset: t2, categoryId: n2, locationId: r2, serviceIds: i2, categoryIds: a2 }) {
2892
2902
  if (n2 && a2?.length && !a2.includes(n2)) return { services: [], hasMore: false, totalPages: 1 };
2893
- let o2 = Qo().limit(e5).skip(t2);
2894
- i2?.length && (o2 = o2.in(`_id`, i2)), n2 ? o2 = o2.eq(`category.id`, n2) : a2?.length && (o2 = o2.in(`category.id`, a2)), r2 === `OTHER_LOCATIONS` ? o2 = o2.hasSome(`locations.type`, [No.CUSTOM, No.CUSTOMER]) : r2 && (o2 = o2.eq(`locations.business.id`, r2));
2903
+ let o2 = ts().limit(e5).skip(t2);
2904
+ i2?.length && (o2 = o2.in(`_id`, i2)), n2 ? o2 = o2.eq(`category.id`, n2) : a2?.length && (o2 = o2.in(`category.id`, a2)), r2 === `OTHER_LOCATIONS` ? o2 = o2.hasSome(`locations.type`, [Io.CUSTOM, Io.CUSTOMER]) : r2 && (o2 = o2.eq(`locations.business.id`, r2));
2895
2905
  let s2 = await o2.find();
2896
2906
  return { services: s2.items ?? [], hasMore: s2.hasNext(), totalPages: s2.totalPages ?? 1 };
2897
2907
  }
2898
- var es = { category: `category`, location: `location`, page: `page`, blob: `b`, resource: `resource`, referral: `referral`, timezone: `timezone`, bookingId: `bookingId`, token: `token`, rescheduleRedirectUrl: `rescheduleRedirectUrl` };
2899
- function ts(e5, t2) {
2908
+ var rs = { category: `category`, location: `location`, page: `page`, blob: `bookingSelection`, legacyBlob: `b`, resource: `resource`, referral: `referral`, timezone: `timezone`, bookingId: `bookingId`, token: `token`, rescheduleRedirectUrl: `rescheduleRedirectUrl` };
2909
+ function is(e5, t2) {
2900
2910
  let n2 = e5(t2);
2901
2911
  return n2 ? n2.replace(/\/$/, ``) || `/` : null;
2902
2912
  }
2903
- function ns(e5, t2, n2) {
2913
+ function as(e5, t2, n2) {
2904
2914
  let r2 = e5(t2);
2905
2915
  return !r2 || !n2 ? null : `${r2.replace(/\/$/, ``)}/${n2}`;
2906
2916
  }
2907
- function rs(e5, t2) {
2917
+ function os(e5, t2) {
2908
2918
  switch (e5) {
2909
2919
  case `servicePage`:
2910
- return (t2.slug ? t2.buildCustomServiceUrl(t2.slug) : void 0) ?? ns(t2.appSectionUrl, W.SERVICE_PAGE, t2.slug);
2920
+ return (t2.slug ? t2.buildCustomServiceUrl(t2.slug) : void 0) ?? as(t2.appSectionUrl, G.SERVICE_PAGE, t2.slug);
2911
2921
  case `bookingCalendar`:
2912
- return t2.isMultiService ? ts(t2.appSectionUrl, W.CALENDAR_PAGE) : ns(t2.appSectionUrl, W.CALENDAR_PAGE, t2.slug);
2922
+ return t2.isMultiService ? is(t2.appSectionUrl, G.CALENDAR_PAGE) : as(t2.appSectionUrl, G.CALENDAR_PAGE, t2.slug);
2913
2923
  case `bookingForm`:
2914
- return t2.serviceId ? ns(t2.appSectionUrl, W.FORM_PAGE, t2.slug) : null;
2924
+ return t2.serviceId ? as(t2.appSectionUrl, G.FORM_PAGE, t2.slug) : null;
2915
2925
  default:
2916
2926
  return null;
2917
2927
  }
2918
2928
  }
2919
- var is = (e5) => e5.target === `_blank`;
2920
- var as = (e5, t2) => t2 === `/` ? e5 : new URL(`.${t2}`, `${e5}/`).href;
2921
- var os = (e5, t2, n2) => n2 ? `.${t2}` : ss(e5, t2);
2922
- var ss = (e5, t2) => e5 ? as(e5, t2) : t2;
2923
- var cs = () => {
2924
- let { previewMode: e5 } = (0, import_services_manager_react.useService)(ki), t2 = (0, import_services_manager_react.useService)(vi), n2 = t2.siteUrl.replace(/\/$/, ``), { navigateTo: r2 } = (0, import_services_manager_react.useService)(ji), a2 = (0, import_services_manager_react.useService)(Mi), o2 = (0, import_services_manager_react.useGetService)(), s2 = (0, import_react.useCallback)(async (t3) => {
2925
- let i2 = os(n2, t3, e5);
2929
+ var ss = (e5) => e5.target === `_blank`;
2930
+ var cs = (e5, t2) => t2 === `/` ? e5 : new URL(`.${t2}`, `${e5}/`).href;
2931
+ var ls = (e5, t2, n2) => n2 ? `.${t2}` : us(e5, t2);
2932
+ var us = (e5, t2) => e5 ? cs(e5, t2) : t2;
2933
+ var ds = () => {
2934
+ let { previewMode: e5 } = (0, import_services_manager_react.useService)(ji), t2 = (0, import_services_manager_react.useService)(bi), n2 = t2.siteUrl.replace(/\/$/, ``), { navigateTo: r2 } = (0, import_services_manager_react.useService)(Ni), a2 = (0, import_services_manager_react.useService)(Pi), o2 = (0, import_services_manager_react.useGetService)(), s2 = (0, import_react.useCallback)(async (t3) => {
2935
+ let i2 = ls(n2, t3, e5);
2926
2936
  await r2({ href: i2 });
2927
2937
  }, [e5, n2, r2]), c2 = (0, import_react.useCallback)(async (e6) => {
2928
- await r2(is(e6) ? { href: e6.href, type: `ExternalLink`, target: `_blank` } : { href: e6.href });
2929
- }, [r2]), l2 = (0, import_react.useCallback)((e6) => ss(n2, e6), [n2]), u2 = (0, import_react.useCallback)((e6) => t2.appSectionRelativeUrl(Ni, e6), [t2]), d2 = (0, import_react.useCallback)((e6) => Ra(a2.urlMappings, e6), [a2]), m2 = (0, import_react.useCallback)((e6, t3) => rs(e6, { ...t3, appSectionUrl: u2, buildCustomServiceUrl: d2 }), [u2, d2]), h2 = (0, import_react.useCallback)((e6, t3) => {
2938
+ await r2(ss(e6) ? { href: e6.href, type: `ExternalLink`, target: `_blank` } : { href: e6.href });
2939
+ }, [r2]), l2 = (0, import_react.useCallback)((e6) => us(n2, e6), [n2]), u2 = (0, import_react.useCallback)((e6) => t2.appSectionRelativeUrl(Fi, e6), [t2]), d2 = (0, import_react.useCallback)((e6) => Va(a2.urlMappings, e6), [a2]), m2 = (0, import_react.useCallback)((e6, t3) => os(e6, { ...t3, appSectionUrl: u2, buildCustomServiceUrl: d2 }), [u2, d2]), h2 = (0, import_react.useCallback)((e6, t3) => {
2930
2940
  let r3 = m2(e6, t3);
2931
- return r3 && n2 ? as(n2, r3) : null;
2941
+ return r3 && n2 ? cs(n2, r3) : null;
2932
2942
  }, [m2, n2]), g2 = (0, import_react.useCallback)((e6, t3) => {
2933
2943
  let n3 = m2(e6, t3);
2934
2944
  n3 && s2(n3);
2935
- }, [m2, s2]), _2 = (0, import_react.useCallback)(() => u2(W.FORM_PAGE) || void 0, [u2]), v2 = (0, import_react.useCallback)((e6) => Object.values(o2(Ai).pages).some((t3) => t3.appPageId === e6 && (!t3.appDefinitionId || t3.appDefinitionId === `1380b703-ce81-ff05-f115-39571d94dfcd`)) && t2.appSectionRelativeUrl(`1380b703-ce81-ff05-f115-39571d94dfcd`, e6) || void 0, [t2, o2]);
2936
- return { navigate: s2, navigateToHref: c2, resolvePath: m2, toHref: l2, resolveAbsoluteUrl: h2, navigateTo: g2, getBookingFormPath: _2, getCartPagePath: (0, import_react.useCallback)(() => v2(Pi), [v2]), getThankYouPagePath: (0, import_react.useCallback)((e6) => {
2937
- let t3 = v2(Fi);
2945
+ }, [m2, s2]), _2 = (0, import_react.useCallback)(() => u2(G.FORM_PAGE) || void 0, [u2]), v2 = (0, import_react.useCallback)((e6) => Object.values(o2(Mi).pages).some((t3) => t3.appPageId === e6 && (!t3.appDefinitionId || t3.appDefinitionId === `1380b703-ce81-ff05-f115-39571d94dfcd`)) && t2.appSectionRelativeUrl(`1380b703-ce81-ff05-f115-39571d94dfcd`, e6) || void 0, [t2, o2]);
2946
+ return { navigate: s2, navigateToHref: c2, resolvePath: m2, toHref: l2, resolveAbsoluteUrl: h2, navigateTo: g2, getBookingFormPath: _2, getCartPagePath: (0, import_react.useCallback)(() => v2(Ii), [v2]), getThankYouPagePath: (0, import_react.useCallback)((e6) => {
2947
+ let t3 = v2(Li);
2938
2948
  return t3 ? `${t3}/${e6}?origin=bookings` : void 0;
2939
2949
  }, [v2]) };
2940
2950
  };
2941
- var ls = U(`@wix/site-service-warmup-data`);
2942
- function us() {
2951
+ var fs = W(`@wix/site-service-warmup-data`);
2952
+ function ps() {
2943
2953
  try {
2944
2954
  return (0, import_services_manager_react.useGetService)();
2945
2955
  } catch {
2946
2956
  return null;
2947
2957
  }
2948
2958
  }
2949
- function ds(e5) {
2959
+ function ms(e5) {
2950
2960
  try {
2951
- return e5 ? e5(ls) : null;
2961
+ return e5 ? e5(fs) : null;
2952
2962
  } catch {
2953
2963
  return null;
2954
2964
  }
2955
2965
  }
2956
- function fs() {
2957
- let e5 = ds(us()), t2 = typeof window > `u`;
2966
+ function hs() {
2967
+ let e5 = ms(ps()), t2 = typeof window > `u`;
2958
2968
  return { scope: e5 ?? void 0, get: async (n2) => {
2959
2969
  if (t2 || !e5) return null;
2960
2970
  try {
2961
2971
  return await e5.get(n2);
2962
2972
  } catch (e6) {
2963
- return H(e6, { feature: V.warmup, action: `read`, level: `warning`, contexts: { warmup: { key: n2 } } }), null;
2973
+ return fi(e6, { feature: U.warmup, action: `read`, level: `warning`, contexts: { warmup: { key: n2 } } }), null;
2964
2974
  }
2965
2975
  }, set: (n2, r2) => {
2966
2976
  if (t2 && e5) try {
@@ -2969,82 +2979,118 @@ function fs() {
2969
2979
  }
2970
2980
  } };
2971
2981
  }
2972
- var ps = U(`@wix/site-service-locale`);
2973
- var ms = U;
2974
- var hs = ms(`@wix/viewer-service-multilingual`);
2975
- function gs() {
2982
+ var gs = W(`@wix/site-service-locale`);
2983
+ var _s = W;
2984
+ var vs = _s(`@wix/viewer-service-multilingual`);
2985
+ function ys() {
2976
2986
  try {
2977
2987
  return si.getLanguage() ?? `en`;
2978
2988
  } catch {
2979
2989
  return `en`;
2980
2990
  }
2981
2991
  }
2982
- function _s(e5) {
2992
+ function bs(e5) {
2983
2993
  try {
2984
2994
  return (0, import_services_manager_react.useService)(e5);
2985
2995
  } catch {
2986
2996
  return null;
2987
2997
  }
2988
2998
  }
2989
- function vs() {
2990
- let e5 = _s(ps), t2 = _s(hs);
2991
- return t2?.multilingualEnabled && t2.currentLocale?.languageCode || e5?.language || gs();
2999
+ function xs() {
3000
+ let e5 = bs(gs), t2 = bs(vs);
3001
+ return t2?.multilingualEnabled && t2.currentLocale?.languageCode || e5?.language || ys();
2992
3002
  }
2993
- var ys = `bookings-uou`;
2994
- function bs(e5, t2, n2, r2, i2, a2 = [], o2 = []) {
2995
- let s2 = a2.length ? `:ids-${encodeURIComponent(JSON.stringify([...a2].sort()))}` : ``, c2 = o2.length ? `:cats-${encodeURIComponent(JSON.stringify([...o2].sort()))}` : ``;
2996
- return `${ys}:${e5}:services:${t2 ?? `all`}:${n2 ?? `all`}:page-${r2}:limit-${i2}${s2}${c2}`;
3003
+ function Ss() {
3004
+ return (0, import_services_manager_react.useService)(Pi).currency;
2997
3005
  }
2998
- function xs(e5, t2, n2) {
2999
- return `${ys}:${e5}:services-variants:ids-${encodeURIComponent(JSON.stringify([...t2].sort()))}:refresh-${n2}`;
3006
+ function Cs() {
3007
+ return globalThis.commonConfig?.currency;
3000
3008
  }
3001
- function Ss() {
3002
- return `${ys}:bookings-settings`;
3009
+ function ws(e5) {
3010
+ let t2 = globalThis.window;
3011
+ if (!t2) return () => {
3012
+ };
3013
+ let n2 = t2.navigation, r2 = true, i2 = () => queueMicrotask(() => {
3014
+ r2 && e5();
3015
+ });
3016
+ return n2?.addEventListener(`currententrychange`, i2), t2.addEventListener(`popstate`, e5), () => {
3017
+ r2 = false, n2?.removeEventListener(`currententrychange`, i2), t2.removeEventListener(`popstate`, e5);
3018
+ };
3019
+ }
3020
+ var Ts = /^[A-Z]{3}$/;
3021
+ function Es(e5) {
3022
+ return Ts.test(e5) ? typeof Intl.supportedValuesOf != `function` || Intl.supportedValuesOf(`currency`).includes(e5) : false;
3003
3023
  }
3004
- var Cs = 5e3;
3005
- var ws = 100;
3006
- var Ts = `wix-warmup-data`;
3007
- var Es = null;
3008
3024
  function Ds(e5) {
3025
+ let t2 = e5?.toUpperCase();
3026
+ return t2 && Es(t2) ? t2 : null;
3027
+ }
3028
+ function Os(e5, t2) {
3029
+ let n2 = Ds(e5);
3030
+ return n2 && n2 !== Ds(t2) ? n2 : null;
3031
+ }
3032
+ function ks() {
3033
+ let e5 = (0, import_react.useSyncExternalStore)(ws, Cs, Cs), t2 = Ss();
3034
+ return (0, import_react.useDeferredValue)(Os(e5, t2));
3035
+ }
3036
+ var As = `bookings-uou`;
3037
+ function js(e5) {
3038
+ return e5 ? `:currency-${e5}` : ``;
3039
+ }
3040
+ function Ms(e5, t2, n2, r2, i2, a2, o2 = [], s2 = []) {
3041
+ let c2 = o2.length ? `:ids-${encodeURIComponent(JSON.stringify([...o2].sort()))}` : ``, l2 = s2.length ? `:cats-${encodeURIComponent(JSON.stringify([...s2].sort()))}` : ``;
3042
+ return `${As}:${e5}:services:${n2 ?? `all`}:${r2 ?? `all`}:page-${i2}:limit-${a2}${c2}${l2}${js(t2)}`;
3043
+ }
3044
+ function Ns(e5, t2, n2, r2) {
3045
+ return `${As}:${e5}:services-variants:ids-${encodeURIComponent(JSON.stringify([...n2].sort()))}:refresh-${r2}${js(t2)}`;
3046
+ }
3047
+ function Ps() {
3048
+ return `${As}:bookings-settings`;
3049
+ }
3050
+ var Fs = 5e3;
3051
+ var Is = 100;
3052
+ var Ls = `wix-warmup-data`;
3053
+ var Rs = null;
3054
+ function zs(e5) {
3009
3055
  if (typeof document < `u`) try {
3010
- let t2 = document.getElementById(Ts)?.textContent;
3011
- return t2 ? (Es?.text !== t2 && (Es = { text: t2, data: JSON.parse(t2).builderComponentsWarmupData ?? {} }), Es.data[e5] ?? void 0) : void 0;
3056
+ let t2 = document.getElementById(Ls)?.textContent;
3057
+ return t2 ? (Rs?.text !== t2 && (Rs = { text: t2, data: JSON.parse(t2).builderComponentsWarmupData ?? {} }), Rs.data[e5] ?? void 0) : void 0;
3012
3058
  } catch {
3013
3059
  return;
3014
3060
  }
3015
3061
  }
3016
- var Os = () => ({ promises: /* @__PURE__ */ new Map(), invalidatedWarmup: /* @__PURE__ */ new Set() });
3017
- var ks = Os();
3018
- var As = /* @__PURE__ */ new WeakMap();
3019
- var js = /* @__PURE__ */ new WeakMap();
3020
- function Ms(e5) {
3021
- if (!e5) return ks;
3022
- let t2 = As.get(e5);
3023
- return t2 || (t2 = Os(), As.set(e5, t2)), t2;
3062
+ var Bs = () => ({ promises: /* @__PURE__ */ new Map(), invalidatedWarmup: /* @__PURE__ */ new Set() });
3063
+ var Vs = Bs();
3064
+ var Hs = /* @__PURE__ */ new WeakMap();
3065
+ var Us = /* @__PURE__ */ new WeakMap();
3066
+ function Ws(e5) {
3067
+ if (!e5) return Vs;
3068
+ let t2 = Hs.get(e5);
3069
+ return t2 || (t2 = Bs(), Hs.set(e5, t2)), t2;
3024
3070
  }
3025
- function Ns({ key: e5, warmupData: t2, fetchData: n2, refresh: r2 = false }) {
3071
+ function Gs({ key: e5, warmupData: t2, fetchData: n2, refresh: r2 = false }) {
3026
3072
  if (e5 === null) return n2();
3027
3073
  if (typeof window > `u`) {
3028
3074
  let r3 = () => n2().then((n3) => (t2.set(e5, n3), n3)), { scope: i3 } = t2;
3029
3075
  if (!i3) return r3();
3030
- let a3 = js.get(i3);
3031
- a3 || (a3 = /* @__PURE__ */ new Map(), js.set(i3, a3));
3076
+ let a3 = Us.get(i3);
3077
+ a3 || (a3 = /* @__PURE__ */ new Map(), Us.set(i3, a3));
3032
3078
  let o3 = a3.get(e5);
3033
3079
  if (o3) return o3;
3034
3080
  let s3 = r3();
3035
3081
  return a3.set(e5, s3), s3.catch(() => a3.delete(e5)), s3;
3036
3082
  }
3037
- let i2 = Ms(t2.scope), a2 = Date.now();
3083
+ let i2 = Ws(t2.scope), a2 = Date.now();
3038
3084
  for (let [e6, t3] of i2.promises) t3.expiresAt <= a2 && i2.promises.delete(e6);
3039
3085
  let o2 = i2.promises.get(e5);
3040
3086
  if (o2 && !r2) return o2.promise;
3041
3087
  r2 && i2.invalidatedWarmup.add(e5);
3042
3088
  let s2 = !i2.invalidatedWarmup.has(e5);
3043
3089
  if (s2) {
3044
- let t3 = Ds(e5);
3090
+ let t3 = zs(e5);
3045
3091
  if (t3 !== void 0) {
3046
- let n3 = hi(t3);
3047
- return i2.promises.set(e5, { promise: n3, expiresAt: a2 + Cs }), n3;
3092
+ let n3 = _i(t3);
3093
+ return i2.promises.set(e5, { promise: n3, expiresAt: a2 + Fs }), n3;
3048
3094
  }
3049
3095
  }
3050
3096
  let c2 = (async () => {
@@ -3054,62 +3100,62 @@ function Ns({ key: e5, warmupData: t2, fetchData: n2, refresh: r2 = false }) {
3054
3100
  }
3055
3101
  return n2();
3056
3102
  })();
3057
- i2.promises.size >= ws && i2.promises.delete(i2.promises.keys().next().value);
3103
+ i2.promises.size >= Is && i2.promises.delete(i2.promises.keys().next().value);
3058
3104
  let l2 = { promise: c2, expiresAt: 1 / 0 };
3059
3105
  return i2.promises.set(e5, l2), c2.then(() => {
3060
- l2.expiresAt = Date.now() + Cs;
3106
+ l2.expiresAt = Date.now() + Fs;
3061
3107
  }, () => {
3062
3108
  i2.promises.get(e5) === l2 && i2.promises.delete(e5);
3063
3109
  }), c2;
3064
3110
  }
3065
- var Ps = 100;
3066
- async function Fs(e5) {
3111
+ var Ks = 100;
3112
+ async function qs(e5) {
3067
3113
  if (e5.length === 0) return {};
3068
3114
  let t2 = [];
3069
- for (let n3 = 0; n3 < e5.length; n3 += Ps) t2.push(e5.slice(n3, n3 + Ps));
3070
- let n2 = await Promise.all(t2.map((e6) => xo().in(`serviceId`, e6).limit(Ps).find())), r2 = {};
3115
+ for (let n3 = 0; n3 < e5.length; n3 += Ks) t2.push(e5.slice(n3, n3 + Ks));
3116
+ let n2 = await Promise.all(t2.map((e6) => wo().in(`serviceId`, e6).limit(Ks).find())), r2 = {};
3071
3117
  for (let e6 of n2.flatMap((e7) => e7.items ?? [])) e6.serviceId && (r2[e6.serviceId] = e6);
3072
3118
  return r2;
3073
3119
  }
3074
- var Is = U(`@wix/site-service-rendering-context`);
3075
- var Ls = () => {
3076
- let { SSR: e5 } = (0, import_services_manager_react.useService)(Is);
3120
+ var Js = W(`@wix/site-service-rendering-context`);
3121
+ var Ys = () => {
3122
+ let { SSR: e5 } = (0, import_services_manager_react.useService)(Js);
3077
3123
  return { isSSR: () => e5 };
3078
3124
  };
3079
- var Rs = ms(`@wix/site-service-business-logger`);
3080
- function zs(e5) {
3125
+ var Xs = _s(`@wix/site-service-business-logger`);
3126
+ function Zs(e5) {
3081
3127
  return { evid: 1222, src: 16, endpoint: ``, params: e5 };
3082
3128
  }
3083
- function Bs(e5) {
3129
+ function Qs(e5) {
3084
3130
  return { evid: 32, src: 16, endpoint: ``, params: e5 };
3085
3131
  }
3086
- var Vs = { SERVICES: `services_context`, SERVICE: `service_context`, TIME_SLOTS: `time_slots_context`, BOOKING_CHECKOUT: `booking_checkout_context`, CATEGORIES: `categories_context`, LOCATIONS: `locations_context`, SERVICE_ADD_ONS: `service_addons_context`, PREFERENCES: `preferences_context` };
3087
- var Hs = W.BOOK_ONLINE;
3088
- var Us = `new_bookings_server`;
3089
- var Ws = `load more`;
3090
- var Gs = (e5) => {
3091
- let { reportBi: t2 } = (0, import_services_manager_react.useService)(Rs);
3132
+ var $s = { SERVICES: `services_context`, SERVICE: `service_context`, TIME_SLOTS: `time_slots_context`, BOOKING_CHECKOUT: `booking_checkout_context`, CATEGORIES: `categories_context`, LOCATIONS: `locations_context`, SERVICE_ADD_ONS: `service_addons_context`, PREFERENCES: `preferences_context` };
3133
+ var ec = G.BOOK_ONLINE;
3134
+ var tc = `new_bookings_server`;
3135
+ var nc = `load more`;
3136
+ var rc = (e5) => {
3137
+ let { reportBi: t2 } = (0, import_services_manager_react.useService)(Xs);
3092
3138
  return (0, import_react.useCallback)((n2) => {
3093
- t2({ widget_name: e5, bookingsPlatform: Us, is_over_editor: false, ...n2.params, src: n2.src, evid: n2.evid }, { endpoint: n2.endpoint });
3139
+ t2({ widget_name: e5, bookingsPlatform: tc, is_over_editor: false, ...n2.params, src: n2.src, evid: n2.evid }, { endpoint: n2.endpoint });
3094
3140
  }, [t2, e5]);
3095
3141
  };
3096
- function Ks(e5) {
3142
+ function ic(e5) {
3097
3143
  return { evid: 540, src: 16, endpoint: `wixboost-ugc`, params: e5 };
3098
3144
  }
3099
- var qs = U(`seo/seo-service`);
3100
- function Js() {
3145
+ var ac = W(`seo/seo-service`);
3146
+ function oc() {
3101
3147
  let e5 = (0, import_services_manager_react.useGetService)();
3102
3148
  try {
3103
- return e5(qs);
3149
+ return e5(ac);
3104
3150
  } catch {
3105
3151
  return null;
3106
3152
  }
3107
3153
  }
3108
- function Ys() {
3109
- let e5 = Js();
3154
+ function sc() {
3155
+ let e5 = oc();
3110
3156
  return { resolved: !!e5, send: (t2) => {
3111
3157
  if (!e5) return Promise.resolve(`unavailable`);
3112
- let n2 = (e6) => H(e6, { feature: V.seo, action: `send-seo-entity`, level: `warning`, contexts: { seo: { itemType: t2.itemType } } });
3158
+ let n2 = (e6) => fi(e6, { feature: U.seo, action: `send-seo-entity`, level: `warning`, contexts: { seo: { itemType: t2.itemType } } });
3113
3159
  try {
3114
3160
  return e5.setSeoEntity(t2).then(() => `sent`).catch((e6) => (n2(e6), `failed`));
3115
3161
  } catch (e6) {
@@ -3117,38 +3163,38 @@ function Ys() {
3117
3163
  }
3118
3164
  } };
3119
3165
  }
3120
- var Xs = `SERVICES_COMPONENT`;
3121
- var Zs = `PAGINATED_COMPONENT`;
3122
- function Qs(e5, t2, n2) {
3123
- return { itemType: Xs, itemData: { services: e5.map((e6) => ({ ...e6, urls: { servicePage: { url: t2(e6) ?? `` } } })), pagination: n2 } };
3166
+ var cc = `SERVICES_COMPONENT`;
3167
+ var lc = `PAGINATED_COMPONENT`;
3168
+ function uc(e5, t2, n2) {
3169
+ return { itemType: cc, itemData: { services: e5.map((e6) => ({ ...e6, urls: { servicePage: { url: t2(e6) ?? `` } } })), pagination: n2 } };
3124
3170
  }
3125
- function $s(e5) {
3126
- return { itemType: Zs, itemData: { pagination: e5 } };
3171
+ function dc(e5) {
3172
+ return { itemType: lc, itemData: { pagination: e5 } };
3127
3173
  }
3128
- var ec = /* @__PURE__ */ new WeakSet();
3129
- function tc({ servicesPromise: e5, currentPage: t2, pageQueryParam: n2 }) {
3130
- let { services: r2, totalPages: i2 } = mi(e5), { resolveAbsoluteUrl: a2 } = cs(), { send: o2 } = Ys();
3174
+ var fc = /* @__PURE__ */ new WeakSet();
3175
+ function pc({ servicesPromise: e5, currentPage: t2, pageQueryParam: n2 }) {
3176
+ let { services: r2, totalPages: i2 } = gi(e5), { resolveAbsoluteUrl: a2 } = ds(), { send: o2 } = sc();
3131
3177
  return (0, import_react.useState)(() => {
3132
- if (ec.has(e5)) return true;
3133
- ec.add(e5);
3178
+ if (fc.has(e5)) return true;
3179
+ fc.add(e5);
3134
3180
  let s2 = { currentPage: t2, totalPages: i2, queryParam: n2 };
3135
- return o2(Qs(r2, (e6) => a2(`servicePage`, { slug: e6.mainSlug?.name ?? null, serviceId: e6._id ?? null }), s2)), i2 > 1 && o2($s(s2)), true;
3181
+ return o2(uc(r2, (e6) => a2(`servicePage`, { slug: e6.mainSlug?.name ?? null, serviceId: e6._id ?? null }), s2)), i2 > 1 && o2(dc(s2)), true;
3136
3182
  }), null;
3137
3183
  }
3138
- function nc(e5) {
3139
- return It(Object.assign(e5, { domainToMappings: { "api._api_base_domain_": [{ srcPath: `/events-3`, destPath: `` }], "manage._base_domain_": [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }, { srcPath: `/_api/calendar/v3/ro/events`, destPath: `/v3/events` }], "www.wixapis.com": [{ srcPath: `/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }], _: [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }], "*.dev.wix-code.com": [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }], "editor._base_domain_": [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }], "blocks._base_domain_": [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }], "create.editorx": [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }] } }));
3184
+ function mc(e5) {
3185
+ return Pt(Object.assign(e5, { domainToMappings: { "api._api_base_domain_": [{ srcPath: `/events-3`, destPath: `` }], "manage._base_domain_": [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }, { srcPath: `/_api/calendar/v3/ro/events`, destPath: `/v3/events` }], "www.wixapis.com": [{ srcPath: `/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }], _: [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }], "*.dev.wix-code.com": [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }], "editor._base_domain_": [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }], "blocks._base_domain_": [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }], "create.editorx": [{ srcPath: `/_api/calendar/v3/events`, destPath: `/v3/events` }, { srcPath: `/_api/calendar/v3/bulk/events`, destPath: `/v3/bulk/events` }] } }));
3140
3186
  }
3141
- var rc = `@wix/auto_sdk_calendar_events`;
3142
- function ic(e5) {
3187
+ var hc = `@wix/auto_sdk_calendar_events`;
3188
+ function gc(e5) {
3143
3189
  function t2({ host: t3 }) {
3144
- return { entityFqdn: `wix.calendar.v3.event`, method: `POST`, methodFqn: `wix.calendar.events.v3.EventsService.QueryEvents`, packageName: rc, migrationOptions: { optInTransformResponse: true }, url: nc({ protoPath: `/v3/events/query`, data: e5, host: t3 }), data: e5, transformResponse: (e6) => N(e6, [{ transformFn: M, paths: [{ path: `events.createdDate` }, { path: `events.updatedDate` }, { path: `events.start.utcDate` }, { path: `events.end.utcDate` }, { path: `events.adjustedStart.utcDate` }, { path: `events.adjustedEnd.utcDate` }, { path: `events.recurrenceRule.until.utcDate` }, { path: `events.recurrenceRule.adjustedUntil.utcDate` }] }]) };
3190
+ return { entityFqdn: `wix.calendar.v3.event`, method: `POST`, methodFqn: `wix.calendar.events.v3.EventsService.QueryEvents`, packageName: hc, migrationOptions: { optInTransformResponse: true }, url: mc({ protoPath: `/v3/events/query`, data: e5, host: t3 }), data: e5, transformResponse: (e6) => F(e6, [{ transformFn: P, paths: [{ path: `events.createdDate` }, { path: `events.updatedDate` }, { path: `events.start.utcDate` }, { path: `events.end.utcDate` }, { path: `events.adjustedStart.utcDate` }, { path: `events.adjustedEnd.utcDate` }, { path: `events.recurrenceRule.until.utcDate` }, { path: `events.recurrenceRule.adjustedUntil.utcDate` }] }]) };
3145
3191
  }
3146
3192
  return t2;
3147
3193
  }
3148
- function ac(e5) {
3194
+ function _c(e5) {
3149
3195
  let { httpClient: t2, sideEffects: n2 } = arguments[1];
3150
- return Ja({ func: async (r2) => {
3151
- let i2 = ic({ ...r2, ...e5 ?? {} });
3196
+ return Za({ func: async (r2) => {
3197
+ let i2 = gc({ ...r2, ...e5 ?? {} });
3152
3198
  n2?.onSiteCall?.();
3153
3199
  try {
3154
3200
  let e6 = await t2.request(i2);
@@ -3158,171 +3204,171 @@ function ac(e5) {
3158
3204
  }
3159
3205
  }, requestTransformer: (t3) => {
3160
3206
  let n3 = [t3, e5];
3161
- return A({ ...n3?.[1], query: n3?.[0] });
3207
+ return M({ ...n3?.[1], query: n3?.[0] });
3162
3208
  }, responseTransformer: ({ data: e6 }) => {
3163
- let t3 = j(N(e6, []));
3209
+ let t3 = N(F(e6, []));
3164
3210
  return { items: t3?.events, pagingMetadata: t3?.pagingMetadata };
3165
3211
  }, errorTransformer: (e6) => {
3166
- throw P(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false });
3212
+ throw I(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false });
3167
3213
  }, pagingMethod: `CURSOR`, transformationPaths: {} });
3168
3214
  }
3169
- async function oc(e5, t2) {
3170
- let { httpClient: n2, sideEffects: r2 } = arguments[2], i2 = ic(A({ query: e5, ...t2 }));
3215
+ async function vc(e5, t2) {
3216
+ let { httpClient: n2, sideEffects: r2 } = arguments[2], i2 = gc(M({ query: e5, ...t2 }));
3171
3217
  r2?.onSiteCall?.();
3172
3218
  try {
3173
3219
  let e6 = await n2.request(i2);
3174
- return r2?.onSuccess?.(e6), j(e6.data);
3220
+ return r2?.onSuccess?.(e6), N(e6.data);
3175
3221
  } catch (e6) {
3176
- let t3 = P(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false }, [`query`, `options`]);
3222
+ let t3 = I(e6, { spreadPathsToArguments: {}, explicitPathsToArguments: { query: `$[0]` }, singleArgumentUnchanged: false }, [`query`, `options`]);
3177
3223
  throw r2?.onError?.(e6), t3;
3178
3224
  }
3179
3225
  }
3180
- ({ ...$a() });
3181
- function sc(e5) {
3182
- return (t2) => ac(t2, { httpClient: e5 });
3226
+ ({ ...no() });
3227
+ function yc(e5) {
3228
+ return (t2) => _c(t2, { httpClient: e5 });
3183
3229
  }
3184
- function cc(e5) {
3185
- return (t2, n2) => oc(t2, n2, { httpClient: e5 });
3186
- }
3187
- var lc = _(`wix.calendar.v3.event_cancelled`, true, (e5) => j(N(e5, [{ transformFn: M, paths: [{ path: `data.event.createdDate` }, { path: `data.event.updatedDate` }, { path: `data.event.start.utcDate` }, { path: `data.event.end.utcDate` }, { path: `data.event.adjustedStart.utcDate` }, { path: `data.event.adjustedEnd.utcDate` }, { path: `data.event.recurrenceRule.until.utcDate` }, { path: `data.event.recurrenceRule.adjustedUntil.utcDate` }, { path: `metadata.eventTime` }] }])))();
3188
- var uc = _(`wix.calendar.v3.event_created`, true, (e5) => j(N(e5, [{ transformFn: M, paths: [{ path: `entity.createdDate` }, { path: `entity.updatedDate` }, { path: `entity.start.utcDate` }, { path: `entity.end.utcDate` }, { path: `entity.adjustedStart.utcDate` }, { path: `entity.adjustedEnd.utcDate` }, { path: `entity.recurrenceRule.until.utcDate` }, { path: `entity.recurrenceRule.adjustedUntil.utcDate` }, { path: `metadata.eventTime` }] }])))();
3189
- var dc = _(`wix.calendar.v3.event_recurring_split`, true, (e5) => j(N(e5, [{ transformFn: M, paths: [{ path: `data.updatedRecurringEventEndingBeforeSplit.createdDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.updatedDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.start.utcDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.end.utcDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.adjustedStart.utcDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.adjustedEnd.utcDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.recurrenceRule.until.utcDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.recurrenceRule.adjustedUntil.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.createdDate` }, { path: `data.newRecurringEventStartingFromSplit.updatedDate` }, { path: `data.newRecurringEventStartingFromSplit.start.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.end.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.adjustedStart.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.adjustedEnd.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.recurrenceRule.until.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.recurrenceRule.adjustedUntil.utcDate` }, { path: `metadata.eventTime` }] }])))();
3190
- var fc = _(`wix.calendar.v3.event_updated`, true, (e5) => j(N(e5, [{ transformFn: M, paths: [{ path: `entity.createdDate` }, { path: `entity.updatedDate` }, { path: `entity.start.utcDate` }, { path: `entity.end.utcDate` }, { path: `entity.adjustedStart.utcDate` }, { path: `entity.adjustedEnd.utcDate` }, { path: `entity.recurrenceRule.until.utcDate` }, { path: `entity.recurrenceRule.adjustedUntil.utcDate` }, { path: `metadata.eventTime` }, { path: `modifiedFields.createdDate` }, { path: `modifiedFields.updatedDate` }, { path: `modifiedFields.start.utcDate` }, { path: `modifiedFields.end.utcDate` }, { path: `modifiedFields.adjustedStart.utcDate` }, { path: `modifiedFields.adjustedEnd.utcDate` }, { path: `modifiedFields.recurrenceRule.until.utcDate` }, { path: `modifiedFields.recurrenceRule.adjustedUntil.utcDate` }] }])))();
3191
- function pc(e5) {
3192
- let t2 = lo({ builderQueryFunction: (t3) => sc(e5)(t3), typedQueryFunction: (t3, n3) => cc(e5)(t3, n3), hasOptionsParameter: true });
3230
+ function bc(e5) {
3231
+ return (t2, n2) => vc(t2, n2, { httpClient: e5 });
3232
+ }
3233
+ var xc = _(`wix.calendar.v3.event_cancelled`, true, (e5) => N(F(e5, [{ transformFn: P, paths: [{ path: `data.event.createdDate` }, { path: `data.event.updatedDate` }, { path: `data.event.start.utcDate` }, { path: `data.event.end.utcDate` }, { path: `data.event.adjustedStart.utcDate` }, { path: `data.event.adjustedEnd.utcDate` }, { path: `data.event.recurrenceRule.until.utcDate` }, { path: `data.event.recurrenceRule.adjustedUntil.utcDate` }, { path: `metadata.eventTime` }] }])))();
3234
+ var Sc = _(`wix.calendar.v3.event_created`, true, (e5) => N(F(e5, [{ transformFn: P, paths: [{ path: `entity.createdDate` }, { path: `entity.updatedDate` }, { path: `entity.start.utcDate` }, { path: `entity.end.utcDate` }, { path: `entity.adjustedStart.utcDate` }, { path: `entity.adjustedEnd.utcDate` }, { path: `entity.recurrenceRule.until.utcDate` }, { path: `entity.recurrenceRule.adjustedUntil.utcDate` }, { path: `metadata.eventTime` }] }])))();
3235
+ var Cc = _(`wix.calendar.v3.event_recurring_split`, true, (e5) => N(F(e5, [{ transformFn: P, paths: [{ path: `data.updatedRecurringEventEndingBeforeSplit.createdDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.updatedDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.start.utcDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.end.utcDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.adjustedStart.utcDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.adjustedEnd.utcDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.recurrenceRule.until.utcDate` }, { path: `data.updatedRecurringEventEndingBeforeSplit.recurrenceRule.adjustedUntil.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.createdDate` }, { path: `data.newRecurringEventStartingFromSplit.updatedDate` }, { path: `data.newRecurringEventStartingFromSplit.start.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.end.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.adjustedStart.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.adjustedEnd.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.recurrenceRule.until.utcDate` }, { path: `data.newRecurringEventStartingFromSplit.recurrenceRule.adjustedUntil.utcDate` }, { path: `metadata.eventTime` }] }])))();
3236
+ var wc = _(`wix.calendar.v3.event_updated`, true, (e5) => N(F(e5, [{ transformFn: P, paths: [{ path: `entity.createdDate` }, { path: `entity.updatedDate` }, { path: `entity.start.utcDate` }, { path: `entity.end.utcDate` }, { path: `entity.adjustedStart.utcDate` }, { path: `entity.adjustedEnd.utcDate` }, { path: `entity.recurrenceRule.until.utcDate` }, { path: `entity.recurrenceRule.adjustedUntil.utcDate` }, { path: `metadata.eventTime` }, { path: `modifiedFields.createdDate` }, { path: `modifiedFields.updatedDate` }, { path: `modifiedFields.start.utcDate` }, { path: `modifiedFields.end.utcDate` }, { path: `modifiedFields.adjustedStart.utcDate` }, { path: `modifiedFields.adjustedEnd.utcDate` }, { path: `modifiedFields.recurrenceRule.until.utcDate` }, { path: `modifiedFields.recurrenceRule.adjustedUntil.utcDate` }] }])))();
3237
+ function Tc(e5) {
3238
+ let t2 = po({ builderQueryFunction: (t3) => yc(e5)(t3), typedQueryFunction: (t3, n3) => bc(e5)(t3, n3), hasOptionsParameter: true });
3193
3239
  function n2(e6, n3) {
3194
3240
  return t2(...arguments);
3195
3241
  }
3196
3242
  return n2;
3197
3243
  }
3198
- var mc = Pt(pc);
3199
- ln(lc), ln(uc), ln(dc), ln(fc);
3200
- var hc = (e5) => {
3244
+ var Ec = Mt(Tc);
3245
+ sn(xc), sn(Sc), sn(Cc), sn(wc);
3246
+ var Dc = (e5) => {
3201
3247
  let t2 = (e6) => e6 < 10 ? `0${e6}` : `${e6}`;
3202
3248
  return `${e5.getFullYear()}-${t2(e5.getMonth() + 1)}-${t2(e5.getDate())}`;
3203
3249
  };
3204
- var gc = (e5) => `${hc(e5)}T00:00:00`;
3205
- var _c = 1e3;
3206
- async function vc(e5, t2) {
3250
+ var Oc = (e5) => `${Dc(e5)}T00:00:00`;
3251
+ var kc = 1e3;
3252
+ async function Ac(e5, t2) {
3207
3253
  let n2 = [], r2;
3208
3254
  do {
3209
- let i2 = await mc({ filter: e5, cursorPaging: { limit: _c, ...r2 ? { cursor: r2 } : {} } }, t2);
3255
+ let i2 = await Ec({ filter: e5, cursorPaging: { limit: kc, ...r2 ? { cursor: r2 } : {} } }, t2);
3210
3256
  n2.push(...i2.events ?? []), r2 = i2.pagingMetadata?.hasNext ? i2.pagingMetadata.cursors?.next ?? void 0 : void 0;
3211
3257
  } while (r2);
3212
3258
  return n2;
3213
3259
  }
3214
- async function yc(e5, t2) {
3215
- return e5.length === 0 ? [] : vc({ appId: Ni, scheduleId: { $in: e5 } }, { recurrenceType: [`MASTER`, `NONE`], fromLocalDate: gc(/* @__PURE__ */ new Date()), ...t2 ? { timeZone: t2 } : {} });
3260
+ async function jc(e5, t2) {
3261
+ return e5.length === 0 ? [] : Ac({ appId: Fi, scheduleId: { $in: e5 } }, { recurrenceType: [`MASTER`, `NONE`], fromLocalDate: Oc(/* @__PURE__ */ new Date()), ...t2 ? { timeZone: t2 } : {} });
3216
3262
  }
3217
- function bc(e5) {
3263
+ function Mc(e5) {
3218
3264
  let t2 = {};
3219
3265
  for (let n2 of e5) n2.scheduleId && (t2[n2.scheduleId] ??= []).push(n2);
3220
3266
  return t2;
3221
3267
  }
3222
- var xc = { displayTimeZonePolicy: { basedOn: Go.BUSINESS_TIME_ZONE, customerCanChange: false }, multiServiceAppointmentsEnabled: false };
3223
- async function Sc() {
3268
+ var Nc = { displayTimeZonePolicy: { basedOn: Jo.BUSINESS_TIME_ZONE, customerCanChange: false }, multiServiceAppointmentsEnabled: false };
3269
+ async function Pc() {
3224
3270
  try {
3225
- let e5 = await Jo();
3226
- return { displayTimeZonePolicy: { basedOn: e5.displayTimeZone?.basedOn ?? Go.BUSINESS_TIME_ZONE, customerCanChange: e5.displayTimeZone?.customerCanChange ?? false }, multiServiceAppointmentsEnabled: e5.multiServiceAppointments?.enabled ?? false };
3271
+ let e5 = await Zo();
3272
+ return { displayTimeZonePolicy: { basedOn: e5.displayTimeZone?.basedOn ?? Jo.BUSINESS_TIME_ZONE, customerCanChange: e5.displayTimeZone?.customerCanChange ?? false }, multiServiceAppointmentsEnabled: e5.multiServiceAppointments?.enabled ?? false };
3227
3273
  } catch (e5) {
3228
- return H(e5, { feature: V.bookingsSettings, action: `fetch-bookings-settings`, level: `warning` }), xc;
3274
+ return fi(e5, { feature: U.bookingsSettings, action: `fetch-bookings-settings`, level: `warning` }), Nc;
3229
3275
  }
3230
3276
  }
3231
3277
  (0, import_react.createContext)(null);
3232
- function Cc(e5) {
3233
- return e5.basedOn === Go.CUSTOMER_TIME_ZONE ? Intl.DateTimeFormat().resolvedOptions().timeZone : void 0;
3278
+ function Fc(e5) {
3279
+ return e5.basedOn === Jo.CUSTOMER_TIME_ZONE ? Intl.DateTimeFormat().resolvedOptions().timeZone : void 0;
3234
3280
  }
3235
- function wc({ categoryId: e5, locationId: t2, serviceItems: n2, isLoading: r2, hasError: i2, children: a2 }) {
3281
+ function Ic({ categoryId: e5, locationId: t2, serviceItems: n2, isLoading: r2, hasError: i2, children: a2 }) {
3236
3282
  let o2 = { serviceItems: n2, bookingsSettings: null, hasMore: false, isLoading: r2, hasError: i2, categoryId: e5, locationId: t2, loadMore: async () => {
3237
3283
  } };
3238
- return (0, import_jsx_runtime.jsx)(Ic.Provider, { value: o2, children: a2 });
3284
+ return (0, import_jsx_runtime.jsx)(Jc.Provider, { value: o2, children: a2 });
3239
3285
  }
3240
- function Tc({ categoryId: e5, locationId: t2, children: n2 }) {
3241
- return (0, import_jsx_runtime.jsx)(wc, { categoryId: e5, locationId: t2, serviceItems: [], isLoading: true, hasError: false, children: n2 });
3286
+ function Lc({ categoryId: e5, locationId: t2, children: n2 }) {
3287
+ return (0, import_jsx_runtime.jsx)(Ic, { categoryId: e5, locationId: t2, serviceItems: [], isLoading: true, hasError: false, children: n2 });
3242
3288
  }
3243
- function Ec({ categoryId: e5, locationId: t2, children: n2 }) {
3244
- return (0, import_jsx_runtime.jsx)(wc, { categoryId: e5, locationId: t2, serviceItems: [], isLoading: false, hasError: true, children: n2 });
3289
+ function Rc({ categoryId: e5, locationId: t2, children: n2 }) {
3290
+ return (0, import_jsx_runtime.jsx)(Ic, { categoryId: e5, locationId: t2, serviceItems: [], isLoading: false, hasError: true, children: n2 });
3245
3291
  }
3246
- function Dc(e5) {
3292
+ function zc(e5) {
3247
3293
  let t2 = e5?.$in ?? (e5?.$eq == null ? [] : [e5.$eq]);
3248
3294
  return [...new Set(t2.filter((e6) => typeof e6 == `string` && e6 !== ``))].sort().join(`,`);
3249
3295
  }
3250
3296
  function $(e5) {
3251
3297
  return e5 ? e5.split(`,`) : null;
3252
3298
  }
3253
- var Oc = [];
3254
- var kc = [];
3255
- var Ac = {};
3256
- var jc = {};
3257
- function Mc(e5, t2) {
3299
+ var Bc = [];
3300
+ var Vc = [];
3301
+ var Hc = {};
3302
+ var Uc = {};
3303
+ function Wc(e5, t2) {
3258
3304
  return Object.keys(t2).length === 0 ? e5 : { ...e5, ...t2 };
3259
3305
  }
3260
- function Nc(e5, t2, n2, r2, i2) {
3261
- let a2 = [...new Set(e5.filter((e6) => !Yo(e6.type)).map((e6) => e6.schedule?._id).filter((e6) => !!e6))], o2 = e5.filter(Xo).map((e6) => e6._id).filter((e6) => !!e6);
3262
- return Promise.all([a2.length === 0 ? Ac : yc(a2, t2).then(bc).catch(() => Ac), o2.length === 0 ? jc : Ns({ key: xs(r2, o2, n2), warmupData: i2, fetchData: () => Fs(o2) }).catch((e6) => (H(e6, { feature: V.services, action: `fetch-service-variants`, level: `warning` }), null))]);
3306
+ function Gc(e5, t2, n2, r2, i2, a2) {
3307
+ let o2 = [...new Set(e5.filter((e6) => !Qo(e6.type)).map((e6) => e6.schedule?._id).filter((e6) => !!e6))], s2 = e5.filter($o).map((e6) => e6._id).filter((e6) => !!e6);
3308
+ return Promise.all([o2.length === 0 ? Hc : jc(o2, t2).then(Mc).catch(() => Hc), s2.length === 0 ? Uc : Gs({ key: Ns(r2, i2, s2, n2), warmupData: a2, fetchData: () => qs(s2) }).catch((e6) => (fi(e6, { feature: U.services, action: `fetch-service-variants`, level: `warning` }), null))]);
3263
3309
  }
3264
- var Pc = { services: [], hasMore: false, totalPages: 1, hasError: true };
3265
- function Fc(e5) {
3310
+ var Kc = { services: [], hasMore: false, totalPages: 1, hasError: true };
3311
+ function qc(e5) {
3266
3312
  let t2 = Math.floor(Number(e5));
3267
3313
  return !e5 || !Number.isSafeInteger(t2) || t2 < 1 ? 1 : t2;
3268
3314
  }
3269
- var Ic = (0, import_react.createContext)(null);
3270
- var Lc = `useServicesContext must be used within ServicesContextProvider`;
3271
- function Rc() {
3272
- let e5 = (0, import_react.useContext)(Ic);
3273
- if (!e5) throw Error(Lc);
3315
+ var Jc = (0, import_react.createContext)(null);
3316
+ var Yc = `useServicesContext must be used within ServicesContextProvider`;
3317
+ function Xc() {
3318
+ let e5 = (0, import_react.useContext)(Jc);
3319
+ if (!e5) throw Error(Yc);
3274
3320
  return e5;
3275
3321
  }
3276
- function zc(e5, t2) {
3322
+ function Zc(e5, t2) {
3277
3323
  return { firstPage: e5, services: e5.services, hasMore: e5.hasMore, isLoadingMore: false, cursor: { offset: (t2.paginationIndex - 1) * t2.safeLimit + e5.services.length, hasMore: e5.hasMore, pending: null, dropped: false } };
3278
3324
  }
3279
- function Bc({ query: e5, isQueryPending: t2, settingsPromise: n2, categoryId: a2, locationId: o2, children: d2 }) {
3280
- let { firstPagePromise: f2, safeLimit: p2, serviceIdsKey: h2, categoryIdsKey: g2, refreshSignal: _2, language: v2 } = e5, y2 = mi(f2), b2 = mi(n2), [x2, S2] = (0, import_react.useState)(() => zc(y2, e5)), [ee2, C2] = (0, import_react.useState)({}), [w2, T2] = (0, import_react.useState)({});
3281
- x2.firstPage !== y2 && (S2(zc(y2, e5)), C2({}), T2({}));
3282
- let { cursor: E2 } = x2;
3283
- (0, import_react.useEffect)(() => (E2.dropped = false, () => {
3284
- E2.dropped = true;
3285
- }), [E2]);
3286
- let D2 = Cc(b2.displayTimeZonePolicy), O2 = Gs(Vs.SERVICES), { getParsedUrl: te2 } = Oi(), ne2 = (0, import_react.useRef)(null), re2 = fs(), ie2 = (0, import_react.useRef)(re2);
3287
- ie2.current = re2, (0, import_react.useEffect)(() => {
3288
- ne2.current !== y2 && (ne2.current = y2, O2(Bs({ referralInfo: te2().searchParams.get(es.referral) ?? void 0 })), O2(Ks({ numOfServices: y2.services.length })));
3289
- }, [O2, te2, y2]), (0, import_react.useEffect)(() => {
3325
+ function Qc({ query: e5, isQueryPending: t2, settingsPromise: n2, categoryId: a2, locationId: o2, children: d2 }) {
3326
+ let { firstPagePromise: f2, safeLimit: p2, serviceIdsKey: h2, categoryIdsKey: g2, refreshSignal: _2, language: v2, currency: y2 } = e5, b2 = gi(f2), x2 = gi(n2), [S2, C2] = (0, import_react.useState)(() => Zc(b2, e5)), [w2, T2] = (0, import_react.useState)({}), [E2, D2] = (0, import_react.useState)({});
3327
+ S2.firstPage !== b2 && (C2(Zc(b2, e5)), T2({}), D2({}));
3328
+ let { cursor: O2 } = S2;
3329
+ (0, import_react.useEffect)(() => (O2.dropped = false, () => {
3330
+ O2.dropped = true;
3331
+ }), [O2]);
3332
+ let ee2 = Fc(x2.displayTimeZonePolicy), k2 = rc($s.SERVICES), { getParsedUrl: te2 } = Ai(), ne2 = (0, import_react.useRef)(null), re2 = hs(), A2 = (0, import_react.useRef)(re2);
3333
+ A2.current = re2, (0, import_react.useEffect)(() => {
3334
+ ne2.current !== b2 && (ne2.current = b2, k2(Qs({ referralInfo: te2().searchParams.get(rs.referral) ?? void 0 })), k2(ic({ numOfServices: b2.services.length })));
3335
+ }, [k2, te2, b2]), (0, import_react.useEffect)(() => {
3290
3336
  let e6 = false;
3291
- return Nc(y2.services, D2, _2, v2, ie2.current).then(([t3, n3]) => {
3337
+ return Gc(b2.services, ee2, _2, v2, y2, A2.current).then(([t3, n3]) => {
3292
3338
  e6 || (0, import_react.startTransition)(() => {
3293
- C2((e7) => Mc(e7, t3)), n3 && T2((e7) => Mc(e7, n3));
3339
+ T2((e7) => Wc(e7, t3)), n3 && D2((e7) => Wc(e7, n3));
3294
3340
  });
3295
3341
  }), () => {
3296
3342
  e6 = true;
3297
3343
  };
3298
- }, [y2.services, D2, _2, v2]);
3299
- let ae2 = (0, import_react.useCallback)(async () => {
3300
- if (O2(zs({ pageName: Hs, buttonName: Ws })), E2.pending) return E2.pending;
3301
- if (!E2.hasMore) return;
3302
- let t3 = (e6) => S2((t4) => t4.cursor === E2 ? e6(t4) : t4);
3303
- return t3((e6) => ({ ...e6, isLoadingMore: true })), E2.pending = $o({ limit: p2, offset: E2.offset, categoryId: e5.categoryId, locationId: e5.locationId, serviceIds: $(h2), categoryIds: $(g2) }).then((e6) => {
3304
- E2.dropped || (E2.hasMore = e6.hasMore, E2.offset += e6.services.length, t3((t4) => ({ ...t4, services: [...t4.services, ...e6.services], hasMore: e6.hasMore })), Nc(e6.services, D2, _2, v2, ie2.current).then(([e7, t4]) => {
3305
- E2.dropped || (0, import_react.startTransition)(() => {
3306
- C2((t5) => Mc(t5, e7)), t4 && T2((e8) => Mc(e8, t4));
3344
+ }, [b2.services, ee2, _2, v2, y2]);
3345
+ let ie2 = (0, import_react.useCallback)(async () => {
3346
+ if (k2(Zs({ pageName: ec, buttonName: nc })), O2.pending) return O2.pending;
3347
+ if (!O2.hasMore) return;
3348
+ let t3 = (e6) => C2((t4) => t4.cursor === O2 ? e6(t4) : t4);
3349
+ return t3((e6) => ({ ...e6, isLoadingMore: true })), O2.pending = ns({ limit: p2, offset: O2.offset, categoryId: e5.categoryId, locationId: e5.locationId, serviceIds: $(h2), categoryIds: $(g2) }).then((e6) => {
3350
+ O2.dropped || (O2.hasMore = e6.hasMore, O2.offset += e6.services.length, t3((t4) => ({ ...t4, services: [...t4.services, ...e6.services], hasMore: e6.hasMore })), Gc(e6.services, ee2, _2, v2, y2, A2.current).then(([e7, t4]) => {
3351
+ O2.dropped || (0, import_react.startTransition)(() => {
3352
+ T2((t5) => Wc(t5, e7)), t4 && D2((e8) => Wc(e8, t4));
3307
3353
  });
3308
3354
  }));
3309
3355
  }).catch(() => {
3310
3356
  }).finally(() => {
3311
- E2.pending = null, t3((e6) => ({ ...e6, isLoadingMore: false }));
3312
- }), E2.pending;
3313
- }, [E2, p2, e5.categoryId, e5.locationId, h2, g2, O2, D2, _2, v2]), { resolvePath: oe2, toHref: se2 } = cs(), ce2 = (0, import_react.useMemo)(() => x2.services.map((e6) => {
3314
- let t3 = oe2(`servicePage`, { slug: e6.mainSlug?.name ?? null, serviceId: e6._id ?? null });
3315
- return { serviceId: e6._id ?? null, refreshSignal: _2, service: e6, masterEvents: ee2[e6.schedule?._id ?? ``] ?? Oc, serviceOptionsAndVariants: w2[e6._id ?? ``] ?? null, bookingsSettings: b2, servicePageLink: t3 ? { href: se2(t3), target: `_self` } : null };
3316
- }), [oe2, se2, x2.services, _2, ee2, w2, b2]), le2 = (0, import_react.useMemo)(() => ({ serviceItems: t2 ? kc : ce2, bookingsSettings: b2, hasMore: !t2 && x2.hasMore, isLoading: t2 || x2.isLoadingMore, hasError: !t2 && y2.hasError, categoryId: a2, locationId: o2, loadMore: ae2 }), [t2, ce2, b2, x2.hasMore, x2.isLoadingMore, y2.hasError, a2, o2, ae2]);
3317
- return (0, import_jsx_runtime.jsx)(Ic.Provider, { value: le2, children: d2 });
3318
- }
3319
- var Vc = (e5) => ({ ...e5, hasError: false });
3320
- var Hc = () => ({ ...Pc });
3321
- function Uc({ categoryData: e5, limit: n2 = 9, servicesPicker: r2, categoriesPicker: i2, refreshSignal: a2 = 0, children: s2 }) {
3322
- let l2 = Math.min(n2 ?? 9, 100), { searchParams: d2 } = Oi(), f2 = e5?.categoryId, p2 = !!f2, g2 = f2 || d2.get(es.category), _2 = d2.get(es.location), v2 = p2 ? 1 : Fc(d2.get(es.page)), y2 = Dc(r2?.serviceId), b2 = Dc(i2?.categoryId), x2 = fs(), S2 = vs(), { isSSR: ee2 } = Ls(), [C2] = (0, import_react.useState)(() => ee2()), w2 = (0, import_react.useMemo)(() => ({ firstPagePromise: _i(Ns({ key: bs(S2, g2, _2, v2, l2, $(y2) ?? [], $(b2) ?? []), refresh: a2 !== 0, warmupData: x2, fetchData: () => fi(`services-context-load`, { feature: V.services }, $o({ limit: l2, offset: (v2 - 1) * l2, categoryId: g2, locationId: _2, serviceIds: $(y2), categoryIds: $(b2) })) }), Vc, Hc), safeLimit: l2, paginationIndex: v2, categoryId: g2, locationId: _2, serviceIdsKey: y2, categoryIdsKey: b2, refreshSignal: a2, language: S2 }), [l2, g2, _2, v2, a2, y2, b2, S2]), [T2] = (0, import_react.useState)(() => Ns({ key: Ss(), warmupData: x2, fetchData: Sc })), E2 = (0, import_react.useDeferredValue)(w2);
3323
- return (0, import_jsx_runtime.jsx)(pi, { fallback: (0, import_jsx_runtime.jsx)(Ec, { categoryId: g2, locationId: _2, children: s2 }), feature: V.services, children: (0, import_jsx_runtime.jsxs)(import_react.Suspense, { fallback: (0, import_jsx_runtime.jsx)(Tc, { categoryId: g2, locationId: _2, children: s2 }), children: [C2 && !p2 && (0, import_jsx_runtime.jsx)(tc, { servicesPromise: w2.firstPagePromise, currentPage: v2, pageQueryParam: es.page }), (0, import_jsx_runtime.jsx)(Bc, { query: E2, isQueryPending: E2 !== w2, settingsPromise: T2, categoryId: g2, locationId: _2, children: s2 })] }) });
3324
- }
3325
- var Wc = zn(`117fa14c-cf9c-47f5-b2cb-7797094612ce`);
3357
+ O2.pending = null, t3((e6) => ({ ...e6, isLoadingMore: false }));
3358
+ }), O2.pending;
3359
+ }, [O2, p2, e5.categoryId, e5.locationId, h2, g2, k2, ee2, _2, v2, y2]), { resolvePath: ae2, toHref: oe2 } = ds(), se2 = (0, import_react.useMemo)(() => S2.services.map((e6) => {
3360
+ let t3 = ae2(`servicePage`, { slug: e6.mainSlug?.name ?? null, serviceId: e6._id ?? null });
3361
+ return { serviceId: e6._id ?? null, refreshSignal: _2, service: e6, masterEvents: w2[e6.schedule?._id ?? ``] ?? Bc, serviceOptionsAndVariants: E2[e6._id ?? ``] ?? null, bookingsSettings: x2, servicePageLink: t3 ? { href: oe2(t3), target: `_self` } : null };
3362
+ }), [ae2, oe2, S2.services, _2, w2, E2, x2]), ce2 = (0, import_react.useMemo)(() => ({ serviceItems: t2 ? Vc : se2, bookingsSettings: x2, hasMore: !t2 && S2.hasMore, isLoading: t2 || S2.isLoadingMore, hasError: !t2 && b2.hasError, categoryId: a2, locationId: o2, loadMore: ie2 }), [t2, se2, x2, S2.hasMore, S2.isLoadingMore, b2.hasError, a2, o2, ie2]);
3363
+ return (0, import_jsx_runtime.jsx)(Jc.Provider, { value: ce2, children: d2 });
3364
+ }
3365
+ var $c = (e5) => ({ ...e5, hasError: false });
3366
+ var el = () => ({ ...Kc });
3367
+ function tl({ categoryData: e5, limit: n2 = 9, servicesPicker: r2, categoriesPicker: i2, refreshSignal: a2 = 0, children: s2 }) {
3368
+ let l2 = Math.min(n2 ?? 9, 100), { searchParams: d2 } = Ai(), f2 = e5?.categoryId, p2 = !!f2, g2 = f2 || d2.get(rs.category), _2 = d2.get(rs.location), v2 = p2 ? 1 : qc(d2.get(rs.page)), y2 = zc(r2?.serviceId), b2 = zc(i2?.categoryId), x2 = hs(), S2 = xs(), C2 = ks(), { isSSR: w2 } = Ys(), [T2] = (0, import_react.useState)(() => w2()), E2 = (0, import_react.useMemo)(() => ({ firstPagePromise: yi(Gs({ key: Ms(S2, C2, g2, _2, v2, l2, $(y2) ?? [], $(b2) ?? []), refresh: a2 !== 0, warmupData: x2, fetchData: () => pi(`services-context-load`, { feature: U.services }, ns({ limit: l2, offset: (v2 - 1) * l2, categoryId: g2, locationId: _2, serviceIds: $(y2), categoryIds: $(b2) })) }), $c, el), safeLimit: l2, paginationIndex: v2, categoryId: g2, locationId: _2, serviceIdsKey: y2, categoryIdsKey: b2, refreshSignal: a2, language: S2, currency: C2 }), [l2, g2, _2, v2, a2, y2, b2, S2, C2]), [D2] = (0, import_react.useState)(() => Gs({ key: Ps(), warmupData: x2, fetchData: Pc })), O2 = (0, import_react.useDeferredValue)(E2);
3369
+ return (0, import_jsx_runtime.jsx)(mi, { fallback: (0, import_jsx_runtime.jsx)(Rc, { categoryId: g2, locationId: _2, children: s2 }), feature: U.services, children: (0, import_jsx_runtime.jsxs)(import_react.Suspense, { fallback: (0, import_jsx_runtime.jsx)(Lc, { categoryId: g2, locationId: _2, children: s2 }), children: [T2 && !p2 && (0, import_jsx_runtime.jsx)(pc, { servicesPromise: E2.firstPagePromise, currentPage: v2, pageQueryParam: rs.page }), (0, import_jsx_runtime.jsx)(Qc, { query: O2, isQueryPending: O2 !== E2, settingsPromise: D2, categoryId: g2, locationId: _2, children: s2 })] }) });
3370
+ }
3371
+ var nl = zn(`117fa14c-cf9c-47f5-b2cb-7797094612ce`);
3326
3372
  // Annotate the CommonJS export names for ESM import in node:
3327
3373
  0 && (module.exports = {
3328
3374
  SERVICES_CONTEXT_MISSING_PROVIDER_ERROR,