import{u as _,i as w,S as v,w as D,j as C,h as x,T as y,bw as A,aE as P,c as b,d as T,m as e,c1 as H,g as k,o as E}from"./BfF8i_OD.js";const F={class:"ebm-content-page"},B={__name:"ContentPage",async setup(N){let t,l;const{$page:d,$gql:h}=_(),{fullPath:p,query:a,path:u}=w(),f=P(),c=v({}),{data:o}=([t,l]=D(()=>H("page",()=>d.getPage())),t=await t,l(),t);if(!o.value)throw C({statusCode:404,statusMessage:"Page Not Found",fatal:!0});c.value={...o.value,pageData:{...o.value.pageData,scroll:{parent:o.value.pageData.id,index:0},route:{fullPath:p,query:a,path:u}}};const s=c.value,n=x("cacheAge",()=>new Date().getTime());return y(async()=>{await A.getUserInfo(),f.public.isDev||(console.log("🚀 cacheAge:",(new Date().getTime()-n.value)/1e3),console.log("clear Cache?: ",new Date().getTime()-n.value>6e5),new Date().getTime()-n.value>6e5&&h.mutate("crawlWebsiteLayoutCacheLock",{input:{aliases:[u],host:window.location.hostname}}))}),(S,W)=>{var i,r,g;const m=k;return E(),b("div",F,[T(m,{page:e(s),"include-header":e(a).includeHeader!=="false"&&((i=e(s))==null?void 0:i.hideHeader)!==!0,"include-footer":e(a).includeFooter!=="false"&&((r=e(s))==null?void 0:r.hideFooter)!==!0,"full-height":e(a).fullHeight!=="false","full-width":e(a).fullWidth==="true"||((g=e(s))==null?void 0:g.hideHeader),"preview-mode":e(a)["preview-mode"]},null,8,["page","include-header","include-footer","full-height","full-width","preview-mode"])])}}};export{B as default};