import{a as V}from"./WpTable.8adff4c1.js";import"./default-i18n.ab92175e.js";import"./constants.e9426d11.js";import{_ as W,c as u,d as t,w as o,r as i,o as m,f as p,e as l,t as c,F as P,i as S,h as B,n as U,a as f}from"./_plugin-vue_export-helper.2d9794a3.js";import"./index.02a5ed9a.js";import"./SaveChanges.bc66cd69.js";import{b as L,m as N}from"./vuex.esm-bundler.8589b2dd.js";import{B as $}from"./HighlightToggle.9350ac53.js";import{G as E,a as H}from"./Row.5e452de4.js";import{W as G,a as O,b as T}from"./Header.34c3e402.js";import{W as F,a as M}from"./Steps.7d2bf1be.js";import"./helpers.de7566d0.js";import"./RequiresUpdate.52f5acf2.js";import"./postContent.741ce73c.js";import"./Caret.42a820e0.js";import"./cleanForSlug.1898a430.js";import"./isArrayLikeObject.c492f682.js";import"./html.14f2a8b9.js";import"./Index.1fd8fc42.js";import"./_commonjsHelpers.f84db168.js";import"./Checkbox.b4e8b6fc.js";import"./Checkmark.c5326878.js";import"./Radio.4c468d8a.js";import"./Logo.81e1a7f3.js";const w=""+window.__aioseoDynamicImportPreload__("images/yoast-logo-small.d61ba0ec.png"),R=""+window.__aioseoDynamicImportPreload__("images/rank-math-seo-logo-small.ca2c09ed.png"),j=""+window.__aioseoDynamicImportPreload__("svg/seopress-free-logo-small.ac91e892.svg"),q=""+window.__aioseoDynamicImportPreload__("svg/seopress-pro-logo-small.6e7e5cab.svg");const J={components:{BaseHighlightToggle:$,GridColumn:E,GridRow:H,WizardBody:G,WizardCloseAndExit:F,WizardContainer:O,WizardHeader:T,WizardSteps:M},mixins:[V],data(){return{loading:!1,stage:"import",strings:{importData:this.$t.__("Import data from your current plugins",this.$td),weHaveDetected:this.$t.sprintf(this.$t.__("We have detected other SEO plugins installed on your website. Select which plugins you would like to import data to %1$s.",this.$td),"AIOSEO"),importDataAndContinue:this.$t.__("Import Data and Continue",this.$td)},pluginImages:{"yoast-seo":this.$getAssetUrl(w),"yoast-seo-premium":this.$getAssetUrl(w),"rank-math-seo":this.$getAssetUrl(R),seopress:this.$getAssetUrl(j),"seopress-pro":this.$getAssetUrl(q)},selected:[]}},watch:{selected(e){this.updateImporters(e.map(a=>a.slug))}},computed:{getPlugins(){return this.$aioseo.importers.filter(e=>e.canImport)}},methods:{...L("wizard",["updateImporters"]),...N("wizard",["saveWizard"]),updateValue(e,a){if(e){this.selected.push(a);return}const d=this.selected.findIndex(_=>_.value===a.value);d!==-1&&this.selected.splice(d,1)},getValue(e){return this.selected.includes(e)},isActive(e){return this.selected.findIndex(d=>d.slug===e.slug)!==-1},saveAndContinue(){this.loading=!0,this.saveWizard("importers").then(()=>{this.$router.push(this.getNextLink)})},skipStep(){this.saveWizard(),this.$router.push(this.getNextLink)}}},K={class:"aioseo-wizard-import"},Q={class:"header"},X={class:"description"},Y={class:"plugins"},Z=["alt","src"],ee={key:1,class:"icon dashicons dashicons-admin-plugins"},te={class:"go-back"},se=p("div",{class:"spacer"},null,-1);function oe(e,a,d,_,n,r){const y=i("wizard-header"),v=i("wizard-steps"),k=i("base-highlight-toggle"),z=i("grid-column"),I=i("grid-row"),g=i("router-link"),h=i("base-button"),x=i("wizard-body"),A=i("wizard-close-and-exit"),b=i("wizard-container");return m(),u("div",K,[t(y),t(b,null,{default:o(()=>[t(x,null,{footer:o(()=>[p("div",te,[t(g,{to:e.getPrevLink,class:"no-underline"},{default:o(()=>[l("←")]),_:1},8,["to"]),l("   "),t(g,{to:e.getPrevLink},{default:o(()=>[l(c(n.strings.goBack),1)]),_:1},8,["to"])]),se,t(h,{type:"gray",onClick:r.skipStep},{default:o(()=>[l(c(n.strings.skipThisStep),1)]),_:1},8,["onClick"]),t(h,{type:"blue",loading:n.loading,onClick:r.saveAndContinue},{default:o(()=>[l(c(n.strings.importDataAndContinue)+" →",1)]),_:1},8,["loading","onClick"])]),default:o(()=>[t(v),p("div",Q,c(n.strings.importData),1),p("div",X,c(n.strings.weHaveDetected),1),p("div",Y,[t(I,null,{default:o(()=>[(m(!0),u(P,null,S(r.getPlugins,(s,C)=>(m(),B(z,{key:C,md:"6"},{default:o(()=>[t(k,{type:"checkbox",size:"medium",round:"",active:r.isActive(s),name:s.name,modelValue:r.getValue(s),"onUpdate:modelValue":D=>r.updateValue(D,s)},{default:o(()=>[n.pluginImages[s.slug]?(m(),u("img",{key:0,alt:s.name+" Plugin Icon",src:n.pluginImages[s.slug],class:U(["icon",s.slug])},null,10,Z)):f("",!0),n.pluginImages[s.slug]?f("",!0):(m(),u("span",ee)),l(" "+c(s.name),1)]),_:2},1032,["active","name","modelValue","onUpdate:modelValue"])]),_:2},1024))),128))]),_:1})])]),_:1}),t(A)]),_:1})])}const De=W(J,[["render",oe]]);export{De as default};
