@vuebro/runtime 1.4.0 → 1.4.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1 +1 @@
1
- {"_markdown-CKwXX3x9.js":{"file":"assets/markdown-CKwXX3x9.js","name":"markdown","imports":["_mermaid-BQWZaxT1.js"]},"_mermaid-BQWZaxT1.js":{"file":"assets/mermaid-BQWZaxT1.js","name":"mermaid"},"_shared-YQYTrUrb.js":{"file":"assets/shared-YQYTrUrb.js","name":"shared","isDynamicEntry":true,"imports":["_markdown-CKwXX3x9.js"]},"index.html":{"file":"assets/index-BNJGgvBA.js","name":"index","src":"index.html","isEntry":true,"imports":["_shared-YQYTrUrb.js","_markdown-CKwXX3x9.js","_mermaid-BQWZaxT1.js"],"dynamicImports":["_shared-YQYTrUrb.js","_shared-YQYTrUrb.js"],"css":["assets/index-vGiKZPT9.css"]},"node_modules/vue/dist/vue.esm-browser.prod.js":{"file":"assets/vue.esm-browser.prod-3.5.25.js","isStaticEntry":true,"name":"vue"},"node_modules/vue-router/dist/vue-router.esm-browser.prod.js":{"file":"assets/vue-router.esm-browser.prod-4.6.3.js","isStaticEntry":true,"name":"vue-router"},"node_modules/@vuebro/loader-sfc/dist/loader-sfc.esm-browser.prod.js":{"file":"assets/loader-sfc.esm-browser.prod-2.4.0.js","isStaticEntry":true,"name":"@vuebro/loader-sfc"}}
1
+ {"_markdown-CKwXX3x9.js":{"file":"assets/markdown-CKwXX3x9.js","name":"markdown","imports":["_mermaid-BQWZaxT1.js"]},"_mermaid-BQWZaxT1.js":{"file":"assets/mermaid-BQWZaxT1.js","name":"mermaid"},"_shared-YQYTrUrb.js":{"file":"assets/shared-YQYTrUrb.js","name":"shared","isDynamicEntry":true,"imports":["_markdown-CKwXX3x9.js"]},"index.html":{"file":"assets/index-BtArdxd1.js","name":"index","src":"index.html","isEntry":true,"imports":["_shared-YQYTrUrb.js","_markdown-CKwXX3x9.js","_mermaid-BQWZaxT1.js"],"dynamicImports":["_shared-YQYTrUrb.js","_shared-YQYTrUrb.js"],"css":["assets/index-vGiKZPT9.css"]},"node_modules/vue/dist/vue.esm-browser.prod.js":{"file":"assets/vue.esm-browser.prod-3.5.25.js","isStaticEntry":true,"name":"vue"},"node_modules/vue-router/dist/vue-router.esm-browser.prod.js":{"file":"assets/vue-router.esm-browser.prod-4.6.3.js","isStaticEntry":true,"name":"vue-router"},"node_modules/@vuebro/loader-sfc/dist/loader-sfc.esm-browser.prod.js":{"file":"assets/loader-sfc.esm-browser.prod-2.4.1.js","isStaticEntry":true,"name":"@vuebro/loader-sfc"}}
@@ -418,4 +418,4 @@ ${e.sfcBlocks?.script?.content??""}
418
418
  ${e.sfcBlocks?.scriptSetup?.content??""}
419
419
  ${e.sfcBlocks?.styles.map(({content:n})=>n).join(`
420
420
  `)??""}
421
- `,{scriptOptions:{inlineTemplate:!0}}))};function Ao(t,e){const n=t.type,r=n==="html"?"htmlAttrs":n==="body"?"bodyAttrs":n;if(typeof r!="string"||!(r in e))return;const o=t.props||{};if(t.children){const i="children";o.children=Array.isArray(t.children)?t.children[0][i]:t[i]}Array.isArray(e[r])?e[r].push(o):r==="title"?e.title=o.children:e[r]=o}function Km(t){const e={title:void 0,htmlAttrs:void 0,bodyAttrs:void 0,base:void 0,meta:[],link:[],style:[],script:[],noscript:[]};for(const n of t)if(typeof n.type=="symbol"&&Array.isArray(n.children))for(const r of n.children)Ao(r,e);else Ao(n,e);return e}const Gm=Wt({name:"Head",setup(t,{slots:e}){const n=wt({}),r=Un(n);return Po(()=>{r.dispose()}),()=>(We(()=>{e.default&&r.patch(Km(e.default()))}),null)}}),Ym=Wt({__name:"NotFoundView",setup(t){return(e,n)=>(gt(),Oe(Ro,null,[$s(_t(Gm),null,{default:Nn(()=>[...n[0]||(n[0]=[qt("title",null,"Page Not Found",-1)])]),_:1}),n[1]||(n[1]=qt("div",{class:"absolute inset-0 grid place-items-center"},[qt("div",{class:"text-center"},[qt("div",{class:"text-9xl"},"404"),qt("p",null,"Oops. Nothing here...")])],-1))],64))}}),Xm={mounted(t,e){if(typeof e.value=="function"){const n=e.value;bt(mo(t),r=>n(r),{immediate:!0})}else{const[n,r]=e.value;bt(mo(t,r),o=>n(o),{immediate:!0})}}};function Zm(){let t=!1;const e=mt(!1);return(n,r)=>{if(e.value=r.value,t)return;t=!0;const o=Wh(n,r.value);bt(e,i=>o.value=i)}}Zm();const Qm=["id"],Jm=Wt({__name:"PageView",setup(t){const e=Q(et,"$these"),n=Q(Dt,"kvNodes"),{intersecting:r,promises:o}=et,i=()=>{[r,o].forEach(a=>{a.clear()})},s=G(()=>new Map(e.value.map(({id:a})=>[a,ls(a)])));return We(()=>{i(),e.value.forEach(({id:a})=>{r.set(a,!1),o.set(a,as())})}),Lo(()=>{i()}),(a,l)=>(gt(!0),Oe(Ro,null,xs(s.value,([c,f])=>Ss((gt(),Oe("div",{id:c,key:c,class:Fo(n.value[c]?.class),"un-cloak":""},[(gt(),ce(Vn(f),{id:c,onVnodeMounted:d=>_t(o).get(c)?.resolve(void 0)},null,8,["id","onVnodeMounted"]))],10,Qm)),[[_t(Xm),[d=>{_t(r).set(c,d)},{threshold:.1}]]])),128))}}),t0=["id"],e0=Wt({__name:"RootView",setup(t){const e=Q(Dt,"nodes"),{root:n}=et,r=G(()=>e.value[0]&&ls(e.value[0].id));return(o,i)=>(gt(),ce(Cs,null,{default:Nn(()=>[e.value[0]?.enabled?(gt(),Oe("div",{key:0,id:e.value[0].id,class:Fo(e.value[0].class),"un-cloak":""},[(gt(),ce(Vn(r.value),{id:e.value[0].id,onVnodeMounted:i[0]||(i[0]=s=>_t(n).resolve(void 0))},null,8,["id"]))],10,t0)):Es("",!0)]),_:1}))}});let Oo=Q(et,"routeName");const cs=De(et),n0=Q(cs,"$these"),r0=Q(cs,"that"),us=De(Dt),o0=Q(us,"kvNodes"),Mo=Q(us,"nodes"),[i0,s0]=(await Promise.all(["index","fonts"].map(t=>Wn(`${t}.json`)))).map(t=>t??[]),fs=js(Dm),{intersecting:a0,promises:l0,root:c0}=et,{pathname:u0}=new URL(document.baseURI);Io.info("👊 VueBro / https://github.com/vuebro / runtime ver.:","1.4.0");Dt.tree=i0;await sl({defaults:{presets:$h({webFontsOptions:{customFetch:_s,fonts:Object.fromEntries(s0.map(t=>[t.toLowerCase().replace(/ /g,"_"),t]))}})},ready:({extractAll:t,toggleObserver:e})=>{let n=!1;const r=As({history:Os(u0),routes:[...Mo.value.filter(({path:a})=>a!==void 0).map(a=>{const{id:l,loc:c,path:f}=a,d=c?.replace(/ /g,"_").replace(/^\/?/,"/").replace(/\/?$/,"/");return{...d&&{alias:d},children:[{component:Jm,name:l,path:""}],component:e0,path:f.replace(/^\/?/,"/").replace(/\/?$/,"/")}}),{component:Ym,name:"404",path:"/:pathMatch(.*)*"}],scrollBehavior:async({hash:a,name:l})=>{if(l)if(Oo.value=l,n)n=!1;else{const{index:c,parent:{flat:f}={}}=r0.value??{};return e(!0),await c0.promise,await Promise.all([...l0.values()].map(({promise:d})=>d)),await t(),e(!1),"requestIdleCallback"in window?await new Promise(d=>requestIdleCallback(d)):(await new Promise(d=>requestAnimationFrame(d)),await new Promise(d=>setTimeout(d))),{behavior:"smooth",...a||f&&c?{el:a||`#${String(l)}`}:{left:0,top:0}}}return!1}}),o=Nh(window,{onStop:()=>{const[a]=n0.value,[l]=Mo.value;if(l&&a){const{$children:[{id:c}={}]=[]}=l,f=!Math.floor(i.value)&&!Math.floor(s.value)&&a.id===c?l.id:[...a0.entries()].find(([,d])=>d)?.[0]??a.id;f!==Oo.value&&(n=!0,r.push({name:f}).catch(Io.error))}}}),i=Q(o,"x"),s=Q(o,"y");return r.beforeEach(({path:a})=>a!==decodeURI(a)?decodeURI(a):void 0),fs.use(r),!1},rootElement:()=>document.getElementById("app")??void 0});fs.use(Ea()).provide("pages",Ah(o0.value)).mount("#app");
421
+ `,{scriptOptions:{inlineTemplate:!0}}))};function Ao(t,e){const n=t.type,r=n==="html"?"htmlAttrs":n==="body"?"bodyAttrs":n;if(typeof r!="string"||!(r in e))return;const o=t.props||{};if(t.children){const i="children";o.children=Array.isArray(t.children)?t.children[0][i]:t[i]}Array.isArray(e[r])?e[r].push(o):r==="title"?e.title=o.children:e[r]=o}function Km(t){const e={title:void 0,htmlAttrs:void 0,bodyAttrs:void 0,base:void 0,meta:[],link:[],style:[],script:[],noscript:[]};for(const n of t)if(typeof n.type=="symbol"&&Array.isArray(n.children))for(const r of n.children)Ao(r,e);else Ao(n,e);return e}const Gm=Wt({name:"Head",setup(t,{slots:e}){const n=wt({}),r=Un(n);return Po(()=>{r.dispose()}),()=>(We(()=>{e.default&&r.patch(Km(e.default()))}),null)}}),Ym=Wt({__name:"NotFoundView",setup(t){return(e,n)=>(gt(),Oe(Ro,null,[$s(_t(Gm),null,{default:Nn(()=>[...n[0]||(n[0]=[qt("title",null,"Page Not Found",-1)])]),_:1}),n[1]||(n[1]=qt("div",{class:"absolute inset-0 grid place-items-center"},[qt("div",{class:"text-center"},[qt("div",{class:"text-9xl"},"404"),qt("p",null,"Oops. Nothing here...")])],-1))],64))}}),Xm={mounted(t,e){if(typeof e.value=="function"){const n=e.value;bt(mo(t),r=>n(r),{immediate:!0})}else{const[n,r]=e.value;bt(mo(t,r),o=>n(o),{immediate:!0})}}};function Zm(){let t=!1;const e=mt(!1);return(n,r)=>{if(e.value=r.value,t)return;t=!0;const o=Wh(n,r.value);bt(e,i=>o.value=i)}}Zm();const Qm=["id"],Jm=Wt({__name:"PageView",setup(t){const e=Q(et,"$these"),n=Q(Dt,"kvNodes"),{intersecting:r,promises:o}=et,i=()=>{[r,o].forEach(a=>{a.clear()})},s=G(()=>new Map(e.value.map(({id:a})=>[a,ls(a)])));return We(()=>{i(),e.value.forEach(({id:a})=>{r.set(a,!1),o.set(a,as())})}),Lo(()=>{i()}),(a,l)=>(gt(!0),Oe(Ro,null,xs(s.value,([c,f])=>Ss((gt(),Oe("div",{id:c,key:c,class:Fo(n.value[c]?.class),"un-cloak":""},[(gt(),ce(Vn(f),{id:c,onVnodeMounted:d=>_t(o).get(c)?.resolve(void 0)},null,8,["id","onVnodeMounted"]))],10,Qm)),[[_t(Xm),[d=>{_t(r).set(c,d)},{threshold:.1}]]])),128))}}),t0=["id"],e0=Wt({__name:"RootView",setup(t){const e=Q(Dt,"nodes"),{root:n}=et,r=G(()=>e.value[0]&&ls(e.value[0].id));return(o,i)=>(gt(),ce(Cs,null,{default:Nn(()=>[e.value[0]?.enabled?(gt(),Oe("div",{key:0,id:e.value[0].id,class:Fo(e.value[0].class),"un-cloak":""},[(gt(),ce(Vn(r.value),{id:e.value[0].id,onVnodeMounted:i[0]||(i[0]=s=>_t(n).resolve(void 0))},null,8,["id"]))],10,t0)):Es("",!0)]),_:1}))}});let Oo=Q(et,"routeName");const cs=De(et),n0=Q(cs,"$these"),r0=Q(cs,"that"),us=De(Dt),o0=Q(us,"kvNodes"),Mo=Q(us,"nodes"),[i0,s0]=(await Promise.all(["index","fonts"].map(t=>Wn(`${t}.json`)))).map(t=>t??[]),fs=js(Dm),{intersecting:a0,promises:l0,root:c0}=et,{pathname:u0}=new URL(document.baseURI);Io.info("👊 VueBro / https://github.com/vuebro / runtime ver.:","1.4.1");Dt.tree=i0;await sl({defaults:{presets:$h({webFontsOptions:{customFetch:_s,fonts:Object.fromEntries(s0.map(t=>[t.toLowerCase().replace(/ /g,"_"),t]))}})},ready:({extractAll:t,toggleObserver:e})=>{let n=!1;const r=As({history:Os(u0),routes:[...Mo.value.filter(({path:a})=>a!==void 0).map(a=>{const{id:l,loc:c,path:f}=a,d=c?.replace(/ /g,"_").replace(/^\/?/,"/").replace(/\/?$/,"/");return{...d&&{alias:d},children:[{component:Jm,name:l,path:""}],component:e0,path:f.replace(/^\/?/,"/").replace(/\/?$/,"/")}}),{component:Ym,name:"404",path:"/:pathMatch(.*)*"}],scrollBehavior:async({hash:a,name:l})=>{if(l)if(Oo.value=l,n)n=!1;else{const{index:c,parent:{flat:f}={}}=r0.value??{};return e(!0),await c0.promise,await Promise.all([...l0.values()].map(({promise:d})=>d)),await t(),e(!1),"requestIdleCallback"in window?await new Promise(d=>requestIdleCallback(d)):(await new Promise(d=>requestAnimationFrame(d)),await new Promise(d=>setTimeout(d))),{behavior:"smooth",...a||f&&c?{el:a||`#${String(l)}`}:{left:0,top:0}}}return!1}}),o=Nh(window,{onStop:()=>{const[a]=n0.value,[l]=Mo.value;if(l&&a){const{$children:[{id:c}={}]=[]}=l,f=!Math.floor(i.value)&&!Math.floor(s.value)&&a.id===c?l.id:[...a0.entries()].find(([,d])=>d)?.[0]??a.id;f!==Oo.value&&(n=!0,r.push({name:f}).catch(Io.error))}}}),i=Q(o,"x"),s=Q(o,"y");return r.beforeEach(({path:a})=>a!==decodeURI(a)?decodeURI(a):void 0),fs.use(r),!1},rootElement:()=>document.getElementById("app")??void 0});fs.use(Ea()).provide("pages",Ah(o0.value)).mount("#app");