sibujs 1.0.0-beta.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.
- package/LICENSE +21 -0
- package/README.md +1630 -0
- package/dist/browser.cjs +815 -0
- package/dist/browser.d.cts +174 -0
- package/dist/browser.d.ts +174 -0
- package/dist/browser.js +458 -0
- package/dist/build.cjs +4970 -0
- package/dist/build.d.cts +630 -0
- package/dist/build.d.ts +630 -0
- package/dist/build.js +2478 -0
- package/dist/cdn.global.js +115 -0
- package/dist/chunk-27QC4FPL.js +67 -0
- package/dist/chunk-2ABBWCGC.js +65 -0
- package/dist/chunk-2MUNQYZ7.js +26 -0
- package/dist/chunk-2PSPKNUI.js +1711 -0
- package/dist/chunk-35CDLDX5.js +1758 -0
- package/dist/chunk-36MU4CFV.js +41 -0
- package/dist/chunk-3FIQOFI6.js +182 -0
- package/dist/chunk-3GHNC2BN.js +28 -0
- package/dist/chunk-3HLWWEPU.js +909 -0
- package/dist/chunk-3IVI3J54.js +252 -0
- package/dist/chunk-3KZ72WNW.js +944 -0
- package/dist/chunk-4AU64SQV.js +182 -0
- package/dist/chunk-4MOK7HAR.js +84 -0
- package/dist/chunk-4QK6FBDH.js +1429 -0
- package/dist/chunk-566Z7HXB.js +737 -0
- package/dist/chunk-5CRBB7XP.js +358 -0
- package/dist/chunk-5G67D3IZ.js +168 -0
- package/dist/chunk-5NCPAWBE.js +99 -0
- package/dist/chunk-5O2RKXR3.js +1444 -0
- package/dist/chunk-6BTBDO6A.js +633 -0
- package/dist/chunk-6IWEHW57.js +43 -0
- package/dist/chunk-6JGMNCD6.js +282 -0
- package/dist/chunk-6QRLJNXR.js +1425 -0
- package/dist/chunk-7HM5UE5T.js +270 -0
- package/dist/chunk-7JOLTGUH.js +58 -0
- package/dist/chunk-7MCWJCQK.js +909 -0
- package/dist/chunk-7RIIFP3E.js +1758 -0
- package/dist/chunk-7UASYN3G.js +254 -0
- package/dist/chunk-7W2WYHDI.js +741 -0
- package/dist/chunk-7Y35RDSJ.js +872 -0
- package/dist/chunk-A65GFJBL.js +65 -0
- package/dist/chunk-AD6ZIEDK.js +67 -0
- package/dist/chunk-AK5Y72F3.js +1426 -0
- package/dist/chunk-APOMMWH4.js +282 -0
- package/dist/chunk-ARZVTWIQ.js +1750 -0
- package/dist/chunk-AWWBM2BI.js +664 -0
- package/dist/chunk-AX5VEQTY.js +58 -0
- package/dist/chunk-AYTXVOW3.js +1708 -0
- package/dist/chunk-BG4A246G.js +1746 -0
- package/dist/chunk-BNFJJA2L.js +1425 -0
- package/dist/chunk-BPKPBVU5.js +59 -0
- package/dist/chunk-BPKPPSXC.js +282 -0
- package/dist/chunk-BPWKKK7F.js +1711 -0
- package/dist/chunk-CCKX6YTC.js +1735 -0
- package/dist/chunk-CIF5Z3MP.js +58 -0
- package/dist/chunk-CSXYU7IO.js +457 -0
- package/dist/chunk-D6JD4FDC.js +26 -0
- package/dist/chunk-E7NGA7X2.js +59 -0
- package/dist/chunk-EEPPJKAE.js +443 -0
- package/dist/chunk-EJMYGAGQ.js +717 -0
- package/dist/chunk-EL6Z5MDY.js +55 -0
- package/dist/chunk-EP7VRLEB.js +41 -0
- package/dist/chunk-ETMEC6FH.js +99 -0
- package/dist/chunk-EZ2WHYVL.js +65 -0
- package/dist/chunk-EZRVMSZK.js +67 -0
- package/dist/chunk-F2TRGINX.js +254 -0
- package/dist/chunk-F5JCIH3Q.js +642 -0
- package/dist/chunk-FGK3JKMN.js +909 -0
- package/dist/chunk-FQWPKSTD.js +1437 -0
- package/dist/chunk-FWHVLMCI.js +26 -0
- package/dist/chunk-GBEYQRO2.js +303 -0
- package/dist/chunk-GBLES3NK.js +248 -0
- package/dist/chunk-GQVGUQW6.js +1436 -0
- package/dist/chunk-HCV2T76T.js +457 -0
- package/dist/chunk-HS7ZKVPR.js +182 -0
- package/dist/chunk-HXDVV7HZ.js +909 -0
- package/dist/chunk-IB23VMO3.js +1746 -0
- package/dist/chunk-IEMZ7RTT.js +99 -0
- package/dist/chunk-IPGRSN42.js +1750 -0
- package/dist/chunk-IVMOK2QN.js +1750 -0
- package/dist/chunk-JCLGQO7T.js +443 -0
- package/dist/chunk-JDXL7KDB.js +1436 -0
- package/dist/chunk-JIIFW636.js +270 -0
- package/dist/chunk-JWGEEH7H.js +944 -0
- package/dist/chunk-K2BESAG7.js +1688 -0
- package/dist/chunk-K2U5YGF4.js +877 -0
- package/dist/chunk-K45FQ4Y4.js +175 -0
- package/dist/chunk-K7BPE427.js +1432 -0
- package/dist/chunk-KL3266RS.js +26 -0
- package/dist/chunk-KNN4P7DZ.js +84 -0
- package/dist/chunk-KP2DZH5Q.js +254 -0
- package/dist/chunk-KZHAJSQR.js +1636 -0
- package/dist/chunk-LBKGHMQV.js +1750 -0
- package/dist/chunk-LBTEPL7A.js +1731 -0
- package/dist/chunk-LEBBPTDB.js +1444 -0
- package/dist/chunk-LLH63WVQ.js +98 -0
- package/dist/chunk-LWVR2C4G.js +1711 -0
- package/dist/chunk-M3MDTVV2.js +896 -0
- package/dist/chunk-M5GNLDEO.js +303 -0
- package/dist/chunk-MFHVGKET.js +267 -0
- package/dist/chunk-MGWSG3PM.js +358 -0
- package/dist/chunk-MJNB47HB.js +19 -0
- package/dist/chunk-MLKGABMK.js +9 -0
- package/dist/chunk-MQWTY3JY.js +944 -0
- package/dist/chunk-MZZOQHNI.js +642 -0
- package/dist/chunk-NIHWGZS4.js +1426 -0
- package/dist/chunk-NSVVHQK5.js +41 -0
- package/dist/chunk-NVI2WE7D.js +443 -0
- package/dist/chunk-O7QBO3PH.js +58 -0
- package/dist/chunk-OAUPQBO2.js +270 -0
- package/dist/chunk-OB2LMD7C.js +297 -0
- package/dist/chunk-OHEYBWQU.js +58 -0
- package/dist/chunk-OI6OXUHJ.js +443 -0
- package/dist/chunk-OX2VMRMV.js +633 -0
- package/dist/chunk-P4FYE5TX.js +866 -0
- package/dist/chunk-P5KFWM4H.js +98 -0
- package/dist/chunk-PUMLE7RJ.js +1711 -0
- package/dist/chunk-Q4MFANBF.js +282 -0
- package/dist/chunk-QLEKZMMU.js +282 -0
- package/dist/chunk-RGGNGVO3.js +98 -0
- package/dist/chunk-RKJDRVV6.js +443 -0
- package/dist/chunk-S5BHU353.js +43 -0
- package/dist/chunk-SHQUSFH7.js +1426 -0
- package/dist/chunk-SMB4DBMD.js +182 -0
- package/dist/chunk-SNYHQP3D.js +743 -0
- package/dist/chunk-T24L3TBF.js +1717 -0
- package/dist/chunk-TAQNSOKT.js +692 -0
- package/dist/chunk-TDNY4SUA.js +41 -0
- package/dist/chunk-TNNF56IQ.js +1750 -0
- package/dist/chunk-TR7E6LYX.js +457 -0
- package/dist/chunk-URWUFH45.js +98 -0
- package/dist/chunk-UUSIH3XH.js +1429 -0
- package/dist/chunk-UYFNXLKR.js +1436 -0
- package/dist/chunk-V6F7KUWD.js +270 -0
- package/dist/chunk-VCZLXRMR.js +254 -0
- package/dist/chunk-VDHXSSBT.js +1426 -0
- package/dist/chunk-VM4QMKVK.js +254 -0
- package/dist/chunk-VWGYKYL2.js +737 -0
- package/dist/chunk-VX2OFBJN.js +1426 -0
- package/dist/chunk-VXVIE6DG.js +84 -0
- package/dist/chunk-W4OH7HG4.js +40 -0
- package/dist/chunk-WBVJX4GZ.js +98 -0
- package/dist/chunk-WDU2ZV4I.js +1426 -0
- package/dist/chunk-X6VUCICU.js +457 -0
- package/dist/chunk-XAY7FM7Y.js +618 -0
- package/dist/chunk-XJZ5Z2CM.js +642 -0
- package/dist/chunk-XKVFQTJJ.js +254 -0
- package/dist/chunk-XRLFASCY.js +22 -0
- package/dist/chunk-XYU6TZOW.js +182 -0
- package/dist/chunk-Y745CBVB.js +944 -0
- package/dist/chunk-YLBJSXYY.js +944 -0
- package/dist/chunk-YQJIKVPZ.js +1429 -0
- package/dist/chunk-YRM2VCZF.js +457 -0
- package/dist/chunk-YS33KBVJ.js +944 -0
- package/dist/chunk-Z27DZPDG.js +41 -0
- package/dist/chunk-ZXQ5NAEN.js +32 -0
- package/dist/contracts-B552GopR.d.cts +245 -0
- package/dist/contracts-B552GopR.d.ts +245 -0
- package/dist/contracts-Bg1ECISC.d.cts +245 -0
- package/dist/contracts-Bg1ECISC.d.ts +245 -0
- package/dist/contracts-CMriKJ6P.d.cts +245 -0
- package/dist/contracts-CMriKJ6P.d.ts +245 -0
- package/dist/contracts-DOrhwbke.d.cts +245 -0
- package/dist/contracts-DOrhwbke.d.ts +245 -0
- package/dist/data.cjs +1373 -0
- package/dist/data.d.cts +434 -0
- package/dist/data.d.ts +434 -0
- package/dist/data.js +945 -0
- package/dist/devtools.cjs +1357 -0
- package/dist/devtools.d.cts +473 -0
- package/dist/devtools.d.ts +473 -0
- package/dist/devtools.js +1084 -0
- package/dist/ecosystem.cjs +1046 -0
- package/dist/ecosystem.d.cts +247 -0
- package/dist/ecosystem.d.ts +247 -0
- package/dist/ecosystem.js +369 -0
- package/dist/extras.cjs +8457 -0
- package/dist/extras.d.cts +2356 -0
- package/dist/extras.d.ts +2356 -0
- package/dist/extras.js +5152 -0
- package/dist/index.cjs +2648 -0
- package/dist/index.d.cts +869 -0
- package/dist/index.d.ts +869 -0
- package/dist/index.js +386 -0
- package/dist/motion.cjs +604 -0
- package/dist/motion.d.cts +146 -0
- package/dist/motion.d.ts +146 -0
- package/dist/motion.js +346 -0
- package/dist/patterns.cjs +815 -0
- package/dist/patterns.d.cts +163 -0
- package/dist/patterns.d.ts +163 -0
- package/dist/patterns.js +296 -0
- package/dist/performance.cjs +927 -0
- package/dist/performance.d.cts +416 -0
- package/dist/performance.d.ts +416 -0
- package/dist/performance.js +654 -0
- package/dist/plugins.cjs +2487 -0
- package/dist/plugins.d.cts +393 -0
- package/dist/plugins.d.ts +393 -0
- package/dist/plugins.js +1504 -0
- package/dist/signal-BnWpq6WB.d.cts +5 -0
- package/dist/signal-BnWpq6WB.d.ts +5 -0
- package/dist/src/components/ErrorBoundary.d.ts +15 -0
- package/dist/src/components/ErrorBoundary.js +119 -0
- package/dist/src/core/catch.d.ts +11 -0
- package/dist/src/core/catch.js +28 -0
- package/dist/src/core/each.d.ts +13 -0
- package/dist/src/core/each.js +68 -0
- package/dist/src/core/for.d.ts +12 -0
- package/dist/src/core/for.js +67 -0
- package/dist/src/core/html.d.ts +137 -0
- package/dist/src/core/html.js +155 -0
- package/dist/src/core/htmlIf.d.ts +11 -0
- package/dist/src/core/htmlIf.js +18 -0
- package/dist/src/core/lazy.d.ts +7 -0
- package/dist/src/core/lazy.js +16 -0
- package/dist/src/core/mount.d.ts +7 -0
- package/dist/src/core/mount.js +12 -0
- package/dist/src/core/slots.d.ts +3 -0
- package/dist/src/core/slots.js +3 -0
- package/dist/src/core/suspense.d.ts +10 -0
- package/dist/src/core/suspense.js +33 -0
- package/dist/src/core/tagFactory.d.ts +13 -0
- package/dist/src/core/tagFactory.js +86 -0
- package/dist/src/core/test.d.ts +11 -0
- package/dist/src/core/test.js +28 -0
- package/dist/src/core/types.d.ts +2 -0
- package/dist/src/core/types.js +1 -0
- package/dist/src/core/useComputed.d.ts +6 -0
- package/dist/src/core/useComputed.js +30 -0
- package/dist/src/core/useEffect.d.ts +6 -0
- package/dist/src/core/useEffect.js +23 -0
- package/dist/src/core/useState.d.ts +10 -0
- package/dist/src/core/useState.js +34 -0
- package/dist/src/core/useStore.d.ts +19 -0
- package/dist/src/core/useStore.js +53 -0
- package/dist/src/core/useWatch.d.ts +8 -0
- package/dist/src/core/useWatch.js +23 -0
- package/dist/src/plugins/i18n.d.ts +6 -0
- package/dist/src/plugins/i18n.js +16 -0
- package/dist/src/plugins/router.d.ts +188 -0
- package/dist/src/plugins/router.js +1178 -0
- package/dist/src/reactivity/bindAttribute.d.ts +5 -0
- package/dist/src/reactivity/bindAttribute.js +31 -0
- package/dist/src/reactivity/bindChildNode.d.ts +10 -0
- package/dist/src/reactivity/bindChildNode.js +46 -0
- package/dist/src/reactivity/bindTextNode.d.ts +10 -0
- package/dist/src/reactivity/bindTextNode.js +27 -0
- package/dist/src/reactivity/signal.d.ts +3 -0
- package/dist/src/reactivity/signal.js +1 -0
- package/dist/src/reactivity/track.d.ts +18 -0
- package/dist/src/reactivity/track.js +73 -0
- package/dist/src/reactivity/useComputed.d.ts +6 -0
- package/dist/src/reactivity/useComputed.js +30 -0
- package/dist/src/reactivity/useEffect.d.ts +6 -0
- package/dist/src/reactivity/useEffect.js +23 -0
- package/dist/src/reactivity/useState.d.ts +10 -0
- package/dist/src/reactivity/useState.js +34 -0
- package/dist/src/reactivity/useStore.d.ts +19 -0
- package/dist/src/reactivity/useStore.js +53 -0
- package/dist/src/reactivity/useWatch.d.ts +8 -0
- package/dist/src/reactivity/useWatch.js +23 -0
- package/dist/src/utils/sanitize.d.ts +1 -0
- package/dist/src/utils/sanitize.js +8 -0
- package/dist/ssr-27FOM46T.js +35 -0
- package/dist/ssr-GFUTTSJD.js +22 -0
- package/dist/ssr-K7DCR6BZ.js +35 -0
- package/dist/ssr-O6LFMRFP.js +35 -0
- package/dist/ssr-QZEVGMMK.js +35 -0
- package/dist/ssr-SGVBCAGC.js +35 -0
- package/dist/ssr-UB2IXCYX.js +35 -0
- package/dist/ssr-XBZQNV4O.js +22 -0
- package/dist/ssr-Y76FSXDU.js +35 -0
- package/dist/ssr-YQJ4AYBD.js +35 -0
- package/dist/ssr.cjs +1757 -0
- package/dist/ssr.d.cts +478 -0
- package/dist/ssr.d.ts +478 -0
- package/dist/ssr.js +743 -0
- package/dist/tagFactory-CZPO4RXF.d.cts +34 -0
- package/dist/tagFactory-CZPO4RXF.d.ts +34 -0
- package/dist/tagFactory-CgImPVMY.d.cts +22 -0
- package/dist/tagFactory-CgImPVMY.d.ts +22 -0
- package/dist/tagFactory-Cw1iv5if.d.cts +22 -0
- package/dist/tagFactory-Cw1iv5if.d.ts +22 -0
- package/dist/tagFactory-DeAXq9ef.d.cts +30 -0
- package/dist/tagFactory-DeAXq9ef.d.ts +30 -0
- package/dist/tagFactory-SkY0a7L1.d.cts +22 -0
- package/dist/tagFactory-SkY0a7L1.d.ts +22 -0
- package/dist/testing.cjs +1919 -0
- package/dist/testing.d.cts +491 -0
- package/dist/testing.d.ts +491 -0
- package/dist/testing.js +1862 -0
- package/dist/ui.cjs +1497 -0
- package/dist/ui.d.cts +264 -0
- package/dist/ui.d.ts +264 -0
- package/dist/ui.js +900 -0
- package/dist/widgets.cjs +919 -0
- package/dist/widgets.d.cts +165 -0
- package/dist/widgets.d.ts +165 -0
- package/dist/widgets.js +545 -0
- package/package.json +134 -0
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
"use strict";var Sibu=(()=>{var ie=Object.defineProperty;var Kr=Object.getOwnPropertyDescriptor;var Vr=Object.getOwnPropertyNames;var Ur=Object.prototype.hasOwnProperty;var _e=(t,e)=>{for(var n in e)ie(t,n,{get:e[n],enumerable:!0})},Fr=(t,e,n,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let o of Vr(e))!Ur.call(t,o)&&o!==n&&ie(t,o,{get:()=>e[o],enumerable:!(r=Kr(e,o))||r.enumerable});return t};var $r=t=>Fr(ie({},"__esModule",{value:!0}),t);var ho={};_e(ho,{DynamicComponent:()=>br,ErrorBoundary:()=>zr,Fragment:()=>pr,Loading:()=>qr,Portal:()=>fr,SVG_NS:()=>h,Suspense:()=>Te,a:()=>ct,abbr:()=>lt,address:()=>Ue,area:()=>Bt,array:()=>Rr,article:()=>je,aside:()=>Ve,audio:()=>Pt,b:()=>ut,base:()=>Mn,batch:()=>wr,bdi:()=>dt,bdo:()=>pt,bindDynamic:()=>ce,blockquote:()=>Ye,body:()=>Pe,br:()=>ft,button:()=>oe,canvas:()=>Zt,caption:()=>tn,catchError:()=>vr,catchErrorAsync:()=>Sr,center:()=>er,checkLeaks:()=>Oe,circle:()=>Hn,cite:()=>mt,clipPath:()=>Un,code:()=>gt,col:()=>nn,colgroup:()=>rn,context:()=>Pr,customElement:()=>rr,data:()=>bt,datalist:()=>pn,dd:()=>Je,deepSignal:()=>Hr,defs:()=>Vn,del:()=>Xt,derived:()=>K,details:()=>En,dfn:()=>ht,dialog:()=>_n,disableSSR:()=>be,dispose:()=>F,div:()=>S,dl:()=>Xe,dt:()=>et,each:()=>ur,effect:()=>G,ellipse:()=>Bn,em:()=>xt,embed:()=>It,enableSSR:()=>ge,enqueueBatchedSignal:()=>P,fieldset:()=>fn,figcaption:()=>tt,figure:()=>nt,font:()=>tr,footer:()=>Ie,form:()=>mn,g:()=>Pn,getSlot:()=>hr,h1:()=>Fe,h2:()=>$e,h3:()=>re,h4:()=>Ge,h5:()=>Qe,h6:()=>Ze,head:()=>Be,header:()=>qe,hr:()=>rt,html:()=>ue,i:()=>yt,iframe:()=>Wt,img:()=>Dt,input:()=>gn,ins:()=>en,isBatching:()=>Er,isSSR:()=>W,kbd:()=>Tt,label:()=>bn,lazy:()=>ye,legend:()=>hn,li:()=>ot,line:()=>Dn,linearGradient:()=>Gn,link:()=>Rn,main:()=>Ke,map:()=>zt,mark:()=>vt,marker:()=>Xn,marquee:()=>nr,mask:()=>Fn,match:()=>Tr,math:()=>Qt,memo:()=>Lr,memoFn:()=>Mr,menu:()=>Cn,meta:()=>On,meter:()=>xn,mount:()=>cr,nav:()=>We,noscript:()=>Yt,object:()=>Kt,ol:()=>it,onMount:()=>xe,onUnmount:()=>Br,optgroup:()=>yn,option:()=>Tn,output:()=>vn,p:()=>ne,param:()=>Vt,path:()=>zn,pattern:()=>$n,picture:()=>Ut,polygon:()=>jn,polyline:()=>qn,portal:()=>Ft,pre:()=>at,progress:()=>Sn,q:()=>St,radialGradient:()=>Qn,reactiveArray:()=>Or,rect:()=>In,ref:()=>Ar,registerComponent:()=>mr,registerDisposer:()=>L,resolveComponent:()=>pe,rp:()=>kt,rt:()=>wt,ruby:()=>Et,s:()=>_t,samp:()=>Ct,script:()=>Jt,section:()=>ze,select:()=>kn,setGlobalErrorHandler:()=>kr,show:()=>xr,signal:()=>C,slot:()=>An,small:()=>Nt,source:()=>$t,span:()=>N,stop:()=>Zn,store:()=>Nr,strong:()=>At,style:()=>I,sub:()=>Lt,summary:()=>Nn,sup:()=>Mt,svg:()=>Gt,symbol:()=>Jn,table:()=>on,tagFactory:()=>s,tbody:()=>sn,td:()=>an,template:()=>Ln,text:()=>Wn,textarea:()=>wn,tfoot:()=>cn,th:()=>ln,thead:()=>un,time:()=>Rt,title:()=>De,tr:()=>dn,track:()=>jt,tspan:()=>Kn,u:()=>Ot,ul:()=>st,unregisterComponent:()=>gr,use:()=>Yn,var_:()=>Ht,video:()=>qt,watch:()=>Cr,when:()=>yr,withSSR:()=>_r});var Se={};_e(Se,{DynamicComponent:()=>br,ErrorBoundary:()=>zr,Fragment:()=>pr,Loading:()=>qr,Portal:()=>fr,SVG_NS:()=>h,Suspense:()=>Te,a:()=>ct,abbr:()=>lt,address:()=>Ue,area:()=>Bt,array:()=>Rr,article:()=>je,aside:()=>Ve,audio:()=>Pt,b:()=>ut,base:()=>Mn,batch:()=>wr,bdi:()=>dt,bdo:()=>pt,bindDynamic:()=>ce,blockquote:()=>Ye,body:()=>Pe,br:()=>ft,button:()=>oe,canvas:()=>Zt,caption:()=>tn,catchError:()=>vr,catchErrorAsync:()=>Sr,center:()=>er,checkLeaks:()=>Oe,circle:()=>Hn,cite:()=>mt,clipPath:()=>Un,code:()=>gt,col:()=>nn,colgroup:()=>rn,context:()=>Pr,customElement:()=>rr,data:()=>bt,datalist:()=>pn,dd:()=>Je,deepSignal:()=>Hr,defs:()=>Vn,del:()=>Xt,derived:()=>K,details:()=>En,dfn:()=>ht,dialog:()=>_n,disableSSR:()=>be,dispose:()=>F,div:()=>S,dl:()=>Xe,dt:()=>et,each:()=>ur,effect:()=>G,ellipse:()=>Bn,em:()=>xt,embed:()=>It,enableSSR:()=>ge,enqueueBatchedSignal:()=>P,fieldset:()=>fn,figcaption:()=>tt,figure:()=>nt,font:()=>tr,footer:()=>Ie,form:()=>mn,g:()=>Pn,getSlot:()=>hr,h1:()=>Fe,h2:()=>$e,h3:()=>re,h4:()=>Ge,h5:()=>Qe,h6:()=>Ze,head:()=>Be,header:()=>qe,hr:()=>rt,html:()=>ue,i:()=>yt,iframe:()=>Wt,img:()=>Dt,input:()=>gn,ins:()=>en,isBatching:()=>Er,isSSR:()=>W,kbd:()=>Tt,label:()=>bn,lazy:()=>ye,legend:()=>hn,li:()=>ot,line:()=>Dn,linearGradient:()=>Gn,link:()=>Rn,main:()=>Ke,map:()=>zt,mark:()=>vt,marker:()=>Xn,marquee:()=>nr,mask:()=>Fn,match:()=>Tr,math:()=>Qt,memo:()=>Lr,memoFn:()=>Mr,menu:()=>Cn,meta:()=>On,meter:()=>xn,mount:()=>cr,nav:()=>We,noscript:()=>Yt,object:()=>Kt,ol:()=>it,onMount:()=>xe,onUnmount:()=>Br,optgroup:()=>yn,option:()=>Tn,output:()=>vn,p:()=>ne,param:()=>Vt,path:()=>zn,pattern:()=>$n,picture:()=>Ut,polygon:()=>jn,polyline:()=>qn,portal:()=>Ft,pre:()=>at,progress:()=>Sn,q:()=>St,radialGradient:()=>Qn,reactiveArray:()=>Or,rect:()=>In,ref:()=>Ar,registerComponent:()=>mr,registerDisposer:()=>L,resolveComponent:()=>pe,rp:()=>kt,rt:()=>wt,ruby:()=>Et,s:()=>_t,samp:()=>Ct,script:()=>Jt,section:()=>ze,select:()=>kn,setGlobalErrorHandler:()=>kr,show:()=>xr,signal:()=>C,slot:()=>An,small:()=>Nt,source:()=>$t,span:()=>N,stop:()=>Zn,store:()=>Nr,strong:()=>At,style:()=>I,sub:()=>Lt,summary:()=>Nn,sup:()=>Mt,svg:()=>Gt,symbol:()=>Jn,table:()=>on,tagFactory:()=>s,tbody:()=>sn,td:()=>an,template:()=>Ln,text:()=>Wn,textarea:()=>wn,tfoot:()=>cn,th:()=>ln,thead:()=>un,time:()=>Rt,title:()=>De,tr:()=>dn,track:()=>jt,tspan:()=>Kn,u:()=>Ot,ul:()=>st,unregisterComponent:()=>gr,use:()=>Yn,var_:()=>Ht,video:()=>qt,watch:()=>Cr,when:()=>yr,withSSR:()=>_r});function Gr(t){return String(t).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'")}function Qr(t){let e=t.replace(/[\x00-\x20\x7f-\x9f]+/g,"").trim();if(!e)return"";let n=e.toLowerCase();return n.startsWith("javascript:")||n.startsWith("data:")||n.startsWith("vbscript:")||n.startsWith("blob:")?"":e}var Zr=new Set(["href","src","action","formaction","cite","poster","background","srcset"]);function Yr(t){return Zr.has(t)}function V(t,e){return Yr(t)?Qr(e):Gr(e)}var H=[],R=null,Jr=new WeakMap,j="__s",M=0,v=[],w=new Set,J=0,X=!1;function x(t,e){return e||(e=t),Ce(e),H.push(e),R=e,t(),H.pop(),R=H[H.length-1]||null,()=>Ce(e)}function se(){J===0&&(H.push(null),R=null,X=!0),J++}function ae(){J--,J===0&&(H.pop(),R=H[H.length-1]||null,X=!1)}function B(t){if(!R)return;let e=R._deps;if(e||(e=new Set,R._deps=e),!e.has(t)){e.add(t);let n=t[j];n||(n=new Set,Jr.set(t,n),t[j]=n),n.add(R),n.size===1?t.__f=R:t.__f!==void 0&&(t.__f=void 0)}}function Ne(t){let e=t[j];if(e)for(let n of e)n._c?z(n):w.has(n)||(w.add(n),v.push(n))}function Ae(){if(!(M>0)){M++;try{let t=0;for(;t<v.length;)v[t](),t++}finally{v.length=0,w.clear(),M--}}}function z(t){t();let e=t._sig,n=!1;if(e&&e._g){let r=t._deps;if(r&&r.size===1){se(),n=!0;let o=e;o._d=!1,o._v=o._g()}}for(;e;){let r=e.__f;if(r){if(r._c){let c=r._sig;if(c._d=!0,n&&c._g){let a=r._deps;a&&a.size===1&&(c._d=!1,c._v=c._g())}e=c;continue}w.has(r)||(w.add(r),v.push(r));break}let o=e[j];if(!o)break;let i;for(let c of o)if(c._c){c();let a=c._sig;a&&!i?i=a:a&&z(c)}else w.has(c)||(w.add(c),v.push(c));e=i}n&&ae()}function q(t){let e=t.__f;if(e){if(M>0){e._c?z(e):w.has(e)||(w.add(e),v.push(e));return}M++;try{e._c?z(e):e();let r=0;for(;r<v.length;)v[r](),r++}finally{v.length=0,w.clear(),M--}return}let n=t[j];if(!(!n||n.size===0)){if(M>0){for(let r of n)r._c?z(r):w.has(r)||(w.add(r),v.push(r));return}M++;try{let r=0;for(let i of n)v[r++]=i;for(let i=0;i<r;i++)v[i]._c&&z(v[i]);for(let i=0;i<r;i++)v[i]._c||w.has(v[i])||v[i]();let o=r;for(;o<v.length;)v[o](),o++}finally{v.length=0,w.clear(),M--}}}function Ce(t){let e=t._deps;if(!(!e||e.size===0)){for(let n of e){let r=n[j];r&&(r.delete(t),n.__f===t&&(n.__f=void 0))}e.clear()}}function Le(t,e,n){function r(){let i;try{i=n()}catch{return}if(typeof i=="boolean"){e in t&&(e==="checked"||e==="disabled"||e==="selected")?t[e]=i:i?t.setAttribute(e,""):t.removeAttribute(e);return}let c=V(e,String(i));(e==="value"||e==="checked")&&e in t?t[e]=e==="checked"?!!i:c:t.setAttribute(e,c)}return x(r)}function ce(t,e,n){let r=null;function o(){let c;try{c=typeof e=="function"?e():e}catch{return}let a;try{a=typeof n=="function"?n():n}catch{return}if(c.toLowerCase().startsWith("on"))return;r!==null&&r!==c&&t.removeAttribute(r);let l=V(c,String(a));(c==="value"||c==="checked")&&c in t?t[c]=c==="checked"?!!a:l:t.setAttribute(c,l),r=c}let i=x(o);return()=>{i(),r!==null&&t.removeAttribute(r)}}function ee(t,e){let n=[];function r(){let o;try{o=e()}catch{return}for(let u of n)u.parentNode?.removeChild(u);if(n=[],o==null)return;let i=t.parentNode;if(!i)return;let c=t.nextSibling,a=[],l=u=>{let d=u instanceof Node?u:document.createTextNode(String(u));i.insertBefore(d,c),a.push(d)};if(Array.isArray(o))for(let u of o)l(u);else l(o);n=a}return x(r)}function Me(){return typeof globalThis.__SIBU_DEV__<"u"?!!globalThis.__SIBU_DEV__:typeof __SIBU_DEV__<"u"?__SIBU_DEV__:!0}function k(t,e){if(Me()&&!t)throw new Error(`[Sibu] ${e}`)}function Re(t){Me()&&console.warn(`[Sibu] ${t}`)}var te=new WeakMap,U=0;function L(t,e){let n=te.get(t);n||(n=[],te.set(t,n)),n.push(e),U++}function F(t){let e=t.childNodes;for(let r of e)F(r);let n=te.get(t);if(n){U-=n.length;for(let r of n)r();te.delete(t)}}function Oe(t=0){return U>t&&Re(`checkLeaks: ${U} active DOM bindings detected. Expected \u2264${t}. This may indicate a component was removed from the DOM without calling dispose().`),U}var h="http://www.w3.org/2000/svg",He=new Map;function Xr(t){let e=He.get(t);return e!==void 0||(e=t.replace(/[A-Z]/g,n=>`-${n.toLowerCase()}`),He.set(t,e)),e}function eo(t,e){if(!e)return;if(typeof e=="function"){let r=x(()=>{t.setAttribute("style",e())});L(t,r);return}if(typeof e=="string"){t.setAttribute("style",e);return}let n=t;for(let r in e){let o=e[r],i=Xr(r);if(typeof o=="function"){let c=o,a=x(()=>{n.style.setProperty(i,String(c()))});L(t,a)}else n.style.setProperty(i,String(o))}}function to(t,e){if(e!=null){if(typeof e=="string"){t.setAttribute("class",e);return}if(typeof e=="function"){let n=e,r=x(()=>{t.setAttribute("class",n())});L(t,r);return}if(typeof e=="object"){let n=e,r=!1;for(let o in n)if(typeof n[o]=="function"){r=!0;break}if(r){let i=x(()=>{let c="";for(let a in n){let l=n[a];(typeof l=="function"?l():l)&&(c=c?`${c} ${a}`:a)}t.setAttribute("class",c)});L(t,i)}else{let o="";for(let i in n)n[i]&&(o=o?`${o} ${i}`:i);t.setAttribute("class",o)}}}}function no(t){return t==null?document.createTextNode(""):t instanceof Node?t:document.createTextNode(String(t))}function le(t,e){if(typeof e=="function"){let n=document.createComment("bind:child");t.appendChild(n);let r=ee(n,e);L(t,r)}else t.appendChild(no(e))}function ro(t,e){if(Array.isArray(e))for(let n=0;n<e.length;n++){let r=e[n];if(Array.isArray(r))for(let o=0;o<r.length;o++)le(t,r[o]);else le(t,r)}else le(t,e)}function oo(t){return typeof t=="object"&&t!==null&&!Array.isArray(t)&&!(t instanceof Node)}var s=(t,e)=>(n,r)=>{let o;n===void 0?o={}:oo(n)?o=n:r!==void 0?o={class:n,nodes:r}:o={nodes:n};let i=e?document.createElementNS(e,t):document.createElement(t);for(let c in o){let a=o[c];if(a!=null)switch(c){case"id":i.id=a;break;case"class":to(i,a);break;case"style":eo(i,a);break;case"ref":a&&typeof a=="object"&&"current"in a&&(a.current=i);break;case"on":{let l=a,u=[];for(let d in l)i.addEventListener(d,l[d]),u.push(d);u.length&&(i.__sibu_events__=u);break}case"nodes":ro(i,a);break;default:if(c.toLowerCase().startsWith("on"))break;if(typeof a=="function"){let l=Le(i,c,a);L(i,l)}else typeof a=="boolean"?a?i.setAttribute(c,""):i.removeAttribute(c):i.setAttribute(c,V(c,String(a)))}}return i};var Po=s("html"),Be=s("head"),Pe=s("body"),De=s("title"),S=s("div"),N=s("span"),ze=s("section"),je=s("article"),qe=s("header"),Ie=s("footer"),We=s("nav"),Ke=s("main"),Ve=s("aside"),Ue=s("address"),ne=s("p"),Fe=s("h1"),$e=s("h2"),re=s("h3"),Ge=s("h4"),Qe=s("h5"),Ze=s("h6"),Ye=s("blockquote"),Je=s("dd"),Xe=s("dl"),et=s("dt"),tt=s("figcaption"),nt=s("figure"),rt=s("hr"),ot=s("li"),it=s("ol"),st=s("ul"),at=s("pre"),ct=s("a"),lt=s("abbr"),ut=s("b"),dt=s("bdi"),pt=s("bdo"),ft=s("br"),mt=s("cite"),gt=s("code"),bt=s("data"),ht=s("dfn"),xt=s("em"),yt=s("i"),Tt=s("kbd"),vt=s("mark"),St=s("q"),kt=s("rp"),wt=s("rt"),Et=s("ruby"),_t=s("s"),Ct=s("samp"),Nt=s("small"),At=s("strong"),Lt=s("sub"),Mt=s("sup"),Rt=s("time"),Ot=s("u"),Ht=s("var"),Bt=s("area"),Pt=s("audio"),Dt=s("img"),zt=s("map"),jt=s("track"),qt=s("video"),It=s("embed"),Wt=s("iframe"),Kt=s("object"),Vt=s("param"),Ut=s("picture"),Ft=s("portal"),$t=s("source"),Gt=s("svg",h),Qt=s("math"),Zt=s("canvas"),Yt=s("noscript"),Jt=s("script"),Xt=s("del"),en=s("ins"),tn=s("caption"),nn=s("col"),rn=s("colgroup"),on=s("table"),sn=s("tbody"),an=s("td"),cn=s("tfoot"),ln=s("th"),un=s("thead"),dn=s("tr"),oe=s("button"),pn=s("datalist"),fn=s("fieldset"),mn=s("form"),gn=s("input"),bn=s("label"),hn=s("legend"),xn=s("meter"),yn=s("optgroup"),Tn=s("option"),vn=s("output"),Sn=s("progress"),kn=s("select"),wn=s("textarea"),En=s("details"),_n=s("dialog"),Cn=s("menu"),Nn=s("summary"),An=s("slot"),Ln=s("template"),Mn=s("base"),Rn=s("link"),On=s("meta"),I=s("style"),Hn=s("circle",h),Bn=s("ellipse",h),Pn=s("g",h),Dn=s("line",h),zn=s("path",h),jn=s("polygon",h),qn=s("polyline",h),In=s("rect",h),Wn=s("text",h),Kn=s("tspan",h),Vn=s("defs",h),Un=s("clipPath",h),Fn=s("mask",h),$n=s("pattern",h),Gn=s("linearGradient",h),Qn=s("radialGradient",h),Zn=s("stop",h),Yn=s("use",h),Jn=s("symbol",h),Xn=s("marker",h),er=s("center"),tr=s("font"),nr=s("marquee"),rr=t=>s(t);var io=new Set(["area","base","br","col","embed","hr","img","input","link","meta","param","source","track","wbr"]),or=new Set(["svg","circle","ellipse","g","line","path","polygon","polyline","rect","text","tspan","defs","clipPath","mask","pattern","linearGradient","radialGradient","stop","use","symbol","marker"]),ir=new WeakMap;function so(t){let e=t.length-1,n=t[0];for(let p=0;p<e;p++)n+=`\0${p}\0${t[p+1]}`;let r=0,o=n.length;function i(){for(;r<o&&(n[r]===" "||n[r]===" "||n[r]===`
|
|
2
|
+
`||n[r]==="\r");)r++}function c(){if(n[r]!=="\0")return-1;let p=r;r++;let g="";for(;r<o&&n[r]!=="\0";)g+=n[r++];r<o&&r++;let b=Number.parseInt(g,10);return Number.isNaN(b)||b<0||b>=e?(r=p,-1):b}function a(){let p="";for(;r<o&&/[a-zA-Z0-9-]/.test(n[r]);)p+=n[r++];return p}function l(){if(i(),n[r]!=="=")return{kind:"bool"};r++,i();let p=c();if(p>=0)return{kind:"expr",idx:p};let g=n[r];if(g==='"'||g==="'"){r++;let E=[],T=[],A="";for(;r<o&&n[r]!==g;){let O=c();O>=0?(E.push(A),A="",T.push(O)):A+=n[r++]}return r<o&&r++,E.push(A),T.length===0?{kind:"static",value:E[0]}:{kind:"mixed",statics:E,exprs:T}}let b="";for(;r<o&&!/[\s>/]/.test(n[r]);)b+=n[r++];return{kind:"static",value:b}}function u(){let p=[];for(;r<o&&(i(),!(n[r]===">"||n[r]==="/"));){let g="";for(;r<o&&/[a-zA-Z0-9\-:_.]/.test(n[r]);)g+=n[r++];if(!g)break;let b=l();g.startsWith("on:")?b.kind==="expr"&&p.push({t:3,name:g.slice(3),idx:b.idx}):b.kind==="bool"?p.push({t:4,name:g}):b.kind==="static"?p.push({t:0,name:g,value:b.value}):b.kind==="expr"?p.push({t:1,name:g,idx:b.idx}):b.kind==="mixed"&&p.push({t:2,name:g,statics:b.statics,exprs:b.exprs})}return p}function d(p){return p.replace(/\s+/g," ")}function f(p){let g="";for(;r<o&&n[r]!=="<";){let E=c();if(E>=0){let T=d(g);T&&p.push({t:1,value:T}),g="",p.push({t:2,idx:E})}else g+=n[r++]}let b=d(g);b&&p.push({t:1,value:b})}function y(){let p=[];for(;r<o&&!(n[r]==="<"&&r+1<o&&n[r+1]==="/");)if(n[r]==="<"){r++;let g=a(),b=u();i();let E=io.has(g),T=n[r]==="/";if(T&&r++,r<o&&r++,E||T)p.push({t:0,el:{tag:g,svg:or.has(g),attrs:b,children:[]}});else{let A=y();n[r]==="<"&&r+1<o&&n[r+1]==="/"&&(r+=2,a(),i(),r<o&&n[r]===">"&&r++),p.push({t:0,el:{tag:g,svg:or.has(g),attrs:b,children:A}})}}else f(p);return p}return y()}var sr=new Map;function ao(t,e){let n=e?`svg:${t}`:t,r=sr.get(n);return r||(r=s(t,e?h:void 0),sr.set(n,r)),r}function co(t,e){let n={},r={},o=!1;for(let i=0;i<t.attrs.length;i++){let c=t.attrs[i];switch(c.t){case 0:n[c.name]=c.value;break;case 1:n[c.name]=e[c.idx];break;case 2:{let a=c.statics[0];for(let l=0;l<c.exprs.length;l++)a+=String(e[c.exprs[l]])+c.statics[l+1];n[c.name]=a;break}case 3:r[c.name]=e[c.idx],o=!0;break;case 4:n[c.name]=!0;break}}if(o&&(n.on=r),t.children.length>0){let i=ar(t.children,e);n.nodes=i.length===1?i[0]:i}return ao(t.tag,t.svg)(n)}function ar(t,e){let n=[];for(let r=0;r<t.length;r++){let o=t[r];switch(o.t){case 0:n.push(co(o.el,e));break;case 1:n.push(o.value);break;case 2:n.push(e[o.idx]);break}}return n}function ue(t,...e){let n=ir.get(t);n||(n=so(t),ir.set(t,n));let r=ar(n,e);if(r.length===1&&r[0]instanceof Node)return r[0];let o=document.createElement("div");for(let i of r)if(i instanceof Node)o.appendChild(i);else if(typeof i=="function"){let c=document.createComment("bind:htm");o.appendChild(c);let a=ee(c,i);L(o,a)}else i!=null&&o.appendChild(document.createTextNode(String(i)));return o}function cr(t,e){if(!e)throw new Error("[Sibu] mount: container element not found. Make sure the DOM element exists before calling mount().");k(typeof t=="function"||t instanceof Node,"mount: first argument must be a component function or a DOM Node.");let n=typeof performance<"u"?performance.now():0,r=typeof t=="function"?t():t,o=typeof performance<"u"?performance.now()-n:0;e.appendChild(r);let i=globalThis.__SIBU_DEVTOOLS_GLOBAL_HOOK__;return i&&i.emit("app:init",{rootElement:r,container:e,duration:o}),{node:r,unmount(){i&&i.emit("app:unmount",{rootElement:r}),F(r),r.parentNode&&r.parentNode.removeChild(r)}}}function lr(t){return typeof t=="function"?lr(t()):t instanceof Node?t:document.createTextNode(String(t))}function lo(t,e){if(e===0)return[];let n=[],r=new Array(e);for(let a=0;a<e;a++){let l=t[a],u=0,d=n.length;for(;u<d;){let f=u+d>>1;t[n[f]]<l?u=f+1:d=f}n[u]=a,r[a]=u>0?n[u-1]:-1}let o=n.length,i=new Array(o),c=n[o-1];for(let a=o-1;a>=0;a--)i[a]=c,c=r[c];return i}function ur(t,e,n){k(typeof t=="function","each: first argument must be a function that returns an array."),k(typeof e=="function","each: second argument must be a render function."),k(n&&typeof n.key=="function","each: options.key must be a function that returns a unique key per item.");let r=document.createComment("each:anchor"),o=document.createComment("each:end"),i=[],c=new Map,a=new Map,l=[],u=new Map,d=[],f=[],y=!1,p=!1,g=n.key,b=()=>{let E=t(),T=E.length,A=r.parentNode;if(!A)return;p||(A.insertBefore(o,r.nextSibling),p=!0);let O=new Array(T);for(let m=0;m<T;m++)O[m]=g(E[m]);l.length<T&&(l=new Array(T)),a.clear();for(let m=0;m<T;m++){let _=O[m],Ee=c.get(_),Y;Ee!==void 0?Y=Ee:Y=lr(e(E[m],m)),a.set(_,Y),l[m]=Y}for(let[m,_]of c)!a.has(m)&&_.parentNode&&A.removeChild(_);if(T===0){i=O;let m=c;c=a,a=m;return}let Ir=i.length;u.clear();for(let m=0;m<Ir;m++)u.set(i[m],m);d.length<T&&(d=new Array(T),f=new Array(T));let Q=0;for(let m=0;m<T;m++){let _=u.get(O[m]);_!==void 0&&(d[Q]=m,f[Q]=_,Q++)}let ke=lo(f,Q),we=new Uint8Array(T);for(let m=0;m<ke.length;m++)we[d[ke[m]]]=1;let Z=o;for(let m=T-1;m>=0;m--){let _=l[m];we[m]||_.nextSibling!==Z&&A.insertBefore(_,Z),Z=_}i=O;let Wr=c;c=a,a=Wr,y=!0};return x(b),y||queueMicrotask(()=>{!y&&r.parentNode&&b()}),r}function pr(t){let e=document.createDocumentFragment();for(let n of t)if(n!=null)if(Array.isArray(n))for(let r of n)e.appendChild(dr(r));else e.appendChild(dr(n));return e}function dr(t){if(t==null)return document.createTextNode("");if(t instanceof Node)return t;if(typeof t=="function"){let e=t();return e instanceof Node?e:document.createTextNode(String(e??""))}return document.createTextNode(String(t))}function fr(t,e){let n=document.createComment("portal"),r=e||document.body,o=null;queueMicrotask(()=>{try{o=t(),r.appendChild(o)}catch(c){console.error("[Portal] Render error:",c)}});let i=new MutationObserver(()=>{!n.isConnected&&o&&(o.remove(),o=null,i.disconnect())});return queueMicrotask(()=>{n.parentNode&&i.observe(n.parentNode,{childList:!0})}),n}var de=new Map;function mr(t,e){de.set(t,e)}function gr(t){de.delete(t)}function pe(t){let e=de.get(t);return e?e():S({nodes:`[Component "${t}" not found]`})}function br(t){let e=S({class:"sibu-dynamic"});function n(){let r=t(),o;typeof r=="function"?o=r():o=pe(r),e.replaceChildren(o)}return x(n),e}function hr(t,e="default"){return t?.[e]}function xr(t,e){return x(()=>{e.style.display=t()?"":"none"}),e}function yr(t,e,n){let r=document.createComment("when"),o=null,i=!1,c=()=>{let a=t(),l=r.parentNode;if(!l)return;o?.parentNode&&(o.parentNode.removeChild(o),o=null);let u=a?e():n?n():null;if(u!=null){let d=u instanceof Node?u:document.createTextNode(String(u));l.insertBefore(d,r.nextSibling),o=d}i=!0};return x(c),i||queueMicrotask(()=>{!i&&r.parentNode&&c()}),r}function Tr(t,e,n){let r=document.createComment("match"),o=null,i=!1,c=()=>{let a=String(t()),l=r.parentNode;if(!l)return;o?.parentNode&&(o.parentNode.removeChild(o),o=null);let u=e[a]||n;if(u){let d=u();if(d!=null){let f=d instanceof Node?d:document.createTextNode(String(d));l.insertBefore(f,r.nextSibling),o=f}}i=!0};return x(c),i||queueMicrotask(()=>{!i&&r.parentNode&&c()}),r}var D=null;function vr(t,e){try{let n=t();return n&&typeof n.then=="function"&&n.catch(r=>{e?e(r,"async"):D?D(r,"async"):console.error("Unhandled async error in Sibu.catchError:",r)}),n}catch(n){return e?e(n,"sync"):D?D(n,"sync"):console.error("Unhandled error in Sibu.catchError:",n),null}}async function Sr(t,e){try{return await t()}catch(n){return e?e(n,"async"):D?D(n,"async"):console.error("Unhandled async error in Sibu.catchErrorAsync:",n),null}}function kr(t){D=t}var $=0,fe=new Set;function wr(t){$++;try{t()}finally{$--,$===0&&uo()}}function P(t){return $===0?!1:(fe.add(t),!0)}function Er(){return $>0}function uo(){let t=Array.from(fe);fe.clear();for(let e of t)Ne(e);Ae()}function C(t,e){let n={value:t},r=e?.name;r&&(n.__name=r);function o(){return B(n),n.value}o.__signal=n,r&&(o.__name=r);function i(a){let l=typeof a=="function"?a(n.value):a;if(Object.is(l,n.value))return;let u=n.value;n.value=l;let d=globalThis.__SIBU_DEVTOOLS_GLOBAL_HOOK__;d&&d.emit("signal:update",{signal:n,name:r,oldValue:u,newValue:l}),P(n)||q(n)}let c=globalThis.__SIBU_DEVTOOLS_GLOBAL_HOOK__;return c&&c.emit("signal:create",{signal:n,name:r,getter:o,initial:t}),[o,i]}var me=!1;function W(){return me}function ge(){me=!0}function be(){me=!1}function _r(t){ge();try{return t()}finally{be()}}function G(t){if(k(typeof t=="function","effect: argument must be a function."),W())return()=>{};let e=0,n=()=>{},r=globalThis.__SIBU_DEVTOOLS_GLOBAL_HOOK__,o=()=>{n(),e++,r&&r.emit("effect:run",{effectFn:t,runCount:e}),n=x(t,o)};return n=x(t,o),e=1,r&&r.emit("effect:create",{effectFn:t}),()=>{r&&r.emit("effect:destroy",{effectFn:t}),n()}}function K(t,e){k(typeof t=="function","derived: argument must be a getter function.");let n=e?.name,r={};r._d=!1,r._g=t;let o=()=>{r._d||(r._d=!0)};o._c=1,o._sig=r,x(()=>{r._d=!1,r._v=t()},o);let i=globalThis.__SIBU_DEVTOOLS_GLOBAL_HOOK__;function c(){if(X)return r._d&&(r._d=!1,r._v=t()),r._v;if(B(r),r._d){let a=r._v;r._d=!1,se();try{r._v=t()}finally{ae()}i&&a!==r._v&&i.emit("computed:update",{signal:r,oldValue:a,newValue:r._v})}return r._v}return n&&(c.__name=n,r.__name=n),c.__signal=r,i&&i.emit("computed:create",{signal:r,name:n,getter:c}),c}function Cr(t,e){if(k(typeof t=="function","watch: first argument must be a getter function."),k(typeof e=="function","watch: second argument must be a callback function."),W())return()=>{};let n=t();return x(()=>{let i=t();Object.is(i,n)||(e(i,n),n=i)})}function Nr(t){k(t!==null&&typeof t=="object"&&!Array.isArray(t),"store: argument must be a plain object. For arrays, use array() instead.");let e={};Object.keys(t).forEach(l=>{let[u,d]=C(t[l]);e[l]=[u,d]});let n=new Proxy({},{get(l,u){if(u in e){let d=e[u][0];return d()}},set(){throw new Error("[Sibu] store: Direct mutation is not allowed. Use actions.setState() to update store properties.")}}),r=()=>{let l={};return Object.keys(e).forEach(u=>{l[u]=e[u][0]()}),l};return[n,{setState:l=>{let u=r(),d=typeof l=="function"?l(u):l;Object.entries(d).forEach(([f,y])=>{f in e&&e[f][1](y)})},reset:()=>{Object.keys(t).forEach(l=>{let u=e[l][1];u(t[l])})},subscribe:l=>G(()=>{let u=r();l(u)}),subscribeKey:(l,u)=>{let d=e[l][0]();return G(()=>{let f=e[l][0]();if(!Object.is(f,d)){let y=d;d=f,u(f,y)}})},getSnapshot:r}]}function Ar(t){return{current:t}}function Lr(t){return K(t)}function Mr(t){return K(t)}function Rr(t=[]){let[e,n]=C([...t]);return[e,{push(...o){n(i=>[...i,...o])},pop(){let o;return n(i=>{let c=[...i];return o=c.pop(),c}),o},shift(){let o;return n(i=>{let c=[...i];return o=c.shift(),c}),o},unshift(...o){n(i=>[...o,...i])},splice(o,i=0,...c){let a=[];return n(l=>{let u=[...l];return a=u.splice(o,i,...c),u}),a},remove(o){n(i=>i.filter((c,a)=>a!==o))},removeWhere(o){n(i=>{let c=i.findIndex(o);return c===-1?i:i.filter((a,l)=>l!==c)})},set(o){n([...o])},update(o,i){n(c=>c.map((a,l)=>l===o?i:a))},updateWhere(o,i){n(c=>c.map(a=>o(a)?i(a):a))},sort(o){n(i=>[...i].sort(o))},reverse(){n(o=>[...o].reverse())},filter(o){n(i=>i.filter(o))},map(o){n(i=>i.map(o))},clear(){n([])}}]}function Or(t=[]){let e=[...t],n=null,r={};function o(){n=null,P(r)||q(r)}function i(){return B(r),n===null&&(n=Object.freeze([...e])),n}return[i,{push(...a){a.length!==0&&(e.push(...a),o())},pop(){if(e.length===0)return;let a=e.pop();return o(),a},shift(){if(e.length===0)return;let a=e.shift();return o(),a},unshift(...a){a.length!==0&&(e.unshift(...a),o())},splice(a,l=0,...u){let d=e.splice(a,l,...u);return(d.length>0||u.length>0)&&o(),d},remove(a){a<0||a>=e.length||(e.splice(a,1),o())},removeWhere(a){let l=e.findIndex(a);l!==-1&&(e.splice(l,1),o())},set(a){e=[...a],o()},update(a,l){a<0||a>=e.length||Object.is(e[a],l)||(e[a]=l,o())},updateWhere(a,l){let u=!1;for(let d=0;d<e.length;d++)if(a(e[d])){let f=l(e[d]);Object.is(e[d],f)||(e[d]=f,u=!0)}u&&o()},sort(a){e.length<=1||(e.sort(a),o())},reverse(){e.length<=1||(e.reverse(),o())},filter(a){let l=e.filter(a);l.length!==e.length&&(e=l,o())},map(a){let l=!1;for(let u=0;u<e.length;u++){let d=a(e[u],u);Object.is(e[u],d)||(e[u]=d,l=!0)}l&&o()},clear(){e.length!==0&&(e=[],o())}}]}function he(t,e){if(Object.is(t,e))return!0;if(t==null||e==null||typeof t!=typeof e||typeof t!="object")return!1;if(Array.isArray(t))return!Array.isArray(e)||t.length!==e.length?!1:t.every((o,i)=>he(o,e[i]));let n=Object.keys(t),r=Object.keys(e);return n.length!==r.length?!1:n.every(o=>he(t[o],e[o]))}function Hr(t){let e={value:t};function n(){return B(e),e.value}function r(o){let i=typeof o=="function"?o(e.value):o;he(i,e.value)||(e.value=i,P(e)||q(e))}return[n,r]}function xe(t,e){if(!(typeof document>"u"))if(e){if(e.isConnected){queueMicrotask(()=>{t()});return}let n=new MutationObserver(()=>{e.isConnected&&(n.disconnect(),t())});queueMicrotask(()=>{e.isConnected?t():n.observe(document.body,{childList:!0,subtree:!0})})}else queueMicrotask(()=>{t()})}function Br(t,e){let n=()=>{let r=new MutationObserver(()=>{e.isConnected||(r.disconnect(),t())});r.observe(document.body,{childList:!0,subtree:!0})};e.isConnected?n():xe(()=>{n()},e)}function Pr(t){let[e,n]=C(t);return{provide(r){n(r)},use(){return e},get(){return e()},set(r){n(r)}}}function ye(t){let e=null;return function(){if(e)return e();let[r,o]=C("loading"),[i,c]=C(null),a=S({class:"sibu-lazy"});return t().then(l=>{e=l.default;let u=e();a.replaceChildren(u),o("loaded")}).catch(l=>{let u=l instanceof Error?l:new Error(String(l));c(u),o("error"),a.replaceChildren(S({class:"sibu-lazy-error",nodes:`Failed to load component: ${u.message}`}))}),a.appendChild(N({class:"sibu-lazy-loading",nodes:"Loading..."})),a}}function Te({nodes:t,fallback:e}){let n=S({class:"sibu-suspense"}),r=e();return n.appendChild(r),queueMicrotask(()=>{try{let o=t();if(o.classList.contains("sibu-lazy")){let i=new MutationObserver(()=>{o.querySelector(".sibu-lazy-loading")||(i.disconnect(),n.replaceChildren(o))});i.observe(o,{childList:!0,subtree:!0}),o.querySelector(".sibu-lazy-loading")||n.replaceChildren(o)}else n.replaceChildren(o)}catch{}}),n}var po=`
|
|
3
|
+
.sibu-error-boundary {
|
|
4
|
+
position: relative;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.sibu-error-fallback {
|
|
8
|
+
border: 2px solid #dc3545;
|
|
9
|
+
border-radius: 8px;
|
|
10
|
+
padding: 20px;
|
|
11
|
+
margin: 10px 0;
|
|
12
|
+
background: linear-gradient(135deg, #fff5f5 0%, #ffebee 100%);
|
|
13
|
+
box-shadow: 0 2px 12px rgba(220, 53, 69, 0.15);
|
|
14
|
+
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.sibu-error-fallback .sibu-error-title {
|
|
18
|
+
margin: 0 0 12px 0;
|
|
19
|
+
color: #dc3545;
|
|
20
|
+
font-size: 1.1em;
|
|
21
|
+
font-weight: 600;
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
.sibu-error-fallback .sibu-error-message {
|
|
25
|
+
font-family: 'SF Mono', 'Fira Code', 'Roboto Mono', monospace;
|
|
26
|
+
background-color: rgba(0, 0, 0, 0.04);
|
|
27
|
+
padding: 10px 14px;
|
|
28
|
+
border-radius: 6px;
|
|
29
|
+
border: 1px solid rgba(0, 0, 0, 0.08);
|
|
30
|
+
margin: 10px 0;
|
|
31
|
+
color: #495057;
|
|
32
|
+
word-break: break-word;
|
|
33
|
+
font-size: 0.9em;
|
|
34
|
+
line-height: 1.5;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
.sibu-error-fallback .sibu-error-btn {
|
|
38
|
+
display: inline-flex;
|
|
39
|
+
align-items: center;
|
|
40
|
+
gap: 6px;
|
|
41
|
+
padding: 8px 18px;
|
|
42
|
+
border: none;
|
|
43
|
+
border-radius: 6px;
|
|
44
|
+
cursor: pointer;
|
|
45
|
+
font-size: 14px;
|
|
46
|
+
font-weight: 500;
|
|
47
|
+
transition: all 0.2s ease;
|
|
48
|
+
margin-top: 8px;
|
|
49
|
+
background-color: #dc3545;
|
|
50
|
+
color: white;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
.sibu-error-fallback .sibu-error-btn:hover {
|
|
54
|
+
background-color: #c82333;
|
|
55
|
+
transform: translateY(-1px);
|
|
56
|
+
box-shadow: 0 2px 8px rgba(220, 53, 69, 0.3);
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.sibu-error-fallback .sibu-error-btn:active {
|
|
60
|
+
transform: translateY(0);
|
|
61
|
+
}
|
|
62
|
+
`,Dr=!1;function fo(){if(!Dr&&typeof document<"u"){let t=I({nodes:po});document.head.appendChild(t),Dr=!0}}var ve=new WeakMap;function mo(t,e,n){let r=ve.get(t);r||(r=new Map,ve.set(t,r));let o=e.message;return r.has(o)||r.set(o,t(e,n)),r.get(o)}function zr({nodes:t,fallback:e,onError:n}){fo();let[r,o]=C(null),i=()=>{e&&ve.delete(e),o(null)},c=d=>{let f=d instanceof Error?d:new Error(String(d));return o(f),n?.(f),f},a=(d,f)=>S({class:"sibu-error-fallback",nodes:[re({nodes:"Something went wrong",class:"sibu-error-title"}),ne({nodes:d.message,class:"sibu-error-message"}),oe({nodes:"Retry",class:"sibu-error-btn",on:{click:f}})]}),l=d=>{let f=e||a;try{return mo(f,d,i)}catch(y){let p=y instanceof Error?y:new Error(String(y));return queueMicrotask(()=>{u.parentNode&&u.dispatchEvent(new CustomEvent("sibu:error-propagate",{bubbles:!0,detail:{error:p}}))}),document.createComment("error-boundary-failed")}},u=S({class:"sibu-error-boundary",nodes:()=>{let d=r();if(d)return l(d);try{let f=t();if(f&&typeof f.then=="function"){let y=S({class:"sibu-error-async"});return y.appendChild(N({class:"sibu-lazy-loading",nodes:"Loading..."})),f.then(p=>{y.replaceChildren(p)}).catch(p=>{let g=c(p);y.replaceChildren(l(g))}),y}return f}catch(f){let y=c(f);return l(y)}}});return u.addEventListener("sibu:error-propagate",d=>{if(r())return;d.stopPropagation();let y=d.detail?.error;y&&c(y)}),u}var go=`
|
|
63
|
+
@keyframes sibu-spin {
|
|
64
|
+
to { transform: rotate(360deg); }
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
@keyframes sibu-pulse {
|
|
68
|
+
0%, 100% { opacity: 1; }
|
|
69
|
+
50% { opacity: 0.4; }
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.sibu-loading {
|
|
73
|
+
display: flex;
|
|
74
|
+
align-items: center;
|
|
75
|
+
justify-content: center;
|
|
76
|
+
padding: 20px;
|
|
77
|
+
gap: 10px;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.sibu-loading-spinner {
|
|
81
|
+
width: 24px;
|
|
82
|
+
height: 24px;
|
|
83
|
+
border: 3px solid #e0e0e0;
|
|
84
|
+
border-top-color: #3b82f6;
|
|
85
|
+
border-radius: 50%;
|
|
86
|
+
animation: sibu-spin 0.8s linear infinite;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.sibu-loading-dots {
|
|
90
|
+
display: flex;
|
|
91
|
+
gap: 4px;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.sibu-loading-dot {
|
|
95
|
+
width: 8px;
|
|
96
|
+
height: 8px;
|
|
97
|
+
border-radius: 50%;
|
|
98
|
+
background-color: #3b82f6;
|
|
99
|
+
animation: sibu-pulse 1.2s ease-in-out infinite;
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
.sibu-loading-dot:nth-child(2) { animation-delay: 0.2s; }
|
|
103
|
+
.sibu-loading-dot:nth-child(3) { animation-delay: 0.4s; }
|
|
104
|
+
|
|
105
|
+
.sibu-loading-text {
|
|
106
|
+
color: #6b7280;
|
|
107
|
+
font-size: 14px;
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
.sibu-loading-sm .sibu-loading-spinner { width: 16px; height: 16px; border-width: 2px; }
|
|
111
|
+
.sibu-loading-sm .sibu-loading-dot { width: 6px; height: 6px; }
|
|
112
|
+
.sibu-loading-lg .sibu-loading-spinner { width: 40px; height: 40px; border-width: 4px; }
|
|
113
|
+
.sibu-loading-lg .sibu-loading-dot { width: 12px; height: 12px; }
|
|
114
|
+
.sibu-loading-lg .sibu-loading-dots { gap: 6px; }
|
|
115
|
+
`,jr=!1;function bo(){!jr&&typeof document<"u"&&(document.head.appendChild(I({nodes:go})),jr=!0)}function qr(t={}){bo();let{text:e,variant:n="spinner",size:r="md"}=t,o=r!=="md"?` sibu-loading-${r}`:"";return n==="dots"?S({class:`sibu-loading${o}`,nodes:[S({class:"sibu-loading-dots",nodes:[N({class:"sibu-loading-dot"}),N({class:"sibu-loading-dot"}),N({class:"sibu-loading-dot"})]}),e?N({class:"sibu-loading-text",nodes:e}):null].filter(Boolean)}):S({class:`sibu-loading${o}`,nodes:[S({class:"sibu-loading-spinner"}),e?N({class:"sibu-loading-text",nodes:e}):null].filter(Boolean)})}typeof window<"u"&&(window.Sibu=Se);return $r(ho);})();
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
import {
|
|
2
|
+
notifySubscribers,
|
|
3
|
+
recordDependency,
|
|
4
|
+
track,
|
|
5
|
+
useState
|
|
6
|
+
} from "./chunk-566Z7HXB.js";
|
|
7
|
+
|
|
8
|
+
// src/core/hooks/useEffect.ts
|
|
9
|
+
function useEffect(effectFn) {
|
|
10
|
+
let cleanupHandle = () => {
|
|
11
|
+
};
|
|
12
|
+
const subscriber = () => {
|
|
13
|
+
cleanupHandle();
|
|
14
|
+
cleanupHandle = track(effectFn, subscriber);
|
|
15
|
+
};
|
|
16
|
+
cleanupHandle = track(effectFn, subscriber);
|
|
17
|
+
return () => {
|
|
18
|
+
cleanupHandle();
|
|
19
|
+
};
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
// src/core/hooks/useComputed.ts
|
|
23
|
+
function useComputed(getter) {
|
|
24
|
+
let value;
|
|
25
|
+
const computedSignal = {};
|
|
26
|
+
const recompute = () => {
|
|
27
|
+
let next;
|
|
28
|
+
track(() => {
|
|
29
|
+
next = getter();
|
|
30
|
+
}, recompute);
|
|
31
|
+
if (Object.is(next, value)) return;
|
|
32
|
+
value = next;
|
|
33
|
+
notifySubscribers(computedSignal);
|
|
34
|
+
};
|
|
35
|
+
track(() => {
|
|
36
|
+
value = getter();
|
|
37
|
+
}, recompute);
|
|
38
|
+
return function computedGetter() {
|
|
39
|
+
recordDependency(computedSignal);
|
|
40
|
+
return value;
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
// src/core/rendering/context.ts
|
|
45
|
+
function createContext(defaultValue) {
|
|
46
|
+
const [getValue, setValue] = useState(defaultValue);
|
|
47
|
+
return {
|
|
48
|
+
provide(value) {
|
|
49
|
+
setValue(value);
|
|
50
|
+
},
|
|
51
|
+
use() {
|
|
52
|
+
return getValue;
|
|
53
|
+
},
|
|
54
|
+
get() {
|
|
55
|
+
return getValue();
|
|
56
|
+
},
|
|
57
|
+
set(value) {
|
|
58
|
+
setValue(value);
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export {
|
|
64
|
+
useEffect,
|
|
65
|
+
useComputed,
|
|
66
|
+
createContext
|
|
67
|
+
};
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import {
|
|
2
|
+
devAssert
|
|
3
|
+
} from "./chunk-MJNB47HB.js";
|
|
4
|
+
import {
|
|
5
|
+
recordDependency,
|
|
6
|
+
resumeTracking,
|
|
7
|
+
suspendTracking,
|
|
8
|
+
track,
|
|
9
|
+
trackingSuspended
|
|
10
|
+
} from "./chunk-M5GNLDEO.js";
|
|
11
|
+
|
|
12
|
+
// src/core/signals/derived.ts
|
|
13
|
+
function derived(getter, options) {
|
|
14
|
+
devAssert(typeof getter === "function", "derived: argument must be a getter function.");
|
|
15
|
+
const debugName = options?.name;
|
|
16
|
+
const cs = {};
|
|
17
|
+
cs._d = false;
|
|
18
|
+
cs._g = getter;
|
|
19
|
+
const markDirty = () => {
|
|
20
|
+
if (cs._d) return;
|
|
21
|
+
cs._d = true;
|
|
22
|
+
};
|
|
23
|
+
markDirty._c = 1;
|
|
24
|
+
markDirty._sig = cs;
|
|
25
|
+
track(() => {
|
|
26
|
+
cs._d = false;
|
|
27
|
+
cs._v = getter();
|
|
28
|
+
}, markDirty);
|
|
29
|
+
const hook = globalThis.__SIBU_DEVTOOLS_GLOBAL_HOOK__;
|
|
30
|
+
function computedGetter() {
|
|
31
|
+
if (trackingSuspended) {
|
|
32
|
+
if (cs._d) {
|
|
33
|
+
cs._d = false;
|
|
34
|
+
cs._v = getter();
|
|
35
|
+
}
|
|
36
|
+
return cs._v;
|
|
37
|
+
}
|
|
38
|
+
recordDependency(cs);
|
|
39
|
+
if (cs._d) {
|
|
40
|
+
const oldValue = cs._v;
|
|
41
|
+
cs._d = false;
|
|
42
|
+
suspendTracking();
|
|
43
|
+
try {
|
|
44
|
+
cs._v = getter();
|
|
45
|
+
} finally {
|
|
46
|
+
resumeTracking();
|
|
47
|
+
}
|
|
48
|
+
if (hook && oldValue !== cs._v) {
|
|
49
|
+
hook.emit("computed:update", { signal: cs, oldValue, newValue: cs._v });
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
return cs._v;
|
|
53
|
+
}
|
|
54
|
+
if (debugName) {
|
|
55
|
+
computedGetter.__name = debugName;
|
|
56
|
+
cs.__name = debugName;
|
|
57
|
+
}
|
|
58
|
+
computedGetter.__signal = cs;
|
|
59
|
+
if (hook) hook.emit("computed:create", { signal: cs, name: debugName, getter: computedGetter });
|
|
60
|
+
return computedGetter;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
export {
|
|
64
|
+
derived
|
|
65
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import {
|
|
2
|
+
sbSignal
|
|
3
|
+
} from "./chunk-OB2LMD7C.js";
|
|
4
|
+
|
|
5
|
+
// src/core/rendering/context.ts
|
|
6
|
+
function createContext(defaultValue) {
|
|
7
|
+
const [getValue, setValue] = sbSignal(defaultValue);
|
|
8
|
+
return {
|
|
9
|
+
provide(value) {
|
|
10
|
+
setValue(value);
|
|
11
|
+
},
|
|
12
|
+
use() {
|
|
13
|
+
return getValue;
|
|
14
|
+
},
|
|
15
|
+
get() {
|
|
16
|
+
return getValue();
|
|
17
|
+
},
|
|
18
|
+
set(value) {
|
|
19
|
+
setValue(value);
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
|
|
24
|
+
export {
|
|
25
|
+
createContext
|
|
26
|
+
};
|