Файловый менеджер - Редактировать - /home/beautybuzzbeyond/public_html/wp-content/plugins/all-in-one-seo-pack/dist/Lite/assets/js/WpCode.f13a175c.js
Назад
import{t as b,w as k,l as x,x as U}from"./index.5a710757.js";import{C as A}from"./Index.c0a0a208.js";import{C as L}from"./Caret.662da1f3.js";import{G as W,a as O}from"./Row.f01f32cd.js";import"./translations.12335a6a.js";import{_ as I}from"./_plugin-vue_export-helper.249dac1d.js";import{_ as e}from"./default-i18n.54b5d8cd.js";import{c as _,a as l,C as E,l as i,G as N,k as c,b as f,v as d,o as p,F as B,J as T,t as s,x as u}from"./runtime-dom.esm-bundler.6789c400.js";import"./helpers.f95d5840.js";import"./constants.2019bcb3.js";const t="all-in-one-seo-pack",D={setup(){return{pluginsStore:b(),wpCodeStore:k(),links:x}},components:{Cta:A,CoreAlert:L,GridColumn:W,GridRow:O},data(){return{loadingUseSnippet:null,failed:!1,activationLoading:!1,strings:{codesnippets:e("Code Snippets",t),installSnippet:e("Use Snippet",t),editSnippet:e("Edit Snippet",t),ctaDescription:e("Using WPCode you can install AIOSEO code snippets with 1-click directly from this page or the WPCode library inside the WordPress admin.",t),ctaLearnMoreText:e("Learn More about WPCode Snippets",t),noSnippets:e("We encountered an error loading the code snippets, please try again later.",t),activateError:e("An error occurred while activating the addon. Please upload it manually or contact support for more information.",t),permissionWarning:e("You currently don't have permission to activate this addon. Please ask a site administrator to activate first.",t)}}},computed:{showSnippets(){return this.wpCodeStore.pluginInstalled&&this.wpCodeStore.pluginActive&&!this.wpCodeStore.pluginNeedsUpdate},blurClass(){return this.showSnippets?"":"aioseo-blur"},ctaTitle(){if(this.wpCodeStore.pluginNeedsUpdate)return e("Please Update WPCode to load the AIOSEO Snippet Library",t);if(this.wpCodeStore.pluginInstalled){if(!this.wpCodeStore.pluginActive)return e("Please Activate WPCode to load the AIOSEO Snippet Library",t)}else return e("Please Install WPCode to load the AIOSEO Snippet Library",t);return e("Please Install WPCode to load the AIOSEO Snippet Library",t)},ctaButtonText(){if(this.wpCodeStore.pluginNeedsUpdate)return e("Update WPCode",t);if(this.wpCodeStore.pluginInstalled){if(!this.wpCodeStore.pluginActive)return e("Activate WPCode",t)}else return e("Install WPCode",t);return e("Install WPCode",t)}},methods:{decode:U.decode,processUpdateOrActivate(){this.activateOrUpdate(this.wpCodeStore.pluginNeedsUpdate)},activateOrUpdate(g=!1){this.failed=!1,this.activationLoading=!0;const m=g?"upgradePlugins":"installPlugins",a=this.pluginsStore.plugins.wpcodePro.installed?"wpcodePro":"wpcode";this.pluginsStore[m]([{plugin:a,type:"plugin"}]).then(o=>{if(o.body.failed.length){this.activationLoading=!1,this.failed=!0;return}const n=[this.wpCodeStore.loadSnippets()];Promise.all(n).then(()=>{this.activationLoading=!1})}).catch(o=>{this.activationLoading=!1,this.failed=!0,console.error(`Unable to install ${a}: ${o}`)})}}},G={class:"aioseo-tools-wpcode"},V={class:"aioseo-wpcode-snippet"},z={class:"wpcode-snippet-body"},M={class:"snippet-title"},F={class:"snippet-description"},R={class:"wpcode-snippet-footer"};function J(g,m,S,a,o,n){const h=d("base-button"),C=d("grid-column"),w=d("grid-row"),v=d("cta"),y=d("core-alert");return p(),_("div",G,[l("div",{class:N(n.blurClass)},[E(w,null,{default:i(()=>[(p(!0),_(B,null,T(a.wpCodeStore.snippets,(r,P)=>(p(),c(C,{key:P,sm:"12",md:"6",lg:"4"},{default:i(()=>[l("div",V,[l("div",z,[l("div",M,s(r.title),1),l("div",F,s(r.note),1)]),l("div",R,[r.install?(p(),c(h,{key:0,type:"blue",size:"medium",tag:"a",href:n.decode(r.install),onClick:Y=>o.loadingUseSnippet=r.install,loading:r.install===o.loadingUseSnippet},{default:i(()=>[u(s(r.installed?o.strings.editSnippet:o.strings.installSnippet),1)]),_:2},1032,["href","onClick","loading"])):(p(),c(h,{key:1,type:"gray",size:"medium",disabled:""},{default:i(()=>[u(s(o.strings.installSnippet),1)]),_:1}))])])]),_:2},1024))),128))]),_:1})],2),!n.showSnippets&&a.wpCodeStore.snippets.length?(p(),c(v,{key:0,"button-text":n.ctaButtonText,"learn-more-link":a.links.getDocUrl("wpcode"),"cta-button-loading":o.activationLoading,onCtaButtonClick:n.processUpdateOrActivate,"same-tab":"","align-top":"","cta-button-action":"","hide-bonus":""},{"header-text":i(()=>[u(s(n.ctaTitle),1)]),description:i(()=>[u(s(o.strings.ctaDescription),1)]),"learn-more-text":i(()=>[u(s(o.strings.ctaLearnMoreText),1)]),_:1},8,["button-text","learn-more-link","cta-button-loading","onCtaButtonClick"])):f("",!0),n.showSnippets&&a.wpCodeStore.snippets.length===0?(p(),c(y,{key:1,type:"yellow"},{default:i(()=>[l("div",null,s(o.strings.noSnippets),1)]),_:1})):f("",!0)])}const oe=I(D,[["render",J]]);export{oe as default};
| ver. 1.4 |
Github
|
.
| PHP 8.0.30 | Генерация страницы: 0 |
proxy
|
phpinfo
|
Настройка