choco-one-click-payment 1.1.48 → 1.1.50

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.esm.js CHANGED
@@ -32,6 +32,7 @@ const br = {
32
32
  errorApplePayUnsupported: "Apple Pay не поддерживается в этом браузере",
33
33
  errorApplePayInit: "Ошибка инициализации Apple Pay",
34
34
  errorApplePayPayment: "Ошибка оплаты через Apple Pay",
35
+ errorApplePayInterrupted: "Пожалуйста, подтвердите оплату после полной загрузки окна Apple Pay",
35
36
  errorGooglePayUnsupported: "Google Pay не поддерживается в этом браузере",
36
37
  errorGooglePaySettingsUnavailable: "Настройки Google Pay недоступны",
37
38
  errorGooglePayPayment: "Ошибка оплаты через Google Pay",
@@ -71,6 +72,7 @@ const br = {
71
72
  errorApplePayUnsupported: "Apple Pay is not supported in this browser",
72
73
  errorApplePayInit: "Apple Pay initialization error",
73
74
  errorApplePayPayment: "Apple Pay payment error",
75
+ errorApplePayInterrupted: "Please confirm payment after the Apple Pay sheet fully loads",
74
76
  errorGooglePayUnsupported: "Google Pay is not supported in this browser",
75
77
  errorGooglePaySettingsUnavailable: "Google Pay settings are unavailable",
76
78
  errorGooglePayPayment: "Google Pay payment error",
@@ -110,6 +112,7 @@ const br = {
110
112
  errorApplePayUnsupported: "Бұл браузерде Apple Pay қолдау көрсетілмейді",
111
113
  errorApplePayInit: "Apple Pay инициализация қатесі",
112
114
  errorApplePayPayment: "Apple Pay арқылы төлем қатесі",
115
+ errorApplePayInterrupted: "Өтінеміз, төлемді Apple Pay терезесі толық жүктелгеннен кейін растаңыз",
113
116
  errorGooglePayUnsupported: "Бұл браузерде Google Pay қолдау көрсетілмейді",
114
117
  errorGooglePaySettingsUnavailable: "Google Pay баптаулары қолжетімсіз",
115
118
  errorGooglePayPayment: "Google Pay арқылы төлем қатесі",
@@ -149,6 +152,7 @@ const br = {
149
152
  errorApplePayUnsupported: "ამ ბრაუზერში Apple Pay არ არის მხარდაჭერილი",
150
153
  errorApplePayInit: "Apple Pay-ის ინიციალიზაციის შეცდომა",
151
154
  errorApplePayPayment: "Apple Pay-ით გადახდის შეცდომა",
155
+ errorApplePayInterrupted: "გთხოვთ, დაადასტუროთ გადახდა Apple Pay-ის ფანჯრის სრულად ჩატვირთვის შემდეგ",
152
156
  errorGooglePayUnsupported: "ამ ბრაუზერში Google Pay არ არის მხარდაჭერილი",
153
157
  errorGooglePaySettingsUnavailable: "Google Pay-ის პარამეტრები მიუწვდომელია",
154
158
  errorGooglePayPayment: "Google Pay-ით გადახდის შეცდომა",
@@ -241,16 +245,16 @@ function Pr() {
241
245
  Object.defineProperty(u, "__esModule", {
242
246
  value: !0
243
247
  }), u.Centrifuge = void 0;
244
- var h = I(l(187)), y = I(l(471)), m = l(147), b = l(853);
248
+ var f = I(l(187)), y = I(l(471)), C = l(147), b = l(853);
245
249
  function I(g) {
246
250
  return g && g.__esModule ? g : { default: g };
247
251
  }
248
252
  function B(g) {
249
253
  "@babel/helpers - typeof";
250
- return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? B = function(C) {
251
- return typeof C;
252
- } : B = function(C) {
253
- return C && typeof Symbol == "function" && C.constructor === Symbol && C !== Symbol.prototype ? "symbol" : typeof C;
254
+ return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? B = function(m) {
255
+ return typeof m;
256
+ } : B = function(m) {
257
+ return m && typeof Symbol == "function" && m.constructor === Symbol && m !== Symbol.prototype ? "symbol" : typeof m;
254
258
  }, B(g);
255
259
  }
256
260
  function Q(g, p) {
@@ -258,12 +262,12 @@ function Pr() {
258
262
  throw new TypeError("Cannot call a class as a function");
259
263
  }
260
264
  function S(g, p) {
261
- for (var C = 0; C < p.length; C++) {
262
- var d = p[C];
265
+ for (var m = 0; m < p.length; m++) {
266
+ var d = p[m];
263
267
  d.enumerable = d.enumerable || !1, d.configurable = !0, "value" in d && (d.writable = !0), Object.defineProperty(g, d.key, d);
264
268
  }
265
269
  }
266
- function P(g, p, C) {
270
+ function P(g, p, m) {
267
271
  return p && S(g.prototype, p), g;
268
272
  }
269
273
  function k(g, p) {
@@ -277,7 +281,7 @@ function Pr() {
277
281
  }, R(g, p);
278
282
  }
279
283
  function L(g) {
280
- var p = K();
284
+ var p = G();
281
285
  return function() {
282
286
  var d = z(g), s;
283
287
  if (p) {
@@ -300,7 +304,7 @@ function Pr() {
300
304
  throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
301
305
  return g;
302
306
  }
303
- function K() {
307
+ function G() {
304
308
  if (typeof Reflect > "u" || !Reflect.construct || Reflect.construct.sham) return !1;
305
309
  if (typeof Proxy == "function") return !0;
306
310
  try {
@@ -311,16 +315,16 @@ function Pr() {
311
315
  }
312
316
  }
313
317
  function z(g) {
314
- return z = Object.setPrototypeOf ? Object.getPrototypeOf : function(C) {
315
- return C.__proto__ || Object.getPrototypeOf(C);
318
+ return z = Object.setPrototypeOf ? Object.getPrototypeOf : function(m) {
319
+ return m.__proto__ || Object.getPrototypeOf(m);
316
320
  }, z(g);
317
321
  }
318
322
  var J = "timeout", M = "connection closed", v = /* @__PURE__ */ (function(g) {
319
- k(C, g);
320
- var p = L(C);
321
- function C(d, s) {
323
+ k(m, g);
324
+ var p = L(m);
325
+ function m(d, s) {
322
326
  var a;
323
- return Q(this, C), a = p.call(this), a._url = d, a._websocket = null, a._sockjs = null, a._isSockjs = !1, a._xmlhttprequest = null, a._binary = !1, a._methodType = null, a._pushType = null, a._encoder = null, a._decoder = null, a._status = "disconnected", a._reconnect = !0, a._reconnecting = !1, a._transport = null, a._transportName = null, a._transportClosed = !0, a._messageId = 0, a._clientID = null, a._refreshRequired = !1, a._subs = {}, a._serverSubs = {}, a._lastSeq = {}, a._lastGen = {}, a._lastOffset = {}, a._lastEpoch = {}, a._messages = [], a._isBatching = !1, a._isSubscribeBatching = !1, a._privateChannels = {}, a._numRefreshFailed = 0, a._refreshTimeout = null, a._pingTimeout = null, a._pongTimeout = null, a._subRefreshTimeouts = {}, a._retries = 0, a._callbacks = {}, a._latency = null, a._latencyStart = null, a._connectData = null, a._token = null, a._xhrID = 0, a._xhrs = {}, a._dispatchPromise = Promise.resolve(), a._protocol = "", a._config = {
327
+ return Q(this, m), a = p.call(this), a._url = d, a._websocket = null, a._sockjs = null, a._isSockjs = !1, a._xmlhttprequest = null, a._binary = !1, a._methodType = null, a._pushType = null, a._encoder = null, a._decoder = null, a._status = "disconnected", a._reconnect = !0, a._reconnecting = !1, a._transport = null, a._transportName = null, a._transportClosed = !0, a._messageId = 0, a._clientID = null, a._refreshRequired = !1, a._subs = {}, a._serverSubs = {}, a._lastSeq = {}, a._lastGen = {}, a._lastOffset = {}, a._lastEpoch = {}, a._messages = [], a._isBatching = !1, a._isSubscribeBatching = !1, a._privateChannels = {}, a._numRefreshFailed = 0, a._refreshTimeout = null, a._pingTimeout = null, a._pongTimeout = null, a._subRefreshTimeouts = {}, a._retries = 0, a._callbacks = {}, a._latency = null, a._latencyStart = null, a._connectData = null, a._token = null, a._xhrID = 0, a._xhrs = {}, a._dispatchPromise = Promise.resolve(), a._protocol = "", a._config = {
324
328
  protocol: "",
325
329
  debug: !1,
326
330
  name: "js",
@@ -355,7 +359,7 @@ function Pr() {
355
359
  disableWithCredentials: !1
356
360
  }, a._configure(s), a;
357
361
  }
358
- return P(C, [{
362
+ return P(m, [{
359
363
  key: "setToken",
360
364
  value: function(s) {
361
365
  this._token = s;
@@ -392,9 +396,9 @@ function Pr() {
392
396
  }
393
397
  }, {
394
398
  key: "_ajax",
395
- value: function(s, a, A, f, E) {
399
+ value: function(s, a, A, h, E) {
396
400
  var _ = this, T = "";
397
- this._debug("sending AJAX request to", s, "with data", JSON.stringify(f));
401
+ this._debug("sending AJAX request to", s, "with data", JSON.stringify(h));
398
402
  var w;
399
403
  this._xmlhttprequest !== null ? w = new this._xmlhttprequest() : w = l.g.XMLHttpRequest ? new l.g.XMLHttpRequest() : new l.g.ActiveXObject("Microsoft.XMLHTTP");
400
404
  for (var O in a)
@@ -425,7 +429,7 @@ function Pr() {
425
429
  data: null
426
430
  });
427
431
  }, setTimeout(function() {
428
- return w.send(JSON.stringify(f));
432
+ return w.send(JSON.stringify(h));
429
433
  }, 20), w;
430
434
  }
431
435
  }, {
@@ -449,7 +453,7 @@ function Pr() {
449
453
  if (!this._formatOverride(s)) {
450
454
  if (s === "protobuf")
451
455
  throw new Error("not implemented by JSON only Centrifuge client – use client with Protobuf");
452
- this._binary = !1, this._methodType = m.JsonMethodType, this._pushType = m.JsonPushType, this._encoder = new m.JsonEncoder(), this._decoder = new m.JsonDecoder();
456
+ this._binary = !1, this._methodType = C.JsonMethodType, this._pushType = C.JsonPushType, this._encoder = new C.JsonEncoder(), this._decoder = new C.JsonDecoder();
453
457
  }
454
458
  }
455
459
  }, {
@@ -540,10 +544,10 @@ function Pr() {
540
544
  if (this._callbacks.hasOwnProperty(a)) {
541
545
  var A = this._callbacks[a];
542
546
  clearTimeout(A.timeout);
543
- var f = A.errback;
544
- if (!f)
547
+ var h = A.errback;
548
+ if (!h)
545
549
  continue;
546
- f({
550
+ h({
547
551
  error: this._createErrorObject("disconnected")
548
552
  });
549
553
  }
@@ -572,9 +576,9 @@ function Pr() {
572
576
  for (var a in s) {
573
577
  var A = a.id;
574
578
  if (A in this._callbacks) {
575
- var f = this._callbacks[A];
579
+ var h = this._callbacks[A];
576
580
  clearTimeout(this._callbacks[A].timeout), delete this._callbacks[A];
577
- var E = f.errback;
581
+ var E = h.errback;
578
582
  E({
579
583
  error: this._createErrorObject(M, 0)
580
584
  });
@@ -609,10 +613,10 @@ function Pr() {
609
613
  s._transportClosed = !1, s._isSockjs ? (s._transportName = "sockjs-" + s._transport.transport, s._transport.onheartbeat = function() {
610
614
  return s._restartPing();
611
615
  }) : s._transportName = "websocket";
612
- var f = {
616
+ var h = {
613
617
  // method: this._methodType.CONNECT
614
618
  };
615
- (s._token || s._connectData || s._config.name || s._config.version) && (f.params = {}), s._token && (f.params.token = s._token), s._connectData && (f.params.data = s._connectData), s._config.name && (f.params.name = s._config.name), s._config.version && (f.params.version = s._config.version);
619
+ (s._token || s._connectData || s._config.name || s._config.version) && (h.params = {}), s._token && (h.params.token = s._token), s._connectData && (h.params.data = s._connectData), s._config.name && (h.params.name = s._config.name), s._config.version && (h.params.version = s._config.version);
616
620
  var E = {}, _ = !1;
617
621
  for (var T in s._serverSubs)
618
622
  if (s._serverSubs.hasOwnProperty(T) && s._serverSubs[T].recoverable) {
@@ -622,26 +626,26 @@ function Pr() {
622
626
  };
623
627
  s._serverSubs[T].seq || s._serverSubs[T].gen ? (s._serverSubs[T].seq && (w.seq = s._serverSubs[T].seq), s._serverSubs[T].gen && (w.gen = s._serverSubs[T].gen)) : s._serverSubs[T].offset && (w.offset = s._serverSubs[T].offset), s._serverSubs[T].epoch && (w.epoch = s._serverSubs[T].epoch), E[T] = w;
624
628
  }
625
- _ && (f.params || (f.params = {}), f.params.subs = E), s._latencyStart = /* @__PURE__ */ new Date(), s._call(f).then(function(O) {
629
+ _ && (h.params || (h.params = {}), h.params.subs = E), s._latencyStart = /* @__PURE__ */ new Date(), s._call(h).then(function(O) {
626
630
  s._connectResponse(s._decoder.decodeCommandResult(s._methodType.CONNECT, O.result), _), O.next && O.next();
627
631
  }, function(O) {
628
632
  var F = O.error;
629
633
  F.code === 109 && (s._refreshRequired = !0), s._disconnect("connect error", !0), O.next && O.next();
630
634
  });
631
- }, this._transport.onerror = function(f) {
632
- s._debug("transport level error", f);
633
- }, this._transport.onclose = function(f) {
635
+ }, this._transport.onerror = function(h) {
636
+ s._debug("transport level error", h);
637
+ }, this._transport.onclose = function(h) {
634
638
  s._transportClosed = !0;
635
639
  var E = M, _ = !0;
636
- if (f && "reason" in f && f.reason)
640
+ if (h && "reason" in h && h.reason)
637
641
  try {
638
- var T = JSON.parse(f.reason);
642
+ var T = JSON.parse(h.reason);
639
643
  s._debug("reason is an advice object", T), E = T.reason, _ = T.reconnect;
640
644
  } catch {
641
- E = f.reason, s._debug("reason is a plain string", E);
645
+ E = h.reason, s._debug("reason is a plain string", E);
642
646
  }
643
647
  if (s._config.onTransportClose !== null && s._config.onTransportClose({
644
- event: f,
648
+ event: h,
645
649
  reason: E,
646
650
  reconnect: _
647
651
  }), s._disconnect(E, _), s._reconnect === !0) {
@@ -651,8 +655,8 @@ function Pr() {
651
655
  s._reconnect === !0 && (s._refreshRequired ? s._refresh() : s._connect());
652
656
  }, w);
653
657
  }
654
- }, this._transport.onmessage = function(f) {
655
- s._dataReceived(f.data);
658
+ }, this._transport.onmessage = function(h) {
659
+ s._dataReceived(h.data);
656
660
  };
657
661
  }
658
662
  }, {
@@ -672,11 +676,11 @@ function Pr() {
672
676
  data: a
673
677
  };
674
678
  s !== "" && (A.method = s);
675
- var f = {
679
+ var h = {
676
680
  method: this._methodType.RPC,
677
681
  params: A
678
682
  };
679
- return this._methodCall(f, function(E) {
683
+ return this._methodCall(h, function(E) {
680
684
  return E;
681
685
  });
682
686
  }
@@ -708,9 +712,9 @@ function Pr() {
708
712
  key: "_methodCall",
709
713
  value: function(s, a) {
710
714
  var A = this;
711
- return this.isConnected() ? new Promise(function(f, E) {
715
+ return this.isConnected() ? new Promise(function(h, E) {
712
716
  A._call(s).then(function(_) {
713
- f(a(A._decoder.decodeCommandResult(s.method, _.result))), _.next && _.next();
717
+ h(a(A._decoder.decodeCommandResult(s.method, _.result))), _.next && _.next();
714
718
  }, function(_) {
715
719
  E(_.error), _.next && _.next();
716
720
  });
@@ -733,11 +737,11 @@ function Pr() {
733
737
  }, {
734
738
  key: "history",
735
739
  value: function(s, a) {
736
- var A = this._getHistoryParams(s, a), f = {
740
+ var A = this._getHistoryParams(s, a), h = {
737
741
  method: this._methodType.HISTORY,
738
742
  params: A
739
743
  };
740
- return this._methodCall(f, function(E) {
744
+ return this._methodCall(h, function(E) {
741
745
  return {
742
746
  publications: E.publications,
743
747
  epoch: E.epoch || "",
@@ -781,23 +785,23 @@ function Pr() {
781
785
  value: function(s) {
782
786
  var a = this, A = this._decoder.decodeReplies(s);
783
787
  this._dispatchPromise = this._dispatchPromise.then(function() {
784
- var f;
788
+ var h;
785
789
  a._dispatchPromise = new Promise(function(E) {
786
- f = E;
787
- }), a._dispatchSynchronized(A, f);
790
+ h = E;
791
+ }), a._dispatchSynchronized(A, h);
788
792
  }), this._restartPing();
789
793
  }
790
794
  }, {
791
795
  key: "_dispatchSynchronized",
792
796
  value: function(s, a) {
793
- var A = this, f = Promise.resolve(), E = function(w) {
794
- s.hasOwnProperty(w) && (f = f.then(function() {
797
+ var A = this, h = Promise.resolve(), E = function(w) {
798
+ s.hasOwnProperty(w) && (h = h.then(function() {
795
799
  return A._dispatchReply(s[w]);
796
800
  }));
797
801
  };
798
802
  for (var _ in s)
799
803
  E(_);
800
- f = f.then(function() {
804
+ h = h.then(function() {
801
805
  a();
802
806
  });
803
807
  }
@@ -809,16 +813,16 @@ function Pr() {
809
813
  });
810
814
  if (s == null)
811
815
  return this._debug("dispatch: got undefined or null reply"), a(), A;
812
- var f = s.id;
813
- return f && f > 0 ? this._handleReply(s, a) : this._handlePush(s.result, a), A;
816
+ var h = s.id;
817
+ return h && h > 0 ? this._handleReply(s, a) : this._handlePush(s.result, a), A;
814
818
  }
815
819
  }, {
816
820
  key: "_call",
817
821
  value: function(s) {
818
822
  var a = this;
819
- return new Promise(function(A, f) {
823
+ return new Promise(function(A, h) {
820
824
  var E = a._addMessage(s);
821
- a._registerCall(E, A, f);
825
+ a._registerCall(E, A, h);
822
826
  });
823
827
  }
824
828
  }, {
@@ -839,9 +843,9 @@ function Pr() {
839
843
  return;
840
844
  }
841
845
  if (this._clearConnectedState(A), this._debug("disconnected:", s, a), this._setStatus("disconnected"), this._refreshTimeout && (clearTimeout(this._refreshTimeout), this._refreshTimeout = null), this._reconnecting === !1) {
842
- for (var f in this._serverSubs)
843
- this._serverSubs.hasOwnProperty(f) && this.emit("unsubscribe", {
844
- channel: f
846
+ for (var h in this._serverSubs)
847
+ this._serverSubs.hasOwnProperty(h) && this.emit("unsubscribe", {
848
+ channel: h
845
849
  });
846
850
  this.emit("disconnect", {
847
851
  reason: s,
@@ -864,7 +868,7 @@ function Pr() {
864
868
  return;
865
869
  }
866
870
  this._refreshTimeout !== null && (clearTimeout(this._refreshTimeout), this._refreshTimeout = null);
867
- var a = this._clientID, A = this._newXHRID(), f = function(w) {
871
+ var a = this._clientID, A = this._newXHRID(), h = function(w) {
868
872
  if (A in s._xhrs && delete s._xhrs[A], s._clientID === a) {
869
873
  if (w.error || w.status !== 200) {
870
874
  if (w.error ? s._debug("error refreshing connection token", w.error) : s._debug("error refreshing connection token: wrong status code", w.status), s._numRefreshFailed++, s._refreshTimeout !== null && (clearTimeout(s._refreshTimeout), s._refreshTimeout = null), s._config.refreshAttempts !== null && s._numRefreshFailed >= s._config.refreshAttempts) {
@@ -901,9 +905,9 @@ function Pr() {
901
905
  };
902
906
  if (this._config.onRefresh !== null) {
903
907
  var E = {};
904
- this._config.onRefresh(E, f);
908
+ this._config.onRefresh(E, h);
905
909
  } else {
906
- var _ = this._ajax(this._config.refreshEndpoint, this._config.refreshParams, this._config.refreshHeaders, this._config.refreshData, f);
910
+ var _ = this._ajax(this._config.refreshEndpoint, this._config.refreshParams, this._config.refreshHeaders, this._config.refreshData, h);
907
911
  this._xhrs[A] = _;
908
912
  }
909
913
  }
@@ -938,8 +942,8 @@ function Pr() {
938
942
  this._clearSubRefreshTimeout(s);
939
943
  else
940
944
  return;
941
- var A = this._clientID, f = this._newXHRID(), E = function(O) {
942
- if (f in a._xhrs && delete a._xhrs[f], !(O.error || O.status !== 200 || a._clientID !== A)) {
945
+ var A = this._clientID, h = this._newXHRID(), E = function(O) {
946
+ if (h in a._xhrs && delete a._xhrs[h], !(O.error || O.status !== 200 || a._clientID !== A)) {
943
947
  var F = {};
944
948
  if (O.data.channels)
945
949
  for (var X in O.data.channels) {
@@ -972,7 +976,7 @@ function Pr() {
972
976
  }, E);
973
977
  else {
974
978
  var T = this._ajax(this._config.subscribeEndpoint, this._config.subscribeParams, this._config.subscribeHeaders, _, E);
975
- this._xhrs[f] = T;
979
+ this._xhrs[h] = T;
976
980
  }
977
981
  }
978
982
  }, {
@@ -985,8 +989,8 @@ function Pr() {
985
989
  value: function(s, a) {
986
990
  var A = this;
987
991
  this._debug("subscription refresh error", s, a), this._clearSubRefreshTimeout(s);
988
- var f = this._getSub(s);
989
- if (f !== null) {
992
+ var h = this._getSub(s);
993
+ if (h !== null) {
990
994
  var E = Math.round(Math.random() * 1e3), _ = setTimeout(function() {
991
995
  return A._subRefresh(s);
992
996
  }, this._config.subRefreshInterval + E);
@@ -998,8 +1002,8 @@ function Pr() {
998
1002
  value: function(s, a) {
999
1003
  var A = this;
1000
1004
  this._debug("subscription refresh success", s), this._clearSubRefreshTimeout(s);
1001
- var f = this._getSub(s);
1002
- if (f !== null && a.expires === !0) {
1005
+ var h = this._getSub(s);
1006
+ if (h !== null && a.expires === !0) {
1003
1007
  var E = setTimeout(function() {
1004
1008
  return A._subRefresh(s);
1005
1009
  }, this._getTTLMilliseconds(a.ttl));
@@ -1011,8 +1015,8 @@ function Pr() {
1011
1015
  value: function(s, a) {
1012
1016
  var A = this;
1013
1017
  this._debug("subscribing on", s.channel);
1014
- var f = s.channel;
1015
- if (f in this._subs || (this._subs[f] = s), !this.isConnected()) {
1018
+ var h = s.channel;
1019
+ if (h in this._subs || (this._subs[h] = s), !this.isConnected()) {
1016
1020
  s._setNew();
1017
1021
  return;
1018
1022
  }
@@ -1020,29 +1024,29 @@ function Pr() {
1020
1024
  var E = {
1021
1025
  method: this._methodType.SUBSCRIBE,
1022
1026
  params: {
1023
- channel: f
1027
+ channel: h
1024
1028
  }
1025
1029
  };
1026
- if (s._subscribeData && (E.params.data = s._subscribeData), (0, b.startsWith)(f, this._config.privateChannelPrefix))
1027
- this._isSubscribeBatching ? this._privateChannels[f] = !0 : (this.startSubscribeBatching(), this._subscribe(s), this.stopSubscribeBatching());
1030
+ if (s._subscribeData && (E.params.data = s._subscribeData), (0, b.startsWith)(h, this._config.privateChannelPrefix))
1031
+ this._isSubscribeBatching ? this._privateChannels[h] = !0 : (this.startSubscribeBatching(), this._subscribe(s), this.stopSubscribeBatching());
1028
1032
  else {
1029
1033
  var _ = s._needRecover();
1030
1034
  if (_ === !0) {
1031
1035
  E.params.recover = !0;
1032
- var T = this._getLastSeq(f), w = this._getLastGen(f);
1036
+ var T = this._getLastSeq(h), w = this._getLastGen(h);
1033
1037
  if (T || w)
1034
1038
  T && (E.params.seq = T), w && (E.params.gen = w);
1035
1039
  else {
1036
- var O = this._getLastOffset(f);
1040
+ var O = this._getLastOffset(h);
1037
1041
  O && (E.params.offset = O);
1038
1042
  }
1039
- var F = this._getLastEpoch(f);
1043
+ var F = this._getLastEpoch(h);
1040
1044
  F && (E.params.epoch = F);
1041
1045
  }
1042
1046
  this._call(E).then(function(X) {
1043
- A._subscribeResponse(f, _, A._decoder.decodeCommandResult(A._methodType.SUBSCRIBE, X.result)), X.next && X.next();
1047
+ A._subscribeResponse(h, _, A._decoder.decodeCommandResult(A._methodType.SUBSCRIBE, X.result)), X.next && X.next();
1044
1048
  }, function(X) {
1045
- A._subscribeError(f, X.error), X.next && X.next();
1049
+ A._subscribeError(h, X.error), X.next && X.next();
1046
1050
  });
1047
1051
  }
1048
1052
  }
@@ -1080,7 +1084,7 @@ function Pr() {
1080
1084
  }, {
1081
1085
  key: "_connectResponse",
1082
1086
  value: function(s, a) {
1083
- var A = this, f = this._reconnecting;
1087
+ var A = this, h = this._reconnecting;
1084
1088
  if (this._reconnecting = !1, this._resetRetry(), this._refreshRequired = !1, !this.isConnected()) {
1085
1089
  this._latencyStart !== null && (this._latency = (/* @__PURE__ */ new Date()).getTime() - this._latencyStart.getTime(), this._latencyStart = null), this._clientID = s.client, this._setStatus("connected"), this._refreshTimeout && clearTimeout(this._refreshTimeout), s.expires && (this._refreshTimeout = setTimeout(function() {
1086
1090
  return A._refresh();
@@ -1088,7 +1092,7 @@ function Pr() {
1088
1092
  for (var E in this._subs)
1089
1093
  if (this._subs.hasOwnProperty(E)) {
1090
1094
  var _ = this._subs[E];
1091
- _._shouldResubscribe() && this._subscribe(_, f);
1095
+ _._shouldResubscribe() && this._subscribe(_, h);
1092
1096
  }
1093
1097
  this.stopSubscribeBatching(), this.stopBatching(), this._startPing();
1094
1098
  var T = {
@@ -1104,9 +1108,9 @@ function Pr() {
1104
1108
  value: function(s) {
1105
1109
  for (var a in s)
1106
1110
  if (s.hasOwnProperty(a)) {
1107
- var A = s[a], f = this._serverSubs[a] !== void 0, E = {
1111
+ var A = s[a], h = this._serverSubs[a] !== void 0, E = {
1108
1112
  channel: a,
1109
- isResubscribe: f
1113
+ isResubscribe: h
1110
1114
  };
1111
1115
  E = this._expandSubscribeContext(E, A), this.emit("subscribe", E);
1112
1116
  }
@@ -1171,12 +1175,12 @@ function Pr() {
1171
1175
  value: function(s, a) {
1172
1176
  var A = !1;
1173
1177
  "recovered" in a && (A = a.recovered), s.recovered = A;
1174
- var f = !1;
1175
- "positioned" in a && (f = a.positioned);
1178
+ var h = !1;
1179
+ "positioned" in a && (h = a.positioned);
1176
1180
  var E = "";
1177
1181
  "epoch" in a && (E = a.epoch);
1178
1182
  var _ = 0;
1179
- return "offset" in a && (_ = a.offset), f && (s.streamPosition = {
1183
+ return "offset" in a && (_ = a.offset), h && (s.streamPosition = {
1180
1184
  offset: _,
1181
1185
  epoch: E
1182
1186
  }), a.data && (s.data = a.data), s;
@@ -1184,7 +1188,7 @@ function Pr() {
1184
1188
  }, {
1185
1189
  key: "_subscribeResponse",
1186
1190
  value: function(s, a, A) {
1187
- var f = this, E = this._getSub(s);
1191
+ var h = this, E = this._getSub(s);
1188
1192
  if (E && E._isSubscribing()) {
1189
1193
  E._setSubscribeSuccess(A);
1190
1194
  var _ = A.publications;
@@ -1195,7 +1199,7 @@ function Pr() {
1195
1199
  }
1196
1200
  if (A.recoverable && (!a || !A.recovered) && (this._lastSeq[s] = A.seq || 0, this._lastGen[s] = A.gen || 0, this._lastOffset[s] = A.offset || 0), this._lastEpoch[s] = A.epoch || "", A.recoverable && (E._recoverable = !0), A.expires === !0) {
1197
1201
  var w = setTimeout(function() {
1198
- return f._subRefresh(s);
1202
+ return h._subRefresh(s);
1199
1203
  }, this._getTTLMilliseconds(A.ttl));
1200
1204
  this._subRefreshTimeouts[s] = w;
1201
1205
  }
@@ -1204,7 +1208,7 @@ function Pr() {
1204
1208
  }, {
1205
1209
  key: "_handleReply",
1206
1210
  value: function(s, a) {
1207
- var A = s.id, f = s.result;
1211
+ var A = s.id, h = s.result;
1208
1212
  if (!(A in this._callbacks)) {
1209
1213
  a();
1210
1214
  return;
@@ -1226,7 +1230,7 @@ function Pr() {
1226
1230
  if (!_)
1227
1231
  return;
1228
1232
  _({
1229
- result: f,
1233
+ result: h,
1230
1234
  next: a
1231
1235
  });
1232
1236
  }
@@ -1236,34 +1240,34 @@ function Pr() {
1236
1240
  value: function(s, a) {
1237
1241
  var A = {
1238
1242
  info: a.info
1239
- }, f = this._getSub(s);
1240
- if (!f) {
1243
+ }, h = this._getSub(s);
1244
+ if (!h) {
1241
1245
  this._isServerSub(s) && (A.channel = s, this.emit("join", A));
1242
1246
  return;
1243
1247
  }
1244
- f.emit("join", A);
1248
+ h.emit("join", A);
1245
1249
  }
1246
1250
  }, {
1247
1251
  key: "_handleLeave",
1248
1252
  value: function(s, a) {
1249
1253
  var A = {
1250
1254
  info: a.info
1251
- }, f = this._getSub(s);
1252
- if (!f) {
1255
+ }, h = this._getSub(s);
1256
+ if (!h) {
1253
1257
  this._isServerSub(s) && (A.channel = s, this.emit("leave", A));
1254
1258
  return;
1255
1259
  }
1256
- f.emit("leave", A);
1260
+ h.emit("leave", A);
1257
1261
  }
1258
1262
  }, {
1259
1263
  key: "_handleUnsub",
1260
1264
  value: function(s, a) {
1261
- var A = {}, f = this._getSub(s);
1262
- if (!f) {
1265
+ var A = {}, h = this._getSub(s);
1266
+ if (!h) {
1263
1267
  this._isServerSub(s) && (delete this._serverSubs[s], A.channel = s, this.emit("unsubscribe", A));
1264
1268
  return;
1265
1269
  }
1266
- f.unsubscribe(), a.resubscribe === !0 && f.subscribe();
1270
+ h.unsubscribe(), a.resubscribe === !0 && h.subscribe();
1267
1271
  }
1268
1272
  }, {
1269
1273
  key: "_handleSub",
@@ -1284,17 +1288,17 @@ function Pr() {
1284
1288
  }, {
1285
1289
  key: "_handlePublication",
1286
1290
  value: function(s, a) {
1287
- var A = this._getSub(s), f = {
1291
+ var A = this._getSub(s), h = {
1288
1292
  data: a.data,
1289
1293
  seq: a.seq,
1290
1294
  gen: a.gen,
1291
1295
  offset: a.offset
1292
1296
  };
1293
- if (a.info && (f.info = a.info), !A) {
1294
- this._isServerSub(s) && (a.seq !== void 0 && (this._serverSubs[s].seq = a.seq), a.gen !== void 0 && (this._serverSubs[s].gen = a.gen), a.offset !== void 0 && (this._serverSubs[s].offset = a.offset), f.channel = s, this.emit("publish", f));
1297
+ if (a.info && (h.info = a.info), !A) {
1298
+ this._isServerSub(s) && (a.seq !== void 0 && (this._serverSubs[s].seq = a.seq), a.gen !== void 0 && (this._serverSubs[s].gen = a.gen), a.offset !== void 0 && (this._serverSubs[s].offset = a.offset), h.channel = s, this.emit("publish", h));
1295
1299
  return;
1296
1300
  }
1297
- a.seq !== void 0 && (this._lastSeq[s] = a.seq), a.gen !== void 0 && (this._lastGen[s] = a.gen), a.offset !== void 0 && (this._lastOffset[s] = a.offset), A.emit("publish", f);
1301
+ a.seq !== void 0 && (this._lastSeq[s] = a.seq), a.gen !== void 0 && (this._lastGen[s] = a.gen), a.offset !== void 0 && (this._lastOffset[s] = a.offset), A.emit("publish", h);
1298
1302
  }
1299
1303
  }, {
1300
1304
  key: "_handleMessage",
@@ -1304,25 +1308,25 @@ function Pr() {
1304
1308
  }, {
1305
1309
  key: "_handlePush",
1306
1310
  value: function(s, a) {
1307
- var A = this._decoder.decodePush(s), f = 0;
1308
- "type" in A && (f = A.type);
1311
+ var A = this._decoder.decodePush(s), h = 0;
1312
+ "type" in A && (h = A.type);
1309
1313
  var E = A.channel;
1310
- if (f === this._pushType.PUBLICATION) {
1314
+ if (h === this._pushType.PUBLICATION) {
1311
1315
  var _ = this._decoder.decodePushData(this._pushType.PUBLICATION, A.data);
1312
1316
  this._handlePublication(E, _);
1313
- } else if (f === this._pushType.MESSAGE) {
1317
+ } else if (h === this._pushType.MESSAGE) {
1314
1318
  var T = this._decoder.decodePushData(this._pushType.MESSAGE, A.data);
1315
1319
  this._handleMessage(T);
1316
- } else if (f === this._pushType.JOIN) {
1320
+ } else if (h === this._pushType.JOIN) {
1317
1321
  var w = this._decoder.decodePushData(this._pushType.JOIN, A.data);
1318
1322
  this._handleJoin(E, w);
1319
- } else if (f === this._pushType.LEAVE) {
1323
+ } else if (h === this._pushType.LEAVE) {
1320
1324
  var O = this._decoder.decodePushData(this._pushType.LEAVE, A.data);
1321
1325
  this._handleLeave(E, O);
1322
- } else if (f === this._pushType.UNSUBSCRIBE) {
1326
+ } else if (h === this._pushType.UNSUBSCRIBE) {
1323
1327
  var F = this._decoder.decodePushData(this._pushType.UNSUBSCRIBE, A.data);
1324
1328
  this._handleUnsub(E, F);
1325
- } else if (f === this._pushType.SUBSCRIBE) {
1329
+ } else if (h === this._pushType.SUBSCRIBE) {
1326
1330
  var X = this._decoder.decodePushData(this._pushType.UNSUBSCRIBE, A.data);
1327
1331
  this._handleSub(E, X);
1328
1332
  }
@@ -1387,14 +1391,14 @@ function Pr() {
1387
1391
  }, {
1388
1392
  key: "_registerCall",
1389
1393
  value: function(s, a, A) {
1390
- var f = this;
1394
+ var h = this;
1391
1395
  this._callbacks[s] = {
1392
1396
  callback: a,
1393
1397
  errback: A,
1394
1398
  timeout: null
1395
1399
  }, this._callbacks[s].timeout = setTimeout(function() {
1396
- delete f._callbacks[s], (0, b.isFunction)(A) && A({
1397
- error: f._createErrorObject(J)
1400
+ delete h._callbacks[s], (0, b.isFunction)(A) && A({
1401
+ error: h._createErrorObject(J)
1398
1402
  });
1399
1403
  }, this._config.timeout);
1400
1404
  }
@@ -1447,12 +1451,12 @@ function Pr() {
1447
1451
  var a = this._privateChannels;
1448
1452
  this._privateChannels = {};
1449
1453
  var A = [];
1450
- for (var f in a)
1451
- if (a.hasOwnProperty(f)) {
1452
- var E = this._getSub(f);
1454
+ for (var h in a)
1455
+ if (a.hasOwnProperty(h)) {
1456
+ var E = this._getSub(h);
1453
1457
  if (!E)
1454
1458
  continue;
1455
- A.push(f);
1459
+ A.push(h);
1456
1460
  }
1457
1461
  if (A.length === 0) {
1458
1462
  this._debug("no private channels found, no need to make request");
@@ -1537,14 +1541,14 @@ function Pr() {
1537
1541
  }, {
1538
1542
  key: "subscribe",
1539
1543
  value: function(s, a, A) {
1540
- var f = this._getSub(s);
1541
- if (f !== null)
1542
- return f._setEvents(a), f._isUnsubscribed() && f.subscribe(A), f;
1544
+ var h = this._getSub(s);
1545
+ if (h !== null)
1546
+ return h._setEvents(a), h._isUnsubscribed() && h.subscribe(A), h;
1543
1547
  var E = new y.default(this, s, a);
1544
1548
  return this._subs[s] = E, E.subscribe(A), E;
1545
1549
  }
1546
- }]), C;
1547
- })(h.default);
1550
+ }]), m;
1551
+ })(f.default);
1548
1552
  u.Centrifuge = v;
1549
1553
  })
1550
1554
  ),
@@ -1555,7 +1559,7 @@ function Pr() {
1555
1559
  Object.defineProperty(u, "__esModule", {
1556
1560
  value: !0
1557
1561
  }), u.default = void 0;
1558
- var h = l(382), y = h.Centrifuge;
1562
+ var f = l(382), y = f.Centrifuge;
1559
1563
  u.default = y, c.exports = u.default;
1560
1564
  })
1561
1565
  ),
@@ -1570,16 +1574,16 @@ function Pr() {
1570
1574
  if (!(Q instanceof S))
1571
1575
  throw new TypeError("Cannot call a class as a function");
1572
1576
  }
1573
- function h(Q, S) {
1577
+ function f(Q, S) {
1574
1578
  for (var P = 0; P < S.length; P++) {
1575
1579
  var k = S[P];
1576
1580
  k.enumerable = k.enumerable || !1, k.configurable = !0, "value" in k && (k.writable = !0), Object.defineProperty(Q, k.key, k);
1577
1581
  }
1578
1582
  }
1579
1583
  function y(Q, S, P) {
1580
- return S && h(Q.prototype, S), Q;
1584
+ return S && f(Q.prototype, S), Q;
1581
1585
  }
1582
- var m = {
1586
+ var C = {
1583
1587
  CONNECT: 0,
1584
1588
  SUBSCRIBE: 1,
1585
1589
  UNSUBSCRIBE: 2,
@@ -1593,7 +1597,7 @@ function Pr() {
1593
1597
  REFRESH: 10,
1594
1598
  SUB_REFRESH: 11
1595
1599
  };
1596
- u.JsonMethodType = m;
1600
+ u.JsonMethodType = C;
1597
1601
  var b = {
1598
1602
  PUBLICATION: 0,
1599
1603
  JOIN: 1,
@@ -1656,49 +1660,49 @@ function Pr() {
1656
1660
  471: (
1657
1661
  /***/
1658
1662
  (function(c, u, l) {
1659
- function h(p) {
1663
+ function f(p) {
1660
1664
  "@babel/helpers - typeof";
1661
- return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? h = function(d) {
1665
+ return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? f = function(d) {
1662
1666
  return typeof d;
1663
- } : h = function(d) {
1667
+ } : f = function(d) {
1664
1668
  return d && typeof Symbol == "function" && d.constructor === Symbol && d !== Symbol.prototype ? "symbol" : typeof d;
1665
- }, h(p);
1669
+ }, f(p);
1666
1670
  }
1667
1671
  Object.defineProperty(u, "__esModule", {
1668
1672
  value: !0
1669
1673
  }), u.default = void 0;
1670
- var y = b(l(187)), m = l(853);
1674
+ var y = b(l(187)), C = l(853);
1671
1675
  function b(p) {
1672
1676
  return p && p.__esModule ? p : { default: p };
1673
1677
  }
1674
- function I(p, C) {
1675
- if (!(p instanceof C))
1678
+ function I(p, m) {
1679
+ if (!(p instanceof m))
1676
1680
  throw new TypeError("Cannot call a class as a function");
1677
1681
  }
1678
- function B(p, C) {
1679
- for (var d = 0; d < C.length; d++) {
1680
- var s = C[d];
1682
+ function B(p, m) {
1683
+ for (var d = 0; d < m.length; d++) {
1684
+ var s = m[d];
1681
1685
  s.enumerable = s.enumerable || !1, s.configurable = !0, "value" in s && (s.writable = !0), Object.defineProperty(p, s.key, s);
1682
1686
  }
1683
1687
  }
1684
- function Q(p, C, d) {
1685
- return C && B(p.prototype, C), p;
1688
+ function Q(p, m, d) {
1689
+ return m && B(p.prototype, m), p;
1686
1690
  }
1687
- function S(p, C) {
1688
- if (typeof C != "function" && C !== null)
1691
+ function S(p, m) {
1692
+ if (typeof m != "function" && m !== null)
1689
1693
  throw new TypeError("Super expression must either be null or a function");
1690
- p.prototype = Object.create(C && C.prototype, { constructor: { value: p, writable: !0, configurable: !0 } }), C && P(p, C);
1694
+ p.prototype = Object.create(m && m.prototype, { constructor: { value: p, writable: !0, configurable: !0 } }), m && P(p, m);
1691
1695
  }
1692
- function P(p, C) {
1696
+ function P(p, m) {
1693
1697
  return P = Object.setPrototypeOf || function(s, a) {
1694
1698
  return s.__proto__ = a, s;
1695
- }, P(p, C);
1699
+ }, P(p, m);
1696
1700
  }
1697
1701
  function k(p) {
1698
- var C = q();
1702
+ var m = q();
1699
1703
  return function() {
1700
1704
  var s = D(p), a;
1701
- if (C) {
1705
+ if (m) {
1702
1706
  var A = D(this).constructor;
1703
1707
  a = Reflect.construct(s, arguments, A);
1704
1708
  } else
@@ -1706,10 +1710,10 @@ function Pr() {
1706
1710
  return R(this, a);
1707
1711
  };
1708
1712
  }
1709
- function R(p, C) {
1710
- if (C && (h(C) === "object" || typeof C == "function"))
1711
- return C;
1712
- if (C !== void 0)
1713
+ function R(p, m) {
1714
+ if (m && (f(m) === "object" || typeof m == "function"))
1715
+ return m;
1716
+ if (m !== void 0)
1713
1717
  throw new TypeError("Derived constructors may only return object or undefined");
1714
1718
  return L(p);
1715
1719
  }
@@ -1733,14 +1737,14 @@ function Pr() {
1733
1737
  return d.__proto__ || Object.getPrototypeOf(d);
1734
1738
  }, D(p);
1735
1739
  }
1736
- var K = 0, z = 1, J = 2, M = 3, v = 4, g = /* @__PURE__ */ (function(p) {
1740
+ var G = 0, z = 1, J = 2, M = 3, v = 4, g = /* @__PURE__ */ (function(p) {
1737
1741
  S(d, p);
1738
- var C = k(d);
1742
+ var m = k(d);
1739
1743
  function d(s, a, A) {
1740
- var f;
1741
- return I(this, d), f = C.call(this), f.channel = a, f._centrifuge = s, f._status = K, f._error = null, f._isResubscribe = !1, f._ready = !1, f._subscriptionPromise = null, f._noResubscribe = !1, f._recoverable = !1, f._recover = !1, f._setEvents(A), f._initializePromise(), f._promises = {}, f._promiseId = 0, f._subscribeData = null, f.on("error", function(E) {
1744
+ var h;
1745
+ return I(this, d), h = m.call(this), h.channel = a, h._centrifuge = s, h._status = G, h._error = null, h._isResubscribe = !1, h._ready = !1, h._subscriptionPromise = null, h._noResubscribe = !1, h._recoverable = !1, h._recover = !1, h._setEvents(A), h._initializePromise(), h._promises = {}, h._promiseId = 0, h._subscribeData = null, h.on("error", function(E) {
1742
1746
  this._centrifuge._debug("subscription error", E);
1743
- }), f;
1747
+ }), h;
1744
1748
  }
1745
1749
  return Q(d, [{
1746
1750
  key: "_nextPromiseId",
@@ -1751,11 +1755,11 @@ function Pr() {
1751
1755
  key: "_initializePromise",
1752
1756
  value: function() {
1753
1757
  var a = this;
1754
- this._ready = !1, this._subscriptionPromise = new Promise(function(A, f) {
1758
+ this._ready = !1, this._subscriptionPromise = new Promise(function(A, h) {
1755
1759
  a._resolve = function(E) {
1756
1760
  a._ready = !0, A(E);
1757
1761
  }, a._reject = function(E) {
1758
- a._ready = !0, f(E);
1762
+ a._ready = !0, h(E);
1759
1763
  };
1760
1764
  }).then(function() {
1761
1765
  }, function() {
@@ -1775,11 +1779,11 @@ function Pr() {
1775
1779
  key: "_setEvents",
1776
1780
  value: function(a) {
1777
1781
  if (a) {
1778
- if ((0, m.isFunction)(a))
1782
+ if ((0, C.isFunction)(a))
1779
1783
  this.on("publish", a);
1780
1784
  else if (Object.prototype.toString.call(a) === Object.prototype.toString.call({}))
1781
- for (var A = ["publish", "join", "leave", "unsubscribe", "subscribe", "error"], f = 0, E = A.length; f < E; f++) {
1782
- var _ = A[f];
1785
+ for (var A = ["publish", "join", "leave", "unsubscribe", "subscribe", "error"], h = 0, E = A.length; h < E; h++) {
1786
+ var _ = A[h];
1783
1787
  _ in a && this.on(_, a[_]);
1784
1788
  }
1785
1789
  }
@@ -1787,7 +1791,7 @@ function Pr() {
1787
1791
  }, {
1788
1792
  key: "_isNew",
1789
1793
  value: function() {
1790
- return this._status === K;
1794
+ return this._status === G;
1791
1795
  }
1792
1796
  }, {
1793
1797
  key: "_isUnsubscribed",
@@ -1817,7 +1821,7 @@ function Pr() {
1817
1821
  }, {
1818
1822
  key: "_setNew",
1819
1823
  value: function() {
1820
- this._status = K;
1824
+ this._status = G;
1821
1825
  }
1822
1826
  }, {
1823
1827
  key: "_setSubscribing",
@@ -1831,8 +1835,8 @@ function Pr() {
1831
1835
  this._status = J;
1832
1836
  var A = this._getSubscribeSuccessContext(a);
1833
1837
  this._recover = !1, this.emit("subscribe", A), this._resolve(A);
1834
- for (var f in this._promises)
1835
- clearTimeout(this._promises[f].timeout), this._promises[f].resolve(), delete this._promises[f];
1838
+ for (var h in this._promises)
1839
+ clearTimeout(this._promises[h].timeout), this._promises[h].resolve(), delete this._promises[h];
1836
1840
  }
1837
1841
  }
1838
1842
  }, {
@@ -1842,8 +1846,8 @@ function Pr() {
1842
1846
  this._status = M, this._error = a;
1843
1847
  var A = this._getSubscribeErrorContext();
1844
1848
  this.emit("error", A), this._reject(A);
1845
- for (var f in this._promises)
1846
- clearTimeout(this._promises[f].timeout), this._promises[f].reject(a), delete this._promises[f];
1849
+ for (var h in this._promises)
1850
+ clearTimeout(this._promises[h].timeout), this._promises[h].reject(a), delete this._promises[h];
1847
1851
  }
1848
1852
  }
1849
1853
  }, {
@@ -1909,7 +1913,7 @@ function Pr() {
1909
1913
  return Promise.resolve();
1910
1914
  if (this._isError())
1911
1915
  return Promise.reject(this._error);
1912
- var A = new Promise(function(f, E) {
1916
+ var A = new Promise(function(h, E) {
1913
1917
  var _ = setTimeout(function() {
1914
1918
  E({
1915
1919
  code: 0,
@@ -1918,7 +1922,7 @@ function Pr() {
1918
1922
  }, a._centrifuge._config.timeout);
1919
1923
  a._promises[a._nextPromiseId()] = {
1920
1924
  timeout: _,
1921
- resolve: f,
1925
+ resolve: h,
1922
1926
  reject: E
1923
1927
  };
1924
1928
  });
@@ -1967,14 +1971,14 @@ function Pr() {
1967
1971
  (function(c, u, l) {
1968
1972
  Object.defineProperty(u, "__esModule", {
1969
1973
  value: !0
1970
- }), u.backoff = b, u.errorExists = I, u.extend = B, u.isFunction = y, u.log = m, u.startsWith = h;
1971
- function h(Q, S) {
1974
+ }), u.backoff = b, u.errorExists = I, u.extend = B, u.isFunction = y, u.log = C, u.startsWith = f;
1975
+ function f(Q, S) {
1972
1976
  return Q.lastIndexOf(S, 0) === 0;
1973
1977
  }
1974
1978
  function y(Q) {
1975
1979
  return Q == null ? !1 : typeof Q == "function";
1976
1980
  }
1977
- function m(Q, S) {
1981
+ function C(Q, S) {
1978
1982
  if (l.g.console) {
1979
1983
  var P = l.g.console[Q];
1980
1984
  y(P) && P.apply(l.g.console, S);
@@ -1998,18 +2002,18 @@ function Pr() {
1998
2002
  187: (
1999
2003
  /***/
2000
2004
  (function(c) {
2001
- var u = typeof Reflect == "object" ? Reflect : null, l = u && typeof u.apply == "function" ? u.apply : function(g, p, C) {
2002
- return Function.prototype.apply.call(g, p, C);
2003
- }, h;
2004
- u && typeof u.ownKeys == "function" ? h = u.ownKeys : Object.getOwnPropertySymbols ? h = function(g) {
2005
+ var u = typeof Reflect == "object" ? Reflect : null, l = u && typeof u.apply == "function" ? u.apply : function(g, p, m) {
2006
+ return Function.prototype.apply.call(g, p, m);
2007
+ }, f;
2008
+ u && typeof u.ownKeys == "function" ? f = u.ownKeys : Object.getOwnPropertySymbols ? f = function(g) {
2005
2009
  return Object.getOwnPropertyNames(g).concat(Object.getOwnPropertySymbols(g));
2006
- } : h = function(g) {
2010
+ } : f = function(g) {
2007
2011
  return Object.getOwnPropertyNames(g);
2008
2012
  };
2009
2013
  function y(v) {
2010
2014
  console && console.warn && console.warn(v);
2011
2015
  }
2012
- var m = Number.isNaN || function(g) {
2016
+ var C = Number.isNaN || function(g) {
2013
2017
  return g !== g;
2014
2018
  };
2015
2019
  function b() {
@@ -2027,14 +2031,14 @@ function Pr() {
2027
2031
  return I;
2028
2032
  },
2029
2033
  set: function(v) {
2030
- if (typeof v != "number" || v < 0 || m(v))
2034
+ if (typeof v != "number" || v < 0 || C(v))
2031
2035
  throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received ' + v + ".");
2032
2036
  I = v;
2033
2037
  }
2034
2038
  }), b.init = function() {
2035
2039
  (this._events === void 0 || this._events === Object.getPrototypeOf(this)._events) && (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0), this._maxListeners = this._maxListeners || void 0;
2036
2040
  }, b.prototype.setMaxListeners = function(g) {
2037
- if (typeof g != "number" || g < 0 || m(g))
2041
+ if (typeof g != "number" || g < 0 || C(g))
2038
2042
  throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received ' + g + ".");
2039
2043
  return this._maxListeners = g, this;
2040
2044
  };
@@ -2044,7 +2048,7 @@ function Pr() {
2044
2048
  b.prototype.getMaxListeners = function() {
2045
2049
  return Q(this);
2046
2050
  }, b.prototype.emit = function(g) {
2047
- for (var p = [], C = 1; C < arguments.length; C++) p.push(arguments[C]);
2051
+ for (var p = [], m = 1; m < arguments.length; m++) p.push(arguments[m]);
2048
2052
  var d = g === "error", s = this._events;
2049
2053
  if (s !== void 0)
2050
2054
  d = d && s.error === void 0;
@@ -2057,17 +2061,17 @@ function Pr() {
2057
2061
  var A = new Error("Unhandled error." + (a ? " (" + a.message + ")" : ""));
2058
2062
  throw A.context = a, A;
2059
2063
  }
2060
- var f = s[g];
2061
- if (f === void 0)
2064
+ var h = s[g];
2065
+ if (h === void 0)
2062
2066
  return !1;
2063
- if (typeof f == "function")
2064
- l(f, this, p);
2067
+ if (typeof h == "function")
2068
+ l(h, this, p);
2065
2069
  else
2066
- for (var E = f.length, _ = q(f, E), C = 0; C < E; ++C)
2067
- l(_[C], this, p);
2070
+ for (var E = h.length, _ = q(h, E), m = 0; m < E; ++m)
2071
+ l(_[m], this, p);
2068
2072
  return !0;
2069
2073
  };
2070
- function S(v, g, p, C) {
2074
+ function S(v, g, p, m) {
2071
2075
  var d, s, a;
2072
2076
  if (B(p), s = v._events, s === void 0 ? (s = v._events = /* @__PURE__ */ Object.create(null), v._eventsCount = 0) : (s.newListener !== void 0 && (v.emit(
2073
2077
  "newListener",
@@ -2075,7 +2079,7 @@ function Pr() {
2075
2079
  p.listener ? p.listener : p
2076
2080
  ), s = v._events), a = s[g]), a === void 0)
2077
2081
  a = s[g] = p, ++v._eventsCount;
2078
- else if (typeof a == "function" ? a = s[g] = C ? [p, a] : [a, p] : C ? a.unshift(p) : a.push(p), d = Q(v), d > 0 && a.length > d && !a.warned) {
2082
+ else if (typeof a == "function" ? a = s[g] = m ? [p, a] : [a, p] : m ? a.unshift(p) : a.push(p), d = Q(v), d > 0 && a.length > d && !a.warned) {
2079
2083
  a.warned = !0;
2080
2084
  var A = new Error("Possible EventEmitter memory leak detected. " + a.length + " " + String(g) + " listeners added. Use emitter.setMaxListeners() to increase limit");
2081
2085
  A.name = "MaxListenersExceededWarning", A.emitter = v, A.type = g, A.count = a.length, y(A);
@@ -2092,45 +2096,45 @@ function Pr() {
2092
2096
  return this.target.removeListener(this.type, this.wrapFn), this.fired = !0, arguments.length === 0 ? this.listener.call(this.target) : this.listener.apply(this.target, arguments);
2093
2097
  }
2094
2098
  function k(v, g, p) {
2095
- var C = { fired: !1, wrapFn: void 0, target: v, type: g, listener: p }, d = P.bind(C);
2096
- return d.listener = p, C.wrapFn = d, d;
2099
+ var m = { fired: !1, wrapFn: void 0, target: v, type: g, listener: p }, d = P.bind(m);
2100
+ return d.listener = p, m.wrapFn = d, d;
2097
2101
  }
2098
2102
  b.prototype.once = function(g, p) {
2099
2103
  return B(p), this.on(g, k(this, g, p)), this;
2100
2104
  }, b.prototype.prependOnceListener = function(g, p) {
2101
2105
  return B(p), this.prependListener(g, k(this, g, p)), this;
2102
2106
  }, b.prototype.removeListener = function(g, p) {
2103
- var C, d, s, a, A;
2107
+ var m, d, s, a, A;
2104
2108
  if (B(p), d = this._events, d === void 0)
2105
2109
  return this;
2106
- if (C = d[g], C === void 0)
2110
+ if (m = d[g], m === void 0)
2107
2111
  return this;
2108
- if (C === p || C.listener === p)
2109
- --this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : (delete d[g], d.removeListener && this.emit("removeListener", g, C.listener || p));
2110
- else if (typeof C != "function") {
2111
- for (s = -1, a = C.length - 1; a >= 0; a--)
2112
- if (C[a] === p || C[a].listener === p) {
2113
- A = C[a].listener, s = a;
2112
+ if (m === p || m.listener === p)
2113
+ --this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : (delete d[g], d.removeListener && this.emit("removeListener", g, m.listener || p));
2114
+ else if (typeof m != "function") {
2115
+ for (s = -1, a = m.length - 1; a >= 0; a--)
2116
+ if (m[a] === p || m[a].listener === p) {
2117
+ A = m[a].listener, s = a;
2114
2118
  break;
2115
2119
  }
2116
2120
  if (s < 0)
2117
2121
  return this;
2118
- s === 0 ? C.shift() : D(C, s), C.length === 1 && (d[g] = C[0]), d.removeListener !== void 0 && this.emit("removeListener", g, A || p);
2122
+ s === 0 ? m.shift() : D(m, s), m.length === 1 && (d[g] = m[0]), d.removeListener !== void 0 && this.emit("removeListener", g, A || p);
2119
2123
  }
2120
2124
  return this;
2121
2125
  }, b.prototype.off = b.prototype.removeListener, b.prototype.removeAllListeners = function(g) {
2122
- var p, C, d;
2123
- if (C = this._events, C === void 0)
2126
+ var p, m, d;
2127
+ if (m = this._events, m === void 0)
2124
2128
  return this;
2125
- if (C.removeListener === void 0)
2126
- return arguments.length === 0 ? (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0) : C[g] !== void 0 && (--this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : delete C[g]), this;
2129
+ if (m.removeListener === void 0)
2130
+ return arguments.length === 0 ? (this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0) : m[g] !== void 0 && (--this._eventsCount === 0 ? this._events = /* @__PURE__ */ Object.create(null) : delete m[g]), this;
2127
2131
  if (arguments.length === 0) {
2128
- var s = Object.keys(C), a;
2132
+ var s = Object.keys(m), a;
2129
2133
  for (d = 0; d < s.length; ++d)
2130
2134
  a = s[d], a !== "removeListener" && this.removeAllListeners(a);
2131
2135
  return this.removeAllListeners("removeListener"), this._events = /* @__PURE__ */ Object.create(null), this._eventsCount = 0, this;
2132
2136
  }
2133
- if (p = C[g], typeof p == "function")
2137
+ if (p = m[g], typeof p == "function")
2134
2138
  this.removeListener(g, p);
2135
2139
  else if (p !== void 0)
2136
2140
  for (d = p.length - 1; d >= 0; d--)
@@ -2138,11 +2142,11 @@ function Pr() {
2138
2142
  return this;
2139
2143
  };
2140
2144
  function R(v, g, p) {
2141
- var C = v._events;
2142
- if (C === void 0)
2145
+ var m = v._events;
2146
+ if (m === void 0)
2143
2147
  return [];
2144
- var d = C[g];
2145
- return d === void 0 ? [] : typeof d == "function" ? p ? [d.listener || d] : [d] : p ? K(d) : q(d, d.length);
2148
+ var d = m[g];
2149
+ return d === void 0 ? [] : typeof d == "function" ? p ? [d.listener || d] : [d] : p ? G(d) : q(d, d.length);
2146
2150
  }
2147
2151
  b.prototype.listeners = function(g) {
2148
2152
  return R(this, g, !0);
@@ -2163,11 +2167,11 @@ function Pr() {
2163
2167
  return 0;
2164
2168
  }
2165
2169
  b.prototype.eventNames = function() {
2166
- return this._eventsCount > 0 ? h(this._events) : [];
2170
+ return this._eventsCount > 0 ? f(this._events) : [];
2167
2171
  };
2168
2172
  function q(v, g) {
2169
- for (var p = new Array(g), C = 0; C < g; ++C)
2170
- p[C] = v[C];
2173
+ for (var p = new Array(g), m = 0; m < g; ++m)
2174
+ p[m] = v[m];
2171
2175
  return p;
2172
2176
  }
2173
2177
  function D(v, g) {
@@ -2175,15 +2179,15 @@ function Pr() {
2175
2179
  v[g] = v[g + 1];
2176
2180
  v.pop();
2177
2181
  }
2178
- function K(v) {
2182
+ function G(v) {
2179
2183
  for (var g = new Array(v.length), p = 0; p < g.length; ++p)
2180
2184
  g[p] = v[p].listener || v[p];
2181
2185
  return g;
2182
2186
  }
2183
2187
  function z(v, g) {
2184
- return new Promise(function(p, C) {
2188
+ return new Promise(function(p, m) {
2185
2189
  function d(a) {
2186
- v.removeListener(g, s), C(a);
2190
+ v.removeListener(g, s), m(a);
2187
2191
  }
2188
2192
  function s() {
2189
2193
  typeof v.removeListener == "function" && v.removeListener("error", d), p([].slice.call(arguments));
@@ -2194,12 +2198,12 @@ function Pr() {
2194
2198
  function J(v, g, p) {
2195
2199
  typeof v.on == "function" && M(v, "error", g, p);
2196
2200
  }
2197
- function M(v, g, p, C) {
2201
+ function M(v, g, p, m) {
2198
2202
  if (typeof v.on == "function")
2199
- C.once ? v.once(g, p) : v.on(g, p);
2203
+ m.once ? v.once(g, p) : v.on(g, p);
2200
2204
  else if (typeof v.addEventListener == "function")
2201
2205
  v.addEventListener(g, function d(s) {
2202
- C.once && v.removeEventListener(g, d), p(s);
2206
+ m.once && v.removeEventListener(g, d), p(s);
2203
2207
  });
2204
2208
  else
2205
2209
  throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type ' + typeof v);
@@ -2262,8 +2266,8 @@ function $t(e, t) {
2262
2266
  const u = i.subscribe(o);
2263
2267
  u.on("publish", (l) => {
2264
2268
  console.log("[Centrifuge] Publish event received:", l);
2265
- const h = Lr(l);
2266
- h && t(h);
2269
+ const f = Lr(l);
2270
+ f && t(f);
2267
2271
  }), u.on("subscribe", (l) => {
2268
2272
  console.log("[Centrifuge] ✅ Channel subscribed successfully:", o, l);
2269
2273
  }), u.on("error", (l) => {
@@ -2319,8 +2323,8 @@ function Rr(e) {
2319
2323
  }
2320
2324
  function Or(e, t, n = {}) {
2321
2325
  var S, P, k, R;
2322
- const r = [], o = (S = e == null ? void 0 : e.kaspi) == null ? void 0 : S.data, i = ((P = e == null ? void 0 : e.cards_v2) == null ? void 0 : P.data) || [], c = ((R = (k = e == null ? void 0 : e.payment_methods) == null ? void 0 : k.data) == null ? void 0 : R.attributes) || {}, u = ee(c.payment_method_kaspi), l = ee(c.payment_method_card), h = typeof window < "u" && window.self === window.top, m = Lt() === "ios", b = !!(n != null && n.onlyKaspiAvailable), I = !!(n != null && n.disableKaspi);
2323
- return o != null && o.isKaspiOnly && u && !I ? [Ae] : b ? o != null && o.isAvailable && u && !I ? [Ae] : [] : (ee(c.payment_method_apple_pay) && !Ke("apple_pay") && (qe() && h || ze() || m || Dn() === 16) && r.push(Mn), o != null && o.isAvailable && u && !I && r.push(Ae), l && i.filter((L) => !L.isExpired).forEach((L) => {
2326
+ const r = [], o = (S = e == null ? void 0 : e.kaspi) == null ? void 0 : S.data, i = ((P = e == null ? void 0 : e.cards_v2) == null ? void 0 : P.data) || [], c = ((R = (k = e == null ? void 0 : e.payment_methods) == null ? void 0 : k.data) == null ? void 0 : R.attributes) || {}, u = ee(c.payment_method_kaspi), l = ee(c.payment_method_card), f = typeof window < "u" && window.self === window.top, C = Lt() === "ios", b = !!(n != null && n.onlyKaspiAvailable), I = !!(n != null && n.disableKaspi);
2327
+ return o != null && o.isKaspiOnly && u && !I ? [Ae] : b ? o != null && o.isAvailable && u && !I ? [Ae] : [] : (ee(c.payment_method_apple_pay) && !Ke("apple_pay") && (qe() && f || ze() || C || Dn() === 16) && r.push(Mn), o != null && o.isAvailable && u && !I && r.push(Ae), l && i.filter((L) => !L.isExpired).forEach((L) => {
2324
2328
  r.push({
2325
2329
  iconType: Xe(L.attributes.mask),
2326
2330
  type: "card",
@@ -2337,13 +2341,13 @@ function Or(e, t, n = {}) {
2337
2341
  }
2338
2342
  function mt(e, t = {}) {
2339
2343
  var Q, S, P, k;
2340
- const n = (Q = e == null ? void 0 : e.kaspi) == null ? void 0 : Q.data, r = ((S = e == null ? void 0 : e.cards_v2) == null ? void 0 : S.data) || [], o = ((k = (P = e == null ? void 0 : e.payment_methods) == null ? void 0 : P.data) == null ? void 0 : k.attributes) || {}, i = ee(o.payment_method_kaspi), c = ee(o.payment_method_card), u = !!(t != null && t.disableKaspi), l = typeof window < "u" && window.self === window.top, y = Lt() === "ios", m = ee(o.payment_method_apple_pay) && !Ke("apple_pay") && (qe() && l || ze() || y || Dn() === 16), b = ee(o.payment_method_google_pay) && !Ke("google_pay") && !(t != null && t.disableGooglePay) && !qe() && !ze();
2344
+ const n = (Q = e == null ? void 0 : e.kaspi) == null ? void 0 : Q.data, r = ((S = e == null ? void 0 : e.cards_v2) == null ? void 0 : S.data) || [], o = ((k = (P = e == null ? void 0 : e.payment_methods) == null ? void 0 : P.data) == null ? void 0 : k.attributes) || {}, i = ee(o.payment_method_kaspi), c = ee(o.payment_method_card), u = !!(t != null && t.disableKaspi), l = typeof window < "u" && window.self === window.top, y = Lt() === "ios", C = ee(o.payment_method_apple_pay) && !Ke("apple_pay") && (qe() && l || ze() || y || Dn() === 16), b = ee(o.payment_method_google_pay) && !Ke("google_pay") && !(t != null && t.disableGooglePay) && !qe() && !ze();
2341
2345
  if (n != null && n.isKaspiOnly && i && !u || t != null && t.onlyKaspiAvailable && (n != null && n.isAvailable) && i && !u)
2342
2346
  return Ae;
2343
2347
  const I = Rr(e);
2344
2348
  if ((I == null ? void 0 : I.type) === "kaspi_pay" && (n != null && n.isAvailable) && i && !u)
2345
2349
  return Ae;
2346
- if ((I == null ? void 0 : I.type) === "apple_pay" && m) return Mn;
2350
+ if ((I == null ? void 0 : I.type) === "apple_pay" && C) return Mn;
2347
2351
  if ((I == null ? void 0 : I.type) === "google_pay" && b) return xn;
2348
2352
  if ((I == null ? void 0 : I.type) === "new_card" && ee(o.payment_method_new_card))
2349
2353
  return { iconType: "new_card", type: "new_card", label: "Оплата новой картой" };
@@ -2457,7 +2461,7 @@ async function tt(e, t, n, r, o) {
2457
2461
  return i.ok || await ue(i, o), i.json();
2458
2462
  }
2459
2463
  async function tn(e, t, n) {
2460
- var u, l, h, y;
2464
+ var u, l, f, y;
2461
2465
  const r = await fetch(`${e}/api/v2/oauth2/tokens`, {
2462
2466
  method: "POST",
2463
2467
  headers: {
@@ -2472,12 +2476,12 @@ async function tn(e, t, n) {
2472
2476
  })
2473
2477
  });
2474
2478
  r.ok || await ue(r, "Не удалось авторизоваться через track_id");
2475
- const o = await r.json(), i = (o == null ? void 0 : o.access_token) ?? ((l = (u = o == null ? void 0 : o.data) == null ? void 0 : u.attributes) == null ? void 0 : l.access_token), c = (o == null ? void 0 : o.refresh_token) ?? ((y = (h = o == null ? void 0 : o.data) == null ? void 0 : h.attributes) == null ? void 0 : y.refresh_token) ?? null;
2479
+ const o = await r.json(), i = (o == null ? void 0 : o.access_token) ?? ((l = (u = o == null ? void 0 : o.data) == null ? void 0 : u.attributes) == null ? void 0 : l.access_token), c = (o == null ? void 0 : o.refresh_token) ?? ((y = (f = o == null ? void 0 : o.data) == null ? void 0 : f.attributes) == null ? void 0 : y.refresh_token) ?? null;
2476
2480
  if (!i) throw new Error("В ответе отсутствует access_token");
2477
2481
  return { access_token: i, refresh_token: c };
2478
2482
  }
2479
2483
  async function Dr(e, t, n) {
2480
- var u, l, h, y;
2484
+ var u, l, f, y;
2481
2485
  const r = await fetch(`${e}/api/v2/oauth2/tokens`, {
2482
2486
  method: "POST",
2483
2487
  headers: { "Content-Type": "application/json" },
@@ -2488,7 +2492,7 @@ async function Dr(e, t, n) {
2488
2492
  })
2489
2493
  });
2490
2494
  r.ok || await ue(r, "Не удалось обновить токен по refresh_token");
2491
- const o = await r.json(), i = (o == null ? void 0 : o.access_token) ?? ((l = (u = o == null ? void 0 : o.data) == null ? void 0 : u.attributes) == null ? void 0 : l.access_token), c = (o == null ? void 0 : o.refresh_token) ?? ((y = (h = o == null ? void 0 : o.data) == null ? void 0 : h.attributes) == null ? void 0 : y.refresh_token) ?? null;
2495
+ const o = await r.json(), i = (o == null ? void 0 : o.access_token) ?? ((l = (u = o == null ? void 0 : o.data) == null ? void 0 : u.attributes) == null ? void 0 : l.access_token), c = (o == null ? void 0 : o.refresh_token) ?? ((y = (f = o == null ? void 0 : o.data) == null ? void 0 : f.attributes) == null ? void 0 : y.refresh_token) ?? null;
2492
2496
  if (!i) throw new Error("В ответе отсутствует access_token");
2493
2497
  return { access_token: i, refresh_token: c };
2494
2498
  }
@@ -2733,7 +2737,7 @@ function qr() {
2733
2737
  };
2734
2738
  }), t;
2735
2739
  }
2736
- const N = nt("logger", qr), Xn = 50, be = "?", an = /\(error: (.*)\)/, cn = /captureMessage|captureException/;
2740
+ const N = nt("logger", qr), Xn = 50, Ce = "?", an = /\(error: (.*)\)/, cn = /captureMessage|captureException/;
2737
2741
  function zr(...e) {
2738
2742
  const t = e.sort((n, r) => n[0] - r[0]).map((n) => n[1]);
2739
2743
  return (n, r = 0, o = 0) => {
@@ -2743,12 +2747,12 @@ function zr(...e) {
2743
2747
  const l = c[u];
2744
2748
  if (l.length > 1024)
2745
2749
  continue;
2746
- const h = an.test(l) ? l.replace(an, "$1") : l;
2747
- if (!h.match(/\S*Error: /)) {
2750
+ const f = an.test(l) ? l.replace(an, "$1") : l;
2751
+ if (!f.match(/\S*Error: /)) {
2748
2752
  for (const y of t) {
2749
- const m = y(h);
2750
- if (m) {
2751
- i.push(m);
2753
+ const C = y(f);
2754
+ if (C) {
2755
+ i.push(C);
2752
2756
  break;
2753
2757
  }
2754
2758
  }
@@ -2766,7 +2770,7 @@ function Kr(e) {
2766
2770
  return /sentryWrapped/.test(Oe(t).function || "") && t.pop(), t.reverse(), cn.test(Oe(t).function || "") && (t.pop(), cn.test(Oe(t).function || "") && t.pop()), t.slice(0, Xn).map((n) => ({
2767
2771
  ...n,
2768
2772
  filename: n.filename || Oe(t).filename,
2769
- function: n.function || be
2773
+ function: n.function || Ce
2770
2774
  }));
2771
2775
  }
2772
2776
  function Oe(e) {
@@ -2820,7 +2824,7 @@ function Dt(e) {
2820
2824
  function Yr(e) {
2821
2825
  return e === null || Dt(e) || typeof e != "object" && typeof e != "function";
2822
2826
  }
2823
- function Ee(e) {
2827
+ function be(e) {
2824
2828
  return Pe(e, "Object");
2825
2829
  }
2826
2830
  function ot(e) {
@@ -2833,7 +2837,7 @@ function st(e) {
2833
2837
  return !!(e && e.then && typeof e.then == "function");
2834
2838
  }
2835
2839
  function Zr(e) {
2836
- return Ee(e) && "nativeEvent" in e && "preventDefault" in e && "stopPropagation" in e;
2840
+ return be(e) && "nativeEvent" in e && "preventDefault" in e && "stopPropagation" in e;
2837
2841
  }
2838
2842
  function it(e, t) {
2839
2843
  try {
@@ -2854,10 +2858,10 @@ function no(e, t = {}) {
2854
2858
  const r = 5, o = [];
2855
2859
  let i = 0, c = 0;
2856
2860
  const u = " > ", l = u.length;
2857
- let h;
2858
- const y = Array.isArray(t) ? t : t.keyAttrs, m = !Array.isArray(t) && t.maxStringLength || to;
2859
- for (; n && i++ < r && (h = ro(n, y), !(h === "html" || i > 1 && c + o.length * l + h.length >= m)); )
2860
- o.push(h), c += h.length, n = n.parentNode;
2861
+ let f;
2862
+ const y = Array.isArray(t) ? t : t.keyAttrs, C = !Array.isArray(t) && t.maxStringLength || to;
2863
+ for (; n && i++ < r && (f = ro(n, y), !(f === "html" || i > 1 && c + o.length * l + f.length >= C)); )
2864
+ o.push(f), c += f.length, n = n.parentNode;
2861
2865
  return o.reverse().join(u);
2862
2866
  } catch {
2863
2867
  return "<unknown>";
@@ -2986,7 +2990,7 @@ function Et(e, t) {
2986
2990
  return e;
2987
2991
  }
2988
2992
  function so(e) {
2989
- if (!Ee(e))
2993
+ if (!be(e))
2990
2994
  return !1;
2991
2995
  try {
2992
2996
  const t = Object.getPrototypeOf(e).constructor.name;
@@ -3011,8 +3015,8 @@ const Wn = io();
3011
3015
  const { performance: e } = j;
3012
3016
  if (!e || !e.now)
3013
3017
  return;
3014
- const t = 3600 * 1e3, n = e.now(), r = Date.now(), o = e.timeOrigin ? Math.abs(e.timeOrigin + n - r) : t, i = o < t, c = e.timing && e.timing.navigationStart, l = typeof c == "number" ? Math.abs(c + n - r) : t, h = l < t;
3015
- return i || h ? o <= l ? e.timeOrigin : c : r;
3018
+ const t = 3600 * 1e3, n = e.now(), r = Date.now(), o = e.timeOrigin ? Math.abs(e.timeOrigin + n - r) : t, i = o < t, c = e.timing && e.timing.navigationStart, l = typeof c == "number" ? Math.abs(c + n - r) : t, f = l < t;
3019
+ return i || f ? o <= l ? e.timeOrigin : c : r;
3016
3020
  })();
3017
3021
  function te() {
3018
3022
  const e = j, t = e.crypto || e.msCrypto;
@@ -3075,18 +3079,18 @@ var re;
3075
3079
  e[e.REJECTED = r] = "REJECTED";
3076
3080
  })(re || (re = {}));
3077
3081
  function he(e) {
3078
- return new G((t) => {
3082
+ return new W((t) => {
3079
3083
  t(e);
3080
3084
  });
3081
3085
  }
3082
3086
  function We(e) {
3083
- return new G((t, n) => {
3087
+ return new W((t, n) => {
3084
3088
  n(e);
3085
3089
  });
3086
3090
  }
3087
- class G {
3091
+ class W {
3088
3092
  constructor(t) {
3089
- G.prototype.__init.call(this), G.prototype.__init2.call(this), G.prototype.__init3.call(this), G.prototype.__init4.call(this), this._state = re.PENDING, this._handlers = [];
3093
+ W.prototype.__init.call(this), W.prototype.__init2.call(this), W.prototype.__init3.call(this), W.prototype.__init4.call(this), this._state = re.PENDING, this._handlers = [];
3090
3094
  try {
3091
3095
  t(this._resolve, this._reject);
3092
3096
  } catch (n) {
@@ -3095,7 +3099,7 @@ class G {
3095
3099
  }
3096
3100
  /** JSDoc */
3097
3101
  then(t, n) {
3098
- return new G((r, o) => {
3102
+ return new W((r, o) => {
3099
3103
  this._handlers.push([
3100
3104
  !1,
3101
3105
  (i) => {
@@ -3127,7 +3131,7 @@ class G {
3127
3131
  }
3128
3132
  /** JSDoc */
3129
3133
  finally(t) {
3130
- return new G((n, r) => {
3134
+ return new W((n, r) => {
3131
3135
  let o, i;
3132
3136
  return this.then(
3133
3137
  (c) => {
@@ -3410,8 +3414,8 @@ class Mt {
3410
3414
  const n = typeof t == "function" ? t(this) : t, [r, o] = n instanceof ce ? (
3411
3415
  // eslint-disable-next-line deprecation/deprecation
3412
3416
  [n.getScopeData(), n.getRequestSession()]
3413
- ) : Ee(n) ? [t, t.requestSession] : [], { tags: i, extra: c, user: u, contexts: l, level: h, fingerprint: y = [], propagationContext: m } = r || {};
3414
- return this._tags = { ...this._tags, ...i }, this._extra = { ...this._extra, ...c }, this._contexts = { ...this._contexts, ...l }, u && Object.keys(u).length && (this._user = u), h && (this._level = h), y.length && (this._fingerprint = y), m && (this._propagationContext = m), o && (this._requestSession = o), this;
3417
+ ) : be(n) ? [t, t.requestSession] : [], { tags: i, extra: c, user: u, contexts: l, level: f, fingerprint: y = [], propagationContext: C } = r || {};
3418
+ return this._tags = { ...this._tags, ...i }, this._extra = { ...this._extra, ...c }, this._contexts = { ...this._contexts, ...l }, u && Object.keys(u).length && (this._user = u), f && (this._level = f), y.length && (this._fingerprint = y), C && (this._propagationContext = C), o && (this._requestSession = o), this;
3415
3419
  }
3416
3420
  /**
3417
3421
  * @inheritDoc
@@ -3624,19 +3628,19 @@ class fo {
3624
3628
  return this._stack.length <= 1 ? !1 : !!this._stack.pop();
3625
3629
  }
3626
3630
  }
3627
- function ve() {
3631
+ function Ee() {
3628
3632
  const e = Ot(), t = Nt(e);
3629
3633
  return t.stack = t.stack || new fo(lo(), Ao());
3630
3634
  }
3631
3635
  function ho(e) {
3632
- return ve().withScope(e);
3636
+ return Ee().withScope(e);
3633
3637
  }
3634
3638
  function po(e, t) {
3635
- const n = ve();
3639
+ const n = Ee();
3636
3640
  return n.withScope(() => (n.getStackTop().scope = e, t(e)));
3637
3641
  }
3638
3642
  function yn(e) {
3639
- return ve().withScope(() => e(ve().getIsolationScope()));
3643
+ return Ee().withScope(() => e(Ee().getIsolationScope()));
3640
3644
  }
3641
3645
  function go() {
3642
3646
  return {
@@ -3644,8 +3648,8 @@ function go() {
3644
3648
  withScope: ho,
3645
3649
  withSetScope: po,
3646
3650
  withSetIsolationScope: (e, t) => yn(t),
3647
- getCurrentScope: () => ve().getScope(),
3648
- getIsolationScope: () => ve().getIsolationScope()
3651
+ getCurrentScope: () => Ee().getScope(),
3652
+ getIsolationScope: () => Ee().getIsolationScope()
3649
3653
  };
3650
3654
  }
3651
3655
  function Yn(e) {
@@ -3813,10 +3817,10 @@ function jo(e) {
3813
3817
  const o = n.spanContext().traceState, i = o && o.get("sentry.dsc"), c = i && wo(i);
3814
3818
  if (c)
3815
3819
  return c;
3816
- const u = er(e.spanContext().traceId, t), l = Ut(n), h = l.data || {}, y = h[Io];
3820
+ const u = er(e.spanContext().traceId, t), l = Ut(n), f = l.data || {}, y = f[Io];
3817
3821
  y != null && (u.sample_rate = `${y}`);
3818
- const m = h[vo], b = l.description;
3819
- return m !== "url" && b && (u.transaction = b), Fo() && (u.sampled = String(Do(n))), t.emit("createDsc", u, n), u;
3822
+ const C = f[vo], b = l.description;
3823
+ return C !== "url" && b && (u.transaction = b), Fo() && (u.sampled = String(Do(n))), t.emit("createDsc", u, n), u;
3820
3824
  }
3821
3825
  function Jo(e) {
3822
3826
  if (typeof e == "boolean")
@@ -3849,13 +3853,13 @@ function Ko(e) {
3849
3853
  return;
3850
3854
  }
3851
3855
  const [n, r, o = "", i = "", c = "", u = ""] = t.slice(1);
3852
- let l = "", h = u;
3853
- const y = h.split("/");
3854
- if (y.length > 1 && (l = y.slice(0, -1).join("/"), h = y.pop()), h) {
3855
- const m = h.match(/^\d+/);
3856
- m && (h = m[0]);
3856
+ let l = "", f = u;
3857
+ const y = f.split("/");
3858
+ if (y.length > 1 && (l = y.slice(0, -1).join("/"), f = y.pop()), f) {
3859
+ const C = f.match(/^\d+/);
3860
+ C && (f = C[0]);
3857
3861
  }
3858
- return tr({ host: i, pass: o, path: l, projectId: h, port: c, protocol: n, publicKey: r });
3862
+ return tr({ host: i, pass: o, path: l, projectId: f, port: c, protocol: n, publicKey: r });
3859
3863
  }
3860
3864
  function tr(e) {
3861
3865
  return {
@@ -3927,25 +3931,25 @@ function St(e, t, n = 1 / 0, r = 1 / 0, o = Yo()) {
3927
3931
  return u.replace("object ", "");
3928
3932
  if (i(t))
3929
3933
  return "[Circular ~]";
3930
- const h = t;
3931
- if (h && typeof h.toJSON == "function")
3934
+ const f = t;
3935
+ if (f && typeof f.toJSON == "function")
3932
3936
  try {
3933
- const I = h.toJSON();
3937
+ const I = f.toJSON();
3934
3938
  return St("", I, l - 1, r, o);
3935
3939
  } catch {
3936
3940
  }
3937
3941
  const y = Array.isArray(t) ? [] : {};
3938
- let m = 0;
3942
+ let C = 0;
3939
3943
  const b = Kn(t);
3940
3944
  for (const I in b) {
3941
3945
  if (!Object.prototype.hasOwnProperty.call(b, I))
3942
3946
  continue;
3943
- if (m >= r) {
3947
+ if (C >= r) {
3944
3948
  y[I] = "[MaxProperties ~]";
3945
3949
  break;
3946
3950
  }
3947
3951
  const B = b[I];
3948
- y[I] = St(I, B, l - 1, r, o), m++;
3952
+ y[I] = St(I, B, l - 1, r, o), C++;
3949
3953
  }
3950
3954
  return c(t), y;
3951
3955
  }
@@ -4109,7 +4113,7 @@ function us(e, t, n, r) {
4109
4113
  return delete e.sdkProcessingMetadata, we(c, [[{ type: i }, e]]);
4110
4114
  }
4111
4115
  function Qt(e, t, n, r = 0) {
4112
- return new G((o, i) => {
4116
+ return new W((o, i) => {
4113
4117
  const c = e[r];
4114
4118
  if (t === null || typeof c != "function")
4115
4119
  o(t);
@@ -4133,9 +4137,9 @@ function ls(e) {
4133
4137
  else {
4134
4138
  const c = e(o);
4135
4139
  for (let u = c.length - 1; u >= 0; u--) {
4136
- const l = c[u], h = l && l.filename, y = t[o];
4137
- if (h && y) {
4138
- r[h] = y, Ne[o] = [h, y];
4140
+ const l = c[u], f = l && l.filename, y = t[o];
4141
+ if (f && y) {
4142
+ r[f] = y, Ne[o] = [f, y];
4139
4143
  break;
4140
4144
  }
4141
4145
  }
@@ -4156,14 +4160,14 @@ function Sn(e, t) {
4156
4160
  level: c,
4157
4161
  sdkProcessingMetadata: u,
4158
4162
  breadcrumbs: l,
4159
- fingerprint: h,
4163
+ fingerprint: f,
4160
4164
  eventProcessors: y,
4161
- attachments: m,
4165
+ attachments: C,
4162
4166
  propagationContext: b,
4163
4167
  transactionName: I,
4164
4168
  span: B
4165
4169
  } = t;
4166
- Me(e, "extra", n), Me(e, "tags", r), Me(e, "user", o), Me(e, "contexts", i), e.sdkProcessingMetadata = ct(e.sdkProcessingMetadata, u, 2), c && (e.level = c), I && (e.transactionName = I), B && (e.span = B), l.length && (e.breadcrumbs = [...e.breadcrumbs, ...l]), h.length && (e.fingerprint = [...e.fingerprint, ...h]), y.length && (e.eventProcessors = [...e.eventProcessors, ...y]), m.length && (e.attachments = [...e.attachments, ...m]), e.propagationContext = { ...e.propagationContext, ...b };
4170
+ Me(e, "extra", n), Me(e, "tags", r), Me(e, "user", o), Me(e, "contexts", i), e.sdkProcessingMetadata = ct(e.sdkProcessingMetadata, u, 2), c && (e.level = c), I && (e.transactionName = I), B && (e.span = B), l.length && (e.breadcrumbs = [...e.breadcrumbs, ...l]), f.length && (e.fingerprint = [...e.fingerprint, ...f]), y.length && (e.eventProcessors = [...e.eventProcessors, ...y]), C.length && (e.attachments = [...e.attachments, ...C]), e.propagationContext = { ...e.propagationContext, ...b };
4167
4171
  }
4168
4172
  function Me(e, t, n) {
4169
4173
  e[t] = ct(e[t], n, 1);
@@ -4171,12 +4175,12 @@ function Me(e, t, n) {
4171
4175
  function ds(e, t) {
4172
4176
  const { extra: n, tags: r, user: o, contexts: i, level: c, transactionName: u } = t, l = V(n);
4173
4177
  l && Object.keys(l).length && (e.extra = { ...l, ...e.extra });
4174
- const h = V(r);
4175
- h && Object.keys(h).length && (e.tags = { ...h, ...e.tags });
4178
+ const f = V(r);
4179
+ f && Object.keys(f).length && (e.tags = { ...f, ...e.tags });
4176
4180
  const y = V(o);
4177
4181
  y && Object.keys(y).length && (e.user = { ...y, ...e.user });
4178
- const m = V(i);
4179
- m && Object.keys(m).length && (e.contexts = { ...m, ...e.contexts }), c && (e.level = c), u && e.type !== "transaction" && (e.transaction = u);
4182
+ const C = V(i);
4183
+ C && Object.keys(C).length && (e.contexts = { ...C, ...e.contexts }), c && (e.level = c), u && e.type !== "transaction" && (e.transaction = u);
4180
4184
  }
4181
4185
  function fs(e, t) {
4182
4186
  const n = [...e.breadcrumbs || [], ...t];
@@ -4207,11 +4211,11 @@ function ys(e, t, n, r, o, i) {
4207
4211
  ...t,
4208
4212
  event_id: t.event_id || n.event_id || te(),
4209
4213
  timestamp: t.timestamp || at()
4210
- }, h = n.integrations || e.integrations.map((S) => S.name);
4211
- ms(l, e), Es(l, h), o && o.emit("applyFrameMetadata", t), t.type === void 0 && Cs(l, e.stackParser);
4214
+ }, f = n.integrations || e.integrations.map((S) => S.name);
4215
+ ms(l, e), Es(l, f), o && o.emit("applyFrameMetadata", t), t.type === void 0 && Cs(l, e.stackParser);
4212
4216
  const y = Is(r, n.captureContext);
4213
4217
  n.mechanism && _e(l, n.mechanism);
4214
- const m = o ? o.getEventProcessors() : [], b = mo().getScopeData();
4218
+ const C = o ? o.getEventProcessors() : [], b = mo().getScopeData();
4215
4219
  if (i) {
4216
4220
  const S = i.getScopeData();
4217
4221
  Sn(b, S);
@@ -4223,7 +4227,7 @@ function ys(e, t, n, r, o, i) {
4223
4227
  const I = [...n.attachments || [], ...b.attachments];
4224
4228
  I.length && (n.attachments = I), As(l, b);
4225
4229
  const B = [
4226
- ...m,
4230
+ ...C,
4227
4231
  // Run scope event processors _after_ all other processors
4228
4232
  ...b.eventProcessors
4229
4233
  ];
@@ -4583,8 +4587,8 @@ class Ts {
4583
4587
  if (i) {
4584
4588
  o = !0;
4585
4589
  for (const l of i) {
4586
- const h = l.mechanism;
4587
- if (h && h.handled === !1) {
4590
+ const f = l.mechanism;
4591
+ if (f && f.handled === !1) {
4588
4592
  r = !0;
4589
4593
  break;
4590
4594
  }
@@ -4607,7 +4611,7 @@ class Ts {
4607
4611
  * `false` otherwise
4608
4612
  */
4609
4613
  _isClientDoneProcessing(t) {
4610
- return new G((n) => {
4614
+ return new W((n) => {
4611
4615
  let r = 0;
4612
4616
  const o = 1, i = setInterval(() => {
4613
4617
  this._numProcessing == 0 ? (clearInterval(i), n(!0)) : (r += o, t && r >= t && (clearInterval(i), n(!1)));
@@ -4676,7 +4680,7 @@ class Ts {
4676
4680
  * @returns A SyncPromise that resolves with the event or rejects in case event was/will not be send.
4677
4681
  */
4678
4682
  _processEvent(t, n, r) {
4679
- const o = this.getOptions(), { sampleRate: i } = o, c = ir(t), u = sr(t), l = t.type || "error", h = `before send for type \`${l}\``, y = typeof i > "u" ? void 0 : Jo(i);
4683
+ const o = this.getOptions(), { sampleRate: i } = o, c = ir(t), u = sr(t), l = t.type || "error", f = `before send for type \`${l}\``, y = typeof i > "u" ? void 0 : Jo(i);
4680
4684
  if (u && typeof y == "number" && Math.random() > y)
4681
4685
  return this.recordDroppedEvent("sample_rate", "error", t), We(
4682
4686
  new Y(
@@ -4684,21 +4688,21 @@ class Ts {
4684
4688
  "log"
4685
4689
  )
4686
4690
  );
4687
- const m = l === "replay_event" ? "replay" : l, I = (t.sdkProcessingMetadata || {}).capturedSpanIsolationScope;
4691
+ const C = l === "replay_event" ? "replay" : l, I = (t.sdkProcessingMetadata || {}).capturedSpanIsolationScope;
4688
4692
  return this._prepareEvent(t, n, r, I).then((B) => {
4689
4693
  if (B === null)
4690
- throw this.recordDroppedEvent("event_processor", m, t), new Y("An event processor returned `null`, will not send event.", "log");
4694
+ throw this.recordDroppedEvent("event_processor", C, t), new Y("An event processor returned `null`, will not send event.", "log");
4691
4695
  if (n.data && n.data.__sentry__ === !0)
4692
4696
  return B;
4693
4697
  const S = Rs(this, o, B, n);
4694
- return Ls(S, h);
4698
+ return Ls(S, f);
4695
4699
  }).then((B) => {
4696
4700
  if (B === null) {
4697
- if (this.recordDroppedEvent("before_send", m, t), c) {
4701
+ if (this.recordDroppedEvent("before_send", C, t), c) {
4698
4702
  const k = 1 + (t.spans || []).length;
4699
4703
  this.recordDroppedEvent("before_send", "span", k);
4700
4704
  }
4701
- throw new Y(`${h} returned \`null\`, will not send event.`, "log");
4705
+ throw new Y(`${f} returned \`null\`, will not send event.`, "log");
4702
4706
  }
4703
4707
  const Q = r && r.getSession();
4704
4708
  if (!c && Q && this._updateSessionFromEvent(Q, B), c) {
@@ -4776,7 +4780,7 @@ function Ls(e, t) {
4776
4780
  if (st(e))
4777
4781
  return e.then(
4778
4782
  (r) => {
4779
- if (!Ee(r) && r !== null)
4783
+ if (!be(r) && r !== null)
4780
4784
  throw new Y(n);
4781
4785
  return r;
4782
4786
  },
@@ -4784,7 +4788,7 @@ function Ls(e, t) {
4784
4788
  throw new Y(`${t} rejected with ${r}`);
4785
4789
  }
4786
4790
  );
4787
- if (!Ee(e) && e !== null)
4791
+ if (!be(e) && e !== null)
4788
4792
  throw new Y(n);
4789
4793
  return e;
4790
4794
  }
@@ -4796,8 +4800,8 @@ function Rs(e, t, n, r) {
4796
4800
  if (n.spans && c) {
4797
4801
  const u = [];
4798
4802
  for (const l of n.spans) {
4799
- const h = c(l);
4800
- h ? u.push(h) : (Uo(), e.recordDroppedEvent("before_send", "span"));
4803
+ const f = c(l);
4804
+ f ? u.push(f) : (Uo(), e.recordDroppedEvent("before_send", "span"));
4801
4805
  }
4802
4806
  n.spans = u;
4803
4807
  }
@@ -4839,16 +4843,16 @@ function Os(e) {
4839
4843
  ), u;
4840
4844
  }
4841
4845
  function i(c) {
4842
- return new G((u, l) => {
4843
- let h = t.length;
4844
- if (!h)
4846
+ return new W((u, l) => {
4847
+ let f = t.length;
4848
+ if (!f)
4845
4849
  return u(!0);
4846
4850
  const y = setTimeout(() => {
4847
4851
  c && c > 0 && u(!1);
4848
4852
  }, c);
4849
- t.forEach((m) => {
4850
- he(m).then(() => {
4851
- --h || (clearTimeout(y), u(!0));
4853
+ t.forEach((C) => {
4854
+ he(C).then(() => {
4855
+ --f || (clearTimeout(y), u(!0));
4852
4856
  }, l);
4853
4857
  });
4854
4858
  });
@@ -4879,11 +4883,11 @@ function Us(e, { statusCode: t, headers: n }, r = Date.now()) {
4879
4883
  }, i = n && n["x-sentry-rate-limits"], c = n && n["retry-after"];
4880
4884
  if (i)
4881
4885
  for (const u of i.trim().split(",")) {
4882
- const [l, h, , , y] = u.split(":", 5), m = parseInt(l, 10), b = (isNaN(m) ? 60 : m) * 1e3;
4883
- if (!h)
4886
+ const [l, f, , , y] = u.split(":", 5), C = parseInt(l, 10), b = (isNaN(C) ? 60 : C) * 1e3;
4887
+ if (!f)
4884
4888
  o.all = r + b;
4885
4889
  else
4886
- for (const I of h.split(";"))
4890
+ for (const I of f.split(";"))
4887
4891
  I === "metric_bucket" ? (!y || y.split(";").includes("custom")) && (o[I] = r + b) : o[I] = r + b;
4888
4892
  }
4889
4893
  else c ? o.all = r + Ds(c, r) : t === 429 && (o.all = r + 60 * 1e3);
@@ -4897,32 +4901,32 @@ function Xs(e, t, n = Os(
4897
4901
  const o = (c) => n.drain(c);
4898
4902
  function i(c) {
4899
4903
  const u = [];
4900
- if (vn(c, (m, b) => {
4904
+ if (vn(c, (C, b) => {
4901
4905
  const I = In(b);
4902
4906
  if (xs(r, I)) {
4903
- const B = Pn(m, b);
4907
+ const B = Pn(C, b);
4904
4908
  e.recordDroppedEvent("ratelimit_backoff", I, B);
4905
4909
  } else
4906
- u.push(m);
4910
+ u.push(C);
4907
4911
  }), u.length === 0)
4908
4912
  return he({});
4909
- const l = we(c[0], u), h = (m) => {
4913
+ const l = we(c[0], u), f = (C) => {
4910
4914
  vn(l, (b, I) => {
4911
4915
  const B = Pn(b, I);
4912
- e.recordDroppedEvent(m, In(I), B);
4916
+ e.recordDroppedEvent(C, In(I), B);
4913
4917
  });
4914
4918
  }, y = () => t({ body: ns(l) }).then(
4915
- (m) => (m.statusCode !== void 0 && (m.statusCode < 200 || m.statusCode >= 300) && U && N.warn(`Sentry responded with status code ${m.statusCode} to sent event.`), r = Us(r, m), m),
4916
- (m) => {
4917
- throw h("network_error"), m;
4919
+ (C) => (C.statusCode !== void 0 && (C.statusCode < 200 || C.statusCode >= 300) && U && N.warn(`Sentry responded with status code ${C.statusCode} to sent event.`), r = Us(r, C), C),
4920
+ (C) => {
4921
+ throw f("network_error"), C;
4918
4922
  }
4919
4923
  );
4920
4924
  return n.add(y).then(
4921
- (m) => m,
4922
- (m) => {
4923
- if (m instanceof Y)
4924
- return U && N.error("Skipped sending event because buffer is full."), h("queue_overflow"), he({});
4925
- throw m;
4925
+ (C) => C,
4926
+ (C) => {
4927
+ if (C instanceof Y)
4928
+ return U && N.error("Skipped sending event because buffer is full."), f("queue_overflow"), he({});
4929
+ throw C;
4926
4930
  }
4927
4931
  );
4928
4932
  }
@@ -4983,8 +4987,8 @@ function zs(e, t, n, r) {
4983
4987
  extra: u
4984
4988
  };
4985
4989
  if (n) {
4986
- const h = Ft(e, n);
4987
- h.length && (l.exception.values[0].stacktrace = { frames: h });
4990
+ const f = Ft(e, n);
4991
+ f.length && (l.exception.values[0].stacktrace = { frames: f });
4988
4992
  }
4989
4993
  return l;
4990
4994
  }
@@ -5043,7 +5047,7 @@ function ei(e, t, n, r, o) {
5043
5047
  }
5044
5048
  return "code" in c && (i.tags = { ...i.tags, "DOMException.code": `${c.code}` }), i;
5045
5049
  }
5046
- return jn(t) ? pt(e, t) : Ee(t) || ot(t) ? (i = zs(e, t, n, o), _e(i, {
5050
+ return jn(t) ? pt(e, t) : be(t) || ot(t) ? (i = zs(e, t, n, o), _e(i, {
5047
5051
  synthetic: !0
5048
5052
  }), i) : (i = kt(e, t, n, r), dn(i, `${t}`), _e(i, {
5049
5053
  synthetic: !0
@@ -5227,7 +5231,7 @@ const li = 30, Ai = 50;
5227
5231
  function Pt(e, t, n, r) {
5228
5232
  const o = {
5229
5233
  filename: e,
5230
- function: t === "<anonymous>" ? be : t,
5234
+ function: t === "<anonymous>" ? Ce : t,
5231
5235
  in_app: !0
5232
5236
  // All browser frames are considered in_app
5233
5237
  };
@@ -5237,7 +5241,7 @@ const di = /^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i, fi = /^\s*at (?:(.+?\)(?: \
5237
5241
  const t = di.exec(e);
5238
5242
  if (t) {
5239
5243
  const [, r, o, i] = t;
5240
- return Pt(r, be, +o, +i);
5244
+ return Pt(r, Ce, +o, +i);
5241
5245
  }
5242
5246
  const n = fi.exec(e);
5243
5247
  if (n) {
@@ -5245,7 +5249,7 @@ const di = /^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i, fi = /^\s*at (?:(.+?\)(?: \
5245
5249
  const c = hi.exec(n[2]);
5246
5250
  c && (n[2] = c[1], n[3] = c[2], n[4] = c[3]);
5247
5251
  }
5248
- const [o, i] = ur(n[1] || be, n[2]);
5252
+ const [o, i] = ur(n[1] || Ce, n[2]);
5249
5253
  return Pt(i, o, n[3] ? +n[3] : void 0, n[4] ? +n[4] : void 0);
5250
5254
  }
5251
5255
  }, gi = [li, pi], yi = /^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i, mi = /(\S+) line (\d+)(?: > eval line \d+)* > eval/i, Ci = (e) => {
@@ -5255,13 +5259,13 @@ const di = /^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i, fi = /^\s*at (?:(.+?\)(?: \
5255
5259
  const i = mi.exec(t[3]);
5256
5260
  i && (t[1] = t[1] || "eval", t[3] = i[1], t[4] = i[2], t[5] = "");
5257
5261
  }
5258
- let r = t[3], o = t[1] || be;
5262
+ let r = t[3], o = t[1] || Ce;
5259
5263
  return [o, r] = ur(o, r), Pt(r, o, t[4] ? +t[4] : void 0, t[5] ? +t[5] : void 0);
5260
5264
  }
5261
5265
  }, bi = [Ai, Ci], Ei = [gi, bi], vi = zr(...Ei), ur = (e, t) => {
5262
5266
  const n = e.indexOf("safari-extension") !== -1, r = e.indexOf("safari-web-extension") !== -1;
5263
5267
  return n || r ? [
5264
- e.indexOf("@") !== -1 ? e.split("@")[0] : be,
5268
+ e.indexOf("@") !== -1 ? e.split("@")[0] : Ce,
5265
5269
  n ? `safari-extension:${t}` : `safari-web-extension:${t}`
5266
5270
  ] : [e, t];
5267
5271
  }, Ii = "https://bbed26c9265c425abb56ff9d3728183e@sentry.chocodev.kz/302";
@@ -5272,7 +5276,7 @@ function Bi(e) {
5272
5276
  transport: ui,
5273
5277
  stackParser: vi,
5274
5278
  integrations: [],
5275
- release: "1.1.48",
5279
+ release: "1.1.50",
5276
5280
  environment: e.environment || "production"
5277
5281
  }), n = new ce();
5278
5282
  n.setClient(t), n.setTags(e), t.init(), wt = n;
@@ -5470,7 +5474,7 @@ function Di(e, t, n, r) {
5470
5474
  }
5471
5475
  function Mi(e, t, n, r, o) {
5472
5476
  if (!e) return "";
5473
- const i = new Date(e.expires_at), c = isNaN(i.getTime()) ? "" : `${String(i.getDate()).padStart(2, "0")}.${String(i.getMonth() + 1).padStart(2, "0")}`, u = c ? r("couponUntil", { date: c }) : "", l = Number(e.reward_amount), h = Number.isFinite(l) && l > 0 ? $(l, "ru", o) : null;
5477
+ const i = new Date(e.expires_at), c = isNaN(i.getTime()) ? "" : `${String(i.getDate()).padStart(2, "0")}.${String(i.getMonth() + 1).padStart(2, "0")}`, u = c ? r("couponUntil", { date: c }) : "", l = Number(e.reward_amount), f = Number.isFinite(l) && l > 0 ? $(l, "ru", o) : null;
5474
5478
  return `
5475
5479
  <div class="choco-widget-balance-toggle${n ? " choco-widget-balance-toggle--disabled" : ""}" data-action="toggle-coupon">
5476
5480
  <div class="choco-widget-balance-info">
@@ -5479,11 +5483,11 @@ function Mi(e, t, n, r, o) {
5479
5483
  </div>
5480
5484
  </div>
5481
5485
  <div class="choco-widget-balance-label-wrapper">
5482
- ${h ? `
5486
+ ${f ? `
5483
5487
  <div class="choco-widget-balance-icon">
5484
5488
  ${Xt}
5485
5489
  </div>
5486
- <div class="choco-widget-balance-amount">${h}</div>
5490
+ <div class="choco-widget-balance-amount">${f}</div>
5487
5491
  ` : ""}
5488
5492
  <label class="choco-widget-toggle">
5489
5493
  <input type="checkbox" ${t && !n ? "checked" : ""} ${n ? "disabled" : ""} />
@@ -5495,7 +5499,7 @@ function Mi(e, t, n, r, o) {
5495
5499
  }
5496
5500
  function xi(e, t, n, r, o, i, c, u, l) {
5497
5501
  if (!e && !n && !o) return "";
5498
- const h = e ? `
5502
+ const f = e ? `
5499
5503
  <div class="choco-widget-balance-toggle" data-action="toggle-balance">
5500
5504
  <div class="choco-widget-balance-info">
5501
5505
  <div class="choco-widget-balance-text">
@@ -5517,7 +5521,7 @@ function xi(e, t, n, r, o, i, c, u, l) {
5517
5521
  return `
5518
5522
  <div class="choco-widget-balance-section">
5519
5523
  ${Mi(o, i, c, u, l)}
5520
- ${h}
5524
+ ${f}
5521
5525
  ${Di(n, r, u, l)}
5522
5526
  </div>
5523
5527
  `;
@@ -5544,9 +5548,9 @@ function Fi(e) {
5544
5548
  selectedMethod: c,
5545
5549
  balanceFormatted: u,
5546
5550
  useBalance: l,
5547
- bonuses: h,
5551
+ bonuses: f,
5548
5552
  useBonuses: y,
5549
- coupon: m,
5553
+ coupon: C,
5550
5554
  useCoupon: b,
5551
5555
  couponDisabled: I,
5552
5556
  cashbackFormatted: B,
@@ -5557,7 +5561,7 @@ function Fi(e) {
5557
5561
  freedomAmountFormatted: R,
5558
5562
  t: L,
5559
5563
  currency: q
5560
- } = e, D = (o == null ? void 0 : o.label) ?? L("selectMethod"), K = Ye(o), z = lr(i, c), J = xi(u, l, h, y, m, b, I, L, q), M = Ui(B, L), v = (c == null ? void 0 : c.type) === "google_pay", g = (c == null ? void 0 : c.type) === "apple_pay", p = v || g;
5564
+ } = e, D = (o == null ? void 0 : o.label) ?? L("selectMethod"), G = Ye(o), z = lr(i, c), J = xi(u, l, f, y, C, b, I, L, q), M = Ui(B, L), v = (c == null ? void 0 : c.type) === "google_pay", g = (c == null ? void 0 : c.type) === "apple_pay", p = v || g;
5561
5565
  return `
5562
5566
  <div class="choco-widget-bottom-bar" role="region" aria-label="${L("paymentMethod")}">
5563
5567
  ${J}
@@ -5582,7 +5586,7 @@ function Fi(e) {
5582
5586
  >
5583
5587
  <div class="choco-widget-method-label">${L("paymentMethod")}</div>
5584
5588
  <div class="choco-widget-method-value">
5585
- <div class="choco-widget-method-icon-wrapper ${o == null ? void 0 : o.type}" aria-hidden="true">${K}</div>
5589
+ <div class="choco-widget-method-icon-wrapper ${o == null ? void 0 : o.type}" aria-hidden="true">${G}</div>
5586
5590
  <div class="choco-widget-method-details">
5587
5591
  <div class="choco-widget-method-name ${o == null ? void 0 : o.type}">${D}</div>
5588
5592
  <div class="choco-widget-method-chevron">
@@ -5718,10 +5722,10 @@ function qi(e) {
5718
5722
  Ar(e) && (e.container.style.setProperty("--choco-widget-accent-color", e.config.color), e.container.innerHTML = Xi());
5719
5723
  }
5720
5724
  function zi(e) {
5721
- var y, m, b, I, B;
5725
+ var y, C, b, I, B;
5722
5726
  if (e._destroyed || !Ar(e)) return;
5723
5727
  e.container.style.setProperty("--choco-widget-accent-color", e.config.color), e.container.classList.remove("choco-one-click-widget--visible");
5724
- const t = e.getAvailablePaymentMethods(), n = (y = e.checkoutContext) == null ? void 0 : y.data, r = e.config.currency || "KZT", o = (I = (b = (m = n == null ? void 0 : n.balance) == null ? void 0 : m.data) == null ? void 0 : b.money) == null ? void 0 : I[r], i = !e.config.disableUseBalance && o > 0 ? $(o, e.config.locale, e.config.currency) : null, c = (B = n == null ? void 0 : n.cashback) == null ? void 0 : B.data, u = (c == null ? void 0 : c.cashbackAmount) > 0 ? $(c.cashbackAmount, e.config.locale, e.config.currency) : null, l = e._getPayableAmount(), h = l < e.config.amount;
5728
+ const t = e.getAvailablePaymentMethods(), n = (y = e.checkoutContext) == null ? void 0 : y.data, r = e.config.currency || "KZT", o = (I = (b = (C = n == null ? void 0 : n.balance) == null ? void 0 : C.data) == null ? void 0 : b.money) == null ? void 0 : I[r], i = !e.config.disableUseBalance && o > 0 ? $(o, e.config.locale, e.config.currency) : null, c = (B = n == null ? void 0 : n.cashback) == null ? void 0 : B.data, u = (c == null ? void 0 : c.cashbackAmount) > 0 ? $(c.cashbackAmount, e.config.locale, e.config.currency) : null, l = e._getPayableAmount(), f = l < e.config.amount;
5725
5729
  e.container.innerHTML = Fi({
5726
5730
  amountFormatted: $(l, e.config.locale, e.config.currency),
5727
5731
  originalAmountFormatted: $(
@@ -5729,7 +5733,7 @@ function zi(e) {
5729
5733
  e.config.locale,
5730
5734
  e.config.currency
5731
5735
  ),
5732
- showOriginalAmount: h,
5736
+ showOriginalAmount: f,
5733
5737
  paymentMethod: e.selectedPaymentMethod,
5734
5738
  methods: t,
5735
5739
  selectedMethod: e.selectedPaymentMethod,
@@ -5799,8 +5803,8 @@ function dr(e) {
5799
5803
  t && e.selectedPaymentMethod && (t.className = `choco-widget-payment-method ${e.selectedPaymentMethod.type}`), n && e.selectedPaymentMethod && (n.className = `choco-widget-method-name ${e.selectedPaymentMethod.type}`, n.textContent = e.selectedPaymentMethod.label), r && e.selectedPaymentMethod && (r.className = `choco-widget-method-icon-wrapper ${e.selectedPaymentMethod.type}`, r.innerHTML = ji(e.selectedPaymentMethod)), fr(e);
5800
5804
  }
5801
5805
  function Je(e) {
5802
- var m, b, I, B, Q, S;
5803
- const t = (m = e.container) == null ? void 0 : m.querySelector(".choco-widget-pay-button"), n = (b = e.container) == null ? void 0 : b.querySelector(
5806
+ var C, b, I, B, Q, S;
5807
+ const t = (C = e.container) == null ? void 0 : C.querySelector(".choco-widget-pay-button"), n = (b = e.container) == null ? void 0 : b.querySelector(
5804
5808
  ".choco-widget-google-pay-amount"
5805
5809
  ), r = (I = e.container) == null ? void 0 : I.querySelector(
5806
5810
  ".choco-widget-google-pay-amount-label"
@@ -5810,7 +5814,7 @@ function Je(e) {
5810
5814
  ), i = (Q = e.container) == null ? void 0 : Q.querySelector(
5811
5815
  ".choco-widget-google-pay-amount-value-number"
5812
5816
  );
5813
- const c = e._getPayableAmount(), u = $(c, e.config.locale, e.config.currency), l = c < e.config.amount, h = $(
5817
+ const c = e._getPayableAmount(), u = $(c, e.config.locale, e.config.currency), l = c < e.config.amount, f = $(
5814
5818
  e.config.amount,
5815
5819
  e.config.locale,
5816
5820
  e.config.currency
@@ -5826,11 +5830,11 @@ function Je(e) {
5826
5830
  }
5827
5831
  !o && n && (o = document.createElement("div"), o.className = "choco-widget-google-pay-amount-value", o.innerHTML = `${e.t("instead")} <span class="choco-widget-google-pay-amount-value-number"></span>`, n.appendChild(o), i = o.querySelector(
5828
5832
  ".choco-widget-google-pay-amount-value-number"
5829
- )), i ? i.textContent = h : o && (o.textContent = `${e.t("instead")} ${h}`);
5833
+ )), i ? i.textContent = f : o && (o.textContent = `${e.t("instead")} ${f}`);
5830
5834
  }
5831
5835
  function fr(e) {
5832
- var l, h, y, m, b, I, B, Q, S, P;
5833
- const t = ((l = e.selectedPaymentMethod) == null ? void 0 : l.type) === "google_pay", n = ((h = e.selectedPaymentMethod) == null ? void 0 : h.type) === "apple_pay", r = t || n, o = (y = e.container) == null ? void 0 : y.querySelector(".choco-widget-pay-button"), i = (m = e.container) == null ? void 0 : m.querySelector(
5836
+ var l, f, y, C, b, I, B, Q, S, P;
5837
+ const t = ((l = e.selectedPaymentMethod) == null ? void 0 : l.type) === "google_pay", n = ((f = e.selectedPaymentMethod) == null ? void 0 : f.type) === "apple_pay", r = t || n, o = (y = e.container) == null ? void 0 : y.querySelector(".choco-widget-pay-button"), i = (C = e.container) == null ? void 0 : C.querySelector(
5834
5838
  ".choco-widget-google-pay-amount"
5835
5839
  ), c = (b = e.container) == null ? void 0 : b.querySelector(".choco-widget-google-pay-row"), u = (I = e.container) == null ? void 0 : I.querySelector(".choco-widget-apple-pay-row");
5836
5840
  if (o == null || o.classList.toggle("choco-widget-pay-button--hidden", r), i == null || i.classList.toggle(
@@ -5860,7 +5864,7 @@ function fr(e) {
5860
5864
  Je(e), ie(e);
5861
5865
  }
5862
5866
  async function Ki(e) {
5863
- var c, u, l, h, y;
5867
+ var c, u, l, f, y;
5864
5868
  const t = (c = e.container) == null ? void 0 : c.querySelector(
5865
5869
  '[data-action="google-pay-button-slot"]'
5866
5870
  );
@@ -5873,7 +5877,7 @@ async function Ki(e) {
5873
5877
  return;
5874
5878
  }
5875
5879
  if (n !== e._googlePayButtonRenderVersion) return;
5876
- if (!((y = (h = (l = window.google) == null ? void 0 : l.payments) == null ? void 0 : h.api) != null && y.PaymentsClient)) {
5880
+ if (!((y = (f = (l = window.google) == null ? void 0 : l.payments) == null ? void 0 : f.api) != null && y.PaymentsClient)) {
5877
5881
  e.config.onError({ attributes: { message: e.t("errorGooglePayUnsupported") } });
5878
5882
  return;
5879
5883
  }
@@ -5886,8 +5890,8 @@ async function Ki(e) {
5886
5890
  buttonLocale: e.config.locale || "ru",
5887
5891
  buttonSizeMode: "fill"
5888
5892
  });
5889
- i.classList.add("choco-widget-google-pay-button"), i.style.setProperty("width", "100%", "important"), i.style.setProperty("height", "52px", "important"), i.style.setProperty("min-height", "52px", "important"), i.style.setProperty("border-radius", "12px", "important"), i.style.setProperty("font-size", "16px", "important"), i.style.setProperty("font-weight", "bold", "important"), i.querySelectorAll("*").forEach((m) => {
5890
- m.style.setProperty("border-radius", "12px", "important"), m.style.setProperty("font-weight", "bold", "important"), m.style.setProperty("font-size", "16px", "important");
5893
+ i.classList.add("choco-widget-google-pay-button"), i.style.setProperty("width", "100%", "important"), i.style.setProperty("height", "52px", "important"), i.style.setProperty("min-height", "52px", "important"), i.style.setProperty("border-radius", "12px", "important"), i.style.setProperty("font-size", "16px", "important"), i.style.setProperty("font-weight", "bold", "important"), i.querySelectorAll("*").forEach((C) => {
5894
+ C.style.setProperty("border-radius", "12px", "important"), C.style.setProperty("font-weight", "bold", "important"), C.style.setProperty("font-size", "16px", "important");
5891
5895
  }), t.appendChild(i), ie(e);
5892
5896
  }
5893
5897
  function Gi(e) {
@@ -5931,10 +5935,10 @@ function Ln(e) {
5931
5935
  function pe(e) {
5932
5936
  e.loading = !0, ie(e);
5933
5937
  }
5934
- function W(e) {
5935
- var m, b, I, B, Q, S, P, k;
5938
+ function K(e) {
5939
+ var C, b, I, B, Q, S, P, k;
5936
5940
  e.loading = !1;
5937
- const t = (m = e.container) == null ? void 0 : m.querySelector(".choco-widget-payment-method"), n = (b = e.container) == null ? void 0 : b.querySelector(".choco-widget-pay-button"), r = (I = e.container) == null ? void 0 : I.querySelector(
5941
+ const t = (C = e.container) == null ? void 0 : C.querySelector(".choco-widget-payment-method"), n = (b = e.container) == null ? void 0 : b.querySelector(".choco-widget-pay-button"), r = (I = e.container) == null ? void 0 : I.querySelector(
5938
5942
  ".choco-widget-google-pay-button-slot button"
5939
5943
  ), o = (B = e.container) == null ? void 0 : B.querySelector(
5940
5944
  ".choco-widget-apple-pay-button-slot button"
@@ -5942,8 +5946,8 @@ function W(e) {
5942
5946
  ".choco-widget-google-pay-amount"
5943
5947
  ), c = (S = e.container) == null ? void 0 : S.querySelector(".choco-widget-google-pay-row"), u = (P = e.container) == null ? void 0 : P.querySelector(".choco-widget-apple-pay-row"), l = (k = e.container) == null ? void 0 : k.querySelector(
5944
5948
  ".choco-widget-balance-section"
5945
- ), h = e._isInteractionBlocked(), y = e.paymentMethodDisabled || h;
5946
- t && (t.disabled = y), n && (n.disabled = h, n.classList.remove("choco-widget-pay-button--loading")), r && (r.disabled = h), o && (o.disabled = h), i == null || i.classList.toggle("choco-widget-wallet-blocked", h), i == null || i.setAttribute("aria-disabled", String(h)), c == null || c.classList.toggle("choco-widget-wallet-blocked", h), c == null || c.setAttribute("aria-disabled", String(h)), u == null || u.classList.toggle("choco-widget-wallet-blocked", h), u == null || u.setAttribute("aria-disabled", String(h)), l == null || l.classList.remove("disabled");
5949
+ ), f = e._isInteractionBlocked(), y = e.paymentMethodDisabled || f;
5950
+ t && (t.disabled = y), n && (n.disabled = f, n.classList.remove("choco-widget-pay-button--loading")), r && (r.disabled = f), o && (o.disabled = f), i == null || i.classList.toggle("choco-widget-wallet-blocked", f), i == null || i.setAttribute("aria-disabled", String(f)), c == null || c.classList.toggle("choco-widget-wallet-blocked", f), c == null || c.setAttribute("aria-disabled", String(f)), u == null || u.classList.toggle("choco-widget-wallet-blocked", f), u == null || u.setAttribute("aria-disabled", String(f)), l == null || l.classList.remove("disabled");
5947
5951
  }
5948
5952
  function ie(e) {
5949
5953
  var b, I, B, Q, S, P, k, R, L;
@@ -5953,10 +5957,10 @@ function ie(e) {
5953
5957
  ".choco-widget-apple-pay-button-slot button"
5954
5958
  ), c = (P = e.container) == null ? void 0 : P.querySelector(
5955
5959
  ".choco-widget-google-pay-amount"
5956
- ), u = (k = e.container) == null ? void 0 : k.querySelector(".choco-widget-google-pay-row"), l = (R = e.container) == null ? void 0 : R.querySelector(".choco-widget-apple-pay-row"), h = (L = e.container) == null ? void 0 : L.querySelector(
5960
+ ), u = (k = e.container) == null ? void 0 : k.querySelector(".choco-widget-google-pay-row"), l = (R = e.container) == null ? void 0 : R.querySelector(".choco-widget-apple-pay-row"), f = (L = e.container) == null ? void 0 : L.querySelector(
5957
5961
  ".choco-widget-balance-section"
5958
- ), y = e._isInteractionBlocked(), m = e.paymentMethodDisabled || y;
5959
- h == null || h.classList.toggle("disabled", y), t && (t.disabled = m), n && (n.disabled = y, n.classList.toggle("choco-widget-pay-button--loading", e.loading)), r && (r.disabled = y), o && (o.disabled = y), i && (i.disabled = y), c == null || c.classList.toggle("choco-widget-wallet-blocked", y), c == null || c.setAttribute("aria-disabled", String(y)), u == null || u.classList.toggle("choco-widget-wallet-blocked", y), u == null || u.setAttribute("aria-disabled", String(y)), l == null || l.classList.toggle("choco-widget-wallet-blocked", y), l == null || l.setAttribute("aria-disabled", String(y));
5962
+ ), y = e._isInteractionBlocked(), C = e.paymentMethodDisabled || y;
5963
+ f == null || f.classList.toggle("disabled", y), t && (t.disabled = C), n && (n.disabled = y, n.classList.toggle("choco-widget-pay-button--loading", e.loading)), r && (r.disabled = y), o && (o.disabled = y), i && (i.disabled = y), c == null || c.classList.toggle("choco-widget-wallet-blocked", y), c == null || c.setAttribute("aria-disabled", String(y)), u == null || u.classList.toggle("choco-widget-wallet-blocked", y), u == null || u.setAttribute("aria-disabled", String(y)), l == null || l.classList.toggle("choco-widget-wallet-blocked", y), l == null || l.setAttribute("aria-disabled", String(y));
5960
5964
  }
5961
5965
  function hr(e) {
5962
5966
  var n;
@@ -5977,7 +5981,7 @@ function ke(e) {
5977
5981
  var l;
5978
5982
  const t = (l = e.container) == null ? void 0 : l.querySelector('[data-sheet="payment"]');
5979
5983
  if (!t) return;
5980
- const n = t.querySelector(".choco-widget-sheet-title"), r = t.querySelector('[data-action="close-sheet"]'), o = t.querySelector('[data-action="edit-sheet"]'), i = t.querySelector('[data-action="previous-sheet"]'), u = e.getAvailablePaymentMethods().some((h) => h.type === "card");
5984
+ const n = t.querySelector(".choco-widget-sheet-title"), r = t.querySelector('[data-action="close-sheet"]'), o = t.querySelector('[data-action="edit-sheet"]'), i = t.querySelector('[data-action="previous-sheet"]'), u = e.getAvailablePaymentMethods().some((f) => f.type === "card");
5981
5985
  e.isPaymentSheetEditMode ? (t.classList.add("choco-widget-payment-sheet--edit"), n && (n.textContent = e.t("editCards")), r && (r.style.display = "none"), o && (o.style.display = "none"), i && (i.style.display = "")) : (t.classList.remove("choco-widget-payment-sheet--edit"), t.classList.toggle("choco-widget-payment-sheet--no-cards", !u), n && (n.textContent = e.t("paymentMethods")), r && (r.style.display = ""), o && (o.style.display = u ? "" : "none"), i && (i.style.display = "none"));
5982
5986
  }
5983
5987
  function gt(e) {
@@ -5987,7 +5991,7 @@ function gt(e) {
5987
5991
  );
5988
5992
  t && n && (n.src = e.addCardActionUrl, t.classList.add("choco-widget-payment-sheet--open"), t.style.display = "flex", t.setAttribute("aria-hidden", "false"), e.isAddCardViewOpen = !0, Wi(e));
5989
5993
  }
5990
- function Ie(e) {
5994
+ function ve(e) {
5991
5995
  var r, o;
5992
5996
  const t = (r = e.container) == null ? void 0 : r.querySelector('[data-sheet="add-card"]'), n = (o = e.container) == null ? void 0 : o.querySelector(
5993
5997
  "#choco-widget-add-card-iframe"
@@ -6082,14 +6086,14 @@ function Rn(e, t) {
6082
6086
  function de(e) {
6083
6087
  e._orderStatusPollingId && (clearInterval(e._orderStatusPollingId), e._orderStatusPollingId = null);
6084
6088
  }
6085
- function Be(e, t) {
6089
+ function Ie(e, t) {
6086
6090
  de(e), e._orderStatusResolved = !1;
6087
6091
  const n = 6e3, r = 5;
6088
6092
  let o = 0;
6089
6093
  const i = async () => {
6090
6094
  if (!e._orderStatusResolved) {
6091
6095
  if (o >= r) {
6092
- de(e), W(e), e.config.onError({
6096
+ de(e), K(e), e.config.onError({
6093
6097
  attributes: { message: e.t("errorNoServerResponseRetry") }
6094
6098
  });
6095
6099
  return;
@@ -6123,7 +6127,7 @@ function Ht() {
6123
6127
  return typeof document > "u" ? !1 : document.hidden || document.visibilityState === "hidden";
6124
6128
  }
6125
6129
  function gr(e, t) {
6126
- W(e), e.config.onSuccess(t);
6130
+ K(e), e.config.onSuccess(t);
6127
6131
  }
6128
6132
  function yt(e) {
6129
6133
  if (!e._pendingSuccessPayload || Ht()) return;
@@ -6132,7 +6136,7 @@ function yt(e) {
6132
6136
  }
6133
6137
  function yr(e, t) {
6134
6138
  var o, i;
6135
- e.isAddCardViewOpen && Ie(e);
6139
+ e.isAddCardViewOpen && ve(e);
6136
6140
  const n = t.attributes || ((o = t.data) == null ? void 0 : o.attributes) || {}, r = { id: t.id || ((i = t.data) == null ? void 0 : i.id), attributes: n };
6137
6141
  if (Ht()) {
6138
6142
  e._pendingSuccessPayload = r;
@@ -6142,7 +6146,7 @@ function yr(e, t) {
6142
6146
  }
6143
6147
  function mr(e, t) {
6144
6148
  var r, o;
6145
- e.isAddCardViewOpen && Ie(e), W(e);
6149
+ e.isAddCardViewOpen && ve(e), K(e);
6146
6150
  const n = t.attributes || ((r = t.data) == null ? void 0 : r.attributes) || {};
6147
6151
  e.config.onError({ id: t.id || ((o = t.data) == null ? void 0 : o.id), attributes: n });
6148
6152
  }
@@ -6150,16 +6154,16 @@ function $i(e, t) {
6150
6154
  var i, c, u;
6151
6155
  const n = t.attributes || ((i = t.data) == null ? void 0 : i.attributes) || {}, r = n.action_link || n.action_url, o = n.action_url_type || n.action_type || "redirect";
6152
6156
  if (!r) {
6153
- console.error(e.t("errorActionUrlMissing")), e.waitingForNewCardAction && (e.waitingForNewCardAction = !1, W(e), e.config.onError({ attributes: { message: e.t("errorNoServerResponse") } }));
6157
+ console.error(e.t("errorActionUrlMissing")), e.waitingForNewCardAction && (e.waitingForNewCardAction = !1, K(e), e.config.onError({ attributes: { message: e.t("errorNoServerResponse") } }));
6154
6158
  return;
6155
6159
  }
6156
6160
  if (e.waitingForNewCardAction && (e.waitingForNewCardAction = !1, e._clearNewCardActionTimeout()), o === "inner") {
6157
- e.addCardActionUrl = r, W(e), e._showAddCardView();
6161
+ e.addCardActionUrl = r, K(e), e._showAddCardView();
6158
6162
  return;
6159
6163
  }
6160
6164
  if (((c = e.selectedPaymentMethod) == null ? void 0 : c.type) === "kaspi_pay") {
6161
6165
  const l = t.id || ((u = t.data) == null ? void 0 : u.id);
6162
- if (l && !e._orderStatusResolved && !e._orderStatusPollingId && Be(e, String(l)), typeof e.config.onKaspiLink == "function") {
6166
+ if (l && !e._orderStatusResolved && !e._orderStatusPollingId && Ie(e, String(l)), typeof e.config.onKaspiLink == "function") {
6163
6167
  e.config.onKaspiLink({
6164
6168
  action_link: r,
6165
6169
  action_url: r,
@@ -6192,9 +6196,9 @@ async function ea(e) {
6192
6196
  );
6193
6197
  await On(e);
6194
6198
  const l = (u == null ? void 0 : u.id) ?? ((n = u == null ? void 0 : u.data) == null ? void 0 : n.id);
6195
- return l && Be(e, String(l)), u;
6199
+ return l && Ie(e, String(l)), u;
6196
6200
  } catch (u) {
6197
- throw W(e), se(u, { paymentMethod: "balance" }), e.config.onError({
6201
+ throw K(e), se(u, { paymentMethod: "balance" }), e.config.onError({
6198
6202
  attributes: { message: e._resolveErrorMessage(u) }
6199
6203
  }), u;
6200
6204
  }
@@ -6222,19 +6226,19 @@ async function ea(e) {
6222
6226
  );
6223
6227
  await On(e);
6224
6228
  const l = (u == null ? void 0 : u.id) ?? ((r = u == null ? void 0 : u.data) == null ? void 0 : r.id);
6225
- if (l && Be(e, String(l)), ((o = e.selectedPaymentMethod) == null ? void 0 : o.type) === "kaspi_pay") {
6226
- const h = (u == null ? void 0 : u.attributes) || ((i = u == null ? void 0 : u.data) == null ? void 0 : i.attributes) || {}, y = h.action_link || h.action_url, m = h.action_url_type || h.action_type || "redirect";
6229
+ if (l && Ie(e, String(l)), ((o = e.selectedPaymentMethod) == null ? void 0 : o.type) === "kaspi_pay") {
6230
+ const f = (u == null ? void 0 : u.attributes) || ((i = u == null ? void 0 : u.data) == null ? void 0 : i.attributes) || {}, y = f.action_link || f.action_url, C = f.action_url_type || f.action_type || "redirect";
6227
6231
  if (y)
6228
6232
  return typeof e.config.onKaspiLink == "function" ? (e.config.onKaspiLink({
6229
6233
  action_link: y,
6230
6234
  action_url: y,
6231
- action_type: m,
6235
+ action_type: C,
6232
6236
  event: u
6233
6237
  }), u) : (window.location.href = y, u);
6234
6238
  }
6235
6239
  return u;
6236
6240
  } catch (u) {
6237
- throw W(e), se(u, { paymentMethod: ((c = e.selectedPaymentMethod) == null ? void 0 : c.type) || "card" }), e.config.onError({ message: e._resolveErrorMessage(u) }), u;
6241
+ throw K(e), se(u, { paymentMethod: ((c = e.selectedPaymentMethod) == null ? void 0 : c.type) || "card" }), e.config.onError({ message: e._resolveErrorMessage(u) }), u;
6238
6242
  }
6239
6243
  }
6240
6244
  async function On(e) {
@@ -6260,25 +6264,20 @@ async function ta(e, t) {
6260
6264
  t
6261
6265
  );
6262
6266
  } catch (n) {
6263
- e.waitingForNewCardAction = !1, e._clearNewCardActionTimeout(), W(e), se(n, { paymentMethod: "new_card" }), e.config.onError({
6267
+ e.waitingForNewCardAction = !1, e._clearNewCardActionTimeout(), K(e), se(n, { paymentMethod: "new_card" }), e.config.onError({
6264
6268
  attributes: { message: e._resolveErrorMessage(n) }
6265
6269
  }), console.error("New card payment error:", n);
6266
6270
  }
6267
6271
  }
6268
- let me = null;
6272
+ let Be = null;
6269
6273
  async function na(e, t) {
6270
6274
  const n = window.ApplePaySession;
6271
6275
  if (!n || !n.canMakePayments()) {
6272
6276
  e.config.onError({ attributes: { message: e.t("errorApplePayUnsupported") } });
6273
6277
  return;
6274
6278
  }
6275
- if (me) {
6276
- try {
6277
- me.abort();
6278
- } catch {
6279
- }
6280
- me = null;
6281
- }
6279
+ if (Be) return;
6280
+ pe(e);
6282
6281
  const r = {
6283
6282
  countryCode: e.config.currency === "GEL" ? "GE" : "KZ",
6284
6283
  currencyCode: e.config.currency,
@@ -6290,57 +6289,65 @@ async function na(e, t) {
6290
6289
  type: "final"
6291
6290
  }
6292
6291
  }, o = new n(3, r);
6293
- me = o, o.onvalidatemerchant = async (i) => {
6294
- var c, u;
6292
+ Be = o;
6293
+ let i = !1;
6294
+ o.onvalidatemerchant = async (c) => {
6295
+ var u, l;
6295
6296
  try {
6296
- let l;
6297
+ let f;
6297
6298
  try {
6298
- l = await rn(
6299
+ f = await rn(
6299
6300
  e.apiUrl,
6300
6301
  e._getApiConfig(),
6301
- i.validationURL
6302
+ c.validationURL
6302
6303
  );
6303
- } catch (m) {
6304
- if (m.status === 401)
6305
- await e._obtainTokenByRefreshOrTrackId(), l = await rn(
6304
+ } catch (b) {
6305
+ if (b.status === 401)
6306
+ await e._obtainTokenByRefreshOrTrackId(), f = await rn(
6306
6307
  e.apiUrl,
6307
6308
  e._getApiConfig(),
6308
- i.validationURL
6309
+ c.validationURL
6309
6310
  );
6310
6311
  else
6311
- throw m;
6312
+ throw b;
6312
6313
  }
6313
- const h = ((u = (c = l == null ? void 0 : l.data) == null ? void 0 : c.attributes) == null ? void 0 : u.session) || l, y = JSON.parse(atob(h));
6314
- o.completeMerchantValidation(y);
6315
- } catch (l) {
6316
- console.error("Apple Pay session error:", l), se(l, { paymentMethod: "apple_pay", phase: "merchant_validation" }), o.abort(), e.config.onError({ attributes: { message: e.t("errorApplePayInit") } });
6314
+ const y = ((l = (u = f == null ? void 0 : f.data) == null ? void 0 : u.attributes) == null ? void 0 : l.session) || f, C = JSON.parse(atob(y));
6315
+ o.completeMerchantValidation(C), i = !0;
6316
+ } catch (f) {
6317
+ console.error("Apple Pay session error:", f), se(f, { paymentMethod: "apple_pay", phase: "merchant_validation" }), K(e), o.abort(), e.config.onError({ attributes: { message: e.t("errorApplePayInit") } });
6317
6318
  }
6318
- }, o.onpaymentauthorized = async (i) => {
6319
- var c;
6319
+ }, o.onpaymentauthorized = async (c) => {
6320
+ var u;
6320
6321
  try {
6321
- if (pe(e), typeof e.config.onBeforeCheckout == "function") {
6322
- const h = await e.config.onBeforeCheckout();
6323
- h && typeof h == "object" && Object.assign(e.config, h);
6322
+ if (typeof e.config.onBeforeCheckout == "function") {
6323
+ const y = await e.config.onBeforeCheckout();
6324
+ y && typeof y == "object" && Object.assign(e.config, y);
6324
6325
  }
6325
- const u = await Hr(
6326
+ const l = await Hr(
6326
6327
  e.apiUrl,
6327
6328
  e._getApiConfig(),
6328
6329
  e.deviceId,
6329
- i.payment,
6330
+ c.payment,
6330
6331
  t
6331
6332
  );
6332
- o.completePayment(n.STATUS_SUCCESS), me = null;
6333
- const l = (u == null ? void 0 : u.id) ?? ((c = u == null ? void 0 : u.data) == null ? void 0 : c.id);
6334
- l && Be(e, String(l));
6335
- } catch (u) {
6336
- console.error("Apple Pay payment error:", u), se(u, { paymentMethod: "apple_pay", phase: "payment_authorized" }), o.completePayment(n.STATUS_FAILURE), W(e), e.config.onError({
6333
+ o.completePayment(n.STATUS_SUCCESS), Be = null;
6334
+ const f = (l == null ? void 0 : l.id) ?? ((u = l == null ? void 0 : l.data) == null ? void 0 : u.id);
6335
+ f && !e._orderStatusResolved && Ie(e, String(f));
6336
+ } catch (l) {
6337
+ console.error("Apple Pay payment error:", l), se(l, { paymentMethod: "apple_pay", phase: "payment_authorized" }), o.completePayment(n.STATUS_FAILURE), Be = null, K(e), e.config.onError({
6337
6338
  attributes: {
6338
- message: e._resolveErrorMessage(u, "errorApplePayPayment")
6339
+ message: e._resolveErrorMessage(l, "errorApplePayPayment")
6339
6340
  }
6340
6341
  });
6341
6342
  }
6342
6343
  }, o.oncancel = () => {
6343
- me = null, e.config.onCancel();
6344
+ if (Be = null, K(e), !i) {
6345
+ e.config.onError({
6346
+ attributes: { message: e.t("errorApplePayInterrupted") }
6347
+ });
6348
+ return;
6349
+ }
6350
+ e.config.onCancel();
6344
6351
  }, o.begin();
6345
6352
  }
6346
6353
  async function ra(e, t) {
@@ -6357,7 +6364,7 @@ async function ra(e, t) {
6357
6364
  });
6358
6365
  return;
6359
6366
  }
6360
- const l = e.config.environment === "production", h = (o == null ? void 0 : o.merchant_name) || "Choco", y = o == null ? void 0 : o.google_merchant_id;
6367
+ const l = e.config.environment === "production", f = (o == null ? void 0 : o.merchant_name) || "Choco", y = o == null ? void 0 : o.google_merchant_id;
6361
6368
  if (l && !y) {
6362
6369
  e.config.onError({
6363
6370
  attributes: { message: e.t("errorGooglePaySettingsUnavailable") }
@@ -6368,7 +6375,7 @@ async function ra(e, t) {
6368
6375
  await oa(e, t, { gateway: c, gatewayMerchantId: u });
6369
6376
  return;
6370
6377
  }
6371
- const m = Number(e._getCheckoutAmount()).toFixed(2);
6378
+ const C = Number(e._getCheckoutAmount()).toFixed(2);
6372
6379
  try {
6373
6380
  await e._loadGooglePaySdk();
6374
6381
  } catch (D) {
@@ -6400,11 +6407,11 @@ async function ra(e, t) {
6400
6407
  transactionInfo: {
6401
6408
  totalPriceStatus: "FINAL",
6402
6409
  totalPriceLabel: "Итого",
6403
- totalPrice: m,
6410
+ totalPrice: C,
6404
6411
  currencyCode: e.config.currency,
6405
6412
  countryCode: e.config.currency === "GEL" ? "GE" : "KZ"
6406
6413
  },
6407
- merchantInfo: l ? { merchantId: y, merchantName: h } : { merchantName: h }
6414
+ merchantInfo: l ? { merchantId: y, merchantName: f } : { merchantName: f }
6408
6415
  }, Q = new b.payments.api.PaymentsClient({
6409
6416
  environment: l ? "PRODUCTION" : "TEST"
6410
6417
  });
@@ -6419,7 +6426,7 @@ async function ra(e, t) {
6419
6426
  return;
6420
6427
  }
6421
6428
  pe(e);
6422
- const K = await Q.loadPaymentData(B), z = (L = (R = K == null ? void 0 : K.paymentMethodData) == null ? void 0 : R.tokenizationData) == null ? void 0 : L.token;
6429
+ const G = await Q.loadPaymentData(B), z = (L = (R = G == null ? void 0 : G.paymentMethodData) == null ? void 0 : R.tokenizationData) == null ? void 0 : L.token;
6423
6430
  if (!z) throw new Error(e.t("errorGooglePayPayment"));
6424
6431
  const J = JSON.parse(z), M = await Fn(
6425
6432
  e.apiUrl,
@@ -6428,9 +6435,9 @@ async function ra(e, t) {
6428
6435
  J,
6429
6436
  t
6430
6437
  ), v = (M == null ? void 0 : M.id) ?? ((q = M == null ? void 0 : M.data) == null ? void 0 : q.id);
6431
- v && Be(e, String(v));
6438
+ v && Ie(e, String(v));
6432
6439
  } catch (D) {
6433
- W(e), D.statusCode === "CANCELED" ? e.config.onCancel() : (se(D, { paymentMethod: "google_pay" }), e.config.onError({
6440
+ K(e), D.statusCode === "CANCELED" ? e.config.onCancel() : (se(D, { paymentMethod: "google_pay" }), e.config.onError({
6434
6441
  attributes: {
6435
6442
  message: e._resolveErrorMessage(D, "errorGooglePayPayment")
6436
6443
  }
@@ -6456,9 +6463,9 @@ async function oa(e, t, n) {
6456
6463
  i,
6457
6464
  t
6458
6465
  ), u = (c == null ? void 0 : c.id) ?? ((r = c == null ? void 0 : c.data) == null ? void 0 : r.id);
6459
- u && Be(e, String(u));
6466
+ u && Ie(e, String(u));
6460
6467
  } catch (o) {
6461
- W(e), o.statusCode === "CANCELED" ? e.config.onCancel() : (se(o, { paymentMethod: "google_pay_native" }), e.config.onError({
6468
+ K(e), o.statusCode === "CANCELED" ? e.config.onCancel() : (se(o, { paymentMethod: "google_pay_native" }), e.config.onError({
6462
6469
  attributes: {
6463
6470
  message: e._resolveErrorMessage(o, "errorGooglePayPayment")
6464
6471
  }
@@ -6466,17 +6473,17 @@ async function oa(e, t, n) {
6466
6473
  }
6467
6474
  }
6468
6475
  function sa(e) {
6469
- var c, u, l, h, y, m, b, I, B, Q, S, P;
6476
+ var c, u, l, f, y, C, b, I, B, Q, S, P;
6470
6477
  const t = e.container;
6471
6478
  (c = t.querySelector('[data-action="freedom-card"]')) == null || c.addEventListener("click", () => {
6472
6479
  e.config.onFreedomLink && e.config.onFreedomLink();
6473
- }), (u = t.querySelector('[data-action="pay"]')) == null || u.addEventListener("click", () => e.handlePayment()), (l = t.querySelector('[data-action="change-method"]')) == null || l.addEventListener("click", () => hr(e)), t.querySelectorAll('[data-action="close"]').forEach((k) => k.addEventListener("click", () => e.close())), (h = t.querySelector('[data-action="close-sheet"]')) == null || h.addEventListener("click", () => {
6480
+ }), (u = t.querySelector('[data-action="pay"]')) == null || u.addEventListener("click", () => e.handlePayment()), (l = t.querySelector('[data-action="change-method"]')) == null || l.addEventListener("click", () => hr(e)), t.querySelectorAll('[data-action="close"]').forEach((k) => k.addEventListener("click", () => e.close())), (f = t.querySelector('[data-action="close-sheet"]')) == null || f.addEventListener("click", () => {
6474
6481
  e._pendingDeleteMethod ? Ve(e) : ae(e);
6475
6482
  }), (y = t.querySelector('[data-action="edit-sheet"]')) == null || y.addEventListener("click", () => {
6476
6483
  e.isPaymentSheetEditMode = !0, Qe(e), ke(e);
6477
- }), (m = t.querySelector('[data-action="previous-sheet"]')) == null || m.addEventListener("click", () => {
6484
+ }), (C = t.querySelector('[data-action="previous-sheet"]')) == null || C.addEventListener("click", () => {
6478
6485
  e.isPaymentSheetEditMode = !1, Qe(e), ke(e);
6479
- }), (b = t.querySelector('[data-action="close-add-card"]')) == null || b.addEventListener("click", () => Ie(e)), (I = t.querySelector('[data-action="confirm-delete-cancel"]')) == null || I.addEventListener("click", () => Ve(e)), (B = t.querySelector('[data-action="confirm-delete-submit"]')) == null || B.addEventListener("click", () => {
6486
+ }), (b = t.querySelector('[data-action="close-add-card"]')) == null || b.addEventListener("click", () => ve(e)), (I = t.querySelector('[data-action="confirm-delete-cancel"]')) == null || I.addEventListener("click", () => Ve(e)), (B = t.querySelector('[data-action="confirm-delete-submit"]')) == null || B.addEventListener("click", () => {
6480
6487
  if (e._pendingDeleteMethod) {
6481
6488
  const k = e._pendingDeleteMethod;
6482
6489
  Tt(e, !0), Zi(e, k).then(() => ae(e)).finally(() => Tt(e, !1));
@@ -6508,34 +6515,34 @@ function sa(e) {
6508
6515
  }
6509
6516
  function ia(e, t) {
6510
6517
  var n, r;
6511
- e.isOpen && (t.key === "Escape" && (t.preventDefault(), e._pendingDeleteMethod ? Ve(e) : e.isAddCardViewOpen ? Ie(e) : e.isPaymentSheetOpen ? ae(e) : e.close()), t.key === "Enter" && ((r = (n = t.target) == null ? void 0 : n.dataset) == null ? void 0 : r.action) === "pay" && (t.preventDefault(), e.handlePayment()));
6518
+ e.isOpen && (t.key === "Escape" && (t.preventDefault(), e._pendingDeleteMethod ? Ve(e) : e.isAddCardViewOpen ? ve(e) : e.isPaymentSheetOpen ? ae(e) : e.close()), t.key === "Enter" && ((r = (n = t.target) == null ? void 0 : n.dataset) == null ? void 0 : r.action) === "pay" && (t.preventDefault(), e.handlePayment()));
6512
6519
  }
6513
6520
  function aa(e, t) {
6514
6521
  const n = t.querySelector('[data-action="sheet-drag-handle"]'), r = t.querySelector(".choco-widget-sheet-content");
6515
6522
  if (!n || !r) return;
6516
6523
  const o = 80;
6517
6524
  let i = 0, c = 0;
6518
- const u = (h) => {
6519
- c = h.clientY;
6525
+ const u = (f) => {
6526
+ c = f.clientY;
6520
6527
  const y = Math.max(0, c - i);
6521
6528
  r.style.transform = `translateY(${y}px)`;
6522
- }, l = (h) => {
6523
- n.releasePointerCapture(h.pointerId), n.removeEventListener("pointermove", u), n.removeEventListener("pointerup", l), n.removeEventListener("pointercancel", l);
6529
+ }, l = (f) => {
6530
+ n.releasePointerCapture(f.pointerId), n.removeEventListener("pointermove", u), n.removeEventListener("pointerup", l), n.removeEventListener("pointercancel", l);
6524
6531
  const y = Math.max(0, c - i);
6525
6532
  if (r.classList.remove("choco-widget-sheet-content--dragging"), y >= o) {
6526
6533
  r.style.transform = "translateY(100%)";
6527
- const m = () => {
6528
- r.removeEventListener("transitionend", m), r.style.transform = "", ae(e);
6534
+ const C = () => {
6535
+ r.removeEventListener("transitionend", C), r.style.transform = "", ae(e);
6529
6536
  };
6530
- r.addEventListener("transitionend", m);
6537
+ r.addEventListener("transitionend", C);
6531
6538
  } else
6532
6539
  r.style.transform = "";
6533
6540
  };
6534
- n.addEventListener("pointerdown", (h) => {
6535
- !e.isPaymentSheetOpen || h.button !== 0 || (h.preventDefault(), i = h.clientY, c = h.clientY, r.classList.add("choco-widget-sheet-content--dragging"), n.setPointerCapture(h.pointerId), n.addEventListener("pointermove", u), n.addEventListener("pointerup", l), n.addEventListener("pointercancel", l));
6541
+ n.addEventListener("pointerdown", (f) => {
6542
+ !e.isPaymentSheetOpen || f.button !== 0 || (f.preventDefault(), i = f.clientY, c = f.clientY, r.classList.add("choco-widget-sheet-content--dragging"), n.setPointerCapture(f.pointerId), n.addEventListener("pointermove", u), n.addEventListener("pointerup", l), n.addEventListener("pointercancel", l));
6536
6543
  });
6537
6544
  }
6538
- class Ce {
6545
+ class me {
6539
6546
  // ─── Статические методы / logout ─────────────────────────────────────────────
6540
6547
  static _getAuthStorageValue(t) {
6541
6548
  return Un(t);
@@ -6602,17 +6609,17 @@ class Ce {
6602
6609
  return Number.isFinite(t) && t > 0 ? t : 0;
6603
6610
  }
6604
6611
  _getPaymentBreakdown() {
6605
- const t = this.config.amount, n = this._getBalanceAmount(), r = this.useBalance ? Math.min(n, t) : 0, o = t - r, i = this.useBalance && r >= t, c = this.useBonuses ? this._getAvailableBonus() : 0, u = Math.max(o - c, 0), l = this._getCouponDiscount(), h = Math.max(u - l, 0), y = this.useBalance ? t : h, m = this.useBalance && !i, I = this.useCoupon && this.selectedCoupon && !this._isCouponDisabled() ? {
6612
+ const t = this.config.amount, n = this._getBalanceAmount(), r = this.useBalance ? Math.min(n, t) : 0, o = t - r, i = this.useBalance && r >= t, c = this.useBonuses ? this._getAvailableBonus() : 0, u = Math.max(o - c, 0), l = this._getCouponDiscount(), f = Math.max(u - l, 0), y = this.useBalance ? t : f, C = this.useBalance && !i, I = this.useCoupon && this.selectedCoupon && !this._isCouponDisabled() ? {
6606
6613
  id: this.selectedCoupon.voucher_id,
6607
6614
  template_id: this.selectedCoupon.template_id,
6608
6615
  type: this.selectedCoupon.type
6609
6616
  } : void 0;
6610
6617
  return {
6611
- payableAmount: h,
6618
+ payableAmount: f,
6612
6619
  checkoutOptions: {
6613
6620
  checkoutAmount: y,
6614
6621
  forceBalanceMethod: i,
6615
- useBalance: m,
6622
+ useBalance: C,
6616
6623
  voucher: I
6617
6624
  }
6618
6625
  };
@@ -6655,12 +6662,12 @@ class Ce {
6655
6662
  gt(this);
6656
6663
  }
6657
6664
  _closeAddCardView() {
6658
- Ie(this);
6665
+ ve(this);
6659
6666
  }
6660
6667
  // ─── Таймауты новой карты ─────────────────────────────────────────────────────
6661
6668
  _setNewCardActionTimeout() {
6662
6669
  this._clearNewCardActionTimeout(), this.newCardActionRequiredTimeoutId = setTimeout(() => {
6663
- this.waitingForNewCardAction && (this.waitingForNewCardAction = !1, W(this), this.config.onError({
6670
+ this.waitingForNewCardAction && (this.waitingForNewCardAction = !1, K(this), this.config.onError({
6664
6671
  attributes: { message: this.t("errorNoServerResponseRetry") }
6665
6672
  })), this.newCardActionRequiredTimeoutId = null;
6666
6673
  }, 6e4);
@@ -6676,13 +6683,13 @@ class Ce {
6676
6683
  Tn();
6677
6684
  }
6678
6685
  _getAuthStorageValue(t) {
6679
- return Ce._getAuthStorageValue(t);
6686
+ return me._getAuthStorageValue(t);
6680
6687
  }
6681
6688
  _setAuthStorageValue(t, n) {
6682
- Ce._setAuthStorageValue(t, n);
6689
+ me._setAuthStorageValue(t, n);
6683
6690
  }
6684
6691
  _removeAuthStorageValue(t) {
6685
- Ce._removeAuthStorageValue(t);
6692
+ me._removeAuthStorageValue(t);
6686
6693
  }
6687
6694
  // ─── Google Pay SDK (используется из domUI + paymentFlow) ────────────────────
6688
6695
  _loadGooglePaySdk() {
@@ -6798,7 +6805,7 @@ class Ce {
6798
6805
  destroy() {
6799
6806
  this._destroyed = !0;
6800
6807
  const t = document.getElementById("choco-one-click-widget");
6801
- t && (t.style.display = "none"), this._clearNewCardActionTimeout(), de(this), this._pendingSuccessPayload = null, this._detachLifecycleListeners(), this.isAddCardViewOpen && Ie(this), this.centrifuge && (this.centrifuge.disconnect(), this.centrifuge = null), document.removeEventListener("keydown", this._boundKeyDown), this.container && (this.container.classList.remove("choco-one-click-widget--visible"), setTimeout(() => {
6808
+ t && (t.style.display = "none"), this._clearNewCardActionTimeout(), de(this), this._pendingSuccessPayload = null, this._detachLifecycleListeners(), this.isAddCardViewOpen && ve(this), this.centrifuge && (this.centrifuge.disconnect(), this.centrifuge = null), document.removeEventListener("keydown", this._boundKeyDown), this.container && (this.container.classList.remove("choco-one-click-widget--visible"), setTimeout(() => {
6802
6809
  var n;
6803
6810
  (n = this.container) == null || n.remove(), this.container = null;
6804
6811
  }, 300)), this.isOpen = !1, this.isPaymentSheetOpen = !1, this.isAddCardViewOpen = !1, this.selectedPaymentMethod = null;
@@ -6890,7 +6897,7 @@ class Ce {
6890
6897
  this.config.idempotencyKey = t;
6891
6898
  }
6892
6899
  async logout() {
6893
- await Ce.logout(), this.accessToken = null;
6900
+ await me.logout(), this.accessToken = null;
6894
6901
  }
6895
6902
  async updateTrackId(t) {
6896
6903
  var n, r;
@@ -6944,7 +6951,7 @@ class Ce {
6944
6951
  this.config.onAppliedBonus = t;
6945
6952
  }
6946
6953
  }
6947
- typeof window < "u" && (window.ChocoOneClickWidget = Ce);
6954
+ typeof window < "u" && (window.ChocoOneClickWidget = me);
6948
6955
  export {
6949
- Ce as default
6956
+ me as default
6950
6957
  };