Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

react-coinbase-commerce

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-coinbase-commerce - npm Package Compare versions

Comparing version 1.5.0 to 1.5.1

2

dist/index.js

@@ -1,1 +0,1 @@

module.exports["react-coinbase-commerce"]=(()=>{var e={361:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>k});const r=require("react");function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function c(){return(c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function l(e,t){return!t||"object"!==o(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function s(e){return(s=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}n(80);var f=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&u(e,t)}(y,e);var t,n,o,f,p=(o=y,f=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=s(o);if(f){var n=s(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return l(this,e)});function y(){return a(this,y),p.apply(this,arguments)}return t=y,(n=[{key:"render",value:function(){var e=this.props,t=e.styled,n=e.children,o=function(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},c=Object.keys(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(e,["styled","children"]);return r.createElement("button",c({},o,{className:t?"coinbase-commerce-button":o.className}),n||"Buy With Crypto")}}])&&i(t.prototype,n),y}(r.PureComponent);function p(e){return(p="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function y(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function d(e,t){return(d=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function h(e,t){return!t||"object"!==p(t)&&"function"!=typeof t?b(e):t}function b(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function m(e){return(m=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function g(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n(224),n(668);var v=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&d(e,t)}(i,e);var t,n,o,c,a=(o=i,c=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=m(o);if(c){var n=m(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return h(this,e)});function i(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),g(b(t=a.call(this,e)),"origin",void 0),g(b(t),"uuid",void 0),g(b(t),"hostName",void 0),g(b(t),"buildSrc",(function(e){var n,r,o=t.props,c=o.checkoutId,a=o.chargeId,i=o.customMetadata,u=o.disableCaching;if(c)r=c,n="checkout";else{if(!a)throw new Error("must supply either checkoutId or chargeId prop");r=a,n="charges"}var l={origin:e,version:"1.5.0",buttonId:t.uuid,cacheDisabled:u},s="";return i&&"string"!=typeof i?console.error('Received customMetadata not of "string" type. Ignoring.'):i&&(s=i),s&&(l.custom=s),"".concat(t.origin,"/embed/").concat(n,"/").concat(encodeURI(r),"?").concat(function(e){var t=[],n=window.encodeURIComponent;for(var r in e)e.hasOwnProperty(r)&&t.push(n(r)+"="+n(e[r]));return t.join("&")}(l))})),g(b(t),"isValidMessage",(function(e){return e.origin===t.origin&&e.data.buttonId===t.uuid})),g(b(t),"handleMessage",(function(e){if(t.isValidMessage(e)){var n=t.props,r=n.onChargeSuccess,o=n.onChargeFailure,c=n.onModalClose,a=n.onError,i=n.onPaymentDetected;switch(e.data.event){case"charge_confirmed":r&&r(e.data);break;case"charge_failed":o&&o(e.data);break;case"payment_detected":i&&i(e.data);break;case"error_not_found":a(e.data);break;case"checkout_modal_closed":c()}}})),g(b(t),"handleIFrameLoaded",(function(){t.setState({loading:!1}),t.props.onLoad&&t.props.onLoad()})),t.origin="https://commerce.coinbase.com",t.uuid="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)})),t.state={loading:!0,src:null},t}return t=i,(n=[{key:"componentDidMount",value:function(){window.addEventListener("message",this.handleMessage);var e="".concat(window.location.protocol,"//").concat(window.location.hostname).concat(window.location.port?":"+window.location.port:"");this.setState({src:this.buildSrc(e)})}},{key:"componentWillUnmount",value:function(){window.removeEventListener("message",this.handleMessage)}},{key:"render",value:function(){var e=this.state,t=e.loading,n=e.src;return r.createElement("div",{className:"coinbase-commerce-iframe-container"},t||null===n&&r.createElement("div",{className:"commerce-loading-spinner"}),null!==n&&r.createElement("iframe",{onLoad:this.handleIFrameLoaded,className:"coinbase-commerce-iframe",src:n,scrolling:"no",frameBorder:"no"}))}}])&&y(t.prototype,n),i}(r.Component);function O(e){return(O="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function w(){return(w=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function j(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function x(e,t){return(x=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function S(e,t){return!t||"object"!==O(t)&&"function"!=typeof t?P(e):t}function P(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function _(e){return(_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function C(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function E(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const k=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&x(e,t)}(i,e);var t,n,o,c,a=(o=i,c=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=_(o);if(c){var n=_(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return S(this,e)});function i(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),E(P(t=a.call(this,e)),"handleButtonClick",(function(){t.setState({showModal:!0})})),E(P(t),"handleModalClose",(function(){t.setState({showModal:!1}),t.props.onModalClosed&&t.props.onModalClosed()})),E(P(t),"handleError",(function(e){console.error(e),t.setState({showModal:!1})})),t.state={showModal:!1},t}return t=i,(n=[{key:"render",value:function(){var e=this.state.showModal,t=this.props,n=t.onLoad,o=t.onChargeSuccess,c=t.onChargeFailure,a=t.checkoutId,i=t.chargeId,u=t.customMetadata,l=t.onPaymentDetected,s=t.disableCaching,p=t.wrapperStyle,y={onLoad:n,onChargeSuccess:o,onChargeFailure:c,checkoutId:a,chargeId:i,onPaymentDetected:l,disableCaching:s},d=function(e){var t=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?C(Object(n),!0).forEach((function(t){E(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):C(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e);return["onLoad","onChargeSuccess","onChargeFailure","customMetadata","onPaymentDetected","checkoutId","chargeId","disableCaching","wrapperStyle"].forEach((function(e){return delete t[e]})),t}(this.props);return r.createElement("div",{style:p},r.createElement("a",{href:"https://commerce.coinbase.com",rel:"external",title:"Pay with Bitcoin, Bitcoin Cash, DAI, Litecoin, Ethereum, or USD Coin",onClick:function(e){return e.preventDefault()}},r.createElement(f,w({},d,{onClick:this.handleButtonClick}))),e&&r.createElement(v,w({},y,{onModalClose:this.handleModalClose,onError:this.handleError,customMetadata:u})))}}])&&j(t.prototype,n),i}(r.Component)},224:()=>{},80:()=>{},668:()=>{}},t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={exports:{}};return e[r](o,o.exports,n),o.exports}return n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n(361)})();
module.exports=(()=>{var e={361:(e,t,n)=>{"use strict";n.r(t),n.d(t,{default:()=>k});const r=require("react");function o(e){return(o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function c(){return(c=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function i(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function u(e,t){return(u=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function l(e,t){return!t||"object"!==o(t)&&"function"!=typeof t?function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e):t}function s(e){return(s=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}n(80);var f=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&u(e,t)}(y,e);var t,n,o,f,p=(o=y,f=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=s(o);if(f){var n=s(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return l(this,e)});function y(){return a(this,y),p.apply(this,arguments)}return t=y,(n=[{key:"render",value:function(){var e=this.props,t=e.styled,n=e.children,o=function(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},c=Object.keys(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var c=Object.getOwnPropertySymbols(e);for(r=0;r<c.length;r++)n=c[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}(e,["styled","children"]);return r.createElement("button",c({},o,{className:t?"coinbase-commerce-button":o.className}),n||"Buy With Crypto")}}])&&i(t.prototype,n),y}(r.PureComponent);function p(e){return(p="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function y(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function d(e,t){return(d=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function h(e,t){return!t||"object"!==p(t)&&"function"!=typeof t?b(e):t}function b(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function m(e){return(m=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function g(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}n(224),n(668);var v=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&d(e,t)}(i,e);var t,n,o,c,a=(o=i,c=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=m(o);if(c){var n=m(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return h(this,e)});function i(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),g(b(t=a.call(this,e)),"origin",void 0),g(b(t),"uuid",void 0),g(b(t),"hostName",void 0),g(b(t),"buildSrc",(function(e){var n,r,o=t.props,c=o.checkoutId,a=o.chargeId,i=o.customMetadata,u=o.disableCaching;if(c)r=c,n="checkout";else{if(!a)throw new Error("must supply either checkoutId or chargeId prop");r=a,n="charges"}var l={origin:e,version:"1.5.1",buttonId:t.uuid,cacheDisabled:u},s="";return i&&"string"!=typeof i?console.error('Received customMetadata not of "string" type. Ignoring.'):i&&(s=i),s&&(l.custom=s),"".concat(t.origin,"/embed/").concat(n,"/").concat(encodeURI(r),"?").concat(function(e){var t=[],n=window.encodeURIComponent;for(var r in e)e.hasOwnProperty(r)&&t.push(n(r)+"="+n(e[r]));return t.join("&")}(l))})),g(b(t),"isValidMessage",(function(e){return e.origin===t.origin&&e.data.buttonId===t.uuid})),g(b(t),"handleMessage",(function(e){if(t.isValidMessage(e)){var n=t.props,r=n.onChargeSuccess,o=n.onChargeFailure,c=n.onModalClose,a=n.onError,i=n.onPaymentDetected;switch(e.data.event){case"charge_confirmed":r&&r(e.data);break;case"charge_failed":o&&o(e.data);break;case"payment_detected":i&&i(e.data);break;case"error_not_found":a(e.data);break;case"checkout_modal_closed":c()}}})),g(b(t),"handleIFrameLoaded",(function(){t.setState({loading:!1}),t.props.onLoad&&t.props.onLoad()})),t.origin="https://commerce.coinbase.com",t.uuid="xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)})),t.state={loading:!0,src:null},t}return t=i,(n=[{key:"componentDidMount",value:function(){window.addEventListener("message",this.handleMessage);var e="".concat(window.location.protocol,"//").concat(window.location.hostname).concat(window.location.port?":"+window.location.port:"");this.setState({src:this.buildSrc(e)})}},{key:"componentWillUnmount",value:function(){window.removeEventListener("message",this.handleMessage)}},{key:"render",value:function(){var e=this.state,t=e.loading,n=e.src;return r.createElement("div",{className:"coinbase-commerce-iframe-container"},t||null===n&&r.createElement("div",{className:"commerce-loading-spinner"}),null!==n&&r.createElement("iframe",{onLoad:this.handleIFrameLoaded,className:"coinbase-commerce-iframe",src:n,scrolling:"no",frameBorder:"no"}))}}])&&y(t.prototype,n),i}(r.Component);function O(e){return(O="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function w(){return(w=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function j(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function x(e,t){return(x=Object.setPrototypeOf||function(e,t){return e.__proto__=t,e})(e,t)}function S(e,t){return!t||"object"!==O(t)&&"function"!=typeof t?P(e):t}function P(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function _(e){return(_=Object.setPrototypeOf?Object.getPrototypeOf:function(e){return e.__proto__||Object.getPrototypeOf(e)})(e)}function C(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function E(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}const k=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),t&&x(e,t)}(i,e);var t,n,o,c,a=(o=i,c=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Date.prototype.toString.call(Reflect.construct(Date,[],(function(){}))),!0}catch(e){return!1}}(),function(){var e,t=_(o);if(c){var n=_(this).constructor;e=Reflect.construct(t,arguments,n)}else e=t.apply(this,arguments);return S(this,e)});function i(e){var t;return function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,i),E(P(t=a.call(this,e)),"handleButtonClick",(function(){t.setState({showModal:!0})})),E(P(t),"handleModalClose",(function(){t.setState({showModal:!1}),t.props.onModalClosed&&t.props.onModalClosed()})),E(P(t),"handleError",(function(e){console.error(e),t.setState({showModal:!1})})),t.state={showModal:!1},t}return t=i,(n=[{key:"render",value:function(){var e=this.state.showModal,t=this.props,n=t.onLoad,o=t.onChargeSuccess,c=t.onChargeFailure,a=t.checkoutId,i=t.chargeId,u=t.customMetadata,l=t.onPaymentDetected,s=t.disableCaching,p=t.wrapperStyle,y={onLoad:n,onChargeSuccess:o,onChargeFailure:c,checkoutId:a,chargeId:i,onPaymentDetected:l,disableCaching:s},d=function(e){var t=function(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?C(Object(n),!0).forEach((function(t){E(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):C(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}({},e);return["onLoad","onChargeSuccess","onChargeFailure","customMetadata","onPaymentDetected","checkoutId","chargeId","disableCaching","wrapperStyle"].forEach((function(e){return delete t[e]})),t}(this.props);return r.createElement("div",{style:p},r.createElement("a",{href:"https://commerce.coinbase.com",rel:"external",title:"Pay with Bitcoin, Bitcoin Cash, DAI, Litecoin, Ethereum, or USD Coin",onClick:function(e){return e.preventDefault()}},r.createElement(f,w({},d,{onClick:this.handleButtonClick}))),e&&r.createElement(v,w({},y,{onModalClose:this.handleModalClose,onError:this.handleError,customMetadata:u})))}}])&&j(t.prototype,n),i}(r.Component)},224:()=>{},80:()=>{},668:()=>{}},t={};function n(r){if(t[r])return t[r].exports;var o=t[r]={exports:{}};return e[r](o,o.exports,n),o.exports}return n.d=(e,t)=>{for(var r in t)n.o(t,r)&&!n.o(e,r)&&Object.defineProperty(e,r,{enumerable:!0,get:t[r]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},n(361)})();
{
"name": "react-coinbase-commerce",
"version": "1.5.0",
"version": "1.5.1",
"description": "A react component to easily embed a Coinbase Commerce Checkout within your application",

@@ -5,0 +5,0 @@ "keywords": [

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc