@ecopages/radiant 0.2.0 → 0.3.0-alpha.0

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 (413) hide show
  1. package/README.md +289 -34
  2. package/dist/chunk-0y78f8hj.js +4 -0
  3. package/dist/chunk-0y78f8hj.js.map +10 -0
  4. package/dist/chunk-0zq7e1ne.js +4 -0
  5. package/dist/chunk-0zq7e1ne.js.map +10 -0
  6. package/dist/chunk-13ydx769.js +4 -0
  7. package/dist/chunk-13ydx769.js.map +10 -0
  8. package/dist/chunk-147yvtsn.js +4 -0
  9. package/dist/chunk-147yvtsn.js.map +10 -0
  10. package/dist/chunk-17earqbr.js +4 -0
  11. package/dist/chunk-17earqbr.js.map +10 -0
  12. package/dist/chunk-1w1dm68j.js +4 -0
  13. package/dist/chunk-1w1dm68j.js.map +10 -0
  14. package/dist/chunk-2tgrfv09.js +4 -0
  15. package/dist/chunk-2tgrfv09.js.map +10 -0
  16. package/dist/chunk-3b033cgq.js +4 -0
  17. package/dist/chunk-3b033cgq.js.map +10 -0
  18. package/dist/chunk-42tyhfvh.js +4 -0
  19. package/dist/chunk-42tyhfvh.js.map +10 -0
  20. package/dist/chunk-4cc2syf5.js +4 -0
  21. package/dist/chunk-4cc2syf5.js.map +10 -0
  22. package/dist/chunk-4fqkmpra.js +4 -0
  23. package/dist/chunk-4fqkmpra.js.map +10 -0
  24. package/dist/chunk-4srpf0y5.js +4 -0
  25. package/dist/chunk-4srpf0y5.js.map +10 -0
  26. package/dist/chunk-57w3vmme.js +4 -0
  27. package/dist/chunk-57w3vmme.js.map +10 -0
  28. package/dist/chunk-5a2xez36.js +4 -0
  29. package/dist/chunk-5a2xez36.js.map +10 -0
  30. package/dist/chunk-5bym7y1d.js +4 -0
  31. package/dist/chunk-5bym7y1d.js.map +10 -0
  32. package/dist/chunk-5td6v9k3.js +4 -0
  33. package/dist/chunk-5td6v9k3.js.map +10 -0
  34. package/dist/chunk-60015zxq.js +4 -0
  35. package/dist/chunk-60015zxq.js.map +10 -0
  36. package/dist/chunk-60q4y3k5.js +4 -0
  37. package/dist/chunk-60q4y3k5.js.map +10 -0
  38. package/dist/chunk-6kdxrppw.js +4 -0
  39. package/dist/chunk-6kdxrppw.js.map +10 -0
  40. package/dist/chunk-6z34stya.js +4 -0
  41. package/dist/chunk-6z34stya.js.map +10 -0
  42. package/dist/chunk-73x7jpdd.js +4 -0
  43. package/dist/chunk-73x7jpdd.js.map +10 -0
  44. package/dist/chunk-84fc8cz9.js +4 -0
  45. package/dist/chunk-84fc8cz9.js.map +10 -0
  46. package/dist/chunk-8dexhy6c.js +4 -0
  47. package/dist/chunk-8dexhy6c.js.map +10 -0
  48. package/dist/chunk-8n2dhx28.js +4 -0
  49. package/dist/chunk-8n2dhx28.js.map +10 -0
  50. package/dist/chunk-8tvt04cm.js +4 -0
  51. package/dist/chunk-8tvt04cm.js.map +10 -0
  52. package/dist/chunk-8vak8w5w.js +4 -0
  53. package/dist/chunk-8vak8w5w.js.map +10 -0
  54. package/dist/chunk-8xy18qmz.js +4 -0
  55. package/dist/chunk-8xy18qmz.js.map +9 -0
  56. package/dist/chunk-9554n9t4.js +4 -0
  57. package/dist/chunk-9554n9t4.js.map +10 -0
  58. package/dist/chunk-9ascmjk3.js +4 -0
  59. package/dist/chunk-9ascmjk3.js.map +10 -0
  60. package/dist/chunk-9gjmqxp2.js +4 -0
  61. package/dist/chunk-9gjmqxp2.js.map +10 -0
  62. package/dist/chunk-a7hzs37s.js +4 -0
  63. package/dist/chunk-a7hzs37s.js.map +10 -0
  64. package/dist/chunk-aajhkdmn.js +4 -0
  65. package/dist/chunk-aajhkdmn.js.map +10 -0
  66. package/dist/chunk-agjb2a3r.js +4 -0
  67. package/dist/chunk-agjb2a3r.js.map +10 -0
  68. package/dist/chunk-ak97hp4w.js +4 -0
  69. package/dist/chunk-ak97hp4w.js.map +10 -0
  70. package/dist/chunk-bmhn4nbp.js +4 -0
  71. package/dist/chunk-bmhn4nbp.js.map +10 -0
  72. package/dist/chunk-c8vqg7r1.js +4 -0
  73. package/dist/chunk-c8vqg7r1.js.map +10 -0
  74. package/dist/chunk-cbvd18v1.js +4 -0
  75. package/dist/chunk-cbvd18v1.js.map +10 -0
  76. package/dist/chunk-chyn72n9.js +4 -0
  77. package/dist/chunk-chyn72n9.js.map +10 -0
  78. package/dist/chunk-cvz9mrxa.js +4 -0
  79. package/dist/chunk-cvz9mrxa.js.map +10 -0
  80. package/dist/chunk-d0n7njdy.js +4 -0
  81. package/dist/chunk-d0n7njdy.js.map +10 -0
  82. package/dist/chunk-d4v5qpxa.js +4 -0
  83. package/dist/chunk-d4v5qpxa.js.map +10 -0
  84. package/dist/chunk-d7hh3ze6.js +4 -0
  85. package/dist/chunk-d7hh3ze6.js.map +10 -0
  86. package/dist/chunk-d98q3myg.js +4 -0
  87. package/dist/chunk-d98q3myg.js.map +10 -0
  88. package/dist/chunk-dscj0sk9.js +4 -0
  89. package/dist/chunk-dscj0sk9.js.map +10 -0
  90. package/dist/chunk-dx1wqc00.js +4 -0
  91. package/dist/chunk-dx1wqc00.js.map +10 -0
  92. package/dist/chunk-g0gz7ypq.js +4 -0
  93. package/dist/chunk-g0gz7ypq.js.map +10 -0
  94. package/dist/chunk-hkmm3dj9.js +4 -0
  95. package/dist/chunk-hkmm3dj9.js.map +10 -0
  96. package/dist/chunk-hn4j8rt5.js +4 -0
  97. package/dist/chunk-hn4j8rt5.js.map +10 -0
  98. package/dist/chunk-jce9gqqw.js +4 -0
  99. package/dist/chunk-jce9gqqw.js.map +10 -0
  100. package/dist/chunk-jg20mzg8.js +4 -0
  101. package/dist/chunk-jg20mzg8.js.map +10 -0
  102. package/dist/chunk-jkb2y7c8.js +4 -0
  103. package/dist/chunk-jkb2y7c8.js.map +10 -0
  104. package/dist/chunk-k5hr781q.js +4 -0
  105. package/dist/chunk-k5hr781q.js.map +10 -0
  106. package/dist/chunk-ksv01cey.js +4 -0
  107. package/dist/chunk-ksv01cey.js.map +10 -0
  108. package/dist/chunk-mpjnqmbq.js +4 -0
  109. package/dist/chunk-mpjnqmbq.js.map +10 -0
  110. package/dist/chunk-mqxmfvyp.js +4 -0
  111. package/dist/chunk-mqxmfvyp.js.map +10 -0
  112. package/dist/chunk-ms6a9zdt.js +4 -0
  113. package/dist/chunk-ms6a9zdt.js.map +10 -0
  114. package/dist/chunk-nerd6fmg.js +4 -0
  115. package/dist/chunk-nerd6fmg.js.map +10 -0
  116. package/dist/chunk-nw171z6m.js +4 -0
  117. package/dist/chunk-nw171z6m.js.map +10 -0
  118. package/dist/chunk-p6pxdvkk.js +4 -0
  119. package/dist/chunk-p6pxdvkk.js.map +10 -0
  120. package/dist/chunk-paehjz94.js +4 -0
  121. package/dist/chunk-paehjz94.js.map +10 -0
  122. package/dist/chunk-par0t822.js +4 -0
  123. package/dist/chunk-par0t822.js.map +10 -0
  124. package/dist/chunk-qaagk55a.js +4 -0
  125. package/dist/chunk-qaagk55a.js.map +10 -0
  126. package/dist/chunk-qbnedp0y.js +4 -0
  127. package/dist/chunk-qbnedp0y.js.map +10 -0
  128. package/dist/chunk-qd28hvdx.js +4 -0
  129. package/dist/chunk-qd28hvdx.js.map +10 -0
  130. package/dist/chunk-qdj6r8jn.js +4 -0
  131. package/dist/chunk-qdj6r8jn.js.map +10 -0
  132. package/dist/chunk-qe6sjr27.js +4 -0
  133. package/dist/chunk-qe6sjr27.js.map +10 -0
  134. package/dist/chunk-r1cvaz1t.js +4 -0
  135. package/dist/chunk-r1cvaz1t.js.map +10 -0
  136. package/dist/chunk-r75y7ydb.js +4 -0
  137. package/dist/chunk-r75y7ydb.js.map +10 -0
  138. package/dist/chunk-s4qgct1z.js +4 -0
  139. package/dist/chunk-s4qgct1z.js.map +10 -0
  140. package/dist/chunk-scfk041e.js +4 -0
  141. package/dist/chunk-scfk041e.js.map +10 -0
  142. package/dist/chunk-t6x9e177.js +4 -0
  143. package/dist/chunk-t6x9e177.js.map +10 -0
  144. package/dist/chunk-t7a1bbxq.js +4 -0
  145. package/dist/chunk-t7a1bbxq.js.map +10 -0
  146. package/dist/chunk-tyysm4gk.js +4 -0
  147. package/dist/chunk-tyysm4gk.js.map +10 -0
  148. package/dist/chunk-vpfm9yw8.js +4 -0
  149. package/dist/chunk-vpfm9yw8.js.map +10 -0
  150. package/dist/chunk-w50v38rv.js +4 -0
  151. package/dist/chunk-w50v38rv.js.map +10 -0
  152. package/dist/chunk-x0522ksh.js +4 -0
  153. package/dist/chunk-x0522ksh.js.map +10 -0
  154. package/dist/chunk-xd1xn3vy.js +4 -0
  155. package/dist/chunk-xd1xn3vy.js.map +10 -0
  156. package/dist/chunk-zb7wh7w4.js +4 -0
  157. package/dist/chunk-zb7wh7w4.js.map +10 -0
  158. package/dist/chunk-zj9ez73m.js +4 -0
  159. package/dist/chunk-zj9ez73m.js.map +10 -0
  160. package/dist/context/context-consumer-bootstrap.d.ts +41 -0
  161. package/dist/context/context-consumer-bootstrap.js +3 -0
  162. package/dist/context/context-consumer-bootstrap.js.map +9 -0
  163. package/dist/context/context-consumer-runtime.d.ts +34 -0
  164. package/dist/context/context-consumer-runtime.js +3 -0
  165. package/dist/context/context-consumer-runtime.js.map +9 -0
  166. package/dist/context/context-provider.d.ts +50 -2
  167. package/dist/context/context-provider.js +2 -3
  168. package/dist/context/context-provider.js.map +3 -4
  169. package/dist/context/context-ssr-bridge.d.ts +16 -0
  170. package/dist/context/context-ssr-bridge.js +3 -0
  171. package/dist/context/context-ssr-bridge.js.map +9 -0
  172. package/dist/context/create-context.js +2 -3
  173. package/dist/context/create-context.js.map +3 -4
  174. package/dist/context/decorators/consume-context.d.ts +8 -4
  175. package/dist/context/decorators/consume-context.js +2 -3
  176. package/dist/context/decorators/consume-context.js.map +3 -4
  177. package/dist/context/decorators/context-selection-delivery.d.ts +1 -0
  178. package/dist/context/decorators/context-selection-delivery.js +3 -0
  179. package/dist/context/decorators/context-selection-delivery.js.map +9 -0
  180. package/dist/context/decorators/context-selector.d.ts +31 -8
  181. package/dist/context/decorators/context-selector.js +2 -3
  182. package/dist/context/decorators/context-selector.js.map +3 -4
  183. package/dist/context/decorators/legacy/consume-context.d.ts +1 -1
  184. package/dist/context/decorators/legacy/consume-context.js +2 -3
  185. package/dist/context/decorators/legacy/consume-context.js.map +3 -4
  186. package/dist/context/decorators/legacy/context-selector-field.d.ts +8 -0
  187. package/dist/context/decorators/legacy/context-selector-field.js +3 -0
  188. package/dist/context/decorators/legacy/context-selector-field.js.map +9 -0
  189. package/dist/context/decorators/legacy/context-selector.d.ts +3 -3
  190. package/dist/context/decorators/legacy/context-selector.js +2 -3
  191. package/dist/context/decorators/legacy/context-selector.js.map +3 -4
  192. package/dist/context/decorators/legacy/provide-context.d.ts +1 -1
  193. package/dist/context/decorators/legacy/provide-context.js +2 -3
  194. package/dist/context/decorators/legacy/provide-context.js.map +3 -4
  195. package/dist/context/decorators/on-context-update.d.ts +31 -0
  196. package/dist/context/decorators/on-context-update.js +3 -0
  197. package/dist/context/decorators/on-context-update.js.map +9 -0
  198. package/dist/context/decorators/provide-context.d.ts +12 -0
  199. package/dist/context/decorators/provide-context.js +2 -3
  200. package/dist/context/decorators/provide-context.js.map +3 -4
  201. package/dist/context/decorators/standard/consume-context.d.ts +1 -1
  202. package/dist/context/decorators/standard/consume-context.js +2 -3
  203. package/dist/context/decorators/standard/consume-context.js.map +3 -4
  204. package/dist/context/decorators/standard/context-selector-field.d.ts +8 -0
  205. package/dist/context/decorators/standard/context-selector-field.js +3 -0
  206. package/dist/context/decorators/standard/context-selector-field.js.map +9 -0
  207. package/dist/context/decorators/standard/context-selector.d.ts +4 -3
  208. package/dist/context/decorators/standard/context-selector.js +2 -3
  209. package/dist/context/decorators/standard/context-selector.js.map +3 -4
  210. package/dist/context/decorators/standard/provide-context.d.ts +1 -1
  211. package/dist/context/decorators/standard/provide-context.js +2 -3
  212. package/dist/context/decorators/standard/provide-context.js.map +3 -4
  213. package/dist/context/events.js +2 -3
  214. package/dist/context/events.js.map +3 -4
  215. package/dist/context/hydration-script.d.ts +17 -0
  216. package/dist/context/hydration-script.js +3 -0
  217. package/dist/context/hydration-script.js.map +9 -0
  218. package/dist/core/custom-element-metadata.d.ts +3 -0
  219. package/dist/core/custom-element-metadata.js +3 -0
  220. package/dist/core/custom-element-metadata.js.map +9 -0
  221. package/dist/core/hydration-codec.d.ts +24 -0
  222. package/dist/core/hydration-codec.js +3 -0
  223. package/dist/core/hydration-codec.js.map +9 -0
  224. package/dist/core/radiant-component-ssr.d.ts +29 -0
  225. package/dist/core/radiant-component-ssr.js +3 -0
  226. package/dist/core/radiant-component-ssr.js.map +9 -0
  227. package/dist/core/radiant-component.d.ts +106 -0
  228. package/dist/core/radiant-component.js +3 -0
  229. package/dist/core/radiant-component.js.map +9 -0
  230. package/dist/core/radiant-element.d.ts +217 -9
  231. package/dist/core/radiant-element.js +2 -3
  232. package/dist/core/radiant-element.js.map +3 -4
  233. package/dist/core/reactive-jsx-value.d.ts +10 -0
  234. package/dist/core/reactive-jsx-value.js +3 -0
  235. package/dist/core/reactive-jsx-value.js.map +9 -0
  236. package/dist/core/reactive-prop-metadata.d.ts +7 -0
  237. package/dist/core/reactive-prop-metadata.js +3 -0
  238. package/dist/core/reactive-prop-metadata.js.map +9 -0
  239. package/dist/core/slot-projection.d.ts +34 -0
  240. package/dist/core/slot-projection.js +3 -0
  241. package/dist/core/slot-projection.js.map +9 -0
  242. package/dist/core/ssr-hydration-binding.d.ts +14 -0
  243. package/dist/core/ssr-hydration-binding.js +2 -0
  244. package/dist/core/ssr-hydration-binding.js.map +9 -0
  245. package/dist/core/ssr-preparation.d.ts +18 -0
  246. package/dist/core/ssr-preparation.js +3 -0
  247. package/dist/core/ssr-preparation.js.map +9 -0
  248. package/dist/decorators/bound.js +2 -2
  249. package/dist/decorators/bound.js.map +3 -4
  250. package/dist/decorators/bridge.d.ts +8 -0
  251. package/dist/decorators/bridge.js +3 -0
  252. package/dist/decorators/bridge.js.map +9 -0
  253. package/dist/decorators/custom-element.js +2 -3
  254. package/dist/decorators/custom-element.js.map +3 -4
  255. package/dist/decorators/debounce.js +2 -2
  256. package/dist/decorators/debounce.js.map +3 -4
  257. package/dist/decorators/event.js +2 -3
  258. package/dist/decorators/event.js.map +3 -4
  259. package/dist/decorators/legacy/bound.js +2 -3
  260. package/dist/decorators/legacy/bound.js.map +3 -4
  261. package/dist/decorators/legacy/custom-element.js +2 -3
  262. package/dist/decorators/legacy/custom-element.js.map +3 -4
  263. package/dist/decorators/legacy/debounce.js +2 -3
  264. package/dist/decorators/legacy/debounce.js.map +3 -4
  265. package/dist/decorators/legacy/event.d.ts +1 -1
  266. package/dist/decorators/legacy/event.js +2 -2
  267. package/dist/decorators/legacy/event.js.map +3 -4
  268. package/dist/decorators/legacy/instance-initializers.d.ts +17 -0
  269. package/dist/decorators/legacy/instance-initializers.js +3 -0
  270. package/dist/decorators/legacy/instance-initializers.js.map +9 -0
  271. package/dist/decorators/legacy/on-event.d.ts +2 -11
  272. package/dist/decorators/legacy/on-event.js +2 -3
  273. package/dist/decorators/legacy/on-event.js.map +3 -4
  274. package/dist/decorators/legacy/on-updated.js +2 -3
  275. package/dist/decorators/legacy/on-updated.js.map +3 -4
  276. package/dist/decorators/legacy/query-slot.d.ts +3 -0
  277. package/dist/decorators/legacy/query-slot.js +3 -0
  278. package/dist/decorators/legacy/query-slot.js.map +9 -0
  279. package/dist/decorators/legacy/query.js +2 -3
  280. package/dist/decorators/legacy/query.js.map +3 -4
  281. package/dist/decorators/legacy/reactive-field.js +2 -3
  282. package/dist/decorators/legacy/reactive-field.js.map +3 -4
  283. package/dist/decorators/legacy/reactive-prop.d.ts +2 -1
  284. package/dist/decorators/legacy/reactive-prop.js +2 -3
  285. package/dist/decorators/legacy/reactive-prop.js.map +3 -4
  286. package/dist/decorators/legacy/signal.d.ts +10 -0
  287. package/dist/decorators/legacy/signal.js +3 -0
  288. package/dist/decorators/legacy/signal.js.map +9 -0
  289. package/dist/decorators/on-event.d.ts +3 -11
  290. package/dist/decorators/on-event.js +2 -3
  291. package/dist/decorators/on-event.js.map +3 -4
  292. package/dist/decorators/on-updated.js +2 -3
  293. package/dist/decorators/on-updated.js.map +3 -4
  294. package/dist/decorators/prop.d.ts +14 -0
  295. package/dist/decorators/prop.js +3 -0
  296. package/dist/decorators/prop.js.map +9 -0
  297. package/dist/decorators/query-slot.d.ts +13 -0
  298. package/dist/decorators/query-slot.js +3 -0
  299. package/dist/decorators/query-slot.js.map +9 -0
  300. package/dist/decorators/query.d.ts +4 -13
  301. package/dist/decorators/query.js +2 -3
  302. package/dist/decorators/query.js.map +3 -4
  303. package/dist/decorators/signal.d.ts +23 -0
  304. package/dist/decorators/signal.js +3 -0
  305. package/dist/decorators/signal.js.map +9 -0
  306. package/dist/decorators/standard/bound.js +2 -3
  307. package/dist/decorators/standard/bound.js.map +3 -4
  308. package/dist/decorators/standard/custom-element.js +2 -3
  309. package/dist/decorators/standard/custom-element.js.map +3 -4
  310. package/dist/decorators/standard/debounce.js +2 -3
  311. package/dist/decorators/standard/debounce.js.map +3 -4
  312. package/dist/decorators/standard/event.d.ts +1 -1
  313. package/dist/decorators/standard/event.js +2 -3
  314. package/dist/decorators/standard/event.js.map +3 -4
  315. package/dist/decorators/standard/on-event.d.ts +1 -11
  316. package/dist/decorators/standard/on-event.js +2 -3
  317. package/dist/decorators/standard/on-event.js.map +3 -4
  318. package/dist/decorators/standard/on-updated.js +2 -3
  319. package/dist/decorators/standard/on-updated.js.map +3 -4
  320. package/dist/decorators/standard/query-slot.d.ts +8 -0
  321. package/dist/decorators/standard/query-slot.js +3 -0
  322. package/dist/decorators/standard/query-slot.js.map +9 -0
  323. package/dist/decorators/standard/query.js +2 -3
  324. package/dist/decorators/standard/query.js.map +3 -4
  325. package/dist/decorators/standard/reactive-field.js +2 -3
  326. package/dist/decorators/standard/reactive-field.js.map +3 -4
  327. package/dist/decorators/standard/reactive-prop.d.ts +1 -1
  328. package/dist/decorators/standard/reactive-prop.js +2 -3
  329. package/dist/decorators/standard/reactive-prop.js.map +3 -4
  330. package/dist/decorators/standard/signal.d.ts +33 -0
  331. package/dist/decorators/standard/signal.js +3 -0
  332. package/dist/decorators/standard/signal.js.map +9 -0
  333. package/dist/decorators/state.d.ts +11 -0
  334. package/dist/decorators/state.js +3 -0
  335. package/dist/decorators/state.js.map +9 -0
  336. package/dist/helpers/create-event-listener.d.ts +28 -0
  337. package/dist/helpers/create-event-listener.js +3 -0
  338. package/dist/helpers/create-event-listener.js.map +9 -0
  339. package/dist/helpers/create-event.d.ts +9 -0
  340. package/dist/helpers/create-event.js +3 -0
  341. package/dist/helpers/create-event.js.map +9 -0
  342. package/dist/helpers/create-query-slot.d.ts +20 -0
  343. package/dist/helpers/create-query-slot.js +3 -0
  344. package/dist/helpers/create-query-slot.js.map +9 -0
  345. package/dist/helpers/create-query.d.ts +27 -0
  346. package/dist/helpers/create-query.js +3 -0
  347. package/dist/helpers/create-query.js.map +9 -0
  348. package/dist/helpers/debounce.d.ts +39 -0
  349. package/dist/helpers/debounce.js +3 -0
  350. package/dist/helpers/debounce.js.map +9 -0
  351. package/dist/helpers/index.d.ts +5 -0
  352. package/dist/helpers/index.js +3 -0
  353. package/dist/{mixins → helpers}/index.js.map +1 -1
  354. package/dist/index.d.ts +13 -5
  355. package/dist/index.js +2 -2
  356. package/dist/index.js.map +1 -1
  357. package/dist/server/context-ssr.d.ts +27 -0
  358. package/dist/server/context-ssr.js +3 -0
  359. package/dist/server/context-ssr.js.map +9 -0
  360. package/dist/server/install-light-dom-shim.d.ts +1 -0
  361. package/dist/server/install-light-dom-shim.js +3 -0
  362. package/dist/server/install-light-dom-shim.js.map +10 -0
  363. package/dist/server/light-dom-shim.d.ts +53 -0
  364. package/dist/server/light-dom-shim.js +3 -0
  365. package/dist/server/light-dom-shim.js.map +9 -0
  366. package/dist/server/project-root.d.ts +20 -0
  367. package/dist/server/project-root.js +3 -0
  368. package/dist/server/project-root.js.map +11 -0
  369. package/dist/server/render-component.d.ts +195 -0
  370. package/dist/server/render-component.js +3 -0
  371. package/dist/server/render-component.js.map +10 -0
  372. package/dist/signals/host-resource.d.ts +59 -0
  373. package/dist/signals/host-resource.js +3 -0
  374. package/dist/signals/host-resource.js.map +10 -0
  375. package/dist/signals/host-signal.d.ts +45 -0
  376. package/dist/signals/host-signal.js +3 -0
  377. package/dist/signals/host-signal.js.map +9 -0
  378. package/dist/signals/hydration-script.d.ts +11 -0
  379. package/dist/signals/hydration-script.js +3 -0
  380. package/dist/signals/hydration-script.js.map +9 -0
  381. package/dist/tools/escape-script-json.d.ts +5 -0
  382. package/dist/tools/escape-script-json.js +3 -0
  383. package/dist/tools/escape-script-json.js.map +9 -0
  384. package/dist/tools/event-emitter.js +2 -3
  385. package/dist/tools/event-emitter.js.map +3 -4
  386. package/dist/tools/index.d.ts +2 -0
  387. package/dist/tools/index.js +2 -2
  388. package/dist/tools/index.js.map +1 -1
  389. package/dist/tools/render-jsx-template.d.ts +5 -0
  390. package/dist/tools/render-jsx-template.js +3 -0
  391. package/dist/tools/render-jsx-template.js.map +9 -0
  392. package/dist/tools/stringify-typed.d.ts +4 -6
  393. package/dist/tools/stringify-typed.js +2 -3
  394. package/dist/tools/stringify-typed.js.map +3 -4
  395. package/dist/types.js +2 -2
  396. package/dist/types.js.map +3 -3
  397. package/dist/utils/attribute-utils.js +2 -3
  398. package/dist/utils/attribute-utils.js.map +3 -4
  399. package/dist/utils/index.js +2 -2
  400. package/dist/utils/index.js.map +1 -1
  401. package/package.json +97 -21
  402. package/size-budget.json +22 -0
  403. package/dist/decorators/reactive-field.d.ts +0 -6
  404. package/dist/decorators/reactive-field.js +0 -4
  405. package/dist/decorators/reactive-field.js.map +0 -10
  406. package/dist/decorators/reactive-prop.d.ts +0 -8
  407. package/dist/decorators/reactive-prop.js +0 -4
  408. package/dist/decorators/reactive-prop.js.map +0 -10
  409. package/dist/mixins/index.d.ts +0 -1
  410. package/dist/mixins/index.js +0 -3
  411. package/dist/mixins/with-kita.d.ts +0 -15
  412. package/dist/mixins/with-kita.js +0 -4
  413. package/dist/mixins/with-kita.js.map +0 -10
package/README.md CHANGED
@@ -1,45 +1,300 @@
1
1
  # Radiant
2
2
 
3
- Radiant is a minimalist web component library designed for simplicity and flexibility.
3
+ Radiant is a light-DOM custom element library.
4
4
 
5
- It leverages the light DOM, allowing components to be styled and manipulated with standard CSS and JavaScript, unlike traditional web components that use the shadow DOM.
5
+ It keeps browser primitives visible instead of wrapping them in a synthetic component model. You work with real custom elements, real DOM events, real attributes, and real light-DOM children. When you want JSX-backed rendering, SSR host serialization, and hydration, use `RadiantComponent`. When you want a more imperative base without JSX, use `RadiantElement`.
6
6
 
7
- This approach deviates from conventional [web component best practices](https://web.dev/articles/custom-elements-best-practices), offering a trade-off for a more streamlined development experience.
7
+ Radiant deliberately does not use shadow DOM by default. That makes styling, DOM inspection, and authored child content simpler, while giving up some of the encapsulation that conventional custom-element guidance usually prefers.
8
8
 
9
- Ideal for any kind of projects, Radiant provides a lightweight alternative to full web components implementations, reducing unnecessary overhead.
9
+ For the full docs site, see [radiant.ecopages.app](https://radiant.ecopages.app/).
10
10
 
11
- For more details, [see the docs page](https://radiant.ecopages.app/).
11
+ ## Installation
12
12
 
13
- ## How to install it
13
+ `@ecopages/radiant` currently expects both `@ecopages/signals` and `@ecopages/jsx` as peer dependencies.
14
+
15
+ Install all three packages:
14
16
 
15
17
  ```sh
16
- bun install @ecopages/radiant
18
+ bun install @ecopages/radiant @ecopages/signals @ecopages/jsx
19
+ ```
20
+
21
+ Important: even if you are starting from `RadiantElement`, the current package surface still depends on `@ecopages/jsx`.
22
+
23
+ ## RadiantComponent Mental Model
24
+
25
+ `RadiantComponent` is the structured JSX-first base class.
26
+
27
+ - `render()` returns the current JSX view.
28
+ - First connect automatically chooses between hydration and a fresh client render.
29
+ - `update()` reruns `render()` and commits the current view into the host immediately.
30
+ - `requestUpdate()` schedules one rerender in a microtask and coalesces repeated requests.
31
+ - `@prop(...)`, `@state`, and `@signal(...)` define reactive members.
32
+ - `@onUpdated(...)` is the bridge from reactive member changes to `update()` or `requestUpdate()` when the rendered structure needs to be recomputed.
33
+ - `this.bindings.key`, `this.$.key`, and `this.bind('key')` expose stable JSX bindings for reactive members.
34
+ - If `render()` is omitted, the base implementation behaves like `<slot />`, so authored light-DOM children pass through unchanged.
35
+ - Literal `<slot>` tags project authored light-DOM content, and `getSlotElement(...)`, `getSlotElements(...)`, or `@querySlot(...)` let component logic read the assigned elements.
36
+
37
+ The key distinction is this:
38
+
39
+ - Use bindings such as `this.$.count` when the shape of the view stays the same and only child values need to change.
40
+ - Use `update()` or `requestUpdate()` when a reactive change affects the structure of the JSX tree.
41
+
42
+ Signal and store reads performed directly inside `render()` also participate in rerender invalidation, so shared reactive data can drive `RadiantComponent` views without an extra wrapper layer.
43
+
44
+ ## Counter Example
45
+
46
+ This counter shows the intended `RadiantComponent` style for stable templates: public props stay explicit, internal state stays local, and bound child values update without forcing a full rerender of the whole template.
47
+
48
+ ```tsx
49
+ /** @jsxImportSource @ecopages/jsx */
50
+
51
+ import type { JsxCustomElementAttributes } from '@ecopages/jsx';
52
+ import { RadiantComponent, customElement, prop, state } from '@ecopages/radiant';
53
+
54
+ type CounterCardBindings = {
55
+ count: number;
56
+ label: string;
57
+ };
58
+
59
+ type CounterCardAttributes = {
60
+ label?: string;
61
+ };
62
+
63
+ @customElement('counter-card')
64
+ export class CounterCard extends RadiantComponent<CounterCardBindings> {
65
+ @prop({ type: String, defaultValue: 'Clicks' }) label!: string;
66
+ @state count = 0;
67
+
68
+ private readonly increment = () => {
69
+ this.count += 1;
70
+ };
71
+
72
+ override render() {
73
+ return (
74
+ <section>
75
+ <h2>{this.$.label}</h2>
76
+ <p>Count: {this.$.count}</p>
77
+ <button type="button" on:click={this.increment}>
78
+ Increment
79
+ </button>
80
+ </section>
81
+ );
82
+ }
83
+ }
84
+
85
+ declare module '@ecopages/jsx/jsx-runtime' {
86
+ interface JsxCustomIntrinsicElements {
87
+ 'counter-card': JsxCustomElementAttributes<HTMLElement, CounterCardAttributes>;
88
+ }
89
+ }
90
+ ```
91
+
92
+ How this works:
93
+
94
+ - `@prop(...)` makes `label` part of the component's public reactive property and attribute surface.
95
+ - `@state` is internal mutable state.
96
+ - `this.$.label` and `this.$.count` are cached JSX bindings, so those text positions can update directly when the underlying reactive members change.
97
+ - This example does not call `update()` because the view structure is stable. Only the bound child values change.
98
+ - The JSX intrinsic-element declaration uses a public attribute type that is narrower than the internal binding shape. That is usually the right split.
99
+
100
+ If the same type truly represents both internal bindings and public JSX attributes, you can reuse it for both. Otherwise, keep those contracts separate.
101
+
102
+ ### When To Call `update()`
103
+
104
+ Call `update()` or `requestUpdate()` when a reactive change affects which elements should exist, not just their child values.
105
+
106
+ ```ts
107
+ import { RadiantComponent, onUpdated, state } from '@ecopages/radiant';
108
+
109
+ export class ResultsPanel extends RadiantComponent<{ expanded: boolean }> {
110
+ @state expanded = false;
111
+
112
+ @onUpdated('expanded')
113
+ protected rerenderView(): void {
114
+ this.requestUpdate();
115
+ }
116
+ }
117
+ ```
118
+
119
+ Use `update()` when you want the rerender immediately. Use `requestUpdate()` when several changes may happen in the same turn and one final rerender is enough.
120
+
121
+ ## Reactive JSX Bindings
122
+
123
+ Bindings are the non-obvious part of the API, and they are worth being explicit about.
124
+
125
+ `RadiantComponent<Bindings>` and `RadiantElement<Bindings>` take a dedicated binding shape, not the full class type. That keeps the binding namespace limited to the reactive props or fields you want JSX to consume.
126
+
127
+ These three forms are equivalent:
128
+
129
+ - `this.bindings.count`
130
+ - `this.$.count`
131
+ - `this.bind('count')`
132
+
133
+ They all resolve through the same cached binding object.
134
+
135
+ Use bindings when:
136
+
137
+ - the rendered element structure stays the same
138
+ - only text, attribute, or child-value positions need to change
139
+ - you want the renderer to patch the owned child range instead of rerunning the whole component view
140
+
141
+ Use `@onUpdated(...)` with `update()` or `requestUpdate()` when the reactive change should rebuild the JSX tree.
142
+
143
+ ## SSR And Hydration
144
+
145
+ `RadiantComponent` has two SSR surfaces:
146
+
147
+ - `renderToString()` serializes the component view only.
148
+ - `renderHostToString()` serializes the custom-element host together with the current view.
149
+
150
+ In practice, `renderHostToString()` is the right default for full component SSR because it emits `<my-element>...</my-element>` instead of only the view fragment.
151
+
152
+ `hydrate: true` adds hydration markers for the component view. On first connect, the component checks for those markers and hydrates in place instead of doing a fresh client render.
153
+
154
+ Server runtime setup, fragment rendering helpers, and SSR-specific import guidance now live in [src/server/README.md](src/server/README.md).
155
+
156
+ For the client lifecycle and hydration flow diagram, see [src/core/README.md](src/core/README.md).
157
+
158
+ ## Event Handling
159
+
160
+ Radiant does not invent a synthetic event layer. JSX handlers and decorators work with the native browser event object directly.
161
+
162
+ | Use this | When you want | Runtime shape |
163
+ | -------------------- | ----------------------------------------------------------------- | ------------------------------------------------------------------------------------------------ |
164
+ | `on:*` in JSX | The normal event API | Auto-delegates a fixed allowlist of bubbling events and falls back to direct listeners otherwise |
165
+ | `on-native:*` in JSX | Exact element-level browser listener semantics | Always calls `addEventListener(...)` on that element |
166
+ | `@onEvent(...)` | Class-level listening from `RadiantElement` or `RadiantComponent` | Supports `selector`, `ref`, `window`, and `document` targets |
167
+ | `@event(...)` | A typed custom event emitter owned by the component | Dispatches a real `CustomEvent` from the host element |
168
+
169
+ ### How JSX Event Binding Works
170
+
171
+ `on:*` is the default JSX event API. For a fixed allowlist of bubbling events, Radiant attaches one listener per event type on the render root and dispatches to matched elements. For all other events, `on:*` attaches directly on the element.
172
+
173
+ Today the delegated allowlist is:
174
+
175
+ - `beforeinput`
176
+ - `click`
177
+ - `contextmenu`
178
+ - `dblclick`
179
+ - `focusin`
180
+ - `focusout`
181
+ - `input`
182
+ - `keydown`
183
+ - `keyup`
184
+ - `mousedown`
185
+ - `mouseout`
186
+ - `mouseover`
187
+ - `mouseup`
188
+ - `pointerdown`
189
+ - `pointerout`
190
+ - `pointerover`
191
+ - `pointerup`
192
+ - `touchend`
193
+ - `touchmove`
194
+ - `touchstart`
195
+
196
+ Use `on-native:*` when exact attachment semantics matter, such as when an ancestor may stop propagation before the delegated root listener runs or when you want to opt out of delegation for a supported bubbling event.
197
+
198
+ Events outside the allowlist, such as `focus`, `blur`, `scroll`, `load`, `invalid`, or `dragstart`, already attach directly when authored with `on:*`.
199
+
200
+ ### `@onEvent(...)`
201
+
202
+ At the class level, `@onEvent(...)` is the main decorator for incoming DOM events. It can listen to:
203
+
204
+ - descendants that match a CSS selector
205
+ - descendants marked with `data-ref`
206
+ - global `window` events
207
+ - global `document` events
208
+
209
+ ```tsx
210
+ /** @jsxImportSource @ecopages/jsx */
211
+
212
+ import { RadiantComponent, customElement, onEvent, state } from '@ecopages/radiant';
213
+
214
+ @customElement('keyboard-panel')
215
+ export class KeyboardPanel extends RadiantComponent<{ lastKey: string }> {
216
+ @state lastKey = 'none';
217
+
218
+ @onEvent({ document: true, type: 'keydown' })
219
+ protected onKeydown(event: KeyboardEvent): void {
220
+ this.lastKey = event.key;
221
+ }
222
+
223
+ override render() {
224
+ return <p>Last key: {this.$.lastKey}</p>;
225
+ }
226
+ }
17
227
  ```
18
228
 
19
- ## Import Structure
20
-
21
- | Folder/Module | Description |
22
- | ----------------------------- | --------------------------------------- |
23
- | `./` | Contains all modules. |
24
- | `./context` | Contains all modules related to contex. |
25
- | `./context/create-context` | Module for creating context. |
26
- | `./context/context-provider` | Module for providing context. |
27
- | `./context/consume-context` | Module for consuming context. |
28
- | `./context/provide-context` | Module for providing context. |
29
- | `./context/context-selector` | Module for selecting context. |
30
- | `./core` | Contains all core elements |
31
- | `./core/radiant-element` | Module for the Radiant Element. |
32
- | `./decorators` | Contains decorator modules. |
33
- | `./decorators/custom-element` | Decorator for custom elements. |
34
- | `./decorators/event` | Decorator for events. |
35
- | `./decorators/on-event` | Decorator for event handlers. |
36
- | `./decorators/on-updated` | Decorator for update handlers. |
37
- | `./decorators/query` | Decorator for querying elements. |
38
- | `./decorators/reactive-field` | Decorator for reactive fields. |
39
- | `./decorators/reactive-prop` | Decorator for reactive properties. |
40
- | `./mixins` | Contains mixin modules. |
41
- | `./mixins/with-kita` | Mixin for Kita functionality. |
42
- | `./tools` | Contains utility modules. |
43
- | `./tools/stringify-typed` | Utility for stringifying attributes. |
44
- | `./tools/event-emitter` | Utility for emitting events. |
45
- | `./utils` | Contains additional utility modules. |
229
+ Important: `@onEvent({ selector: ... })` and `@onEvent({ ref: ... })` currently check `event.target.matches(...)` directly. That means matching is strict against the original target, not ancestor-aware. If a nested element inside a button receives the click, the nested element must match for the handler to run.
230
+
231
+ Also note that selector- and ref-based `@onEvent(...)` handlers rely on bubbling. Use `focusin` and `focusout` instead of `focus` and `blur` for that pattern.
232
+
233
+ ### `@event(...)`
234
+
235
+ Outgoing component events use `@event(...)`, which gives the class a typed `EventEmitter`. Calling `.emit(detail)` dispatches a real `CustomEvent` from the host element.
236
+
237
+ ```ts
238
+ import type { EventEmitter } from '@ecopages/radiant/tools/event-emitter';
239
+ import { RadiantElement, customElement, event } from '@ecopages/radiant';
240
+
241
+ type SaveDetail = {
242
+ id: string;
243
+ };
244
+
245
+ @customElement('save-button')
246
+ export class SaveButton extends RadiantElement {
247
+ @event({ name: 'save-requested', bubbles: true, composed: true })
248
+ saveRequested!: EventEmitter<SaveDetail>;
249
+
250
+ requestSave(): void {
251
+ this.saveRequested.emit({ id: 'draft-1' });
252
+ }
253
+ }
254
+ ```
255
+
256
+ The mental model stays simple:
257
+
258
+ - DOM events come in through JSX handlers or `@onEvent(...)`
259
+ - component events go out through `@event(...)`
260
+ - both are ordinary browser events at runtime
261
+
262
+ ## Public Entry Points
263
+
264
+ These are the documented public import paths exposed by the package.
265
+
266
+ | Path | Use for |
267
+ | --------------------------------------------- | --------------------------------------------------------------------------------------------------------------- |
268
+ | `@ecopages/radiant` | Main client entrypoint. Re-exports `RadiantElement`, `RadiantComponent`, common decorators, and context helpers |
269
+ | `@ecopages/radiant/context` | Context-related exports as a grouped entrypoint |
270
+ | `@ecopages/radiant/context/create-context` | Creating context keys |
271
+ | `@ecopages/radiant/context/context-provider` | Low-level context provider class |
272
+ | `@ecopages/radiant/context/consume-context` | `@consumeContext(...)` decorator |
273
+ | `@ecopages/radiant/context/provide-context` | `@provideContext(...)` decorator |
274
+ | `@ecopages/radiant/context/context-selector` | `@contextSelector(...)` decorator — bind a field to context |
275
+ | `@ecopages/radiant/context/on-context-update` | `@onContextUpdate(...)` decorator — run a method on context change |
276
+ | `@ecopages/radiant/core/radiant-element` | Non-JSX reactive custom-element base |
277
+ | `@ecopages/radiant/core/radiant-component` | JSX-first component base |
278
+ | `@ecopages/radiant/signals/host-resource` | Low-level `HostResource`, `createHostResource(...)`, and `createResource(...)` helpers |
279
+ | `@ecopages/radiant/server/light-dom-shim` | Minimal SSR window and host-preparation helpers |
280
+ | `@ecopages/radiant/server/render-component` | Canonical component SSR helpers and metadata utilities |
281
+ | `@ecopages/radiant/server/project-root` | Project-root resolution helper for server adapters |
282
+ | `@ecopages/radiant/decorators/bound` | `@bound` |
283
+ | `@ecopages/radiant/decorators/custom-element` | `@customElement(...)` |
284
+ | `@ecopages/radiant/decorators/debounce` | `@debounce(...)` |
285
+ | `@ecopages/radiant/decorators/event` | `@event(...)` |
286
+ | `@ecopages/radiant/decorators/on-event` | `@onEvent(...)` |
287
+ | `@ecopages/radiant/decorators/on-updated` | `@onUpdated(...)` |
288
+ | `@ecopages/radiant/decorators/prop` | `@prop(...)` |
289
+ | `@ecopages/radiant/decorators/query` | `@query(...)` |
290
+ | `@ecopages/radiant/decorators/query-slot` | `@querySlot(...)` |
291
+ | `@ecopages/radiant/decorators/signal` | `@signal(...)` |
292
+ | `@ecopages/radiant/decorators/state` | `@state` |
293
+ | `@ecopages/radiant/tools/stringify-typed` | Typed attribute serialization helper |
294
+ | `@ecopages/radiant/tools/render-jsx-template` | Render a JSX template result into an existing host |
295
+ | `@ecopages/radiant/tools/escape-script-json` | Safe JSON-for-script serialization helper |
296
+ | `@ecopages/radiant/tools/event-emitter` | Low-level `EventEmitter` helper |
297
+
298
+ Import component bases, decorators, and context helpers from the root entrypoint. Import server and low-level tool helpers from their explicit public subpaths.
299
+
300
+ For SSR-specific guidance and examples, see [src/server/README.md](src/server/README.md).
@@ -0,0 +1,4 @@
1
+ import{Z as A}from"./chunk-5bym7y1d.js";import{ba as E}from"./chunk-bmhn4nbp.js";import{Na as z}from"./chunk-nerd6fmg.js";function K(k={}){return function(F,G){return z(E(k),A(k),F,G)}}
2
+ export{K as Y};
3
+
4
+ //# debugId=7E28710D2CFCA22564756E2164756E21
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/decorators/query-slot.ts"],
4
+ "sourcesContent": [
5
+ "import type { StandardOrLegacyFieldDecoratorArgs } from '../types';\nimport type { QuerySlotConfig } from '../helpers/create-query-slot';\nimport { querySlot as legacyQuerySlot } from './legacy/query-slot';\nimport { querySlot as standardQuerySlot } from './standard/query-slot';\nimport { fieldDecoratorBridge } from './bridge';\n\nexport type { QuerySlotConfig };\n\n/**\n * Queries projected light-DOM content assigned to a RadiantComponent slot.\n *\n * The decorator returns assigned elements from the default slot when `name` is\n * omitted, or from the named slot when `name` is provided. Results are cached\n * by default and automatically invalidated when slot projection changes.\n *\n * @param options Slot query options.\n */\nexport function querySlot<T extends Element | Element[]>(options: QuerySlotConfig = {}) {\n\treturn function (\n\t\tprotoOrTarget: StandardOrLegacyFieldDecoratorArgs['protoOrTarget'],\n\t\tnameOrContext: StandardOrLegacyFieldDecoratorArgs['nameOrContext'],\n\t): any {\n\t\treturn fieldDecoratorBridge(\n\t\t\tstandardQuerySlot(options),\n\t\t\tlegacyQuerySlot<T>(options),\n\t\t\tprotoOrTarget,\n\t\t\tnameOrContext,\n\t\t);\n\t};\n}\n"
6
+ ],
7
+ "mappings": "sIAiBO,GAAS,LAAwC,CAAC,EAA2B,CAAC,EAAG,CACvF,OAAO,QAAS,CACf,EACA,EACM,CACN,OAAO,EACN,EAAkB,CAAO,EACzB,EAAmB,CAAO,EAC1B,EACA,CACD",
8
+ "debugId": "7E28710D2CFCA22564756E2164756E21",
9
+ "names": []
10
+ }
@@ -0,0 +1,4 @@
1
+ import{Da as q}from"./chunk-tyysm4gk.js";import{Ea as v}from"./chunk-qdj6r8jn.js";import{Oa as j}from"./chunk-nerd6fmg.js";function I(f){return function(w,z,E){return j(v(f),q(f),w,z,E)}}
2
+ export{I as Ca};
3
+
4
+ //# debugId=4A933B29B129F75D64756E2164756E21
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/decorators/on-updated.ts"],
4
+ "sourcesContent": [
5
+ "import type { StandardOrLegacyMethodDecoratorArgs } from '../types';\nimport { onUpdated as legacyOnUpdated } from './legacy/on-updated';\nimport { onUpdated as standardOnUpdated } from './standard/on-updated';\nimport { methodDecoratorBridge } from './bridge';\n\n/**\n * A decorator to bind a method to the instance.\n */\nexport function onUpdated(keyOrKeys: string | string[]) {\n\treturn function (\n\t\tprotoOrTarget: StandardOrLegacyMethodDecoratorArgs['protoOrTarget'],\n\t\tnameOrContext: StandardOrLegacyMethodDecoratorArgs['nameOrContext'],\n\t\tdescriptor?: StandardOrLegacyMethodDecoratorArgs['descriptor'],\n\t): any {\n\t\treturn methodDecoratorBridge(\n\t\t\tstandardOnUpdated(keyOrKeys),\n\t\t\tlegacyOnUpdated(keyOrKeys),\n\t\t\tprotoOrTarget,\n\t\t\tnameOrContext,\n\t\t\tdescriptor,\n\t\t);\n\t};\n}\n"
6
+ ],
7
+ "mappings": "uIAQO,GAAS,LAAS,CAAC,EAA8B,CACvD,OAAO,QAAS,CACf,EACA,EACA,EACM,CACN,OAAO,EACN,EAAkB,CAAS,EAC3B,EAAgB,CAAS,EACzB,EACA,EACA,CACD",
8
+ "debugId": "4A933B29B129F75D64756E2164756E21",
9
+ "names": []
10
+ }
@@ -0,0 +1,4 @@
1
+ function J(G,H){let q=null,j=null,z,D=()=>{if(q!==null)clearTimeout(q),q=null},F=()=>{if(j===null)return z;let E=j;return j=null,D(),z=E(),z},B=function(...E){j=()=>G.apply(this,E),D(),q=setTimeout(()=>{F()},H)};return B.cancel=()=>{D(),j=null},B.flush=()=>{if(j===null)return z;return F()},B.pending=()=>j!==null,B}
2
+ export{J as qb};
3
+
4
+ //# debugId=ECC21E357978581264756E2164756E21
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/helpers/debounce.ts"],
4
+ "sourcesContent": [
5
+ "import type { Method } from '../types';\n\n/**\n * A debounced function with imperative helpers for controlling pending work.\n *\n * @typeParam T The wrapped callback type.\n */\nexport interface DebouncedFunction<T extends Method> {\n\t(...args: Parameters<T>): void;\n\n\t/**\n\t * Cancels the pending callback invocation, if one exists.\n\t */\n\tcancel(): void;\n\n\t/**\n\t * Immediately invokes the latest pending callback invocation.\n\t *\n\t * @returns The callback result when a call is pending, or the last completed\n\t * result when no call is pending.\n\t */\n\tflush(): ReturnType<T> | undefined;\n\n\t/**\n\t * Reports whether the callback currently has a scheduled invocation.\n\t *\n\t * @returns True when a call is pending.\n\t */\n\tpending(): boolean;\n}\n\n/**\n * Creates a debounced wrapper around a function.\n *\n * The returned function delays invocation until the configured timeout has\n * elapsed since the latest call. It also exposes helpers to cancel, flush,\n * and inspect pending work.\n *\n * @typeParam T The wrapped callback type.\n * @param callback The callback to debounce.\n * @param timeout The debounce timeout in milliseconds.\n * @returns A debounced wrapper around the callback.\n */\nexport function debounce<T extends Method>(callback: T, timeout: number): DebouncedFunction<T> {\n\tlet timeoutRef: ReturnType<typeof setTimeout> | null = null;\n\tlet pendingInvocation: (() => ReturnType<T>) | null = null;\n\tlet lastResult: ReturnType<T> | undefined;\n\n\tconst clearPendingCall = () => {\n\t\tif (timeoutRef !== null) {\n\t\t\tclearTimeout(timeoutRef);\n\t\t\ttimeoutRef = null;\n\t\t}\n\t};\n\n\tconst invoke = (): ReturnType<T> | undefined => {\n\t\tif (pendingInvocation === null) {\n\t\t\treturn lastResult;\n\t\t}\n\n\t\tconst invocation = pendingInvocation;\n\t\tpendingInvocation = null;\n\t\tclearPendingCall();\n\t\tlastResult = invocation();\n\n\t\treturn lastResult;\n\t};\n\n\tconst debounced = function (this: ThisParameterType<T>, ...args: Parameters<T>) {\n\t\tpendingInvocation = () => callback.apply(this, args) as ReturnType<T>;\n\t\tclearPendingCall();\n\t\ttimeoutRef = setTimeout(() => {\n\t\t\tinvoke();\n\t\t}, timeout);\n\t} as DebouncedFunction<T>;\n\n\tdebounced.cancel = () => {\n\t\tclearPendingCall();\n\t\tpendingInvocation = null;\n\t};\n\n\tdebounced.flush = () => {\n\t\tif (pendingInvocation === null) {\n\t\t\treturn lastResult;\n\t\t}\n\n\t\treturn invoke();\n\t};\n\n\tdebounced.pending = () => pendingInvocation !== null;\n\n\treturn debounced;\n}\n"
6
+ ],
7
+ "mappings": "AA2CO,SAAS,CAA0B,CAAC,EAAa,EAAuC,CAC9F,IAAI,EAAmD,KACnD,EAAkD,KAClD,EAEE,EAAmB,IAAM,CAC9B,GAAI,IAAe,KAClB,aAAa,CAAU,EACvB,EAAa,MAIT,EAAS,IAAiC,CAC/C,GAAI,IAAsB,KACzB,OAAO,EAGR,IAAM,EAAa,EAKnB,OAJA,EAAoB,KACpB,EAAiB,EACjB,EAAa,EAAW,EAEjB,GAGF,EAAY,QAAS,IAAgC,EAAqB,CAC/E,EAAoB,IAAM,EAAS,MAAM,KAAM,CAAI,EACnD,EAAiB,EACjB,EAAa,WAAW,IAAM,CAC7B,EAAO,GACL,CAAO,GAkBX,OAfA,EAAU,OAAS,IAAM,CACxB,EAAiB,EACjB,EAAoB,MAGrB,EAAU,MAAQ,IAAM,CACvB,GAAI,IAAsB,KACzB,OAAO,EAGR,OAAO,EAAO,GAGf,EAAU,QAAU,IAAM,IAAsB,KAEzC",
8
+ "debugId": "ECC21E357978581264756E2164756E21",
9
+ "names": []
10
+ }
@@ -0,0 +1,4 @@
1
+ import{k as w}from"./chunk-d0n7njdy.js";import{n as z}from"./chunk-4srpf0y5.js";import{Na as q}from"./chunk-nerd6fmg.js";function J(j){return function(E,F){return q(z(j),w(j),E,F)}}
2
+ export{J as j};
3
+
4
+ //# debugId=D437F2873D9864A764756E2164756E21
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/context/decorators/provide-context.ts"],
4
+ "sourcesContent": [
5
+ "import type { StandardOrLegacyFieldDecoratorArgs } from '../../types';\nimport type { AttributeTypeConstant } from '../../utils';\nimport type { UnknownContext } from '../types';\nimport { provideContext as legacyProvideContext } from './legacy/provide-context';\nimport { provideContext as standardProvideContext } from './standard/provide-context';\nimport { fieldDecoratorBridge } from '../../decorators/bridge';\n\nexport type ProvideContextOptions<T extends UnknownContext> = {\n\t/** Context token made available to descendant consumers. */\n\tcontext: T;\n\t/** Client-side default value installed before any SSR hydration is merged. */\n\tinitialValue?: T['__context__'];\n\t/** Attribute type used to opt the provider into SSR hydration. */\n\thydrate?: AttributeTypeConstant;\n\t/**\n\t * Projects the current provider value into an SSR-safe hydration payload.\n\t *\n\t * Use this when the live client context includes instances or other values\n\t * that should stay client-only. When `hydrate: Object` is active, the parsed\n\t * payload merges back into `initialValue`, so omitted members keep their\n\t * client-side defaults.\n\t */\n\tserialize?: (value: T['__context__']) => unknown;\n};\n\n/**\n * A decorator to provide a context to the target element.\n * @param options {@link ProvideContextOptions}\n * @returns\n */\nexport function provideContext<T extends UnknownContext>(options: ProvideContextOptions<T>) {\n\treturn function (\n\t\tprotoOrTarget: StandardOrLegacyFieldDecoratorArgs['protoOrTarget'],\n\t\tnameOrContext: StandardOrLegacyFieldDecoratorArgs['nameOrContext'],\n\t): any {\n\t\treturn fieldDecoratorBridge(\n\t\t\tstandardProvideContext(options),\n\t\t\tlegacyProvideContext(options),\n\t\t\tprotoOrTarget,\n\t\t\tnameOrContext,\n\t\t);\n\t};\n}\n"
6
+ ],
7
+ "mappings": "qIA8BO,GAAS,LAAwC,CAAC,EAAmC,CAC3F,OAAO,QAAS,CACf,EACA,EACM,CACN,OAAO,EACN,EAAuB,CAAO,EAC9B,EAAqB,CAAO,EAC5B,EACA,CACD",
8
+ "debugId": "D437F2873D9864A764756E2164756E21",
9
+ "names": []
10
+ }
@@ -0,0 +1,4 @@
1
+ import{H as G}from"./chunk-84fc8cz9.js";import{I as B,J as D,K as Q,L as U,M as V,N as W,O as X,P as Y,Q as Z,R as _}from"./chunk-9ascmjk3.js";import{X as K}from"./chunk-9554n9t4.js";import{ga as L}from"./chunk-8dexhy6c.js";import{gb as O}from"./chunk-ksv01cey.js";import{hasHydrationMarkers as F,hydrate as $,jsx as A,render as E}from"@ecopages/jsx";import{renderToString as J}from"@ecopages/jsx/server";import{Computed as T,subtle as I}from"@ecopages/signals";class v extends G{isRendering=!1;isFirstConnectPending=!1;isRenderScheduled=!1;needsRender=!1;projectedSlotContent=new Map;renderSignal;renderWatcher=new I.Watcher(()=>{this.requestUpdate()});slotProjectionObserver;slotProjectionVersion=0;ssr=new K({constructor:this.constructor,getAuthoredHydrationScriptMarkup:()=>this.getAuthoredHydrationScriptMarkup(),getHydrationBindings:()=>this.getHydrationBindings(),getSlotProjectionScriptTag:()=>this.getSlotProjectionScriptTag(),renderToString:(f)=>this.renderToString(f),getContextProviders:()=>this.getContextProviders(),getReactiveProperties:()=>this.getReactiveProperties(),getReactivePropDefinitions:()=>L(this),getPropertyValue:(f)=>this[f],listAttributeNames:()=>typeof this.getAttributeNames==="function"?this.getAttributeNames():[],getAttributeValue:(f)=>this.getAttribute(f)});connectedCallback(){if(super.connectedCallback(),this.isFirstConnectPending)return;this.isFirstConnectPending=!0,queueMicrotask(()=>{if(this.isFirstConnectPending=!1,!this.isConnected)return;if(this.ensureSlotProjectionState(),this.observeSlotProjection(),F(this)){if(this.needsRender=!1,this.hydrate(),this.needsRender)this.update();return}this.update()})}render(){return A("slot",{})}renderToString(f={}){return this.prepareForSsr(),J(this.resolveTrackedRenderOutput().value,f)}renderHost(){return this.ssr.renderHost()}renderHostToString(f={}){return this.ssr.renderHostToString(f,this.getHostSsrAttributes())}hydrate(){if(!this.isConnected||this.isRendering)return;this.isRendering=!0,this.disconnectSlotProjectionObserver();try{$(this.resolveTrackedRenderOutput().value,this)}finally{this.isRendering=!1,this.observeSlotProjection()}}requestUpdate(){if(this.needsRender=!0,this.isRenderScheduled)return;this.isRenderScheduled=!0,queueMicrotask(()=>{if(this.isRenderScheduled=!1,!this.needsRender)return;this.update()})}update(){if(this.needsRender=!0,!this.isConnected||this.isRendering)return;if(this.isFirstConnectPending&&F(this))return;while(this.needsRender&&this.isConnected){this.needsRender=!1,this.isRendering=!0,this.disconnectSlotProjectionObserver();try{E(this.resolveTrackedRenderOutput().value,this)}finally{this.isRendering=!1,this.observeSlotProjection()}}}disconnectedCallback(){this.disconnectSlotProjectionObserver(),this.disconnectRenderWatcher(),super.disconnectedCallback()}getSlotElement(f){return this.getSlotElements(f)[0]??null}getSlotElements(f){return this.ensureSlotProjectionState(),(this.projectedSlotContent.get(f??B)??[]).filter((q)=>typeof Node<"u"&&q instanceof Element)}shouldAutoBindReactiveMembers(){return!0}getHostSsrAttributes(){return this.ssr.getHostAttributes()}ensureSlotProjectionState(){if(this.projectedSlotContent.size>0)return;let f=this.isConnected?_(this):void 0;if(typeof f==="string"&&f!==""){this.projectedSlotContent=U(f),this.slotProjectionVersion+=1;return}if(this.getHostChildNodeCount()>0){this.projectedSlotContent=Q(this),this.slotProjectionVersion+=1;return}let q=typeof this.innerHTML==="string"?this.innerHTML:"";if(!this.isConnected&&q!=="")this.projectedSlotContent=V(q),this.slotProjectionVersion+=1}getHostChildNodeCount(){return"childNodes"in this&&this.childNodes?this.childNodes.length:0}getSlotProjectionScriptTag(){this.ensureSlotProjectionState();let f=Y(this.projectedSlotContent);if(!f)return;return`<script type="application/json" ${D}>${C(f)}</script>`}getAuthoredHydrationScriptMarkup(){let f=W(this);if(f)return f;let q=typeof this.innerHTML==="string"?this.innerHTML:"";if(q==="")return;return X(q)}handleSlotProjectionMutations(f){let q=!1;for(let w of f){for(let z of Array.from(w.removedNodes))if(this.removeProjectedSlotNode(z))q=!0;for(let z of Array.from(w.addedNodes)){if(z.parentNode!==this)continue;if(this.addProjectedSlotNode(z))q=!0}}if(q)this.slotProjectionVersion+=1,this.update()}addProjectedSlotNode(f){if(f instanceof HTMLScriptElement&&(f.hasAttribute(D)||f.hasAttribute(O)))return!1;let q=f instanceof Element?f.getAttribute("slot")??B:B,w=this.projectedSlotContent.get(q);if(w){if(w.includes(f))return!1;return w.push(f),!0}return this.projectedSlotContent.set(q,[f]),!0}removeProjectedSlotNode(f){for(let[q,w]of this.projectedSlotContent.entries()){let z=w.indexOf(f);if(z===-1)continue;if(w.splice(z,1),w.length===0)this.projectedSlotContent.delete(q);return!0}return!1}observeSlotProjection(){if(typeof MutationObserver>"u"||this.slotProjectionObserver||!this.isConnected)return;this.slotProjectionObserver=new MutationObserver((f)=>this.handleSlotProjectionMutations(f)),this.slotProjectionObserver.observe(this,{childList:!0})}disconnectSlotProjectionObserver(){this.slotProjectionObserver?.disconnect(),this.slotProjectionObserver=void 0}disconnectRenderWatcher(){if(!this.renderSignal)return;this.renderWatcher.unwatch(this.renderSignal),this.renderSignal=void 0}resolveTrackedRenderOutput(){let f=new T(()=>this.resolveRenderOutput()),q=f.get();if(!this.isConnected)return q;if(this.renderSignal)this.renderWatcher.unwatch(this.renderSignal);return this.renderSignal=f,this.renderWatcher.watch(f),q}resolveRenderOutput(){return this.ensureSlotProjectionState(),Z(this.render(),this.projectedSlotContent)}}function C(f){return f.replace(/</g,"\\u003c")}
2
+ export{v as G};
3
+
4
+ //# debugId=B0226C1DEFFA435E64756E2164756E21
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/core/radiant-component.ts"],
4
+ "sourcesContent": [
5
+ "import {\n\thasHydrationMarkers,\n\thydrate as hydrateJsx,\n\tjsx,\n\trender as renderJsx,\n\ttype JsxRenderable,\n} from '@ecopages/jsx';\nimport { renderToString as renderJsxToString, type RenderToStringOptions } from '@ecopages/jsx/server';\nimport { Computed, subtle } from '@ecopages/signals';\nimport { RadiantComponentSsrService } from './radiant-component-ssr';\nimport { getReactivePropDefinitions } from './reactive-prop-metadata';\nimport { RadiantElement } from './radiant-element';\nimport {\n\tDEFAULT_SLOT_NAME,\n\tSLOT_PROJECTION_SCRIPT_ATTRIBUTE,\n\tcollectAuthoredHydrationScriptMarkup,\n\tcollectAuthoredHydrationScriptMarkupFromHtml,\n\tcaptureProjectedSlotRenderables,\n\tdeserializeProjectedSlotRenderables,\n\tparseProjectedSlotRenderablesFromHtml,\n\tresolveSlotProjection,\n\tserializeProjectedSlotRenderables,\n\ttakeSlotProjectionScriptPayload,\n} from './slot-projection';\nimport { HYDRATION_ATTRIBUTE } from './hydration-codec';\n\n/**\n * A structured JSX-first Radiant base class.\n * @typeParam Bindings - Explicit internal bindable shape. Include only the\n * prop/state keys that JSX bindings should accept.\n *\n * Treat this as the component's internal reactive/bindable surface, not as the\n * default public custom-element attribute contract. When a component exposes a\n * narrower external API than its internal state, declare a separate public\n * props type for the JSX intrinsic element and keep internal-only state out of\n * that contract.\n *\n * Reusing the same type for both is fine only when the public props and the\n * bindable reactive members are intentionally the same surface.\n *\n * - `render()` describes the view.\n * - `update()` commits the current view into the host.\n * - first render happens automatically on connect.\n * - plain `@prop`, `@state`, and `@signal` reads performed during `render()`\n * participate in tracked rerender invalidation.\n * - `update()` and `requestUpdate()` remain available when a rerender should be\n * scheduled from imperative work outside those tracked reads.\n */\nexport class RadiantComponent<Bindings extends object = {}> extends RadiantElement<Bindings> {\n\tprivate isRendering = false;\n\tprivate isFirstConnectPending = false;\n\tprivate isRenderScheduled = false;\n\tprivate needsRender = false;\n\tprivate projectedSlotContent = new Map<string, JsxRenderable[]>();\n\tprivate renderSignal?: Computed<{ containsSlots: boolean; value: JsxRenderable }>;\n\tprivate readonly renderWatcher = new subtle.Watcher(() => {\n\t\tthis.requestUpdate();\n\t});\n\tprivate slotProjectionObserver?: MutationObserver;\n\tprivate slotProjectionVersion = 0;\n\tprivate readonly ssr = new RadiantComponentSsrService({\n\t\tconstructor: this.constructor as CustomElementConstructor,\n\t\tgetAuthoredHydrationScriptMarkup: () => this.getAuthoredHydrationScriptMarkup(),\n\t\tgetHydrationBindings: () => this.getHydrationBindings(),\n\t\tgetSlotProjectionScriptTag: () => this.getSlotProjectionScriptTag(),\n\t\trenderToString: (options) => this.renderToString(options),\n\t\tgetContextProviders: () => this.getContextProviders(),\n\t\tgetReactiveProperties: () => this.getReactiveProperties(),\n\t\tgetReactivePropDefinitions: () => getReactivePropDefinitions(this),\n\t\tgetPropertyValue: (name) => (this as Record<string, unknown>)[name],\n\t\tlistAttributeNames: () => (typeof this.getAttributeNames === 'function' ? this.getAttributeNames() : []),\n\t\tgetAttributeValue: (name) => this.getAttribute(name),\n\t});\n\n\toverride connectedCallback() {\n\t\tsuper.connectedCallback();\n\n\t\tif (this.isFirstConnectPending) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.isFirstConnectPending = true;\n\n\t\tqueueMicrotask(() => {\n\t\t\tthis.isFirstConnectPending = false;\n\n\t\t\tif (!this.isConnected) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tthis.ensureSlotProjectionState();\n\t\t\tthis.observeSlotProjection();\n\n\t\t\tif (hasHydrationMarkers(this)) {\n\t\t\t\tthis.needsRender = false;\n\t\t\t\tthis.hydrate();\n\n\t\t\t\tif (this.needsRender) {\n\t\t\t\t\tthis.update();\n\t\t\t\t}\n\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tthis.update();\n\t\t});\n\t}\n\n\t/**\n\t * Returns the current component view.\n\t *\n\t * The base implementation behaves like `<slot />`, so authored host children\n\t * pass through unchanged when a subclass does not override `render()`.\n\t */\n\tpublic render(): JsxRenderable {\n\t\treturn jsx('slot', {});\n\t}\n\n\t/**\n\t * Serializes the current component view into HTML.\n\t */\n\tpublic renderToString(options: RenderToStringOptions = {}): string {\n\t\tthis.prepareForSsr();\n\n\t\treturn renderJsxToString(this.resolveTrackedRenderOutput().value, options);\n\t}\n\n\t/**\n\t * Returns the component host and current view as a JSX element.\n\t */\n\tpublic renderHost(): JsxRenderable {\n\t\treturn this.ssr.renderHost();\n\t}\n\n\t/**\n\t * Serializes the component host and current view into HTML.\n\t */\n\tpublic renderHostToString(options: RenderToStringOptions = {}): string {\n\t\treturn this.ssr.renderHostToString(options, this.getHostSsrAttributes());\n\t}\n\n\t/**\n\t * Hydrates an SSR-rendered component view in place.\n\t */\n\tpublic hydrate(): void {\n\t\tif (!this.isConnected || this.isRendering) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.isRendering = true;\n\t\tthis.disconnectSlotProjectionObserver();\n\n\t\ttry {\n\t\t\thydrateJsx(this.resolveTrackedRenderOutput().value, this);\n\t\t} finally {\n\t\t\tthis.isRendering = false;\n\t\t\tthis.observeSlotProjection();\n\t\t}\n\t}\n\n\t/**\n\t * Queues a component rerender and coalesces repeated requests into the same\n\t * microtask.\n\t *\n\t * Use this when reactive state may change multiple times in the same turn and\n\t * the current view should refresh once with the final values.\n\t */\n\tpublic requestUpdate(): void {\n\t\tthis.needsRender = true;\n\n\t\tif (this.isRenderScheduled) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.isRenderScheduled = true;\n\n\t\tqueueMicrotask(() => {\n\t\t\tthis.isRenderScheduled = false;\n\n\t\t\tif (!this.needsRender) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tthis.update();\n\t\t});\n\t}\n\n\t/**\n\t * Explicitly rerenders the component into its host.\n\t */\n\tpublic update(): void {\n\t\tthis.needsRender = true;\n\n\t\tif (!this.isConnected || this.isRendering) {\n\t\t\treturn;\n\t\t}\n\n\t\tif (this.isFirstConnectPending && hasHydrationMarkers(this)) {\n\t\t\treturn;\n\t\t}\n\n\t\twhile (this.needsRender && this.isConnected) {\n\t\t\tthis.needsRender = false;\n\t\t\tthis.isRendering = true;\n\t\t\tthis.disconnectSlotProjectionObserver();\n\n\t\t\ttry {\n\t\t\t\trenderJsx(this.resolveTrackedRenderOutput().value, this);\n\t\t\t} finally {\n\t\t\t\tthis.isRendering = false;\n\t\t\t\tthis.observeSlotProjection();\n\t\t\t}\n\t\t}\n\t}\n\n\toverride disconnectedCallback() {\n\t\tthis.disconnectSlotProjectionObserver();\n\t\tthis.disconnectRenderWatcher();\n\t\tsuper.disconnectedCallback();\n\t}\n\n\t/**\n\t * Returns the first projected element assigned to the default or named slot.\n\t *\n\t * Use this when component logic needs direct access to authored light-DOM\n\t * content after projection.\n\t *\n\t * @param name Optional slot name. Omit for the default slot.\n\t */\n\tpublic getSlotElement<T extends Element = Element>(name?: string): T | null {\n\t\treturn (this.getSlotElements<T>(name)[0] ?? null) as T | null;\n\t}\n\n\t/**\n\t * Returns all projected elements assigned to the default or named slot.\n\t *\n\t * Text nodes are intentionally excluded so the result matches the element-\n\t * oriented query semantics used by Radiant decorators.\n\t *\n\t * @param name Optional slot name. Omit for the default slot.\n\t */\n\tpublic getSlotElements<T extends Element = Element>(name?: string): T[] {\n\t\tthis.ensureSlotProjectionState();\n\n\t\treturn (this.projectedSlotContent.get(name ?? DEFAULT_SLOT_NAME) ?? []).filter(\n\t\t\t(renderable): renderable is T => typeof Node !== 'undefined' && renderable instanceof Element,\n\t\t);\n\t}\n\n\tprotected override shouldAutoBindReactiveMembers(): boolean {\n\t\treturn true;\n\t}\n\n\tprotected getHostSsrAttributes(): Record<string, string> {\n\t\treturn this.ssr.getHostAttributes();\n\t}\n\n\tprivate ensureSlotProjectionState(): void {\n\t\tif (this.projectedSlotContent.size > 0) {\n\t\t\treturn;\n\t\t}\n\n\t\tconst scriptPayload = this.isConnected ? takeSlotProjectionScriptPayload(this) : undefined;\n\n\t\tif (typeof scriptPayload === 'string' && scriptPayload !== '') {\n\t\t\tthis.projectedSlotContent = deserializeProjectedSlotRenderables(scriptPayload);\n\t\t\tthis.slotProjectionVersion += 1;\n\t\t\treturn;\n\t\t}\n\n\t\tif (this.getHostChildNodeCount() > 0) {\n\t\t\tthis.projectedSlotContent = captureProjectedSlotRenderables(this);\n\t\t\tthis.slotProjectionVersion += 1;\n\t\t\treturn;\n\t\t}\n\n\t\tconst innerHtml = typeof this.innerHTML === 'string' ? this.innerHTML : '';\n\n\t\tif (!this.isConnected && innerHtml !== '') {\n\t\t\tthis.projectedSlotContent = parseProjectedSlotRenderablesFromHtml(innerHtml);\n\t\t\tthis.slotProjectionVersion += 1;\n\t\t}\n\t}\n\n\tprivate getHostChildNodeCount(): number {\n\t\treturn 'childNodes' in this && this.childNodes ? this.childNodes.length : 0;\n\t}\n\n\tprivate getSlotProjectionScriptTag(): string | undefined {\n\t\tthis.ensureSlotProjectionState();\n\t\tconst payload = serializeProjectedSlotRenderables(this.projectedSlotContent);\n\n\t\tif (!payload) {\n\t\t\treturn undefined;\n\t\t}\n\n\t\treturn `<script type=\"application/json\" ${SLOT_PROJECTION_SCRIPT_ATTRIBUTE}>${escapeScriptText(payload)}</script>`;\n\t}\n\n\tprivate getAuthoredHydrationScriptMarkup(): string | undefined {\n\t\tconst authoredHydrationMarkup = collectAuthoredHydrationScriptMarkup(this);\n\n\t\tif (authoredHydrationMarkup) {\n\t\t\treturn authoredHydrationMarkup;\n\t\t}\n\n\t\tconst innerHtml = typeof this.innerHTML === 'string' ? this.innerHTML : '';\n\n\t\tif (innerHtml === '') {\n\t\t\treturn undefined;\n\t\t}\n\n\t\treturn collectAuthoredHydrationScriptMarkupFromHtml(innerHtml);\n\t}\n\n\tprivate handleSlotProjectionMutations(records: MutationRecord[]): void {\n\t\tlet hasProjectionChanges = false;\n\n\t\tfor (const record of records) {\n\t\t\tfor (const removedNode of Array.from(record.removedNodes)) {\n\t\t\t\tif (this.removeProjectedSlotNode(removedNode)) {\n\t\t\t\t\thasProjectionChanges = true;\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tfor (const addedNode of Array.from(record.addedNodes)) {\n\t\t\t\tif (addedNode.parentNode !== this) {\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\tif (this.addProjectedSlotNode(addedNode)) {\n\t\t\t\t\thasProjectionChanges = true;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\tif (hasProjectionChanges) {\n\t\t\tthis.slotProjectionVersion += 1;\n\t\t\tthis.update();\n\t\t}\n\t}\n\n\tprivate addProjectedSlotNode(node: Node): boolean {\n\t\tif (\n\t\t\tnode instanceof HTMLScriptElement &&\n\t\t\t(node.hasAttribute(SLOT_PROJECTION_SCRIPT_ATTRIBUTE) || node.hasAttribute(HYDRATION_ATTRIBUTE))\n\t\t) {\n\t\t\treturn false;\n\t\t}\n\n\t\tconst slotName = node instanceof Element ? (node.getAttribute('slot') ?? DEFAULT_SLOT_NAME) : DEFAULT_SLOT_NAME;\n\t\tconst bucket = this.projectedSlotContent.get(slotName);\n\n\t\tif (bucket) {\n\t\t\tif (bucket.includes(node)) {\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\tbucket.push(node);\n\t\t\treturn true;\n\t\t}\n\n\t\tthis.projectedSlotContent.set(slotName, [node]);\n\t\treturn true;\n\t}\n\n\tprivate removeProjectedSlotNode(node: Node): boolean {\n\t\tfor (const [slotName, bucket] of this.projectedSlotContent.entries()) {\n\t\t\tconst nodeIndex = bucket.indexOf(node);\n\n\t\t\tif (nodeIndex === -1) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tbucket.splice(nodeIndex, 1);\n\n\t\t\tif (bucket.length === 0) {\n\t\t\t\tthis.projectedSlotContent.delete(slotName);\n\t\t\t}\n\n\t\t\treturn true;\n\t\t}\n\n\t\treturn false;\n\t}\n\n\tprivate observeSlotProjection(): void {\n\t\tif (typeof MutationObserver === 'undefined' || this.slotProjectionObserver || !this.isConnected) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.slotProjectionObserver = new MutationObserver((records) => this.handleSlotProjectionMutations(records));\n\t\tthis.slotProjectionObserver.observe(this, { childList: true });\n\t}\n\n\tprivate disconnectSlotProjectionObserver(): void {\n\t\tthis.slotProjectionObserver?.disconnect();\n\t\tthis.slotProjectionObserver = undefined;\n\t}\n\n\tprivate disconnectRenderWatcher(): void {\n\t\tif (!this.renderSignal) {\n\t\t\treturn;\n\t\t}\n\n\t\tthis.renderWatcher.unwatch(this.renderSignal);\n\t\tthis.renderSignal = undefined;\n\t}\n\n\tprivate resolveTrackedRenderOutput(): { containsSlots: boolean; value: JsxRenderable } {\n\t\tconst nextRenderSignal = new Computed(() => this.resolveRenderOutput());\n\t\tconst output = nextRenderSignal.get();\n\n\t\tif (!this.isConnected) {\n\t\t\treturn output;\n\t\t}\n\n\t\tif (this.renderSignal) {\n\t\t\tthis.renderWatcher.unwatch(this.renderSignal);\n\t\t}\n\n\t\tthis.renderSignal = nextRenderSignal;\n\t\tthis.renderWatcher.watch(nextRenderSignal);\n\t\treturn output;\n\t}\n\n\tprivate resolveRenderOutput(): { containsSlots: boolean; value: JsxRenderable } {\n\t\tthis.ensureSlotProjectionState();\n\t\treturn resolveSlotProjection(this.render(), this.projectedSlotContent);\n\t}\n}\n\nfunction escapeScriptText(value: string): string {\n\treturn value.replace(/</g, '\\\\u003c');\n}\n"
6
+ ],
7
+ "mappings": "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",
8
+ "debugId": "B0226C1DEFFA435E64756E2164756E21",
9
+ "names": []
10
+ }
@@ -0,0 +1,4 @@
1
+ var z;((j)=>{j.SUBSCRIPTION_REQUEST="context-subscription-request";j.CONTEXT_REQUEST="context-request";j.ON_MOUNT="context-on-mount";j.MOUNTED="context-mounted"})(z||={});class B extends Event{context;callback;subscribe;constructor(k,q,w){super("context-request",{bubbles:!0,composed:!0});this.context=k;this.callback=q;this.subscribe=w}}class D extends CustomEvent{constructor(k){super("context-on-mount",{detail:{context:k},bubbles:!0,composed:!0})}}class F extends Event{context;callback;select;subscribe;constructor(k,q,w,G){super("context-subscription-request",{bubbles:!0,composed:!0});this.context=k;this.callback=q;this.select=w;this.subscribe=G}}
2
+ export{z as C,B as D,D as E,F};
3
+
4
+ //# debugId=EBE34A5EDD44DA4464756E2164756E21
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/context/events.ts"],
4
+ "sourcesContent": [
5
+ "import type { Context, ContextCallback, ContextType, UnknownContext } from './types';\n\n/**\n * List of events which can be emitted by a context provider or requester.\n */\nexport enum ContextEventsTypes {\n\tSUBSCRIPTION_REQUEST = 'context-subscription-request',\n\tCONTEXT_REQUEST = 'context-request',\n\tON_MOUNT = 'context-on-mount',\n\tMOUNTED = 'context-mounted',\n}\n\n/**\n * An event fired by a context requester to signal it desires a named context.\n *\n * A provider should inspect the `context` property of the event to determine if it has a value that can\n * satisfy the request, calling the `callback` with the requested value if so.\n *\n * If the requested context event contains a truthy `subscribe` value, then a provider can call the callback\n * multiple times if the value is changed, if this is the case the provider should pass an `unsubscribe`\n * function to the callback which requesters can invoke to indicate they no longer wish to receive these updates.\n */\nexport class ContextRequestEvent<T extends UnknownContext> extends Event {\n\tpublic constructor(\n\t\tpublic readonly context: T,\n\t\tpublic readonly callback: ContextCallback<ContextType<T>>,\n\t\tpublic readonly subscribe?: boolean,\n\t) {\n\t\tsuper(ContextEventsTypes.CONTEXT_REQUEST, { bubbles: true, composed: true });\n\t}\n}\n\n/**\n * A type which represents a subscription to a context value.\n */\nexport type ContextSubscription<T extends UnknownContext> = {\n\tselect?: (context: ContextType<T>) => unknown;\n\tcallback: (value: unknown) => void;\n};\n\n/**\n * An event fired by a context provider to signal that a context value has been mounted and is available for consumption.\n */\nexport class ContextOnMountEvent extends CustomEvent<{ context: UnknownContext }> {\n\tpublic constructor(context: UnknownContext) {\n\t\tsuper(ContextEventsTypes.ON_MOUNT, {\n\t\t\tdetail: { context },\n\t\t\tbubbles: true,\n\t\t\tcomposed: true,\n\t\t});\n\t}\n}\n\n/**\n * An event fired by a context requester to signal it desires a named context.\n *\n * A provider should inspect the `context` property of the event to determine if it has a value that can\n * satisfy the request, calling the `callback` with the requested value if so.\n *\n * If the requested context event contains a truthy `subscribe` value, then a provider can call the callback\n * multiple times if the value is changed, if this is the case the provider should pass an `unsubscribe`\n * function to the callback which requesters can invoke to indicate they no longer wish to receive these updates.\n *\n * It accepts a `selector` property which can be used to request a specific property of the context value.\n */\nexport class ContextSubscriptionRequestEvent<T extends UnknownContext> extends Event {\n\tpublic constructor(\n\t\tpublic readonly context: T,\n\t\tpublic readonly callback: (value: ContextType<T> | { [K in keyof ContextType<T>]: ContextType<T>[K] }) => void,\n\t\tpublic readonly select?: (context: ContextType<T>) => unknown,\n\t\tpublic readonly subscribe?: boolean,\n\t) {\n\t\tsuper(ContextEventsTypes.SUBSCRIPTION_REQUEST, {\n\t\t\tbubbles: true,\n\t\t\tcomposed: true,\n\t\t});\n\t}\n}\n\ndeclare global {\n\tinterface HTMLElementEventMap {\n\t\t/**\n\t\t * A 'context-request-subscription' event can be emitted by any element which desires\n\t\t * a context value to be injected by an external provider.\n\t\t */\n\t\t[ContextEventsTypes.SUBSCRIPTION_REQUEST]: ContextSubscriptionRequestEvent<UnknownContext>;\n\t\t/**\n\t\t * A context-request-provider event can be emitted by a context requester to signal\n\t\t * that it desires a context value to be provided by a context provider.\n\t\t */\n\t\t[ContextEventsTypes.CONTEXT_REQUEST]: ContextRequestEvent<Context<unknown, unknown>>;\n\t\t/**\n\t\t * A 'context-mount' event can be emitted by a context provider to signal\n\t\t * that a context value has been mounted and is available for consumption.\n\t\t */\n\t\t[ContextEventsTypes.ON_MOUNT]: ContextOnMountEvent;\n\t}\n}\n"
6
+ ],
7
+ "mappings": "AAKO,IAAK,GAAL,CAAK,IAAL,CACN,uBAAuB,+BACvB,kBAAkB,kBAClB,WAAW,mBACX,UAAU,oBAJC,QAiBL,MAAM,UAAsD,KAAM,CAEvD,QACA,SACA,UAHV,WAAW,CACD,EACA,EACA,EACf,CACD,MAAM,kBAAoC,CAAE,QAAS,GAAM,SAAU,EAAK,CAAC,EAJ3D,eACA,gBACA,iBAIlB,CAaO,MAAM,UAA4B,WAAyC,CAC1E,WAAW,CAAC,EAAyB,CAC3C,MAAM,mBAA6B,CAClC,OAAQ,CAAE,SAAQ,EAClB,QAAS,GACT,SAAU,EACX,CAAC,EAEH,CAcO,MAAM,UAAkE,KAAM,CAEnE,QACA,SACA,OACA,UAJV,WAAW,CACD,EACA,EACA,EACA,EACf,CACD,MAAM,+BAAyC,CAC9C,QAAS,GACT,SAAU,EACX,CAAC,EARe,eACA,gBACA,cACA,iBAOlB",
8
+ "debugId": "EBE34A5EDD44DA4464756E2164756E21",
9
+ "names": []
10
+ }
@@ -0,0 +1,4 @@
1
+ import{ia as E}from"./chunk-qe6sjr27.js";import{ja as F}from"./chunk-scfk041e.js";import{Na as z}from"./chunk-nerd6fmg.js";function N(j){return function(G,H){return z(F(j),E(j),G,H)}}
2
+ export{N as ha};
3
+
4
+ //# debugId=32E7E97F8742520364756E2164756E21
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/decorators/query.ts"],
4
+ "sourcesContent": [
5
+ "import type { StandardOrLegacyFieldDecoratorArgs } from '../types';\nimport type { QueryConfig, QueryScope } from '../helpers/create-query';\nimport { query as legacyQuery } from './legacy/query';\nimport { query as standardQuery } from './standard/query';\nimport { fieldDecoratorBridge } from './bridge';\n\nexport type { QueryConfig, QueryScope };\n\n/**\n * A decorator to query by CSS selector or data-ref attribute.\n * By default it queries for the first element that matches the selector, but it can be configured to query for all elements.\n * It caches the result only when `cache` is enabled.\n * Queries run against the host light DOM by default, but can be directed to the shadow root or both trees.\n * @param options {@link QueryConfig} The options for the reactive property.\n */\nexport function query<T extends Element | Element[]>(options: QueryConfig) {\n\treturn function (\n\t\tprotoOrTarget: StandardOrLegacyFieldDecoratorArgs['protoOrTarget'],\n\t\tnameOrContext: StandardOrLegacyFieldDecoratorArgs['nameOrContext'],\n\t): any {\n\t\treturn fieldDecoratorBridge(standardQuery(options), legacyQuery<T>(options), protoOrTarget, nameOrContext);\n\t};\n}\n"
6
+ ],
7
+ "mappings": "uIAeO,GAAS,LAAoC,CAAC,EAAsB,CAC1E,OAAO,QAAS,CACf,EACA,EACM,CACN,OAAO,EAAqB,EAAc,CAAO,EAAG,EAAe,CAAO,EAAG,EAAe,CAAa",
8
+ "debugId": "32E7E97F8742520364756E2164756E21",
9
+ "names": []
10
+ }
@@ -0,0 +1,4 @@
1
+ import{La as k}from"./chunk-8tvt04cm.js";import{tb as q}from"./chunk-nw171z6m.js";function E(u){return(w,A,b)=>{let x=b.value;return k(w,(j)=>{q(j,u,x.bind(j))}),b}}
2
+ export{E as Ja};
3
+
4
+ //# debugId=1DF826E615F36F0264756E2164756E21
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/decorators/legacy/on-event.ts"],
4
+ "sourcesContent": [
5
+ "import type { RadiantElement } from '../../core/radiant-element';\nimport { createEventListener } from '../../helpers/create-event-listener';\nimport type { OnEventConfig } from '../on-event';\nimport { registerLegacyInstanceInitializer } from './instance-initializers';\n\n/**\n * A decorator to subscribe to an event on the target element.\n * The event listener will be automatically unsubscribed when the element is disconnected.\n *\n * Note: This decorator uses event delegation, which means it relies on event bubbling.\n * Therefore, it will not work with events that do not bubble, such as `focus`, `blur`, `load`, `unload`, `scroll`, etc.\n * For focus and blur events, consider using `focusin` and `focusout` which are similar but do bubble.\n *\n * @param eventConfig The event configuration.\n * @param eventConfig.selectors The CSS selector(s) of the target element(s).\n * @param eventConfig.ref The data-ref attribute of the target element.\n * @param eventConfig.type The type of the event to listen for.\n * @param eventConfig.options Optional. An options object that specifies characteristics about the event listener.\n */\nexport function onEvent(eventConfig: OnEventConfig) {\n\treturn (proto: RadiantElement, _: string, descriptor: PropertyDescriptor) => {\n\t\tconst originalMethod = descriptor.value;\n\n\t\tregisterLegacyInstanceInitializer(proto, (element) => {\n\t\t\tcreateEventListener(element, eventConfig, originalMethod.bind(element));\n\t\t});\n\n\t\treturn descriptor;\n\t};\n}\n"
6
+ ],
7
+ "mappings": "wFAmBO,GAAS,CAAO,CAAC,EAA4B,CACnD,MAAO,CAAC,EAAuB,EAAW,IAAmC,CAC5E,IAAM,EAAiB,EAAW,MAMlC,OAJA,EAAkC,EAAO,CAAC,IAAY,CACrD,EAAoB,EAAS,EAAa,EAAe,KAAK,CAAO,CAAC,EACtE,EAEM",
8
+ "debugId": "1DF826E615F36F0264756E2164756E21",
9
+ "names": []
10
+ }
@@ -0,0 +1,4 @@
1
+ import{pb as z}from"./chunk-qbnedp0y.js";function B(j,x){let y=new z(j,x);return j.registerEventEmitter(x.name,y),y}
2
+ export{B as ob};
3
+
4
+ //# debugId=F3608E2E8957998F64756E2164756E21
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/helpers/create-event.ts"],
4
+ "sourcesContent": [
5
+ "import type { RadiantElement } from '../core/radiant-element';\nimport { EventEmitter, type EventEmitterConfig } from '../tools/event-emitter';\n\n/**\n * Creates an EventEmitter bound to a host element and registers it on the host.\n * Functional equivalent of the `@event` decorator for vanilla JS usage.\n * @param host The host element that will dispatch the events.\n * @param config {@link EventEmitterConfig} The event emitter configuration.\n */\nexport function createEvent<T = unknown>(host: RadiantElement, config: EventEmitterConfig): EventEmitter<T> {\n\tconst emitter = new EventEmitter<T>(host, config);\n\thost.registerEventEmitter(config.name, emitter);\n\treturn emitter;\n}\n"
6
+ ],
7
+ "mappings": "yCASO,SAAS,CAAwB,CAAC,EAAsB,EAA6C,CAC3G,IAAM,EAAU,IAAI,EAAgB,EAAM,CAAM,EAEhD,OADA,EAAK,qBAAqB,EAAO,KAAM,CAAO,EACvC",
8
+ "debugId": "F3608E2E8957998F64756E2164756E21",
9
+ "names": []
10
+ }
@@ -0,0 +1,4 @@
1
+ var f=Symbol.for("@ecopages/radiant.ssr-context-provider-resolver");function h(){return globalThis}function i(d){h()[f]=d}function j(d){return h()[f]?.(d)}
2
+ export{i as ab,j as bb};
3
+
4
+ //# debugId=C6EAF0525222DDCD64756E2164756E21
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/context/context-ssr-bridge.ts"],
4
+ "sourcesContent": [
5
+ "import type { SsrSerializableContextProvider } from './context-provider';\nimport type { UnknownContext } from './types';\n\ntype SsrContextProviderResolver = (context: UnknownContext) => SsrSerializableContextProvider | undefined;\n\nconst SSR_CONTEXT_PROVIDER_RESOLVER_SYMBOL = Symbol.for('@ecopages/radiant.ssr-context-provider-resolver');\n\ntype GlobalResolverScope = typeof globalThis & {\n\t[SSR_CONTEXT_PROVIDER_RESOLVER_SYMBOL]?: SsrContextProviderResolver;\n};\n\nfunction getGlobalResolverScope(): GlobalResolverScope {\n\treturn globalThis as GlobalResolverScope;\n}\n\n/**\n * Installs the ambient SSR provider resolver used by shared context runtime helpers.\n *\n * Server-side rendering infrastructure owns the actual provider stack storage and\n * publishes a lookup function here so client/runtime code does not need to import\n * server-oriented modules.\n */\nexport function installSsrContextProviderResolver(resolver: SsrContextProviderResolver): void {\n\tgetGlobalResolverScope()[SSR_CONTEXT_PROVIDER_RESOLVER_SYMBOL] = resolver;\n}\n\n/**\n * Resolves an ambient SSR provider when a server render has published one.\n */\nexport function resolveAmbientSsrContextProvider(context: UnknownContext): SsrSerializableContextProvider | undefined {\n\treturn getGlobalResolverScope()[SSR_CONTEXT_PROVIDER_RESOLVER_SYMBOL]?.(context);\n}\n"
6
+ ],
7
+ "mappings": "AAKA,IAAM,EAAuC,OAAO,IAAI,iDAAiD,EAMzG,SAAS,CAAsB,EAAwB,CACtD,OAAO,WAUD,SAAS,CAAiC,CAAC,EAA4C,CAC7F,EAAuB,EAAE,GAAwC,EAM3D,SAAS,CAAgC,CAAC,EAAqE,CACrH,OAAO,EAAuB,EAAE,KAAwC,CAAO",
8
+ "debugId": "C6EAF0525222DDCD64756E2164756E21",
9
+ "names": []
10
+ }
@@ -0,0 +1,4 @@
1
+ import{ua as q}from"./chunk-t7a1bbxq.js";import{va as z}from"./chunk-paehjz94.js";import{Na as j}from"./chunk-nerd6fmg.js";function L(A,G){return j(z,q,A,G)}
2
+ export{L as ta};
3
+
4
+ //# debugId=D06059C72CCD77A564756E2164756E21
@@ -0,0 +1,10 @@
1
+ {
2
+ "version": 3,
3
+ "sources": ["../src/decorators/state.ts"],
4
+ "sourcesContent": [
5
+ "import type { StandardOrLegacyFieldDecoratorArgs } from '../types';\nimport { reactiveField as legacyReactiveField } from './legacy/reactive-field';\nimport { reactiveField as standardReactiveField } from './standard/reactive-field';\nimport { fieldDecoratorBridge } from './bridge';\n\n/**\n * Declares internal mutable component state.\n *\n * Each write triggers `notifyUpdate` so update callbacks, bindings, and\n * `RadiantComponent` renders stay in sync. When no explicit binding option\n * is supplied, `RadiantComponent` hosts expose a JSX companion binding\n * accessor automatically while plain `RadiantElement` hosts keep binding\n * opt-in.\n */\nexport function state(\n\tprotoOrTarget: StandardOrLegacyFieldDecoratorArgs['protoOrTarget'],\n\tnameOrContext: StandardOrLegacyFieldDecoratorArgs['nameOrContext'],\n): any {\n\treturn fieldDecoratorBridge(standardReactiveField, legacyReactiveField, protoOrTarget, nameOrContext);\n}\n"
6
+ ],
7
+ "mappings": "uIAcO,GAAS,LAAK,CACpB,EACA,EACM,CACN,OAAO,EAAqB,EAAuB,EAAqB,EAAe,CAAa",
8
+ "debugId": "D06059C72CCD77A564756E2164756E21",
9
+ "names": []
10
+ }