관리-도구
편집 파일: Import.cujkmhug.js
import{u as P,h as B,r as L}from"./index.nsvc8vqf.js";import{g as m}from"./helpers.fdpg7vgg.js";import{u as N}from"./Wizard.k83dkx8n.js";import{B as E}from"./HighlightToggle.n7i6u2ep.js";import{G,a as H}from"./Row.o0q8mn7y.js";import{W as U,a as O,b as R}from"./Header.dy1nr3gs.js";import{W as T}from"./CloseAndExit.fogssdp0.js";import{_ as F}from"./Steps.mseeto7k.js";import"./translations.lf9cwm9a.js";import{_ as J}from"./_plugin-vue_export-helper.oebm7xum.js";import{_ as h,a as M}from"./default-i18n.hohxoesu.js";import{v as s,c as g,C as t,l as r,o as u,a as p,x as l,t as c,F as j,J as q,k as K,G as Q,b as k}from"./runtime-dom.esm-bundler.h3clfjuw.js";import"./addons.foby19s7.js";import"./upperFirst.mzmrvvb6.js";import"./_stringToArray.mpukyt2g.js";import"./toString.g0kcp64r.js";import"./Checkbox.fww0datn.js";import"./Checkmark.d5kkjaf5.js";import"./Radio.flou2v5o.js";import"./Logo.nueehhao.js";import"./Index.fywmukpg.js";import"./Caret.hnvbzqgq.js";const w=""+window.__aioseoDynamicImportPreload__("images/yoast-logo-small.ftz730wa.png"),X=""+window.__aioseoDynamicImportPreload__("images/rank-math-seo-logo-small.i99e3sdy.png"),Y=""+window.__aioseoDynamicImportPreload__("svg/seopress-free-logo-small.ds3g8yrk.svg"),Z=""+window.__aioseoDynamicImportPreload__("svg/seopress-pro-logo-small.n503xkgm.svg"),f="all-in-one-seo-pack",$={setup(){const{strings:e}=N({stage:"import"});return{composableStrings:e,rootStore:P(),setupWizardStore:B()}},components:{BaseHighlightToggle:E,GridColumn:G,GridRow:H,WizardBody:U,WizardCloseAndExit:T,WizardContainer:O,WizardHeader:R,WizardSteps:F},data(){return{loading:!1,strings:L(this.composableStrings,{importData:h("Import data from your current plugins",f),weHaveDetected:M(h("We have detected other SEO plugins installed on your website. Select which plugins you would like to import data to %1$s.",f),"AIOSEO"),importDataAndContinue:h("Import Data and Continue",f)}),pluginImages:{"yoast-seo":m(w),"yoast-seo-premium":m(w),"rank-math-seo":m(X),seopress:m(Y),"seopress-pro":m(Z)},selected:[]}},watch:{selected(e){this.setupWizardStore.importers=e.map(a=>a.slug)}},computed:{getPlugins(){return this.rootStore.aioseo.importers.filter(e=>e.canImport)}},methods:{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.setupWizardStore.saveWizard("importers").then(()=>{this.$router.push(this.setupWizardStore.getNextLink)})},skipStep(){this.setupWizardStore.saveWizard(),this.$router.push(this.setupWizardStore.getNextLink)}}},ee={class:"aioseo-wizard-import"},te={class:"header"},oe={class:"description"},se={class:"plugins"},re=["alt","src"],ne={key:1,class:"icon dashicons dashicons-admin-plugins"},ae={class:"go-back"},ie=p("div",{class:"spacer"},null,-1);function le(e,a,d,_,n,i){const v=s("wizard-header"),S=s("wizard-steps"),x=s("base-highlight-toggle"),I=s("grid-column"),W=s("grid-row"),y=s("router-link"),z=s("base-button"),C=s("wizard-body"),b=s("wizard-close-and-exit"),A=s("wizard-container");return u(),g("div",ee,[t(v),t(A,null,{default:r(()=>[t(C,null,{footer:r(()=>[p("div",ae,[t(y,{to:_.setupWizardStore.getPrevLink,class:"no-underline"},{default:r(()=>[l("←")]),_:1},8,["to"]),l(" "),t(y,{to:_.setupWizardStore.getPrevLink},{default:r(()=>[l(c(n.strings.goBack),1)]),_:1},8,["to"])]),ie,t(z,{type:"gray",onClick:i.skipStep},{default:r(()=>[l(c(n.strings.skipThisStep),1)]),_:1},8,["onClick"]),t(z,{type:"blue",loading:n.loading,onClick:i.saveAndContinue},{default:r(()=>[l(c(n.strings.importDataAndContinue)+" →",1)]),_:1},8,["loading","onClick"])]),default:r(()=>[t(S),p("div",te,c(n.strings.importData),1),p("div",oe,c(n.strings.weHaveDetected),1),p("div",se,[t(W,null,{default:r(()=>[(u(!0),g(j,null,q(i.getPlugins,(o,D)=>(u(),K(I,{key:D,md:"6"},{default:r(()=>[t(x,{type:"checkbox",size:"medium",round:"",active:i.isActive(o),name:o.name,modelValue:i.getValue(o),"onUpdate:modelValue":V=>i.updateValue(V,o)},{default:r(()=>[n.pluginImages[o.slug]?(u(),g("img",{key:0,alt:o.name+" Plugin Icon",src:n.pluginImages[o.slug],class:Q(["icon",o.slug])},null,10,re)):k("",!0),n.pluginImages[o.slug]?k("",!0):(u(),g("span",ne)),l(" "+c(o.name),1)]),_:2},1032,["active","name","modelValue","onUpdate:modelValue"])]),_:2},1024))),128))]),_:1})])]),_:1}),t(b)]),_:1})])}const Ve=J($,[["render",le]]);export{Ve as default};