← Back
Editing: settings.min.js
/*! For license information please see settings.min.js.LICENSE.txt */ (globalThis.itsecWebpackJsonP=globalThis.itsecWebpackJsonP||[]).push([[8781],{3075:e=>{e.exports=function(){return this.wp.i18n}()},8601:e=>{e.exports=function(){return this.wp.element}()},22642:(e,t,r)=>{"use strict";r.d(t,{A:()=>i});var n=r(51609),o=r(55933);const i=(0,n.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,n.createElement)(o.Path,{d:"M18.5 15v3.5H13V6.7l4.5 4.1 1-1.1-6.2-5.8-5.8 5.8 1 1.1 4-4v11.7h-6V15H4v5h16v-5z"}))},26425:e=>{e.exports=function(){return this.itsec.pages.settings}()},31987:e=>{e.exports=function(){return this.wp.data}()},38125:e=>{e.exports=function(){return this.wp.plugins}()},39959:e=>{e.exports=function(){return this.wp.components}()},46627:e=>{e.exports=function(){return this.itsec.packages.data}()},46644:(e,t,r)=>{"use strict";r.d(t,{A:()=>i});var n=r(51609),o=r(55933);const i=(0,n.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"-2 -2 24 24"},(0,n.createElement)(o.Path,{d:"M20 10c0-5.51-4.49-10-10-10C4.48 0 0 4.49 0 10c0 5.52 4.48 10 10 10 5.51 0 10-4.48 10-10zM7.78 15.37L4.37 6.22c.55-.02 1.17-.08 1.17-.08.5-.06.44-1.13-.06-1.11 0 0-1.45.11-2.37.11-.18 0-.37 0-.58-.01C4.12 2.69 6.87 1.11 10 1.11c2.33 0 4.45.87 6.05 2.34-.68-.11-1.65.39-1.65 1.58 0 .74.45 1.36.9 2.1.35.61.55 1.36.55 2.46 0 1.49-1.4 5-1.4 5l-3.03-8.37c.54-.02.82-.17.82-.17.5-.05.44-1.25-.06-1.22 0 0-1.44.12-2.38.12-.87 0-2.33-.12-2.33-.12-.5-.03-.56 1.2-.06 1.22l.92.08 1.26 3.41zM17.41 10c.24-.64.74-1.87.43-4.25.7 1.29 1.05 2.71 1.05 4.25 0 3.29-1.73 6.24-4.4 7.78.97-2.59 1.94-5.2 2.92-7.78zM6.1 18.09C3.12 16.65 1.11 13.53 1.11 10c0-1.3.23-2.48.72-3.59C3.25 10.3 4.67 14.2 6.1 18.09zm4.03-6.63l2.58 6.98c-.86.29-1.76.45-2.71.45-.79 0-1.57-.11-2.29-.33.81-2.38 1.62-4.74 2.42-7.1z"}))},46814:e=>{e.exports=function(){return this.itsec["import-export"].data}()},46942:(e,t)=>{var r;!function(){"use strict";var n={}.hasOwnProperty;function o(){for(var e="",t=0;t<arguments.length;t++){var r=arguments[t];r&&(e=a(e,i(r)))}return e}function i(e){if("string"==typeof e||"number"==typeof e)return e;if("object"!=typeof e)return"";if(Array.isArray(e))return o.apply(null,e);if(e.toString!==Object.prototype.toString&&!e.toString.toString().includes("[native code]"))return e.toString();var t="";for(var r in e)n.call(e,r)&&e[r]&&(t=a(t,r));return t}function a(e,t){return t?e?e+" "+t:e+t:e}e.exports?(o.default=o,e.exports=o):void 0===(r=function(){return o}.apply(t,[]))||(e.exports=r)}()},47406:(e,t,r)=>{"use strict";r.d(t,{A:()=>i});var n=r(51609),o=r(55933);const i=(0,n.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,n.createElement)(o.Path,{d:"M20 11.2H6.8l3.7-3.7-1-1L3.9 12l5.6 5.5 1-1-3.7-3.7H20z"}))},47989:e=>{e.exports=function(){return this.wp.htmlEntities}()},50444:e=>{e.exports=function(){return this.itsec["import-export"].ui}()},51609:e=>{"use strict";e.exports=window.React},55933:e=>{e.exports=function(){return this.wp.primitives}()},57677:(e,t,r)=>{"use strict";r.d(t,{A:()=>o});var n=r(8601);const o=(0,n.forwardRef)((function({icon:e,size:t=24,...r},o){return(0,n.cloneElement)(e,{width:t,height:t,...r,ref:o})}))},62247:e=>{e.exports=function(){return this.wp.isShallowEqual}()},63703:(e,t,r)=>{"use strict";var n=r(51609),o=r(38125),i=r(3075),a=r(54625),s=r(31987),l=r(8601),c=r(53390),u=r(26425),p=r(46814),d=r(98883),m=r(62932),E=r(81923),h=r(56347);const g=(0,E.A)("div",{target:"e1kzz2so0"})({name:"e1ptu",styles:"width:100%;max-width:600px"});function f(){return(0,n.createElement)(u.Page,{id:"select-export",title:(0,i.__)("Select Export","it-l10n-ithemes-security-pro"),roots:["import"],priority:0},(()=>(0,n.createElement)(w,null)))}function w(){const{path:e,url:t}=(0,h.W5)();return(0,n.createElement)(g,null,(0,n.createElement)(h.dO,null,(0,n.createElement)(h.qh,{path:`${e}/wordpress-create`,render:()=>(0,n.createElement)(ae,{baseUrl:t})}),(0,n.createElement)(h.qh,{path:`${e}/wordpress-select`,render:()=>(0,n.createElement)(oe,{baseUrl:t})}),(0,n.createElement)(h.qh,{path:`${e}/wordpress-connect`,render:()=>(0,n.createElement)(Y,{baseUrl:t})}),(0,n.createElement)(h.qh,{path:`${e}/summary`,render:()=>(0,n.createElement)(le,{baseUrl:t})}),(0,n.createElement)(h.qh,{path:e,render:()=>(0,n.createElement)(N,{baseUrl:t})})))}var x=r(58168),_=r(39959),v=r(47406),S=r(22642),y=r(46644);const b=(0,E.A)("div",{target:"e1j9p0p21"})({name:"baeyrq",styles:"display:flex;gap:3.25rem;&>*{flex-grow:1;width:100%;}"}),O=(0,E.A)(_.DropZone,{target:"e1j9p0p20"})({name:"4zleql",styles:"display:block"});function N({baseUrl:e}){const t=(0,u.useNavigateTo)(),{url:r}=(0,h.W5)(),{onboardComplete:o}=(0,u.useConfigContext)(),E=(0,m.aZ)("tools"),{validateExportFile:g,resetImport:f}=(0,s.useDispatch)(p.STORE_NAME),w=async r=>{r.length&&(await g(r[0]),t(`${e}/summary`))};(0,l.useEffect)((()=>{f()}),[f]);const N={text:(0,i.__)("Back","it-l10n-ithemes-security-pro"),icon:v.A,iconPosition:"left",variant:"tertiary"};return(0,n.createElement)(React.Fragment,null,(0,n.createElement)(u.OnboardBackActionFill,null,o&&(0,n.createElement)(c.$n,(0,x.A)({href:E},N)),!o&&(0,n.createElement)(a.N_,(0,x.A)({to:"/onboard",component:(0,d.kk)(c.$n)},N))),(0,n.createElement)(u.OnboardHeader,{title:(0,i.__)("Select Export","it-l10n-ithemes-security-pro"),description:(0,i.__)("Either upload an export file or enter the URL of a website running Solid Security.","it-l10n-ithemes-security-pro")}),(0,n.createElement)(b,null,(0,n.createElement)(_.FormFileUpload,{onChange:e=>w(e.target.files),accept:"text/plain,application/json,application/zip",render:({openFileDialog:e})=>(0,n.createElement)(u.SelectableCard,{title:(0,i.__)("Upload File","it-l10n-ithemes-security-pro"),description:(0,i.__)("Upload a Solid Security export file from your computer.","it-l10n-ithemes-security-pro"),icon:S.A,direction:"vertical",onClick:e})}),(0,n.createElement)(u.SelectableCard,{title:(0,i.__)("WordPress Site","it-l10n-ithemes-security-pro"),description:(0,i.__)("Import from a WordPress site running Solid Security.","it-l10n-ithemes-security-pro"),icon:y.A,direction:"vertical",onClick:()=>t(`${r}/wordpress-connect`)})),(0,n.createElement)(O,{onFilesDrop:w}))}var A=r(7e3),C=r(77172),R=r(89959),I=r(47926),T=r(46627);function M(){const{roles:e,targets:t,map:r}=(0,s.useSelect)((e=>({roles:e(T.coreStore).getRoles(),map:e(p.STORE_NAME).getImportRoleMap(),targets:e(p.STORE_NAME).getImportExportRoleReplacementTargets()})),[]),{editImportRoleMap:o}=(0,s.useDispatch)(p.STORE_NAME);return t.length&&e?(0,n.createElement)(W,{title:(0,i.__)("Replace Roles","it-l10n-ithemes-security-pro"),description:(0,i.__)("Choose the user roles that best match the roles from the export.","it-l10n-ithemes-security-pro")},t.map((t=>(0,n.createElement)(D,{key:t.slug,target:t,value:r,onChange:o,roles:e})))):null}function L(){const{targets:e,map:t}=(0,s.useSelect)((e=>({map:e(p.STORE_NAME).getImportUserMap(),targets:e(p.STORE_NAME).getImportExportUserReplacementTargets()})),[]),{editImportUserMap:r}=(0,s.useDispatch)(p.STORE_NAME);return e.length?(0,n.createElement)(W,{title:(0,i.__)("Replace Users","it-l10n-ithemes-security-pro"),description:(0,i.__)("Choose the users that best match the users from the export.","it-l10n-ithemes-security-pro")},e.map((e=>(0,n.createElement)(k,{key:e.id,target:e,value:t,onChange:r})))):null}function W({title:e,description:t,children:r}){return(0,n.createElement)("fieldset",null,(0,n.createElement)(_.Flex,{direction:"column",gap:5,expanded:!1},(0,n.createElement)(_.Flex,{direction:"column",gap:2,expanded:!1},(0,n.createElement)(c.EY,{as:"legend",size:c.$C.SUBTITLE_SMALL,weight:c.uL.HEAVY,variant:c.J3.MUTED,text:e}),(0,n.createElement)(c.EY,{variant:c.J3.MUTED,text:t})),(0,n.createElement)(_.Flex,{direction:"column",gap:2,expanded:!1},r)))}function D({target:e,value:t,onChange:r,roles:o}){var i;const a=Object.entries(o).map((([e,t])=>({value:e,label:t.label}))).concat({value:"",label:""});return(0,n.createElement)(_.SelectControl,{label:e.label,value:null!==(i=t[e.slug])&&void 0!==i?i:o[e.slug]?e.slug:"",onChange:n=>r({...t,[e.slug]:n}),options:a})}function k({target:e,value:t,onChange:r}){return(0,n.createElement)(I.F5,{value:t[e.id]||0,onChange:n=>r({...t,[e.id]:n}),label:(0,i.sprintf)((0,i.__)("%1$s (%2$s)","it-l10n-ithemes-security-pro"),e.name,e.email),path:"/wp/v2/users",labelAttr:"name"})}var F=r(66087),U=r(47989);const B=(0,E.A)("div",{target:"e1vmmqn63"})({name:"1ifi7n9",styles:'display:grid;width:100%;grid-gap:0.5rem;grid-template-areas:"logo details spinner";grid-template-columns:fit-content(80px) auto fit-content(40px);align-items:center'}),P=(0,E.A)("img",{target:"e1vmmqn62"})({name:"a4ee79",styles:"grid-area:logo;width:auto;height:50px"}),H=(0,E.A)("div",{target:"e1vmmqn61"})({name:"bxcwlk",styles:"grid-area:details;align-self:stretch;display:flex;flex-direction:column;justify-content:space-between;gap:0.5rem;margin:0.25rem 0"}),$=(0,E.A)(_.Spinner,{target:"e1vmmqn60"})({name:"i3kdum",styles:"grid-area:spinner;margin:0!important;width:32px!important;height:32px!important"});function z({showSpinner:e,isConnected:t}){const{url:r,discovery:o}=(0,s.useSelect)((e=>({url:e(p.STORE_NAME).getWpConnectSiteUrl(),discovery:e(p.STORE_NAME).getWpConnectDiscoveryResult()})),[]),a=(0,F.get)(o,["data","index","home"]),l=(0,F.get)(o,["data","index","name"]),u=(0,F.get)(o,["data","index","_embedded","wp:featuredmedia",0]),d=u&&function(e,t){const r=t.width?"width":"height",n=(0,F.sortBy)(e.media_details.sizes,r);for(const e of n)if(e[r]>t[r])return e;return n.length?(0,F.last)(n):{height:e.media_details.height||t.height,width:e.media_details.width||t.width,source_url:e.source_url}}(u,{width:50}),m=t?(0,i.__)("Connected to %s","it-l10n-ithemes-security-pro"):(0,i.__)("Connecting to %s","it-l10n-ithemes-security-pro");return(0,n.createElement)(B,null,d&&(0,n.createElement)(P,{src:d.source_url,height:d.height,width:d.width,alt:u.alt_text}),(0,n.createElement)(H,null,(0,n.createElement)(c.DZ,{level:3,variant:c.J3.DARK,size:c.$C.NORMAL,text:(0,i.sprintf)(m,a||r)}),l&&(0,n.createElement)(c.EY,{variant:c.J3.MUTED,text:(0,U.decodeEntities)(l)})),e&&(0,n.createElement)($,null))}const j=(0,E.A)(c.$T,{target:"e2t4ciz0"})({name:"nyfdx3",styles:"margin-bottom:3rem"}),{Slot:V,Fill:q}=(0,_.createSlotFill)("ImportExportWordPressConnect");function Y({baseUrl:e}){const{step:t,url:r,discoveredApi:o,isExpired:a,isDeleting:c}=(0,s.useSelect)((e=>({step:e(p.STORE_NAME).getWpConnectStep(),url:e(p.STORE_NAME).getWpConnectSiteUrl(),discoveredApi:e(p.STORE_NAME).getWpConnectDiscoveryResult(),isExpired:e(p.STORE_NAME).areWpConnectCredentialsExpired(),isDeleting:e(p.STORE_NAME).isDeletingWpConnectCredential()})),[]),{wpConnectReset:d,wpConnectEnterWebsite:m,wpConnectDiscoverRestApi:E,wpConnectApplicationApproved:h,wpConnectApplicationRejected:g}=(0,s.useDispatch)(p.STORE_NAME),[f,w]=(0,A.sq)({user_login:A.fr,password:A.fr,site_url:A.fr,success:A.fr});(0,l.useEffect)((()=>{f.site_url&&f.user_login&&f.password?h(f.site_url,{username:f.user_login,password:f.password}):"false"===f.success&&g(),w({},"replace")}),[f,w,h,g]);const x=["enterWebsite","discovering"].includes(t);return(0,n.createElement)(React.Fragment,null,a&&(0,n.createElement)(j,{type:"warning",text:(0,i.__)("Authentication expired. Please reauthorize Solid Security.","it-l10n-ithemes-security-pro")}),(0,n.createElement)(u.OnboardHeader,{title:(0,i.__)("Connect to WordPress","it-l10n-ithemes-security-pro"),description:(0,i.__)("Import from a WordPress site running Solid Security.","it-l10n-ithemes-security-pro")}),(0,n.createElement)(_.Flex,{as:"form",onSubmit:e=>{e.preventDefault(),"enterWebsite"===t&&E(r)},direction:"column",align:"left",gap:8,expanded:!1},(0,n.createElement)(G,{step:t,isExpired:a}),!x&&(0,n.createElement)(z,{showSpinner:"appAuthed"===t,isConnected:"hasSupport"===t}),x&&(0,n.createElement)(J,{url:r,setUrl:m,isDiscovering:"discovering"===t}),(0,n.createElement)(I.e4,{result:o}),(0,n.createElement)(Q,{step:t}),(0,n.createElement)(K,{step:t}),(0,n.createElement)(X,{step:t}),(0,n.createElement)(ee,{step:t}),(0,n.createElement)(Z,{step:t,baseUrl:e,isExpired:a}),(0,n.createElement)(_.Flex,{justify:"start"},!x&&(0,n.createElement)(_.Button,{text:(0,i.__)("Start Again","it-l10n-ithemes-security-pro"),onClick:d,isBusy:c,disabled:c,variant:"secondary"}),(0,n.createElement)(V,null))))}function J({url:e,setUrl:t,isDiscovering:r}){return(0,n.createElement)(React.Fragment,null,(0,n.createElement)(_.TextControl,{type:"url",label:(0,i.__)("WordPress URL","it-l10n-ithemes-security-pro"),value:e,onChange:t,__nextHasNoMarginBottom:!0}),(0,n.createElement)(q,null,(0,n.createElement)(_.Button,{text:(0,i.__)("Connect","it-l10n-ithemes-security-pro"),type:"submit",variant:"primary",isBusy:r,disabled:r})))}function G({step:e,isExpired:t}){const{endpoint:r}=(0,s.useSelect)((e=>({endpoint:e(p.STORE_NAME).getWpConnectAppPasswordsAuthEndpoint()})),[]);if(!["awaitingAuth","appRejected"].includes(e)&&!t)return null;const o=(a=r,(0,C.addQueryArgs)(a,{app_name:(0,i.sprintf)((0,i.__)("Solid Security Import (%1$s) on %2$s","it-l10n-ithemes-security-pro"),window.location.hostname,(0,R.dateI18n)("M j g:i a")),app_id:"0fc6ff2d-d96f-5033-838f-90cc2bf48d9d",success_url:window.location.href}));var a;return(0,n.createElement)(React.Fragment,null,(0,n.createElement)(c.$T,{type:"info",text:(0,n.createElement)(c.EY,null,(0,l.createInterpolateElement)((0,i.__)("<a>Authorize Solid Security</a> to connect to your WordPress site to continue the import process.","it-l10n-ithemes-security-pro"),{a:(0,n.createElement)("a",{href:o})}))}),(0,n.createElement)(q,null,(0,n.createElement)(_.Button,{text:(0,i.__)("Authorize Solid Security","it-l10n-ithemes-security-pro"),href:o,variant:"primary"})))}function X({step:e}){return null}function Z({step:e,baseUrl:t,isExpired:r}){return r||!["appAuthed","hasSupport"].includes(e)?null:(0,n.createElement)(q,null,(0,n.createElement)(a.N_,{to:`${t}/wordpress-select`,component:(0,d.kk)(_.Button),variant:"primary",text:(0,i.__)("Select Export","it-l10n-ithemes-security-pro"),disabled:"appAuthed"===e}))}function Q({step:e}){return"noAppPasswords"===e&&(0,n.createElement)(c.$T,{type:"danger",text:(0,i.__)("The website cannot be connected to because it does not support Application Passwords.","it-l10n-ithemes-security-pro")})}function K({step:e}){return"appRejected"===e&&(0,n.createElement)(c.$T,{type:"danger",text:(0,i.__)("Application was not approved. You must click “I approve of this connection” to continue.","it-l10n-ithemes-security-pro")})}function ee({step:e}){return"noSupport"===e&&(0,n.createElement)(c.$T,{type:"danger",text:(0,i.__)("The website must be running Solid Security 7.1 or later.","it-l10n-ithemes-security-pro")})}function te({allowLax:e=!1}={}){const t=(0,u.useNavigateTo)(),{credentials:r,hasExports:n}=(0,s.useSelect)((e=>({credentials:e(p.STORE_NAME).getWpConnectCredentials(),hasExports:e(p.STORE_NAME).hasWpConnectExports()})),[]);(0,l.useEffect)((()=>{r||n&&e||t("/import/select-export/wordpress-connect")}),[r,n,e,t])}var re=r(50444);const ne=(0,E.A)(re.ExportsList,{target:"e112v7a70"})("border:1px solid ",(({theme:e})=>e.colors.border.normal),";border-top:none;");function oe({baseUrl:e}){te({allowLax:!0});const t=(0,u.useNavigateTo)(),{exports:r,sources:o,isLoading:c}=(0,s.useSelect)((e=>({exports:e(p.STORE_NAME).getWpConnectExports(),sources:e(p.STORE_NAME).getWpConnectSources(),isLoading:!e(p.STORE_NAME).hasFinishedResolution("getWpConnectExports")||!e(p.STORE_NAME).hasFinishedResolution("getWpConnectSources")})),[]),{validateExportData:m}=(0,s.useDispatch)(p.STORE_NAME),[E,h]=(0,l.useState)([]);return(0,n.createElement)(React.Fragment,null,(0,n.createElement)(u.OnboardHeader,{title:(0,i.__)("Pick from WordPress","it-l10n-ithemes-security-pro"),description:(0,i.__)("Select an existing Solid Security export or create a new one.","it-l10n-ithemes-security-pro")}),(0,n.createElement)(_.Flex,{onSubmit:async n=>{n.preventDefault();const o=(0,F.find)(r,{id:E[0]});o&&(await m(o),t(`${e}/summary`))},as:"form",direction:"column",justify:"left",gap:8},(0,n.createElement)(z,{isConnected:!0}),(0,n.createElement)(ne,{exports:r,sources:o,singleSelection:!0,selected:E,setSelected:h,isLoading:c}),(0,n.createElement)(_.Flex,null,(0,n.createElement)(I.g8,null),(0,n.createElement)(a.N_,{to:`${e}/wordpress-create`,component:(0,d.kk)(_.Button),disabled:E.length>0,text:(0,i.__)("Create Export","it-l10n-ithemes-security-pro"),variant:"secondary"}),(0,n.createElement)(_.Button,{disabled:0===E.length,text:(0,i.__)("Select Export","it-l10n-ithemes-security-pro"),variant:"primary",type:"submit"}))))}var ie=r(52238);function ae({baseUrl:e}){te();const t=(0,u.useNavigateTo)(),{sources:r,isCreating:o,result:l}=(0,s.useSelect)((e=>({sources:e(p.STORE_NAME).getWpConnectSources(),isCreating:e(p.STORE_NAME).wpConnectIsCreating(),result:e(p.STORE_NAME).getWpConnectExport()})),[]),{wpConnectCreateExport:c,validateExportData:m}=(0,s.useDispatch)(p.STORE_NAME);return(0,n.createElement)(React.Fragment,null,(0,n.createElement)(u.OnboardHeader,{title:(0,i.__)("Create New Export","it-l10n-ithemes-security-pro")}),(0,n.createElement)(ie.e4,{result:l,hasBorder:!0}),(0,n.createElement)(z,{isConnected:!0}),(0,n.createElement)(re.ExportForm,{sources:r,isCreating:o,createExport:async r=>{const n=await c(r);n.isSuccess()&&(await m(n.data),t(`${e}/summary`))}},(0,n.createElement)(a.N_,{to:e+"/wordpress-select",variant:"secondary",text:(0,i.__)("Select an existing export","it-l10n-ithemes-security-pro"),component:(0,d.kk)(_.Button)})))}const se=(0,E.A)(c.$n,{target:"er91c820"})({name:"135vrw8",styles:"align-self:start"});function le(){const{goNext:e}=(0,u.useNavigation)(),{result:t,data:r,sources:o,selectedSources:a}=(0,s.useSelect)((e=>({result:e(p.STORE_NAME).getImportExportValidationResult(),data:e(p.STORE_NAME).getImportExportData(),sources:e(p.STORE_NAME).getSources(),selectedSources:e(p.STORE_NAME).getImportSources()})),[]),{applyExportData:c,editImportSources:d}=(0,s.useDispatch)(p.STORE_NAME);(0,l.useEffect)((()=>{d(Object.keys(r?.sources||{}))}),[r,d]);const m=o.filter((e=>r?.sources[e.slug])).map((e=>({value:e.slug,label:e.title,help:e.description}))),[E,h]=(0,l.useState)(!1);return(0,n.createElement)(React.Fragment,null,(0,n.createElement)(u.OnboardHeader,{title:(0,i.__)("Export Data","it-l10n-ithemes-security-pro"),description:(0,i.__)("Choose what Solid Security info you’d like to import.","it-l10n-ithemes-security-pro")}),(0,n.createElement)(_.Flex,{direction:"column",justify:"left",gap:6,expanded:!1},(0,n.createElement)(I.e4,{result:t}),r&&(0,n.createElement)(React.Fragment,null,(0,n.createElement)(ie.iI,{hideLabelFromVision:!0,label:(0,i.__)("Export Data","it-l10n-ithemes-security-pro"),value:a,onChange:d,options:m,style:"chicklet"}),a.length>0&&(0,n.createElement)(React.Fragment,null,(0,n.createElement)(L,null),(0,n.createElement)(M,null))),(0,n.createElement)(se,{onClick:async()=>{h(!0),await c(),h(!1),e()},variant:"primary",isBusy:E,disabled:E||!a.length,text:(0,i.__)("Next","it-l10n-ithemes-security-pro")})))}function ce(){return pe(),(0,n.createElement)(React.Fragment,null,(0,n.createElement)(f,null),(0,n.createElement)(u.OnboardSiteTypeBeforeFill,null,(0,n.createElement)(ue,null)))}function ue(){return(0,n.createElement)(c.$T,{text:(0,n.createElement)(c.EY,null,(0,l.createInterpolateElement)((0,i.__)("Do you have Security settings you’d like to import? You can import settings from a WordPress site running Solid Security or an export file you downloaded. <a>Click here to import settings</a>.","it-l10n-ithemes-security-pro"),{a:(0,n.createElement)(a.N_,{to:"/import"})}))})}function pe(){const{registerCompletionStep:e}=(0,s.useDispatch)(u.ONBOARD_STORE_NAME),{completeImport:t,resetImport:r,wpConnectReset:n}=(0,s.useDispatch)(p.STORE_NAME);(0,d.ee)(pe,(()=>{e({id:"import",label:(0,i.__)("Complete Import","it-l10n-ithemes-security-pro"),priority:100,activeCallback:({root:e})=>"import"===e,async callback(){const e=await t();if(e.type!==m.Q7.SUCCESS)throw{code:e.error.getErrorCode(),message:e.error.getAllErrorMessages().join(" ")};await r(),await n()}})}))}r.p=window.itsecWebpackPublicPath,(0,i.setLocaleData)({"":{}},"ithemes-security-pro"),(0,o.registerPlugin)("itsec-import-export-settings",{render:()=>(0,n.createElement)(ce,null)})},66087:e=>{"use strict";e.exports=window.lodash},70404:(e,t,r)=>{"use strict";function n(e){return"object"==typeof e&&null!=e&&1===e.nodeType}function o(e,t){return(!t||"hidden"!==e)&&"visible"!==e&&"clip"!==e}function i(e,t){if(e.clientHeight<e.scrollHeight||e.clientWidth<e.scrollWidth){var r=getComputedStyle(e,null);return o(r.overflowY,t)||o(r.overflowX,t)||function(e){var t=function(e){if(!e.ownerDocument||!e.ownerDocument.defaultView)return null;try{return e.ownerDocument.defaultView.frameElement}catch(e){return null}}(e);return!!t&&(t.clientHeight<e.scrollHeight||t.clientWidth<e.scrollWidth)}(e)}return!1}function a(e,t,r,n,o,i,a,s){return i<e&&a>t||i>e&&a<t?0:i<=e&&s<=r||a>=t&&s>=r?i-e-n:a>t&&s<r||i<e&&s>r?a-t+o:0}r.d(t,{A:()=>c});var s=function(e,t){var r=window,o=t.scrollMode,s=t.block,l=t.inline,c=t.boundary,u=t.skipOverflowHiddenElements,p="function"==typeof c?c:function(e){return e!==c};if(!n(e))throw new TypeError("Invalid target");for(var d,m,E=document.scrollingElement||document.documentElement,h=[],g=e;n(g)&&p(g);){if((g=null==(m=(d=g).parentElement)?d.getRootNode().host||null:m)===E){h.push(g);break}null!=g&&g===document.body&&i(g)&&!i(document.documentElement)||null!=g&&i(g,u)&&h.push(g)}for(var f=r.visualViewport?r.visualViewport.width:innerWidth,w=r.visualViewport?r.visualViewport.height:innerHeight,x=window.scrollX||pageXOffset,_=window.scrollY||pageYOffset,v=e.getBoundingClientRect(),S=v.height,y=v.width,b=v.top,O=v.right,N=v.bottom,A=v.left,C="start"===s||"nearest"===s?b:"end"===s?N:b+S/2,R="center"===l?A+y/2:"end"===l?O:A,I=[],T=0;T<h.length;T++){var M=h[T],L=M.getBoundingClientRect(),W=L.height,D=L.width,k=L.top,F=L.right,U=L.bottom,B=L.left;if("if-needed"===o&&b>=0&&A>=0&&N<=w&&O<=f&&b>=k&&N<=U&&A>=B&&O<=F)return I;var P=getComputedStyle(M),H=parseInt(P.borderLeftWidth,10),$=parseInt(P.borderTopWidth,10),z=parseInt(P.borderRightWidth,10),j=parseInt(P.borderBottomWidth,10),V=0,q=0,Y="offsetWidth"in M?M.offsetWidth-M.clientWidth-H-z:0,J="offsetHeight"in M?M.offsetHeight-M.clientHeight-$-j:0,G="offsetWidth"in M?0===M.offsetWidth?0:D/M.offsetWidth:0,X="offsetHeight"in M?0===M.offsetHeight?0:W/M.offsetHeight:0;if(E===M)V="start"===s?C:"end"===s?C-w:"nearest"===s?a(_,_+w,w,$,j,_+C,_+C+S,S):C-w/2,q="start"===l?R:"center"===l?R-f/2:"end"===l?R-f:a(x,x+f,f,H,z,x+R,x+R+y,y),V=Math.max(0,V+_),q=Math.max(0,q+x);else{V="start"===s?C-k-$:"end"===s?C-U+j+J:"nearest"===s?a(k,U,W,$,j+J,C,C+S,S):C-(k+W/2)+J/2,q="start"===l?R-B-H:"center"===l?R-(B+D/2)+Y/2:"end"===l?R-F+z+Y:a(B,F,D,H,z+Y,R,R+y,y);var Z=M.scrollLeft,Q=M.scrollTop;C+=Q-(V=Math.max(0,Math.min(Q+V/X,M.scrollHeight-W/X+J))),R+=Z-(q=Math.max(0,Math.min(Z+q/G,M.scrollWidth-D/G+Y)))}I.push({el:M,top:V,left:q})}return I};function l(e){return e===Object(e)&&0!==Object.keys(e).length}const c=function(e,t){var r=e.isConnected||e.ownerDocument.documentElement.contains(e);if(l(t)&&"function"==typeof t.behavior)return t.behavior(r?s(e,t):[]);if(r){var n=function(e){return!1===e?{block:"end",inline:"nearest"}:l(e)?e:{block:"start",inline:"nearest"}}(t);return function(e,t){void 0===t&&(t="auto");var r="scrollBehavior"in document.body.style;e.forEach((function(e){var n=e.el,o=e.top,i=e.left;n.scroll&&r?n.scroll({top:o,left:i,behavior:t}):(n.scrollTop=o,n.scrollLeft=i)}))}(s(e,n),n.behavior)}}},74596:(e,t,r)=>{"use strict";r.d(t,{A:()=>i});var n=r(51609),o=r(55933);const i=(0,n.createElement)(o.SVG,{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24"},(0,n.createElement)(o.Path,{d:"M7 11.5h10V13H7z"}))},75795:e=>{"use strict";e.exports=window.ReactDOM},76154:e=>{"use strict";e.exports=window.moment},77172:e=>{e.exports=function(){return this.wp.url}()},79860:e=>{e.exports=function(){return this.wp.keycodes}()},85631:e=>{e.exports=function(){return this.wp.apiFetch}()},89897:e=>{e.exports=function(){return this.wp.compose}()},89959:e=>{e.exports=function(){return this.wp.date}()}},e=>{e.O(0,[9427,3390,2038,3733,8363,1645,2932,3520,7926,2238],(()=>e(e.s=63703)));var t=e.O();((window.itsec=window.itsec||{})["import-export"]=window.itsec["import-export"]||{}).settings=t}]);
Save File
Cancel