@everymatrix/player-account-self-exclusion 1.72.2 → 1.73.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- import { B as Zo, C as Qo, D as Dr, $ as kr, c as Pr, S as Tr, a as Mr, s as Or, f as he, b as Ir, E as li, d as be, j as xe, v as T, F as Fr, G as Nr, o as zr, x as so, r as g, H as X, I, J as Wt, w as M, K as ro, L as Lr, M as $r, N as ye, O as Ve, P as Tt, Q as _e, R as ke, T as Rr, y as Hr, z as Br, A as Yr } from "./PlayerAccountGeneralConfirmationModal-CF0gIxAh.js";
1
+ import { B as Zo, C as Qo, D as Dr, $ as kr, c as Pr, S as Tr, a as Mr, s as Or, f as fe, b as Ir, E as li, d as be, j as xe, v as T, F as Fr, G as Nr, o as zr, x as so, r as g, H as X, I, J as Wt, w as M, K as ro, L as Lr, M as $r, N as ye, O as Ve, P as Tt, Q as _e, R as ke, T as Rr, y as Hr, z as Br, A as Yr } from "./PlayerAccountGeneralConfirmationModal-CF0gIxAh.js";
2
2
  import "../stencil/ui-skeleton-hI4GeaLk.js";
3
3
  var es = { exports: {} };
4
4
  (function(o, t) {
@@ -102,7 +102,7 @@ var es = { exports: {} };
102
102
  return A ? Y : Y.endOf(c);
103
103
  }, H = function(Z, L) {
104
104
  return k.w(_.toDate()[Z].apply(_.toDate("s"), (A ? [0, 0, 0, 0] : [23, 59, 59, 999]).slice(L)), _);
105
- }, V = this.$W, W = this.$M, ee = this.$D, ue = "set" + (this.$u ? "UTC" : "");
105
+ }, V = this.$W, W = this.$M, ee = this.$D, de = "set" + (this.$u ? "UTC" : "");
106
106
  switch (S) {
107
107
  case p:
108
108
  return A ? F(1, 0) : F(31, 11);
@@ -113,13 +113,13 @@ var es = { exports: {} };
113
113
  return F(A ? ee - te : ee + (6 - te), W);
114
114
  case c:
115
115
  case y:
116
- return H(ue + "Hours", 0);
116
+ return H(de + "Hours", 0);
117
117
  case l:
118
- return H(ue + "Minutes", 1);
118
+ return H(de + "Minutes", 1);
119
119
  case a:
120
- return H(ue + "Seconds", 2);
120
+ return H(de + "Seconds", 2);
121
121
  case n:
122
- return H(ue + "Milliseconds", 3);
122
+ return H(de + "Milliseconds", 3);
123
123
  default:
124
124
  return this.clone();
125
125
  }
@@ -160,17 +160,17 @@ var es = { exports: {} };
160
160
  var x = this, _ = this.$locale();
161
161
  if (!this.isValid())
162
162
  return _.invalidDate || f;
163
- var A = m || "YYYY-MM-DDTHH:mm:ssZ", S = k.z(this), F = this.$H, H = this.$m, V = this.$M, W = _.weekdays, ee = _.months, ue = _.meridiem, ae = function(L, Y, de, le) {
164
- return L && (L[Y] || L(x, A)) || de[Y].slice(0, le);
163
+ var A = m || "YYYY-MM-DDTHH:mm:ssZ", S = k.z(this), F = this.$H, H = this.$m, V = this.$M, W = _.weekdays, ee = _.months, de = _.meridiem, ae = function(L, Y, he, le) {
164
+ return L && (L[Y] || L(x, A)) || he[Y].slice(0, le);
165
165
  }, te = function(L) {
166
166
  return k.s(F % 12 || 12, L, "0");
167
- }, Z = ue || function(L, Y, de) {
167
+ }, Z = de || function(L, Y, he) {
168
168
  var le = L < 12 ? "AM" : "PM";
169
- return de ? le.toLowerCase() : le;
169
+ return he ? le.toLowerCase() : le;
170
170
  };
171
171
  return A.replace(D, function(L, Y) {
172
- return Y || function(de) {
173
- switch (de) {
172
+ return Y || function(he) {
173
+ switch (he) {
174
174
  case "YY":
175
175
  return String(x.$y).slice(-2);
176
176
  case "YYYY":
@@ -398,10 +398,10 @@ var ts = { exports: {} };
398
398
  try {
399
399
  if (["x", "X"].indexOf(x) > -1)
400
400
  return new Date((x === "X" ? 1e3 : 1) * m);
401
- var A = y(x)(m), S = A.year, F = A.month, H = A.day, V = A.hours, W = A.minutes, ee = A.seconds, ue = A.milliseconds, ae = A.zone, te = /* @__PURE__ */ new Date(), Z = H || (S || F ? 1 : te.getDate()), L = S || te.getFullYear(), Y = 0;
401
+ var A = y(x)(m), S = A.year, F = A.month, H = A.day, V = A.hours, W = A.minutes, ee = A.seconds, de = A.milliseconds, ae = A.zone, te = /* @__PURE__ */ new Date(), Z = H || (S || F ? 1 : te.getDate()), L = S || te.getFullYear(), Y = 0;
402
402
  S && !F || (Y = F > 0 ? F - 1 : te.getMonth());
403
- var de = V || 0, le = W || 0, ce = ee || 0, ge = ue || 0;
404
- return ae ? new Date(Date.UTC(L, Y, Z, de, le, ce, ge + 60 * ae.offset * 1e3)) : _ ? new Date(Date.UTC(L, Y, Z, de, le, ce, ge)) : new Date(L, Y, Z, de, le, ce, ge);
403
+ var he = V || 0, le = W || 0, ce = ee || 0, ge = de || 0;
404
+ return ae ? new Date(Date.UTC(L, Y, Z, he, le, ce, ge + 60 * ae.offset * 1e3)) : _ ? new Date(Date.UTC(L, Y, Z, he, le, ce, ge)) : new Date(L, Y, Z, he, le, ce, ge);
405
405
  } catch {
406
406
  return /* @__PURE__ */ new Date("");
407
407
  }
@@ -16238,7 +16238,7 @@ function Mu(o) {
16238
16238
  ), G, U, O, k, j, se, E, v, m, x, _, A, S, F = (
16239
16239
  /*$_*/
16240
16240
  o[20]("save") + ""
16241
- ), H, V, W, ee, ue, ae, te = (
16241
+ ), H, V, W, ee, de, ae, te = (
16242
16242
  /*isMobile*/
16243
16243
  o[22] && Iu(o)
16244
16244
  ), Z = ro(
@@ -16251,7 +16251,7 @@ function Mu(o) {
16251
16251
  /*isUntilDate*/
16252
16252
  o[16] && Xo(o)
16253
16253
  );
16254
- function de(P, J) {
16254
+ function he(P, J) {
16255
16255
  return (
16256
16256
  /*isPermanentSelfExclusion*/
16257
16257
  P[15] ? zu : (
@@ -16260,7 +16260,7 @@ function Mu(o) {
16260
16260
  )
16261
16261
  );
16262
16262
  }
16263
- let le = de(o), ce = le(o), ge = (
16263
+ let le = he(o), ce = le(o), ge = (
16264
16264
  /*showConfirmationModal*/
16265
16265
  o[23] && Lu(o)
16266
16266
  );
@@ -16302,7 +16302,7 @@ function Mu(o) {
16302
16302
  xe(P, t, J), g(t, e), te && te.m(e, null), g(e, i), g(e, s), g(s, n), g(e, a), g(e, l), g(l, c), c.innerHTML = u, g(l, d), g(l, h), g(h, y), g(h, f), g(h, b), g(b, D), g(e, z), g(e, N), g(N, $), g($, q), g(q, G), g($, U), g($, O), g(O, k), g(k, j), g(N, se), g(N, E);
16303
16303
  for (let ie = 0; ie < L.length; ie += 1)
16304
16304
  L[ie] && L[ie].m(E, null);
16305
- g(e, v), Y && Y.m(e, null), g(e, m), g(e, x), ce.m(x, null), g(e, _), g(e, A), g(A, S), g(S, H), g(t, ee), ge && ge.m(t, null), ue || (ae = [
16305
+ g(e, v), Y && Y.m(e, null), g(e, m), g(e, x), ce.m(x, null), g(e, _), g(e, A), g(A, S), g(S, H), g(t, ee), ge && ge.m(t, null), de || (ae = [
16306
16306
  Tt(
16307
16307
  $,
16308
16308
  "click",
@@ -16315,7 +16315,7 @@ function Mu(o) {
16315
16315
  /*click_handler_3*/
16316
16316
  o[40]
16317
16317
  )
16318
- ], ue = !0);
16318
+ ], de = !0);
16319
16319
  },
16320
16320
  p(P, J) {
16321
16321
  if (
@@ -16386,7 +16386,7 @@ function Mu(o) {
16386
16386
  /*isPeriodDropDownToggled*/
16387
16387
  P[18]
16388
16388
  ), /*isUntilDate*/
16389
- P[16] ? Y ? Y.p(P, J) : (Y = Xo(P), Y.c(), Y.m(e, m)) : Y && (Y.d(1), Y = null), le === (le = de(P)) && ce ? ce.p(P, J) : (ce.d(1), ce = le(P), ce && (ce.c(), ce.m(x, null))), J[0] & /*$_*/
16389
+ P[16] ? Y ? Y.p(P, J) : (Y = Xo(P), Y.c(), Y.m(e, m)) : Y && (Y.d(1), Y = null), le === (le = he(P)) && ce ? ce.p(P, J) : (ce.d(1), ce = le(P), ce && (ce.c(), ce.m(x, null))), J[0] & /*$_*/
16390
16390
  1048576 && F !== (F = /*$_*/
16391
16391
  P[20]("save") + "") && ye(H, F), J[0] & /*isDateSelected*/
16392
16392
  131072 && V !== (V = "SelfExclusionSave " + /*isDateSelected*/
@@ -16396,7 +16396,7 @@ function Mu(o) {
16396
16396
  P[23] && ge.p(P, J);
16397
16397
  },
16398
16398
  d(P) {
16399
- P && be(t), te && te.d(), Lr(L, P), Y && Y.d(), ce.d(), ge && ge.d(), ue = !1, $r(ae);
16399
+ P && be(t), te && te.d(), Lr(L, P), Y && Y.d(), ce.d(), ge && ge.d(), de = !1, $r(ae);
16400
16400
  }
16401
16401
  };
16402
16402
  }
@@ -16819,12 +16819,12 @@ function Bu(o, t, e) {
16819
16819
  Fr(o, Rr, (w) => e(20, i = w)), Ce.extend(Ur);
16820
16820
  let { endpoint: s = "", session: r = "", userid: n = "", lang: a = "en", gmversion: l = "", operator: c = "Everymatrix", supportemail: u = "", baseurl: d = "", clientstyling: h = "", clientstylingurl: p = "", mbsource: y, translationurl: f = "", hasconfirmationmodal: b = "false", dateformat: D = "DD/MM/YYYY", sendnotificationemail: C = "false" } = t, z, N, $ = [], q = {}, K = D.toUpperCase(), G = window.navigator.userAgent, U, O, k = "", j = "", se = "selectAPeriod", E = "", v = "", m = Nr(G) !== "PC", x = !1, _ = !1, A = !1, S = !1, F = b === "true", H = !0;
16821
16821
  const V = () => {
16822
- fetch(f).then((pe) => pe.json()).then((pe) => {
16823
- Object.keys(pe).forEach((fe) => {
16824
- no(fe, pe[fe]);
16822
+ fetch(f).then((ue) => ue.json()).then((ue) => {
16823
+ Object.keys(ue).forEach((pe) => {
16824
+ no(pe, ue[pe]);
16825
16825
  });
16826
- }).catch((pe) => {
16827
- console.log(pe);
16826
+ }).catch((ue) => {
16827
+ console.log(ue);
16828
16828
  });
16829
16829
  };
16830
16830
  Object.keys(ao).forEach((w) => {
@@ -16838,29 +16838,28 @@ function Bu(o, t, e) {
16838
16838
  "Content-Type": "application/json",
16839
16839
  Accept: "application/json"
16840
16840
  }
16841
- }).then((fe) => ue(fe)).then((fe) => {
16842
- e(9, $ = fe.periods);
16843
- }).catch((fe) => {
16844
- console.log(fe);
16845
- }).finally(() => {
16846
- e(19, H = !1);
16847
- });
16848
- }, ee = (w) => {
16849
- w.data.type === "setSelfExclusion" && Y();
16850
- }, ue = async (w) => {
16851
- if (w.status >= 300)
16852
- q = await w.json(), v = q.thirdPartyResponse.errorCode, console.error(i(v || "generalError")), window.postMessage(
16841
+ }).then((pe) => de(pe)).then((pe) => {
16842
+ e(9, $ = pe.periods);
16843
+ }).catch((pe) => {
16844
+ console.log(pe), window.postMessage(
16853
16845
  {
16854
16846
  type: "WidgetNotification",
16855
- data: {
16856
- type: "error",
16857
- message: i(v || "generalError")
16858
- }
16847
+ data: { type: "error", message: pe.message }
16859
16848
  },
16860
16849
  window.location.href
16861
16850
  );
16862
- else
16863
- return w.json();
16851
+ }).finally(() => {
16852
+ e(19, H = !1);
16853
+ });
16854
+ }, ee = (w) => {
16855
+ w.data.type === "setSelfExclusion" && Y();
16856
+ }, de = async (w) => {
16857
+ if (!w.ok) {
16858
+ q = await w.json(), v = q.thirdPartyResponse?.errorCode;
16859
+ const ue = i(v || "generalError");
16860
+ throw new Error(ue);
16861
+ }
16862
+ return w.json();
16864
16863
  }, ae = () => {
16865
16864
  e(18, S = !S);
16866
16865
  }, te = (w) => {
@@ -16872,10 +16871,10 @@ function Bu(o, t, e) {
16872
16871
  e(15, x = !x);
16873
16872
  break;
16874
16873
  default:
16875
- const [pe, fe] = j.split(" "), Fe = fe.includes("Day") ? "days" : fe.includes("Month") ? "months" : fe.includes("Year") ? "years" : null;
16874
+ const [ue, pe] = j.split(" "), Fe = pe.includes("Day") ? "days" : pe.includes("Month") ? "months" : pe.includes("Year") ? "years" : null;
16876
16875
  if (!Fe)
16877
16876
  return;
16878
- e(12, k = Ce().add(Number(pe), Fe).format("YYYY-MM-DD"));
16877
+ e(12, k = Ce().add(Number(ue), Fe).format("YYYY-MM-DD"));
16879
16878
  break;
16880
16879
  }
16881
16880
  F && Z();
@@ -16898,7 +16897,7 @@ function Bu(o, t, e) {
16898
16897
  )) : Y();
16899
16898
  }, Y = () => {
16900
16899
  e(19, H = !0);
16901
- const w = new URL(`/v2/player/${n}/limits${l === "gm16" ? "/session" : ""}`, s), fe = {
16900
+ const w = new URL(`/v2/player/${n}/limits${l === "gm16" ? "/session" : ""}`, s), pe = {
16902
16901
  method: "PUT",
16903
16902
  headers: {
16904
16903
  "X-SessionID": r,
@@ -16914,7 +16913,7 @@ function Bu(o, t, e) {
16914
16913
  }
16915
16914
  })
16916
16915
  };
16917
- fetch(w.href, fe).then((Fe) => ue(Fe)).then((Fe) => {
16916
+ fetch(w.href, pe).then((Fe) => de(Fe)).then((Fe) => {
16918
16917
  window.postMessage(
16919
16918
  {
16920
16919
  type: "WidgetNotification",
@@ -16939,7 +16938,7 @@ function Bu(o, t, e) {
16939
16938
  }).finally(() => {
16940
16939
  e(19, H = !1);
16941
16940
  });
16942
- }, de = () => {
16941
+ }, he = () => {
16943
16942
  window.postMessage(
16944
16943
  {
16945
16944
  type: "PlayerAccountMenuActive",
@@ -16956,11 +16955,11 @@ function Bu(o, t, e) {
16956
16955
  ...N.i18n,
16957
16956
  formatDate: (w) => Ce(new Date(w.year, w.month, w.day)).format(K),
16958
16957
  parseDate: (w) => {
16959
- const pe = Ce(w, K);
16958
+ const ue = Ce(w, K);
16960
16959
  return {
16961
- year: pe.year(),
16962
- month: pe.month(),
16963
- day: pe.date()
16960
+ year: ue.year(),
16961
+ month: ue.month(),
16962
+ day: ue.date()
16964
16963
  };
16965
16964
  }
16966
16965
  },
@@ -16972,7 +16971,7 @@ function Bu(o, t, e) {
16972
16971
  }));
16973
16972
  const ge = () => {
16974
16973
  Wr(a);
16975
- }, P = () => de(), J = () => ae(), ie = (w) => te(w);
16974
+ }, P = () => he(), J = () => ae(), ie = (w) => te(w);
16976
16975
  function wt(w) {
16977
16976
  so[w ? "unshift" : "push"](() => {
16978
16977
  N = w, e(8, N);
@@ -17024,7 +17023,7 @@ function Bu(o, t, e) {
17024
17023
  ae,
17025
17024
  te,
17026
17025
  L,
17027
- de,
17026
+ he,
17028
17027
  s,
17029
17028
  r,
17030
17029
  n,
@@ -17074,91 +17073,91 @@ class Yu extends Tr {
17074
17073
  return this.$$.ctx[28];
17075
17074
  }
17076
17075
  set endpoint(t) {
17077
- this.$$set({ endpoint: t }), he();
17076
+ this.$$set({ endpoint: t }), fe();
17078
17077
  }
17079
17078
  get session() {
17080
17079
  return this.$$.ctx[29];
17081
17080
  }
17082
17081
  set session(t) {
17083
- this.$$set({ session: t }), he();
17082
+ this.$$set({ session: t }), fe();
17084
17083
  }
17085
17084
  get userid() {
17086
17085
  return this.$$.ctx[30];
17087
17086
  }
17088
17087
  set userid(t) {
17089
- this.$$set({ userid: t }), he();
17088
+ this.$$set({ userid: t }), fe();
17090
17089
  }
17091
17090
  get lang() {
17092
17091
  return this.$$.ctx[0];
17093
17092
  }
17094
17093
  set lang(t) {
17095
- this.$$set({ lang: t }), he();
17094
+ this.$$set({ lang: t }), fe();
17096
17095
  }
17097
17096
  get gmversion() {
17098
17097
  return this.$$.ctx[31];
17099
17098
  }
17100
17099
  set gmversion(t) {
17101
- this.$$set({ gmversion: t }), he();
17100
+ this.$$set({ gmversion: t }), fe();
17102
17101
  }
17103
17102
  get operator() {
17104
17103
  return this.$$.ctx[1];
17105
17104
  }
17106
17105
  set operator(t) {
17107
- this.$$set({ operator: t }), he();
17106
+ this.$$set({ operator: t }), fe();
17108
17107
  }
17109
17108
  get supportemail() {
17110
17109
  return this.$$.ctx[2];
17111
17110
  }
17112
17111
  set supportemail(t) {
17113
- this.$$set({ supportemail: t }), he();
17112
+ this.$$set({ supportemail: t }), fe();
17114
17113
  }
17115
17114
  get baseurl() {
17116
17115
  return this.$$.ctx[3];
17117
17116
  }
17118
17117
  set baseurl(t) {
17119
- this.$$set({ baseurl: t }), he();
17118
+ this.$$set({ baseurl: t }), fe();
17120
17119
  }
17121
17120
  get clientstyling() {
17122
17121
  return this.$$.ctx[4];
17123
17122
  }
17124
17123
  set clientstyling(t) {
17125
- this.$$set({ clientstyling: t }), he();
17124
+ this.$$set({ clientstyling: t }), fe();
17126
17125
  }
17127
17126
  get clientstylingurl() {
17128
17127
  return this.$$.ctx[5];
17129
17128
  }
17130
17129
  set clientstylingurl(t) {
17131
- this.$$set({ clientstylingurl: t }), he();
17130
+ this.$$set({ clientstylingurl: t }), fe();
17132
17131
  }
17133
17132
  get mbsource() {
17134
17133
  return this.$$.ctx[6];
17135
17134
  }
17136
17135
  set mbsource(t) {
17137
- this.$$set({ mbsource: t }), he();
17136
+ this.$$set({ mbsource: t }), fe();
17138
17137
  }
17139
17138
  get translationurl() {
17140
17139
  return this.$$.ctx[32];
17141
17140
  }
17142
17141
  set translationurl(t) {
17143
- this.$$set({ translationurl: t }), he();
17142
+ this.$$set({ translationurl: t }), fe();
17144
17143
  }
17145
17144
  get hasconfirmationmodal() {
17146
17145
  return this.$$.ctx[33];
17147
17146
  }
17148
17147
  set hasconfirmationmodal(t) {
17149
- this.$$set({ hasconfirmationmodal: t }), he();
17148
+ this.$$set({ hasconfirmationmodal: t }), fe();
17150
17149
  }
17151
17150
  get dateformat() {
17152
17151
  return this.$$.ctx[34];
17153
17152
  }
17154
17153
  set dateformat(t) {
17155
- this.$$set({ dateformat: t }), he();
17154
+ this.$$set({ dateformat: t }), fe();
17156
17155
  }
17157
17156
  get sendnotificationemail() {
17158
17157
  return this.$$.ctx[35];
17159
17158
  }
17160
17159
  set sendnotificationemail(t) {
17161
- this.$$set({ sendnotificationemail: t }), he();
17160
+ this.$$set({ sendnotificationemail: t }), fe();
17162
17161
  }
17163
17162
  }
17164
17163
  Pr(Yu, { endpoint: {}, session: {}, userid: {}, lang: {}, gmversion: {}, operator: {}, supportemail: {}, baseurl: {}, clientstyling: {}, clientstylingurl: {}, mbsource: {}, translationurl: {}, hasconfirmationmodal: {}, dateformat: {}, sendnotificationemail: {} }, [], [], !0);