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

react-datatrans-light-box

Package Overview
Dependencies
Maintainers
2
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-datatrans-light-box - npm Package Compare versions

Comparing version 1.0.2 to 1.0.3

11

example/package.json

@@ -18,5 +18,3 @@ {

},
"peerDependencies": {
"react": "^15.0.0"
},
"peerDependencies": {},
"devDependencies": {

@@ -40,6 +38,7 @@ "babel": "^6.5.2",

"dependencies": {
"react": "^15.4.2",
"react-datatrans-light-box": "^1.0.0",
"react-dom": "^15.4.2"
"prop-types": "^15.6.0",
"react": "^16.2.0",
"react-datatrans-light-box": "../",
"react-dom": "^16.2.0"
}
}

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

!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require(void 0),require("react")):"function"==typeof define&&define.amd?define([,"react"],t):"object"==typeof exports?exports.LightBox=t(require(void 0),require("react")):e.LightBox=t(e[void 0],e.React)}(this,function(e,t){return function(e){function t(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var n={};return t.m=e,t.c=n,t.i=function(e){return e},t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=9)}([function(t,n){t.exports=e},function(e,n){e.exports=t},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=t.scrollLock="\n html {\n width: 100%;\n height: 100%;\n overflow: hidden;\n }\n html body {\n width: 100%;\n height: 100%;\n overflow: visible;\n position: fixed;\n }\n",o=t.pageFrame={zIndex:9999,position:"fixed",right:0,bottom:0,left:0,top:0,overflow:"hidden",WebkitTransform:"translate3d(0, 0, 0)",transform:"translate3d(0, 0, 0)",display:"none"},a=t.iframe={border:0,margin:0,padding:0,width:"100%",height:"100%"};t.default={scrollLock:r,pageFrame:o,iframe:a}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=function(){function e(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)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),l="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},s=n(1),c=r(s),d=n(0),f=r(d),p=n(8),h=r(p),y=n(4),b=["production","onCancelled","onLoaded","onError","version"],m=function(e,t){return t?"https://payment.datatrans.biz/upp/jsp/upStart.jsp?"+(0,y.toUrlParams)(e):"https://pilot.datatrans.biz/upp/jsp/upStart.jsp?"+(0,y.toUrlParams)(e)},v=function(e){return"undefined"!==l(e.data)&&"error"===e.data.type},g=function(e){function t(e){o(this,t);var n=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));n.onMessage=n.onMessage.bind(n),n.onCancelled=n.onCancelled.bind(n),(0,y.lockScrolling)();var r=(0,y.filterProps)(n.props,b);return n.url=m(r,n.props.production),n.origin=(0,y.parseUrl)(n.url).origin,n.state={visible:!0},n}return i(t,e),u(t,[{key:"onMessage",value:function(e){if(e.origin===this.origin)return"cancel"===e.data?this.onCancelled():"frameReady"===e.data?this.props.onLoaded():v(e)?this.props.onError(e.data):void 0}},{key:"onCancelled",value:function(){this.setState({visible:!1}),(0,y.releaseLock)(),this.props.onCancelled()}},{key:"componentDidMount",value:function(){(0,y.addListener)("message",this.onMessage)}},{key:"componentWillUnmount",value:function(){(0,y.removeListener)("message",this.onMessage),(0,y.releaseLock)()}},{key:"render",value:function(){return this.state.visible?c.default.createElement(h.default,{url:this.url,showsPaymentPage:this.props.showsPaymentPage}):c.default.createElement("div",null," do not render me ")}}]),t}(s.Component);t.default=g,g.propTypes={merchantId:f.default.string.isRequired,refno:f.default.string.isRequired,amount:f.default.string.isRequired,currency:f.default.string.isRequired,sign:f.default.string.isRequired,production:f.default.bool,showsPaymentPage:f.default.bool.isRequired,onCancelled:f.default.func.isRequired,onLoaded:f.default.func.isRequired,onError:f.default.func.isRequired},g.defaultProps={onCancelled:function(){},onLoaded:function(){},onError:function(){},production:!1,theme:"DT2015",version:"1.0.2",showsPaymentPage:!0}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.releaseLock=t.lockScrolling=t.addListener=t.removeListener=t.parseUrl=t.toUrlParams=t.set=t.filterProps=void 0;var r=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},o=n(2),a=function(e){return e&&e.__esModule?e:{default:e}}(o);t.filterProps=function(e,t){var n=r({},e);return t.forEach(function(e){return delete n[e]}),n},t.set=function(e,t,n){return e[t]=n,e},t.toUrlParams=function(e){return Object.keys(e).map(function(t){return t+"="+e[t]}).join("&")},t.parseUrl=function(e){var t=document.createElement("a");return t.href=e,t},t.removeListener=removeEventListener||detachEvent,t.addListener=addEventListener||attachEvent,t.lockScrolling=function(){var e=document.createElement("style");e.innerHTML=a.default.scrollLock,e.id="scroll-lock",document.getElementsByTagName("head")[0].appendChild(e)},t.releaseLock=function(){var e=document.getElementById("scroll-lock");e&&(e.outerHTML="")}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.withLightBox=t.LightBoxHoc=void 0;var o=n(3),a=r(o),i=n(6),u=r(i);a.default.Hoc=u.default,t.LightBoxHoc=u.default,t.withLightBox=u.default,t.default=a.default},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var u=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},l=function(){function e(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)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=n(1),c=r(s),d=n(0),f=r(d),p=n(3),h=r(p),y=n(4),b=function(){return new Error("payment page is not loaded yet.")},m={shouldLoad:!1,visible:!1,loaded:!1,error:null,cancelled:!1},v=function(e){return function(t){function n(e){o(this,n);var t=a(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e));return t.load=t.load.bind(t),t.show=t.show.bind(t),t.on=t.on.bind(t),t.onLoaded=t.onLoaded.bind(t),t.onCancelled=t.onCancelled.bind(t),t.onError=t.onError.bind(t),t.config={},t.state=u({},m,{load:t.load,show:t.show,on:t.on}),t.listeners={cancelled:[],error:[],loaded:[]},t}return i(n,t),l(n,[{key:"onCancelled",value:function(){this.listeners.cancelled.forEach(function(e){return e()}),this.setState(u({},m,{cancelled:!0}))}},{key:"onError",value:function(e){var t=this;this.setState(u({},m,{error:e}),function(){return t.listeners.error.forEach(function(t){return t(e)})})}},{key:"onLoaded",value:function(){var e=this;this.setState({loaded:!0},function(){return e.listeners.loaded.forEach(function(e){return e()})})}},{key:"on",value:function(e,t){var n=this.listeners[e];n&&n.push(t)}},{key:"load",value:function(e){this.config=e,this.setState({shouldLoad:!0})}},{key:"show",value:function(){if(!this.state.loaded)throw b();this.setState({visible:!0})}},{key:"render",value:function(){return c.default.createElement("div",null,this.state.shouldLoad&&c.default.createElement(h.default,u({},this.config,{onLoaded:this.onLoaded,showsPaymentPage:this.state.visible,onCancelled:this.onCancelled,onError:this.onError})),c.default.createElement(e,u({},this.props,{lightBox:(0,y.filterProps)(this.state,["shouldLoad"])})))}}]),n}(s.Component)};v.propType=f.default.shape({visible:f.default.bool.isRequired,loaded:f.default.bool.isRequired,cancelled:f.default.bool.isRequired,error:f.default.any,load:f.default.func.isRequired,show:f.default.func.isRequired,on:f.default.func.isRequired}),t.default=v},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(1),a=r(o),i=n(0),u=r(i),l=n(2),s=r(l),c=function(e){return a.default.createElement("iframe",{src:e.url,style:s.default.iframe,id:"datatransPaymentFrame",name:"datatransPaymentFrame",frameBorder:0,allowTransparency:!0})};c.propTypes={url:u.default.string.isRequired},t.default=c},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=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},a=n(1),i=r(a),u=n(0),l=r(u),s=n(7),c=r(s),d=n(2),f=r(d),p=function(e){var t=e.showsPaymentPage?o({},f.default.pageFrame,{display:"block"}):f.default.pageFrame;return i.default.createElement("div",{style:t},i.default.createElement(c.default,{url:e.url}))};p.propTypes={url:l.default.string.isRequired,showsPaymentPage:l.default.bool.isRequired},t.default=p},function(e,t,n){e.exports=n(5)}])});
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("react")):"function"==typeof define&&define.amd?define(["react"],t):"object"==typeof exports?exports.LightBox=t(require("react")):e.LightBox=t(e.React)}(this,function(e){return function(e){function t(r){if(n[r])return n[r].exports;var o=n[r]={i:r,l:!1,exports:{}};return e[r].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var n={};return t.m=e,t.c=n,t.i=function(e){return e},t.d=function(e,n,r){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=8)}([function(t,n){t.exports=e},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var r=t.scrollLock="\n html {\n width: 100%;\n height: 100%;\n overflow: hidden;\n }\n html body {\n width: 100%;\n height: 100%;\n overflow: visible;\n position: fixed;\n }\n",o=t.pageFrame={zIndex:9999,position:"fixed",right:0,bottom:0,left:0,top:0,overflow:"hidden",WebkitTransform:"translate3d(0, 0, 0)",transform:"translate3d(0, 0, 0)",display:"none"},a=t.iframe={border:0,margin:0,padding:0,width:"100%",height:"100%"};t.default={scrollLock:r,pageFrame:o,iframe:a}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var l=function(){function e(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)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),u="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},s=n(0),c=r(s),f=n(7),d=r(f),p=n(3),h=["production","onCancelled","onLoaded","onError","version"],y=function(e,t){return t?"https://payment.datatrans.biz/upp/jsp/upStart.jsp?"+(0,p.toUrlParams)(e):"https://pilot.datatrans.biz/upp/jsp/upStart.jsp?"+(0,p.toUrlParams)(e)},m=function(e){return"undefined"!==u(e.data)&&"error"===e.data.type},v=function(e){function t(e){o(this,t);var n=a(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));n.onMessage=n.onMessage.bind(n),n.onCancelled=n.onCancelled.bind(n),(0,p.lockScrolling)();var r=(0,p.filterProps)(n.props,h);return n.url=y(r,n.props.production),n.origin=(0,p.parseUrl)(n.url).origin,n.state={visible:!0},n}return i(t,e),l(t,[{key:"onMessage",value:function(e){if(e.origin===this.origin)return"cancel"===e.data?this.onCancelled():"frameReady"===e.data?this.props.onLoaded():m(e)?this.props.onError(e.data):void 0}},{key:"onCancelled",value:function(){this.setState({visible:!1}),(0,p.releaseLock)(),this.props.onCancelled()}},{key:"componentDidMount",value:function(){(0,p.addListener)("message",this.onMessage)}},{key:"componentWillUnmount",value:function(){(0,p.removeListener)("message",this.onMessage),(0,p.releaseLock)()}},{key:"render",value:function(){return this.state.visible?c.default.createElement(d.default,{url:this.url,showsPaymentPage:this.props.showsPaymentPage}):c.default.createElement("div",null," do not render me ")}}]),t}(s.Component);t.default=v,v.defaultProps={onCancelled:function(){},onLoaded:function(){},onError:function(){},production:!1,theme:"DT2015",version:"1.0.2",showsPaymentPage:!0}},function(e,t,n){"use strict";Object.defineProperty(t,"__esModule",{value:!0}),t.releaseLock=t.lockScrolling=t.addListener=t.removeListener=t.parseUrl=t.toUrlParams=t.set=t.filterProps=void 0;var r=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},o=n(1),a=function(e){return e&&e.__esModule?e:{default:e}}(o);t.filterProps=function(e,t){var n=r({},e);return t.forEach(function(e){return delete n[e]}),n},t.set=function(e,t,n){return e[t]=n,e},t.toUrlParams=function(e){return Object.keys(e).map(function(t){return t+"="+e[t]}).join("&")},t.parseUrl=function(e){var t=document.createElement("a");return t.href=e,t},t.removeListener=removeEventListener||detachEvent,t.addListener=addEventListener||attachEvent,t.lockScrolling=function(){var e=document.createElement("style");e.innerHTML=a.default.scrollLock,e.id="scroll-lock",document.getElementsByTagName("head")[0].appendChild(e)},t.releaseLock=function(){var e=document.getElementById("scroll-lock");e&&(e.outerHTML="")}},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0}),t.withLightBox=t.LightBoxHoc=void 0;var o=n(2),a=r(o),i=n(5),l=r(i);a.default.Hoc=l.default,t.LightBoxHoc=l.default,t.withLightBox=l.default,t.default=a.default},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function i(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}Object.defineProperty(t,"__esModule",{value:!0});var l=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},u=function(){function e(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)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),s=n(0),c=r(s),f=n(2),d=r(f),p=n(3),h=function(){return new Error("payment page is not loaded yet.")},y={shouldLoad:!1,visible:!1,loaded:!1,error:null,cancelled:!1},m=function(e){return function(t){function n(e){o(this,n);var t=a(this,(n.__proto__||Object.getPrototypeOf(n)).call(this,e));return t.load=t.load.bind(t),t.show=t.show.bind(t),t.on=t.on.bind(t),t.onLoaded=t.onLoaded.bind(t),t.onCancelled=t.onCancelled.bind(t),t.onError=t.onError.bind(t),t.config={},t.state=l({},y,{load:t.load,show:t.show,on:t.on}),t.listeners={cancelled:[],error:[],loaded:[]},t}return i(n,t),u(n,[{key:"onCancelled",value:function(){this.listeners.cancelled.forEach(function(e){return e()}),this.setState(l({},y,{cancelled:!0}))}},{key:"onError",value:function(e){var t=this;this.setState(l({},y,{error:e}),function(){return t.listeners.error.forEach(function(t){return t(e)})})}},{key:"onLoaded",value:function(){var e=this;this.setState({loaded:!0},function(){return e.listeners.loaded.forEach(function(e){return e()})})}},{key:"on",value:function(e,t){var n=this.listeners[e];n&&n.push(t)}},{key:"load",value:function(e){this.config=e,this.setState({shouldLoad:!0})}},{key:"show",value:function(){if(!this.state.loaded)throw h();this.setState({visible:!0})}},{key:"render",value:function(){return c.default.createElement("div",null,this.state.shouldLoad&&c.default.createElement(d.default,l({},this.config,{onLoaded:this.onLoaded,showsPaymentPage:this.state.visible,onCancelled:this.onCancelled,onError:this.onError})),c.default.createElement(e,l({},this.props,{lightBox:(0,p.filterProps)(this.state,["shouldLoad"])})))}}]),n}(s.Component)};t.default=m},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=n(0),a=r(o),i=n(1),l=r(i),u=function(e){return a.default.createElement("iframe",{src:e.url,style:l.default.iframe,id:"datatransPaymentFrame",name:"datatransPaymentFrame",frameBorder:0,allowTransparency:!0})};t.default=u},function(e,t,n){"use strict";function r(e){return e&&e.__esModule?e:{default:e}}Object.defineProperty(t,"__esModule",{value:!0});var o=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},a=n(0),i=r(a),l=n(6),u=r(l),s=n(1),c=r(s),f=function(e){var t=e.showsPaymentPage?o({},c.default.pageFrame,{display:"block"}):c.default.pageFrame;return i.default.createElement("div",{style:t},i.default.createElement(u.default,{url:e.url}))};t.default=f},function(e,t,n){e.exports=n(4)}])});
{
"name": "react-datatrans-light-box",
"version": "1.0.2",
"version": "1.0.3",
"description": "Datatrans light box component for react apps",
"main": "lib/main.js",
"module": "src/index.js",
"keywords": [

@@ -26,3 +25,2 @@ "react",

"peerDependencies": {
"prop-types": "^15.5.10",
"react": "^15.0.0 || ^16.0.0-0"

@@ -29,0 +27,0 @@ },

import React, {Component} from 'react'
import PropTypes from 'prop-types'
// import PropTypes from 'prop-types'
import PaymentPageFrame from './PaymentPageFrame'

@@ -74,17 +74,17 @@ import {

LightBox.propTypes = {
merchantId: PropTypes.string.isRequired,
refno: PropTypes.string.isRequired,
amount: PropTypes.string.isRequired,
currency: PropTypes.string.isRequired,
sign: PropTypes.string.isRequired,
// LightBox.propTypes = {
// merchantId: PropTypes.string.isRequired,
// refno: PropTypes.string.isRequired,
// amount: PropTypes.string.isRequired,
// currency: PropTypes.string.isRequired,
// sign: PropTypes.string.isRequired,
production: PropTypes.bool,
showsPaymentPage: PropTypes.bool.isRequired,
// production: PropTypes.bool,
// showsPaymentPage: PropTypes.bool.isRequired,
onCancelled: PropTypes.func.isRequired,
onLoaded: PropTypes.func.isRequired,
onError: PropTypes.func.isRequired,
// onCancelled: PropTypes.func.isRequired,
// onLoaded: PropTypes.func.isRequired,
// onError: PropTypes.func.isRequired,
}
// }

@@ -91,0 +91,0 @@ LightBox.defaultProps = {

import React, {Component} from 'react'
import PropTypes from 'prop-types'
// import PropTypes from 'prop-types'
import LightBox from './LightBox'

@@ -108,17 +108,17 @@ import {filterProps} from './utils'

LightBoxHoc.propType = PropTypes.shape({
// LightBoxHoc.propType = PropTypes.shape({
//LightBox state
visible: PropTypes.bool.isRequired,
loaded: PropTypes.bool.isRequired,
cancelled: PropTypes.bool.isRequired,
error: PropTypes.any,
// //LightBox state
// visible: PropTypes.bool.isRequired,
// loaded: PropTypes.bool.isRequired,
// cancelled: PropTypes.bool.isRequired,
// error: PropTypes.any,
//Methods
load: PropTypes.func.isRequired,
show: PropTypes.func.isRequired,
on: PropTypes.func.isRequired,
})
// //Methods
// load: PropTypes.func.isRequired,
// show: PropTypes.func.isRequired,
// on: PropTypes.func.isRequired,
// })
export default LightBoxHoc
import React from 'react'
import PropTypes from 'prop-types'
// import PropTypes from 'prop-types'
import styles from './styles'

@@ -18,6 +18,6 @@

PaymentPage.propTypes = {
url: PropTypes.string.isRequired,
}
// PaymentPage.propTypes = {
// url: PropTypes.string.isRequired,
// }
export default PaymentPage
import React from 'react'
import PropTypes from 'prop-types'
// import PropTypes from 'prop-types'
import PaymentPage from './PaymentPage'

@@ -20,7 +20,7 @@ import styles from './styles'

PaymentPageFrame.propTypes = {
url: PropTypes.string.isRequired,
showsPaymentPage: PropTypes.bool.isRequired,
}
// PaymentPageFrame.propTypes = {
// url: PropTypes.string.isRequired,
// showsPaymentPage: PropTypes.bool.isRequired,
// }
export default PaymentPageFrame

@@ -16,5 +16,5 @@ const path = require('path')

root: 'PropTypes',
commonjs2: 'PropTypes',
commonjs: 'PropTypes',
amd: 'PropTypes'
commonjs2: 'prop-types',
commonjs: 'prop-types',
amd: 'prop-types'
}

@@ -21,0 +21,0 @@ }

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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