@stacksjs/stx 0.2.94 → 0.2.95

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 (551) hide show
  1. package/dist/a11y.js +1 -1
  2. package/dist/analytics.js +1 -1
  3. package/dist/analyzer.js +1 -1
  4. package/dist/animation.js +1 -1
  5. package/dist/app-shell.js +1 -1
  6. package/dist/app.js +1 -1
  7. package/dist/assets.js +1 -1
  8. package/dist/ast.js +1 -1
  9. package/dist/async-components.js +1 -1
  10. package/dist/auth.js +1 -1
  11. package/dist/broadcasting.js +1 -1
  12. package/dist/browser-composables.js +1 -1
  13. package/dist/build-assets.js +1 -1
  14. package/dist/build-mode-detector.js +1 -1
  15. package/dist/build-optimizer.js +1 -1
  16. package/dist/build-views.js +1 -1
  17. package/dist/build.js +1 -1
  18. package/dist/builtins/drawer.js +1 -1
  19. package/dist/builtins/escape.js +1 -1
  20. package/dist/builtins/icon.js +1 -1
  21. package/dist/builtins/index.js +1 -1
  22. package/dist/builtins/modal.js +1 -1
  23. package/dist/builtins/safe-image.js +1 -1
  24. package/dist/builtins/stx-image.js +1 -1
  25. package/dist/builtins/stx-link.js +1 -1
  26. package/dist/builtins/stx-loading-indicator.js +1 -1
  27. package/dist/builtins/suspense.js +1 -1
  28. package/dist/builtins/toast.js +1 -1
  29. package/dist/builtins/tooltip.js +1 -1
  30. package/dist/builtins/transition-group.js +1 -1
  31. package/dist/bundle-analyzer/collector.js +1 -1
  32. package/dist/bundle-analyzer/index.js +1 -1
  33. package/dist/bundle-analyzer/report.js +1 -1
  34. package/dist/bundle-analyzer/treemap.js +1 -1
  35. package/dist/caching.js +1 -1
  36. package/dist/{chunk-eh8hact1.js → chunk-04n64bnt.js} +1 -1
  37. package/dist/{chunk-yexjrg9d.js → chunk-06w68hyg.js} +2 -2
  38. package/dist/{chunk-4j188175.js → chunk-07y6m5xx.js} +1 -1
  39. package/dist/{chunk-b3kkjcdh.js → chunk-09k66d8a.js} +1 -1
  40. package/dist/{chunk-bk8ew8ze.js → chunk-0a61y94n.js} +2 -2
  41. package/dist/{chunk-qdc3aav1.js → chunk-0dx4q6yq.js} +1 -1
  42. package/dist/{chunk-k8440jxh.js → chunk-0p0nyq50.js} +2 -2
  43. package/dist/{chunk-5qb761h2.js → chunk-0p1h3p3w.js} +1 -1
  44. package/dist/{chunk-znxp3zha.js → chunk-10debkj5.js} +1 -1
  45. package/dist/{chunk-bgec9r1v.js → chunk-15nesxgt.js} +2 -2
  46. package/dist/{chunk-mv03qb75.js → chunk-1sr54zp8.js} +1 -1
  47. package/dist/{chunk-0jkwrcwj.js → chunk-1v49fwr5.js} +1 -1
  48. package/dist/{chunk-w01y57f5.js → chunk-1xz0w746.js} +2 -2
  49. package/dist/{chunk-w4n8fqp7.js → chunk-20swzkx3.js} +1 -1
  50. package/dist/{chunk-cz25azze.js → chunk-27zsyhrd.js} +1 -1
  51. package/dist/{chunk-hjdc99kb.js → chunk-29y0hk5z.js} +2 -2
  52. package/dist/{chunk-tx6br9r4.js → chunk-2cdvw21b.js} +1 -1
  53. package/dist/{chunk-g2hekckm.js → chunk-2j21d3ka.js} +1 -1
  54. package/dist/chunk-2jxbwnkz.js +2 -0
  55. package/dist/{chunk-8fgwhhb8.js → chunk-31dr4bys.js} +2 -2
  56. package/dist/{chunk-x64kb787.js → chunk-35faj94w.js} +1 -1
  57. package/dist/{chunk-9yz5d003.js → chunk-3a4qsygv.js} +2 -2
  58. package/dist/{chunk-1z2yq9em.js → chunk-3te20hqw.js} +2 -2
  59. package/dist/{chunk-aw3rp9ac.js → chunk-43t7faps.js} +1 -1
  60. package/dist/{chunk-0m9tdm7t.js → chunk-47kpewks.js} +1 -1
  61. package/dist/{chunk-cygfdk1n.js → chunk-4d2y57k7.js} +2 -2
  62. package/dist/{chunk-0tatqxj2.js → chunk-4deg33rw.js} +2 -2
  63. package/dist/{chunk-a69tvya5.js → chunk-4qcy5tx6.js} +2 -2
  64. package/dist/{chunk-d77yxcds.js → chunk-4x7kae4j.js} +2 -2
  65. package/dist/{chunk-g8b81pzc.js → chunk-55nwdnsd.js} +1 -1
  66. package/dist/{chunk-svahbw0w.js → chunk-5f43yz6z.js} +2 -2
  67. package/dist/{chunk-fch9tk1k.js → chunk-5shey2e4.js} +1 -1
  68. package/dist/{chunk-nanw7yhz.js → chunk-6djzdes9.js} +1 -1
  69. package/dist/{chunk-yj560gp8.js → chunk-6eqbxcrd.js} +1 -1
  70. package/dist/{chunk-03c26pjz.js → chunk-7074g241.js} +1 -1
  71. package/dist/{chunk-e0zytzdh.js → chunk-7b6s3g65.js} +1 -1
  72. package/dist/{chunk-77tga15w.js → chunk-7dkz6z2s.js} +2 -2
  73. package/dist/{chunk-q60knhjf.js → chunk-7ed3tean.js} +1 -1
  74. package/dist/{chunk-b0cyc09a.js → chunk-7gd339hd.js} +1 -1
  75. package/dist/{chunk-xsqbk4yk.js → chunk-7j5e8sdj.js} +2 -2
  76. package/dist/{chunk-52agge4n.js → chunk-7n8g0nfn.js} +1 -1
  77. package/dist/{chunk-cn409b69.js → chunk-80g54ncj.js} +1 -1
  78. package/dist/{chunk-w21mwxdd.js → chunk-8a5bxece.js} +1 -1
  79. package/dist/{chunk-7rvh2wwv.js → chunk-8ahwt6a4.js} +1 -1
  80. package/dist/{chunk-fhawx87n.js → chunk-8b3z0zd5.js} +1 -1
  81. package/dist/{chunk-y86m1wr4.js → chunk-8dhdpa5h.js} +2 -2
  82. package/dist/{chunk-hje9v2zh.js → chunk-8n9nnqr6.js} +1 -1
  83. package/dist/{chunk-rb1e4cnb.js → chunk-8qc1bsym.js} +1 -1
  84. package/dist/{chunk-bwxda6n1.js → chunk-8va64c9n.js} +2 -2
  85. package/dist/{chunk-hrampcrj.js → chunk-8vtm0m84.js} +1 -1
  86. package/dist/{chunk-cp3kwv17.js → chunk-8xj7c3mf.js} +1 -1
  87. package/dist/{chunk-fe7r1mq1.js → chunk-988dw6q3.js} +2 -2
  88. package/dist/{chunk-wk07pwtd.js → chunk-9b6cec0v.js} +1 -1
  89. package/dist/{chunk-13yz561y.js → chunk-9cf97f9p.js} +2 -2
  90. package/dist/{chunk-rv002yn0.js → chunk-9ecv8aqj.js} +1 -1
  91. package/dist/{chunk-jbejwejg.js → chunk-9eq3ht5f.js} +1 -1
  92. package/dist/{chunk-dzw95th7.js → chunk-9jtj77jx.js} +2 -2
  93. package/dist/{chunk-57p201gb.js → chunk-9t14se2t.js} +1 -1
  94. package/dist/{chunk-qd5461tt.js → chunk-9wmq2272.js} +1 -1
  95. package/dist/{chunk-qm4yppj5.js → chunk-9zbk5zx5.js} +2 -2
  96. package/dist/{chunk-7b0xdy5h.js → chunk-a2g2qb2y.js} +1 -1
  97. package/dist/{chunk-26r6zh3t.js → chunk-a87qqft6.js} +2 -2
  98. package/dist/{chunk-5kt3ay7x.js → chunk-ah88wzbg.js} +1 -1
  99. package/dist/{chunk-0wdar532.js → chunk-akf1r75r.js} +1 -1
  100. package/dist/{chunk-wxvyj65q.js → chunk-amaa1bev.js} +1 -1
  101. package/dist/{chunk-ganag9dm.js → chunk-avx8aydt.js} +2 -2
  102. package/dist/{chunk-mgmyr1b9.js → chunk-ay9qf4zj.js} +1 -1
  103. package/dist/{chunk-haecq01c.js → chunk-aywxfqev.js} +1 -1
  104. package/dist/{chunk-4bt81cg3.js → chunk-azkegjd8.js} +1 -1
  105. package/dist/{chunk-e53h9qhd.js → chunk-b77wjyn7.js} +1 -1
  106. package/dist/{chunk-jfm69keq.js → chunk-baf1hfwh.js} +2 -2
  107. package/dist/{chunk-hke99a0v.js → chunk-bdk6g1vj.js} +2 -2
  108. package/dist/{chunk-kkp6rs2n.js → chunk-bhqgmyqw.js} +1 -1
  109. package/dist/{chunk-fs0qezn5.js → chunk-bk3j0n82.js} +1 -1
  110. package/dist/{chunk-sn07azv3.js → chunk-bndmdahk.js} +2 -2
  111. package/dist/{chunk-mrehzhxv.js → chunk-bs3gmfxz.js} +1 -1
  112. package/dist/{chunk-yach037f.js → chunk-bxc7kjsk.js} +1 -1
  113. package/dist/{chunk-gqpkp459.js → chunk-ckxjqqn9.js} +2 -2
  114. package/dist/{chunk-ncnfa8ae.js → chunk-d0zjtdw4.js} +2 -2
  115. package/dist/{chunk-qfwzdffx.js → chunk-d1qh1x2g.js} +2 -2
  116. package/dist/{chunk-gcf5v18y.js → chunk-djddhmcc.js} +1 -1
  117. package/dist/{chunk-fms20x0n.js → chunk-dqn9gyhb.js} +1 -1
  118. package/dist/{chunk-6w03t7h6.js → chunk-drjq2zwg.js} +2 -2
  119. package/dist/{chunk-91s2hres.js → chunk-e2q9c5vq.js} +1 -1
  120. package/dist/{chunk-3ngm57nt.js → chunk-e98v1bc6.js} +2 -2
  121. package/dist/chunk-ejayeex8.js +2 -0
  122. package/dist/{chunk-yr1gdceh.js → chunk-ejh8fyak.js} +1 -1
  123. package/dist/{chunk-6wn85hn6.js → chunk-ek2w6zvy.js} +1 -1
  124. package/dist/{chunk-7dy588as.js → chunk-ewa88139.js} +1 -1
  125. package/dist/{chunk-ht4j68cs.js → chunk-fjk3x41y.js} +2 -2
  126. package/dist/{chunk-x39sfpvm.js → chunk-frg705zq.js} +1 -1
  127. package/dist/{chunk-nap11ntr.js → chunk-g1vt329s.js} +2 -2
  128. package/dist/{chunk-6cr3eeh4.js → chunk-gkzq8zw4.js} +1 -1
  129. package/dist/{chunk-3rh7va1z.js → chunk-gz5fmp3q.js} +1 -1
  130. package/dist/{chunk-asarebzq.js → chunk-h0hjy0kn.js} +1 -1
  131. package/dist/{chunk-ywkrxp2h.js → chunk-h5jxydqq.js} +1 -1
  132. package/dist/{chunk-4qq8ffke.js → chunk-h7aq56qj.js} +1 -1
  133. package/dist/{chunk-hepg894w.js → chunk-hbehnm18.js} +2 -2
  134. package/dist/{chunk-gc84b1d2.js → chunk-hbgxbgam.js} +2 -2
  135. package/dist/{chunk-05hgyyqc.js → chunk-hc2mf5h6.js} +1 -1
  136. package/dist/{chunk-tr0z0e1g.js → chunk-hjm2xab3.js} +1 -1
  137. package/dist/{chunk-50vqeesm.js → chunk-hrnnh4tq.js} +2 -2
  138. package/dist/{chunk-hq5cem49.js → chunk-ht43ds42.js} +1 -1
  139. package/dist/{chunk-vdfwv0fp.js → chunk-hy8820vc.js} +1 -1
  140. package/dist/{chunk-vpe6napb.js → chunk-j447q024.js} +2 -2
  141. package/dist/{chunk-x4fze3q2.js → chunk-j58vh0w6.js} +1 -1
  142. package/dist/{chunk-z37xq5rx.js → chunk-j8tn8enq.js} +2 -2
  143. package/dist/{chunk-m59y310j.js → chunk-jjb05d21.js} +2 -2
  144. package/dist/{chunk-3bjtemm6.js → chunk-jjdq01dv.js} +1 -1
  145. package/dist/{chunk-b3prs7y0.js → chunk-jnmgm2xw.js} +1 -1
  146. package/dist/{chunk-5ggw1dyv.js → chunk-jpndqst5.js} +1 -1
  147. package/dist/{chunk-7sm05m0j.js → chunk-jt0ezawy.js} +1 -1
  148. package/dist/{chunk-6y4gqs1q.js → chunk-jz73j3qs.js} +1 -1
  149. package/dist/{chunk-jt98jhpt.js → chunk-k21df0pg.js} +1 -1
  150. package/dist/{chunk-zt2yag10.js → chunk-k848dzsa.js} +1 -1
  151. package/dist/{chunk-bjnjpsgn.js → chunk-kdfe4t91.js} +2 -2
  152. package/dist/{chunk-82t27pvd.js → chunk-keawsbpn.js} +1 -1
  153. package/dist/{chunk-5q87fgkk.js → chunk-khdn7jwe.js} +2 -2
  154. package/dist/{chunk-ca6qd1dx.js → chunk-km25cwz6.js} +1 -1
  155. package/dist/{chunk-pc31m5x5.js → chunk-knm8a8yx.js} +1 -1
  156. package/dist/{chunk-baa7h4yz.js → chunk-krqn0ddk.js} +2 -2
  157. package/dist/{chunk-0g4gece6.js → chunk-kx6eb6ma.js} +1 -1
  158. package/dist/{chunk-3yg9hbmb.js → chunk-kypas8vy.js} +1 -1
  159. package/dist/{chunk-7xcfy2fn.js → chunk-m167kjhv.js} +1 -1
  160. package/dist/{chunk-w959hm8j.js → chunk-m491r0rj.js} +1 -1
  161. package/dist/{chunk-x1hjv24z.js → chunk-m8448qby.js} +1 -1
  162. package/dist/{chunk-tj6zfxeb.js → chunk-mgj88zeq.js} +2 -2
  163. package/dist/{chunk-6djgb0hr.js → chunk-mhgk632d.js} +1 -1
  164. package/dist/{chunk-y5wazw6j.js → chunk-n5kg7fpx.js} +1 -1
  165. package/dist/{chunk-957amb71.js → chunk-n98x35xd.js} +1 -1
  166. package/dist/{chunk-04mvcmcr.js → chunk-n9dhs1dw.js} +1 -1
  167. package/dist/{chunk-75rndzbd.js → chunk-nd9rmddh.js} +1 -1
  168. package/dist/{chunk-y25pr13j.js → chunk-nhv099jv.js} +1 -1
  169. package/dist/{chunk-cpcc11vp.js → chunk-nm15ccsg.js} +2 -2
  170. package/dist/{chunk-z4djtgt0.js → chunk-npfmdb6y.js} +1 -1
  171. package/dist/{chunk-xhkjhxsp.js → chunk-p077sw22.js} +1 -1
  172. package/dist/{chunk-kfd2hf6f.js → chunk-p1h8065h.js} +2 -2
  173. package/dist/{chunk-647849kf.js → chunk-p3e0cqtt.js} +2 -2
  174. package/dist/{chunk-c53hyw5c.js → chunk-p3fpb79v.js} +1 -1
  175. package/dist/{chunk-adjcg6wa.js → chunk-p52yzjq6.js} +2 -2
  176. package/dist/{chunk-qgxwmagw.js → chunk-p73meypx.js} +1 -1
  177. package/dist/{chunk-bykjk6vj.js → chunk-pa9zb7ty.js} +1 -1
  178. package/dist/{chunk-qk584whs.js → chunk-pcm1vd8w.js} +1 -1
  179. package/dist/{chunk-bn08k7yy.js → chunk-pcntd9h4.js} +2 -2
  180. package/dist/{chunk-87kx8byz.js → chunk-psc3wfcf.js} +1 -1
  181. package/dist/{chunk-svhtdb0s.js → chunk-pznnww6k.js} +1 -1
  182. package/dist/{chunk-5ppkfyn2.js → chunk-q6zhd9yf.js} +1 -1
  183. package/dist/chunk-qa59zejf.js +246 -0
  184. package/dist/{chunk-hpqr9e3x.js → chunk-qvrbjpdc.js} +2 -2
  185. package/dist/{chunk-46mkpbkk.js → chunk-qygvvygy.js} +2 -2
  186. package/dist/{chunk-xygc53vr.js → chunk-r0jcmpv6.js} +1 -1
  187. package/dist/{chunk-yw2fzq86.js → chunk-r5m9xtm7.js} +2 -2
  188. package/dist/{chunk-174z0cd0.js → chunk-rpx5fa65.js} +2 -2
  189. package/dist/{chunk-tmgz5t2g.js → chunk-rqxf5hns.js} +1 -1
  190. package/dist/{chunk-5xvbq2gs.js → chunk-rtr974rc.js} +2 -2
  191. package/dist/{chunk-y4c744dk.js → chunk-rvptcndz.js} +2 -2
  192. package/dist/{chunk-25s7bckb.js → chunk-rw26rpek.js} +2 -2
  193. package/dist/{chunk-qhdtssn1.js → chunk-rw7937v4.js} +2 -2
  194. package/dist/{chunk-n46a5g1g.js → chunk-rwrv9wbf.js} +1 -1
  195. package/dist/{chunk-8qbax8xn.js → chunk-rz2ec6g7.js} +1 -1
  196. package/dist/{chunk-epj957jf.js → chunk-scpkdrdb.js} +1 -1
  197. package/dist/{chunk-q6h6yvzb.js → chunk-shv88d2d.js} +2 -2
  198. package/dist/{chunk-2w3302dh.js → chunk-t0c9wvpr.js} +1 -1
  199. package/dist/{chunk-6dqzky7x.js → chunk-tffh3b1e.js} +1 -1
  200. package/dist/{chunk-ceg2c2q2.js → chunk-tg2f1mzq.js} +2 -2
  201. package/dist/{chunk-eqeyaq6g.js → chunk-trfswy66.js} +1 -1
  202. package/dist/{chunk-t37dp99j.js → chunk-tzwtg722.js} +1 -1
  203. package/dist/{chunk-ghrx0hn1.js → chunk-v7f8jj15.js} +1 -1
  204. package/dist/{chunk-95w08s8v.js → chunk-v8j49spx.js} +1 -1
  205. package/dist/{chunk-yaan98dd.js → chunk-veeerpwa.js} +1 -1
  206. package/dist/{chunk-xcb0pbr6.js → chunk-vg5kt6az.js} +1 -1
  207. package/dist/{chunk-9tmbrwwx.js → chunk-vgv7jvyz.js} +1 -1
  208. package/dist/{chunk-2xen423s.js → chunk-vjbefncc.js} +1 -1
  209. package/dist/{chunk-jt44av4j.js → chunk-vmxjghsm.js} +1 -1
  210. package/dist/{chunk-mqwbpamc.js → chunk-vw7vqd76.js} +1 -1
  211. package/dist/{chunk-adqh2m9z.js → chunk-w3b6m427.js} +1 -1
  212. package/dist/{chunk-eds0f8f1.js → chunk-wazkqv7n.js} +2 -2
  213. package/dist/{chunk-y4md9hp0.js → chunk-wfg2gm11.js} +1 -1
  214. package/dist/{chunk-vv9wfz1c.js → chunk-wg9k6h8w.js} +2 -2
  215. package/dist/{chunk-1mmykse5.js → chunk-wkz2vwkr.js} +1 -1
  216. package/dist/{chunk-7a51hkpf.js → chunk-wvf31nzs.js} +1 -1
  217. package/dist/{chunk-dyjnn5k8.js → chunk-x05nxhyv.js} +2 -2
  218. package/dist/{chunk-kh6rfz2v.js → chunk-x0770gt9.js} +1 -1
  219. package/dist/{chunk-5p568px4.js → chunk-x24s4heg.js} +1 -1
  220. package/dist/{chunk-cdbwprfv.js → chunk-x3r64r0c.js} +2 -2
  221. package/dist/{chunk-fbxt2mrx.js → chunk-x5g9w4hh.js} +2 -2
  222. package/dist/{chunk-268adc7r.js → chunk-xgkv66q5.js} +1 -1
  223. package/dist/chunk-xqq1vxb6.js +1 -0
  224. package/dist/{chunk-qxs6et76.js → chunk-xs03kc1h.js} +1 -1
  225. package/dist/{chunk-3jm3snz8.js → chunk-xv34zbp4.js} +1 -1
  226. package/dist/{chunk-b5zc9y0y.js → chunk-xw36p73h.js} +2 -2
  227. package/dist/{chunk-j4s5qwd7.js → chunk-xyg1r5w0.js} +2 -2
  228. package/dist/{chunk-cyp4m0vh.js → chunk-xys2sxh6.js} +1 -1
  229. package/dist/{chunk-kdxa9epn.js → chunk-y1k17c8b.js} +2 -2
  230. package/dist/{chunk-cr3wbrcr.js → chunk-y6xsqe9a.js} +2 -2
  231. package/dist/{chunk-94g3cahw.js → chunk-yb1t2h8h.js} +2 -2
  232. package/dist/{chunk-vw6ejgmy.js → chunk-yj4x5ehw.js} +1 -1
  233. package/dist/{chunk-fk51yyrw.js → chunk-ynhngsdh.js} +1 -1
  234. package/dist/{chunk-vp2395eb.js → chunk-yrsb6j3z.js} +2 -2
  235. package/dist/chunk-yywfvfph.js +2 -0
  236. package/dist/{chunk-xhnpsngj.js → chunk-zcxzdrn7.js} +2 -2
  237. package/dist/{chunk-jjvp4t5w.js → chunk-zen6ax1y.js} +2 -2
  238. package/dist/{chunk-n944baxp.js → chunk-zf2pek72.js} +1 -1
  239. package/dist/{chunk-z8cjr9n9.js → chunk-zk3d0jjf.js} +1 -1
  240. package/dist/{chunk-9agvhp1x.js → chunk-zy3rp1ab.js} +1 -1
  241. package/dist/cli.js +1 -1
  242. package/dist/client/directive.js +1 -1
  243. package/dist/client/index.js +1 -1
  244. package/dist/client-helpers.js +1 -1
  245. package/dist/client-script-bundler.js +1 -1
  246. package/dist/client-script.js +1 -1
  247. package/dist/component-hmr.js +1 -1
  248. package/dist/component-processing.js +1 -1
  249. package/dist/component-registry.js +1 -1
  250. package/dist/component-renderer.js +1 -1
  251. package/dist/components.js +1 -1
  252. package/dist/composables/index.js +1 -1
  253. package/dist/composables/use-battery.js +1 -1
  254. package/dist/composables/use-broadcast-channel.js +1 -1
  255. package/dist/composables/use-channel.js +1 -1
  256. package/dist/composables/use-clipboard.js +1 -1
  257. package/dist/composables/use-color-mode.js +1 -1
  258. package/dist/composables/use-cookie.js +1 -1
  259. package/dist/composables/use-device-orientation.js +1 -1
  260. package/dist/composables/use-event-listener.js +1 -1
  261. package/dist/composables/use-event-source.js +1 -1
  262. package/dist/composables/use-eye-dropper.js +1 -1
  263. package/dist/composables/use-fetch.js +1 -1
  264. package/dist/composables/use-fullscreen.js +1 -1
  265. package/dist/composables/use-geolocation.js +1 -1
  266. package/dist/composables/use-idle.js +1 -1
  267. package/dist/composables/use-intersection-observer.js +1 -1
  268. package/dist/composables/use-keyboard.js +1 -1
  269. package/dist/composables/use-media-query.js +1 -1
  270. package/dist/composables/use-meta.js +1 -1
  271. package/dist/composables/use-mouse.js +1 -1
  272. package/dist/composables/use-mutation-observer.js +1 -1
  273. package/dist/composables/use-network.js +1 -1
  274. package/dist/composables/use-notification.js +1 -1
  275. package/dist/composables/use-permissions.js +1 -1
  276. package/dist/composables/use-resize-observer.js +1 -1
  277. package/dist/composables/use-router.js +1 -1
  278. package/dist/composables/use-share.js +1 -1
  279. package/dist/composables/use-speech.js +1 -1
  280. package/dist/composables/use-storage.js +1 -1
  281. package/dist/composables/use-text-selection.js +1 -1
  282. package/dist/composables/use-timer.js +1 -1
  283. package/dist/composables/use-utilities.js +1 -1
  284. package/dist/composables/use-wake-lock.js +1 -1
  285. package/dist/composables/use-websocket.js +1 -1
  286. package/dist/composables/use-window.js +1 -1
  287. package/dist/composables.js +1 -1
  288. package/dist/composition-api.js +1 -1
  289. package/dist/computed.js +1 -1
  290. package/dist/conditionals.js +1 -1
  291. package/dist/config.js +1 -1
  292. package/dist/craft-bridge.js +1 -1
  293. package/dist/craft-compiler.js +1 -1
  294. package/dist/craft-components.js +1 -1
  295. package/dist/craft-entry.js +1 -1
  296. package/dist/craft-ssr.js +1 -1
  297. package/dist/csp.js +1 -1
  298. package/dist/csrf.js +1 -1
  299. package/dist/custom-directives.js +1 -1
  300. package/dist/defer.js +1 -1
  301. package/dist/deploy/config-generators.js +1 -1
  302. package/dist/deploy/index.js +1 -1
  303. package/dist/deploy/netlify.js +1 -1
  304. package/dist/dev-server/crosswind.js +1 -1
  305. package/dist/dev-server/index.js +1 -1
  306. package/dist/dev-server/keyboard-shortcuts.js +1 -1
  307. package/dist/dev-server/native-window.js +1 -1
  308. package/dist/dev-server/port-utils.js +1 -1
  309. package/dist/dev-server/serve-app.js +1 -6
  310. package/dist/dev-server/serve-file.js +1 -6
  311. package/dist/dev-server/serve-markdown.js +1 -1
  312. package/dist/dev-server/serve-multi.js +1 -171
  313. package/dist/dev-server/terminal-colors.js +1 -1
  314. package/dist/dev-server/theme-selector.js +1 -1
  315. package/dist/dev-server/types.js +1 -1
  316. package/dist/dev-server.js +1 -1
  317. package/dist/devtools.js +1 -1
  318. package/dist/directive-api.js +1 -1
  319. package/dist/docs.js +1 -1
  320. package/dist/doctor.js +1 -1
  321. package/dist/document-shell.js +1 -1
  322. package/dist/dynamic-components.js +1 -1
  323. package/dist/edge-runtime.js +1 -1
  324. package/dist/env.js +1 -1
  325. package/dist/error-boundaries.js +1 -1
  326. package/dist/error-handling.js +1 -1
  327. package/dist/errors/codes.js +1 -1
  328. package/dist/errors/formatter.js +1 -1
  329. package/dist/errors/index.js +1 -1
  330. package/dist/errors/logger.js +1 -1
  331. package/dist/errors/sanitizer.js +1 -1
  332. package/dist/errors/types.js +1 -1
  333. package/dist/events.js +1 -1
  334. package/dist/expressions.js +1 -1
  335. package/dist/formatter.js +1 -1
  336. package/dist/forms-validation.js +1 -1
  337. package/dist/forms.js +1 -1
  338. package/dist/head.js +1 -1
  339. package/dist/heatmap.js +1 -1
  340. package/dist/hot-reload.js +1 -1
  341. package/dist/html-masking.js +1 -1
  342. package/dist/hydration-runtime.js +1 -1
  343. package/dist/hydration.js +1 -1
  344. package/dist/i18n.js +1 -1
  345. package/dist/image-optimization/auto-sibling.js +1 -1
  346. package/dist/image-optimization/build-plugin.js +1 -1
  347. package/dist/image-optimization/component.js +1 -1
  348. package/dist/image-optimization/directive.js +1 -1
  349. package/dist/image-optimization/index.js +1 -1
  350. package/dist/image-optimization/processor.js +1 -1
  351. package/dist/image-optimization/serve.js +1 -1
  352. package/dist/includes.js +1 -1
  353. package/dist/index.js +1 -1
  354. package/dist/init.js +1 -1
  355. package/dist/inline-assets.js +1 -1
  356. package/dist/interactive.js +1 -1
  357. package/dist/internal-markdown.js +1 -1
  358. package/dist/island-chunking.js +1 -1
  359. package/dist/js-ts.js +1 -1
  360. package/dist/jsx-runtime.js +1 -1
  361. package/dist/keep-alive.js +1 -1
  362. package/dist/lazy-loader.js +1 -1
  363. package/dist/loading-indicator.js +1 -1
  364. package/dist/loops.js +1 -1
  365. package/dist/manifest.js +1 -1
  366. package/dist/markdown.js +1 -1
  367. package/dist/media/client/blur-up.js +1 -1
  368. package/dist/media/client/index.js +1 -1
  369. package/dist/media/client/lazy-load.js +1 -1
  370. package/dist/media/client/upload-handler.js +1 -1
  371. package/dist/media/image/component.js +1 -1
  372. package/dist/media/image/directive.js +1 -1
  373. package/dist/media/image/editing.js +1 -1
  374. package/dist/media/image/index.js +1 -1
  375. package/dist/media/image/placeholder.js +1 -1
  376. package/dist/media/image/processor/cache.js +1 -1
  377. package/dist/media/image/processor/index.js +1 -1
  378. package/dist/media/image/processor/optimizer.js +1 -1
  379. package/dist/media/image/processor/responsive.js +1 -1
  380. package/dist/media/image/srcset.js +1 -1
  381. package/dist/media/index.js +1 -1
  382. package/dist/media/manager/embed.js +1 -1
  383. package/dist/media/protected/component.js +1 -1
  384. package/dist/media/protected/index.js +1 -1
  385. package/dist/media/protected/signature.js +1 -1
  386. package/dist/media/shared/cache.js +1 -1
  387. package/dist/media/shared/hash.js +1 -1
  388. package/dist/media/shared/index.js +1 -1
  389. package/dist/media/upload/component.js +1 -1
  390. package/dist/media/upload/index.js +1 -1
  391. package/dist/media/video/directive.js +1 -1
  392. package/dist/media/video/index.js +1 -1
  393. package/dist/media/video/processor/cache.js +1 -1
  394. package/dist/media/video/processor/index.js +1 -1
  395. package/dist/media/video/processor/streaming.js +1 -1
  396. package/dist/media/video/processor/thumbnail.js +1 -1
  397. package/dist/media/video/processor/transcoder.js +1 -1
  398. package/dist/method-spoofing.js +1 -1
  399. package/dist/middleware.js +1 -1
  400. package/dist/misc-directives.js +1 -1
  401. package/dist/native-build.js +1 -1
  402. package/dist/parser/directive-parser.js +1 -1
  403. package/dist/parser/expression-parser.js +1 -1
  404. package/dist/parser/index.js +1 -1
  405. package/dist/parser/tokenizer.js +1 -1
  406. package/dist/partial-hydration.js +1 -1
  407. package/dist/performance-utils.js +1 -1
  408. package/dist/placeholder.js +1 -1
  409. package/dist/plugin-system.js +1 -1
  410. package/dist/plugin.js +1 -1
  411. package/dist/precompiler.js +1 -1
  412. package/dist/process.js +1 -1
  413. package/dist/production-build.js +1 -1
  414. package/dist/production-builder.js +1 -1
  415. package/dist/production-server.js +1 -1
  416. package/dist/props.js +1 -1
  417. package/dist/public-env.js +1 -1
  418. package/dist/pwa/audit.js +1 -1
  419. package/dist/pwa/directives.js +1 -1
  420. package/dist/pwa/icons.js +1 -1
  421. package/dist/pwa/index.js +1 -1
  422. package/dist/pwa/inject.js +1 -1
  423. package/dist/pwa/manifest.js +1 -1
  424. package/dist/pwa/offline.js +1 -1
  425. package/dist/pwa/precache.js +1 -1
  426. package/dist/pwa/service-worker.js +1 -1
  427. package/dist/pwa/workbox-strategies.js +1 -1
  428. package/dist/pwa/workbox.js +1 -1
  429. package/dist/reactive-bindings.js +1 -1
  430. package/dist/reactive.js +1 -1
  431. package/dist/reactivity.js +1 -1
  432. package/dist/release.js +1 -1
  433. package/dist/render.js +1 -1
  434. package/dist/route-middleware.js +1 -1
  435. package/dist/router.js +1 -1
  436. package/dist/routes.js +1 -1
  437. package/dist/runtime-injection.js +1 -1
  438. package/dist/runtime.js +1 -1
  439. package/dist/safe-evaluator.js +1 -1
  440. package/dist/scaffolding.js +1 -1
  441. package/dist/screenshot.js +1 -1
  442. package/dist/script-classifier.js +1 -1
  443. package/dist/script-validation.js +1 -1
  444. package/dist/seo.js +1 -1
  445. package/dist/serve.js +1 -1
  446. package/dist/server-bindings.js +1 -1
  447. package/dist/server-components.js +1 -1
  448. package/dist/signal-processing.js +1 -1
  449. package/dist/signals-api.js +1 -1
  450. package/dist/signals.js +1 -1
  451. package/dist/site-builder/build.js +1 -1
  452. package/dist/site-builder/i18n.js +1 -1
  453. package/dist/site-builder/index.js +1 -1
  454. package/dist/site-builder/robots.js +1 -1
  455. package/dist/site-builder/router.js +1 -1
  456. package/dist/site-builder/seo.js +1 -1
  457. package/dist/site-builder/sitemap.js +1 -1
  458. package/dist/site-builder/theme.js +1 -1
  459. package/dist/slots.js +1 -1
  460. package/dist/source-maps.js +1 -1
  461. package/dist/spa-shell.js +1 -1
  462. package/dist/ssr.js +1 -1
  463. package/dist/state-management.js +1 -1
  464. package/dist/store-imports.js +1 -1
  465. package/dist/store-loader.js +1 -1
  466. package/dist/stores-client.js +1 -1
  467. package/dist/story/addons.js +1 -1
  468. package/dist/story/analytics.js +1 -1
  469. package/dist/story/auto-stories.js +1 -1
  470. package/dist/story/bookmarks.js +1 -1
  471. package/dist/story/bun-test.js +1 -1
  472. package/dist/story/cli.js +1 -1
  473. package/dist/story/collect/analyzer.js +1 -1
  474. package/dist/story/collect/index.js +1 -1
  475. package/dist/story/collect/parser.js +1 -1
  476. package/dist/story/collect/scanner.js +1 -1
  477. package/dist/story/collect/tree.js +1 -1
  478. package/dist/story/commands/build.js +1 -1
  479. package/dist/story/commands/dev.js +1 -1
  480. package/dist/story/commands/index.js +1 -1
  481. package/dist/story/commands/preview.js +1 -1
  482. package/dist/story/compiled-output.js +1 -1
  483. package/dist/story/composition.js +1 -1
  484. package/dist/story/config-watcher.js +1 -1
  485. package/dist/story/config.js +1 -1
  486. package/dist/story/context.js +1 -1
  487. package/dist/story/controls/index.js +1 -1
  488. package/dist/story/crosswind.js +1 -1
  489. package/dist/story/desktop-preview.js +1 -1
  490. package/dist/story/docs-generator.js +1 -1
  491. package/dist/story/errors.js +1 -1
  492. package/dist/story/figma-export.js +1 -1
  493. package/dist/story/generator.js +1 -1
  494. package/dist/story/hmr.js +1 -1
  495. package/dist/story/hot-swap.js +1 -1
  496. package/dist/story/index.js +1 -1
  497. package/dist/story/interactions.js +1 -1
  498. package/dist/story/keyboard-shortcuts.js +1 -1
  499. package/dist/story/output.js +1 -1
  500. package/dist/story/performance.js +1 -1
  501. package/dist/story/presets.js +1 -1
  502. package/dist/story/props-validation.js +1 -1
  503. package/dist/story/renderer.js +1 -1
  504. package/dist/story/search-index.js +1 -1
  505. package/dist/story/search.js +1 -1
  506. package/dist/story/server.js +1 -1
  507. package/dist/story/setup.js +1 -1
  508. package/dist/story/snapshots.js +1 -1
  509. package/dist/story/testing.js +1 -1
  510. package/dist/story/theme.js +1 -1
  511. package/dist/story/ui/code-panel.js +1 -1
  512. package/dist/story/ui/controls-panel.js +1 -1
  513. package/dist/story/ui/index.js +1 -1
  514. package/dist/story/ui/navigation.js +1 -1
  515. package/dist/story/ui/preview.js +1 -1
  516. package/dist/story/visual-testing.js +1 -1
  517. package/dist/streaming.js +1 -1
  518. package/dist/strict-lint.js +1 -1
  519. package/dist/style-scoping.js +1 -1
  520. package/dist/suspense.js +1 -1
  521. package/dist/teleport.js +1 -1
  522. package/dist/template-compiler.js +1 -1
  523. package/dist/template-hydrator.js +1 -1
  524. package/dist/template-tag-balance.js +1 -1
  525. package/dist/testing.js +1 -1
  526. package/dist/transitions.js +1 -1
  527. package/dist/type-checker.js +1 -1
  528. package/dist/types/directive-types.js +1 -1
  529. package/dist/types/index.js +1 -1
  530. package/dist/types.js +1 -1
  531. package/dist/typescript-templates.js +1 -1
  532. package/dist/utils.js +1 -1
  533. package/dist/validator.js +1 -1
  534. package/dist/variable-extractor.js +1 -1
  535. package/dist/view-composers.js +1 -1
  536. package/dist/virtual-scrolling.js +1 -1
  537. package/dist/visual-editor.js +1 -1
  538. package/dist/vue-template.js +1 -1
  539. package/dist/web-components/css-scoping.js +1 -1
  540. package/dist/web-components/index.js +1 -1
  541. package/dist/web-components/reactive-generator.js +1 -1
  542. package/dist/web-components.js +1 -1
  543. package/dist/x-element.js +1 -1
  544. package/package.json +6 -6
  545. package/dist/chunk-48cw2nde.js +0 -2
  546. package/dist/chunk-48r3qe0k.js +0 -3
  547. package/dist/chunk-h45py5w5.js +0 -2
  548. package/dist/chunk-jfrn43vh.js +0 -2
  549. package/dist/chunk-mwbng54r.js +0 -2
  550. package/dist/chunk-qwyd9a1d.js +0 -2
  551. package/dist/chunk-sjagg9qz.js +0 -66
@@ -1,3 +1,3 @@
1
1
  // @bun
2
- import{Cx as Z}from"./chunk-rv002yn0.js";import{ry as $}from"./chunk-jjvp4t5w.js";import{Ty as _}from"./chunk-cz25azze.js";async function b(J,L,B,y){if(!y.customDirectives||y.customDirectives.length===0)return J;let G=J;for(let j of y.customDirectives){if(!j.name||typeof j.handler!=="function"){if(y.debug)console.warn("Invalid custom directive:",j);continue}if(j.hasEndTag)G=await D(G,j,L,B,y);else G=await Q(G,j,L,B,y)}return G}async function D(J,L,B,y,G){let{name:j,handler:k}=L,O=`@${j}`,Y=`@end${j}`,H=J,V=Z(`${O}(?:\\s*\\(([^()]*(?:\\([^)]*\\)[^()]*)*)\\))?([\\s\\S]*?)${Y}`,"g"),X=[],U=V.exec(H);while(U!==null){let[z,F="",A=""]=U,K=U.index||0;try{let N=F?W(F):[],w=A.trim(),q=await k(w,N,B,y);X.push({original:z,processed:q,startIndex:K})}catch(N){let w=N instanceof Error?N.message:String(N);if(G.debug)console.error(`Error processing custom directive @${j}:`,N);X.push({original:z,processed:$("CustomDirective",`Error in @${j}${F?`(${F})`:""}: ${w}`,_.EVALUATION_ERROR),startIndex:K})}U=V.exec(H)}for(let z=X.length-1;z>=0;z--){let{original:F,processed:A}=X[z];H=H.replace(F,A)}return H}async function Q(J,L,B,y,G){let{name:j,handler:k}=L,O=J,Y=Z(`@${j}\\s*\\(([^()]*(?:\\([^)]*\\)[^()]*)*)\\)`,"g"),H=[],V=Y.exec(O);while(V!==null){let[z,F=""]=V,A=V.index||0;try{let K=W(F),N=await k("",K,B,y);H.push({original:z,processed:N,startIndex:A})}catch(K){let N=K instanceof Error?K.message:String(K);if(G.debug)console.error(`Error processing custom directive @${j}:`,K);H.push({original:z,processed:$("CustomDirective",`Error in @${j}(${F}): ${N}`,_.EVALUATION_ERROR),startIndex:A})}V=Y.exec(O)}let X=Z(`@${j}(?!\\w)(?!\\s*\\()`,"g"),U=X.exec(O);while(U!==null){let[z]=U,F=U.index||0;try{let A=await k("",[],B,y);H.push({original:z,processed:A,startIndex:F})}catch(A){let K=A instanceof Error?A.message:String(A);if(G.debug)console.error(`Error processing custom directive @${j}:`,A);H.push({original:z,processed:$("CustomDirective",`Error in @${j}: ${K}`,_.EVALUATION_ERROR),startIndex:F})}U=X.exec(O)}for(let z=H.length-1;z>=0;z--){let{original:F,processed:A}=H[z];O=O.replace(F,A)}return O}function W(J){if(!J.trim())return[];let L=[],B="",y=!1,G="";for(let j=0;j<J.length;j++){let k=J[j];if((k==='"'||k==="'")&&(j===0||J[j-1]!=="\\"))if(!y)y=!0,G=k;else if(k===G)y=!1;else B+=k;else if(k===","&&!y)L.push(B.trim()),B="";else B+=k}if(B.trim())L.push(B.trim());return L.map((j)=>{let k=j.trim();if(k.startsWith('"')&&k.endsWith('"')||k.startsWith("'")&&k.endsWith("'"))return k.substring(1,k.length-1);return k})}
3
- export{b as Ax};
2
+ import{Bx as Z}from"./chunk-9ecv8aqj.js";import{py as $}from"./chunk-zen6ax1y.js";import{Ry as _}from"./chunk-27zsyhrd.js";async function b(J,L,B,y){if(!y.customDirectives||y.customDirectives.length===0)return J;let G=J;for(let j of y.customDirectives){if(!j.name||typeof j.handler!=="function"){if(y.debug)console.warn("Invalid custom directive:",j);continue}if(j.hasEndTag)G=await D(G,j,L,B,y);else G=await Q(G,j,L,B,y)}return G}async function D(J,L,B,y,G){let{name:j,handler:k}=L,O=`@${j}`,Y=`@end${j}`,H=J,V=Z(`${O}(?:\\s*\\(([^()]*(?:\\([^)]*\\)[^()]*)*)\\))?([\\s\\S]*?)${Y}`,"g"),X=[],U=V.exec(H);while(U!==null){let[z,F="",A=""]=U,K=U.index||0;try{let N=F?W(F):[],w=A.trim(),q=await k(w,N,B,y);X.push({original:z,processed:q,startIndex:K})}catch(N){let w=N instanceof Error?N.message:String(N);if(G.debug)console.error(`Error processing custom directive @${j}:`,N);X.push({original:z,processed:$("CustomDirective",`Error in @${j}${F?`(${F})`:""}: ${w}`,_.EVALUATION_ERROR),startIndex:K})}U=V.exec(H)}for(let z=X.length-1;z>=0;z--){let{original:F,processed:A}=X[z];H=H.replace(F,A)}return H}async function Q(J,L,B,y,G){let{name:j,handler:k}=L,O=J,Y=Z(`@${j}\\s*\\(([^()]*(?:\\([^)]*\\)[^()]*)*)\\)`,"g"),H=[],V=Y.exec(O);while(V!==null){let[z,F=""]=V,A=V.index||0;try{let K=W(F),N=await k("",K,B,y);H.push({original:z,processed:N,startIndex:A})}catch(K){let N=K instanceof Error?K.message:String(K);if(G.debug)console.error(`Error processing custom directive @${j}:`,K);H.push({original:z,processed:$("CustomDirective",`Error in @${j}(${F}): ${N}`,_.EVALUATION_ERROR),startIndex:A})}V=Y.exec(O)}let X=Z(`@${j}(?!\\w)(?!\\s*\\()`,"g"),U=X.exec(O);while(U!==null){let[z]=U,F=U.index||0;try{let A=await k("",[],B,y);H.push({original:z,processed:A,startIndex:F})}catch(A){let K=A instanceof Error?A.message:String(A);if(G.debug)console.error(`Error processing custom directive @${j}:`,A);H.push({original:z,processed:$("CustomDirective",`Error in @${j}: ${K}`,_.EVALUATION_ERROR),startIndex:F})}U=X.exec(O)}for(let z=H.length-1;z>=0;z--){let{original:F,processed:A}=H[z];O=O.replace(F,A)}return O}function W(J){if(!J.trim())return[];let L=[],B="",y=!1,G="";for(let j=0;j<J.length;j++){let k=J[j];if((k==='"'||k==="'")&&(j===0||J[j-1]!=="\\"))if(!y)y=!0,G=k;else if(k===G)y=!1;else B+=k;else if(k===","&&!y)L.push(B.trim()),B="";else B+=k}if(B.trim())L.push(B.trim());return L.map((j)=>{let k=j.trim();if(k.startsWith('"')&&k.endsWith('"')||k.startsWith("'")&&k.endsWith("'"))return k.substring(1,k.length-1);return k})}
3
+ export{b as zx};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
2
  import D from"process";function F(B="STX_PUBLIC_"){let q={},A={};for(let[z,C]of Object.entries(D.env)){if(!z.startsWith(B)||C===void 0)continue;q[`import.meta.env.${z}`]=JSON.stringify(C),A[z]=C}return q["import.meta.env"]=JSON.stringify(A),q}function H(B="STX_PUBLIC_"){let q={};for(let[A,z]of Object.entries(D.env))if(A.startsWith(B)&&z!==void 0)q[A]=z;return q}
3
- export{F as Vy,H as Wy};
3
+ export{F as Ty,H as Uy};
@@ -106,4 +106,4 @@ else {
106
106
  })();
107
107
  </script>`}function x(q){let j=_(q);if(j.length===0)return{template:q,bindings:[]};let F=q,z=[];for(let J=j.length-1;J>=0;J--){let G=j[J],$=G.originalTag;if(!$.includes(" id="))$=$.replace(/^<([a-z][a-z0-9-]*)/,`<$1 id="${G.elementId}"`);else{let X=$.match(/id=["']([^"']+)["']/);if(X)for(let D of G.events)D.elementId=X[1]}for(let X of G.events){let D=X.attribute.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),V=new RegExp(`\\s*${D}\\s*=\\s*"[^"]*"`,"g"),Z=new RegExp(`\\s*${D}\\s*=\\s*'[^']*'`,"g");$=$.replace(V,""),$=$.replace(Z,"")}F=F.slice(0,G.startIndex)+$+F.slice(G.endIndex),z.push(...G.events)}return{template:F,bindings:z}}function S(q,j,F){if(/\b(?:state|derived|effect)\s*(?:<[^<>()]*>)?\s*\(/.test(q)||/@(?:model|show|for|if)\s*=/.test(q)||/data-stx(?:-auto)?(?![-\w])/.test(q))return q;if(j.__stx_sfc_mode){if(/x-data\s*=\s*["']/.test(q))return q;let{template:D,bindings:V}=x(q),Z=j.__stx_event_bindings||[];return j.__stx_event_bindings=[...Z,...V],D}let J=_(q);if(J.length===0)return q;let G=q;for(let D=J.length-1;D>=0;D--){let V=J[D],Z=V.originalTag;if(!Z.includes(" id="))Z=Z.replace(/^<([a-z][a-z0-9-]*)/,`<$1 id="${V.elementId}"`);else{let K=Z.match(/id=["']([^"']+)["']/);if(K)for(let L of V.events)L.elementId=K[1]}for(let K of V.events){let L=K.attribute.replace(/[.*+?^${}()|[\]\\]/g,"\\$&"),B=new RegExp(`\\s*${L}\\s*=\\s*"[^"]*"`,"g"),Y=new RegExp(`\\s*${L}\\s*=\\s*'[^']*'`,"g");Z=Z.replace(B,""),Z=Z.replace(Y,"")}G=G.slice(0,V.startIndex)+Z+G.slice(V.endIndex)}let $=k(J),X=G.lastIndexOf("</body>");if(X!==-1)G=G.slice(0,X)+$+`
108
108
  `+G.slice(X);else G+=$;return G}function E(q){return/@[a-z]+(?:\.[a-z]+)*\s*=\s*["'][^"']*["']/i.test(q)}
109
- export{x as Lv,S as Mv,E as Nv};
109
+ export{x as Kv,S as Lv,E as Mv};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
- import{Ls as y}from"./chunk-w01y57f5.js";import{et as x}from"./chunk-nap11ntr.js";import{yy as I}from"./chunk-94g3cahw.js";import g from"crypto";import w from"path";class h{store=new Map;async get(B){let U=this.store.get(B);if(!U||U.expires<=Date.now()){if(U)this.store.delete(B);return null}return{...U.data}}async set(B,U,A){this.store.set(B,{data:{...U},expires:Date.now()+A*1000})}async delete(B){this.store.delete(B)}}async function l(B,U,A){let Q={},z={},b=await A.get(B);if(b)Object.assign(Q,b);let E={id:B,data:Q,get(G){return Q[G]},set(G,O){Q[G]=O,W()},delete(G){delete Q[G],W()},clear(){Object.keys(Q).forEach((G)=>delete Q[G]),W()},has(G){return G in Q},flash(G,O){if(O!==void 0){z[G]=O;return}let R=z[G];return delete z[G],R},regenerate(){let G=B;B=u(),E.id=B,A.delete(G),W()},destroy(){A.delete(B),Object.keys(Q).forEach((G)=>delete Q[G])}};function W(){A.set(B,{...Q,__flash:z},U)}return W(),E}function u(){return g.randomBytes(32).toString("hex")}function p(B){if(!B)return{};return B.split(";").reduce((U,A)=>{let[Q,...z]=A.trim().split("=");if(Q)U[Q]=decodeURIComponent(z.join("="));return U},{})}function v(B,U,A={}){let Q=`${encodeURIComponent(B)}=${encodeURIComponent(U)}`;if(A.maxAge!==void 0)Q+=`; Max-Age=${A.maxAge}`;if(A.expires)Q+=`; Expires=${A.expires.toUTCString()}`;if(A.path)Q+=`; Path=${A.path}`;if(A.domain)Q+=`; Domain=${A.domain}`;if(A.secure)Q+="; Secure";if(A.httpOnly)Q+="; HttpOnly";if(A.sameSite)Q+=`; SameSite=${A.sameSite}`;return Q}function d(){return g.randomBytes(32).toString("hex")}function r(B,U){if(!B||!U)return!1;try{return g.timingSafeEqual(Buffer.from(B),Buffer.from(U))}catch{return!1}}async function i(B,U={},A={}){let Q=A.viewsDir||"./views",z=A.layoutsDir||"./layouts",b=!B.includes("<")&&!B.includes("@"),E,W;if(b){if(W=w.resolve(Q,B),!W.endsWith(".stx"))W+=".stx";if(!await Bun.file(W).exists())return new Response(`Template not found: ${B}`,{status:500});E=await Bun.file(W).text()}else E=B,W="inline-template.stx";let G={...U,props:U,__filename:W,__dirname:w.dirname(W)};if(A.ctx)G.csrf_token=A.ctx.csrfToken,G.csrf_field=`<input type="hidden" name="_token" value="${A.ctx.csrfToken}">`,G.old=A.ctx.old,G.errors=A.ctx.errors,G.session=A.ctx.session,G.user=A.ctx.user(),G.isAuthenticated=A.ctx.isAuthenticated();let O=E.match(/<script\s+server\b[^>]*>([\s\S]*?)<\/script>/i);if(O){let H=O[1];E=E.replace(/<script\s+server\b[^>]*>[\s\S]*?<\/script>/gi,""),await x(H,G,W)}let R={layoutsDir:z,...A.stxOptions},P=await y(E,G,W,R,new Set),C=new Headers({"Content-Type":"text/html; charset=utf-8"});if(A.ctx)A.ctx.responseHeaders.forEach((H,T)=>{C.set(T,H)});return new Response(P,{headers:C})}function e(B={}){let{viewsDir:U="./views",layoutsDir:A="./layouts",defaultLayout:Q,sessionSecret:z=g.randomBytes(32).toString("hex"),sessionCookieName:b="stx_session",sessionTtl:E=86400,stxOptions:W={},csrfCookieName:G="csrf_token",csrfEnabled:O=!0}=B,R=B.sessionStore??new h,q=[],P=[];function C(j,J){for(let K of q){if(K.method!==j&&K.method!=="*")continue;let Y=[],V=K.pattern.replace(/\/:(\w+)/g,(Z,X)=>{return Y.push(X),"/([^/]+)"}).replace(/\//g,"\\/"),L=new RegExp(`^${V}$`),_=J.match(L);if(_){let Z={};return Y.forEach((X,N)=>{Z[X]=_[N+1]}),{route:K,params:Z}}}return null}async function H(j,J){let K=new URL(j.url),Y=p(j.headers.get("Cookie")),V=new Headers,L=[],_=Y[b];if(!_)_=u(),L.push(v(b,_,{httpOnly:!0,secure:K.protocol==="https:",sameSite:"Lax",path:"/",maxAge:E}));let Z=await l(_,E,R),X=Z.get("_csrf");if(!X)X=d(),Z.set("_csrf",X);let N={};K.searchParams.forEach(($,F)=>{N[F]=$});let f=Z.flash("_errors")||{},k=Z.flash("_old_input")||{},m={request:j,url:K,params:J,query:N,session:Z,csrfToken:X,cookies:Y,responseHeaders:V,errors:f,async formData(){let $=await j.formData(),F={};return $.forEach((D,c)=>{F[c]=D}),F},async json(){return await j.json()},setCookie($,F,D={}){L.push(v($,F,D))},flash($,F){Z.flash($,F)},getFlash($){return Z.flash($)},old($){return k[$]||""},isAuthenticated(){return Z.has("user")},user(){return Z.get("user")}};if(L.length>0)L.forEach(($)=>{V.append("Set-Cookie",$)});return m}let T=async(j,J)=>{if(["GET","HEAD","OPTIONS"].includes(j.request.method))return J();if(!O)return J();let Y=(await j.request.clone().formData().catch(()=>new FormData)).get("_token"),V=j.request.headers.get("X-CSRF-Token"),L=Y||V,_=j.session.get("_csrf");if(!L||!_||!r(L,_))return new Response("CSRF token mismatch",{status:419});return J()};async function S(j){let J=new URL(j.url),K=j.method,Y=C(K,J.pathname);if(!Y)return new Response("Not Found",{status:404});let V=await H(j,Y.params),L=[...P,T,...Y.route.middleware],_=0,Z=async()=>{if(_<L.length){let X=L[_++];return X(V,Z)}return Y.route.handler(V)};try{let X=await Z();return V.responseHeaders.forEach((N,f)=>{X.headers.set(f,N)}),X}catch(X){return I.log(X instanceof Error?X:Error(String(X)),{handler:"request"},"error"),new Response("Internal Server Error",{status:500})}}function M(j,J,K,Y=[]){q.push({method:j,pattern:J,handler:K,middleware:Y})}return{fetch:S,get(j,J,K=[]){return M("GET",j,J,K),this},post(j,J,K=[]){return M("POST",j,J,K),this},put(j,J,K=[]){return M("PUT",j,J,K),this},delete(j,J,K=[]){return M("DELETE",j,J,K),this},patch(j,J,K=[]){return M("PATCH",j,J,K),this},use(j){return P.push(j),this},async render(j,J={},K){return i(j,J,{viewsDir:U,layoutsDir:A,stxOptions:W,ctx:K})},redirect(j,J=302){return new Response(null,{status:J,headers:{Location:j}})},back(j,J,K){if(J)j.session.flash("_errors",J);if(K)j.session.flash("_old_input",K);let Y=j.request.headers.get("Referer")||"/";return new Response(null,{status:302,headers:{Location:Y}})},listen(j=3000){return Bun.serve({port:j,fetch:S})}}}
3
- export{h as ng,i as og,e as pg};
2
+ import{Ks as y}from"./chunk-1xz0w746.js";import{dt as x}from"./chunk-g1vt329s.js";import{wy as I}from"./chunk-yb1t2h8h.js";import g from"crypto";import w from"path";class h{store=new Map;async get(B){let U=this.store.get(B);if(!U||U.expires<=Date.now()){if(U)this.store.delete(B);return null}return{...U.data}}async set(B,U,A){this.store.set(B,{data:{...U},expires:Date.now()+A*1000})}async delete(B){this.store.delete(B)}}async function l(B,U,A){let Q={},z={},b=await A.get(B);if(b)Object.assign(Q,b);let E={id:B,data:Q,get(G){return Q[G]},set(G,O){Q[G]=O,W()},delete(G){delete Q[G],W()},clear(){Object.keys(Q).forEach((G)=>delete Q[G]),W()},has(G){return G in Q},flash(G,O){if(O!==void 0){z[G]=O;return}let R=z[G];return delete z[G],R},regenerate(){let G=B;B=u(),E.id=B,A.delete(G),W()},destroy(){A.delete(B),Object.keys(Q).forEach((G)=>delete Q[G])}};function W(){A.set(B,{...Q,__flash:z},U)}return W(),E}function u(){return g.randomBytes(32).toString("hex")}function p(B){if(!B)return{};return B.split(";").reduce((U,A)=>{let[Q,...z]=A.trim().split("=");if(Q)U[Q]=decodeURIComponent(z.join("="));return U},{})}function v(B,U,A={}){let Q=`${encodeURIComponent(B)}=${encodeURIComponent(U)}`;if(A.maxAge!==void 0)Q+=`; Max-Age=${A.maxAge}`;if(A.expires)Q+=`; Expires=${A.expires.toUTCString()}`;if(A.path)Q+=`; Path=${A.path}`;if(A.domain)Q+=`; Domain=${A.domain}`;if(A.secure)Q+="; Secure";if(A.httpOnly)Q+="; HttpOnly";if(A.sameSite)Q+=`; SameSite=${A.sameSite}`;return Q}function d(){return g.randomBytes(32).toString("hex")}function r(B,U){if(!B||!U)return!1;try{return g.timingSafeEqual(Buffer.from(B),Buffer.from(U))}catch{return!1}}async function i(B,U={},A={}){let Q=A.viewsDir||"./views",z=A.layoutsDir||"./layouts",b=!B.includes("<")&&!B.includes("@"),E,W;if(b){if(W=w.resolve(Q,B),!W.endsWith(".stx"))W+=".stx";if(!await Bun.file(W).exists())return new Response(`Template not found: ${B}`,{status:500});E=await Bun.file(W).text()}else E=B,W="inline-template.stx";let G={...U,props:U,__filename:W,__dirname:w.dirname(W)};if(A.ctx)G.csrf_token=A.ctx.csrfToken,G.csrf_field=`<input type="hidden" name="_token" value="${A.ctx.csrfToken}">`,G.old=A.ctx.old,G.errors=A.ctx.errors,G.session=A.ctx.session,G.user=A.ctx.user(),G.isAuthenticated=A.ctx.isAuthenticated();let O=E.match(/<script\s+server\b[^>]*>([\s\S]*?)<\/script>/i);if(O){let H=O[1];E=E.replace(/<script\s+server\b[^>]*>[\s\S]*?<\/script>/gi,""),await x(H,G,W)}let R={layoutsDir:z,...A.stxOptions},P=await y(E,G,W,R,new Set),C=new Headers({"Content-Type":"text/html; charset=utf-8"});if(A.ctx)A.ctx.responseHeaders.forEach((H,T)=>{C.set(T,H)});return new Response(P,{headers:C})}function e(B={}){let{viewsDir:U="./views",layoutsDir:A="./layouts",defaultLayout:Q,sessionSecret:z=g.randomBytes(32).toString("hex"),sessionCookieName:b="stx_session",sessionTtl:E=86400,stxOptions:W={},csrfCookieName:G="csrf_token",csrfEnabled:O=!0}=B,R=B.sessionStore??new h,q=[],P=[];function C(j,J){for(let K of q){if(K.method!==j&&K.method!=="*")continue;let Y=[],V=K.pattern.replace(/\/:(\w+)/g,(Z,X)=>{return Y.push(X),"/([^/]+)"}).replace(/\//g,"\\/"),L=new RegExp(`^${V}$`),_=J.match(L);if(_){let Z={};return Y.forEach((X,N)=>{Z[X]=_[N+1]}),{route:K,params:Z}}}return null}async function H(j,J){let K=new URL(j.url),Y=p(j.headers.get("Cookie")),V=new Headers,L=[],_=Y[b];if(!_)_=u(),L.push(v(b,_,{httpOnly:!0,secure:K.protocol==="https:",sameSite:"Lax",path:"/",maxAge:E}));let Z=await l(_,E,R),X=Z.get("_csrf");if(!X)X=d(),Z.set("_csrf",X);let N={};K.searchParams.forEach(($,F)=>{N[F]=$});let f=Z.flash("_errors")||{},k=Z.flash("_old_input")||{},m={request:j,url:K,params:J,query:N,session:Z,csrfToken:X,cookies:Y,responseHeaders:V,errors:f,async formData(){let $=await j.formData(),F={};return $.forEach((D,c)=>{F[c]=D}),F},async json(){return await j.json()},setCookie($,F,D={}){L.push(v($,F,D))},flash($,F){Z.flash($,F)},getFlash($){return Z.flash($)},old($){return k[$]||""},isAuthenticated(){return Z.has("user")},user(){return Z.get("user")}};if(L.length>0)L.forEach(($)=>{V.append("Set-Cookie",$)});return m}let T=async(j,J)=>{if(["GET","HEAD","OPTIONS"].includes(j.request.method))return J();if(!O)return J();let Y=(await j.request.clone().formData().catch(()=>new FormData)).get("_token"),V=j.request.headers.get("X-CSRF-Token"),L=Y||V,_=j.session.get("_csrf");if(!L||!_||!r(L,_))return new Response("CSRF token mismatch",{status:419});return J()};async function S(j){let J=new URL(j.url),K=j.method,Y=C(K,J.pathname);if(!Y)return new Response("Not Found",{status:404});let V=await H(j,Y.params),L=[...P,T,...Y.route.middleware],_=0,Z=async()=>{if(_<L.length){let X=L[_++];return X(V,Z)}return Y.route.handler(V)};try{let X=await Z();return V.responseHeaders.forEach((N,f)=>{X.headers.set(f,N)}),X}catch(X){return I.log(X instanceof Error?X:Error(String(X)),{handler:"request"},"error"),new Response("Internal Server Error",{status:500})}}function M(j,J,K,Y=[]){q.push({method:j,pattern:J,handler:K,middleware:Y})}return{fetch:S,get(j,J,K=[]){return M("GET",j,J,K),this},post(j,J,K=[]){return M("POST",j,J,K),this},put(j,J,K=[]){return M("PUT",j,J,K),this},delete(j,J,K=[]){return M("DELETE",j,J,K),this},patch(j,J,K=[]){return M("PATCH",j,J,K),this},use(j){return P.push(j),this},async render(j,J={},K){return i(j,J,{viewsDir:U,layoutsDir:A,stxOptions:W,ctx:K})},redirect(j,J=302){return new Response(null,{status:J,headers:{Location:j}})},back(j,J,K){if(J)j.session.flash("_errors",J);if(K)j.session.flash("_old_input",K);let Y=j.request.headers.get("Referer")||"/";return new Response(null,{status:302,headers:{Location:Y}})},listen(j=3000){return Bun.serve({port:j,fetch:S})}}}
3
+ export{h as qg,i as rg,e as sg};
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import{et as _}from"./chunk-nap11ntr.js";import{rB as M}from"./chunk-3jm3snz8.js";import X from"fs";var U=new Map;async function Z(z,q,A={}){let B=performance.now(),J=[];try{let K=await X.promises.stat(q),O=U.get(q),N;if(O&&O.mtime===K.mtimeMs)N=O.content;else N=await X.promises.readFile(q,"utf-8"),U.set(q,{content:N,mtime:K.mtimeMs,analyzed:null});let{processDirectives:G}=await import("././process.js"),Q={},L=Y(N);if(L)try{await _(L,Q,q)}catch($){J.push(`Warning: Could not extract script variables: ${$ instanceof Error?$.message:String($)}`)}if(A.props)Object.assign(Q,A.props);let W=await G(N,Q,q,{},new Set),F=D(N),b=Y(N);return W=j(W),W=E(W,Q),{html:W,css:F,js:b,errors:J,duration:performance.now()-B}}catch(K){return J.push(K instanceof Error?K.message:String(K)),{html:`<div class="stx-render-error">${k(J[0])}</div>`,css:"",js:"",errors:J,duration:performance.now()-B}}}async function w(z){try{let q=await X.promises.readFile(z,"utf-8"),A=Y(q);if(!A)return null;let B={};if(await _(A,B,z),Array.isArray(B.variants))return B.variants;return null}catch{return null}}async function T(z,q,A,B){let J=q.story?.variants;if(!J){let N=await w(q.path);if(N)J=N}if(!J&&A==="default")return Z(z,q.path,{props:B||{}});if(!J)return Z(z,q.path,{props:B||{}});let K=J.find((N)=>N.id===A);if(!K&&A==="default")return Z(z,q.path,{props:B||{}});if(!K)return{html:'<div class="stx-render-error">Variant not found</div>',css:"",js:"",errors:[`Variant '${A}' not found`],duration:0};let O={...K.state,...B};if(K.source)return R(z,K.source,O);return Z(z,q.path,{props:O})}async function R(z,q,A={}){let B=performance.now(),J=[];try{let{processDirectives:K}=await import("././process.js"),O={...A},N=Y(q);if(N)try{await _(N,O,"inline-template.stx")}catch{}let Q=await K(q,O,"inline-template.stx",{},new Set);return Q=j(Q),Q=E(Q,O),{html:Q,css:D(q),js:Y(q),errors:J,duration:performance.now()-B}}catch(K){return J.push(K instanceof Error?K.message:String(K)),{html:`<div class="stx-render-error">${k(J[0])}</div>`,css:"",js:"",errors:J,duration:performance.now()-B}}}function D(z){let q=[],A=/<style\b[^>]*>([\s\S]*?)<\/style>/gi,B=A.exec(z);while(B!==null)q.push(B[1].trim()),B=A.exec(z);return q.join(`
2
+ import{dt as _}from"./chunk-g1vt329s.js";import{pB as M}from"./chunk-xv34zbp4.js";import X from"fs";var U=new Map;async function Z(z,q,A={}){let B=performance.now(),J=[];try{let K=await X.promises.stat(q),O=U.get(q),N;if(O&&O.mtime===K.mtimeMs)N=O.content;else N=await X.promises.readFile(q,"utf-8"),U.set(q,{content:N,mtime:K.mtimeMs,analyzed:null});let{processDirectives:G}=await import("././process.js"),Q={},L=Y(N);if(L)try{await _(L,Q,q)}catch($){J.push(`Warning: Could not extract script variables: ${$ instanceof Error?$.message:String($)}`)}if(A.props)Object.assign(Q,A.props);let W=await G(N,Q,q,{},new Set),F=D(N),b=Y(N);return W=j(W),W=E(W,Q),{html:W,css:F,js:b,errors:J,duration:performance.now()-B}}catch(K){return J.push(K instanceof Error?K.message:String(K)),{html:`<div class="stx-render-error">${k(J[0])}</div>`,css:"",js:"",errors:J,duration:performance.now()-B}}}async function w(z){try{let q=await X.promises.readFile(z,"utf-8"),A=Y(q);if(!A)return null;let B={};if(await _(A,B,z),Array.isArray(B.variants))return B.variants;return null}catch{return null}}async function T(z,q,A,B){let J=q.story?.variants;if(!J){let N=await w(q.path);if(N)J=N}if(!J&&A==="default")return Z(z,q.path,{props:B||{}});if(!J)return Z(z,q.path,{props:B||{}});let K=J.find((N)=>N.id===A);if(!K&&A==="default")return Z(z,q.path,{props:B||{}});if(!K)return{html:'<div class="stx-render-error">Variant not found</div>',css:"",js:"",errors:[`Variant '${A}' not found`],duration:0};let O={...K.state,...B};if(K.source)return R(z,K.source,O);return Z(z,q.path,{props:O})}async function R(z,q,A={}){let B=performance.now(),J=[];try{let{processDirectives:K}=await import("././process.js"),O={...A},N=Y(q);if(N)try{await _(N,O,"inline-template.stx")}catch{}let Q=await K(q,O,"inline-template.stx",{},new Set);return Q=j(Q),Q=E(Q,O),{html:Q,css:D(q),js:Y(q),errors:J,duration:performance.now()-B}}catch(K){return J.push(K instanceof Error?K.message:String(K)),{html:`<div class="stx-render-error">${k(J[0])}</div>`,css:"",js:"",errors:J,duration:performance.now()-B}}}function D(z){let q=[],A=/<style\b[^>]*>([\s\S]*?)<\/style>/gi,B=A.exec(z);while(B!==null)q.push(B[1].trim()),B=A.exec(z);return q.join(`
3
3
  `)}function j(z){return z.replace(/<!--[\s\S]*?-->/g,"").replace(/<style\b[^>]*>[\s\S]*?<\/style>/gi,"").replace(/<script\b[^>]*>[\s\S]*?<\/script>/gi,"").replace(/^\s*\n/gm,"").trim()}function Y(z){let q=[],A=/<script\b[^>]*>([\s\S]*?)<\/script>/gi,B=A.exec(z);while(B!==null)q.push(B[1].trim()),B=A.exec(z);return q.join(`
4
4
  `)}function E(z,q){let A=`<script>window.__stxProps = ${JSON.stringify(q)};</script>`;return z+A}function k(z){return z.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;")}function g(){U.clear()}function u(){return{size:U.size,entries:Array.from(U.keys())}}async function I(z){let q=0;for(let A of z)try{let B=await X.promises.stat(A),J=await X.promises.readFile(A,"utf-8");U.set(A,{content:J,mtime:B.mtimeMs,analyzed:null}),q++}catch{}return q}function S(z,q={}){let{title:A="Preview",theme:B="light",background:J="#ffffff",crosswindCss:K=""}=q;return`<!DOCTYPE html>
5
5
  <html lang="en" class="${B==="dark"?"dark":""}">
@@ -1,3 +1,3 @@
1
1
  // @bun
2
2
  import y from"fs";import z from"path";function C(q,j,g){return{version:1,buildTime:new Date().toISOString(),routes:q,assets:j,outputDir:g}}function E(q,j){let g=z.join(j,"manifest.json");y.writeFileSync(g,JSON.stringify(q,null,2))}function F(q){let j=z.join(q,"manifest.json");if(!y.existsSync(j))return null;try{let g=y.readFileSync(j,"utf-8"),w=JSON.parse(g);if(w.version!==1)return console.warn(`[stx] Manifest version mismatch: expected 1, got ${w.version}`),null;return w}catch(g){return console.warn("[stx] Failed to load manifest:",g),null}}
3
- export{C as Yk,E as Zk,F as _k};
3
+ export{C as $k,E as al,F as bl};
@@ -1,4 +1,4 @@
1
1
  // @bun
2
- import{rB as v}from"./chunk-3jm3snz8.js";import Z from"fs";import Q from"path";var F=[72,96,128,144,152,192,384,512],L=[120,152,167,180],T=[16,32];async function A(R,w){let j={success:!0,generatedFiles:[],errors:[],warnings:[]},J=R.pwa?.icons;if(!J?.src)return j.errors.push("No source icon specified in pwa.icons.src"),j.success=!1,j;let G=Q.isAbsolute(J.src)?J.src:Q.resolve(process.cwd(),J.src);if(!await Bun.file(G).exists())return j.errors.push(`Source icon not found: ${G}`),j.success=!1,j;let q=Q.resolve(w,J.outputDir||"pwa-icons");try{Z.mkdirSync(q,{recursive:!0})}catch{return j.errors.push(`Failed to create output directory: ${q}`),j.success=!1,j}let y=J.sizes||F,U=J.generateWebP??!0,N=J.generateAppleIcons??!0;try{let B;try{B=await import("sharp")}catch{return j.errors.push(`sharp is not installed. Install it with: bun add sharp
2
+ import{pB as v}from"./chunk-xv34zbp4.js";import Z from"fs";import Q from"path";var F=[72,96,128,144,152,192,384,512],L=[120,152,167,180],T=[16,32];async function A(R,w){let j={success:!0,generatedFiles:[],errors:[],warnings:[]},J=R.pwa?.icons;if(!J?.src)return j.errors.push("No source icon specified in pwa.icons.src"),j.success=!1,j;let G=Q.isAbsolute(J.src)?J.src:Q.resolve(process.cwd(),J.src);if(!await Bun.file(G).exists())return j.errors.push(`Source icon not found: ${G}`),j.success=!1,j;let q=Q.resolve(w,J.outputDir||"pwa-icons");try{Z.mkdirSync(q,{recursive:!0})}catch{return j.errors.push(`Failed to create output directory: ${q}`),j.success=!1,j}let y=J.sizes||F,U=J.generateWebP??!0,N=J.generateAppleIcons??!0;try{let B;try{B=await import("sharp")}catch{return j.errors.push(`sharp is not installed. Install it with: bun add sharp
3
3
  Icon generation requires the sharp package for image processing.`),j.success=!1,j}let $=await B.default(G).metadata();if($.width&&$.width<512)j.warnings.push(`Source icon is ${$.width}x${$.height}. Recommend using at least 512x512 for best quality.`);for(let x of y){let K=Q.join(q,`icon-${x}x${x}.png`);if(await B.default(G).resize(x,x,{fit:"contain",background:{r:0,g:0,b:0,alpha:0}}).png().toFile(K),j.generatedFiles.push(K),U){let Y=Q.join(q,`icon-${x}x${x}.webp`);await B.default(G).resize(x,x,{fit:"contain",background:{r:0,g:0,b:0,alpha:0}}).webp({quality:90}).toFile(Y),j.generatedFiles.push(Y)}}if(N){for(let K of L){let Y=Q.join(q,`apple-touch-icon-${K}x${K}.png`);await B.default(G).resize(K,K,{fit:"contain",background:{r:255,g:255,b:255,alpha:1}}).png().toFile(Y),j.generatedFiles.push(Y)}let x=Q.join(q,"apple-touch-icon.png");await B.default(G).resize(180,180,{fit:"contain",background:{r:255,g:255,b:255,alpha:1}}).png().toFile(x),j.generatedFiles.push(x)}for(let x of T){let K=Q.join(q,`favicon-${x}x${x}.png`);await B.default(G).resize(x,x,{fit:"contain",background:{r:0,g:0,b:0,alpha:0}}).png().toFile(K),j.generatedFiles.push(K)}let M=512,V=Q.join(q,`icon-maskable-${M}x${M}.png`),X=Math.floor(M*0.1),W=M-X*2;await B.default(G).resize(W,W,{fit:"contain",background:{r:0,g:0,b:0,alpha:0}}).extend({top:X,bottom:X,left:X,right:X,background:{r:255,g:255,b:255,alpha:1}}).png().toFile(V),j.generatedFiles.push(V)}catch(B){let H=B instanceof Error?B.message:String(B);j.errors.push(`Icon generation failed: ${H}`),j.success=!1}return j}function E(R){let w=R.sizes||F,j=R.outputDir?`/${R.outputDir}`:"/pwa-icons",J=R.generateWebP??!0,G=R.generateAppleIcons??!0,q=[];for(let y of w)if(q.push(`${j}/icon-${y}x${y}.png`),J)q.push(`${j}/icon-${y}x${y}.webp`);if(G){q.push(`${j}/apple-touch-icon.png`);for(let y of L)q.push(`${j}/apple-touch-icon-${y}x${y}.png`)}for(let y of T)q.push(`${j}/favicon-${y}x${y}.png`);return q.push(`${j}/icon-maskable-512x512.png`),q}async function b(){try{return await import("sharp"),!0}catch{return!1}}
4
4
  export{F as Be,L as Ce,T as De,A as Ee,E as Fe,b as Ge};
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import{Wb as T,Xb as S,Yb as u}from"./chunk-fzm3y0r3.js";import{cc as M}from"./chunk-jjamhxpm.js";import{dc as g}from"./chunk-h5wa62ek.js";import{ic as k}from"./chunk-52agge4n.js";import{oc as P,qc as U,rc as F,sc as w,xc as H}from"./chunk-s6ja2bdg.js";import{yc as v}from"./chunk-55yp0q8t.js";import{fd as L,hd as C}from"./chunk-bpgg59wa.js";import{jd as A}from"./chunk-y0qg6rrv.js";import{Fd as R}from"./chunk-hxx3za24.js";import{Ud as I}from"./chunk-pg1fvqb9.js";import{ge as W,he as _}from"./chunk-0qnz93q2.js";import{rB as f}from"./chunk-3jm3snz8.js";async function a(E,z){let J=await L(E);W(E,J);let $=A(E.config,J);_(E,$),console.log(` Found ${J.length} story files`);let X=typeof z.host==="string"?z.host:z.host===!0?"0.0.0.0":"localhost",Y=new g(E.root),O=new I(E.root),j=new R(E.root),D=P(),Z=Bun.serve({port:z.port,hostname:X,fetch:async(K,Q)=>{let B=new URL(K.url).pathname;if(B==="/__hmr"){if(Q.upgrade(K,{data:{isHmr:!0}}))return;return new Response("WebSocket upgrade failed",{status:400})}if(B.startsWith("/api/"))return q(E,B,K,{presetsManager:Y,bookmarksManager:O,analyticsTracker:j});return b(E,B,z.port)},websocket:{open(K){D.open(K)},close(K){D.close(K)},message(K,Q){D.message(K,Q)}}}),G=`http://${X}:${z.port}`,V=C(E,async(K,Q)=>{console.log(` [${K}] ${Q.relativePath}`);let N=await L(E);W(E,N);let B=A(E.config,N);if(_(E,B),K==="add")F(Q.id,{fileName:Q.fileName});else if(K==="unlink")w(Q.id);else U(Q.id,{fileName:Q.fileName})});if(z.open){let K=G;try{let{exec:Q}=await import("child_process"),N=process.platform;Q(`${N==="darwin"?"open":N==="win32"?"start":"xdg-open"} ${K}`)}catch{}}return{server:Z,url:G,close:async()=>{V(),Z.stop()}}}async function q(E,z,J,$){let{presetsManager:X,bookmarksManager:Y,analyticsTracker:O}=$;if(z==="/api/stories")return Response.json({files:E.storyFiles.map((j)=>({id:j.id,fileName:j.fileName,relativePath:j.relativePath,treePath:j.treePath})),tree:E.tree});if(z.startsWith("/api/story/")){let j=z.slice(11),D=E.storyFiles.find((Z)=>Z.id===j);if(!D)return new Response("Story not found",{status:404});try{let Z=await Bun.file(D.path).text();return Response.json({id:D.id,fileName:D.fileName,relativePath:D.relativePath,content:Z})}catch{return new Response("Error reading story",{status:500})}}if(z==="/api/config")return Response.json({theme:E.config.theme,responsivePresets:E.config.responsivePresets,backgroundPresets:E.config.backgroundPresets});if(z.startsWith("/api/render/")){let j=new URL(J.url),D=z.slice(12).split("/"),Z=D[0],G=D[1]||"default",V,K=j.searchParams.get("props");if(K)try{V=JSON.parse(K)}catch{}let Q=E.storyFiles.find((N)=>N.id===Z);if(!Q)return new Response("Story not found",{status:404});try{let N=await k(E,Q,G,V);return Response.json({html:N.html,css:N.css,js:N.js,errors:N.errors,duration:N.duration})}catch(N){return Response.json({html:"",css:"",js:"",errors:[N instanceof Error?N.message:String(N)],duration:0},{status:500})}}if(z==="/api/presets"&&J.method==="GET")return Response.json({presets:X.getAllPresets()});if(z==="/api/presets"&&J.method==="POST")try{let j=await J.json(),D=X.createPreset(j.name,j.props,{componentId:j.componentId,description:j.description});return await X.save(),Response.json(D)}catch(j){return Response.json({error:String(j)},{status:400})}if(z.startsWith("/api/presets/")&&!z.includes("/use")&&J.method==="GET"){let j=z.slice(13),D=X.getPreset(j);if(!D)return new Response("Preset not found",{status:404});return Response.json(D)}if(z.endsWith("/use")&&J.method==="POST"){let j=z.slice(13,-4),D=X.usePreset(j);if(!D)return new Response("Preset not found",{status:404});return await X.save(),Response.json(D)}if(z.startsWith("/api/presets/")&&J.method==="DELETE"){let j=z.slice(13);if(!X.deletePreset(j))return new Response("Preset not found",{status:404});return await X.save(),Response.json({success:!0})}if(z==="/api/bookmarks"&&J.method==="GET")return Response.json({bookmarks:Y.getAllBookmarks()});if(z==="/api/bookmarks"&&J.method==="POST")try{let j=await J.json(),D=Y.addBookmark(j.storyId,j.variantId,j.props,{name:j.name,notes:j.notes,color:j.color});return await Y.save(),Response.json(D)}catch(j){return Response.json({error:String(j)},{status:400})}if(z==="/api/bookmarks/toggle"&&J.method==="POST")try{let j=await J.json(),D=Y.toggleBookmark(j.storyId,j.variantId,j.props);return await Y.save(),Response.json(D)}catch(j){return Response.json({error:String(j)},{status:400})}if(z.startsWith("/api/bookmarks/")&&z!=="/api/bookmarks/toggle"&&J.method==="GET"){let j=z.slice(15),D=Y.getBookmark(j);if(!D)return new Response("Bookmark not found",{status:404});return Response.json(D)}if(z.startsWith("/api/bookmarks/")&&J.method==="DELETE"){let j=z.slice(15);if(!Y.deleteBookmark(j))return new Response("Bookmark not found",{status:404});return await Y.save(),Response.json({success:!0})}if(z==="/api/analytics/track"&&J.method==="POST")try{let j=await J.json();if(j.type==="view"&&j.componentId)O.trackView(j.componentId,j.variantId);else if(j.type==="prop_change"&&j.componentId&&j.propName)O.trackPropChange(j.componentId,j.propName,null);else if(j.type==="variant_switch"&&j.componentId&&j.variantId)O.trackVariantSwitch(j.componentId,j.variantId);else if(j.type==="search"&&j.query)O.trackSearch(j.query,0);return await O.save(),Response.json({success:!0})}catch(j){return Response.json({error:String(j)},{status:400})}if(z==="/api/analytics/summary"&&J.method==="GET")return Response.json({mostViewed:O.getMostViewedComponents(10),mostChangedProps:O.getMostChangedProps(10),searchAnalytics:O.getSearchAnalytics()});if(z.startsWith("/api/analytics/component/")&&J.method==="GET"){let j=z.slice(25),D=E.storyFiles.find((G)=>G.id===j),Z=O.getComponentAnalytics(j,D?.fileName||j);return Response.json(Z)}return new Response("Not found",{status:404})}function b(E,z,J){let $=x(E,J);return new Response($,{headers:{"Content-Type":"text/html; charset=utf-8"}})}function x(E,z){let{theme:J}=E.config,$=J.title||"STX Story",X=`ws://localhost:${z}/__hmr`,Y=H(X);return`<!DOCTYPE html>
2
+ import{Wb as T,Xb as S,Yb as u}from"./chunk-fzm3y0r3.js";import{cc as M}from"./chunk-jjamhxpm.js";import{dc as g}from"./chunk-h5wa62ek.js";import{ic as k}from"./chunk-7n8g0nfn.js";import{oc as P,qc as U,rc as F,sc as w,xc as H}from"./chunk-s6ja2bdg.js";import{yc as v}from"./chunk-55yp0q8t.js";import{fd as L,hd as C}from"./chunk-bpgg59wa.js";import{jd as A}from"./chunk-y0qg6rrv.js";import{Fd as R}from"./chunk-hxx3za24.js";import{Ud as I}from"./chunk-pg1fvqb9.js";import{ge as W,he as _}from"./chunk-0qnz93q2.js";import{pB as f}from"./chunk-xv34zbp4.js";async function a(E,z){let J=await L(E);W(E,J);let $=A(E.config,J);_(E,$),console.log(` Found ${J.length} story files`);let X=typeof z.host==="string"?z.host:z.host===!0?"0.0.0.0":"localhost",Y=new g(E.root),O=new I(E.root),j=new R(E.root),D=P(),Z=Bun.serve({port:z.port,hostname:X,fetch:async(K,Q)=>{let B=new URL(K.url).pathname;if(B==="/__hmr"){if(Q.upgrade(K,{data:{isHmr:!0}}))return;return new Response("WebSocket upgrade failed",{status:400})}if(B.startsWith("/api/"))return q(E,B,K,{presetsManager:Y,bookmarksManager:O,analyticsTracker:j});return b(E,B,z.port)},websocket:{open(K){D.open(K)},close(K){D.close(K)},message(K,Q){D.message(K,Q)}}}),G=`http://${X}:${z.port}`,V=C(E,async(K,Q)=>{console.log(` [${K}] ${Q.relativePath}`);let N=await L(E);W(E,N);let B=A(E.config,N);if(_(E,B),K==="add")F(Q.id,{fileName:Q.fileName});else if(K==="unlink")w(Q.id);else U(Q.id,{fileName:Q.fileName})});if(z.open){let K=G;try{let{exec:Q}=await import("child_process"),N=process.platform;Q(`${N==="darwin"?"open":N==="win32"?"start":"xdg-open"} ${K}`)}catch{}}return{server:Z,url:G,close:async()=>{V(),Z.stop()}}}async function q(E,z,J,$){let{presetsManager:X,bookmarksManager:Y,analyticsTracker:O}=$;if(z==="/api/stories")return Response.json({files:E.storyFiles.map((j)=>({id:j.id,fileName:j.fileName,relativePath:j.relativePath,treePath:j.treePath})),tree:E.tree});if(z.startsWith("/api/story/")){let j=z.slice(11),D=E.storyFiles.find((Z)=>Z.id===j);if(!D)return new Response("Story not found",{status:404});try{let Z=await Bun.file(D.path).text();return Response.json({id:D.id,fileName:D.fileName,relativePath:D.relativePath,content:Z})}catch{return new Response("Error reading story",{status:500})}}if(z==="/api/config")return Response.json({theme:E.config.theme,responsivePresets:E.config.responsivePresets,backgroundPresets:E.config.backgroundPresets});if(z.startsWith("/api/render/")){let j=new URL(J.url),D=z.slice(12).split("/"),Z=D[0],G=D[1]||"default",V,K=j.searchParams.get("props");if(K)try{V=JSON.parse(K)}catch{}let Q=E.storyFiles.find((N)=>N.id===Z);if(!Q)return new Response("Story not found",{status:404});try{let N=await k(E,Q,G,V);return Response.json({html:N.html,css:N.css,js:N.js,errors:N.errors,duration:N.duration})}catch(N){return Response.json({html:"",css:"",js:"",errors:[N instanceof Error?N.message:String(N)],duration:0},{status:500})}}if(z==="/api/presets"&&J.method==="GET")return Response.json({presets:X.getAllPresets()});if(z==="/api/presets"&&J.method==="POST")try{let j=await J.json(),D=X.createPreset(j.name,j.props,{componentId:j.componentId,description:j.description});return await X.save(),Response.json(D)}catch(j){return Response.json({error:String(j)},{status:400})}if(z.startsWith("/api/presets/")&&!z.includes("/use")&&J.method==="GET"){let j=z.slice(13),D=X.getPreset(j);if(!D)return new Response("Preset not found",{status:404});return Response.json(D)}if(z.endsWith("/use")&&J.method==="POST"){let j=z.slice(13,-4),D=X.usePreset(j);if(!D)return new Response("Preset not found",{status:404});return await X.save(),Response.json(D)}if(z.startsWith("/api/presets/")&&J.method==="DELETE"){let j=z.slice(13);if(!X.deletePreset(j))return new Response("Preset not found",{status:404});return await X.save(),Response.json({success:!0})}if(z==="/api/bookmarks"&&J.method==="GET")return Response.json({bookmarks:Y.getAllBookmarks()});if(z==="/api/bookmarks"&&J.method==="POST")try{let j=await J.json(),D=Y.addBookmark(j.storyId,j.variantId,j.props,{name:j.name,notes:j.notes,color:j.color});return await Y.save(),Response.json(D)}catch(j){return Response.json({error:String(j)},{status:400})}if(z==="/api/bookmarks/toggle"&&J.method==="POST")try{let j=await J.json(),D=Y.toggleBookmark(j.storyId,j.variantId,j.props);return await Y.save(),Response.json(D)}catch(j){return Response.json({error:String(j)},{status:400})}if(z.startsWith("/api/bookmarks/")&&z!=="/api/bookmarks/toggle"&&J.method==="GET"){let j=z.slice(15),D=Y.getBookmark(j);if(!D)return new Response("Bookmark not found",{status:404});return Response.json(D)}if(z.startsWith("/api/bookmarks/")&&J.method==="DELETE"){let j=z.slice(15);if(!Y.deleteBookmark(j))return new Response("Bookmark not found",{status:404});return await Y.save(),Response.json({success:!0})}if(z==="/api/analytics/track"&&J.method==="POST")try{let j=await J.json();if(j.type==="view"&&j.componentId)O.trackView(j.componentId,j.variantId);else if(j.type==="prop_change"&&j.componentId&&j.propName)O.trackPropChange(j.componentId,j.propName,null);else if(j.type==="variant_switch"&&j.componentId&&j.variantId)O.trackVariantSwitch(j.componentId,j.variantId);else if(j.type==="search"&&j.query)O.trackSearch(j.query,0);return await O.save(),Response.json({success:!0})}catch(j){return Response.json({error:String(j)},{status:400})}if(z==="/api/analytics/summary"&&J.method==="GET")return Response.json({mostViewed:O.getMostViewedComponents(10),mostChangedProps:O.getMostChangedProps(10),searchAnalytics:O.getSearchAnalytics()});if(z.startsWith("/api/analytics/component/")&&J.method==="GET"){let j=z.slice(25),D=E.storyFiles.find((G)=>G.id===j),Z=O.getComponentAnalytics(j,D?.fileName||j);return Response.json(Z)}return new Response("Not found",{status:404})}function b(E,z,J){let $=x(E,J);return new Response($,{headers:{"Content-Type":"text/html; charset=utf-8"}})}function x(E,z){let{theme:J}=E.config,$=J.title||"STX Story",X=`ws://localhost:${z}/__hmr`,Y=H(X);return`<!DOCTYPE html>
3
3
  <html lang="en" class="${J.darkClass||"dark"}">
4
4
  <head>
5
5
  <meta charset="UTF-8">
@@ -5,4 +5,4 @@ var Y=[{pattern:/document\.getElementById\s*\(/g,message:"document.getElementByI
5
5
  ${G.join(`
6
6
  `)}
7
7
  Tip: prefer useRef(), navigate(), and composables for component code`;if(z.failOnViolation)throw Error(k);else console.warn(k)}}
8
- export{Y as vt,Z as wt};
8
+ export{Y as ut,Z as vt};
@@ -1,4 +1,4 @@
1
1
  // @bun
2
- import{Ci as S}from"./chunk-bjnjpsgn.js";import{Di as g}from"./chunk-2w3302dh.js";import{Yk as A,Zk as D}from"./chunk-cn409b69.js";import{$p as P,_p as C}from"./chunk-y4c744dk.js";import{Oq as f}from"./chunk-ncnfa8ae.js";import{Sr as R}from"./chunk-w01y57f5.js";import{Iw as b}from"./chunk-y25pr13j.js";import{Sw as y}from"./chunk-q6h6yvzb.js";import V from"fs";import H from"path";var d=new Set([".DS_Store","Thumbs.db","desktop.ini",".gitkeep",".gitignore"]);function n(J,K){let X=0,z=0;if(!V.existsSync(J))return{copied:X,bytes:z};function Q(E,O){let U=V.readdirSync(E,{withFileTypes:!0});for(let W of U){if(d.has(W.name))continue;let G=H.join(E,W.name),Y=H.join(O,W.name);if(W.isDirectory())V.mkdirSync(Y,{recursive:!0}),Q(G,Y);else if(W.isFile()){if(V.existsSync(Y))continue;V.copyFileSync(G,Y),X++,z+=V.statSync(Y).size}}}return Q(J,K),{copied:X,bytes:z}}async function zq(J={}){let K=Date.now(),X=H.resolve(J.root||process.cwd()),z=H.resolve(X,J.outputDir||".output");console.log("[stx build] Starting production build...");let Q={};try{Q=await R()}catch{}let E=J.componentsDir??Q.componentsDir??"components",O=J.partialsDir??Q.partialsDir??"partials",U=J.layoutsDir??Q.layoutsDir??"layouts",W=J.publicDir??Q.publicDir??"public",G=Q.app?.head||{},Y=Q.router?.container||"main";if(V.existsSync(z))V.rmSync(z,{recursive:!0});let h=[H.join(z,"public","__stx"),H.join(z,"public","assets"),H.join(z,"server","pages"),H.join(z,"server","fragments")];for(let F of h)V.mkdirSync(F,{recursive:!0});console.log("[stx build] Discovering routes...");let I=g(X),m=["components","layouts","partials"],k=I.filter((F)=>{return!m.some((q)=>F.pattern.startsWith(`/${q}/`)||F.pattern===`/${q}`)});console.log(`[stx build] Found ${k.length} page routes (${I.length-k.length} non-page files excluded)`),console.log("[stx build] Generating shared assets...");let $=C(J.debug),Z=P();await Bun.write(H.join(z,"public","__stx",$.filename),$.content),await Bun.write(H.join(z,"public","__stx",Z.filename),Z.content),console.log(`[stx build] Runtime: ${$.filename} (${($.content.length/1024).toFixed(1)}KB)`),console.log(`[stx build] Router: ${Z.filename} (${(Z.content.length/1024).toFixed(1)}KB)`),console.log("[stx build] Compiling templates...");let v=[],N=[];for(let F of k)try{let q=await S(F.filePath,F.pattern,{componentsDir:E,partialsDir:O,layoutsDir:U,debug:J.debug});if(v.push(q),q.html=q.html.replace(/runtime\.__STX_HASH__\.js/g,$.filename).replace(/router\.__STX_HASH__\.js/g,Z.filename),q.html=b(q.html,G,{bodyScripts:[`<script src="/__stx/${Z.filename}"></script>`]}),!/<body[^>]*\bdata-stx=/.test(q.html)){let B=q.html.match(/<(?!body\b)[a-zA-Z][a-zA-Z0-9-]*\b[^>]*?\s(data-stx="[^"]+")[^>]*>/);if(B&&B[1]){let x=B[1];q.html=q.html.replace(" "+x,""),q.html=q.html.replace(/<body([^>]*)>/,`<body$1 ${x}>`)}}q.html=q.html.replace(/<style data-crosswind="generated">[\s\S]*?<\/style>\s*/g,""),q.html=await y(q.html),q.fragment=f(q.html,Y);let w=F.pattern==="/"?"index":F.pattern.slice(1).replace(/\//g,"-").replace(/[[\]]/g,"_"),M=H.join("server","pages",`${w}.compiled.json`),j=H.join("server","fragments",`${w}.html`);await Bun.write(H.join(z,M),JSON.stringify(q,null,2)),await Bun.write(H.join(z,j),q.fragment),N.push({pattern:F.pattern,compiledPath:M,fragmentPath:j,isDynamic:q.hasServerScripts,hasParams:F.pattern.includes(":")||F.pattern.includes("[")}),console.log(`[stx build] \u2713 ${F.pattern}`)}catch(q){console.error(`[stx build] \u2717 ${F.pattern}:`,q instanceof Error?q.message:q)}let _=H.resolve(X,W);if(V.existsSync(_)){let{copied:F,bytes:q}=n(_,H.join(z,"public"));if(F>0)console.log(`[stx build] Copied ${F} public asset${F===1?"":"s"} (${(q/1024).toFixed(1)}KB) from ${W}/`)}let L={runtime:$.filename,router:Z.filename},l=A(N,L,z);D(l,z);let T=Date.now()-K;return console.log(`
2
+ import{Fi as S}from"./chunk-kdfe4t91.js";import{Gi as g}from"./chunk-t0c9wvpr.js";import{$k as A,al as D}from"./chunk-80g54ncj.js";import{Zp as C,_p as P}from"./chunk-rvptcndz.js";import{Nq as f}from"./chunk-d0zjtdw4.js";import{Rr as R}from"./chunk-1xz0w746.js";import{Hw as b}from"./chunk-nhv099jv.js";import{Rw as y}from"./chunk-shv88d2d.js";import V from"fs";import H from"path";var d=new Set([".DS_Store","Thumbs.db","desktop.ini",".gitkeep",".gitignore"]);function n(J,K){let X=0,z=0;if(!V.existsSync(J))return{copied:X,bytes:z};function Q(E,O){let U=V.readdirSync(E,{withFileTypes:!0});for(let W of U){if(d.has(W.name))continue;let G=H.join(E,W.name),Y=H.join(O,W.name);if(W.isDirectory())V.mkdirSync(Y,{recursive:!0}),Q(G,Y);else if(W.isFile()){if(V.existsSync(Y))continue;V.copyFileSync(G,Y),X++,z+=V.statSync(Y).size}}}return Q(J,K),{copied:X,bytes:z}}async function zq(J={}){let K=Date.now(),X=H.resolve(J.root||process.cwd()),z=H.resolve(X,J.outputDir||".output");console.log("[stx build] Starting production build...");let Q={};try{Q=await R()}catch{}let E=J.componentsDir??Q.componentsDir??"components",O=J.partialsDir??Q.partialsDir??"partials",U=J.layoutsDir??Q.layoutsDir??"layouts",W=J.publicDir??Q.publicDir??"public",G=Q.app?.head||{},Y=Q.router?.container||"main";if(V.existsSync(z))V.rmSync(z,{recursive:!0});let h=[H.join(z,"public","__stx"),H.join(z,"public","assets"),H.join(z,"server","pages"),H.join(z,"server","fragments")];for(let F of h)V.mkdirSync(F,{recursive:!0});console.log("[stx build] Discovering routes...");let I=g(X),m=["components","layouts","partials"],k=I.filter((F)=>{return!m.some((q)=>F.pattern.startsWith(`/${q}/`)||F.pattern===`/${q}`)});console.log(`[stx build] Found ${k.length} page routes (${I.length-k.length} non-page files excluded)`),console.log("[stx build] Generating shared assets...");let $=C(J.debug),Z=P();await Bun.write(H.join(z,"public","__stx",$.filename),$.content),await Bun.write(H.join(z,"public","__stx",Z.filename),Z.content),console.log(`[stx build] Runtime: ${$.filename} (${($.content.length/1024).toFixed(1)}KB)`),console.log(`[stx build] Router: ${Z.filename} (${(Z.content.length/1024).toFixed(1)}KB)`),console.log("[stx build] Compiling templates...");let v=[],N=[];for(let F of k)try{let q=await S(F.filePath,F.pattern,{componentsDir:E,partialsDir:O,layoutsDir:U,debug:J.debug});if(v.push(q),q.html=q.html.replace(/runtime\.__STX_HASH__\.js/g,$.filename).replace(/router\.__STX_HASH__\.js/g,Z.filename),q.html=b(q.html,G,{bodyScripts:[`<script src="/__stx/${Z.filename}"></script>`]}),!/<body[^>]*\bdata-stx=/.test(q.html)){let B=q.html.match(/<(?!body\b)[a-zA-Z][a-zA-Z0-9-]*\b[^>]*?\s(data-stx="[^"]+")[^>]*>/);if(B&&B[1]){let x=B[1];q.html=q.html.replace(" "+x,""),q.html=q.html.replace(/<body([^>]*)>/,`<body$1 ${x}>`)}}q.html=q.html.replace(/<style data-crosswind="generated">[\s\S]*?<\/style>\s*/g,""),q.html=await y(q.html),q.fragment=f(q.html,Y);let w=F.pattern==="/"?"index":F.pattern.slice(1).replace(/\//g,"-").replace(/[[\]]/g,"_"),M=H.join("server","pages",`${w}.compiled.json`),j=H.join("server","fragments",`${w}.html`);await Bun.write(H.join(z,M),JSON.stringify(q,null,2)),await Bun.write(H.join(z,j),q.fragment),N.push({pattern:F.pattern,compiledPath:M,fragmentPath:j,isDynamic:q.hasServerScripts,hasParams:F.pattern.includes(":")||F.pattern.includes("[")}),console.log(`[stx build] \u2713 ${F.pattern}`)}catch(q){console.error(`[stx build] \u2717 ${F.pattern}:`,q instanceof Error?q.message:q)}let _=H.resolve(X,W);if(V.existsSync(_)){let{copied:F,bytes:q}=n(_,H.join(z,"public"));if(F>0)console.log(`[stx build] Copied ${F} public asset${F===1?"":"s"} (${(q/1024).toFixed(1)}KB) from ${W}/`)}let L={runtime:$.filename,router:Z.filename},l=A(N,L,z);D(l,z);let T=Date.now()-K;return console.log(`
3
3
  [stx build] Done in ${T}ms \u2014 ${v.length} pages compiled`),{pageCount:v.length,assets:L,outputDir:z,duration:T}}
4
- export{zq as Bi};
4
+ export{zq as Ei};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
2
  var nk={enabled:!0,image:{enabled:!0,defaultWidths:[320,480,640,768,1024,1280,1536,1920],defaultFormats:["avif","webp","jpeg"],defaultQuality:80,placeholderStrategy:"thumbhash",lazyByDefault:!0,enableDpr:!0,defaultDpr:[1,2,3]},video:{enabled:!0,lazyByDefault:!0,defaultControls:!0},upload:{enabled:!0,maxSize:10485760,allowedTypes:["image/*","video/*","audio/*","application/pdf"],maxConcurrent:3},protected:{enabled:!0,expirationSeconds:3600,batchSize:10},cache:{enabled:!0,directory:".stx/media-cache",maxAge:30,maxSize:500}};
3
- export{nk as tj};
3
+ export{nk as wj};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
2
  var M=/<script\b[^>]*>/iy,Q=/<\/script\s*>/ig,U=/<style\b[^>]*>/iy,V=/<\/style\s*>/ig;function J(f,j,w,B){w.lastIndex=j;let z=w.exec(f);if(!z||z.index!==j)return-1;B.lastIndex=w.lastIndex;let v=B.exec(f);if(!v)return-1;return v.index+v[0].length}function W(f,j){return J(f,j,M,Q)}function Z(f,j){return J(f,j,U,V)}function $(f,j){if(!f.startsWith("<!--",j))return-1;let w=f.indexOf("-->",j+4);if(w===-1)return-1;return w+3}function X(f,j,w){let B=[],z="",v=0,K=f.length,H=!1,F=null;while(v<K){let D=f[v];if(H){if(z+=D,F){if(D===F)F=null}else if(D==='"'||D==="'")F=D;else if(D===">")H=!1;v++;continue}if(D==="<"){let G=j(f,v);if(G>v){z+=w(f.slice(v,G),B.length),B.push(f.slice(v,G)),v=G;continue}if(/^<\/?[a-zA-Z]/.test(f.slice(v,v+2)))H=!0;z+=D,v++;continue}z+=D,v++}return{output:z,tokens:B}}function b(f){let{output:j,tokens:w}=X(f,W,(B,z)=>`\x00STX_SCRIPT_${z}\x00`);return{output:j,scripts:w}}function y(f,j){if(j.length===0)return f;return f.replace(/\x00STX_SCRIPT_(\d+)\x00/g,(w,B)=>j[+B]??"")}
3
- export{W as lv,Z as mv,$ as nv,X as ov,b as pv,y as qv};
3
+ export{W as kv,Z as lv,$ as mv,X as nv,b as ov,y as pv};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
- import{Sr as O}from"./chunk-w01y57f5.js";import M from"path";var Q=/<script\b[^>]*\bserver\b/i,W=/<script\b[^>]*\bclient\b/i;async function Z(q){let u=performance.now(),k=await O(q),z=q||k.root||process.cwd(),G=[k.build?.pagesDir||k.pagesDir||"pages",k.componentsDir||"components",k.layoutsDir||"layouts",k.partialsDir||"partials"].map((w)=>M.resolve(z,w)),A=[],B=0;for(let w of G){let H=await U(w);for(let J of H){B++;let K=await Bun.file(J).text();if(Q.test(K))A.push(M.relative(z,J))}}return{mode:A.length>0?"ssr":"ssg",serverScriptFiles:A,totalFilesScanned:B,scanDurationMs:Math.round(performance.now()-u)}}async function $(q){let u=await O(q),k=q||u.root||process.cwd(),z=M.resolve(k,u.componentsDir||"components"),G=[],A=await U(z);for(let B of A){let w=await Bun.file(B).text(),H=Q.test(w),J=W.test(w)||/<script\b(?![^>]*\bserver\b)[^>]*>/i.test(w)&&!H;if(H&&J){let K=M.relative(k,B);G.push({file:K,message:`Component "${K}" has both <script server> and <script client>. `+"Components should be server OR client \u2014 compose them via props/slots."})}}return G}async function U(q){let u=[];try{let k=new Bun.Glob("**/*.stx");for await(let z of k.scan({cwd:q,absolute:!0}))u.push(z)}catch{}return u}
3
- export{Z as pq,$ as qq};
2
+ import{Rr as O}from"./chunk-1xz0w746.js";import M from"path";var Q=/<script\b[^>]*\bserver\b/i,W=/<script\b[^>]*\bclient\b/i;async function Z(q){let u=performance.now(),k=await O(q),z=q||k.root||process.cwd(),G=[k.build?.pagesDir||k.pagesDir||"pages",k.componentsDir||"components",k.layoutsDir||"layouts",k.partialsDir||"partials"].map((w)=>M.resolve(z,w)),A=[],B=0;for(let w of G){let H=await U(w);for(let J of H){B++;let K=await Bun.file(J).text();if(Q.test(K))A.push(M.relative(z,J))}}return{mode:A.length>0?"ssr":"ssg",serverScriptFiles:A,totalFilesScanned:B,scanDurationMs:Math.round(performance.now()-u)}}async function $(q){let u=await O(q),k=q||u.root||process.cwd(),z=M.resolve(k,u.componentsDir||"components"),G=[],A=await U(z);for(let B of A){let w=await Bun.file(B).text(),H=Q.test(w),J=W.test(w)||/<script\b(?![^>]*\bserver\b)[^>]*>/i.test(w)&&!H;if(H&&J){let K=M.relative(k,B);G.push({file:K,message:`Component "${K}" has both <script server> and <script client>. `+"Components should be server OR client \u2014 compose them via props/slots."})}}return G}async function U(q){let u=[];try{let k=new Bun.Glob("**/*.stx");for await(let z of k.scan({cwd:q,absolute:!0}))u.push(z)}catch{}return u}
3
+ export{Z as oq,$ as pq};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
2
  async function y(z,w,A,B){let j=w[0]?.replace(/['"]/g,"")||"main",b=q();if(j!=="main")b=b.replace("container:'main'",`container:'${j}'`);return`<script data-stx-router>${b}</script>`}var E={name:"stxRouter",handler:y,hasEndTag:!1,description:"Inject the STX SPA router script for client-side navigation"};import{getRouterScript as q}from"stx-router";
3
- export{q as Xy,y as Yy,E as Zy};
3
+ export{q as Vy,y as Wy,E as Xy};
@@ -5,4 +5,4 @@ ${$.join(`
5
5
  `)}
6
6
  ${z}
7
7
  </picture>`}return`${U}${z}`}};
8
- export{c as kz};
8
+ export{c as iz};
@@ -1,9 +1,9 @@
1
1
  // @bun
2
- import{Vy as $}from"./chunk-q60knhjf.js";import H from"path";function Z(j){return j.startsWith("http://")||j.startsWith("https://")||j.startsWith("//")}async function _(j,z,Q){try{let q;if(j.startsWith("/")){let B=z;for(let J=0;J<5;J++){let K=H.join(B,j);if(await Bun.file(K).exists())return K;B=H.dirname(B)}q=H.join(z,j)}else if(j.startsWith("./")||j.startsWith("../"))q=H.resolve(z,j);else q=H.resolve(z,j);if(await Bun.file(q).exists())return q;return null}catch{return null}}async function I(j,z,Q){let q=j,B=H.dirname(z),J=/<script\b([^>]*)src=["']([^"']+)["']([^>]*)><\/script>/gi,K;while((K=J.exec(q))!==null){let[T,X,w,Y]=K;if(Z(w))continue;let G=await _(w,B,z);if(G)try{let O=await Bun.file(G).text();if(Q.add(G),w.endsWith(".ts")||w.endsWith(".tsx")){let N=await Bun.build({entrypoints:[G],target:"browser",minify:!1,define:$()});if(N.outputs.length>0)O=await N.outputs[0].text()}let L=`<script>
2
+ import{Ty as $}from"./chunk-7ed3tean.js";import H from"path";function Z(j){return j.startsWith("http://")||j.startsWith("https://")||j.startsWith("//")}async function _(j,z,Q){try{let q;if(j.startsWith("/")){let B=z;for(let J=0;J<5;J++){let K=H.join(B,j);if(await Bun.file(K).exists())return K;B=H.dirname(B)}q=H.join(z,j)}else if(j.startsWith("./")||j.startsWith("../"))q=H.resolve(z,j);else q=H.resolve(z,j);if(await Bun.file(q).exists())return q;return null}catch{return null}}async function I(j,z,Q){let q=j,B=H.dirname(z),J=/<script\b([^>]*)src=["']([^"']+)["']([^>]*)><\/script>/gi,K;while((K=J.exec(q))!==null){let[T,X,w,Y]=K;if(Z(w))continue;let G=await _(w,B,z);if(G)try{let O=await Bun.file(G).text();if(Q.add(G),w.endsWith(".ts")||w.endsWith(".tsx")){let N=await Bun.build({entrypoints:[G],target:"browser",minify:!1,define:$()});if(N.outputs.length>0)O=await N.outputs[0].text()}let L=`<script>
3
3
  // Source: ${w}
4
4
  ${O}
5
5
  </script>`;q=q.replace(T,L),J.lastIndex=0}catch(O){}}let V=/<link\b([^>]*)href=["']([^"']+)["']([^>]*)(?:\/?>)/gi,W;while((W=V.exec(q))!==null){let[T,X,w,Y]=W,G=X+Y;if(Z(w))continue;if(/rel=["']stylesheet["']/.test(G)||w.endsWith(".css")){let L=await _(w,B,z);if(L)try{let N=await Bun.file(L).text();Q.add(L);let y=`<style>
6
6
  /* Source: ${w} */
7
7
  ${N}
8
8
  </style>`;q=q.replace(T,y),V.lastIndex=0}catch(N){}}}return q}
9
- export{Z as iv,_ as jv,I as kv};
9
+ export{Z as hv,_ as iv,I as jv};
@@ -318,4 +318,4 @@ else {
318
318
  console.log('[stx] Transition runtime initialized');
319
319
  })();
320
320
  `}function $(b){let j=/@transition\.([a-z-]+)(?:\.(\d+))?="([^"]+)"/gi;return b.replace(j,(B,q,A,z)=>{let F=A||"300",G=`stx-t-${Math.random().toString(36).slice(2,7)}`;return`data-stx-transition="${q}" data-stx-transition-duration="${F}" data-stx-transition-condition="${z}" data-stx-transition-id="${G}"`})}
321
- export{W as Nf,X as Of,Y as Pf,Z as Qf,_ as Rf,$ as Sf};
321
+ export{W as Qf,X as Rf,Y as Sf,Z as Tf,_ as Uf,$ as Vf};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
- import{nt as H,ot as J}from"./chunk-nanw7yhz.js";function Y(B,z){if(!/<style\s+[^>]*\bscoped\b/i.test(B))return{html:B,hasScoped:!1};let D=H(z),v=`data-v-${D}`,q=B,E=/<style\s+([^>]*\bscoped\b[^>]*)>([\s\S]*?)<\/style>/gi,F=!1;if(q=q.replace(E,(V,K,L)=>{F=!0;let M=Q(L,v),G=K.replace(/\bscoped\b/gi,"").trim(),O=G?` ${G}`:"";return`<style data-stx-scoped="${D}"${O}>${M}</style>`}),!F)return{html:B,hasScoped:!1};return q=U(q,v),{html:q,hasScoped:!0}}function Q(B,z){return J(B,"__SCOPE_PLACEHOLDER__",{preserveHost:!1}).replace(/\.(__SCOPE_PLACEHOLDER__) /g,`[${z}] `).replace(/\.(__SCOPE_PLACEHOLDER__)/g,`[${z}]`)}function U(B,z){let D=new Set(["script","style","template","html","head","body","meta","link","title","base","!doctype","!DOCTYPE"]);return B.replace(/<([a-zA-Z][a-zA-Z0-9-]*)(\s[^>]*)?\/?>/g,(v,q,E)=>{if(D.has(q.toLowerCase()))return v;if(v.includes(z))return v;if(q.toLowerCase()==="style"||q.toLowerCase()==="script")return v;if(E)return v.replace(`<${q}${E}`,`<${q} ${z}${E}`);if(v.endsWith("/>"))return`<${q} ${z} />`;return`<${q} ${z}>`})}
3
- export{Y as mt};
2
+ import{mt as H,nt as J}from"./chunk-6djzdes9.js";function Y(B,z){if(!/<style\s+[^>]*\bscoped\b/i.test(B))return{html:B,hasScoped:!1};let D=H(z),v=`data-v-${D}`,q=B,E=/<style\s+([^>]*\bscoped\b[^>]*)>([\s\S]*?)<\/style>/gi,F=!1;if(q=q.replace(E,(V,K,L)=>{F=!0;let M=Q(L,v),G=K.replace(/\bscoped\b/gi,"").trim(),O=G?` ${G}`:"";return`<style data-stx-scoped="${D}"${O}>${M}</style>`}),!F)return{html:B,hasScoped:!1};return q=U(q,v),{html:q,hasScoped:!0}}function Q(B,z){return J(B,"__SCOPE_PLACEHOLDER__",{preserveHost:!1}).replace(/\.(__SCOPE_PLACEHOLDER__) /g,`[${z}] `).replace(/\.(__SCOPE_PLACEHOLDER__)/g,`[${z}]`)}function U(B,z){let D=new Set(["script","style","template","html","head","body","meta","link","title","base","!doctype","!DOCTYPE"]);return B.replace(/<([a-zA-Z][a-zA-Z0-9-]*)(\s[^>]*)?\/?>/g,(v,q,E)=>{if(D.has(q.toLowerCase()))return v;if(v.includes(z))return v;if(q.toLowerCase()==="style"||q.toLowerCase()==="script")return v;if(E)return v.replace(`<${q}${E}`,`<${q} ${z}${E}`);if(v.endsWith("/>"))return`<${q} ${z} />`;return`<${q} ${z}>`})}
3
+ export{Y as lt};
@@ -11,4 +11,4 @@ catch (e) {
11
11
  throw e;
12
12
  }
13
13
  `),N.set(Z,$)}return $(...T)}catch{return}}};if(this.pool.length<this.maxPoolSize)this.pool.push({func:O,context:F.slice()});return O}clear(){this.pool.length=0,this.fnCache.clear()}}var S=new L;class W{metrics=new Map;budgets=new Map;violations=[];maxViolations=100;violationHandlers=[];enabled=!0;setEnabled(j){this.enabled=j}isEnabled(){return this.enabled}setBudget(j,F){this.budgets.set(j,{warnThreshold:0.8,action:"warn",...F})}setBudgets(j){for(let[F,D]of Object.entries(j))this.setBudget(F,D)}removeBudget(j){this.budgets.delete(j)}getBudgets(){let j={};for(let[F,D]of this.budgets.entries())j[F]=D;return j}onViolation(j){this.violationHandlers.push(j)}offViolation(j){let F=this.violationHandlers.indexOf(j);if(F!==-1)this.violationHandlers.splice(F,1)}time(j,F){if(!this.enabled)return F();let D=performance.now(),J=F(),N=performance.now()-D;return this.recordTime(j,N),this.checkBudget(j,N),J}async timeAsync(j,F){if(!this.enabled)return F();let D=performance.now(),J=await F(),N=performance.now()-D;return this.recordTime(j,N),this.checkBudget(j,N),J}checkBudget(j,F){let D=this.budgets.get(j);if(!D)return;let J=F/D.maxTime*100,N=D.warnThreshold!==void 0?F>=D.maxTime*D.warnThreshold&&F<D.maxTime:!1,Q=F>=D.maxTime;if(!N&&!Q)return;let O={label:j,actualTime:F,budgetTime:D.maxTime,exceedancePercent:J,timestamp:new Date,isWarning:N};this.violations.push(O);while(this.violations.length>this.maxViolations)this.violations.shift();for(let Y of this.violationHandlers)try{Y(O)}catch{}let T=N?`[Performance Warning] "${j}" took ${F.toFixed(2)}ms (${J.toFixed(1)}% of ${D.maxTime}ms budget)`:`[Performance Budget Exceeded] "${j}" took ${F.toFixed(2)}ms (exceeded ${D.maxTime}ms budget by ${(J-100).toFixed(1)}%)`;switch(D.action){case"log":console.log(T);break;case"warn":console.warn(T);break;case"error":console.error(T);break;case"throw":if(Q)throw Error(T);else console.warn(T);break}}recordTime(j,F){let D=this.metrics.get(j);if(D)D.count++,D.totalTime+=F,D.maxTime=Math.max(D.maxTime,F),D.minTime=Math.min(D.minTime,F);else this.metrics.set(j,{count:1,totalTime:F,maxTime:F,minTime:F})}getStats(j){if(j){let D=this.metrics.get(j);if(!D)return{};let J=this.budgets.get(j);return{count:D.count,avgTime:D.totalTime/D.count,totalTime:D.totalTime,maxTime:D.maxTime,minTime:D.minTime,budget:J?.maxTime,budgetUtilization:J?D.totalTime/D.count/J.maxTime*100:void 0}}let F={};for(let[D,J]of this.metrics.entries()){let N=this.budgets.get(D);F[D]={count:J.count,avgTime:J.totalTime/J.count,totalTime:J.totalTime,maxTime:J.maxTime,minTime:J.minTime,budget:N?.maxTime,budgetUtilization:N?J.totalTime/J.count/N.maxTime*100:void 0}}return F}getViolations(j){if(j)return this.violations.filter((F)=>F.label===j);return[...this.violations]}getViolationStats(){let j={},F=0,D=0;for(let J of this.violations)if(j[J.label]=(j[J.label]||0)+1,J.isWarning)F++;else D++;return{total:this.violations.length,byLabel:j,warnings:F,errors:D}}clear(){this.metrics.clear()}clearViolations(){this.violations.length=0}clearBudgets(){this.budgets.clear()}reset(){this.clear(),this.clearViolations(),this.clearBudgets(),this.violationHandlers.length=0}}var H={processDirectives:{maxTime:500,warnThreshold:0.8,action:"warn"},processTemplate:{maxTime:200,warnThreshold:0.8,action:"warn"},processIncludes:{maxTime:100,warnThreshold:0.8,action:"warn"},processLoops:{maxTime:50,warnThreshold:0.8,action:"warn"},processConditionals:{maxTime:50,warnThreshold:0.8,action:"warn"},processExpressions:{maxTime:100,warnThreshold:0.8,action:"warn"},renderComponent:{maxTime:150,warnThreshold:0.8,action:"warn"},buildWebComponents:{maxTime:1000,warnThreshold:0.8,action:"warn"}},B=null;function w(){if(!B)B=new W;return B}var _=new Proxy({},{get(j,F){return w()[F]}});function v(j=w()){j.setBudgets(H)}function K(){B=null}
14
- export{I as Bx,z as Cx,A as Dx,G as Ex,X as Fx,M as Gx,P as Hx,R as Ix,S as Jx,W as Kx,H as Lx,w as Mx,_ as Nx,v as Ox,K as Px};
14
+ export{I as Ax,z as Bx,A as Cx,G as Dx,X as Ex,M as Fx,P as Gx,R as Hx,S as Ix,W as Jx,H as Kx,w as Lx,_ as Mx,v as Nx,K as Ox};
@@ -5,4 +5,4 @@ function j(g){let f=g.robots??"allow";if(f===!1)return null;if(typeof f==="strin
5
5
  `:"";if(f==="disallow")return["User-agent: *","Disallow: /","",h].filter(Boolean).join(`
6
6
  `);return["User-agent: *","Allow: /","",h].filter(Boolean).join(`
7
7
  `)}
8
- export{j as ch};
8
+ export{j as fh};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
- import{iz as L}from"./chunk-3rh7va1z.js";import{rB as $}from"./chunk-3jm3snz8.js";import{existsSync as j,readFileSync as u}from"fs";var I=new Map;function q(E){try{return $.resolve(`@iconify/json/json/${E}.json`)}catch{}let G=process.cwd();for(let H of[`${G}/node_modules/@iconify/json/json/${E}.json`,`${G}/pantry/@iconify/json/json/${E}.json`])if(j(H))return H;return null}function D(E){if(I.has(E))return I.get(E);let G=q(E);if(!G)return null;try{let H=JSON.parse(u(G,"utf8"));return I.set(E,H.icons),H.icons}catch{return null}}async function R(E){if(I.has(E))return I.get(E);let G=q(E);if(!G)return null;try{let H=await Bun.file(G).json();return I.set(E,H.icons),H.icons}catch{return null}}function J(E,G){if(E.serverDynamic[G]!==void 0)return String(E.serverDynamic[G]);if(E.static[G]!==void 0)return String(E.static[G]);if(E.clientReactive[G]!==void 0)return E.clientReactive[G];return}var b={name:"Icon",aliases:["icon","stx-icon"],render(E,G,H){let M=J(E,"name")??J(E,"icon");if(!M)return"<!-- Icon: missing name/icon prop -->";let K="lucide",Q=M;if(M.includes(":")){let Z=M.split(":");K=Z[0],Q=Z[1]}let U=L(J(E,"size")||"24"),V=L(J(E,"color")||"currentColor"),W=L(J(E,"class")||""),X=L(J(E,"style")||""),Y=I.get(K)??D(K);if(!Y)return`<!-- Icon: collection "${K}" not loaded -->`;let O=Y[Q];if(!O)return`<!-- Icon: "${Q}" not found in ${K} -->`;let B=O.width||24,F=O.height||24,z=`0 0 ${B} ${F}`,T=O.body;if(V!=="currentColor")T=T.replace(/currentColor/g,V);let S=W?` class="${W}"`:"",g=X?` style="${X}"`:"";return`<svg xmlns="http://www.w3.org/2000/svg" width="${U}" height="${U}" viewBox="${z}" fill="none"${S}${g}>${T}</svg>`}};async function A(E="lucide"){await R(E)}
3
- export{b as fz,A as gz};
2
+ import{gz as L}from"./chunk-gz5fmp3q.js";import{pB as $}from"./chunk-xv34zbp4.js";import{existsSync as j,readFileSync as u}from"fs";var I=new Map;function q(E){try{return $.resolve(`@iconify/json/json/${E}.json`)}catch{}let G=process.cwd();for(let H of[`${G}/node_modules/@iconify/json/json/${E}.json`,`${G}/pantry/@iconify/json/json/${E}.json`])if(j(H))return H;return null}function D(E){if(I.has(E))return I.get(E);let G=q(E);if(!G)return null;try{let H=JSON.parse(u(G,"utf8"));return I.set(E,H.icons),H.icons}catch{return null}}async function R(E){if(I.has(E))return I.get(E);let G=q(E);if(!G)return null;try{let H=await Bun.file(G).json();return I.set(E,H.icons),H.icons}catch{return null}}function J(E,G){if(E.serverDynamic[G]!==void 0)return String(E.serverDynamic[G]);if(E.static[G]!==void 0)return String(E.static[G]);if(E.clientReactive[G]!==void 0)return E.clientReactive[G];return}var b={name:"Icon",aliases:["icon","stx-icon"],render(E,G,H){let M=J(E,"name")??J(E,"icon");if(!M)return"<!-- Icon: missing name/icon prop -->";let K="lucide",Q=M;if(M.includes(":")){let Z=M.split(":");K=Z[0],Q=Z[1]}let U=L(J(E,"size")||"24"),V=L(J(E,"color")||"currentColor"),W=L(J(E,"class")||""),X=L(J(E,"style")||""),Y=I.get(K)??D(K);if(!Y)return`<!-- Icon: collection "${K}" not loaded -->`;let O=Y[Q];if(!O)return`<!-- Icon: "${Q}" not found in ${K} -->`;let B=O.width||24,F=O.height||24,z=`0 0 ${B} ${F}`,T=O.body;if(V!=="currentColor")T=T.replace(/currentColor/g,V);let S=W?` class="${W}"`:"",g=X?` style="${X}"`:"";return`<svg xmlns="http://www.w3.org/2000/svg" width="${U}" height="${U}" viewBox="${z}" fill="none"${S}${g}>${T}</svg>`}};async function A(E="lucide"){await R(E)}
3
+ export{b as dz,A as ez};
@@ -80,4 +80,4 @@ else {
80
80
  <span>${Array.isArray(g)?g.join(", "):String(g)}</span>
81
81
  </div>`).join("")}
82
82
  </div>`}var q=["dark","night","monokai","dracula","nord","material","ayu","one-dark","tokyo","gruvbox","solarized-dark"];function G(b){let j=b.toLowerCase();return q.some((g)=>j.includes(g))}
83
- export{x as no,z as oo,B as po,F as qo,q as ro,G as so};
83
+ export{x as mo,z as no,B as oo,F as po,q as qo,G as ro};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
2
  import{Buffer as R}from"buffer";import S from"crypto";var W=40,V="_token",w=null;function X(j=W){let q=S.randomBytes(Math.ceil(j/2)).toString("hex").slice(0,j);return w=q,q}function Y(){if(!w)X();return w}function v(){w=null}function G(j){w=j}function Z(j=V){let q=Y();return`<input type="hidden" name="${j}" value="${q}">`}function H(j){return j.replace(/@csrf(?:\((['"])([^'"]*)\1\))?/g,(q,J,z)=>{return Z(z||V)})}function K(j,q){let J=q??w;if(!J)return!1;let z=R.from(j),Q=R.from(J);if(z.length!==Q.length)return!1;return S.timingSafeEqual(z,Q)}
3
- export{X as tx,Y as ux,v as vx,G as wx,Z as xx,H as yx,K as zx};
3
+ export{X as sx,Y as tx,v as ux,G as vx,Z as wx,H as xx,K as yx};
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import{Tj as _,Uj as M,Yj as R}from"./chunk-eqeyaq6g.js";async function y(q){let{src:w,alt:j="",signatureEndpoint:z="/api/sign",signatureConfig:F={},auth:J,fallback:K,oneTimeUse:G=!0}=q,W=q.class,X=q.style;if(J){if(!await _(J)){if(K)return{html:`<img src="${B(K)}" alt="${B(j)}"${W?` class="${B(W)}"`:""}${X?` style="${B(X)}"`:""} />`};return{html:"<!-- Protected content: access denied -->"}}}let $={endpoint:z,oneTimeUse:G,...F,params:J?M(J):F.params},Y=`stx-protected-${Math.random().toString(36).slice(2,8)}`,O=[`id="${Y}"`,`data-protected-src="${B(w)}"`,`data-signature-endpoint="${B(z)}"`,`alt="${B(j)}"`];if(K)O.push(`data-fallback="${B(K)}"`),O.push(`src="${B(K)}"`);else O.push('src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"');if(W)O.push(`class="${B(W)}"`);if(X)O.push(`style="${B(X)}"`);let Z=`
2
+ import{$j as R,Wj as _,Xj as M}from"./chunk-trfswy66.js";async function y(q){let{src:w,alt:j="",signatureEndpoint:z="/api/sign",signatureConfig:F={},auth:J,fallback:K,oneTimeUse:G=!0}=q,W=q.class,X=q.style;if(J){if(!await _(J)){if(K)return{html:`<img src="${B(K)}" alt="${B(j)}"${W?` class="${B(W)}"`:""}${X?` style="${B(X)}"`:""} />`};return{html:"<!-- Protected content: access denied -->"}}}let $={endpoint:z,oneTimeUse:G,...F,params:J?M(J):F.params},Y=`stx-protected-${Math.random().toString(36).slice(2,8)}`,O=[`id="${Y}"`,`data-protected-src="${B(w)}"`,`data-signature-endpoint="${B(z)}"`,`alt="${B(j)}"`];if(K)O.push(`data-fallback="${B(K)}"`),O.push(`src="${B(K)}"`);else O.push('src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7"');if(W)O.push(`class="${B(W)}"`);if(X)O.push(`style="${B(X)}"`);let Z=`
3
3
  (function() {
4
4
  var el = document.getElementById('${Y}');
5
5
  if (!el) return;
@@ -54,4 +54,4 @@ else if (el.dataset.fallback) {
54
54
  });
55
55
  })();
56
56
  `.trim(),{html:q,script:J}}function E(q,w,j){if(w.src)return{src:String(w.src),alt:String(w.alt||""),signatureEndpoint:String(w.signatureEndpoint||"/api/sign"),auth:w.auth,fallback:w.fallback?String(w.fallback):void 0,oneTimeUse:w.oneTimeUse!==!1};let z=q.trim();if(z.startsWith("@protected(")||z.startsWith("("))z=z.replace(/^@protected\(/,"").replace(/^\(/,"").replace(/\)$/,"");let F=D(z);return{src:L(F[0],j)||"",alt:L(F[1],j)||"",...typeof F[2]==="object"?F[2]:{}}}function D(q){let w=[],j="",z=!1,F="",J=0;for(let K=0;K<q.length;K++){let G=q[K],W=K>0?q[K-1]:"";if((G==='"'||G==="'")&&W!=="\\"){if(!z)z=!0,F=G;else if(G===F)z=!1;else j+=G;continue}if(!z){if(G==="{")J++;if(G==="}")J--;if(G===","&&J===0){w.push(j.trim()),j="";continue}}j+=G}if(j.trim())w.push(j.trim());return w}function L(q,w){if(typeof q!=="string")return q;let j=q.trim();if(j.startsWith('"')&&j.endsWith('"')||j.startsWith("'")&&j.endsWith("'"))return j.slice(1,-1);if(w[j]!==void 0)return w[j];if(j.startsWith("{"))try{return JSON.parse(j)}catch{}return j}function B(q){return q.replace(/&/g,"&amp;").replace(/"/g,"&quot;").replace(/'/g,"&#039;").replace(/</g,"&lt;").replace(/>/g,"&gt;")}
57
- export{y as Jj,C as Kj,x as Lj,E as Mj};
57
+ export{y as Mj,C as Nj,x as Oj,E as Pj};
@@ -383,4 +383,4 @@ else {
383
383
  })();
384
384
  </script>
385
385
  `}function R(D,j){let q=L(j);if(!q)return D;let E=D.lastIndexOf("</body>");if(E!==-1)return D.slice(0,E)+q+D.slice(E);return D+q}var T={name:"heatmap",hasEndTag:!1,description:"Inject privacy-compliant heatmap tracking script",handler:async(D,j,q,E)=>{let F=q.__stx_config||{};if(j.length>0){let J=Q(j.join(" "));F.heatmap={...F.heatmap,...J,enabled:!0}}return L(F)}};function Q(D){let j={},q=D.match(/(\w+)=["']?([^"'\s]+)["']?/g)||[];for(let E of q){let[F,J]=E.split("="),G=J?.replace(/["']/g,"");switch(F){case"endpoint":j.endpoint=G;break;case"samplingRate":j.samplingRate=Number.parseInt(G,10);break;case"batchSize":j.batchSize=Number.parseInt(G,10);break;case"trackMouse":j.trackMouse=G==="true";break;case"trackClicks":j.trackClicks=G==="true";break;case"trackScroll":j.trackScroll=G==="true";break;case"honorDnt":j.honorDnt=G==="true";break;case"debugOverlay":j.debugOverlay=G==="true";break}}return j}class M{sessions=new Map;addSession(D){let j=this.sessions.get(D.sid);if(j)j.points.push(...D.points),j.lastActivity=Math.max(j.lastActivity,D.lastActivity);else this.sessions.set(D.sid,D)}getPageData(D){let j=[];for(let q of this.sessions.values())if(q.page===D)j.push(...q.points);return j}getClickData(D){return this.getPageData(D).filter((j)=>j.type==="click")}getMovementData(D){return this.getPageData(D).filter((j)=>j.type==="move")}getScrollData(D){let j=this.getPageData(D).filter((E)=>E.type==="scroll"),q=new Map;for(let E of j)if(E.depth!==void 0)q.set(E.depth,(q.get(E.depth)||0)+1);return Array.from(q.entries()).map(([E,F])=>({depth:E,count:F})).sort((E,F)=>E.depth-F.depth)}getZoneStats(D){let j=new Map,q=this.getPageData(D);for(let E of q)if(E.zone){let F=j.get(E.zone)||{clicks:0,hovers:0};if(E.type==="click")F.clicks++;else if(E.type==="move")F.hovers++;j.set(E.zone,F)}return j}generateGridData(D,j=20){let q=this.getPageData(D),E=[];for(let J=0;J<j;J++){E[J]=[];for(let G=0;G<j;G++)E[J][G]=0}for(let J of q){let G=Math.min(Math.floor(J.x/100*j),j-1),K=Math.min(Math.floor(J.y/100*j),j-1);E[K][G]+=J.type==="click"?3:1}let F=0;for(let J of E)for(let G of J)F=Math.max(F,G);return E.map((J,G)=>J.map((K,N)=>({x:N,y:G,intensity:F>0?K/F:0})))}exportJSON(){return JSON.stringify({sessions:Array.from(this.sessions.values()),exportedAt:new Date().toISOString()},null,2)}clear(){this.sessions.clear()}get sessionCount(){return this.sessions.size}get totalPoints(){let D=0;for(let j of this.sessions.values())D+=j.points.length;return D}}function U(){return new M}
386
- export{O as ow,L as pw,R as qw,T as rw,M as sw,U as tw};
386
+ export{O as nw,L as ow,R as pw,T as qw,M as rw,U as sw};
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import{Ls as H,Rr as g,Vs as x,ur as O}from"./chunk-w01y57f5.js";import{et as R}from"./chunk-nap11ntr.js";import b from"path";var v={enabled:!0,bufferSize:16384,strategy:"auto",timeout:30000},M=/<!-- @section:([\w-]+) -->([\s\S]*?)<!-- @endsection:\1 -->/g;var T=/<!-- @suspense:([\w-]+) -->([\s\S]*?)<!-- @endsuspense:\1 -->/g;function f(q){let B=[],Q=0,G;T.lastIndex=0;while((G=T.exec(q))!==null){if(G.index>Q){let X=q.slice(Q,G.index);if(X.trim())B.push({type:B.length===0?"shell":"content",content:X})}let J=G[1],K=G[2];B.push({type:"suspense",name:J,content:K}),Q=G.index+G[0].length}if(Q<q.length){let J=q.slice(Q);if(J.trim())B.push({type:B.length===0?"shell":"content",content:J})}if(B.length===0)B.push({type:"shell",content:q});return B}async function r(q,B={},Q={}){let G={...g,...Q,streaming:{...v,...Q.streaming}},J=G.streaming?.bufferSize||16384;return new ReadableStream({async start(K){try{let X=await Bun.file(q).text(),z=X.match(/<script\b[^>]*\bserver\b[^>]*>([\s\S]*?)<\/script>/i),L=z?z[1]:"",Y=X.replace(/<script\b[^>]*>[\s\S]*?<\/script>/gi,""),j={...B,__filename:q,__dirname:b.dirname(q)};if(L.trim())await R(L,j,q);let D=f(Y),$=new Set;if(!D.some((w)=>w.type==="suspense")){let w=G.streaming?.strategy||"auto",U=new RegExp(M.source,"g");if(!(w!=="manual"&&U.test(Y))){let F=await H(Y,j,q,G,$);for(let V=0;V<F.length;V+=J)K.enqueue(F.slice(V,V+J)),await new Promise((W)=>setTimeout(W,0))}else{let F=[],V=new RegExp(M.source,"g"),W;while((W=V.exec(Y))!==null)F.push({name:W[1],content:W[2],start:W.index,end:W.index+W[0].length});let y=0;for(let A of F){if(A.start>y){let k=Y.slice(y,A.start);if(k.trim()){let E=await H(k,j,q,G,$);K.enqueue(E),await new Promise((S)=>setTimeout(S,0))}}let I=await H(A.content,j,q,G,$);K.enqueue(I),await new Promise((k)=>setTimeout(k,0)),y=A.end}if(y<Y.length){let A=Y.slice(y);if(A.trim()){let I=await H(A,j,q,G,$);K.enqueue(I)}}}}else{let w=new Map;for(let Z of D)if(Z.type==="shell"||Z.type==="content"){let F=await H(Z.content,j,q,G,$);K.enqueue(F)}else if(Z.type==="suspense"&&Z.name){let F=`stx-suspense-${Z.name}`;K.enqueue(`<div id="${F}" data-suspense="${Z.name}" style="display:contents;">
2
+ import{Ks as H,Qr as g,Us as x,tr as O}from"./chunk-1xz0w746.js";import{dt as R}from"./chunk-g1vt329s.js";import b from"path";var v={enabled:!0,bufferSize:16384,strategy:"auto",timeout:30000},M=/<!-- @section:([\w-]+) -->([\s\S]*?)<!-- @endsection:\1 -->/g;var T=/<!-- @suspense:([\w-]+) -->([\s\S]*?)<!-- @endsuspense:\1 -->/g;function f(q){let B=[],Q=0,G;T.lastIndex=0;while((G=T.exec(q))!==null){if(G.index>Q){let X=q.slice(Q,G.index);if(X.trim())B.push({type:B.length===0?"shell":"content",content:X})}let J=G[1],K=G[2];B.push({type:"suspense",name:J,content:K}),Q=G.index+G[0].length}if(Q<q.length){let J=q.slice(Q);if(J.trim())B.push({type:B.length===0?"shell":"content",content:J})}if(B.length===0)B.push({type:"shell",content:q});return B}async function r(q,B={},Q={}){let G={...g,...Q,streaming:{...v,...Q.streaming}},J=G.streaming?.bufferSize||16384;return new ReadableStream({async start(K){try{let X=await Bun.file(q).text(),z=X.match(/<script\b[^>]*\bserver\b[^>]*>([\s\S]*?)<\/script>/i),L=z?z[1]:"",Y=X.replace(/<script\b[^>]*>[\s\S]*?<\/script>/gi,""),j={...B,__filename:q,__dirname:b.dirname(q)};if(L.trim())await R(L,j,q);let D=f(Y),$=new Set;if(!D.some((w)=>w.type==="suspense")){let w=G.streaming?.strategy||"auto",U=new RegExp(M.source,"g");if(!(w!=="manual"&&U.test(Y))){let F=await H(Y,j,q,G,$);for(let V=0;V<F.length;V+=J)K.enqueue(F.slice(V,V+J)),await new Promise((W)=>setTimeout(W,0))}else{let F=[],V=new RegExp(M.source,"g"),W;while((W=V.exec(Y))!==null)F.push({name:W[1],content:W[2],start:W.index,end:W.index+W[0].length});let y=0;for(let A of F){if(A.start>y){let k=Y.slice(y,A.start);if(k.trim()){let E=await H(k,j,q,G,$);K.enqueue(E),await new Promise((S)=>setTimeout(S,0))}}let I=await H(A.content,j,q,G,$);K.enqueue(I),await new Promise((k)=>setTimeout(k,0)),y=A.end}if(y<Y.length){let A=Y.slice(y);if(A.trim()){let I=await H(A,j,q,G,$);K.enqueue(I)}}}}else{let w=new Map;for(let Z of D)if(Z.type==="shell"||Z.type==="content"){let F=await H(Z.content,j,q,G,$);K.enqueue(F)}else if(Z.type==="suspense"&&Z.name){let F=`stx-suspense-${Z.name}`;K.enqueue(`<div id="${F}" data-suspense="${Z.name}" style="display:contents;">
3
3
  <template data-suspense-fallback>Loading...</template>
4
4
  </div>`),w.set(Z.name,H(Z.content,j,q,G,$))}K.enqueue(`
5
5
  <script>
@@ -191,4 +191,4 @@ else {
191
191
  stx.hydrate();
192
192
  }
193
193
  })();`}
194
- export{r as Tf,N as Uf,C as Vf,s as Wf,a as Xf,o as Yf,n as Zf,e as _f,d as $f,h as ag,t as bg,qq as cg,Bq as dg,Gq as eg};
194
+ export{r as Wf,N as Xf,C as Yf,s as Zf,a as _f,o as $f,n as ag,e as bg,d as cg,h as dg,t as eg,qq as fg,Bq as gg,Gq as hg};
@@ -7,4 +7,4 @@ function G(j){return j.replace(/[;{}()]/g,"").replace(/url/gi,"")}function E(j,q
7
7
  <script>
8
8
  (function(){var el=document.getElementById('stx-loading-indicator'),p=0,l=!1,i=null;function u(v){p=Math.min(Math.max(v,0),100);if(el){el.style.opacity=p>0?'1':'0';el.style.transform='scaleX('+(p/100)+')'}}window.stxLoading={start:function(){l=!0;p=0;u(10);if(i)clearInterval(i);i=setInterval(function(){if(!l)return;var r=90-p,inc=Math.max(0.5,r*0.1);if(p<90)u(p+inc)},${K})},finish:function(){l=!1;if(i){clearInterval(i);i=null}u(100);setTimeout(function(){if(el)el.style.opacity='0';setTimeout(function(){p=0;if(el)el.style.transform='scaleX(0)'},300)},200)},set:function(v){u(v)},clear:function(){l=!1;p=0;if(i){clearInterval(i);i=null}if(el){el.style.opacity='0';el.style.transform='scaleX(0)'}}};document.addEventListener('click',function(e){var a=e.target.closest&&e.target.closest('a');if(!a)return;var h=a.getAttribute('href');if(!h||h.startsWith('http')||h.startsWith('#')||h.startsWith('mailto:')||h.startsWith('tel:')||a.target==='_blank')return;window.stxLoading.start()});window.addEventListener('popstate',function(){window.stxLoading.start()});window.addEventListener('load',function(){window.stxLoading.finish()})})();
9
9
  </script>`}};
10
- export{O as $y};
10
+ export{O as Zy};
@@ -99,4 +99,4 @@ else {
99
99
  opacity: 0.5;
100
100
  }
101
101
  `.trim()}
102
- export{G as bl,u as cl,R as dl,y as el,v as fl,x as gl,w as hl,l as il,c as jl};
102
+ export{G as el,u as fl,R as gl,y as hl,v as il,x as jl,w as kl,l as ll,c as ml};
@@ -1,2 +1,2 @@
1
1
  // @bun
2
- import{gy as A,hy as _,jy as B}from"./chunk-mrehzhxv.js";function w(K){let Q=[],L=0;while(L<K.length){let G=K.indexOf("{{",L),j=K.indexOf("{!!",L),O=!1,J;if(G===-1&&j===-1)break;else if(G===-1)J=j,O=!0;else if(j===-1)J=G,O=!1;else if(j<G)J=j,O=!0;else J=G,O=!1;if(!O&&K.slice(J,J+3)==="{{{")O=!0;let H=O?K.slice(J,J+3)==="{{{"?"{{{":"{!!":"{{",Y=O?H==="{{{"?"}}}":"!!}":"}}",W=J+H.length,X=M(K,W,Y);if(X===-1){L=J+1;continue}let Z=K.slice(W,X).trim(),U=X+Y.length;Q.push({fullMatch:K.slice(J,U),expression:Z,start:J,end:U,isRaw:O}),L=U}return Q}function M(K,Q,L){let G=Q,j=null,O={paren:0,bracket:0,brace:0},J=0;while(G<K.length){let H=K[G];if((G>0?K[G-1]:"")==="\\"&&j){G++;continue}if((H==='"'||H==="'")&&!j){j=H,G++;continue}if(H===j&&j!=="`"){j=null,G++;continue}if(H==="`"&&!j){j="`",G++;continue}if(H==="`"&&j==="`"&&J===0){j=null,G++;continue}if(j==="`"&&H==="$"&&K[G+1]==="{"){J++,G+=2;continue}if(J>0){if(H==="{")J++;else if(H==="}")J--;G++;continue}if(j){G++;continue}if(H==="(")O.paren++;else if(H===")")O.paren--;else if(H==="[")O.bracket++;else if(H==="]")O.bracket--;else if(H==="{")O.brace++;else if(H==="}")O.brace--;if(O.paren===0&&O.bracket===0&&O.brace<=0){if(K.slice(G,G+L.length)===L)return G}G++}return-1}function D(K){let Q=B(K);if(Q.length===0)return{baseExpression:"",filters:[]};let L=Q[0],G=[];for(let j=1;j<Q.length;j++){let O=v(Q[j]);if(O)G.push(O)}return{baseExpression:L,filters:G}}function v(K){let Q=K.trim();if(!Q)return null;let L=Q.indexOf("(");if(L===-1)return{name:Q,args:[]};let G=Q.slice(0,L).trim(),j=L+1,O=_(Q,"(",")",L);if(O===-1)return{name:G,args:[]};let J=Q.slice(j,O),H=y(J);return{name:G,args:H}}function y(K){let Q=[],L="",G={paren:0,bracket:0,brace:0},j=null,O=0;for(let J=0;J<K.length;J++){let H=K[J];if((J>0?K[J-1]:"")==="\\"&&j){L+=H;continue}if((H==='"'||H==="'")&&!j){j=H,L+=H;continue}if(H===j&&j!=="`"){j=null,L+=H;continue}if(H==="`"&&!j){j="`",L+=H;continue}if(H==="`"&&j==="`"&&O===0){j=null,L+=H;continue}if(j==="`"&&H==="$"&&K[J+1]==="{"){O++,L+="${",J++;continue}if(O>0&&H==="{"){O++,L+=H;continue}if(O>0&&H==="}"){O--,L+=H;continue}if(j){L+=H;continue}if(H==="(")G.paren++;else if(H===")")G.paren--;else if(H==="[")G.bracket++;else if(H==="]")G.bracket--;else if(H==="{")G.brace++;else if(H==="}")G.brace--;if(H===","&&G.paren===0&&G.bracket===0&&G.brace===0){Q.push(L.trim()),L="";continue}L+=H}if(L.trim())Q.push(L.trim());return Q}function f(K,Q){let L=Q;while(L<K.length&&/\s/.test(K[L]))L++;if(K[L]!=="(")return null;let G=_(K,"(",")",L);if(G===-1)return null;return{params:K.slice(L+1,G),endPos:G+1}}function R(K){let Q=[],G=new A(K).tokenize().filter((O)=>O.type!=="WHITESPACE"&&O.type!=="COMMENT"),j=0;while(j<G.length){let O=G[j],J=!1;if(O.type==="IDENTIFIER"&&O.value==="export"){if(J=!0,j++,j>=G.length)break}let H=G[j];if(H.type==="IDENTIFIER"&&(H.value==="const"||H.value==="let"||H.value==="var")){let Y=H.value;if(j++,j>=G.length)break;let W=G[j];if(W.type==="IDENTIFIER"){let X=W.value;if(j++,j<G.length&&G[j].type==="OPERATOR"&&G[j].value==="="){j++;let Z=j<G.length?G[j].start:K.length,U=N(G,j,K);j=U.nextIndex,Q.push({type:"variable",name:X,value:K.slice(Z,U.endPos),exported:J,start:H.start,end:U.endPos})}}else if(W.type==="PUNCTUATION"&&(W.value==="{"||W.value==="[")){let X=W.start,Z=W.value==="{"?"}":"]",U=_(K,W.value,Z,X);if(U!==-1){let F=K.slice(X,U+1);if(j=V(G,U+1),j<G.length&&G[j].type==="OPERATOR"&&G[j].value==="="){j++;let z=j<G.length?G[j].start:K.length,$=N(G,j,K);j=$.nextIndex;let q=`__stx_destructured_${Q.length}`;Q.push({type:"variable",name:q,value:`${K.slice(z,$.endPos)}; ${Y} ${F} = ${q}`,exported:J,start:H.start,end:$.endPos})}}}}else if(H.type==="IDENTIFIER"&&H.value==="function"){let Y=J?G[j-1].start:H.start;if(j++,j>=G.length)break;let W=G[j];if(W.type==="IDENTIFIER"){let X=W.value;j++;let Z=-1;while(j<G.length){if(G[j].type==="PUNCTUATION"&&G[j].value==="{"){Z=G[j].start;break}j++}if(Z!==-1){let U=_(K,"{","}",Z);if(U!==-1)Q.push({type:"function",name:X,value:K.slice(Y,U+1).replace(/^export\s+/,""),exported:J,start:Y,end:U+1}),j=V(G,U+1)}}}else j++}return Q}function N(K,Q,L){let G=Q,j={paren:0,bracket:0,brace:0},O=Q<K.length?K[Q].start:L.length;while(G<K.length){let J=K[G];if(J.type==="PUNCTUATION"){if(J.value==="(")j.paren++;else if(J.value===")")j.paren--;else if(J.value==="[")j.bracket++;else if(J.value==="]")j.bracket--;else if(J.value==="{")j.brace++;else if(J.value==="}")j.brace--;if(J.value===";"&&j.paren===0&&j.bracket===0&&j.brace===0){O=J.start,G++;break}}if(J.type==="IDENTIFIER"&&(J.value==="const"||J.value==="let"||J.value==="var"||J.value==="function"||J.value==="export")){if(j.paren===0&&j.bracket===0&&j.brace===0){O=K[G-1]?.end??J.start;break}}O=J.end,G++}return{nextIndex:G,endPos:O}}function V(K,Q){for(let L=0;L<K.length;L++)if(K[L].start>=Q)return L;return K.length}export{w as Wx,D as Xx,y as Yx,f as Zx,R as _x};
2
+ import{ey as A,fy as _,hy as B}from"./chunk-bs3gmfxz.js";function w(K){let Q=[],L=0;while(L<K.length){let G=K.indexOf("{{",L),j=K.indexOf("{!!",L),O=!1,J;if(G===-1&&j===-1)break;else if(G===-1)J=j,O=!0;else if(j===-1)J=G,O=!1;else if(j<G)J=j,O=!0;else J=G,O=!1;if(!O&&K.slice(J,J+3)==="{{{")O=!0;let H=O?K.slice(J,J+3)==="{{{"?"{{{":"{!!":"{{",Y=O?H==="{{{"?"}}}":"!!}":"}}",W=J+H.length,X=M(K,W,Y);if(X===-1){L=J+1;continue}let Z=K.slice(W,X).trim(),U=X+Y.length;Q.push({fullMatch:K.slice(J,U),expression:Z,start:J,end:U,isRaw:O}),L=U}return Q}function M(K,Q,L){let G=Q,j=null,O={paren:0,bracket:0,brace:0},J=0;while(G<K.length){let H=K[G];if((G>0?K[G-1]:"")==="\\"&&j){G++;continue}if((H==='"'||H==="'")&&!j){j=H,G++;continue}if(H===j&&j!=="`"){j=null,G++;continue}if(H==="`"&&!j){j="`",G++;continue}if(H==="`"&&j==="`"&&J===0){j=null,G++;continue}if(j==="`"&&H==="$"&&K[G+1]==="{"){J++,G+=2;continue}if(J>0){if(H==="{")J++;else if(H==="}")J--;G++;continue}if(j){G++;continue}if(H==="(")O.paren++;else if(H===")")O.paren--;else if(H==="[")O.bracket++;else if(H==="]")O.bracket--;else if(H==="{")O.brace++;else if(H==="}")O.brace--;if(O.paren===0&&O.bracket===0&&O.brace<=0){if(K.slice(G,G+L.length)===L)return G}G++}return-1}function D(K){let Q=B(K);if(Q.length===0)return{baseExpression:"",filters:[]};let L=Q[0],G=[];for(let j=1;j<Q.length;j++){let O=v(Q[j]);if(O)G.push(O)}return{baseExpression:L,filters:G}}function v(K){let Q=K.trim();if(!Q)return null;let L=Q.indexOf("(");if(L===-1)return{name:Q,args:[]};let G=Q.slice(0,L).trim(),j=L+1,O=_(Q,"(",")",L);if(O===-1)return{name:G,args:[]};let J=Q.slice(j,O),H=y(J);return{name:G,args:H}}function y(K){let Q=[],L="",G={paren:0,bracket:0,brace:0},j=null,O=0;for(let J=0;J<K.length;J++){let H=K[J];if((J>0?K[J-1]:"")==="\\"&&j){L+=H;continue}if((H==='"'||H==="'")&&!j){j=H,L+=H;continue}if(H===j&&j!=="`"){j=null,L+=H;continue}if(H==="`"&&!j){j="`",L+=H;continue}if(H==="`"&&j==="`"&&O===0){j=null,L+=H;continue}if(j==="`"&&H==="$"&&K[J+1]==="{"){O++,L+="${",J++;continue}if(O>0&&H==="{"){O++,L+=H;continue}if(O>0&&H==="}"){O--,L+=H;continue}if(j){L+=H;continue}if(H==="(")G.paren++;else if(H===")")G.paren--;else if(H==="[")G.bracket++;else if(H==="]")G.bracket--;else if(H==="{")G.brace++;else if(H==="}")G.brace--;if(H===","&&G.paren===0&&G.bracket===0&&G.brace===0){Q.push(L.trim()),L="";continue}L+=H}if(L.trim())Q.push(L.trim());return Q}function f(K,Q){let L=Q;while(L<K.length&&/\s/.test(K[L]))L++;if(K[L]!=="(")return null;let G=_(K,"(",")",L);if(G===-1)return null;return{params:K.slice(L+1,G),endPos:G+1}}function R(K){let Q=[],G=new A(K).tokenize().filter((O)=>O.type!=="WHITESPACE"&&O.type!=="COMMENT"),j=0;while(j<G.length){let O=G[j],J=!1;if(O.type==="IDENTIFIER"&&O.value==="export"){if(J=!0,j++,j>=G.length)break}let H=G[j];if(H.type==="IDENTIFIER"&&(H.value==="const"||H.value==="let"||H.value==="var")){let Y=H.value;if(j++,j>=G.length)break;let W=G[j];if(W.type==="IDENTIFIER"){let X=W.value;if(j++,j<G.length&&G[j].type==="OPERATOR"&&G[j].value==="="){j++;let Z=j<G.length?G[j].start:K.length,U=N(G,j,K);j=U.nextIndex,Q.push({type:"variable",name:X,value:K.slice(Z,U.endPos),exported:J,start:H.start,end:U.endPos})}}else if(W.type==="PUNCTUATION"&&(W.value==="{"||W.value==="[")){let X=W.start,Z=W.value==="{"?"}":"]",U=_(K,W.value,Z,X);if(U!==-1){let F=K.slice(X,U+1);if(j=V(G,U+1),j<G.length&&G[j].type==="OPERATOR"&&G[j].value==="="){j++;let z=j<G.length?G[j].start:K.length,$=N(G,j,K);j=$.nextIndex;let q=`__stx_destructured_${Q.length}`;Q.push({type:"variable",name:q,value:`${K.slice(z,$.endPos)}; ${Y} ${F} = ${q}`,exported:J,start:H.start,end:$.endPos})}}}}else if(H.type==="IDENTIFIER"&&H.value==="function"){let Y=J?G[j-1].start:H.start;if(j++,j>=G.length)break;let W=G[j];if(W.type==="IDENTIFIER"){let X=W.value;j++;let Z=-1;while(j<G.length){if(G[j].type==="PUNCTUATION"&&G[j].value==="{"){Z=G[j].start;break}j++}if(Z!==-1){let U=_(K,"{","}",Z);if(U!==-1)Q.push({type:"function",name:X,value:K.slice(Y,U+1).replace(/^export\s+/,""),exported:J,start:Y,end:U+1}),j=V(G,U+1)}}}else j++}return Q}function N(K,Q,L){let G=Q,j={paren:0,bracket:0,brace:0},O=Q<K.length?K[Q].start:L.length;while(G<K.length){let J=K[G];if(J.type==="PUNCTUATION"){if(J.value==="(")j.paren++;else if(J.value===")")j.paren--;else if(J.value==="[")j.bracket++;else if(J.value==="]")j.bracket--;else if(J.value==="{")j.brace++;else if(J.value==="}")j.brace--;if(J.value===";"&&j.paren===0&&j.bracket===0&&j.brace===0){O=J.start,G++;break}}if(J.type==="IDENTIFIER"&&(J.value==="const"||J.value==="let"||J.value==="var"||J.value==="function"||J.value==="export")){if(j.paren===0&&j.bracket===0&&j.brace===0){O=K[G-1]?.end??J.start;break}}O=J.end,G++}return{nextIndex:G,endPos:O}}function V(K,Q){for(let L=0;L<K.length;L++)if(K[L].start>=Q)return L;return K.length}export{w as Ux,D as Vx,y as Wx,f as Xx,R as Yx};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
- import{$q as J}from"./chunk-xygc53vr.js";function Q(E,D){let A=new Set,B=new Map,C=new Map,F={globalProperties:{},performance:!1,compilerOptions:{}},z={config:F,_components:B,_directives:C,_installedPlugins:A,use(q,...x){if(A.has(q))return z;if(A.add(q),typeof q==="function")q(z,...x);else if(typeof q.install==="function")q.install(z,...x);return z},provide(q,x){return J(q,x),z},component(q,x){if(!x)return B.get(q);return B.set(q,x),z},directive(q,x){if(!x)return C.get(q);return C.set(q,x),z},mount(q){if(typeof document<"u"){let x=globalThis.__stx_globals||(globalThis.__stx_globals={});Object.assign(x,F.globalProperties),document.querySelectorAll("[v-cloak]").forEach((K)=>{K.removeAttribute("v-cloak")})}return z},unmount(){B.clear(),C.clear(),A.clear()}};return z}function R(E){return class extends HTMLElement{_component;_shadow;constructor(){super();this._shadow=this.attachShadow({mode:"open"}),this._component=E}connectedCallback(){if(this._component?.render){let D=this._component.render();if(typeof D==="string")this._shadow.innerHTML=D}else if(this._component?.template)this._shadow.innerHTML=this._component.template;else if(typeof this._component==="string")this._shadow.innerHTML=this._component}disconnectedCallback(){this._shadow.innerHTML=""}}}
3
- export{Q as Sq,R as Tq};
2
+ import{_q as J}from"./chunk-r0jcmpv6.js";function Q(E,D){let A=new Set,B=new Map,C=new Map,F={globalProperties:{},performance:!1,compilerOptions:{}},z={config:F,_components:B,_directives:C,_installedPlugins:A,use(q,...x){if(A.has(q))return z;if(A.add(q),typeof q==="function")q(z,...x);else if(typeof q.install==="function")q.install(z,...x);return z},provide(q,x){return J(q,x),z},component(q,x){if(!x)return B.get(q);return B.set(q,x),z},directive(q,x){if(!x)return C.get(q);return C.set(q,x),z},mount(q){if(typeof document<"u"){let x=globalThis.__stx_globals||(globalThis.__stx_globals={});Object.assign(x,F.globalProperties),document.querySelectorAll("[v-cloak]").forEach((K)=>{K.removeAttribute("v-cloak")})}return z},unmount(){B.clear(),C.clear(),A.clear()}};return z}function R(E){return class extends HTMLElement{_component;_shadow;constructor(){super();this._shadow=this.attachShadow({mode:"open"}),this._component=E}connectedCallback(){if(this._component?.render){let D=this._component.render();if(typeof D==="string")this._shadow.innerHTML=D}else if(this._component?.template)this._shadow.innerHTML=this._component.template;else if(typeof this._component==="string")this._shadow.innerHTML=this._component}disconnectedCallback(){this._shadow.innerHTML=""}}}
3
+ export{Q as Rq,R as Sq};
@@ -3,4 +3,4 @@ import{existsSync as _,readFileSync as $}from"fs";var A={strict:!1,allowAny:!0,c
3
3
  `),H=this.getLineNumber(j);for(let B=0;B<q.length;B++){let D=q[B],G=H+B;this.extractTypedVariables(D,G),this.extractInterfaces(D,q,B,G),this.extractTypeAliases(D,G)}}extractTypedVariables(z,j){let q=z.match(/(?:export\s+)?(?:const|let|var)\s+(\w+)\s*:\s*([^=]+?)\s*=/);if(q){let[,D,G]=q,J=this.parseTypeAnnotation(G.trim());this.variables.set(D,J);return}let H=z.match(/(?:export\s+)?(?:const|let|var)\s+(\w+)\s*=\s*(.+)/);if(H){let[,D,G]=H,J=this.inferType(G.trim());this.variables.set(D,J);return}let B=z.match(/(?:export\s+)?function\s+(\w+)\s*\(([^)]*)\)(?:\s*:\s*(\w+))?/);if(B){let[,D,G,J]=B,K=this.parseParams(G),Q=J?this.parseTypeAnnotation(J):{kind:"primitive",value:"any"};this.variables.set(D,{kind:"function",params:K,returnType:Q})}}extractInterfaces(z,j,q,H){let B=z.match(/(?:export\s+)?interface\s+(\w+)\s*\{/);if(B){let[,D]=B,G={},J=1,K=q+1;while(K<j.length&&J>0){let Q=j[K].trim();if(Q.includes("{"))J++;if(Q.includes("}"))J--;let U=Q.match(/(\w+)\??\s*:\s*([^;]+)/);if(U&&J>0){let[,W,V]=U;G[W]=this.parseTypeAnnotation(V.trim())}K++}this.variables.set(D,{kind:"object",name:D,properties:G})}}extractTypeAliases(z,j){let q=z.match(/(?:export\s+)?type\s+(\w+)\s*=\s*(.+)/);if(q){let[,H,B]=q,D=this.parseTypeAnnotation(B.trim());D.name=H,this.variables.set(H,D)}}parseTypeAnnotation(z){let j=z.trim();if(j.includes("|"))return{kind:"union",types:j.split("|").map((D)=>this.parseTypeAnnotation(D.trim()))};if(j.includes("&"))return{kind:"intersection",types:j.split("&").map((D)=>this.parseTypeAnnotation(D.trim()))};if(j.endsWith("[]"))return{kind:"array",elementType:this.parseTypeAnnotation(j.slice(0,-2))};let q=j.match(/^Array<(.+)>$/);if(q)return{kind:"array",elementType:this.parseTypeAnnotation(q[1])};if(j.startsWith("{")&&j.endsWith("}")){let B={},D=j.slice(1,-1).trim();if(D){let G=this.splitByComma(D);for(let J of G){let K=J.match(/(\w+)\??\s*:\s*(.+)/);if(K){let[,Q,U]=K;B[Q]=this.parseTypeAnnotation(U.trim())}}}return{kind:"object",properties:B}}if(j.startsWith('"')||j.startsWith("'"))return{kind:"literal",value:j.slice(1,-1)};if(/^\d+$/.test(j))return{kind:"literal",value:j};if(j==="true"||j==="false")return{kind:"literal",value:j};if(["string","number","boolean","null","undefined","any","unknown","void","never"].includes(j))return{kind:"primitive",value:j};if(this.variables.has(j))return this.variables.get(j);return{kind:"primitive",value:"any"}}inferType(z){let j=z.trim().replace(/;$/,"");if(j.startsWith('"')&&j.endsWith('"')||j.startsWith("'")&&j.endsWith("'")||j.startsWith("`")&&j.endsWith("`"))return{kind:"primitive",value:"string"};if(/^-?\d+(\.\d+)?$/.test(j))return{kind:"primitive",value:"number"};if(j==="true"||j==="false")return{kind:"primitive",value:"boolean"};if(j==="null")return{kind:"primitive",value:"null"};if(j==="undefined")return{kind:"primitive",value:"undefined"};if(j.startsWith("[")){let q=j.slice(1,-1).trim();if(q){let H=this.splitByComma(q)[0];if(H)return{kind:"array",elementType:this.inferType(H.trim())}}return{kind:"array",elementType:{kind:"primitive",value:"any"}}}if(j.startsWith("{")){let q={},H=this.extractObjectLiteral(j);for(let[B,D]of Object.entries(H))q[B]=this.inferType(D);return{kind:"object",properties:q}}if(j.includes("=>")){let q=j.match(/^\(([^)]*)\)\s*(?::\s*(\w+))?\s*=>/);if(q){let H=this.parseParams(q[1]),B=q[2]?this.parseTypeAnnotation(q[2]):{kind:"primitive",value:"any"};return{kind:"function",params:H,returnType:B}}}if(/^\w+$/.test(j)&&this.variables.has(j))return this.variables.get(j);if(j.includes("."))return this.resolvePropertyAccess(j);if(j.includes("(")){let q=j.split("(")[0],H=this.variables.get(q);if(H?.kind==="function"&&H.returnType)return H.returnType}return{kind:"primitive",value:"any"}}parseParams(z){if(!z.trim())return[];let j=[],q=this.splitByComma(z);for(let H of q){let B=H.trim(),D=B.includes("?"),G=B.match(/(\w+)\??\s*(?::\s*([^=]+))?(?:\s*=)?/);if(G){let[,J,K]=G,Q=K?this.parseTypeAnnotation(K.trim()):{kind:"primitive",value:"any"};j.push({name:J,type:Q,optional:D})}}return j}checkExpressions(z){let j=/\{\{([\s\S]*?)\}\}/g,q;while((q=j.exec(z))!==null){let B=q[1].trim(),D=q.index,G=this.getLineNumber(D,z),J=this.getColumn(D,z);if(!B)continue;if(B.startsWith("!")||B.endsWith("!"))continue;this.checkExpression(B,G,J)}let H=/\{!!([\s\S]*?)!!\}/g;while((q=H.exec(z))!==null){let B=q[1].trim(),D=q.index,G=this.getLineNumber(D,z),J=this.getColumn(D,z);if(!B)continue;this.checkExpression(B,G,J)}}checkExpression(z,j,q){if(z.includes("?")&&z.includes(":")){let D=z.split("?");this.checkExpression(D[0].trim(),j,q);let G=D.slice(1).join("?").split(":");if(G.length>=2)this.checkExpression(G[0].trim(),j,q),this.checkExpression(G.slice(1).join(":").trim(),j,q);return}for(let D of["&&","||","??"])if(z.includes(D)){z.split(D).forEach((J)=>this.checkExpression(J.trim(),j,q));return}for(let D of["===","!==","==","!=",">=","<=",">","<"])if(z.includes(D)){z.split(D).forEach((J)=>this.checkExpression(J.trim(),j,q));return}if(z.startsWith("!")){this.checkExpression(z.slice(1).trim(),j,q);return}if(this.isLiteral(z))return;let H=z.match(/^(\w+(?:\.\w+)*)\s*\(/);if(H){let D=H[1],G=this.resolvePropertyAccess(D);if(G.kind!=="function"&&G.value!=="any")this.addWarning(`'${D}' is not a function`,j,q,z);return}if(z.includes(".")){if(this.resolvePropertyAccess(z).value==="undefined"&&this.options.checkPropertyAccess)this.addWarning(`Property access '${z}' may be undefined`,j,q,z);return}let B=z.match(/^\w+/)?.[0];if(B&&!this.variables.has(B))this.addError(`Variable '${B}' is not defined`,j,q,z)}checkDirectives(z){let j=/@if\s*\(([^)]+)\)/g,q;while((q=j.exec(z))!==null){let G=q[1].trim(),J=q.index,K=this.getLineNumber(J,z),Q=this.getColumn(J,z);this.checkExpression(G,K,Q)}let H=/@foreach\s*\((\w+)\s+(?:as|in)\s+(\w+)(?:\s*,\s*(\w+))?\)/g;while((q=H.exec(z))!==null){let[,G,J,K]=q,Q=q.index,U=this.getLineNumber(Q,z),W=this.getColumn(Q,z);if(!this.variables.has(G))this.addError(`Collection '${G}' is not defined`,U,W,q[0]);else{let V=this.variables.get(G);if(V.kind==="array"&&V.elementType)this.variables.set(J,V.elementType);else this.variables.set(J,{kind:"primitive",value:"any"});if(K)this.variables.set(K,{kind:"primitive",value:"number"})}}let B=/@unless\s*\(([^)]+)\)/g;while((q=B.exec(z))!==null){let G=q[1].trim(),J=q.index,K=this.getLineNumber(J,z),Q=this.getColumn(J,z);this.checkExpression(G,K,Q)}let D=/@switch\s*\(([^)]+)\)/g;while((q=D.exec(z))!==null){let G=q[1].trim(),J=q.index,K=this.getLineNumber(J,z),Q=this.getColumn(J,z);this.checkExpression(G,K,Q)}}resolvePropertyAccess(z){let j=z.split("."),q=this.variables.get(j[0])||{kind:"primitive",value:"any"};for(let H=1;H<j.length;H++){let B=j[H].replace(/\(\)$/,"");if(q.kind==="object"&&q.properties)if(q.properties[B])q=q.properties[B];else if(!this.options.allowAny)return{kind:"primitive",value:"undefined"};else q={kind:"primitive",value:"any"};else if(q.kind==="array"&&q.elementType)if(["length"].includes(B))q={kind:"primitive",value:"number"};else if(["map","filter","find","forEach","some","every","reduce"].includes(B))q={kind:"function",returnType:{kind:"primitive",value:"any"}};else if(["join"].includes(B))q={kind:"function",returnType:{kind:"primitive",value:"string"}};else q={kind:"primitive",value:"any"};else if(q.kind==="primitive"&&q.value==="string")if(["length"].includes(B))q={kind:"primitive",value:"number"};else if(["toUpperCase","toLowerCase","trim","slice","substring"].includes(B))q={kind:"function",returnType:{kind:"primitive",value:"string"}};else if(["split"].includes(B))q={kind:"function",returnType:{kind:"array",elementType:{kind:"primitive",value:"string"}}};else q={kind:"primitive",value:"any"};else q={kind:"primitive",value:"any"}}return q}isLiteral(z){let j=z.trim();if(j.startsWith('"')&&j.endsWith('"')||j.startsWith("'")&&j.endsWith("'")||j.startsWith("`")&&j.endsWith("`"))return!0;if(/^-?\d+(\.\d+)?$/.test(j))return!0;if(j==="true"||j==="false")return!0;if(j==="null"||j==="undefined")return!0;return!1}extractObjectLiteral(z){let j={},q=z.slice(1,-1).trim();if(!q)return j;let H=this.splitByComma(q);for(let B of H){let D=B.indexOf(":");if(D>0){let G=B.slice(0,D).trim(),J=B.slice(D+1).trim();j[G]=J}}return j}splitByComma(z){let j=[],q="",H=0,B=null;for(let D=0;D<z.length;D++){let G=z[D],J=D>0?z[D-1]:"";if((G==='"'||G==="'"||G==="`")&&J!=="\\"){if(B===G)B=null;else if(!B)B=G}if(!B){if(G==="{"||G==="["||G==="(")H++;if(G==="}"||G==="]"||G===")")H--;if(G===","&&H===0){j.push(q.trim()),q="";continue}}q+=G}if(q.trim())j.push(q.trim());return j}getLineNumber(z,j){return((j||"").slice(0,z).match(/\n/g)||[]).length+1}getColumn(z,j){let H=j.slice(0,z).lastIndexOf(`
4
4
  `);return z-H}addError(z,j,q,H,B,D){this.errors.push({message:z,file:this.currentFile,line:j,column:q,expression:H,expected:B,received:D,severity:"error"})}addWarning(z,j,q,H,B,D){let G={message:z,file:this.currentFile,line:j,column:q,expression:H,expected:B,received:D,severity:"warning"};if(this.options.strict)this.errors.push(G);else this.warnings.push(G)}getResult(){return{valid:this.errors.length===0,errors:this.errors,warnings:this.warnings,variables:new Map(this.variables)}}addVariable(z,j){this.variables.set(z,j)}reset(){if(this.errors=[],this.warnings=[],this.variables.clear(),this.options.includeBuiltins)Object.entries(X).forEach(([z,j])=>{this.variables.set(z,j)})}}function Z(z){return new Y(z)}function E(z,j){return Z(j).checkFile(z)}function I(z,j){return Z(j).checkTemplate(z)}function L(z){let j=[];for(let q of z.errors){if(j.push(`\x1B[31merror\x1B[0m: ${q.message}`),j.push(` --> ${q.file}:${q.line}:${q.column}`),q.expression)j.push(" |"),j.push(` | ${q.expression}`),j.push(" |");if(q.expected&&q.received)j.push(` expected: ${q.expected}`),j.push(` received: ${q.received}`);j.push("")}for(let q of z.warnings){if(j.push(`\x1B[33mwarning\x1B[0m: ${q.message}`),j.push(` --> ${q.file}:${q.line}:${q.column}`),q.expression)j.push(" |"),j.push(` | ${q.expression}`),j.push(" |");j.push("")}if(z.valid)j.push("\x1B[32m\u2713 No type errors found\x1B[0m");else j.push(`\x1B[31m\u2717 Found ${z.errors.length} error(s) and ${z.warnings.length} warning(s)\x1B[0m`);return j.join(`
5
5
  `)}
6
- export{Y as Af,Z as Bf,E as Cf,I as Df,L as Ef};
6
+ export{Y as Df,Z as Ef,E as Ff,I as Gf,L as Hf};
@@ -1,3 +1,3 @@
1
1
  // @bun
2
2
  import{Broadcast as D,BroadcastServer as U}from"ts-broadcasting";import{channel as b}from"ts-broadcasting";import{Broadcast as N,BroadcastServer as p}from"ts-broadcasting";var z=null,H=[];function X(){return z}async function Y(j){if(z)return z;let k=j.driver??"bun",q=j.host??"0.0.0.0",G=j.port??6001,J=j.scheme??"ws",E={verbose:j.verbose??!1,driver:k,default:k,connections:{[k]:{driver:k,host:q,port:G,scheme:J}}};return z=new U(E),D.setServer(z),await z.start(),z}async function Z(){for(let j of H)clearInterval(j);if(H.length=0,!z)return;await z.stop(),z=null}async function $(j){let k=await import(j),q=k.default??k;if(typeof q!=="function")throw Error(`routes/channels.ts must export a default function, got ${typeof q}`);let G=0;return q({channel(E,A){if(G++,A.authorize&&z)z.channels.channel(E,A.authorize);if(A.interval&&A.data){let L=A.event??`${E}.updated`,M=A.data,Q=setInterval(async()=>{try{let T=await M();V(E,L,T)}catch{}},A.interval);H.push(Q)}}}),G}var K=!1;function F(){if(z)return!0;if(!K)K=!0,console.warn("[stx] broadcast() called before server started \u2014 messages will be sent once broadcasting is ready");return!1}function V(j,k,q){if(!F())return;D.send(j,k,q)}function x(j,k,q){if(!F())return;D.toUser(j,k,q)}function C(j,k,q){if(!F())return;D.toUsers(j,k,q)}function S(j,k,q){if(!F())return;D.send(`private-${j}`,k,q)}function w(j,k,q){if(!F())return;D.presence(j,k,q)}
3
- export{X as Np,Y as Op,Z as Pp,$ as Qp,V as Rp,x as Sp,C as Tp,S as Up,w as Vp,b as Wp,N as Xp,p as Yp};
3
+ export{X as Mp,Y as Np,Z as Op,$ as Pp,V as Qp,x as Rp,C as Sp,S as Tp,w as Up,b as Vp,N as Wp,p as Xp};
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import{Se as O,Ve as Q}from"./chunk-87kx8byz.js";Q();function J(j){let q=j.pwa;if(!q?.enabled)return"";let A=q.manifest,z=q.icons?.outputDir?`/${q.icons.outputDir}`:"/pwa-icons",G=O(j),C=`
2
+ import{Se as O,Ve as Q}from"./chunk-psc3wfcf.js";Q();function J(j){let q=j.pwa;if(!q?.enabled)return"";let A=q.manifest,z=q.icons?.outputDir?`/${q.icons.outputDir}`:"/pwa-icons",G=O(j),C=`
3
3
  <!-- stx PWA Meta Tags -->
4
4
  <link rel="manifest" href="/manifest.json">
5
5
  <meta name="theme-color" content="${K(A?.themeColor||"#000000")}">
@@ -81,4 +81,4 @@ else {
81
81
  </div>
82
82
  ${U}
83
83
  `})}
84
- export{_ as In};
84
+ export{_ as Mn};
@@ -1,5 +1,5 @@
1
1
  // @bun
2
- import{mm as O,om as R,pm as f}from"./chunk-6y4gqs1q.js";function _(){let q=new Map;return{islands:q,register(j){q.set(j.id,j)},get(j){return q.get(j)},async hydrate(j){let w=q.get(j);if(!w||w.hydrated)return;if(w.hydrated=!0,typeof window<"u"&&typeof window.dispatchEvent==="function")window.dispatchEvent(new CustomEvent("stx:hydrate",{detail:{id:j,component:w.component}}))},async hydrateAll(){let j=Array.from(q.values()).filter((w)=>!w.hydrated).map((w)=>this.hydrate(w.id));await Promise.all(j)}}}function b(q){return`
2
+ import{pm as O,rm as R,sm as f}from"./chunk-jz73j3qs.js";function _(){let q=new Map;return{islands:q,register(j){q.set(j.id,j)},get(j){return q.get(j)},async hydrate(j){let w=q.get(j);if(!w||w.hydrated)return;if(w.hydrated=!0,typeof window<"u"&&typeof window.dispatchEvent==="function")window.dispatchEvent(new CustomEvent("stx:hydrate",{detail:{id:j,component:w.component}}))},async hydrateAll(){let j=Array.from(q.values()).filter((w)=>!w.hydrated).map((w)=>this.hydrate(w.id));await Promise.all(j)}}}function b(q){return`
3
3
  <script data-hydrate="${q}">
4
4
  (function() {
5
5
  const island = document.querySelector('[data-island="${q}"]');
@@ -228,4 +228,4 @@ else {
228
228
  ${JSON.stringify(j)}
229
229
  </script>
230
230
  `}var c={processPartialHydrationDirectives:D,processStaticDirectives:m,generatePartialHydrationCSS:H,generateIslandManifest:u,createIslandRegistry:_,hydrateIsland:h,hydrateByStrategy:S,hydrateAll:x,isHydrated:g,onHydrated:v};
231
- export{_ as aj,D as bj,H as cj,h as dj,S as ej,x as fj,g as gj,v as hj,m as ij,u as jj,c as kj};
231
+ export{_ as dj,D as ej,H as fj,h as gj,S as hj,x as ij,g as jj,v as kj,m as lj,u as mj,c as nj};