@revenuecat/purchases-js 0.3.0 → 0.3.2
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/Purchases.es.d.ts +31 -2
- package/dist/Purchases.es.js +793 -736
- package/dist/Purchases.umd.js +4 -4
- package/package.json +1 -1
package/dist/Purchases.es.js
CHANGED
|
@@ -47,8 +47,8 @@ class G {
|
|
|
47
47
|
}
|
|
48
48
|
}
|
|
49
49
|
Q(G, "logLevel", W.Silent);
|
|
50
|
-
var
|
|
51
|
-
function
|
|
50
|
+
var ne = /* @__PURE__ */ ((t) => (t.Year = "year", t.Month = "month", t.Week = "week", t.Day = "day", t))(ne || {});
|
|
51
|
+
function Je(t) {
|
|
52
52
|
const e = t.match(/^PT?([0-9]+)([MDYW])$/);
|
|
53
53
|
if (!e || e.length < 3)
|
|
54
54
|
return G.errorLog(`Invalid ISO 8601 duration format: ${t}`), null;
|
|
@@ -82,7 +82,7 @@ function yt(t) {
|
|
|
82
82
|
return G.errorLog(`Invalid ISO 8601 unit duration format: ${t}`), null;
|
|
83
83
|
}
|
|
84
84
|
}
|
|
85
|
-
const
|
|
85
|
+
const Ve = (t, e) => {
|
|
86
86
|
const r = t / 100;
|
|
87
87
|
return new Intl.NumberFormat("en-US", {
|
|
88
88
|
style: "currency",
|
|
@@ -92,13 +92,13 @@ const Je = (t, e) => {
|
|
|
92
92
|
const e = t.number;
|
|
93
93
|
if (e === 1)
|
|
94
94
|
switch (t.unit) {
|
|
95
|
-
case
|
|
95
|
+
case ne.Year:
|
|
96
96
|
return "yearly";
|
|
97
|
-
case
|
|
97
|
+
case ne.Month:
|
|
98
98
|
return "monthly";
|
|
99
|
-
case
|
|
99
|
+
case ne.Week:
|
|
100
100
|
return "weekly";
|
|
101
|
-
case
|
|
101
|
+
case ne.Day:
|
|
102
102
|
return "daily";
|
|
103
103
|
}
|
|
104
104
|
else
|
|
@@ -107,37 +107,41 @@ const Je = (t, e) => {
|
|
|
107
107
|
const e = t.number;
|
|
108
108
|
if (e === 1)
|
|
109
109
|
switch (t.unit) {
|
|
110
|
-
case
|
|
110
|
+
case ne.Year:
|
|
111
111
|
return "1 year";
|
|
112
|
-
case
|
|
112
|
+
case ne.Month:
|
|
113
113
|
return "1 month";
|
|
114
|
-
case
|
|
114
|
+
case ne.Week:
|
|
115
115
|
return "1 week";
|
|
116
|
-
case
|
|
116
|
+
case ne.Day:
|
|
117
117
|
return "1 day";
|
|
118
118
|
}
|
|
119
119
|
else
|
|
120
120
|
return `${e} ${t.unit}s`;
|
|
121
|
-
},
|
|
122
|
-
const e =
|
|
121
|
+
}, nt = (t) => {
|
|
122
|
+
const e = Je(t);
|
|
123
123
|
return e ? Jt(e) : "unknown";
|
|
124
124
|
}, Wt = (t) => {
|
|
125
|
-
const e =
|
|
125
|
+
const e = Je(t);
|
|
126
126
|
return e ? Vt(e) : "unknown";
|
|
127
127
|
};
|
|
128
128
|
var zt = /* @__PURE__ */ ((t) => (t.Unknown = "unknown", t.Custom = "custom", t.Lifetime = "$rc_lifetime", t.Annual = "$rc_annual", t.SixMonth = "$rc_six_month", t.ThreeMonth = "$rc_three_month", t.TwoMonth = "$rc_two_month", t.Monthly = "$rc_monthly", t.Weekly = "$rc_weekly", t))(zt || {});
|
|
129
129
|
const Xt = (t) => ({
|
|
130
130
|
amount: t.amount,
|
|
131
131
|
currency: t.currency,
|
|
132
|
-
formattedPrice:
|
|
133
|
-
}),
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
132
|
+
formattedPrice: Ve(t.amount, t.currency)
|
|
133
|
+
}), rt = (t) => {
|
|
134
|
+
const e = t.period_duration;
|
|
135
|
+
return {
|
|
136
|
+
periodDuration: e,
|
|
137
|
+
period: e ? Je(e) : null,
|
|
138
|
+
cycleCount: t.cycle_count,
|
|
139
|
+
price: t.price ? Xt(t.price) : null
|
|
140
|
+
};
|
|
141
|
+
}, Zt = (t) => t.base == null ? (G.debugLog("Missing base phase for subscription option. Ignoring."), null) : {
|
|
138
142
|
id: t.id,
|
|
139
|
-
base:
|
|
140
|
-
trial: t.trial ?
|
|
143
|
+
base: rt(t.base),
|
|
144
|
+
trial: t.trial ? rt(t.trial) : null
|
|
141
145
|
}, en = (t, e) => {
|
|
142
146
|
const r = {};
|
|
143
147
|
if (Object.entries(t.subscription_options).forEach(
|
|
@@ -178,7 +182,7 @@ const Xt = (t) => ({
|
|
|
178
182
|
rcBillingProduct: i,
|
|
179
183
|
packageType: nn(e.identifier)
|
|
180
184
|
};
|
|
181
|
-
},
|
|
185
|
+
}, it = (t, e) => {
|
|
182
186
|
const r = t.packages.map(
|
|
183
187
|
(i) => tn(t.identifier, i, e)
|
|
184
188
|
).filter(jt), n = {};
|
|
@@ -232,7 +236,7 @@ function rn(t, e) {
|
|
|
232
236
|
function Bt(t) {
|
|
233
237
|
return t();
|
|
234
238
|
}
|
|
235
|
-
function
|
|
239
|
+
function ot() {
|
|
236
240
|
return /* @__PURE__ */ Object.create(null);
|
|
237
241
|
}
|
|
238
242
|
function we(t) {
|
|
@@ -248,11 +252,11 @@ let De;
|
|
|
248
252
|
function Z(t, e) {
|
|
249
253
|
return t === e ? !0 : (De || (De = document.createElement("a")), De.href = e, t === De.href);
|
|
250
254
|
}
|
|
251
|
-
function
|
|
255
|
+
function st(t) {
|
|
252
256
|
return t.split(",").map((e) => e.trim().split(" ").filter(Boolean));
|
|
253
257
|
}
|
|
254
258
|
function on(t, e) {
|
|
255
|
-
const r =
|
|
259
|
+
const r = st(t.srcset), n = st(e || "");
|
|
256
260
|
return n.length === r.length && n.every(
|
|
257
261
|
([i, o], s) => o === r[s][1] && // We need to test both ways because Vite will create an a full URL with
|
|
258
262
|
// `new URL(asset, import.meta.url).href` for the client when `base: './'`, and the
|
|
@@ -307,7 +311,7 @@ function V(t) {
|
|
|
307
311
|
function Ee(t) {
|
|
308
312
|
return t ?? "";
|
|
309
313
|
}
|
|
310
|
-
function
|
|
314
|
+
function C(t, e) {
|
|
311
315
|
t.appendChild(e);
|
|
312
316
|
}
|
|
313
317
|
function x(t, e, r) {
|
|
@@ -328,7 +332,7 @@ function ln(t) {
|
|
|
328
332
|
) : t.ownerDocument;
|
|
329
333
|
}
|
|
330
334
|
function cn(t, e) {
|
|
331
|
-
return
|
|
335
|
+
return C(
|
|
332
336
|
/** @type {Document} */
|
|
333
337
|
t.head || t,
|
|
334
338
|
e
|
|
@@ -343,19 +347,19 @@ function g(t) {
|
|
|
343
347
|
function k(t) {
|
|
344
348
|
return document.createElement(t);
|
|
345
349
|
}
|
|
346
|
-
function
|
|
350
|
+
function L(t) {
|
|
347
351
|
return document.createTextNode(t);
|
|
348
352
|
}
|
|
349
353
|
function P() {
|
|
350
|
-
return
|
|
354
|
+
return L(" ");
|
|
351
355
|
}
|
|
352
|
-
function
|
|
353
|
-
return
|
|
356
|
+
function te() {
|
|
357
|
+
return L("");
|
|
354
358
|
}
|
|
355
359
|
function ke(t, e, r, n) {
|
|
356
360
|
return t.addEventListener(e, r, n), () => t.removeEventListener(e, r, n);
|
|
357
361
|
}
|
|
358
|
-
function
|
|
362
|
+
function Mt(t) {
|
|
359
363
|
return function(e) {
|
|
360
364
|
return e.preventDefault(), t.call(this, e);
|
|
361
365
|
};
|
|
@@ -388,7 +392,7 @@ function ae(t, e) {
|
|
|
388
392
|
e = "" + e, t.data !== e && (t.data = /** @type {string} */
|
|
389
393
|
e);
|
|
390
394
|
}
|
|
391
|
-
function
|
|
395
|
+
function lt(t, e) {
|
|
392
396
|
t.value = e ?? "";
|
|
393
397
|
}
|
|
394
398
|
function pn(t, e, { bubbles: r = !1, cancelable: n = !1 } = {}) {
|
|
@@ -398,16 +402,16 @@ let be;
|
|
|
398
402
|
function Ae(t) {
|
|
399
403
|
be = t;
|
|
400
404
|
}
|
|
401
|
-
function
|
|
405
|
+
function Se() {
|
|
402
406
|
if (!be)
|
|
403
407
|
throw new Error("Function called outside component initialization");
|
|
404
408
|
return be;
|
|
405
409
|
}
|
|
406
|
-
function
|
|
407
|
-
|
|
410
|
+
function Oe(t) {
|
|
411
|
+
Se().$$.on_mount.push(t);
|
|
408
412
|
}
|
|
409
413
|
function _n() {
|
|
410
|
-
const t =
|
|
414
|
+
const t = Se();
|
|
411
415
|
return (e, r, { cancelable: n = !1 } = {}) => {
|
|
412
416
|
const i = t.$$.callbacks[e];
|
|
413
417
|
if (i) {
|
|
@@ -425,12 +429,12 @@ function _n() {
|
|
|
425
429
|
};
|
|
426
430
|
}
|
|
427
431
|
function An(t, e) {
|
|
428
|
-
return
|
|
432
|
+
return Se().$$.context.set(t, e), e;
|
|
429
433
|
}
|
|
430
434
|
function hn(t) {
|
|
431
|
-
return
|
|
435
|
+
return Se().$$.context.get(t);
|
|
432
436
|
}
|
|
433
|
-
function
|
|
437
|
+
function Ct(t, e) {
|
|
434
438
|
const r = t.$$.callbacks[e.type];
|
|
435
439
|
r && r.slice().forEach((n) => n.call(this, e));
|
|
436
440
|
}
|
|
@@ -487,7 +491,7 @@ function kn(t) {
|
|
|
487
491
|
}
|
|
488
492
|
const Pe = /* @__PURE__ */ new Set();
|
|
489
493
|
let re;
|
|
490
|
-
function
|
|
494
|
+
function H() {
|
|
491
495
|
re = {
|
|
492
496
|
r: 0,
|
|
493
497
|
c: [],
|
|
@@ -495,7 +499,7 @@ function Y() {
|
|
|
495
499
|
// parent group
|
|
496
500
|
};
|
|
497
501
|
}
|
|
498
|
-
function
|
|
502
|
+
function K() {
|
|
499
503
|
re.r || we(re.c), re = re.p;
|
|
500
504
|
}
|
|
501
505
|
function f(t, e) {
|
|
@@ -542,7 +546,7 @@ function N(t, e, r, n, i, o, s = null, l = [-1]) {
|
|
|
542
546
|
props: o,
|
|
543
547
|
update: v,
|
|
544
548
|
not_equal: i,
|
|
545
|
-
bound:
|
|
549
|
+
bound: ot(),
|
|
546
550
|
// lifecycle
|
|
547
551
|
on_mount: [],
|
|
548
552
|
on_destroy: [],
|
|
@@ -551,7 +555,7 @@ function N(t, e, r, n, i, o, s = null, l = [-1]) {
|
|
|
551
555
|
after_update: [],
|
|
552
556
|
context: new Map(e.context || (c ? c.$$.context : [])),
|
|
553
557
|
// everything else
|
|
554
|
-
callbacks:
|
|
558
|
+
callbacks: ot(),
|
|
555
559
|
dirty: l,
|
|
556
560
|
skip_bound: !1,
|
|
557
561
|
root: e.target || c.$$.root
|
|
@@ -691,7 +695,7 @@ function Dn(t) {
|
|
|
691
695
|
);
|
|
692
696
|
return {
|
|
693
697
|
c() {
|
|
694
|
-
i && i.c(), r =
|
|
698
|
+
i && i.c(), r = te();
|
|
695
699
|
},
|
|
696
700
|
m(o, s) {
|
|
697
701
|
i && i.m(o, s), p(o, r, s), n = !0;
|
|
@@ -718,7 +722,7 @@ function Dn(t) {
|
|
|
718
722
|
}
|
|
719
723
|
};
|
|
720
724
|
}
|
|
721
|
-
function
|
|
725
|
+
function Mn(t, e, r) {
|
|
722
726
|
let { $$slots: n = {}, $$scope: i } = e, { as: o = "section" } = e;
|
|
723
727
|
return t.$$set = (s) => {
|
|
724
728
|
"as" in s && r(0, o = s.as), "$$scope" in s && r(1, i = s.$$scope);
|
|
@@ -726,10 +730,10 @@ function Cn(t, e, r) {
|
|
|
726
730
|
}
|
|
727
731
|
class ue extends U {
|
|
728
732
|
constructor(e) {
|
|
729
|
-
super(), N(this, e,
|
|
733
|
+
super(), N(this, e, Mn, Dn, T, { as: 0 }, Bn);
|
|
730
734
|
}
|
|
731
735
|
}
|
|
732
|
-
function
|
|
736
|
+
function Cn(t) {
|
|
733
737
|
x(t, "svelte-gf0gr5", ".rcb-pricing-info.svelte-gf0gr5{display:flex;flex-direction:column;margin-top:102px;font-weight:500}.rcb-product-price.svelte-gf0gr5{font-size:24px;margin:12px 0px}.rcb-product-price-after-trial.svelte-gf0gr5{margin-bottom:12px}.rcb-product-details.svelte-gf0gr5{opacity:0.6;list-style-type:disc;list-style-position:inside;margin:0px;padding:0px}@media screen and (max-width: 960px){.rcb-pricing-info.svelte-gf0gr5{margin-top:48px}}");
|
|
734
738
|
}
|
|
735
739
|
function Qn(t) {
|
|
@@ -739,7 +743,7 @@ function Qn(t) {
|
|
|
739
743
|
) + "", r, n;
|
|
740
744
|
return {
|
|
741
745
|
c() {
|
|
742
|
-
r =
|
|
746
|
+
r = L(e), n = L(" free trial");
|
|
743
747
|
},
|
|
744
748
|
m(i, o) {
|
|
745
749
|
p(i, r, o), p(i, n, o);
|
|
@@ -754,7 +758,7 @@ function Pn(t) {
|
|
|
754
758
|
let e = (
|
|
755
759
|
/*basePrice*/
|
|
756
760
|
(t[2].currency || "") + ""
|
|
757
|
-
), r, n, i =
|
|
761
|
+
), r, n, i = Ve(
|
|
758
762
|
/*basePrice*/
|
|
759
763
|
t[2].amount,
|
|
760
764
|
/*basePrice*/
|
|
@@ -762,7 +766,7 @@ function Pn(t) {
|
|
|
762
766
|
) + "", o;
|
|
763
767
|
return {
|
|
764
768
|
c() {
|
|
765
|
-
r =
|
|
769
|
+
r = L(e), n = P(), o = L(i);
|
|
766
770
|
},
|
|
767
771
|
m(s, l) {
|
|
768
772
|
p(s, r, l), p(s, n, l), p(s, o, l);
|
|
@@ -780,7 +784,7 @@ function Tn(t) {
|
|
|
780
784
|
e = k("span"), e.textContent = `${/*trial*/
|
|
781
785
|
t[1] && /*basePrice*/
|
|
782
786
|
t[2] && `${/*basePrice*/
|
|
783
|
-
t[2].currency} ${
|
|
787
|
+
t[2].currency} ${Ve(
|
|
784
788
|
/*basePrice*/
|
|
785
789
|
t[2].amount,
|
|
786
790
|
/*basePrice*/
|
|
@@ -796,21 +800,21 @@ function Tn(t) {
|
|
|
796
800
|
}
|
|
797
801
|
};
|
|
798
802
|
}
|
|
799
|
-
function
|
|
800
|
-
let e, r, n =
|
|
803
|
+
function ct(t) {
|
|
804
|
+
let e, r, n = nt(
|
|
801
805
|
/*productDetails*/
|
|
802
806
|
t[0].normalPeriodDuration
|
|
803
807
|
) + "", i;
|
|
804
808
|
return {
|
|
805
809
|
c() {
|
|
806
|
-
e = k("li"), r =
|
|
810
|
+
e = k("li"), r = L("Renews "), i = L(n);
|
|
807
811
|
},
|
|
808
812
|
m(o, s) {
|
|
809
|
-
p(o, e, s),
|
|
813
|
+
p(o, e, s), C(e, r), C(e, i);
|
|
810
814
|
},
|
|
811
815
|
p(o, s) {
|
|
812
816
|
s & /*productDetails*/
|
|
813
|
-
1 && n !== (n =
|
|
817
|
+
1 && n !== (n = nt(
|
|
814
818
|
/*productDetails*/
|
|
815
819
|
o[0].normalPeriodDuration
|
|
816
820
|
) + "") && ae(i, n);
|
|
@@ -821,13 +825,13 @@ function lt(t) {
|
|
|
821
825
|
};
|
|
822
826
|
}
|
|
823
827
|
function Nn(t) {
|
|
824
|
-
var
|
|
828
|
+
var M, ve;
|
|
825
829
|
let e, r, n = (
|
|
826
830
|
/*productDetails*/
|
|
827
831
|
t[0].displayName + ""
|
|
828
832
|
), i, o, s, l, c, a, u, d, h, $, E, B = (
|
|
829
833
|
/*trial*/
|
|
830
|
-
((
|
|
834
|
+
((M = t[1]) == null ? void 0 : M.periodDuration) && Qn(t)
|
|
831
835
|
), A = !/*trial*/
|
|
832
836
|
((ve = t[1]) != null && ve.periodDuration) && /*basePrice*/
|
|
833
837
|
t[2] && Pn(t), y = (
|
|
@@ -836,26 +840,26 @@ function Nn(t) {
|
|
|
836
840
|
t[2] && Tn(t)
|
|
837
841
|
), R = (
|
|
838
842
|
/*productDetails*/
|
|
839
|
-
t[0].normalPeriodDuration &&
|
|
843
|
+
t[0].normalPeriodDuration && ct(t)
|
|
840
844
|
);
|
|
841
845
|
return {
|
|
842
846
|
c() {
|
|
843
|
-
e = k("div"), r = k("span"), i =
|
|
847
|
+
e = k("div"), r = k("span"), i = L(n), o = P(), s = k("span"), B && B.c(), l = P(), A && A.c(), c = P(), y && y.c(), a = P(), u = k("ul"), R && R.c(), d = P(), h = k("li"), h.textContent = "Continues until canceled", $ = P(), E = k("li"), E.textContent = "Cancel anytime", _(s, "class", "rcb-product-price svelte-gf0gr5"), _(u, "class", "rcb-product-details svelte-gf0gr5"), _(e, "class", "rcb-pricing-info svelte-gf0gr5");
|
|
844
848
|
},
|
|
845
|
-
m(F,
|
|
846
|
-
p(F, e,
|
|
849
|
+
m(F, S) {
|
|
850
|
+
p(F, e, S), C(e, r), C(r, i), C(e, o), C(e, s), B && B.m(s, null), C(s, l), A && A.m(s, null), C(e, c), y && y.m(e, null), C(e, a), C(e, u), R && R.m(u, null), C(u, d), C(u, h), C(u, $), C(u, E);
|
|
847
851
|
},
|
|
848
|
-
p(F,
|
|
852
|
+
p(F, S) {
|
|
849
853
|
var ye, Be;
|
|
850
|
-
|
|
854
|
+
S & /*productDetails*/
|
|
851
855
|
1 && n !== (n = /*productDetails*/
|
|
852
856
|
F[0].displayName + "") && ae(i, n), /*trial*/
|
|
853
|
-
(ye = F[1]) != null && ye.periodDuration && B.p(F,
|
|
857
|
+
(ye = F[1]) != null && ye.periodDuration && B.p(F, S), !/*trial*/
|
|
854
858
|
((Be = F[1]) != null && Be.periodDuration) && /*basePrice*/
|
|
855
|
-
F[2] && A.p(F,
|
|
859
|
+
F[2] && A.p(F, S), /*trial*/
|
|
856
860
|
F[1] && /*basePrice*/
|
|
857
|
-
F[2] && y.p(F,
|
|
858
|
-
F[0].normalPeriodDuration ? R ? R.p(F,
|
|
861
|
+
F[2] && y.p(F, S), /*productDetails*/
|
|
862
|
+
F[0].normalPeriodDuration ? R ? R.p(F, S) : (R = ct(F), R.c(), R.m(u, d)) : R && (R.d(1), R = null);
|
|
859
863
|
},
|
|
860
864
|
d(F) {
|
|
861
865
|
F && g(e), B && B.d(), A && A.d(), y && y.d(), R && R.d();
|
|
@@ -902,15 +906,15 @@ function Rn(t, e, r) {
|
|
|
902
906
|
}
|
|
903
907
|
class Pt extends U {
|
|
904
908
|
constructor(e) {
|
|
905
|
-
super(), N(this, e, Rn, Un, T, { productDetails: 0, purchaseOption: 3 },
|
|
909
|
+
super(), N(this, e, Rn, Un, T, { productDetails: 0, purchaseOption: 3 }, Cn);
|
|
906
910
|
}
|
|
907
911
|
}
|
|
908
|
-
const On = "data:image/gif;base64,R0lGODlhMgAyAPcBAAAAAAD/AAMDAwcHBxERERUVFSoqKi0tLTAwMDg4OD09PURERElJSUtLS1BQUFJSUlVVVVdXV1paWl9fX2NjY2ZmZmlpaWxsbG1tbXNzc3t7e39/f4GBgYKCgoSEhIaGhoeHh4iIiIuLi5KSkpSUlJaWlp2dnaGhoaOjo6SkpKWlpaenp6ioqKqqqqurq6ysrLCwsLGxsbS0tLa2tri4uLm5ub29vb6+vsDAwMHBwcLCwsXFxcjIyMnJyc3Nzc7OztPT09TU1NXV1dfX19nZ2dra2tvb29zc3N7e3uDg4OHh4eLi4uPj4+fn5+np6ezs7O7u7vDw8PHx8fLy8vPz8/X19fb29vj4+Pn5+fz8/P39/f7+/v///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////yH/C05FVFNDQVBFMi4wAwEAAAAh+QQFBAABACwAAAAAMgAyAIcAAAAA/wADAwMHBwcREREVFRUqKiotLS0wMDA4ODg9PT1ERERJSUlLS0tQUFBSUlJVVVVXV1daWlpfX19jY2NmZmZpaWlsbGxtbW1zc3N7e3t/f3+BgYGCgoKEhISGhoaHh4eIiIiLi4uSkpKUlJSWlpadnZ2hoaGjo6OkpKSlpaWnp6eoqKiqqqqrq6usrKywsLCxsbG0tLS2tra4uLi5ubm9vb2+vr7AwMDBwcHCwsLFxcXIyMjJycnNzc3Ozs7T09PU1NTV1dXX19fZ2dna2trb29vc3Nze3t7g4ODh4eHi4uLj4+Pn5+fp6ens7Ozu7u7w8PDx8fHy8vLz8/P19fX29vb4+Pj5+fn8/Pz9/f3+/v7///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////8I/wCzcBFIcKDBgggPKkzIcCEXLlq4bIEokeLEiBcrYrTIcaNHjRobinQ4sqRCkBlTdtR44MBKlR9TmjQJQMBMkgZfdpwSMSYAACgpRtHpcSYSFUIa1mz448UQnAWDfmzSooUVmD9XVnnBwglMlDdvvMjhcOlCHit23CSqcUrVJiizpnTC4sXQmB1vZvmxwgYWhWYLznjRA+rJryqvxGhxxGNLjkVcwMCCN6ZeLkNevDCcRYYKJJfZptyCQwdiijl0CDxdlLPryw2lymY9WzTs17ijVq69mzbM28Bd8x7u23bu46F7i16uXEvw5ziJM5duGbl1k9OLN5cKvfvh7OC3b0jxTv6h+PDUy3unzl67RPXXc56fnz4+/PbofcOHnr9/5f3x4UeffvYVqJuACP5m4IIJ+gfWgusN6KCCAN7WoITVVXjchBxqERAAIfkEBQQAAQAsDQADACAAEAAACKcAAwgcSDDAAwcFEypcSNDAAYYQA2DZstCAAYZOKCqM8uNJxYcKa3DYsVBKECBYFFpU+MTDhiIMkQxBohJkwRYaUkDEEiQIlYQrCyLZ0MFJRCdAkgC1OZBEBxgRJRIBAqXgwYI8NoCwEjWAkyFDoorQ4KOrQCRLoqbQuZCKR7NdqzD5MaQKXIhZmAwBIqTJ3YVYogQZ8oMJ178Kk/A1YhfxQiRHjBYMCAAh+QQFBQABACwNAAMAIAAQAAAInQADCBxIMECGDAUTKlxI8EEEhhADcGEI4QFDJQy5ZJmo0OFCFBFkLNzCRQvHghEgKHQi4cEPhhuzdHyYUMQDDxC5kNSSsGLCIA4x5oxZ0GNBDBFKRAxgkmTBgwVpRJhAZWkAohErPKhhVaLJpR8+YFnohEjXrlB2qHgB5SxELD5etHgBxC1DJC9eqOAxxe5CHSxc0HDilyEOGWYLBgQAIfkEBQQAAQAsGAADABcAFwAACJYA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qqqqurq6ysrLCwsLGxsbS0tLa2tri4uLm5ub29vb6+vsDAwMHBwcLCwsXFxcjIyMnJyc3Nzc7OztPT09TU1NXV1dfX19nZ2dra2tvb29zc3N7e3uDg4OHh4eLi4uPj4+fn5+np6ezs7O7u7vDw8PHx8fLy8vPz8/X19fb29vj4+Pn5+fz8/P39/f7+/v///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////yH/C05FVFNDQVBFMi4wAwEAAAAh+QQFBAABACwAAAAAMgAyAIcAAAAA/wADAwMHBwcREREVFRUqKiotLS0wMDA4ODg9PT1ERERJSUlLS0tQUFBSUlJVVVVXV1daWlpfX19jY2NmZmZpaWlsbGxtbW1zc3N7e3t/f3+BgYGCgoKEhISGhoaHh4eIiIiLi4uSkpKUlJSWlpadnZ2hoaGjo6OkpKSlpaWnp6eoqKiqqqqrq6usrKywsLCxsbG0tLS2tra4uLi5ubm9vb2+vr7AwMDBwcHCwsLFxcXIyMjJycnNzc3Ozs7T09PU1NTV1dXX19fZ2dna2trb29vc3Nze3t7g4ODh4eHi4uLj4+Pn5+fp6ens7Ozu7u7w8PDx8fHy8vLz8/P19fX29vb4+Pj5+fn8/Pz9/f3+/v7///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////8I/wCzcBFIcKDBgggPKkzIcCEXLlq4bIEokeLEiBcrYrTIcaNHjRobinQ4sqRCkBlTdtR44MBKlR9TmjQJQMBMkgZfdpwSMSYAACgpRtHpcSYSFUIa1mz448UQn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MDgRpIBoCQwsKIgQpwBUBxIULEHkYcUUC580tDEE6AGbXSYKKMKVIJSUnDQIGIHl6sQS0w8AZagjxAsyqpdy7at24pJfgwBMkQukCRQjQQBIgTIXiFGoAYEACH5BAUFAAEALAMAAwAXABcAAAiVAAMIHEiwoMEMGQwqXPggwsKBTLQshPDgYYAaD1owdPjQB4QIThRGgGAxwIYIIBQ2LMlkJBCDFEsGOPEgA5aCK0tKmQChRkGEMgPIiDDhoRYjTR56CPGwiooXN6oENQikhYsWP65MJXglx4sVMoZsJdikRosWOMYSRPJih9q3cOPKnWuRSxa7eO9O3cJFCxe+frdMDQgAIfkEBQUAAQAsBQADACAAEAAACKYAAwgcSLAgwQcODCpcyNDAAYYQAzhpaIDhFYY+NOBY6HAhkyETFRLZ0CGKQgMVDV4RAoQKQxMdUpx8aJAJECYQnWzYcMQgSoNVgAy5CHGGhhI+aRIkMgRnxCohNvQoiLDgEyFDskQUuINDiK1Hfpgc+ETKQi0nVGxNkkSrwCw/hiBxu7XuFidAhARpgqWu3yxIhgApEtLvVipIgARBYthvlKaNFQYEADs=";
|
|
913
|
+
function On(t) {
|
|
910
914
|
let e, r;
|
|
911
915
|
return {
|
|
912
916
|
c() {
|
|
913
|
-
e = k("img"), Z(e.src, r =
|
|
917
|
+
e = k("img"), Z(e.src, r = Sn) || _(e, "src", r), _(e, "alt", "spinner");
|
|
914
918
|
},
|
|
915
919
|
m(n, i) {
|
|
916
920
|
p(n, e, i);
|
|
@@ -925,7 +929,7 @@ function Sn(t) {
|
|
|
925
929
|
}
|
|
926
930
|
class Ln extends U {
|
|
927
931
|
constructor(e) {
|
|
928
|
-
super(), N(this, e, null,
|
|
932
|
+
super(), N(this, e, null, On, T, {});
|
|
929
933
|
}
|
|
930
934
|
}
|
|
931
935
|
function xn(t) {
|
|
@@ -952,18 +956,181 @@ function Fn(t) {
|
|
|
952
956
|
}
|
|
953
957
|
};
|
|
954
958
|
}
|
|
955
|
-
class
|
|
959
|
+
class We extends U {
|
|
956
960
|
constructor(e) {
|
|
957
961
|
super(), N(this, e, null, Fn, T, {}, xn);
|
|
958
962
|
}
|
|
959
963
|
}
|
|
960
|
-
var
|
|
961
|
-
class
|
|
964
|
+
var ee = /* @__PURE__ */ ((t) => (t[t.UnknownError = 0] = "UnknownError", t[t.UserCancelledError = 1] = "UserCancelledError", t[t.StoreProblemError = 2] = "StoreProblemError", t[t.PurchaseNotAllowedError = 3] = "PurchaseNotAllowedError", t[t.PurchaseInvalidError = 4] = "PurchaseInvalidError", t[t.ProductNotAvailableForPurchaseError = 5] = "ProductNotAvailableForPurchaseError", t[t.ProductAlreadyPurchasedError = 6] = "ProductAlreadyPurchasedError", t[t.ReceiptAlreadyInUseError = 7] = "ReceiptAlreadyInUseError", t[t.InvalidReceiptError = 8] = "InvalidReceiptError", t[t.MissingReceiptFileError = 9] = "MissingReceiptFileError", t[t.NetworkError = 10] = "NetworkError", t[t.InvalidCredentialsError = 11] = "InvalidCredentialsError", t[t.UnexpectedBackendResponseError = 12] = "UnexpectedBackendResponseError", t[t.InvalidAppUserIdError = 14] = "InvalidAppUserIdError", t[t.OperationAlreadyInProgressError = 15] = "OperationAlreadyInProgressError", t[t.UnknownBackendError = 16] = "UnknownBackendError", t[t.InvalidAppleSubscriptionKeyError = 17] = "InvalidAppleSubscriptionKeyError", t[t.IneligibleError = 18] = "IneligibleError", t[t.InsufficientPermissionsError = 19] = "InsufficientPermissionsError", t[t.PaymentPendingError = 20] = "PaymentPendingError", t[t.InvalidSubscriberAttributesError = 21] = "InvalidSubscriberAttributesError", t[t.LogOutWithAnonymousUserError = 22] = "LogOutWithAnonymousUserError", t[t.ConfigurationError = 23] = "ConfigurationError", t[t.UnsupportedError = 24] = "UnsupportedError", t[t.EmptySubscriberAttributesError = 25] = "EmptySubscriberAttributesError", t[t.CustomerInfoError = 28] = "CustomerInfoError", t[t.SignatureVerificationError = 36] = "SignatureVerificationError", t))(ee || {});
|
|
965
|
+
class he {
|
|
966
|
+
static getPublicMessage(e) {
|
|
967
|
+
switch (e) {
|
|
968
|
+
case 0:
|
|
969
|
+
return "Unknown error.";
|
|
970
|
+
case 1:
|
|
971
|
+
return "Purchase was cancelled.";
|
|
972
|
+
case 2:
|
|
973
|
+
return "There was a problem with the store.";
|
|
974
|
+
case 3:
|
|
975
|
+
return "The device or user is not allowed to make the purchase.";
|
|
976
|
+
case 4:
|
|
977
|
+
return "One or more of the arguments provided are invalid.";
|
|
978
|
+
case 5:
|
|
979
|
+
return "The product is not available for purchase.";
|
|
980
|
+
case 6:
|
|
981
|
+
return "This product is already active for the user.";
|
|
982
|
+
case 7:
|
|
983
|
+
return "There is already another active subscriber using the same receipt.";
|
|
984
|
+
case 8:
|
|
985
|
+
return "The receipt is not valid.";
|
|
986
|
+
case 9:
|
|
987
|
+
return "The receipt is missing.";
|
|
988
|
+
case 10:
|
|
989
|
+
return "Error performing request.";
|
|
990
|
+
case 11:
|
|
991
|
+
return "There was a credentials issue. Check the underlying error for more details.";
|
|
992
|
+
case 12:
|
|
993
|
+
return "Received unexpected response from the backend.";
|
|
994
|
+
case 14:
|
|
995
|
+
return "The app user id is not valid.";
|
|
996
|
+
case 15:
|
|
997
|
+
return "The operation is already in progress.";
|
|
998
|
+
case 16:
|
|
999
|
+
return "There was an unknown backend error.";
|
|
1000
|
+
case 17:
|
|
1001
|
+
return "Apple Subscription Key is invalid or not present. In order to provide subscription offers, you must first generate a subscription key. Please see https://docs.revenuecat.com/docs/ios-subscription-offers for more info.";
|
|
1002
|
+
case 18:
|
|
1003
|
+
return "The User is ineligible for that action.";
|
|
1004
|
+
case 19:
|
|
1005
|
+
return "App does not have sufficient permissions to make purchases.";
|
|
1006
|
+
case 20:
|
|
1007
|
+
return "The payment is pending.";
|
|
1008
|
+
case 21:
|
|
1009
|
+
return "One or more of the attributes sent could not be saved.";
|
|
1010
|
+
case 22:
|
|
1011
|
+
return "Called logOut but the current user is anonymous.";
|
|
1012
|
+
case 23:
|
|
1013
|
+
return "There is an issue with your configuration. Check the underlying error for more details.";
|
|
1014
|
+
case 24:
|
|
1015
|
+
return "There was a problem with the operation. Looks like we doesn't support that yet. Check the underlying error for more details.";
|
|
1016
|
+
case 25:
|
|
1017
|
+
return "A request for subscriber attributes returned none.";
|
|
1018
|
+
case 28:
|
|
1019
|
+
return "There was a problem related to the customer info.";
|
|
1020
|
+
case 36:
|
|
1021
|
+
return "Request failed signature verification. Please see https://rev.cat/trusted-entitlements for more info.";
|
|
1022
|
+
}
|
|
1023
|
+
}
|
|
1024
|
+
static getErrorCodeForBackendErrorCode(e) {
|
|
1025
|
+
switch (e) {
|
|
1026
|
+
case 7101:
|
|
1027
|
+
return 2;
|
|
1028
|
+
case 7102:
|
|
1029
|
+
return 7;
|
|
1030
|
+
case 7103:
|
|
1031
|
+
return 8;
|
|
1032
|
+
case 7107:
|
|
1033
|
+
case 7224:
|
|
1034
|
+
case 7225:
|
|
1035
|
+
return 11;
|
|
1036
|
+
case 7105:
|
|
1037
|
+
case 7106:
|
|
1038
|
+
case 7814:
|
|
1039
|
+
return 4;
|
|
1040
|
+
case 7772:
|
|
1041
|
+
return 6;
|
|
1042
|
+
case 7220:
|
|
1043
|
+
return 14;
|
|
1044
|
+
case 7229:
|
|
1045
|
+
return 2;
|
|
1046
|
+
case 7230:
|
|
1047
|
+
case 7e3:
|
|
1048
|
+
return 23;
|
|
1049
|
+
case 7231:
|
|
1050
|
+
return 2;
|
|
1051
|
+
case 7232:
|
|
1052
|
+
return 18;
|
|
1053
|
+
case 7263:
|
|
1054
|
+
case 7264:
|
|
1055
|
+
return 21;
|
|
1056
|
+
case 7104:
|
|
1057
|
+
case 7234:
|
|
1058
|
+
case 7226:
|
|
1059
|
+
case 7110:
|
|
1060
|
+
return 12;
|
|
1061
|
+
case 7662:
|
|
1062
|
+
return 24;
|
|
1063
|
+
}
|
|
1064
|
+
}
|
|
1065
|
+
static convertCodeToBackendErrorCode(e) {
|
|
1066
|
+
return e in Tt ? e : null;
|
|
1067
|
+
}
|
|
1068
|
+
static convertPurchaseFlowErrorCodeToErrorCode(e) {
|
|
1069
|
+
switch (e) {
|
|
1070
|
+
case O.ErrorSettingUpPurchase:
|
|
1071
|
+
return 2;
|
|
1072
|
+
case O.ErrorChargingPayment:
|
|
1073
|
+
return 20;
|
|
1074
|
+
case O.NetworkError:
|
|
1075
|
+
return 10;
|
|
1076
|
+
case O.MissingEmailError:
|
|
1077
|
+
return 4;
|
|
1078
|
+
case O.StripeError:
|
|
1079
|
+
return 2;
|
|
1080
|
+
case O.UnknownError:
|
|
1081
|
+
return 0;
|
|
1082
|
+
case O.AlreadySubscribedError:
|
|
1083
|
+
return 6;
|
|
1084
|
+
}
|
|
1085
|
+
}
|
|
1086
|
+
}
|
|
1087
|
+
var Tt = /* @__PURE__ */ ((t) => (t[t.BackendInvalidPlatform = 7e3] = "BackendInvalidPlatform", t[t.BackendStoreProblem = 7101] = "BackendStoreProblem", t[t.BackendCannotTransferPurchase = 7102] = "BackendCannotTransferPurchase", t[t.BackendInvalidReceiptToken = 7103] = "BackendInvalidReceiptToken", t[t.BackendInvalidAppStoreSharedSecret = 7104] = "BackendInvalidAppStoreSharedSecret", t[t.BackendInvalidPaymentModeOrIntroPriceNotProvided = 7105] = "BackendInvalidPaymentModeOrIntroPriceNotProvided", t[t.BackendProductIdForGoogleReceiptNotProvided = 7106] = "BackendProductIdForGoogleReceiptNotProvided", t[t.BackendInvalidPlayStoreCredentials = 7107] = "BackendInvalidPlayStoreCredentials", t[t.BackendInternalServerError = 7110] = "BackendInternalServerError", t[t.BackendEmptyAppUserId = 7220] = "BackendEmptyAppUserId", t[t.BackendInvalidAuthToken = 7224] = "BackendInvalidAuthToken", t[t.BackendInvalidAPIKey = 7225] = "BackendInvalidAPIKey", t[t.BackendBadRequest = 7226] = "BackendBadRequest", t[t.BackendPlayStoreQuotaExceeded = 7229] = "BackendPlayStoreQuotaExceeded", t[t.BackendPlayStoreInvalidPackageName = 7230] = "BackendPlayStoreInvalidPackageName", t[t.BackendPlayStoreGenericError = 7231] = "BackendPlayStoreGenericError", t[t.BackendUserIneligibleForPromoOffer = 7232] = "BackendUserIneligibleForPromoOffer", t[t.BackendInvalidAppleSubscriptionKey = 7234] = "BackendInvalidAppleSubscriptionKey", t[t.BackendInvalidSubscriberAttributes = 7263] = "BackendInvalidSubscriberAttributes", t[t.BackendInvalidSubscriberAttributesBody = 7264] = "BackendInvalidSubscriberAttributesBody", t[t.BackendProductIDsMalformed = 7662] = "BackendProductIDsMalformed", t[t.BackendAlreadySubscribedError = 7772] = "BackendAlreadySubscribedError", t[t.BackendOfferNotFound = 7814] = "BackendOfferNotFound", t))(Tt || {});
|
|
1088
|
+
class X extends Error {
|
|
1089
|
+
constructor(r, n, i) {
|
|
1090
|
+
super(n);
|
|
1091
|
+
Q(this, "toString", () => `PurchasesError(code: ${ee[this.errorCode]}, message: ${this.message})`);
|
|
1092
|
+
this.errorCode = r, this.underlyingErrorMessage = i;
|
|
1093
|
+
}
|
|
1094
|
+
/** @internal */
|
|
1095
|
+
static getForBackendError(r, n) {
|
|
1096
|
+
const i = he.getErrorCodeForBackendErrorCode(r);
|
|
1097
|
+
return new X(
|
|
1098
|
+
i,
|
|
1099
|
+
he.getPublicMessage(i),
|
|
1100
|
+
n
|
|
1101
|
+
);
|
|
1102
|
+
}
|
|
1103
|
+
/** @internal */
|
|
1104
|
+
static getForPurchasesFlowError(r) {
|
|
1105
|
+
return new X(
|
|
1106
|
+
he.convertPurchaseFlowErrorCodeToErrorCode(
|
|
1107
|
+
r.errorCode
|
|
1108
|
+
),
|
|
1109
|
+
r.message,
|
|
1110
|
+
r.underlyingErrorMessage
|
|
1111
|
+
);
|
|
1112
|
+
}
|
|
1113
|
+
}
|
|
1114
|
+
class Gn extends Error {
|
|
1115
|
+
constructor() {
|
|
1116
|
+
super("Purchases must be configured before calling getInstance");
|
|
1117
|
+
}
|
|
1118
|
+
}
|
|
1119
|
+
var pe = /* @__PURE__ */ ((t) => (t.Started = "started", t.InProgress = "in_progress", t.Succeeded = "succeeded", t.Failed = "failed", t))(pe || {}), Te = /* @__PURE__ */ ((t) => (t[t.SetupIntentCreationFailed = 1] = "SetupIntentCreationFailed", t[t.PaymentMethodCreationFailed = 2] = "PaymentMethodCreationFailed", t[t.PaymentChargeFailed = 3] = "PaymentChargeFailed", t))(Te || {}), O = /* @__PURE__ */ ((t) => (t[t.ErrorSettingUpPurchase = 0] = "ErrorSettingUpPurchase", t[t.ErrorChargingPayment = 1] = "ErrorChargingPayment", t[t.UnknownError = 2] = "UnknownError", t[t.NetworkError = 3] = "NetworkError", t[t.StripeError = 4] = "StripeError", t[t.MissingEmailError = 5] = "MissingEmailError", t[t.AlreadySubscribedError = 6] = "AlreadySubscribedError", t))(O || {});
|
|
1120
|
+
class Y extends Error {
|
|
962
1121
|
constructor(e, r, n) {
|
|
963
1122
|
super(r), this.errorCode = e, this.underlyingErrorMessage = n;
|
|
964
1123
|
}
|
|
1124
|
+
static fromPurchasesError(e, r) {
|
|
1125
|
+
let n;
|
|
1126
|
+
return e.errorCode === ee.ProductAlreadyPurchasedError ? n = 6 : n = r, new Y(
|
|
1127
|
+
n,
|
|
1128
|
+
e.message,
|
|
1129
|
+
e.underlyingErrorMessage
|
|
1130
|
+
);
|
|
1131
|
+
}
|
|
965
1132
|
}
|
|
966
|
-
class
|
|
1133
|
+
class Yn {
|
|
967
1134
|
constructor(e, r = 10) {
|
|
968
1135
|
Q(this, "operationSessionId", null);
|
|
969
1136
|
Q(this, "backend");
|
|
@@ -972,19 +1139,35 @@ class Gn {
|
|
|
972
1139
|
this.backend = e, this.maxNumberAttempts = r;
|
|
973
1140
|
}
|
|
974
1141
|
async startPurchase(e, r, n, i, o) {
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
1142
|
+
try {
|
|
1143
|
+
const s = await this.backend.postSubscribe(
|
|
1144
|
+
e,
|
|
1145
|
+
r,
|
|
1146
|
+
i,
|
|
1147
|
+
o,
|
|
1148
|
+
n == null ? void 0 : n.id
|
|
1149
|
+
);
|
|
1150
|
+
return this.operationSessionId = s.operation_session_id, s;
|
|
1151
|
+
} catch (s) {
|
|
1152
|
+
if (s instanceof X)
|
|
1153
|
+
throw Y.fromPurchasesError(
|
|
1154
|
+
s,
|
|
1155
|
+
0
|
|
1156
|
+
/* ErrorSettingUpPurchase */
|
|
1157
|
+
);
|
|
1158
|
+
{
|
|
1159
|
+
const l = "Unknown error starting purchase: " + String(s);
|
|
1160
|
+
throw G.errorLog(l), new Y(
|
|
1161
|
+
2,
|
|
1162
|
+
l
|
|
1163
|
+
);
|
|
1164
|
+
}
|
|
1165
|
+
}
|
|
983
1166
|
}
|
|
984
1167
|
async pollCurrentPurchaseForCompletion() {
|
|
985
1168
|
const e = this.operationSessionId;
|
|
986
1169
|
if (!e)
|
|
987
|
-
throw new
|
|
1170
|
+
throw new Y(
|
|
988
1171
|
0,
|
|
989
1172
|
"No purchase in progress"
|
|
990
1173
|
);
|
|
@@ -992,7 +1175,7 @@ class Gn {
|
|
|
992
1175
|
const i = (o = 1) => {
|
|
993
1176
|
if (o > this.maxNumberAttempts) {
|
|
994
1177
|
this.clearPurchaseInProgress(), n(
|
|
995
|
-
new
|
|
1178
|
+
new Y(
|
|
996
1179
|
2,
|
|
997
1180
|
"Max attempts reached trying to get successful purchase status"
|
|
998
1181
|
)
|
|
@@ -1018,12 +1201,12 @@ class Gn {
|
|
|
1018
1201
|
);
|
|
1019
1202
|
}
|
|
1020
1203
|
}).catch((s) => {
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
)
|
|
1204
|
+
const l = Y.fromPurchasesError(
|
|
1205
|
+
s,
|
|
1206
|
+
3
|
|
1207
|
+
/* NetworkError */
|
|
1026
1208
|
);
|
|
1209
|
+
n(l);
|
|
1027
1210
|
});
|
|
1028
1211
|
};
|
|
1029
1212
|
i();
|
|
@@ -1035,7 +1218,7 @@ class Gn {
|
|
|
1035
1218
|
handlePaymentError(e, r) {
|
|
1036
1219
|
if (e == null) {
|
|
1037
1220
|
r(
|
|
1038
|
-
new
|
|
1221
|
+
new Y(
|
|
1039
1222
|
2,
|
|
1040
1223
|
"Got an error status but error field is empty."
|
|
1041
1224
|
)
|
|
@@ -1045,7 +1228,7 @@ class Gn {
|
|
|
1045
1228
|
switch (e.code) {
|
|
1046
1229
|
case Te.SetupIntentCreationFailed:
|
|
1047
1230
|
r(
|
|
1048
|
-
new
|
|
1231
|
+
new Y(
|
|
1049
1232
|
0,
|
|
1050
1233
|
"Setup intent creation failed"
|
|
1051
1234
|
)
|
|
@@ -1053,7 +1236,7 @@ class Gn {
|
|
|
1053
1236
|
return;
|
|
1054
1237
|
case Te.PaymentMethodCreationFailed:
|
|
1055
1238
|
r(
|
|
1056
|
-
new
|
|
1239
|
+
new Y(
|
|
1057
1240
|
0,
|
|
1058
1241
|
"Payment method creation failed"
|
|
1059
1242
|
)
|
|
@@ -1061,7 +1244,7 @@ class Gn {
|
|
|
1061
1244
|
return;
|
|
1062
1245
|
case Te.PaymentChargeFailed:
|
|
1063
1246
|
r(
|
|
1064
|
-
new
|
|
1247
|
+
new Y(
|
|
1065
1248
|
1,
|
|
1066
1249
|
"Payment charge failed"
|
|
1067
1250
|
)
|
|
@@ -1070,15 +1253,15 @@ class Gn {
|
|
|
1070
1253
|
}
|
|
1071
1254
|
}
|
|
1072
1255
|
}
|
|
1073
|
-
const
|
|
1074
|
-
function
|
|
1256
|
+
const Hn = "data:image/svg+xml,%3csvg%20width='124'%20height='124'%20viewBox='0%200%20124%20124'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3ccircle%20cx='62'%20cy='62'%20r='62'%20fill='%23767676'/%3e%3cpath%20d='M87.6668%2041.504L82.4968%2036.334L62.0002%2056.8307L41.5035%2036.334L36.3335%2041.504L56.8302%2062.0006L36.3335%2082.4973L41.5035%2087.6673L62.0002%2067.1706L82.4968%2087.6673L87.6668%2082.4973L67.1702%2062.0006L87.6668%2041.504Z'%20fill='white'/%3e%3c/svg%3e";
|
|
1257
|
+
function Kn(t) {
|
|
1075
1258
|
x(t, "svelte-1609h93", "img.svelte-1609h93{width:124px;height:124px;margin:0 auto}");
|
|
1076
1259
|
}
|
|
1077
|
-
function
|
|
1260
|
+
function qn(t) {
|
|
1078
1261
|
let e, r;
|
|
1079
1262
|
return {
|
|
1080
1263
|
c() {
|
|
1081
|
-
e = k("img"), Z(e.src, r =
|
|
1264
|
+
e = k("img"), Z(e.src, r = Hn) || _(e, "src", r), _(e, "alt", "icon"), _(e, "class", "rcb-ui-asset-icon svelte-1609h93");
|
|
1082
1265
|
},
|
|
1083
1266
|
m(n, i) {
|
|
1084
1267
|
p(n, e, i);
|
|
@@ -1091,15 +1274,15 @@ function Kn(t) {
|
|
|
1091
1274
|
}
|
|
1092
1275
|
};
|
|
1093
1276
|
}
|
|
1094
|
-
class
|
|
1277
|
+
class jn extends U {
|
|
1095
1278
|
constructor(e) {
|
|
1096
|
-
super(), N(this, e, null,
|
|
1279
|
+
super(), N(this, e, null, qn, T, {}, Kn);
|
|
1097
1280
|
}
|
|
1098
1281
|
}
|
|
1099
|
-
function
|
|
1282
|
+
function Jn(t) {
|
|
1100
1283
|
x(t, "svelte-1rmxk7q", "button.svelte-1rmxk7q{border:none;border-radius:56px;font-size:16px;cursor:pointer;height:56px;color:var(--rc-color-grey-text-dark);background-color:var(--rc-color-grey-ui-dark);display:flex;align-items:center;justify-content:center}button.intent-primary.svelte-1rmxk7q{background-color:var(--rc-color-grey-text-dark);color:var(--rc-color-white);font-size:16px}button.svelte-1rmxk7q:disabled{color:var(--rc-color-grey-text-light)}button.intent-primary.svelte-1rmxk7q:disabled{color:var(--rc-color-grey-text-light)}");
|
|
1101
1284
|
}
|
|
1102
|
-
function
|
|
1285
|
+
function Vn(t) {
|
|
1103
1286
|
let e, r, n, i, o;
|
|
1104
1287
|
const s = (
|
|
1105
1288
|
/*#slots*/
|
|
@@ -1161,10 +1344,10 @@ function Jn(t) {
|
|
|
1161
1344
|
}
|
|
1162
1345
|
};
|
|
1163
1346
|
}
|
|
1164
|
-
function
|
|
1347
|
+
function Wn(t, e, r) {
|
|
1165
1348
|
let { $$slots: n = {}, $$scope: i } = e, { intent: o = "primary" } = e, { disabled: s = !1 } = e;
|
|
1166
1349
|
function l(c) {
|
|
1167
|
-
|
|
1350
|
+
Ct.call(this, t, c);
|
|
1168
1351
|
}
|
|
1169
1352
|
return t.$$set = (c) => {
|
|
1170
1353
|
"intent" in c && r(0, o = c.intent), "disabled" in c && r(1, s = c.disabled), "$$scope" in c && r(2, i = c.$$scope);
|
|
@@ -1172,13 +1355,13 @@ function Vn(t, e, r) {
|
|
|
1172
1355
|
}
|
|
1173
1356
|
class Ie extends U {
|
|
1174
1357
|
constructor(e) {
|
|
1175
|
-
super(), N(this, e,
|
|
1358
|
+
super(), N(this, e, Wn, Vn, T, { intent: 0, disabled: 1 }, Jn);
|
|
1176
1359
|
}
|
|
1177
1360
|
}
|
|
1178
|
-
function
|
|
1361
|
+
function zn(t) {
|
|
1179
1362
|
x(t, "svelte-1f9z0o8", "footer.svelte-1f9z0o8{display:flex;flex-direction:column}");
|
|
1180
1363
|
}
|
|
1181
|
-
function
|
|
1364
|
+
function Xn(t) {
|
|
1182
1365
|
let e, r;
|
|
1183
1366
|
const n = (
|
|
1184
1367
|
/*#slots*/
|
|
@@ -1229,21 +1412,21 @@ function zn(t) {
|
|
|
1229
1412
|
}
|
|
1230
1413
|
};
|
|
1231
1414
|
}
|
|
1232
|
-
function
|
|
1415
|
+
function Zn(t, e, r) {
|
|
1233
1416
|
let { $$slots: n = {}, $$scope: i } = e;
|
|
1234
1417
|
return t.$$set = (o) => {
|
|
1235
1418
|
"$$scope" in o && r(0, i = o.$$scope);
|
|
1236
1419
|
}, [i, n];
|
|
1237
1420
|
}
|
|
1238
|
-
class
|
|
1421
|
+
class ze extends U {
|
|
1239
1422
|
constructor(e) {
|
|
1240
|
-
super(), N(this, e,
|
|
1423
|
+
super(), N(this, e, Zn, Xn, T, {}, zn);
|
|
1241
1424
|
}
|
|
1242
1425
|
}
|
|
1243
|
-
function
|
|
1426
|
+
function er(t) {
|
|
1244
1427
|
x(t, "svelte-6o8e90", '.column.svelte-6o8e90{display:flex;flex-direction:column;justify-content:flex-start;gap:var(--gap, "8px");flex-grow:1}');
|
|
1245
1428
|
}
|
|
1246
|
-
function
|
|
1429
|
+
function tr(t) {
|
|
1247
1430
|
let e, r, n;
|
|
1248
1431
|
const i = (
|
|
1249
1432
|
/*#slots*/
|
|
@@ -1297,7 +1480,7 @@ function er(t) {
|
|
|
1297
1480
|
}
|
|
1298
1481
|
};
|
|
1299
1482
|
}
|
|
1300
|
-
function
|
|
1483
|
+
function nr(t, e, r) {
|
|
1301
1484
|
let { $$slots: n = {}, $$scope: i } = e, { gutter: o = "8px" } = e;
|
|
1302
1485
|
return t.$$set = (s) => {
|
|
1303
1486
|
"gutter" in s && r(0, o = s.gutter), "$$scope" in s && r(1, i = s.$$scope);
|
|
@@ -1305,22 +1488,22 @@ function tr(t, e, r) {
|
|
|
1305
1488
|
}
|
|
1306
1489
|
class $e extends U {
|
|
1307
1490
|
constructor(e) {
|
|
1308
|
-
super(), N(this, e,
|
|
1491
|
+
super(), N(this, e, nr, tr, T, { gutter: 0 }, er);
|
|
1309
1492
|
}
|
|
1310
1493
|
}
|
|
1311
|
-
const
|
|
1312
|
-
function
|
|
1494
|
+
const rr = "data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20id='mdi_close'%3e%3cpath%20id='Vector'%20d='M19%206.41L17.59%205L12%2010.59L6.41%205L5%206.41L10.59%2012L5%2017.59L6.41%2019L12%2013.41L17.59%2019L19%2017.59L13.41%2012L19%206.41Z'%20fill='%23767676'/%3e%3c/g%3e%3c/svg%3e";
|
|
1495
|
+
function ir(t) {
|
|
1313
1496
|
x(t, "svelte-14xreta", ".close-button.svelte-14xreta{border:none;cursor:pointer;background-color:transparent;padding:0px}");
|
|
1314
1497
|
}
|
|
1315
|
-
function
|
|
1498
|
+
function or(t) {
|
|
1316
1499
|
let e, r, n, i, o;
|
|
1317
1500
|
return {
|
|
1318
1501
|
c() {
|
|
1319
|
-
e = k("button"), r = k("img"), Z(r.src, n =
|
|
1502
|
+
e = k("button"), r = k("img"), Z(r.src, n = rr) || _(r, "src", n), _(r, "alt", "close"), _(e, "class", "close-button svelte-14xreta"), e.disabled = /*disabled*/
|
|
1320
1503
|
t[0];
|
|
1321
1504
|
},
|
|
1322
1505
|
m(s, l) {
|
|
1323
|
-
p(s, e, l),
|
|
1506
|
+
p(s, e, l), C(e, r), i || (o = ke(
|
|
1324
1507
|
e,
|
|
1325
1508
|
"click",
|
|
1326
1509
|
/*click_handler*/
|
|
@@ -1339,24 +1522,24 @@ function ir(t) {
|
|
|
1339
1522
|
}
|
|
1340
1523
|
};
|
|
1341
1524
|
}
|
|
1342
|
-
function
|
|
1525
|
+
function sr(t, e, r) {
|
|
1343
1526
|
let { disabled: n = !1 } = e;
|
|
1344
1527
|
function i(o) {
|
|
1345
|
-
|
|
1528
|
+
Ct.call(this, t, o);
|
|
1346
1529
|
}
|
|
1347
1530
|
return t.$$set = (o) => {
|
|
1348
1531
|
"disabled" in o && r(0, n = o.disabled);
|
|
1349
1532
|
}, [n, i];
|
|
1350
1533
|
}
|
|
1351
|
-
class
|
|
1534
|
+
class lr extends U {
|
|
1352
1535
|
constructor(e) {
|
|
1353
|
-
super(), N(this, e,
|
|
1536
|
+
super(), N(this, e, sr, or, T, { disabled: 0 }, ir);
|
|
1354
1537
|
}
|
|
1355
1538
|
}
|
|
1356
|
-
function
|
|
1539
|
+
function cr(t) {
|
|
1357
1540
|
x(t, "svelte-44qpq9", ".rcb-app-icon.svelte-44qpq9{width:40px;height:40px;border-radius:12px;box-shadow:0px 1px 10px 0px rgba(0, 0, 0, 0.1);margin-right:16px}.rcb-app-icon-picture-container.svelte-44qpq9{height:40px}.rcb-app-icon.loading.svelte-44qpq9{background-color:gray}");
|
|
1358
1541
|
}
|
|
1359
|
-
function
|
|
1542
|
+
function ar(t) {
|
|
1360
1543
|
let e;
|
|
1361
1544
|
return {
|
|
1362
1545
|
c() {
|
|
@@ -1371,7 +1554,7 @@ function cr(t) {
|
|
|
1371
1554
|
}
|
|
1372
1555
|
};
|
|
1373
1556
|
}
|
|
1374
|
-
function
|
|
1557
|
+
function ur(t) {
|
|
1375
1558
|
let e, r, n, i, o, s;
|
|
1376
1559
|
return {
|
|
1377
1560
|
c() {
|
|
@@ -1380,7 +1563,7 @@ function ar(t) {
|
|
|
1380
1563
|
t[0]) || _(o, "src", s), _(o, "alt", "App icon"), _(e, "class", "rcb-app-icon-picture-container svelte-44qpq9");
|
|
1381
1564
|
},
|
|
1382
1565
|
m(l, c) {
|
|
1383
|
-
p(l, e, c),
|
|
1566
|
+
p(l, e, c), C(e, r), C(e, i), C(e, o);
|
|
1384
1567
|
},
|
|
1385
1568
|
p(l, c) {
|
|
1386
1569
|
c & /*srcWebp*/
|
|
@@ -1394,18 +1577,18 @@ function ar(t) {
|
|
|
1394
1577
|
}
|
|
1395
1578
|
};
|
|
1396
1579
|
}
|
|
1397
|
-
function
|
|
1580
|
+
function fr(t) {
|
|
1398
1581
|
let e;
|
|
1399
1582
|
function r(o, s) {
|
|
1400
1583
|
return (
|
|
1401
1584
|
/*src*/
|
|
1402
|
-
o[0] !== null ?
|
|
1585
|
+
o[0] !== null ? ur : ar
|
|
1403
1586
|
);
|
|
1404
1587
|
}
|
|
1405
1588
|
let n = r(t), i = n(t);
|
|
1406
1589
|
return {
|
|
1407
1590
|
c() {
|
|
1408
|
-
i.c(), e =
|
|
1591
|
+
i.c(), e = te();
|
|
1409
1592
|
},
|
|
1410
1593
|
m(o, s) {
|
|
1411
1594
|
i.m(o, s), p(o, e, s);
|
|
@@ -1420,24 +1603,24 @@ function ur(t) {
|
|
|
1420
1603
|
}
|
|
1421
1604
|
};
|
|
1422
1605
|
}
|
|
1423
|
-
function
|
|
1606
|
+
function dr(t, e, r) {
|
|
1424
1607
|
let { src: n = null } = e, { srcWebp: i = null } = e;
|
|
1425
1608
|
return t.$$set = (o) => {
|
|
1426
1609
|
"src" in o && r(0, n = o.src), "srcWebp" in o && r(1, i = o.srcWebp);
|
|
1427
1610
|
}, [n, i];
|
|
1428
1611
|
}
|
|
1429
|
-
class
|
|
1612
|
+
class Nt extends U {
|
|
1430
1613
|
constructor(e) {
|
|
1431
|
-
super(), N(this, e,
|
|
1614
|
+
super(), N(this, e, dr, fr, T, { src: 0, srcWebp: 1 }, cr);
|
|
1432
1615
|
}
|
|
1433
1616
|
}
|
|
1434
|
-
const
|
|
1435
|
-
function
|
|
1617
|
+
const Me = (t) => `https://da08ctfrofx1b.cloudfront.net/${t}`;
|
|
1618
|
+
function mr(t) {
|
|
1436
1619
|
x(t, "svelte-10uf5fq", ".app-title.svelte-10uf5fq{font-weight:500;margin:8px 0;font-size:16px}.rcb-header-layout__business-info.svelte-10uf5fq{display:flex;align-items:center}");
|
|
1437
1620
|
}
|
|
1438
|
-
function
|
|
1621
|
+
function gr(t) {
|
|
1439
1622
|
let e, r;
|
|
1440
|
-
return e = new
|
|
1623
|
+
return e = new Nt({}), {
|
|
1441
1624
|
c() {
|
|
1442
1625
|
w(e.$$.fragment);
|
|
1443
1626
|
},
|
|
@@ -1456,29 +1639,29 @@ function mr(t) {
|
|
|
1456
1639
|
}
|
|
1457
1640
|
};
|
|
1458
1641
|
}
|
|
1459
|
-
function
|
|
1642
|
+
function pr(t) {
|
|
1460
1643
|
let e, r, n = (
|
|
1461
1644
|
/*brandingInfo*/
|
|
1462
1645
|
t[0].seller_company_name + ""
|
|
1463
1646
|
), i, o, s = (
|
|
1464
1647
|
/*brandingInfo*/
|
|
1465
1648
|
t[0].app_icon_webp !== null && /*brandingInfo*/
|
|
1466
|
-
t[0].app_icon !== null &&
|
|
1649
|
+
t[0].app_icon !== null && at(t)
|
|
1467
1650
|
);
|
|
1468
1651
|
return {
|
|
1469
1652
|
c() {
|
|
1470
|
-
s && s.c(), e = P(), r = k("span"), i =
|
|
1653
|
+
s && s.c(), e = P(), r = k("span"), i = L(n), _(r, "class", "app-title svelte-10uf5fq");
|
|
1471
1654
|
},
|
|
1472
1655
|
m(l, c) {
|
|
1473
|
-
s && s.m(l, c), p(l, e, c), p(l, r, c),
|
|
1656
|
+
s && s.m(l, c), p(l, e, c), p(l, r, c), C(r, i), o = !0;
|
|
1474
1657
|
},
|
|
1475
1658
|
p(l, c) {
|
|
1476
1659
|
/*brandingInfo*/
|
|
1477
1660
|
l[0].app_icon_webp !== null && /*brandingInfo*/
|
|
1478
1661
|
l[0].app_icon !== null ? s ? (s.p(l, c), c & /*brandingInfo*/
|
|
1479
|
-
1 && f(s, 1)) : (s =
|
|
1662
|
+
1 && f(s, 1)) : (s = at(l), s.c(), f(s, 1), s.m(e.parentNode, e)) : s && (H(), m(s, 1, 1, () => {
|
|
1480
1663
|
s = null;
|
|
1481
|
-
}),
|
|
1664
|
+
}), K()), (!o || c & /*brandingInfo*/
|
|
1482
1665
|
1) && n !== (n = /*brandingInfo*/
|
|
1483
1666
|
l[0].seller_company_name + "") && ae(i, n);
|
|
1484
1667
|
},
|
|
@@ -1493,15 +1676,15 @@ function gr(t) {
|
|
|
1493
1676
|
}
|
|
1494
1677
|
};
|
|
1495
1678
|
}
|
|
1496
|
-
function
|
|
1679
|
+
function at(t) {
|
|
1497
1680
|
let e, r;
|
|
1498
|
-
return e = new
|
|
1681
|
+
return e = new Nt({
|
|
1499
1682
|
props: {
|
|
1500
|
-
src:
|
|
1683
|
+
src: Me(
|
|
1501
1684
|
/*brandingInfo*/
|
|
1502
1685
|
t[0].app_icon
|
|
1503
1686
|
),
|
|
1504
|
-
srcWebp:
|
|
1687
|
+
srcWebp: Me(
|
|
1505
1688
|
/*brandingInfo*/
|
|
1506
1689
|
t[0].app_icon_webp
|
|
1507
1690
|
)
|
|
@@ -1516,11 +1699,11 @@ function ct(t) {
|
|
|
1516
1699
|
p(n, i) {
|
|
1517
1700
|
const o = {};
|
|
1518
1701
|
i & /*brandingInfo*/
|
|
1519
|
-
1 && (o.src =
|
|
1702
|
+
1 && (o.src = Me(
|
|
1520
1703
|
/*brandingInfo*/
|
|
1521
1704
|
n[0].app_icon
|
|
1522
1705
|
)), i & /*brandingInfo*/
|
|
1523
|
-
1 && (o.srcWebp =
|
|
1706
|
+
1 && (o.srcWebp = Me(
|
|
1524
1707
|
/*brandingInfo*/
|
|
1525
1708
|
n[0].app_icon_webp
|
|
1526
1709
|
)), e.$set(o);
|
|
@@ -1536,9 +1719,9 @@ function ct(t) {
|
|
|
1536
1719
|
}
|
|
1537
1720
|
};
|
|
1538
1721
|
}
|
|
1539
|
-
function
|
|
1722
|
+
function _r(t) {
|
|
1540
1723
|
let e, r, n, i;
|
|
1541
|
-
const o = [
|
|
1724
|
+
const o = [pr, gr], s = [];
|
|
1542
1725
|
function l(c, a) {
|
|
1543
1726
|
return (
|
|
1544
1727
|
/*brandingInfo*/
|
|
@@ -1554,9 +1737,9 @@ function pr(t) {
|
|
|
1554
1737
|
},
|
|
1555
1738
|
p(c, [a]) {
|
|
1556
1739
|
let u = r;
|
|
1557
|
-
r = l(c), r === u ? s[r].p(c, a) : (
|
|
1740
|
+
r = l(c), r === u ? s[r].p(c, a) : (H(), m(s[u], 1, 1, () => {
|
|
1558
1741
|
s[u] = null;
|
|
1559
|
-
}),
|
|
1742
|
+
}), K(), n = s[r], n ? n.p(c, a) : (n = s[r] = o[r](c), n.c()), f(n, 1), n.m(e, null));
|
|
1560
1743
|
},
|
|
1561
1744
|
i(c) {
|
|
1562
1745
|
i || (f(n), i = !0);
|
|
@@ -1569,28 +1752,28 @@ function pr(t) {
|
|
|
1569
1752
|
}
|
|
1570
1753
|
};
|
|
1571
1754
|
}
|
|
1572
|
-
function
|
|
1755
|
+
function Ar(t, e, r) {
|
|
1573
1756
|
let { brandingInfo: n = null } = e;
|
|
1574
1757
|
return t.$$set = (i) => {
|
|
1575
1758
|
"brandingInfo" in i && r(0, n = i.brandingInfo);
|
|
1576
1759
|
}, [n];
|
|
1577
1760
|
}
|
|
1578
|
-
class
|
|
1761
|
+
class Ut extends U {
|
|
1579
1762
|
constructor(e) {
|
|
1580
|
-
super(), N(this, e,
|
|
1763
|
+
super(), N(this, e, Ar, _r, T, { brandingInfo: 0 }, mr);
|
|
1581
1764
|
}
|
|
1582
1765
|
}
|
|
1583
|
-
function
|
|
1766
|
+
function hr(t) {
|
|
1584
1767
|
x(t, "svelte-17puakv", ".rcb-post-purchase-header-layout.svelte-17puakv{display:flex;justify-content:space-between;align-items:center;width:100%;margin-top:-4px}");
|
|
1585
1768
|
}
|
|
1586
|
-
function
|
|
1769
|
+
function Er(t) {
|
|
1587
1770
|
let e, r, n, i, o;
|
|
1588
|
-
return r = new
|
|
1771
|
+
return r = new Ut({
|
|
1589
1772
|
props: { brandingInfo: (
|
|
1590
1773
|
/*brandingInfo*/
|
|
1591
1774
|
t[0]
|
|
1592
1775
|
) }
|
|
1593
|
-
}), i = new
|
|
1776
|
+
}), i = new lr({}), i.$on("click", function() {
|
|
1594
1777
|
ce(
|
|
1595
1778
|
/*onClose*/
|
|
1596
1779
|
t[1]
|
|
@@ -1600,7 +1783,7 @@ function hr(t) {
|
|
|
1600
1783
|
e = k("div"), w(r.$$.fragment), n = P(), w(i.$$.fragment), _(e, "class", "rcb-post-purchase-header-layout svelte-17puakv");
|
|
1601
1784
|
},
|
|
1602
1785
|
m(s, l) {
|
|
1603
|
-
p(s, e, l), b(r, e, null),
|
|
1786
|
+
p(s, e, l), b(r, e, null), C(e, n), b(i, e, null), o = !0;
|
|
1604
1787
|
},
|
|
1605
1788
|
p(s, l) {
|
|
1606
1789
|
t = s;
|
|
@@ -1620,12 +1803,12 @@ function hr(t) {
|
|
|
1620
1803
|
}
|
|
1621
1804
|
};
|
|
1622
1805
|
}
|
|
1623
|
-
function
|
|
1806
|
+
function br(t) {
|
|
1624
1807
|
let e, r;
|
|
1625
1808
|
return e = new ue({
|
|
1626
1809
|
props: {
|
|
1627
1810
|
as: "header",
|
|
1628
|
-
$$slots: { default: [
|
|
1811
|
+
$$slots: { default: [Er] },
|
|
1629
1812
|
$$scope: { ctx: t }
|
|
1630
1813
|
}
|
|
1631
1814
|
}), {
|
|
@@ -1651,22 +1834,22 @@ function Er(t) {
|
|
|
1651
1834
|
}
|
|
1652
1835
|
};
|
|
1653
1836
|
}
|
|
1654
|
-
function
|
|
1837
|
+
function Ir(t, e, r) {
|
|
1655
1838
|
let { brandingInfo: n = null } = e, { onClose: i } = e;
|
|
1656
1839
|
return t.$$set = (o) => {
|
|
1657
1840
|
"brandingInfo" in o && r(0, n = o.brandingInfo), "onClose" in o && r(1, i = o.onClose);
|
|
1658
1841
|
}, [n, i];
|
|
1659
1842
|
}
|
|
1660
|
-
class
|
|
1843
|
+
class wr extends U {
|
|
1661
1844
|
constructor(e) {
|
|
1662
|
-
super(), N(this, e,
|
|
1845
|
+
super(), N(this, e, Ir, br, T, { brandingInfo: 0, onClose: 1 }, hr);
|
|
1663
1846
|
}
|
|
1664
1847
|
}
|
|
1665
|
-
function
|
|
1848
|
+
function kr(t) {
|
|
1666
1849
|
x(t, "svelte-10pcqja", ".rcb-modal-message.svelte-10pcqja{width:100%;min-height:160px;display:flex;justify-content:center;align-items:center;flex-direction:column;text-align:center}.title.svelte-10pcqja{font-size:24px;line-height:1.25em}.subtitle.svelte-10pcqja{font-size:16px;line-height:1.25em;overflow-wrap:anywhere}");
|
|
1667
1850
|
}
|
|
1668
|
-
const
|
|
1669
|
-
function
|
|
1851
|
+
const $r = (t) => ({}), ut = (t) => ({});
|
|
1852
|
+
function vr(t) {
|
|
1670
1853
|
let e, r, n, i, o;
|
|
1671
1854
|
const s = (
|
|
1672
1855
|
/*#slots*/
|
|
@@ -1680,13 +1863,13 @@ function $r(t) {
|
|
|
1680
1863
|
);
|
|
1681
1864
|
return {
|
|
1682
1865
|
c() {
|
|
1683
|
-
e = k("span"), r =
|
|
1866
|
+
e = k("span"), r = L(
|
|
1684
1867
|
/*title*/
|
|
1685
1868
|
t[2]
|
|
1686
1869
|
), n = P(), i = k("span"), l && l.c(), _(e, "class", "title svelte-10pcqja"), _(i, "class", "subtitle svelte-10pcqja");
|
|
1687
1870
|
},
|
|
1688
1871
|
m(c, a) {
|
|
1689
|
-
p(c, e, a),
|
|
1872
|
+
p(c, e, a), C(e, r), p(c, n, a), p(c, i, a), l && l.m(i, null), o = !0;
|
|
1690
1873
|
},
|
|
1691
1874
|
p(c, a) {
|
|
1692
1875
|
(!o || a & /*title*/
|
|
@@ -1725,7 +1908,7 @@ function $r(t) {
|
|
|
1725
1908
|
}
|
|
1726
1909
|
};
|
|
1727
1910
|
}
|
|
1728
|
-
function
|
|
1911
|
+
function yr(t) {
|
|
1729
1912
|
let e, r, n;
|
|
1730
1913
|
const i = (
|
|
1731
1914
|
/*#slots*/
|
|
@@ -1735,12 +1918,12 @@ function vr(t) {
|
|
|
1735
1918
|
t,
|
|
1736
1919
|
/*$$scope*/
|
|
1737
1920
|
t[5],
|
|
1738
|
-
|
|
1921
|
+
ut
|
|
1739
1922
|
);
|
|
1740
1923
|
return r = new $e({
|
|
1741
1924
|
props: {
|
|
1742
1925
|
gutter: "16px",
|
|
1743
|
-
$$slots: { default: [
|
|
1926
|
+
$$slots: { default: [vr] },
|
|
1744
1927
|
$$scope: { ctx: t }
|
|
1745
1928
|
}
|
|
1746
1929
|
}), {
|
|
@@ -1763,12 +1946,12 @@ function vr(t) {
|
|
|
1763
1946
|
/*$$scope*/
|
|
1764
1947
|
s[5],
|
|
1765
1948
|
l,
|
|
1766
|
-
|
|
1949
|
+
$r
|
|
1767
1950
|
) : V(
|
|
1768
1951
|
/*$$scope*/
|
|
1769
1952
|
s[5]
|
|
1770
1953
|
),
|
|
1771
|
-
|
|
1954
|
+
ut
|
|
1772
1955
|
);
|
|
1773
1956
|
const c = {};
|
|
1774
1957
|
l & /*$$scope, title*/
|
|
@@ -1785,12 +1968,12 @@ function vr(t) {
|
|
|
1785
1968
|
}
|
|
1786
1969
|
};
|
|
1787
1970
|
}
|
|
1788
|
-
function
|
|
1971
|
+
function Br(t) {
|
|
1789
1972
|
let e, r, n;
|
|
1790
1973
|
return r = new $e({
|
|
1791
1974
|
props: {
|
|
1792
1975
|
gutter: "16px",
|
|
1793
|
-
$$slots: { default: [
|
|
1976
|
+
$$slots: { default: [yr] },
|
|
1794
1977
|
$$scope: { ctx: t }
|
|
1795
1978
|
}
|
|
1796
1979
|
}), {
|
|
@@ -1827,11 +2010,11 @@ function yr(t) {
|
|
|
1827
2010
|
}
|
|
1828
2011
|
};
|
|
1829
2012
|
}
|
|
1830
|
-
function
|
|
2013
|
+
function Dr(t) {
|
|
1831
2014
|
let e;
|
|
1832
2015
|
return {
|
|
1833
2016
|
c() {
|
|
1834
|
-
e =
|
|
2017
|
+
e = L("Go back to app");
|
|
1835
2018
|
},
|
|
1836
2019
|
m(r, n) {
|
|
1837
2020
|
p(r, e, n);
|
|
@@ -1841,11 +2024,11 @@ function Br(t) {
|
|
|
1841
2024
|
}
|
|
1842
2025
|
};
|
|
1843
2026
|
}
|
|
1844
|
-
function
|
|
2027
|
+
function Mr(t) {
|
|
1845
2028
|
let e, r;
|
|
1846
2029
|
return e = new Ie({
|
|
1847
2030
|
props: {
|
|
1848
|
-
$$slots: { default: [
|
|
2031
|
+
$$slots: { default: [Dr] },
|
|
1849
2032
|
$$scope: { ctx: t }
|
|
1850
2033
|
}
|
|
1851
2034
|
}), e.$on("click", function() {
|
|
@@ -1879,7 +2062,7 @@ function Dr(t) {
|
|
|
1879
2062
|
}
|
|
1880
2063
|
function Cr(t) {
|
|
1881
2064
|
let e, r, n, i, o, s;
|
|
1882
|
-
return e = new
|
|
2065
|
+
return e = new wr({
|
|
1883
2066
|
props: {
|
|
1884
2067
|
brandingInfo: (
|
|
1885
2068
|
/*brandingInfo*/
|
|
@@ -1892,12 +2075,12 @@ function Cr(t) {
|
|
|
1892
2075
|
}
|
|
1893
2076
|
}), n = new ue({
|
|
1894
2077
|
props: {
|
|
1895
|
-
$$slots: { default: [
|
|
2078
|
+
$$slots: { default: [Br] },
|
|
1896
2079
|
$$scope: { ctx: t }
|
|
1897
2080
|
}
|
|
1898
|
-
}), o = new
|
|
2081
|
+
}), o = new ze({
|
|
1899
2082
|
props: {
|
|
1900
|
-
$$slots: { default: [
|
|
2083
|
+
$$slots: { default: [Mr] },
|
|
1901
2084
|
$$scope: { ctx: t }
|
|
1902
2085
|
}
|
|
1903
2086
|
}), {
|
|
@@ -1932,7 +2115,7 @@ function Cr(t) {
|
|
|
1932
2115
|
}
|
|
1933
2116
|
};
|
|
1934
2117
|
}
|
|
1935
|
-
function
|
|
2118
|
+
function Qr(t) {
|
|
1936
2119
|
let e, r;
|
|
1937
2120
|
return e = new $e({
|
|
1938
2121
|
props: {
|
|
@@ -1963,19 +2146,19 @@ function Mr(t) {
|
|
|
1963
2146
|
}
|
|
1964
2147
|
};
|
|
1965
2148
|
}
|
|
1966
|
-
function
|
|
2149
|
+
function Pr(t, e, r) {
|
|
1967
2150
|
let { $$slots: n = {}, $$scope: i } = e, { brandingInfo: o = null } = e, { onContinue: s } = e, { title: l } = e, { type: c } = e;
|
|
1968
2151
|
return t.$$set = (a) => {
|
|
1969
2152
|
"brandingInfo" in a && r(0, o = a.brandingInfo), "onContinue" in a && r(1, s = a.onContinue), "title" in a && r(2, l = a.title), "type" in a && r(3, c = a.type), "$$scope" in a && r(5, i = a.$$scope);
|
|
1970
2153
|
}, [o, s, l, c, n, i];
|
|
1971
2154
|
}
|
|
1972
|
-
class
|
|
2155
|
+
class Rt extends U {
|
|
1973
2156
|
constructor(e) {
|
|
1974
2157
|
super(), N(
|
|
1975
2158
|
this,
|
|
1976
2159
|
e,
|
|
2160
|
+
Pr,
|
|
1977
2161
|
Qr,
|
|
1978
|
-
Mr,
|
|
1979
2162
|
T,
|
|
1980
2163
|
{
|
|
1981
2164
|
brandingInfo: 0,
|
|
@@ -1983,22 +2166,22 @@ class Ut extends U {
|
|
|
1983
2166
|
title: 2,
|
|
1984
2167
|
type: 3
|
|
1985
2168
|
},
|
|
1986
|
-
|
|
2169
|
+
kr
|
|
1987
2170
|
);
|
|
1988
2171
|
}
|
|
1989
2172
|
}
|
|
1990
|
-
function
|
|
2173
|
+
function ft(t) {
|
|
1991
2174
|
let e, r, n, i, o;
|
|
1992
2175
|
return {
|
|
1993
2176
|
c() {
|
|
1994
|
-
e =
|
|
2177
|
+
e = L("If this error persists, please contact "), r = k("a"), n = L(
|
|
1995
2178
|
/*supportEmail*/
|
|
1996
2179
|
t[1]
|
|
1997
|
-
), o =
|
|
2180
|
+
), o = L("."), _(r, "href", i = "mailto:" + /*supportEmail*/
|
|
1998
2181
|
t[1]);
|
|
1999
2182
|
},
|
|
2000
2183
|
m(s, l) {
|
|
2001
|
-
p(s, e, l), p(s, r, l),
|
|
2184
|
+
p(s, e, l), p(s, r, l), C(r, n), p(s, o, l);
|
|
2002
2185
|
},
|
|
2003
2186
|
p(s, l) {
|
|
2004
2187
|
l & /*supportEmail*/
|
|
@@ -2015,33 +2198,33 @@ function ut(t) {
|
|
|
2015
2198
|
}
|
|
2016
2199
|
};
|
|
2017
2200
|
}
|
|
2018
|
-
function
|
|
2201
|
+
function Tr(t) {
|
|
2019
2202
|
let e = (
|
|
2020
2203
|
/*getErrorMessage*/
|
|
2021
2204
|
t[3]() + ""
|
|
2022
2205
|
), r, n, i, o = (
|
|
2023
2206
|
/*supportEmail*/
|
|
2024
|
-
t[1] &&
|
|
2207
|
+
t[1] && ft(t)
|
|
2025
2208
|
);
|
|
2026
2209
|
return {
|
|
2027
2210
|
c() {
|
|
2028
|
-
r =
|
|
2211
|
+
r = L(e), n = P(), o && o.c(), i = te();
|
|
2029
2212
|
},
|
|
2030
2213
|
m(s, l) {
|
|
2031
2214
|
p(s, r, l), p(s, n, l), o && o.m(s, l), p(s, i, l);
|
|
2032
2215
|
},
|
|
2033
2216
|
p(s, l) {
|
|
2034
2217
|
/*supportEmail*/
|
|
2035
|
-
s[1] ? o ? o.p(s, l) : (o =
|
|
2218
|
+
s[1] ? o ? o.p(s, l) : (o = ft(s), o.c(), o.m(i.parentNode, i)) : o && (o.d(1), o = null);
|
|
2036
2219
|
},
|
|
2037
2220
|
d(s) {
|
|
2038
2221
|
s && (g(r), g(n), g(i)), o && o.d(s);
|
|
2039
2222
|
}
|
|
2040
2223
|
};
|
|
2041
2224
|
}
|
|
2042
|
-
function
|
|
2225
|
+
function Nr(t) {
|
|
2043
2226
|
let e, r;
|
|
2044
|
-
return e = new
|
|
2227
|
+
return e = new jn({ props: { slot: "icon" } }), {
|
|
2045
2228
|
c() {
|
|
2046
2229
|
w(e.$$.fragment);
|
|
2047
2230
|
},
|
|
@@ -2060,11 +2243,14 @@ function Tr(t) {
|
|
|
2060
2243
|
}
|
|
2061
2244
|
};
|
|
2062
2245
|
}
|
|
2063
|
-
function
|
|
2246
|
+
function Ur(t) {
|
|
2064
2247
|
let e, r;
|
|
2065
|
-
return e = new
|
|
2248
|
+
return e = new Rt({
|
|
2066
2249
|
props: {
|
|
2067
|
-
title:
|
|
2250
|
+
title: (
|
|
2251
|
+
/*getErrorTitle*/
|
|
2252
|
+
t[4]()
|
|
2253
|
+
),
|
|
2068
2254
|
brandingInfo: (
|
|
2069
2255
|
/*brandingInfo*/
|
|
2070
2256
|
t[0]
|
|
@@ -2075,8 +2261,8 @@ function Nr(t) {
|
|
|
2075
2261
|
),
|
|
2076
2262
|
type: "error",
|
|
2077
2263
|
$$slots: {
|
|
2078
|
-
icon: [
|
|
2079
|
-
default: [
|
|
2264
|
+
icon: [Nr],
|
|
2265
|
+
default: [Tr]
|
|
2080
2266
|
},
|
|
2081
2267
|
$$scope: { ctx: t }
|
|
2082
2268
|
}
|
|
@@ -2094,7 +2280,7 @@ function Nr(t) {
|
|
|
2094
2280
|
n[0]), i & /*onContinue*/
|
|
2095
2281
|
4 && (o.onContinue = /*onContinue*/
|
|
2096
2282
|
n[2]), i & /*$$scope, supportEmail*/
|
|
2097
|
-
|
|
2283
|
+
66 && (o.$$scope = { dirty: i, ctx: n }), e.$set(o);
|
|
2098
2284
|
},
|
|
2099
2285
|
i(n) {
|
|
2100
2286
|
r || (f(e.$$.fragment, n), r = !0);
|
|
@@ -2107,47 +2293,64 @@ function Nr(t) {
|
|
|
2107
2293
|
}
|
|
2108
2294
|
};
|
|
2109
2295
|
}
|
|
2110
|
-
function
|
|
2296
|
+
function Rr(t, e, r) {
|
|
2111
2297
|
let { brandingInfo: n = null } = e, { lastError: i } = e, { supportEmail: o = null } = e, { onContinue: s } = e;
|
|
2112
|
-
|
|
2113
|
-
G.errorLog(`Displayed error: ${
|
|
2298
|
+
Oe(() => {
|
|
2299
|
+
G.errorLog(`Displayed error: ${O[i.errorCode]}. Message: ${i.message ?? "None"}. Underlying error: ${i.underlyingErrorMessage ?? "None"}`);
|
|
2114
2300
|
});
|
|
2115
2301
|
function l() {
|
|
2116
2302
|
switch (i.errorCode) {
|
|
2117
|
-
case
|
|
2303
|
+
case O.UnknownError:
|
|
2118
2304
|
return "An unknown error occurred.";
|
|
2119
|
-
case
|
|
2305
|
+
case O.ErrorSettingUpPurchase:
|
|
2120
2306
|
return "Purchase not started due to an error.";
|
|
2121
|
-
case
|
|
2307
|
+
case O.ErrorChargingPayment:
|
|
2122
2308
|
return "Payment failed.";
|
|
2123
|
-
case
|
|
2309
|
+
case O.NetworkError:
|
|
2124
2310
|
return "Network error. Please check your internet connection.";
|
|
2125
|
-
case
|
|
2311
|
+
case O.StripeError:
|
|
2126
2312
|
return i.message;
|
|
2127
|
-
case
|
|
2313
|
+
case O.MissingEmailError:
|
|
2128
2314
|
return "Email is required to complete the purchase.";
|
|
2315
|
+
case O.AlreadySubscribedError:
|
|
2316
|
+
return "You are already subscribed to this product.";
|
|
2129
2317
|
}
|
|
2130
2318
|
return i.message;
|
|
2131
2319
|
}
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2320
|
+
function c() {
|
|
2321
|
+
switch (i.errorCode) {
|
|
2322
|
+
case O.AlreadySubscribedError:
|
|
2323
|
+
return "Already subscribed";
|
|
2324
|
+
default:
|
|
2325
|
+
return "Something went wrong";
|
|
2326
|
+
}
|
|
2327
|
+
}
|
|
2328
|
+
return t.$$set = (a) => {
|
|
2329
|
+
"brandingInfo" in a && r(0, n = a.brandingInfo), "lastError" in a && r(5, i = a.lastError), "supportEmail" in a && r(1, o = a.supportEmail), "onContinue" in a && r(2, s = a.onContinue);
|
|
2330
|
+
}, [
|
|
2331
|
+
n,
|
|
2332
|
+
o,
|
|
2333
|
+
s,
|
|
2334
|
+
l,
|
|
2335
|
+
c,
|
|
2336
|
+
i
|
|
2337
|
+
];
|
|
2135
2338
|
}
|
|
2136
|
-
class
|
|
2339
|
+
class Sr extends U {
|
|
2137
2340
|
constructor(e) {
|
|
2138
|
-
super(), N(this, e,
|
|
2341
|
+
super(), N(this, e, Rr, Ur, T, {
|
|
2139
2342
|
brandingInfo: 0,
|
|
2140
|
-
lastError:
|
|
2343
|
+
lastError: 5,
|
|
2141
2344
|
supportEmail: 1,
|
|
2142
2345
|
onContinue: 2
|
|
2143
2346
|
});
|
|
2144
2347
|
}
|
|
2145
2348
|
}
|
|
2146
2349
|
const Or = "data:image/svg+xml,%3csvg%20width='124'%20height='124'%20viewBox='0%200%20124%20124'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3ccircle%20cx='62'%20cy='62'%20r='62'%20fill='%23576CDB'/%3e%3crect%20x='44.1116'%20y='56'%20width='27.5'%20height='11'%20transform='rotate(45%2044.1116%2056)'%20fill='white'/%3e%3crect%20x='79.1133'%20y='44.334'%20width='11'%20height='44'%20transform='rotate(45%2079.1133%2044.334)'%20fill='white'/%3e%3c/svg%3e";
|
|
2147
|
-
function
|
|
2350
|
+
function Lr(t) {
|
|
2148
2351
|
x(t, "svelte-1609h93", "img.svelte-1609h93{width:124px;height:124px;margin:0 auto}");
|
|
2149
2352
|
}
|
|
2150
|
-
function
|
|
2353
|
+
function xr(t) {
|
|
2151
2354
|
let e, r;
|
|
2152
2355
|
return {
|
|
2153
2356
|
c() {
|
|
@@ -2164,16 +2367,16 @@ function Lr(t) {
|
|
|
2164
2367
|
}
|
|
2165
2368
|
};
|
|
2166
2369
|
}
|
|
2167
|
-
class
|
|
2370
|
+
class Fr extends U {
|
|
2168
2371
|
constructor(e) {
|
|
2169
|
-
super(), N(this, e, null,
|
|
2372
|
+
super(), N(this, e, null, xr, T, {}, Lr);
|
|
2170
2373
|
}
|
|
2171
2374
|
}
|
|
2172
|
-
function
|
|
2375
|
+
function Gr(t) {
|
|
2173
2376
|
let e;
|
|
2174
2377
|
return {
|
|
2175
2378
|
c() {
|
|
2176
|
-
e =
|
|
2379
|
+
e = L("Your plan is now active.");
|
|
2177
2380
|
},
|
|
2178
2381
|
m(r, n) {
|
|
2179
2382
|
p(r, e, n);
|
|
@@ -2183,9 +2386,9 @@ function Fr(t) {
|
|
|
2183
2386
|
}
|
|
2184
2387
|
};
|
|
2185
2388
|
}
|
|
2186
|
-
function
|
|
2389
|
+
function Yr(t) {
|
|
2187
2390
|
let e, r;
|
|
2188
|
-
return e = new
|
|
2391
|
+
return e = new Fr({ props: { slot: "icon" } }), {
|
|
2189
2392
|
c() {
|
|
2190
2393
|
w(e.$$.fragment);
|
|
2191
2394
|
},
|
|
@@ -2204,9 +2407,9 @@ function Gr(t) {
|
|
|
2204
2407
|
}
|
|
2205
2408
|
};
|
|
2206
2409
|
}
|
|
2207
|
-
function
|
|
2410
|
+
function Hr(t) {
|
|
2208
2411
|
let e, r;
|
|
2209
|
-
return e = new
|
|
2412
|
+
return e = new Rt({
|
|
2210
2413
|
props: {
|
|
2211
2414
|
type: "success",
|
|
2212
2415
|
title: "Purchase successful",
|
|
@@ -2219,8 +2422,8 @@ function Yr(t) {
|
|
|
2219
2422
|
t[1]
|
|
2220
2423
|
),
|
|
2221
2424
|
$$slots: {
|
|
2222
|
-
icon: [
|
|
2223
|
-
default: [
|
|
2425
|
+
icon: [Yr],
|
|
2426
|
+
default: [Gr]
|
|
2224
2427
|
},
|
|
2225
2428
|
$$scope: { ctx: t }
|
|
2226
2429
|
}
|
|
@@ -2251,30 +2454,30 @@ function Yr(t) {
|
|
|
2251
2454
|
}
|
|
2252
2455
|
};
|
|
2253
2456
|
}
|
|
2254
|
-
function
|
|
2457
|
+
function Kr(t, e, r) {
|
|
2255
2458
|
let { brandingInfo: n = null } = e, { onContinue: i } = e;
|
|
2256
2459
|
return t.$$set = (o) => {
|
|
2257
2460
|
"brandingInfo" in o && r(0, n = o.brandingInfo), "onContinue" in o && r(1, i = o.onContinue);
|
|
2258
2461
|
}, [n, i];
|
|
2259
2462
|
}
|
|
2260
|
-
class
|
|
2463
|
+
class qr extends U {
|
|
2261
2464
|
constructor(e) {
|
|
2262
|
-
super(), N(this, e,
|
|
2465
|
+
super(), N(this, e, Kr, Hr, T, { brandingInfo: 0, onContinue: 1 });
|
|
2263
2466
|
}
|
|
2264
2467
|
}
|
|
2265
|
-
function
|
|
2468
|
+
function jr(t, e, r, n, i = {}) {
|
|
2266
2469
|
const o = r.create(e, i);
|
|
2267
2470
|
return o.mount(t), o.on("change", (s) => n("change", s)), o.on("ready", (s) => n("ready", s)), o.on("focus", (s) => n("focus", s)), o.on("blur", (s) => n("blur", s)), o.on("escape", (s) => n("escape", s)), o.on("click", (s) => n("click", s)), o.on("loaderror", (s) => n("loaderror", s)), o.on("loaderstart", (s) => n("loaderstart", s)), o.on("networkschange", (s) => n("networkschange", s)), o;
|
|
2268
2471
|
}
|
|
2269
|
-
const
|
|
2270
|
-
function
|
|
2271
|
-
if (!
|
|
2472
|
+
const Jr = typeof window > "u";
|
|
2473
|
+
function Vr(t) {
|
|
2474
|
+
if (!Jr)
|
|
2272
2475
|
return t.registerAppInfo({
|
|
2273
2476
|
name: "svelte-stripe-js",
|
|
2274
2477
|
url: "https://svelte-stripe-js.vercel.app"
|
|
2275
2478
|
});
|
|
2276
2479
|
}
|
|
2277
|
-
function
|
|
2480
|
+
function Wr(t) {
|
|
2278
2481
|
let e;
|
|
2279
2482
|
return {
|
|
2280
2483
|
c() {
|
|
@@ -2291,11 +2494,11 @@ function Vr(t) {
|
|
|
2291
2494
|
}
|
|
2292
2495
|
};
|
|
2293
2496
|
}
|
|
2294
|
-
function
|
|
2497
|
+
function zr(t, e, r) {
|
|
2295
2498
|
let n, i;
|
|
2296
2499
|
const o = _n(), { elements: s } = hn("stripe");
|
|
2297
2500
|
let { options: l = void 0 } = e;
|
|
2298
|
-
|
|
2501
|
+
Oe(() => (n = jr(i, "payment", s, o, l), () => n.destroy()));
|
|
2299
2502
|
function c() {
|
|
2300
2503
|
n.blur();
|
|
2301
2504
|
}
|
|
@@ -2317,9 +2520,9 @@ function Wr(t, e, r) {
|
|
|
2317
2520
|
"options" in $ && r(1, l = $.options);
|
|
2318
2521
|
}, [i, l, c, a, u, d, h];
|
|
2319
2522
|
}
|
|
2320
|
-
class
|
|
2523
|
+
class Xr extends U {
|
|
2321
2524
|
constructor(e) {
|
|
2322
|
-
super(), N(this, e,
|
|
2525
|
+
super(), N(this, e, zr, Wr, T, {
|
|
2323
2526
|
options: 1,
|
|
2324
2527
|
blur: 2,
|
|
2325
2528
|
clear: 3,
|
|
@@ -2340,7 +2543,7 @@ class zr extends U {
|
|
|
2340
2543
|
return this.$$.ctx[5];
|
|
2341
2544
|
}
|
|
2342
2545
|
}
|
|
2343
|
-
function
|
|
2546
|
+
function dt(t) {
|
|
2344
2547
|
let e;
|
|
2345
2548
|
const r = (
|
|
2346
2549
|
/*#slots*/
|
|
@@ -2391,15 +2594,15 @@ function ft(t) {
|
|
|
2391
2594
|
}
|
|
2392
2595
|
};
|
|
2393
2596
|
}
|
|
2394
|
-
function
|
|
2597
|
+
function Zr(t) {
|
|
2395
2598
|
let e, r, n = (
|
|
2396
2599
|
/*stripe*/
|
|
2397
2600
|
t[1] && /*elements*/
|
|
2398
|
-
t[0] &&
|
|
2601
|
+
t[0] && dt(t)
|
|
2399
2602
|
);
|
|
2400
2603
|
return {
|
|
2401
2604
|
c() {
|
|
2402
|
-
n && n.c(), e =
|
|
2605
|
+
n && n.c(), e = te();
|
|
2403
2606
|
},
|
|
2404
2607
|
m(i, o) {
|
|
2405
2608
|
n && n.m(i, o), p(i, e, o), r = !0;
|
|
@@ -2408,9 +2611,9 @@ function Xr(t) {
|
|
|
2408
2611
|
/*stripe*/
|
|
2409
2612
|
i[1] && /*elements*/
|
|
2410
2613
|
i[0] ? n ? (n.p(i, o), o & /*stripe, elements*/
|
|
2411
|
-
3 && f(n, 1)) : (n =
|
|
2614
|
+
3 && f(n, 1)) : (n = dt(i), n.c(), f(n, 1), n.m(e.parentNode, e)) : n && (H(), m(n, 1, 1, () => {
|
|
2412
2615
|
n = null;
|
|
2413
|
-
}),
|
|
2616
|
+
}), K());
|
|
2414
2617
|
},
|
|
2415
2618
|
i(i) {
|
|
2416
2619
|
r || (f(n), r = !0);
|
|
@@ -2423,10 +2626,10 @@ function Xr(t) {
|
|
|
2423
2626
|
}
|
|
2424
2627
|
};
|
|
2425
2628
|
}
|
|
2426
|
-
function
|
|
2629
|
+
function ei(t, e, r) {
|
|
2427
2630
|
let n, { $$slots: i = {}, $$scope: o } = e, { stripe: s } = e, { mode: l = void 0 } = e, { theme: c = "stripe" } = e, { variables: a = {} } = e, { rules: u = {} } = e, { labels: d = "above" } = e, { loader: h = "auto" } = e, { fonts: $ = [] } = e, { locale: E = "auto" } = e, { currency: B = void 0 } = e, { amount: A = void 0 } = e, { clientSecret: y = void 0 } = e, { elements: R = null } = e;
|
|
2428
|
-
return t.$$set = (
|
|
2429
|
-
"stripe" in
|
|
2631
|
+
return t.$$set = (M) => {
|
|
2632
|
+
"stripe" in M && r(1, s = M.stripe), "mode" in M && r(2, l = M.mode), "theme" in M && r(3, c = M.theme), "variables" in M && r(4, a = M.variables), "rules" in M && r(5, u = M.rules), "labels" in M && r(6, d = M.labels), "loader" in M && r(7, h = M.loader), "fonts" in M && r(8, $ = M.fonts), "locale" in M && r(9, E = M.locale), "currency" in M && r(10, B = M.currency), "amount" in M && r(11, A = M.amount), "clientSecret" in M && r(12, y = M.clientSecret), "elements" in M && r(0, R = M.elements), "$$scope" in M && r(14, o = M.$$scope);
|
|
2430
2633
|
}, t.$$.update = () => {
|
|
2431
2634
|
t.$$.dirty & /*theme, variables, rules, labels*/
|
|
2432
2635
|
120 && r(13, n = { theme: c, variables: a, rules: u, labels: d }), t.$$.dirty & /*stripe, elements, mode, currency, amount, appearance, clientSecret, fonts, loader, locale*/
|
|
@@ -2439,7 +2642,7 @@ function Zr(t, e, r) {
|
|
|
2439
2642
|
fonts: $,
|
|
2440
2643
|
loader: h,
|
|
2441
2644
|
locale: E
|
|
2442
|
-
})),
|
|
2645
|
+
})), Vr(s), An("stripe", { stripe: s, elements: R })), t.$$.dirty & /*elements, appearance, locale*/
|
|
2443
2646
|
8705 && R && R.update({ appearance: n, locale: E });
|
|
2444
2647
|
}, [
|
|
2445
2648
|
R,
|
|
@@ -2460,9 +2663,9 @@ function Zr(t, e, r) {
|
|
|
2460
2663
|
i
|
|
2461
2664
|
];
|
|
2462
2665
|
}
|
|
2463
|
-
class
|
|
2666
|
+
class ti extends U {
|
|
2464
2667
|
constructor(e) {
|
|
2465
|
-
super(), N(this, e,
|
|
2668
|
+
super(), N(this, e, ei, Zr, T, {
|
|
2466
2669
|
stripe: 1,
|
|
2467
2670
|
mode: 2,
|
|
2468
2671
|
theme: 3,
|
|
@@ -2479,55 +2682,55 @@ class ei extends U {
|
|
|
2479
2682
|
});
|
|
2480
2683
|
}
|
|
2481
2684
|
}
|
|
2482
|
-
var
|
|
2483
|
-
for (var e = document.querySelectorAll('script[src^="'.concat(
|
|
2685
|
+
var St = "https://js.stripe.com/v3", ni = /^https:\/\/js\.stripe\.com\/v3\/?(\?.*)?$/, mt = "loadStripe.setLoadParameters was called but an existing Stripe.js script already exists in the document; existing script parameters will be used", ri = function() {
|
|
2686
|
+
for (var e = document.querySelectorAll('script[src^="'.concat(St, '"]')), r = 0; r < e.length; r++) {
|
|
2484
2687
|
var n = e[r];
|
|
2485
|
-
if (
|
|
2688
|
+
if (ni.test(n.src))
|
|
2486
2689
|
return n;
|
|
2487
2690
|
}
|
|
2488
2691
|
return null;
|
|
2489
|
-
},
|
|
2692
|
+
}, gt = function(e) {
|
|
2490
2693
|
var r = e && !e.advancedFraudSignals ? "?advancedFraudSignals=false" : "", n = document.createElement("script");
|
|
2491
|
-
n.src = "".concat(
|
|
2694
|
+
n.src = "".concat(St).concat(r);
|
|
2492
2695
|
var i = document.head || document.body;
|
|
2493
2696
|
if (!i)
|
|
2494
2697
|
throw new Error("Expected document.body not to be null. Stripe.js requires a <body> element.");
|
|
2495
2698
|
return i.appendChild(n), n;
|
|
2496
|
-
},
|
|
2699
|
+
}, ii = function(e, r) {
|
|
2497
2700
|
!e || !e._registerWrapper || e._registerWrapper({
|
|
2498
2701
|
name: "stripe-js",
|
|
2499
2702
|
version: "2.4.0",
|
|
2500
2703
|
startTime: r
|
|
2501
2704
|
});
|
|
2502
|
-
}, me = null,
|
|
2705
|
+
}, me = null, Ce = null, Qe = null, oi = function(e) {
|
|
2503
2706
|
return function() {
|
|
2504
2707
|
e(new Error("Failed to load Stripe.js"));
|
|
2505
2708
|
};
|
|
2506
|
-
},
|
|
2709
|
+
}, si = function(e, r) {
|
|
2507
2710
|
return function() {
|
|
2508
2711
|
window.Stripe ? e(window.Stripe) : r(new Error("Stripe.js not available"));
|
|
2509
2712
|
};
|
|
2510
|
-
},
|
|
2713
|
+
}, li = function(e) {
|
|
2511
2714
|
return me !== null ? me : (me = new Promise(function(r, n) {
|
|
2512
2715
|
if (typeof window > "u" || typeof document > "u") {
|
|
2513
2716
|
r(null);
|
|
2514
2717
|
return;
|
|
2515
2718
|
}
|
|
2516
|
-
if (window.Stripe && e && console.warn(
|
|
2719
|
+
if (window.Stripe && e && console.warn(mt), window.Stripe) {
|
|
2517
2720
|
r(window.Stripe);
|
|
2518
2721
|
return;
|
|
2519
2722
|
}
|
|
2520
2723
|
try {
|
|
2521
|
-
var i =
|
|
2724
|
+
var i = ri();
|
|
2522
2725
|
if (i && e)
|
|
2523
|
-
console.warn(
|
|
2726
|
+
console.warn(mt);
|
|
2524
2727
|
else if (!i)
|
|
2525
|
-
i =
|
|
2526
|
-
else if (i && Qe !== null &&
|
|
2728
|
+
i = gt(e);
|
|
2729
|
+
else if (i && Qe !== null && Ce !== null) {
|
|
2527
2730
|
var o;
|
|
2528
|
-
i.removeEventListener("load", Qe), i.removeEventListener("error",
|
|
2731
|
+
i.removeEventListener("load", Qe), i.removeEventListener("error", Ce), (o = i.parentNode) === null || o === void 0 || o.removeChild(i), i = gt(e);
|
|
2529
2732
|
}
|
|
2530
|
-
Qe =
|
|
2733
|
+
Qe = si(r, n), Ce = oi(n), i.addEventListener("load", Qe), i.addEventListener("error", Ce);
|
|
2531
2734
|
} catch (s) {
|
|
2532
2735
|
n(s);
|
|
2533
2736
|
return;
|
|
@@ -2535,34 +2738,34 @@ var Rt = "https://js.stripe.com/v3", ti = /^https:\/\/js\.stripe\.com\/v3\/?(\?.
|
|
|
2535
2738
|
}), me.catch(function(r) {
|
|
2536
2739
|
return me = null, Promise.reject(r);
|
|
2537
2740
|
}));
|
|
2538
|
-
},
|
|
2741
|
+
}, ci = function(e, r, n) {
|
|
2539
2742
|
if (e === null)
|
|
2540
2743
|
return null;
|
|
2541
2744
|
var i = e.apply(void 0, r);
|
|
2542
|
-
return
|
|
2543
|
-
}, ge, Ot = !1,
|
|
2544
|
-
return ge || (ge =
|
|
2745
|
+
return ii(i, n), i;
|
|
2746
|
+
}, ge, Ot = !1, Lt = function() {
|
|
2747
|
+
return ge || (ge = li(null).catch(function(e) {
|
|
2545
2748
|
return ge = null, Promise.reject(e);
|
|
2546
2749
|
}), ge);
|
|
2547
2750
|
};
|
|
2548
2751
|
Promise.resolve().then(function() {
|
|
2549
|
-
return
|
|
2752
|
+
return Lt();
|
|
2550
2753
|
}).catch(function(t) {
|
|
2551
2754
|
Ot || console.warn(t);
|
|
2552
2755
|
});
|
|
2553
|
-
var
|
|
2756
|
+
var ai = function() {
|
|
2554
2757
|
for (var e = arguments.length, r = new Array(e), n = 0; n < e; n++)
|
|
2555
2758
|
r[n] = arguments[n];
|
|
2556
2759
|
Ot = !0;
|
|
2557
2760
|
var i = Date.now();
|
|
2558
|
-
return
|
|
2559
|
-
return
|
|
2761
|
+
return Lt().then(function(o) {
|
|
2762
|
+
return ci(o, r, i);
|
|
2560
2763
|
});
|
|
2561
2764
|
};
|
|
2562
|
-
function
|
|
2765
|
+
function ui(t) {
|
|
2563
2766
|
x(t, "svelte-1xe711j", ".rcb-header-layout.svelte-1xe711j{display:flex;justify-content:space-between;align-items:center;width:100%;font-size:24px;margin:0;font-weight:500}");
|
|
2564
2767
|
}
|
|
2565
|
-
function
|
|
2768
|
+
function fi(t) {
|
|
2566
2769
|
let e, r;
|
|
2567
2770
|
const n = (
|
|
2568
2771
|
/*#slots*/
|
|
@@ -2613,12 +2816,12 @@ function ui(t) {
|
|
|
2613
2816
|
}
|
|
2614
2817
|
};
|
|
2615
2818
|
}
|
|
2616
|
-
function
|
|
2819
|
+
function di(t) {
|
|
2617
2820
|
let e, r;
|
|
2618
2821
|
return e = new ue({
|
|
2619
2822
|
props: {
|
|
2620
2823
|
as: "header",
|
|
2621
|
-
$$slots: { default: [
|
|
2824
|
+
$$slots: { default: [fi] },
|
|
2622
2825
|
$$scope: { ctx: t }
|
|
2623
2826
|
}
|
|
2624
2827
|
}), {
|
|
@@ -2644,23 +2847,23 @@ function fi(t) {
|
|
|
2644
2847
|
}
|
|
2645
2848
|
};
|
|
2646
2849
|
}
|
|
2647
|
-
function
|
|
2850
|
+
function mi(t, e, r) {
|
|
2648
2851
|
let { $$slots: n = {}, $$scope: i } = e;
|
|
2649
2852
|
return t.$$set = (o) => {
|
|
2650
2853
|
"$$scope" in o && r(1, i = o.$$scope);
|
|
2651
2854
|
}, [n, i];
|
|
2652
2855
|
}
|
|
2653
|
-
class
|
|
2856
|
+
class Xe extends U {
|
|
2654
2857
|
constructor(e) {
|
|
2655
|
-
super(), N(this, e,
|
|
2858
|
+
super(), N(this, e, mi, di, T, {}, ui);
|
|
2656
2859
|
}
|
|
2657
2860
|
}
|
|
2658
|
-
const
|
|
2659
|
-
function
|
|
2861
|
+
const gi = "data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M18%208H17V6C17%203.24%2014.76%201%2012%201C9.24%201%207%203.24%207%206V8H6C4.9%208%204%208.9%204%2010V20C4%2021.1%204.9%2022%206%2022H18C19.1%2022%2020%2021.1%2020%2020V10C20%208.9%2019.1%208%2018%208ZM12%2017C10.9%2017%2010%2016.1%2010%2015C10%2013.9%2010.9%2013%2012%2013C13.1%2013%2014%2013.9%2014%2015C14%2016.1%2013.1%2017%2012%2017ZM15.1%208H8.9V6C8.9%204.29%2010.29%202.9%2012%202.9C13.71%202.9%2015.1%204.29%2015.1%206V8Z'%20fill='%2311D483'/%3e%3c/svg%3e";
|
|
2862
|
+
function pi(t) {
|
|
2660
2863
|
let e, r;
|
|
2661
2864
|
return {
|
|
2662
2865
|
c() {
|
|
2663
|
-
e = k("img"), Z(e.src, r =
|
|
2866
|
+
e = k("img"), Z(e.src, r = gi) || _(e, "src", r), _(e, "alt", "icon"), _(e, "class", "rcb-ui-asset-icon");
|
|
2664
2867
|
},
|
|
2665
2868
|
m(n, i) {
|
|
2666
2869
|
p(n, e, i);
|
|
@@ -2673,9 +2876,9 @@ function gi(t) {
|
|
|
2673
2876
|
}
|
|
2674
2877
|
};
|
|
2675
2878
|
}
|
|
2676
|
-
class
|
|
2879
|
+
class _i extends U {
|
|
2677
2880
|
constructor(e) {
|
|
2678
|
-
super(), N(this, e, null,
|
|
2881
|
+
super(), N(this, e, null, pi, T, {});
|
|
2679
2882
|
}
|
|
2680
2883
|
}
|
|
2681
2884
|
const _e = {
|
|
@@ -2687,7 +2890,7 @@ const _e = {
|
|
|
2687
2890
|
"grey-ui-dark": "#dfdfdf",
|
|
2688
2891
|
white: "#ffffff"
|
|
2689
2892
|
};
|
|
2690
|
-
function
|
|
2893
|
+
function Ai(t) {
|
|
2691
2894
|
x(t, "svelte-rjmul6", `.processing.svelte-rjmul6{width:12px;aspect-ratio:1;border-radius:50%;animation:svelte-rjmul6-l5 1.5s infinite linear}@keyframes svelte-rjmul6-l5{0%{box-shadow:20px 0 #fff2,
|
|
2692
2895
|
-20px 0 #fff2;background:#fff2}25%{box-shadow:20px 0 #fff2,
|
|
2693
2896
|
-20px 0 #ffff;background:#fff2}50%{box-shadow:20px 0 #fff2,
|
|
@@ -2695,7 +2898,7 @@ function _i(t) {
|
|
|
2695
2898
|
-20px 0 #fff2;background:#fff2}100%{box-shadow:20px 0 #fff2,
|
|
2696
2899
|
-20px 0 #fff2;background:#fff2}}`);
|
|
2697
2900
|
}
|
|
2698
|
-
function
|
|
2901
|
+
function hi(t) {
|
|
2699
2902
|
let e;
|
|
2700
2903
|
return {
|
|
2701
2904
|
c() {
|
|
@@ -2712,17 +2915,17 @@ function Ai(t) {
|
|
|
2712
2915
|
}
|
|
2713
2916
|
};
|
|
2714
2917
|
}
|
|
2715
|
-
class
|
|
2918
|
+
class xt extends U {
|
|
2716
2919
|
constructor(e) {
|
|
2717
|
-
super(), N(this, e, null,
|
|
2920
|
+
super(), N(this, e, null, hi, T, {}, Ai);
|
|
2718
2921
|
}
|
|
2719
2922
|
}
|
|
2720
|
-
function
|
|
2923
|
+
function Ei(t) {
|
|
2721
2924
|
x(t, "svelte-1wxt892", ".rcb-stripe-elements-container.svelte-1wxt892{width:100%;margin-top:32px;margin-bottom:24px}");
|
|
2722
2925
|
}
|
|
2723
|
-
function
|
|
2926
|
+
function bi(t) {
|
|
2724
2927
|
let e, r;
|
|
2725
|
-
return e = new
|
|
2928
|
+
return e = new We({}), {
|
|
2726
2929
|
c() {
|
|
2727
2930
|
w(e.$$.fragment);
|
|
2728
2931
|
},
|
|
@@ -2741,7 +2944,7 @@ function Ei(t) {
|
|
|
2741
2944
|
}
|
|
2742
2945
|
};
|
|
2743
2946
|
}
|
|
2744
|
-
function
|
|
2947
|
+
function Ii(t) {
|
|
2745
2948
|
let e, r, n, i, o, s;
|
|
2746
2949
|
function l(a) {
|
|
2747
2950
|
t[9](a);
|
|
@@ -2788,12 +2991,12 @@ function bi(t) {
|
|
|
2788
2991
|
return (
|
|
2789
2992
|
/*elements*/
|
|
2790
2993
|
t[2] !== void 0 && (c.elements = /*elements*/
|
|
2791
|
-
t[2]), r = new
|
|
2994
|
+
t[2]), r = new ti({ props: c }), Ue.push(() => $n(r, "elements", l)), {
|
|
2792
2995
|
c() {
|
|
2793
2996
|
e = k("form"), w(r.$$.fragment);
|
|
2794
2997
|
},
|
|
2795
2998
|
m(a, u) {
|
|
2796
|
-
p(a, e, u), b(r, e, null), i = !0, o || (s = ke(e, "submit",
|
|
2999
|
+
p(a, e, u), b(r, e, null), i = !0, o || (s = ke(e, "submit", Mt(
|
|
2797
3000
|
/*handleContinue*/
|
|
2798
3001
|
t[5]
|
|
2799
3002
|
)), o = !0);
|
|
@@ -2819,9 +3022,9 @@ function bi(t) {
|
|
|
2819
3022
|
}
|
|
2820
3023
|
);
|
|
2821
3024
|
}
|
|
2822
|
-
function
|
|
3025
|
+
function wi(t) {
|
|
2823
3026
|
let e, r, n, i;
|
|
2824
|
-
return n = new
|
|
3027
|
+
return n = new _i({}), {
|
|
2825
3028
|
c() {
|
|
2826
3029
|
e = k("div"), e.textContent = "Secure Checkout", r = P(), w(n.$$.fragment);
|
|
2827
3030
|
},
|
|
@@ -2840,9 +3043,9 @@ function Ii(t) {
|
|
|
2840
3043
|
}
|
|
2841
3044
|
};
|
|
2842
3045
|
}
|
|
2843
|
-
function
|
|
3046
|
+
function ki(t) {
|
|
2844
3047
|
let e, r, n;
|
|
2845
|
-
return r = new
|
|
3048
|
+
return r = new Xr({}), {
|
|
2846
3049
|
c() {
|
|
2847
3050
|
e = k("div"), w(r.$$.fragment), _(e, "class", "rcb-stripe-elements-container svelte-1wxt892");
|
|
2848
3051
|
},
|
|
@@ -2861,11 +3064,11 @@ function wi(t) {
|
|
|
2861
3064
|
}
|
|
2862
3065
|
};
|
|
2863
3066
|
}
|
|
2864
|
-
function
|
|
3067
|
+
function $i(t) {
|
|
2865
3068
|
let e;
|
|
2866
3069
|
return {
|
|
2867
3070
|
c() {
|
|
2868
|
-
e =
|
|
3071
|
+
e = L("Pay");
|
|
2869
3072
|
},
|
|
2870
3073
|
m(r, n) {
|
|
2871
3074
|
p(r, e, n);
|
|
@@ -2877,9 +3080,9 @@ function ki(t) {
|
|
|
2877
3080
|
}
|
|
2878
3081
|
};
|
|
2879
3082
|
}
|
|
2880
|
-
function
|
|
3083
|
+
function vi(t) {
|
|
2881
3084
|
let e, r;
|
|
2882
|
-
return e = new
|
|
3085
|
+
return e = new xt({}), {
|
|
2883
3086
|
c() {
|
|
2884
3087
|
w(e.$$.fragment);
|
|
2885
3088
|
},
|
|
@@ -2897,9 +3100,9 @@ function $i(t) {
|
|
|
2897
3100
|
}
|
|
2898
3101
|
};
|
|
2899
3102
|
}
|
|
2900
|
-
function
|
|
3103
|
+
function yi(t) {
|
|
2901
3104
|
let e, r, n, i;
|
|
2902
|
-
const o = [$i
|
|
3105
|
+
const o = [vi, $i], s = [];
|
|
2903
3106
|
function l(c, a) {
|
|
2904
3107
|
return (
|
|
2905
3108
|
/*processing*/
|
|
@@ -2908,16 +3111,16 @@ function vi(t) {
|
|
|
2908
3111
|
}
|
|
2909
3112
|
return e = l(t), r = s[e] = o[e](t), {
|
|
2910
3113
|
c() {
|
|
2911
|
-
r.c(), n =
|
|
3114
|
+
r.c(), n = te();
|
|
2912
3115
|
},
|
|
2913
3116
|
m(c, a) {
|
|
2914
3117
|
s[e].m(c, a), p(c, n, a), i = !0;
|
|
2915
3118
|
},
|
|
2916
3119
|
p(c, a) {
|
|
2917
3120
|
let u = e;
|
|
2918
|
-
e = l(c), e !== u && (
|
|
3121
|
+
e = l(c), e !== u && (H(), m(s[u], 1, 1, () => {
|
|
2919
3122
|
s[u] = null;
|
|
2920
|
-
}),
|
|
3123
|
+
}), K(), r = s[e], r || (r = s[e] = o[e](c), r.c()), f(r, 1), r.m(n.parentNode, n));
|
|
2921
3124
|
},
|
|
2922
3125
|
i(c) {
|
|
2923
3126
|
i || (f(r), i = !0);
|
|
@@ -2930,11 +3133,11 @@ function vi(t) {
|
|
|
2930
3133
|
}
|
|
2931
3134
|
};
|
|
2932
3135
|
}
|
|
2933
|
-
function
|
|
3136
|
+
function Bi(t) {
|
|
2934
3137
|
let e;
|
|
2935
3138
|
return {
|
|
2936
3139
|
c() {
|
|
2937
|
-
e =
|
|
3140
|
+
e = L("Close");
|
|
2938
3141
|
},
|
|
2939
3142
|
m(r, n) {
|
|
2940
3143
|
p(r, e, n);
|
|
@@ -2944,7 +3147,7 @@ function yi(t) {
|
|
|
2944
3147
|
}
|
|
2945
3148
|
};
|
|
2946
3149
|
}
|
|
2947
|
-
function
|
|
3150
|
+
function Di(t) {
|
|
2948
3151
|
let e, r, n, i;
|
|
2949
3152
|
return e = new Ie({
|
|
2950
3153
|
props: {
|
|
@@ -2952,7 +3155,7 @@ function Bi(t) {
|
|
|
2952
3155
|
/*processing*/
|
|
2953
3156
|
t[0]
|
|
2954
3157
|
),
|
|
2955
|
-
$$slots: { default: [
|
|
3158
|
+
$$slots: { default: [yi] },
|
|
2956
3159
|
$$scope: { ctx: t }
|
|
2957
3160
|
}
|
|
2958
3161
|
}), n = new Ie({
|
|
@@ -2962,7 +3165,7 @@ function Bi(t) {
|
|
|
2962
3165
|
t[0]
|
|
2963
3166
|
),
|
|
2964
3167
|
intent: "secondary",
|
|
2965
|
-
$$slots: { default: [
|
|
3168
|
+
$$slots: { default: [Bi] },
|
|
2966
3169
|
$$scope: { ctx: t }
|
|
2967
3170
|
}
|
|
2968
3171
|
}), n.$on("click", function() {
|
|
@@ -3001,11 +3204,11 @@ function Bi(t) {
|
|
|
3001
3204
|
}
|
|
3002
3205
|
};
|
|
3003
3206
|
}
|
|
3004
|
-
function
|
|
3207
|
+
function Mi(t) {
|
|
3005
3208
|
let e, r;
|
|
3006
3209
|
return e = new $e({
|
|
3007
3210
|
props: {
|
|
3008
|
-
$$slots: { default: [
|
|
3211
|
+
$$slots: { default: [Di] },
|
|
3009
3212
|
$$scope: { ctx: t }
|
|
3010
3213
|
}
|
|
3011
3214
|
}), {
|
|
@@ -3033,19 +3236,19 @@ function Di(t) {
|
|
|
3033
3236
|
}
|
|
3034
3237
|
function Ci(t) {
|
|
3035
3238
|
let e, r, n, i, o, s;
|
|
3036
|
-
return e = new
|
|
3239
|
+
return e = new Xe({
|
|
3037
3240
|
props: {
|
|
3038
|
-
$$slots: { default: [
|
|
3241
|
+
$$slots: { default: [wi] },
|
|
3039
3242
|
$$scope: { ctx: t }
|
|
3040
3243
|
}
|
|
3041
3244
|
}), n = new ue({
|
|
3042
3245
|
props: {
|
|
3043
|
-
$$slots: { default: [
|
|
3246
|
+
$$slots: { default: [ki] },
|
|
3044
3247
|
$$scope: { ctx: t }
|
|
3045
3248
|
}
|
|
3046
|
-
}), o = new
|
|
3249
|
+
}), o = new ze({
|
|
3047
3250
|
props: {
|
|
3048
|
-
$$slots: { default: [
|
|
3251
|
+
$$slots: { default: [Mi] },
|
|
3049
3252
|
$$scope: { ctx: t }
|
|
3050
3253
|
}
|
|
3051
3254
|
}), {
|
|
@@ -3077,9 +3280,9 @@ function Ci(t) {
|
|
|
3077
3280
|
}
|
|
3078
3281
|
};
|
|
3079
3282
|
}
|
|
3080
|
-
function
|
|
3283
|
+
function Qi(t) {
|
|
3081
3284
|
let e, r, n, i;
|
|
3082
|
-
const o = [
|
|
3285
|
+
const o = [Ii, bi], s = [];
|
|
3083
3286
|
function l(c, a) {
|
|
3084
3287
|
return (
|
|
3085
3288
|
/*stripe*/
|
|
@@ -3096,9 +3299,9 @@ function Mi(t) {
|
|
|
3096
3299
|
},
|
|
3097
3300
|
p(c, [a]) {
|
|
3098
3301
|
let u = r;
|
|
3099
|
-
r = l(c), r === u ? s[r].p(c, a) : (
|
|
3302
|
+
r = l(c), r === u ? s[r].p(c, a) : (H(), m(s[u], 1, 1, () => {
|
|
3100
3303
|
s[u] = null;
|
|
3101
|
-
}),
|
|
3304
|
+
}), K(), n = s[r], n ? n.p(c, a) : (n = s[r] = o[r](c), n.c()), f(n, 1), n.m(e, null));
|
|
3102
3305
|
},
|
|
3103
3306
|
i(c) {
|
|
3104
3307
|
i || (f(n), i = !0);
|
|
@@ -3111,15 +3314,15 @@ function Mi(t) {
|
|
|
3111
3314
|
}
|
|
3112
3315
|
};
|
|
3113
3316
|
}
|
|
3114
|
-
function
|
|
3317
|
+
function Pi(t, e, r) {
|
|
3115
3318
|
let { onClose: n } = e, { onContinue: i } = e, { onError: o } = e, { paymentInfoCollectionMetadata: s } = e, { processing: l = !1 } = e;
|
|
3116
3319
|
const c = s.data.client_secret;
|
|
3117
3320
|
let a = null, u, d;
|
|
3118
|
-
|
|
3321
|
+
Oe(async () => {
|
|
3119
3322
|
const E = s.data.publishable_api_key, B = s.data.stripe_account_id;
|
|
3120
3323
|
if (!E || !B)
|
|
3121
3324
|
throw new Error("Stripe publishable key or account ID not found");
|
|
3122
|
-
r(3, a = await
|
|
3325
|
+
r(3, a = await ai(E, { stripeAccount: B }));
|
|
3123
3326
|
});
|
|
3124
3327
|
const h = async () => {
|
|
3125
3328
|
if (l || !a || !d)
|
|
@@ -3129,7 +3332,7 @@ function Qi(t, e, r) {
|
|
|
3129
3332
|
elements: d,
|
|
3130
3333
|
redirect: "if_required"
|
|
3131
3334
|
});
|
|
3132
|
-
E.error ? (r(0, l = !1), o(new
|
|
3335
|
+
E.error ? (r(0, l = !1), o(new Y(O.StripeError, E.error.message))) : i();
|
|
3133
3336
|
};
|
|
3134
3337
|
function $(E) {
|
|
3135
3338
|
u = E, r(2, u);
|
|
@@ -3152,13 +3355,13 @@ function Qi(t, e, r) {
|
|
|
3152
3355
|
$
|
|
3153
3356
|
];
|
|
3154
3357
|
}
|
|
3155
|
-
class
|
|
3358
|
+
class Ti extends U {
|
|
3156
3359
|
constructor(e) {
|
|
3157
3360
|
super(), N(
|
|
3158
3361
|
this,
|
|
3159
3362
|
e,
|
|
3363
|
+
Pi,
|
|
3160
3364
|
Qi,
|
|
3161
|
-
Mi,
|
|
3162
3365
|
T,
|
|
3163
3366
|
{
|
|
3164
3367
|
onClose: 1,
|
|
@@ -3167,18 +3370,21 @@ class Pi extends U {
|
|
|
3167
3370
|
paymentInfoCollectionMetadata: 8,
|
|
3168
3371
|
processing: 0
|
|
3169
3372
|
},
|
|
3170
|
-
|
|
3373
|
+
Ei
|
|
3171
3374
|
);
|
|
3172
3375
|
}
|
|
3173
3376
|
}
|
|
3174
|
-
function
|
|
3377
|
+
function Ni(t) {
|
|
3378
|
+
return t.trim() === "" ? "You need to provide your email address to continue." : t.match(/^[^@]+@[^@]+\.[^@]+$/) ? null : "Email is not valid. Please provide a valid email address.";
|
|
3379
|
+
}
|
|
3380
|
+
function Ui(t) {
|
|
3175
3381
|
x(t, "svelte-favd20", "form.svelte-favd20.svelte-favd20{display:flex;flex-direction:column;min-height:100%;flex-grow:1}.form-container.svelte-favd20.svelte-favd20{display:flex;flex-direction:column;width:100%;margin-top:32px;margin-bottom:16px}.form-label.svelte-favd20.svelte-favd20{margin-top:8px;margin-bottom:8px;display:block;font-weight:500;line-height:22px}.form-input.error.svelte-favd20 input.svelte-favd20{border-color:var(--rc-color-error)}.form-error.svelte-favd20.svelte-favd20{margin-top:4px;font-size:16px;line-height:20px;min-height:40px;color:var(--rc-color-error)}input.svelte-favd20.svelte-favd20{width:100%;box-sizing:border-box;padding:8px;border:2px solid var(--rc-color-grey-ui-dark);border-radius:12px;font-size:16px;height:48px;padding:6px 14px}input.svelte-favd20.svelte-favd20:focus{outline:none;border:2px solid var(--rc-color-focus)}");
|
|
3176
3382
|
}
|
|
3177
|
-
function
|
|
3383
|
+
function Ri(t) {
|
|
3178
3384
|
let e;
|
|
3179
3385
|
return {
|
|
3180
3386
|
c() {
|
|
3181
|
-
e =
|
|
3387
|
+
e = L("Billing email address");
|
|
3182
3388
|
},
|
|
3183
3389
|
m(r, n) {
|
|
3184
3390
|
p(r, e, n);
|
|
@@ -3188,17 +3394,17 @@ function Ni(t) {
|
|
|
3188
3394
|
}
|
|
3189
3395
|
};
|
|
3190
3396
|
}
|
|
3191
|
-
function
|
|
3397
|
+
function pt(t) {
|
|
3192
3398
|
let e, r;
|
|
3193
3399
|
return {
|
|
3194
3400
|
c() {
|
|
3195
|
-
e = k("div"), r =
|
|
3401
|
+
e = k("div"), r = L(
|
|
3196
3402
|
/*error*/
|
|
3197
3403
|
t[2]
|
|
3198
3404
|
), _(e, "class", "form-error svelte-favd20");
|
|
3199
3405
|
},
|
|
3200
3406
|
m(n, i) {
|
|
3201
|
-
p(n, e, i),
|
|
3407
|
+
p(n, e, i), C(e, r);
|
|
3202
3408
|
},
|
|
3203
3409
|
p(n, i) {
|
|
3204
3410
|
i & /*error*/
|
|
@@ -3213,10 +3419,10 @@ function gt(t) {
|
|
|
3213
3419
|
}
|
|
3214
3420
|
};
|
|
3215
3421
|
}
|
|
3216
|
-
function
|
|
3422
|
+
function Si(t) {
|
|
3217
3423
|
let e, r, n, i, o, s, l, c, a, u = (
|
|
3218
3424
|
/*error*/
|
|
3219
|
-
t[2] &&
|
|
3425
|
+
t[2] && pt(t)
|
|
3220
3426
|
);
|
|
3221
3427
|
return {
|
|
3222
3428
|
c() {
|
|
@@ -3224,11 +3430,11 @@ function Ui(t) {
|
|
|
3224
3430
|
t[4] + " svelte-favd20"), _(e, "class", "form-container svelte-favd20");
|
|
3225
3431
|
},
|
|
3226
3432
|
m(d, h) {
|
|
3227
|
-
p(d, e, h),
|
|
3433
|
+
p(d, e, h), C(e, r), C(e, n), C(e, i), C(i, o), lt(
|
|
3228
3434
|
o,
|
|
3229
3435
|
/*email*/
|
|
3230
3436
|
t[3]
|
|
3231
|
-
),
|
|
3437
|
+
), C(e, l), u && u.m(e, null), c || (a = ke(
|
|
3232
3438
|
o,
|
|
3233
3439
|
"input",
|
|
3234
3440
|
/*input_input_handler*/
|
|
@@ -3238,25 +3444,25 @@ function Ui(t) {
|
|
|
3238
3444
|
p(d, h) {
|
|
3239
3445
|
h & /*email*/
|
|
3240
3446
|
8 && o.value !== /*email*/
|
|
3241
|
-
d[3] &&
|
|
3447
|
+
d[3] && lt(
|
|
3242
3448
|
o,
|
|
3243
3449
|
/*email*/
|
|
3244
3450
|
d[3]
|
|
3245
3451
|
), h & /*inputClass*/
|
|
3246
3452
|
16 && s !== (s = "form-input " + /*inputClass*/
|
|
3247
3453
|
d[4] + " svelte-favd20") && _(i, "class", s), /*error*/
|
|
3248
|
-
d[2] ? u ? u.p(d, h) : (u =
|
|
3454
|
+
d[2] ? u ? u.p(d, h) : (u = pt(d), u.c(), u.m(e, null)) : u && (u.d(1), u = null);
|
|
3249
3455
|
},
|
|
3250
3456
|
d(d) {
|
|
3251
3457
|
d && g(e), u && u.d(), c = !1, a();
|
|
3252
3458
|
}
|
|
3253
3459
|
};
|
|
3254
3460
|
}
|
|
3255
|
-
function
|
|
3461
|
+
function Oi(t) {
|
|
3256
3462
|
let e;
|
|
3257
3463
|
return {
|
|
3258
3464
|
c() {
|
|
3259
|
-
e =
|
|
3465
|
+
e = L("Continue");
|
|
3260
3466
|
},
|
|
3261
3467
|
m(r, n) {
|
|
3262
3468
|
p(r, e, n);
|
|
@@ -3268,9 +3474,9 @@ function Ri(t) {
|
|
|
3268
3474
|
}
|
|
3269
3475
|
};
|
|
3270
3476
|
}
|
|
3271
|
-
function
|
|
3477
|
+
function Li(t) {
|
|
3272
3478
|
let e, r;
|
|
3273
|
-
return e = new
|
|
3479
|
+
return e = new xt({}), {
|
|
3274
3480
|
c() {
|
|
3275
3481
|
w(e.$$.fragment);
|
|
3276
3482
|
},
|
|
@@ -3288,9 +3494,9 @@ function Oi(t) {
|
|
|
3288
3494
|
}
|
|
3289
3495
|
};
|
|
3290
3496
|
}
|
|
3291
|
-
function
|
|
3497
|
+
function xi(t) {
|
|
3292
3498
|
let e, r, n, i;
|
|
3293
|
-
const o = [
|
|
3499
|
+
const o = [Li, Oi], s = [];
|
|
3294
3500
|
function l(c, a) {
|
|
3295
3501
|
return (
|
|
3296
3502
|
/*processing*/
|
|
@@ -3299,16 +3505,16 @@ function Si(t) {
|
|
|
3299
3505
|
}
|
|
3300
3506
|
return e = l(t), r = s[e] = o[e](t), {
|
|
3301
3507
|
c() {
|
|
3302
|
-
r.c(), n =
|
|
3508
|
+
r.c(), n = te();
|
|
3303
3509
|
},
|
|
3304
3510
|
m(c, a) {
|
|
3305
3511
|
s[e].m(c, a), p(c, n, a), i = !0;
|
|
3306
3512
|
},
|
|
3307
3513
|
p(c, a) {
|
|
3308
3514
|
let u = e;
|
|
3309
|
-
e = l(c), e !== u && (
|
|
3515
|
+
e = l(c), e !== u && (H(), m(s[u], 1, 1, () => {
|
|
3310
3516
|
s[u] = null;
|
|
3311
|
-
}),
|
|
3517
|
+
}), K(), r = s[e], r || (r = s[e] = o[e](c), r.c()), f(r, 1), r.m(n.parentNode, n));
|
|
3312
3518
|
},
|
|
3313
3519
|
i(c) {
|
|
3314
3520
|
i || (f(r), i = !0);
|
|
@@ -3321,11 +3527,11 @@ function Si(t) {
|
|
|
3321
3527
|
}
|
|
3322
3528
|
};
|
|
3323
3529
|
}
|
|
3324
|
-
function
|
|
3530
|
+
function Fi(t) {
|
|
3325
3531
|
let e;
|
|
3326
3532
|
return {
|
|
3327
3533
|
c() {
|
|
3328
|
-
e =
|
|
3534
|
+
e = L("Close");
|
|
3329
3535
|
},
|
|
3330
3536
|
m(r, n) {
|
|
3331
3537
|
p(r, e, n);
|
|
@@ -3335,7 +3541,7 @@ function Li(t) {
|
|
|
3335
3541
|
}
|
|
3336
3542
|
};
|
|
3337
3543
|
}
|
|
3338
|
-
function
|
|
3544
|
+
function Gi(t) {
|
|
3339
3545
|
let e, r, n, i;
|
|
3340
3546
|
return e = new Ie({
|
|
3341
3547
|
props: {
|
|
@@ -3343,7 +3549,7 @@ function xi(t) {
|
|
|
3343
3549
|
/*processing*/
|
|
3344
3550
|
t[1]
|
|
3345
3551
|
),
|
|
3346
|
-
$$slots: { default: [
|
|
3552
|
+
$$slots: { default: [xi] },
|
|
3347
3553
|
$$scope: { ctx: t }
|
|
3348
3554
|
}
|
|
3349
3555
|
}), n = new Ie({
|
|
@@ -3353,7 +3559,7 @@ function xi(t) {
|
|
|
3353
3559
|
/*processing*/
|
|
3354
3560
|
t[1]
|
|
3355
3561
|
),
|
|
3356
|
-
$$slots: { default: [
|
|
3562
|
+
$$slots: { default: [Fi] },
|
|
3357
3563
|
$$scope: { ctx: t }
|
|
3358
3564
|
}
|
|
3359
3565
|
}), n.$on("click", function() {
|
|
@@ -3392,11 +3598,11 @@ function xi(t) {
|
|
|
3392
3598
|
}
|
|
3393
3599
|
};
|
|
3394
3600
|
}
|
|
3395
|
-
function
|
|
3601
|
+
function Yi(t) {
|
|
3396
3602
|
let e, r;
|
|
3397
3603
|
return e = new $e({
|
|
3398
3604
|
props: {
|
|
3399
|
-
$$slots: { default: [
|
|
3605
|
+
$$slots: { default: [Gi] },
|
|
3400
3606
|
$$scope: { ctx: t }
|
|
3401
3607
|
}
|
|
3402
3608
|
}), {
|
|
@@ -3422,21 +3628,21 @@ function Fi(t) {
|
|
|
3422
3628
|
}
|
|
3423
3629
|
};
|
|
3424
3630
|
}
|
|
3425
|
-
function
|
|
3631
|
+
function Hi(t) {
|
|
3426
3632
|
let e, r, n, i, o, s, l, c, a;
|
|
3427
|
-
return r = new
|
|
3633
|
+
return r = new Xe({
|
|
3428
3634
|
props: {
|
|
3429
|
-
$$slots: { default: [
|
|
3635
|
+
$$slots: { default: [Ri] },
|
|
3430
3636
|
$$scope: { ctx: t }
|
|
3431
3637
|
}
|
|
3432
3638
|
}), i = new ue({
|
|
3433
3639
|
props: {
|
|
3434
|
-
$$slots: { default: [
|
|
3640
|
+
$$slots: { default: [Si] },
|
|
3435
3641
|
$$scope: { ctx: t }
|
|
3436
3642
|
}
|
|
3437
|
-
}), s = new
|
|
3643
|
+
}), s = new ze({
|
|
3438
3644
|
props: {
|
|
3439
|
-
$$slots: { default: [
|
|
3645
|
+
$$slots: { default: [Yi] },
|
|
3440
3646
|
$$scope: { ctx: t }
|
|
3441
3647
|
}
|
|
3442
3648
|
}), {
|
|
@@ -3444,7 +3650,7 @@ function Gi(t) {
|
|
|
3444
3650
|
e = k("form"), w(r.$$.fragment), n = P(), w(i.$$.fragment), o = P(), w(s.$$.fragment), _(e, "class", "svelte-favd20");
|
|
3445
3651
|
},
|
|
3446
3652
|
m(u, d) {
|
|
3447
|
-
p(u, e, d), b(r, e, null),
|
|
3653
|
+
p(u, e, d), b(r, e, null), C(e, n), b(i, e, null), C(e, o), b(s, e, null), l = !0, c || (a = ke(e, "submit", Mt(
|
|
3448
3654
|
/*handleContinue*/
|
|
3449
3655
|
t[5]
|
|
3450
3656
|
)), c = !0);
|
|
@@ -3471,10 +3677,11 @@ function Gi(t) {
|
|
|
3471
3677
|
}
|
|
3472
3678
|
};
|
|
3473
3679
|
}
|
|
3474
|
-
function
|
|
3680
|
+
function Ki(t, e, r) {
|
|
3475
3681
|
let n, i, o, { onContinue: s } = e, { onClose: l } = e, { processing: c } = e;
|
|
3476
3682
|
const a = async () => {
|
|
3477
|
-
|
|
3683
|
+
const d = Ni(n);
|
|
3684
|
+
d ? r(2, i = d) : s({ email: n });
|
|
3478
3685
|
};
|
|
3479
3686
|
function u() {
|
|
3480
3687
|
n = this.value, r(3, n);
|
|
@@ -3495,15 +3702,15 @@ function Yi(t, e, r) {
|
|
|
3495
3702
|
u
|
|
3496
3703
|
];
|
|
3497
3704
|
}
|
|
3498
|
-
class
|
|
3705
|
+
class qi extends U {
|
|
3499
3706
|
constructor(e) {
|
|
3500
|
-
super(), N(this, e,
|
|
3707
|
+
super(), N(this, e, Ki, Hi, T, { onContinue: 6, onClose: 0, processing: 1 }, Ui);
|
|
3501
3708
|
}
|
|
3502
3709
|
}
|
|
3503
|
-
function
|
|
3710
|
+
function ji(t) {
|
|
3504
3711
|
x(t, "svelte-17tslso", ".rcb-modal-backdrop.svelte-17tslso{position:fixed;top:0;left:0;right:0;min-width:100%;width:100vw;width:100dvw;min-height:100%;height:100vh;height:100dvh;background-color:rgba(40, 40, 40, 0.75);display:flex;flex-direction:column;justify-content:space-around;z-index:1000001}");
|
|
3505
3712
|
}
|
|
3506
|
-
function
|
|
3713
|
+
function Ji(t) {
|
|
3507
3714
|
let e, r;
|
|
3508
3715
|
const n = (
|
|
3509
3716
|
/*#slots*/
|
|
@@ -3554,21 +3761,21 @@ function qi(t) {
|
|
|
3554
3761
|
}
|
|
3555
3762
|
};
|
|
3556
3763
|
}
|
|
3557
|
-
function
|
|
3764
|
+
function Vi(t, e, r) {
|
|
3558
3765
|
let { $$slots: n = {}, $$scope: i } = e;
|
|
3559
3766
|
return t.$$set = (o) => {
|
|
3560
3767
|
"$$scope" in o && r(0, i = o.$$scope);
|
|
3561
3768
|
}, [i, n];
|
|
3562
3769
|
}
|
|
3563
|
-
class
|
|
3770
|
+
class Wi extends U {
|
|
3564
3771
|
constructor(e) {
|
|
3565
|
-
super(), N(this, e,
|
|
3772
|
+
super(), N(this, e, Vi, Ji, T, {}, ji);
|
|
3566
3773
|
}
|
|
3567
3774
|
}
|
|
3568
|
-
function
|
|
3775
|
+
function zi(t) {
|
|
3569
3776
|
x(t, "svelte-ioxu5d", ".rcb-modal-container.svelte-ioxu5d{width:100%}.rcb-modal-main.svelte-ioxu5d{box-sizing:border-box;border-radius:8px;background-color:var(--rc-color-white);color:var(--rc-color-grey-text-dark);min-height:460px;padding:40px;flex-direction:column;display:flex}.rcb-modal-dark.svelte-ioxu5d{background-color:var(--rc-color-grey-text-dark);color:var(--rc-color-white);min-height:0px}@media screen and (max-width: 960px){.rcb-modal-container.svelte-ioxu5d{width:calc(100% - 32px);min-width:300px;max-width:640px;margin:auto}.rcb-modal-main.svelte-ioxu5d,.rcb-modal-dark.svelte-ioxu5d{min-width:300px;max-width:640px;padding:32px}}");
|
|
3570
3777
|
}
|
|
3571
|
-
function
|
|
3778
|
+
function Xi(t) {
|
|
3572
3779
|
let e, r, n, i;
|
|
3573
3780
|
const o = (
|
|
3574
3781
|
/*#slots*/
|
|
@@ -3586,7 +3793,7 @@ function Wi(t) {
|
|
|
3586
3793
|
t[0] ? "rcb-modal-dark" : ""}`) + " svelte-ioxu5d"), _(e, "class", "rcb-modal-container svelte-ioxu5d");
|
|
3587
3794
|
},
|
|
3588
3795
|
m(l, c) {
|
|
3589
|
-
p(l, e, c),
|
|
3796
|
+
p(l, e, c), C(e, r), s && s.m(r, null), i = !0;
|
|
3590
3797
|
},
|
|
3591
3798
|
p(l, [c]) {
|
|
3592
3799
|
s && s.p && (!i || c & /*$$scope*/
|
|
@@ -3622,18 +3829,18 @@ function Wi(t) {
|
|
|
3622
3829
|
}
|
|
3623
3830
|
};
|
|
3624
3831
|
}
|
|
3625
|
-
function
|
|
3832
|
+
function Zi(t, e, r) {
|
|
3626
3833
|
let { $$slots: n = {}, $$scope: i } = e, { dark: o = !1 } = e;
|
|
3627
3834
|
return t.$$set = (s) => {
|
|
3628
3835
|
"dark" in s && r(0, o = s.dark), "$$scope" in s && r(1, i = s.$$scope);
|
|
3629
3836
|
}, [o, i, n];
|
|
3630
3837
|
}
|
|
3631
|
-
class
|
|
3838
|
+
class eo extends U {
|
|
3632
3839
|
constructor(e) {
|
|
3633
|
-
super(), N(this, e,
|
|
3840
|
+
super(), N(this, e, Zi, Xi, T, { dark: 0 }, zi);
|
|
3634
3841
|
}
|
|
3635
3842
|
}
|
|
3636
|
-
function
|
|
3843
|
+
function to(t) {
|
|
3637
3844
|
let e;
|
|
3638
3845
|
const r = (
|
|
3639
3846
|
/*#slots*/
|
|
@@ -3684,11 +3891,11 @@ function Zi(t) {
|
|
|
3684
3891
|
}
|
|
3685
3892
|
};
|
|
3686
3893
|
}
|
|
3687
|
-
function
|
|
3894
|
+
function no(t) {
|
|
3688
3895
|
let e, r;
|
|
3689
|
-
return e = new
|
|
3896
|
+
return e = new Wi({
|
|
3690
3897
|
props: {
|
|
3691
|
-
$$slots: { default: [
|
|
3898
|
+
$$slots: { default: [ro] },
|
|
3692
3899
|
$$scope: { ctx: t }
|
|
3693
3900
|
}
|
|
3694
3901
|
}), {
|
|
@@ -3714,7 +3921,7 @@ function eo(t) {
|
|
|
3714
3921
|
}
|
|
3715
3922
|
};
|
|
3716
3923
|
}
|
|
3717
|
-
function
|
|
3924
|
+
function ro(t) {
|
|
3718
3925
|
let e;
|
|
3719
3926
|
const r = (
|
|
3720
3927
|
/*#slots*/
|
|
@@ -3765,9 +3972,9 @@ function to(t) {
|
|
|
3765
3972
|
}
|
|
3766
3973
|
};
|
|
3767
3974
|
}
|
|
3768
|
-
function
|
|
3975
|
+
function io(t) {
|
|
3769
3976
|
let e, r, n, i;
|
|
3770
|
-
const o = [
|
|
3977
|
+
const o = [no, to], s = [];
|
|
3771
3978
|
function l(c, a) {
|
|
3772
3979
|
return (
|
|
3773
3980
|
/*condition*/
|
|
@@ -3776,16 +3983,16 @@ function no(t) {
|
|
|
3776
3983
|
}
|
|
3777
3984
|
return e = l(t), r = s[e] = o[e](t), {
|
|
3778
3985
|
c() {
|
|
3779
|
-
r.c(), n =
|
|
3986
|
+
r.c(), n = te();
|
|
3780
3987
|
},
|
|
3781
3988
|
m(c, a) {
|
|
3782
3989
|
s[e].m(c, a), p(c, n, a), i = !0;
|
|
3783
3990
|
},
|
|
3784
3991
|
p(c, [a]) {
|
|
3785
3992
|
let u = e;
|
|
3786
|
-
e = l(c), e === u ? s[e].p(c, a) : (
|
|
3993
|
+
e = l(c), e === u ? s[e].p(c, a) : (H(), m(s[u], 1, 1, () => {
|
|
3787
3994
|
s[u] = null;
|
|
3788
|
-
}),
|
|
3995
|
+
}), K(), r = s[e], r ? r.p(c, a) : (r = s[e] = o[e](c), r.c()), f(r, 1), r.m(n.parentNode, n));
|
|
3789
3996
|
},
|
|
3790
3997
|
i(c) {
|
|
3791
3998
|
i || (f(r), i = !0);
|
|
@@ -3798,19 +4005,19 @@ function no(t) {
|
|
|
3798
4005
|
}
|
|
3799
4006
|
};
|
|
3800
4007
|
}
|
|
3801
|
-
function
|
|
4008
|
+
function oo(t, e, r) {
|
|
3802
4009
|
let { $$slots: n = {}, $$scope: i } = e, { condition: o = !1 } = e;
|
|
3803
4010
|
return t.$$set = (s) => {
|
|
3804
4011
|
"condition" in s && r(0, o = s.condition), "$$scope" in s && r(2, i = s.$$scope);
|
|
3805
4012
|
}, [o, n, i];
|
|
3806
4013
|
}
|
|
3807
|
-
class
|
|
4014
|
+
class so extends U {
|
|
3808
4015
|
constructor(e) {
|
|
3809
|
-
super(), N(this, e,
|
|
4016
|
+
super(), N(this, e, oo, io, T, { condition: 0 });
|
|
3810
4017
|
}
|
|
3811
4018
|
}
|
|
3812
|
-
const
|
|
3813
|
-
function
|
|
4019
|
+
const lo = (t) => ({}), _t = (t) => ({});
|
|
4020
|
+
function co(t) {
|
|
3814
4021
|
let e, r;
|
|
3815
4022
|
const n = (
|
|
3816
4023
|
/*#slots*/
|
|
@@ -3820,7 +4027,7 @@ function so(t) {
|
|
|
3820
4027
|
t,
|
|
3821
4028
|
/*$$scope*/
|
|
3822
4029
|
t[2],
|
|
3823
|
-
|
|
4030
|
+
_t
|
|
3824
4031
|
), o = (
|
|
3825
4032
|
/*#slots*/
|
|
3826
4033
|
t[1].default
|
|
@@ -3851,12 +4058,12 @@ function so(t) {
|
|
|
3851
4058
|
/*$$scope*/
|
|
3852
4059
|
l[2],
|
|
3853
4060
|
c,
|
|
3854
|
-
|
|
4061
|
+
lo
|
|
3855
4062
|
) : V(
|
|
3856
4063
|
/*$$scope*/
|
|
3857
4064
|
l[2]
|
|
3858
4065
|
),
|
|
3859
|
-
|
|
4066
|
+
_t
|
|
3860
4067
|
), s && s.p && (!r || c & /*$$scope*/
|
|
3861
4068
|
4) && J(
|
|
3862
4069
|
s,
|
|
@@ -3888,15 +4095,15 @@ function so(t) {
|
|
|
3888
4095
|
}
|
|
3889
4096
|
};
|
|
3890
4097
|
}
|
|
3891
|
-
function
|
|
4098
|
+
function ao(t) {
|
|
3892
4099
|
let e, r;
|
|
3893
|
-
return e = new
|
|
4100
|
+
return e = new eo({
|
|
3894
4101
|
props: {
|
|
3895
4102
|
dark: (
|
|
3896
4103
|
/*dark*/
|
|
3897
4104
|
t[0]
|
|
3898
4105
|
),
|
|
3899
|
-
$$slots: { default: [
|
|
4106
|
+
$$slots: { default: [co] },
|
|
3900
4107
|
$$scope: { ctx: t }
|
|
3901
4108
|
}
|
|
3902
4109
|
}), {
|
|
@@ -3924,168 +4131,18 @@ function lo(t) {
|
|
|
3924
4131
|
}
|
|
3925
4132
|
};
|
|
3926
4133
|
}
|
|
3927
|
-
function
|
|
4134
|
+
function uo(t, e, r) {
|
|
3928
4135
|
let { $$slots: n = {}, $$scope: i } = e, { dark: o = !1 } = e;
|
|
3929
4136
|
return t.$$set = (s) => {
|
|
3930
4137
|
"dark" in s && r(0, o = s.dark), "$$scope" in s && r(2, i = s.$$scope);
|
|
3931
4138
|
}, [o, n, i];
|
|
3932
4139
|
}
|
|
3933
|
-
class
|
|
4140
|
+
class Ft extends U {
|
|
3934
4141
|
constructor(e) {
|
|
3935
|
-
super(), N(this, e,
|
|
4142
|
+
super(), N(this, e, uo, ao, T, { dark: 0 });
|
|
3936
4143
|
}
|
|
3937
4144
|
}
|
|
3938
|
-
|
|
3939
|
-
class he {
|
|
3940
|
-
static getPublicMessage(e) {
|
|
3941
|
-
switch (e) {
|
|
3942
|
-
case 0:
|
|
3943
|
-
return "Unknown error.";
|
|
3944
|
-
case 1:
|
|
3945
|
-
return "Purchase was cancelled.";
|
|
3946
|
-
case 2:
|
|
3947
|
-
return "There was a problem with the store.";
|
|
3948
|
-
case 3:
|
|
3949
|
-
return "The device or user is not allowed to make the purchase.";
|
|
3950
|
-
case 4:
|
|
3951
|
-
return "One or more of the arguments provided are invalid.";
|
|
3952
|
-
case 5:
|
|
3953
|
-
return "The product is not available for purchase.";
|
|
3954
|
-
case 6:
|
|
3955
|
-
return "This product is already active for the user.";
|
|
3956
|
-
case 7:
|
|
3957
|
-
return "There is already another active subscriber using the same receipt.";
|
|
3958
|
-
case 8:
|
|
3959
|
-
return "The receipt is not valid.";
|
|
3960
|
-
case 9:
|
|
3961
|
-
return "The receipt is missing.";
|
|
3962
|
-
case 10:
|
|
3963
|
-
return "Error performing request.";
|
|
3964
|
-
case 11:
|
|
3965
|
-
return "There was a credentials issue. Check the underlying error for more details.";
|
|
3966
|
-
case 12:
|
|
3967
|
-
return "Received unexpected response from the backend.";
|
|
3968
|
-
case 14:
|
|
3969
|
-
return "The app user id is not valid.";
|
|
3970
|
-
case 15:
|
|
3971
|
-
return "The operation is already in progress.";
|
|
3972
|
-
case 16:
|
|
3973
|
-
return "There was an unknown backend error.";
|
|
3974
|
-
case 17:
|
|
3975
|
-
return "Apple Subscription Key is invalid or not present. In order to provide subscription offers, you must first generate a subscription key. Please see https://docs.revenuecat.com/docs/ios-subscription-offers for more info.";
|
|
3976
|
-
case 18:
|
|
3977
|
-
return "The User is ineligible for that action.";
|
|
3978
|
-
case 19:
|
|
3979
|
-
return "App does not have sufficient permissions to make purchases.";
|
|
3980
|
-
case 20:
|
|
3981
|
-
return "The payment is pending.";
|
|
3982
|
-
case 21:
|
|
3983
|
-
return "One or more of the attributes sent could not be saved.";
|
|
3984
|
-
case 22:
|
|
3985
|
-
return "Called logOut but the current user is anonymous.";
|
|
3986
|
-
case 23:
|
|
3987
|
-
return "There is an issue with your configuration. Check the underlying error for more details.";
|
|
3988
|
-
case 24:
|
|
3989
|
-
return "There was a problem with the operation. Looks like we doesn't support that yet. Check the underlying error for more details.";
|
|
3990
|
-
case 25:
|
|
3991
|
-
return "A request for subscriber attributes returned none.";
|
|
3992
|
-
case 28:
|
|
3993
|
-
return "There was a problem related to the customer info.";
|
|
3994
|
-
case 36:
|
|
3995
|
-
return "Request failed signature verification. Please see https://rev.cat/trusted-entitlements for more info.";
|
|
3996
|
-
}
|
|
3997
|
-
}
|
|
3998
|
-
static getErrorCodeForBackendErrorCode(e) {
|
|
3999
|
-
switch (e) {
|
|
4000
|
-
case 7101:
|
|
4001
|
-
return 2;
|
|
4002
|
-
case 7102:
|
|
4003
|
-
return 7;
|
|
4004
|
-
case 7103:
|
|
4005
|
-
return 8;
|
|
4006
|
-
case 7107:
|
|
4007
|
-
case 7224:
|
|
4008
|
-
case 7225:
|
|
4009
|
-
return 11;
|
|
4010
|
-
case 7105:
|
|
4011
|
-
case 7106:
|
|
4012
|
-
return 4;
|
|
4013
|
-
case 7220:
|
|
4014
|
-
return 14;
|
|
4015
|
-
case 7229:
|
|
4016
|
-
return 2;
|
|
4017
|
-
case 7230:
|
|
4018
|
-
case 7e3:
|
|
4019
|
-
return 23;
|
|
4020
|
-
case 7231:
|
|
4021
|
-
return 2;
|
|
4022
|
-
case 7232:
|
|
4023
|
-
return 18;
|
|
4024
|
-
case 7263:
|
|
4025
|
-
case 7264:
|
|
4026
|
-
return 21;
|
|
4027
|
-
case 7104:
|
|
4028
|
-
case 7234:
|
|
4029
|
-
case 7226:
|
|
4030
|
-
case 7110:
|
|
4031
|
-
return 12;
|
|
4032
|
-
case 7662:
|
|
4033
|
-
return 24;
|
|
4034
|
-
}
|
|
4035
|
-
}
|
|
4036
|
-
static convertCodeToBackendErrorCode(e) {
|
|
4037
|
-
return e in Ft ? e : null;
|
|
4038
|
-
}
|
|
4039
|
-
static convertPurchaseFlowErrorCodeToErrorCode(e) {
|
|
4040
|
-
switch (e) {
|
|
4041
|
-
case L.ErrorSettingUpPurchase:
|
|
4042
|
-
return 2;
|
|
4043
|
-
case L.ErrorChargingPayment:
|
|
4044
|
-
return 20;
|
|
4045
|
-
case L.NetworkError:
|
|
4046
|
-
return 10;
|
|
4047
|
-
case L.MissingEmailError:
|
|
4048
|
-
return 4;
|
|
4049
|
-
case L.StripeError:
|
|
4050
|
-
return 2;
|
|
4051
|
-
case L.UnknownError:
|
|
4052
|
-
return 0;
|
|
4053
|
-
}
|
|
4054
|
-
}
|
|
4055
|
-
}
|
|
4056
|
-
var Ft = /* @__PURE__ */ ((t) => (t[t.BackendInvalidPlatform = 7e3] = "BackendInvalidPlatform", t[t.BackendStoreProblem = 7101] = "BackendStoreProblem", t[t.BackendCannotTransferPurchase = 7102] = "BackendCannotTransferPurchase", t[t.BackendInvalidReceiptToken = 7103] = "BackendInvalidReceiptToken", t[t.BackendInvalidAppStoreSharedSecret = 7104] = "BackendInvalidAppStoreSharedSecret", t[t.BackendInvalidPaymentModeOrIntroPriceNotProvided = 7105] = "BackendInvalidPaymentModeOrIntroPriceNotProvided", t[t.BackendProductIdForGoogleReceiptNotProvided = 7106] = "BackendProductIdForGoogleReceiptNotProvided", t[t.BackendInvalidPlayStoreCredentials = 7107] = "BackendInvalidPlayStoreCredentials", t[t.BackendInternalServerError = 7110] = "BackendInternalServerError", t[t.BackendEmptyAppUserId = 7220] = "BackendEmptyAppUserId", t[t.BackendInvalidAuthToken = 7224] = "BackendInvalidAuthToken", t[t.BackendInvalidAPIKey = 7225] = "BackendInvalidAPIKey", t[t.BackendBadRequest = 7226] = "BackendBadRequest", t[t.BackendPlayStoreQuotaExceeded = 7229] = "BackendPlayStoreQuotaExceeded", t[t.BackendPlayStoreInvalidPackageName = 7230] = "BackendPlayStoreInvalidPackageName", t[t.BackendPlayStoreGenericError = 7231] = "BackendPlayStoreGenericError", t[t.BackendUserIneligibleForPromoOffer = 7232] = "BackendUserIneligibleForPromoOffer", t[t.BackendInvalidAppleSubscriptionKey = 7234] = "BackendInvalidAppleSubscriptionKey", t[t.BackendInvalidSubscriberAttributes = 7263] = "BackendInvalidSubscriberAttributes", t[t.BackendInvalidSubscriberAttributesBody = 7264] = "BackendInvalidSubscriberAttributesBody", t[t.BackendProductIDsMalformed = 7662] = "BackendProductIDsMalformed", t))(Ft || {});
|
|
4057
|
-
class X extends Error {
|
|
4058
|
-
constructor(r, n, i) {
|
|
4059
|
-
super(n);
|
|
4060
|
-
Q(this, "toString", () => `PurchasesError(code: ${ne[this.errorCode]}, message: ${this.message})`);
|
|
4061
|
-
this.errorCode = r, this.underlyingErrorMessage = i;
|
|
4062
|
-
}
|
|
4063
|
-
/** @internal */
|
|
4064
|
-
static getForBackendError(r, n) {
|
|
4065
|
-
const i = he.getErrorCodeForBackendErrorCode(r);
|
|
4066
|
-
return new X(
|
|
4067
|
-
i,
|
|
4068
|
-
he.getPublicMessage(i),
|
|
4069
|
-
n
|
|
4070
|
-
);
|
|
4071
|
-
}
|
|
4072
|
-
/** @internal */
|
|
4073
|
-
static getForPurchasesFlowError(r) {
|
|
4074
|
-
return new X(
|
|
4075
|
-
he.convertPurchaseFlowErrorCodeToErrorCode(
|
|
4076
|
-
r.errorCode
|
|
4077
|
-
),
|
|
4078
|
-
r.message,
|
|
4079
|
-
r.underlyingErrorMessage
|
|
4080
|
-
);
|
|
4081
|
-
}
|
|
4082
|
-
}
|
|
4083
|
-
class ao extends Error {
|
|
4084
|
-
constructor() {
|
|
4085
|
-
super("Purchases must be configured before calling getInstance");
|
|
4086
|
-
}
|
|
4087
|
-
}
|
|
4088
|
-
const uo = "0.3.0", fe = "https://api.revenuecat.com";
|
|
4145
|
+
const fo = "0.3.2", fe = "https://api.revenuecat.com";
|
|
4089
4146
|
var Re;
|
|
4090
4147
|
(function(t) {
|
|
4091
4148
|
t[t.CONTINUE = 100] = "CONTINUE", t[t.SWITCHING_PROTOCOLS = 101] = "SWITCHING_PROTOCOLS", t[t.PROCESSING = 102] = "PROCESSING", t[t.EARLY_HINTS = 103] = "EARLY_HINTS", t[t.OK = 200] = "OK", t[t.CREATED = 201] = "CREATED", t[t.ACCEPTED = 202] = "ACCEPTED", t[t.NON_AUTHORITATIVE_INFORMATION = 203] = "NON_AUTHORITATIVE_INFORMATION", t[t.NO_CONTENT = 204] = "NO_CONTENT", t[t.RESET_CONTENT = 205] = "RESET_CONTENT", t[t.PARTIAL_CONTENT = 206] = "PARTIAL_CONTENT", t[t.MULTI_STATUS = 207] = "MULTI_STATUS", t[t.MULTIPLE_CHOICES = 300] = "MULTIPLE_CHOICES", t[t.MOVED_PERMANENTLY = 301] = "MOVED_PERMANENTLY", t[t.MOVED_TEMPORARILY = 302] = "MOVED_TEMPORARILY", t[t.SEE_OTHER = 303] = "SEE_OTHER", t[t.NOT_MODIFIED = 304] = "NOT_MODIFIED", t[t.USE_PROXY = 305] = "USE_PROXY", t[t.TEMPORARY_REDIRECT = 307] = "TEMPORARY_REDIRECT", t[t.PERMANENT_REDIRECT = 308] = "PERMANENT_REDIRECT", t[t.BAD_REQUEST = 400] = "BAD_REQUEST", t[t.UNAUTHORIZED = 401] = "UNAUTHORIZED", t[t.PAYMENT_REQUIRED = 402] = "PAYMENT_REQUIRED", t[t.FORBIDDEN = 403] = "FORBIDDEN", t[t.NOT_FOUND = 404] = "NOT_FOUND", t[t.METHOD_NOT_ALLOWED = 405] = "METHOD_NOT_ALLOWED", t[t.NOT_ACCEPTABLE = 406] = "NOT_ACCEPTABLE", t[t.PROXY_AUTHENTICATION_REQUIRED = 407] = "PROXY_AUTHENTICATION_REQUIRED", t[t.REQUEST_TIMEOUT = 408] = "REQUEST_TIMEOUT", t[t.CONFLICT = 409] = "CONFLICT", t[t.GONE = 410] = "GONE", t[t.LENGTH_REQUIRED = 411] = "LENGTH_REQUIRED", t[t.PRECONDITION_FAILED = 412] = "PRECONDITION_FAILED", t[t.REQUEST_TOO_LONG = 413] = "REQUEST_TOO_LONG", t[t.REQUEST_URI_TOO_LONG = 414] = "REQUEST_URI_TOO_LONG", t[t.UNSUPPORTED_MEDIA_TYPE = 415] = "UNSUPPORTED_MEDIA_TYPE", t[t.REQUESTED_RANGE_NOT_SATISFIABLE = 416] = "REQUESTED_RANGE_NOT_SATISFIABLE", t[t.EXPECTATION_FAILED = 417] = "EXPECTATION_FAILED", t[t.IM_A_TEAPOT = 418] = "IM_A_TEAPOT", t[t.INSUFFICIENT_SPACE_ON_RESOURCE = 419] = "INSUFFICIENT_SPACE_ON_RESOURCE", t[t.METHOD_FAILURE = 420] = "METHOD_FAILURE", t[t.MISDIRECTED_REQUEST = 421] = "MISDIRECTED_REQUEST", t[t.UNPROCESSABLE_ENTITY = 422] = "UNPROCESSABLE_ENTITY", t[t.LOCKED = 423] = "LOCKED", t[t.FAILED_DEPENDENCY = 424] = "FAILED_DEPENDENCY", t[t.UPGRADE_REQUIRED = 426] = "UPGRADE_REQUIRED", t[t.PRECONDITION_REQUIRED = 428] = "PRECONDITION_REQUIRED", t[t.TOO_MANY_REQUESTS = 429] = "TOO_MANY_REQUESTS", t[t.REQUEST_HEADER_FIELDS_TOO_LARGE = 431] = "REQUEST_HEADER_FIELDS_TOO_LARGE", t[t.UNAVAILABLE_FOR_LEGAL_REASONS = 451] = "UNAVAILABLE_FOR_LEGAL_REASONS", t[t.INTERNAL_SERVER_ERROR = 500] = "INTERNAL_SERVER_ERROR", t[t.NOT_IMPLEMENTED = 501] = "NOT_IMPLEMENTED", t[t.BAD_GATEWAY = 502] = "BAD_GATEWAY", t[t.SERVICE_UNAVAILABLE = 503] = "SERVICE_UNAVAILABLE", t[t.GATEWAY_TIMEOUT = 504] = "GATEWAY_TIMEOUT", t[t.HTTP_VERSION_NOT_SUPPORTED = 505] = "HTTP_VERSION_NOT_SUPPORTED", t[t.INSUFFICIENT_STORAGE = 507] = "INSUFFICIENT_STORAGE", t[t.NETWORK_AUTHENTICATION_REQUIRED = 511] = "NETWORK_AUTHENTICATION_REQUIRED";
|
|
@@ -4097,19 +4154,19 @@ async function oe(t, e, r, n) {
|
|
|
4097
4154
|
try {
|
|
4098
4155
|
const i = await fetch(t.url(), {
|
|
4099
4156
|
method: t.method,
|
|
4100
|
-
headers:
|
|
4101
|
-
body:
|
|
4157
|
+
headers: po(e, n),
|
|
4158
|
+
body: go(r)
|
|
4102
4159
|
});
|
|
4103
|
-
return await
|
|
4160
|
+
return await mo(i, t), await i.json();
|
|
4104
4161
|
} catch (i) {
|
|
4105
4162
|
throw i instanceof TypeError ? new X(
|
|
4106
|
-
|
|
4107
|
-
he.getPublicMessage(
|
|
4163
|
+
ee.NetworkError,
|
|
4164
|
+
he.getPublicMessage(ee.NetworkError),
|
|
4108
4165
|
i.message
|
|
4109
4166
|
) : i;
|
|
4110
4167
|
}
|
|
4111
4168
|
}
|
|
4112
|
-
async function
|
|
4169
|
+
async function mo(t, e) {
|
|
4113
4170
|
const r = t.status;
|
|
4114
4171
|
if (r >= Re.INTERNAL_SERVER_ERROR)
|
|
4115
4172
|
Ye(e, r, await t.text());
|
|
@@ -4130,26 +4187,26 @@ async function fo(t, e) {
|
|
|
4130
4187
|
}
|
|
4131
4188
|
function Ye(t, e, r) {
|
|
4132
4189
|
throw new X(
|
|
4133
|
-
|
|
4190
|
+
ee.UnknownBackendError,
|
|
4134
4191
|
`Unknown backend error. Request: ${t.name}. Status code: ${e}. Body: ${r}.`
|
|
4135
4192
|
);
|
|
4136
4193
|
}
|
|
4137
|
-
function
|
|
4194
|
+
function go(t) {
|
|
4138
4195
|
return t == null ? null : JSON.stringify(t);
|
|
4139
4196
|
}
|
|
4140
|
-
function
|
|
4197
|
+
function po(t, e) {
|
|
4141
4198
|
let r = {
|
|
4142
4199
|
Authorization: `Bearer ${t}`,
|
|
4143
4200
|
"Content-Type": "application/json",
|
|
4144
4201
|
Accept: "application/json",
|
|
4145
4202
|
"X-Platform": "web",
|
|
4146
|
-
"X-Version":
|
|
4203
|
+
"X-Version": fo,
|
|
4147
4204
|
"X-Is-Sandbox": `${je(t)}`
|
|
4148
4205
|
};
|
|
4149
4206
|
return e != null && (r = { ...r, ...e }), r;
|
|
4150
4207
|
}
|
|
4151
4208
|
const Gt = "/v1/subscribers", Le = "/rcbilling/v1";
|
|
4152
|
-
class
|
|
4209
|
+
class _o {
|
|
4153
4210
|
constructor(e) {
|
|
4154
4211
|
Q(this, "appUserId");
|
|
4155
4212
|
Q(this, "method", "GET");
|
|
@@ -4161,7 +4218,7 @@ class po {
|
|
|
4161
4218
|
return `${fe}${Gt}/${e}/offerings`;
|
|
4162
4219
|
}
|
|
4163
4220
|
}
|
|
4164
|
-
class
|
|
4221
|
+
class Ao {
|
|
4165
4222
|
constructor() {
|
|
4166
4223
|
Q(this, "method", "POST");
|
|
4167
4224
|
Q(this, "name", "subscribe");
|
|
@@ -4170,7 +4227,7 @@ class _o {
|
|
|
4170
4227
|
return `${fe}${Le}/subscribe`;
|
|
4171
4228
|
}
|
|
4172
4229
|
}
|
|
4173
|
-
class
|
|
4230
|
+
class ho {
|
|
4174
4231
|
constructor(e, r) {
|
|
4175
4232
|
Q(this, "method", "GET");
|
|
4176
4233
|
Q(this, "name", "getProducts");
|
|
@@ -4183,7 +4240,7 @@ class Ao {
|
|
|
4183
4240
|
return `${fe}${Le}/subscribers/${e}/products?id=${r}`;
|
|
4184
4241
|
}
|
|
4185
4242
|
}
|
|
4186
|
-
class
|
|
4243
|
+
class Eo {
|
|
4187
4244
|
constructor(e) {
|
|
4188
4245
|
Q(this, "method", "GET");
|
|
4189
4246
|
Q(this, "name", "getCustomerInfo");
|
|
@@ -4195,7 +4252,7 @@ class ho {
|
|
|
4195
4252
|
return `${fe}${Gt}/${e}`;
|
|
4196
4253
|
}
|
|
4197
4254
|
}
|
|
4198
|
-
class
|
|
4255
|
+
class bo {
|
|
4199
4256
|
constructor() {
|
|
4200
4257
|
Q(this, "method", "GET");
|
|
4201
4258
|
Q(this, "name", "getBrandingInfo");
|
|
@@ -4204,7 +4261,7 @@ class Eo {
|
|
|
4204
4261
|
return `${fe}${Le}/branding`;
|
|
4205
4262
|
}
|
|
4206
4263
|
}
|
|
4207
|
-
class
|
|
4264
|
+
class Io {
|
|
4208
4265
|
constructor(e) {
|
|
4209
4266
|
Q(this, "method", "GET");
|
|
4210
4267
|
Q(this, "name", "getCheckoutStatus");
|
|
@@ -4215,32 +4272,32 @@ class bo {
|
|
|
4215
4272
|
return `${fe}${Le}/checkout/${this.operationSessionId}`;
|
|
4216
4273
|
}
|
|
4217
4274
|
}
|
|
4218
|
-
class
|
|
4275
|
+
class wo {
|
|
4219
4276
|
constructor(e) {
|
|
4220
4277
|
Q(this, "API_KEY");
|
|
4221
4278
|
this.API_KEY = e;
|
|
4222
4279
|
}
|
|
4223
4280
|
async getOfferings(e) {
|
|
4224
4281
|
return await oe(
|
|
4225
|
-
new
|
|
4282
|
+
new _o(e),
|
|
4226
4283
|
this.API_KEY
|
|
4227
4284
|
);
|
|
4228
4285
|
}
|
|
4229
4286
|
async getCustomerInfo(e) {
|
|
4230
4287
|
return await oe(
|
|
4231
|
-
new
|
|
4288
|
+
new Eo(e),
|
|
4232
4289
|
this.API_KEY
|
|
4233
4290
|
);
|
|
4234
4291
|
}
|
|
4235
4292
|
async getProducts(e, r) {
|
|
4236
4293
|
return await oe(
|
|
4237
|
-
new
|
|
4294
|
+
new ho(e, r),
|
|
4238
4295
|
this.API_KEY
|
|
4239
4296
|
);
|
|
4240
4297
|
}
|
|
4241
4298
|
async getBrandingInfo() {
|
|
4242
4299
|
return await oe(
|
|
4243
|
-
new
|
|
4300
|
+
new bo(),
|
|
4244
4301
|
this.API_KEY
|
|
4245
4302
|
);
|
|
4246
4303
|
}
|
|
@@ -4252,24 +4309,24 @@ class Io {
|
|
|
4252
4309
|
presented_offering_identifier: i
|
|
4253
4310
|
};
|
|
4254
4311
|
return o && o !== "base_option" && (s.offer_id = o), await oe(
|
|
4255
|
-
new
|
|
4312
|
+
new Ao(),
|
|
4256
4313
|
this.API_KEY,
|
|
4257
4314
|
s
|
|
4258
4315
|
);
|
|
4259
4316
|
}
|
|
4260
4317
|
async getCheckoutStatus(e) {
|
|
4261
4318
|
return await oe(
|
|
4262
|
-
new
|
|
4319
|
+
new Io(e),
|
|
4263
4320
|
this.API_KEY
|
|
4264
4321
|
);
|
|
4265
4322
|
}
|
|
4266
4323
|
}
|
|
4267
|
-
const
|
|
4268
|
-
function
|
|
4324
|
+
const ko = "data:image/svg+xml,%3csvg%20width='24'%20height='24'%20viewBox='0%200%2024%2024'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cg%20opacity='0.5'%20clip-path='url(%23clip0_344_3390)'%3e%3cpath%20d='M7%2018C5.9%2018%205.01%2018.9%205.01%2020C5.01%2021.1%205.9%2022%207%2022C8.1%2022%209%2021.1%209%2020C9%2018.9%208.1%2018%207%2018ZM1%202V4H3L6.6%2011.59L5.25%2014.04C5.09%2014.32%205%2014.65%205%2015C5%2016.1%205.9%2017%207%2017H19V15H7.42C7.28%2015%207.17%2014.89%207.17%2014.75L7.2%2014.63L8.1%2013H15.55C16.3%2013%2016.96%2012.59%2017.3%2011.97L20.88%205.48C20.96%205.34%2021%205.17%2021%205C21%204.45%2020.55%204%2020%204H5.21L4.27%202H1ZM17%2018C15.9%2018%2015.01%2018.9%2015.01%2020C15.01%2021.1%2015.9%2022%2017%2022C18.1%2022%2019%2021.1%2019%2020C19%2018.9%2018.1%2018%2017%2018Z'%20fill='white'/%3e%3c/g%3e%3cdefs%3e%3cclipPath%20id='clip0_344_3390'%3e%3crect%20width='24'%20height='24'%20fill='white'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e";
|
|
4325
|
+
function $o(t) {
|
|
4269
4326
|
let e, r;
|
|
4270
4327
|
return {
|
|
4271
4328
|
c() {
|
|
4272
|
-
e = k("img"), Z(e.src, r =
|
|
4329
|
+
e = k("img"), Z(e.src, r = ko) || _(e, "src", r), _(e, "alt", "icon"), _(e, "class", "rcb-ui-asset-icon");
|
|
4273
4330
|
},
|
|
4274
4331
|
m(n, i) {
|
|
4275
4332
|
p(n, e, i);
|
|
@@ -4282,15 +4339,15 @@ function ko(t) {
|
|
|
4282
4339
|
}
|
|
4283
4340
|
};
|
|
4284
4341
|
}
|
|
4285
|
-
class
|
|
4342
|
+
class vo extends U {
|
|
4286
4343
|
constructor(e) {
|
|
4287
|
-
super(), N(this, e, null,
|
|
4344
|
+
super(), N(this, e, null, $o, T, {});
|
|
4288
4345
|
}
|
|
4289
4346
|
}
|
|
4290
|
-
function
|
|
4347
|
+
function yo(t) {
|
|
4291
4348
|
x(t, "svelte-1rhrjxe", "div.svelte-1rhrjxe{background-color:var(--rc-color-warning);color:var(--rc-color-grey-text-dark);font-size:10px;font-weight:bold;text-transform:uppercase;padding:4px 10px;line-height:10px;border-radius:9px;margin:0px;margin-left:16px}");
|
|
4292
4349
|
}
|
|
4293
|
-
function
|
|
4350
|
+
function Bo(t) {
|
|
4294
4351
|
let e;
|
|
4295
4352
|
return {
|
|
4296
4353
|
c() {
|
|
@@ -4307,22 +4364,22 @@ function yo(t) {
|
|
|
4307
4364
|
}
|
|
4308
4365
|
};
|
|
4309
4366
|
}
|
|
4310
|
-
class
|
|
4367
|
+
class Do extends U {
|
|
4311
4368
|
constructor(e) {
|
|
4312
|
-
super(), N(this, e, null,
|
|
4369
|
+
super(), N(this, e, null, Bo, T, {}, yo);
|
|
4313
4370
|
}
|
|
4314
4371
|
}
|
|
4315
|
-
function
|
|
4372
|
+
function Mo(t) {
|
|
4316
4373
|
x(t, "svelte-1qect5g", `.rcb-ui-container.svelte-1qect5g{color-scheme:none;font-size:16px;line-height:1.5em;font-weight:400;font-family:-apple-system, "system-ui", "Segoe UI", Roboto, Oxygen, Ubuntu,
|
|
4317
4374
|
Cantarell, "Open Sans", "Helvetica Neue", sans-serif}.rcb-ui-layout.svelte-1qect5g{width:100vw;width:100 dvw;margin-right:auto;display:flex;justify-content:center;align-items:flex-start;position:relative;padding:0px 80px;box-sizing:border-box}.rcb-ui-aside.svelte-1qect5g{margin-right:16px;flex:320px 1 0;max-width:480px}.rcb-ui-main.svelte-1qect5g{flex:480px 1 0;max-width:640px}@media screen and (max-width: 960px){.rcb-ui-layout.svelte-1qect5g{flex-direction:column;align-items:center;justify-content:center;height:100%;min-width:100%}.rcb-ui-aside.svelte-1qect5g{margin-right:0;margin-bottom:16px;min-width:100%;display:flex;flex-direction:column;align-items:center;flex:none;max-width:none}.rcb-ui-main.svelte-1qect5g{flex:none;max-width:none;min-width:100%}}@media screen and (max-width: 960px) and (max-height: 960px){.rcb-ui-layout.svelte-1qect5g{overflow-y:scroll;justify-content:flex-start;padding:16px 0px}}`);
|
|
4318
4375
|
}
|
|
4319
|
-
function
|
|
4376
|
+
function At(t) {
|
|
4320
4377
|
let e, r, n;
|
|
4321
|
-
return r = new
|
|
4378
|
+
return r = new Ft({
|
|
4322
4379
|
props: {
|
|
4323
4380
|
dark: !0,
|
|
4324
4381
|
$$slots: {
|
|
4325
|
-
header: [
|
|
4382
|
+
header: [No],
|
|
4326
4383
|
default: [Co]
|
|
4327
4384
|
},
|
|
4328
4385
|
$$scope: { ctx: t }
|
|
@@ -4350,7 +4407,7 @@ function _t(t) {
|
|
|
4350
4407
|
}
|
|
4351
4408
|
};
|
|
4352
4409
|
}
|
|
4353
|
-
function
|
|
4410
|
+
function ht(t) {
|
|
4354
4411
|
let e, r;
|
|
4355
4412
|
return e = new Pt({
|
|
4356
4413
|
props: {
|
|
@@ -4393,11 +4450,11 @@ function Co(t) {
|
|
|
4393
4450
|
let e, r, n = (
|
|
4394
4451
|
/*productDetails*/
|
|
4395
4452
|
t[3] && /*purchaseOption*/
|
|
4396
|
-
t[1] &&
|
|
4453
|
+
t[1] && ht(t)
|
|
4397
4454
|
);
|
|
4398
4455
|
return {
|
|
4399
4456
|
c() {
|
|
4400
|
-
n && n.c(), e =
|
|
4457
|
+
n && n.c(), e = te();
|
|
4401
4458
|
},
|
|
4402
4459
|
m(i, o) {
|
|
4403
4460
|
n && n.m(i, o), p(i, e, o), r = !0;
|
|
@@ -4406,9 +4463,9 @@ function Co(t) {
|
|
|
4406
4463
|
/*productDetails*/
|
|
4407
4464
|
i[3] && /*purchaseOption*/
|
|
4408
4465
|
i[1] ? n ? (n.p(i, o), o & /*productDetails, purchaseOption*/
|
|
4409
|
-
10 && f(n, 1)) : (n =
|
|
4466
|
+
10 && f(n, 1)) : (n = ht(i), n.c(), f(n, 1), n.m(e.parentNode, e)) : n && (H(), m(n, 1, 1, () => {
|
|
4410
4467
|
n = null;
|
|
4411
|
-
}),
|
|
4468
|
+
}), K());
|
|
4412
4469
|
},
|
|
4413
4470
|
i(i) {
|
|
4414
4471
|
r || (f(n), r = !0);
|
|
@@ -4421,9 +4478,9 @@ function Co(t) {
|
|
|
4421
4478
|
}
|
|
4422
4479
|
};
|
|
4423
4480
|
}
|
|
4424
|
-
function
|
|
4481
|
+
function Qo(t) {
|
|
4425
4482
|
let e, r;
|
|
4426
|
-
return e = new
|
|
4483
|
+
return e = new vo({}), {
|
|
4427
4484
|
c() {
|
|
4428
4485
|
w(e.$$.fragment);
|
|
4429
4486
|
},
|
|
@@ -4441,9 +4498,9 @@ function Mo(t) {
|
|
|
4441
4498
|
}
|
|
4442
4499
|
};
|
|
4443
4500
|
}
|
|
4444
|
-
function
|
|
4501
|
+
function Po(t) {
|
|
4445
4502
|
let e, r;
|
|
4446
|
-
return e = new
|
|
4503
|
+
return e = new Do({}), {
|
|
4447
4504
|
c() {
|
|
4448
4505
|
w(e.$$.fragment);
|
|
4449
4506
|
},
|
|
@@ -4461,15 +4518,15 @@ function Qo(t) {
|
|
|
4461
4518
|
}
|
|
4462
4519
|
};
|
|
4463
4520
|
}
|
|
4464
|
-
function
|
|
4521
|
+
function To(t) {
|
|
4465
4522
|
let e, r, n, i, o, s, l;
|
|
4466
|
-
e = new
|
|
4523
|
+
e = new Ut({
|
|
4467
4524
|
props: { brandingInfo: (
|
|
4468
4525
|
/*brandingInfo*/
|
|
4469
4526
|
t[4]
|
|
4470
4527
|
) }
|
|
4471
4528
|
});
|
|
4472
|
-
const c = [
|
|
4529
|
+
const c = [Po, Qo], a = [];
|
|
4473
4530
|
function u(d, h) {
|
|
4474
4531
|
return h & /*purchases*/
|
|
4475
4532
|
4 && (n = null), n == null && (n = !!/*purchases*/
|
|
@@ -4477,7 +4534,7 @@ function Po(t) {
|
|
|
4477
4534
|
}
|
|
4478
4535
|
return i = u(t, -1), o = a[i] = c[i](t), {
|
|
4479
4536
|
c() {
|
|
4480
|
-
w(e.$$.fragment), r = P(), o.c(), s =
|
|
4537
|
+
w(e.$$.fragment), r = P(), o.c(), s = te();
|
|
4481
4538
|
},
|
|
4482
4539
|
m(d, h) {
|
|
4483
4540
|
b(e, d, h), p(d, r, h), a[i].m(d, h), p(d, s, h), l = !0;
|
|
@@ -4488,9 +4545,9 @@ function Po(t) {
|
|
|
4488
4545
|
16 && ($.brandingInfo = /*brandingInfo*/
|
|
4489
4546
|
d[4]), e.$set($);
|
|
4490
4547
|
let E = i;
|
|
4491
|
-
i = u(d, h), i !== E && (
|
|
4548
|
+
i = u(d, h), i !== E && (H(), m(a[E], 1, 1, () => {
|
|
4492
4549
|
a[E] = null;
|
|
4493
|
-
}),
|
|
4550
|
+
}), K(), o = a[i], o || (o = a[i] = c[i](d), o.c()), f(o, 1), o.m(s.parentNode, s));
|
|
4494
4551
|
},
|
|
4495
4552
|
i(d) {
|
|
4496
4553
|
l || (f(e.$$.fragment, d), f(o), l = !0);
|
|
@@ -4503,12 +4560,12 @@ function Po(t) {
|
|
|
4503
4560
|
}
|
|
4504
4561
|
};
|
|
4505
4562
|
}
|
|
4506
|
-
function
|
|
4563
|
+
function No(t) {
|
|
4507
4564
|
let e, r;
|
|
4508
|
-
return e = new
|
|
4565
|
+
return e = new Xe({
|
|
4509
4566
|
props: {
|
|
4510
4567
|
slot: "header",
|
|
4511
|
-
$$slots: { default: [
|
|
4568
|
+
$$slots: { default: [To] },
|
|
4512
4569
|
$$scope: { ctx: t }
|
|
4513
4570
|
}
|
|
4514
4571
|
}), {
|
|
@@ -4534,7 +4591,7 @@ function To(t) {
|
|
|
4534
4591
|
}
|
|
4535
4592
|
};
|
|
4536
4593
|
}
|
|
4537
|
-
function
|
|
4594
|
+
function Et(t) {
|
|
4538
4595
|
let e, r;
|
|
4539
4596
|
return e = new Pt({
|
|
4540
4597
|
props: {
|
|
@@ -4573,9 +4630,9 @@ function ht(t) {
|
|
|
4573
4630
|
}
|
|
4574
4631
|
};
|
|
4575
4632
|
}
|
|
4576
|
-
function
|
|
4633
|
+
function bt(t) {
|
|
4577
4634
|
let e, r;
|
|
4578
|
-
return e = new
|
|
4635
|
+
return e = new We({}), {
|
|
4579
4636
|
c() {
|
|
4580
4637
|
w(e.$$.fragment);
|
|
4581
4638
|
},
|
|
@@ -4593,9 +4650,9 @@ function Et(t) {
|
|
|
4593
4650
|
}
|
|
4594
4651
|
};
|
|
4595
4652
|
}
|
|
4596
|
-
function
|
|
4653
|
+
function It(t) {
|
|
4597
4654
|
let e, r;
|
|
4598
|
-
return e = new
|
|
4655
|
+
return e = new qi({
|
|
4599
4656
|
props: {
|
|
4600
4657
|
onContinue: (
|
|
4601
4658
|
/*handleContinue*/
|
|
@@ -4634,9 +4691,9 @@ function bt(t) {
|
|
|
4634
4691
|
}
|
|
4635
4692
|
};
|
|
4636
4693
|
}
|
|
4637
|
-
function
|
|
4694
|
+
function wt(t) {
|
|
4638
4695
|
let e, r;
|
|
4639
|
-
return e = new
|
|
4696
|
+
return e = new Ti({
|
|
4640
4697
|
props: {
|
|
4641
4698
|
paymentInfoCollectionMetadata: (
|
|
4642
4699
|
/*paymentInfoCollectionMetadata*/
|
|
@@ -4685,9 +4742,9 @@ function It(t) {
|
|
|
4685
4742
|
}
|
|
4686
4743
|
};
|
|
4687
4744
|
}
|
|
4688
|
-
function
|
|
4745
|
+
function kt(t) {
|
|
4689
4746
|
let e, r;
|
|
4690
|
-
return e = new
|
|
4747
|
+
return e = new We({}), {
|
|
4691
4748
|
c() {
|
|
4692
4749
|
w(e.$$.fragment);
|
|
4693
4750
|
},
|
|
@@ -4705,10 +4762,10 @@ function wt(t) {
|
|
|
4705
4762
|
}
|
|
4706
4763
|
};
|
|
4707
4764
|
}
|
|
4708
|
-
function
|
|
4765
|
+
function $t(t) {
|
|
4709
4766
|
var n;
|
|
4710
4767
|
let e, r;
|
|
4711
|
-
return e = new
|
|
4768
|
+
return e = new Sr({
|
|
4712
4769
|
props: {
|
|
4713
4770
|
brandingInfo: (
|
|
4714
4771
|
/*brandingInfo*/
|
|
@@ -4716,7 +4773,7 @@ function kt(t) {
|
|
|
4716
4773
|
),
|
|
4717
4774
|
lastError: (
|
|
4718
4775
|
/*lastError*/
|
|
4719
|
-
t[6] ?? new
|
|
4776
|
+
t[6] ?? new Y(O.UnknownError, "Unknown error without state set.")
|
|
4720
4777
|
),
|
|
4721
4778
|
supportEmail: (
|
|
4722
4779
|
/*brandingInfo*/
|
|
@@ -4741,7 +4798,7 @@ function kt(t) {
|
|
|
4741
4798
|
16 && (s.brandingInfo = /*brandingInfo*/
|
|
4742
4799
|
i[4]), o & /*lastError*/
|
|
4743
4800
|
64 && (s.lastError = /*lastError*/
|
|
4744
|
-
i[6] ?? new
|
|
4801
|
+
i[6] ?? new Y(O.UnknownError, "Unknown error without state set.")), o & /*brandingInfo*/
|
|
4745
4802
|
16 && (s.supportEmail = /*brandingInfo*/
|
|
4746
4803
|
(l = i[4]) == null ? void 0 : l.seller_company_support_email), e.$set(s);
|
|
4747
4804
|
},
|
|
@@ -4756,9 +4813,9 @@ function kt(t) {
|
|
|
4756
4813
|
}
|
|
4757
4814
|
};
|
|
4758
4815
|
}
|
|
4759
|
-
function
|
|
4816
|
+
function vt(t) {
|
|
4760
4817
|
let e, r;
|
|
4761
|
-
return e = new
|
|
4818
|
+
return e = new qr({
|
|
4762
4819
|
props: {
|
|
4763
4820
|
brandingInfo: (
|
|
4764
4821
|
/*brandingInfo*/
|
|
@@ -4793,38 +4850,38 @@ function $t(t) {
|
|
|
4793
4850
|
}
|
|
4794
4851
|
};
|
|
4795
4852
|
}
|
|
4796
|
-
function
|
|
4853
|
+
function Uo(t) {
|
|
4797
4854
|
let e, r, n, i, o, s, l, c, a = (
|
|
4798
4855
|
/*state*/
|
|
4799
4856
|
t[7] === "present-offer" && /*productDetails*/
|
|
4800
4857
|
t[3] && /*purchaseOption*/
|
|
4801
|
-
t[1] &&
|
|
4858
|
+
t[1] && Et(t)
|
|
4802
4859
|
), u = (
|
|
4803
4860
|
/*state*/
|
|
4804
4861
|
t[7] === "present-offer" && !/*productDetails*/
|
|
4805
|
-
t[3] &&
|
|
4862
|
+
t[3] && bt()
|
|
4806
4863
|
), d = (
|
|
4807
4864
|
/*state*/
|
|
4808
4865
|
(t[7] === "needs-auth-info" || /*state*/
|
|
4809
|
-
t[7] === "processing-auth-info") &&
|
|
4866
|
+
t[7] === "processing-auth-info") && It(t)
|
|
4810
4867
|
), h = (
|
|
4811
4868
|
/*paymentInfoCollectionMetadata*/
|
|
4812
4869
|
t[5] && /*state*/
|
|
4813
4870
|
(t[7] === "needs-payment-info" || /*state*/
|
|
4814
|
-
t[7] === "polling-purchase-status") &&
|
|
4871
|
+
t[7] === "polling-purchase-status") && wt(t)
|
|
4815
4872
|
), $ = (
|
|
4816
4873
|
/*state*/
|
|
4817
|
-
t[7] === "loading" &&
|
|
4874
|
+
t[7] === "loading" && kt()
|
|
4818
4875
|
), E = (
|
|
4819
4876
|
/*state*/
|
|
4820
|
-
t[7] === "error" &&
|
|
4877
|
+
t[7] === "error" && $t(t)
|
|
4821
4878
|
), B = (
|
|
4822
4879
|
/*state*/
|
|
4823
|
-
t[7] === "success" &&
|
|
4880
|
+
t[7] === "success" && vt(t)
|
|
4824
4881
|
);
|
|
4825
4882
|
return {
|
|
4826
4883
|
c() {
|
|
4827
|
-
a && a.c(), e = P(), u && u.c(), r = P(), d && d.c(), n = P(), h && h.c(), i = P(), $ && $.c(), o = P(), E && E.c(), s = P(), B && B.c(), l =
|
|
4884
|
+
a && a.c(), e = P(), u && u.c(), r = P(), d && d.c(), n = P(), h && h.c(), i = P(), $ && $.c(), o = P(), E && E.c(), s = P(), B && B.c(), l = te();
|
|
4828
4885
|
},
|
|
4829
4886
|
m(A, y) {
|
|
4830
4887
|
a && a.m(A, y), p(A, e, y), u && u.m(A, y), p(A, r, y), d && d.m(A, y), p(A, n, y), h && h.m(A, y), p(A, i, y), $ && $.m(A, y), p(A, o, y), E && E.m(A, y), p(A, s, y), B && B.m(A, y), p(A, l, y), c = !0;
|
|
@@ -4834,37 +4891,37 @@ function No(t) {
|
|
|
4834
4891
|
A[7] === "present-offer" && /*productDetails*/
|
|
4835
4892
|
A[3] && /*purchaseOption*/
|
|
4836
4893
|
A[1] ? a ? (a.p(A, y), y & /*state, productDetails, purchaseOption*/
|
|
4837
|
-
138 && f(a, 1)) : (a =
|
|
4894
|
+
138 && f(a, 1)) : (a = Et(A), a.c(), f(a, 1), a.m(e.parentNode, e)) : a && (H(), m(a, 1, 1, () => {
|
|
4838
4895
|
a = null;
|
|
4839
|
-
}),
|
|
4896
|
+
}), K()), /*state*/
|
|
4840
4897
|
A[7] === "present-offer" && !/*productDetails*/
|
|
4841
4898
|
A[3] ? u ? y & /*state, productDetails*/
|
|
4842
|
-
136 && f(u, 1) : (u =
|
|
4899
|
+
136 && f(u, 1) : (u = bt(), u.c(), f(u, 1), u.m(r.parentNode, r)) : u && (H(), m(u, 1, 1, () => {
|
|
4843
4900
|
u = null;
|
|
4844
|
-
}),
|
|
4901
|
+
}), K()), /*state*/
|
|
4845
4902
|
A[7] === "needs-auth-info" || /*state*/
|
|
4846
4903
|
A[7] === "processing-auth-info" ? d ? (d.p(A, y), y & /*state*/
|
|
4847
|
-
128 && f(d, 1)) : (d =
|
|
4904
|
+
128 && f(d, 1)) : (d = It(A), d.c(), f(d, 1), d.m(n.parentNode, n)) : d && (H(), m(d, 1, 1, () => {
|
|
4848
4905
|
d = null;
|
|
4849
|
-
}),
|
|
4906
|
+
}), K()), /*paymentInfoCollectionMetadata*/
|
|
4850
4907
|
A[5] && /*state*/
|
|
4851
4908
|
(A[7] === "needs-payment-info" || /*state*/
|
|
4852
4909
|
A[7] === "polling-purchase-status") ? h ? (h.p(A, y), y & /*paymentInfoCollectionMetadata, state*/
|
|
4853
|
-
160 && f(h, 1)) : (h =
|
|
4910
|
+
160 && f(h, 1)) : (h = wt(A), h.c(), f(h, 1), h.m(i.parentNode, i)) : h && (H(), m(h, 1, 1, () => {
|
|
4854
4911
|
h = null;
|
|
4855
|
-
}),
|
|
4912
|
+
}), K()), /*state*/
|
|
4856
4913
|
A[7] === "loading" ? $ ? y & /*state*/
|
|
4857
|
-
128 && f($, 1) : ($ =
|
|
4914
|
+
128 && f($, 1) : ($ = kt(), $.c(), f($, 1), $.m(o.parentNode, o)) : $ && (H(), m($, 1, 1, () => {
|
|
4858
4915
|
$ = null;
|
|
4859
|
-
}),
|
|
4916
|
+
}), K()), /*state*/
|
|
4860
4917
|
A[7] === "error" ? E ? (E.p(A, y), y & /*state*/
|
|
4861
|
-
128 && f(E, 1)) : (E =
|
|
4918
|
+
128 && f(E, 1)) : (E = $t(A), E.c(), f(E, 1), E.m(s.parentNode, s)) : E && (H(), m(E, 1, 1, () => {
|
|
4862
4919
|
E = null;
|
|
4863
|
-
}),
|
|
4920
|
+
}), K()), /*state*/
|
|
4864
4921
|
A[7] === "success" ? B ? (B.p(A, y), y & /*state*/
|
|
4865
|
-
128 && f(B, 1)) : (B =
|
|
4922
|
+
128 && f(B, 1)) : (B = vt(A), B.c(), f(B, 1), B.m(l.parentNode, l)) : B && (H(), m(B, 1, 1, () => {
|
|
4866
4923
|
B = null;
|
|
4867
|
-
}),
|
|
4924
|
+
}), K());
|
|
4868
4925
|
},
|
|
4869
4926
|
i(A) {
|
|
4870
4927
|
c || (f(a), f(u), f(d), f(h), f($), f(E), f(B), c = !0);
|
|
@@ -4877,17 +4934,17 @@ function No(t) {
|
|
|
4877
4934
|
}
|
|
4878
4935
|
};
|
|
4879
4936
|
}
|
|
4880
|
-
function
|
|
4937
|
+
function Ro(t) {
|
|
4881
4938
|
let e, r = (
|
|
4882
4939
|
/*statesWhereOfferDetailsAreShown*/
|
|
4883
4940
|
t[9].includes(
|
|
4884
4941
|
/*state*/
|
|
4885
4942
|
t[7]
|
|
4886
4943
|
)
|
|
4887
|
-
), n, i, o, s, l = r &&
|
|
4888
|
-
return o = new
|
|
4944
|
+
), n, i, o, s, l = r && At(t);
|
|
4945
|
+
return o = new Ft({
|
|
4889
4946
|
props: {
|
|
4890
|
-
$$slots: { default: [
|
|
4947
|
+
$$slots: { default: [Uo] },
|
|
4891
4948
|
$$scope: { ctx: t }
|
|
4892
4949
|
}
|
|
4893
4950
|
}), {
|
|
@@ -4900,7 +4957,7 @@ function Uo(t) {
|
|
|
4900
4957
|
);
|
|
4901
4958
|
},
|
|
4902
4959
|
m(c, a) {
|
|
4903
|
-
p(c, e, a), l && l.m(e, null),
|
|
4960
|
+
p(c, e, a), l && l.m(e, null), C(e, n), C(e, i), b(o, i, null), s = !0;
|
|
4904
4961
|
},
|
|
4905
4962
|
p(c, a) {
|
|
4906
4963
|
a & /*state*/
|
|
@@ -4909,9 +4966,9 @@ function Uo(t) {
|
|
|
4909
4966
|
/*state*/
|
|
4910
4967
|
c[7]
|
|
4911
4968
|
)), r ? l ? (l.p(c, a), a & /*state*/
|
|
4912
|
-
128 && f(l, 1)) : (l =
|
|
4969
|
+
128 && f(l, 1)) : (l = At(c), l.c(), f(l, 1), l.m(e, n)) : l && (H(), m(l, 1, 1, () => {
|
|
4913
4970
|
l = null;
|
|
4914
|
-
}),
|
|
4971
|
+
}), K());
|
|
4915
4972
|
const u = {};
|
|
4916
4973
|
a & /*$$scope, brandingInfo, state, lastError, paymentInfoCollectionMetadata, productDetails, purchaseOption*/
|
|
4917
4974
|
67109114 && (u.$$scope = { dirty: a, ctx: c }), o.$set(u);
|
|
@@ -4927,15 +4984,15 @@ function Uo(t) {
|
|
|
4927
4984
|
}
|
|
4928
4985
|
};
|
|
4929
4986
|
}
|
|
4930
|
-
function
|
|
4987
|
+
function So(t) {
|
|
4931
4988
|
let e, r, n;
|
|
4932
|
-
return r = new
|
|
4989
|
+
return r = new so({
|
|
4933
4990
|
props: {
|
|
4934
4991
|
condition: (
|
|
4935
4992
|
/*asModal*/
|
|
4936
4993
|
t[0]
|
|
4937
4994
|
),
|
|
4938
|
-
$$slots: { default: [
|
|
4995
|
+
$$slots: { default: [Ro] },
|
|
4939
4996
|
$$scope: { ctx: t }
|
|
4940
4997
|
}
|
|
4941
4998
|
}), {
|
|
@@ -4964,12 +5021,12 @@ function Ro(t) {
|
|
|
4964
5021
|
};
|
|
4965
5022
|
}
|
|
4966
5023
|
function Oo(t, e, r) {
|
|
4967
|
-
var
|
|
5024
|
+
var et, tt;
|
|
4968
5025
|
let { asModal: n = !0 } = e, { customerEmail: i } = e, { appUserId: o } = e, { rcPackage: s } = e, { purchaseOption: l } = e, { onFinished: c } = e, { onError: a } = e, { onClose: u } = e, { purchases: d } = e, { backend: h } = e, { purchaseOperationHelper: $ } = e;
|
|
4969
5026
|
const E = Object.entries(_e).map(([D, xe]) => `--rc-color-${D}: ${xe}`).join("; ");
|
|
4970
5027
|
let B = null, A = null, y = null, R = null;
|
|
4971
|
-
const
|
|
4972
|
-
let
|
|
5028
|
+
const M = ((et = s == null ? void 0 : s.rcBillingProduct) == null ? void 0 : et.identifier) ?? null, ve = (tt = s == null ? void 0 : s.rcBillingProduct) == null ? void 0 : tt.defaultSubscriptionOption, F = l || ve;
|
|
5029
|
+
let S = "present-offer";
|
|
4973
5030
|
const ye = [
|
|
4974
5031
|
"present-offer",
|
|
4975
5032
|
"needs-auth-info",
|
|
@@ -4978,58 +5035,58 @@ function Oo(t, e, r) {
|
|
|
4978
5035
|
"polling-purchase-status",
|
|
4979
5036
|
"loading"
|
|
4980
5037
|
];
|
|
4981
|
-
|
|
4982
|
-
if (r(3, B = s.rcBillingProduct), r(4, A = await h.getBrandingInfo()),
|
|
4983
|
-
i ?
|
|
5038
|
+
Oe(async () => {
|
|
5039
|
+
if (r(3, B = s.rcBillingProduct), r(4, A = await h.getBrandingInfo()), S === "present-offer") {
|
|
5040
|
+
i ? Ze() : r(7, S = "needs-auth-info");
|
|
4984
5041
|
return;
|
|
4985
5042
|
}
|
|
4986
5043
|
});
|
|
4987
5044
|
const Be = () => {
|
|
4988
5045
|
u();
|
|
4989
|
-
},
|
|
4990
|
-
if (
|
|
4991
|
-
de(new
|
|
5046
|
+
}, Ze = () => {
|
|
5047
|
+
if (M === null) {
|
|
5048
|
+
de(new Y(O.ErrorSettingUpPurchase, "Product ID was not set before purchase."));
|
|
4992
5049
|
return;
|
|
4993
5050
|
} else
|
|
4994
|
-
|
|
5051
|
+
S === "present-offer" && r(7, S = "loading");
|
|
4995
5052
|
if (!i) {
|
|
4996
|
-
de(new
|
|
5053
|
+
de(new Y(O.MissingEmailError));
|
|
4997
5054
|
return;
|
|
4998
5055
|
}
|
|
4999
|
-
$.startPurchase(o,
|
|
5056
|
+
$.startPurchase(o, M, F, i, s.rcBillingProduct.presentedOfferingIdentifier).then((D) => {
|
|
5000
5057
|
if (D.next_action === "collect_payment_info") {
|
|
5001
|
-
r(7,
|
|
5058
|
+
r(7, S = "needs-payment-info"), r(5, y = D);
|
|
5002
5059
|
return;
|
|
5003
5060
|
}
|
|
5004
5061
|
if (D.next_action === "completed") {
|
|
5005
|
-
r(7,
|
|
5062
|
+
r(7, S = "success");
|
|
5006
5063
|
return;
|
|
5007
5064
|
}
|
|
5008
5065
|
}).catch((D) => {
|
|
5009
|
-
de(
|
|
5066
|
+
de(D);
|
|
5010
5067
|
});
|
|
5011
5068
|
}, Yt = (D) => {
|
|
5012
|
-
if (
|
|
5013
|
-
D && (r(14, i = D.email), r(7,
|
|
5069
|
+
if (S === "needs-auth-info") {
|
|
5070
|
+
D && (r(14, i = D.email), r(7, S = "processing-auth-info")), Ze();
|
|
5014
5071
|
return;
|
|
5015
5072
|
}
|
|
5016
|
-
if (
|
|
5017
|
-
r(7,
|
|
5018
|
-
r(7,
|
|
5073
|
+
if (S === "needs-payment-info") {
|
|
5074
|
+
r(7, S = "polling-purchase-status"), $.pollCurrentPurchaseForCompletion().then(() => {
|
|
5075
|
+
r(7, S = "success");
|
|
5019
5076
|
}).catch((xe) => {
|
|
5020
5077
|
de(xe);
|
|
5021
5078
|
});
|
|
5022
5079
|
return;
|
|
5023
5080
|
}
|
|
5024
|
-
if (
|
|
5081
|
+
if (S === "success" || S === "error") {
|
|
5025
5082
|
c();
|
|
5026
5083
|
return;
|
|
5027
5084
|
}
|
|
5028
|
-
r(7,
|
|
5085
|
+
r(7, S = "success");
|
|
5029
5086
|
}, de = (D) => {
|
|
5030
|
-
r(6, R = D), r(7,
|
|
5087
|
+
r(6, R = D), r(7, S = "error");
|
|
5031
5088
|
}, Ht = () => {
|
|
5032
|
-
a(R ?? new
|
|
5089
|
+
a(R ?? new Y(O.UnknownError, "Unknown error without state set."));
|
|
5033
5090
|
};
|
|
5034
5091
|
return t.$$set = (D) => {
|
|
5035
5092
|
"asModal" in D && r(0, n = D.asModal), "customerEmail" in D && r(14, i = D.customerEmail), "appUserId" in D && r(15, o = D.appUserId), "rcPackage" in D && r(16, s = D.rcPackage), "purchaseOption" in D && r(1, l = D.purchaseOption), "onFinished" in D && r(17, c = D.onFinished), "onError" in D && r(18, a = D.onError), "onClose" in D && r(19, u = D.onClose), "purchases" in D && r(2, d = D.purchases), "backend" in D && r(20, h = D.backend), "purchaseOperationHelper" in D && r(21, $ = D.purchaseOperationHelper);
|
|
@@ -5041,7 +5098,7 @@ function Oo(t, e, r) {
|
|
|
5041
5098
|
A,
|
|
5042
5099
|
y,
|
|
5043
5100
|
R,
|
|
5044
|
-
|
|
5101
|
+
S,
|
|
5045
5102
|
E,
|
|
5046
5103
|
ye,
|
|
5047
5104
|
Be,
|
|
@@ -5058,13 +5115,13 @@ function Oo(t, e, r) {
|
|
|
5058
5115
|
$
|
|
5059
5116
|
];
|
|
5060
5117
|
}
|
|
5061
|
-
class
|
|
5118
|
+
class Lo extends U {
|
|
5062
5119
|
constructor(e) {
|
|
5063
5120
|
super(), N(
|
|
5064
5121
|
this,
|
|
5065
5122
|
e,
|
|
5066
5123
|
Oo,
|
|
5067
|
-
|
|
5124
|
+
So,
|
|
5068
5125
|
T,
|
|
5069
5126
|
{
|
|
5070
5127
|
asModal: 0,
|
|
@@ -5079,37 +5136,37 @@ class So extends U {
|
|
|
5079
5136
|
backend: 20,
|
|
5080
5137
|
purchaseOperationHelper: 21
|
|
5081
5138
|
},
|
|
5082
|
-
|
|
5139
|
+
Mo
|
|
5083
5140
|
);
|
|
5084
5141
|
}
|
|
5085
5142
|
}
|
|
5086
|
-
function
|
|
5143
|
+
function xo(t) {
|
|
5087
5144
|
return t.expires_date == null ? !0 : new Date(t.expires_date) > /* @__PURE__ */ new Date();
|
|
5088
5145
|
}
|
|
5089
|
-
function
|
|
5146
|
+
function Fo(t, e, r, n) {
|
|
5090
5147
|
const i = e.product_identifier;
|
|
5091
5148
|
if (i in r)
|
|
5092
|
-
return
|
|
5149
|
+
return Go(
|
|
5093
5150
|
t,
|
|
5094
5151
|
e,
|
|
5095
5152
|
r[i]
|
|
5096
5153
|
);
|
|
5097
5154
|
if (i in n)
|
|
5098
|
-
return
|
|
5155
|
+
return Yo(
|
|
5099
5156
|
t,
|
|
5100
5157
|
e,
|
|
5101
5158
|
n[i]
|
|
5102
5159
|
);
|
|
5103
5160
|
throw new X(
|
|
5104
|
-
|
|
5161
|
+
ee.CustomerInfoError,
|
|
5105
5162
|
"Could not find entitlement product in subscriptions or non-subscriptions."
|
|
5106
5163
|
);
|
|
5107
5164
|
}
|
|
5108
|
-
function
|
|
5165
|
+
function Go(t, e, r) {
|
|
5109
5166
|
return {
|
|
5110
5167
|
identifier: t,
|
|
5111
|
-
isActive:
|
|
5112
|
-
willRenew:
|
|
5168
|
+
isActive: xo(e),
|
|
5169
|
+
willRenew: qo(e, r),
|
|
5113
5170
|
store: (r == null ? void 0 : r.store) ?? "unknown",
|
|
5114
5171
|
latestPurchaseDate: new Date(e.purchase_date),
|
|
5115
5172
|
originalPurchaseDate: new Date(e.purchase_date),
|
|
@@ -5125,7 +5182,7 @@ function Fo(t, e, r) {
|
|
|
5125
5182
|
periodType: (r == null ? void 0 : r.period_type) ?? "normal"
|
|
5126
5183
|
};
|
|
5127
5184
|
}
|
|
5128
|
-
function
|
|
5185
|
+
function Yo(t, e, r) {
|
|
5129
5186
|
return {
|
|
5130
5187
|
identifier: t,
|
|
5131
5188
|
isActive: !0,
|
|
@@ -5143,10 +5200,10 @@ function Go(t, e, r) {
|
|
|
5143
5200
|
periodType: "normal"
|
|
5144
5201
|
};
|
|
5145
5202
|
}
|
|
5146
|
-
function
|
|
5203
|
+
function Ho(t, e, r) {
|
|
5147
5204
|
const n = {}, i = {};
|
|
5148
5205
|
for (const o in t) {
|
|
5149
|
-
const s =
|
|
5206
|
+
const s = Fo(
|
|
5150
5207
|
o,
|
|
5151
5208
|
t[o],
|
|
5152
5209
|
e,
|
|
@@ -5162,22 +5219,22 @@ function Yo(t, e, r) {
|
|
|
5162
5219
|
function Ne(t) {
|
|
5163
5220
|
return t == null ? null : new Date(t);
|
|
5164
5221
|
}
|
|
5165
|
-
function
|
|
5166
|
-
const e =
|
|
5222
|
+
function Ko(t) {
|
|
5223
|
+
const e = Jo(t), r = t.subscriber, n = Wo(
|
|
5167
5224
|
r.non_subscriptions
|
|
5168
5225
|
);
|
|
5169
5226
|
return {
|
|
5170
|
-
entitlements:
|
|
5227
|
+
entitlements: Ho(
|
|
5171
5228
|
r.entitlements,
|
|
5172
5229
|
r.subscriptions,
|
|
5173
5230
|
n
|
|
5174
5231
|
),
|
|
5175
5232
|
allExpirationDatesByProduct: e,
|
|
5176
|
-
allPurchaseDatesByProduct:
|
|
5233
|
+
allPurchaseDatesByProduct: jo(
|
|
5177
5234
|
t,
|
|
5178
5235
|
n
|
|
5179
5236
|
),
|
|
5180
|
-
activeSubscriptions:
|
|
5237
|
+
activeSubscriptions: Vo(e),
|
|
5181
5238
|
managementURL: r.management_url,
|
|
5182
5239
|
requestDate: new Date(t.request_date),
|
|
5183
5240
|
firstSeenDate: new Date(r.first_seen),
|
|
@@ -5187,13 +5244,13 @@ function Ho(t) {
|
|
|
5187
5244
|
originalAppUserId: t.subscriber.original_app_user_id
|
|
5188
5245
|
};
|
|
5189
5246
|
}
|
|
5190
|
-
function
|
|
5247
|
+
function qo(t, e) {
|
|
5191
5248
|
if (e == null)
|
|
5192
5249
|
return !1;
|
|
5193
5250
|
const r = e.store == "promotional", n = t.expires_date == null, i = e.unsubscribe_detected_at != null, o = e.billing_issues_detected_at != null;
|
|
5194
5251
|
return !(r || n || i || o);
|
|
5195
5252
|
}
|
|
5196
|
-
function
|
|
5253
|
+
function jo(t, e) {
|
|
5197
5254
|
const r = {};
|
|
5198
5255
|
for (const n in t.subscriber.subscriptions) {
|
|
5199
5256
|
const i = t.subscriber.subscriptions[n];
|
|
@@ -5207,7 +5264,7 @@ function qo(t, e) {
|
|
|
5207
5264
|
}
|
|
5208
5265
|
return r;
|
|
5209
5266
|
}
|
|
5210
|
-
function
|
|
5267
|
+
function Jo(t) {
|
|
5211
5268
|
const e = {};
|
|
5212
5269
|
for (const r in t.subscriber.subscriptions) {
|
|
5213
5270
|
const n = t.subscriber.subscriptions[r];
|
|
@@ -5217,7 +5274,7 @@ function jo(t) {
|
|
|
5217
5274
|
}
|
|
5218
5275
|
return e;
|
|
5219
5276
|
}
|
|
5220
|
-
function
|
|
5277
|
+
function Vo(t) {
|
|
5221
5278
|
const e = /* @__PURE__ */ new Set(), r = /* @__PURE__ */ new Date();
|
|
5222
5279
|
for (const n in t) {
|
|
5223
5280
|
const i = t[n];
|
|
@@ -5225,7 +5282,7 @@ function Jo(t) {
|
|
|
5225
5282
|
}
|
|
5226
5283
|
return e;
|
|
5227
5284
|
}
|
|
5228
|
-
function
|
|
5285
|
+
function Wo(t) {
|
|
5229
5286
|
const e = {};
|
|
5230
5287
|
for (const r in t) {
|
|
5231
5288
|
if (t[r].length === 0)
|
|
@@ -5235,14 +5292,14 @@ function Vo(t) {
|
|
|
5235
5292
|
}
|
|
5236
5293
|
return e;
|
|
5237
5294
|
}
|
|
5238
|
-
function
|
|
5295
|
+
function zo(t) {
|
|
5239
5296
|
if (!/^rcb_[a-zA-Z0-9_.-]+$/.test(t))
|
|
5240
5297
|
throw new X(
|
|
5241
|
-
|
|
5298
|
+
ee.InvalidCredentialsError,
|
|
5242
5299
|
"Invalid API key. Use your RevenueCat Billing API key."
|
|
5243
5300
|
);
|
|
5244
5301
|
}
|
|
5245
|
-
function
|
|
5302
|
+
function Xo(t) {
|
|
5246
5303
|
if ((/* @__PURE__ */ new Set([
|
|
5247
5304
|
"no_user",
|
|
5248
5305
|
"null",
|
|
@@ -5257,7 +5314,7 @@ function zo(t) {
|
|
|
5257
5314
|
"unknown"
|
|
5258
5315
|
])).has(t) || t.includes("/"))
|
|
5259
5316
|
throw new X(
|
|
5260
|
-
|
|
5317
|
+
ee.InvalidAppUserIdError,
|
|
5261
5318
|
'Provided user id: "' + t + '" is not valid. See https://www.revenuecat.com/docs/customers/user-ids#tips-for-setting-app-user-ids for more information.'
|
|
5262
5319
|
);
|
|
5263
5320
|
}
|
|
@@ -5280,9 +5337,9 @@ const z = class z {
|
|
|
5280
5337
|
r.product_details.forEach((l) => {
|
|
5281
5338
|
i[l.identifier] = l;
|
|
5282
5339
|
});
|
|
5283
|
-
const o = n == null ? null :
|
|
5340
|
+
const o = n == null ? null : it(n, i), s = {};
|
|
5284
5341
|
return e.offerings.forEach((l) => {
|
|
5285
|
-
const c =
|
|
5342
|
+
const c = it(l, i);
|
|
5286
5343
|
c != null && (s[l.identifier] = c);
|
|
5287
5344
|
}), Object.keys(s).length == 0 && G.debugLog(
|
|
5288
5345
|
"Empty offerings. Please make sure you've configured offerings correctly in the RevenueCat dashboard and that the products are properly configured."
|
|
@@ -5291,7 +5348,7 @@ const z = class z {
|
|
|
5291
5348
|
current: o
|
|
5292
5349
|
};
|
|
5293
5350
|
});
|
|
5294
|
-
this._API_KEY = e, this._appUserId = r, je(e) && G.debugLog("Initializing Purchases SDK with sandbox API Key"), this.backend = new
|
|
5351
|
+
this._API_KEY = e, this._appUserId = r, je(e) && G.debugLog("Initializing Purchases SDK with sandbox API Key"), this.backend = new wo(this._API_KEY), this.purchaseOperationHelper = new Yn(this.backend);
|
|
5295
5352
|
}
|
|
5296
5353
|
/**
|
|
5297
5354
|
* Set the log level. Logs of the given level and below will be printed
|
|
@@ -5310,7 +5367,7 @@ const z = class z {
|
|
|
5310
5367
|
static getSharedInstance() {
|
|
5311
5368
|
if (z.isConfigured())
|
|
5312
5369
|
return z.instance;
|
|
5313
|
-
throw new
|
|
5370
|
+
throw new Gn();
|
|
5314
5371
|
}
|
|
5315
5372
|
/**
|
|
5316
5373
|
* Returns whether the Purchases SDK is configured or not.
|
|
@@ -5329,7 +5386,7 @@ const z = class z {
|
|
|
5329
5386
|
static configure(e, r) {
|
|
5330
5387
|
return z.instance !== void 0 && G.warnLog(
|
|
5331
5388
|
"Purchases is already initialized. You normally should only configure Purchases once. Creating and returning new instance."
|
|
5332
|
-
),
|
|
5389
|
+
), zo(e), Xo(r), z.instance = new z(e, r), z.getSharedInstance();
|
|
5333
5390
|
}
|
|
5334
5391
|
/**
|
|
5335
5392
|
* Fetch the configured offerings for this user. You can configure these
|
|
@@ -5397,7 +5454,7 @@ const z = class z {
|
|
|
5397
5454
|
return G.debugLog(
|
|
5398
5455
|
`Presenting purchase form for package ${r.identifier}`
|
|
5399
5456
|
), new Promise((u, d) => {
|
|
5400
|
-
new
|
|
5457
|
+
new Lo({
|
|
5401
5458
|
target: l,
|
|
5402
5459
|
props: {
|
|
5403
5460
|
appUserId: a,
|
|
@@ -5410,7 +5467,7 @@ const z = class z {
|
|
|
5410
5467
|
});
|
|
5411
5468
|
},
|
|
5412
5469
|
onClose: () => {
|
|
5413
|
-
l.innerHTML = "", G.debugLog("Purchase cancelled by user"), d(new X(
|
|
5470
|
+
l.innerHTML = "", G.debugLog("Purchase cancelled by user"), d(new X(ee.UserCancelledError));
|
|
5414
5471
|
},
|
|
5415
5472
|
onError: (h) => {
|
|
5416
5473
|
l.innerHTML = "", d(X.getForPurchasesFlowError(h));
|
|
@@ -5477,17 +5534,17 @@ const z = class z {
|
|
|
5477
5534
|
/** @internal */
|
|
5478
5535
|
async _getCustomerInfoForUserId(e) {
|
|
5479
5536
|
const r = await this.backend.getCustomerInfo(e);
|
|
5480
|
-
return
|
|
5537
|
+
return Ko(r);
|
|
5481
5538
|
}
|
|
5482
5539
|
};
|
|
5483
5540
|
/** @internal */
|
|
5484
5541
|
Q(z, "instance");
|
|
5485
|
-
let
|
|
5542
|
+
let yt = z;
|
|
5486
5543
|
export {
|
|
5487
|
-
|
|
5544
|
+
ee as ErrorCode,
|
|
5488
5545
|
W as LogLevel,
|
|
5489
5546
|
zt as PackageType,
|
|
5490
|
-
|
|
5547
|
+
yt as Purchases,
|
|
5491
5548
|
X as PurchasesError,
|
|
5492
|
-
|
|
5549
|
+
Gn as UninitializedPurchasesError
|
|
5493
5550
|
};
|