This commit is contained in:
Rizky 2023-10-19 08:53:27 +00:00
parent 64491439c3
commit f0a88a2e77
4 changed files with 0 additions and 208 deletions

Binary file not shown.

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@ -1,2 +0,0 @@
import{a as E,b as r,c as L,d as h,g as d,j as u,k as y,l as m,m as i}from"./chunk-DH54TKQS.js";var g=E(c=>{"use strict";var f=h();c.createRoot=f.createRoot,c.hydrateRoot=f.hydrateRoot;var b});var w=r(L()),R=r(g());var C=`/_web/${window.id_site}`,a={site:null,pages:[],api:null},_={async site(n,e){let t=await p("/site?prod=1");return a.site=t.site,a.pages=t.pages,a.api=t.api,i.serverurl=t.site.config.api_url,i.apiurl=t.site.config.api_url,i.prasiApi={[t.site.config.api_url]:{apiEntry:t.api}},t.site},async comp(n,e){let t=await p(`/comp/${e}`);return n.comps.all[e]=t,t},npm(n,e,t){return e==="site"?`/_web/${a.site.id}/npm-site/site.js`:`/_web/${a.site.id}/npm-page/${t}/page.js`},async page(n,e){let t=a.pages.find(o=>o.id===e);return t&&!t.content_tree?await p(`/page/${e}`):null},async pages(n,e){return a.pages}},p=async n=>{let t=await(await fetch(`${C}${n}`)).text();return JSON.parse(t)};var s=r(u()),l=window;l.prasiContext={global:{},render(){}};var x=({url:n,Live:e})=>{let[t,o]=(0,w.useState)({});l.prasiContext.render=()=>{o({})};let v=d.Provider;return(0,s.jsx)(v,{value:l.prasiContext,children:(0,s.jsx)(e,{domain:n.host,pathname:location.pathname,loader:_})})};(async()=>{let n=document.getElementById("root");if(n){let e=(0,R.createRoot)(n),t=new URL(location.href);await m(!1),y();let{Live:o}=await import("./live-4QMOJQZB.js");e.render((0,s.jsx)(x,{url:t,Live:o})),document.body.classList.contains("opacity-0")&&document.body.classList.remove("opacity-0")}})();
//# sourceMappingURL=site.js.map