@stacksjs/stx 0.2.401 → 0.2.402

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.
Files changed (162) hide show
  1. package/dist/chunk-020a4q6e.js +2 -0
  2. package/dist/chunk-0j5wwmha.js +2 -0
  3. package/dist/{chunk-197z74b9.js → chunk-111tdjzz.js} +1 -1
  4. package/dist/{chunk-21dz636m.js → chunk-14rh4kd0.js} +1 -1
  5. package/dist/chunk-1a569y4r.js +2 -0
  6. package/dist/chunk-1chgn7qv.js +2 -0
  7. package/dist/chunk-1hw8p2g4.js +2 -0
  8. package/dist/{chunk-fffbzsmv.js → chunk-21adgg8e.js} +1 -1
  9. package/dist/{chunk-x86qttwm.js → chunk-2g3ffsc9.js} +1 -1
  10. package/dist/{chunk-8xm3z6dh.js → chunk-2hy87cn4.js} +1 -1
  11. package/dist/{chunk-dz29q408.js → chunk-2m17v3yx.js} +1 -1
  12. package/dist/{chunk-k2nydt80.js → chunk-2n3twnde.js} +1 -1
  13. package/dist/{chunk-h55mae9h.js → chunk-3t953qe0.js} +1 -1
  14. package/dist/{chunk-1ktxk84n.js → chunk-3tmnemhq.js} +1 -1
  15. package/dist/{chunk-btn4481e.js → chunk-42tn0t54.js} +1 -1
  16. package/dist/{chunk-cy8hgd86.js → chunk-4azk3jdd.js} +1 -1
  17. package/dist/{chunk-v7q2nf37.js → chunk-4m2e8w2g.js} +1 -1
  18. package/dist/{chunk-c9kj8p6j.js → chunk-4yc9gx6h.js} +1 -1
  19. package/dist/chunk-55d66wh7.js +2 -0
  20. package/dist/{chunk-zh3q10wd.js → chunk-5kzcyx1w.js} +1 -1
  21. package/dist/{chunk-cd6pe75s.js → chunk-6jns68ee.js} +1 -1
  22. package/dist/chunk-702rda41.js +2 -0
  23. package/dist/chunk-7r7qcpw2.js +2 -0
  24. package/dist/{chunk-yj5gkn17.js → chunk-7vftjm43.js} +1 -1
  25. package/dist/{chunk-epzm35py.js → chunk-8aa32p8v.js} +1 -1
  26. package/dist/{chunk-zrnppyqz.js → chunk-8e287qw8.js} +1 -1
  27. package/dist/{chunk-e1rv01pn.js → chunk-8ghwewek.js} +2 -2
  28. package/dist/{chunk-p81zbym6.js → chunk-9a79ev5a.js} +1 -1
  29. package/dist/chunk-9csrj2k2.js +2 -0
  30. package/dist/{chunk-88tt0qg0.js → chunk-9rp8f7jz.js} +2 -2
  31. package/dist/chunk-9xs1ekk3.js +2 -0
  32. package/dist/{chunk-7tgjn256.js → chunk-ah8gs0q2.js} +1 -1
  33. package/dist/{chunk-aewsgyzc.js → chunk-av7a1sct.js} +1 -1
  34. package/dist/{chunk-d4km7egg.js → chunk-b1hqgm6j.js} +1 -1
  35. package/dist/{chunk-hh8abhtc.js → chunk-b5na4j0k.js} +1 -1
  36. package/dist/{chunk-bf6zcjr5.js → chunk-b5rc4t8t.js} +1 -1
  37. package/dist/{chunk-aeaf5nsy.js → chunk-b89mqprp.js} +1 -1
  38. package/dist/{chunk-j9x1hxhg.js → chunk-baa5pana.js} +1 -1
  39. package/dist/{chunk-5zmppe0c.js → chunk-bd0eyzgz.js} +1 -1
  40. package/dist/{chunk-caj47vtj.js → chunk-bdy1fpqq.js} +1 -1
  41. package/dist/chunk-bgyh22e9.js +2 -0
  42. package/dist/{chunk-pm8wzxsb.js → chunk-bs2a7a2b.js} +1 -1
  43. package/dist/{chunk-rxz43r6k.js → chunk-cevkpyn9.js} +1 -1
  44. package/dist/{chunk-61cwdy7h.js → chunk-cf05s8c1.js} +1 -1
  45. package/dist/{chunk-45etne17.js → chunk-chn6e3en.js} +1 -1
  46. package/dist/chunk-cqn8qq4v.js +2 -0
  47. package/dist/chunk-crjn0b04.js +2 -0
  48. package/dist/{chunk-0rdhrgff.js → chunk-cvkty3ha.js} +1 -1
  49. package/dist/{chunk-x2wmn8m7.js → chunk-d6rkgay9.js} +2 -2
  50. package/dist/{chunk-kfhm9vh1.js → chunk-db1bf5yj.js} +2 -2
  51. package/dist/{chunk-r1d9x0dy.js → chunk-ddh21d04.js} +1 -1
  52. package/dist/{chunk-ar5stjnb.js → chunk-dnew7qmv.js} +1 -1
  53. package/dist/{chunk-8ded3tn8.js → chunk-e5aqq9ms.js} +1 -1
  54. package/dist/{chunk-nm7jfzmz.js → chunk-eg30ksd8.js} +2 -2
  55. package/dist/{chunk-vs4dafbz.js → chunk-ek069b44.js} +1 -1
  56. package/dist/{chunk-h7sgg3vh.js → chunk-etah20m0.js} +2 -2
  57. package/dist/{chunk-1rskz446.js → chunk-ezwtd7s2.js} +1 -1
  58. package/dist/chunk-f4f5dzfg.js +2 -0
  59. package/dist/chunk-fkht7kzs.js +2 -0
  60. package/dist/{chunk-57yhrery.js → chunk-fpqz7msz.js} +1 -1
  61. package/dist/{chunk-rwtj7j0r.js → chunk-fpxz25xz.js} +1 -1
  62. package/dist/{chunk-pdxbys31.js → chunk-fwc5p9bn.js} +1 -1
  63. package/dist/{chunk-4x73bm95.js → chunk-gbwqy9py.js} +1 -1
  64. package/dist/{chunk-dvpk2rer.js → chunk-gs67nnfb.js} +1 -1
  65. package/dist/{chunk-0fwecpfm.js → chunk-gv6fnbw5.js} +2 -2
  66. package/dist/{chunk-3znzj20j.js → chunk-h37e97qq.js} +1 -1
  67. package/dist/{chunk-wmqhn6rq.js → chunk-h3zqzczc.js} +1 -1
  68. package/dist/{chunk-kdwbpcm4.js → chunk-h7qv6sc5.js} +1 -1
  69. package/dist/{chunk-gtn2agxa.js → chunk-ht9rdkf3.js} +1 -1
  70. package/dist/{chunk-h01bbt3r.js → chunk-hw96m872.js} +1 -1
  71. package/dist/{chunk-xfedcdb2.js → chunk-j665en0c.js} +1 -1
  72. package/dist/{chunk-w4nmvn5v.js → chunk-j6p78bma.js} +1 -1
  73. package/dist/{chunk-8kkqx4sc.js → chunk-j89wctm5.js} +1 -1
  74. package/dist/{chunk-twws9vvz.js → chunk-jbtzq3xt.js} +2 -2
  75. package/dist/{chunk-3769e62c.js → chunk-jct6cs2k.js} +1 -1
  76. package/dist/chunk-jmek11fc.js +2 -0
  77. package/dist/{chunk-4eyzkbzj.js → chunk-kdqcb0r5.js} +1 -1
  78. package/dist/chunk-kvdd2zfn.js +2 -0
  79. package/dist/{chunk-mgndzdqy.js → chunk-m28xqhyz.js} +1 -1
  80. package/dist/chunk-mjdsjxm5.js +2 -0
  81. package/dist/{chunk-g7qmxjyc.js → chunk-mjearf0g.js} +1 -1
  82. package/dist/{chunk-980w4zcq.js → chunk-mntzk6ga.js} +1 -1
  83. package/dist/{chunk-kyw2cbvn.js → chunk-msecn1gm.js} +1 -1
  84. package/dist/chunk-n9cgqpe2.js +2 -0
  85. package/dist/{chunk-7bym5kky.js → chunk-n9nb4e1v.js} +168 -168
  86. package/dist/chunk-n9wmhtap.js +2 -0
  87. package/dist/{chunk-7c8r36ve.js → chunk-ndydf37f.js} +3 -3
  88. package/dist/{chunk-eqhsprr0.js → chunk-nn42gs3q.js} +1 -1
  89. package/dist/{chunk-hm66z7e8.js → chunk-nt03zdme.js} +1 -1
  90. package/dist/{chunk-r0jqyxbc.js → chunk-pj0jjn5b.js} +1 -1
  91. package/dist/chunk-pp8e3t71.js +2 -0
  92. package/dist/{chunk-zstrcmbj.js → chunk-ptad3t7a.js} +335 -326
  93. package/dist/{chunk-d0qy1ezf.js → chunk-qbc0bebg.js} +2 -2
  94. package/dist/chunk-qmr1we72.js +2 -0
  95. package/dist/{chunk-fsvkqeya.js → chunk-qnye902b.js} +1 -1
  96. package/dist/{chunk-bdz7nznw.js → chunk-rk8p4b1z.js} +2 -2
  97. package/dist/chunk-s35w8xjx.js +2 -0
  98. package/dist/{chunk-h8zp2fz9.js → chunk-saf4xhac.js} +1 -1
  99. package/dist/chunk-scak53zc.js +2 -0
  100. package/dist/chunk-scn75qrm.js +2 -0
  101. package/dist/{chunk-q4v62yed.js → chunk-szcxpbfn.js} +38 -6
  102. package/dist/chunk-t3pfdz1r.js +2 -0
  103. package/dist/{chunk-76q768gt.js → chunk-tev79q0a.js} +1 -1
  104. package/dist/{chunk-csgshaeh.js → chunk-v54tq312.js} +1 -1
  105. package/dist/{chunk-wh8vwykh.js → chunk-vaxepwj5.js} +1 -1
  106. package/dist/chunk-vwe0fvez.js +2 -0
  107. package/dist/chunk-vxxj6sqn.js +2 -0
  108. package/dist/{chunk-ekvejzvk.js → chunk-wheh08v2.js} +1 -1
  109. package/dist/{chunk-5zapxgys.js → chunk-wm07h8q1.js} +1 -1
  110. package/dist/{chunk-8qzc5n61.js → chunk-x1c4vcds.js} +1 -1
  111. package/dist/{chunk-ef3y864p.js → chunk-xd2bapap.js} +1 -1
  112. package/dist/{chunk-pqc4sv02.js → chunk-xe06rkka.js} +2 -2
  113. package/dist/chunk-xn9t0hnt.js +2 -0
  114. package/dist/{chunk-4cv7bw5e.js → chunk-y9f9g2kh.js} +2 -2
  115. package/dist/{chunk-re9rv45k.js → chunk-za3zzk6p.js} +1 -1
  116. package/dist/cli.js +14 -14
  117. package/dist/composables/use-offline.d.ts +6 -5
  118. package/dist/composables/use-offline.js +20 -1
  119. package/dist/craft-entry.js +1 -1
  120. package/dist/craft.js +1 -1
  121. package/dist/database.js +1 -1
  122. package/dist/doctor.d.ts +35 -0
  123. package/dist/doctor.js +95 -0
  124. package/dist/offline/app-service-worker.js +15 -6
  125. package/dist/process.d.ts +0 -3
  126. package/dist/process.js +12 -3
  127. package/dist/pwa.js +2 -2
  128. package/dist/signal-processing.d.ts +29 -11
  129. package/dist/signal-processing.js +40 -0
  130. package/dist/signals.js +37 -5
  131. package/dist/ssg.js +2 -2
  132. package/dist/visual-testing.js +1 -1
  133. package/package.json +5 -5
  134. package/dist/chunk-07syq64h.js +0 -2
  135. package/dist/chunk-0nqcv7z7.js +0 -2
  136. package/dist/chunk-160zge7a.js +0 -2
  137. package/dist/chunk-19kj26z3.js +0 -2
  138. package/dist/chunk-1nj174s0.js +0 -2
  139. package/dist/chunk-1s9jswhp.js +0 -2
  140. package/dist/chunk-2m88psbh.js +0 -2
  141. package/dist/chunk-2x9gpv2d.js +0 -2
  142. package/dist/chunk-3t17hkar.js +0 -2
  143. package/dist/chunk-3wsrhb1a.js +0 -2
  144. package/dist/chunk-65y5abx7.js +0 -2
  145. package/dist/chunk-6n0jamtd.js +0 -2
  146. package/dist/chunk-7vnkqnyh.js +0 -2
  147. package/dist/chunk-8ywzw4h9.js +0 -2
  148. package/dist/chunk-9hh5eg8y.js +0 -2
  149. package/dist/chunk-bgy4hwh4.js +0 -2
  150. package/dist/chunk-ch2aycnm.js +0 -2
  151. package/dist/chunk-cmnve329.js +0 -2
  152. package/dist/chunk-k9t7pyb8.js +0 -2
  153. package/dist/chunk-kp4ja0w3.js +0 -2
  154. package/dist/chunk-kxxph6d4.js +0 -2
  155. package/dist/chunk-s4yq7q1d.js +0 -2
  156. package/dist/chunk-vyn2y774.js +0 -2
  157. package/dist/chunk-w680bfze.js +0 -2
  158. package/dist/chunk-waz1sddd.js +0 -2
  159. package/dist/chunk-wdszjnbp.js +0 -2
  160. package/dist/chunk-x3h04mgd.js +0 -2
  161. package/dist/chunk-y5gyez1p.js +0 -2
  162. package/dist/chunk-zfs01pjr.js +0 -2
@@ -0,0 +1,2 @@
1
+ // @bun
2
+ import{_f as a}from"./chunk-8aa32p8v.js";import"./chunk-eg30ksd8.js";import"./chunk-g64qyhhb.js";import"./chunk-szcxpbfn.js";import"./chunk-mnk5mdwp.js";import"./chunk-7eea1cse.js";import"./chunk-etah20m0.js";import"./chunk-ptad3t7a.js";import"./chunk-y9f9g2kh.js";import"./chunk-ah8gs0q2.js";import"./chunk-saf4xhac.js";import"./chunk-wheh08v2.js";import"./chunk-jct6cs2k.js";import"./chunk-ndydf37f.js";import"./chunk-7vftjm43.js";import"./chunk-4azk3jdd.js";import"./chunk-jbtzq3xt.js";import"./chunk-mjearf0g.js";import"./chunk-9rp8f7jz.js";import"./chunk-8ghwewek.js";import"./chunk-rk8p4b1z.js";import"./chunk-fpxz25xz.js";import"./chunk-nn42gs3q.js";import"./chunk-v54tq312.js";import"./chunk-qbc0bebg.js";import"./chunk-4yc9gx6h.js";import"./chunk-d6rkgay9.js";import"./chunk-cevkpyn9.js";export{a as buildForProduction};
@@ -0,0 +1,2 @@
1
+ // @bun
2
+ import{hi as a}from"./chunk-mwh3ymwc.js";import"./chunk-cevkpyn9.js";export{a as rewriteImagesWithSiblings};
@@ -1,2 +1,2 @@
1
1
  // @bun
2
- import{Qh as a,Rh as b,Sh as c,Th as d,Uh as e,Vh as f,Wh as g,Xh as h,Yh as i,Zh as j,_h as k}from"./chunk-9368t9jm.js";import"./chunk-rxz43r6k.js";export{i as processStaticDirectives,b as processPartialHydrationDirectives,h as onHydrated,g as isHydrated,d as hydrateIsland,e as hydrateByStrategy,f as hydrateAll,c as generatePartialHydrationCSS,j as generateIslandManifest,k as default,a as createIslandRegistry};
2
+ import{Qh as a,Rh as b,Sh as c,Th as d,Uh as e,Vh as f,Wh as g,Xh as h,Yh as i,Zh as j,_h as k}from"./chunk-9368t9jm.js";import"./chunk-cevkpyn9.js";export{i as processStaticDirectives,b as processPartialHydrationDirectives,h as onHydrated,g as isHydrated,d as hydrateIsland,e as hydrateByStrategy,f as hydrateAll,c as generatePartialHydrationCSS,j as generateIslandManifest,k as default,a as createIslandRegistry};
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import{wl as QJ}from"./chunk-h7sgg3vh.js";import{xl as WJ}from"./chunk-2andsajh.js";import{Fr as XJ,Gr as qJ,em as GJ}from"./chunk-zstrcmbj.js";import{ys as ZJ,zs as $J}from"./chunk-h8zp2fz9.js";import{Ss as YJ,Ws as u}from"./chunk-7c8r36ve.js";import{At as c}from"./chunk-yj5gkn17.js";import X from"path";import O from"fs";function UJ(J){if(!J||typeof J!=="object")return!1;let K=J;return typeof K.message==="string"&&(K.name==="BuildMessage"||K.name==="ResolveMessage"||("position"in K))}function LJ(J){if(J&&typeof J==="object"&&Array.isArray(J.errors))return J.errors;return[J]}function b(J,K){let $=[];for(let W of LJ(J)){if(UJ(W)){let Y=W.position||void 0;$.push({file:K||Y?.file,line:Y?.line,column:Y?.column,message:W.message??"",lineText:Y?.lineText});continue}$.push({file:K,message:W instanceof Error?W.message:String(W)})}return $}function t(J,K){return b(J,K).map(($)=>{let W=$.file?`${$.file}${$.line?`:${$.line}${$.column?`:${$.column}`:""}`:""}`:"",Y=$.lineText?`
2
+ import{wl as QJ}from"./chunk-etah20m0.js";import{xl as WJ}from"./chunk-2andsajh.js";import{Gr as XJ,Hr as qJ,em as GJ}from"./chunk-ptad3t7a.js";import{As as $J,zs as ZJ}from"./chunk-saf4xhac.js";import{Ts as YJ,Xs as u}from"./chunk-ndydf37f.js";import{Bt as c}from"./chunk-7vftjm43.js";import X from"path";import O from"fs";function UJ(J){if(!J||typeof J!=="object")return!1;let K=J;return typeof K.message==="string"&&(K.name==="BuildMessage"||K.name==="ResolveMessage"||("position"in K))}function LJ(J){if(J&&typeof J==="object"&&Array.isArray(J.errors))return J.errors;return[J]}function b(J,K){let $=[];for(let W of LJ(J)){if(UJ(W)){let Y=W.position||void 0;$.push({file:K||Y?.file,line:Y?.line,column:Y?.column,message:W.message??"",lineText:Y?.lineText});continue}$.push({file:K,message:W instanceof Error?W.message:String(W)})}return $}function t(J,K){return b(J,K).map(($)=>{let W=$.file?`${$.file}${$.line?`:${$.line}${$.column?`:${$.column}`:""}`:""}`:"",Y=$.lineText?`
3
3
  ${$.lineText.trim()}`:"";return W?`${W}: ${$.message}${Y}`:`${$.message}${Y}`}).join(`
4
4
  `)}var TJ=9;function P(J,K,$){return/^(?:(?:stx|ui)\.config\.[cm]?[jt]s|runtime-config-(?:server|loader)\.[cm]?[jt]s)$/.test(X.basename(J))||QJ(J,K,$)}var HJ=1,zJ=new Map,f=600,AJ=100,g=new Map;async function MJ(J){let K=g.get(J)??0;if(K>0&&K<AJ){g.set(J,K+1);return}g.set(J,1);try{let $=(await O.promises.readdir(J)).filter((z)=>z.endsWith(".js"));if($.length<=f)return;let Y=(await Promise.all($.map(async(z)=>{try{return{name:z,at:(await O.promises.stat(X.join(J,z))).mtimeMs}}catch{return null}}))).filter((z)=>z!==null);Y.sort((z,H)=>H.at-z.at);for(let z of Y.slice(f)){let H=z.name.slice(0,-3);await O.promises.rm(X.join(J,`${H}.js`),{force:!0}),await O.promises.rm(X.join(J,`${H}.deps.json`),{force:!0})}x("pruned bundle cache to",f,"entries")}catch{}}function nJ(J){return zJ.get(J)??[]}function h(J,K){if(J)zJ.set(J,K)}function CJ(J=process.env){return J.STX_DEBUG==="true"||J.STX_DEBUG==="1"}function x(...J){if(CJ())console.log("[stx:bundler]",...J)}var n=[];function r(J,K,$){n.push({filePath:J||"<inline>",message:K,details:$})}function oJ(){return n.slice()}function lJ(){n.length=0}var p;function dJ(J){p=J}function a(){if(p)return p;try{let J=qJ.strict;return typeof J==="object"&&J!==null?J.bundlerFallback??"warn":"warn"}catch{return"warn"}}var e=[/^stx$/,/^@stacksjs\/stx$/,/^@stores$/,/^stx\/stores$/,/^@composables$/];function sJ(J){let K=/^[ \t]*import[ \t]+(?!type(?:[ \t]|{))[\s\S]*?\s+from\s+['"]([^'"]+)['"][ \t]*;?/gm,$;while(($=K.exec(J))!==null){let Y=$[1];if(!e.some((H)=>H.test(Y)))return x("detected user import:",Y),!0}let W=/^[ \t]*import[ \t]+['"]([^'"]+)['"]/gm;while(($=W.exec(J))!==null){let Y=$[1];if(/\.css(?:\?.*)?$/.test(Y))continue;if(!e.some((H)=>H.test(Y)))return x("detected side-effect import:",Y),!0}return!1}var v="stx-module:",xJ=/\.(?:[cm]?[jt]sx?|json)$/i;function IJ(J,K){return X.relative(J,K).split(X.sep).join("/")}function _J(J,K){if(K.size===0)return J;return J.replace(/^([ \t]*import\s+(?:[^;"']*?\s+from\s+)?)(["'])([^"']+)\2/gm,($,W,Y,z)=>{let H=K.get(z);return H&&!z.startsWith(v)?`${W}${Y}${H}${Y}`:$})}function NJ(J,K){let $=0,W=(z)=>{let H=`__stxMod${$++}`,j=JSON.stringify(z);return K.push(`var ${H} = globalThis.__stxModules && globalThis.__stxModules[${j}];`,`if (${H} === undefined) throw new Error("[stx] module " + ${JSON.stringify(j)} + " is not registered on this page (#1957)");`),H},Y=(z,H)=>{for(let j of z.split(",")){let T=j.trim();if(!T)continue;let Q=T.match(/^("(?:[^"\\]|\\.)*"|[\w$]+)(?:\s+as\s+([\w$]+))?$/);if(!Q)continue;let Z=Q[1].startsWith('"')?JSON.parse(Q[1]):Q[1],G=Q[2]??Z;K.push(`var ${G} = ${H}[${JSON.stringify(Z)}];`)}};return J=J.replace(/^[ \t]*import\s+([^;"']*?)\s+from\s+["'](stx-module:[^"']+)["'];?[ \t]*$/gm,(z,H,j)=>{let T=j.slice(v.length),Q=W(T),Z=H.trim(),G=Z.match(/^([\w$]+)\s*(?:,\s*|$)/);if(G&&!Z.startsWith("{")&&!Z.startsWith("*"))K.push(`var ${G[1]} = ${Q}.default;`),Z=Z.slice(G[0].length).trim();let q=Z.match(/^\*\s*as\s+([\w$]+)$/);if(q)K.push(`var ${q[1]} = ${Q};`);else if(Z.startsWith("{"))Y(Z.replace(/^\{|\}$/g,""),Q);return""}),J=J.replace(/^[ \t]*import\s+["'](stx-module:[^"']+)["'];?[ \t]*$/gm,(z,H)=>{return W(H.slice(v.length)),""}),J}function JJ(J){let K=[J,`${J}.ts`,`${J}.tsx`,`${J}.js`,`${J}.mjs`,`${J}.jsx`,X.join(J,"index.ts"),X.join(J,"index.tsx"),X.join(J,"index.js"),X.join(J,"index.mjs")];for(let $ of K)try{if(O.existsSync($)&&O.statSync($,{throwIfNoEntry:!1})?.isFile())return $}catch{}return}function SJ(J,K,$,W,Y,z=new Map,H){let j=(Q,Z,G)=>{if(P(Z,J,H))return null;if(!Y||Q!==$||!xJ.test(Z))return null;try{if(!O.statSync(Z,{throwIfNoEntry:!1})?.isFile())return null}catch{return null}W.add(Z);let q=`${v}${IJ(process.cwd(),Z)}`;return z.set(G,q),{path:q,external:!0}},T=(Q,Z)=>{let G=Q===$?K:X.dirname(Q),q=X.resolve(G,Z);return JJ(q)??q};return{name:"stx-client-bundle",setup(Q){if(Q.onResolve({filter:/^(stx|@stacksjs\/stx)$/},(Z)=>({path:Z.path,external:!0})),Q.onResolve({filter:/^(@stores|@composables|stx\/stores)$/},(Z)=>({path:Z.path,external:!0})),Q.onResolve({filter:/^\//},(Z)=>{let G=JJ(Z.path);if(G){let q=j(Z.importer,G,Z.path);if(q)return q;if(G!==$)W.add(G);return{path:G}}return{path:Z.path,external:!0}}),Q.onResolve({filter:/^\.\.?\//},(Z)=>{let G=T(Z.importer,Z.path),q=j(Z.importer,G,Z.path);if(q)return q;return W.add(G),{path:G}}),Q.onResolve({filter:/^[@~]\//},(Z)=>{let G=X.resolve(J,Z.path.slice(2)),q=[G,`${G}.ts`,`${G}.tsx`,`${G}.js`,`${G}.mjs`,`${G}.jsx`,X.join(G,"index.ts"),X.join(G,"index.tsx"),X.join(G,"index.js"),X.join(G,"index.mjs")];for(let w of q)if(O.existsSync(w)&&O.statSync(w,{throwIfNoEntry:!1})?.isFile()){let y=j(Z.importer,w,Z.path);if(y)return y;return x(`resolved ${Z.path[0]}/ import:`,Z.path,"\u2192",w),W.add(w),{path:w}}return console.warn(`[stx:bundler] could not resolve ${Z.path[0]}/ import:`,Z.path),{path:G}}),Y)Q.onResolve({filter:/^(?!node:|bun:)(?:@[\w.-]+\/)?[\w.-]/},(Z)=>{if(Z.importer!==$)return;let G=`${v}npm:${Z.path}`;return z.set(Z.path,G),{path:G,external:!0}});Q.onLoad({filter:/\.(?:[cm]?[jt]sx?|json)$/},(Z)=>{if(P(Z.path,J,H))throw Error(`Server-only API source cannot be imported by a client script: ${Z.path}`);let G=X.extname(Z.path).toLowerCase(),q=G===".json"?"json":G===".tsx"?"tsx":G===".jsx"?"jsx":G===".ts"||G===".mts"||G===".cts"?"ts":"js";if(Z.path!==$)W.add(Z.path);return{contents:O.readFileSync(Z.path,"utf8"),loader:q}})}}}var m=new Map,D=YJ(64),KJ=Symbol.for("stx.client-bundle-build-queue");function yJ(J){let K=globalThis,W=(K[KJ]??Promise.resolve()).then(J,J);return K[KJ]=W.then(()=>{return},()=>{return}),W}async function iJ(J,K,$={}){let W=$.projectRoot||process.cwd(),Y=(await XJ(W)).serverApi,z=$.minify??!1,H=$.externalizeUserModules??!0,j=$.cacheDir||c(W,"bundle-cache"),T=new Bun.CryptoHasher("md5");T.update(`${TJ}\x00${WJ()}\x00${JSON.stringify(Y??!1)}\x00${H?"registry":"inline"}\x00${J}\x00${K}`);let Q=T.digest("hex").slice(0,12),Z=X.join(j,`${Q}.js`),G=D.get(Z);if(G){if(u(G.files)&&G.files.every((A)=>!P(A.path,W,Y))){x("memo hit:",Q);let A=G.files.map((M)=>M.path);return h(K,A),$.collectInputs?.push(...A),G.code}D.delete(Z),x("memo invalidated by dep change:",Q)}let q=X.join(j,`${Q}.deps.json`),w=Bun.file(Z);if(await w.exists()){let A=Bun.file(q),M=!1,U=null;if(await A.exists())try{let N=JSON.parse(await A.text());if(N.metadataVersion!==HJ||!Array.isArray(N.files))M=!1;else U=N.files,M=!0;if(U&&(!u(U)||U.some((B)=>P(B.path,W,Y))))M=!1}catch{M=!1}if(M){if(x("cache hit:",Q),U)h(K,U.map((B)=>B.path)),$.collectInputs?.push(...U.map((B)=>B.path));let N=await w.text();if(U)D.set(Z,{code:N,files:U});return N}x("cache invalidated by dep change:",Q)}let y=m.get(Q);if(y){let A=await y;if($.collectInputs)$.collectInputs.push(...(D.get(Z)?.files??[]).map((M)=>M.path));return A}let I=yJ(()=>FJ(J,K,{projectRoot:W,minify:z,cacheDir:j,hash:Q,cachePath:Z,depsPath:q,collectInputs:$.collectInputs,externalizeUserModules:H,serverApi:Y}));m.set(Q,I);try{return await I}finally{m.delete(Q)}}var BJ=0;function RJ(J){return`${J}-${process.pid}-${++BJ}`}async function FJ(J,K,$){let{projectRoot:W,minify:Y,cacheDir:z,hash:H,cachePath:j,depsPath:T,externalizeUserModules:Q}=$,Z=c(W,"bundle-tmp"),G=RJ(H),q=X.join(Z,`${G}.ts`),w=X.join(Z,"out",G);O.mkdirSync(Z,{recursive:!0}),O.mkdirSync(w,{recursive:!0});let y=X.dirname(K),I=new Set,A=/^[ \t]*(export\s+)?(?:const|let|var)\s+(?:\{([^}]+)\}|(\w+))/gm,M=/^[ \t]*(export\s+)?(?:async\s+)?function\s+(\w+)/gm,U=ZJ(J),{depths:N,balanced:B}=$J(U),o=(L)=>!B||N[L]===0,C;while((C=A.exec(U))!==null){if(C[1])continue;if(!o(C.index))continue;if(C[2])C[2].split(",").forEach((L)=>{let k=DJ(L);if(k)I.add(k)});else if(C[3])I.add(C[3])}while((C=M.exec(U))!==null){if(C[1])continue;if(!o(C.index))continue;I.add(C[2])}let VJ=I.size>0?`
5
5
  export { ${[...I].join(", ")} }`:"";await Bun.write(q,J+VJ),x("bundling:",H,"from:",X.basename(K));let l=new Set,d=new Map;try{let L=await Bun.build({entrypoints:[q],outdir:w,target:"browser",format:"esm",minify:Y,plugins:[SJ(W,y,q,l,Q,d,$.serverApi)],define:{"process.env.NODE_ENV":Y?'"production"':'"development"',...GJ()},root:W});if(!L.success){let S=L.logs.filter((R)=>R.level==="error").map((R)=>R.message).join(", ")||`Unable to bundle ${X.basename(K)}`,F=b(L.logs,K||void 0);if(console.warn("[stx:bundler] build failed:",S),r(K||"",S,F),a()==="error")throw Error(S);return J}let k="";for(let V of L.outputs){k=await V.text();break}let _=[];for(let V of k.matchAll(/^\s*export\s*\{([^}]*)\}\s*;?\s*$/gm))for(let S of V[1].split(",")){let F=S.trim().match(/^([A-Za-z_$][\w$]*)\s+as\s+([A-Za-z_$][\w$]*)$/);if(F){_.push([F[2],F[1]]);continue}let R=S.trim();if(/^[A-Za-z_$][\w$]*$/.test(R))_.push([R,R])}let s=[];k=NJ(_J(k,d),s);let kJ=k.match(/^\s*import\s+[^;]+;?\s*$/gm)||[];k=k.replace(/^\s*import\s+[^;]+;?\s*$/gm,"").replace(/^\s*export\s*\{[^}]*\}\s*;?\s*$/gm,"").replace(/^\s*export\s+default\s+.*$/gm,"").trim();let i=`__stxBundle_${H}`,jJ=_.map(([V,S])=>`${JSON.stringify(V)}: ${S}`).join(", "),OJ=_.map(([V])=>`var ${V} = undefined;`).join(`
@@ -0,0 +1,2 @@
1
+ // @bun
2
+ import{ok as a,pk as b,qk as c,rk as d}from"./chunk-b5na4j0k.js";import"./chunk-xe06rkka.js";import"./chunk-ptad3t7a.js";import"./chunk-y9f9g2kh.js";import"./chunk-ah8gs0q2.js";import"./chunk-saf4xhac.js";import"./chunk-wheh08v2.js";import"./chunk-jct6cs2k.js";import"./chunk-ndydf37f.js";import"./chunk-7vftjm43.js";import"./chunk-4azk3jdd.js";import"./chunk-jbtzq3xt.js";import"./chunk-mjearf0g.js";import"./chunk-9rp8f7jz.js";import"./chunk-8ghwewek.js";import"./chunk-rk8p4b1z.js";import"./chunk-fpxz25xz.js";import"./chunk-nn42gs3q.js";import"./chunk-v54tq312.js";import"./chunk-qbc0bebg.js";import"./chunk-4yc9gx6h.js";import"./chunk-d6rkgay9.js";import"./chunk-cevkpyn9.js";export{b as getAvailableTargets,c as getAvailableFormats,d as default,a as buildNative};
@@ -0,0 +1,2 @@
1
+ // @bun
2
+ import{Ao as j,Bo as k,Co as l,Do as m,Eo as n,ro as a,so as b,to as c,uo as d,vo as e,wo as f,xo as g,yo as h,zo as i}from"./chunk-ptad3t7a.js";import"./chunk-y9f9g2kh.js";import"./chunk-ah8gs0q2.js";import"./chunk-saf4xhac.js";import"./chunk-wheh08v2.js";import"./chunk-jct6cs2k.js";import"./chunk-ndydf37f.js";import"./chunk-7vftjm43.js";import"./chunk-4azk3jdd.js";import"./chunk-jbtzq3xt.js";import"./chunk-mjearf0g.js";import"./chunk-9rp8f7jz.js";import"./chunk-8ghwewek.js";import"./chunk-rk8p4b1z.js";import"./chunk-fpxz25xz.js";import"./chunk-nn42gs3q.js";import"./chunk-v54tq312.js";import"./chunk-qbc0bebg.js";import"./chunk-4yc9gx6h.js";import"./chunk-d6rkgay9.js";import"./chunk-cevkpyn9.js";export{n as stripStxRuntimeImports,b as scanScriptTags,m as rewriteStxImportSpecifiers,k as processSignals,i as processScriptSetup,f as preEvalLiteralReactiveIfs,c as parseLoopExpression,d as hasSignalsSyntax,l as findMarkupIndexOutsideScripts,j as extractExports,h as convertSignalLoopsToAttributes,e as convertSignalDirectivesToAttributes,g as convertServerLoopAttributesToDirectives,a as clearScriptScanCache};
@@ -0,0 +1,2 @@
1
+ // @bun
2
+ import{ws as a,xs as b}from"./chunk-ah8gs0q2.js";import"./chunk-cevkpyn9.js";export{b as resolveStxTargets,a as looksLikeGlob};
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import"./chunk-rxz43r6k.js";var Y=null,S=[],F=new WeakMap;function I(z){let K=z,B=new Set,G={get value(){if(Y){let H=F.get(G);if(!H)H=new Set,F.set(G,H);H.add(Y)}return K},set value(H){if(!Object.is(K,H)){K=H,B.forEach((J)=>J(H));let L=F.get(G);if(L)L.forEach((J)=>J())}},subscribe(H){return B.add(H),()=>B.delete(H)},peek(){return K}};return G}function W(z){return z!==null&&typeof z==="object"&&"value"in z&&"subscribe"in z&&"peek"in z}function P(z){return W(z)?z.value:z}function j(z){let K={};for(let B in z)if(Object.prototype.hasOwnProperty.call(z,B))K[B]=I(z[B]);return K}function D(z){return I(z)}function U(z){let K=typeof z==="function",B=K?z:z.get,G=K?void 0:z.set,H=K?Object.is:z.equals||Object.is,L,J=!0,Q=new Set,X=new Set,_=()=>{if(J=!0,X.size>0){let N=T.value;X.forEach(($)=>$(N))}};function Z(){Q.clear();let N=Y;Y=_,S.push(_);try{return B()}finally{S.pop(),Y=N}}let T={get value(){if(Y){let N=F.get(T);if(!N)N=new Set,F.set(T,N);N.add(Y)}if(J){let N=Z();if(!H(L,N))L=N;J=!1}return L},set value(N){if(G)G(N);else console.warn("Computed property is readonly")},subscribe(N){return X.add(N),()=>X.delete(N)},peek(){if(J)L=B(),J=!1;return L},invalidate(){J=!0},get dirty(){return J},get deps(){return Q}};return T}function x(z,K,B={}){let{immediate:G=!1,deep:H=!1,flush:L="pre",once:J=!1}=B,Q,X=!0,_=!1,Z=()=>{if(W(z))return H?q(z.value):z.value;return z()},T=()=>{if(!X||_)return;let M=Z();if(Q!==void 0&&Object.is(Q,M)&&!H)return;let A=()=>{if(K(M,Q),Q=H?q(M):M,J)$()};if(L==="sync")A();else if(L==="post")queueMicrotask(A);else Promise.resolve().then(A)},N=null;if(W(z))N=z.subscribe(()=>T());else N=U(z).subscribe(()=>T());if(G)Q=void 0,T();else Q=Z();let $=()=>{if(X=!1,N)N(),N=null};return $.pause=()=>{_=!0},$.resume=()=>{_=!1},$}function E(z,K,B={}){let{immediate:G=!1,once:H=!1}=B,L=z.map((T)=>W(T)?T.value:void 0),J=!0,Q=!1,X=()=>{if(!J||Q)return;let T=z.map((N)=>W(N)?N.value:void 0);if(K(T,L),L=[...T],H)Z()},_=z.map((T)=>{if(W(T))return T.subscribe(()=>X());return()=>{}});if(G)X();let Z=()=>{J=!1,_.forEach((T)=>T())};return Z.pause=()=>{Q=!0},Z.resume=()=>{Q=!1},Z}function y(z,K={}){let{flush:B="pre"}=K,G,H=!0,L=!1,J=()=>{if(!H||L)return;if(G)G();let X=Y;Y=J,S.push(J);try{G=z()}finally{S.pop(),Y=X}};if(B==="sync")J();else if(B==="post")queueMicrotask(J);else Promise.resolve().then(J);let Q=()=>{if(H=!1,G)G()};return Q.pause=()=>{L=!0},Q.resume=()=>{L=!1},Q}function C(z,K={},B){let G=/@computed\s*\(\s*(\w+)\s*,\s*(.+?)\s*\)/gi;return z.replace(G,(H,L,J)=>{try{let X=Function(...Object.keys(K),`return ${J}`)(...Object.values(K));return K[L]=X,`<!-- computed: ${L} = ${X} -->`}catch(Q){return`<!-- computed error: ${L} - ${Q} -->`}})}function R(z,K={},B){let G=/@watch\s*\(\s*(\w+)\s*\)\s*([\s\S]*?)@endwatch/gi;return z.replace(G,(H,L,J)=>{return`
2
+ import"./chunk-cevkpyn9.js";var Y=null,S=[],F=new WeakMap;function I(z){let K=z,B=new Set,G={get value(){if(Y){let H=F.get(G);if(!H)H=new Set,F.set(G,H);H.add(Y)}return K},set value(H){if(!Object.is(K,H)){K=H,B.forEach((J)=>J(H));let L=F.get(G);if(L)L.forEach((J)=>J())}},subscribe(H){return B.add(H),()=>B.delete(H)},peek(){return K}};return G}function W(z){return z!==null&&typeof z==="object"&&"value"in z&&"subscribe"in z&&"peek"in z}function P(z){return W(z)?z.value:z}function j(z){let K={};for(let B in z)if(Object.prototype.hasOwnProperty.call(z,B))K[B]=I(z[B]);return K}function D(z){return I(z)}function U(z){let K=typeof z==="function",B=K?z:z.get,G=K?void 0:z.set,H=K?Object.is:z.equals||Object.is,L,J=!0,Q=new Set,X=new Set,_=()=>{if(J=!0,X.size>0){let N=T.value;X.forEach(($)=>$(N))}};function Z(){Q.clear();let N=Y;Y=_,S.push(_);try{return B()}finally{S.pop(),Y=N}}let T={get value(){if(Y){let N=F.get(T);if(!N)N=new Set,F.set(T,N);N.add(Y)}if(J){let N=Z();if(!H(L,N))L=N;J=!1}return L},set value(N){if(G)G(N);else console.warn("Computed property is readonly")},subscribe(N){return X.add(N),()=>X.delete(N)},peek(){if(J)L=B(),J=!1;return L},invalidate(){J=!0},get dirty(){return J},get deps(){return Q}};return T}function x(z,K,B={}){let{immediate:G=!1,deep:H=!1,flush:L="pre",once:J=!1}=B,Q,X=!0,_=!1,Z=()=>{if(W(z))return H?q(z.value):z.value;return z()},T=()=>{if(!X||_)return;let M=Z();if(Q!==void 0&&Object.is(Q,M)&&!H)return;let A=()=>{if(K(M,Q),Q=H?q(M):M,J)$()};if(L==="sync")A();else if(L==="post")queueMicrotask(A);else Promise.resolve().then(A)},N=null;if(W(z))N=z.subscribe(()=>T());else N=U(z).subscribe(()=>T());if(G)Q=void 0,T();else Q=Z();let $=()=>{if(X=!1,N)N(),N=null};return $.pause=()=>{_=!0},$.resume=()=>{_=!1},$}function E(z,K,B={}){let{immediate:G=!1,once:H=!1}=B,L=z.map((T)=>W(T)?T.value:void 0),J=!0,Q=!1,X=()=>{if(!J||Q)return;let T=z.map((N)=>W(N)?N.value:void 0);if(K(T,L),L=[...T],H)Z()},_=z.map((T)=>{if(W(T))return T.subscribe(()=>X());return()=>{}});if(G)X();let Z=()=>{J=!1,_.forEach((T)=>T())};return Z.pause=()=>{Q=!0},Z.resume=()=>{Q=!1},Z}function y(z,K={}){let{flush:B="pre"}=K,G,H=!0,L=!1,J=()=>{if(!H||L)return;if(G)G();let X=Y;Y=J,S.push(J);try{G=z()}finally{S.pop(),Y=X}};if(B==="sync")J();else if(B==="post")queueMicrotask(J);else Promise.resolve().then(J);let Q=()=>{if(H=!1,G)G()};return Q.pause=()=>{L=!0},Q.resume=()=>{L=!1},Q}function C(z,K={},B){let G=/@computed\s*\(\s*(\w+)\s*,\s*(.+?)\s*\)/gi;return z.replace(G,(H,L,J)=>{try{let X=Function(...Object.keys(K),`return ${J}`)(...Object.values(K));return K[L]=X,`<!-- computed: ${L} = ${X} -->`}catch(Q){return`<!-- computed error: ${L} - ${Q} -->`}})}function R(z,K={},B){let G=/@watch\s*\(\s*(\w+)\s*\)\s*([\s\S]*?)@endwatch/gi;return z.replace(G,(H,L,J)=>{return`
3
3
  <script data-watch="${`watch-${Math.random().toString(36).substring(2,9)}`}">
4
4
  (function() {
5
5
  // Watch implementation for ${L}
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import{mh as x,rh as B,sh as c,th as u,uh as n}from"./chunk-6rzwef28.js";import{$w as v}from"./chunk-rxz43r6k.js";import{resolve as JJ,basename as WJ,extname as _J,join as LJ}from"path";import{mkdir as QJ}from"fs/promises";var ZJ={enabled:!0,directory:".stx/media-cache",maxAge:30,maxSize:2000,cacheTranscoded:!0,cacheThumbnails:!0,cacheManifests:!0};class V{config;constructor(K={}){this.config={...ZJ,...K}}async get(K,J){return c(K,J,"video",this.config)}async set(K,J,X){return u(K,J,X,"video",this.config)}async clear(){return n("video",this.config)}updateConfig(K){this.config={...this.config,...K}}}var S=null;function D(K){if(!S)S=new V(K);else if(K)S.updateConfig(K);return S}async function q(K,J,X){let N=X?{directory:`${X.outputDir}/../.cache`}:{};return D(N).get(K,J)}async function b(K,J,X,N){let Z=N?{directory:`${N.outputDir}/../.cache`}:{};return D(Z).set(K,J,X)}async function $J(){return D().clear()}import{resolve as y,basename as P,extname as f,join as U}from"path";import{mkdir as g}from"fs/promises";async function m(){try{return await import("ts-videos")}catch{return null}}async function h(K,J,X,N){let Z=await m();if(!Z)return console.warn("[stx-media] ts-videos not installed, cannot generate poster"),null;try{let $=y(K);if(!await B($))return null;await g(X,{recursive:!0});let Y=await x($),z=P(K,f(K)),G=J.format||"webp",M=J.timestamp||0,E=`${z}-poster-${Y}.${G}`,W=U(X,E),Q=await Z.extractThumbnails($,{timestamps:[M],width:J.width||1280,height:J.height,format:G,quality:J.quality||85,outputDir:X,outputPattern:E.replace(`.${G}`,"")});if(Q&&Q.length>0){let _=Q[0];return{path:W,url:`${N}/${E}`,width:_.width||J.width||1280,height:_.height||720,timestamp:M,size:_.size||0}}return null}catch($){return console.warn(`[stx-media] Failed to generate poster: ${$}`),null}}async function d(K,J,X,N){let Z=await m();if(!Z)return[];try{let $=y(K);if(!await B($))return[];await g(X,{recursive:!0});let Y=await x($),z=P(K,f(K)),G=J.format||"webp",W=(await new Z.Input($).getInfo()).duration||60,Q=J.count||10,_=J.interval||W/Q,O=[];for(let w=0;w<Q&&w*_<W;w++)O.push(w*_);let L=await Z.extractThumbnails($,{timestamps:O,width:J.width||320,format:G,quality:J.quality||80,outputDir:X,outputPattern:`${z}-thumb-${Y}`});if(L&&L.length>0)return L.map((w,j)=>({path:w.path||U(X,`${z}-thumb-${Y}-${j}.${G}`),url:`${N}/${z}-thumb-${Y}-${j}.${G}`,width:w.width||J.width||320,height:w.height||180,timestamp:O[j],size:w.size||0}));return[]}catch($){return console.warn(`[stx-media] Failed to generate thumbnails: ${$}`),[]}}async function zJ(K,J,X,N){let Z=await m();if(!Z)return console.warn("[stx-media] ts-videos not installed, cannot generate sprite sheet"),null;try{let $=y(K);if(!await B($))return null;await g(X,{recursive:!0});let Y=await x($),z=P(K,f(K)),E=(await new Z.Input($).getInfo()).duration||60,W=J.columns||10,Q=J.interval||5,_=J.thumbnailWidth||160,O=J.thumbnailHeight||90,L=J.format||"jpeg",w=Math.ceil(E/Q),j=Math.ceil(w/W),F=`${z}-sprite-${Y}.${L}`,k=U(X,F),T=[];for(let I=0;I<w;I++)T.push(I*Q);let A=await Z.extractThumbnails($,{timestamps:T,width:_,height:O,format:L,quality:J.quality||70,outputDir:U(X,".temp")});if(!A||A.length===0)return null;try{let I=await import("ts-images"),H=W*_,kJ=j*O,jJ=await I.createSprite({images:A.map((YJ)=>YJ.path),columns:W,padding:0,outputPath:k,format:L,quality:J.quality||70});return{url:`${N}/${F}`,path:k,columns:W,rows:j,thumbnailWidth:_,thumbnailHeight:O,interval:Q,totalFrames:w}}catch{return console.warn("[stx-media] ts-images not installed, sprite sheet generation skipped"),null}}catch($){return console.warn(`[stx-media] Failed to generate sprite sheet: ${$}`),null}}import{resolve as r,basename as e,extname as i,join as C}from"path";import{mkdir as R,writeFile as o}from"fs/promises";async function t(){try{return await import("ts-videos")}catch{return null}}var s=[{label:"1080p",width:1920,height:1080,bitrate:5000000,audioBitrate:192000},{label:"720p",width:1280,height:720,bitrate:2500000,audioBitrate:128000},{label:"480p",width:854,height:480,bitrate:1e6,audioBitrate:96000},{label:"360p",width:640,height:360,bitrate:600000,audioBitrate:64000}];async function p(K,J,X,N,Z){let $=await t();if(!$)return console.warn("[stx-media] ts-videos not installed, cannot generate HLS manifest"),null;try{let Y=r(K);if(!await B(Y))return null;let z=await x(Y),G=e(K,i(K)),M=C(X,`${G}-${z}-hls`);await R(M,{recursive:!0});let E=J.length>0?J:s,W=Z?.segmentDuration||6,O=(await new $.Input(Y).getInfo()).duration||0,L=[],w=0;for(let k of E){let T=C(M,k.label);await R(T,{recursive:!0});let A=`${k.label}.m3u8`,I=C(T,A);try{let H=await $.generateHLS(Y,{outputDir:T,segmentDuration:W,width:k.width,height:k.height,videoBitrate:k.bitrate,audioBitrate:k.audioBitrate,playlistName:k.label});if(H)L.push({quality:k,url:`${N}/${G}-${z}-hls/${k.label}/${A}`,path:I}),w+=H.segmentCount||Math.ceil(O/W)}catch(H){console.warn(`[stx-media] Failed to generate HLS for ${k.label}: ${H}`)}}if(L.length===0)return null;let j=C(M,"master.m3u8"),F=GJ(L,N,G,z);return await o(j,F),{manifestUrl:`${N}/${G}-${z}-hls/master.m3u8`,manifestPath:j,playlists:L,segmentCount:w,duration:O}}catch(Y){return console.warn(`[stx-media] Failed to generate HLS manifest: ${Y}`),null}}function GJ(K,J,X,N){let Z=["#EXTM3U","#EXT-X-VERSION:3"];for(let $ of K){let{quality:Y}=$,z=Y.bitrate+(Y.audioBitrate||128000),G=`${Y.width}x${Y.height||Math.round(Y.width*9/16)}`;Z.push(`#EXT-X-STREAM-INF:BANDWIDTH=${z},RESOLUTION=${G},NAME="${Y.label}"`,`${Y.label}/${Y.label}.m3u8`)}return Z.join(`
2
+ import{mh as x,rh as B,sh as c,th as u,uh as n}from"./chunk-6rzwef28.js";import{ax as v}from"./chunk-cevkpyn9.js";import{resolve as JJ,basename as WJ,extname as _J,join as LJ}from"path";import{mkdir as QJ}from"fs/promises";var ZJ={enabled:!0,directory:".stx/media-cache",maxAge:30,maxSize:2000,cacheTranscoded:!0,cacheThumbnails:!0,cacheManifests:!0};class V{config;constructor(K={}){this.config={...ZJ,...K}}async get(K,J){return c(K,J,"video",this.config)}async set(K,J,X){return u(K,J,X,"video",this.config)}async clear(){return n("video",this.config)}updateConfig(K){this.config={...this.config,...K}}}var S=null;function D(K){if(!S)S=new V(K);else if(K)S.updateConfig(K);return S}async function q(K,J,X){let N=X?{directory:`${X.outputDir}/../.cache`}:{};return D(N).get(K,J)}async function b(K,J,X,N){let Z=N?{directory:`${N.outputDir}/../.cache`}:{};return D(Z).set(K,J,X)}async function $J(){return D().clear()}import{resolve as y,basename as P,extname as f,join as U}from"path";import{mkdir as g}from"fs/promises";async function m(){try{return await import("ts-videos")}catch{return null}}async function h(K,J,X,N){let Z=await m();if(!Z)return console.warn("[stx-media] ts-videos not installed, cannot generate poster"),null;try{let $=y(K);if(!await B($))return null;await g(X,{recursive:!0});let Y=await x($),z=P(K,f(K)),G=J.format||"webp",M=J.timestamp||0,E=`${z}-poster-${Y}.${G}`,W=U(X,E),Q=await Z.extractThumbnails($,{timestamps:[M],width:J.width||1280,height:J.height,format:G,quality:J.quality||85,outputDir:X,outputPattern:E.replace(`.${G}`,"")});if(Q&&Q.length>0){let _=Q[0];return{path:W,url:`${N}/${E}`,width:_.width||J.width||1280,height:_.height||720,timestamp:M,size:_.size||0}}return null}catch($){return console.warn(`[stx-media] Failed to generate poster: ${$}`),null}}async function d(K,J,X,N){let Z=await m();if(!Z)return[];try{let $=y(K);if(!await B($))return[];await g(X,{recursive:!0});let Y=await x($),z=P(K,f(K)),G=J.format||"webp",W=(await new Z.Input($).getInfo()).duration||60,Q=J.count||10,_=J.interval||W/Q,O=[];for(let w=0;w<Q&&w*_<W;w++)O.push(w*_);let L=await Z.extractThumbnails($,{timestamps:O,width:J.width||320,format:G,quality:J.quality||80,outputDir:X,outputPattern:`${z}-thumb-${Y}`});if(L&&L.length>0)return L.map((w,j)=>({path:w.path||U(X,`${z}-thumb-${Y}-${j}.${G}`),url:`${N}/${z}-thumb-${Y}-${j}.${G}`,width:w.width||J.width||320,height:w.height||180,timestamp:O[j],size:w.size||0}));return[]}catch($){return console.warn(`[stx-media] Failed to generate thumbnails: ${$}`),[]}}async function zJ(K,J,X,N){let Z=await m();if(!Z)return console.warn("[stx-media] ts-videos not installed, cannot generate sprite sheet"),null;try{let $=y(K);if(!await B($))return null;await g(X,{recursive:!0});let Y=await x($),z=P(K,f(K)),E=(await new Z.Input($).getInfo()).duration||60,W=J.columns||10,Q=J.interval||5,_=J.thumbnailWidth||160,O=J.thumbnailHeight||90,L=J.format||"jpeg",w=Math.ceil(E/Q),j=Math.ceil(w/W),F=`${z}-sprite-${Y}.${L}`,k=U(X,F),T=[];for(let I=0;I<w;I++)T.push(I*Q);let A=await Z.extractThumbnails($,{timestamps:T,width:_,height:O,format:L,quality:J.quality||70,outputDir:U(X,".temp")});if(!A||A.length===0)return null;try{let I=await import("ts-images"),H=W*_,kJ=j*O,jJ=await I.createSprite({images:A.map((YJ)=>YJ.path),columns:W,padding:0,outputPath:k,format:L,quality:J.quality||70});return{url:`${N}/${F}`,path:k,columns:W,rows:j,thumbnailWidth:_,thumbnailHeight:O,interval:Q,totalFrames:w}}catch{return console.warn("[stx-media] ts-images not installed, sprite sheet generation skipped"),null}}catch($){return console.warn(`[stx-media] Failed to generate sprite sheet: ${$}`),null}}import{resolve as r,basename as e,extname as i,join as C}from"path";import{mkdir as R,writeFile as o}from"fs/promises";async function t(){try{return await import("ts-videos")}catch{return null}}var s=[{label:"1080p",width:1920,height:1080,bitrate:5000000,audioBitrate:192000},{label:"720p",width:1280,height:720,bitrate:2500000,audioBitrate:128000},{label:"480p",width:854,height:480,bitrate:1e6,audioBitrate:96000},{label:"360p",width:640,height:360,bitrate:600000,audioBitrate:64000}];async function p(K,J,X,N,Z){let $=await t();if(!$)return console.warn("[stx-media] ts-videos not installed, cannot generate HLS manifest"),null;try{let Y=r(K);if(!await B(Y))return null;let z=await x(Y),G=e(K,i(K)),M=C(X,`${G}-${z}-hls`);await R(M,{recursive:!0});let E=J.length>0?J:s,W=Z?.segmentDuration||6,O=(await new $.Input(Y).getInfo()).duration||0,L=[],w=0;for(let k of E){let T=C(M,k.label);await R(T,{recursive:!0});let A=`${k.label}.m3u8`,I=C(T,A);try{let H=await $.generateHLS(Y,{outputDir:T,segmentDuration:W,width:k.width,height:k.height,videoBitrate:k.bitrate,audioBitrate:k.audioBitrate,playlistName:k.label});if(H)L.push({quality:k,url:`${N}/${G}-${z}-hls/${k.label}/${A}`,path:I}),w+=H.segmentCount||Math.ceil(O/W)}catch(H){console.warn(`[stx-media] Failed to generate HLS for ${k.label}: ${H}`)}}if(L.length===0)return null;let j=C(M,"master.m3u8"),F=GJ(L,N,G,z);return await o(j,F),{manifestUrl:`${N}/${G}-${z}-hls/master.m3u8`,manifestPath:j,playlists:L,segmentCount:w,duration:O}}catch(Y){return console.warn(`[stx-media] Failed to generate HLS manifest: ${Y}`),null}}function GJ(K,J,X,N){let Z=["#EXTM3U","#EXT-X-VERSION:3"];for(let $ of K){let{quality:Y}=$,z=Y.bitrate+(Y.audioBitrate||128000),G=`${Y.width}x${Y.height||Math.round(Y.width*9/16)}`;Z.push(`#EXT-X-STREAM-INF:BANDWIDTH=${z},RESOLUTION=${G},NAME="${Y.label}"`,`${Y.label}/${Y.label}.m3u8`)}return Z.join(`
3
3
  `)}async function l(K,J,X,N,Z){let $=await t();if(!$)return console.warn("[stx-media] ts-videos not installed, cannot generate DASH manifest"),null;try{let Y=r(K);if(!await B(Y))return null;let z=await x(Y),G=e(K,i(K)),M=C(X,`${G}-${z}-dash`);await R(M,{recursive:!0});let E=J.length>0?J:s,W=Z?.segmentDuration||4,Q=Z?.minBufferTime||2,L=(await new $.Input(Y).getInfo()).duration||0,w=[],j=[];for(let A of E){let I=C(M,A.label);await R(I,{recursive:!0});try{if(await $.generateDASH(Y,{outputDir:I,segmentDuration:W,width:A.width,height:A.height,videoBitrate:A.bitrate,audioBitrate:A.audioBitrate})){if(w.push({bandwidth:A.bitrate,width:A.width,height:A.height||Math.round(A.width*9/16),url:`${N}/${G}-${z}-dash/${A.label}/video`}),A.audioBitrate)j.push({bandwidth:A.audioBitrate,url:`${N}/${G}-${z}-dash/${A.label}/audio`})}}catch(H){console.warn(`[stx-media] Failed to generate DASH for ${A.label}: ${H}`)}}if(w.length===0)return null;let F=C(M,"manifest.mpd"),k=NJ(w,j,L,W,Q);await o(F,k);let T=[{type:"video",representations:w}];if(j.length>0)T.push({type:"audio",representations:j});return{manifestUrl:`${N}/${G}-${z}-dash/manifest.mpd`,manifestPath:F,adaptationSets:T,duration:L}}catch(Y){return console.warn(`[stx-media] Failed to generate DASH manifest: ${Y}`),null}}function NJ(K,J,X,N,Z){let $=a(X),Y=a(Z),z=`<?xml version="1.0" encoding="UTF-8"?>
4
4
  <MPD xmlns="urn:mpeg:dash:schema:mpd:2011"
5
5
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
@@ -1,3 +1,3 @@
1
1
  // @bun
2
- import{xl as G}from"./chunk-2andsajh.js";import{vq as U,zq as B}from"./chunk-zstrcmbj.js";import{Ts as O}from"./chunk-7c8r36ve.js";import{At as L}from"./chunk-yj5gkn17.js";import{$w as y}from"./chunk-rxz43r6k.js";import X from"fs";import Z from"path";var H=new Map,$=new Map;async function p(j){let J;for(let V=0;V<3;V++)try{let q=(await X.promises.stat(j)).mtime.getTime(),W=$.get(j);if(W&&W.mtime===q)return W.content;let I=await Bun.file(j).text(),T=(await X.promises.stat(j)).mtime.getTime();if(T!==q)continue;return $.set(j,{content:I,mtime:T}),I}catch(Q){J=Q;break}throw $.delete(j),Error(`File not found: ${j}${J?` (${J.message})`:""}`)}function m(j){$.delete(j)}function f(j){for(let z of $.keys())if(z.startsWith(j))$.delete(z)}var M=null,v=null,b=null;function r(j){b=j}async function k(j=!1){let z=b??await import("./chunk-mgndzdqy.js");if(j)return z.generateSignalsRuntimeDev();if(M===null)M=z.generateSignalsRuntime();return M}var N=null;async function R(){if(N===null){let{getRouterScript:j}=await import("./chunk-p81zbym6.js");N=j()}return N}var x={};async function d(j,z=!1){let J=j==="runtime"?await k(z):await R(),V=j==="runtime"&&z?"runtime-debug":j,Q=x[V];if(!Q||Q.content!==J)Q={content:J,hash:Bun.hash(J).toString(16).padStart(16,"0").slice(0,16)},x[V]=Q;return{content:J,hash:Q.hash,url:`/_stx/${j}.${Q.hash}.js`}}var E=500,Y=new Map;function w(j){return L(process.cwd(),"module-bundles",`${j}.js`)}function c(j){let z=Bun.hash(j).toString(16).padStart(16,"0").slice(0,16),J=Y.has(z);if(J)Y.delete(z);Y.set(z,j);while(Y.size>E)Y.delete(Y.keys().next().value);if(!J)try{let V=w(z);if(!X.existsSync(V))X.mkdirSync(Z.dirname(V),{recursive:!0}),X.writeFileSync(V,j)}catch{}return`/_stx/modules.${z}.js`}function l(j){if(!/^[0-9a-f]{16}$/.test(j))return;let z=Y.get(j);if(z!==void 0)return z;try{return X.readFileSync(w(j),"utf8")}catch{return}}function o(){$.clear(),B(),O(),M=null,v=null,N=null}function A(j){let z={debug:j.debug===!0,middleware:(j.middleware??[]).map((J)=>({name:J.name,timing:J.timing,handler:String(J.handler)})),customDirectives:(j.customDirectives??[]).map((J)=>({name:J.name,hasEndTag:J.hasEndTag===!0,rawParams:J.rawParams===!0,handler:String(J.handler)}))};return new Bun.CryptoHasher("sha1").update(JSON.stringify(z)).digest("hex")}async function s(j,z){try{if(!z.cachePath)return null;let J=Z.resolve(z.cachePath),V=Z.join(J,`${D(j)}.html`),Q=Z.join(J,`${D(j)}.meta.json`);if(!await U(V)||!await U(Q))return null;let q=await Bun.file(Q).text(),W=JSON.parse(q);if(W.cacheVersion!==z.cacheVersion)return null;if(W.engine!==G())return null;if(W.optionsSignature!==A(z))return null;if((await X.promises.stat(j)).mtime.getTime()>W.mtime)return null;for(let K of W.dependencies)if(await U(K)){if((await X.promises.stat(K)).mtime.getTime()>W.mtime)return null}else return null;return await Bun.file(V).text()}catch(J){return console.warn(`Cache error for ${j}:`,J),null}}async function n(j,z,J,V){try{if(!V.cachePath)return;let Q=Z.resolve(V.cachePath);await X.promises.mkdir(Q,{recursive:!0});let q=Z.join(Q,`${D(j)}.html`),W=Z.join(Q,`${D(j)}.meta.json`),I=await X.promises.stat(j);await Bun.write(q,z);let K={sourcePath:j,mtime:I.mtime.getTime(),dependencies:Array.from(J),cacheVersion:V.cacheVersion,engine:G(),optionsSignature:A(V),generatedAt:Date.now()};await Bun.write(W,JSON.stringify(K,null,2)),H.set(j,{output:z,mtime:I.mtime.getTime(),dependencies:J})}catch(Q){console.warn(`Failed to cache template ${j}:`,Q)}}var F=16;function D(j){return new Bun.CryptoHasher("sha1").update(j).digest("hex").substring(0,F)}
2
+ import{xl as G}from"./chunk-2andsajh.js";import{Aq as B,wq as U}from"./chunk-ptad3t7a.js";import{Us as O}from"./chunk-ndydf37f.js";import{Bt as L}from"./chunk-7vftjm43.js";import{ax as y}from"./chunk-cevkpyn9.js";import X from"fs";import Z from"path";var H=new Map,$=new Map;async function p(j){let J;for(let V=0;V<3;V++)try{let q=(await X.promises.stat(j)).mtime.getTime(),W=$.get(j);if(W&&W.mtime===q)return W.content;let I=await Bun.file(j).text(),T=(await X.promises.stat(j)).mtime.getTime();if(T!==q)continue;return $.set(j,{content:I,mtime:T}),I}catch(Q){J=Q;break}throw $.delete(j),Error(`File not found: ${j}${J?` (${J.message})`:""}`)}function m(j){$.delete(j)}function f(j){for(let z of $.keys())if(z.startsWith(j))$.delete(z)}var M=null,v=null,b=null;function r(j){b=j}async function k(j=!1){let z=b??await import("./chunk-m28xqhyz.js");if(j)return z.generateSignalsRuntimeDev();if(M===null)M=z.generateSignalsRuntime();return M}var N=null;async function R(){if(N===null){let{getRouterScript:j}=await import("./chunk-9a79ev5a.js");N=j()}return N}var x={};async function d(j,z=!1){let J=j==="runtime"?await k(z):await R(),V=j==="runtime"&&z?"runtime-debug":j,Q=x[V];if(!Q||Q.content!==J)Q={content:J,hash:Bun.hash(J).toString(16).padStart(16,"0").slice(0,16)},x[V]=Q;return{content:J,hash:Q.hash,url:`/_stx/${j}.${Q.hash}.js`}}var E=500,Y=new Map;function w(j){return L(process.cwd(),"module-bundles",`${j}.js`)}function c(j){let z=Bun.hash(j).toString(16).padStart(16,"0").slice(0,16),J=Y.has(z);if(J)Y.delete(z);Y.set(z,j);while(Y.size>E)Y.delete(Y.keys().next().value);if(!J)try{let V=w(z);if(!X.existsSync(V))X.mkdirSync(Z.dirname(V),{recursive:!0}),X.writeFileSync(V,j)}catch{}return`/_stx/modules.${z}.js`}function l(j){if(!/^[0-9a-f]{16}$/.test(j))return;let z=Y.get(j);if(z!==void 0)return z;try{return X.readFileSync(w(j),"utf8")}catch{return}}function o(){$.clear(),B(),O(),M=null,v=null,N=null}function A(j){let z={debug:j.debug===!0,middleware:(j.middleware??[]).map((J)=>({name:J.name,timing:J.timing,handler:String(J.handler)})),customDirectives:(j.customDirectives??[]).map((J)=>({name:J.name,hasEndTag:J.hasEndTag===!0,rawParams:J.rawParams===!0,handler:String(J.handler)}))};return new Bun.CryptoHasher("sha1").update(JSON.stringify(z)).digest("hex")}async function s(j,z){try{if(!z.cachePath)return null;let J=Z.resolve(z.cachePath),V=Z.join(J,`${D(j)}.html`),Q=Z.join(J,`${D(j)}.meta.json`);if(!await U(V)||!await U(Q))return null;let q=await Bun.file(Q).text(),W=JSON.parse(q);if(W.cacheVersion!==z.cacheVersion)return null;if(W.engine!==G())return null;if(W.optionsSignature!==A(z))return null;if((await X.promises.stat(j)).mtime.getTime()>W.mtime)return null;for(let K of W.dependencies)if(await U(K)){if((await X.promises.stat(K)).mtime.getTime()>W.mtime)return null}else return null;return await Bun.file(V).text()}catch(J){return console.warn(`Cache error for ${j}:`,J),null}}async function n(j,z,J,V){try{if(!V.cachePath)return;let Q=Z.resolve(V.cachePath);await X.promises.mkdir(Q,{recursive:!0});let q=Z.join(Q,`${D(j)}.html`),W=Z.join(Q,`${D(j)}.meta.json`),I=await X.promises.stat(j);await Bun.write(q,z);let K={sourcePath:j,mtime:I.mtime.getTime(),dependencies:Array.from(J),cacheVersion:V.cacheVersion,engine:G(),optionsSignature:A(V),generatedAt:Date.now()};await Bun.write(W,JSON.stringify(K,null,2)),H.set(j,{output:z,mtime:I.mtime.getTime(),dependencies:J})}catch(Q){console.warn(`Failed to cache template ${j}:`,Q)}}var F=16;function D(j){return new Bun.CryptoHasher("sha1").update(j).digest("hex").substring(0,F)}
3
3
  export{H as Nj,p as Oj,m as Pj,f as Qj,r as Rj,k as Sj,R as Tj,d as Uj,c as Vj,l as Wj,o as Xj,s as Yj,n as Zj,D as _j};
@@ -1,2 +1,2 @@
1
1
  // @bun
2
- import{Cg as a,Dg as b,Eg as c,Fg as d,Gg as e,Hg as f,Ig as g,Jg as h,Kg as i,Lg as j,Mg as k,Ng as l}from"./chunk-9vwpf0bk.js";import"./chunk-rxz43r6k.js";export{g as toUsers,f as toUser,c as stopBroadcasting,b as startBroadcasting,d as loadChannels,a as getBroadcastServer,j as channel,h as broadcastPrivate,i as broadcastPresence,e as broadcast,l as BroadcastServer,k as Broadcast};
2
+ import{Cg as a,Dg as b,Eg as c,Fg as d,Gg as e,Hg as f,Ig as g,Jg as h,Kg as i,Lg as j,Mg as k,Ng as l}from"./chunk-9vwpf0bk.js";import"./chunk-cevkpyn9.js";export{g as toUsers,f as toUser,c as stopBroadcasting,b as startBroadcasting,d as loadChannels,a as getBroadcastServer,j as channel,h as broadcastPrivate,i as broadcastPresence,e as broadcast,l as BroadcastServer,k as Broadcast};
@@ -1,2 +1,2 @@
1
1
  // @bun
2
- import{mh as x,rh as M,sh as C,th as v,uh as P}from"./chunk-6rzwef28.js";import{$w as y}from"./chunk-rxz43r6k.js";import{resolve as h,basename as f,extname as u,join as m}from"path";import{mkdir as l}from"fs/promises";var I={enabled:!0,directory:".stx/media-cache",maxAge:30,maxSize:500,cacheVariants:!0,cachePlaceholders:!0};class z{config;constructor(J={}){this.config={...I,...J}}async get(J,Z){return C(J,Z,"image",this.config)}async set(J,Z,Y){return v(J,Z,Y,"image",this.config)}async clear(){return P("image",this.config)}updateConfig(J){this.config={...this.config,...J}}}var H=null;function S(J){if(!H)H=new z(J);else if(J)H.updateConfig(J);return H}async function w(J,Z,Y){let K=Y?{directory:`${Y.outputDir}/../.cache`}:{};return S(K).get(J,Z)}async function Q(J,Z,Y,K){let X=K?{directory:`${K.outputDir}/../.cache`}:{};return S(X).set(J,Z,Y)}async function d(){return S().clear()}async function R(){try{return await import("ts-images")}catch{return null}}function b(J){switch(J){case"quality":return{jpeg:{quality:90,mozjpeg:!0,progressive:!0},png:{compressionLevel:6,palette:!1},webp:{quality:90,effort:6,smartSubsample:!0},avif:{quality:85,effort:6}};case"performance":return{jpeg:{quality:70,mozjpeg:!0,progressive:!0},png:{compressionLevel:9,palette:!0},webp:{quality:70,effort:4,smartSubsample:!0},avif:{quality:60,effort:2}};case"web":default:return{jpeg:{quality:82,mozjpeg:!0,progressive:!0},png:{compressionLevel:8,palette:!1},webp:{quality:82,effort:5,smartSubsample:!0},avif:{quality:75,effort:4}}}}function p(J,Z){let Y=Z?b(Z):b("web"),K=J.formatQuality||{};return{jpeg:{...Y.jpeg,...K.jpeg},png:{...Y.png,...K.png},webp:{...Y.webp,...K.webp},avif:{...Y.avif,...K.avif}}}async function g(J,Z,Y){let K=await R();if(!K)return console.warn("[stx-media] ts-images not installed, skipping optimization"),{src:J,processed:!1};let X=await w(J,Z,Y);if(X)return X;try{let N=h(J);if(!await M(N))return{src:J,processed:!1,errors:[`Source file not found: ${J}`]};let L=p(Y,Z.preset),V=Y.outputDir||"dist/images",F=Y.baseUrl||"/images";await l(V,{recursive:!0});let q=await x(N),U=f(J,u(J)),E=Z.outputFormat?[Z.outputFormat]:Y.defaultFormats||["avif","webp","jpeg"],G={src:J,processed:!0,variants:[],hash:q},j=null;if(Z.transformations&&Z.transformations.length>0)j=await D(N,Z.transformations,K);for(let $ of E){let A=L[$]||{},W=`${U}-${q}.${$}`,_=m(V,W);try{let O=await K.optimizeImage({input:j||N,output:_,format:$,quality:A.quality,progressive:A.progressive});if(O){if(G.variants.push({path:_,url:`${F}/${W}`,width:O.width||0,height:O.height||0,format:$,size:O.outputSize||0}),!G.originalWidth&&O.width)G.originalWidth=O.width,G.originalHeight=O.height}}catch(O){G.errors=G.errors||[],G.errors.push(`Failed to optimize ${$}: ${O}`)}}if(Z.embedThumbhash||Z.placeholder==="thumbhash")try{let $=await K.generateThumbHash(N);G.placeholder=$.dataUrl}catch($){G.errors=G.errors||[],G.errors.push(`Failed to generate thumbhash: ${$}`)}if(Z.useDominantColor)try{let $=await K.generatePlaceholder(N,{strategy:"dominant-color"});G.dominantColor=$.dominantColor}catch($){G.errors=G.errors||[],G.errors.push(`Failed to extract dominant color: ${$}`)}return await Q(J,Z,G,Y),G}catch(N){return{src:J,processed:!1,errors:[`Processing failed: ${N}`]}}}async function n(J,Z,Y,K){let X=await R();if(!X)return{success:!1,error:"ts-images not installed"};try{return{success:!0,size:(await X.optimizeImage({input:J,output:K,format:Z,quality:Y}))?.outputSize}}catch(N){return{success:!1,error:String(N)}}}async function D(J,Z,Y){let K=Y||await R();if(!K)return console.warn("[stx-media] ts-images not installed, skipping transformations"),null;try{let X=await K.decode(J);for(let N of Z){let L=N.options||{};switch(N.type){case"resize":if(L.width||L.height)X=await K.resize(X,{width:L.width,height:L.height,fit:L.fit});break;case"blur":if(L.sigma!==void 0)X=await K.blur(X,L.sigma);break;case"sharpen":if(L.amount!==void 0)X=await K.sharpen(X,L.amount);break;case"grayscale":X=await K.grayscale(X);break;case"rotate":if(L.angle!==void 0)X=await K.rotate(X,L.angle);break;case"flip":X=await K.flip(X);break;case"flop":X=await K.flop(X);break;case"brightness":if(L.value!==void 0)X=await K.brightness(X,L.value);break;case"contrast":if(L.value!==void 0)X=await K.contrast(X,L.value);break;case"saturation":if(L.value!==void 0)X=await K.saturation(X,L.value);break}}return await K.encode(X,"png")}catch(X){return console.error(`[stx-media] Transformation failed: ${X}`),null}}import{resolve as c,basename as i,extname as r,join as o}from"path";import{mkdir as a}from"fs/promises";async function e(){try{return await import("ts-images")}catch{return null}}var s=[320,480,640,768,1024,1280,1536,1920];async function t(J,Z,Y){let K=await e();if(!K)return console.warn("[stx-media] ts-images not installed, skipping responsive generation"),null;let X=c(J);if(!await M(X))return console.warn(`[stx-media] Source file not found: ${J}`),null;try{let N=Z.responsiveWidths||Y.breakpoints||s,L=Z.formats||Y.defaultFormats||["avif","webp","jpeg"],V=Y.outputDir||"dist/images",F=Y.baseUrl||"/images";await a(V,{recursive:!0});let q=await x(X),U=i(J,r(J)),E=Y.formatQuality||{jpeg:{quality:82},png:{quality:80},webp:{quality:82},avif:{quality:75}},G={src:J,byFormat:{},srcsets:{}};for(let $ of L){G.byFormat[$]=[];let A=[];for(let W of N){let _=`${U}-${W}w-${q}.${$}`,O=o(V,_),B=`${F}/${_}`;try{let T=E[$]?.quality||80;if(await M(O)){G.byFormat[$].push({path:O,url:B,width:W,height:0,format:$,size:0}),A.push(`${B} ${W}w`);continue}let k=await K.processImage({input:X,output:O,format:$,quality:T,resize:{width:W}});if(k)G.byFormat[$].push({path:O,url:B,width:W,height:k.height||Math.round(W*(k.height||1)/(k.width||1)),format:$,size:k.outputSize||0}),A.push(`${B} ${W}w`)}catch(T){console.warn(`[stx-media] Failed to generate ${$} at ${W}w: ${T}`)}}G.srcsets[$]=A.join(", ")}let j=Z.placeholder||Y.placeholderStrategy||"thumbhash";if(j!=="none")try{if(j==="thumbhash"){let $=await K.generateThumbHash(X);G.placeholder={dataURL:$.dataUrl,width:$.width||32,height:$.height||32,strategy:"thumbhash"}}else{let $=await K.generatePlaceholder(X,{strategy:j,width:20});G.placeholder={dataURL:$.dataURL,width:$.width,height:$.height,strategy:j}}}catch($){console.warn(`[stx-media] Failed to generate placeholder: ${$}`)}return G.sizes=Z.sizes||JJ(N),G}catch(N){return console.error(`[stx-media] Responsive generation failed: ${N}`),null}}function JJ(J){let Z=[...J].sort((K,X)=>K-X),Y=[];for(let K=0;K<Z.length-1;K++){let X=Z[K];Y.push(`(max-width: ${X}px) ${X}px`)}return Y.push(`${Z[Z.length-1]}px`),Y.join(", ")}function KJ(J,Z="width"){if(!J||J.length===0)return"";if(Z==="dpr")return J.filter((Y)=>Y.dpr).map((Y)=>`${Y.url} ${Y.dpr}x`).join(", ");return J.map((Y)=>`${Y.url} ${Y.width}w`).join(", ")}export{z as Ug,w as Vg,Q as Wg,d as Xg,g as Yg,n as Zg,D as _g,t as $g,KJ as ah};
2
+ import{mh as x,rh as M,sh as C,th as v,uh as P}from"./chunk-6rzwef28.js";import{ax as y}from"./chunk-cevkpyn9.js";import{resolve as h,basename as f,extname as u,join as m}from"path";import{mkdir as l}from"fs/promises";var I={enabled:!0,directory:".stx/media-cache",maxAge:30,maxSize:500,cacheVariants:!0,cachePlaceholders:!0};class z{config;constructor(J={}){this.config={...I,...J}}async get(J,Z){return C(J,Z,"image",this.config)}async set(J,Z,Y){return v(J,Z,Y,"image",this.config)}async clear(){return P("image",this.config)}updateConfig(J){this.config={...this.config,...J}}}var H=null;function S(J){if(!H)H=new z(J);else if(J)H.updateConfig(J);return H}async function w(J,Z,Y){let K=Y?{directory:`${Y.outputDir}/../.cache`}:{};return S(K).get(J,Z)}async function Q(J,Z,Y,K){let X=K?{directory:`${K.outputDir}/../.cache`}:{};return S(X).set(J,Z,Y)}async function d(){return S().clear()}async function R(){try{return await import("ts-images")}catch{return null}}function b(J){switch(J){case"quality":return{jpeg:{quality:90,mozjpeg:!0,progressive:!0},png:{compressionLevel:6,palette:!1},webp:{quality:90,effort:6,smartSubsample:!0},avif:{quality:85,effort:6}};case"performance":return{jpeg:{quality:70,mozjpeg:!0,progressive:!0},png:{compressionLevel:9,palette:!0},webp:{quality:70,effort:4,smartSubsample:!0},avif:{quality:60,effort:2}};case"web":default:return{jpeg:{quality:82,mozjpeg:!0,progressive:!0},png:{compressionLevel:8,palette:!1},webp:{quality:82,effort:5,smartSubsample:!0},avif:{quality:75,effort:4}}}}function p(J,Z){let Y=Z?b(Z):b("web"),K=J.formatQuality||{};return{jpeg:{...Y.jpeg,...K.jpeg},png:{...Y.png,...K.png},webp:{...Y.webp,...K.webp},avif:{...Y.avif,...K.avif}}}async function g(J,Z,Y){let K=await R();if(!K)return console.warn("[stx-media] ts-images not installed, skipping optimization"),{src:J,processed:!1};let X=await w(J,Z,Y);if(X)return X;try{let N=h(J);if(!await M(N))return{src:J,processed:!1,errors:[`Source file not found: ${J}`]};let L=p(Y,Z.preset),V=Y.outputDir||"dist/images",F=Y.baseUrl||"/images";await l(V,{recursive:!0});let q=await x(N),U=f(J,u(J)),E=Z.outputFormat?[Z.outputFormat]:Y.defaultFormats||["avif","webp","jpeg"],G={src:J,processed:!0,variants:[],hash:q},j=null;if(Z.transformations&&Z.transformations.length>0)j=await D(N,Z.transformations,K);for(let $ of E){let A=L[$]||{},W=`${U}-${q}.${$}`,_=m(V,W);try{let O=await K.optimizeImage({input:j||N,output:_,format:$,quality:A.quality,progressive:A.progressive});if(O){if(G.variants.push({path:_,url:`${F}/${W}`,width:O.width||0,height:O.height||0,format:$,size:O.outputSize||0}),!G.originalWidth&&O.width)G.originalWidth=O.width,G.originalHeight=O.height}}catch(O){G.errors=G.errors||[],G.errors.push(`Failed to optimize ${$}: ${O}`)}}if(Z.embedThumbhash||Z.placeholder==="thumbhash")try{let $=await K.generateThumbHash(N);G.placeholder=$.dataUrl}catch($){G.errors=G.errors||[],G.errors.push(`Failed to generate thumbhash: ${$}`)}if(Z.useDominantColor)try{let $=await K.generatePlaceholder(N,{strategy:"dominant-color"});G.dominantColor=$.dominantColor}catch($){G.errors=G.errors||[],G.errors.push(`Failed to extract dominant color: ${$}`)}return await Q(J,Z,G,Y),G}catch(N){return{src:J,processed:!1,errors:[`Processing failed: ${N}`]}}}async function n(J,Z,Y,K){let X=await R();if(!X)return{success:!1,error:"ts-images not installed"};try{return{success:!0,size:(await X.optimizeImage({input:J,output:K,format:Z,quality:Y}))?.outputSize}}catch(N){return{success:!1,error:String(N)}}}async function D(J,Z,Y){let K=Y||await R();if(!K)return console.warn("[stx-media] ts-images not installed, skipping transformations"),null;try{let X=await K.decode(J);for(let N of Z){let L=N.options||{};switch(N.type){case"resize":if(L.width||L.height)X=await K.resize(X,{width:L.width,height:L.height,fit:L.fit});break;case"blur":if(L.sigma!==void 0)X=await K.blur(X,L.sigma);break;case"sharpen":if(L.amount!==void 0)X=await K.sharpen(X,L.amount);break;case"grayscale":X=await K.grayscale(X);break;case"rotate":if(L.angle!==void 0)X=await K.rotate(X,L.angle);break;case"flip":X=await K.flip(X);break;case"flop":X=await K.flop(X);break;case"brightness":if(L.value!==void 0)X=await K.brightness(X,L.value);break;case"contrast":if(L.value!==void 0)X=await K.contrast(X,L.value);break;case"saturation":if(L.value!==void 0)X=await K.saturation(X,L.value);break}}return await K.encode(X,"png")}catch(X){return console.error(`[stx-media] Transformation failed: ${X}`),null}}import{resolve as c,basename as i,extname as r,join as o}from"path";import{mkdir as a}from"fs/promises";async function e(){try{return await import("ts-images")}catch{return null}}var s=[320,480,640,768,1024,1280,1536,1920];async function t(J,Z,Y){let K=await e();if(!K)return console.warn("[stx-media] ts-images not installed, skipping responsive generation"),null;let X=c(J);if(!await M(X))return console.warn(`[stx-media] Source file not found: ${J}`),null;try{let N=Z.responsiveWidths||Y.breakpoints||s,L=Z.formats||Y.defaultFormats||["avif","webp","jpeg"],V=Y.outputDir||"dist/images",F=Y.baseUrl||"/images";await a(V,{recursive:!0});let q=await x(X),U=i(J,r(J)),E=Y.formatQuality||{jpeg:{quality:82},png:{quality:80},webp:{quality:82},avif:{quality:75}},G={src:J,byFormat:{},srcsets:{}};for(let $ of L){G.byFormat[$]=[];let A=[];for(let W of N){let _=`${U}-${W}w-${q}.${$}`,O=o(V,_),B=`${F}/${_}`;try{let T=E[$]?.quality||80;if(await M(O)){G.byFormat[$].push({path:O,url:B,width:W,height:0,format:$,size:0}),A.push(`${B} ${W}w`);continue}let k=await K.processImage({input:X,output:O,format:$,quality:T,resize:{width:W}});if(k)G.byFormat[$].push({path:O,url:B,width:W,height:k.height||Math.round(W*(k.height||1)/(k.width||1)),format:$,size:k.outputSize||0}),A.push(`${B} ${W}w`)}catch(T){console.warn(`[stx-media] Failed to generate ${$} at ${W}w: ${T}`)}}G.srcsets[$]=A.join(", ")}let j=Z.placeholder||Y.placeholderStrategy||"thumbhash";if(j!=="none")try{if(j==="thumbhash"){let $=await K.generateThumbHash(X);G.placeholder={dataURL:$.dataUrl,width:$.width||32,height:$.height||32,strategy:"thumbhash"}}else{let $=await K.generatePlaceholder(X,{strategy:j,width:20});G.placeholder={dataURL:$.dataURL,width:$.width,height:$.height,strategy:j}}}catch($){console.warn(`[stx-media] Failed to generate placeholder: ${$}`)}return G.sizes=Z.sizes||JJ(N),G}catch(N){return console.error(`[stx-media] Responsive generation failed: ${N}`),null}}function JJ(J){let Z=[...J].sort((K,X)=>K-X),Y=[];for(let K=0;K<Z.length-1;K++){let X=Z[K];Y.push(`(max-width: ${X}px) ${X}px`)}return Y.push(`${Z[Z.length-1]}px`),Y.join(", ")}function KJ(J,Z="width"){if(!J||J.length===0)return"";if(Z==="dpr")return J.filter((Y)=>Y.dpr).map((Y)=>`${Y.url} ${Y.dpr}x`).join(", ");return J.map((Y)=>`${Y.url} ${Y.width}w`).join(", ")}export{z as Ug,w as Vg,Q as Wg,d as Xg,g as Yg,n as Zg,D as _g,t as $g,KJ as ah};
@@ -1,2 +1,2 @@
1
1
  // @bun
2
- import{$t as e,Xt as a,Yt as b,Zt as c,_t as d,au as f,bu as g,cu as h,du as i,eu as j,fu as k,gu as l}from"./chunk-88tt0qg0.js";import"./chunk-e1rv01pn.js";import"./chunk-bdz7nznw.js";import"./chunk-x2wmn8m7.js";import"./chunk-rxz43r6k.js";export{f as structuredDataDirective,j as scanForSitemapEntries,g as registerSeoDirectives,b as processStructuredData,c as processSeoDirective,a as processMetaDirectives,e as metaDirective,d as injectSeoTags,i as generateSitemapIndex,h as generateSitemap,k as generateRobotsTxt,l as generateDefaultRobotsTxt};
2
+ import{$t as d,Yt as a,Zt as b,_t as c,au as e,bu as f,cu as g,du as h,eu as i,fu as j,gu as k,hu as l}from"./chunk-9rp8f7jz.js";import"./chunk-8ghwewek.js";import"./chunk-rk8p4b1z.js";import"./chunk-d6rkgay9.js";import"./chunk-cevkpyn9.js";export{f as structuredDataDirective,j as scanForSitemapEntries,g as registerSeoDirectives,b as processStructuredData,c as processSeoDirective,a as processMetaDirectives,e as metaDirective,d as injectSeoTags,i as generateSitemapIndex,h as generateSitemap,k as generateRobotsTxt,l as generateDefaultRobotsTxt};
@@ -1,2 +1,2 @@
1
1
  // @bun
2
- import{Ai as b,Bi as c,Ci as d,Di as e,zi as a}from"./chunk-4bb28mz5.js";import"./chunk-rxz43r6k.js";export{a as processAsyncDirectives,c as isAsyncComponent,e as generateAsyncComponentRuntime,d as generateAsyncComponentCSS,b as defineAsyncComponent};
2
+ import{Ai as b,Bi as c,Ci as d,Di as e,zi as a}from"./chunk-4bb28mz5.js";import"./chunk-cevkpyn9.js";export{a as processAsyncDirectives,c as isAsyncComponent,e as generateAsyncComponentRuntime,d as generateAsyncComponentCSS,b as defineAsyncComponent};
@@ -1,2 +1,2 @@
1
1
  // @bun
2
- import{$ as om,$a as ro,$b as Cp,$c as Cq,$d as Cr,A as _k,Aa as Cn,Ab as Wo,Ac as bq,Ad as br,Ae as hs,B as $k,Ba as Dn,Bb as Xo,Bc as cq,Bd as cr,Be as is,C as al,Ca as En,Cb as Yo,Cc as dq,Cd as dr,Ce as js,D as bl,Da as Fn,Db as Zo,Dc as eq,Dd as er,De as ks,E as cl,Ea as Gn,Eb as _o,Ec as fq,Ed as fr,Ee as ls,F as dl,Fa as Tn,Fb as $o,Fc as gq,Fd as gr,Fe as ms,G as el,Ga as Un,Gb as ap,Gc as hq,Gd as hr,Ge as ns,H as Wl,Ha as Vn,Hb as bp,Hc as iq,Hd as ir,He as os,I as Xl,Ia as Wn,Ib as cp,Ic as jq,Id as jr,Ie as ps,J as Yl,Ja as Xn,Jb as dp,Jc as kq,Jd as kr,Je as qs,K as Zl,Ka as Yn,Kb as ep,Kc as lq,Kd as lr,Ke as rs,L as _l,La as ao,Lb as fp,Lc as mq,Ld as mr,Le as ss,M as $l,Ma as bo,Mb as gp,Mc as nq,Md as nr,Me as ts,N as am,Na as co,Nb as hp,Nc as oq,Nd as or,Ne as us,O as bm,Oa as eo,Ob as ip,Oc as pq,Od as pr,P as cm,Pa as fo,Pb as jp,Pc as qq,Pd as qr,Q as dm,Qa as go,Qb as rp,Qc as rq,Qd as rr,R as em,Ra as ho,Rb as sp,Rc as sq,Rd as sr,S as fm,Sa as io,Sb as tp,Sc as tq,Sd as tr,T as gm,Ta as jo,Tb as up,Tc as uq,Td as ur,U as hm,Ua as ko,Ub as vp,Uc as vq,Ud as vr,V as im,Va as lo,Vb as wp,Vc as wq,Vd as wr,W as jm,Wa as mo,Wb as xp,Wc as xq,Wd as xr,X as km,Xa as no,Xb as yp,Xc as yq,Xd as yr,Y as lm,Ya as oo,Yb as zp,Yc as zq,Yd as zr,Z as mm,Za as po,Zb as Ap,Zc as Aq,Zd as Ar,_ as nm,_a as qo,_b as Bp,_c as Bq,_d as Br,aa as pm,ab as so,ac as Dp,ad as Dq,ae as Dr,ba as qm,bb as to,bc as Ep,bd as Eq,be as Er,ca as rm,cb as uo,cc as Fp,cd as Fq,ce as Fr,da as sm,db as vo,dc as Gp,dd as Gq,de as Gr,ea as tm,eb as wo,ec as Hp,ed as Hq,ee as Nr,fa as um,fb as xo,fc as Ip,fd as Iq,fe as Or,ga as vm,gb as yo,gc as Jp,gd as Jq,ge as Pr,ha as wm,hb as zo,hc as Kp,hd as Kq,he as Qr,ia as xm,ib as Ao,ic as Lp,id as Lq,ie as Rr,ja as ym,jb as Bo,jc as Mp,jd as Mq,je as Sr,ka as zm,kb as Co,kc as Np,kd as Nq,ke as Tr,la as Am,lb as Do,lc as Op,ld as Oq,le as Ur,ma as Bm,mb as Eo,mc as Pp,md as Pq,me as Vr,na as Cm,nb as Fo,nc as Qp,nd as Qq,ne as Wr,o as a,oa as Dm,ob as Go,oc as Rp,od as Rq,oe as Xr,p as Lk,pa as Em,pb as Ho,pc as Sp,pd as Sq,pe as Yr,q as Mk,qa as Fm,qb as Ko,qc as Tp,qd as Tq,qe as Zr,r as Nk,ra as Gm,rb as Lo,rc as Up,rd as Uq,re as _r,s as Ok,sa as un,sb as Mo,sc as Vp,sd as Vq,se as $r,t as Pk,ta as vn,tb as No,tc as Wp,td as Wq,te as as,u as Qk,ua as wn,ub as Po,uc as Xp,ud as Xq,ue as bs,v as Rk,va as xn,vb as Qo,vc as Yp,vd as Yq,ve as cs,w as Sk,wa as yn,wb as Ro,wc as Zp,wd as Zq,we as ds,x as Tk,xa as zn,xb as So,xc as _p,xd as _q,xe as es,y as Yk,ya as An,yb as Uo,yc as $p,yd as $q,ye as fs,z as Zk,za as Bn,zb as Vo,zc as aq,zd as ar,ze as gs}from"./chunk-7bym5kky.js";import{Oe as kp,Pe as lp,Qe as mp,Re as np,Se as op,Te as pp,Ue as qp}from"./chunk-re9rv45k.js";import{Ve as Io,We as Jo}from"./chunk-pkspqh0m.js";import{Xe as Oo}from"./chunk-61cwdy7h.js";import{Ye as tn}from"./chunk-wmqhn6rq.js";import{$e as $n,Ze as Zn,_e as _n,af as To}from"./chunk-bf6zcjr5.js";import{bf as fl,cf as gl,df as hl,ef as il,ff as jl,gf as kl,hf as ll,if as ml,jf as nl,kf as ol,lf as pl,mf as ql,nf as rl,of as sl,pf as tl}from"./chunk-ewxbx67c.js";import{Af as Ul,Bf as Vl,qf as Kl,rf as Ll,sf as Ml,tf as Nl,uf as Ol,vf as Pl,wf as Ql,xf as Rl,yf as Sl,zf as Tl}from"./chunk-kdwbpcm4.js";import{Cf as Il,Df as Jl}from"./chunk-fsvkqeya.js";import{Ef as ul,Ff as vl,Gf as wl,Hf as xl,If as yl,Jf as zl,Kf as Al,Mf as Bl,Nf as Cl,Of as Dl,Pf as El,Qf as Fl,Rf as Gl,Uf as Hl}from"./chunk-980w4zcq.js";import{Vf as bn,Wf as cn,Xf as dn,Yf as en,Zf as fn,_f as sn}from"./chunk-epzm35py.js";import{$f as Hm,ag as Im,bg as Jm,cg as Km,dg as Lm,eg as Mm,fg as Nm,gg as Om,hg as Pm,ig as Qm,jg as Rm,kg as Sm,lg as Tm,mg as Um,ng as Vm,og as Wm,pg as gn,qg as hn,rg as jn,sg as kn,tg as ln,ug as mn,vg as nn,wg as on,xg as pn,yg as qn,zg as rn}from"./chunk-nm7jfzmz.js";import{Ag as Xm,Bg as Ym}from"./chunk-g64qyhhb.js";import{Cg as Hn,Dg as In,Eg as Jn,Fg as Kn,Gg as Ln,Hg as Mn,Ig as Nn,Jg as On,Kg as Pn,Lg as Qn,Mg as Rn,Ng as Sn}from"./chunk-9vwpf0bk.js";import{Og as ui,Pg as vi,Qg as wi,Rg as xi,Sg as yi,Tg as zi}from"./chunk-pm8wzxsb.js";import{$g as Tj,Ug as Pj,Vg as Qj,Wg as Rj,_g as Sj,ah as Uj}from"./chunk-k2nydt80.js";import{bh as _j,ch as $j,dh as ak,eh as bk,fh as ck,gh as dk,hh as ek,ih as fk,jh as gk,kh as hk,lh as ik}from"./chunk-x86qttwm.js";import{mh as Fj,nh as Gj,oh as Hj,ph as Ij,qh as Jj,sh as Kj,th as Lj,uh as Mj,vh as Nj,wh as Oj}from"./chunk-6rzwef28.js";import{xh as Ak,zh as Bk}from"./chunk-683tfkz4.js";import{Fh as Ph,Gh as Qh,Hh as Rh,Ih as Sh,Jh as Th,Kh as Uh}from"./chunk-9r2xgf5k.js";import{Mh as Vh,Nh as Wh,Oh as Xh,Ph as Yh,Qh as Zh,Rh as _h,Sh as $h,Th as ai,Uh as bi,Vh as ci,Wh as di,Xh as ei,Yh as fi,Zh as gi}from"./chunk-9368t9jm.js";import{$h as hi,ai as ii,bi as ji,ci as ki}from"./chunk-st9vrfw7.js";import{hi as li}from"./chunk-mwh3ymwc.js";import{ki as oh}from"./chunk-r0jqyxbc.js";import{li as ph}from"./chunk-1t5vwavd.js";import{mi as qh,ni as rh}from"./chunk-cks5rbzt.js";import{oi as sh,pi as th,qi as uh,ri as vh,si as wh,ti as xh}from"./chunk-092qw0ps.js";import{ui as yh,vi as zh,wi as Ah,xi as Bh,yi as Ch}from"./chunk-kpg48dhw.js";import{Ai as Eh,Bi as Fh,Ci as Gh,Di as Hh,zi as Dh}from"./chunk-4bb28mz5.js";import{Ei as Ih,Fi as Jh,Gi as Kh,Hi as Lh,Ii as Mh,Ji as Nh,Ki as Oh}from"./chunk-90zfg77v.js";import{Li as mh,Mi as nh}from"./chunk-8kkqx4sc.js";import"./chunk-452k8psm.js";import{$i as _e,Qi as Pe,Ri as Qe,Si as Re,Ti as Se,Ui as Te,Vi as Ue,Wi as Ve,Xi as We,Yi as Xe,Zi as Ye,_i as Ze,aj as $e,bj as af}from"./chunk-45etne17.js";import{cj as sf,dj as tf,ej as uf,fj as vf,gj as wf,hj as xf,ij as yf,jj as zf,kj as Af,lj as Bf,mj as Cf,nj as Df,oj as Ef,pj as Ff,qj as Gf,rj as Hf,sj as If}from"./chunk-q4v62yed.js";import{Aj as ef,Bj as ff,Cj as gf,Dj as hf,Ej as jf,Fj as kf,Gj as lf,Hj as mf,Ij as nf,Jj as of,Kj as pf,Lj as qf,Mj as rf,zj as df}from"./chunk-mnk5mdwp.js";import{Nj as Jf,Oj as Kf,Pj as Lf,Qj as Mf,Rj as Nf,Sj as Of,Tj as Pf,Uj as Qf,Vj as Rf,Wj as Sf,Xj as Tf,Yj as Uf,Zj as Vf,_j as Wf}from"./chunk-8xm3z6dh.js";import{sk as Hr,tk as Ir,uk as Jr,vk as Kr,wk as Lr,xk as Mr}from"./chunk-pqc4sv02.js";import{Ak as Wk,Bk as Xk,Ck as Zm,Dk as _m,Ek as $m,Fk as an,yk as Uk,zk as Vk}from"./chunk-gtn2agxa.js";import"./chunk-7eea1cse.js";import"./chunk-21dz636m.js";import{ql as ec,rl as fc,vl as gc}from"./chunk-h7sgg3vh.js";import{xl as bc}from"./chunk-2andsajh.js";import{$l as Nb,$m as id,$n as Ce,$o as ug,$q as xj,Al as za,Am as Bc,An as Nd,Ap as Vg,Aq as Pi,Ar as xk,Bl as Aa,Bm as Cc,Bn as Od,Bp as Wg,Bq as Qi,Br as yk,Cl as Ba,Cm as Dc,Cn as Pd,Cp as Xg,Cq as Ri,Cr as zk,Dl as Ca,Dm as Ec,Dn as Qd,Dp as Yg,Dq as $i,Dr as Ck,El as Da,Em as Fc,En as Rd,Ep as Zg,Eq as aj,Er as Dk,Fl as Ea,Fm as Gc,Fn as Sd,Fo as Yf,Fp as _g,Fq as bj,Fr as Ek,Gl as Fa,Gm as Hc,Gn as Td,Gp as $g,Gq as cj,Gr as Fk,Hl as Ga,Hm as Ic,Hn as Ud,Hp as ah,Hq as dj,Hr as Gk,Il as Ha,Im as Jc,In as Vd,Ip as bh,Iq as ej,Ir as Hk,Jl as Ia,Jm as Kc,Jn as Wd,Jp as ch,Jq as fj,Jr as Ik,Kl as Ja,Km as Lc,Kn as Xd,Kp as dh,Kq as gj,Kr as Jk,Ll as Ka,Lm as Mc,Ln as Yd,Lp as eh,Lq as hj,Lr as Kk,Ml as La,Mm as Nc,Mn as Zd,Mp as fh,Mq as ij,Nl as Ma,Nm as Oc,Nn as _d,No as Zf,Np as gh,Nq as jj,Ol as Na,Om as Pc,On as $d,Op as hh,Oq as kj,Pl as Oa,Pm as Qc,Pn as ae,Po as _f,Pp as ih,Pq as lj,Ql as ib,Qm as _c,Qn as re,Qp as jh,Qq as mj,Rl as jb,Rm as $c,Rn as se,Ro as $f,Rp as kh,Rq as nj,Sl as kb,Sm as ad,Sn as te,So as ag,Sp as lh,Sq as oj,Tl as lb,Tm as bd,Tn as ue,To as bg,Tp as mi,Tq as pj,Ul as mb,Um as cd,Un as ve,Uo as cg,Up as ni,Uq as qj,Vl as nb,Vm as dd,Vn as we,Vo as dg,Vq as rj,Wm as ed,Wn as xe,Wo as eg,Wq as sj,Xn as ye,Xo as qg,Xp as oi,Xq as tj,Yl as Kb,Ym as fd,Yn as ze,Yo as rg,Yq as uj,Zl as Lb,Zm as gd,Zn as Ae,Zo as sg,Zq as vj,_l as Mb,_m as hd,_n as Be,_o as tg,_q as wj,am as Ob,an as jd,ao as De,ap as vg,ar as yj,bm as Pb,bn as kd,bo as Ee,bp as wg,br as zj,cm as Qb,cn as ld,cp as xg,cr as Aj,dm as Ub,dn as md,do as Ie,dp as yg,dr as Bj,em as Vb,en as nd,eo as Je,ep as zg,er as Cj,fm as Wb,fn as od,fo as Ke,fp as Ag,fr as Dj,gm as hc,gn as pd,go as Le,gp as Bg,gq as pi,gr as Ej,hm as ic,hn as qd,ho as Me,hp as Cg,hq as qi,hr as Vj,im as jc,in as vd,io as Ne,ip as Dg,iq as ri,ir as Wj,jm as kc,jn as wd,jo as Oe,jp as Eg,jq as si,jr as Xj,km as lc,kn as xd,kp as Fg,kq as ti,kr as Yj,lm as mc,ln as yd,lp as Gg,lq as Ai,lr as Zj,mm as nc,mn as zd,mp as Hg,mq as Bi,mr as jk,nm as oc,nn as Ad,no as bf,np as Ig,nq as Ci,nr as kk,om as pc,on as Bd,oo as cf,op as Jg,oq as Di,or as lk,pm as qc,pn as Cd,pp as Kg,pq as Ei,pr as mk,qm as rc,qn as Dd,qo as Xf,qp as Lg,qq as Fi,qr as nk,rm as sc,rn as Ed,rp as Mg,rq as Gi,rr as ok,sm as tc,sn as Fd,sp as Ng,sq as Hi,sr as pk,tm as uc,tn as Gd,tp as Og,tq as Ii,tr as qk,um as vc,un as Hd,up as Pg,uq as Ji,ur as rk,vm as wc,vn as Id,vp as Qg,vq as Ki,vr as sk,wm as xc,wn as Jd,wp as Rg,wq as Li,wr as tk,xm as yc,xn as Kd,xp as Sg,xq as Mi,xr as uk,yl as xa,ym as zc,yn as Ld,yp as Tg,yq as Ni,yr as vk,zl as ya,zm as Ac,zn as Md,zp as Ug,zq as Oi,zr as wk}from"./chunk-zstrcmbj.js";import{$r as $,Mr as M,Nr as N,Or as O,Pr as P,Qr as Q,Rr as R,Sr as S,Tr as T,Ur as U,Vr as V,Wr as W,Xr as X,Yr as Y,Zr as Z,_r as _,as as aa,bs as ba,cs as ca,ds as da,es as ea,fs as fa,gs as ia,hs as ja,is as ka,js as la,ks as ma,ls as na,ms as oa,ns as pa,os as qa,ps as ra,qs as sa,rs as ta,ss as ua,ts as va,us as wa}from"./chunk-4cv7bw5e.js";import{vs as ga,ws as ha}from"./chunk-7tgjn256.js";import{xs as Rb,ys as Sb,zs as Tb}from"./chunk-h8zp2fz9.js";import"./chunk-ekvejzvk.js";import{Gs as Si,Hs as Ti,Is as Ui,Js as Vi,Ks as Wi,Ls as Xi,Ms as Yi,Ns as Zi,Os as _i}from"./chunk-3769e62c.js";import{et as Rc,ft as Sc,gt as Tc,ht as Uc,it as Vc,kt as Wc,tt as Xc,ut as Yc,vt as Zc}from"./chunk-7c8r36ve.js";import{At as $b,Bt as ac,wt as Xb,xt as Yb,yt as Zb,zt as _b}from"./chunk-yj5gkn17.js";import{It as Fe,Kt as Ge,Nt as He}from"./chunk-cy8hgd86.js";import"./chunk-twws9vvz.js";import{St as cc,Tt as dc}from"./chunk-g7qmxjyc.js";import{$t as jg,Xt as fg,Yt as gg,Zt as hg,_t as ig,au as kg,bu as lg,du as mg,eu as ng,fu as og,gu as pg}from"./chunk-88tt0qg0.js";import{Au as he,Bu as ie,Cu as je,Du as ke,Eu as le,Fu as me,Gu as ne,Hu as oe,Iu as pe,Ju as qe,hu as rd,iu as sd,ju as td,ku as ud,uu as be,vu as ce,wu as de,xu as ee,yu as fe,zu as ge}from"./chunk-e1rv01pn.js";import{$u as v,Ku as b,Lu as c,Mu as d,Nu as e,Ou as f,Pu as g,Qu as h,Ru as i,Su as m,Tu as n,Uu as o,Vu as p,Wu as q,Xu as r,Yu as s,Zu as t,_u as u,av as w,bv as x,cv as y,dv as z,ev as A,fv as B,gv as C,hv as D,iv as E,jv as F,kv as G,lv as H,mv as I,nv as J,ov as K,pv as L}from"./chunk-bdz7nznw.js";import"./chunk-rwtj7j0r.js";import"./chunk-eqhsprr0.js";import{Fv as ob,Gv as pb,Hv as qb,Iv as rb,Jv as sb,Kv as tb,Lv as ub,Mv as vb,Nv as wb,Ov as xb,Pv as yb,Qv as zb,Rv as Ab,Sv as Bb,Tv as Cb,Uv as Db,Vv as Eb,Wv as Fb,Xv as Gb,Yv as Hb,Zv as Ib,_v as Jb}from"./chunk-csgshaeh.js";import{Aw as ab,Bw as bb,Cw as cb,Dw as db,Ew as eb,Fw as fb,Gw as gb,Iw as hb,cw as Pa,dw as Qa,gw as Ra,lw as Sa,mw as Ta,sw as Ua,tw as Va,uw as Wa,vw as Xa,ww as Ya,xw as Za,yw as _a,zw as $a}from"./chunk-d0qy1ezf.js";import"./chunk-c9kj8p6j.js";import{Uw as j,Vw as k,Ww as l}from"./chunk-x2wmn8m7.js";import"./chunk-rxz43r6k.js";export{pl as writeNetlifyConfig,hn as writeManifest,Ul as writeImageManifest,Ap as wrapComponentForHMR,hs as withDefaults,zk as webComponentDirectiveHandler,pq as watermark,rr as watchViews,cm as watchMultiple,dm as watchEffect,bm as watch,Me as warmImagePlaceholders,qm as waitForStore,X as waitForLocale,lp as virtualPathFor,mk as videoDirective,G as validators,ls as validated,Ce as validateValueEnhanced,pi as validateTemplate,Xm as validateRouteRules,uq as validateParams,De as validateFormEnhanced,gr as validateFile,ye as validateFields,xe as validateField,ri as validateDirective,Xd as validateCspDirectives,Hk as validateConfig,vn as validateComponentScripts,Tn as validateComponentProps,lh as validateClientScript,ki as v,Hc as usesSignalsInScript,ub as usesReactiveRuntime,Fi as userComponentFileExists,Sh as useVirtualList,je as useTitle,pm as useStoreOrThrow,Sp as useStore,Yk as useStorage,Af as useSlots,_k as useSessionStorage,cc as useServerRuntimeConfig,Yf as useServerData,ge as useSeoMeta,dc as useRuntimeConfig,rm as useRouteParams,tm as useRouteParamOrThrow,sm as useRouteParam,je as usePageTitle,rf as useOptimistic,Ff as useModel,vm as useMiddlewareValue,um as useMiddlewareState,Zk as useLocalStorage,tp as useLoadingIndicator,ee as useHead,hi as useForm,Cf as useAttrs,ir as uploadFiles,hr as uploadFile,mm as updateInstance,pf as untrack,Vi as unregisterDirective,nm as unmountInstance,Qc as unescapeHtml,pp as typecheckStxFiles,Di as transpileTypeScript,Wr as translate,Ba as transitionDirective,lc as transformAutoImports,Nn as toUsers,Mn as toUser,_p as thumbnail,$q as thumbHashToRGBA,ar as thumbHashToDataURL,wb as templateNeedsRuntime,vb as templateHasReactiveContext,Jf as templateCache,nd as syncRecordedResponse,xp as stxClientHelpers,kg as structuredDataDirective,Zr as stripLocalePrefix,Um as stripDocumentWrapper,Sb as stripCommentsAndLiterals,yo as stringToStream,Ld as strictCspPreset,Xe as streamingSuspenseDirective,$e as streamToResponse,Ve as streamTemplateSimple,Pe as streamTemplate,Tk as stopHmrServer,Jn as stopBroadcasting,_b as stateDirName,$b as stateDir,df as state,fh as startsDocument,To as startProductionServer,Oo as startInteractive,In as startBroadcasting,$r as stampLocaleLayoutGroup,Ia as staggerDirective,sq as srcsetUrls,Ja as springDirective,ud as splitByPipe,Qm as spaNavVaryHeaders,mp as sourcePathFor,zq as smartBatchSign,Hi as slotContentHasExpressions,xq as signUrl,Bi as shouldTranspileTypeScript,Qk as shouldReloadOnChange,Cq as shouldRefreshSignature,Rk as shouldIgnoreFile,Kh as shouldCacheComponent,cq as sharpen,os as shape,Zb as setStateDir,zm as setRouteParams,Am as setMiddlewareState,Le as setImagePlaceholder,uf as setGlobalProvide,b as setErrorLocale,Wl as setCurrentInstance,ak as setCachedVideoResult,Rj as setCachedImageResult,Lj as setCached,rs as serveStxFile,ts as serveMultipleStxFiles,Lk as serveMarkdownFile,cp as serveFile,us as serveApp,bp as serve,Dp as serializeState,kn as serializeSetCookie,eq as sepia,he as seoMetaToHeadConfig,Ca as scrollAnimateDirective,va as screenReaderDirective,Ei as scopeOnRootElement,qk as scopeHTML,pk as scopeCSS,ng as scanForSitemapEntries,pa as scanA11yTargets,qa as scanA11yIssues,iq as saturation,vq as sanitizeParams,I as sanitizeFilePath,J as sanitizeExpression,K as sanitizeDirectiveParams,H as sanitizeDirectiveParam,L as sanitizeComponentProps,B as safeExecuteAsync,A as safeExecute,Cb as runtimeHandledXAttrsLiteral,Gb as runtimeEventRegexLiteral,Eb as runtimeDirectiveNamesLiteral,yg as runPreProcessingMiddleware,zg as runPostProcessingMiddleware,nn as runPageAction,kf as runMountCallbacks,gb as runMiddleware,km as runHooks,Pr as runDoctor,lf as runDestroyCallbacks,Cg as runComposers,jq as rotate,li as rewriteImagesWithSiblings,od as responseBindings,Li as resolveTemplatePath,ha as resolveStxTargets,Dk as resolveStxDirectories,Vr as resolveI18n,Yp as resize,qg as resetUnscopedSignalWarnings,Oc as resetRejectedExpressionWarnings,sc as resetPlaceholders,de as resetHead,Cp as resetHMRHandler,o as resetErrorConfig,js as required,cg as reportDeferredLoopWarnings,wc as replacePlaceholders,Ec as replaceInterpolations,pr as renderView,jk as renderVideoComponent,ic as renderVendorStyleTags,yr as renderToString,zr as renderToStream,Ar as renderToDOM,_q as renderThumbhashToCanvas,Mr as renderTemplateString,Kr as renderTemplate,Lr as renderString,Se as renderStreamingPage,wi as renderSlot,Ah as renderSSRSuspense,Kq as renderProtectedVideo,Jq as renderProtectedImg,wq as renderMediaUpload,Jr as renderMarkdownView,$m as renderLayoutTypes,Vj as renderImgComponent,Kl as renderImageComponent,le as renderHtmlAttrs,ke as renderHead,sr as renderEmail,Ji as renderComponentWithSlot,me as renderBodyAttrs,Np as render,Nd as relaxedCspPreset,we as registerValidationRule,Ze as registerStreamingDirectives,Up as registerStoresClient,xm as registerStore,Rf as registerServeModuleBundle,lg as registerSeoDirectives,_a as registerMiddleware,Ac as registerFilters,zc as registerFilter,d as registerErrorMessages,Be as registerEnhancedValidationRule,Si as registerDirective,Wd as registerCspDirectives,Wn as registerComponentDirectives,Oa as registerAnimationDirectives,wa as registerA11yDirectives,mc as referencesName,_l as ref,Go as redirect,jd as recordResponseStatus,kd as recordResponseHeader,ac as rebaseOntoStateDir,ld as readResponseStatus,md as readResponseHeaders,Jk as readMarkdownFile,Kf as readFileCached,$l as reactive,nq as quality,Hq as pruneSignatureCache,Oj as pruneCache,sf as provide,Ir as protectCodeBlocks,is as prop,Fg as processVueTemplate,Qh as processVirtualListDirectives,Uh as processVirtualGridDirectives,ik as processVideo,ze as processValidateDirective,ea as processTranslateDirective,uh as processTransitionDirectives,xh as processTransitionAttributes,pe as processTitleDirective,bd as processTemplateBindings,qh as processTeleportDirectives,yh as processSuspenseDirectives,gg as processStructuredData,Te as processStreamDirectives,pd as processStatusDirective,fi as processStaticDirectives,wg as processStackReplacements,vg as processStackPushDirectives,xi as processSlots,Sm as processShell,Oe as processServerBindings,hg as processSeoDirective,_e as processSectionDirectives,Vc as processScopedStyles,$c as processReactiveBindings,Lq as processProtectedMedia,_h as processPartialHydrationDirectives,kh as processOnceDirective,xg as processMiddleware,fg as processMetaDirectives,qe as processMetaDirective,Kk as processMarkdownFileDirectives,Qi as processMarkdownDirectives,dg as processLoops,Ih as processKeepAliveDirectives,jh as processJsonDirective,Th as processInfiniteListDirectives,ug as processIncludes,Xj as processImgComponents,Ml as processImageComponents,zl as processImage,oe as processHeadDirective,se as processForms,ue as processFormInputDirectives,Mc as processExpressions,Pb as processEventDirectives,ve as processErrorDirective,Gg as processDynamicComponents,mi as processDirectives,_i as processDirectiveAttributes,ph as processDeferDirectives,$d as processCustomDirectives,Td as processCspDirectives,ps as processComponentProps,rc as processClientScript,te as processBasicFormDirectives,Dh as processAsyncDirectives,ae as processAppearanceBootstrapDirective,Fa as processAnimationDirectives,ka as processA11yDirectives,He as prepareImageDelivery,T as preloadTranslationsBackground,S as preloadTranslations,sp as preloadIslandHandlers,Ne as preloadIconCollection,En as poolStrings,Bk as pluginManager,Je as placeholdersWarmed,th as performLeave,sh as performEnter,mf as pendingLifecycleCounts,qf as peek,rg as partialsCache,kk as parseVideoDirectiveOptions,Wp as parseUrl,br as parseThumbhashString,Ad as parseSwitchBlock,ui as parseSlots,vi as parseSlotElement,Fd as parseScriptDeclarations,xk as parseSFCComponent,Mq as parseProtectedArgs,bg as parseLoopBinding,Wj as parseImgComponent,mj as parseImageUrl,Ll as parseImageComponent,ln as parseFormBody,Cd as parseExpressionWithFilters,Xn as parseDefaults,Do as parseCookies,Jm as parseContainerSelector,xd as parseConditionalBlock,Dd as parseArguments,Ma as parseAnimationShorthand,ks as optional,Fn as optimizeTemplate,Rl as optimizeImage,Sl as optimizeDirectory,ms as oneOf,sg as onceStore,hm as onUpdated,_c as onUpdate,jm as onUnmounted,Em as onServer,fm as onMounted,hf as onMount,ei as onHydrated,yf as onErrorCaptured,jf as onDestroy,Oh as onDeactivated,Dm as onClient,gm as onBeforeUpdate,im as onBeforeUnmount,em as onBeforeMount,Nh as onActivated,Wq as observeElement,Ho as notFound,Lg as normalizeCriticalHeadOrder,xf as nextTick,_n as negotiateEncoding,Ua as navigateTo,lm as mountInstance,Ea as motionDirective,Md as moderateCspPreset,Dn as minifyHtml,jg as metaDirective,Zg as metaDedupKey,Xp as mergeParams,$g as mergeHtmlAttrs,fe as mergeHeadConfigs,Sc as mergeCssConfig,Qd as mergeCspDirectives,Ra as matchRoute,Ri as markdownDirectiveHandler,Ik as markdownCache,ga as looksLikeGlob,Yr as localizePath,U as loadTranslationLazy,_ as loadTranslation,Ek as loadStxConfig,db as loadMiddlewareFromDirectory,jn as loadManifest,Sq as loadElement,Kn as loadChannels,Lb as listensPassively,ds as lintStxStrict,Uq as lazyLoadAll,Tq as lazyLoad,Ha as keyframeDirective,dl as keptState,wr as jsxs,xr as jsxDEV,vr as jsx,Fo as jsonResponse,Ye as islandDirective,l as isTest,Vm as isSpaNavigation,Om as isSpaNavRequest,Aq as isSignatureValid,nf as isSignal,xl as isSharpAvailable,ro as isServerEnvironment,Bm as isServer,yb as isRuntimeOwnedColonAttr,Hb as isRuntimeEventName,da as isRtlLocale,j as isProduction,ia as isPresentationalRole,Pq as isNativeLazySupported,Hr as isMarkdownPath,Q as isLoading,R as isLoaded,Ai as isJavaScriptScript,Qq as isIntersectionObserverSupported,Fl as isImageFile,yl as isImageBackendAvailable,aa as isICUFormat,di as isHydrated,Gi as isHydrateTrigger,hd as isHttpStatus,qo as isEdgeEnvironment,es as isDirectiveKind,k as isDevelopment,of as isDerived,Pk as isCssOnlyChange,Zn as isCompressible,Cm as isClient,Fh as isAsyncComponent,mn as isActionableMethod,fq as invert,Mf as invalidateFileCacheByDir,Lf as invalidateFileCache,Lc as interpolateScriptsInTemplate,Jc as interpolateScriptExpressions,Kc as interpolateScriptAttributes,x as inlineError,Ur as injectThemeBootstrap,ig as injectSeoTags,Rr as injectSeo,Xf as injectRouterScript,Ok as injectHotReload,kb as injectHeatmap,Zc as injectCss,Rd as injectCspMetaTag,hh as injectConfigHeadTags,Kg as injectColorModeBootScript,bh as injectCloakStyle,Rg as injectBuildId,kc as injectBrowserCoreAutoImports,dd as injectAnalytics,tf as inject,wm as initStoreRegistry,sl as initNetlify,up as initLoadingIndicator,Rq as initLazyLoading,No as initFile,Zq as initBlurUp,dr as initAllBlurUp,Zj as imgDirective,Pl as imageDirective,qn as hydrateTemplateStream,pn as hydrateTemplate,rp as hydrateIslands,ai as hydrateIsland,rn as hydrateFragment,bi as hydrateByStrategy,ci as hydrateAll,Kp as hydrate,ap as htmlResponse,dh as hoistLeadingHeadTags,Mg as hoistColorModeBootScript,lb as heatmapDirective,Hj as hashString,Wf as hashFilePath,Fj as hashFile,Gj as hashBuffer,Eg as hasVueTemplateSyntax,ag as hasVariables,Pp as hasStore,xc as hasPlaceholders,ql as hasNetlifyConfig,ab as hasMiddleware,Qb as hasEventDirectives,gh as hasDocumentShell,si as hasDirectives,ma as hasDOMSupport,Il as handleImageRequest,zf as handleError,Er as h,El as groupVariantsByFormat,dq as grayscale,Vo as gitHash,xn as getUnusedDirectives,V as getTranslationSync,O as getTranslationCacheStats,W as getTranslationAsync,ba as getTranslation,ll as getTotalSize,Bq as getTimeUntilExpiry,mh as getStoreScript,Qp as getStoreNames,Op as getStore,bl as getStorageSize,al as getStorageKeys,Mi as getSourceLineInfo,Ci as getSharedTranspiler,Sf as getServeModuleBundle,Qf as getServeClientAsset,la as getScreenReaderOnlyStyle,rk as getScopeAttribute,cf as getRouteParams,Vb as getPublicEnvDefine,Wb as getPublicEnv,qi as getPositionInfo,uc as getPlaceholderRegistry,Ej as getPlaceholderCacheStats,ce as getPageMeta,Hd as getNonce,Gl as getMimeType,cb as getMiddlewareNames,$a as getMiddleware,ca as getLocaleDirection,P as getLoadingState,Y as getLoadingLocales,Ie as getImagePlaceholder,Al as getImageMetadata,Fe as getImageDelivery,Jp as getHydrationRuntime,ym as getHydratedStoreState,Sk as getHmrServer,be as getHead,Bp as getHMRHandler,qj as getFormatExtension,Jj as getFileMtime,Dl as getFallbackVariant,f as getErrorMessage,c as getErrorLocale,n as getErrorConfig,i as getErrorCodeName,Ui as getDirectives,Ti as getDirective,Xl as getCurrentInstance,Wc as getCssServeAsset,Pd as getCspPreset,Yd as getCspHeaderName,Pi as getComponentCacheStats,$j as getCachedVideoResult,Fq as getCachedSignature,Of as getCachedSignalsRuntime,Pf as getCachedRouterScript,Cj as getCachedPlaceholder,Qj as getCachedImageResult,Kj as getCached,Nj as getCacheStats,Pg as getBuildId,Hn as getBroadcastServer,pj as getBestVariant,Bc as getAllFilters,dj as generateWidthSrcset,Rh as generateVirtualListCSS,kr as generateVideoPreview,Ee as generateValidationScript,lr as generateUploadRuntime,yn as generateTreeShakenBundle,wh as generateTransitionRuntime,vh as generateTransitionCSS,dk as generateThumbnails,vj as generateThumbhashPlaceholder,io as generateTemplatesDocs,Ch as generateSuspenseRuntime,Bh as generateSuspenseCSS,Ep as generateStateScript,nj as generateSrcsetData,Uj as generateSrcset,Bl as generateSrcSet,ek as generateSpriteSheet,tr as generateSpaShell,oj as generateSourceTags,jj as generateSizesFromBreakpoints,ij as generateSizesAttribute,Cl as generateSizes,mg as generateSitemapIndex,Sr as generateSitemap,Oq as generateSimpleMediaPicker,Iq as generateSignatureRuntime,If as generateSignalsRuntimeDev,Hf as generateSignalsRuntime,qc as generateServerDataBridge,ok as generateScopeId,yk as generateSFCWebComponent,Nb as generateRuntimeScript,Pa as generateRouteTypes,Qa as generateRouteManifest,og as generateRobotsTxt,Tr as generateRobots,Tj as generateResponsiveVariants,uk as generateReactiveWebComponentTS,tk as generateReactiveWebComponent,wk as generateReactiveRuntime,vk as generateReactiveMixin,ck as generatePoster,Bj as generatePlaceholderStyle,Aj as generatePlaceholderCSS,uj as generatePlaceholder,$h as generatePartialHydrationCSS,Vg as generateOfflineWorker,Gd as generateNonce,ml as generateNetlifyToml,nr as generateMinifiedMediaRuntime,mr as generateMediaRuntime,Nq as generateMediaManagerEmbed,gn as generateManifest,wp as generateLoadingIndicatorHtml,Yq as generateLazyLoadRuntime,an as generateLayoutTypes,xj as generateLQIP,Mh as generateKeepAliveRuntime,Lh as generateKeepAliveCSS,gi as generateIslandManifest,jr as generateImagePreview,Tl as generateImageManifest,Ip as generateHydrationScript,af as generateHydrationRuntime,Lp as generateHydrationCSS,Vh as generateHydrationBootstrap,Nk as generateHotReloadScript,jb as generateHeatmapScript,zp as generateHMRClientScript,fk as generateHLSManifest,Fp as generateEventBindings,hj as generateDprSrcsetWithVariableQuality,gj as generateDprSrcset,eh as generateDocumentShell,no as generateDocs,jo as generateDirectivesDocs,Zi as generateDirectiveRuntime,pg as generateDefaultRobotsTxt,gk as generateDASHManifest,Yc as generateCss,Kd as generateCspMetaTag,Jd as generateCspHeader,Ef as generateCompositionRuntime,ho as generateComponentsDocs,Wh as generateComponentManifest,fo as generateComponentDoc,zj as generateColorPlaceholder,Jg as generateColorModeBootScript,om as generateClientRuntime,Ij as generateCacheKey,oc as generateBrowserAutoImportDestructuring,er as generateBlurUpRuntime,fr as generateBlurUpCSS,ad as generateBindingsRuntime,ej as generateAutoWidthSrcset,nc as generateAutoImportDestructuring,Hh as generateAsyncComponentRuntime,Gh as generateAsyncComponentCSS,fc as generateApiTypes,Na as generateAnimationRuntime,La as generateAnimationCSS,cd as generateAnalyticsScript,qp as formatTypecheckDiagnostics,jp as formatTypeErrors,Ko as formatStxContent,kl as formatSize,Ta as formatRoutes,Lo as formatMarkdownContent,g as formatLocalizedError,$ as formatICU,p as formatFilePath,w as formatError,Qr as formatDoctorReport,ko as formatDocsAsMarkdown,mo as formatDocsAsJson,lo as formatDocsAsHtml,mq as format,el as forgetKeptState,Cn as foldConstants,lq as flipVertical,kq as flipHorizontal,bn as fingerprint,op as findStxModuleDeclarations,np as findRuntimeTypeDeclarations,Or as findPantryPackage,Dc as findMustacheEnd,wd as findMatchingEndTag,sd as findMatchingDelimiter,Rb as findInterpolationEnd,yd as findIfBlocks,Bd as findExpressions,Sa as findErrorPage,Tc as findDuplicateScopedStyleRanges,zd as findDirectiveBlocks,zn as findDeadCode,zn as findDeadBranches,Km as findContainerRegion,go as findComponentFiles,ss as findCommonDir,jl as filterRequiredFiles,Ki as fileExists,Zf as extractVariables,oi as extractTemplateExpressions,Ue as extractStreamBoundaries,Gp as extractState,yi as extractSlotContent,$f as extractScriptFromTemplate,ni as extractScriptBlocks,vc as extractPlaceholders,vd as extractParenthesizedExpression,id as extractPageResponseStatus,hb as extractLayoutMetadata,yj as extractDominantColor,Ed as extractDirectiveParams,ti as extractDirectiveNames,Wm as extractContainerContent,co as extractComponentProps,Xh as extractComponentName,eo as extractComponentDescription,Xc as extractClassNames,pc as extractBridgeData,Yh as extractBoundProps,td as extractBalancedExpression,hc as extractAndStripCssImports,sk as extractAndScopeStyles,Ob as extractAndProcessEvents,Wk as externalizeSharedAssets,Xk as externalizeRepeatedAssets,Vk as externalizeHtml,Pc as evaluateExpression,Bn as evaluateConstant,qd as evaluateAuthExpression,Gc as escapeHtmlValue,Fc as escapeHtml,C as errorRecovery,E as errorLogger,rh as ensureTeleportTargets,ih as ensureDocumentShell,Ae as enhancedValidationRules,ao as enableDevTools,An as eliminateDeadCode,ff as effect,tq as dprUrls,oo as docsCommand,ec as discoverServerApi,_m as discoverLayoutNames,Xq as disconnectObserver,bo as disableDevTools,F as devHelpers,Rm as detectShell,po as detectRuntime,nl as detectProjectConfig,rj as detectFormat,un as detectBuildMode,ef as derived,rl as deploy,Gk as defineStxConfig,Tp as defineStore,Bf as defineSlots,cs as defineSiteConfig,gs as definePropsWithValidation,fs as defineProps,Ak as definePlugin,ie as definePageMeta,Wa as defineMiddleware,ii as defineForm,wf as defineExpose,vf as defineEmits,Wi as defineDirective,Gr as defineCustomElement,So as defineConfig,Xi as defineClientDirective,Eh as defineAsyncComponent,Uo as defineApiHandler,or as defaultMediaConfig,Vl as defaultImageConfig,M as defaultI18nConfig,ib as defaultHeatmapConfig,re as defaultFormClasses,yc as defaultFilters,_d as defaultCspConfig,Ck as defaultConfig,qs as default,Rc as deepMergeThemes,Uc as dedupeScopedStyles,Nm as decodeTitleEntities,wj as decodeThumbhash,eg as declareBareLoopHead,Vd as cspNonceDirective,Ud as cspDirective,cr as crossfadeTransition,Zp as crop,Ph as createVirtualList,lk as createVideoDirective,Bo as createVercelHandler,gp as createTypeChecker,fa as createTranslateFilter,xo as createTextEncoderStream,Fr as createStxApp,wo as createStreamingResponse,We as createStreamRenderer,Rp as createStore,Za as createStorageManager,Xa as createServerCookieManager,gc as createServerApi,Zl as createScope,zh as createSSRSuspense,bf as createRouter,Ym as createRouteRuleResolver,eb as createRouteLocation,ep as createRoute,_l as createRef,$l as createReactive,Df as createProvideContext,Xo as createProject,Ro as createProductionBuild,tc as createPlaceholder,Gn as createOptimizedBuild,Co as createNetlifyHandler,fl as createNetlifyClient,fb as createMiddlewareContext,dp as createMiddleware,Vq as createLazyObserver,Jh as createKeepAliveCache,to as createKVNamespace,Zh as createIslandRegistry,Yj as createImgDirective,Ql as createImagePlugin,Jl as createImageHandler,Ol as createImageDirective,nb as createHeatmapAggregator,il as createFileManifest,so as createEnvAccessor,z as createEnhancedError,vo as createEdgeHandler,uo as createEdgeCache,Ni as createDetailedErrorMessage,Ao as createDenoHandler,ol as createDefaultNetlifyConfig,Zd as createCspHeaders,Eo as createCookie,am as createComputed,Yl as createComponentInstance,zo as createCloudflareHandler,Ya as createClientCookieManager,Yi as createBuiltinDirectives,Fr as createApp,Ka as createAnimationTimeline,aq as cover,_f as convertToCommonJS,hq as contrast,$p as contain,y as consoleError,m as configureErrorHandling,Fk as config,am as computed,$n as compressResponse,Bg as composerPattern,Ag as composer,Tm as composeShellWithPage,Vn as componentDirective,Ii as componentClientSignalNames,fn as compileTemplate,a as collectRepeatedFlag,hl as collectDeployFiles,ch as cloakStyleFragment,Ic as clientLoopScopes,bk as clearVideoCache,N as clearTranslationCache,nh as clearStoreCache,$k as clearStorage,Gq as clearSignatureCache,Gf as clearServerData,Dj as clearPlaceholderCache,tg as clearOnceStore,Id as clearNonce,bb as clearMiddleware,Ke as clearImagePlaceholders,Ge as clearImageDeliveryCatalog,Nl as clearImageCache,e as clearErrorMessages,Tf as clearDevCaches,Cc as clearCustomFilters,Dg as clearComposers,oh as clearComposableCache,Oi as clearComponentCache,Mj as clearCache,Ib as clearBlankCache,vp as cleanupLoadingIndicator,Hm as classifyScript,Im as classifyAllScripts,hp as checkTemplateFile,ip as checkTemplate,Uf as checkCache,Dq as checkAuthAccess,na as checkA11yWithRegex,oa as checkA11y,Qn as channel,Jo as captureScreenshots,Io as captureScreenshot,Z as cancelPendingLoads,gl as calculateSha1,fj as calculateOptimalWidths,Vf as cacheTemplate,bc as cacheEngineFingerprint,nk as buildWebComponents,kp as buildVirtualSource,qr as buildViews,Vp as buildUrl,Qe as buildSuspenseResolveScript,bs as buildStaticSite,qb as buildRuntimeGlobalsDestructure,cn as buildRuntimeAsset,dn as buildRouterAsset,as as buildLangPickerScript,lj as buildImageUrl,Sg as buildIdFragment,_g as buildHtmlAttrs,sn as buildForProduction,Yn as buildComponentLibrary,Eq as buildAuthParams,tn as buildApp,_r as buildAlternateLinks,Qo as build,On as broadcastPrivate,Pn as broadcastPresence,Ln as broadcast,gq as brightness,Tb as bracketDepths,bq as blur,Jb as blankInertHtmlRegions,yq as batchSignUrls,gf as batch,sa as autoFixA11yFile,ta as autoFixA11yDirectory,ra as autoFixA11y,oq as auto,ja as attributeValue,en as assetTags,Mb as asInvocableStatement,ns as arrayOf,Xr as applyTranslations,Sj as applyTransformations,zi as applySlots,Un as applyPropDefaults,rq as applyPreset,ah as applyHtmlAttrs,ne as applyHead,Nc as applyFilters,Pm as appendVary,Od as apiCspPreset,Da as animationGroupDirective,hk as analyzeVideo,wn as analyzeUsage,Fm as analyzeTemplate,Gm as analyzeProject,wn as analyzeDirectiveUsage,ed as analyticsDirective,_o as addStore,Zo as addPage,Sd as addNonceToInlineContent,$o as addLayout,Yo as addComponent,on as actionRedirectResponse,Va as abortNavigation,ua as a11yDirective,Nf as __setSignalsGeneratorsForTest,Qg as __setBuildIdForTest,_j as VideoProcessorCache,ji as Validator,xa as TransitionType,za as TransitionEase,ya as TransitionDirection,rd as Tokenizer,fp as TemplateTypeChecker,Mo as TEMPLATE_PRESETS,v as StxValidationError,r as StxSyntaxError,t as StxSecurityError,s as StxRuntimeError,u as StxFileError,q as StxError,Br as Show,Re as SUSPENSE_RESOLVER_RUNTIME,ob as STX_RUNTIME_GLOBALS,jc as STX_AUTO_IMPORTS,Yb as STATE_DIR_ENV_VAR,Ga as SPRING_PRESETS,Lm as SPA_NAV_HEADER,Kb as SCROLL_BLOCKING_EVENTS,xb as RUNTIME_OWNED_COLON_ATTRS,zb as RUNTIME_HANDLED_X_ATTRS,Fb as RUNTIME_EVENT_NAMES,Db as RUNTIME_DIRECTIVE_NAMES,fd as RESPONSE_STATUS_KEY,gd as RESPONSE_HEADERS_KEY,tb as REACTIVE_RUNTIME_GLOBALS,Po as ProductionBuild,Dr as Portal,Wo as PROJECT_TEMPLATES,qq as PRESETS,Tg as OFFLINE_WORKER_PATH,Ug as OFFLINE_REGISTER_SCRIPT,sb as NON_CLIENT_PRIMITIVES,Mp as MemorySessionStore,cj as MIME_TYPES,$i as MEDIA_DEFAULT_WIDTHS,bj as MEDIA_DEFAULT_FORMATS,Zm as LAYOUT_TYPES_FILE,cl as KEPT_STATE_PREFIX,Pj as ImageProcessorCache,Hl as ImageProcessingError,Hp as HydrationRuntime,Mk as HotReloadServer,mb as HeatmapAggregator,Yg as HTML_CLASS_MARKER,Xg as HTML_ATTRS_MARKER,ur as Fragment,Cr as For,Mm as FRAGMENT_CACHE_CONTROL,D as ErrorLogger,h as ErrorCodes,Uk as EXTERNALIZED_ASSET_DIR,tl as DeployError,ul as DEFAULT_WIDTHS,Aa as DEFAULT_TRANSITION_OPTIONS,Xb as DEFAULT_STATE_DIR,wl as DEFAULT_QUALITY,sj as DEFAULT_PLACEHOLDER_OPTIONS,vl as DEFAULT_FORMATS,aj as DEFAULT_DPR_VALUES,yp as ComponentHMRHandler,pb as COMPONENT_SCOPE_LOCAL_GLOBALS,Bb as COMPONENT_PASSTHROUGH_X_ATTRS,rb as COMPILE_TIME_ONLY_GLOBALS,kj as COMMON_SIZES,Hg as COLOR_MODE_BOOT_MARKER,Ig as COLOR_MODE_BOOT_GLOBAL,Wg as CLOAK_STYLE,Sn as BroadcastServer,Rn as Broadcast,Ng as BUILD_ID_META,Og as BUILD_ID_HEADER,Ub as BROWSER_CORE_IMPORTS,tj as BLUR_UP_CSS,Ab as ALPINE_BRIDGE_X_ATTRS,Nr as $path};
2
+ import{$ as om,$a as ro,$b as Cp,$c as Cq,$d as Cr,A as _k,Aa as Cn,Ab as Wo,Ac as bq,Ad as br,Ae as hs,B as $k,Ba as Dn,Bb as Xo,Bc as cq,Bd as cr,Be as is,C as al,Ca as En,Cb as Yo,Cc as dq,Cd as dr,Ce as js,D as bl,Da as Fn,Db as Zo,Dc as eq,Dd as er,De as ks,E as cl,Ea as Gn,Eb as _o,Ec as fq,Ed as fr,Ee as ls,F as dl,Fa as Tn,Fb as $o,Fc as gq,Fd as gr,Fe as ms,G as el,Ga as Un,Gb as ap,Gc as hq,Gd as hr,Ge as ns,H as Wl,Ha as Vn,Hb as bp,Hc as iq,Hd as ir,He as os,I as Xl,Ia as Wn,Ib as cp,Ic as jq,Id as jr,Ie as ps,J as Yl,Ja as Xn,Jb as dp,Jc as kq,Jd as kr,Je as qs,K as Zl,Ka as Yn,Kb as ep,Kc as lq,Kd as lr,Ke as rs,L as _l,La as ao,Lb as fp,Lc as mq,Ld as mr,Le as ss,M as $l,Ma as bo,Mb as gp,Mc as nq,Md as nr,Me as ts,N as am,Na as co,Nb as hp,Nc as oq,Nd as or,Ne as us,O as bm,Oa as eo,Ob as ip,Oc as pq,Od as pr,P as cm,Pa as fo,Pb as jp,Pc as qq,Pd as qr,Q as dm,Qa as go,Qb as rp,Qc as rq,Qd as rr,R as em,Ra as ho,Rb as sp,Rc as sq,Rd as sr,S as fm,Sa as io,Sb as tp,Sc as tq,Sd as tr,T as gm,Ta as jo,Tb as up,Tc as uq,Td as ur,U as hm,Ua as ko,Ub as vp,Uc as vq,Ud as vr,V as im,Va as lo,Vb as wp,Vc as wq,Vd as wr,W as jm,Wa as mo,Wb as xp,Wc as xq,Wd as xr,X as km,Xa as no,Xb as yp,Xc as yq,Xd as yr,Y as lm,Ya as oo,Yb as zp,Yc as zq,Yd as zr,Z as mm,Za as po,Zb as Ap,Zc as Aq,Zd as Ar,_ as nm,_a as qo,_b as Bp,_c as Bq,_d as Br,aa as pm,ab as so,ac as Dp,ad as Dq,ae as Dr,ba as qm,bb as to,bc as Ep,bd as Eq,be as Er,ca as rm,cb as uo,cc as Fp,cd as Fq,ce as Fr,da as sm,db as vo,dc as Gp,dd as Gq,de as Gr,ea as tm,eb as wo,ec as Hp,ed as Hq,ee as Nr,fa as um,fb as xo,fc as Ip,fd as Iq,fe as Or,ga as vm,gb as yo,gc as Jp,gd as Jq,ge as Pr,ha as wm,hb as zo,hc as Kp,hd as Kq,he as Qr,ia as xm,ib as Ao,ic as Lp,id as Lq,ie as Rr,ja as ym,jb as Bo,jc as Mp,jd as Mq,je as Sr,ka as zm,kb as Co,kc as Np,kd as Nq,ke as Tr,la as Am,lb as Do,lc as Op,ld as Oq,le as Ur,ma as Bm,mb as Eo,mc as Pp,md as Pq,me as Vr,na as Cm,nb as Fo,nc as Qp,nd as Qq,ne as Wr,o as a,oa as Dm,ob as Go,oc as Rp,od as Rq,oe as Xr,p as Lk,pa as Em,pb as Ho,pc as Sp,pd as Sq,pe as Yr,q as Mk,qa as Fm,qb as Ko,qc as Tp,qd as Tq,qe as Zr,r as Nk,ra as Gm,rb as Lo,rc as Up,rd as Uq,re as _r,s as Ok,sa as un,sb as Mo,sc as Vp,sd as Vq,se as $r,t as Pk,ta as vn,tb as No,tc as Wp,td as Wq,te as as,u as Qk,ua as wn,ub as Po,uc as Xp,ud as Xq,ue as bs,v as Rk,va as xn,vb as Qo,vc as Yp,vd as Yq,ve as cs,w as Sk,wa as yn,wb as Ro,wc as Zp,wd as Zq,we as ds,x as Tk,xa as zn,xb as So,xc as _p,xd as _q,xe as es,y as Yk,ya as An,yb as Uo,yc as $p,yd as $q,ye as fs,z as Zk,za as Bn,zb as Vo,zc as aq,zd as ar,ze as gs}from"./chunk-n9nb4e1v.js";import{Oe as kp,Pe as lp,Qe as mp,Re as np,Se as op,Te as pp,Ue as qp}from"./chunk-za3zzk6p.js";import{Ve as Io,We as Jo}from"./chunk-pkspqh0m.js";import{Xe as Oo}from"./chunk-cf05s8c1.js";import{Ye as tn}from"./chunk-h3zqzczc.js";import{$e as $n,Ze as Zn,_e as _n,af as To}from"./chunk-b5rc4t8t.js";import{bf as fl,cf as gl,df as hl,ef as il,ff as jl,gf as kl,hf as ll,if as ml,jf as nl,kf as ol,lf as pl,mf as ql,nf as rl,of as sl,pf as tl}from"./chunk-ewxbx67c.js";import{Af as Ul,Bf as Vl,qf as Kl,rf as Ll,sf as Ml,tf as Nl,uf as Ol,vf as Pl,wf as Ql,xf as Rl,yf as Sl,zf as Tl}from"./chunk-h7qv6sc5.js";import{Cf as Il,Df as Jl}from"./chunk-qnye902b.js";import{Ef as ul,Ff as vl,Gf as wl,Hf as xl,If as yl,Jf as zl,Kf as Al,Mf as Bl,Nf as Cl,Of as Dl,Pf as El,Qf as Fl,Rf as Gl,Uf as Hl}from"./chunk-mntzk6ga.js";import{Vf as bn,Wf as cn,Xf as dn,Yf as en,Zf as fn,_f as sn}from"./chunk-8aa32p8v.js";import{$f as Hm,ag as Im,bg as Jm,cg as Km,dg as Lm,eg as Mm,fg as Nm,gg as Om,hg as Pm,ig as Qm,jg as Rm,kg as Sm,lg as Tm,mg as Um,ng as Vm,og as Wm,pg as gn,qg as hn,rg as jn,sg as kn,tg as ln,ug as mn,vg as nn,wg as on,xg as pn,yg as qn,zg as rn}from"./chunk-eg30ksd8.js";import{Ag as Xm,Bg as Ym}from"./chunk-g64qyhhb.js";import{Cg as Hn,Dg as In,Eg as Jn,Fg as Kn,Gg as Ln,Hg as Mn,Ig as Nn,Jg as On,Kg as Pn,Lg as Qn,Mg as Rn,Ng as Sn}from"./chunk-9vwpf0bk.js";import{Og as ui,Pg as vi,Qg as wi,Rg as xi,Sg as yi,Tg as zi}from"./chunk-bs2a7a2b.js";import{$g as Tj,Ug as Pj,Vg as Qj,Wg as Rj,_g as Sj,ah as Uj}from"./chunk-2n3twnde.js";import{bh as _j,ch as $j,dh as ak,eh as bk,fh as ck,gh as dk,hh as ek,ih as fk,jh as gk,kh as hk,lh as ik}from"./chunk-2g3ffsc9.js";import{mh as Fj,nh as Gj,oh as Hj,ph as Ij,qh as Jj,sh as Kj,th as Lj,uh as Mj,vh as Nj,wh as Oj}from"./chunk-6rzwef28.js";import{xh as Ak,zh as Bk}from"./chunk-683tfkz4.js";import{Fh as Ph,Gh as Qh,Hh as Rh,Ih as Sh,Jh as Th,Kh as Uh}from"./chunk-9r2xgf5k.js";import{Mh as Vh,Nh as Wh,Oh as Xh,Ph as Yh,Qh as Zh,Rh as _h,Sh as $h,Th as ai,Uh as bi,Vh as ci,Wh as di,Xh as ei,Yh as fi,Zh as gi}from"./chunk-9368t9jm.js";import{$h as hi,ai as ii,bi as ji,ci as ki}from"./chunk-st9vrfw7.js";import{hi as li}from"./chunk-mwh3ymwc.js";import{ki as oh}from"./chunk-pj0jjn5b.js";import{li as ph}from"./chunk-1t5vwavd.js";import{mi as qh,ni as rh}from"./chunk-cks5rbzt.js";import{oi as sh,pi as th,qi as uh,ri as vh,si as wh,ti as xh}from"./chunk-092qw0ps.js";import{ui as yh,vi as zh,wi as Ah,xi as Bh,yi as Ch}from"./chunk-kpg48dhw.js";import{Ai as Eh,Bi as Fh,Ci as Gh,Di as Hh,zi as Dh}from"./chunk-4bb28mz5.js";import{Ei as Ih,Fi as Jh,Gi as Kh,Hi as Lh,Ii as Mh,Ji as Nh,Ki as Oh}from"./chunk-90zfg77v.js";import{Li as mh,Mi as nh}from"./chunk-j89wctm5.js";import"./chunk-452k8psm.js";import{$i as _e,Qi as Pe,Ri as Qe,Si as Re,Ti as Se,Ui as Te,Vi as Ue,Wi as Ve,Xi as We,Yi as Xe,Zi as Ye,_i as Ze,aj as $e,bj as af}from"./chunk-chn6e3en.js";import{cj as sf,dj as tf,ej as uf,fj as vf,gj as wf,hj as xf,ij as yf,jj as zf,kj as Af,lj as Bf,mj as Cf,nj as Df,oj as Ef,pj as Ff,qj as Gf,rj as Hf,sj as If}from"./chunk-szcxpbfn.js";import{Aj as ef,Bj as ff,Cj as gf,Dj as hf,Ej as jf,Fj as kf,Gj as lf,Hj as mf,Ij as nf,Jj as of,Kj as pf,Lj as qf,Mj as rf,zj as df}from"./chunk-mnk5mdwp.js";import{Nj as Jf,Oj as Kf,Pj as Lf,Qj as Mf,Rj as Nf,Sj as Of,Tj as Pf,Uj as Qf,Vj as Rf,Wj as Sf,Xj as Tf,Yj as Uf,Zj as Vf,_j as Wf}from"./chunk-2hy87cn4.js";import{sk as Hr,tk as Ir,uk as Jr,vk as Kr,wk as Lr,xk as Mr}from"./chunk-xe06rkka.js";import{Ak as Wk,Bk as Xk,Ck as Zm,Dk as _m,Ek as $m,Fk as an,yk as Uk,zk as Vk}from"./chunk-ht9rdkf3.js";import"./chunk-7eea1cse.js";import"./chunk-14rh4kd0.js";import{ql as ec,rl as fc,vl as gc}from"./chunk-etah20m0.js";import{xl as bc}from"./chunk-2andsajh.js";import{$l as Nb,$m as id,$n as Ce,$o as tg,$q as wj,Al as za,Am as Bc,An as Nd,Ap as Ug,Aq as Oi,Ar as wk,Bl as Aa,Bm as Cc,Bn as Od,Bp as Vg,Bq as Pi,Br as xk,Cl as Ba,Cm as Dc,Cn as Pd,Cp as Wg,Cq as Qi,Cr as yk,Dl as Ca,Dm as Ec,Dn as Qd,Dp as Xg,Dq as Ri,Dr as zk,El as Da,Em as Fc,En as Rd,Ep as Yg,Eq as $i,Er as Ck,Fl as Ea,Fm as Gc,Fn as Sd,Fp as Zg,Fq as aj,Fr as Dk,Gl as Fa,Gm as Hc,Gn as Td,Go as Yf,Gp as _g,Gq as bj,Gr as Ek,Hl as Ga,Hm as Ic,Hn as Ud,Hp as $g,Hq as cj,Hr as Fk,Il as Ha,Im as Jc,In as Vd,Ip as ah,Iq as dj,Ir as Gk,Jl as Ia,Jm as Kc,Jn as Wd,Jp as bh,Jq as ej,Jr as Hk,Kl as Ja,Km as Lc,Kn as Xd,Kp as ch,Kq as fj,Kr as Ik,Ll as Ka,Lm as Mc,Ln as Yd,Lp as dh,Lq as gj,Lr as Jk,Ml as La,Mm as Nc,Mn as Zd,Mp as eh,Mq as hj,Mr as Kk,Nl as Ma,Nm as Oc,Nn as _d,Np as fh,Nq as ij,Ol as Na,Om as Pc,On as $d,Oo as Zf,Op as gh,Oq as jj,Pl as Oa,Pm as Qc,Pn as ae,Pp as hh,Pq as kj,Ql as ib,Qm as _c,Qn as re,Qo as _f,Qp as ih,Qq as lj,Rl as jb,Rm as $c,Rn as se,Rp as jh,Rq as mj,Sl as kb,Sm as ad,Sn as te,So as $f,Sp as kh,Sq as nj,Tl as lb,Tm as bd,Tn as ue,To as ag,Tp as lh,Tq as oj,Ul as mb,Um as cd,Un as ve,Uo as bg,Up as mi,Uq as pj,Vl as nb,Vm as dd,Vn as we,Vo as cg,Vp as ni,Vq as qj,Wm as ed,Wn as xe,Wo as dg,Wq as rj,Xn as ye,Xo as eg,Xq as sj,Yl as Kb,Ym as fd,Yn as ze,Yo as qg,Yp as oi,Yq as tj,Zl as Lb,Zm as gd,Zn as Ae,Zo as rg,Zq as uj,_l as Mb,_m as hd,_n as Be,_o as sg,_q as vj,am as Ob,an as jd,ao as De,ap as ug,ar as xj,bm as Pb,bn as kd,bo as Ee,bp as vg,br as yj,cm as Qb,cn as ld,cp as wg,cr as zj,dm as Ub,dn as md,do as Ie,dp as xg,dr as Aj,em as Vb,en as nd,eo as Je,ep as yg,er as Bj,fm as Wb,fn as od,fo as Ke,fp as zg,fr as Cj,gm as hc,gn as pd,go as Le,gp as Ag,gr as Dj,hm as ic,hn as qd,ho as Me,hp as Bg,hq as pi,hr as Ej,im as jc,in as vd,io as Ne,ip as Cg,iq as qi,ir as Vj,jm as kc,jn as wd,jo as Oe,jp as Dg,jq as ri,jr as Wj,km as lc,kn as xd,kp as Eg,kq as si,kr as Xj,lm as mc,ln as yd,lp as Fg,lq as ti,lr as Yj,mm as nc,mn as zd,mp as Gg,mq as Ai,mr as Zj,nm as oc,nn as Ad,no as bf,np as Hg,nq as Bi,nr as jk,om as pc,on as Bd,oo as cf,op as Ig,oq as Ci,or as kk,pm as qc,pn as Cd,pp as Jg,pq as Di,pr as lk,qm as rc,qn as Dd,qo as Xf,qp as Kg,qq as Ei,qr as mk,rm as sc,rn as Ed,rp as Lg,rq as Fi,rr as nk,sm as tc,sn as Fd,sp as Mg,sq as Gi,sr as ok,tm as uc,tn as Gd,tp as Ng,tq as Hi,tr as pk,um as vc,un as Hd,up as Og,uq as Ii,ur as qk,vm as wc,vn as Id,vp as Pg,vq as Ji,vr as rk,wm as xc,wn as Jd,wp as Qg,wq as Ki,wr as sk,xm as yc,xn as Kd,xp as Rg,xq as Li,xr as tk,yl as xa,ym as zc,yn as Ld,yp as Sg,yq as Mi,yr as uk,zl as ya,zm as Ac,zn as Md,zp as Tg,zq as Ni,zr as vk}from"./chunk-ptad3t7a.js";import{$r as _,Nr as M,Or as N,Pr as O,Qr as P,Rr as Q,Sr as R,Tr as S,Ur as T,Vr as U,Wr as V,Xr as W,Yr as X,Zr as Y,_r as Z,as as $,bs as aa,cs as ba,ds as ca,es as da,fs as ea,gs as fa,hs as ia,is as ja,js as ka,ks as la,ls as ma,ms as na,ns as oa,os as pa,ps as qa,qs as ra,rs as sa,ss as ta,ts as ua,us as va,vs as wa}from"./chunk-y9f9g2kh.js";import{ws as ga,xs as ha}from"./chunk-ah8gs0q2.js";import{As as Tb,ys as Rb,zs as Sb}from"./chunk-saf4xhac.js";import"./chunk-wheh08v2.js";import{Hs as Si,Is as Ti,Js as Ui,Ks as Vi,Ls as Wi,Ms as Xi,Ns as Yi,Os as Zi,Ps as _i}from"./chunk-jct6cs2k.js";import{ft as Rc,gt as Sc,ht as Tc,it as Uc,jt as Vc,lt as Wc,ut as Xc,vt as Yc,wt as Zc}from"./chunk-ndydf37f.js";import{At as _b,Bt as $b,Ct as ac,xt as Xb,yt as Yb,zt as Zb}from"./chunk-7vftjm43.js";import{Jt as Fe,Lt as Ge,Ot as He}from"./chunk-4azk3jdd.js";import"./chunk-jbtzq3xt.js";import{Tt as cc,Ut as dc}from"./chunk-mjearf0g.js";import{$t as ig,Yt as fg,Zt as gg,_t as hg,au as jg,bu as kg,cu as lg,eu as mg,fu as ng,gu as og,hu as pg}from"./chunk-9rp8f7jz.js";import{Au as ge,Bu as he,Cu as ie,Du as je,Eu as ke,Fu as le,Gu as me,Hu as ne,Iu as oe,Ju as pe,Ku as qe,iu as rd,ju as sd,ku as td,lu as ud,vu as be,wu as ce,xu as de,yu as ee,zu as fe}from"./chunk-8ghwewek.js";import{$u as u,Lu as b,Mu as c,Nu as d,Ou as e,Pu as f,Qu as g,Ru as h,Su as i,Tu as m,Uu as n,Vu as o,Wu as p,Xu as q,Yu as r,Zu as s,_u as t,av as v,bv as w,cv as x,dv as y,ev as z,fv as A,gv as B,hv as C,iv as D,jv as E,kv as F,lv as G,mv as H,nv as I,ov as J,pv as K,qv as L}from"./chunk-rk8p4b1z.js";import"./chunk-fpxz25xz.js";import"./chunk-nn42gs3q.js";import{$v as Jb,Gv as ob,Hv as pb,Iv as qb,Jv as rb,Kv as sb,Lv as tb,Mv as ub,Nv as vb,Ov as wb,Pv as xb,Qv as yb,Rv as zb,Sv as Ab,Tv as Bb,Uv as Cb,Vv as Db,Wv as Eb,Xv as Fb,Yv as Gb,Zv as Hb,_v as Ib}from"./chunk-v54tq312.js";import{Aw as $a,Bw as ab,Cw as bb,Dw as cb,Ew as db,Fw as eb,Gw as fb,Hw as gb,Jw as hb,dw as Pa,ew as Qa,hw as Ra,mw as Sa,nw as Ta,tw as Ua,uw as Va,vw as Wa,ww as Xa,xw as Ya,yw as Za,zw as _a}from"./chunk-qbc0bebg.js";import"./chunk-4yc9gx6h.js";import{Vw as j,Ww as k,Xw as l}from"./chunk-d6rkgay9.js";import"./chunk-cevkpyn9.js";export{pl as writeNetlifyConfig,hn as writeManifest,Ul as writeImageManifest,Ap as wrapComponentForHMR,hs as withDefaults,zk as webComponentDirectiveHandler,pq as watermark,rr as watchViews,cm as watchMultiple,dm as watchEffect,bm as watch,Me as warmImagePlaceholders,qm as waitForStore,X as waitForLocale,lp as virtualPathFor,mk as videoDirective,G as validators,ls as validated,Ce as validateValueEnhanced,pi as validateTemplate,Xm as validateRouteRules,uq as validateParams,De as validateFormEnhanced,gr as validateFile,ye as validateFields,xe as validateField,ri as validateDirective,Xd as validateCspDirectives,Hk as validateConfig,vn as validateComponentScripts,Tn as validateComponentProps,lh as validateClientScript,ki as v,Hc as usesSignalsInScript,ub as usesReactiveRuntime,Fi as userComponentFileExists,Sh as useVirtualList,je as useTitle,pm as useStoreOrThrow,Sp as useStore,Yk as useStorage,Af as useSlots,_k as useSessionStorage,cc as useServerRuntimeConfig,Yf as useServerData,ge as useSeoMeta,dc as useRuntimeConfig,rm as useRouteParams,tm as useRouteParamOrThrow,sm as useRouteParam,je as usePageTitle,rf as useOptimistic,Ff as useModel,vm as useMiddlewareValue,um as useMiddlewareState,Zk as useLocalStorage,tp as useLoadingIndicator,ee as useHead,hi as useForm,Cf as useAttrs,ir as uploadFiles,hr as uploadFile,mm as updateInstance,pf as untrack,Vi as unregisterDirective,nm as unmountInstance,Qc as unescapeHtml,pp as typecheckStxFiles,Di as transpileTypeScript,Wr as translate,Ba as transitionDirective,lc as transformAutoImports,Nn as toUsers,Mn as toUser,_p as thumbnail,$q as thumbHashToRGBA,ar as thumbHashToDataURL,wb as templateNeedsRuntime,vb as templateHasReactiveContext,Jf as templateCache,nd as syncRecordedResponse,xp as stxClientHelpers,kg as structuredDataDirective,Zr as stripLocalePrefix,Um as stripDocumentWrapper,Sb as stripCommentsAndLiterals,yo as stringToStream,Ld as strictCspPreset,Xe as streamingSuspenseDirective,$e as streamToResponse,Ve as streamTemplateSimple,Pe as streamTemplate,Tk as stopHmrServer,Jn as stopBroadcasting,_b as stateDirName,$b as stateDir,df as state,fh as startsDocument,To as startProductionServer,Oo as startInteractive,In as startBroadcasting,$r as stampLocaleLayoutGroup,Ia as staggerDirective,sq as srcsetUrls,Ja as springDirective,ud as splitByPipe,Qm as spaNavVaryHeaders,mp as sourcePathFor,zq as smartBatchSign,Hi as slotContentHasExpressions,xq as signUrl,Bi as shouldTranspileTypeScript,Qk as shouldReloadOnChange,Cq as shouldRefreshSignature,Rk as shouldIgnoreFile,Kh as shouldCacheComponent,cq as sharpen,os as shape,Zb as setStateDir,zm as setRouteParams,Am as setMiddlewareState,Le as setImagePlaceholder,uf as setGlobalProvide,b as setErrorLocale,Wl as setCurrentInstance,ak as setCachedVideoResult,Rj as setCachedImageResult,Lj as setCached,rs as serveStxFile,ts as serveMultipleStxFiles,Lk as serveMarkdownFile,cp as serveFile,us as serveApp,bp as serve,Dp as serializeState,kn as serializeSetCookie,eq as sepia,he as seoMetaToHeadConfig,Ca as scrollAnimateDirective,va as screenReaderDirective,Ei as scopeOnRootElement,qk as scopeHTML,pk as scopeCSS,ng as scanForSitemapEntries,pa as scanA11yTargets,qa as scanA11yIssues,iq as saturation,vq as sanitizeParams,I as sanitizeFilePath,J as sanitizeExpression,K as sanitizeDirectiveParams,H as sanitizeDirectiveParam,L as sanitizeComponentProps,B as safeExecuteAsync,A as safeExecute,Cb as runtimeHandledXAttrsLiteral,Gb as runtimeEventRegexLiteral,Eb as runtimeDirectiveNamesLiteral,yg as runPreProcessingMiddleware,zg as runPostProcessingMiddleware,nn as runPageAction,kf as runMountCallbacks,gb as runMiddleware,km as runHooks,Pr as runDoctor,lf as runDestroyCallbacks,Cg as runComposers,jq as rotate,li as rewriteImagesWithSiblings,od as responseBindings,Li as resolveTemplatePath,ha as resolveStxTargets,Dk as resolveStxDirectories,Vr as resolveI18n,Yp as resize,qg as resetUnscopedSignalWarnings,Oc as resetRejectedExpressionWarnings,sc as resetPlaceholders,de as resetHead,Cp as resetHMRHandler,o as resetErrorConfig,js as required,cg as reportDeferredLoopWarnings,wc as replacePlaceholders,Ec as replaceInterpolations,pr as renderView,jk as renderVideoComponent,ic as renderVendorStyleTags,yr as renderToString,zr as renderToStream,Ar as renderToDOM,_q as renderThumbhashToCanvas,Mr as renderTemplateString,Kr as renderTemplate,Lr as renderString,Se as renderStreamingPage,wi as renderSlot,Ah as renderSSRSuspense,Kq as renderProtectedVideo,Jq as renderProtectedImg,wq as renderMediaUpload,Jr as renderMarkdownView,$m as renderLayoutTypes,Vj as renderImgComponent,Kl as renderImageComponent,le as renderHtmlAttrs,ke as renderHead,sr as renderEmail,Ji as renderComponentWithSlot,me as renderBodyAttrs,Np as render,Nd as relaxedCspPreset,we as registerValidationRule,Ze as registerStreamingDirectives,Up as registerStoresClient,xm as registerStore,Rf as registerServeModuleBundle,lg as registerSeoDirectives,_a as registerMiddleware,Ac as registerFilters,zc as registerFilter,d as registerErrorMessages,Be as registerEnhancedValidationRule,Si as registerDirective,Wd as registerCspDirectives,Wn as registerComponentDirectives,Oa as registerAnimationDirectives,wa as registerA11yDirectives,mc as referencesName,_l as ref,Go as redirect,jd as recordResponseStatus,kd as recordResponseHeader,ac as rebaseOntoStateDir,ld as readResponseStatus,md as readResponseHeaders,Jk as readMarkdownFile,Kf as readFileCached,$l as reactive,nq as quality,Hq as pruneSignatureCache,Oj as pruneCache,sf as provide,Ir as protectCodeBlocks,is as prop,Fg as processVueTemplate,Qh as processVirtualListDirectives,Uh as processVirtualGridDirectives,ik as processVideo,ze as processValidateDirective,ea as processTranslateDirective,uh as processTransitionDirectives,xh as processTransitionAttributes,pe as processTitleDirective,bd as processTemplateBindings,qh as processTeleportDirectives,yh as processSuspenseDirectives,gg as processStructuredData,Te as processStreamDirectives,pd as processStatusDirective,fi as processStaticDirectives,wg as processStackReplacements,vg as processStackPushDirectives,xi as processSlots,Sm as processShell,Oe as processServerBindings,hg as processSeoDirective,_e as processSectionDirectives,Vc as processScopedStyles,$c as processReactiveBindings,Lq as processProtectedMedia,_h as processPartialHydrationDirectives,kh as processOnceDirective,xg as processMiddleware,fg as processMetaDirectives,qe as processMetaDirective,Kk as processMarkdownFileDirectives,Qi as processMarkdownDirectives,dg as processLoops,Ih as processKeepAliveDirectives,jh as processJsonDirective,Th as processInfiniteListDirectives,ug as processIncludes,Xj as processImgComponents,Ml as processImageComponents,zl as processImage,oe as processHeadDirective,se as processForms,ue as processFormInputDirectives,Mc as processExpressions,Pb as processEventDirectives,ve as processErrorDirective,Gg as processDynamicComponents,mi as processDirectives,_i as processDirectiveAttributes,ph as processDeferDirectives,$d as processCustomDirectives,Td as processCspDirectives,ps as processComponentProps,rc as processClientScript,te as processBasicFormDirectives,Dh as processAsyncDirectives,ae as processAppearanceBootstrapDirective,Fa as processAnimationDirectives,ka as processA11yDirectives,He as prepareImageDelivery,T as preloadTranslationsBackground,S as preloadTranslations,sp as preloadIslandHandlers,Ne as preloadIconCollection,En as poolStrings,Bk as pluginManager,Je as placeholdersWarmed,th as performLeave,sh as performEnter,mf as pendingLifecycleCounts,qf as peek,rg as partialsCache,kk as parseVideoDirectiveOptions,Wp as parseUrl,br as parseThumbhashString,Ad as parseSwitchBlock,ui as parseSlots,vi as parseSlotElement,Fd as parseScriptDeclarations,xk as parseSFCComponent,Mq as parseProtectedArgs,bg as parseLoopBinding,Wj as parseImgComponent,mj as parseImageUrl,Ll as parseImageComponent,ln as parseFormBody,Cd as parseExpressionWithFilters,Xn as parseDefaults,Do as parseCookies,Jm as parseContainerSelector,xd as parseConditionalBlock,Dd as parseArguments,Ma as parseAnimationShorthand,ks as optional,Fn as optimizeTemplate,Rl as optimizeImage,Sl as optimizeDirectory,ms as oneOf,sg as onceStore,hm as onUpdated,_c as onUpdate,jm as onUnmounted,Em as onServer,fm as onMounted,hf as onMount,ei as onHydrated,yf as onErrorCaptured,jf as onDestroy,Oh as onDeactivated,Dm as onClient,gm as onBeforeUpdate,im as onBeforeUnmount,em as onBeforeMount,Nh as onActivated,Wq as observeElement,Ho as notFound,Lg as normalizeCriticalHeadOrder,xf as nextTick,_n as negotiateEncoding,Ua as navigateTo,lm as mountInstance,Ea as motionDirective,Md as moderateCspPreset,Dn as minifyHtml,jg as metaDirective,Zg as metaDedupKey,Xp as mergeParams,$g as mergeHtmlAttrs,fe as mergeHeadConfigs,Sc as mergeCssConfig,Qd as mergeCspDirectives,Ra as matchRoute,Ri as markdownDirectiveHandler,Ik as markdownCache,ga as looksLikeGlob,Yr as localizePath,U as loadTranslationLazy,_ as loadTranslation,Ek as loadStxConfig,db as loadMiddlewareFromDirectory,jn as loadManifest,Sq as loadElement,Kn as loadChannels,Lb as listensPassively,ds as lintStxStrict,Uq as lazyLoadAll,Tq as lazyLoad,Ha as keyframeDirective,dl as keptState,wr as jsxs,xr as jsxDEV,vr as jsx,Fo as jsonResponse,Ye as islandDirective,l as isTest,Vm as isSpaNavigation,Om as isSpaNavRequest,Aq as isSignatureValid,nf as isSignal,xl as isSharpAvailable,ro as isServerEnvironment,Bm as isServer,yb as isRuntimeOwnedColonAttr,Hb as isRuntimeEventName,da as isRtlLocale,j as isProduction,ia as isPresentationalRole,Pq as isNativeLazySupported,Hr as isMarkdownPath,Q as isLoading,R as isLoaded,Ai as isJavaScriptScript,Qq as isIntersectionObserverSupported,Fl as isImageFile,yl as isImageBackendAvailable,aa as isICUFormat,di as isHydrated,Gi as isHydrateTrigger,hd as isHttpStatus,qo as isEdgeEnvironment,es as isDirectiveKind,k as isDevelopment,of as isDerived,Pk as isCssOnlyChange,Zn as isCompressible,Cm as isClient,Fh as isAsyncComponent,mn as isActionableMethod,fq as invert,Mf as invalidateFileCacheByDir,Lf as invalidateFileCache,Lc as interpolateScriptsInTemplate,Jc as interpolateScriptExpressions,Kc as interpolateScriptAttributes,x as inlineError,Ur as injectThemeBootstrap,ig as injectSeoTags,Rr as injectSeo,Xf as injectRouterScript,Ok as injectHotReload,kb as injectHeatmap,Zc as injectCss,Rd as injectCspMetaTag,hh as injectConfigHeadTags,Kg as injectColorModeBootScript,bh as injectCloakStyle,Rg as injectBuildId,kc as injectBrowserCoreAutoImports,dd as injectAnalytics,tf as inject,wm as initStoreRegistry,sl as initNetlify,up as initLoadingIndicator,Rq as initLazyLoading,No as initFile,Zq as initBlurUp,dr as initAllBlurUp,Zj as imgDirective,Pl as imageDirective,qn as hydrateTemplateStream,pn as hydrateTemplate,rp as hydrateIslands,ai as hydrateIsland,rn as hydrateFragment,bi as hydrateByStrategy,ci as hydrateAll,Kp as hydrate,ap as htmlResponse,dh as hoistLeadingHeadTags,Mg as hoistColorModeBootScript,lb as heatmapDirective,Hj as hashString,Wf as hashFilePath,Fj as hashFile,Gj as hashBuffer,Eg as hasVueTemplateSyntax,ag as hasVariables,Pp as hasStore,xc as hasPlaceholders,ql as hasNetlifyConfig,ab as hasMiddleware,Qb as hasEventDirectives,gh as hasDocumentShell,si as hasDirectives,ma as hasDOMSupport,Il as handleImageRequest,zf as handleError,Er as h,El as groupVariantsByFormat,dq as grayscale,Vo as gitHash,xn as getUnusedDirectives,V as getTranslationSync,O as getTranslationCacheStats,W as getTranslationAsync,ba as getTranslation,ll as getTotalSize,Bq as getTimeUntilExpiry,mh as getStoreScript,Qp as getStoreNames,Op as getStore,bl as getStorageSize,al as getStorageKeys,Mi as getSourceLineInfo,Ci as getSharedTranspiler,Sf as getServeModuleBundle,Qf as getServeClientAsset,la as getScreenReaderOnlyStyle,rk as getScopeAttribute,cf as getRouteParams,Vb as getPublicEnvDefine,Wb as getPublicEnv,qi as getPositionInfo,uc as getPlaceholderRegistry,Ej as getPlaceholderCacheStats,ce as getPageMeta,Hd as getNonce,Gl as getMimeType,cb as getMiddlewareNames,$a as getMiddleware,ca as getLocaleDirection,P as getLoadingState,Y as getLoadingLocales,Ie as getImagePlaceholder,Al as getImageMetadata,Fe as getImageDelivery,Jp as getHydrationRuntime,ym as getHydratedStoreState,Sk as getHmrServer,be as getHead,Bp as getHMRHandler,qj as getFormatExtension,Jj as getFileMtime,Dl as getFallbackVariant,f as getErrorMessage,c as getErrorLocale,n as getErrorConfig,i as getErrorCodeName,Ui as getDirectives,Ti as getDirective,Xl as getCurrentInstance,Wc as getCssServeAsset,Pd as getCspPreset,Yd as getCspHeaderName,Pi as getComponentCacheStats,$j as getCachedVideoResult,Fq as getCachedSignature,Of as getCachedSignalsRuntime,Pf as getCachedRouterScript,Cj as getCachedPlaceholder,Qj as getCachedImageResult,Kj as getCached,Nj as getCacheStats,Pg as getBuildId,Hn as getBroadcastServer,pj as getBestVariant,Bc as getAllFilters,dj as generateWidthSrcset,Rh as generateVirtualListCSS,kr as generateVideoPreview,Ee as generateValidationScript,lr as generateUploadRuntime,yn as generateTreeShakenBundle,wh as generateTransitionRuntime,vh as generateTransitionCSS,dk as generateThumbnails,vj as generateThumbhashPlaceholder,io as generateTemplatesDocs,Ch as generateSuspenseRuntime,Bh as generateSuspenseCSS,Ep as generateStateScript,nj as generateSrcsetData,Uj as generateSrcset,Bl as generateSrcSet,ek as generateSpriteSheet,tr as generateSpaShell,oj as generateSourceTags,jj as generateSizesFromBreakpoints,ij as generateSizesAttribute,Cl as generateSizes,mg as generateSitemapIndex,Sr as generateSitemap,Oq as generateSimpleMediaPicker,Iq as generateSignatureRuntime,If as generateSignalsRuntimeDev,Hf as generateSignalsRuntime,qc as generateServerDataBridge,ok as generateScopeId,yk as generateSFCWebComponent,Nb as generateRuntimeScript,Pa as generateRouteTypes,Qa as generateRouteManifest,og as generateRobotsTxt,Tr as generateRobots,Tj as generateResponsiveVariants,uk as generateReactiveWebComponentTS,tk as generateReactiveWebComponent,wk as generateReactiveRuntime,vk as generateReactiveMixin,ck as generatePoster,Bj as generatePlaceholderStyle,Aj as generatePlaceholderCSS,uj as generatePlaceholder,$h as generatePartialHydrationCSS,Vg as generateOfflineWorker,Gd as generateNonce,ml as generateNetlifyToml,nr as generateMinifiedMediaRuntime,mr as generateMediaRuntime,Nq as generateMediaManagerEmbed,gn as generateManifest,wp as generateLoadingIndicatorHtml,Yq as generateLazyLoadRuntime,an as generateLayoutTypes,xj as generateLQIP,Mh as generateKeepAliveRuntime,Lh as generateKeepAliveCSS,gi as generateIslandManifest,jr as generateImagePreview,Tl as generateImageManifest,Ip as generateHydrationScript,af as generateHydrationRuntime,Lp as generateHydrationCSS,Vh as generateHydrationBootstrap,Nk as generateHotReloadScript,jb as generateHeatmapScript,zp as generateHMRClientScript,fk as generateHLSManifest,Fp as generateEventBindings,hj as generateDprSrcsetWithVariableQuality,gj as generateDprSrcset,eh as generateDocumentShell,no as generateDocs,jo as generateDirectivesDocs,Zi as generateDirectiveRuntime,pg as generateDefaultRobotsTxt,gk as generateDASHManifest,Yc as generateCss,Kd as generateCspMetaTag,Jd as generateCspHeader,Ef as generateCompositionRuntime,ho as generateComponentsDocs,Wh as generateComponentManifest,fo as generateComponentDoc,zj as generateColorPlaceholder,Jg as generateColorModeBootScript,om as generateClientRuntime,Ij as generateCacheKey,oc as generateBrowserAutoImportDestructuring,er as generateBlurUpRuntime,fr as generateBlurUpCSS,ad as generateBindingsRuntime,ej as generateAutoWidthSrcset,nc as generateAutoImportDestructuring,Hh as generateAsyncComponentRuntime,Gh as generateAsyncComponentCSS,fc as generateApiTypes,Na as generateAnimationRuntime,La as generateAnimationCSS,cd as generateAnalyticsScript,qp as formatTypecheckDiagnostics,jp as formatTypeErrors,Ko as formatStxContent,kl as formatSize,Ta as formatRoutes,Lo as formatMarkdownContent,g as formatLocalizedError,$ as formatICU,p as formatFilePath,w as formatError,Qr as formatDoctorReport,ko as formatDocsAsMarkdown,mo as formatDocsAsJson,lo as formatDocsAsHtml,mq as format,el as forgetKeptState,Cn as foldConstants,lq as flipVertical,kq as flipHorizontal,bn as fingerprint,op as findStxModuleDeclarations,np as findRuntimeTypeDeclarations,Or as findPantryPackage,Dc as findMustacheEnd,wd as findMatchingEndTag,sd as findMatchingDelimiter,Rb as findInterpolationEnd,yd as findIfBlocks,Bd as findExpressions,Sa as findErrorPage,Tc as findDuplicateScopedStyleRanges,zd as findDirectiveBlocks,zn as findDeadCode,zn as findDeadBranches,Km as findContainerRegion,go as findComponentFiles,ss as findCommonDir,jl as filterRequiredFiles,Ki as fileExists,Zf as extractVariables,oi as extractTemplateExpressions,Ue as extractStreamBoundaries,Gp as extractState,yi as extractSlotContent,$f as extractScriptFromTemplate,ni as extractScriptBlocks,vc as extractPlaceholders,vd as extractParenthesizedExpression,id as extractPageResponseStatus,hb as extractLayoutMetadata,yj as extractDominantColor,Ed as extractDirectiveParams,ti as extractDirectiveNames,Wm as extractContainerContent,co as extractComponentProps,Xh as extractComponentName,eo as extractComponentDescription,Xc as extractClassNames,pc as extractBridgeData,Yh as extractBoundProps,td as extractBalancedExpression,hc as extractAndStripCssImports,sk as extractAndScopeStyles,Ob as extractAndProcessEvents,Wk as externalizeSharedAssets,Xk as externalizeRepeatedAssets,Vk as externalizeHtml,Pc as evaluateExpression,Bn as evaluateConstant,qd as evaluateAuthExpression,Gc as escapeHtmlValue,Fc as escapeHtml,C as errorRecovery,E as errorLogger,rh as ensureTeleportTargets,ih as ensureDocumentShell,Ae as enhancedValidationRules,ao as enableDevTools,An as eliminateDeadCode,ff as effect,tq as dprUrls,oo as docsCommand,ec as discoverServerApi,_m as discoverLayoutNames,Xq as disconnectObserver,bo as disableDevTools,F as devHelpers,Rm as detectShell,po as detectRuntime,nl as detectProjectConfig,rj as detectFormat,un as detectBuildMode,ef as derived,rl as deploy,Gk as defineStxConfig,Tp as defineStore,Bf as defineSlots,cs as defineSiteConfig,gs as definePropsWithValidation,fs as defineProps,Ak as definePlugin,ie as definePageMeta,Wa as defineMiddleware,ii as defineForm,wf as defineExpose,vf as defineEmits,Wi as defineDirective,Gr as defineCustomElement,So as defineConfig,Xi as defineClientDirective,Eh as defineAsyncComponent,Uo as defineApiHandler,or as defaultMediaConfig,Vl as defaultImageConfig,M as defaultI18nConfig,ib as defaultHeatmapConfig,re as defaultFormClasses,yc as defaultFilters,_d as defaultCspConfig,Ck as defaultConfig,qs as default,Rc as deepMergeThemes,Uc as dedupeScopedStyles,Nm as decodeTitleEntities,wj as decodeThumbhash,eg as declareBareLoopHead,Vd as cspNonceDirective,Ud as cspDirective,cr as crossfadeTransition,Zp as crop,Ph as createVirtualList,lk as createVideoDirective,Bo as createVercelHandler,gp as createTypeChecker,fa as createTranslateFilter,xo as createTextEncoderStream,Fr as createStxApp,wo as createStreamingResponse,We as createStreamRenderer,Rp as createStore,Za as createStorageManager,Xa as createServerCookieManager,gc as createServerApi,Zl as createScope,zh as createSSRSuspense,bf as createRouter,Ym as createRouteRuleResolver,eb as createRouteLocation,ep as createRoute,_l as createRef,$l as createReactive,Df as createProvideContext,Xo as createProject,Ro as createProductionBuild,tc as createPlaceholder,Gn as createOptimizedBuild,Co as createNetlifyHandler,fl as createNetlifyClient,fb as createMiddlewareContext,dp as createMiddleware,Vq as createLazyObserver,Jh as createKeepAliveCache,to as createKVNamespace,Zh as createIslandRegistry,Yj as createImgDirective,Ql as createImagePlugin,Jl as createImageHandler,Ol as createImageDirective,nb as createHeatmapAggregator,il as createFileManifest,so as createEnvAccessor,z as createEnhancedError,vo as createEdgeHandler,uo as createEdgeCache,Ni as createDetailedErrorMessage,Ao as createDenoHandler,ol as createDefaultNetlifyConfig,Zd as createCspHeaders,Eo as createCookie,am as createComputed,Yl as createComponentInstance,zo as createCloudflareHandler,Ya as createClientCookieManager,Yi as createBuiltinDirectives,Fr as createApp,Ka as createAnimationTimeline,aq as cover,_f as convertToCommonJS,hq as contrast,$p as contain,y as consoleError,m as configureErrorHandling,Fk as config,am as computed,$n as compressResponse,Bg as composerPattern,Ag as composer,Tm as composeShellWithPage,Vn as componentDirective,Ii as componentClientSignalNames,fn as compileTemplate,a as collectRepeatedFlag,hl as collectDeployFiles,ch as cloakStyleFragment,Ic as clientLoopScopes,bk as clearVideoCache,N as clearTranslationCache,nh as clearStoreCache,$k as clearStorage,Gq as clearSignatureCache,Gf as clearServerData,Dj as clearPlaceholderCache,tg as clearOnceStore,Id as clearNonce,bb as clearMiddleware,Ke as clearImagePlaceholders,Ge as clearImageDeliveryCatalog,Nl as clearImageCache,e as clearErrorMessages,Tf as clearDevCaches,Cc as clearCustomFilters,Dg as clearComposers,oh as clearComposableCache,Oi as clearComponentCache,Mj as clearCache,Ib as clearBlankCache,vp as cleanupLoadingIndicator,Hm as classifyScript,Im as classifyAllScripts,hp as checkTemplateFile,ip as checkTemplate,Uf as checkCache,Dq as checkAuthAccess,na as checkA11yWithRegex,oa as checkA11y,Qn as channel,Jo as captureScreenshots,Io as captureScreenshot,Z as cancelPendingLoads,gl as calculateSha1,fj as calculateOptimalWidths,Vf as cacheTemplate,bc as cacheEngineFingerprint,nk as buildWebComponents,kp as buildVirtualSource,qr as buildViews,Vp as buildUrl,Qe as buildSuspenseResolveScript,bs as buildStaticSite,qb as buildRuntimeGlobalsDestructure,cn as buildRuntimeAsset,dn as buildRouterAsset,as as buildLangPickerScript,lj as buildImageUrl,Sg as buildIdFragment,_g as buildHtmlAttrs,sn as buildForProduction,Yn as buildComponentLibrary,Eq as buildAuthParams,tn as buildApp,_r as buildAlternateLinks,Qo as build,On as broadcastPrivate,Pn as broadcastPresence,Ln as broadcast,gq as brightness,Tb as bracketDepths,bq as blur,Jb as blankInertHtmlRegions,yq as batchSignUrls,gf as batch,sa as autoFixA11yFile,ta as autoFixA11yDirectory,ra as autoFixA11y,oq as auto,ja as attributeValue,en as assetTags,Mb as asInvocableStatement,ns as arrayOf,Xr as applyTranslations,Sj as applyTransformations,zi as applySlots,Un as applyPropDefaults,rq as applyPreset,ah as applyHtmlAttrs,ne as applyHead,Nc as applyFilters,Pm as appendVary,Od as apiCspPreset,Da as animationGroupDirective,hk as analyzeVideo,wn as analyzeUsage,Fm as analyzeTemplate,Gm as analyzeProject,wn as analyzeDirectiveUsage,ed as analyticsDirective,_o as addStore,Zo as addPage,Sd as addNonceToInlineContent,$o as addLayout,Yo as addComponent,on as actionRedirectResponse,Va as abortNavigation,ua as a11yDirective,Nf as __setSignalsGeneratorsForTest,Qg as __setBuildIdForTest,_j as VideoProcessorCache,ji as Validator,xa as TransitionType,za as TransitionEase,ya as TransitionDirection,rd as Tokenizer,fp as TemplateTypeChecker,Mo as TEMPLATE_PRESETS,v as StxValidationError,r as StxSyntaxError,t as StxSecurityError,s as StxRuntimeError,u as StxFileError,q as StxError,Br as Show,Re as SUSPENSE_RESOLVER_RUNTIME,ob as STX_RUNTIME_GLOBALS,jc as STX_AUTO_IMPORTS,Yb as STATE_DIR_ENV_VAR,Ga as SPRING_PRESETS,Lm as SPA_NAV_HEADER,Kb as SCROLL_BLOCKING_EVENTS,xb as RUNTIME_OWNED_COLON_ATTRS,zb as RUNTIME_HANDLED_X_ATTRS,Fb as RUNTIME_EVENT_NAMES,Db as RUNTIME_DIRECTIVE_NAMES,fd as RESPONSE_STATUS_KEY,gd as RESPONSE_HEADERS_KEY,tb as REACTIVE_RUNTIME_GLOBALS,Po as ProductionBuild,Dr as Portal,Wo as PROJECT_TEMPLATES,qq as PRESETS,Tg as OFFLINE_WORKER_PATH,Ug as OFFLINE_REGISTER_SCRIPT,sb as NON_CLIENT_PRIMITIVES,Mp as MemorySessionStore,cj as MIME_TYPES,$i as MEDIA_DEFAULT_WIDTHS,bj as MEDIA_DEFAULT_FORMATS,Zm as LAYOUT_TYPES_FILE,cl as KEPT_STATE_PREFIX,Pj as ImageProcessorCache,Hl as ImageProcessingError,Hp as HydrationRuntime,Mk as HotReloadServer,mb as HeatmapAggregator,Yg as HTML_CLASS_MARKER,Xg as HTML_ATTRS_MARKER,ur as Fragment,Cr as For,Mm as FRAGMENT_CACHE_CONTROL,D as ErrorLogger,h as ErrorCodes,Uk as EXTERNALIZED_ASSET_DIR,tl as DeployError,ul as DEFAULT_WIDTHS,Aa as DEFAULT_TRANSITION_OPTIONS,Xb as DEFAULT_STATE_DIR,wl as DEFAULT_QUALITY,sj as DEFAULT_PLACEHOLDER_OPTIONS,vl as DEFAULT_FORMATS,aj as DEFAULT_DPR_VALUES,yp as ComponentHMRHandler,pb as COMPONENT_SCOPE_LOCAL_GLOBALS,Bb as COMPONENT_PASSTHROUGH_X_ATTRS,rb as COMPILE_TIME_ONLY_GLOBALS,kj as COMMON_SIZES,Hg as COLOR_MODE_BOOT_MARKER,Ig as COLOR_MODE_BOOT_GLOBAL,Wg as CLOAK_STYLE,Sn as BroadcastServer,Rn as Broadcast,Ng as BUILD_ID_META,Og as BUILD_ID_HEADER,Ub as BROWSER_CORE_IMPORTS,tj as BLUR_UP_CSS,Ab as ALPINE_BRIDGE_X_ATTRS,Nr as $path};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
2
  import{createHash as n}from"crypto";import x from"fs";import K from"path";import{decode as $Q,generateThumbHash as JQ}from"ts-images";import{createImageDeliveryCatalog as f}from"ts-images/delivery";import R from"fs";function T(Q,$,Z){let M=Buffer.alloc(Z),J=R.readSync(Q,M,0,Z,$);return M.subarray(0,J)}function P(Q){if(Q.length<25)return!1;let $=(M,J)=>String.fromCharCode(...Q.subarray(M,J));if($(0,4)!=="RIFF"||$(8,12)!=="WEBP")return!1;let Z=$(12,16);if(Z==="VP8X")return(Q[20]&16)!==0;if(Z==="VP8L")return((Q[21]|Q[22]<<8|Q[23]<<16|Q[24]<<24)>>>28&1)===1;return!1}function m(Q){let $;try{$=R.openSync(Q,"r");let Z=T($,0,33);if(Z.length>=3&&Z[0]===255&&Z[1]===216&&Z[2]===255)return"none";if(Z.length>=26&&Z[0]===137&&Z.toString("latin1",1,4)==="PNG"){let M=Z[25];if(M===4||M===6)return"possible";let J=8;for(let X=0;X<64;X++){let G=T($,J,8);if(G.length<8)return"unknown";let Y=G.toString("latin1",4,8);if(Y==="tRNS")return"possible";if(Y==="IDAT"||Y==="IEND")return"none";J+=12+G.readUInt32BE(0)}return"unknown"}if(Z.length>=25&&Z.toString("latin1",0,4)==="RIFF"&&Z.toString("latin1",8,12)==="WEBP"){if(P(Z))return"possible";let M=Z.toString("latin1",12,16);return M==="VP8 "||M==="VP8X"?"none":"unknown"}return"unknown"}catch{return"unknown"}finally{if($!==void 0)R.closeSync($)}}import i from"fs";import O from"os";import{join as k}from"path";import{fileURLToPath as b}from"url";import{Worker as v}from"worker_threads";var I=Symbol("stx.image-worker.unavailable");function t(Q=typeof O.availableParallelism==="function"?O.availableParallelism():O.cpus().length){return Math.max(1,Math.min(2,Q-1))}var C=0,y=[];async function a(){if(C<t()){C++;return}await new Promise((Q)=>y.push(Q)),C++}function r(){C--,y.shift()?.()}var e="@stacksjs/stx/builtins/image-warmup-worker";function QQ(Q=process.cwd()){let $=import.meta.url.endsWith(".ts")?"ts":"js";try{let Z=new URL(`./image-warmup-worker.${$}`,import.meta.url);if(Z.protocol==="file:"&&i.existsSync(b(Z)))return b(Z)}catch{}try{let Z=typeof Bun<"u"?Bun.resolveSync(e,Q):void 0;return Z&&ZQ(Z)?Z:void 0}catch{return}}function ZQ(Q,$=process.env){let Z=Q.replace(/\\/g,"/");if(Z.split("/").some((J)=>/@\d[^/]*@@@\d+$/.test(J)))return!1;return![$.BUN_INSTALL_CACHE_DIR,k($.BUN_INSTALL||k(O.homedir(),".bun"),"install","cache")].filter((J)=>!!J).map((J)=>`${J.replace(/\\/g,"/").replace(/\/$/,"")}/`).some((J)=>Z.startsWith(J))}var g=!1;function N(Q){if(!g)g=!0,console.warn(`[stx] image worker unavailable (${Q}); running the image pass on the serving thread instead. Results are the same, but requests may stall while it runs.`);return I}function A(Q){return Q instanceof Error?Q.message:String(Q)}async function u(Q,$){if(typeof v!=="function")return N("node:worker_threads has no Worker in this runtime");let Z=QQ();if(!Z)return N("no image-warmup-worker entry beside this module or in the installed @stacksjs/stx");await a();try{return await new Promise((M,J)=>{let X;try{X=new v(Z)}catch(B){M(N(`could not start ${Z}: ${A(B)}`));return}let G=!1,Y=!1,q=(B)=>{if(Y)return;Y=!0,B(),X.terminate()};X.on("message",(B)=>{if(B.type==="ready"){G=!0,X.postMessage({task:Q,args:$});return}if(B.type==="result"){q(()=>M(B.value));return}let j=Error(B.error?.message??"image worker failed");if(B.error?.name)j.name=B.error.name;if(B.error?.stack)j.stack=B.error.stack;q(()=>J(j))}),X.on("error",(B)=>{q(()=>G?J(B instanceof Error?B:Error(A(B)||"image worker crashed")):M(N(`the worker failed before it was ready: ${A(B)}`)))}),X.on("exit",(B)=>{q(()=>G?J(Error("image worker exited before it finished")):M(N(`the worker exited with code ${B} before it was ready`)))})})}finally{r()}}var MQ=new Set([".avif",".jpeg",".jpg",".png",".webp"]),XQ=[320,640,960,1280,1920],L="/_stx/images",BQ=`stx:${L}:alpha-1`,GQ=["@stacksjs/ts-webp","@stacksjs/ts-avif"],W;function qQ(Q,$){let Z=K.dirname(Bun.resolveSync(Q,$));while(Z!==K.dirname(Z)){let M=K.join(Z,"package.json");if(x.existsSync(M)){let J=JSON.parse(x.readFileSync(M,"utf8"));if(J.name===Q)return J.version}Z=K.dirname(Z)}return}function bQ(Q){W=Q}function KQ(){if(W!==void 0)return W;let Q;try{Q=K.dirname(Bun.resolveSync("ts-images",import.meta.dir))}catch{}return W=GQ.map(($)=>{let Z;try{Z=Q?qQ($,Q):void 0}catch{}return`${$.replace("@stacksjs/","")}@${Z??"unknown"}`}).join("+"),W}var U=new Map,_=new Set,c=new Set;function YQ(Q){return`/${Q.split(K.sep).map(encodeURIComponent).join("/")}`}function xQ(Q){let $=K.extname(Q),Z=Q.slice(0,-$.length).replace(/[^a-zA-Z0-9_-]+/g,"-").replace(/^-+|-+$/g,""),M=n("sha256").update(Q).digest("hex").slice(0,8);return`${Z||"image"}-${M}`}function h(Q,$=`stx:${L}`){let Z=(M)=>`${L}/${M.split("/").map(encodeURIComponent).join("/")}`;return{cacheNamespace:$,async stat(M){let J=K.join(Q,M);try{let X=await x.promises.stat(J);return X.size>0?{bytes:X.size,path:J,url:Z(M)}:null}catch{return null}},async write(M,J){let X=K.join(Q,M);await x.promises.mkdir(K.dirname(X),{recursive:!0});let G=`${X}.${process.pid}.tmp`;return await x.promises.writeFile(G,J),await x.promises.rename(G,X),{bytes:J.byteLength,path:X,url:Z(M)}},url:Z}}async function l(Q,$=Q){let Z=await x.promises.readdir($,{withFileTypes:!0});Z.sort((J,X)=>J.name.localeCompare(X.name));let M=[];for(let J of Z){let X=K.join($,J.name);if(J.isDirectory()){M.push(...await l(Q,X));continue}if(!J.isFile()||!MQ.has(K.extname(J.name).toLowerCase()))continue;M.push({absolutePath:X,relativePath:K.relative(Q,X)})}return M}function p(Q,$){return Q.map((Z)=>({key:YQ(Z.relativePath),input:Z.absolutePath,name:xQ(Z.relativePath),...jQ(Z.absolutePath)?{options:{storage:$}}:{}}))}function jQ(Q){return m(Q)==="possible"}function zQ(Q){for(let $=3;$<Q.length;$+=4)if(Q[$]!==255)return!0;return!1}async function FQ(Q){let $=Object.entries(Q).filter(([,J])=>J.fallback.format==="png"),Z=new Set,M=8;for(let J=0;J<$.length;J+=8)await Promise.all($.slice(J,J+8).map(async([X,G])=>{let Y=G.variants.filter((q)=>q.format==="png").sort((q,B)=>q.width-B.width)[0];try{let q=await $Q(new Uint8Array(await x.promises.readFile(Y?.path??G.fallback.path)));if(zQ(q.data))Z.add(X)}catch{Z.add(X)}}));return Z}function VQ(Q,$){let Z=[];for(let M of $){let J=Q[M],X=J?.variants.filter((Y)=>Y.format==="webp")??[];if(!J||X.length===0)continue;if(!X.some((Y)=>{let q;try{return q=x.openSync(Y.path,"r"),!P(T(q,0,32))}catch{return!0}finally{if(q!==void 0)x.closeSync(q)}}))continue;if(J.variants=J.variants.filter((Y)=>Y.format!=="webp"),delete J.sources.webp,Z.push(M),!c.has(M))c.add(M),console.warn(`[stx-images] ${M} is transparent but its WebP variants have no alpha channel; serving PNG instead. Upgrade @stacksjs/ts-webp to 0.1.6 or later.`)}return Z}async function HQ(Q){let $=[],Z=8;for(let M=0;M<Q.length;M+=8){let J=Q.slice(M,M+8),X=await Promise.all(J.map(async(G)=>{try{return await JQ(G.absolutePath),G}catch{return console.warn(`[stx-images] Skipping unreadable raster: ${G.relativePath}`),null}}));$.push(...X.filter((G)=>G!==null))}return $}function E(Q){return K.join(Q,"undecodable.json")}function NQ(Q){try{let $=x.readFileSync(E(Q),"utf-8"),Z=JSON.parse($);return Z&&typeof Z==="object"?Z:{}}catch{return{}}}function OQ(Q,$){try{x.mkdirSync(K.dirname(E(Q)),{recursive:!0}),x.writeFileSync(E(Q),JSON.stringify($))}catch{}}function d(Q){try{let $=x.statSync(Q);return{mtimeMs:$.mtimeMs,size:$.size}}catch{return}}function o(Q){if(!Q||Q.startsWith("data:")||Q.startsWith("blob:")||/^https?:\/\//i.test(Q)||Q.startsWith("//"))return;let $=Q.split(/[?#]/,1)[0];if(!$)return;try{return`/${$.replace(/^\/+/,"").split("/").map(decodeURIComponent).map(encodeURIComponent).join("/")}`}catch{return}}function vQ(Q){let $=o(Q);return $?U.get($):void 0}function gQ(Q){let $=o(Q);return $?_.has($):!1}function S(){U=new Map,_=new Set}function yQ(){return{entries:[...U],transparent:[..._]}}function WQ(Q){U=new Map(Q.entries),_=new Set(Q.transparent)}async function uQ(Q,$,Z={}){if(!Q||!x.existsSync(Q))return S(),{count:0,fingerprint:""};if(Z.offThread){let z=await u("delivery",{publicDir:Q,outputDir:$});if(z!==I)return WQ(z.state),z.result}let M=await l(Q);if(M.length===0)return S(),{count:0,fingerprint:""};let J=NQ($),X=M.filter((z)=>{let V=J[z.relativePath];if(!V)return!0;let F=d(z.absolutePath);return!F||F.mtimeMs!==V.mtimeMs||F.size!==V.size});if(X.length===0)return S(),{count:0,fingerprint:""};let G=h(K.join($,"_stx","images"),`${BQ}:${KQ()}`),Y={outDir:K.join($,"_stx","images"),storage:h(K.join($,"_stx","images")),baseUrl:L,widths:XQ,formats:["avif","webp"],quality:{avif:70,webp:78,jpeg:82,png:100},includeOriginal:!1,placeholder:!0,batchConcurrency:4,concurrency:4},q=X,B;try{B=await f({...Y,entries:p(X,G)})}catch(z){if(q=await HQ(X),q.length===X.length)throw z;let V=new Set(q.map((H)=>H.relativePath)),F=!1;for(let H of X){if(V.has(H.relativePath))continue;let D=d(H.absolutePath);if(!D)continue;J[H.relativePath]=D,F=!0}if(F)OQ($,J);if(q.length===0)return S(),{count:0,fingerprint:""};B=await f({...Y,entries:p(q,G)})}let j=await FQ(B.entries),w=VQ(B.entries,j);U=new Map(Object.entries(B.entries)),_=j;let s=j.size===0&&w.length===0?B.fingerprint:n("sha256").update(B.fingerprint).update(JSON.stringify({transparent:[...j].sort(),droppedWebp:w.sort()})).digest("hex");return{count:q.length,fingerprint:s}}
3
- export{P as Ct,m as Dt,I as Et,u as Ft,bQ as Gt,KQ as Ht,vQ as It,gQ as Jt,S as Kt,yQ as Lt,WQ as Mt,uQ as Nt};
3
+ export{P as Dt,m as Et,I as Ft,u as Gt,bQ as Ht,KQ as It,vQ as Jt,gQ as Kt,S as Lt,yQ as Mt,WQ as Nt,uQ as Ot};
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import"./chunk-rxz43r6k.js";var Z=0;function $(){return`eb-${++Z}-${Date.now().toString(36)}`}var U=/<!--stx-render-failed:([a-z-]+)-->/g;function w(q){return q.replace(U,"")}function O(q,z={},J){let j=/@errorBoundary(?:\s*\(([^)]*)\))?\s*([\s\S]*?)@fallback\s*([\s\S]*?)@enderrorBoundary/gi;return q.replace(j,(Q,P,T,W)=>{let X=$(),Y=C(P||"");return G(X,T.trim(),W.trim(),Y)})}function C(q){let z={},J=/(\w+)\s*:\s*(?:'([^']*)'|"([^"]*)"|(\w+))/g,j;while((j=J.exec(q))!==null){let Q=j[1],P=j[2]||j[3]||j[4];switch(Q){case"id":z.id=P;break;case"logErrors":z.logErrors=P==="true";break}}return z}function G(q,z,J,j){let Q=j.logErrors!==!1,P=U.test(z);U.lastIndex=0;let T=P?` <div class="stx-error-boundary-fallback" data-boundary-fallback="${q}">
2
+ import"./chunk-cevkpyn9.js";var Z=0;function $(){return`eb-${++Z}-${Date.now().toString(36)}`}var U=/<!--stx-render-failed:([a-z-]+)-->/g;function w(q){return q.replace(U,"")}function O(q,z={},J){let j=/@errorBoundary(?:\s*\(([^)]*)\))?\s*([\s\S]*?)@fallback\s*([\s\S]*?)@enderrorBoundary/gi;return q.replace(j,(Q,P,T,W)=>{let X=$(),Y=C(P||"");return G(X,T.trim(),W.trim(),Y)})}function C(q){let z={},J=/(\w+)\s*:\s*(?:'([^']*)'|"([^"]*)"|(\w+))/g,j;while((j=J.exec(q))!==null){let Q=j[1],P=j[2]||j[3]||j[4];switch(Q){case"id":z.id=P;break;case"logErrors":z.logErrors=P==="true";break}}return z}function G(q,z,J,j){let Q=j.logErrors!==!1,P=U.test(z);U.lastIndex=0;let T=P?` <div class="stx-error-boundary-fallback" data-boundary-fallback="${q}">
3
3
  ${J}
4
4
  </div>`:` <div class="stx-error-boundary-content" data-boundary-content="${q}">
5
5
  ${w(z)}
@@ -299,4 +299,4 @@ catch (error) {
299
299
  }
300
300
  })();
301
301
  </script>`}var N={name:"pwa.installButton",handler:(j,z,k,E)=>{let q=k.__stx_options||{};return H(j,q)},hasEndTag:!0,description:"Renders a PWA install prompt button that appears when the app can be installed"},Q={name:"pwa.updatePrompt",handler:(j,z,k,E)=>{let q=k.__stx_options||{};return J(j,q)},hasEndTag:!0,description:"Renders a PWA update notification UI when a new version is available"},T={name:"pwa.offlineIndicator",handler:(j,z,k,E)=>{let q=k.__stx_options||{};return L(j,q)},hasEndTag:!0,description:"Renders an offline status indicator that shows when the user loses connection"},V={name:"pwa.pushSubscribe",handler:(j,z,k,E)=>{let q=k.__stx_options||{};return M(j,q)},hasEndTag:!0,description:"Renders a push notification subscription button"},X=[N,Q,T,V];function Z(j){return[...j,...X]}
302
- export{N as Ow,Q as Pw,T as Qw,V as Rw,X as Sw,Z as Tw};
302
+ export{N as Pw,Q as Qw,T as Rw,V as Sw,X as Tw,Z as Uw};
@@ -0,0 +1,2 @@
1
+ // @bun
2
+ import{Dv as a,Ev as b}from"./chunk-nn42gs3q.js";import"./chunk-cevkpyn9.js";export{b as warnUnbalancedTags,a as findUnbalancedTags};
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import{a as N,c as R,e as W,g as j,i as H,k as J}from"./chunk-0y46fbkx.js";import{l as k,m as w,n as B}from"./chunk-q9n5swx7.js";import"./chunk-rxz43r6k.js";import E from"fs";import K from"path";var V=[];function _(U){V=[];for(let A of U.storyFiles)if(V.push({text:A.fileName.toLowerCase(),original:A.fileName,type:"story",storyId:A.id}),V.push({text:A.relativePath.toLowerCase(),original:A.relativePath,type:"story",storyId:A.id}),A.story)for(let z of A.story.variants)V.push({text:z.title.toLowerCase(),original:z.title,type:"story",storyId:A.id,variantId:z.id})}function $(){return JSON.stringify(V)}async function O(U={}){let A=Date.now();N();let z=await k({mode:"build"});if(!z.config.enabled){W("Story feature is disabled in config.");return}let P=await H(z);w(z,P);let Y=J(z.config,P);B(z,Y),R(P.length);let X=U.outDir??z.config.outDir,Q=K.resolve(z.root,X);await E.promises.mkdir(Q,{recursive:!0}),console.log(` Building to ${X}...`);let M=F(z);await E.promises.writeFile(K.join(Q,"index.html"),M);let v={files:P.map((G)=>({id:G.id,fileName:G.fileName,relativePath:G.relativePath,treePath:G.treePath})),tree:Y};await E.promises.writeFile(K.join(Q,"stories.json"),JSON.stringify(v,null,2));let L={theme:z.config.theme,responsivePresets:z.config.responsivePresets,backgroundPresets:z.config.backgroundPresets};await E.promises.writeFile(K.join(Q,"config.json"),JSON.stringify(L,null,2));let Z=K.join(Q,"stories");await E.promises.mkdir(Z,{recursive:!0});for(let G of P){let g=await E.promises.readFile(G.path,"utf-8");await E.promises.writeFile(K.join(Z,`${G.id}.stx`),g)}_(z);let T=$();await E.promises.writeFile(K.join(Q,"search-index.json"),T);let C=Date.now()-A;j(P.length,X,C)}function F(U){let{theme:A}=U.config,z=A.title||"STX Story";return`<!DOCTYPE html>
2
+ import{a as N,c as R,e as W,g as j,i as H,k as J}from"./chunk-0y46fbkx.js";import{l as k,m as w,n as B}from"./chunk-q9n5swx7.js";import"./chunk-cevkpyn9.js";import E from"fs";import K from"path";var V=[];function _(U){V=[];for(let A of U.storyFiles)if(V.push({text:A.fileName.toLowerCase(),original:A.fileName,type:"story",storyId:A.id}),V.push({text:A.relativePath.toLowerCase(),original:A.relativePath,type:"story",storyId:A.id}),A.story)for(let z of A.story.variants)V.push({text:z.title.toLowerCase(),original:z.title,type:"story",storyId:A.id,variantId:z.id})}function $(){return JSON.stringify(V)}async function O(U={}){let A=Date.now();N();let z=await k({mode:"build"});if(!z.config.enabled){W("Story feature is disabled in config.");return}let P=await H(z);w(z,P);let Y=J(z.config,P);B(z,Y),R(P.length);let X=U.outDir??z.config.outDir,Q=K.resolve(z.root,X);await E.promises.mkdir(Q,{recursive:!0}),console.log(` Building to ${X}...`);let M=F(z);await E.promises.writeFile(K.join(Q,"index.html"),M);let v={files:P.map((G)=>({id:G.id,fileName:G.fileName,relativePath:G.relativePath,treePath:G.treePath})),tree:Y};await E.promises.writeFile(K.join(Q,"stories.json"),JSON.stringify(v,null,2));let L={theme:z.config.theme,responsivePresets:z.config.responsivePresets,backgroundPresets:z.config.backgroundPresets};await E.promises.writeFile(K.join(Q,"config.json"),JSON.stringify(L,null,2));let Z=K.join(Q,"stories");await E.promises.mkdir(Z,{recursive:!0});for(let G of P){let g=await E.promises.readFile(G.path,"utf-8");await E.promises.writeFile(K.join(Z,`${G.id}.stx`),g)}_(z);let T=$();await E.promises.writeFile(K.join(Q,"search-index.json"),T);let C=Date.now()-A;j(P.length,X,C)}function F(U){let{theme:A}=U.config,z=A.title||"STX Story";return`<!DOCTYPE html>
3
3
  <html lang="en">
4
4
  <head>
5
5
  <meta charset="UTF-8">
@@ -1,2 +1,2 @@
1
1
  // @bun
2
- import{Jk as a,Kk as b,Lk as c,Mk as d,Nk as e}from"./chunk-fj6fbqgb.js";import"./chunk-rxz43r6k.js";export{d as runPwaAudit,e as formatAuditResult,c as calculateAuditResult,a as auditConfig,b as auditBuildOutput};
2
+ import{Jk as a,Kk as b,Lk as c,Mk as d,Nk as e}from"./chunk-fj6fbqgb.js";import"./chunk-cevkpyn9.js";export{d as runPwaAudit,e as formatAuditResult,c as calculateAuditResult,a as auditConfig,b as auditBuildOutput};
@@ -0,0 +1,2 @@
1
+ // @bun
2
+ import{Li as a,Mi as b}from"./chunk-j89wctm5.js";import"./chunk-452k8psm.js";import"./chunk-14rh4kd0.js";import"./chunk-etah20m0.js";import"./chunk-2andsajh.js";import"./chunk-ptad3t7a.js";import"./chunk-y9f9g2kh.js";import"./chunk-ah8gs0q2.js";import"./chunk-saf4xhac.js";import"./chunk-wheh08v2.js";import"./chunk-jct6cs2k.js";import"./chunk-ndydf37f.js";import"./chunk-7vftjm43.js";import"./chunk-4azk3jdd.js";import"./chunk-jbtzq3xt.js";import"./chunk-mjearf0g.js";import"./chunk-9rp8f7jz.js";import"./chunk-8ghwewek.js";import"./chunk-rk8p4b1z.js";import"./chunk-fpxz25xz.js";import"./chunk-nn42gs3q.js";import"./chunk-v54tq312.js";import"./chunk-qbc0bebg.js";import"./chunk-4yc9gx6h.js";import"./chunk-d6rkgay9.js";import"./chunk-cevkpyn9.js";export{a as getStoreScript,b as clearStoreCache};
@@ -0,0 +1,2 @@
1
+ // @bun
2
+ import{Er as a,Fr as b,Gr as c,Hr as d,Ir as e,Jr as f}from"./chunk-ptad3t7a.js";import"./chunk-y9f9g2kh.js";import"./chunk-ah8gs0q2.js";import"./chunk-saf4xhac.js";import"./chunk-wheh08v2.js";import"./chunk-jct6cs2k.js";import"./chunk-ndydf37f.js";import"./chunk-7vftjm43.js";import"./chunk-4azk3jdd.js";import"./chunk-jbtzq3xt.js";import"./chunk-mjearf0g.js";import"./chunk-9rp8f7jz.js";import"./chunk-8ghwewek.js";import"./chunk-rk8p4b1z.js";import"./chunk-fpxz25xz.js";import"./chunk-nn42gs3q.js";import"./chunk-v54tq312.js";import"./chunk-qbc0bebg.js";import"./chunk-4yc9gx6h.js";import"./chunk-d6rkgay9.js";import"./chunk-cevkpyn9.js";export{f as validateConfig,b as resolveStxDirectories,c as loadStxConfig,e as defineStxConfig,a as defaultConfig,d as config};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
2
  import C from"path";var G=".stx",K="STX_DIR",J=null;function O(j){J=j?.trim()||null}function H(){return process.env[K]?.trim()||J||G}function Q(j=process.cwd(),...q){let B=H();return C.isAbsolute(B)?C.join(B,...q):C.join(j,B,...q)}function W(j){if(!j||C.isAbsolute(j))return j;let q=j.replace(/\\/g,"/");if(q!==G&&!q.startsWith(`${G}/`))return j;let B=q.slice(G.length+1);return B?C.join(H(),B):H()}
3
- export{G as wt,K as xt,O as yt,H as zt,Q as At,W as Bt};
3
+ export{G as xt,K as yt,O as zt,H as At,Q as Bt,W as Ct};
@@ -1,4 +1,4 @@
1
1
  // @bun
2
- import{mg as e,og as kF,pg as UF,qg as wF,yg as EF}from"./chunk-nm7jfzmz.js";import{Bg as BF}from"./chunk-g64qyhhb.js";import{rj as l,sj as d}from"./chunk-q4v62yed.js";import{Gk as HF,Hk as IF,Ik as KF}from"./chunk-7eea1cse.js";import{ql as YF,sl as ZF}from"./chunk-h7sgg3vh.js";import{$m as s,Dr as t,Fr as M,Hp as GF,Pp as VF,Tp as r,Yp as o,no as zF,pp as $F,rm as p,tm as i}from"./chunk-zstrcmbj.js";import{Fs as XF}from"./chunk-ekvejzvk.js";import{vt as qF}from"./chunk-7c8r36ve.js";import{Pt as WF}from"./chunk-twws9vvz.js";import{Ut as QF}from"./chunk-g7qmxjyc.js";import{Kw as h,Nw as _F}from"./chunk-d0qy1ezf.js";import G from"fs";import q from"path";import{createHash as NF}from"crypto";_F();function u(Q){return NF("sha256").update(Q).digest("hex").slice(0,8)}function c(Q=!1){let z=Q?d():l(),Z=u(z);return{content:z,filename:`runtime.${Z}.js`,hash:Z}}function a(){let Q=h(),z=u(Q);return{content:Q,filename:`router.${z}.js`,hash:z}}function bF(Q){return{runtimeTag:Q.runtime?`<script src="/__stx/${Q.runtime.filename}"></script>`:"",routerTag:Q.router?`<script src="/__stx/${Q.router.filename}"></script>`:"",cssTag:Q.css?`<link rel="stylesheet" href="/__stx/${Q.css.filename}">`:""}}import n from"path";import{createHash as OF}from"crypto";function TF(Q={}){let z=new Set;return{context:new Proxy(Q,{get(X,F){if(F in X)return X[F];if(typeof F==="string"&&!F.startsWith("__"))z.add(F);return},has(X,F){if(F in X)return!0;if(typeof F==="string"&&!F.startsWith("__"))z.add(F);return!1}}),accessedKeys:z}}async function FF(Q,z,Z={}){let X=n.resolve(Q),F=await Bun.file(X).text(),U=OF("sha256").update(F).digest("hex").slice(0,16);p();let w={};try{w=await M(Z.configDir)}catch{}let H=[],V=/<script\b([^>]*)>([\s\S]*?)<\/script>/gi,k;while((k=V.exec(F))!==null){let E=k[1];if(/\bserver\b/.test(E))H.push(k[2])}let W=new Set(H.flatMap((E)=>o(E))),{context:_}=TF({__filename:X,__dirname:n.dirname(X),__stx_serverDeclared:W}),N=new Set,x={...t,...w,...Z,buildMode:"compile",strict:!1},I=await r(F,_,X,x,N),O=e(I),j=i();return{route:z,sourceFile:Q,html:I,fragment:O,placeholders:j,hasServerScripts:H.length>0,serverScriptContent:H,dependencies:Array.from(N),contentHash:U,status:s(F),streamTemplates:_.__streamTemplates}}var MF=new Set([".DS_Store","Thumbs.db","desktop.ini",".gitkeep",".gitignore"]);function JF(Q,z){let Z=0,X=0;if(!G.existsSync(Q))return{copied:Z,bytes:X};G.mkdirSync(z,{recursive:!0});function F(U,w){let H=G.readdirSync(U,{withFileTypes:!0});for(let V of H){if(MF.has(V.name))continue;let k=q.join(U,V.name),W=q.join(w,V.name);if(V.isDirectory())G.mkdirSync(W,{recursive:!0}),F(k,W);else if(V.isFile()){if(G.existsSync(W))continue;G.copyFileSync(k,W),Z++,X+=G.statSync(W).size}}}return F(Q,z),{copied:Z,bytes:X}}async function qJ(Q={}){let z=Date.now(),Z=q.resolve(Q.root||process.cwd()),X=q.resolve(Z,Q.outputDir||".output");console.log("[stx build] Starting production build...");let F=await M(Z),U=q.resolve(Z,Q.componentsDir??F.componentsDir??"components"),w=q.resolve(Z,Q.partialsDir??F.partialsDir??"partials"),H=q.resolve(Z,Q.layoutsDir??F.layoutsDir??"layouts"),V=Q.publicDir??F.publicDir??"public",k=F.app?.head||{},W=F.app?.colorMode,_=F.router?.container||"main",N=Q.routeRules??F.routeRules??{},x=BF(N),I=Q.serverApi??F.serverApi,O=typeof I==="object"?I:{};if(I)YF(Z,O);if(F.runtimeConfig)QF(F.runtimeConfig,{});if(G.existsSync(X))G.rmSync(X,{recursive:!0});let j=[q.join(X,"public","__stx"),q.join(X,"public","assets"),q.join(X,"server","pages"),q.join(X,"server","fragments")];for(let Y of j)G.mkdirSync(Y,{recursive:!0});console.log("[stx build] Discovering routes...");let E=zF(Z,{pagesDirs:F._layerPageDirs}),LF=["components","layouts","partials"],y=E.filter((Y)=>{return!LF.some((B)=>Y.pattern.startsWith(`/${B}/`)||Y.pattern===`/${B}`)});console.log(`[stx build] Found ${y.length} page routes (${E.length-y.length} non-page files excluded)`),console.log("[stx build] Generating shared assets...");let L=c(Q.debug),K=a();await Bun.write(q.join(X,"public","__stx",L.filename),L.content),await Bun.write(q.join(X,"public","__stx",K.filename),K.content),console.log(`[stx build] Runtime: ${L.filename} (${(L.content.length/1024).toFixed(1)}KB)`),console.log(`[stx build] Router: ${K.filename} (${(K.content.length/1024).toFixed(1)}KB)`),console.log("[stx build] Compiling templates...");let R=[],v=[];for(let Y of y){let B=x(Y.pattern),b=B.rendering==="prerender";if(b&&(Y.pattern.includes(":")||Y.pattern.includes("[")))throw Error(`Cannot prerender parameter route ${Y.pattern}; use dynamic rendering (explicit path enumeration is not supported here)`);try{let J=await FF(Y.filePath,Y.pattern,{configDir:Z,componentsDir:U,partialsDir:w,layoutsDir:H,debug:Q.debug});if(R.push(J),J.html=J.html.replace(/runtime\.__STX_HASH__\.js/g,L.filename).replace(/router\.__STX_HASH__\.js/g,K.filename),J.html=VF(J.html,k,{bodyScripts:[`<script src="/__stx/${K.filename}"></script>`],...W&&{colorMode:W}}),W)J.html=$F(J.html,W);if(k.htmlAttrs)J.html=GF(J.html,k.htmlAttrs);if(!/<body[^>]*\bdata-stx=/.test(J.html)){let $=J.html.match(/<(?!body\b)[a-zA-Z][a-zA-Z0-9-]*\b[^>]*?\s(data-stx="[^"]+")[^>]*>/);if($&&$[1]){let m=$[1];J.html=J.html.replace(" "+m,""),J.html=J.html.replace(/<body([^>]*)>/,`<body$1 ${m}>`)}}if(J.html=J.html.replace(/<style data-css="generated">[\s\S]*?<\/style>\s*/g,""),J.html=await qF(J.html),b){let $=await EF(J,{params:{},request:new Request(`http://stx.build${Y.pattern}`),method:"GET",__stx_strict_hydration:!0});if($.redirect||$.cookies?.length||$.boundaries?.length||$.headers&&Object.keys($.headers).length)throw Error(`Prerendered route ${Y.pattern} cannot set response headers/cookies, redirect or stream`);J.html=$.html,J.status=$.status??J.status,J.hasServerScripts=!1,J.serverScriptContent=[],J.placeholders={}}J.fragment=kF(J.html,_);let C=Y.pattern==="/"?"index":Y.pattern.slice(1).replace(/\//g,"-").replace(/[[\]]/g,"_"),g=q.join("server","pages",`${C}.compiled.json`),f=q.join("server","fragments",`${C}.html`);await Bun.write(q.join(X,g),JSON.stringify(J,null,2)),await Bun.write(q.join(X,f),J.fragment),v.push({pattern:Y.pattern,compiledPath:g,fragmentPath:f,isDynamic:J.hasServerScripts,hasParams:Y.pattern.includes(":")||Y.pattern.includes("["),prerendered:b}),console.log(`[stx build] \u2713 ${Y.pattern}`)}catch(J){if(Object.keys(B).length)throw J;console.error(`[stx build] \u2717 ${Y.pattern}:`,J instanceof Error?J.message:J)}}let P=q.resolve(Z,V);if(G.existsSync(P)){let{copied:Y,bytes:B}=JF(P,q.join(X,"public"));if(Y>0)console.log(`[stx build] Copied ${Y} public asset${Y===1?"":"s"} (${(B/1024).toFixed(1)}KB) from ${V}/`)}let A=KF(Z);if(A){let{copied:Y,bytes:B}=JF(A,q.join(X,"public",IF));if(Y>0)console.log(`[stx build] Copied ${Y} asset${Y===1?"":"s"} (${(B/1024).toFixed(1)}KB) from ${HF}/`)}let S={runtime:L.filename,router:K.filename},T=UF(v,S,X);if(T.routeRules=N,T.routerContainer=_,I)T.apiRoutes=await ZF(Z,X,O);if(F.runtimeConfig)await Bun.write(q.join(X,"server/runtime-config.json"),JSON.stringify(F.runtimeConfig)),await WF(Z,F.runtimeConfig);if(F._layerGraph)await Bun.write(q.join(X,"server/layers.json"),JSON.stringify(XF(F._layerGraph),null,2));wF(T,X);let D=Date.now()-z;return console.log(`
2
+ import{mg as e,og as kF,pg as UF,qg as wF,yg as EF}from"./chunk-eg30ksd8.js";import{Bg as BF}from"./chunk-g64qyhhb.js";import{rj as l,sj as d}from"./chunk-szcxpbfn.js";import{Gk as HF,Hk as IF,Ik as KF}from"./chunk-7eea1cse.js";import{ql as YF,sl as ZF}from"./chunk-etah20m0.js";import{$m as s,Er as t,Gr as M,Ip as GF,Qp as VF,Up as r,Zp as o,no as zF,qp as $F,rm as p,tm as i}from"./chunk-ptad3t7a.js";import{Gs as XF}from"./chunk-wheh08v2.js";import{wt as qF}from"./chunk-ndydf37f.js";import{Qt as WF}from"./chunk-jbtzq3xt.js";import{Vt as QF}from"./chunk-mjearf0g.js";import{Lw as h,Ow as _F}from"./chunk-qbc0bebg.js";import G from"fs";import q from"path";import{createHash as NF}from"crypto";_F();function u(Q){return NF("sha256").update(Q).digest("hex").slice(0,8)}function c(Q=!1){let z=Q?d():l(),Z=u(z);return{content:z,filename:`runtime.${Z}.js`,hash:Z}}function a(){let Q=h(),z=u(Q);return{content:Q,filename:`router.${z}.js`,hash:z}}function bF(Q){return{runtimeTag:Q.runtime?`<script src="/__stx/${Q.runtime.filename}"></script>`:"",routerTag:Q.router?`<script src="/__stx/${Q.router.filename}"></script>`:"",cssTag:Q.css?`<link rel="stylesheet" href="/__stx/${Q.css.filename}">`:""}}import n from"path";import{createHash as OF}from"crypto";function TF(Q={}){let z=new Set;return{context:new Proxy(Q,{get(X,F){if(F in X)return X[F];if(typeof F==="string"&&!F.startsWith("__"))z.add(F);return},has(X,F){if(F in X)return!0;if(typeof F==="string"&&!F.startsWith("__"))z.add(F);return!1}}),accessedKeys:z}}async function FF(Q,z,Z={}){let X=n.resolve(Q),F=await Bun.file(X).text(),U=OF("sha256").update(F).digest("hex").slice(0,16);p();let w={};try{w=await M(Z.configDir)}catch{}let H=[],V=/<script\b([^>]*)>([\s\S]*?)<\/script>/gi,k;while((k=V.exec(F))!==null){let E=k[1];if(/\bserver\b/.test(E))H.push(k[2])}let W=new Set(H.flatMap((E)=>o(E))),{context:_}=TF({__filename:X,__dirname:n.dirname(X),__stx_serverDeclared:W}),N=new Set,x={...t,...w,...Z,buildMode:"compile",strict:!1},I=await r(F,_,X,x,N),O=e(I),j=i();return{route:z,sourceFile:Q,html:I,fragment:O,placeholders:j,hasServerScripts:H.length>0,serverScriptContent:H,dependencies:Array.from(N),contentHash:U,status:s(F),streamTemplates:_.__streamTemplates}}var MF=new Set([".DS_Store","Thumbs.db","desktop.ini",".gitkeep",".gitignore"]);function JF(Q,z){let Z=0,X=0;if(!G.existsSync(Q))return{copied:Z,bytes:X};G.mkdirSync(z,{recursive:!0});function F(U,w){let H=G.readdirSync(U,{withFileTypes:!0});for(let V of H){if(MF.has(V.name))continue;let k=q.join(U,V.name),W=q.join(w,V.name);if(V.isDirectory())G.mkdirSync(W,{recursive:!0}),F(k,W);else if(V.isFile()){if(G.existsSync(W))continue;G.copyFileSync(k,W),Z++,X+=G.statSync(W).size}}}return F(Q,z),{copied:Z,bytes:X}}async function qJ(Q={}){let z=Date.now(),Z=q.resolve(Q.root||process.cwd()),X=q.resolve(Z,Q.outputDir||".output");console.log("[stx build] Starting production build...");let F=await M(Z),U=q.resolve(Z,Q.componentsDir??F.componentsDir??"components"),w=q.resolve(Z,Q.partialsDir??F.partialsDir??"partials"),H=q.resolve(Z,Q.layoutsDir??F.layoutsDir??"layouts"),V=Q.publicDir??F.publicDir??"public",k=F.app?.head||{},W=F.app?.colorMode,_=F.router?.container||"main",N=Q.routeRules??F.routeRules??{},x=BF(N),I=Q.serverApi??F.serverApi,O=typeof I==="object"?I:{};if(I)YF(Z,O);if(F.runtimeConfig)QF(F.runtimeConfig,{});if(G.existsSync(X))G.rmSync(X,{recursive:!0});let j=[q.join(X,"public","__stx"),q.join(X,"public","assets"),q.join(X,"server","pages"),q.join(X,"server","fragments")];for(let Y of j)G.mkdirSync(Y,{recursive:!0});console.log("[stx build] Discovering routes...");let E=zF(Z,{pagesDirs:F._layerPageDirs}),LF=["components","layouts","partials"],y=E.filter((Y)=>{return!LF.some((B)=>Y.pattern.startsWith(`/${B}/`)||Y.pattern===`/${B}`)});console.log(`[stx build] Found ${y.length} page routes (${E.length-y.length} non-page files excluded)`),console.log("[stx build] Generating shared assets...");let L=c(Q.debug),K=a();await Bun.write(q.join(X,"public","__stx",L.filename),L.content),await Bun.write(q.join(X,"public","__stx",K.filename),K.content),console.log(`[stx build] Runtime: ${L.filename} (${(L.content.length/1024).toFixed(1)}KB)`),console.log(`[stx build] Router: ${K.filename} (${(K.content.length/1024).toFixed(1)}KB)`),console.log("[stx build] Compiling templates...");let R=[],v=[];for(let Y of y){let B=x(Y.pattern),b=B.rendering==="prerender";if(b&&(Y.pattern.includes(":")||Y.pattern.includes("[")))throw Error(`Cannot prerender parameter route ${Y.pattern}; use dynamic rendering (explicit path enumeration is not supported here)`);try{let J=await FF(Y.filePath,Y.pattern,{configDir:Z,componentsDir:U,partialsDir:w,layoutsDir:H,debug:Q.debug});if(R.push(J),J.html=J.html.replace(/runtime\.__STX_HASH__\.js/g,L.filename).replace(/router\.__STX_HASH__\.js/g,K.filename),J.html=VF(J.html,k,{bodyScripts:[`<script src="/__stx/${K.filename}"></script>`],...W&&{colorMode:W}}),W)J.html=$F(J.html,W);if(k.htmlAttrs)J.html=GF(J.html,k.htmlAttrs);if(!/<body[^>]*\bdata-stx=/.test(J.html)){let $=J.html.match(/<(?!body\b)[a-zA-Z][a-zA-Z0-9-]*\b[^>]*?\s(data-stx="[^"]+")[^>]*>/);if($&&$[1]){let m=$[1];J.html=J.html.replace(" "+m,""),J.html=J.html.replace(/<body([^>]*)>/,`<body$1 ${m}>`)}}if(J.html=J.html.replace(/<style data-css="generated">[\s\S]*?<\/style>\s*/g,""),J.html=await qF(J.html),b){let $=await EF(J,{params:{},request:new Request(`http://stx.build${Y.pattern}`),method:"GET",__stx_strict_hydration:!0});if($.redirect||$.cookies?.length||$.boundaries?.length||$.headers&&Object.keys($.headers).length)throw Error(`Prerendered route ${Y.pattern} cannot set response headers/cookies, redirect or stream`);J.html=$.html,J.status=$.status??J.status,J.hasServerScripts=!1,J.serverScriptContent=[],J.placeholders={}}J.fragment=kF(J.html,_);let C=Y.pattern==="/"?"index":Y.pattern.slice(1).replace(/\//g,"-").replace(/[[\]]/g,"_"),g=q.join("server","pages",`${C}.compiled.json`),f=q.join("server","fragments",`${C}.html`);await Bun.write(q.join(X,g),JSON.stringify(J,null,2)),await Bun.write(q.join(X,f),J.fragment),v.push({pattern:Y.pattern,compiledPath:g,fragmentPath:f,isDynamic:J.hasServerScripts,hasParams:Y.pattern.includes(":")||Y.pattern.includes("["),prerendered:b}),console.log(`[stx build] \u2713 ${Y.pattern}`)}catch(J){if(Object.keys(B).length)throw J;console.error(`[stx build] \u2717 ${Y.pattern}:`,J instanceof Error?J.message:J)}}let P=q.resolve(Z,V);if(G.existsSync(P)){let{copied:Y,bytes:B}=JF(P,q.join(X,"public"));if(Y>0)console.log(`[stx build] Copied ${Y} public asset${Y===1?"":"s"} (${(B/1024).toFixed(1)}KB) from ${V}/`)}let A=KF(Z);if(A){let{copied:Y,bytes:B}=JF(A,q.join(X,"public",IF));if(Y>0)console.log(`[stx build] Copied ${Y} asset${Y===1?"":"s"} (${(B/1024).toFixed(1)}KB) from ${HF}/`)}let S={runtime:L.filename,router:K.filename},T=UF(v,S,X);if(T.routeRules=N,T.routerContainer=_,I)T.apiRoutes=await ZF(Z,X,O);if(F.runtimeConfig)await Bun.write(q.join(X,"server/runtime-config.json"),JSON.stringify(F.runtimeConfig)),await WF(Z,F.runtimeConfig);if(F._layerGraph)await Bun.write(q.join(X,"server/layers.json"),JSON.stringify(XF(F._layerGraph),null,2));wF(T,X);let D=Date.now()-z;return console.log(`
3
3
  [stx build] Done in ${D}ms \u2014 ${R.length} pages compiled`),{pageCount:R.length,assets:S,outputDir:X,duration:D}}
4
4
  export{u as Vf,c as Wf,a as Xf,bF as Yf,FF as Zf,qJ as _f};
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import"./chunk-rxz43r6k.js";function F(){return`<script data-stx-scoped data-stx-x-element-runtime data-stx-run="always">
2
+ import"./chunk-cevkpyn9.js";function F(){return`<script data-stx-scoped data-stx-x-element-runtime data-stx-run="always">
3
3
  (function() {
4
4
  'use strict';
5
5