(globalThis.webpackChunkreally_simple_ssl_modal=globalThis.webpackChunkreally_simple_ssl_modal||[]).push([[433],{433:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>u});var l=r(609),s=r(427),n=r(87),a=r(723),o=r(378),c=r.n(o);class i extends n.Component{constructor(e){super(e),this.state={hasError:!1,error:null,errorInfo:null},this.resetError=this.resetError.bind(this)}static getDerivedStateFromError(e){return{hasError:!0}}componentDidCatch(e,t){this.setState({error:e,errorInfo:t}),console.log("ErrorBoundary",e,t)}resetError(){this.setState({hasError:!1,error:null,errorInfo:null})}render(){return this.state.hasError?(0,l.createElement)("div",null,(0,l.createElement)("h1",null,"Something went wrong."),(0,l.createElement)("p",null,this.props.fallback),(0,l.createElement)("button",{onClick:this.resetError},"Try Again")):this.props.children}}i.propTypes={children:c().node,fallback:c().node};const m=i,u=({title:e,subTitle:t,currentStep:o,buttons:c,content:i,list:u,confirmAction:p,confirmText:d,alternativeAction:E,alternativeText:h,alternativeClassName:f,isOpen:g,setOpen:y,className:_})=>{const[b,C]=(0,n.useState)(null);let T="undefined"!=typeof rsssl_modal?rsssl_modal.plugin_url:rsssl_settings.plugin_url;f=f||"rsssl-warning",(0,n.useEffect)((()=>{b||Promise.all([r.e(161),r.e(291)]).then(r.bind(r,291)).then((({default:e})=>{C((()=>e))}))}));let k=_?" "+_:"";return(0,l.createElement)(l.Fragment,null,g&&(0,l.createElement)(l.Fragment,null,(0,l.createElement)(m,{fallback:"Error loading modal"},(0,l.createElement)(s.Modal,{className:"rsssl-modal"+k,shouldCloseOnClickOutside:!1,shouldCloseOnEsc:!1,title:e,onRequestClose:()=>y(!1),open:g},(0,l.createElement)("div",{className:"rsssl-modal-body"},t&&(0,l.createElement)("p",{dangerouslySetInnerHTML:{__html:t}}),i&&(0,l.createElement)(l.Fragment,null,i),u&&b&&(0,l.createElement)("ul",null,u.map(((e,t)=>(0,l.createElement)("li",{key:t},(0,l.createElement)(b,{name:e.icon,color:e.color}),e.text))))),(0,l.createElement)("div",{className:"rsssl-modal-footer"},(0,l.createElement)("div",{className:"rsssl-modal-footer-image"},(0,l.createElement)("img",{className:"rsssl-logo",src:T+"assets/img/really-simple-security-logo.svg",alt:"Really Simple Security"})),(0,l.createElement)("div",{className:"rsssl-modal-footer-buttons"},(0,l.createElement)(s.Button,{onClick:()=>y(!1)},(0,a.__)("Cancel","really-simple-ssl")),c&&(0,l.createElement)(l.Fragment,null,c),!c&&(0,l.createElement)(l.Fragment,null,h&&(0,l.createElement)(s.Button,{className:f,onClick:()=>E()},h),d&&(0,l.createElement)(s.Button,{isPrimary:!0,onClick:()=>p()},d))))))))}},572:(e,t,r)=>{"use strict";var l=r(808);function s(){}function n(){}n.resetWarningCache=s,e.exports=function(){function e(e,t,r,s,n,a){if(a!==l){var o=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw o.name="Invariant Violation",o}}function t(){return e}e.isRequired=e;var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:n,resetWarningCache:s};return r.PropTypes=r,r}},378:(e,t,r)=>{e.exports=r(572)()},808:e=>{"use strict";e.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}}]);