@heliofi/checkout-react 2.1.0 → 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1,21 +1,17 @@
|
|
|
1
|
-
|
|
1
|
+
import { BlockchainSymbol } from '@heliofi/common';
|
|
2
|
+
|
|
2
3
|
mainButtonTitle?: string;
|
|
3
4
|
payButtonTitle?: string;
|
|
4
5
|
}
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
declare type EmbedPaymentType = 'paylink' | 'paystream';
|
|
9
|
-
|
|
10
|
-
declare type EmbedThemeMode = 'light' | 'dark';
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
11
9
|
|
|
12
10
|
export declare const HelioCheckout: (props: HelioCheckoutReactProps) => JSX.Element;
|
|
13
|
-
|
|
14
|
-
declare interface HelioCheckoutReactProps {
|
|
11
|
+
|
|
15
12
|
config: HelioEmbedConfig;
|
|
16
13
|
}
|
|
17
|
-
|
|
18
|
-
declare interface HelioEmbedConfig {
|
|
14
|
+
|
|
19
15
|
paylinkId: string;
|
|
20
16
|
network?: NetworkType;
|
|
21
17
|
debug?: boolean;
|
|
@@ -36,7 +32,7 @@ declare interface HelioEmbedConfig {
|
|
|
36
32
|
transaction: string;
|
|
37
33
|
paymentPK?: string;
|
|
38
34
|
swapTransactionSignature?: string;
|
|
39
|
-
blockchainSymbol?:
|
|
35
|
+
blockchainSymbol?: BlockchainSymbol;
|
|
40
36
|
redirectUrl?: string;
|
|
41
37
|
}) => void;
|
|
42
38
|
onError?: (event: {
|
|
@@ -46,14 +42,15 @@ declare interface HelioEmbedConfig {
|
|
|
46
42
|
onPending?: (event: {
|
|
47
43
|
data?: unknown;
|
|
48
44
|
transaction: string;
|
|
45
|
+
redirectUrl?: string;
|
|
46
|
+
blockchainSymbol?: BlockchainSymbol;
|
|
49
47
|
}) => void;
|
|
50
48
|
onCancel?: (error?: {
|
|
51
49
|
errorMessage?: string;
|
|
52
50
|
}) => void;
|
|
53
51
|
onStartPayment?: () => void;
|
|
54
52
|
}
|
|
55
|
-
|
|
56
|
-
declare interface HelioEmbedTheme {
|
|
53
|
+
|
|
57
54
|
themeMode: EmbedThemeMode;
|
|
58
55
|
colors?: {
|
|
59
56
|
primaryButtonBackground?: string;
|
|
@@ -66,22 +63,18 @@ declare interface HelioEmbedTheme {
|
|
|
66
63
|
backgroundContainer?: string;
|
|
67
64
|
backgroundSecondary?: string;
|
|
68
65
|
primaryButtonShadow?: string;
|
|
69
|
-
/** @deprecated -
|
|
66
|
+
/** @deprecated - for internal use only */
|
|
70
67
|
shadowPrimaryGray?: string;
|
|
71
68
|
shadowWalletButton?: string;
|
|
72
69
|
textLabel?: string;
|
|
73
70
|
iconFillColor?: string;
|
|
74
71
|
};
|
|
75
72
|
}
|
|
76
|
-
|
|
77
|
-
declare type Json = Json[] | boolean | null | number | string | {
|
|
73
|
+
|
|
78
74
|
[key: string]: Json;
|
|
79
75
|
};
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
declare type PrimaryPaymentMethod = 'fiat' | 'crypto';
|
|
84
|
-
|
|
85
|
-
declare type WidgetPlatform = 'magic_eden' | 'helio';
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
|
|
86
79
|
|
|
87
80
|
export { }
|
|
@@ -2,7 +2,7 @@ import we, { Component as fr, useRef as dr, useState as Z, useEffect as Te, useL
|
|
|
2
2
|
var Q = { exports: {} }, L = {};
|
|
3
3
|
/**
|
|
4
4
|
* @license React
|
|
5
|
-
* react-jsx-runtime.
|
|
5
|
+
* react-jsx-runtime.production.min.js
|
|
6
6
|
*
|
|
7
7
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
8
8
|
*
|
|
@@ -11,8 +11,32 @@ var Q = { exports: {} }, L = {};
|
|
|
11
11
|
*/
|
|
12
12
|
var Se;
|
|
13
13
|
function pr() {
|
|
14
|
-
|
|
15
|
-
|
|
14
|
+
if (Se) return L;
|
|
15
|
+
Se = 1;
|
|
16
|
+
var l = we, d = Symbol.for("react.element"), P = Symbol.for("react.fragment"), S = Object.prototype.hasOwnProperty, b = l.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, j = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
17
|
+
function O(R, f, _) {
|
|
18
|
+
var v, E = {}, y = null, m = null;
|
|
19
|
+
_ !== void 0 && (y = "" + _), f.key !== void 0 && (y = "" + f.key), f.ref !== void 0 && (m = f.ref);
|
|
20
|
+
for (v in f) S.call(f, v) && !j.hasOwnProperty(v) && (E[v] = f[v]);
|
|
21
|
+
if (R && R.defaultProps) for (v in f = R.defaultProps, f) E[v] === void 0 && (E[v] = f[v]);
|
|
22
|
+
return { $$typeof: d, type: R, key: y, ref: m, props: E, _owner: b.current };
|
|
23
|
+
}
|
|
24
|
+
return L.Fragment = P, L.jsx = O, L.jsxs = O, L;
|
|
25
|
+
}
|
|
26
|
+
var W = {};
|
|
27
|
+
/**
|
|
28
|
+
* @license React
|
|
29
|
+
* react-jsx-runtime.development.js
|
|
30
|
+
*
|
|
31
|
+
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
32
|
+
*
|
|
33
|
+
* This source code is licensed under the MIT license found in the
|
|
34
|
+
* LICENSE file in the root directory of this source tree.
|
|
35
|
+
*/
|
|
36
|
+
var Oe;
|
|
37
|
+
function hr() {
|
|
38
|
+
return Oe || (Oe = 1, process.env.NODE_ENV !== "production" && function() {
|
|
39
|
+
var l = we, d = Symbol.for("react.element"), P = Symbol.for("react.portal"), S = Symbol.for("react.fragment"), b = Symbol.for("react.strict_mode"), j = Symbol.for("react.profiler"), O = Symbol.for("react.provider"), R = Symbol.for("react.context"), f = Symbol.for("react.forward_ref"), _ = Symbol.for("react.suspense"), v = Symbol.for("react.suspense_list"), E = Symbol.for("react.memo"), y = Symbol.for("react.lazy"), m = Symbol.for("react.offscreen"), A = Symbol.iterator, je = "@@iterator";
|
|
16
40
|
function ke(e) {
|
|
17
41
|
if (e === null || typeof e != "object")
|
|
18
42
|
return null;
|
|
@@ -40,7 +64,7 @@ function pr() {
|
|
|
40
64
|
var De = !1, Ae = !1, Ie = !1, $e = !1, Le = !1, ee;
|
|
41
65
|
ee = Symbol.for("react.module.reference");
|
|
42
66
|
function We(e) {
|
|
43
|
-
return !!(typeof e == "string" || typeof e == "function" || e === S || e === j || Le || e === b || e ===
|
|
67
|
+
return !!(typeof e == "string" || typeof e == "function" || e === S || e === j || Le || e === b || e === _ || e === v || $e || e === m || De || Ae || Ie || typeof e == "object" && e !== null && (e.$$typeof === y || e.$$typeof === E || e.$$typeof === O || e.$$typeof === R || e.$$typeof === f || // This needs to include all possible module reference object
|
|
44
68
|
// types supported by any Flight configuration anywhere since
|
|
45
69
|
// we don't know which Flight build this will end up being used
|
|
46
70
|
// with.
|
|
@@ -72,7 +96,7 @@ function pr() {
|
|
|
72
96
|
return "Profiler";
|
|
73
97
|
case b:
|
|
74
98
|
return "StrictMode";
|
|
75
|
-
case
|
|
99
|
+
case _:
|
|
76
100
|
return "Suspense";
|
|
77
101
|
case v:
|
|
78
102
|
return "SuspenseList";
|
|
@@ -90,7 +114,7 @@ function pr() {
|
|
|
90
114
|
case E:
|
|
91
115
|
var n = e.displayName || null;
|
|
92
116
|
return n !== null ? n : C(e.type) || "Memo";
|
|
93
|
-
case
|
|
117
|
+
case y: {
|
|
94
118
|
var i = e, u = i._payload, o = i._init;
|
|
95
119
|
try {
|
|
96
120
|
return C(o(u));
|
|
@@ -268,7 +292,7 @@ function pr() {
|
|
|
268
292
|
if (typeof e == "string")
|
|
269
293
|
return Y(e);
|
|
270
294
|
switch (e) {
|
|
271
|
-
case
|
|
295
|
+
case _:
|
|
272
296
|
return Y("Suspense");
|
|
273
297
|
case v:
|
|
274
298
|
return Y("SuspenseList");
|
|
@@ -279,7 +303,7 @@ function pr() {
|
|
|
279
303
|
return Ve(e.render);
|
|
280
304
|
case E:
|
|
281
305
|
return U(e.type, r, t);
|
|
282
|
-
case
|
|
306
|
+
case y: {
|
|
283
307
|
var n = e, i = n._payload, u = n._init;
|
|
284
308
|
try {
|
|
285
309
|
return U(u(i), r, t);
|
|
@@ -464,15 +488,7 @@ Check the render method of \`` + e + "`.";
|
|
|
464
488
|
}
|
|
465
489
|
}
|
|
466
490
|
function nr(e) {
|
|
467
|
-
|
|
468
|
-
if (e !== void 0) {
|
|
469
|
-
var r = e.fileName.replace(/^.*[\\\/]/, ""), t = e.lineNumber;
|
|
470
|
-
return `
|
|
471
|
-
|
|
472
|
-
Check your code at ` + r + ":" + t + ".";
|
|
473
|
-
}
|
|
474
|
-
return "";
|
|
475
|
-
}
|
|
491
|
+
return "";
|
|
476
492
|
}
|
|
477
493
|
var be = {};
|
|
478
494
|
function ar(e) {
|
|
@@ -500,7 +516,7 @@ Check the top-level render call using <` + t + ">.");
|
|
|
500
516
|
e && e._owner && e._owner !== z.current && (n = " It was passed a child from " + C(e._owner.type) + "."), F(e), p('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.', t, n), F(null);
|
|
501
517
|
}
|
|
502
518
|
}
|
|
503
|
-
function
|
|
519
|
+
function _e(e, r) {
|
|
504
520
|
{
|
|
505
521
|
if (typeof e != "object")
|
|
506
522
|
return;
|
|
@@ -556,13 +572,13 @@ Check the top-level render call using <` + t + ">.");
|
|
|
556
572
|
e.ref !== null && (F(e), p("Invalid attribute `ref` supplied to `React.Fragment`."), F(null));
|
|
557
573
|
}
|
|
558
574
|
}
|
|
559
|
-
function
|
|
575
|
+
function ye(e, r, t, n, i, u) {
|
|
560
576
|
{
|
|
561
577
|
var o = We(e);
|
|
562
578
|
if (!o) {
|
|
563
579
|
var a = "";
|
|
564
580
|
(e === void 0 || typeof e == "object" && e !== null && Object.keys(e).length === 0) && (a += " You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");
|
|
565
|
-
var h = nr(
|
|
581
|
+
var h = nr();
|
|
566
582
|
h ? a += h : a += ge();
|
|
567
583
|
var s;
|
|
568
584
|
e === null ? s = "null" : J(e) ? s = "array" : e !== void 0 && e.$$typeof === d ? (s = "<" + (C(e.type) || "Unknown") + " />", a = " Did you accidentally export a JSX literal instead of a component?") : s = typeof e, p("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s", s, a);
|
|
@@ -576,55 +592,27 @@ Check the top-level render call using <` + t + ">.");
|
|
|
576
592
|
if (n)
|
|
577
593
|
if (J(g)) {
|
|
578
594
|
for (var D = 0; D < g.length; D++)
|
|
579
|
-
|
|
595
|
+
_e(g[D], e);
|
|
580
596
|
Object.freeze && Object.freeze(g);
|
|
581
597
|
} else
|
|
582
598
|
p("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");
|
|
583
599
|
else
|
|
584
|
-
|
|
600
|
+
_e(g, e);
|
|
585
601
|
}
|
|
586
602
|
return e === S ? ir(c) : or(c), c;
|
|
587
603
|
}
|
|
588
604
|
}
|
|
589
605
|
function ur(e, r, t) {
|
|
590
|
-
return
|
|
606
|
+
return ye(e, r, t, !0);
|
|
591
607
|
}
|
|
592
608
|
function sr(e, r, t) {
|
|
593
|
-
return
|
|
609
|
+
return ye(e, r, t, !1);
|
|
594
610
|
}
|
|
595
611
|
var cr = sr, lr = ur;
|
|
596
|
-
|
|
597
|
-
}()),
|
|
598
|
-
}
|
|
599
|
-
var W = {};
|
|
600
|
-
/**
|
|
601
|
-
* @license React
|
|
602
|
-
* react-jsx-runtime.production.min.js
|
|
603
|
-
*
|
|
604
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
605
|
-
*
|
|
606
|
-
* This source code is licensed under the MIT license found in the
|
|
607
|
-
* LICENSE file in the root directory of this source tree.
|
|
608
|
-
*/
|
|
609
|
-
var Oe;
|
|
610
|
-
function hr() {
|
|
611
|
-
if (Oe)
|
|
612
|
-
return W;
|
|
613
|
-
Oe = 1;
|
|
614
|
-
var l = we, d = Symbol.for("react.element"), P = Symbol.for("react.fragment"), S = Object.prototype.hasOwnProperty, b = l.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner, j = { key: !0, ref: !0, __self: !0, __source: !0 };
|
|
615
|
-
function O(R, f, y) {
|
|
616
|
-
var v, E = {}, _ = null, m = null;
|
|
617
|
-
y !== void 0 && (_ = "" + y), f.key !== void 0 && (_ = "" + f.key), f.ref !== void 0 && (m = f.ref);
|
|
618
|
-
for (v in f)
|
|
619
|
-
S.call(f, v) && !j.hasOwnProperty(v) && (E[v] = f[v]);
|
|
620
|
-
if (R && R.defaultProps)
|
|
621
|
-
for (v in f = R.defaultProps, f)
|
|
622
|
-
E[v] === void 0 && (E[v] = f[v]);
|
|
623
|
-
return { $$typeof: d, type: R, key: _, ref: m, props: E, _owner: b.current };
|
|
624
|
-
}
|
|
625
|
-
return W.Fragment = P, W.jsx = O, W.jsxs = O, W;
|
|
612
|
+
W.Fragment = S, W.jsx = cr, W.jsxs = lr;
|
|
613
|
+
}()), W;
|
|
626
614
|
}
|
|
627
|
-
process.env.NODE_ENV === "production" ? Q.exports =
|
|
615
|
+
process.env.NODE_ENV === "production" ? Q.exports = pr() : Q.exports = hr();
|
|
628
616
|
var x = Q.exports;
|
|
629
617
|
const xe = ({ children: l }) => /* @__PURE__ */ x.jsxs("div", { children: [
|
|
630
618
|
"Error loading Helio Checkout for React",
|
|
@@ -648,11 +636,9 @@ const mr = "https://embed.hel.io/assets/index-v1.js", Pe = "helio-checkout-react
|
|
|
648
636
|
const d = dr(null), [P, S] = Z(!1), [b, j] = Z(), [O, R] = Z("");
|
|
649
637
|
return Te(() => S(!0), []), Te(() => {
|
|
650
638
|
let f = !1;
|
|
651
|
-
if (b)
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
if (f)
|
|
655
|
-
return;
|
|
639
|
+
if (b) return;
|
|
640
|
+
const _ = () => {
|
|
641
|
+
if (f) return;
|
|
656
642
|
const m = window.helioCheckout;
|
|
657
643
|
if (!m) {
|
|
658
644
|
R(
|
|
@@ -663,18 +649,18 @@ const mr = "https://embed.hel.io/assets/index-v1.js", Pe = "helio-checkout-react
|
|
|
663
649
|
j(() => m);
|
|
664
650
|
}, v = (m) => {
|
|
665
651
|
const A = () => R("Error loading script tag");
|
|
666
|
-
return m.addEventListener("load",
|
|
667
|
-
f = !0, m.removeEventListener("load",
|
|
652
|
+
return m.addEventListener("load", _), m.addEventListener("error", A), () => {
|
|
653
|
+
f = !0, m.removeEventListener("load", _), m.removeEventListener("error", A);
|
|
668
654
|
};
|
|
669
655
|
}, E = document.querySelector(
|
|
670
656
|
`script#${Pe}`
|
|
671
657
|
);
|
|
672
658
|
if (E) {
|
|
673
|
-
window.helioCheckout ?
|
|
659
|
+
window.helioCheckout ? _() : v(E);
|
|
674
660
|
return;
|
|
675
661
|
}
|
|
676
|
-
const
|
|
677
|
-
return v(
|
|
662
|
+
const y = gr(l.embedScriptSource);
|
|
663
|
+
return v(y);
|
|
678
664
|
}, [b, l.embedScriptSource]), vr(() => {
|
|
679
665
|
if (!(!b || !P)) {
|
|
680
666
|
if (!d.current) {
|
|
@@ -684,7 +670,7 @@ const mr = "https://embed.hel.io/assets/index-v1.js", Pe = "helio-checkout-react
|
|
|
684
670
|
b(d.current, l);
|
|
685
671
|
}
|
|
686
672
|
}, [b, P, l]), O ? /* @__PURE__ */ x.jsx(xe, { children: O }) : b ? /* @__PURE__ */ x.jsx("div", { ref: d }) : null;
|
|
687
|
-
}, Rr = (l) => /* @__PURE__ */ x.jsx(Er, { children: /* @__PURE__ */ x.jsx(br, { config: l.config }) }),
|
|
673
|
+
}, Rr = (l) => /* @__PURE__ */ x.jsx(Er, { children: /* @__PURE__ */ x.jsx(br, { config: l.config }) }), yr = (l) => /* @__PURE__ */ x.jsx(Rr, { config: l.config });
|
|
688
674
|
export {
|
|
689
|
-
|
|
675
|
+
yr as HelioCheckout
|
|
690
676
|
};
|
|
@@ -1,27 +1,25 @@
|
|
|
1
1
|
(function(x,E){typeof exports=="object"&&typeof module<"u"?E(exports,require("react")):typeof define=="function"&&define.amd?define(["exports","react"],E):(x=typeof globalThis<"u"?globalThis:x||self,E(x["react-library-scaffold"]={},x.React))})(this,function(x,E){"use strict";var J={exports:{}},L={};/**
|
|
2
2
|
* @license React
|
|
3
|
-
* react-jsx-runtime.
|
|
3
|
+
* react-jsx-runtime.production.min.js
|
|
4
4
|
*
|
|
5
5
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var re;function Pe(){return re
|
|
10
|
-
`+z+e}}var K=!1,V;{var Ke=typeof WeakMap=="function"?WeakMap:Map;V=new Ke}function he(e,r){if(!e||K)return"";{var t=V.get(e);if(t!==void 0)return t}var n;K=!0;var i=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var u;u=G.current,G.current=null,Ge();try{if(r){var o=function(){throw Error()};if(Object.defineProperty(o.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(o,[])}catch(C){n=C}Reflect.construct(e,[],o)}else{try{o.call()}catch(C){n=C}e.call(o.prototype)}}else{try{throw Error()}catch(C){n=C}e()}}catch(C){if(C&&n&&typeof C.stack=="string"){for(var a=C.stack.split(`
|
|
11
|
-
`),h=n.stack.split(`
|
|
12
|
-
`),s=a.length-1,c=h.length-1;s>=1&&c>=0&&a[s]!==h[c];)c--;for(;s>=1&&c>=0;s--,c--)if(a[s]!==h[c]){if(s!==1||c!==1)do if(s--,c--,c<0||a[s]!==h[c]){var g=`
|
|
13
|
-
`+a[s].replace(" at new "," at ");return e.displayName&&g.includes("<anonymous>")&&(g=g.replace("<anonymous>",e.displayName)),typeof e=="function"&&V.set(e,g),g}while(s>=1&&c>=0);break}}}finally{K=!1,G.current=u,ze(),Error.prepareStackTrace=i}var I=e?e.displayName||e.name:"",xe=I?N(I):"";return typeof e=="function"&&V.set(e,xe),xe}function Xe(e,r,t){return he(e,!1)}function Ze(e){var r=e.prototype;return!!(r&&r.isReactComponent)}function B(e,r,t){if(e==null)return"";if(typeof e=="function")return he(e,Ze(e));if(typeof e=="string")return N(e);switch(e){case _:return N("Suspense");case v:return N("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case l:return Xe(e.render);case m:return B(e.type,r,t);case S:{var n=e,i=n._payload,u=n._init;try{return B(u(i),r,t)}catch{}}}return""}var H=Object.prototype.hasOwnProperty,Ee={},me=D.ReactDebugCurrentFrame;function $(e){if(e){var r=e._owner,t=B(e.type,e._source,r?r.type:null);me.setExtraStackFrame(t)}else me.setExtraStackFrame(null)}function qe(e,r,t,n,i){{var u=Function.call.bind(H);for(var o in e)if(u(e,o)){var a=void 0;try{if(typeof e[o]!="function"){var h=Error((n||"React class")+": "+t+" type `"+o+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[o]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw h.name="Invariant Violation",h}a=e[o](r,o,n,t,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(s){a=s}a&&!(a instanceof Error)&&($(i),p("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",n||"React class",t,o,typeof a),$(null)),a instanceof Error&&!(a.message in Ee)&&(Ee[a.message]=!0,$(i),p("Failed %s type: %s",t,a.message),$(null))}}}var Qe=Array.isArray;function X(e){return Qe(e)}function er(e){{var r=typeof Symbol=="function"&&Symbol.toStringTag,t=r&&e[Symbol.toStringTag]||e.constructor.name||"Object";return t}}function rr(e){try{return be(e),!1}catch{return!0}}function be(e){return""+e}function ge(e){if(rr(e))return p("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",er(e)),be(e)}var U=D.ReactCurrentOwner,tr={key:!0,ref:!0,__self:!0,__source:!0},ye,Re,Z;Z={};function nr(e){if(H.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return e.ref!==void 0}function ar(e){if(H.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return e.key!==void 0}function or(e,r){if(typeof e.ref=="string"&&U.current&&r&&U.current.stateNode!==r){var t=T(U.current.type);Z[t]||(p('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',T(U.current.type),e.ref),Z[t]=!0)}}function ir(e,r){{var t=function(){ye||(ye=!0,p("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",r))};t.isReactWarning=!0,Object.defineProperty(e,"key",{get:t,configurable:!0})}}function ur(e,r){{var t=function(){Re||(Re=!0,p("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",r))};t.isReactWarning=!0,Object.defineProperty(e,"ref",{get:t,configurable:!0})}}var sr=function(e,r,t,n,i,u,o){var a={$$typeof:d,type:e,key:r,ref:t,props:o,_owner:u};return a._store={},Object.defineProperty(a._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(a,"_self",{configurable:!1,enumerable:!1,writable:!1,value:n}),Object.defineProperty(a,"_source",{configurable:!1,enumerable:!1,writable:!1,value:i}),Object.freeze&&(Object.freeze(a.props),Object.freeze(a)),a};function cr(e,r,t,n,i){{var u,o={},a=null,h=null;t!==void 0&&(ge(t),a=""+t),ar(r)&&(ge(r.key),a=""+r.key),nr(r)&&(h=r.ref,or(r,i));for(u in r)H.call(r,u)&&!tr.hasOwnProperty(u)&&(o[u]=r[u]);if(e&&e.defaultProps){var s=e.defaultProps;for(u in s)o[u]===void 0&&(o[u]=s[u])}if(a||h){var c=typeof e=="function"?e.displayName||e.name||"Unknown":e;a&&ir(o,c),h&&ur(o,c)}return sr(e,a,h,i,n,U.current,o)}}var q=D.ReactCurrentOwner,_e=D.ReactDebugCurrentFrame;function A(e){if(e){var r=e._owner,t=B(e.type,e._source,r?r.type:null);_e.setExtraStackFrame(t)}else _e.setExtraStackFrame(null)}var Q;Q=!1;function ee(e){return typeof e=="object"&&e!==null&&e.$$typeof===d}function Se(){{if(q.current){var e=T(q.current.type);if(e)return`
|
|
14
|
-
|
|
15
|
-
Check the render method of \``+e+"`."}return""}}function fr(e){{if(e!==void 0){var r=e.fileName.replace(/^.*[\\\/]/,""),t=e.lineNumber;return`
|
|
16
|
-
|
|
17
|
-
Check your code at `+r+":"+t+"."}return""}}var Te={};function lr(e){{var r=Se();if(!r){var t=typeof e=="string"?e:e.displayName||e.name;t&&(r=`
|
|
18
|
-
|
|
19
|
-
Check the top-level render call using <`+t+">.")}return r}}function Ce(e,r){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var t=lr(r);if(Te[t])return;Te[t]=!0;var n="";e&&e._owner&&e._owner!==q.current&&(n=" It was passed a child from "+T(e._owner.type)+"."),A(e),p('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',t,n),A(null)}}function Oe(e,r){{if(typeof e!="object")return;if(X(e))for(var t=0;t<e.length;t++){var n=e[t];ee(n)&&Ce(n,r)}else if(ee(e))e._store&&(e._store.validated=!0);else if(e){var i=Ye(e);if(typeof i=="function"&&i!==e.entries)for(var u=i.call(e),o;!(o=u.next()).done;)ee(o.value)&&Ce(o.value,r)}}}function dr(e){{var r=e.type;if(r==null||typeof r=="string")return;var t;if(typeof r=="function")t=r.propTypes;else if(typeof r=="object"&&(r.$$typeof===l||r.$$typeof===m))t=r.propTypes;else return;if(t){var n=T(r);qe(t,e.props,"prop",n,e)}else if(r.PropTypes!==void 0&&!Q){Q=!0;var i=T(r);p("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",i||"Unknown")}typeof r.getDefaultProps=="function"&&!r.getDefaultProps.isReactClassApproved&&p("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function vr(e){{for(var r=Object.keys(e.props),t=0;t<r.length;t++){var n=r[t];if(n!=="children"&&n!=="key"){A(e),p("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),A(null);break}}e.ref!==null&&(A(e),p("Invalid attribute `ref` supplied to `React.Fragment`."),A(null))}}function we(e,r,t,n,i,u){{var o=$e(e);if(!o){var a="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(a+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var h=fr(i);h?a+=h:a+=Se();var s;e===null?s="null":X(e)?s="array":e!==void 0&&e.$$typeof===d?(s="<"+(T(e.type)||"Unknown")+" />",a=" Did you accidentally export a JSX literal instead of a component?"):s=typeof e,p("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",s,a)}var c=cr(e,r,t,i,u);if(c==null)return c;if(o){var g=r.children;if(g!==void 0)if(n)if(X(g)){for(var I=0;I<g.length;I++)Oe(g[I],e);Object.freeze&&Object.freeze(g)}else p("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Oe(g,e)}return e===O?vr(c):dr(c),c}}function pr(e,r,t){return we(e,r,t,!0)}function hr(e,r,t){return we(e,r,t,!1)}var Er=hr,mr=pr;L.Fragment=O,L.jsx=Er,L.jsxs=mr}()),L}var W={};/**
|
|
9
|
+
*/var re;function Pe(){if(re)return L;re=1;var f=E,d=Symbol.for("react.element"),k=Symbol.for("react.fragment"),O=Object.prototype.hasOwnProperty,y=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,F={key:!0,ref:!0,__self:!0,__source:!0};function w(R,l,_){var v,m={},S=null,g=null;_!==void 0&&(S=""+_),l.key!==void 0&&(S=""+l.key),l.ref!==void 0&&(g=l.ref);for(v in l)O.call(l,v)&&!F.hasOwnProperty(v)&&(m[v]=l[v]);if(R&&R.defaultProps)for(v in l=R.defaultProps,l)m[v]===void 0&&(m[v]=l[v]);return{$$typeof:d,type:R,key:S,ref:g,props:m,_owner:y.current}}return L.Fragment=k,L.jsx=w,L.jsxs=w,L}var W={};/**
|
|
20
10
|
* @license React
|
|
21
|
-
* react-jsx-runtime.
|
|
11
|
+
* react-jsx-runtime.development.js
|
|
22
12
|
*
|
|
23
13
|
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
24
14
|
*
|
|
25
15
|
* This source code is licensed under the MIT license found in the
|
|
26
16
|
* LICENSE file in the root directory of this source tree.
|
|
27
|
-
*/var te;function je(){
|
|
17
|
+
*/var te;function je(){return te||(te=1,process.env.NODE_ENV!=="production"&&function(){var f=E,d=Symbol.for("react.element"),k=Symbol.for("react.portal"),O=Symbol.for("react.fragment"),y=Symbol.for("react.strict_mode"),F=Symbol.for("react.profiler"),w=Symbol.for("react.provider"),R=Symbol.for("react.context"),l=Symbol.for("react.forward_ref"),_=Symbol.for("react.suspense"),v=Symbol.for("react.suspense_list"),m=Symbol.for("react.memo"),S=Symbol.for("react.lazy"),g=Symbol.for("react.offscreen"),Y=Symbol.iterator,We="@@iterator";function Ye(e){if(e===null||typeof e!="object")return null;var r=Y&&e[Y]||e[We];return typeof r=="function"?r:null}var D=f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;function p(e){{for(var r=arguments.length,t=new Array(r>1?r-1:0),n=1;n<r;n++)t[n-1]=arguments[n];Me("error",e,t)}}function Me(e,r,t){{var n=D.ReactDebugCurrentFrame,i=n.getStackAddendum();i!==""&&(r+="%s",t=t.concat([i]));var u=t.map(function(o){return String(o)});u.unshift("Warning: "+r),Function.prototype.apply.call(console[e],console,u)}}var Ue=!1,Ne=!1,Ve=!1,Be=!1,He=!1,oe;oe=Symbol.for("react.module.reference");function $e(e){return!!(typeof e=="string"||typeof e=="function"||e===O||e===F||He||e===y||e===_||e===v||Be||e===g||Ue||Ne||Ve||typeof e=="object"&&e!==null&&(e.$$typeof===S||e.$$typeof===m||e.$$typeof===w||e.$$typeof===R||e.$$typeof===l||e.$$typeof===oe||e.getModuleId!==void 0))}function Je(e,r,t){var n=e.displayName;if(n)return n;var i=r.displayName||r.name||"";return i!==""?t+"("+i+")":t}function ie(e){return e.displayName||"Context"}function T(e){if(e==null)return null;if(typeof e.tag=="number"&&p("Received an unexpected object in getComponentNameFromType(). This is likely a bug in React. Please file an issue."),typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case O:return"Fragment";case k:return"Portal";case F:return"Profiler";case y:return"StrictMode";case _:return"Suspense";case v:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case R:var r=e;return ie(r)+".Consumer";case w:var t=e;return ie(t._context)+".Provider";case l:return Je(e,e.render,"ForwardRef");case m:var n=e.displayName||null;return n!==null?n:T(e.type)||"Memo";case S:{var i=e,u=i._payload,o=i._init;try{return T(o(u))}catch{return null}}}return null}var j=Object.assign,M=0,ue,se,ce,fe,le,de,ve;function pe(){}pe.__reactDisabledLog=!0;function Ge(){{if(M===0){ue=console.log,se=console.info,ce=console.warn,fe=console.error,le=console.group,de=console.groupCollapsed,ve=console.groupEnd;var e={configurable:!0,enumerable:!0,value:pe,writable:!0};Object.defineProperties(console,{info:e,log:e,warn:e,error:e,group:e,groupCollapsed:e,groupEnd:e})}M++}}function ze(){{if(M--,M===0){var e={configurable:!0,enumerable:!0,writable:!0};Object.defineProperties(console,{log:j({},e,{value:ue}),info:j({},e,{value:se}),warn:j({},e,{value:ce}),error:j({},e,{value:fe}),group:j({},e,{value:le}),groupCollapsed:j({},e,{value:de}),groupEnd:j({},e,{value:ve})})}M<0&&p("disabledDepth fell below zero. This is a bug in React. Please file an issue.")}}var G=D.ReactCurrentDispatcher,z;function N(e,r,t){{if(z===void 0)try{throw Error()}catch(i){var n=i.stack.trim().match(/\n( *(at )?)/);z=n&&n[1]||""}return`
|
|
18
|
+
`+z+e}}var K=!1,V;{var Ke=typeof WeakMap=="function"?WeakMap:Map;V=new Ke}function he(e,r){if(!e||K)return"";{var t=V.get(e);if(t!==void 0)return t}var n;K=!0;var i=Error.prepareStackTrace;Error.prepareStackTrace=void 0;var u;u=G.current,G.current=null,Ge();try{if(r){var o=function(){throw Error()};if(Object.defineProperty(o.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(o,[])}catch(C){n=C}Reflect.construct(e,[],o)}else{try{o.call()}catch(C){n=C}e.call(o.prototype)}}else{try{throw Error()}catch(C){n=C}e()}}catch(C){if(C&&n&&typeof C.stack=="string"){for(var a=C.stack.split(`
|
|
19
|
+
`),h=n.stack.split(`
|
|
20
|
+
`),s=a.length-1,c=h.length-1;s>=1&&c>=0&&a[s]!==h[c];)c--;for(;s>=1&&c>=0;s--,c--)if(a[s]!==h[c]){if(s!==1||c!==1)do if(s--,c--,c<0||a[s]!==h[c]){var b=`
|
|
21
|
+
`+a[s].replace(" at new "," at ");return e.displayName&&b.includes("<anonymous>")&&(b=b.replace("<anonymous>",e.displayName)),typeof e=="function"&&V.set(e,b),b}while(s>=1&&c>=0);break}}}finally{K=!1,G.current=u,ze(),Error.prepareStackTrace=i}var I=e?e.displayName||e.name:"",xe=I?N(I):"";return typeof e=="function"&&V.set(e,xe),xe}function Xe(e,r,t){return he(e,!1)}function Ze(e){var r=e.prototype;return!!(r&&r.isReactComponent)}function B(e,r,t){if(e==null)return"";if(typeof e=="function")return he(e,Ze(e));if(typeof e=="string")return N(e);switch(e){case _:return N("Suspense");case v:return N("SuspenseList")}if(typeof e=="object")switch(e.$$typeof){case l:return Xe(e.render);case m:return B(e.type,r,t);case S:{var n=e,i=n._payload,u=n._init;try{return B(u(i),r,t)}catch{}}}return""}var H=Object.prototype.hasOwnProperty,Ee={},me=D.ReactDebugCurrentFrame;function $(e){if(e){var r=e._owner,t=B(e.type,e._source,r?r.type:null);me.setExtraStackFrame(t)}else me.setExtraStackFrame(null)}function qe(e,r,t,n,i){{var u=Function.call.bind(H);for(var o in e)if(u(e,o)){var a=void 0;try{if(typeof e[o]!="function"){var h=Error((n||"React class")+": "+t+" type `"+o+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[o]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw h.name="Invariant Violation",h}a=e[o](r,o,n,t,null,"SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED")}catch(s){a=s}a&&!(a instanceof Error)&&($(i),p("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).",n||"React class",t,o,typeof a),$(null)),a instanceof Error&&!(a.message in Ee)&&(Ee[a.message]=!0,$(i),p("Failed %s type: %s",t,a.message),$(null))}}}var Qe=Array.isArray;function X(e){return Qe(e)}function er(e){{var r=typeof Symbol=="function"&&Symbol.toStringTag,t=r&&e[Symbol.toStringTag]||e.constructor.name||"Object";return t}}function rr(e){try{return ge(e),!1}catch{return!0}}function ge(e){return""+e}function be(e){if(rr(e))return p("The provided key is an unsupported type %s. This value must be coerced to a string before before using it here.",er(e)),ge(e)}var U=D.ReactCurrentOwner,tr={key:!0,ref:!0,__self:!0,__source:!0},ye,Re,Z;Z={};function nr(e){if(H.call(e,"ref")){var r=Object.getOwnPropertyDescriptor(e,"ref").get;if(r&&r.isReactWarning)return!1}return e.ref!==void 0}function ar(e){if(H.call(e,"key")){var r=Object.getOwnPropertyDescriptor(e,"key").get;if(r&&r.isReactWarning)return!1}return e.key!==void 0}function or(e,r){if(typeof e.ref=="string"&&U.current&&r&&U.current.stateNode!==r){var t=T(U.current.type);Z[t]||(p('Component "%s" contains the string ref "%s". Support for string refs will be removed in a future major release. This case cannot be automatically converted to an arrow function. We ask you to manually fix this case by using useRef() or createRef() instead. Learn more about using refs safely here: https://reactjs.org/link/strict-mode-string-ref',T(U.current.type),e.ref),Z[t]=!0)}}function ir(e,r){{var t=function(){ye||(ye=!0,p("%s: `key` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",r))};t.isReactWarning=!0,Object.defineProperty(e,"key",{get:t,configurable:!0})}}function ur(e,r){{var t=function(){Re||(Re=!0,p("%s: `ref` is not a prop. Trying to access it will result in `undefined` being returned. If you need to access the same value within the child component, you should pass it as a different prop. (https://reactjs.org/link/special-props)",r))};t.isReactWarning=!0,Object.defineProperty(e,"ref",{get:t,configurable:!0})}}var sr=function(e,r,t,n,i,u,o){var a={$$typeof:d,type:e,key:r,ref:t,props:o,_owner:u};return a._store={},Object.defineProperty(a._store,"validated",{configurable:!1,enumerable:!1,writable:!0,value:!1}),Object.defineProperty(a,"_self",{configurable:!1,enumerable:!1,writable:!1,value:n}),Object.defineProperty(a,"_source",{configurable:!1,enumerable:!1,writable:!1,value:i}),Object.freeze&&(Object.freeze(a.props),Object.freeze(a)),a};function cr(e,r,t,n,i){{var u,o={},a=null,h=null;t!==void 0&&(be(t),a=""+t),ar(r)&&(be(r.key),a=""+r.key),nr(r)&&(h=r.ref,or(r,i));for(u in r)H.call(r,u)&&!tr.hasOwnProperty(u)&&(o[u]=r[u]);if(e&&e.defaultProps){var s=e.defaultProps;for(u in s)o[u]===void 0&&(o[u]=s[u])}if(a||h){var c=typeof e=="function"?e.displayName||e.name||"Unknown":e;a&&ir(o,c),h&&ur(o,c)}return sr(e,a,h,i,n,U.current,o)}}var q=D.ReactCurrentOwner,_e=D.ReactDebugCurrentFrame;function A(e){if(e){var r=e._owner,t=B(e.type,e._source,r?r.type:null);_e.setExtraStackFrame(t)}else _e.setExtraStackFrame(null)}var Q;Q=!1;function ee(e){return typeof e=="object"&&e!==null&&e.$$typeof===d}function Se(){{if(q.current){var e=T(q.current.type);if(e)return`
|
|
22
|
+
|
|
23
|
+
Check the render method of \``+e+"`."}return""}}function fr(e){return""}var Te={};function lr(e){{var r=Se();if(!r){var t=typeof e=="string"?e:e.displayName||e.name;t&&(r=`
|
|
24
|
+
|
|
25
|
+
Check the top-level render call using <`+t+">.")}return r}}function Ce(e,r){{if(!e._store||e._store.validated||e.key!=null)return;e._store.validated=!0;var t=lr(r);if(Te[t])return;Te[t]=!0;var n="";e&&e._owner&&e._owner!==q.current&&(n=" It was passed a child from "+T(e._owner.type)+"."),A(e),p('Each child in a list should have a unique "key" prop.%s%s See https://reactjs.org/link/warning-keys for more information.',t,n),A(null)}}function Oe(e,r){{if(typeof e!="object")return;if(X(e))for(var t=0;t<e.length;t++){var n=e[t];ee(n)&&Ce(n,r)}else if(ee(e))e._store&&(e._store.validated=!0);else if(e){var i=Ye(e);if(typeof i=="function"&&i!==e.entries)for(var u=i.call(e),o;!(o=u.next()).done;)ee(o.value)&&Ce(o.value,r)}}}function dr(e){{var r=e.type;if(r==null||typeof r=="string")return;var t;if(typeof r=="function")t=r.propTypes;else if(typeof r=="object"&&(r.$$typeof===l||r.$$typeof===m))t=r.propTypes;else return;if(t){var n=T(r);qe(t,e.props,"prop",n,e)}else if(r.PropTypes!==void 0&&!Q){Q=!0;var i=T(r);p("Component %s declared `PropTypes` instead of `propTypes`. Did you misspell the property assignment?",i||"Unknown")}typeof r.getDefaultProps=="function"&&!r.getDefaultProps.isReactClassApproved&&p("getDefaultProps is only used on classic React.createClass definitions. Use a static property named `defaultProps` instead.")}}function vr(e){{for(var r=Object.keys(e.props),t=0;t<r.length;t++){var n=r[t];if(n!=="children"&&n!=="key"){A(e),p("Invalid prop `%s` supplied to `React.Fragment`. React.Fragment can only have `key` and `children` props.",n),A(null);break}}e.ref!==null&&(A(e),p("Invalid attribute `ref` supplied to `React.Fragment`."),A(null))}}function we(e,r,t,n,i,u){{var o=$e(e);if(!o){var a="";(e===void 0||typeof e=="object"&&e!==null&&Object.keys(e).length===0)&&(a+=" You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.");var h=fr();h?a+=h:a+=Se();var s;e===null?s="null":X(e)?s="array":e!==void 0&&e.$$typeof===d?(s="<"+(T(e.type)||"Unknown")+" />",a=" Did you accidentally export a JSX literal instead of a component?"):s=typeof e,p("React.jsx: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: %s.%s",s,a)}var c=cr(e,r,t,i,u);if(c==null)return c;if(o){var b=r.children;if(b!==void 0)if(n)if(X(b)){for(var I=0;I<b.length;I++)Oe(b[I],e);Object.freeze&&Object.freeze(b)}else p("React.jsx: Static children should always be an array. You are likely explicitly calling React.jsxs or React.jsxDEV. Use the Babel transform instead.");else Oe(b,e)}return e===O?vr(c):dr(c),c}}function pr(e,r,t){return we(e,r,t,!0)}function hr(e,r,t){return we(e,r,t,!1)}var Er=hr,mr=pr;W.Fragment=O,W.jsx=Er,W.jsxs=mr}()),W}process.env.NODE_ENV==="production"?J.exports=Pe():J.exports=je();var P=J.exports;const ne=({children:f})=>P.jsxs("div",{children:["Error loading Helio Checkout for React",f?`: ${f}`:""]});class ke extends E.Component{constructor(d){super(d),this.state={hasError:!1}}static getDerivedStateFromError(){return{hasError:!0}}render(){return this.state.hasError?P.jsx(ne,{}):this.props.children}}const Fe="https://embed.hel.io/assets/index-v1.js",ae="helio-checkout-react-v1",De=(f=Fe)=>{const d=document.createElement("script");return d.setAttribute("type","module"),d.setAttribute("id",ae),d.setAttribute("src",f),document.body.appendChild(d),d},Ae=({config:f})=>{const d=E.useRef(null),[k,O]=E.useState(!1),[y,F]=E.useState(),[w,R]=E.useState("");return E.useEffect(()=>O(!0),[]),E.useEffect(()=>{let l=!1;if(y)return;const _=()=>{if(l)return;const g=window.helioCheckout;if(!g){R("Unable to load helio checkout - missing init function on window.helioCheckout");return}F(()=>g)},v=g=>{const Y=()=>R("Error loading script tag");return g.addEventListener("load",_),g.addEventListener("error",Y),()=>{l=!0,g.removeEventListener("load",_),g.removeEventListener("error",Y)}},m=document.querySelector(`script#${ae}`);if(m){window.helioCheckout?_():v(m);return}const S=De(f.embedScriptSource);return v(S)},[y,f.embedScriptSource]),E.useLayoutEffect(()=>{if(!(!y||!k)){if(!d.current){R("Missing element to mount Helio checkout");return}y(d.current,f)}},[y,k,f]),w?P.jsx(ne,{children:w}):y?P.jsx("div",{ref:d}):null},Ie=f=>P.jsx(ke,{children:P.jsx(Ae,{config:f.config})}),Le=f=>P.jsx(Ie,{config:f.config});x.HelioCheckout=Le,Object.defineProperty(x,Symbol.toStringTag,{value:"Module"})});
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@heliofi/checkout-react",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "2.
|
|
4
|
+
"version": "2.2.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"scripts": {
|
|
7
7
|
"dev": "vite",
|
|
@@ -44,13 +44,13 @@
|
|
|
44
44
|
"@types/react-dom": "18.2.0",
|
|
45
45
|
"@typescript-eslint/eslint-plugin": "^6.0.0",
|
|
46
46
|
"@typescript-eslint/parser": "^6.0.0",
|
|
47
|
-
"@vitejs/plugin-react": "^4.
|
|
47
|
+
"@vitejs/plugin-react": "^4.3.2",
|
|
48
48
|
"eslint": "8.45.0",
|
|
49
49
|
"eslint-plugin-react": "^7.33.2",
|
|
50
50
|
"eslint-plugin-react-hooks": "^4.6.0",
|
|
51
51
|
"jsdom": "^23.0.1",
|
|
52
52
|
"typescript": "5.1.6",
|
|
53
|
-
"vite": "5.
|
|
53
|
+
"vite": "5.4.8",
|
|
54
54
|
"vite-plugin-dts": "^3.7.1",
|
|
55
55
|
"vitest": "1.2.1"
|
|
56
56
|
}
|