import{_ as c,o as p,c as i,C as u,r as d,Q as s,a5 as l,a6 as _,a7 as f,a8 as m,a9 as h,aa as v,ab as A,ac as g,ad as C,ae as y,M as P,d as w,u as x,k as E,q as R,af as b,ag as D,ah as H,ai as S}from"./chunks/framework.b31a4d00.js";import{t as T}from"./chunks/theme.9e72a8a7.js";const V={},B={class:"VPFeatures"},F={class:"vp-doc fes-home container"};function O(e,t){return p(),i("div",B,[u("div",F,[d(e.$slots,"default",{},void 0,!0)])])}const $=c(V,[["render",O],["__scopeId","data-v-0d1d9f22"]]);const j={extends:T,enhanceApp(e){e.app.component("HomeContent",$)}};function r(e){if(e.extends){const t=r(e.extends);return{...t,...e,async enhanceApp(a){t.enhanceApp&&await t.enhanceApp(a),e.enhanceApp&&await e.enhanceApp(a)}}}return e}const n=r(j),k=w({name:"VitePressApp",setup(){const{site:e}=x();return E(()=>{R(()=>{document.documentElement.lang=e.value.lang,document.documentElement.dir=e.value.dir})}),b(),D(),H(),n.setup&&n.setup(),()=>S(n.Layout)}});async function I(){const e=M(),t=L();t.provide(_,e);const a=f(e.route);return t.provide(m,a),t.component("Content",h),t.component("ClientOnly",v),Object.defineProperties(t.config.globalProperties,{$frontmatter:{get(){return a.frontmatter.value}},$params:{get(){return a.page.value.params}}}),n.enhanceApp&&await n.enhanceApp({app:t,router:e,siteData:A}),{app:t,router:e,data:a}}function L(){return g(k)}function M(){let e=s,t;return C(a=>{let o=y(a);return e&&(t=o),(e||t===o)&&(o=o.replace(/\.js$/,".lean.js")),s&&(e=!1),P(()=>import(o),[])},n.NotFound)}s&&I().then(({app:e,router:t,data:a})=>{t.go().then(()=>{l(t.route,a.site),e.mount("#app")})});export{I as createApp};