@paynext/sdk 0.0.118 → 0.0.119

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.es.js CHANGED
@@ -10,7 +10,7 @@ var xt = (n, e, t) => e in n ? kr(n, e, { enumerable: !0, configurable: !0, writ
10
10
  Cn.call(e, t) && xt(n, t, e[t]);
11
11
  return n;
12
12
  }, I = (n, e) => Er(n, xr(e));
13
- var se = (n, e) => {
13
+ var ae = (n, e) => {
14
14
  var t = {};
15
15
  for (var i in n)
16
16
  yn.call(n, i) && e.indexOf(i) < 0 && (t[i] = n[i]);
@@ -20,20 +20,20 @@ var se = (n, e) => {
20
20
  return t;
21
21
  };
22
22
  var c = (n, e, t) => xt(n, typeof e != "symbol" ? e + "" : e, t);
23
- var E = (n, e, t) => new Promise((i, r) => {
24
- var s = (l) => {
23
+ var k = (n, e, t) => new Promise((i, r) => {
24
+ var a = (l) => {
25
25
  try {
26
26
  o(t.next(l));
27
27
  } catch (u) {
28
28
  r(u);
29
29
  }
30
- }, a = (l) => {
30
+ }, s = (l) => {
31
31
  try {
32
32
  o(t.throw(l));
33
33
  } catch (u) {
34
34
  r(u);
35
35
  }
36
- }, o = (l) => l.done ? i(l.value) : Promise.resolve(l.value).then(s, a);
36
+ }, o = (l) => l.done ? i(l.value) : Promise.resolve(l.value).then(a, s);
37
37
  o((t = t.apply(n, e)).next());
38
38
  });
39
39
  import wr from "react";
@@ -44,7 +44,7 @@ class iu {
44
44
  typeof window != "undefined" && (this.parent = e);
45
45
  }
46
46
  mount(e) {
47
- return E(this, null, function* () {
47
+ return k(this, null, function* () {
48
48
  if (!this.parent)
49
49
  return;
50
50
  if (!this.core) {
@@ -62,7 +62,7 @@ class iu {
62
62
  });
63
63
  }
64
64
  unmount() {
65
- return E(this, null, function* () {
65
+ return k(this, null, function* () {
66
66
  !this.parent || !this.core || (this.parent.innerHTML = "", this.core.clearState());
67
67
  });
68
68
  }
@@ -141,15 +141,15 @@ const kn = {
141
141
  token_service_provider: e.token.tokenServiceProvider
142
142
  };
143
143
  }, Ir = (n) => {
144
- var t, i, r, s, a, o;
144
+ var t, i, r, a, s, o;
145
145
  const e = n.applePay;
146
146
  if (e)
147
147
  return {
148
148
  cryptogram: e.cryptogram,
149
149
  eci: e.eci,
150
150
  exp_month: (i = (t = e.networkToken) == null ? void 0 : t.expiry) != null && i.month ? Number(e.networkToken.expiry.month) : void 0,
151
- exp_year: (s = (r = e.networkToken) == null ? void 0 : r.expiry) != null && s.year ? Number(e.networkToken.expiry.year) : void 0,
152
- token: (a = e.networkToken) == null ? void 0 : a.number,
151
+ exp_year: (a = (r = e.networkToken) == null ? void 0 : r.expiry) != null && a.year ? Number(e.networkToken.expiry.year) : void 0,
152
+ token: (s = e.networkToken) == null ? void 0 : s.number,
153
153
  token_service_provider: (o = e.networkToken) == null ? void 0 : o.tokenServiceProvider
154
154
  };
155
155
  }, Mr = (n) => {
@@ -159,33 +159,33 @@ const kn = {
159
159
  payment_method_nonce: e.nonce
160
160
  };
161
161
  }, En = (n) => {
162
- var i, r, s, a, o, l, u, d, h, m, p, g, b, y;
162
+ var i, r, a, s, o, l, u, d, h, m, p, g, b, y;
163
163
  const { applePay: e, googlePay: t } = n;
164
164
  if (!(!e && !t))
165
165
  return {
166
166
  city: ((i = e == null ? void 0 : e.billingContact) == null ? void 0 : i.locality) || ((r = t == null ? void 0 : t.billingAddress) == null ? void 0 : r.locality) || void 0,
167
- country: ((s = e == null ? void 0 : e.billingContact) == null ? void 0 : s.countryCode) || ((a = t == null ? void 0 : t.billingAddress) == null ? void 0 : a.countryCode) || void 0,
167
+ country: ((a = e == null ? void 0 : e.billingContact) == null ? void 0 : a.countryCode) || ((s = t == null ? void 0 : t.billingAddress) == null ? void 0 : s.countryCode) || void 0,
168
168
  line1: ((l = (o = e == null ? void 0 : e.billingContact) == null ? void 0 : o.addressLines) == null ? void 0 : l.at(0)) || ((u = t == null ? void 0 : t.billingAddress) == null ? void 0 : u.address1) || void 0,
169
169
  line2: ((h = (d = e == null ? void 0 : e.billingContact) == null ? void 0 : d.addressLines) == null ? void 0 : h.at(1)) || ((m = t == null ? void 0 : t.billingAddress) == null ? void 0 : m.address2) || void 0,
170
170
  postal_code: ((p = e == null ? void 0 : e.billingContact) == null ? void 0 : p.postalCode) || ((g = t == null ? void 0 : t.billingAddress) == null ? void 0 : g.postalCode) || void 0,
171
171
  state: ((b = e == null ? void 0 : e.billingContact) == null ? void 0 : b.administrativeArea) || ((y = t == null ? void 0 : t.billingAddress) == null ? void 0 : y.administrativeArea) || void 0
172
172
  };
173
173
  }, xn = (n) => {
174
- var r, s, a, o, l, u, d, h, m, p, g, b, y, k, V, _, M, T, D;
174
+ var r, a, s, o, l, u, d, h, m, p, g, b, y, E, V, _, M, T, D;
175
175
  const { card: e, googlePay: t, applePay: i } = n;
176
176
  if (!(!e && !(t != null && t.card) && !(i != null && i.card)))
177
177
  return {
178
178
  bin: e == null ? void 0 : e.firstSixDigits,
179
179
  bin_data: {
180
- brand: (e == null ? void 0 : e.cardBrand) || ((r = t == null ? void 0 : t.card) == null ? void 0 : r.brand) || ((s = i == null ? void 0 : i.card) == null ? void 0 : s.brand),
181
- country: (e == null ? void 0 : e.country) || ((a = t == null ? void 0 : t.card) == null ? void 0 : a.country) || ((o = i == null ? void 0 : i.card) == null ? void 0 : o.country),
180
+ brand: (e == null ? void 0 : e.cardBrand) || ((r = t == null ? void 0 : t.card) == null ? void 0 : r.brand) || ((a = i == null ? void 0 : i.card) == null ? void 0 : a.brand),
181
+ country: (e == null ? void 0 : e.country) || ((s = t == null ? void 0 : t.card) == null ? void 0 : s.country) || ((o = i == null ? void 0 : i.card) == null ? void 0 : o.country),
182
182
  currency_code: (e == null ? void 0 : e.currency) || ((l = t == null ? void 0 : t.card) == null ? void 0 : l.currency) || ((u = i == null ? void 0 : i.card) == null ? void 0 : u.currency),
183
183
  funding: (e == null ? void 0 : e.funding) || ((d = t == null ? void 0 : t.card) == null ? void 0 : d.funding) || ((h = i == null ? void 0 : i.card) == null ? void 0 : h.funding),
184
184
  issuer: (e == null ? void 0 : e.issuer) || ((m = t == null ? void 0 : t.card) == null ? void 0 : m.issuer) || ((p = i == null ? void 0 : i.card) == null ? void 0 : p.issuer),
185
185
  type: (e == null ? void 0 : e.type) || ((g = t == null ? void 0 : t.card) == null ? void 0 : g.segment) || ((b = i == null ? void 0 : i.card) == null ? void 0 : b.segment)
186
186
  },
187
187
  cvc: e == null ? void 0 : e.cvc,
188
- exp_month: e != null && e.expMonth || (y = t == null ? void 0 : t.card) != null && y.expiry.month ? Number((e == null ? void 0 : e.expMonth) || ((k = t == null ? void 0 : t.card) == null ? void 0 : k.expiry.month)) : void 0,
188
+ exp_month: e != null && e.expMonth || (y = t == null ? void 0 : t.card) != null && y.expiry.month ? Number((e == null ? void 0 : e.expMonth) || ((E = t == null ? void 0 : t.card) == null ? void 0 : E.expiry.month)) : void 0,
189
189
  exp_year: e != null && e.expYear || (V = t == null ? void 0 : t.card) != null && V.expiry.year ? Number((e == null ? void 0 : e.expYear) || ((_ = t == null ? void 0 : t.card) == null ? void 0 : _.expiry.year)) : void 0,
190
190
  last4: (e == null ? void 0 : e.lastFourDigits) || ((M = t == null ? void 0 : t.card) == null ? void 0 : M.lastFour) || ((T = i == null ? void 0 : i.card) == null ? void 0 : T.lastFour),
191
191
  number: (e == null ? void 0 : e.number) || ((D = t == null ? void 0 : t.card) == null ? void 0 : D.number)
@@ -195,7 +195,7 @@ const kn = {
195
195
  const { applePay: e, card: t } = n;
196
196
  return (i = e == null ? void 0 : e.billingContact) != null && i.givenName ? `${e.billingContact.givenName} ${e.billingContact.familyName || ""}`.trim() : (r = t == null ? void 0 : t.metadata) == null ? void 0 : r.name;
197
197
  }, Pr = (n) => {
198
- var i, r, s, a, o, l;
198
+ var i, r, a, s, o, l, u, d;
199
199
  const e = Ar(n), t = {
200
200
  client_session: n.clientSession,
201
201
  three_ds_session_id: n.threeDsSessionId,
@@ -214,7 +214,7 @@ const kn = {
214
214
  case x.GOOGLE_PAY:
215
215
  return I(v({}, t), {
216
216
  name: (r = (i = n.googlePay) == null ? void 0 : i.billingAddress) == null ? void 0 : r.name,
217
- phone: (a = (s = n.googlePay) == null ? void 0 : s.billingAddress) == null ? void 0 : a.phoneNumber,
217
+ phone: (l = (o = (s = (a = n.googlePay) == null ? void 0 : a.billingAddress) == null ? void 0 : s.phoneNumber) == null ? void 0 : o.replace(/ /g, "")) == null ? void 0 : l.replace(/-/g, ""),
218
218
  card: xn(n),
219
219
  google_pay: Vr(n),
220
220
  billing_address: En(n)
@@ -224,7 +224,7 @@ const kn = {
224
224
  name: wn(n),
225
225
  card: xn(n),
226
226
  apple_pay: Ir(n),
227
- phone: (l = (o = n.applePay) == null ? void 0 : o.shippingContact) == null ? void 0 : l.phoneNumber,
227
+ phone: (d = (u = n.applePay) == null ? void 0 : u.shippingContact) == null ? void 0 : d.phoneNumber,
228
228
  billing_address: En(n)
229
229
  });
230
230
  case x.VENMO:
@@ -234,27 +234,27 @@ const kn = {
234
234
  default:
235
235
  throw new Error(`Unsupported payment method: ${e}`);
236
236
  }
237
- }, Dr = (n, e, t) => E(void 0, null, function* () {
237
+ }, Dr = (n, e, t) => k(void 0, null, function* () {
238
238
  const i = `${Xt(e)}/payments/create`, r = new Headers();
239
239
  r.append("Content-Type", "application/json"), r.append("X-API-Version", t);
240
- const s = Pr(n);
240
+ const a = Pr(n);
241
241
  return yield (yield fetch(i, {
242
242
  method: "POST",
243
243
  headers: r,
244
- body: JSON.stringify(s)
244
+ body: JSON.stringify(a)
245
245
  })).json();
246
- }), Rr = (n, e, t) => E(void 0, null, function* () {
246
+ }), Rr = (n, e, t) => k(void 0, null, function* () {
247
247
  const i = `${Xt(e)}/payments/create/billing/agreement`, r = new Headers();
248
248
  return r.append("Content-Type", "application/json"), r.append("X-API-Version", t), (yield (yield fetch(i, {
249
249
  method: "POST",
250
250
  headers: r,
251
251
  body: JSON.stringify({ client_session: n })
252
252
  })).json()).paypal_agreement_token_response.token_id || "";
253
- }), Or = (n, e, t) => E(void 0, null, function* () {
253
+ }), Or = (n, e, t) => k(void 0, null, function* () {
254
254
  const i = new Headers();
255
255
  i.append("X-API-Version", t);
256
- const r = `${Xt(e)}/payments/config?client_session_id=${n}`, a = yield (yield fetch(r, { headers: i })).json();
257
- return a.checkout_config || (a.checkout_config = Tr), a;
256
+ const r = `${Xt(e)}/payments/config?client_session_id=${n}`, s = yield (yield fetch(r, { headers: i })).json();
257
+ return s.checkout_config || (s.checkout_config = Tr), s;
258
258
  });
259
259
  let Nr = class {
260
260
  constructor(e) {
@@ -264,14 +264,14 @@ let Nr = class {
264
264
  this.ev = e;
265
265
  }
266
266
  init(u, d) {
267
- return E(this, arguments, function* ({
267
+ return k(this, arguments, function* ({
268
268
  transaction: e,
269
269
  locale: t,
270
270
  // supportedCardTypes,
271
271
  onReady: i,
272
272
  onError: r,
273
- onSuccess: s,
274
- onCancel: a,
273
+ onSuccess: a,
274
+ onCancel: s,
275
275
  onPaymentAttempt: o
276
276
  }, l) {
277
277
  const h = this.ev.transactions.create(e);
@@ -288,25 +288,25 @@ let Nr = class {
288
288
  allowedCardNetworks: ["visa", "masterCard"],
289
289
  requestBillingAddress: !0,
290
290
  requestPayerDetails: ["name", "email", "phone"],
291
- process: (b, y) => E(this, [b, y], function* (p, { fail: g }) {
291
+ process: (b, y) => k(this, [b, y], function* (p, { fail: g }) {
292
292
  o == null || o({
293
293
  paymentMethod: x.GOOGLE_PAY
294
294
  });
295
295
  try {
296
- s == null || s(p);
297
- } catch (k) {
298
- console.error(k), g({
296
+ a == null || a(p);
297
+ } catch (E) {
298
+ console.error(E), g({
299
299
  message: "Cannot pay with payment credentials"
300
300
  });
301
301
  }
302
302
  })
303
303
  }));
304
- const m = yield this.apple.availability();
305
- this.isAvailable = m === "available", this.isAvailable || r == null || r("Apple Pay is not supported on this device"), r && this.apple.on("error", r), a && this.apple.on("cancel", a), this.onReady = i;
304
+ const m = "available";
305
+ this.isAvailable = m === "available", this.isAvailable || r == null || r("Apple Pay is not supported on this device"), r && this.apple.on("error", r), s && this.apple.on("cancel", s), this.onReady = i;
306
306
  });
307
307
  }
308
308
  render(e) {
309
- return E(this, null, function* () {
309
+ return k(this, null, function* () {
310
310
  var t;
311
311
  !this.apple || !this.isAvailable || (e.innerHTML = "", yield this.apple.mount(e), (t = this.onReady) == null || t.call(this));
312
312
  });
@@ -317,7 +317,7 @@ let Nr = class {
317
317
  this.ev = e;
318
318
  }
319
319
  init(u, d) {
320
- return E(this, arguments, function* ({ transaction: e, locale: t, onReady: i, onError: r, onSuccess: s, onCancel: a, onPaymentAttempt: o }, l) {
320
+ return k(this, arguments, function* ({ transaction: e, locale: t, onReady: i, onError: r, onSuccess: a, onCancel: s, onPaymentAttempt: o }, l) {
321
321
  const h = this.ev.transactions.create(e);
322
322
  this.google = this.ev.ui.googlePay(h, I(v({
323
323
  locale: t,
@@ -334,23 +334,23 @@ let Nr = class {
334
334
  allowedAuthMethods: ["PAN_ONLY", "CRYPTOGRAM_3DS"],
335
335
  // ToDo: Temporary we have only Visa and Master card
336
336
  allowedCardNetworks: ["VISA", "MASTERCARD"],
337
- process: (g, b) => E(this, [g, b], function* (m, { fail: p }) {
337
+ process: (g, b) => k(this, [g, b], function* (m, { fail: p }) {
338
338
  o == null || o({
339
339
  paymentMethod: x.GOOGLE_PAY
340
340
  });
341
341
  try {
342
- s == null || s(m);
342
+ a == null || a(m);
343
343
  } catch (y) {
344
344
  console.error(y), p({
345
345
  message: "Cannot pay with payment credentials"
346
346
  });
347
347
  }
348
348
  })
349
- })), a && this.google.on("cancel", a), i && this.google.on("ready", i), r && this.google.on("error", r);
349
+ })), s && this.google.on("cancel", s), i && this.google.on("ready", i), r && this.google.on("error", r);
350
350
  });
351
351
  }
352
352
  render(e) {
353
- return E(this, null, function* () {
353
+ return k(this, null, function* () {
354
354
  this.google && (e.innerHTML = "", this.google.mount(e));
355
355
  });
356
356
  }
@@ -378,13 +378,13 @@ class Fr {
378
378
  c(this, "threeDs", null);
379
379
  this.ev = e;
380
380
  }
381
- init(s) {
382
- return E(this, arguments, function* ({ threeDsId: e, onReady: t, onSuccess: i, onError: r }) {
381
+ init(a) {
382
+ return k(this, arguments, function* ({ threeDsId: e, onReady: t, onSuccess: i, onError: r }) {
383
383
  this.threeDs = this.ev.ui.threeDSecure(e), this.threeDs.on("ready", () => t == null ? void 0 : t()), this.threeDs.on("success", () => i == null ? void 0 : i()), this.threeDs.on("failure", () => r == null ? void 0 : r()), this.threeDs.on("error", () => r == null ? void 0 : r());
384
384
  });
385
385
  }
386
386
  render(e) {
387
- return E(this, null, function* () {
387
+ return k(this, null, function* () {
388
388
  this.threeDs && this.threeDs.mount(e);
389
389
  });
390
390
  }
@@ -405,34 +405,40 @@ class jr {
405
405
  var i, r;
406
406
  return ((i = this.ev) == null ? void 0 : i.config.appId) !== t || ((r = this.ev) == null ? void 0 : r.config.teamId) !== e;
407
407
  }
408
- // init ev
409
- initEv(e) {
410
- return E(this, null, function* () {
408
+ // preload evervault
409
+ preloadEvervault(e) {
410
+ return k(this, null, function* () {
411
411
  if (!this.isShouldLoad(e)) return;
412
412
  if (typeof window == "undefined")
413
413
  throw new Error("Evervault can only be initialized in browser environment");
414
414
  this.isReady = !1;
415
415
  const { loadEvervault: t } = yield import("./evervault-js-37KtqVz5.js");
416
- this.ev = yield t(e.teamId, e.appId), this.apple = new Nr(this.ev), this.google = new Sr(this.ev), this.events.ready.emit(), this.isReady = !0;
416
+ this.ev = yield t(e.teamId, e.appId), this.apple = new Nr(this.ev), this.google = new Sr(this.ev);
417
+ });
418
+ }
419
+ // init ev
420
+ initEv(e) {
421
+ return k(this, null, function* () {
422
+ this.events.ready.emit(), this.isReady = !0;
417
423
  });
418
424
  }
419
425
  // init three ds
420
426
  initThreeDs(e) {
421
- return E(this, null, function* () {
427
+ return k(this, null, function* () {
422
428
  if (!this.ev) throw new Error("Evervault should be init before using Three DS Secure");
423
429
  this.threeDs = new Fr(this.ev), yield this.threeDs.init(e), yield this.threeDs.render();
424
430
  });
425
431
  }
426
432
  // init apple
427
433
  initApple(e, t) {
428
- return E(this, null, function* () {
434
+ return k(this, null, function* () {
429
435
  if (!this.apple) throw new Error("Evervault should be init before using Apple Pay");
430
436
  yield this.apple.init(e, t);
431
437
  });
432
438
  }
433
439
  // init google
434
440
  initGoogle(e, t) {
435
- return E(this, null, function* () {
441
+ return k(this, null, function* () {
436
442
  if (!this.google) throw new Error("Evervault should be init before using Google Pay");
437
443
  yield this.google.init(e, t);
438
444
  });
@@ -448,14 +454,14 @@ class jr {
448
454
  }
449
455
  // render apple
450
456
  renderApple(e) {
451
- return E(this, null, function* () {
457
+ return k(this, null, function* () {
452
458
  var t;
453
459
  return (t = this.apple) == null ? void 0 : t.render(e);
454
460
  });
455
461
  }
456
462
  // render google
457
463
  renderGoogle(e) {
458
- return E(this, null, function* () {
464
+ return k(this, null, function* () {
459
465
  var t;
460
466
  return (t = this.google) == null ? void 0 : t.render(e);
461
467
  });
@@ -476,8 +482,8 @@ function Br(n, e, t) {
476
482
  return [n];
477
483
  if (typeof n == "string") {
478
484
  let r = document;
479
- const s = (i = t == null ? void 0 : t[n]) != null ? i : r.querySelectorAll(n);
480
- return s ? Array.from(s) : [];
485
+ const a = (i = t == null ? void 0 : t[n]) != null ? i : r.querySelectorAll(n);
486
+ return a ? Array.from(a) : [];
481
487
  }
482
488
  return Array.from(n);
483
489
  }
@@ -511,13 +517,13 @@ function qr(n, e, t) {
511
517
  r.at > e && r.at < t && (gi(n, r), i--);
512
518
  }
513
519
  }
514
- function Gr(n, e, t, i, r, s) {
515
- qr(n, r, s);
516
- for (let a = 0; a < e.length; a++)
520
+ function Gr(n, e, t, i, r, a) {
521
+ qr(n, r, a);
522
+ for (let s = 0; s < e.length; s++)
517
523
  n.push({
518
- value: e[a],
519
- at: nt(r, s, i[a]),
520
- easing: fi(t, a)
524
+ value: e[s],
525
+ at: nt(r, a, i[s]),
526
+ easing: fi(t, s)
521
527
  });
522
528
  }
523
529
  function Hr(n, e) {
@@ -554,12 +560,12 @@ function nn(n) {
554
560
  e += t, i = n.next(e);
555
561
  return e >= mt ? 1 / 0 : e;
556
562
  }
557
- const ae = /* @__NO_SIDE_EFFECTS__ */ (n) => n * 1e3, le = /* @__NO_SIDE_EFFECTS__ */ (n) => n / 1e3;
563
+ const se = /* @__NO_SIDE_EFFECTS__ */ (n) => n * 1e3, le = /* @__NO_SIDE_EFFECTS__ */ (n) => n / 1e3;
558
564
  function yi(n, e = 100, t) {
559
565
  const i = t(I(v({}, n), { keyframes: [0, e] })), r = Math.min(nn(i), mt);
560
566
  return {
561
567
  type: "keyframes",
562
- ease: (s) => i.next(r * s).value / e,
568
+ ease: (a) => i.next(r * a).value / e,
563
569
  duration: /* @__PURE__ */ le(r)
564
570
  };
565
571
  }
@@ -573,8 +579,8 @@ process.env.NODE_ENV !== "production" && (it = (n, e) => {
573
579
  throw new Error(e);
574
580
  });
575
581
  const Ur = "easeInOut", Wr = 20;
576
- function Zr(n, s = {}, i, r) {
577
- var a = s, { defaultTransition: e = {} } = a, t = se(a, ["defaultTransition"]);
582
+ function Zr(n, a = {}, i, r) {
583
+ var s = a, { defaultTransition: e = {} } = s, t = ae(s, ["defaultTransition"]);
578
584
  const o = e.duration || 0.3, l = /* @__PURE__ */ new Map(), u = /* @__PURE__ */ new Map(), d = {}, h = /* @__PURE__ */ new Map();
579
585
  let m = 0, p = 0, g = 0;
580
586
  for (let b = 0; b < n.length; b++) {
@@ -586,21 +592,21 @@ function Zr(n, s = {}, i, r) {
586
592
  h.set(y.name, Tn(p, y.at, m, h));
587
593
  continue;
588
594
  }
589
- let [k, V, _ = {}] = y;
595
+ let [E, V, _ = {}] = y;
590
596
  _.at !== void 0 && (p = Tn(p, _.at, m, h));
591
597
  let M = 0;
592
598
  const T = (D, C, w, R = 0, O = 0) => {
593
- const q = Jr(D), _e = C, { delay: Te = 0, times: te = vi(q), type: fe = "keyframes", repeat: he, repeatType: kt, repeatDelay: Et = 0 } = _e, at = se(_e, ["delay", "times", "type", "repeat", "repeatType", "repeatDelay"]);
599
+ const q = Jr(D), _e = C, { delay: Te = 0, times: te = vi(q), type: fe = "keyframes", repeat: he, repeatType: kt, repeatDelay: Et = 0 } = _e, st = ae(_e, ["delay", "times", "type", "repeat", "repeatType", "repeatDelay"]);
594
600
  let { ease: ne = e.ease || "easeOut", duration: f } = C;
595
601
  const P = typeof Te == "function" ? Te(R, O) : Te, N = q.length, G = tn(fe) ? fe : r == null ? void 0 : r[fe];
596
602
  if (N <= 2 && G) {
597
603
  let z = 100;
598
- if (N === 2 && es(q)) {
604
+ if (N === 2 && ea(q)) {
599
605
  const ge = q[1] - q[0];
600
606
  z = Math.abs(ge);
601
607
  }
602
- const re = v({}, at);
603
- f !== void 0 && (re.duration = /* @__PURE__ */ ae(f));
608
+ const re = v({}, st);
609
+ f !== void 0 && (re.duration = /* @__PURE__ */ se(f));
604
610
  const pe = yi(re, z, G);
605
611
  ne = pe.ease, f = pe.duration;
606
612
  }
@@ -623,11 +629,11 @@ function Zr(n, s = {}, i, r) {
623
629
  const Ae = ie + f;
624
630
  Gr(w, q, ne, te, ie, Ae), M = Math.max(P + f, M), g = Math.max(Ae, g);
625
631
  };
626
- if (J(k)) {
627
- const D = An(k, u);
632
+ if (J(E)) {
633
+ const D = An(E, u);
628
634
  T(V, _, _n("default", D));
629
635
  } else {
630
- const D = pi(k, V, i, d), C = D.length;
636
+ const D = pi(E, V, i, d), C = D.length;
631
637
  for (let w = 0; w < C; w++) {
632
638
  V = V, _ = _;
633
639
  const R = D[w], O = An(R, u);
@@ -638,8 +644,8 @@ function Zr(n, s = {}, i, r) {
638
644
  m = p, p += M;
639
645
  }
640
646
  return u.forEach((b, y) => {
641
- for (const k in b) {
642
- const V = b[k];
647
+ for (const E in b) {
648
+ const V = b[E];
643
649
  V.sort(Yr);
644
650
  const _ = [], M = [], T = [];
645
651
  for (let C = 0; C < V.length; C++) {
@@ -651,7 +657,7 @@ function Zr(n, s = {}, i, r) {
651
657
  transition: {}
652
658
  });
653
659
  const D = l.get(y);
654
- D.keyframes[k] = _, D.transition[k] = v(I(v({}, e), {
660
+ D.keyframes[E] = _, D.transition[E] = v(I(v({}, e), {
655
661
  duration: g,
656
662
  ease: T,
657
663
  times: M
@@ -671,7 +677,7 @@ function Jr(n) {
671
677
  function Xr(n, e) {
672
678
  return n && n[e] ? v(v({}, n), n[e]) : v({}, n);
673
679
  }
674
- const Qr = (n) => typeof n == "number", es = (n) => n.every(Qr), Je = /* @__PURE__ */ new WeakMap(), ts = (n) => Array.isArray(n);
680
+ const Qr = (n) => typeof n == "number", ea = (n) => n.every(Qr), Je = /* @__PURE__ */ new WeakMap(), ta = (n) => Array.isArray(n);
675
681
  function Ln(n) {
676
682
  const e = [{}, {}];
677
683
  return n == null || n.values.forEach((t, i) => {
@@ -680,16 +686,16 @@ function Ln(n) {
680
686
  }
681
687
  function Ci(n, e, t, i) {
682
688
  if (typeof e == "function") {
683
- const [r, s] = Ln(i);
684
- e = e(t !== void 0 ? t : n.custom, r, s);
689
+ const [r, a] = Ln(i);
690
+ e = e(t !== void 0 ? t : n.custom, r, a);
685
691
  }
686
692
  if (typeof e == "string" && (e = n.variants && n.variants[e]), typeof e == "function") {
687
- const [r, s] = Ln(i);
688
- e = e(t !== void 0 ? t : n.custom, r, s);
693
+ const [r, a] = Ln(i);
694
+ e = e(t !== void 0 ? t : n.custom, r, a);
689
695
  }
690
696
  return e;
691
697
  }
692
- function ns(n, e, t) {
698
+ function na(n, e, t) {
693
699
  const i = n.getProps();
694
700
  return Ci(i, e, i.custom, n);
695
701
  }
@@ -711,16 +717,16 @@ const lt = [
711
717
  "postRender"
712
718
  // Compute
713
719
  ];
714
- function is(n, e) {
715
- let t = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Set(), r = !1, s = !1;
716
- const a = /* @__PURE__ */ new WeakSet();
720
+ function ia(n, e) {
721
+ let t = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Set(), r = !1, a = !1;
722
+ const s = /* @__PURE__ */ new WeakSet();
717
723
  let o = {
718
724
  delta: 0,
719
725
  timestamp: 0,
720
726
  isProcessing: !1
721
727
  };
722
728
  function l(d) {
723
- a.has(d) && (u.schedule(d), n()), d(o);
729
+ s.has(d) && (u.schedule(d), n()), d(o);
724
730
  }
725
731
  const u = {
726
732
  /**
@@ -728,57 +734,57 @@ function is(n, e) {
728
734
  */
729
735
  schedule: (d, h = !1, m = !1) => {
730
736
  const g = m && r ? t : i;
731
- return h && a.add(d), g.has(d) || g.add(d), d;
737
+ return h && s.add(d), g.has(d) || g.add(d), d;
732
738
  },
733
739
  /**
734
740
  * Cancel the provided callback from running on the next frame.
735
741
  */
736
742
  cancel: (d) => {
737
- i.delete(d), a.delete(d);
743
+ i.delete(d), s.delete(d);
738
744
  },
739
745
  /**
740
746
  * Execute all schedule callbacks.
741
747
  */
742
748
  process: (d) => {
743
749
  if (o = d, r) {
744
- s = !0;
750
+ a = !0;
745
751
  return;
746
752
  }
747
- r = !0, [t, i] = [i, t], t.forEach(l), t.clear(), r = !1, s && (s = !1, u.process(d));
753
+ r = !0, [t, i] = [i, t], t.forEach(l), t.clear(), r = !1, a && (a = !1, u.process(d));
748
754
  }
749
755
  };
750
756
  return u;
751
757
  }
752
- const de = {}, rs = 40;
753
- function ss(n, e) {
758
+ const de = {}, ra = 40;
759
+ function aa(n, e) {
754
760
  let t = !1, i = !0;
755
761
  const r = {
756
762
  delta: 0,
757
763
  timestamp: 0,
758
764
  isProcessing: !1
759
- }, s = () => t = !0, a = lt.reduce((_, M) => (_[M] = is(s), _), {}), { setup: o, read: l, resolveKeyframes: u, preUpdate: d, update: h, preRender: m, render: p, postRender: g } = a, b = () => {
765
+ }, a = () => t = !0, s = lt.reduce((_, M) => (_[M] = ia(a), _), {}), { setup: o, read: l, resolveKeyframes: u, preUpdate: d, update: h, preRender: m, render: p, postRender: g } = s, b = () => {
760
766
  const _ = de.useManualTiming ? r.timestamp : performance.now();
761
- t = !1, de.useManualTiming || (r.delta = i ? 1e3 / 60 : Math.max(Math.min(_ - r.timestamp, rs), 1)), r.timestamp = _, r.isProcessing = !0, o.process(r), l.process(r), u.process(r), d.process(r), h.process(r), m.process(r), p.process(r), g.process(r), r.isProcessing = !1, t && e && (i = !1, n(b));
767
+ t = !1, de.useManualTiming || (r.delta = i ? 1e3 / 60 : Math.max(Math.min(_ - r.timestamp, ra), 1)), r.timestamp = _, r.isProcessing = !0, o.process(r), l.process(r), u.process(r), d.process(r), h.process(r), m.process(r), p.process(r), g.process(r), r.isProcessing = !1, t && e && (i = !1, n(b));
762
768
  }, y = () => {
763
769
  t = !0, i = !0, r.isProcessing || n(b);
764
770
  };
765
771
  return { schedule: lt.reduce((_, M) => {
766
- const T = a[M];
772
+ const T = s[M];
767
773
  return _[M] = (D, C = !1, w = !1) => (t || y(), T.schedule(D, C, w)), _;
768
774
  }, {}), cancel: (_) => {
769
775
  for (let M = 0; M < lt.length; M++)
770
- a[lt[M]].cancel(_);
771
- }, state: r, steps: a };
776
+ s[lt[M]].cancel(_);
777
+ }, state: r, steps: s };
772
778
  }
773
- const De = /* @__NO_SIDE_EFFECTS__ */ (n) => n, { schedule: ue, cancel: Rt, state: ft } = /* @__PURE__ */ ss(typeof requestAnimationFrame != "undefined" ? requestAnimationFrame : De, !0);
779
+ const De = /* @__NO_SIDE_EFFECTS__ */ (n) => n, { schedule: ue, cancel: Rt, state: ft } = /* @__PURE__ */ aa(typeof requestAnimationFrame != "undefined" ? requestAnimationFrame : De, !0);
774
780
  let pt;
775
- function as() {
781
+ function sa() {
776
782
  pt = void 0;
777
783
  }
778
784
  const ee = {
779
785
  now: () => (pt === void 0 && ee.set(ft.isProcessing || de.useManualTiming ? ft.timestamp : performance.now()), pt),
780
786
  set: (n) => {
781
- pt = n, queueMicrotask(as);
787
+ pt = n, queueMicrotask(sa);
782
788
  }
783
789
  }, Vn = /* @__PURE__ */ new Set();
784
790
  function ki(n, e, t) {
@@ -797,9 +803,9 @@ class Ei {
797
803
  if (r === 1)
798
804
  this.subscriptions[0](e, t, i);
799
805
  else
800
- for (let s = 0; s < r; s++) {
801
- const a = this.subscriptions[s];
802
- a && a(e, t, i);
806
+ for (let a = 0; a < r; a++) {
807
+ const s = this.subscriptions[a];
808
+ s && s(e, t, i);
803
809
  }
804
810
  }
805
811
  getSize() {
@@ -812,8 +818,8 @@ class Ei {
812
818
  function xi(n, e) {
813
819
  return e ? n * (1e3 / e) : 0;
814
820
  }
815
- const In = 30, os = (n) => !isNaN(parseFloat(n));
816
- class ls {
821
+ const In = 30, oa = (n) => !isNaN(parseFloat(n));
822
+ class la {
817
823
  /**
818
824
  * @param init - The initiating value
819
825
  * @param config - Optional configuration options
@@ -822,16 +828,16 @@ class ls {
822
828
  */
823
829
  constructor(e, t = {}) {
824
830
  this.canTrackVelocity = null, this.events = {}, this.updateAndNotify = (i, r = !0) => {
825
- var a, o;
826
- const s = ee.now();
827
- if (this.updatedAt !== s && this.setPrevFrameValue(), this.prev = this.current, this.setCurrent(i), this.current !== this.prev && ((a = this.events.change) == null || a.notify(this.current), this.dependents))
831
+ var s, o;
832
+ const a = ee.now();
833
+ if (this.updatedAt !== a && this.setPrevFrameValue(), this.prev = this.current, this.setCurrent(i), this.current !== this.prev && ((s = this.events.change) == null || s.notify(this.current), this.dependents))
828
834
  for (const l of this.dependents)
829
835
  l.dirty();
830
836
  r && ((o = this.events.renderRequest) == null || o.notify(this.current));
831
837
  }, this.hasAnimated = !1, this.setCurrent(e), this.owner = t.owner;
832
838
  }
833
839
  setCurrent(e) {
834
- this.current = e, this.updatedAt = ee.now(), this.canTrackVelocity === null && e !== void 0 && (this.canTrackVelocity = os(this.current));
840
+ this.current = e, this.updatedAt = ee.now(), this.canTrackVelocity === null && e !== void 0 && (this.canTrackVelocity = oa(this.current));
835
841
  }
836
842
  setPrevFrameValue(e = this.current) {
837
843
  this.prevFrameValue = e, this.prevUpdatedAt = this.updatedAt;
@@ -1017,42 +1023,42 @@ class ls {
1017
1023
  }
1018
1024
  }
1019
1025
  function Xe(n, e) {
1020
- return new ls(n, e);
1026
+ return new la(n, e);
1021
1027
  }
1022
- function cs(n, e, t) {
1028
+ function ca(n, e, t) {
1023
1029
  n.hasValue(e) ? n.getValue(e).set(t) : n.addValue(e, Xe(t));
1024
1030
  }
1025
- function ds(n) {
1026
- return ts(n) ? n[n.length - 1] || 0 : n;
1031
+ function da(n) {
1032
+ return ta(n) ? n[n.length - 1] || 0 : n;
1027
1033
  }
1028
- function us(n, e) {
1029
- let a = ns(n, e) || {}, { transitionEnd: i = {}, transition: r = {} } = a, s = se(a, ["transitionEnd", "transition"]);
1030
- s = v(v({}, s), i);
1031
- for (const o in s) {
1032
- const l = ds(s[o]);
1033
- cs(n, o, l);
1034
+ function ua(n, e) {
1035
+ let s = na(n, e) || {}, { transitionEnd: i = {}, transition: r = {} } = s, a = ae(s, ["transitionEnd", "transition"]);
1036
+ a = v(v({}, a), i);
1037
+ for (const o in a) {
1038
+ const l = da(a[o]);
1039
+ ca(n, o, l);
1034
1040
  }
1035
1041
  }
1036
- function hs(n) {
1042
+ function ha(n) {
1037
1043
  return !!(J(n) && n.add);
1038
1044
  }
1039
- function ps(n, e) {
1045
+ function pa(n, e) {
1040
1046
  const t = n.getValue("willChange");
1041
- if (hs(t))
1047
+ if (ha(t))
1042
1048
  return t.add(e);
1043
1049
  if (!t && de.WillChange) {
1044
1050
  const i = new de.WillChange("auto");
1045
1051
  n.addValue("willChange", i), i.add(e);
1046
1052
  }
1047
1053
  }
1048
- const rn = (n) => n.replace(/([a-z])([A-Z])/gu, "$1-$2").toLowerCase(), ms = "framerAppearId", fs = "data-" + rn(ms);
1049
- function gs(n) {
1050
- return n.props[fs];
1054
+ const rn = (n) => n.replace(/([a-z])([A-Z])/gu, "$1-$2").toLowerCase(), ma = "framerAppearId", fa = "data-" + rn(ma);
1055
+ function ga(n) {
1056
+ return n.props[fa];
1051
1057
  }
1052
- const bs = (n) => n !== null;
1053
- function vs(n, { repeat: e, repeatType: t = "loop" }, i) {
1054
- const r = n.filter(bs), s = e && t !== "loop" && e % 2 === 1 ? 0 : r.length - 1;
1055
- return r[s];
1058
+ const ba = (n) => n !== null;
1059
+ function va(n, { repeat: e, repeatType: t = "loop" }, i) {
1060
+ const r = n.filter(ba), a = e && t !== "loop" && e % 2 === 1 ? 0 : r.length - 1;
1061
+ return r[a];
1056
1062
  }
1057
1063
  const Re = [
1058
1064
  "transformPerspective",
@@ -1072,33 +1078,33 @@ const Re = [
1072
1078
  "skew",
1073
1079
  "skewX",
1074
1080
  "skewY"
1075
- ], Oe = new Set(Re), ys = {
1081
+ ], Oe = new Set(Re), ya = {
1076
1082
  type: "spring",
1077
1083
  stiffness: 500,
1078
1084
  damping: 25,
1079
1085
  restSpeed: 10
1080
- }, Cs = (n) => ({
1086
+ }, Ca = (n) => ({
1081
1087
  type: "spring",
1082
1088
  stiffness: 550,
1083
1089
  damping: n === 0 ? 2 * Math.sqrt(550) : 30,
1084
1090
  restSpeed: 10
1085
- }), ks = {
1091
+ }), ka = {
1086
1092
  type: "keyframes",
1087
1093
  duration: 0.8
1088
- }, Es = {
1094
+ }, Ea = {
1089
1095
  type: "keyframes",
1090
1096
  ease: [0.25, 0.1, 0.35, 1],
1091
1097
  duration: 0.3
1092
- }, xs = (n, { keyframes: e }) => e.length > 2 ? ks : Oe.has(n) ? n.startsWith("scale") ? Cs(e[1]) : ys : Es;
1093
- function ws(h) {
1094
- var m = h, { when: n, delay: e, delayChildren: t, staggerChildren: i, staggerDirection: r, repeat: s, repeatType: a, repeatDelay: o, from: l, elapsed: u } = m, d = se(m, ["when", "delay", "delayChildren", "staggerChildren", "staggerDirection", "repeat", "repeatType", "repeatDelay", "from", "elapsed"]);
1098
+ }, xa = (n, { keyframes: e }) => e.length > 2 ? ka : Oe.has(n) ? n.startsWith("scale") ? Ca(e[1]) : ya : Ea;
1099
+ function wa(h) {
1100
+ var m = h, { when: n, delay: e, delayChildren: t, staggerChildren: i, staggerDirection: r, repeat: a, repeatType: s, repeatDelay: o, from: l, elapsed: u } = m, d = ae(m, ["when", "delay", "delayChildren", "staggerChildren", "staggerDirection", "repeat", "repeatType", "repeatDelay", "from", "elapsed"]);
1095
1101
  return !!Object.keys(d).length;
1096
1102
  }
1097
1103
  function wi(n, e) {
1098
1104
  var t, i;
1099
1105
  return (i = (t = n == null ? void 0 : n[e]) != null ? t : n == null ? void 0 : n.default) != null ? i : n;
1100
1106
  }
1101
- const Ti = (n) => (e) => typeof e == "string" && e.startsWith(n), Ai = /* @__PURE__ */ Ti("--"), Ts = /* @__PURE__ */ Ti("var(--"), sn = (n) => Ts(n) ? As.test(n.split("/*")[0].trim()) : !1, As = /var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu, xe = (n, e, t) => t > e ? e : t < n ? n : t, Ne = {
1107
+ const Ti = (n) => (e) => typeof e == "string" && e.startsWith(n), Ai = /* @__PURE__ */ Ti("--"), Ta = /* @__PURE__ */ Ti("var(--"), an = (n) => Ta(n) ? Aa.test(n.split("/*")[0].trim()) : !1, Aa = /var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu, xe = (n, e, t) => t > e ? e : t < n ? n : t, Ne = {
1102
1108
  test: (n) => typeof n == "number",
1103
1109
  parse: parseFloat,
1104
1110
  transform: (n) => n
@@ -1106,28 +1112,28 @@ const Ti = (n) => (e) => typeof e == "string" && e.startsWith(n), Ai = /* @__PUR
1106
1112
  transform: (n) => xe(0, 1, n)
1107
1113
  }), ct = I(v({}, Ne), {
1108
1114
  default: 1
1109
- }), We = (n) => Math.round(n * 1e5) / 1e5, an = /-?(?:\d+(?:\.\d+)?|\.\d+)/gu;
1110
- function _s(n) {
1115
+ }), We = (n) => Math.round(n * 1e5) / 1e5, sn = /-?(?:\d+(?:\.\d+)?|\.\d+)/gu;
1116
+ function _a(n) {
1111
1117
  return n == null;
1112
1118
  }
1113
- const Ls = /^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu, on = (n, e) => (t) => !!(typeof t == "string" && Ls.test(t) && t.startsWith(n) || e && !_s(t) && Object.prototype.hasOwnProperty.call(t, e)), _i = (n, e, t) => (i) => {
1119
+ const La = /^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu, on = (n, e) => (t) => !!(typeof t == "string" && La.test(t) && t.startsWith(n) || e && !_a(t) && Object.prototype.hasOwnProperty.call(t, e)), _i = (n, e, t) => (i) => {
1114
1120
  if (typeof i != "string")
1115
1121
  return i;
1116
- const [r, s, a, o] = i.match(an);
1122
+ const [r, a, s, o] = i.match(sn);
1117
1123
  return {
1118
1124
  [n]: parseFloat(r),
1119
- [e]: parseFloat(s),
1120
- [t]: parseFloat(a),
1125
+ [e]: parseFloat(a),
1126
+ [t]: parseFloat(s),
1121
1127
  alpha: o !== void 0 ? parseFloat(o) : 1
1122
1128
  };
1123
- }, Vs = (n) => xe(0, 255, n), wt = I(v({}, Ne), {
1124
- transform: (n) => Math.round(Vs(n))
1129
+ }, Va = (n) => xe(0, 255, n), wt = I(v({}, Ne), {
1130
+ transform: (n) => Math.round(Va(n))
1125
1131
  }), ye = {
1126
1132
  test: /* @__PURE__ */ on("rgb", "red"),
1127
1133
  parse: /* @__PURE__ */ _i("red", "green", "blue"),
1128
1134
  transform: ({ red: n, green: e, blue: t, alpha: i = 1 }) => "rgba(" + wt.transform(n) + ", " + wt.transform(e) + ", " + wt.transform(t) + ", " + We(Qe.transform(i)) + ")"
1129
1135
  };
1130
- function Is(n) {
1136
+ function Ia(n) {
1131
1137
  let e = "", t = "", i = "", r = "";
1132
1138
  return n.length > 5 ? (e = n.substring(1, 3), t = n.substring(3, 5), i = n.substring(5, 7), r = n.substring(7, 9)) : (e = n.substring(1, 2), t = n.substring(2, 3), i = n.substring(3, 4), r = n.substring(4, 5), e += e, t += t, i += i, r += r), {
1133
1139
  red: parseInt(e, 16),
@@ -1138,13 +1144,13 @@ function Is(n) {
1138
1144
  }
1139
1145
  const Ot = {
1140
1146
  test: /* @__PURE__ */ on("#"),
1141
- parse: Is,
1147
+ parse: Ia,
1142
1148
  transform: ye.transform
1143
1149
  }, rt = /* @__NO_SIDE_EFFECTS__ */ (n) => ({
1144
1150
  test: (e) => typeof e == "string" && e.endsWith(n) && e.split(" ").length === 1,
1145
1151
  parse: parseFloat,
1146
1152
  transform: (e) => `${e}${n}`
1147
- }), me = /* @__PURE__ */ rt("deg"), Me = /* @__PURE__ */ rt("%"), L = /* @__PURE__ */ rt("px"), Ms = /* @__PURE__ */ rt("vh"), Ps = /* @__PURE__ */ rt("vw"), Mn = I(v({}, Me), {
1153
+ }), me = /* @__PURE__ */ rt("deg"), Me = /* @__PURE__ */ rt("%"), L = /* @__PURE__ */ rt("px"), Ma = /* @__PURE__ */ rt("vh"), Pa = /* @__PURE__ */ rt("vw"), Mn = I(v({}, Me), {
1148
1154
  parse: (n) => Me.parse(n) / 100,
1149
1155
  transform: (n) => Me.transform(n * 100)
1150
1156
  }), Ve = {
@@ -1155,20 +1161,20 @@ const Ot = {
1155
1161
  test: (n) => ye.test(n) || Ot.test(n) || Ve.test(n),
1156
1162
  parse: (n) => ye.test(n) ? ye.parse(n) : Ve.test(n) ? Ve.parse(n) : Ot.parse(n),
1157
1163
  transform: (n) => typeof n == "string" ? n : n.hasOwnProperty("red") ? ye.transform(n) : Ve.transform(n)
1158
- }, Ds = /(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;
1159
- function Rs(n) {
1164
+ }, Da = /(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;
1165
+ function Ra(n) {
1160
1166
  var e, t;
1161
- return isNaN(n) && typeof n == "string" && (((e = n.match(an)) == null ? void 0 : e.length) || 0) + (((t = n.match(Ds)) == null ? void 0 : t.length) || 0) > 0;
1167
+ return isNaN(n) && typeof n == "string" && (((e = n.match(sn)) == null ? void 0 : e.length) || 0) + (((t = n.match(Da)) == null ? void 0 : t.length) || 0) > 0;
1162
1168
  }
1163
- const Li = "number", Vi = "color", Os = "var", Ns = "var(", Pn = "${}", Ss = /var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;
1169
+ const Li = "number", Vi = "color", Oa = "var", Na = "var(", Pn = "${}", Sa = /var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;
1164
1170
  function et(n) {
1165
1171
  const e = n.toString(), t = [], i = {
1166
1172
  color: [],
1167
1173
  number: [],
1168
1174
  var: []
1169
1175
  }, r = [];
1170
- let s = 0;
1171
- const o = e.replace(Ss, (l) => (U.test(l) ? (i.color.push(s), r.push(Vi), t.push(U.parse(l))) : l.startsWith(Ns) ? (i.var.push(s), r.push(Os), t.push(l)) : (i.number.push(s), r.push(Li), t.push(parseFloat(l))), ++s, Pn)).split(Pn);
1176
+ let a = 0;
1177
+ const o = e.replace(Sa, (l) => (U.test(l) ? (i.color.push(a), r.push(Vi), t.push(U.parse(l))) : l.startsWith(Na) ? (i.var.push(a), r.push(Oa), t.push(l)) : (i.number.push(a), r.push(Li), t.push(parseFloat(l))), ++a, Pn)).split(Pn);
1172
1178
  return { values: t, split: o, indexes: i, types: r };
1173
1179
  }
1174
1180
  function Ii(n) {
@@ -1177,42 +1183,42 @@ function Ii(n) {
1177
1183
  function Mi(n) {
1178
1184
  const { split: e, types: t } = et(n), i = e.length;
1179
1185
  return (r) => {
1180
- let s = "";
1181
- for (let a = 0; a < i; a++)
1182
- if (s += e[a], r[a] !== void 0) {
1183
- const o = t[a];
1184
- o === Li ? s += We(r[a]) : o === Vi ? s += U.transform(r[a]) : s += r[a];
1186
+ let a = "";
1187
+ for (let s = 0; s < i; s++)
1188
+ if (a += e[s], r[s] !== void 0) {
1189
+ const o = t[s];
1190
+ o === Li ? a += We(r[s]) : o === Vi ? a += U.transform(r[s]) : a += r[s];
1185
1191
  }
1186
- return s;
1192
+ return a;
1187
1193
  };
1188
1194
  }
1189
- const Fs = (n) => typeof n == "number" ? 0 : n;
1190
- function js(n) {
1195
+ const Fa = (n) => typeof n == "number" ? 0 : n;
1196
+ function ja(n) {
1191
1197
  const e = Ii(n);
1192
- return Mi(n)(e.map(Fs));
1198
+ return Mi(n)(e.map(Fa));
1193
1199
  }
1194
1200
  const Se = {
1195
- test: Rs,
1201
+ test: Ra,
1196
1202
  parse: Ii,
1197
1203
  createTransformer: Mi,
1198
- getAnimatableNone: js
1204
+ getAnimatableNone: ja
1199
1205
  };
1200
1206
  function Tt(n, e, t) {
1201
1207
  return t < 0 && (t += 1), t > 1 && (t -= 1), t < 1 / 6 ? n + (e - n) * 6 * t : t < 1 / 2 ? e : t < 2 / 3 ? n + (e - n) * (2 / 3 - t) * 6 : n;
1202
1208
  }
1203
- function Bs({ hue: n, saturation: e, lightness: t, alpha: i }) {
1209
+ function Ba({ hue: n, saturation: e, lightness: t, alpha: i }) {
1204
1210
  n /= 360, e /= 100, t /= 100;
1205
- let r = 0, s = 0, a = 0;
1211
+ let r = 0, a = 0, s = 0;
1206
1212
  if (!e)
1207
- r = s = a = t;
1213
+ r = a = s = t;
1208
1214
  else {
1209
1215
  const o = t < 0.5 ? t * (1 + e) : t + e - t * e, l = 2 * t - o;
1210
- r = Tt(l, o, n + 1 / 3), s = Tt(l, o, n), a = Tt(l, o, n - 1 / 3);
1216
+ r = Tt(l, o, n + 1 / 3), a = Tt(l, o, n), s = Tt(l, o, n - 1 / 3);
1211
1217
  }
1212
1218
  return {
1213
1219
  red: Math.round(r * 255),
1214
- green: Math.round(s * 255),
1215
- blue: Math.round(a * 255),
1220
+ green: Math.round(a * 255),
1221
+ blue: Math.round(s * 255),
1216
1222
  alpha: i
1217
1223
  };
1218
1224
  }
@@ -1222,66 +1228,66 @@ function gt(n, e) {
1222
1228
  const At = (n, e, t) => {
1223
1229
  const i = n * n, r = t * (e * e - i) + i;
1224
1230
  return r < 0 ? 0 : Math.sqrt(r);
1225
- }, zs = [Ot, ye, Ve], $s = (n) => zs.find((e) => e.test(n));
1231
+ }, za = [Ot, ye, Ve], $a = (n) => za.find((e) => e.test(n));
1226
1232
  function Dn(n) {
1227
- const e = $s(n);
1233
+ const e = $a(n);
1228
1234
  if (it(!!e, `'${n}' is not an animatable color. Use the equivalent color code instead.`), !e)
1229
1235
  return !1;
1230
1236
  let t = e.parse(n);
1231
- return e === Ve && (t = Bs(t)), t;
1237
+ return e === Ve && (t = Ba(t)), t;
1232
1238
  }
1233
1239
  const Rn = (n, e) => {
1234
1240
  const t = Dn(n), i = Dn(e);
1235
1241
  if (!t || !i)
1236
1242
  return gt(n, e);
1237
1243
  const r = v({}, t);
1238
- return (s) => (r.red = At(t.red, i.red, s), r.green = At(t.green, i.green, s), r.blue = At(t.blue, i.blue, s), r.alpha = nt(t.alpha, i.alpha, s), ye.transform(r));
1244
+ return (a) => (r.red = At(t.red, i.red, a), r.green = At(t.green, i.green, a), r.blue = At(t.blue, i.blue, a), r.alpha = nt(t.alpha, i.alpha, a), ye.transform(r));
1239
1245
  }, Nt = /* @__PURE__ */ new Set(["none", "hidden"]);
1240
- function Ks(n, e) {
1246
+ function Ka(n, e) {
1241
1247
  return Nt.has(n) ? (t) => t <= 0 ? n : e : (t) => t >= 1 ? e : n;
1242
1248
  }
1243
- const qs = (n, e) => (t) => e(n(t)), ln = (...n) => n.reduce(qs);
1244
- function Gs(n, e) {
1249
+ const qa = (n, e) => (t) => e(n(t)), ln = (...n) => n.reduce(qa);
1250
+ function Ga(n, e) {
1245
1251
  return (t) => nt(n, e, t);
1246
1252
  }
1247
1253
  function cn(n) {
1248
- return typeof n == "number" ? Gs : typeof n == "string" ? sn(n) ? gt : U.test(n) ? Rn : Us : Array.isArray(n) ? Pi : typeof n == "object" ? U.test(n) ? Rn : Hs : gt;
1254
+ return typeof n == "number" ? Ga : typeof n == "string" ? an(n) ? gt : U.test(n) ? Rn : Ua : Array.isArray(n) ? Pi : typeof n == "object" ? U.test(n) ? Rn : Ha : gt;
1249
1255
  }
1250
1256
  function Pi(n, e) {
1251
- const t = [...n], i = t.length, r = n.map((s, a) => cn(s)(s, e[a]));
1252
- return (s) => {
1253
- for (let a = 0; a < i; a++)
1254
- t[a] = r[a](s);
1257
+ const t = [...n], i = t.length, r = n.map((a, s) => cn(a)(a, e[s]));
1258
+ return (a) => {
1259
+ for (let s = 0; s < i; s++)
1260
+ t[s] = r[s](a);
1255
1261
  return t;
1256
1262
  };
1257
1263
  }
1258
- function Hs(n, e) {
1264
+ function Ha(n, e) {
1259
1265
  const t = v(v({}, n), e), i = {};
1260
1266
  for (const r in t)
1261
1267
  n[r] !== void 0 && e[r] !== void 0 && (i[r] = cn(n[r])(n[r], e[r]));
1262
1268
  return (r) => {
1263
- for (const s in i)
1264
- t[s] = i[s](r);
1269
+ for (const a in i)
1270
+ t[a] = i[a](r);
1265
1271
  return t;
1266
1272
  };
1267
1273
  }
1268
- function Ys(n, e) {
1274
+ function Ya(n, e) {
1269
1275
  var r;
1270
1276
  const t = [], i = { color: 0, var: 0, number: 0 };
1271
- for (let s = 0; s < e.values.length; s++) {
1272
- const a = e.types[s], o = n.indexes[a][i[a]], l = (r = n.values[o]) != null ? r : 0;
1273
- t[s] = l, i[a]++;
1277
+ for (let a = 0; a < e.values.length; a++) {
1278
+ const s = e.types[a], o = n.indexes[s][i[s]], l = (r = n.values[o]) != null ? r : 0;
1279
+ t[a] = l, i[s]++;
1274
1280
  }
1275
1281
  return t;
1276
1282
  }
1277
- const Us = (n, e) => {
1283
+ const Ua = (n, e) => {
1278
1284
  const t = Se.createTransformer(e), i = et(n), r = et(e);
1279
- return i.indexes.var.length === r.indexes.var.length && i.indexes.color.length === r.indexes.color.length && i.indexes.number.length >= r.indexes.number.length ? Nt.has(n) && !r.values.length || Nt.has(e) && !i.values.length ? Ks(n, e) : ln(Pi(Ys(i, r), r.values), t) : (it(!0, `Complex values '${n}' and '${e}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`), gt(n, e));
1285
+ return i.indexes.var.length === r.indexes.var.length && i.indexes.color.length === r.indexes.color.length && i.indexes.number.length >= r.indexes.number.length ? Nt.has(n) && !r.values.length || Nt.has(e) && !i.values.length ? Ka(n, e) : ln(Pi(Ya(i, r), r.values), t) : (it(!0, `Complex values '${n}' and '${e}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`), gt(n, e));
1280
1286
  };
1281
1287
  function Di(n, e, t) {
1282
1288
  return typeof n == "number" && typeof e == "number" && typeof t == "number" ? nt(n, e, t) : cn(n)(n, e);
1283
1289
  }
1284
- const Ws = (n) => {
1290
+ const Wa = (n) => {
1285
1291
  const e = ({ timestamp: t }) => n(t);
1286
1292
  return {
1287
1293
  start: (t = !0) => ue.update(e, t),
@@ -1295,12 +1301,12 @@ const Ws = (n) => {
1295
1301
  }, Ri = (n, e, t = 10) => {
1296
1302
  let i = "";
1297
1303
  const r = Math.max(Math.round(e / t), 2);
1298
- for (let s = 0; s < r; s++)
1299
- i += n(s / (r - 1)) + ", ";
1304
+ for (let a = 0; a < r; a++)
1305
+ i += n(a / (r - 1)) + ", ";
1300
1306
  return `linear(${i.substring(0, i.length - 2)})`;
1301
- }, Zs = 5;
1307
+ }, Za = 5;
1302
1308
  function Oi(n, e, t) {
1303
- const i = Math.max(e - Zs, 0);
1309
+ const i = Math.max(e - Za, 0);
1304
1310
  return xi(t - n(i), e - i);
1305
1311
  }
1306
1312
  const B = {
@@ -1332,25 +1338,25 @@ const B = {
1332
1338
  minDamping: 0.05,
1333
1339
  maxDamping: 1
1334
1340
  }, _t = 1e-3;
1335
- function Js({ duration: n = B.duration, bounce: e = B.bounce, velocity: t = B.velocity, mass: i = B.mass }) {
1336
- let r, s;
1337
- it(n <= /* @__PURE__ */ ae(B.maxDuration), "Spring duration must be 10 seconds or less");
1338
- let a = 1 - e;
1339
- a = xe(B.minDamping, B.maxDamping, a), n = xe(B.minDuration, B.maxDuration, /* @__PURE__ */ le(n)), a < 1 ? (r = (u) => {
1340
- const d = u * a, h = d * n, m = d - t, p = St(u, a), g = Math.exp(-h);
1341
+ function Ja({ duration: n = B.duration, bounce: e = B.bounce, velocity: t = B.velocity, mass: i = B.mass }) {
1342
+ let r, a;
1343
+ it(n <= /* @__PURE__ */ se(B.maxDuration), "Spring duration must be 10 seconds or less");
1344
+ let s = 1 - e;
1345
+ s = xe(B.minDamping, B.maxDamping, s), n = xe(B.minDuration, B.maxDuration, /* @__PURE__ */ le(n)), s < 1 ? (r = (u) => {
1346
+ const d = u * s, h = d * n, m = d - t, p = St(u, s), g = Math.exp(-h);
1341
1347
  return _t - m / p * g;
1342
- }, s = (u) => {
1343
- const h = u * a * n, m = h * t + t, p = Math.pow(a, 2) * Math.pow(u, 2) * n, g = Math.exp(-h), b = St(Math.pow(u, 2), a);
1348
+ }, a = (u) => {
1349
+ const h = u * s * n, m = h * t + t, p = Math.pow(s, 2) * Math.pow(u, 2) * n, g = Math.exp(-h), b = St(Math.pow(u, 2), s);
1344
1350
  return (-r(u) + _t > 0 ? -1 : 1) * ((m - p) * g) / b;
1345
1351
  }) : (r = (u) => {
1346
1352
  const d = Math.exp(-u * n), h = (u - t) * n + 1;
1347
1353
  return -_t + d * h;
1348
- }, s = (u) => {
1354
+ }, a = (u) => {
1349
1355
  const d = Math.exp(-u * n), h = (t - u) * (n * n);
1350
1356
  return d * h;
1351
1357
  });
1352
- const o = 5 / n, l = Qs(r, s, o);
1353
- if (n = /* @__PURE__ */ ae(n), isNaN(l))
1358
+ const o = 5 / n, l = Qa(r, a, o);
1359
+ if (n = /* @__PURE__ */ se(n), isNaN(l))
1354
1360
  return {
1355
1361
  stiffness: B.stiffness,
1356
1362
  damping: B.damping,
@@ -1360,26 +1366,26 @@ function Js({ duration: n = B.duration, bounce: e = B.bounce, velocity: t = B.ve
1360
1366
  const u = Math.pow(l, 2) * i;
1361
1367
  return {
1362
1368
  stiffness: u,
1363
- damping: a * 2 * Math.sqrt(i * u),
1369
+ damping: s * 2 * Math.sqrt(i * u),
1364
1370
  duration: n
1365
1371
  };
1366
1372
  }
1367
1373
  }
1368
- const Xs = 12;
1369
- function Qs(n, e, t) {
1374
+ const Xa = 12;
1375
+ function Qa(n, e, t) {
1370
1376
  let i = t;
1371
- for (let r = 1; r < Xs; r++)
1377
+ for (let r = 1; r < Xa; r++)
1372
1378
  i = i - n(i) / e(i);
1373
1379
  return i;
1374
1380
  }
1375
1381
  function St(n, e) {
1376
1382
  return n * Math.sqrt(1 - e * e);
1377
1383
  }
1378
- const ea = ["duration", "bounce"], ta = ["stiffness", "damping", "mass"];
1384
+ const es = ["duration", "bounce"], ts = ["stiffness", "damping", "mass"];
1379
1385
  function On(n, e) {
1380
1386
  return e.some((t) => n[t] !== void 0);
1381
1387
  }
1382
- function na(n) {
1388
+ function ns(n) {
1383
1389
  let e = v({
1384
1390
  velocity: B.velocity,
1385
1391
  stiffness: B.stiffness,
@@ -1387,16 +1393,16 @@ function na(n) {
1387
1393
  mass: B.mass,
1388
1394
  isResolvedFromDuration: !1
1389
1395
  }, n);
1390
- if (!On(n, ta) && On(n, ea))
1396
+ if (!On(n, ts) && On(n, es))
1391
1397
  if (n.visualDuration) {
1392
- const t = n.visualDuration, i = 2 * Math.PI / (t * 1.2), r = i * i, s = 2 * xe(0.05, 1, 1 - (n.bounce || 0)) * Math.sqrt(r);
1398
+ const t = n.visualDuration, i = 2 * Math.PI / (t * 1.2), r = i * i, a = 2 * xe(0.05, 1, 1 - (n.bounce || 0)) * Math.sqrt(r);
1393
1399
  e = I(v({}, e), {
1394
1400
  mass: B.mass,
1395
1401
  stiffness: r,
1396
- damping: s
1402
+ damping: a
1397
1403
  });
1398
1404
  } else {
1399
- const t = Js(n);
1405
+ const t = Ja(n);
1400
1406
  e = I(v(v({}, e), t), {
1401
1407
  mass: B.mass
1402
1408
  }), e.isResolvedFromDuration = !0;
@@ -1410,24 +1416,24 @@ function tt(n = B.visualDuration, e = B.bounce) {
1410
1416
  bounce: e
1411
1417
  } : n;
1412
1418
  let { restSpeed: i, restDelta: r } = t;
1413
- const s = t.keyframes[0], a = t.keyframes[t.keyframes.length - 1], o = { done: !1, value: s }, { stiffness: l, damping: u, mass: d, duration: h, velocity: m, isResolvedFromDuration: p } = na(I(v({}, t), {
1419
+ const a = t.keyframes[0], s = t.keyframes[t.keyframes.length - 1], o = { done: !1, value: a }, { stiffness: l, damping: u, mass: d, duration: h, velocity: m, isResolvedFromDuration: p } = ns(I(v({}, t), {
1414
1420
  velocity: -/* @__PURE__ */ le(t.velocity || 0)
1415
- })), g = m || 0, b = u / (2 * Math.sqrt(l * d)), y = a - s, k = /* @__PURE__ */ le(Math.sqrt(l / d)), V = Math.abs(y) < 5;
1421
+ })), g = m || 0, b = u / (2 * Math.sqrt(l * d)), y = s - a, E = /* @__PURE__ */ le(Math.sqrt(l / d)), V = Math.abs(y) < 5;
1416
1422
  i || (i = V ? B.restSpeed.granular : B.restSpeed.default), r || (r = V ? B.restDelta.granular : B.restDelta.default);
1417
1423
  let _;
1418
1424
  if (b < 1) {
1419
- const T = St(k, b);
1425
+ const T = St(E, b);
1420
1426
  _ = (D) => {
1421
- const C = Math.exp(-b * k * D);
1422
- return a - C * ((g + b * k * y) / T * Math.sin(T * D) + y * Math.cos(T * D));
1427
+ const C = Math.exp(-b * E * D);
1428
+ return s - C * ((g + b * E * y) / T * Math.sin(T * D) + y * Math.cos(T * D));
1423
1429
  };
1424
1430
  } else if (b === 1)
1425
- _ = (T) => a - Math.exp(-k * T) * (y + (g + k * y) * T);
1431
+ _ = (T) => s - Math.exp(-E * T) * (y + (g + E * y) * T);
1426
1432
  else {
1427
- const T = k * Math.sqrt(b * b - 1);
1433
+ const T = E * Math.sqrt(b * b - 1);
1428
1434
  _ = (D) => {
1429
- const C = Math.exp(-b * k * D), w = Math.min(T * D, 300);
1430
- return a - C * ((g + b * k * y) * Math.sinh(w) + T * y * Math.cosh(w)) / T;
1435
+ const C = Math.exp(-b * E * D), w = Math.min(T * D, 300);
1436
+ return s - C * ((g + b * E * y) * Math.sinh(w) + T * y * Math.cosh(w)) / T;
1431
1437
  };
1432
1438
  }
1433
1439
  const M = {
@@ -1438,11 +1444,11 @@ function tt(n = B.visualDuration, e = B.bounce) {
1438
1444
  o.done = T >= h;
1439
1445
  else {
1440
1446
  let C = T === 0 ? g : 0;
1441
- b < 1 && (C = T === 0 ? /* @__PURE__ */ ae(g) : Oi(_, T, D));
1442
- const w = Math.abs(C) <= i, R = Math.abs(a - D) <= r;
1447
+ b < 1 && (C = T === 0 ? /* @__PURE__ */ se(g) : Oi(_, T, D));
1448
+ const w = Math.abs(C) <= i, R = Math.abs(s - D) <= r;
1443
1449
  o.done = w && R;
1444
1450
  }
1445
- return o.value = o.done ? a : D, o;
1451
+ return o.value = o.done ? s : D, o;
1446
1452
  },
1447
1453
  toString: () => {
1448
1454
  const T = Math.min(nn(M), mt), D = Ri((C) => M.next(T * C).value, T, 30);
@@ -1455,19 +1461,19 @@ function tt(n = B.visualDuration, e = B.bounce) {
1455
1461
  }
1456
1462
  tt.applyToOptions = (n) => {
1457
1463
  const e = yi(n, 100, tt);
1458
- return n.ease = e.ease, n.duration = /* @__PURE__ */ ae(e.duration), n.type = "keyframes", n;
1464
+ return n.ease = e.ease, n.duration = /* @__PURE__ */ se(e.duration), n.type = "keyframes", n;
1459
1465
  };
1460
- function Ft({ keyframes: n, velocity: e = 0, power: t = 0.8, timeConstant: i = 325, bounceDamping: r = 10, bounceStiffness: s = 500, modifyTarget: a, min: o, max: l, restDelta: u = 0.5, restSpeed: d }) {
1466
+ function Ft({ keyframes: n, velocity: e = 0, power: t = 0.8, timeConstant: i = 325, bounceDamping: r = 10, bounceStiffness: a = 500, modifyTarget: s, min: o, max: l, restDelta: u = 0.5, restSpeed: d }) {
1461
1467
  const h = n[0], m = {
1462
1468
  done: !1,
1463
1469
  value: h
1464
1470
  }, p = (w) => o !== void 0 && w < o || l !== void 0 && w > l, g = (w) => o === void 0 ? l : l === void 0 || Math.abs(o - w) < Math.abs(l - w) ? o : l;
1465
1471
  let b = t * e;
1466
- const y = h + b, k = a === void 0 ? y : a(y);
1467
- k !== y && (b = k - h);
1468
- const V = (w) => -b * Math.exp(-w / i), _ = (w) => k + V(w), M = (w) => {
1472
+ const y = h + b, E = s === void 0 ? y : s(y);
1473
+ E !== y && (b = E - h);
1474
+ const V = (w) => -b * Math.exp(-w / i), _ = (w) => E + V(w), M = (w) => {
1469
1475
  const R = V(w), O = _(w);
1470
- m.done = Math.abs(R) <= u, m.value = m.done ? k : O;
1476
+ m.done = Math.abs(R) <= u, m.value = m.done ? E : O;
1471
1477
  };
1472
1478
  let T, D;
1473
1479
  const C = (w) => {
@@ -1476,7 +1482,7 @@ function Ft({ keyframes: n, velocity: e = 0, power: t = 0.8, timeConstant: i = 3
1476
1482
  velocity: Oi(_, w, m.value),
1477
1483
  // TODO: This should be passing * 1000
1478
1484
  damping: r,
1479
- stiffness: s,
1485
+ stiffness: a,
1480
1486
  restDelta: u,
1481
1487
  restSpeed: d
1482
1488
  }));
@@ -1489,28 +1495,28 @@ function Ft({ keyframes: n, velocity: e = 0, power: t = 0.8, timeConstant: i = 3
1489
1495
  }
1490
1496
  };
1491
1497
  }
1492
- function ia(n, e, t) {
1493
- const i = [], r = t || de.mix || Di, s = n.length - 1;
1494
- for (let a = 0; a < s; a++) {
1495
- let o = r(n[a], n[a + 1]);
1498
+ function is(n, e, t) {
1499
+ const i = [], r = t || de.mix || Di, a = n.length - 1;
1500
+ for (let s = 0; s < a; s++) {
1501
+ let o = r(n[s], n[s + 1]);
1496
1502
  if (e) {
1497
- const l = Array.isArray(e) ? e[a] || De : e;
1503
+ const l = Array.isArray(e) ? e[s] || De : e;
1498
1504
  o = ln(l, o);
1499
1505
  }
1500
1506
  i.push(o);
1501
1507
  }
1502
1508
  return i;
1503
1509
  }
1504
- function ra(n, e, { clamp: t = !0, ease: i, mixer: r } = {}) {
1505
- const s = n.length;
1506
- if (ce(s === e.length, "Both input and output ranges must be the same length"), s === 1)
1510
+ function rs(n, e, { clamp: t = !0, ease: i, mixer: r } = {}) {
1511
+ const a = n.length;
1512
+ if (ce(a === e.length, "Both input and output ranges must be the same length"), a === 1)
1507
1513
  return () => e[0];
1508
- if (s === 2 && e[0] === e[1])
1514
+ if (a === 2 && e[0] === e[1])
1509
1515
  return () => e[1];
1510
- const a = n[0] === n[1];
1511
- n[0] > n[s - 1] && (n = [...n].reverse(), e = [...e].reverse());
1512
- const o = ia(e, i, r), l = o.length, u = (d) => {
1513
- if (a && d < n[0])
1516
+ const s = n[0] === n[1];
1517
+ n[0] > n[a - 1] && (n = [...n].reverse(), e = [...e].reverse());
1518
+ const o = is(e, i, r), l = o.length, u = (d) => {
1519
+ if (s && d < n[0])
1514
1520
  return e[0];
1515
1521
  let h = 0;
1516
1522
  if (l > 1)
@@ -1519,72 +1525,72 @@ function ra(n, e, { clamp: t = !0, ease: i, mixer: r } = {}) {
1519
1525
  const m = /* @__PURE__ */ en(n[h], n[h + 1], d);
1520
1526
  return o[h](m);
1521
1527
  };
1522
- return t ? (d) => u(xe(n[0], n[s - 1], d)) : u;
1528
+ return t ? (d) => u(xe(n[0], n[a - 1], d)) : u;
1523
1529
  }
1524
- function sa(n, e) {
1530
+ function as(n, e) {
1525
1531
  return n.map((t) => t * e);
1526
1532
  }
1527
- const Ni = (n, e, t) => (((1 - 3 * t + 3 * e) * n + (3 * t - 6 * e)) * n + 3 * e) * n, aa = 1e-7, oa = 12;
1528
- function la(n, e, t, i, r) {
1529
- let s, a, o = 0;
1533
+ const Ni = (n, e, t) => (((1 - 3 * t + 3 * e) * n + (3 * t - 6 * e)) * n + 3 * e) * n, ss = 1e-7, os = 12;
1534
+ function ls(n, e, t, i, r) {
1535
+ let a, s, o = 0;
1530
1536
  do
1531
- a = e + (t - e) / 2, s = Ni(a, i, r) - n, s > 0 ? t = a : e = a;
1532
- while (Math.abs(s) > aa && ++o < oa);
1533
- return a;
1537
+ s = e + (t - e) / 2, a = Ni(s, i, r) - n, a > 0 ? t = s : e = s;
1538
+ while (Math.abs(a) > ss && ++o < os);
1539
+ return s;
1534
1540
  }
1535
- function st(n, e, t, i) {
1541
+ function at(n, e, t, i) {
1536
1542
  if (n === e && t === i)
1537
1543
  return De;
1538
- const r = (s) => la(s, 0, 1, n, t);
1539
- return (s) => s === 0 || s === 1 ? s : Ni(r(s), e, i);
1544
+ const r = (a) => ls(a, 0, 1, n, t);
1545
+ return (a) => a === 0 || a === 1 ? a : Ni(r(a), e, i);
1540
1546
  }
1541
- const ca = /* @__PURE__ */ st(0.42, 0, 1, 1), da = /* @__PURE__ */ st(0, 0, 0.58, 1), Si = /* @__PURE__ */ st(0.42, 0, 0.58, 1), Fi = (n) => (e) => e <= 0.5 ? n(2 * e) / 2 : (2 - n(2 * (1 - e))) / 2, ji = (n) => (e) => 1 - n(1 - e), Bi = /* @__PURE__ */ st(0.33, 1.53, 0.69, 0.99), dn = /* @__PURE__ */ ji(Bi), zi = /* @__PURE__ */ Fi(dn), $i = (n) => (n *= 2) < 1 ? 0.5 * dn(n) : 0.5 * (2 - Math.pow(2, -10 * (n - 1))), un = (n) => 1 - Math.sin(Math.acos(n)), ua = ji(un), Ki = Fi(un), qi = (n) => Array.isArray(n) && typeof n[0] == "number", Nn = {
1547
+ const cs = /* @__PURE__ */ at(0.42, 0, 1, 1), ds = /* @__PURE__ */ at(0, 0, 0.58, 1), Si = /* @__PURE__ */ at(0.42, 0, 0.58, 1), Fi = (n) => (e) => e <= 0.5 ? n(2 * e) / 2 : (2 - n(2 * (1 - e))) / 2, ji = (n) => (e) => 1 - n(1 - e), Bi = /* @__PURE__ */ at(0.33, 1.53, 0.69, 0.99), dn = /* @__PURE__ */ ji(Bi), zi = /* @__PURE__ */ Fi(dn), $i = (n) => (n *= 2) < 1 ? 0.5 * dn(n) : 0.5 * (2 - Math.pow(2, -10 * (n - 1))), un = (n) => 1 - Math.sin(Math.acos(n)), us = ji(un), Ki = Fi(un), qi = (n) => Array.isArray(n) && typeof n[0] == "number", Nn = {
1542
1548
  linear: De,
1543
- easeIn: ca,
1549
+ easeIn: cs,
1544
1550
  easeInOut: Si,
1545
- easeOut: da,
1551
+ easeOut: ds,
1546
1552
  circIn: un,
1547
1553
  circInOut: Ki,
1548
- circOut: ua,
1554
+ circOut: us,
1549
1555
  backIn: dn,
1550
1556
  backInOut: zi,
1551
1557
  backOut: Bi,
1552
1558
  anticipate: $i
1553
- }, ha = (n) => typeof n == "string", Sn = (n) => {
1559
+ }, hs = (n) => typeof n == "string", Sn = (n) => {
1554
1560
  if (qi(n)) {
1555
1561
  ce(n.length === 4, "Cubic bezier arrays must contain four numerical values.");
1556
1562
  const [e, t, i, r] = n;
1557
- return st(e, t, i, r);
1558
- } else if (ha(n))
1563
+ return at(e, t, i, r);
1564
+ } else if (hs(n))
1559
1565
  return ce(Nn[n] !== void 0, `Invalid easing type '${n}'`), Nn[n];
1560
1566
  return n;
1561
1567
  };
1562
- function pa(n, e) {
1568
+ function ps(n, e) {
1563
1569
  return n.map(() => e || Si).splice(0, n.length - 1);
1564
1570
  }
1565
1571
  function Ie({ duration: n = 300, keyframes: e, times: t, ease: i = "easeInOut" }) {
1566
- const r = mi(i) ? i.map(Sn) : Sn(i), s = {
1572
+ const r = mi(i) ? i.map(Sn) : Sn(i), a = {
1567
1573
  done: !1,
1568
1574
  value: e[0]
1569
- }, a = sa(
1575
+ }, s = as(
1570
1576
  // Only use the provided offsets if they're the correct length
1571
1577
  // TODO Maybe we should warn here if there's a length mismatch
1572
1578
  t && t.length === e.length ? t : vi(e),
1573
1579
  n
1574
- ), o = ra(a, e, {
1575
- ease: Array.isArray(r) ? r : pa(e, r)
1580
+ ), o = rs(s, e, {
1581
+ ease: Array.isArray(r) ? r : ps(e, r)
1576
1582
  });
1577
1583
  return {
1578
1584
  calculatedDuration: n,
1579
- next: (l) => (s.value = o(l), s.done = l >= n, s)
1585
+ next: (l) => (a.value = o(l), a.done = l >= n, a)
1580
1586
  };
1581
1587
  }
1582
- const ma = (n) => n !== null;
1588
+ const ms = (n) => n !== null;
1583
1589
  function hn(n, { repeat: e, repeatType: t = "loop" }, i, r = 1) {
1584
- const s = n.filter(ma), o = r < 0 || e && t !== "loop" && e % 2 === 1 ? 0 : s.length - 1;
1585
- return !o || i === void 0 ? s[o] : i;
1590
+ const a = n.filter(ms), o = r < 0 || e && t !== "loop" && e % 2 === 1 ? 0 : a.length - 1;
1591
+ return !o || i === void 0 ? a[o] : i;
1586
1592
  }
1587
- const fa = {
1593
+ const fs = {
1588
1594
  decay: Ft,
1589
1595
  inertia: Ft,
1590
1596
  tween: Ie,
@@ -1592,7 +1598,7 @@ const fa = {
1592
1598
  spring: tt
1593
1599
  };
1594
1600
  function Gi(n) {
1595
- typeof n.type == "string" && (n.type = fa[n.type]);
1601
+ typeof n.type == "string" && (n.type = fs[n.type]);
1596
1602
  }
1597
1603
  class pn {
1598
1604
  constructor() {
@@ -1618,7 +1624,7 @@ class pn {
1618
1624
  return this.finished.then(e, t);
1619
1625
  }
1620
1626
  }
1621
- const ga = (n) => n / 100;
1627
+ const gs = (n) => n / 100;
1622
1628
  class mn extends pn {
1623
1629
  constructor(e) {
1624
1630
  super(), this.state = "idle", this.startTime = null, this.isStopped = !1, this.currentTime = 0, this.holdTime = null, this.playbackSpeed = 1, this.stop = () => {
@@ -1630,14 +1636,14 @@ class mn extends pn {
1630
1636
  initAnimation() {
1631
1637
  const { options: e } = this;
1632
1638
  Gi(e);
1633
- const { type: t = Ie, repeat: i = 0, repeatDelay: r = 0, repeatType: s, velocity: a = 0 } = e;
1639
+ const { type: t = Ie, repeat: i = 0, repeatDelay: r = 0, repeatType: a, velocity: s = 0 } = e;
1634
1640
  let { keyframes: o } = e;
1635
1641
  const l = t || Ie;
1636
- process.env.NODE_ENV !== "production" && l !== Ie && ce(o.length <= 2, `Only two keyframes currently supported with spring and inertia animations. Trying to animate ${o}`), l !== Ie && typeof o[0] != "number" && (this.mixKeyframes = ln(ga, Di(o[0], o[1])), o = [0, 100]);
1642
+ process.env.NODE_ENV !== "production" && l !== Ie && ce(o.length <= 2, `Only two keyframes currently supported with spring and inertia animations. Trying to animate ${o}`), l !== Ie && typeof o[0] != "number" && (this.mixKeyframes = ln(gs, Di(o[0], o[1])), o = [0, 100]);
1637
1643
  const u = l(I(v({}, e), { keyframes: o }));
1638
- s === "mirror" && (this.mirroredGenerator = l(I(v({}, e), {
1644
+ a === "mirror" && (this.mirroredGenerator = l(I(v({}, e), {
1639
1645
  keyframes: [...o].reverse(),
1640
- velocity: -a
1646
+ velocity: -s
1641
1647
  }))), u.calculatedDuration === null && (u.calculatedDuration = nn(u));
1642
1648
  const { calculatedDuration: d } = u;
1643
1649
  this.calculatedDuration = d, this.resolvedDuration = d + r, this.totalDuration = this.resolvedDuration * (i + 1) - r, this.generator = u;
@@ -1647,21 +1653,21 @@ class mn extends pn {
1647
1653
  this.holdTime !== null ? this.currentTime = this.holdTime : this.currentTime = t;
1648
1654
  }
1649
1655
  tick(e, t = !1) {
1650
- const { generator: i, totalDuration: r, mixKeyframes: s, mirroredGenerator: a, resolvedDuration: o, calculatedDuration: l } = this;
1656
+ const { generator: i, totalDuration: r, mixKeyframes: a, mirroredGenerator: s, resolvedDuration: o, calculatedDuration: l } = this;
1651
1657
  if (this.startTime === null)
1652
1658
  return i.next(0);
1653
1659
  const { delay: u = 0, keyframes: d, repeat: h, repeatType: m, repeatDelay: p, type: g, onUpdate: b, finalKeyframe: y } = this.options;
1654
1660
  this.speed > 0 ? this.startTime = Math.min(this.startTime, e) : this.speed < 0 && (this.startTime = Math.min(e - r / this.speed, this.startTime)), t ? this.currentTime = e : this.updateTime(e);
1655
- const k = this.currentTime - u * (this.playbackSpeed >= 0 ? 1 : -1), V = this.playbackSpeed >= 0 ? k < 0 : k > r;
1656
- this.currentTime = Math.max(k, 0), this.state === "finished" && this.holdTime === null && (this.currentTime = r);
1661
+ const E = this.currentTime - u * (this.playbackSpeed >= 0 ? 1 : -1), V = this.playbackSpeed >= 0 ? E < 0 : E > r;
1662
+ this.currentTime = Math.max(E, 0), this.state === "finished" && this.holdTime === null && (this.currentTime = r);
1657
1663
  let _ = this.currentTime, M = i;
1658
1664
  if (h) {
1659
1665
  const w = Math.min(this.currentTime, r) / o;
1660
1666
  let R = Math.floor(w), O = w % 1;
1661
- !O && w >= 1 && (O = 1), O === 1 && R--, R = Math.min(R, h + 1), !!(R % 2) && (m === "reverse" ? (O = 1 - O, p && (O -= p / o)) : m === "mirror" && (M = a)), _ = xe(0, 1, O) * o;
1667
+ !O && w >= 1 && (O = 1), O === 1 && R--, R = Math.min(R, h + 1), !!(R % 2) && (m === "reverse" ? (O = 1 - O, p && (O -= p / o)) : m === "mirror" && (M = s)), _ = xe(0, 1, O) * o;
1662
1668
  }
1663
1669
  const T = V ? { done: !1, value: d[0] } : M.next(_);
1664
- s && (T.value = s(T.value));
1670
+ a && (T.value = a(T.value));
1665
1671
  let { done: D } = T;
1666
1672
  !V && l !== null && (D = this.playbackSpeed >= 0 ? this.currentTime >= r : this.currentTime <= 0);
1667
1673
  const C = this.holdTime === null && (this.state === "finished" || this.state === "running" && D);
@@ -1683,7 +1689,7 @@ class mn extends pn {
1683
1689
  }
1684
1690
  set time(e) {
1685
1691
  var t;
1686
- e = /* @__PURE__ */ ae(e), this.currentTime = e, this.startTime === null || this.holdTime !== null || this.playbackSpeed === 0 ? this.holdTime = e : this.driver && (this.startTime = this.driver.now() - e / this.playbackSpeed), (t = this.driver) == null || t.start(!1);
1692
+ e = /* @__PURE__ */ se(e), this.currentTime = e, this.startTime === null || this.holdTime !== null || this.playbackSpeed === 0 ? this.holdTime = e : this.driver && (this.startTime = this.driver.now() - e / this.playbackSpeed), (t = this.driver) == null || t.start(!1);
1687
1693
  }
1688
1694
  get speed() {
1689
1695
  return this.playbackSpeed;
@@ -1694,11 +1700,11 @@ class mn extends pn {
1694
1700
  this.playbackSpeed = e, t && (this.time = /* @__PURE__ */ le(this.currentTime));
1695
1701
  }
1696
1702
  play() {
1697
- var r, s;
1703
+ var r, a;
1698
1704
  if (this.isStopped)
1699
1705
  return;
1700
- const { driver: e = Ws, startTime: t } = this.options;
1701
- this.driver || (this.driver = e((a) => this.tick(a))), (s = (r = this.options).onPlay) == null || s.call(r);
1706
+ const { driver: e = Wa, startTime: t } = this.options;
1707
+ this.driver || (this.driver = e((s) => this.tick(s))), (a = (r = this.options).onPlay) == null || a.call(r);
1702
1708
  const i = this.driver.now();
1703
1709
  this.state === "finished" ? (this.updateFinished(), this.startTime = i) : this.holdTime !== null ? this.startTime = i - this.holdTime : this.startTime || (this.startTime = t != null ? t : i), this.state === "finished" && this.speed < 0 && (this.startTime += this.calculatedDuration), this.holdTime = null, this.state = "running", this.driver.start();
1704
1710
  }
@@ -1730,7 +1736,7 @@ class mn extends pn {
1730
1736
  return this.options.allowFlatten && (this.options.type = "keyframes", this.options.ease = "linear", this.initAnimation()), (t = this.driver) == null || t.stop(), e.observe(this);
1731
1737
  }
1732
1738
  }
1733
- function ba(n) {
1739
+ function bs(n) {
1734
1740
  var e;
1735
1741
  for (let t = 1; t < n.length; t++)
1736
1742
  (e = n[t]) != null || (n[t] = n[t - 1]);
@@ -1738,7 +1744,7 @@ function ba(n) {
1738
1744
  const Ce = (n) => n * 180 / Math.PI, jt = (n) => {
1739
1745
  const e = Ce(Math.atan2(n[1], n[0]));
1740
1746
  return Bt(e);
1741
- }, va = {
1747
+ }, vs = {
1742
1748
  x: 4,
1743
1749
  y: 5,
1744
1750
  translateX: 4,
@@ -1751,7 +1757,7 @@ const Ce = (n) => n * 180 / Math.PI, jt = (n) => {
1751
1757
  skewX: (n) => Ce(Math.atan(n[1])),
1752
1758
  skewY: (n) => Ce(Math.atan(n[2])),
1753
1759
  skew: (n) => (Math.abs(n[1]) + Math.abs(n[2])) / 2
1754
- }, Bt = (n) => (n = n % 360, n < 0 && (n += 360), n), Fn = jt, jn = (n) => Math.sqrt(n[0] * n[0] + n[1] * n[1]), Bn = (n) => Math.sqrt(n[4] * n[4] + n[5] * n[5]), ya = {
1760
+ }, Bt = (n) => (n = n % 360, n < 0 && (n += 360), n), Fn = jt, jn = (n) => Math.sqrt(n[0] * n[0] + n[1] * n[1]), Bn = (n) => Math.sqrt(n[4] * n[4] + n[5] * n[5]), ys = {
1755
1761
  x: 12,
1756
1762
  y: 13,
1757
1763
  z: 14,
@@ -1778,27 +1784,27 @@ function $t(n, e) {
1778
1784
  const t = n.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);
1779
1785
  let i, r;
1780
1786
  if (t)
1781
- i = ya, r = t;
1787
+ i = ys, r = t;
1782
1788
  else {
1783
1789
  const o = n.match(/^matrix\(([-\d.e\s,]+)\)$/u);
1784
- i = va, r = o;
1790
+ i = vs, r = o;
1785
1791
  }
1786
1792
  if (!r)
1787
1793
  return zt(e);
1788
- const s = i[e], a = r[1].split(",").map(ka);
1789
- return typeof s == "function" ? s(a) : a[s];
1794
+ const a = i[e], s = r[1].split(",").map(ks);
1795
+ return typeof a == "function" ? a(s) : s[a];
1790
1796
  }
1791
- const Ca = (n, e) => {
1797
+ const Cs = (n, e) => {
1792
1798
  const { transform: t = "none" } = getComputedStyle(n);
1793
1799
  return $t(t, e);
1794
1800
  };
1795
- function ka(n) {
1801
+ function ks(n) {
1796
1802
  return parseFloat(n.trim());
1797
1803
  }
1798
- const zn = (n) => n === Ne || n === L, Ea = /* @__PURE__ */ new Set(["x", "y", "z"]), xa = Re.filter((n) => !Ea.has(n));
1799
- function wa(n) {
1804
+ const zn = (n) => n === Ne || n === L, Es = /* @__PURE__ */ new Set(["x", "y", "z"]), xs = Re.filter((n) => !Es.has(n));
1805
+ function ws(n) {
1800
1806
  const e = [];
1801
- return xa.forEach((t) => {
1807
+ return xs.forEach((t) => {
1802
1808
  const i = n.getValue(t);
1803
1809
  i !== void 0 && (e.push([t, i.get()]), i.set(t.startsWith("scale") ? 1 : 0));
1804
1810
  }), e;
@@ -1823,14 +1829,14 @@ function Hi() {
1823
1829
  if (qt) {
1824
1830
  const n = Array.from(Ee).filter((i) => i.needsMeasurement), e = new Set(n.map((i) => i.element)), t = /* @__PURE__ */ new Map();
1825
1831
  e.forEach((i) => {
1826
- const r = wa(i);
1832
+ const r = ws(i);
1827
1833
  r.length && (t.set(i, r), i.render());
1828
1834
  }), n.forEach((i) => i.measureInitialState()), e.forEach((i) => {
1829
1835
  i.render();
1830
1836
  const r = t.get(i);
1831
- r && r.forEach(([s, a]) => {
1837
+ r && r.forEach(([a, s]) => {
1832
1838
  var o;
1833
- (o = i.getValue(s)) == null || o.set(a);
1839
+ (o = i.getValue(a)) == null || o.set(s);
1834
1840
  });
1835
1841
  }), n.forEach((i) => i.measureEndState()), n.forEach((i) => {
1836
1842
  i.suspendedScrollY !== void 0 && window.scrollTo(0, i.suspendedScrollY);
@@ -1843,12 +1849,12 @@ function Yi() {
1843
1849
  n.readKeyframes(), n.needsMeasurement && (qt = !0);
1844
1850
  });
1845
1851
  }
1846
- function Ta() {
1852
+ function Ts() {
1847
1853
  Gt = !0, Yi(), Hi(), Gt = !1;
1848
1854
  }
1849
1855
  class fn {
1850
- constructor(e, t, i, r, s, a = !1) {
1851
- this.state = "pending", this.isAsync = !1, this.needsMeasurement = !1, this.unresolvedKeyframes = [...e], this.onComplete = t, this.name = i, this.motionValue = r, this.element = s, this.isAsync = a;
1856
+ constructor(e, t, i, r, a, s = !1) {
1857
+ this.state = "pending", this.isAsync = !1, this.needsMeasurement = !1, this.unresolvedKeyframes = [...e], this.onComplete = t, this.name = i, this.motionValue = r, this.element = a, this.isAsync = s;
1852
1858
  }
1853
1859
  scheduleResolve() {
1854
1860
  this.state = "scheduled", this.isAsync ? (Ee.add(this), Kt || (Kt = !0, ue.read(Yi), ue.resolveKeyframes(Hi))) : (this.readKeyframes(), this.complete());
@@ -1856,16 +1862,16 @@ class fn {
1856
1862
  readKeyframes() {
1857
1863
  const { unresolvedKeyframes: e, name: t, element: i, motionValue: r } = this;
1858
1864
  if (e[0] === null) {
1859
- const s = r == null ? void 0 : r.get(), a = e[e.length - 1];
1860
- if (s !== void 0)
1861
- e[0] = s;
1865
+ const a = r == null ? void 0 : r.get(), s = e[e.length - 1];
1866
+ if (a !== void 0)
1867
+ e[0] = a;
1862
1868
  else if (i && t) {
1863
- const o = i.readValue(t, a);
1869
+ const o = i.readValue(t, s);
1864
1870
  o != null && (e[0] = o);
1865
1871
  }
1866
- e[0] === void 0 && (e[0] = a), r && s === void 0 && r.set(e[0]);
1872
+ e[0] === void 0 && (e[0] = s), r && a === void 0 && r.set(e[0]);
1867
1873
  }
1868
- ba(e);
1874
+ bs(e);
1869
1875
  }
1870
1876
  setFinalKeyframe() {
1871
1877
  }
@@ -1885,24 +1891,24 @@ class fn {
1885
1891
  this.state === "pending" && this.scheduleResolve();
1886
1892
  }
1887
1893
  }
1888
- const Aa = (n) => n.startsWith("--");
1889
- function _a(n, e, t) {
1890
- Aa(e) ? n.style.setProperty(e, t) : n.style[e] = t;
1894
+ const As = (n) => n.startsWith("--");
1895
+ function _s(n, e, t) {
1896
+ As(e) ? n.style.setProperty(e, t) : n.style[e] = t;
1891
1897
  }
1892
1898
  // @__NO_SIDE_EFFECTS__
1893
1899
  function gn(n) {
1894
1900
  let e;
1895
1901
  return () => (e === void 0 && (e = n()), e);
1896
1902
  }
1897
- const La = /* @__PURE__ */ gn(() => window.ScrollTimeline !== void 0), Va = {};
1898
- function Ia(n, e) {
1903
+ const Ls = /* @__PURE__ */ gn(() => window.ScrollTimeline !== void 0), Vs = {};
1904
+ function Is(n, e) {
1899
1905
  const t = /* @__PURE__ */ gn(n);
1900
1906
  return () => {
1901
1907
  var i;
1902
- return (i = Va[e]) != null ? i : t();
1908
+ return (i = Vs[e]) != null ? i : t();
1903
1909
  };
1904
1910
  }
1905
- const Ui = /* @__PURE__ */ Ia(() => {
1911
+ const Ui = /* @__PURE__ */ Is(() => {
1906
1912
  try {
1907
1913
  document.createElement("div").animate({ opacity: 0 }, { easing: "linear(0, 1)" });
1908
1914
  } catch (n) {
@@ -1924,7 +1930,7 @@ function Wi(n, e) {
1924
1930
  if (n)
1925
1931
  return typeof n == "function" ? Ui() ? Ri(n, e) : "ease-out" : qi(n) ? Ue(n) : Array.isArray(n) ? n.map((t) => Wi(t, e) || $n.easeOut) : $n[n];
1926
1932
  }
1927
- function Ma(n, e, t, { delay: i = 0, duration: r = 300, repeat: s = 0, repeatType: a = "loop", ease: o = "easeOut", times: l } = {}, u = void 0) {
1933
+ function Ms(n, e, t, { delay: i = 0, duration: r = 300, repeat: a = 0, repeatType: s = "loop", ease: o = "easeOut", times: l } = {}, u = void 0) {
1928
1934
  const d = {
1929
1935
  [e]: t
1930
1936
  };
@@ -1936,27 +1942,27 @@ function Ma(n, e, t, { delay: i = 0, duration: r = 300, repeat: s = 0, repeatTyp
1936
1942
  duration: r,
1937
1943
  easing: Array.isArray(h) ? "linear" : h,
1938
1944
  fill: "both",
1939
- iterations: s + 1,
1940
- direction: a === "reverse" ? "alternate" : "normal"
1945
+ iterations: a + 1,
1946
+ direction: s === "reverse" ? "alternate" : "normal"
1941
1947
  };
1942
1948
  return u && (m.pseudoElement = u), n.animate(d, m);
1943
1949
  }
1944
- function Pa(t) {
1945
- var i = t, { type: n } = i, e = se(i, ["type"]);
1946
- var r, s;
1947
- return tn(n) && Ui() ? n.applyToOptions(e) : ((r = e.duration) != null || (e.duration = 300), (s = e.ease) != null || (e.ease = "easeOut"), e);
1950
+ function Ps(t) {
1951
+ var i = t, { type: n } = i, e = ae(i, ["type"]);
1952
+ var r, a;
1953
+ return tn(n) && Ui() ? n.applyToOptions(e) : ((r = e.duration) != null || (e.duration = 300), (a = e.ease) != null || (e.ease = "easeOut"), e);
1948
1954
  }
1949
- class Da extends pn {
1955
+ class Ds extends pn {
1950
1956
  constructor(e) {
1951
1957
  if (super(), this.finishedTime = null, this.isStopped = !1, !e)
1952
1958
  return;
1953
- const { element: t, name: i, keyframes: r, pseudoElement: s, allowFlatten: a = !1, finalKeyframe: o, onComplete: l } = e;
1954
- this.isPseudoElement = !!s, this.allowFlatten = a, this.options = e, ce(typeof e.type != "string", `animateMini doesn't support "type" as a string. Did you mean to import { spring } from "motion"?`);
1955
- const u = Pa(e);
1956
- this.animation = Ma(t, i, r, u, s), u.autoplay === !1 && this.animation.pause(), this.animation.onfinish = () => {
1957
- if (this.finishedTime = this.time, !s) {
1959
+ const { element: t, name: i, keyframes: r, pseudoElement: a, allowFlatten: s = !1, finalKeyframe: o, onComplete: l } = e;
1960
+ this.isPseudoElement = !!a, this.allowFlatten = s, this.options = e, ce(typeof e.type != "string", `animateMini doesn't support "type" as a string. Did you mean to import { spring } from "motion"?`);
1961
+ const u = Ps(e);
1962
+ this.animation = Ms(t, i, r, u, a), u.autoplay === !1 && this.animation.pause(), this.animation.onfinish = () => {
1963
+ if (this.finishedTime = this.time, !a) {
1958
1964
  const d = hn(r, this.options, o, this.speed);
1959
- this.updateMotionValue ? this.updateMotionValue(d) : _a(t, i, d), this.animation.cancel();
1965
+ this.updateMotionValue ? this.updateMotionValue(d) : _s(t, i, d), this.animation.cancel();
1960
1966
  }
1961
1967
  l == null || l(), this.notifyFinished();
1962
1968
  };
@@ -2009,7 +2015,7 @@ class Da extends pn {
2009
2015
  return /* @__PURE__ */ le(Number(this.animation.currentTime) || 0);
2010
2016
  }
2011
2017
  set time(e) {
2012
- this.finishedTime = null, this.animation.currentTime = /* @__PURE__ */ ae(e);
2018
+ this.finishedTime = null, this.animation.currentTime = /* @__PURE__ */ se(e);
2013
2019
  }
2014
2020
  /**
2015
2021
  * The playback speed of the animation.
@@ -2035,7 +2041,7 @@ class Da extends pn {
2035
2041
  */
2036
2042
  attachTimeline({ timeline: e, observe: t }) {
2037
2043
  var i;
2038
- return this.allowFlatten && ((i = this.animation.effect) == null || i.updateTiming({ easing: "linear" })), this.animation.onfinish = null, e && La() ? (this.animation.timeline = e, De) : t(this);
2044
+ return this.allowFlatten && ((i = this.animation.effect) == null || i.updateTiming({ easing: "linear" })), this.animation.onfinish = null, e && Ls() ? (this.animation.timeline = e, De) : t(this);
2039
2045
  }
2040
2046
  }
2041
2047
  const Zi = {
@@ -2043,16 +2049,16 @@ const Zi = {
2043
2049
  backInOut: zi,
2044
2050
  circInOut: Ki
2045
2051
  };
2046
- function Ra(n) {
2052
+ function Rs(n) {
2047
2053
  return n in Zi;
2048
2054
  }
2049
- function Oa(n) {
2050
- typeof n.ease == "string" && Ra(n.ease) && (n.ease = Zi[n.ease]);
2055
+ function Os(n) {
2056
+ typeof n.ease == "string" && Rs(n.ease) && (n.ease = Zi[n.ease]);
2051
2057
  }
2052
2058
  const Kn = 10;
2053
- class Na extends Da {
2059
+ class Ns extends Ds {
2054
2060
  constructor(e) {
2055
- Oa(e), Gi(e), super(e), e.startTime && (this.startTime = e.startTime), this.options = e;
2061
+ Os(e), Gi(e), super(e), e.startTime && (this.startTime = e.startTime), this.options = e;
2056
2062
  }
2057
2063
  /**
2058
2064
  * WAAPI doesn't natively have any interruption capabilities.
@@ -2064,23 +2070,23 @@ class Na extends Da {
2064
2070
  */
2065
2071
  updateMotionValue(e) {
2066
2072
  var d;
2067
- const u = this.options, { motionValue: t, onUpdate: i, onComplete: r, element: s } = u, a = se(u, ["motionValue", "onUpdate", "onComplete", "element"]);
2073
+ const u = this.options, { motionValue: t, onUpdate: i, onComplete: r, element: a } = u, s = ae(u, ["motionValue", "onUpdate", "onComplete", "element"]);
2068
2074
  if (!t)
2069
2075
  return;
2070
2076
  if (e !== void 0) {
2071
2077
  t.set(e);
2072
2078
  return;
2073
2079
  }
2074
- const o = new mn(I(v({}, a), {
2080
+ const o = new mn(I(v({}, s), {
2075
2081
  autoplay: !1
2076
- })), l = /* @__PURE__ */ ae((d = this.finishedTime) != null ? d : this.time);
2082
+ })), l = /* @__PURE__ */ se((d = this.finishedTime) != null ? d : this.time);
2077
2083
  t.setWithVelocity(o.sample(l - Kn).value, o.sample(l).value, Kn), o.stop();
2078
2084
  }
2079
2085
  }
2080
2086
  const qn = (n, e) => e === "zIndex" ? !1 : !!(typeof n == "number" || Array.isArray(n) || typeof n == "string" && // It's animatable if we have a string
2081
2087
  (Se.test(n) || n === "0") && // And it contains numbers and/or colors
2082
2088
  !n.startsWith("url("));
2083
- function Sa(n) {
2089
+ function Ss(n) {
2084
2090
  const e = n[0];
2085
2091
  if (n.length === 1)
2086
2092
  return !0;
@@ -2088,73 +2094,73 @@ function Sa(n) {
2088
2094
  if (n[t] !== e)
2089
2095
  return !0;
2090
2096
  }
2091
- function Fa(n, e, t, i) {
2097
+ function Fs(n, e, t, i) {
2092
2098
  const r = n[0];
2093
2099
  if (r === null)
2094
2100
  return !1;
2095
2101
  if (e === "display" || e === "visibility")
2096
2102
  return !0;
2097
- const s = n[n.length - 1], a = qn(r, e), o = qn(s, e);
2098
- return it(a === o, `You are trying to animate ${e} from "${r}" to "${s}". ${r} is not an animatable value - to enable this animation set ${r} to a value animatable to ${s} via the \`style\` property.`), !a || !o ? !1 : Sa(n) || (t === "spring" || tn(t)) && i;
2103
+ const a = n[n.length - 1], s = qn(r, e), o = qn(a, e);
2104
+ return it(s === o, `You are trying to animate ${e} from "${r}" to "${a}". ${r} is not an animatable value - to enable this animation set ${r} to a value animatable to ${a} via the \`style\` property.`), !s || !o ? !1 : Ss(n) || (t === "spring" || tn(t)) && i;
2099
2105
  }
2100
2106
  function Ji(n) {
2101
2107
  return typeof n == "object" && n !== null;
2102
2108
  }
2103
- function ja(n) {
2109
+ function js(n) {
2104
2110
  return Ji(n) && "offsetHeight" in n;
2105
2111
  }
2106
- const Ba = /* @__PURE__ */ new Set([
2112
+ const Bs = /* @__PURE__ */ new Set([
2107
2113
  "opacity",
2108
2114
  "clipPath",
2109
2115
  "filter",
2110
2116
  "transform"
2111
2117
  // TODO: Could be re-enabled now we have support for linear() easing
2112
2118
  // "background-color"
2113
- ]), za = /* @__PURE__ */ gn(() => Object.hasOwnProperty.call(Element.prototype, "animate"));
2114
- function $a(n) {
2119
+ ]), zs = /* @__PURE__ */ gn(() => Object.hasOwnProperty.call(Element.prototype, "animate"));
2120
+ function $s(n) {
2115
2121
  var u;
2116
- const { motionValue: e, name: t, repeatDelay: i, repeatType: r, damping: s, type: a } = n;
2117
- if (!ja((u = e == null ? void 0 : e.owner) == null ? void 0 : u.current))
2122
+ const { motionValue: e, name: t, repeatDelay: i, repeatType: r, damping: a, type: s } = n;
2123
+ if (!js((u = e == null ? void 0 : e.owner) == null ? void 0 : u.current))
2118
2124
  return !1;
2119
2125
  const { onUpdate: o, transformTemplate: l } = e.owner.getProps();
2120
- return za() && t && Ba.has(t) && (t !== "transform" || !l) && /**
2126
+ return zs() && t && Bs.has(t) && (t !== "transform" || !l) && /**
2121
2127
  * If we're outputting values to onUpdate then we can't use WAAPI as there's
2122
2128
  * no way to read the value from WAAPI every frame.
2123
2129
  */
2124
- !o && !i && r !== "mirror" && s !== 0 && a !== "inertia";
2130
+ !o && !i && r !== "mirror" && a !== 0 && s !== "inertia";
2125
2131
  }
2126
- const Ka = 40;
2127
- class qa extends pn {
2132
+ const Ks = 40;
2133
+ class qs extends pn {
2128
2134
  constructor(m) {
2129
- var p = m, { autoplay: e = !0, delay: t = 0, type: i = "keyframes", repeat: r = 0, repeatDelay: s = 0, repeatType: a = "loop", keyframes: o, name: l, motionValue: u, element: d } = p, h = se(p, ["autoplay", "delay", "type", "repeat", "repeatDelay", "repeatType", "keyframes", "name", "motionValue", "element"]);
2135
+ var p = m, { autoplay: e = !0, delay: t = 0, type: i = "keyframes", repeat: r = 0, repeatDelay: a = 0, repeatType: s = "loop", keyframes: o, name: l, motionValue: u, element: d } = p, h = ae(p, ["autoplay", "delay", "type", "repeat", "repeatDelay", "repeatType", "keyframes", "name", "motionValue", "element"]);
2130
2136
  var y;
2131
2137
  super(), this.stop = () => {
2132
- var k, V;
2133
- this._animation && (this._animation.stop(), (k = this.stopTimeline) == null || k.call(this)), (V = this.keyframeResolver) == null || V.cancel();
2138
+ var E, V;
2139
+ this._animation && (this._animation.stop(), (E = this.stopTimeline) == null || E.call(this)), (V = this.keyframeResolver) == null || V.cancel();
2134
2140
  }, this.createdAt = ee.now();
2135
2141
  const g = v({
2136
2142
  autoplay: e,
2137
2143
  delay: t,
2138
2144
  type: i,
2139
2145
  repeat: r,
2140
- repeatDelay: s,
2141
- repeatType: a,
2146
+ repeatDelay: a,
2147
+ repeatType: s,
2142
2148
  name: l,
2143
2149
  motionValue: u,
2144
2150
  element: d
2145
2151
  }, h), b = (d == null ? void 0 : d.KeyframeResolver) || fn;
2146
- this.keyframeResolver = new b(o, (k, V, _) => this.onKeyframesResolved(k, V, g, !_), l, u, d), (y = this.keyframeResolver) == null || y.scheduleResolve();
2152
+ this.keyframeResolver = new b(o, (E, V, _) => this.onKeyframesResolved(E, V, g, !_), l, u, d), (y = this.keyframeResolver) == null || y.scheduleResolve();
2147
2153
  }
2148
2154
  onKeyframesResolved(e, t, i, r) {
2149
2155
  this.keyframeResolver = void 0;
2150
- const { name: s, type: a, velocity: o, delay: l, isHandoff: u, onUpdate: d } = i;
2151
- this.resolvedAt = ee.now(), Fa(e, s, a, o) || ((de.instantAnimations || !l) && (d == null || d(hn(e, i, t))), e[0] = e[e.length - 1], i.duration = 0, i.repeat = 0);
2152
- const h = r ? this.resolvedAt ? this.resolvedAt - this.createdAt > Ka ? this.resolvedAt : this.createdAt : this.createdAt : void 0, m = I(v({
2156
+ const { name: a, type: s, velocity: o, delay: l, isHandoff: u, onUpdate: d } = i;
2157
+ this.resolvedAt = ee.now(), Fs(e, a, s, o) || ((de.instantAnimations || !l) && (d == null || d(hn(e, i, t))), e[0] = e[e.length - 1], i.duration = 0, i.repeat = 0);
2158
+ const h = r ? this.resolvedAt ? this.resolvedAt - this.createdAt > Ks ? this.resolvedAt : this.createdAt : this.createdAt : void 0, m = I(v({
2153
2159
  startTime: h,
2154
2160
  finalKeyframe: t
2155
2161
  }, i), {
2156
2162
  keyframes: e
2157
- }), p = !u && $a(m) ? new Na(I(v({}, m), {
2163
+ }), p = !u && $s(m) ? new Ns(I(v({}, m), {
2158
2164
  element: m.motionValue.owner.current
2159
2165
  })) : new mn(m);
2160
2166
  p.finished.then(() => this.notifyFinished()).catch(De), this.pendingTimeline && (this.stopTimeline = p.attachTimeline(this.pendingTimeline), this.pendingTimeline = void 0), this._animation = p;
@@ -2168,7 +2174,7 @@ class qa extends pn {
2168
2174
  }
2169
2175
  get animation() {
2170
2176
  var e;
2171
- return this._animation || ((e = this.keyframeResolver) == null || e.resume(), Ta()), this._animation;
2177
+ return this._animation || ((e = this.keyframeResolver) == null || e.resume(), Ts()), this._animation;
2172
2178
  }
2173
2179
  get duration() {
2174
2180
  return this.animation.duration;
@@ -2208,10 +2214,10 @@ class qa extends pn {
2208
2214
  this._animation && this.animation.cancel(), (e = this.keyframeResolver) == null || e.cancel();
2209
2215
  }
2210
2216
  }
2211
- const Xi = (n, e, t, i = {}, r, s) => (a) => {
2217
+ const Xi = (n, e, t, i = {}, r, a) => (s) => {
2212
2218
  const o = wi(i, n) || {}, l = o.delay || i.delay || 0;
2213
2219
  let { elapsed: u = 0 } = i;
2214
- u = u - /* @__PURE__ */ ae(l);
2220
+ u = u - /* @__PURE__ */ se(l);
2215
2221
  const d = I(v({
2216
2222
  keyframes: Array.isArray(t) ? t : [null, t],
2217
2223
  ease: "easeOut",
@@ -2222,16 +2228,16 @@ const Xi = (n, e, t, i = {}, r, s) => (a) => {
2222
2228
  e.set(m), o.onUpdate && o.onUpdate(m);
2223
2229
  },
2224
2230
  onComplete: () => {
2225
- a(), o.onComplete && o.onComplete();
2231
+ s(), o.onComplete && o.onComplete();
2226
2232
  },
2227
2233
  name: n,
2228
2234
  motionValue: e,
2229
- element: s ? void 0 : r
2235
+ element: a ? void 0 : r
2230
2236
  });
2231
- ws(o) || Object.assign(d, xs(n, d)), d.duration && (d.duration = /* @__PURE__ */ ae(d.duration)), d.repeatDelay && (d.repeatDelay = /* @__PURE__ */ ae(d.repeatDelay)), d.from !== void 0 && (d.keyframes[0] = d.from);
2237
+ wa(o) || Object.assign(d, xa(n, d)), d.duration && (d.duration = /* @__PURE__ */ se(d.duration)), d.repeatDelay && (d.repeatDelay = /* @__PURE__ */ se(d.repeatDelay)), d.from !== void 0 && (d.keyframes[0] = d.from);
2232
2238
  let h = !1;
2233
- if ((d.type === !1 || d.duration === 0 && !d.repeatDelay) && (d.duration = 0, d.delay === 0 && (h = !0)), (de.instantAnimations || de.skipAnimations) && (h = !0, d.duration = 0, d.delay = 0), d.allowFlatten = !o.type && !o.ease, h && !s && e.get() !== void 0) {
2234
- const m = vs(d.keyframes, o);
2239
+ if ((d.type === !1 || d.duration === 0 && !d.repeatDelay) && (d.duration = 0, d.delay === 0 && (h = !0)), (de.instantAnimations || de.skipAnimations) && (h = !0, d.duration = 0, d.delay = 0), d.allowFlatten = !o.type && !o.ease, h && !a && e.get() !== void 0) {
2240
+ const m = va(d.keyframes, o);
2235
2241
  if (m !== void 0) {
2236
2242
  ue.update(() => {
2237
2243
  d.onUpdate(m), d.onComplete();
@@ -2239,7 +2245,7 @@ const Xi = (n, e, t, i = {}, r, s) => (a) => {
2239
2245
  return;
2240
2246
  }
2241
2247
  }
2242
- return o.isSync ? new mn(d) : new qa(d);
2248
+ return o.isSync ? new mn(d) : new qs(d);
2243
2249
  }, Qi = /* @__PURE__ */ new Set([
2244
2250
  "width",
2245
2251
  "height",
@@ -2249,49 +2255,49 @@ const Xi = (n, e, t, i = {}, r, s) => (a) => {
2249
2255
  "bottom",
2250
2256
  ...Re
2251
2257
  ]);
2252
- function Ga({ protectedKeys: n, needsAnimating: e }, t) {
2258
+ function Gs({ protectedKeys: n, needsAnimating: e }, t) {
2253
2259
  const i = n.hasOwnProperty(t) && e[t] !== !0;
2254
2260
  return e[t] = !1, i;
2255
2261
  }
2256
- function Ha(n, e, { delay: t = 0, transitionOverride: i, type: r } = {}) {
2262
+ function Hs(n, e, { delay: t = 0, transitionOverride: i, type: r } = {}) {
2257
2263
  var h;
2258
- let d = e, { transition: s = n.getDefaultTransition(), transitionEnd: a } = d, o = se(d, ["transition", "transitionEnd"]);
2259
- i && (s = i);
2264
+ let d = e, { transition: a = n.getDefaultTransition(), transitionEnd: s } = d, o = ae(d, ["transition", "transitionEnd"]);
2265
+ i && (a = i);
2260
2266
  const l = [], u = r && n.animationState && n.animationState.getState()[r];
2261
2267
  for (const m in o) {
2262
2268
  const p = n.getValue(m, (h = n.latestValues[m]) != null ? h : null), g = o[m];
2263
- if (g === void 0 || u && Ga(u, m))
2269
+ if (g === void 0 || u && Gs(u, m))
2264
2270
  continue;
2265
2271
  const b = v({
2266
2272
  delay: t
2267
- }, wi(s || {}, m)), y = p.get();
2273
+ }, wi(a || {}, m)), y = p.get();
2268
2274
  if (y !== void 0 && !p.isAnimating && !Array.isArray(g) && g === y && !b.velocity)
2269
2275
  continue;
2270
- let k = !1;
2276
+ let E = !1;
2271
2277
  if (window.MotionHandoffAnimation) {
2272
- const _ = gs(n);
2278
+ const _ = ga(n);
2273
2279
  if (_) {
2274
2280
  const M = window.MotionHandoffAnimation(_, m, ue);
2275
- M !== null && (b.startTime = M, k = !0);
2281
+ M !== null && (b.startTime = M, E = !0);
2276
2282
  }
2277
2283
  }
2278
- ps(n, m), p.start(Xi(m, p, g, n.shouldReduceMotion && Qi.has(m) ? { type: !1 } : b, n, k));
2284
+ pa(n, m), p.start(Xi(m, p, g, n.shouldReduceMotion && Qi.has(m) ? { type: !1 } : b, n, E));
2279
2285
  const V = p.animation;
2280
2286
  V && l.push(V);
2281
2287
  }
2282
- return a && Promise.all(l).then(() => {
2288
+ return s && Promise.all(l).then(() => {
2283
2289
  ue.update(() => {
2284
- a && us(n, a);
2290
+ s && ua(n, s);
2285
2291
  });
2286
2292
  }), l;
2287
2293
  }
2288
- function Ya({ top: n, left: e, right: t, bottom: i }) {
2294
+ function Ys({ top: n, left: e, right: t, bottom: i }) {
2289
2295
  return {
2290
2296
  x: { min: e, max: t },
2291
2297
  y: { min: n, max: i }
2292
2298
  };
2293
2299
  }
2294
- function Ua(n, e) {
2300
+ function Us(n, e) {
2295
2301
  if (!e)
2296
2302
  return n;
2297
2303
  const t = e({ x: n.left, y: n.top }), i = e({ x: n.right, y: n.bottom });
@@ -2302,8 +2308,8 @@ function Ua(n, e) {
2302
2308
  right: i.x
2303
2309
  };
2304
2310
  }
2305
- function Wa(n, e) {
2306
- return Ya(Ua(n.getBoundingClientRect(), e));
2311
+ function Ws(n, e) {
2312
+ return Ys(Us(n.getBoundingClientRect(), e));
2307
2313
  }
2308
2314
  const Gn = {
2309
2315
  animation: [
@@ -2332,19 +2338,19 @@ for (const n in Gn)
2332
2338
  const Hn = () => ({ min: 0, max: 0 }), bn = () => ({
2333
2339
  x: Hn(),
2334
2340
  y: Hn()
2335
- }), Za = typeof window != "undefined", Yt = { current: null }, er = { current: !1 };
2336
- function Ja() {
2337
- if (er.current = !0, !!Za)
2341
+ }), Zs = typeof window != "undefined", Yt = { current: null }, er = { current: !1 };
2342
+ function Js() {
2343
+ if (er.current = !0, !!Zs)
2338
2344
  if (window.matchMedia) {
2339
2345
  const n = window.matchMedia("(prefers-reduced-motion)"), e = () => Yt.current = n.matches;
2340
2346
  n.addListener(e), e();
2341
2347
  } else
2342
2348
  Yt.current = !1;
2343
2349
  }
2344
- function Xa(n) {
2350
+ function Xs(n) {
2345
2351
  return n !== null && typeof n == "object" && typeof n.start == "function";
2346
2352
  }
2347
- function Qa(n) {
2353
+ function Qs(n) {
2348
2354
  return typeof n == "string" || Array.isArray(n);
2349
2355
  }
2350
2356
  const eo = [
@@ -2357,25 +2363,25 @@ const eo = [
2357
2363
  "exit"
2358
2364
  ], to = ["initial", ...eo];
2359
2365
  function tr(n) {
2360
- return Xa(n.animate) || to.some((e) => Qa(n[e]));
2366
+ return Xs(n.animate) || to.some((e) => Qs(n[e]));
2361
2367
  }
2362
2368
  function no(n) {
2363
2369
  return !!(tr(n) || n.variants);
2364
2370
  }
2365
2371
  function io(n, e, t) {
2366
2372
  for (const i in e) {
2367
- const r = e[i], s = t[i];
2373
+ const r = e[i], a = t[i];
2368
2374
  if (J(r))
2369
2375
  n.addValue(i, r);
2370
- else if (J(s))
2376
+ else if (J(a))
2371
2377
  n.addValue(i, Xe(r, { owner: n }));
2372
- else if (s !== r)
2378
+ else if (a !== r)
2373
2379
  if (n.hasValue(i)) {
2374
- const a = n.getValue(i);
2375
- a.liveStyle === !0 ? a.jump(r) : a.hasAnimated || a.set(r);
2380
+ const s = n.getValue(i);
2381
+ s.liveStyle === !0 ? s.jump(r) : s.hasAnimated || s.set(r);
2376
2382
  } else {
2377
- const a = n.getStaticValue(i);
2378
- n.addValue(i, Xe(a !== void 0 ? a : r, { owner: n }));
2383
+ const s = n.getStaticValue(i);
2384
+ n.addValue(i, Xe(s !== void 0 ? s : r, { owner: n }));
2379
2385
  }
2380
2386
  }
2381
2387
  for (const i in t)
@@ -2385,17 +2391,17 @@ function io(n, e, t) {
2385
2391
  const nr = (n) => /^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(n), ir = (n) => /^0[^.\s]+$/u.test(n), ro = {
2386
2392
  test: (n) => n === "auto",
2387
2393
  parse: (n) => n
2388
- }, rr = (n) => (e) => e.test(n), sr = [Ne, L, Me, me, Ps, Ms, ro], Yn = (n) => sr.find(rr(n)), so = [...sr, U, Se], ao = (n) => so.find(rr(n)), oo = /* @__PURE__ */ new Set(["brightness", "contrast", "saturate", "opacity"]);
2394
+ }, rr = (n) => (e) => e.test(n), ar = [Ne, L, Me, me, Pa, Ma, ro], Yn = (n) => ar.find(rr(n)), ao = [...ar, U, Se], so = (n) => ao.find(rr(n)), oo = /* @__PURE__ */ new Set(["brightness", "contrast", "saturate", "opacity"]);
2389
2395
  function lo(n) {
2390
2396
  const [e, t] = n.slice(0, -1).split("(");
2391
2397
  if (e === "drop-shadow")
2392
2398
  return n;
2393
- const [i] = t.match(an) || [];
2399
+ const [i] = t.match(sn) || [];
2394
2400
  if (!i)
2395
2401
  return n;
2396
2402
  const r = t.replace(i, "");
2397
- let s = oo.has(e) ? 1 : 0;
2398
- return i !== t && (s *= 100), e + "(" + s + r + ")";
2403
+ let a = oo.has(e) ? 1 : 0;
2404
+ return i !== t && (a *= 100), e + "(" + a + r + ")";
2399
2405
  }
2400
2406
  const co = /\b([a-z-]*)\(.*?\)/gu, Ut = I(v({}, Se), {
2401
2407
  getAnimatableNone: (n) => {
@@ -2486,9 +2492,9 @@ const co = /\b([a-z-]*)\(.*?\)/gu, Ut = I(v({}, Se), {
2486
2492
  borderLeftColor: U,
2487
2493
  filter: Ut,
2488
2494
  WebkitFilter: Ut
2489
- }), ar = (n) => ho[n];
2495
+ }), sr = (n) => ho[n];
2490
2496
  function or(n, e) {
2491
- let t = ar(n);
2497
+ let t = sr(n);
2492
2498
  return t !== Ut && (t = Se), t.getAnimatableNone ? t.getAnimatableNone(e) : void 0;
2493
2499
  }
2494
2500
  const Wn = [
@@ -2511,23 +2517,23 @@ class lr {
2511
2517
  scrapeMotionValuesFromProps(e, t, i) {
2512
2518
  return {};
2513
2519
  }
2514
- constructor({ parent: e, props: t, presenceContext: i, reducedMotionConfig: r, blockInitialAnimation: s, visualState: a }, o = {}) {
2520
+ constructor({ parent: e, props: t, presenceContext: i, reducedMotionConfig: r, blockInitialAnimation: a, visualState: s }, o = {}) {
2515
2521
  this.current = null, this.children = /* @__PURE__ */ new Set(), this.isVariantNode = !1, this.isControllingVariants = !1, this.shouldReduceMotion = null, this.values = /* @__PURE__ */ new Map(), this.KeyframeResolver = fn, this.features = {}, this.valueSubscriptions = /* @__PURE__ */ new Map(), this.prevMotionValues = {}, this.events = {}, this.propEventSubscriptions = {}, this.notifyUpdate = () => this.notify("Update", this.latestValues), this.render = () => {
2516
2522
  this.current && (this.triggerBuild(), this.renderInstance(this.current, this.renderState, this.props.style, this.projection));
2517
2523
  }, this.renderScheduledAt = 0, this.scheduleRender = () => {
2518
2524
  const p = ee.now();
2519
2525
  this.renderScheduledAt < p && (this.renderScheduledAt = p, ue.render(this.render, !1, !0));
2520
2526
  };
2521
- const { latestValues: l, renderState: u } = a;
2522
- this.latestValues = l, this.baseTarget = v({}, l), this.initialValues = t.initial ? v({}, l) : {}, this.renderState = u, this.parent = e, this.props = t, this.presenceContext = i, this.depth = e ? e.depth + 1 : 0, this.reducedMotionConfig = r, this.options = o, this.blockInitialAnimation = !!s, this.isControllingVariants = tr(t), this.isVariantNode = no(t), this.isVariantNode && (this.variantChildren = /* @__PURE__ */ new Set()), this.manuallyAnimateOnMount = !!(e && e.current);
2523
- const m = this.scrapeMotionValuesFromProps(t, {}, this), { willChange: d } = m, h = se(m, ["willChange"]);
2527
+ const { latestValues: l, renderState: u } = s;
2528
+ this.latestValues = l, this.baseTarget = v({}, l), this.initialValues = t.initial ? v({}, l) : {}, this.renderState = u, this.parent = e, this.props = t, this.presenceContext = i, this.depth = e ? e.depth + 1 : 0, this.reducedMotionConfig = r, this.options = o, this.blockInitialAnimation = !!a, this.isControllingVariants = tr(t), this.isVariantNode = no(t), this.isVariantNode && (this.variantChildren = /* @__PURE__ */ new Set()), this.manuallyAnimateOnMount = !!(e && e.current);
2529
+ const m = this.scrapeMotionValuesFromProps(t, {}, this), { willChange: d } = m, h = ae(m, ["willChange"]);
2524
2530
  for (const p in h) {
2525
2531
  const g = h[p];
2526
2532
  l[p] !== void 0 && J(g) && g.set(l[p], !1);
2527
2533
  }
2528
2534
  }
2529
2535
  mount(e) {
2530
- this.current = e, Je.set(e, this), this.projection && !this.projection.instance && this.projection.mount(e), this.parent && this.isVariantNode && !this.isControllingVariants && (this.removeFromVariantTree = this.parent.addVariantChild(this)), this.values.forEach((t, i) => this.bindToMotionValue(i, t)), er.current || Ja(), this.shouldReduceMotion = this.reducedMotionConfig === "never" ? !1 : this.reducedMotionConfig === "always" ? !0 : Yt.current, process.env.NODE_ENV !== "production" && ki(this.shouldReduceMotion !== !0, "You have Reduced Motion enabled on your device. Animations may not appear as expected."), this.parent && this.parent.children.add(this), this.update(this.props, this.presenceContext);
2536
+ this.current = e, Je.set(e, this), this.projection && !this.projection.instance && this.projection.mount(e), this.parent && this.isVariantNode && !this.isControllingVariants && (this.removeFromVariantTree = this.parent.addVariantChild(this)), this.values.forEach((t, i) => this.bindToMotionValue(i, t)), er.current || Js(), this.shouldReduceMotion = this.reducedMotionConfig === "never" ? !1 : this.reducedMotionConfig === "always" ? !0 : Yt.current, process.env.NODE_ENV !== "production" && ki(this.shouldReduceMotion !== !0, "You have Reduced Motion enabled on your device. Animations may not appear as expected."), this.parent && this.parent.children.add(this), this.update(this.props, this.presenceContext);
2531
2537
  }
2532
2538
  unmount() {
2533
2539
  this.projection && this.projection.unmount(), Rt(this.notifyUpdate), Rt(this.render), this.valueSubscriptions.forEach((e) => e()), this.valueSubscriptions.clear(), this.removeFromVariantTree && this.removeFromVariantTree(), this.parent && this.parent.children.delete(this);
@@ -2545,10 +2551,10 @@ class lr {
2545
2551
  i && this.onBindTransform && this.onBindTransform();
2546
2552
  const r = t.on("change", (o) => {
2547
2553
  this.latestValues[e] = o, this.props.onUpdate && ue.preRender(this.notifyUpdate), i && this.projection && (this.projection.isTransformDirty = !0);
2548
- }), s = t.on("renderRequest", this.scheduleRender);
2549
- let a;
2550
- window.MotionCheckAppearSync && (a = window.MotionCheckAppearSync(this, e, t)), this.valueSubscriptions.set(e, () => {
2551
- r(), s(), a && a(), t.owner && t.stop();
2554
+ }), a = t.on("renderRequest", this.scheduleRender);
2555
+ let s;
2556
+ window.MotionCheckAppearSync && (s = window.MotionCheckAppearSync(this, e, t)), this.valueSubscriptions.set(e, () => {
2557
+ r(), a(), s && s(), t.owner && t.stop();
2552
2558
  });
2553
2559
  }
2554
2560
  sortNodePosition(e) {
@@ -2562,8 +2568,8 @@ class lr {
2562
2568
  continue;
2563
2569
  const { isEnabled: i, Feature: r } = t;
2564
2570
  if (!this.features[e] && r && i(this.props) && (this.features[e] = new r(this)), this.features[e]) {
2565
- const s = this.features[e];
2566
- s.isMounted ? s.update() : (s.mount(), s.isMounted = !0);
2571
+ const a = this.features[e];
2572
+ a.isMounted ? a.update() : (a.mount(), a.isMounted = !0);
2567
2573
  }
2568
2574
  }
2569
2575
  }
@@ -2593,8 +2599,8 @@ class lr {
2593
2599
  for (let i = 0; i < Wn.length; i++) {
2594
2600
  const r = Wn[i];
2595
2601
  this.propEventSubscriptions[r] && (this.propEventSubscriptions[r](), delete this.propEventSubscriptions[r]);
2596
- const s = "on" + r, a = e[s];
2597
- a && (this.propEventSubscriptions[r] = this.on(r, a));
2602
+ const a = "on" + r, s = e[a];
2603
+ s && (this.propEventSubscriptions[r] = this.on(r, s));
2598
2604
  }
2599
2605
  this.prevMotionValues = io(this, this.scrapeMotionValuesFromProps(e, this.prevProps, this), this.prevMotionValues), this.handleChildMotionValue && this.handleChildMotionValue();
2600
2606
  }
@@ -2662,7 +2668,7 @@ class lr {
2662
2668
  readValue(e, t) {
2663
2669
  var r;
2664
2670
  let i = this.latestValues[e] !== void 0 || !this.current ? this.latestValues[e] : (r = this.getBaseTargetFromProps(this.props, e)) != null ? r : this.readValueFromInstance(this.current, e, this.options);
2665
- return i != null && (typeof i == "string" && (nr(i) || ir(i)) ? i = parseFloat(i) : !ao(i) && Se.test(t) && (i = or(e, t)), this.setBaseTarget(e, J(i) ? i.get() : i)), J(i) ? i.get() : i;
2671
+ return i != null && (typeof i == "string" && (nr(i) || ir(i)) ? i = parseFloat(i) : !so(i) && Se.test(t) && (i = or(e, t)), this.setBaseTarget(e, J(i) ? i.get() : i)), J(i) ? i.get() : i;
2666
2672
  }
2667
2673
  /**
2668
2674
  * Set the base target to later animate back to. This is currently
@@ -2676,12 +2682,12 @@ class lr {
2676
2682
  * props.
2677
2683
  */
2678
2684
  getBaseTarget(e) {
2679
- var s;
2685
+ var a;
2680
2686
  const { initial: t } = this.props;
2681
2687
  let i;
2682
2688
  if (typeof t == "string" || typeof t == "object") {
2683
- const a = Ci(this.props, t, (s = this.presenceContext) == null ? void 0 : s.custom);
2684
- a && (i = a[e]);
2689
+ const s = Ci(this.props, t, (a = this.presenceContext) == null ? void 0 : a.custom);
2690
+ s && (i = s[e]);
2685
2691
  }
2686
2692
  if (t && i !== void 0)
2687
2693
  return i;
@@ -2712,12 +2718,12 @@ function cr(n, e, t = 1) {
2712
2718
  const [i, r] = mo(n);
2713
2719
  if (!i)
2714
2720
  return;
2715
- const s = window.getComputedStyle(e).getPropertyValue(i);
2716
- if (s) {
2717
- const a = s.trim();
2718
- return nr(a) ? parseFloat(a) : a;
2721
+ const a = window.getComputedStyle(e).getPropertyValue(i);
2722
+ if (a) {
2723
+ const s = a.trim();
2724
+ return nr(s) ? parseFloat(s) : s;
2719
2725
  }
2720
- return sn(r) ? cr(r, e, t + 1) : r;
2726
+ return an(r) ? cr(r, e, t + 1) : r;
2721
2727
  }
2722
2728
  function go(n) {
2723
2729
  return typeof n == "number" ? n === 0 : n !== null ? n === "none" || n === "0" || ir(n) : !0;
@@ -2726,16 +2732,16 @@ const bo = /* @__PURE__ */ new Set(["auto", "none", "0"]);
2726
2732
  function vo(n, e, t) {
2727
2733
  let i = 0, r;
2728
2734
  for (; i < n.length && !r; ) {
2729
- const s = n[i];
2730
- typeof s == "string" && !bo.has(s) && et(s).values.length && (r = n[i]), i++;
2735
+ const a = n[i];
2736
+ typeof a == "string" && !bo.has(a) && et(a).values.length && (r = n[i]), i++;
2731
2737
  }
2732
2738
  if (r && t)
2733
- for (const s of e)
2734
- n[s] = or(t, r);
2739
+ for (const a of e)
2740
+ n[a] = or(t, r);
2735
2741
  }
2736
2742
  class yo extends fn {
2737
- constructor(e, t, i, r, s) {
2738
- super(e, t, i, r, s, !0);
2743
+ constructor(e, t, i, r, a) {
2744
+ super(e, t, i, r, a, !0);
2739
2745
  }
2740
2746
  readKeyframes() {
2741
2747
  const { unresolvedKeyframes: e, element: t, name: i } = this;
@@ -2744,16 +2750,16 @@ class yo extends fn {
2744
2750
  super.readKeyframes();
2745
2751
  for (let l = 0; l < e.length; l++) {
2746
2752
  let u = e[l];
2747
- if (typeof u == "string" && (u = u.trim(), sn(u))) {
2753
+ if (typeof u == "string" && (u = u.trim(), an(u))) {
2748
2754
  const d = cr(u, t.current);
2749
2755
  d !== void 0 && (e[l] = d), l === e.length - 1 && (this.finalKeyframe = u);
2750
2756
  }
2751
2757
  }
2752
2758
  if (this.resolveNoneKeyframes(), !Qi.has(i) || e.length !== 2)
2753
2759
  return;
2754
- const [r, s] = e, a = Yn(r), o = Yn(s);
2755
- if (a !== o)
2756
- if (zn(a) && zn(o))
2760
+ const [r, a] = e, s = Yn(r), o = Yn(a);
2761
+ if (s !== o)
2762
+ if (zn(s) && zn(o))
2757
2763
  for (let l = 0; l < e.length; l++) {
2758
2764
  const u = e[l];
2759
2765
  typeof u == "string" && (e[l] = parseFloat(u));
@@ -2781,8 +2787,8 @@ class yo extends fn {
2781
2787
  return;
2782
2788
  const r = e.getValue(t);
2783
2789
  r && r.jump(this.measuredOrigin, !1);
2784
- const s = i.length - 1, a = i[s];
2785
- i[s] = ke[t](e.measureViewportBox(), window.getComputedStyle(e.current)), a !== null && this.finalKeyframe === void 0 && (this.finalKeyframe = a), (o = this.removedTransforms) != null && o.length && this.removedTransforms.forEach(([l, u]) => {
2790
+ const a = i.length - 1, s = i[a];
2791
+ i[a] = ke[t](e.measureViewportBox(), window.getComputedStyle(e.current)), s !== null && this.finalKeyframe === void 0 && (this.finalKeyframe = s), (o = this.removedTransforms) != null && o.length && this.removedTransforms.forEach(([l, u]) => {
2786
2792
  e.getValue(l).set(u);
2787
2793
  }), this.resolveNoneKeyframes();
2788
2794
  }
@@ -2816,58 +2822,58 @@ const ur = (n, e) => e && typeof n == "number" ? e.transform(n) : n, Co = {
2816
2822
  }, ko = Re.length;
2817
2823
  function Eo(n, e, t) {
2818
2824
  let i = "", r = !0;
2819
- for (let s = 0; s < ko; s++) {
2820
- const a = Re[s], o = n[a];
2825
+ for (let a = 0; a < ko; a++) {
2826
+ const s = Re[a], o = n[s];
2821
2827
  if (o === void 0)
2822
2828
  continue;
2823
2829
  let l = !0;
2824
- if (typeof o == "number" ? l = o === (a.startsWith("scale") ? 1 : 0) : l = parseFloat(o) === 0, !l || t) {
2825
- const u = ur(o, vn[a]);
2830
+ if (typeof o == "number" ? l = o === (s.startsWith("scale") ? 1 : 0) : l = parseFloat(o) === 0, !l || t) {
2831
+ const u = ur(o, vn[s]);
2826
2832
  if (!l) {
2827
2833
  r = !1;
2828
- const d = Co[a] || a;
2834
+ const d = Co[s] || s;
2829
2835
  i += `${d}(${u}) `;
2830
2836
  }
2831
- t && (e[a] = u);
2837
+ t && (e[s] = u);
2832
2838
  }
2833
2839
  }
2834
2840
  return i = i.trim(), t ? i = t(e, r ? "" : i) : r && (i = "none"), i;
2835
2841
  }
2836
2842
  function hr(n, e, t) {
2837
- const { style: i, vars: r, transformOrigin: s } = n;
2838
- let a = !1, o = !1;
2843
+ const { style: i, vars: r, transformOrigin: a } = n;
2844
+ let s = !1, o = !1;
2839
2845
  for (const l in e) {
2840
2846
  const u = e[l];
2841
2847
  if (Oe.has(l)) {
2842
- a = !0;
2848
+ s = !0;
2843
2849
  continue;
2844
2850
  } else if (Ai(l)) {
2845
2851
  r[l] = u;
2846
2852
  continue;
2847
2853
  } else {
2848
2854
  const d = ur(u, vn[l]);
2849
- l.startsWith("origin") ? (o = !0, s[l] = d) : i[l] = d;
2855
+ l.startsWith("origin") ? (o = !0, a[l] = d) : i[l] = d;
2850
2856
  }
2851
2857
  }
2852
- if (e.transform || (a || t ? i.transform = Eo(e, n.transform, t) : i.transform && (i.transform = "none")), o) {
2853
- const { originX: l = "50%", originY: u = "50%", originZ: d = 0 } = s;
2858
+ if (e.transform || (s || t ? i.transform = Eo(e, n.transform, t) : i.transform && (i.transform = "none")), o) {
2859
+ const { originX: l = "50%", originY: u = "50%", originZ: d = 0 } = a;
2854
2860
  i.transformOrigin = `${l} ${u} ${d}`;
2855
2861
  }
2856
2862
  }
2857
2863
  function pr(n, { style: e, vars: t }, i, r) {
2858
2864
  Object.assign(n.style, e, r && r.getProjectionStyles(i));
2859
- for (const s in t)
2860
- n.style.setProperty(s, t[s]);
2865
+ for (const a in t)
2866
+ n.style.setProperty(a, t[a]);
2861
2867
  }
2862
2868
  const xo = {};
2863
2869
  function wo(n, { layout: e, layoutId: t }) {
2864
2870
  return Oe.has(n) || n.startsWith("origin") || (e || t !== void 0) && (!!xo[n] || n === "opacity");
2865
2871
  }
2866
2872
  function mr(n, e, t) {
2867
- var s;
2873
+ var a;
2868
2874
  const { style: i } = n, r = {};
2869
- for (const a in i)
2870
- (J(i[a]) || e.style && J(e.style[a]) || wo(a, n) || ((s = t == null ? void 0 : t.getValue(a)) == null ? void 0 : s.liveStyle) !== void 0) && (r[a] = i[a]);
2875
+ for (const s in i)
2876
+ (J(i[s]) || e.style && J(e.style[s]) || wo(s, n) || ((a = t == null ? void 0 : t.getValue(s)) == null ? void 0 : a.liveStyle) !== void 0) && (r[s] = i[s]);
2871
2877
  return r;
2872
2878
  }
2873
2879
  function To(n) {
@@ -2880,14 +2886,14 @@ class Ao extends dr {
2880
2886
  readValueFromInstance(e, t) {
2881
2887
  var i;
2882
2888
  if (Oe.has(t))
2883
- return (i = this.projection) != null && i.isProjecting ? zt(t) : Ca(e, t);
2889
+ return (i = this.projection) != null && i.isProjecting ? zt(t) : Cs(e, t);
2884
2890
  {
2885
- const r = To(e), s = (Ai(t) ? r.getPropertyValue(t) : r[t]) || 0;
2886
- return typeof s == "string" ? s.trim() : s;
2891
+ const r = To(e), a = (Ai(t) ? r.getPropertyValue(t) : r[t]) || 0;
2892
+ return typeof a == "string" ? a.trim() : a;
2887
2893
  }
2888
2894
  }
2889
2895
  measureInstanceViewportBox(e, { transformPagePoint: t }) {
2890
- return Wa(e, t);
2896
+ return Ws(e, t);
2891
2897
  }
2892
2898
  build(e, t, i) {
2893
2899
  hr(e, t, i.transformTemplate);
@@ -2937,10 +2943,10 @@ const Vo = {
2937
2943
  };
2938
2944
  function Mo(n, e, t = 1, i = 0, r = !0) {
2939
2945
  n.pathLength = 1;
2940
- const s = r ? Vo : Io;
2941
- n[s.offset] = L.transform(-i);
2942
- const a = L.transform(e), o = L.transform(t);
2943
- n[s.array] = `${a} ${o}`;
2946
+ const a = r ? Vo : Io;
2947
+ n[a.offset] = L.transform(-i);
2948
+ const s = L.transform(e), o = L.transform(t);
2949
+ n[a.array] = `${s} ${o}`;
2944
2950
  }
2945
2951
  function Po(n, h, l, u, d) {
2946
2952
  var m = h, {
@@ -2948,9 +2954,9 @@ function Po(n, h, l, u, d) {
2948
2954
  attrY: t,
2949
2955
  attrScale: i,
2950
2956
  pathLength: r,
2951
- pathSpacing: s = 1,
2952
- pathOffset: a = 0
2953
- } = m, o = se(m, [
2957
+ pathSpacing: a = 1,
2958
+ pathOffset: s = 0
2959
+ } = m, o = ae(m, [
2954
2960
  "attrX",
2955
2961
  "attrY",
2956
2962
  "attrScale",
@@ -2965,7 +2971,7 @@ function Po(n, h, l, u, d) {
2965
2971
  }
2966
2972
  n.attrs = n.style, n.style = {};
2967
2973
  const { attrs: p, style: g } = n;
2968
- p.transform && (g.transform = p.transform, delete p.transform), (g.transform || p.transformOrigin) && (g.transformOrigin = (b = p.transformOrigin) != null ? b : "50% 50%", delete p.transformOrigin), g.transform && (g.transformBox = (y = d == null ? void 0 : d.transformBox) != null ? y : "fill-box", delete p.transformBox), e !== void 0 && (p.x = e), t !== void 0 && (p.y = t), i !== void 0 && (p.scale = i), r !== void 0 && Mo(p, r, s, a, !1);
2974
+ p.transform && (g.transform = p.transform, delete p.transform), (g.transform || p.transformOrigin) && (g.transformOrigin = (b = p.transformOrigin) != null ? b : "50% 50%", delete p.transformOrigin), g.transform && (g.transformBox = (y = d == null ? void 0 : d.transformBox) != null ? y : "fill-box", delete p.transformBox), e !== void 0 && (p.x = e), t !== void 0 && (p.y = t), i !== void 0 && (p.scale = i), r !== void 0 && Mo(p, r, a, s, !1);
2969
2975
  }
2970
2976
  const fr = /* @__PURE__ */ new Set([
2971
2977
  "baseFrequency",
@@ -3001,8 +3007,8 @@ function Oo(n, e, t) {
3001
3007
  const i = mr(n, e, t);
3002
3008
  for (const r in n)
3003
3009
  if (J(n[r]) || J(e[r])) {
3004
- const s = Re.indexOf(r) !== -1 ? "attr" + r.charAt(0).toUpperCase() + r.substring(1) : r;
3005
- i[s] = n[r];
3010
+ const a = Re.indexOf(r) !== -1 ? "attr" + r.charAt(0).toUpperCase() + r.substring(1) : r;
3011
+ i[a] = n[r];
3006
3012
  }
3007
3013
  return i;
3008
3014
  }
@@ -3015,7 +3021,7 @@ class No extends dr {
3015
3021
  }
3016
3022
  readValueFromInstance(e, t) {
3017
3023
  if (Oe.has(t)) {
3018
- const i = ar(t);
3024
+ const i = sr(t);
3019
3025
  return i && i.default || 0;
3020
3026
  }
3021
3027
  return t = fr.has(t) ? t : rn(t), e.getAttribute(t);
@@ -3081,21 +3087,21 @@ function br(n, e, t, i) {
3081
3087
  if (zo(n, e))
3082
3088
  r.push(Bo(n, Qt(e) && e.default || e, t && (t.default || t)));
3083
3089
  else {
3084
- const s = pi(n, e, i), a = s.length;
3085
- ce(!!a, "No valid elements provided.");
3086
- for (let o = 0; o < a; o++) {
3087
- const l = s[o], u = l instanceof Element ? Fo : jo;
3090
+ const a = pi(n, e, i), s = a.length;
3091
+ ce(!!s, "No valid elements provided.");
3092
+ for (let o = 0; o < s; o++) {
3093
+ const l = a[o], u = l instanceof Element ? Fo : jo;
3088
3094
  Je.has(l) || u(l);
3089
3095
  const d = Je.get(l), h = v({}, t);
3090
- "delay" in h && typeof h.delay == "function" && (h.delay = h.delay(o, a)), r.push(...Ha(d, I(v({}, e), { transition: h }), {}));
3096
+ "delay" in h && typeof h.delay == "function" && (h.delay = h.delay(o, s)), r.push(...Hs(d, I(v({}, e), { transition: h }), {}));
3091
3097
  }
3092
3098
  }
3093
3099
  return r;
3094
3100
  }
3095
3101
  function $o(n, e, t) {
3096
3102
  const i = [];
3097
- return Zr(n, e, t, { spring: tt }).forEach(({ keyframes: s, transition: a }, o) => {
3098
- i.push(...br(o, s, a));
3103
+ return Zr(n, e, t, { spring: tt }).forEach(({ keyframes: a, transition: s }, o) => {
3104
+ i.push(...br(o, a, s));
3099
3105
  }), i;
3100
3106
  }
3101
3107
  class Ko {
@@ -3174,8 +3180,8 @@ function Go(n) {
3174
3180
  }
3175
3181
  function Ho(n) {
3176
3182
  function e(t, i, r) {
3177
- let s = [];
3178
- return Go(t) ? s = $o(t, i, n) : s = br(t, i, r, n), new qo(s);
3183
+ let a = [];
3184
+ return Go(t) ? a = $o(t, i, n) : a = br(t, i, r, n), new qo(a);
3179
3185
  }
3180
3186
  return e;
3181
3187
  }
@@ -3233,9 +3239,9 @@ class rl {
3233
3239
  return this.loader;
3234
3240
  }
3235
3241
  }
3236
- const sl = "_checkout_mcuv2_1", al = "_hidden_mcuv2_8", ol = "_formInitial_mcuv2_12", ll = "_btnsInitial_mcuv2_22", Z = {
3237
- checkout: sl,
3238
- hidden: al,
3242
+ const al = "_checkout_mcuv2_1", sl = "_hidden_mcuv2_8", ol = "_formInitial_mcuv2_12", ll = "_btnsInitial_mcuv2_22", Z = {
3243
+ checkout: al,
3244
+ hidden: sl,
3239
3245
  formInitial: ol,
3240
3246
  btnsInitial: ll
3241
3247
  }, cl = "_buttons_qc8am_1", dl = "_hidden_qc8am_8", ul = "_skeleton_qc8am_12", be = {
@@ -3457,9 +3463,9 @@ var $e = {}, Qn;
3457
3463
  function fl() {
3458
3464
  if (Qn) return $e;
3459
3465
  Qn = 1, Object.defineProperty($e, "__esModule", { value: !0 }), $e.matches = void 0;
3460
- function n(i, r, s) {
3461
- var a = String(r).length, o = i.substr(0, a), l = parseInt(o, 10);
3462
- return r = parseInt(String(r).substr(0, o.length), 10), s = parseInt(String(s).substr(0, o.length), 10), l >= r && l <= s;
3466
+ function n(i, r, a) {
3467
+ var s = String(r).length, o = i.substr(0, s), l = parseInt(o, 10);
3468
+ return r = parseInt(String(r).substr(0, o.length), 10), a = parseInt(String(a).substr(0, o.length), 10), l >= r && l <= a;
3463
3469
  }
3464
3470
  function e(i, r) {
3465
3471
  return r = String(r), r.substring(0, i.length) === i.substring(0, r.length);
@@ -3474,13 +3480,13 @@ function gl() {
3474
3480
  if (ei) return Be;
3475
3481
  ei = 1, Object.defineProperty(Be, "__esModule", { value: !0 }), Be.addMatchingCardsToResults = void 0;
3476
3482
  var n = yr(), e = fl();
3477
- function t(i, r, s) {
3478
- var a, o;
3479
- for (a = 0; a < r.patterns.length; a++) {
3480
- var l = r.patterns[a];
3483
+ function t(i, r, a) {
3484
+ var s, o;
3485
+ for (s = 0; s < r.patterns.length; s++) {
3486
+ var l = r.patterns[s];
3481
3487
  if ((0, e.matches)(i, l)) {
3482
3488
  var u = (0, n.clone)(r);
3483
- Array.isArray(l) ? o = String(l[0]).length : o = String(l).length, i.length >= o && (u.matchStrength = o), s.push(u);
3489
+ Array.isArray(l) ? o = String(l[0]).length : o = String(l).length, i.length >= o && (u.matchStrength = o), a.push(u);
3484
3490
  break;
3485
3491
  }
3486
3492
  }
@@ -3519,13 +3525,13 @@ function yl() {
3519
3525
  ii = 1;
3520
3526
  var n = Ge && Ge.__assign || function() {
3521
3527
  return n = Object.assign || function(g) {
3522
- for (var b, y = 1, k = arguments.length; y < k; y++) {
3528
+ for (var b, y = 1, E = arguments.length; y < E; y++) {
3523
3529
  b = arguments[y];
3524
3530
  for (var V in b) Object.prototype.hasOwnProperty.call(b, V) && (g[V] = b[V]);
3525
3531
  }
3526
3532
  return g;
3527
3533
  }, n.apply(this, arguments);
3528
- }, e = ml(), t = gl(), i = bl(), r = vl(), s = yr(), a = {}, o = {
3534
+ }, e = ml(), t = gl(), i = bl(), r = vl(), a = yr(), s = {}, o = {
3529
3535
  VISA: "visa",
3530
3536
  MASTERCARD: "mastercard",
3531
3537
  AMERICAN_EXPRESS: "american-express",
@@ -3551,13 +3557,13 @@ function yl() {
3551
3557
  o.MIR,
3552
3558
  o.HIPER,
3553
3559
  o.HIPERCARD
3554
- ], u = (0, s.clone)(l);
3560
+ ], u = (0, a.clone)(l);
3555
3561
  function d(g) {
3556
- return a[g] || e[g];
3562
+ return s[g] || e[g];
3557
3563
  }
3558
3564
  function h() {
3559
3565
  return u.map(function(g) {
3560
- return (0, s.clone)(d(g));
3566
+ return (0, a.clone)(d(g));
3561
3567
  });
3562
3568
  }
3563
3569
  function m(g, b) {
@@ -3573,34 +3579,34 @@ function yl() {
3573
3579
  return b;
3574
3580
  if (g.length === 0)
3575
3581
  return h();
3576
- u.forEach(function(k) {
3577
- var V = d(k);
3582
+ u.forEach(function(E) {
3583
+ var V = d(E);
3578
3584
  (0, t.addMatchingCardsToResults)(g, V, b);
3579
3585
  });
3580
3586
  var y = (0, r.findBestMatch)(b);
3581
3587
  return y ? [y] : b;
3582
3588
  }
3583
3589
  return p.getTypeInfo = function(g) {
3584
- return (0, s.clone)(d(g));
3590
+ return (0, a.clone)(d(g));
3585
3591
  }, p.removeCard = function(g) {
3586
3592
  var b = m(g);
3587
3593
  u.splice(b, 1);
3588
3594
  }, p.addCard = function(g) {
3589
3595
  var b = m(g.type, !0);
3590
- a[g.type] = g, b === -1 && u.push(g.type);
3596
+ s[g.type] = g, b === -1 && u.push(g.type);
3591
3597
  }, p.updateCard = function(g, b) {
3592
- var y = a[g] || e[g];
3598
+ var y = s[g] || e[g];
3593
3599
  if (!y)
3594
3600
  throw new Error('"'.concat(g, "\" is not a recognized type. Use `addCard` instead.'"));
3595
3601
  if (b.type && y.type !== b.type)
3596
3602
  throw new Error("Cannot overwrite type parameter.");
3597
- var k = (0, s.clone)(y);
3598
- k = n(n({}, k), b), a[k.type] = k;
3603
+ var E = (0, a.clone)(y);
3604
+ E = n(n({}, E), b), s[E.type] = E;
3599
3605
  }, p.changeOrder = function(g, b) {
3600
3606
  var y = m(g);
3601
3607
  u.splice(y, 1), u.splice(b, 0, g);
3602
3608
  }, p.resetModifications = function() {
3603
- u = (0, s.clone)(l), a = {};
3609
+ u = (0, a.clone)(l), s = {};
3604
3610
  }, p.types = o, Ge = p, Ge;
3605
3611
  }
3606
3612
  var Pe = yl();
@@ -3611,12 +3617,12 @@ Pe.updateCard("unionpay", {
3611
3617
  gaps: [4, 8, 12, 16]
3612
3618
  });
3613
3619
  const Cl = (n, e) => {
3614
- const t = Pe.getTypeInfo(e), i = n.replace(/\D/g, ""), r = (t == null ? void 0 : t.gaps) || [4, 8, 12], s = t ? Math.max(...t.lengths) + r.length : 19, a = [0].concat(r, i.length), o = [];
3615
- for (let l = 0; a[l] < i.length; l++) {
3616
- const u = a[l], d = Math.min(a[l + 1], i.length);
3620
+ const t = Pe.getTypeInfo(e), i = n.replace(/\D/g, ""), r = (t == null ? void 0 : t.gaps) || [4, 8, 12], a = t ? Math.max(...t.lengths) + r.length : 19, s = [0].concat(r, i.length), o = [];
3621
+ for (let l = 0; s[l] < i.length; l++) {
3622
+ const u = s[l], d = Math.min(s[l + 1], i.length);
3617
3623
  o.push(i.slice(u, d));
3618
3624
  }
3619
- return o.join(" ").slice(0, s);
3625
+ return o.join(" ").slice(0, a);
3620
3626
  }, kl = (n, e) => {
3621
3627
  const t = Pe.getTypeInfo(e), i = (t == null ? void 0 : t.code.size) || 4;
3622
3628
  return n.replace(/\D/g, "").slice(0, i);
@@ -3714,7 +3720,7 @@ const bt = [
3714
3720
  t && (r *= 2, r > 9 && (r -= 9)), e += r, t = !t;
3715
3721
  }
3716
3722
  return e % 10 === 0;
3717
- }, si = (n, e) => {
3723
+ }, ai = (n, e) => {
3718
3724
  const t = n.replace(/\D/g, "");
3719
3725
  if (!t)
3720
3726
  return { isValid: !1, cardType: null, error: Y.Empty };
@@ -3763,7 +3769,7 @@ const bt = [
3763
3769
  }, Ml = (n) => {
3764
3770
  var e, t;
3765
3771
  return n ? typeof n.amount != "number" ? (console.error("Transaction amount is missing or invalid for Apple Pay"), null) : n.currency ? n.country ? n.merchant_id ? n.checkout_config && !((e = n.checkout_config) == null ? void 0 : e.find(
3766
- ({ is_active: r, type: s }) => r && s === x.APPLE_PAY
3772
+ ({ is_active: r, type: a }) => r && a === x.APPLE_PAY
3767
3773
  )) ? null : {
3768
3774
  amount: n.amount,
3769
3775
  currency: n.currency,
@@ -3889,24 +3895,24 @@ var dt = { exports: {} }, He = {};
3889
3895
  * This source code is licensed under the MIT license found in the
3890
3896
  * LICENSE file in the root directory of this source tree.
3891
3897
  */
3892
- var ai;
3898
+ var si;
3893
3899
  function Nl() {
3894
- if (ai) return He;
3895
- ai = 1;
3900
+ if (si) return He;
3901
+ si = 1;
3896
3902
  var n = Symbol.for("react.transitional.element"), e = Symbol.for("react.fragment");
3897
- function t(i, r, s) {
3898
- var a = null;
3899
- if (s !== void 0 && (a = "" + s), r.key !== void 0 && (a = "" + r.key), "key" in r) {
3900
- s = {};
3903
+ function t(i, r, a) {
3904
+ var s = null;
3905
+ if (a !== void 0 && (s = "" + a), r.key !== void 0 && (s = "" + r.key), "key" in r) {
3906
+ a = {};
3901
3907
  for (var o in r)
3902
- o !== "key" && (s[o] = r[o]);
3903
- } else s = r;
3904
- return r = s.ref, {
3908
+ o !== "key" && (a[o] = r[o]);
3909
+ } else a = r;
3910
+ return r = a.ref, {
3905
3911
  $$typeof: n,
3906
3912
  type: i,
3907
- key: a,
3913
+ key: s,
3908
3914
  ref: r !== void 0 ? r : null,
3909
- props: s
3915
+ props: a
3910
3916
  };
3911
3917
  }
3912
3918
  return He.Fragment = e, He.jsx = t, He.jsxs = t, He;
@@ -3932,7 +3938,7 @@ function Sl() {
3932
3938
  switch (f) {
3933
3939
  case b:
3934
3940
  return "Fragment";
3935
- case k:
3941
+ case E:
3936
3942
  return "Profiler";
3937
3943
  case y:
3938
3944
  return "StrictMode";
@@ -4002,10 +4008,10 @@ function Sl() {
4002
4008
  var f = q.A;
4003
4009
  return f === null ? null : f.getOwner();
4004
4010
  }
4005
- function s() {
4011
+ function a() {
4006
4012
  return Error("react-stack-top-frame");
4007
4013
  }
4008
- function a(f) {
4014
+ function s(f) {
4009
4015
  if (Te.call(f, "key")) {
4010
4016
  var P = Object.getOwnPropertyDescriptor(f, "key").get;
4011
4017
  if (P && P.isReactWarning) return !1;
@@ -4093,7 +4099,7 @@ React keys must be passed directly to JSX without using spread:
4093
4099
  z
4094
4100
  ), ne[z + G] = !0);
4095
4101
  }
4096
- if (z = null, N !== void 0 && (t(N), z = "" + N), a(P) && (t(P.key), z = "" + P.key), "key" in P) {
4102
+ if (z = null, N !== void 0 && (t(N), z = "" + N), s(P) && (t(P.key), z = "" + P.key), "key" in P) {
4097
4103
  N = {};
4098
4104
  for (var pe in P)
4099
4105
  pe !== "key" && (N[pe] = P[pe]);
@@ -4115,7 +4121,7 @@ React keys must be passed directly to JSX without using spread:
4115
4121
  function h(f) {
4116
4122
  typeof f == "object" && f !== null && f.$$typeof === p && f._store && (f._store.validated = 1);
4117
4123
  }
4118
- var m = wr, p = Symbol.for("react.transitional.element"), g = Symbol.for("react.portal"), b = Symbol.for("react.fragment"), y = Symbol.for("react.strict_mode"), k = Symbol.for("react.profiler"), V = Symbol.for("react.consumer"), _ = Symbol.for("react.context"), M = Symbol.for("react.forward_ref"), T = Symbol.for("react.suspense"), D = Symbol.for("react.suspense_list"), C = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), R = Symbol.for("react.activity"), O = Symbol.for("react.client.reference"), q = m.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, Te = Object.prototype.hasOwnProperty, te = Array.isArray, fe = console.createTask ? console.createTask : function() {
4124
+ var m = wr, p = Symbol.for("react.transitional.element"), g = Symbol.for("react.portal"), b = Symbol.for("react.fragment"), y = Symbol.for("react.strict_mode"), E = Symbol.for("react.profiler"), V = Symbol.for("react.consumer"), _ = Symbol.for("react.context"), M = Symbol.for("react.forward_ref"), T = Symbol.for("react.suspense"), D = Symbol.for("react.suspense_list"), C = Symbol.for("react.memo"), w = Symbol.for("react.lazy"), R = Symbol.for("react.activity"), O = Symbol.for("react.client.reference"), q = m.__CLIENT_INTERNALS_DO_NOT_USE_OR_WARN_USERS_THEY_CANNOT_UPGRADE, Te = Object.prototype.hasOwnProperty, te = Array.isArray, fe = console.createTask ? console.createTask : function() {
4119
4125
  return null;
4120
4126
  };
4121
4127
  m = {
@@ -4125,8 +4131,8 @@ React keys must be passed directly to JSX without using spread:
4125
4131
  };
4126
4132
  var he, kt = {}, Et = m.react_stack_bottom_frame.bind(
4127
4133
  m,
4128
- s
4129
- )(), at = fe(i(s)), ne = {};
4134
+ a
4135
+ )(), st = fe(i(a)), ne = {};
4130
4136
  Ye.Fragment = b, Ye.jsx = function(f, P, N, G, ie) {
4131
4137
  var X = 1e4 > q.recentlyCreatedOwnerStacks++;
4132
4138
  return d(
@@ -4137,7 +4143,7 @@ React keys must be passed directly to JSX without using spread:
4137
4143
  G,
4138
4144
  ie,
4139
4145
  X ? Error("react-stack-top-frame") : Et,
4140
- X ? fe(i(f)) : at
4146
+ X ? fe(i(f)) : st
4141
4147
  );
4142
4148
  }, Ye.jsxs = function(f, P, N, G, ie) {
4143
4149
  var X = 1e4 > q.recentlyCreatedOwnerStacks++;
@@ -4149,7 +4155,7 @@ React keys must be passed directly to JSX without using spread:
4149
4155
  G,
4150
4156
  ie,
4151
4157
  X ? Error("react-stack-top-frame") : Et,
4152
- X ? fe(i(f)) : at
4158
+ X ? fe(i(f)) : st
4153
4159
  );
4154
4160
  };
4155
4161
  }()), Ye;
@@ -4184,28 +4190,28 @@ class Bl {
4184
4190
  this.onPaymentAttempt = this.config.state.checkout.getState().onCheckoutAttempt, this.ev = this.config.service.ev, this.customButtonStyles = t, this.element = document.createElement("div"), this.element.classList.add(Lt.applePay, Lt.hidden);
4185
4191
  }
4186
4192
  init(e) {
4187
- return E(this, null, function* () {
4193
+ return k(this, null, function* () {
4188
4194
  if (!this.config) return !1;
4189
4195
  const t = this.config.state.transaction.getState(), i = this.config.state.translate.locale(), r = Ml(t);
4190
4196
  if (!r)
4191
4197
  return !1;
4192
- const s = e ? I(v({}, e), {
4193
- onError: (a) => {
4198
+ const a = e ? I(v({}, e), {
4199
+ onError: (s) => {
4194
4200
  var l, u;
4195
4201
  if (!this.isInitialized) {
4196
- console.error("Apple Pay error:", a);
4202
+ console.error("Apple Pay error:", s);
4197
4203
  return;
4198
4204
  }
4199
4205
  const o = this.config.state.translate.messages();
4200
- a != null && a.toLowerCase().includes("cancelled") ? (l = e.onCancel) == null || l.call(e) : (vt(a, o), (u = e.onError) == null || u.call(e, a));
4206
+ s != null && s.toLowerCase().includes("cancelled") ? (l = e.onCancel) == null || l.call(e) : (vt(s, o), (u = e.onError) == null || u.call(e, s));
4201
4207
  },
4202
- onSuccess: (a) => {
4208
+ onSuccess: (s) => {
4203
4209
  var o;
4204
- (o = e.onSuccess) == null || o.call(e, a);
4210
+ (o = e.onSuccess) == null || o.call(e, s);
4205
4211
  }
4206
4212
  }) : void 0;
4207
4213
  return yield this.ev.initApple(
4208
- I(v({}, s), {
4214
+ I(v({}, a), {
4209
4215
  transaction: r,
4210
4216
  supportedCardTypes: Pl(jl),
4211
4217
  locale: Dl(i || "en"),
@@ -4261,27 +4267,27 @@ class ql {
4261
4267
  this.config = e, this.ev = this.config.service.ev, this.customButtonStyles = this.config.state.styles.getState().GooglePayButton, this.onPaymentAttempt = this.config.state.checkout.getState().onCheckoutAttempt, this.element = document.createElement("div"), this.element.classList.add(It.googlePay, It.hidden);
4262
4268
  }
4263
4269
  init(e) {
4264
- return E(this, null, function* () {
4270
+ return k(this, null, function* () {
4265
4271
  if (!this.config) return !1;
4266
4272
  const t = this.config.state.transaction.getState(), i = this.config.state.translate.locale(), r = Il(t);
4267
4273
  if (!r)
4268
4274
  return !1;
4269
- const s = e ? I(v({}, e), {
4270
- onError: (a) => {
4275
+ const a = e ? I(v({}, e), {
4276
+ onError: (s) => {
4271
4277
  var o;
4272
4278
  if (!this.isInitialized) {
4273
- console.error("Google Pay error:", a);
4279
+ console.error("Google Pay error:", s);
4274
4280
  return;
4275
4281
  }
4276
- vt(a, this.config.state.translate.messages()), (o = e.onError) == null || o.call(e, a);
4282
+ vt(s, this.config.state.translate.messages()), (o = e.onError) == null || o.call(e, s);
4277
4283
  },
4278
- onSuccess: (a) => {
4284
+ onSuccess: (s) => {
4279
4285
  var o;
4280
- (o = e.onSuccess) == null || o.call(e, a);
4286
+ (o = e.onSuccess) == null || o.call(e, s);
4281
4287
  }
4282
4288
  }) : void 0;
4283
4289
  return yield this.ev.initGoogle(
4284
- I(v({}, s), {
4290
+ I(v({}, a), {
4285
4291
  transaction: r,
4286
4292
  locale: Rl(i || "en"),
4287
4293
  onPaymentAttempt: this.onPaymentAttempt
@@ -4317,11 +4323,11 @@ class Yl {
4317
4323
  }
4318
4324
  // init
4319
4325
  init(e) {
4320
- return E(this, null, function* () {
4321
- var a, o;
4326
+ return k(this, null, function* () {
4327
+ var s, o;
4322
4328
  if (!this.config)
4323
4329
  return !1;
4324
- const t = this.config.state.transaction.getState(), i = this.config.state.checkout.getState(), r = () => E(this, null, function* () {
4330
+ const t = this.config.state.transaction.getState(), i = this.config.state.checkout.getState(), r = () => k(this, null, function* () {
4325
4331
  try {
4326
4332
  return yield Rr(i.clientToken, i.environment, i.apiVersion);
4327
4333
  } catch (l) {
@@ -4330,7 +4336,7 @@ class Yl {
4330
4336
  });
4331
4337
  if (!t || Object.keys(t).length === 0)
4332
4338
  return console.error("PayPal transaction data is empty or invalid"), !1;
4333
- if (!((a = t == null ? void 0 : t.paypal_info) != null && a.client_id))
4339
+ if (!((s = t == null ? void 0 : t.paypal_info) != null && s.client_id))
4334
4340
  return !1;
4335
4341
  try {
4336
4342
  if (yield this.paypal.init({
@@ -4344,7 +4350,7 @@ class Yl {
4344
4350
  } catch (l) {
4345
4351
  return !1;
4346
4352
  }
4347
- const s = e ? I(v({}, e), {
4353
+ const a = e ? I(v({}, e), {
4348
4354
  onError: (l) => {
4349
4355
  var d, h;
4350
4356
  if (this.emitAttemptOnce(), !this.isInitialized) {
@@ -4363,24 +4369,24 @@ class Yl {
4363
4369
  }
4364
4370
  }) : void 0;
4365
4371
  try {
4366
- yield this.paypal.render(this.element, I(v({}, s), {
4372
+ yield this.paypal.render(this.element, I(v({}, a), {
4367
4373
  createBillingAgreement: r,
4368
4374
  onClick: () => {
4369
4375
  this.emitAttemptOnce();
4370
4376
  },
4371
- onApprove: (u) => E(this, [u], function* ({ billingToken: l }) {
4377
+ onApprove: (u) => k(this, [u], function* ({ billingToken: l }) {
4372
4378
  var d;
4373
- (d = s == null ? void 0 : s.onSuccess) == null || d.call(s, l || "");
4379
+ (d = a == null ? void 0 : a.onSuccess) == null || d.call(a, l || "");
4374
4380
  }),
4375
4381
  style: (o = this.customButtonStyles) == null ? void 0 : o.styles,
4376
4382
  onCancel: () => {
4377
4383
  var l;
4378
- (l = s == null ? void 0 : s.onCancel) == null || l.call(s);
4384
+ (l = a == null ? void 0 : a.onCancel) == null || l.call(a);
4379
4385
  },
4380
4386
  onError: (l) => {
4381
4387
  var d, h;
4382
4388
  const u = this.isUserCancellationError(l);
4383
- !u && l ? (d = s == null ? void 0 : s.onError) == null || d.call(s, l) : u && ((h = s == null ? void 0 : s.onCancel) == null || h.call(s));
4389
+ !u && l ? (d = a == null ? void 0 : a.onError) == null || d.call(a, l) : u && ((h = a == null ? void 0 : a.onCancel) == null || h.call(a));
4384
4390
  }
4385
4391
  }));
4386
4392
  } catch (l) {
@@ -4408,7 +4414,7 @@ class Yl {
4408
4414
  "cancelled by user",
4409
4415
  "user cancelled",
4410
4416
  "popup close"
4411
- ].some((s) => t.toLowerCase().includes(s));
4417
+ ].some((a) => t.toLowerCase().includes(a));
4412
4418
  }
4413
4419
  setupInterceptOverlay() {
4414
4420
  if (this.interceptOverlay) return;
@@ -4469,8 +4475,8 @@ class Zl {
4469
4475
  const t = this.config.state.styles.getState().WalletButton, i = this.config.state.translate;
4470
4476
  this.element = document.createElement("button"), this.element.classList.add(ci.button, ci.press), t != null && t.className && F(this.element, t.className), t != null && t.styles && Object.assign(this.element.style, t.styles);
4471
4477
  const r = document.createElement("span");
4472
- r.textContent = i.getState().messages.card.compact.button, this.element.append(this.icon.render(), r), i.subscribe(({ messages: s }) => {
4473
- r.textContent = s.card.compact.button;
4478
+ r.textContent = i.getState().messages.card.compact.button, this.element.append(this.icon.render(), r), i.subscribe(({ messages: a }) => {
4479
+ r.textContent = a.card.compact.button;
4474
4480
  });
4475
4481
  }
4476
4482
  addEventListener(e) {
@@ -4509,7 +4515,7 @@ class ic {
4509
4515
  }
4510
4516
  // init
4511
4517
  init(e) {
4512
- return E(this, null, function* () {
4518
+ return k(this, null, function* () {
4513
4519
  var i;
4514
4520
  if (!this.config) return !1;
4515
4521
  const t = this.config.state.transaction.getState();
@@ -4529,7 +4535,7 @@ class ic {
4529
4535
  }
4530
4536
  // display venmo button
4531
4537
  displayVenmoButton(e) {
4532
- Object.assign(this.venmoButton.style, tc), this.venmoButton.addEventListener("click", () => E(this, null, function* () {
4538
+ Object.assign(this.venmoButton.style, tc), this.venmoButton.addEventListener("click", () => k(this, null, function* () {
4533
4539
  if (this.events.onPaymentAttempt.emit(x.VENMO), !this.isProcessing) {
4534
4540
  this.isProcessing = !0, this.venmoButton.disabled = !0;
4535
4541
  try {
@@ -4545,7 +4551,7 @@ class ic {
4545
4551
  }
4546
4552
  // handle existing tokenization results
4547
4553
  handleExistingTokenization(e) {
4548
- return E(this, null, function* () {
4554
+ return k(this, null, function* () {
4549
4555
  try {
4550
4556
  const t = yield this.braintree.tokenize();
4551
4557
  this.handleVenmoSuccess(t, e);
@@ -4561,8 +4567,8 @@ class ic {
4561
4567
  }
4562
4568
  // handle venmo errors
4563
4569
  handleVenmoError(e, t) {
4564
- var i, r, s;
4565
- this.isInitialized && ((i = e == null ? void 0 : e.message) != null && i.toLowerCase().includes("close") ? (r = t == null ? void 0 : t.onCancel) == null || r.call(t) : (s = t == null ? void 0 : t.onError) == null || s.call(t, e));
4570
+ var i, r, a;
4571
+ this.isInitialized && ((i = e == null ? void 0 : e.message) != null && i.toLowerCase().includes("close") ? (r = t == null ? void 0 : t.onCancel) == null || r.call(t) : (a = t == null ? void 0 : t.onError) == null || a.call(t, e));
4566
4572
  }
4567
4573
  // add event listener
4568
4574
  addEventListener(e, t) {
@@ -4595,7 +4601,7 @@ class rc {
4595
4601
  }
4596
4602
  // init
4597
4603
  init() {
4598
- return E(this, null, function* () {
4604
+ return k(this, null, function* () {
4599
4605
  this.config.state.transaction.subscribe(() => {
4600
4606
  this.config.service.ev.isReady && this.initPaymentMethods().catch(console.error);
4601
4607
  }), this.config.state.checkout.subscribe(() => {
@@ -4607,7 +4613,7 @@ class rc {
4607
4613
  }
4608
4614
  // init apple
4609
4615
  initApple(e) {
4610
- return E(this, null, function* () {
4616
+ return k(this, null, function* () {
4611
4617
  if (!this.applePay) {
4612
4618
  e == null || e.remove();
4613
4619
  return;
@@ -4632,8 +4638,8 @@ class rc {
4632
4638
  };
4633
4639
  i.addEventListener("pointerdown", r, { capture: !0 }), i.addEventListener("click", r, { capture: !0 }), i.addEventListener(
4634
4640
  "keydown",
4635
- (s) => {
4636
- ((s == null ? void 0 : s.key) === "Enter" || (s == null ? void 0 : s.key) === " ") && r();
4641
+ (a) => {
4642
+ ((a == null ? void 0 : a.key) === "Enter" || (a == null ? void 0 : a.key) === " ") && r();
4637
4643
  },
4638
4644
  { capture: !0 }
4639
4645
  ), i.addEventListener("focusin", r, { capture: !0 }), e == null || e.addEventListener("pointerdown", r, { capture: !0 }), e == null || e.addEventListener("click", r, { capture: !0 }), e == null || e.addEventListener("focusin", r, { capture: !0 });
@@ -4646,7 +4652,7 @@ class rc {
4646
4652
  }
4647
4653
  // init google
4648
4654
  initGoogle(e) {
4649
- return E(this, null, function* () {
4655
+ return k(this, null, function* () {
4650
4656
  if (!this.googlePay) {
4651
4657
  e == null || e.remove();
4652
4658
  return;
@@ -4671,8 +4677,8 @@ class rc {
4671
4677
  };
4672
4678
  i.addEventListener("pointerdown", r, { capture: !0 }), i.addEventListener("click", r, { capture: !0 }), i.addEventListener(
4673
4679
  "keydown",
4674
- (s) => {
4675
- ((s == null ? void 0 : s.key) === "Enter" || (s == null ? void 0 : s.key) === " ") && r();
4680
+ (a) => {
4681
+ ((a == null ? void 0 : a.key) === "Enter" || (a == null ? void 0 : a.key) === " ") && r();
4676
4682
  },
4677
4683
  { capture: !0 }
4678
4684
  ), i.addEventListener("focusin", r, { capture: !0 }), e == null || e.addEventListener("pointerdown", r, { capture: !0 }), e == null || e.addEventListener("click", r, { capture: !0 }), e == null || e.addEventListener("focusin", r, { capture: !0 });
@@ -4685,7 +4691,7 @@ class rc {
4685
4691
  }
4686
4692
  // init paypal
4687
4693
  initPayPal(e) {
4688
- return E(this, null, function* () {
4694
+ return k(this, null, function* () {
4689
4695
  if (!this.paypal) {
4690
4696
  e == null || e.remove();
4691
4697
  return;
@@ -4711,7 +4717,7 @@ class rc {
4711
4717
  }
4712
4718
  // init braintree
4713
4719
  initBraintreeVenmo(e) {
4714
- return E(this, null, function* () {
4720
+ return k(this, null, function* () {
4715
4721
  if (!this.braintree) {
4716
4722
  e == null || e.remove();
4717
4723
  return;
@@ -4738,7 +4744,7 @@ class rc {
4738
4744
  }
4739
4745
  // init card
4740
4746
  initCard(e) {
4741
- return E(this, null, function* () {
4747
+ return k(this, null, function* () {
4742
4748
  if (!this.card) {
4743
4749
  e == null || e.remove();
4744
4750
  return;
@@ -4748,20 +4754,20 @@ class rc {
4748
4754
  }
4749
4755
  // init payment methods
4750
4756
  initPaymentMethods() {
4751
- return E(this, null, function* () {
4752
- const e = this.config.state.transaction.getState(), t = Jl(zl, (e == null ? void 0 : e.checkout_config) || [], (a, o) => a.type === o.type), i = this.config.state.checkout.getState();
4753
- let r = t.filter(({ is_active: a }) => a);
4754
- (i == null ? void 0 : i.variant) === "default" && (r = r.filter(({ type: a }) => a !== x.CARD));
4755
- const s = this.initializeButtonInstances(r);
4756
- Promise.all(s).then(() => {
4757
+ return k(this, null, function* () {
4758
+ const e = this.config.state.transaction.getState(), t = Jl(zl, (e == null ? void 0 : e.checkout_config) || [], (s, o) => s.type === o.type), i = this.config.state.checkout.getState();
4759
+ let r = t.filter(({ is_active: s }) => s);
4760
+ (i == null ? void 0 : i.variant) === "default" && (r = r.filter(({ type: s }) => s !== x.CARD));
4761
+ const a = this.initializeButtonInstances(r);
4762
+ Promise.all(a).then(() => {
4757
4763
  this.handleOnFormLoaded();
4758
4764
  }), this.handleReady();
4759
4765
  });
4760
4766
  }
4761
4767
  // initialize button instances
4762
4768
  initializeButtonInstances(e) {
4763
- const t = e.map(({ type: h }) => h), i = t.includes(x.APPLE_PAY), r = t.includes(x.GOOGLE_PAY), s = t.includes(x.PAYPAL), a = t.includes(x.VENMO), o = t.includes(x.CARD);
4764
- i && !this.applePay && (this.applePay = new Bl(this.config)), r && !this.googlePay && (this.googlePay = new ql(this.config)), s && !this.paypal && (this.paypal = new Yl(this.config), this.paypal.addEventListener("onPaymentAttempt", (h) => this.events.onPaymentAttempt.emit(h))), a && !this.braintree && (this.braintree = new ic(this.config), this.braintree.addEventListener("onPaymentAttempt", (h) => this.events.onPaymentAttempt.emit(h))), o && !this.card && (this.card = new Zl(this.config), this.card.addEventListener(() => {
4769
+ const t = e.map(({ type: h }) => h), i = t.includes(x.APPLE_PAY), r = t.includes(x.GOOGLE_PAY), a = t.includes(x.PAYPAL), s = t.includes(x.VENMO), o = t.includes(x.CARD);
4770
+ i && !this.applePay && (this.applePay = new Bl(this.config)), r && !this.googlePay && (this.googlePay = new ql(this.config)), a && !this.paypal && (this.paypal = new Yl(this.config), this.paypal.addEventListener("onPaymentAttempt", (h) => this.events.onPaymentAttempt.emit(h))), s && !this.braintree && (this.braintree = new ic(this.config), this.braintree.addEventListener("onPaymentAttempt", (h) => this.events.onPaymentAttempt.emit(h))), o && !this.card && (this.card = new Zl(this.config), this.card.addEventListener(() => {
4765
4771
  this.events.open.emit();
4766
4772
  }));
4767
4773
  const l = e.sort((h, m) => h.order - m.order), u = /* @__PURE__ */ new Map();
@@ -4805,7 +4811,7 @@ class rc {
4805
4811
  return this.buttons;
4806
4812
  }
4807
4813
  }
4808
- class sc {
4814
+ class ac {
4809
4815
  constructor(e) {
4810
4816
  c(this, "template", `
4811
4817
  <svg
@@ -4831,14 +4837,14 @@ class sc {
4831
4837
  return this.element;
4832
4838
  }
4833
4839
  }
4834
- const ac = "_button_125my_1", oc = {
4835
- button: ac
4840
+ const sc = "_button_125my_1", oc = {
4841
+ button: sc
4836
4842
  };
4837
4843
  class lc {
4838
4844
  constructor(e) {
4839
4845
  c(this, "element");
4840
4846
  c(this, "icon");
4841
- this.element = document.createElement("div"), this.element.classList.add(oc.button), this.icon = new sc(e), this.element.appendChild(this.icon.render());
4847
+ this.element = document.createElement("div"), this.element.classList.add(oc.button), this.icon = new ac(e), this.element.appendChild(this.icon.render());
4842
4848
  }
4843
4849
  addEventListener(e) {
4844
4850
  return this.element.addEventListener("click", e);
@@ -4928,9 +4934,9 @@ class Ac {
4928
4934
  c(this, "events", {
4929
4935
  change: new K()
4930
4936
  });
4931
- var r, s, a, o, l, u, d, h, m;
4937
+ var r, a, s, o, l, u, d, h, m;
4932
4938
  const i = e.messages();
4933
- if (this.element = document.createElement("div"), this.element.classList.add($.wrapper), this.inputContainer.classList.add($.inputContainer), (r = t == null ? void 0 : t.container) != null && r.className && F(this.inputContainer, t.container.className), (s = t == null ? void 0 : t.container) != null && s.styles && Object.assign(this.inputContainer.style, t.container.styles), this.input.setAttribute("id", this.id), this.input.setAttribute("autocomplete", "cc-name"), this.input.setAttribute("placeholder", i.card.name.placeholder), this.input.classList.add($.input), (a = t == null ? void 0 : t.field) != null && a.className && F(this.input, t.field.className), (o = t == null ? void 0 : t.field) != null && o.styles && Object.assign(this.input.style, t.field.styles), (l = t == null ? void 0 : t.placeholder) != null && l.styles && Object.keys(t.placeholder.styles).length) {
4939
+ if (this.element = document.createElement("div"), this.element.classList.add($.wrapper), this.inputContainer.classList.add($.inputContainer), (r = t == null ? void 0 : t.container) != null && r.className && F(this.inputContainer, t.container.className), (a = t == null ? void 0 : t.container) != null && a.styles && Object.assign(this.inputContainer.style, t.container.styles), this.input.setAttribute("id", this.id), this.input.setAttribute("autocomplete", "cc-name"), this.input.setAttribute("placeholder", i.card.name.placeholder), this.input.classList.add($.input), (s = t == null ? void 0 : t.field) != null && s.className && F(this.input, t.field.className), (o = t == null ? void 0 : t.field) != null && o.styles && Object.assign(this.input.style, t.field.styles), (l = t == null ? void 0 : t.placeholder) != null && l.styles && Object.keys(t.placeholder.styles).length) {
4934
4940
  const p = (b) => b.replace(/[A-Z]/g, (y) => "-" + y.toLowerCase()), g = Object.entries(t.placeholder.styles).map(([b, y]) => `${p(b)}:${y};`).join("");
4935
4941
  this.placeholderStyle.textContent = `#${this.id}::placeholder{${g}}`, this.element.appendChild(this.placeholderStyle);
4936
4942
  }
@@ -4953,7 +4959,7 @@ class Ac {
4953
4959
  }), this.render();
4954
4960
  }
4955
4961
  toggleLabelError(e) {
4956
- return E(this, null, function* () {
4962
+ return k(this, null, function* () {
4957
4963
  if (e) {
4958
4964
  this.inputContainer.classList.add($.errorInput), this.endContent.classList.remove($.hidden), this.labelError.classList.remove($.hidden), yield H(this.labelError, W.open, W.transition);
4959
4965
  return;
@@ -5133,11 +5139,11 @@ class zc {
5133
5139
  c(this, "events", {
5134
5140
  change: new K()
5135
5141
  });
5136
- var r, s, a, o, l, u, d, h, m;
5142
+ var r, a, s, o, l, u, d, h, m;
5137
5143
  this.translate = e;
5138
5144
  const i = e.messages();
5139
- if (this.element = document.createElement("div"), this.element.classList.add(j.wrapper), this.inputContainer.classList.add(j.inputContainer), (r = t == null ? void 0 : t.container) != null && r.className && F(this.inputContainer, t.container.className), (s = t == null ? void 0 : t.container) != null && s.styles && Object.assign(this.inputContainer.style, t.container.styles), this.input.setAttribute("id", this.id), this.input.setAttribute("autocomplete", "cc-number"), this.input.setAttribute("placeholder", "1234 1234 1234 1234"), this.input.setAttribute("inputmode", "numeric"), this.input.setAttribute("pattern", "[0-9]*"), this.input.setAttribute("enterkeyhint", "done"), this.input.classList.add(j.input), (a = t == null ? void 0 : t.field) != null && a.className && F(this.input, t.field.className), (o = t == null ? void 0 : t.field) != null && o.styles && Object.assign(this.input.style, t.field.styles), (l = t == null ? void 0 : t.placeholder) != null && l.styles && Object.keys(t.placeholder.styles).length) {
5140
- const p = (y) => y.replace(/[A-Z]/g, (k) => "-" + k.toLowerCase()), g = Object.entries(t.placeholder.styles).map(([y, k]) => `${p(y)}:${k} !important;`).join(""), b = `#${this.id}`;
5145
+ if (this.element = document.createElement("div"), this.element.classList.add(j.wrapper), this.inputContainer.classList.add(j.inputContainer), (r = t == null ? void 0 : t.container) != null && r.className && F(this.inputContainer, t.container.className), (a = t == null ? void 0 : t.container) != null && a.styles && Object.assign(this.inputContainer.style, t.container.styles), this.input.setAttribute("id", this.id), this.input.setAttribute("autocomplete", "cc-number"), this.input.setAttribute("placeholder", "1234 1234 1234 1234"), this.input.setAttribute("inputmode", "numeric"), this.input.setAttribute("pattern", "[0-9]*"), this.input.setAttribute("enterkeyhint", "done"), this.input.classList.add(j.input), (s = t == null ? void 0 : t.field) != null && s.className && F(this.input, t.field.className), (o = t == null ? void 0 : t.field) != null && o.styles && Object.assign(this.input.style, t.field.styles), (l = t == null ? void 0 : t.placeholder) != null && l.styles && Object.keys(t.placeholder.styles).length) {
5146
+ const p = (y) => y.replace(/[A-Z]/g, (E) => "-" + E.toLowerCase()), g = Object.entries(t.placeholder.styles).map(([y, E]) => `${p(y)}:${E} !important;`).join(""), b = `#${this.id}`;
5141
5147
  this.placeholderStyle.textContent = `${b}::placeholder{${g}}
5142
5148
  ${b}::-webkit-input-placeholder{${g}}
5143
5149
  ${b}::-moz-placeholder{${g}}
@@ -5163,16 +5169,16 @@ ${b}::-ms-input-placeholder{${g}}
5163
5169
  handleChange(e) {
5164
5170
  if (this.isDisabled) return;
5165
5171
  this.isRequired = !1, this.errorMessage = "", this.isChanged || (this.isChanged = !0);
5166
- const t = ri(e).map((s) => s.type), i = Cr(e), r = Cl(e, (i == null ? void 0 : i.type) || "");
5172
+ const t = ri(e).map((a) => a.type), i = Cr(e), r = Cl(e, (i == null ? void 0 : i.type) || "");
5167
5173
  this.supportedCardTypes = t.length ? t : this.initialCardTypes, r.replace(/\D/g, "").length === ((i == null ? void 0 : i.maxLength) || 16) && this.validate(r), this.input.value = r, this.events.change.emit({
5168
5174
  card: r,
5169
5175
  cardType: i == null ? void 0 : i.type,
5170
5176
  cardTypes: t,
5171
- isValid: si(e, this.supportedCardTypes).isValid
5177
+ isValid: ai(e, this.supportedCardTypes).isValid
5172
5178
  }), this.render();
5173
5179
  }
5174
5180
  toggleLabelError(e) {
5175
- return E(this, null, function* () {
5181
+ return k(this, null, function* () {
5176
5182
  if (e) {
5177
5183
  this.inputContainer.classList.add(j.errorInput), this.labelError.classList.remove(j.hidden), yield H(this.labelError, W.open, W.transition);
5178
5184
  return;
@@ -5181,7 +5187,7 @@ ${b}::-ms-input-placeholder{${g}}
5181
5187
  });
5182
5188
  }
5183
5189
  toggleErrorMessage(e) {
5184
- return E(this, null, function* () {
5190
+ return k(this, null, function* () {
5185
5191
  if (e) {
5186
5192
  this.inputContainer.classList.add(j.errorInput), this.error.textContent = this.errorMessage, this.error.classList.remove(j.hidden), yield H(this.error, Q.open, Q.transition);
5187
5193
  return;
@@ -5217,7 +5223,7 @@ ${b}::-ms-input-placeholder{${g}}
5217
5223
  };
5218
5224
  }
5219
5225
  validate(e) {
5220
- const t = this.translate.messages(), { isValid: i, error: r } = si(e, this.supportedCardTypes);
5226
+ const t = this.translate.messages(), { isValid: i, error: r } = ai(e, this.supportedCardTypes);
5221
5227
  return i ? (this.isRequired = !1, this.errorMessage = "", this.render(), i) : (r === Y.Empty ? (this.errorMessage = "", this.isRequired = !0) : r === Y.Unsupported ? (this.errorMessage = t.card.number.error.unsupported, this.isRequired = !1) : (this.errorMessage = r === Y.Incomplete ? t.card.number.error.incomplete : t.card.number.error.invalid, this.isRequired = !1), this.render(), i);
5222
5228
  }
5223
5229
  render() {
@@ -5303,24 +5309,24 @@ class ed {
5303
5309
  expiryChange: new K(),
5304
5310
  cvcChange: new K()
5305
5311
  });
5306
- var a, o, l, u, d, h, m, p, g, b, y, k, V, _, M, T, D;
5312
+ var s, o, l, u, d, h, m, p, g, b, y, E, V, _, M, T, D;
5307
5313
  this.translate = e;
5308
5314
  const i = e.messages();
5309
- this.element = document.createElement("div"), this.element.classList.add(A.securityContent), this.expiryInputContainer.classList.add(A.inputContainer), (a = t == null ? void 0 : t.container) != null && a.className && F(this.expiryInputContainer, t.container.className), (o = t == null ? void 0 : t.container) != null && o.styles && Object.assign(this.expiryInputContainer.style, t.container.styles), this.expiryInput.setAttribute("id", this.expiryId), this.expiryInput.setAttribute("autocomplete", "cc-exp"), this.expiryInput.setAttribute("placeholder", i.card.expiry.placeholder), this.expiryInput.setAttribute("inputmode", "numeric"), this.expiryInput.setAttribute("pattern", "[0-9]*"), this.expiryInput.setAttribute("enterkeyhint", "next"), this.expiryInput.classList.add(A.input), (l = t == null ? void 0 : t.field) != null && l.className && F(this.expiryInput, t.field.className), (u = t == null ? void 0 : t.field) != null && u.styles && Object.assign(this.expiryInput.style, t.field.styles), this.expiryEndContent.classList.add(A.endContent), this.expiryEndContent.appendChild(this.expiryWarning.render()), this.expiryInputContainer.append(this.expiryInput, this.expiryEndContent), this.expiryLabel.setAttribute("for", this.expiryId), this.expiryLabel.classList.add(A.label), (d = t == null ? void 0 : t.label) != null && d.className && F(this.expiryLabel, t.label.className), (h = t == null ? void 0 : t.label) != null && h.styles && Object.assign(this.expiryLabel.style, t.label.styles), this.expiryLabelText.contentEditable = "false", this.expiryLabelText.textContent = i.card.expiry.label, this.expiryLabelError.textContent = i.card.required, this.expiryLabelError.classList.add(A.labelError, A.hidden), this.expiryLabel.append(this.expiryLabelText, this.expiryLabelError), this.expiryError.classList.add(A.error, A.hidden), (m = t == null ? void 0 : t.error) != null && m.className && F(this.expiryError, t.error.className), (p = t == null ? void 0 : t.error) != null && p.styles && Object.assign(this.expiryError.style, t.error.styles);
5315
+ this.element = document.createElement("div"), this.element.classList.add(A.securityContent), this.expiryInputContainer.classList.add(A.inputContainer), (s = t == null ? void 0 : t.container) != null && s.className && F(this.expiryInputContainer, t.container.className), (o = t == null ? void 0 : t.container) != null && o.styles && Object.assign(this.expiryInputContainer.style, t.container.styles), this.expiryInput.setAttribute("id", this.expiryId), this.expiryInput.setAttribute("autocomplete", "cc-exp"), this.expiryInput.setAttribute("placeholder", i.card.expiry.placeholder), this.expiryInput.setAttribute("inputmode", "numeric"), this.expiryInput.setAttribute("pattern", "[0-9]*"), this.expiryInput.setAttribute("enterkeyhint", "next"), this.expiryInput.classList.add(A.input), (l = t == null ? void 0 : t.field) != null && l.className && F(this.expiryInput, t.field.className), (u = t == null ? void 0 : t.field) != null && u.styles && Object.assign(this.expiryInput.style, t.field.styles), this.expiryEndContent.classList.add(A.endContent), this.expiryEndContent.appendChild(this.expiryWarning.render()), this.expiryInputContainer.append(this.expiryInput, this.expiryEndContent), this.expiryLabel.setAttribute("for", this.expiryId), this.expiryLabel.classList.add(A.label), (d = t == null ? void 0 : t.label) != null && d.className && F(this.expiryLabel, t.label.className), (h = t == null ? void 0 : t.label) != null && h.styles && Object.assign(this.expiryLabel.style, t.label.styles), this.expiryLabelText.contentEditable = "false", this.expiryLabelText.textContent = i.card.expiry.label, this.expiryLabelError.textContent = i.card.required, this.expiryLabelError.classList.add(A.labelError, A.hidden), this.expiryLabel.append(this.expiryLabelText, this.expiryLabelError), this.expiryError.classList.add(A.error, A.hidden), (m = t == null ? void 0 : t.error) != null && m.className && F(this.expiryError, t.error.className), (p = t == null ? void 0 : t.error) != null && p.styles && Object.assign(this.expiryError.style, t.error.styles);
5310
5316
  const r = document.createElement("div");
5311
- if (r.appendChild(this.expiryError), this.cvcInputContainer.classList.add(A.inputContainer), (g = t == null ? void 0 : t.container) != null && g.className && F(this.cvcInputContainer, t.container.className), (b = t == null ? void 0 : t.container) != null && b.styles && Object.assign(this.cvcInputContainer.style, t.container.styles), this.cvcInput.setAttribute("id", this.cvcId), this.cvcInput.setAttribute("autocomplete", "cc-csc"), this.cvcInput.setAttribute("placeholder", i.card.cvc.placeholder), this.cvcInput.setAttribute("inputmode", "numeric"), this.cvcInput.setAttribute("pattern", "[0-9]*"), this.cvcInput.setAttribute("enterkeyhint", "done"), this.cvcInput.classList.add(A.input), (y = t == null ? void 0 : t.field) != null && y.className && F(this.cvcInput, t.field.className), (k = t == null ? void 0 : t.field) != null && k.styles && Object.assign(this.cvcInput.style, t.field.styles), (V = t == null ? void 0 : t.placeholder) != null && V.styles && Object.keys(t.placeholder.styles).length) {
5317
+ if (r.appendChild(this.expiryError), this.cvcInputContainer.classList.add(A.inputContainer), (g = t == null ? void 0 : t.container) != null && g.className && F(this.cvcInputContainer, t.container.className), (b = t == null ? void 0 : t.container) != null && b.styles && Object.assign(this.cvcInputContainer.style, t.container.styles), this.cvcInput.setAttribute("id", this.cvcId), this.cvcInput.setAttribute("autocomplete", "cc-csc"), this.cvcInput.setAttribute("placeholder", i.card.cvc.placeholder), this.cvcInput.setAttribute("inputmode", "numeric"), this.cvcInput.setAttribute("pattern", "[0-9]*"), this.cvcInput.setAttribute("enterkeyhint", "done"), this.cvcInput.classList.add(A.input), (y = t == null ? void 0 : t.field) != null && y.className && F(this.cvcInput, t.field.className), (E = t == null ? void 0 : t.field) != null && E.styles && Object.assign(this.cvcInput.style, t.field.styles), (V = t == null ? void 0 : t.placeholder) != null && V.styles && Object.keys(t.placeholder.styles).length) {
5312
5318
  const C = (R) => R.replace(/[A-Z]/g, (O) => "-" + O.toLowerCase()), w = Object.entries(t.placeholder.styles).map(([R, O]) => `${C(R)}:${O};`).join("");
5313
5319
  this.placeholderStyle.textContent = `#${this.expiryId}::placeholder{${w}}#${this.cvcId}::placeholder{${w}}`, this.element.appendChild(this.placeholderStyle);
5314
5320
  }
5315
5321
  this.cvcEndContent.classList.add(A.endContent), this.cvcEndContent.appendChild(this.cardCvc.render()), this.cvcInputContainer.append(this.cvcInput, this.cvcEndContent), this.cvcLabel.setAttribute("for", this.cvcId), this.cvcLabel.classList.add(A.label), (_ = t == null ? void 0 : t.label) != null && _.className && F(this.cvcLabel, t.label.className), (M = t == null ? void 0 : t.label) != null && M.styles && Object.assign(this.cvcLabel.style, t.label.styles), this.cvcLabelText.textContent = i.card.cvc.label, this.cvcLabelError.textContent = i.card.required, this.cvcLabelError.classList.add(A.labelError, A.hidden), (T = t == null ? void 0 : t.error) != null && T.className && F(this.cvcLabel, t.error.className), (D = t == null ? void 0 : t.error) != null && D.styles && Object.assign(this.cvcLabelError.style, t.error.styles), this.cvcLabel.append(this.cvcLabelText, this.cvcLabelError), this.cvcError.classList.add(A.error, A.hidden);
5316
- const s = document.createElement("div");
5317
- s.appendChild(this.cvcError), this.element.append(
5322
+ const a = document.createElement("div");
5323
+ a.appendChild(this.cvcError), this.element.append(
5318
5324
  this.expiryLabel,
5319
5325
  this.cvcLabel,
5320
5326
  this.expiryInputContainer,
5321
5327
  this.cvcInputContainer,
5322
5328
  r,
5323
- s
5329
+ a
5324
5330
  ), this.expiryInput.addEventListener("input", (C) => {
5325
5331
  C.preventDefault();
5326
5332
  const R = this.expiryInput.value.replace(/\D/g, "");
@@ -5365,7 +5371,7 @@ class ed {
5365
5371
  }), this.cvcInput.value = t, this.render();
5366
5372
  }
5367
5373
  toggleCvcLabelError(e) {
5368
- return E(this, null, function* () {
5374
+ return k(this, null, function* () {
5369
5375
  if (e) {
5370
5376
  this.cvcInputContainer.classList.add(A.errorInput), this.cvcLabelError.classList.remove(A.hidden), yield H(this.cvcLabelError, W.open, W.transition);
5371
5377
  return;
@@ -5374,7 +5380,7 @@ class ed {
5374
5380
  });
5375
5381
  }
5376
5382
  toggleCvcErrorMessage(e) {
5377
- return E(this, null, function* () {
5383
+ return k(this, null, function* () {
5378
5384
  if (e) {
5379
5385
  this.cvcInputContainer.classList.add(A.errorInput), this.cvcError.textContent = this.cvcErrorMessage, this.cvcError.classList.remove(A.hidden), yield H(this.cvcError, Q.open, Q.transition);
5380
5386
  return;
@@ -5383,8 +5389,8 @@ class ed {
5383
5389
  });
5384
5390
  }
5385
5391
  expiryValidator(e) {
5386
- const t = !e, i = e.length < 7, r = /* @__PURE__ */ new Date(), [s, a] = e.split(" / ");
5387
- r.setFullYear(2e3 + parseInt(a), parseInt(s) - 1, 31);
5392
+ const t = !e, i = e.length < 7, r = /* @__PURE__ */ new Date(), [a, s] = e.split(" / ");
5393
+ r.setFullYear(2e3 + parseInt(s), parseInt(a) - 1, 31);
5388
5394
  const o = r.getTime() < Date.now(), l = /* @__PURE__ */ new Date(), u = /* @__PURE__ */ new Date();
5389
5395
  u.setFullYear(l.getFullYear() + 50);
5390
5396
  const d = r.getTime() > u.getTime() || r.getFullYear() < l.getFullYear();
@@ -5416,7 +5422,7 @@ class ed {
5416
5422
  }
5417
5423
  // toggle expiry label error
5418
5424
  toggleExpiryLabelError(e) {
5419
- return E(this, null, function* () {
5425
+ return k(this, null, function* () {
5420
5426
  if (e) {
5421
5427
  this.expiryInputContainer.classList.add(A.errorInput), this.expiryLabelError.classList.remove(A.hidden), yield H(this.expiryLabelError, W.open, W.transition);
5422
5428
  return;
@@ -5426,7 +5432,7 @@ class ed {
5426
5432
  }
5427
5433
  // toggle expiry error message
5428
5434
  toggleExpiryErrorMessage(e) {
5429
- return E(this, null, function* () {
5435
+ return k(this, null, function* () {
5430
5436
  if (e) {
5431
5437
  this.expiryInputContainer.classList.add(A.errorInput), this.expiryError.textContent = this.expiryErrorMessage, this.expiryError.classList.remove(A.hidden), yield H(this.expiryError, Q.open, Q.transition);
5432
5438
  return;
@@ -5466,12 +5472,12 @@ class ed {
5466
5472
  render() {
5467
5473
  const e = this.isTouchSubmit || this.isExpiryChanged, t = e && !this.isDisabled && this.isExpiryRequired, i = e && !this.isDisabled && !!this.expiryErrorMessage;
5468
5474
  this.toggleExpiryLabelError(t), this.toggleExpiryErrorMessage(i), !t && !i ? (this.expiryInputContainer.classList.remove(A.errorInput), this.expiryEndContent.classList.add(A.hidden)) : this.expiryEndContent.classList.remove(A.hidden);
5469
- const r = this.isTouchSubmit || this.isCvcChanged, s = r && !this.isDisabled && this.isCvcRequired, a = r && !this.isDisabled && !!this.cvcErrorMessage;
5470
- return this.toggleCvcLabelError(s), this.toggleCvcErrorMessage(a), !s && !a ? (this.cvcInputContainer.classList.remove(A.errorInput), this.cvcEndContent.innerHTML = "", this.cvcEndContent.appendChild(this.cardCvc.render())) : (this.cvcEndContent.innerHTML = "", this.cvcEndContent.appendChild(this.cvcWarning.render())), this.isDisabled ? (this.expiryInputContainer.classList.add(A.disabled), this.expiryInput.classList.add(A.disabledInput), this.cvcInputContainer.classList.add(A.disabled), this.cvcInput.classList.add(A.disabledInput)) : (this.expiryInputContainer.classList.remove(A.disabled), this.expiryInput.classList.remove(A.disabledInput), this.cvcInputContainer.classList.remove(A.disabled), this.cvcInput.classList.remove(A.disabledInput)), this.element;
5475
+ const r = this.isTouchSubmit || this.isCvcChanged, a = r && !this.isDisabled && this.isCvcRequired, s = r && !this.isDisabled && !!this.cvcErrorMessage;
5476
+ return this.toggleCvcLabelError(a), this.toggleCvcErrorMessage(s), !a && !s ? (this.cvcInputContainer.classList.remove(A.errorInput), this.cvcEndContent.innerHTML = "", this.cvcEndContent.appendChild(this.cardCvc.render())) : (this.cvcEndContent.innerHTML = "", this.cvcEndContent.appendChild(this.cvcWarning.render())), this.isDisabled ? (this.expiryInputContainer.classList.add(A.disabled), this.expiryInput.classList.add(A.disabledInput), this.cvcInputContainer.classList.add(A.disabled), this.cvcInput.classList.add(A.disabledInput)) : (this.expiryInputContainer.classList.remove(A.disabled), this.expiryInput.classList.remove(A.disabledInput), this.cvcInputContainer.classList.remove(A.disabled), this.cvcInput.classList.remove(A.disabledInput)), this.element;
5471
5477
  }
5472
5478
  }
5473
5479
  class td {
5474
- constructor({ translate: e, className: t, stylesState: i, isDefaultVariant: r, onPaymentAttempt: s }) {
5480
+ constructor({ translate: e, className: t, stylesState: i, isDefaultVariant: r, onPaymentAttempt: a }) {
5475
5481
  c(this, "element");
5476
5482
  c(this, "submit");
5477
5483
  c(this, "back");
@@ -5484,8 +5490,8 @@ class td {
5484
5490
  submit: new K(),
5485
5491
  close: new K()
5486
5492
  });
5487
- const a = i.getState();
5488
- this.element = document.createElement("form"), this.onPaymentAttempt = s, this.submit = new pc(e, a.SubmitButton), this.back = new lc(a.BackButton), this.number = new zc(e, a.Input), this.name = new Ac(e, a.Input), this.cardSecurity = new ed(e, a.Input), this.element.classList.add(ve.cardForm), t && F(this.element, t);
5493
+ const s = i.getState();
5494
+ this.element = document.createElement("form"), this.onPaymentAttempt = a, this.submit = new pc(e, s.SubmitButton), this.back = new lc(s.BackButton), this.number = new zc(e, s.Input), this.name = new Ac(e, s.Input), this.cardSecurity = new ed(e, s.Input), this.element.classList.add(ve.cardForm), t && F(this.element, t);
5489
5495
  const o = this.back.render();
5490
5496
  r && (this.isBackVisible = !1, o.classList.add(ve.hidden), this.element.classList.add(ve.topOffset)), this.element.append(
5491
5497
  o,
@@ -5567,7 +5573,7 @@ const id = "_container_79xkl_1", rd = "_title_79xkl_5", di = {
5567
5573
  container: id,
5568
5574
  title: rd
5569
5575
  };
5570
- class sd {
5576
+ class ad {
5571
5577
  constructor() {
5572
5578
  c(this, "element");
5573
5579
  c(this, "message", document.createElement("p"));
@@ -5584,8 +5590,8 @@ class sd {
5584
5590
  return this.element;
5585
5591
  }
5586
5592
  }
5587
- const ad = "_container_g3abj_1", od = "_title_g3abj_12", ui = {
5588
- container: ad,
5593
+ const sd = "_container_g3abj_1", od = "_title_g3abj_12", ui = {
5594
+ container: sd,
5589
5595
  title: od
5590
5596
  }, Ze = class Ze {
5591
5597
  constructor(e, t) {
@@ -5654,11 +5660,11 @@ class ld {
5654
5660
  var i, r;
5655
5661
  return (r = (i = this.config.state.checkout.getState()).onCheckoutAttempt) == null ? void 0 : r.call(i, t);
5656
5662
  }
5657
- }), this.success = new sd(), this.success.addClassName(Z.hidden), this.error = new Wt(e.state.translate, e.state.checkout.getState().errorMessageText), this.error.hide(), this.container.append(this.loader.render(), this.buttons.render(), this.form.render()), this.checkout = document.createElement("div"), this.checkout.classList.add(Z.checkout), this.checkout.append(this.container, this.error.render(), this.success.render());
5663
+ }), this.success = new ad(), this.success.addClassName(Z.hidden), this.error = new Wt(e.state.translate, e.state.checkout.getState().errorMessageText), this.error.hide(), this.container.append(this.loader.render(), this.buttons.render(), this.form.render()), this.checkout = document.createElement("div"), this.checkout.classList.add(Z.checkout), this.checkout.append(this.container, this.error.render(), this.success.render());
5658
5664
  }
5659
5665
  // init
5660
5666
  init() {
5661
- return E(this, null, function* () {
5667
+ return k(this, null, function* () {
5662
5668
  this.buttons.addEventListener("onPaymentAttempt", (e) => {
5663
5669
  var i;
5664
5670
  const t = this.config.state.checkout.getState();
@@ -5666,7 +5672,7 @@ class ld {
5666
5672
  }), this.buttons.addEventListener("onFormLoaded", () => {
5667
5673
  const { onCheckoutLoaded: e } = this.config.state.checkout.getState();
5668
5674
  !this.hasLoadedOnce && e && (this.hasLoadedOnce = !0, e({ success: !0 }));
5669
- }), this.buttons.addEventListener("ready", () => E(this, null, function* () {
5675
+ }), this.buttons.addEventListener("ready", () => k(this, null, function* () {
5670
5676
  var t;
5671
5677
  this.loader.setClassName(Z.hidden);
5672
5678
  const { variant: e } = this.config.state.checkout.getState();
@@ -5677,7 +5683,7 @@ class ld {
5677
5683
  { duration: 250, easing: "ease-out", fill: "forwards" }
5678
5684
  ).finished) != null ? t : Promise.resolve(), this.checkout.style.height = ""), this.isFormOpen = !0;
5679
5685
  }
5680
- })), this.buttons.addEventListener("open", () => E(this, null, function* () {
5686
+ })), this.buttons.addEventListener("open", () => k(this, null, function* () {
5681
5687
  var r;
5682
5688
  if (this.isLoading) return;
5683
5689
  this.hideError();
@@ -5693,9 +5699,9 @@ class ld {
5693
5699
  i != null ? i : Promise.resolve()
5694
5700
  ]), t < this.FORM_HEIGHT && (this.checkout.style.height = ""), this.isFormOpen = !0;
5695
5701
  })), this.buttons.addEventListener("error", (e) => {
5696
- const { onCheckoutFail: t, onCheckoutLoaded: i } = this.config.state.checkout.getState(), r = this.config.state.translate.messages(), s = vt(e, r);
5697
- this.showError(s);
5698
- const a = {
5702
+ const { onCheckoutFail: t, onCheckoutLoaded: i } = this.config.state.checkout.getState(), r = this.config.state.translate.messages(), a = vt(e, r);
5703
+ this.showError(a);
5704
+ const s = {
5699
5705
  status: "failed",
5700
5706
  status_reason: {
5701
5707
  advice_code: "try_again_later",
@@ -5703,7 +5709,7 @@ class ld {
5703
5709
  message: e.message || e
5704
5710
  }
5705
5711
  };
5706
- !this.hasLoadedOnce && i && (this.hasLoadedOnce = !0, i({ success: !1, error: a })), t == null || t(a);
5712
+ !this.hasLoadedOnce && i && (this.hasLoadedOnce = !0, i({ success: !1, error: s })), t == null || t(s);
5707
5713
  }), this.buttons.addEventListener("success", (e) => {
5708
5714
  const { clientToken: t } = this.config.state.checkout.getState();
5709
5715
  switch (e.type) {
@@ -5719,29 +5725,29 @@ class ld {
5719
5725
  case "venmo":
5720
5726
  return this.handleSuccess({ clientSession: t, braintree: { nonce: e } });
5721
5727
  }
5722
- }), this.form.addEventListener("close", () => E(this, null, function* () {
5723
- var s, a;
5728
+ }), this.form.addEventListener("close", () => k(this, null, function* () {
5729
+ var a, s;
5724
5730
  if (this.isLoading) return;
5725
5731
  this.hideError();
5726
5732
  const e = this.checkout.getBoundingClientRect().height;
5727
5733
  let t = null;
5728
- this.closedHeight > 0 && e > this.closedHeight && (this.checkout.style.height = `${e}px`, t = (s = this.checkout.animate(
5734
+ this.closedHeight > 0 && e > this.closedHeight && (this.checkout.style.height = `${e}px`, t = (a = this.checkout.animate(
5729
5735
  { minHeight: [`${e}px`, `${this.closedHeight}px`] },
5730
5736
  { duration: 250, easing: "ease-out", fill: "forwards" }
5731
- ).finished) != null ? s : Promise.resolve()), yield H(this.form.element, Le.close, Le.transition), this.form.element.classList.add(Z.hidden);
5737
+ ).finished) != null ? a : Promise.resolve()), yield H(this.form.element, Le.close, Le.transition), this.form.element.classList.add(Z.hidden);
5732
5738
  const { variant: r } = this.config.state.checkout.getState();
5733
5739
  if (r !== "default") {
5734
5740
  this.buttons.buttons.classList.add(Z.btnsInitial), this.buttons.buttons.classList.remove(Z.hidden);
5735
5741
  const o = H(this.buttons.buttons, ut.open, ut.transition);
5736
5742
  yield Promise.all([o, t != null ? t : Promise.resolve()]);
5737
5743
  }
5738
- this.closedHeight > 0 && (t = (a = this.checkout.animate(
5744
+ this.closedHeight > 0 && (t = (s = this.checkout.animate(
5739
5745
  { minHeight: [`${e}px`, `${this.closedHeight}px`] },
5740
5746
  { duration: 250, easing: "ease-out", fill: "forwards" }
5741
- ).finished) != null ? a : Promise.resolve(), this.checkout.style.height = "auto"), this.isFormOpen = !1;
5742
- })), this.form.addEventListener("submit", (e) => E(this, null, function* () {
5747
+ ).finished) != null ? s : Promise.resolve(), this.checkout.style.height = "auto"), this.isFormOpen = !1;
5748
+ })), this.form.addEventListener("submit", (e) => k(this, null, function* () {
5743
5749
  if (this.isLoading || (this.form.touchSubmit(), this.hideError(), !this.form.validate())) return;
5744
- const i = e.number.replace(/\D/g, ""), r = this.config.state.checkout.getState(), s = this.config.service.ev.getEv(), [a, o] = yield Promise.all([s.encrypt(i), s.encrypt(e.cvc)]), [l, u] = e.expiry.split("/");
5750
+ const i = e.number.replace(/\D/g, ""), r = this.config.state.checkout.getState(), a = this.config.service.ev.getEv(), [s, o] = yield Promise.all([a.encrypt(i), a.encrypt(e.cvc)]), [l, u] = e.expiry.split("/");
5745
5751
  yield this.handleSuccess({
5746
5752
  clientSession: r.clientToken,
5747
5753
  card: {
@@ -5750,7 +5756,7 @@ class ld {
5750
5756
  expMonth: Number(l),
5751
5757
  expYear: Number(u),
5752
5758
  cardBrand: e.cardBrand || "",
5753
- number: a,
5759
+ number: s,
5754
5760
  cvc: o,
5755
5761
  type: x.CARD,
5756
5762
  metadata: {
@@ -5764,21 +5770,21 @@ class ld {
5764
5770
  }
5765
5771
  // handle error
5766
5772
  handleError(e) {
5767
- var s;
5773
+ var a;
5768
5774
  const t = this.config.state.checkout.getState(), i = this.config.state.translate.messages(), r = vt(e, i);
5769
- e && (this.showError(r), (s = t.onCheckoutFail) == null || s.call(t, e)), this.setLoading(!1);
5775
+ e && (this.showError(r), (a = t.onCheckoutFail) == null || a.call(t, e)), this.setLoading(!1);
5770
5776
  }
5771
5777
  // handle success
5772
5778
  handleSuccess(e) {
5773
- return E(this, null, function* () {
5774
- var s, a;
5779
+ return k(this, null, function* () {
5780
+ var a, s;
5775
5781
  if (this.isLoading) return;
5776
5782
  this.hideError(), this.setLoading(!0);
5777
5783
  const t = this.config.state.checkout.getState(), i = this.config.state.translate.messages();
5778
5784
  let r;
5779
5785
  try {
5780
5786
  if (r = yield Dr(e, t.environment, t.apiVersion), r.error)
5781
- throw new Error(((s = r.error) == null ? void 0 : s.message) || i.status.error);
5787
+ throw new Error(((a = r.error) == null ? void 0 : a.message) || i.status.error);
5782
5788
  if (r.three_ds_session_id) {
5783
5789
  yield this.config.service.ev.initThreeDs({
5784
5790
  threeDsId: r.three_ds_session_id,
@@ -5806,12 +5812,12 @@ class ld {
5806
5812
  }
5807
5813
  });
5808
5814
  }
5809
- (a = t.onCheckoutComplete) == null || a.call(t, r);
5815
+ (s = t.onCheckoutComplete) == null || s.call(t, r);
5810
5816
  });
5811
5817
  }
5812
5818
  // show success
5813
5819
  showSuccess() {
5814
- return E(this, null, function* () {
5820
+ return k(this, null, function* () {
5815
5821
  this.container.classList.add(Z.hidden), this.success.removeClassName(Z.hidden), yield H(this.success.element, Le.open, Le.transition);
5816
5822
  });
5817
5823
  }
@@ -5862,13 +5868,13 @@ class cd {
5862
5868
  }
5863
5869
  // init
5864
5870
  init() {
5865
- return E(this, null, function* () {
5866
- const { checkout: e, transaction: t, translate: i, styles: r } = this.config.state, { apiVersion: s } = e.getState();
5867
- e.subscribe(({ clientToken: a, environment: o, locale: l, translate: u, styles: d }) => {
5871
+ return k(this, null, function* () {
5872
+ const { checkout: e, transaction: t, translate: i, styles: r } = this.config.state, { apiVersion: a } = e.getState();
5873
+ e.subscribe(({ clientToken: s, environment: o, locale: l, translate: u, styles: d }) => {
5868
5874
  const h = kn.teamId, m = kn.appIds[o];
5869
- l && i.locale() !== l && i.setLocale(l), u && i.overrides() !== u && i.setMessages(u), d && r.setState(d), t.updateTransaction(a, o, s).then((p) => {
5875
+ this.config.service.ev.preloadEvervault({ teamId: h, appId: m }).finally(), l && i.locale() !== l && i.setLocale(l), u && i.overrides() !== u && i.setMessages(u), d && r.setState(d), t.updateTransaction(s, o, a).then((p) => {
5870
5876
  if (!p)
5871
- throw new Error("No config found");
5877
+ throw new Error("Payment config not found");
5872
5878
  return this.config.service.ev.initEv({ teamId: h, appId: m });
5873
5879
  }).catch((p) => {
5874
5880
  if (console.error(p), this.component) {
@@ -5881,7 +5887,7 @@ class cd {
5881
5887
  }
5882
5888
  // mount
5883
5889
  mount() {
5884
- return E(this, null, function* () {
5890
+ return k(this, null, function* () {
5885
5891
  return this.component || (this.component = new ld(this.config)), yield this.init(), yield this.component.init(), this.component.render();
5886
5892
  });
5887
5893
  }
@@ -5930,16 +5936,16 @@ class md extends Ct {
5930
5936
  }
5931
5937
  // update transaction
5932
5938
  updateTransaction(t, i, r) {
5933
- return E(this, null, function* () {
5939
+ return k(this, null, function* () {
5934
5940
  if (this.clientToken === t) return this.getState();
5935
5941
  this.clientToken = t;
5936
5942
  try {
5937
- const s = yield Or(t, i, r);
5938
- return this.setState(s), s;
5939
- } catch (s) {
5940
- console.error("Failed to update transaction:", s);
5941
- const a = new Error("INVALID_SESSION");
5942
- throw a.name = "INVALID_SESSION", a;
5943
+ const a = yield Or(t, i, r);
5944
+ return this.setState(a), a;
5945
+ } catch (a) {
5946
+ console.error("Failed to update transaction:", a);
5947
+ const s = new Error("INVALID_SESSION");
5948
+ throw s.name = "INVALID_SESSION", s;
5943
5949
  }
5944
5950
  });
5945
5951
  }
@@ -7533,7 +7539,7 @@ const fd = {
7533
7539
  const n = navigator == null ? void 0 : navigator.language.split("-")[0];
7534
7540
  return Zt[n] || Zt.en;
7535
7541
  }, hi = (n, e = {}) => {
7536
- var r, s;
7542
+ var r, a;
7537
7543
  if (!n) return Jt();
7538
7544
  const t = Zt[n] || Jt();
7539
7545
  return {
@@ -7554,7 +7560,7 @@ const fd = {
7554
7560
  }),
7555
7561
  status: {
7556
7562
  error: ((r = e == null ? void 0 : e.status) == null ? void 0 : r.error) || t.status.error,
7557
- invalidSession: ((s = e == null ? void 0 : e.status) == null ? void 0 : s.invalidSession) || t.status.invalidSession
7563
+ invalidSession: ((a = e == null ? void 0 : e.status) == null ? void 0 : a.invalidSession) || t.status.invalidSession
7558
7564
  }
7559
7565
  };
7560
7566
  };
@@ -7601,7 +7607,7 @@ class Qd {
7601
7607
  }
7602
7608
  // init
7603
7609
  init(e) {
7604
- return E(this, null, function* () {
7610
+ return k(this, null, function* () {
7605
7611
  if (typeof window == "undefined")
7606
7612
  throw new Error("PayPal can only be initialized in browser environment");
7607
7613
  try {
@@ -7618,16 +7624,16 @@ class Qd {
7618
7624
  }
7619
7625
  // render
7620
7626
  render(e, t) {
7621
- return E(this, null, function* () {
7627
+ return k(this, null, function* () {
7622
7628
  var i, r;
7623
7629
  if (!e.isConnected)
7624
7630
  throw new Error("PayPal parent element must be connected to DOM before render()");
7625
7631
  if (this.paypal) {
7626
- const s = v(v({}, Xd), (t == null ? void 0 : t.style) || {}), a = I(v({
7632
+ const a = v(v({}, Xd), (t == null ? void 0 : t.style) || {}), s = I(v({
7627
7633
  fundingSource: "paypal"
7628
7634
  }, t), {
7629
- style: s
7630
- }), o = (r = (i = this.paypal).Buttons) == null ? void 0 : r.call(i, a);
7635
+ style: a
7636
+ }), o = (r = (i = this.paypal).Buttons) == null ? void 0 : r.call(i, s);
7631
7637
  if (!o)
7632
7638
  throw new Error("PayPal Buttons instance is null");
7633
7639
  yield o.render(e);
@@ -7643,20 +7649,20 @@ class eu {
7643
7649
  }
7644
7650
  // init
7645
7651
  init(e) {
7646
- return E(this, null, function* () {
7652
+ return k(this, null, function* () {
7647
7653
  if (typeof window == "undefined")
7648
7654
  throw new Error("Braintree can only be initialized in browser environment");
7649
7655
  try {
7650
7656
  const [t, i] = yield Promise.all([
7651
- import("./client-Cz7Nq-cT.js").then((a) => a.c),
7652
- import("./data-collector-DPBfun3X.js").then((a) => a.d)
7653
- ]), r = t.default, s = i.default;
7657
+ import("./client-Cz7Nq-cT.js").then((s) => s.c),
7658
+ import("./data-collector-DPBfun3X.js").then((s) => s.d)
7659
+ ]), r = t.default, a = i.default;
7654
7660
  this.client = yield r.create({ authorization: e.authorization });
7655
7661
  try {
7656
- const a = yield s.create({ client: this.client, paypal: !0 });
7657
- this.deviceData = a.deviceData || null;
7658
- } catch (a) {
7659
- console.warn("Braintree device data collection failed:", a), this.deviceData = null;
7662
+ const s = yield a.create({ client: this.client, paypal: !0 });
7663
+ this.deviceData = s.deviceData || null;
7664
+ } catch (s) {
7665
+ console.warn("Braintree device data collection failed:", s), this.deviceData = null;
7660
7666
  }
7661
7667
  } catch (t) {
7662
7668
  throw console.error("Failed to initialize Braintree client:", t), t;
@@ -7665,7 +7671,7 @@ class eu {
7665
7671
  }
7666
7672
  // create venmo instance
7667
7673
  createVenmo(e) {
7668
- return E(this, null, function* () {
7674
+ return k(this, null, function* () {
7669
7675
  if (!this.client)
7670
7676
  throw new Error("Braintree client must be initialized before creating Venmo instance");
7671
7677
  try {
@@ -7694,7 +7700,7 @@ class eu {
7694
7700
  }
7695
7701
  // tokenize venmo payment
7696
7702
  tokenize() {
7697
- return E(this, null, function* () {
7703
+ return k(this, null, function* () {
7698
7704
  if (!this.venmoInstance)
7699
7705
  throw new Error("Venmo instance not initialized");
7700
7706
  return new Promise((e, t) => {
@@ -7702,9 +7708,9 @@ class eu {
7702
7708
  if (i)
7703
7709
  t(i);
7704
7710
  else {
7705
- const s = I(v({}, r), {
7711
+ const a = I(v({}, r), {
7706
7712
  device_data: this.deviceData || void 0
7707
- }), a = r, o = (a == null ? void 0 : a.billingAddress) || (a == null ? void 0 : a.billing_address);
7713
+ }), s = r, o = (s == null ? void 0 : s.billingAddress) || (s == null ? void 0 : s.billing_address);
7708
7714
  if (o) {
7709
7715
  const l = {
7710
7716
  city: o.adminArea2,
@@ -7714,16 +7720,16 @@ class eu {
7714
7720
  postal_code: o.postalCode,
7715
7721
  state: o.adminArea1
7716
7722
  };
7717
- s.billing_address = l;
7723
+ a.billing_address = l;
7718
7724
  }
7719
- e(s);
7725
+ e(a);
7720
7726
  }
7721
7727
  });
7722
7728
  });
7723
7729
  });
7724
7730
  }
7725
7731
  }
7726
- class au {
7732
+ class su {
7727
7733
  constructor() {
7728
7734
  c(this, "ev", new jr());
7729
7735
  c(this, "paypal", new Qd());
@@ -7744,7 +7750,7 @@ class au {
7744
7750
  }
7745
7751
  }
7746
7752
  export {
7747
- au as Core,
7753
+ su as Core,
7748
7754
  iu as PayNextCheckout,
7749
7755
  x as PaymentMethod
7750
7756
  };