@stigg/react-sdk 8.5.0 → 8.7.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.
- package/dist/{CreditUsageChart-25PEGAXR.esm.js → CreditUsageChart-BDFRW7BA.esm.js} +1 -1
- package/dist/{CreditUsageChart-MTZLZN5J.cjs.js → CreditUsageChart-T5PAX7TE.cjs.js} +19 -19
- package/dist/{chunk-45WJQS4T.esm.js → chunk-EOAWTHEF.esm.js} +16 -13
- package/dist/{chunk-YAS4WG6F.cjs.js → chunk-IVDIW747.cjs.js} +16 -13
- package/dist/index.d.mts +3 -3
- package/dist/index.d.ts +3 -3
- package/dist/stigg-sdk.cjs.js +173 -171
- package/dist/stigg-sdk.esm.js +5 -3
- package/package.json +4 -4
|
@@ -8,7 +8,7 @@ import d1 from'@emotion/styled';import Lt,{forwardRef,useRef,useState,useEffect,
|
|
|
8
8
|
@media (max-width: 1040px) {
|
|
9
9
|
${({$smallScreenAlign:t})=>t&&`align-self: ${t};`}
|
|
10
10
|
}
|
|
11
|
-
`;function l2({source:t,showWatermark:e,align:o,smallScreenAlign:n="center",style:s={}}){if(!e)return null;let a=()=>{let l=window.location.hostname.replace("www.","");window.open(`https://www.stigg.io/?utm_source=${l}&utm_medium=referral&utm_campaign=${t}`,"_blank");};return jsx(vt,{$alignSelf:o,$smallScreenAlign:n,className:yt,style:r({cursor:"pointer"},s),onClick:a,children:jsx(kt,{})})}var O=class{error(e,o,...n){console.error(e,o||{},n);}log(e,o){console.log(e,o||{});}debug(e,o){console.debug(e,o||{});}},m1=new O;var u1="8.
|
|
11
|
+
`;function l2({source:t,showWatermark:e,align:o,smallScreenAlign:n="center",style:s={}}){if(!e)return null;let a=()=>{let l=window.location.hostname.replace("www.","");window.open(`https://www.stigg.io/?utm_source=${l}&utm_medium=referral&utm_campaign=${t}`,"_blank");};return jsx(vt,{$alignSelf:o,$smallScreenAlign:n,className:yt,style:r({cursor:"pointer"},s),onClick:a,children:jsx(kt,{})})}var O=class{error(e,o,...n){console.error(e,o||{},n);}log(e,o){console.log(e,o||{});}debug(e,o){console.debug(e,o||{});}},m1=new O;var u1="8.7.0";var h1="@stigg/react-sdk";var _=Lt.createContext(null);_.displayName="StiggContext";var Tt="en-US",v2=({apiKey:t,baseUri:e,baseEdgeUri:o,enableEdge:n,customerId:s,customerToken:a,resourceId:l,theme:d,locale:g,cacheTtlMs:c,useEntitlementPolling:S,entitlementPollingInterval:E,entitlementsFallback:P,stiggClient:U,children:R,offline:W,clientName:Z=h1,clientVersion:ct=u1})=>{let o1=useRef(t),r1={apiKey:t,customerId:s,customerToken:a,resourceId:l,baseUri:e,baseEdgeUri:o,enableEdge:n,entitlementsFallback:P,cacheTtlMs:c,useEntitlementPolling:S,entitlementPollingInterval:E,clientName:Z,clientVersion:ct,offline:W},[M,G]=useState(()=>({stigg:U!=null?U:x1.initialize(i(r({},r1),{lazyLoad:true})),locale:g||Tt,isInitialized:false,theme:d,refreshData:()=>y(null,null,function*(){G(u=>i(r({},u),{customerPortalUpdatedAt:new Date})),yield M.stigg.refresh();})}));return useEffect(()=>{let u=true,N=f=>{u&&G(f);},$=()=>N(f=>i(r({},f),{updatedAt:new Date})),Ct=f=>N(b=>(b.stigg&&b.stigg.removeListener("entitlementsUpdated",$),f.addListener("entitlementsUpdated",$),i(r({},b),{stigg:f,isInitialized:true,updatedAt:new Date})));return y(null,null,function*(){let f=M.stigg;t!==o1.current&&(m1.log("Updating stigg client",{apiKey:t}),o1.current=t,f=x1.initialize(r({},r1)),N(b=>i(r({},b),{isInitialized:false,updatedAt:new Date}))),yield f.waitForInitialization(),Ct(f);}),()=>{u=false,M.stigg.removeListener("entitlementsUpdated",$),M.stigg.clearCustomer();}},[t]),useEffect(()=>{let u=M.stigg;s?u.setCustomerId(s,a,l):u.clearCustomer();},[s,a,l]),useEffect(()=>{G(u=>i(r({},u),{theme:d}));},[d]),jsx(_.Provider,{value:M,children:jsx(SkeletonTheme,{baseColor:"#F5F6F9",highlightColor:"#e5e6ea",children:R})})};function p(t){let{optional:e}=t||{},o=useContext(_);if(!o&&!e)throw new Error("Could not find Stigg context; You need to wrap your app in an <StiggProvider> component.");return o}var y1=({externalFontUrl:t})=>jsx(Global,{styles:css`
|
|
12
12
|
${t&&`
|
|
13
13
|
@font-face {
|
|
14
14
|
font-family: 'custom-font';
|
|
@@ -25,8 +25,8 @@ import d1 from'@emotion/styled';import Lt,{forwardRef,useRef,useState,useEffect,
|
|
|
25
25
|
font-weight: 400;
|
|
26
26
|
font-display: swap;
|
|
27
27
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Hp2ywxg089UriCZ2IHTWEBlwu8Q.woff2) format('woff2');
|
|
28
|
-
unicode-range:
|
|
29
|
-
U+A720-A7FF;
|
|
28
|
+
unicode-range:
|
|
29
|
+
U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
|
|
30
30
|
}
|
|
31
31
|
/* latin */
|
|
32
32
|
@font-face {
|
|
@@ -35,8 +35,9 @@ import d1 from'@emotion/styled';import Lt,{forwardRef,useRef,useState,useEffect,
|
|
|
35
35
|
font-weight: 400;
|
|
36
36
|
font-display: swap;
|
|
37
37
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Hp2ywxg089UriCZOIHTWEBlw.woff2) format('woff2');
|
|
38
|
-
unicode-range:
|
|
39
|
-
U+
|
|
38
|
+
unicode-range:
|
|
39
|
+
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122,
|
|
40
|
+
U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
|
40
41
|
}
|
|
41
42
|
/* latin-ext */
|
|
42
43
|
@font-face {
|
|
@@ -45,8 +46,8 @@ import d1 from'@emotion/styled';import Lt,{forwardRef,useRef,useState,useEffect,
|
|
|
45
46
|
font-weight: 500;
|
|
46
47
|
font-display: swap;
|
|
47
48
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Cp2ywxg089UriAWCrCBamC3YU-CnE6Q.woff2) format('woff2');
|
|
48
|
-
unicode-range:
|
|
49
|
-
U+A720-A7FF;
|
|
49
|
+
unicode-range:
|
|
50
|
+
U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
|
|
50
51
|
}
|
|
51
52
|
/* latin */
|
|
52
53
|
@font-face {
|
|
@@ -55,8 +56,9 @@ import d1 from'@emotion/styled';import Lt,{forwardRef,useRef,useState,useEffect,
|
|
|
55
56
|
font-weight: 500;
|
|
56
57
|
font-display: swap;
|
|
57
58
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Cp2ywxg089UriAWCrCBimC3YU-Ck.woff2) format('woff2');
|
|
58
|
-
unicode-range:
|
|
59
|
-
U+
|
|
59
|
+
unicode-range:
|
|
60
|
+
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122,
|
|
61
|
+
U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
|
60
62
|
}
|
|
61
63
|
/* latin-ext */
|
|
62
64
|
@font-face {
|
|
@@ -65,8 +67,8 @@ import d1 from'@emotion/styled';import Lt,{forwardRef,useRef,useState,useEffect,
|
|
|
65
67
|
font-weight: 700;
|
|
66
68
|
font-display: swap;
|
|
67
69
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Cp2ywxg089UriASitCBamC3YU-CnE6Q.woff2) format('woff2');
|
|
68
|
-
unicode-range:
|
|
69
|
-
U+A720-A7FF;
|
|
70
|
+
unicode-range:
|
|
71
|
+
U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
|
|
70
72
|
}
|
|
71
73
|
/* latin */
|
|
72
74
|
@font-face {
|
|
@@ -75,8 +77,9 @@ import d1 from'@emotion/styled';import Lt,{forwardRef,useRef,useState,useEffect,
|
|
|
75
77
|
font-weight: 700;
|
|
76
78
|
font-display: swap;
|
|
77
79
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Cp2ywxg089UriASitCBimC3YU-Ck.woff2) format('woff2');
|
|
78
|
-
unicode-range:
|
|
79
|
-
U+
|
|
80
|
+
unicode-range:
|
|
81
|
+
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122,
|
|
82
|
+
U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
|
80
83
|
}
|
|
81
84
|
`});var P2=t=>({left:"flex-start",center:"center",right:"flex-end"})[t],k1=t=>{var c,S,E;let e=k(((c=t==null?void 0:t.palette)==null?void 0:c.primary)||"#327EEE"),o=k(((E=(S=t==null?void 0:t.palette)==null?void 0:S.text)==null?void 0:E.primary)||"#001E6C"),n=k("#4CAF50"),s=k("#f44336"),a=k("#ff9800"),l=k("#2196f3"),d=k("#9e9e9e"),g={palette:{primary:e.hex(),primaryDark:e.darken(.3).hex(),primaryLight:e.alpha(.5).toString(),backgroundPaper:"#FFFFFF",backgroundHighlight:"#F5F6F9",backgroundSection:e.alpha(.1).toString(),backgroundButton:e.alpha(.08).toString(),outlinedBorder:"#C4CBDD",outlinedRestingBorder:e.alpha(.5).toString(),outlinedHoverBackground:e.lightness(95).hex(),switchBorder:e.lighten(.1).hex(),switchFill:e.lighten(.5).hex(),switchHandle:e.hex(),warning:"#ed6c02",error:s.hex(),errorDark:s.darken(.3).hex(),success:n.hex(),successDark:n.darken(.3).hex(),white:"#FFFFFF",text:{primary:o.hex(),secondary:o.alpha(.75).toString(),tertiary:o.alpha(.5).toString(),disabled:o.alpha(.35).toString()},statusChips:{success:{background:n.alpha(.15).toString(),text:n.darken(.2).hex(),border:"transparent"},warning:{background:a.alpha(.15).toString(),text:a.darken(.2).hex(),border:"transparent"},error:{background:s.alpha(.15).toString(),text:s.darken(.1).hex(),border:"transparent"},info:{background:l.alpha(.15).toString(),text:l.darken(.2).hex(),border:"transparent"},neutral:{background:d.alpha(.15).toString(),text:d.darken(.2).hex(),border:"transparent"}},progress:{background:"#e0e0e0",low:"#4caf50",medium:"#ff9800",high:"#f44336"}},layout:{planMinWidth:"330px",planMaxWidth:"330px",planMargin:"20px",planPadding:"40px",ctaAlignment:"left",headerAlignment:"left",descriptionAlignment:"left",descriptionMinHeight:"80px",switchBottomSpacing:"40px"},shadows:{light:"0px 2px 1px -1px rgba(0, 0, 0, 0.2), 0px 1px 1px rgba(0, 0, 0, 0.14), 0px 1px 3px rgba(0, 0, 0, 0.12)",popover:"0px 4px 5px -2px rgba(0, 30, 108, 0.2), 0px 7px 10px 1px rgba(0, 30, 108, 0.14), 0px 2px 16px 1px rgba(0, 30, 108, 0.12)"},border:{radius:"10px"},typography:{fontFamily:"custom-font, DM Sans, sans-serif",h1:{fontSize:"32px",fontWeight:"bold",semanticElement:"h1"},h2:{fontSize:"24px",fontWeight:"normal",semanticElement:"h2"},h3:{fontSize:"16px",fontWeight:"normal",semanticElement:"h3"},body:{fontSize:"14px",fontWeight:"normal",semanticElement:"p"},caption:{fontSize:"12px",fontWeight:"normal",semanticElement:"span"}},customCss:""};return Ht(g,t)};var _t=C.div`
|
|
82
85
|
${({$customCss:t})=>t&&css`
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
@media (max-width: 1040px) {
|
|
9
9
|
${({$smallScreenAlign:t})=>t&&`align-self: ${t};`}
|
|
10
10
|
}
|
|
11
|
-
`;function l2({source:t,showWatermark:e,align:o,smallScreenAlign:n="center",style:s={}}){if(!e)return null;let a=()=>{let l=window.location.hostname.replace("www.","");window.open(`https://www.stigg.io/?utm_source=${l}&utm_medium=referral&utm_campaign=${t}`,"_blank");};return jsxRuntime.jsx(vt,{$alignSelf:o,$smallScreenAlign:n,className:yt,style:r({cursor:"pointer"},s),onClick:a,children:jsxRuntime.jsx(kt,{})})}var O=class{error(e,o,...n){console.error(e,o||{},n);}log(e,o){console.log(e,o||{});}debug(e,o){console.debug(e,o||{});}},m1=new O;var u1="8.
|
|
11
|
+
`;function l2({source:t,showWatermark:e,align:o,smallScreenAlign:n="center",style:s={}}){if(!e)return null;let a=()=>{let l=window.location.hostname.replace("www.","");window.open(`https://www.stigg.io/?utm_source=${l}&utm_medium=referral&utm_campaign=${t}`,"_blank");};return jsxRuntime.jsx(vt,{$alignSelf:o,$smallScreenAlign:n,className:yt,style:r({cursor:"pointer"},s),onClick:a,children:jsxRuntime.jsx(kt,{})})}var O=class{error(e,o,...n){console.error(e,o||{},n);}log(e,o){console.log(e,o||{});}debug(e,o){console.debug(e,o||{});}},m1=new O;var u1="8.7.0";var h1="@stigg/react-sdk";var _=Lt__default.default.createContext(null);_.displayName="StiggContext";var Tt="en-US",v2=({apiKey:t,baseUri:e,baseEdgeUri:o,enableEdge:n,customerId:s,customerToken:a,resourceId:l,theme:d,locale:g,cacheTtlMs:c,useEntitlementPolling:S,entitlementPollingInterval:E,entitlementsFallback:P,stiggClient:U,children:R,offline:W,clientName:Z=h1,clientVersion:ct=u1})=>{let o1=Lt.useRef(t),r1={apiKey:t,customerId:s,customerToken:a,resourceId:l,baseUri:e,baseEdgeUri:o,enableEdge:n,entitlementsFallback:P,cacheTtlMs:c,useEntitlementPolling:S,entitlementPollingInterval:E,clientName:Z,clientVersion:ct,offline:W},[M,G]=Lt.useState(()=>({stigg:U!=null?U:x1__default.default.initialize(i(r({},r1),{lazyLoad:true})),locale:g||Tt,isInitialized:false,theme:d,refreshData:()=>y(null,null,function*(){G(u=>i(r({},u),{customerPortalUpdatedAt:new Date})),yield M.stigg.refresh();})}));return Lt.useEffect(()=>{let u=true,N=f=>{u&&G(f);},$=()=>N(f=>i(r({},f),{updatedAt:new Date})),Ct=f=>N(b=>(b.stigg&&b.stigg.removeListener("entitlementsUpdated",$),f.addListener("entitlementsUpdated",$),i(r({},b),{stigg:f,isInitialized:true,updatedAt:new Date})));return y(null,null,function*(){let f=M.stigg;t!==o1.current&&(m1.log("Updating stigg client",{apiKey:t}),o1.current=t,f=x1__default.default.initialize(r({},r1)),N(b=>i(r({},b),{isInitialized:false,updatedAt:new Date}))),yield f.waitForInitialization(),Ct(f);}),()=>{u=false,M.stigg.removeListener("entitlementsUpdated",$),M.stigg.clearCustomer();}},[t]),Lt.useEffect(()=>{let u=M.stigg;s?u.setCustomerId(s,a,l):u.clearCustomer();},[s,a,l]),Lt.useEffect(()=>{G(u=>i(r({},u),{theme:d}));},[d]),jsxRuntime.jsx(_.Provider,{value:M,children:jsxRuntime.jsx(Je.SkeletonTheme,{baseColor:"#F5F6F9",highlightColor:"#e5e6ea",children:R})})};function p(t){let{optional:e}=t||{},o=Lt.useContext(_);if(!o&&!e)throw new Error("Could not find Stigg context; You need to wrap your app in an <StiggProvider> component.");return o}var y1=({externalFontUrl:t})=>jsxRuntime.jsx(react.Global,{styles:react.css`
|
|
12
12
|
${t&&`
|
|
13
13
|
@font-face {
|
|
14
14
|
font-family: 'custom-font';
|
|
@@ -25,8 +25,8 @@
|
|
|
25
25
|
font-weight: 400;
|
|
26
26
|
font-display: swap;
|
|
27
27
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Hp2ywxg089UriCZ2IHTWEBlwu8Q.woff2) format('woff2');
|
|
28
|
-
unicode-range:
|
|
29
|
-
U+A720-A7FF;
|
|
28
|
+
unicode-range:
|
|
29
|
+
U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
|
|
30
30
|
}
|
|
31
31
|
/* latin */
|
|
32
32
|
@font-face {
|
|
@@ -35,8 +35,9 @@
|
|
|
35
35
|
font-weight: 400;
|
|
36
36
|
font-display: swap;
|
|
37
37
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Hp2ywxg089UriCZOIHTWEBlw.woff2) format('woff2');
|
|
38
|
-
unicode-range:
|
|
39
|
-
U+
|
|
38
|
+
unicode-range:
|
|
39
|
+
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122,
|
|
40
|
+
U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
|
40
41
|
}
|
|
41
42
|
/* latin-ext */
|
|
42
43
|
@font-face {
|
|
@@ -45,8 +46,8 @@
|
|
|
45
46
|
font-weight: 500;
|
|
46
47
|
font-display: swap;
|
|
47
48
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Cp2ywxg089UriAWCrCBamC3YU-CnE6Q.woff2) format('woff2');
|
|
48
|
-
unicode-range:
|
|
49
|
-
U+A720-A7FF;
|
|
49
|
+
unicode-range:
|
|
50
|
+
U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
|
|
50
51
|
}
|
|
51
52
|
/* latin */
|
|
52
53
|
@font-face {
|
|
@@ -55,8 +56,9 @@
|
|
|
55
56
|
font-weight: 500;
|
|
56
57
|
font-display: swap;
|
|
57
58
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Cp2ywxg089UriAWCrCBimC3YU-Ck.woff2) format('woff2');
|
|
58
|
-
unicode-range:
|
|
59
|
-
U+
|
|
59
|
+
unicode-range:
|
|
60
|
+
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122,
|
|
61
|
+
U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
|
60
62
|
}
|
|
61
63
|
/* latin-ext */
|
|
62
64
|
@font-face {
|
|
@@ -65,8 +67,8 @@
|
|
|
65
67
|
font-weight: 700;
|
|
66
68
|
font-display: swap;
|
|
67
69
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Cp2ywxg089UriASitCBamC3YU-CnE6Q.woff2) format('woff2');
|
|
68
|
-
unicode-range:
|
|
69
|
-
U+A720-A7FF;
|
|
70
|
+
unicode-range:
|
|
71
|
+
U+0100-024F, U+0259, U+1E00-1EFF, U+2020, U+20A0-20AB, U+20AD-20CF, U+2113, U+2C60-2C7F, U+A720-A7FF;
|
|
70
72
|
}
|
|
71
73
|
/* latin */
|
|
72
74
|
@font-face {
|
|
@@ -75,8 +77,9 @@
|
|
|
75
77
|
font-weight: 700;
|
|
76
78
|
font-display: swap;
|
|
77
79
|
src: url(https://fonts.gstatic.com/s/dmsans/v11/rP2Cp2ywxg089UriASitCBimC3YU-Ck.woff2) format('woff2');
|
|
78
|
-
unicode-range:
|
|
79
|
-
U+
|
|
80
|
+
unicode-range:
|
|
81
|
+
U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+2074, U+20AC, U+2122,
|
|
82
|
+
U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
|
|
80
83
|
}
|
|
81
84
|
`});var P2=t=>({left:"flex-start",center:"center",right:"flex-end"})[t],k1=t=>{var c,S,E;let e=k__default.default(((c=t==null?void 0:t.palette)==null?void 0:c.primary)||"#327EEE"),o=k__default.default(((E=(S=t==null?void 0:t.palette)==null?void 0:S.text)==null?void 0:E.primary)||"#001E6C"),n=k__default.default("#4CAF50"),s=k__default.default("#f44336"),a=k__default.default("#ff9800"),l=k__default.default("#2196f3"),d=k__default.default("#9e9e9e"),g={palette:{primary:e.hex(),primaryDark:e.darken(.3).hex(),primaryLight:e.alpha(.5).toString(),backgroundPaper:"#FFFFFF",backgroundHighlight:"#F5F6F9",backgroundSection:e.alpha(.1).toString(),backgroundButton:e.alpha(.08).toString(),outlinedBorder:"#C4CBDD",outlinedRestingBorder:e.alpha(.5).toString(),outlinedHoverBackground:e.lightness(95).hex(),switchBorder:e.lighten(.1).hex(),switchFill:e.lighten(.5).hex(),switchHandle:e.hex(),warning:"#ed6c02",error:s.hex(),errorDark:s.darken(.3).hex(),success:n.hex(),successDark:n.darken(.3).hex(),white:"#FFFFFF",text:{primary:o.hex(),secondary:o.alpha(.75).toString(),tertiary:o.alpha(.5).toString(),disabled:o.alpha(.35).toString()},statusChips:{success:{background:n.alpha(.15).toString(),text:n.darken(.2).hex(),border:"transparent"},warning:{background:a.alpha(.15).toString(),text:a.darken(.2).hex(),border:"transparent"},error:{background:s.alpha(.15).toString(),text:s.darken(.1).hex(),border:"transparent"},info:{background:l.alpha(.15).toString(),text:l.darken(.2).hex(),border:"transparent"},neutral:{background:d.alpha(.15).toString(),text:d.darken(.2).hex(),border:"transparent"}},progress:{background:"#e0e0e0",low:"#4caf50",medium:"#ff9800",high:"#f44336"}},layout:{planMinWidth:"330px",planMaxWidth:"330px",planMargin:"20px",planPadding:"40px",ctaAlignment:"left",headerAlignment:"left",descriptionAlignment:"left",descriptionMinHeight:"80px",switchBottomSpacing:"40px"},shadows:{light:"0px 2px 1px -1px rgba(0, 0, 0, 0.2), 0px 1px 1px rgba(0, 0, 0, 0.14), 0px 1px 3px rgba(0, 0, 0, 0.12)",popover:"0px 4px 5px -2px rgba(0, 30, 108, 0.2), 0px 7px 10px 1px rgba(0, 30, 108, 0.14), 0px 2px 16px 1px rgba(0, 30, 108, 0.12)"},border:{radius:"10px"},typography:{fontFamily:"custom-font, DM Sans, sans-serif",h1:{fontSize:"32px",fontWeight:"bold",semanticElement:"h1"},h2:{fontSize:"24px",fontWeight:"normal",semanticElement:"h2"},h3:{fontSize:"16px",fontWeight:"normal",semanticElement:"h3"},body:{fontSize:"14px",fontWeight:"normal",semanticElement:"p"},caption:{fontSize:"12px",fontWeight:"normal",semanticElement:"span"}},customCss:""};return Ht__default.default(g,t)};var _t=C.div`
|
|
82
85
|
${({$customCss:t})=>t&&react.css`
|
package/dist/index.d.mts
CHANGED
|
@@ -601,9 +601,9 @@ declare enum ProvisionStatus {
|
|
|
601
601
|
FAILED = "FAILED"
|
|
602
602
|
}
|
|
603
603
|
declare const useWaitForCheckoutCompleted: ({ onProvisionStart, onProvisionSucceeded, onProvisionFailed, }?: {
|
|
604
|
-
onProvisionStart?: (
|
|
605
|
-
onProvisionSucceeded?: (
|
|
606
|
-
onProvisionFailed?: (
|
|
604
|
+
onProvisionStart?: () => void;
|
|
605
|
+
onProvisionSucceeded?: (subscription?: Subscription | null) => void;
|
|
606
|
+
onProvisionFailed?: (err?: any) => void;
|
|
607
607
|
}) => {
|
|
608
608
|
isAwaitingCheckout: boolean;
|
|
609
609
|
provisionStatus: ProvisionStatus;
|
package/dist/index.d.ts
CHANGED
|
@@ -601,9 +601,9 @@ declare enum ProvisionStatus {
|
|
|
601
601
|
FAILED = "FAILED"
|
|
602
602
|
}
|
|
603
603
|
declare const useWaitForCheckoutCompleted: ({ onProvisionStart, onProvisionSucceeded, onProvisionFailed, }?: {
|
|
604
|
-
onProvisionStart?: (
|
|
605
|
-
onProvisionSucceeded?: (
|
|
606
|
-
onProvisionFailed?: (
|
|
604
|
+
onProvisionStart?: () => void;
|
|
605
|
+
onProvisionSucceeded?: (subscription?: Subscription | null) => void;
|
|
606
|
+
onProvisionFailed?: (err?: any) => void;
|
|
607
607
|
}) => {
|
|
608
608
|
isAwaitingCheckout: boolean;
|
|
609
609
|
provisionStatus: ProvisionStatus;
|