GoScrobble/web/node_modules/.cache/babel-loader/50faa35cbbfa4af7f4ae88fe0973f852.json

1 line
4.0 KiB
JSON
Raw Normal View History

2022-04-25 02:47:15 +00:00
{"ast":null,"code":"import _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { canUseDOM } from './utils';\nvar propTypes = {\n children: PropTypes.node.isRequired,\n node: PropTypes.any\n};\n\nvar Portal = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Portal, _React$Component);\n\n function Portal() {\n return _React$Component.apply(this, arguments) || this;\n }\n\n var _proto = Portal.prototype;\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n if (this.defaultNode) {\n document.body.removeChild(this.defaultNode);\n }\n\n this.defaultNode = null;\n };\n\n _proto.render = function render() {\n if (!canUseDOM) {\n return null;\n }\n\n if (!this.props.node && !this.defaultNode) {\n this.defaultNode = document.createElement('div');\n document.body.appendChild(this.defaultNode);\n }\n\n return /*#__PURE__*/ReactDOM.createPortal(this.props.children, this.props.node || this.defaultNode);\n };\n\n return Portal;\n}(React.Component);\n\nPortal.propTypes = propTypes;\nexport default Portal;","map":{"version":3,"sources":["/app/node_modules/reactstrap/es/Portal.js"],"names":["_inheritsLoose","React","ReactDOM","PropTypes","canUseDOM","propTypes","children","node","isRequired","any","Portal","_React$Component","apply","arguments","_proto","prototype","componentWillUnmount","defaultNode","document","body","removeChild","render","props","createElement","appendChild","createPortal","Component"],"mappings":"AAAA,OAAOA,cAAP,MAA2B,0CAA3B;AACA,OAAOC,KAAP,MAAkB,OAAlB;AACA,OAAOC,QAAP,MAAqB,WAArB;AACA,OAAOC,SAAP,MAAsB,YAAtB;AACA,SAASC,SAAT,QAA0B,SAA1B;AACA,IAAIC,SAAS,GAAG;AACdC,EAAAA,QAAQ,EAAEH,SAAS,CAACI,IAAV,CAAeC,UADX;AAEdD,EAAAA,IAAI,EAAEJ,SAAS,CAACM;AAFF,CAAhB;;AAKA,IAAIC,MAAM,GAAG,aAAa,UAAUC,gBAAV,EAA4B;AACpDX,EAAAA,cAAc,CAACU,MAAD,EAASC,gBAAT,CAAd;;AAEA,WAASD,MAAT,GAAkB;AAChB,WAAOC,gBAAgB,CAACC,KAAjB,CAAuB,IAAvB,EAA6BC,SAA7B,KAA2C,IAAlD;AACD;;AAED,MAAIC,MAAM,GAAGJ,MAAM,CAACK,SAApB;;AAEAD,EAAAA,MAAM,CAACE,oBAAP,GAA8B,SAASA,oBAAT,GAAgC;AAC5D,QAAI,KAAKC,WAAT,EAAsB;AACpBC,MAAAA,QAAQ,CAACC,IAAT,CAAcC,WAAd,CAA0B,KAAKH,WAA/B;AACD;;AAED,SAAKA,WAAL,GAAmB,IAAnB;AACD,GAND;;AAQAH,EAAAA,MAAM,CAACO,MAAP,GAAgB,SAASA,MAAT,GAAkB;AAChC,QAAI,CAACjB,SAAL,EAAgB;AACd,aAAO,IAAP;AACD;;AAED,QAAI,CAAC,KAAKkB,KAAL,CAAWf,IAAZ,IAAoB,CAAC,KAAKU,WAA9B,EAA2C;AACzC,WAAKA,WAAL,GAAmBC,QAAQ,CAACK,aAAT,CAAuB,KAAvB,CAAnB;AACAL,MAAAA,QAAQ,CAACC,IAAT,CAAcK,WAAd,CAA0B,KAAKP,WAA/B;AACD;;AAED,WAAO,aAAaf,QAAQ,CAACuB,YAAT,CAAsB,KAAKH,KAAL,CAAWhB,QAAjC,EAA2C,KAAKgB,KAAL,CAAWf,IAAX,IAAmB,KAAKU,WAAnE,CAApB;AACD,GAXD;;AAaA,SAAOP,MAAP;AACD,CA/ByB,CA+BxBT,KAAK,CAACyB,SA/BkB,CAA1B;;AAiCAhB,MAAM,CAACL,SAAP,GAAmBA,SAAnB;AACA,eAAeK,MAAf","sourcesContent":["import _inheritsLoose from \"@babel/runtime/helpers/esm/inheritsLoose\";\nimport React from 'react';\nimport ReactDOM from 'react-dom';\nimport PropTypes from 'prop-types';\nimport { canUseDOM } from './utils';\nvar propTypes = {\n children: PropTypes.node.isRequired,\n node: PropTypes.any\n};\n\nvar Portal = /*#__PURE__*/function (_React$Component) {\n _inheritsLoose(Portal, _React$Component);\n\n function Portal() {\n return _React$Component.apply(this, arguments) || this;\n }\n\n var _proto = Portal.prototype;\n\n _proto.componentWillUnmount = function componentWillUnmount() {\n if (this.defaultNode) {\n document.body.removeChild(this.defaultNode);\n }\n\n this.defaultNode = null;\n };\n\n _proto.render = function render() {\n if (!canUseDOM) {\n return null;\n }\n\n if (!this.props.node && !this.defaultNode) {\n this.defaultNode = document.createElement('div');\n document.body.appendChild(this.defaultNode);\n }\n\n return /*#__PURE__*/ReactDOM.createPortal(this.props.children, this.props.node || this.defaultNode);\n };\n\n return Portal;\n}(React.Component);\n\nPortal.propTypes = propTypes;\nexport default Portal;"]},"metadata":{},"sourceType":"module"}