import{aq as d,aw as f}from"./vendor-vue-ui.02763c14.js";import{b as y,D as _,l as w,B as h}from"./app-core.82d0a9b8.js";const c=(t,r,n)=>{const e=r[n];return e?()=>{const a=c(t,r,n+1);e({...t,next:a})}:t.next},x=(t,r)=>{const n=d({history:f(`wp-admin/admin.php?page=aioseo-${window.aioseo.page}`),routes:t,scrollBehavior(e,a,o){return o||(e.hash?{selector:e.hash}:{left:0,top:0})}});return n.beforeEach((e,a,o)=>{const s=y(),l=_();s.loaded||w(r),s.ping();const m=e.meta.access;if(!h(m))return e.meta.home!==a.name?n.replace({name:e.meta.home}):null;if(e.meta.middleware){const i=Array.isArray(e.meta.middleware)?e.meta.middleware:[e.meta.middleware],u={app:r,from:a,next:o,router:n,to:e},p=c(u,i,1);return i[0]({...u,next:p})}return l.resetPageNumbers(),o()}),n},v=(t,r,n)=>{const e=t[r];return e?typeof e=="function"?e():Promise.resolve(e):new Promise((a,o)=>{(typeof queueMicrotask=="function"?queueMicrotask:setTimeout)(o.bind(null,new Error("Unknown variable dynamic import: "+r+(r.split("/").length!==n?". Note that variables only represent file names one level deep.":""))))})};export{v as _,x as s};
