@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.
- package/README.md +289 -34
- package/dist/chunk-0y78f8hj.js +4 -0
- package/dist/chunk-0y78f8hj.js.map +10 -0
- package/dist/chunk-0zq7e1ne.js +4 -0
- package/dist/chunk-0zq7e1ne.js.map +10 -0
- package/dist/chunk-13ydx769.js +4 -0
- package/dist/chunk-13ydx769.js.map +10 -0
- package/dist/chunk-147yvtsn.js +4 -0
- package/dist/chunk-147yvtsn.js.map +10 -0
- package/dist/chunk-17earqbr.js +4 -0
- package/dist/chunk-17earqbr.js.map +10 -0
- package/dist/chunk-1w1dm68j.js +4 -0
- package/dist/chunk-1w1dm68j.js.map +10 -0
- package/dist/chunk-2tgrfv09.js +4 -0
- package/dist/chunk-2tgrfv09.js.map +10 -0
- package/dist/chunk-3b033cgq.js +4 -0
- package/dist/chunk-3b033cgq.js.map +10 -0
- package/dist/chunk-42tyhfvh.js +4 -0
- package/dist/chunk-42tyhfvh.js.map +10 -0
- package/dist/chunk-4cc2syf5.js +4 -0
- package/dist/chunk-4cc2syf5.js.map +10 -0
- package/dist/chunk-4fqkmpra.js +4 -0
- package/dist/chunk-4fqkmpra.js.map +10 -0
- package/dist/chunk-4srpf0y5.js +4 -0
- package/dist/chunk-4srpf0y5.js.map +10 -0
- package/dist/chunk-57w3vmme.js +4 -0
- package/dist/chunk-57w3vmme.js.map +10 -0
- package/dist/chunk-5a2xez36.js +4 -0
- package/dist/chunk-5a2xez36.js.map +10 -0
- package/dist/chunk-5bym7y1d.js +4 -0
- package/dist/chunk-5bym7y1d.js.map +10 -0
- package/dist/chunk-5td6v9k3.js +4 -0
- package/dist/chunk-5td6v9k3.js.map +10 -0
- package/dist/chunk-60015zxq.js +4 -0
- package/dist/chunk-60015zxq.js.map +10 -0
- package/dist/chunk-60q4y3k5.js +4 -0
- package/dist/chunk-60q4y3k5.js.map +10 -0
- package/dist/chunk-6kdxrppw.js +4 -0
- package/dist/chunk-6kdxrppw.js.map +10 -0
- package/dist/chunk-6z34stya.js +4 -0
- package/dist/chunk-6z34stya.js.map +10 -0
- package/dist/chunk-73x7jpdd.js +4 -0
- package/dist/chunk-73x7jpdd.js.map +10 -0
- package/dist/chunk-84fc8cz9.js +4 -0
- package/dist/chunk-84fc8cz9.js.map +10 -0
- package/dist/chunk-8dexhy6c.js +4 -0
- package/dist/chunk-8dexhy6c.js.map +10 -0
- package/dist/chunk-8n2dhx28.js +4 -0
- package/dist/chunk-8n2dhx28.js.map +10 -0
- package/dist/chunk-8tvt04cm.js +4 -0
- package/dist/chunk-8tvt04cm.js.map +10 -0
- package/dist/chunk-8vak8w5w.js +4 -0
- package/dist/chunk-8vak8w5w.js.map +10 -0
- package/dist/chunk-8xy18qmz.js +4 -0
- package/dist/chunk-8xy18qmz.js.map +9 -0
- package/dist/chunk-9554n9t4.js +4 -0
- package/dist/chunk-9554n9t4.js.map +10 -0
- package/dist/chunk-9ascmjk3.js +4 -0
- package/dist/chunk-9ascmjk3.js.map +10 -0
- package/dist/chunk-9gjmqxp2.js +4 -0
- package/dist/chunk-9gjmqxp2.js.map +10 -0
- package/dist/chunk-a7hzs37s.js +4 -0
- package/dist/chunk-a7hzs37s.js.map +10 -0
- package/dist/chunk-aajhkdmn.js +4 -0
- package/dist/chunk-aajhkdmn.js.map +10 -0
- package/dist/chunk-agjb2a3r.js +4 -0
- package/dist/chunk-agjb2a3r.js.map +10 -0
- package/dist/chunk-ak97hp4w.js +4 -0
- package/dist/chunk-ak97hp4w.js.map +10 -0
- package/dist/chunk-bmhn4nbp.js +4 -0
- package/dist/chunk-bmhn4nbp.js.map +10 -0
- package/dist/chunk-c8vqg7r1.js +4 -0
- package/dist/chunk-c8vqg7r1.js.map +10 -0
- package/dist/chunk-cbvd18v1.js +4 -0
- package/dist/chunk-cbvd18v1.js.map +10 -0
- package/dist/chunk-chyn72n9.js +4 -0
- package/dist/chunk-chyn72n9.js.map +10 -0
- package/dist/chunk-cvz9mrxa.js +4 -0
- package/dist/chunk-cvz9mrxa.js.map +10 -0
- package/dist/chunk-d0n7njdy.js +4 -0
- package/dist/chunk-d0n7njdy.js.map +10 -0
- package/dist/chunk-d4v5qpxa.js +4 -0
- package/dist/chunk-d4v5qpxa.js.map +10 -0
- package/dist/chunk-d7hh3ze6.js +4 -0
- package/dist/chunk-d7hh3ze6.js.map +10 -0
- package/dist/chunk-d98q3myg.js +4 -0
- package/dist/chunk-d98q3myg.js.map +10 -0
- package/dist/chunk-dscj0sk9.js +4 -0
- package/dist/chunk-dscj0sk9.js.map +10 -0
- package/dist/chunk-dx1wqc00.js +4 -0
- package/dist/chunk-dx1wqc00.js.map +10 -0
- package/dist/chunk-g0gz7ypq.js +4 -0
- package/dist/chunk-g0gz7ypq.js.map +10 -0
- package/dist/chunk-hkmm3dj9.js +4 -0
- package/dist/chunk-hkmm3dj9.js.map +10 -0
- package/dist/chunk-hn4j8rt5.js +4 -0
- package/dist/chunk-hn4j8rt5.js.map +10 -0
- package/dist/chunk-jce9gqqw.js +4 -0
- package/dist/chunk-jce9gqqw.js.map +10 -0
- package/dist/chunk-jg20mzg8.js +4 -0
- package/dist/chunk-jg20mzg8.js.map +10 -0
- package/dist/chunk-jkb2y7c8.js +4 -0
- package/dist/chunk-jkb2y7c8.js.map +10 -0
- package/dist/chunk-k5hr781q.js +4 -0
- package/dist/chunk-k5hr781q.js.map +10 -0
- package/dist/chunk-ksv01cey.js +4 -0
- package/dist/chunk-ksv01cey.js.map +10 -0
- package/dist/chunk-mpjnqmbq.js +4 -0
- package/dist/chunk-mpjnqmbq.js.map +10 -0
- package/dist/chunk-mqxmfvyp.js +4 -0
- package/dist/chunk-mqxmfvyp.js.map +10 -0
- package/dist/chunk-ms6a9zdt.js +4 -0
- package/dist/chunk-ms6a9zdt.js.map +10 -0
- package/dist/chunk-nerd6fmg.js +4 -0
- package/dist/chunk-nerd6fmg.js.map +10 -0
- package/dist/chunk-nw171z6m.js +4 -0
- package/dist/chunk-nw171z6m.js.map +10 -0
- package/dist/chunk-p6pxdvkk.js +4 -0
- package/dist/chunk-p6pxdvkk.js.map +10 -0
- package/dist/chunk-paehjz94.js +4 -0
- package/dist/chunk-paehjz94.js.map +10 -0
- package/dist/chunk-par0t822.js +4 -0
- package/dist/chunk-par0t822.js.map +10 -0
- package/dist/chunk-qaagk55a.js +4 -0
- package/dist/chunk-qaagk55a.js.map +10 -0
- package/dist/chunk-qbnedp0y.js +4 -0
- package/dist/chunk-qbnedp0y.js.map +10 -0
- package/dist/chunk-qd28hvdx.js +4 -0
- package/dist/chunk-qd28hvdx.js.map +10 -0
- package/dist/chunk-qdj6r8jn.js +4 -0
- package/dist/chunk-qdj6r8jn.js.map +10 -0
- package/dist/chunk-qe6sjr27.js +4 -0
- package/dist/chunk-qe6sjr27.js.map +10 -0
- package/dist/chunk-r1cvaz1t.js +4 -0
- package/dist/chunk-r1cvaz1t.js.map +10 -0
- package/dist/chunk-r75y7ydb.js +4 -0
- package/dist/chunk-r75y7ydb.js.map +10 -0
- package/dist/chunk-s4qgct1z.js +4 -0
- package/dist/chunk-s4qgct1z.js.map +10 -0
- package/dist/chunk-scfk041e.js +4 -0
- package/dist/chunk-scfk041e.js.map +10 -0
- package/dist/chunk-t6x9e177.js +4 -0
- package/dist/chunk-t6x9e177.js.map +10 -0
- package/dist/chunk-t7a1bbxq.js +4 -0
- package/dist/chunk-t7a1bbxq.js.map +10 -0
- package/dist/chunk-tyysm4gk.js +4 -0
- package/dist/chunk-tyysm4gk.js.map +10 -0
- package/dist/chunk-vpfm9yw8.js +4 -0
- package/dist/chunk-vpfm9yw8.js.map +10 -0
- package/dist/chunk-w50v38rv.js +4 -0
- package/dist/chunk-w50v38rv.js.map +10 -0
- package/dist/chunk-x0522ksh.js +4 -0
- package/dist/chunk-x0522ksh.js.map +10 -0
- package/dist/chunk-xd1xn3vy.js +4 -0
- package/dist/chunk-xd1xn3vy.js.map +10 -0
- package/dist/chunk-zb7wh7w4.js +4 -0
- package/dist/chunk-zb7wh7w4.js.map +10 -0
- package/dist/chunk-zj9ez73m.js +4 -0
- package/dist/chunk-zj9ez73m.js.map +10 -0
- package/dist/context/context-consumer-bootstrap.d.ts +41 -0
- package/dist/context/context-consumer-bootstrap.js +3 -0
- package/dist/context/context-consumer-bootstrap.js.map +9 -0
- package/dist/context/context-consumer-runtime.d.ts +34 -0
- package/dist/context/context-consumer-runtime.js +3 -0
- package/dist/context/context-consumer-runtime.js.map +9 -0
- package/dist/context/context-provider.d.ts +50 -2
- package/dist/context/context-provider.js +2 -3
- package/dist/context/context-provider.js.map +3 -4
- package/dist/context/context-ssr-bridge.d.ts +16 -0
- package/dist/context/context-ssr-bridge.js +3 -0
- package/dist/context/context-ssr-bridge.js.map +9 -0
- package/dist/context/create-context.js +2 -3
- package/dist/context/create-context.js.map +3 -4
- package/dist/context/decorators/consume-context.d.ts +8 -4
- package/dist/context/decorators/consume-context.js +2 -3
- package/dist/context/decorators/consume-context.js.map +3 -4
- package/dist/context/decorators/context-selection-delivery.d.ts +1 -0
- package/dist/context/decorators/context-selection-delivery.js +3 -0
- package/dist/context/decorators/context-selection-delivery.js.map +9 -0
- package/dist/context/decorators/context-selector.d.ts +31 -8
- package/dist/context/decorators/context-selector.js +2 -3
- package/dist/context/decorators/context-selector.js.map +3 -4
- package/dist/context/decorators/legacy/consume-context.d.ts +1 -1
- package/dist/context/decorators/legacy/consume-context.js +2 -3
- package/dist/context/decorators/legacy/consume-context.js.map +3 -4
- package/dist/context/decorators/legacy/context-selector-field.d.ts +8 -0
- package/dist/context/decorators/legacy/context-selector-field.js +3 -0
- package/dist/context/decorators/legacy/context-selector-field.js.map +9 -0
- package/dist/context/decorators/legacy/context-selector.d.ts +3 -3
- package/dist/context/decorators/legacy/context-selector.js +2 -3
- package/dist/context/decorators/legacy/context-selector.js.map +3 -4
- package/dist/context/decorators/legacy/provide-context.d.ts +1 -1
- package/dist/context/decorators/legacy/provide-context.js +2 -3
- package/dist/context/decorators/legacy/provide-context.js.map +3 -4
- package/dist/context/decorators/on-context-update.d.ts +31 -0
- package/dist/context/decorators/on-context-update.js +3 -0
- package/dist/context/decorators/on-context-update.js.map +9 -0
- package/dist/context/decorators/provide-context.d.ts +12 -0
- package/dist/context/decorators/provide-context.js +2 -3
- package/dist/context/decorators/provide-context.js.map +3 -4
- package/dist/context/decorators/standard/consume-context.d.ts +1 -1
- package/dist/context/decorators/standard/consume-context.js +2 -3
- package/dist/context/decorators/standard/consume-context.js.map +3 -4
- package/dist/context/decorators/standard/context-selector-field.d.ts +8 -0
- package/dist/context/decorators/standard/context-selector-field.js +3 -0
- package/dist/context/decorators/standard/context-selector-field.js.map +9 -0
- package/dist/context/decorators/standard/context-selector.d.ts +4 -3
- package/dist/context/decorators/standard/context-selector.js +2 -3
- package/dist/context/decorators/standard/context-selector.js.map +3 -4
- package/dist/context/decorators/standard/provide-context.d.ts +1 -1
- package/dist/context/decorators/standard/provide-context.js +2 -3
- package/dist/context/decorators/standard/provide-context.js.map +3 -4
- package/dist/context/events.js +2 -3
- package/dist/context/events.js.map +3 -4
- package/dist/context/hydration-script.d.ts +17 -0
- package/dist/context/hydration-script.js +3 -0
- package/dist/context/hydration-script.js.map +9 -0
- package/dist/core/custom-element-metadata.d.ts +3 -0
- package/dist/core/custom-element-metadata.js +3 -0
- package/dist/core/custom-element-metadata.js.map +9 -0
- package/dist/core/hydration-codec.d.ts +24 -0
- package/dist/core/hydration-codec.js +3 -0
- package/dist/core/hydration-codec.js.map +9 -0
- package/dist/core/radiant-component-ssr.d.ts +29 -0
- package/dist/core/radiant-component-ssr.js +3 -0
- package/dist/core/radiant-component-ssr.js.map +9 -0
- package/dist/core/radiant-component.d.ts +106 -0
- package/dist/core/radiant-component.js +3 -0
- package/dist/core/radiant-component.js.map +9 -0
- package/dist/core/radiant-element.d.ts +217 -9
- package/dist/core/radiant-element.js +2 -3
- package/dist/core/radiant-element.js.map +3 -4
- package/dist/core/reactive-jsx-value.d.ts +10 -0
- package/dist/core/reactive-jsx-value.js +3 -0
- package/dist/core/reactive-jsx-value.js.map +9 -0
- package/dist/core/reactive-prop-metadata.d.ts +7 -0
- package/dist/core/reactive-prop-metadata.js +3 -0
- package/dist/core/reactive-prop-metadata.js.map +9 -0
- package/dist/core/slot-projection.d.ts +34 -0
- package/dist/core/slot-projection.js +3 -0
- package/dist/core/slot-projection.js.map +9 -0
- package/dist/core/ssr-hydration-binding.d.ts +14 -0
- package/dist/core/ssr-hydration-binding.js +2 -0
- package/dist/core/ssr-hydration-binding.js.map +9 -0
- package/dist/core/ssr-preparation.d.ts +18 -0
- package/dist/core/ssr-preparation.js +3 -0
- package/dist/core/ssr-preparation.js.map +9 -0
- package/dist/decorators/bound.js +2 -2
- package/dist/decorators/bound.js.map +3 -4
- package/dist/decorators/bridge.d.ts +8 -0
- package/dist/decorators/bridge.js +3 -0
- package/dist/decorators/bridge.js.map +9 -0
- package/dist/decorators/custom-element.js +2 -3
- package/dist/decorators/custom-element.js.map +3 -4
- package/dist/decorators/debounce.js +2 -2
- package/dist/decorators/debounce.js.map +3 -4
- package/dist/decorators/event.js +2 -3
- package/dist/decorators/event.js.map +3 -4
- package/dist/decorators/legacy/bound.js +2 -3
- package/dist/decorators/legacy/bound.js.map +3 -4
- package/dist/decorators/legacy/custom-element.js +2 -3
- package/dist/decorators/legacy/custom-element.js.map +3 -4
- package/dist/decorators/legacy/debounce.js +2 -3
- package/dist/decorators/legacy/debounce.js.map +3 -4
- package/dist/decorators/legacy/event.d.ts +1 -1
- package/dist/decorators/legacy/event.js +2 -2
- package/dist/decorators/legacy/event.js.map +3 -4
- package/dist/decorators/legacy/instance-initializers.d.ts +17 -0
- package/dist/decorators/legacy/instance-initializers.js +3 -0
- package/dist/decorators/legacy/instance-initializers.js.map +9 -0
- package/dist/decorators/legacy/on-event.d.ts +2 -11
- package/dist/decorators/legacy/on-event.js +2 -3
- package/dist/decorators/legacy/on-event.js.map +3 -4
- package/dist/decorators/legacy/on-updated.js +2 -3
- package/dist/decorators/legacy/on-updated.js.map +3 -4
- package/dist/decorators/legacy/query-slot.d.ts +3 -0
- package/dist/decorators/legacy/query-slot.js +3 -0
- package/dist/decorators/legacy/query-slot.js.map +9 -0
- package/dist/decorators/legacy/query.js +2 -3
- package/dist/decorators/legacy/query.js.map +3 -4
- package/dist/decorators/legacy/reactive-field.js +2 -3
- package/dist/decorators/legacy/reactive-field.js.map +3 -4
- package/dist/decorators/legacy/reactive-prop.d.ts +2 -1
- package/dist/decorators/legacy/reactive-prop.js +2 -3
- package/dist/decorators/legacy/reactive-prop.js.map +3 -4
- package/dist/decorators/legacy/signal.d.ts +10 -0
- package/dist/decorators/legacy/signal.js +3 -0
- package/dist/decorators/legacy/signal.js.map +9 -0
- package/dist/decorators/on-event.d.ts +3 -11
- package/dist/decorators/on-event.js +2 -3
- package/dist/decorators/on-event.js.map +3 -4
- package/dist/decorators/on-updated.js +2 -3
- package/dist/decorators/on-updated.js.map +3 -4
- package/dist/decorators/prop.d.ts +14 -0
- package/dist/decorators/prop.js +3 -0
- package/dist/decorators/prop.js.map +9 -0
- package/dist/decorators/query-slot.d.ts +13 -0
- package/dist/decorators/query-slot.js +3 -0
- package/dist/decorators/query-slot.js.map +9 -0
- package/dist/decorators/query.d.ts +4 -13
- package/dist/decorators/query.js +2 -3
- package/dist/decorators/query.js.map +3 -4
- package/dist/decorators/signal.d.ts +23 -0
- package/dist/decorators/signal.js +3 -0
- package/dist/decorators/signal.js.map +9 -0
- package/dist/decorators/standard/bound.js +2 -3
- package/dist/decorators/standard/bound.js.map +3 -4
- package/dist/decorators/standard/custom-element.js +2 -3
- package/dist/decorators/standard/custom-element.js.map +3 -4
- package/dist/decorators/standard/debounce.js +2 -3
- package/dist/decorators/standard/debounce.js.map +3 -4
- package/dist/decorators/standard/event.d.ts +1 -1
- package/dist/decorators/standard/event.js +2 -3
- package/dist/decorators/standard/event.js.map +3 -4
- package/dist/decorators/standard/on-event.d.ts +1 -11
- package/dist/decorators/standard/on-event.js +2 -3
- package/dist/decorators/standard/on-event.js.map +3 -4
- package/dist/decorators/standard/on-updated.js +2 -3
- package/dist/decorators/standard/on-updated.js.map +3 -4
- package/dist/decorators/standard/query-slot.d.ts +8 -0
- package/dist/decorators/standard/query-slot.js +3 -0
- package/dist/decorators/standard/query-slot.js.map +9 -0
- package/dist/decorators/standard/query.js +2 -3
- package/dist/decorators/standard/query.js.map +3 -4
- package/dist/decorators/standard/reactive-field.js +2 -3
- package/dist/decorators/standard/reactive-field.js.map +3 -4
- package/dist/decorators/standard/reactive-prop.d.ts +1 -1
- package/dist/decorators/standard/reactive-prop.js +2 -3
- package/dist/decorators/standard/reactive-prop.js.map +3 -4
- package/dist/decorators/standard/signal.d.ts +33 -0
- package/dist/decorators/standard/signal.js +3 -0
- package/dist/decorators/standard/signal.js.map +9 -0
- package/dist/decorators/state.d.ts +11 -0
- package/dist/decorators/state.js +3 -0
- package/dist/decorators/state.js.map +9 -0
- package/dist/helpers/create-event-listener.d.ts +28 -0
- package/dist/helpers/create-event-listener.js +3 -0
- package/dist/helpers/create-event-listener.js.map +9 -0
- package/dist/helpers/create-event.d.ts +9 -0
- package/dist/helpers/create-event.js +3 -0
- package/dist/helpers/create-event.js.map +9 -0
- package/dist/helpers/create-query-slot.d.ts +20 -0
- package/dist/helpers/create-query-slot.js +3 -0
- package/dist/helpers/create-query-slot.js.map +9 -0
- package/dist/helpers/create-query.d.ts +27 -0
- package/dist/helpers/create-query.js +3 -0
- package/dist/helpers/create-query.js.map +9 -0
- package/dist/helpers/debounce.d.ts +39 -0
- package/dist/helpers/debounce.js +3 -0
- package/dist/helpers/debounce.js.map +9 -0
- package/dist/helpers/index.d.ts +5 -0
- package/dist/helpers/index.js +3 -0
- package/dist/{mixins → helpers}/index.js.map +1 -1
- package/dist/index.d.ts +13 -5
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/server/context-ssr.d.ts +27 -0
- package/dist/server/context-ssr.js +3 -0
- package/dist/server/context-ssr.js.map +9 -0
- package/dist/server/install-light-dom-shim.d.ts +1 -0
- package/dist/server/install-light-dom-shim.js +3 -0
- package/dist/server/install-light-dom-shim.js.map +10 -0
- package/dist/server/light-dom-shim.d.ts +53 -0
- package/dist/server/light-dom-shim.js +3 -0
- package/dist/server/light-dom-shim.js.map +9 -0
- package/dist/server/project-root.d.ts +20 -0
- package/dist/server/project-root.js +3 -0
- package/dist/server/project-root.js.map +11 -0
- package/dist/server/render-component.d.ts +195 -0
- package/dist/server/render-component.js +3 -0
- package/dist/server/render-component.js.map +10 -0
- package/dist/signals/host-resource.d.ts +59 -0
- package/dist/signals/host-resource.js +3 -0
- package/dist/signals/host-resource.js.map +10 -0
- package/dist/signals/host-signal.d.ts +45 -0
- package/dist/signals/host-signal.js +3 -0
- package/dist/signals/host-signal.js.map +9 -0
- package/dist/signals/hydration-script.d.ts +11 -0
- package/dist/signals/hydration-script.js +3 -0
- package/dist/signals/hydration-script.js.map +9 -0
- package/dist/tools/escape-script-json.d.ts +5 -0
- package/dist/tools/escape-script-json.js +3 -0
- package/dist/tools/escape-script-json.js.map +9 -0
- package/dist/tools/event-emitter.js +2 -3
- package/dist/tools/event-emitter.js.map +3 -4
- package/dist/tools/index.d.ts +2 -0
- package/dist/tools/index.js +2 -2
- package/dist/tools/index.js.map +1 -1
- package/dist/tools/render-jsx-template.d.ts +5 -0
- package/dist/tools/render-jsx-template.js +3 -0
- package/dist/tools/render-jsx-template.js.map +9 -0
- package/dist/tools/stringify-typed.d.ts +4 -6
- package/dist/tools/stringify-typed.js +2 -3
- package/dist/tools/stringify-typed.js.map +3 -4
- package/dist/types.js +2 -2
- package/dist/types.js.map +3 -3
- package/dist/utils/attribute-utils.js +2 -3
- package/dist/utils/attribute-utils.js.map +3 -4
- package/dist/utils/index.js +2 -2
- package/dist/utils/index.js.map +1 -1
- package/package.json +97 -21
- package/size-budget.json +22 -0
- package/dist/decorators/reactive-field.d.ts +0 -6
- package/dist/decorators/reactive-field.js +0 -4
- package/dist/decorators/reactive-field.js.map +0 -10
- package/dist/decorators/reactive-prop.d.ts +0 -8
- package/dist/decorators/reactive-prop.js +0 -4
- package/dist/decorators/reactive-prop.js.map +0 -10
- package/dist/mixins/index.d.ts +0 -1
- package/dist/mixins/index.js +0 -3
- package/dist/mixins/with-kita.d.ts +0 -15
- package/dist/mixins/with-kita.js +0 -4
- package/dist/mixins/with-kita.js.map +0 -10
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import type { Method } from '../types';
|
|
2
|
+
/**
|
|
3
|
+
* A debounced function with imperative helpers for controlling pending work.
|
|
4
|
+
*
|
|
5
|
+
* @typeParam T The wrapped callback type.
|
|
6
|
+
*/
|
|
7
|
+
export interface DebouncedFunction<T extends Method> {
|
|
8
|
+
(...args: Parameters<T>): void;
|
|
9
|
+
/**
|
|
10
|
+
* Cancels the pending callback invocation, if one exists.
|
|
11
|
+
*/
|
|
12
|
+
cancel(): void;
|
|
13
|
+
/**
|
|
14
|
+
* Immediately invokes the latest pending callback invocation.
|
|
15
|
+
*
|
|
16
|
+
* @returns The callback result when a call is pending, or the last completed
|
|
17
|
+
* result when no call is pending.
|
|
18
|
+
*/
|
|
19
|
+
flush(): ReturnType<T> | undefined;
|
|
20
|
+
/**
|
|
21
|
+
* Reports whether the callback currently has a scheduled invocation.
|
|
22
|
+
*
|
|
23
|
+
* @returns True when a call is pending.
|
|
24
|
+
*/
|
|
25
|
+
pending(): boolean;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* Creates a debounced wrapper around a function.
|
|
29
|
+
*
|
|
30
|
+
* The returned function delays invocation until the configured timeout has
|
|
31
|
+
* elapsed since the latest call. It also exposes helpers to cancel, flush,
|
|
32
|
+
* and inspect pending work.
|
|
33
|
+
*
|
|
34
|
+
* @typeParam T The wrapped callback type.
|
|
35
|
+
* @param callback The callback to debounce.
|
|
36
|
+
* @param timeout The debounce timeout in milliseconds.
|
|
37
|
+
* @returns A debounced wrapper around the callback.
|
|
38
|
+
*/
|
|
39
|
+
export declare function debounce<T extends Method>(callback: T, timeout: number): DebouncedFunction<T>;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import{ob as x}from"../chunk-42tyhfvh.js";import"../chunk-qbnedp0y.js";import{qb as t}from"../chunk-13ydx769.js";import{rb as c}from"../chunk-qd28hvdx.js";import{sb as b}from"../chunk-g0gz7ypq.js";import{tb as a}from"../chunk-nw171z6m.js";import"../chunk-8xy18qmz.js";export{t as debounce,c as createQuerySlot,b as createQuery,a as createEventListener,x as createEvent};
|
|
2
|
+
|
|
3
|
+
//# debugId=1A8607ADDD869B3264756E2164756E21
|
package/dist/index.d.ts
CHANGED
|
@@ -1,16 +1,24 @@
|
|
|
1
1
|
export * from './core/radiant-element';
|
|
2
|
+
export * from './core/radiant-component';
|
|
3
|
+
export * from './core/reactive-jsx-value';
|
|
4
|
+
export * from './decorators/bound';
|
|
2
5
|
export * from './decorators/custom-element';
|
|
6
|
+
export * from './decorators/debounce';
|
|
3
7
|
export * from './decorators/event';
|
|
4
8
|
export * from './decorators/on-event';
|
|
5
9
|
export * from './decorators/on-updated';
|
|
10
|
+
export * from './decorators/prop';
|
|
6
11
|
export * from './decorators/query';
|
|
7
|
-
export * from './decorators/
|
|
8
|
-
export * from './decorators/
|
|
12
|
+
export * from './decorators/query-slot';
|
|
13
|
+
export * from './decorators/signal';
|
|
14
|
+
export * from './decorators/state';
|
|
9
15
|
export * from './context/context-provider';
|
|
10
16
|
export * from './context/create-context';
|
|
11
17
|
export * from './context/decorators/consume-context';
|
|
12
18
|
export * from './context/decorators/context-selector';
|
|
19
|
+
export * from './context/decorators/on-context-update';
|
|
13
20
|
export * from './context/decorators/provide-context';
|
|
14
|
-
export * from './
|
|
15
|
-
export * from './
|
|
16
|
-
export * from './
|
|
21
|
+
export * from './helpers/create-query';
|
|
22
|
+
export * from './helpers/create-query-slot';
|
|
23
|
+
export * from './helpers/create-event';
|
|
24
|
+
export * from './helpers/create-event-listener';
|
package/dist/index.js
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import"./
|
|
1
|
+
import{f as p}from"./chunk-r1cvaz1t.js";import"./chunk-par0t822.js";import{h as n}from"./chunk-d7hh3ze6.js";import"./chunk-agjb2a3r.js";import{j as o}from"./chunk-147yvtsn.js";import"./chunk-d0n7njdy.js";import"./chunk-hkmm3dj9.js";import"./chunk-chyn72n9.js";import"./chunk-4srpf0y5.js";import{o as h}from"./chunk-jg20mzg8.js";import{p as a}from"./chunk-zb7wh7w4.js";import{q as l}from"./chunk-ak97hp4w.js";import"./chunk-d98q3myg.js";import"./chunk-qaagk55a.js";import"./chunk-5td6v9k3.js";import"./chunk-vpfm9yw8.js";import"./chunk-s4qgct1z.js";import"./chunk-1w1dm68j.js";import{G as S}from"./chunk-17earqbr.js";import{H as R}from"./chunk-84fc8cz9.js";import"./chunk-9ascmjk3.js";import{S as T}from"./chunk-mpjnqmbq.js";import"./chunk-6kdxrppw.js";import"./chunk-9554n9t4.js";import{Y as x}from"./chunk-0y78f8hj.js";import"./chunk-5bym7y1d.js";import"./chunk-9gjmqxp2.js";import"./chunk-bmhn4nbp.js";import{ca as d}from"./chunk-p6pxdvkk.js";import"./chunk-x0522ksh.js";import"./chunk-dscj0sk9.js";import"./chunk-8dexhy6c.js";import{ha as q}from"./chunk-2tgrfv09.js";import"./chunk-qe6sjr27.js";import"./chunk-scfk041e.js";import{ka as y}from"./chunk-c8vqg7r1.js";import"./chunk-t6x9e177.js";import"./chunk-5a2xez36.js";import{na as Y}from"./chunk-r75y7ydb.js";import"./chunk-a7hzs37s.js";import"./chunk-k5hr781q.js";import"./chunk-57w3vmme.js";import{ta as v}from"./chunk-4fqkmpra.js";import"./chunk-t7a1bbxq.js";import"./chunk-paehjz94.js";import{wa as U}from"./chunk-w50v38rv.js";import"./chunk-cbvd18v1.js";import"./chunk-xd1xn3vy.js";import{za as W}from"./chunk-mqxmfvyp.js";import"./chunk-hn4j8rt5.js";import"./chunk-8vak8w5w.js";import{Ca as $}from"./chunk-0zq7e1ne.js";import"./chunk-tyysm4gk.js";import"./chunk-qdj6r8jn.js";import{Fa as V}from"./chunk-60015zxq.js";import"./chunk-60q4y3k5.js";import"./chunk-zj9ez73m.js";import{Ia as _}from"./chunk-d4v5qpxa.js";import"./chunk-3b033cgq.js";import"./chunk-aajhkdmn.js";import"./chunk-8tvt04cm.js";import"./chunk-nerd6fmg.js";import"./chunk-73x7jpdd.js";import"./chunk-ms6a9zdt.js";import"./chunk-dx1wqc00.js";import"./chunk-4cc2syf5.js";import"./chunk-6z34stya.js";import"./chunk-ksv01cey.js";import"./chunk-8n2dhx28.js";import{ob as X}from"./chunk-42tyhfvh.js";import"./chunk-qbnedp0y.js";import"./chunk-13ydx769.js";import{rb as u}from"./chunk-qd28hvdx.js";import{sb as i}from"./chunk-g0gz7ypq.js";import{tb as Z}from"./chunk-nw171z6m.js";import"./chunk-8xy18qmz.js";export{v as state,y as signal,x as querySlot,q as query,o as provideContext,d as prop,$ as onUpdated,_ as onEvent,l as onContextUpdate,Y as event,W as debounce,V as customElement,u as createQuerySlot,i as createQuery,Z as createEventListener,X as createEvent,a as createContext,p as contextSelector,n as consumeContext,U as bound,T as bindReactiveValue,R as RadiantElement,S as RadiantComponent,h as ContextProvider};
|
|
2
2
|
|
|
3
|
-
//# debugId=
|
|
3
|
+
//# debugId=B6A1B7EED2B4CACB64756E2164756E21
|
package/dist/index.js.map
CHANGED
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { SsrSerializableContextProvider } from '../context/context-provider';
|
|
2
|
+
import type { ContextType, UnknownContext } from '../context/types';
|
|
3
|
+
/**
|
|
4
|
+
* Pushes a temporary provider frame onto the SSR context stack.
|
|
5
|
+
*
|
|
6
|
+
* On the server, each call creates an isolated `AsyncLocalStorage` context so
|
|
7
|
+
* concurrent renders cannot corrupt each other.
|
|
8
|
+
*
|
|
9
|
+
* In browser test environments where `AsyncLocalStorage` is unavailable, a
|
|
10
|
+
* synchronous global stack is used as a fallback.
|
|
11
|
+
*/
|
|
12
|
+
export declare function withSsrContextProviders(providers: readonly SsrSerializableContextProvider[]): () => void;
|
|
13
|
+
/**
|
|
14
|
+
* Resolves the nearest SSR-visible provider for a given context token.
|
|
15
|
+
*
|
|
16
|
+
* Lookup walks the provider frames from innermost to outermost so nested host
|
|
17
|
+
* serialization behaves the same way as runtime context resolution in the DOM.
|
|
18
|
+
*/
|
|
19
|
+
export declare function resolveSsrContextProvider<T extends UnknownContext>(context: T): SsrSerializableContextProvider | undefined;
|
|
20
|
+
/**
|
|
21
|
+
* Resolves the current SSR-visible value for a given context token.
|
|
22
|
+
*
|
|
23
|
+
* This is the ergonomic helper consumed by SSR-aware decorators and component
|
|
24
|
+
* render paths when they only need the context payload instead of the full
|
|
25
|
+
* provider instance.
|
|
26
|
+
*/
|
|
27
|
+
export declare function resolveSsrContextValue<T extends UnknownContext>(context: T): ContextType<T> | undefined;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../src/server/install-light-dom-shim.ts"],
|
|
4
|
+
"sourcesContent": [
|
|
5
|
+
"import { installLightDomShim } from './light-dom-shim';\n\ninstallLightDomShim();\n"
|
|
6
|
+
],
|
|
7
|
+
"mappings": "2EAEA,HAAoB",
|
|
8
|
+
"debugId": "C4400E1D9340C2EC64756E2164756E21",
|
|
9
|
+
"names": []
|
|
10
|
+
}
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
type MinimalCustomElementRegistry = {
|
|
2
|
+
define(name: string, constructor: CustomElementConstructor, options?: ElementDefinitionOptions): void;
|
|
3
|
+
get(name: string): CustomElementConstructor | undefined;
|
|
4
|
+
};
|
|
5
|
+
/**
|
|
6
|
+
* Minimal window-like runtime surface exposed by the SSR light-DOM shim.
|
|
7
|
+
*
|
|
8
|
+
* This is intentionally much smaller than a browser `window`; it only includes
|
|
9
|
+
* the constructors and registry access that Radiant SSR currently needs.
|
|
10
|
+
*/
|
|
11
|
+
export type LightDomShimWindow = {
|
|
12
|
+
/** Event constructor exposed to SSR-created components. */
|
|
13
|
+
CustomEvent: typeof CustomEvent;
|
|
14
|
+
/** Element constructor exposed to SSR-created components. */
|
|
15
|
+
Element: typeof Element;
|
|
16
|
+
/** Event constructor exposed to SSR-created components. */
|
|
17
|
+
Event: typeof Event;
|
|
18
|
+
/** EventTarget constructor exposed to SSR-created components. */
|
|
19
|
+
EventTarget: typeof EventTarget;
|
|
20
|
+
/** HTMLScriptElement constructor used by slot projection payload parsing. */
|
|
21
|
+
HTMLScriptElement: typeof HTMLScriptElement;
|
|
22
|
+
/** HTMLElement constructor exposed to SSR-created components. */
|
|
23
|
+
HTMLElement: typeof HTMLElement;
|
|
24
|
+
/** Node constructor exposed to SSR-created components. */
|
|
25
|
+
Node: typeof Node;
|
|
26
|
+
/** Custom element registry used while rendering in SSR. */
|
|
27
|
+
customElements: MinimalCustomElementRegistry;
|
|
28
|
+
};
|
|
29
|
+
/** Host preparation options accepted by the server render environment. */
|
|
30
|
+
export type PrepareServerRenderHostOptions = {
|
|
31
|
+
/** Serialized light-DOM content to attach to the host before SSR. */
|
|
32
|
+
authoredContent?: string;
|
|
33
|
+
};
|
|
34
|
+
/** Reusable SSR environment used to prepare component hosts before rendering. */
|
|
35
|
+
export type ServerRenderEnvironment = {
|
|
36
|
+
/** Prepares the host instance for rendering, including authored light-DOM content. */
|
|
37
|
+
prepareHost(host: HTMLElement, options?: PrepareServerRenderHostOptions): void;
|
|
38
|
+
};
|
|
39
|
+
/** Ensures that a minimal window-like SSR runtime is available and returns it. */
|
|
40
|
+
export declare function ensureLightDomShim(): LightDomShimWindow;
|
|
41
|
+
/**
|
|
42
|
+
* Creates a reusable SSR environment that can prepare a component host with
|
|
43
|
+
* authored light-DOM content before rendering.
|
|
44
|
+
*
|
|
45
|
+
* Adapters can reuse a single environment across multiple render calls when
|
|
46
|
+
* they want a single host-preparation entrypoint backed by the installed shim.
|
|
47
|
+
*/
|
|
48
|
+
export declare function createServerRenderEnvironment(): ServerRenderEnvironment;
|
|
49
|
+
/**
|
|
50
|
+
* Installs the smallest global surface needed to instantiate Radiant custom elements during SSR.
|
|
51
|
+
*/
|
|
52
|
+
export declare function installLightDomShim(): LightDomShimWindow;
|
|
53
|
+
export {};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Options that constrain how {@link resolveProjectRoot} searches ancestor
|
|
3
|
+
* directories.
|
|
4
|
+
*/
|
|
5
|
+
export type ResolveProjectRootOptions = {
|
|
6
|
+
/** Expected `package.json#name` value for the resolved project root. */
|
|
7
|
+
packageName?: string;
|
|
8
|
+
/** Additional relative paths that must exist inside the resolved directory. */
|
|
9
|
+
requiredPaths?: string[];
|
|
10
|
+
/** Starting directories to search upward from before giving up. */
|
|
11
|
+
startDirectories?: string[];
|
|
12
|
+
/** Absolute or relative directory where the upward search must stop. */
|
|
13
|
+
stopAt?: string;
|
|
14
|
+
};
|
|
15
|
+
/**
|
|
16
|
+
* Resolves the nearest ancestor directory that matches the provided package and
|
|
17
|
+
* path markers. Framework adapters can use this to find their project root
|
|
18
|
+
* without hardcoding a fixed number of parent-directory guesses.
|
|
19
|
+
*/
|
|
20
|
+
export declare function resolveProjectRoot(options?: ResolveProjectRootOptions): string;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import"../chunk-8xy18qmz.js";var{existsSync:T,readFileSync:U}=(()=>({}));function C(e){if(typeof e!=="string")throw TypeError("Path must be a string. Received "+JSON.stringify(e))}function w(e,f){var l="",n=0,i=-1,r=0,g;for(var u=0;u<=e.length;++u){if(u<e.length)g=e.charCodeAt(u);else if(g===47)break;else g=47;if(g===47){if(i===u-1||r===1);else if(i!==u-1&&r===2){if(l.length<2||n!==2||l.charCodeAt(l.length-1)!==46||l.charCodeAt(l.length-2)!==46){if(l.length>2){var v=l.lastIndexOf("/");if(v!==l.length-1){if(v===-1)l="",n=0;else l=l.slice(0,v),n=l.length-1-l.lastIndexOf("/");i=u,r=0;continue}}else if(l.length===2||l.length===1){l="",n=0,i=u,r=0;continue}}if(f){if(l.length>0)l+="/..";else l="..";n=2}}else{if(l.length>0)l+="/"+e.slice(i+1,u);else l=e.slice(i+1,u);n=u-i-1}i=u,r=0}else if(g===46&&r!==-1)++r;else r=-1}return l}function m(e,f){var l=f.dir||f.root,n=f.base||(f.name||"")+(f.ext||"");if(!l)return n;if(l===f.root)return l+n;return l+e+n}function b(){var e="",f=!1,l;for(var n=arguments.length-1;n>=-1&&!f;n--){var i;if(n>=0)i=arguments[n];else{if(l===void 0)l=process.cwd();i=l}if(C(i),i.length===0)continue;e=i+"/"+e,f=i.charCodeAt(0)===47}if(e=w(e,!f),f)if(e.length>0)return"/"+e;else return"/";else if(e.length>0)return e;else return"."}function L(e){if(C(e),e.length===0)return".";var f=e.charCodeAt(0)===47,l=e.charCodeAt(e.length-1)===47;if(e=w(e,!f),e.length===0&&!f)e=".";if(e.length>0&&l)e+="/";if(f)return"/"+e;return e}function _(e){return C(e),e.length>0&&e.charCodeAt(0)===47}function z(){if(arguments.length===0)return".";var e;for(var f=0;f<arguments.length;++f){var l=arguments[f];if(C(l),l.length>0)if(e===void 0)e=l;else e+="/"+l}if(e===void 0)return".";return L(e)}function S(e,f){if(C(e),C(f),e===f)return"";if(e=b(e),f=b(f),e===f)return"";var l=1;for(;l<e.length;++l)if(e.charCodeAt(l)!==47)break;var n=e.length,i=n-l,r=1;for(;r<f.length;++r)if(f.charCodeAt(r)!==47)break;var g=f.length,u=g-r,v=i<u?i:u,A=-1,s=0;for(;s<=v;++s){if(s===v){if(u>v){if(f.charCodeAt(r+s)===47)return f.slice(r+s+1);else if(s===0)return f.slice(r+s)}else if(i>v){if(e.charCodeAt(l+s)===47)A=s;else if(s===0)A=0}break}var t=e.charCodeAt(l+s),h=f.charCodeAt(r+s);if(t!==h)break;else if(t===47)A=s}var d="";for(s=l+A+1;s<=n;++s)if(s===n||e.charCodeAt(s)===47)if(d.length===0)d+="..";else d+="/..";if(d.length>0)return d+f.slice(r+A);else{if(r+=A,f.charCodeAt(r)===47)++r;return f.slice(r)}}function E(e){return e}function c(e){if(C(e),e.length===0)return".";var f=e.charCodeAt(0),l=f===47,n=-1,i=!0;for(var r=e.length-1;r>=1;--r)if(f=e.charCodeAt(r),f===47){if(!i){n=r;break}}else i=!1;if(n===-1)return l?"/":".";if(l&&n===1)return"//";return e.slice(0,n)}function B(e,f){if(f!==void 0&&typeof f!=="string")throw TypeError('"ext" argument must be a string');C(e);var l=0,n=-1,i=!0,r;if(f!==void 0&&f.length>0&&f.length<=e.length){if(f.length===e.length&&f===e)return"";var g=f.length-1,u=-1;for(r=e.length-1;r>=0;--r){var v=e.charCodeAt(r);if(v===47){if(!i){l=r+1;break}}else{if(u===-1)i=!1,u=r+1;if(g>=0)if(v===f.charCodeAt(g)){if(--g===-1)n=r}else g=-1,n=u}}if(l===n)n=u;else if(n===-1)n=e.length;return e.slice(l,n)}else{for(r=e.length-1;r>=0;--r)if(e.charCodeAt(r)===47){if(!i){l=r+1;break}}else if(n===-1)i=!1,n=r+1;if(n===-1)return"";return e.slice(l,n)}}function G(e){C(e);var f=-1,l=0,n=-1,i=!0,r=0;for(var g=e.length-1;g>=0;--g){var u=e.charCodeAt(g);if(u===47){if(!i){l=g+1;break}continue}if(n===-1)i=!1,n=g+1;if(u===46){if(f===-1)f=g;else if(r!==1)r=1}else if(f!==-1)r=-1}if(f===-1||n===-1||r===0||r===1&&f===n-1&&f===l+1)return"";return e.slice(f,n)}function H(e){if(e===null||typeof e!=="object")throw TypeError('The "pathObject" argument must be of type Object. Received type '+typeof e);return m("/",e)}function K(e){C(e);var f={root:"",dir:"",base:"",ext:"",name:""};if(e.length===0)return f;var l=e.charCodeAt(0),n=l===47,i;if(n)f.root="/",i=1;else i=0;var r=-1,g=0,u=-1,v=!0,A=e.length-1,s=0;for(;A>=i;--A){if(l=e.charCodeAt(A),l===47){if(!v){g=A+1;break}continue}if(u===-1)v=!1,u=A+1;if(l===46){if(r===-1)r=A;else if(s!==1)s=1}else if(r!==-1)s=-1}if(r===-1||u===-1||s===0||s===1&&r===u-1&&r===g+1){if(u!==-1)if(g===0&&n)f.base=f.name=e.slice(1,u);else f.base=f.name=e.slice(g,u)}else{if(g===0&&n)f.name=e.slice(1,r),f.base=e.slice(1,u);else f.name=e.slice(g,r),f.base=e.slice(g,u);f.ext=e.slice(r,u)}if(g>0)f.dir=e.slice(0,g-1);else if(n)f.dir="/";return f}var M="/",Q=":",$=((e)=>(e.posix=e,e))({resolve:b,normalize:L,isAbsolute:_,join:z,relative:S,_makeLong:E,dirname:c,basename:B,extname:G,format:H,parse:K,sep:M,delimiter:Q,win32:null,posix:null});function k(e={}){let f=Y(e.startDirectories?.length?e.startDirectories:[process.cwd(),import.meta.dirname]),l=b(e.stopAt??"/");for(let n of f){let i=V(n,l,e);if(i)return i}throw Error(Z(e,f))}function V(e,f,l){let n=b(e);for(;;){if(W(n,l))return n;if(n===f)return;let i=c(n);if(i===n)return;n=i}}function W(e,f){if(!X(e,f.packageName))return!1;return(f.requiredPaths??[]).every((l)=>T(b(e,l)))}function X(e,f){if(!f)return!0;let l=b(e,"package.json");if(!T(l))return!1;try{return JSON.parse(U(l,"utf8")).name===f}catch{return!1}}function Y(e){return Array.from(new Set(e.map((f)=>b(f))))}function Z(e,f){let l=[e.packageName?`package name ${JSON.stringify(e.packageName)}`:void 0,e.requiredPaths?.length?`paths ${e.requiredPaths.map((n)=>JSON.stringify(n)).join(", ")}`:void 0].filter((n)=>typeof n==="string").join(" and ");return`Unable to resolve a project root${l?` matching ${l}`:""} from ${f.join(", ")}.`}export{k as resolveProjectRoot};
|
|
2
|
+
|
|
3
|
+
//# debugId=092C65A79F3C884364756E2164756E21
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../src/server/project-root.ts", "node:path"],
|
|
4
|
+
"sourcesContent": [
|
|
5
|
+
"import { existsSync, readFileSync } from 'node:fs';\nimport { dirname, resolve } from 'node:path';\n\n/**\n * Options that constrain how {@link resolveProjectRoot} searches ancestor\n * directories.\n */\nexport type ResolveProjectRootOptions = {\n\t/** Expected `package.json#name` value for the resolved project root. */\n\tpackageName?: string;\n\t/** Additional relative paths that must exist inside the resolved directory. */\n\trequiredPaths?: string[];\n\t/** Starting directories to search upward from before giving up. */\n\tstartDirectories?: string[];\n\t/** Absolute or relative directory where the upward search must stop. */\n\tstopAt?: string;\n};\n\n/**\n * Resolves the nearest ancestor directory that matches the provided package and\n * path markers. Framework adapters can use this to find their project root\n * without hardcoding a fixed number of parent-directory guesses.\n */\nexport function resolveProjectRoot(options: ResolveProjectRootOptions = {}): string {\n\tconst candidateStarts = dedupeDirectories(\n\t\toptions.startDirectories?.length ? options.startDirectories : [process.cwd(), import.meta.dirname],\n\t);\n\tconst stopAt = resolve(options.stopAt ?? '/');\n\n\tfor (const startDirectory of candidateStarts) {\n\t\tconst resolvedRoot = resolveProjectRootFrom(startDirectory, stopAt, options);\n\n\t\tif (resolvedRoot) {\n\t\t\treturn resolvedRoot;\n\t\t}\n\t}\n\n\tthrow new Error(createResolveProjectRootError(options, candidateStarts));\n}\n\nfunction resolveProjectRootFrom(\n\tstartDirectory: string,\n\tstopAt: string,\n\toptions: ResolveProjectRootOptions,\n): string | undefined {\n\tlet currentDirectory = resolve(startDirectory);\n\n\tfor (;;) {\n\t\tif (matchesProjectRoot(currentDirectory, options)) {\n\t\t\treturn currentDirectory;\n\t\t}\n\n\t\tif (currentDirectory === stopAt) {\n\t\t\treturn undefined;\n\t\t}\n\n\t\tconst parentDirectory = dirname(currentDirectory);\n\n\t\tif (parentDirectory === currentDirectory) {\n\t\t\treturn undefined;\n\t\t}\n\n\t\tcurrentDirectory = parentDirectory;\n\t}\n}\n\nfunction matchesProjectRoot(directory: string, options: ResolveProjectRootOptions): boolean {\n\tif (!matchesPackageName(directory, options.packageName)) {\n\t\treturn false;\n\t}\n\n\treturn (options.requiredPaths ?? []).every((requiredPath) => existsSync(resolve(directory, requiredPath)));\n}\n\nfunction matchesPackageName(directory: string, packageName: string | undefined): boolean {\n\tif (!packageName) {\n\t\treturn true;\n\t}\n\n\tconst packageJsonPath = resolve(directory, 'package.json');\n\n\tif (!existsSync(packageJsonPath)) {\n\t\treturn false;\n\t}\n\n\ttry {\n\t\tconst packageJson = JSON.parse(readFileSync(packageJsonPath, 'utf8')) as { name?: string };\n\t\treturn packageJson.name === packageName;\n\t} catch {\n\t\treturn false;\n\t}\n}\n\nfunction dedupeDirectories(directories: string[]): string[] {\n\treturn Array.from(new Set(directories.map((directory) => resolve(directory))));\n}\n\nfunction createResolveProjectRootError(options: ResolveProjectRootOptions, startDirectories: string[]): string {\n\tconst markerSummary = [\n\t\toptions.packageName ? `package name ${JSON.stringify(options.packageName)}` : undefined,\n\t\toptions.requiredPaths?.length\n\t\t\t? `paths ${options.requiredPaths.map((path) => JSON.stringify(path)).join(', ')}`\n\t\t\t: undefined,\n\t]\n\t\t.filter((marker): marker is string => typeof marker === 'string')\n\t\t.join(' and ');\n\n\treturn `Unable to resolve a project root${markerSummary ? ` matching ${markerSummary}` : ''} from ${startDirectories.join(', ')}.`;\n}\n",
|
|
6
|
+
"function assertPath(path){if(typeof path!==\"string\")throw TypeError(\"Path must be a string. Received \"+JSON.stringify(path))}function normalizeStringPosix(path,allowAboveRoot){var res=\"\",lastSegmentLength=0,lastSlash=-1,dots=0,code;for(var i=0;i<=path.length;++i){if(i<path.length)code=path.charCodeAt(i);else if(code===47)break;else code=47;if(code===47){if(lastSlash===i-1||dots===1);else if(lastSlash!==i-1&&dots===2){if(res.length<2||lastSegmentLength!==2||res.charCodeAt(res.length-1)!==46||res.charCodeAt(res.length-2)!==46){if(res.length>2){var lastSlashIndex=res.lastIndexOf(\"/\");if(lastSlashIndex!==res.length-1){if(lastSlashIndex===-1)res=\"\",lastSegmentLength=0;else res=res.slice(0,lastSlashIndex),lastSegmentLength=res.length-1-res.lastIndexOf(\"/\");lastSlash=i,dots=0;continue}}else if(res.length===2||res.length===1){res=\"\",lastSegmentLength=0,lastSlash=i,dots=0;continue}}if(allowAboveRoot){if(res.length>0)res+=\"/..\";else res=\"..\";lastSegmentLength=2}}else{if(res.length>0)res+=\"/\"+path.slice(lastSlash+1,i);else res=path.slice(lastSlash+1,i);lastSegmentLength=i-lastSlash-1}lastSlash=i,dots=0}else if(code===46&&dots!==-1)++dots;else dots=-1}return res}function _format(sep,pathObject){var dir=pathObject.dir||pathObject.root,base=pathObject.base||(pathObject.name||\"\")+(pathObject.ext||\"\");if(!dir)return base;if(dir===pathObject.root)return dir+base;return dir+sep+base}function resolve(){var resolvedPath=\"\",resolvedAbsolute=!1,cwd;for(var i=arguments.length-1;i>=-1&&!resolvedAbsolute;i--){var path;if(i>=0)path=arguments[i];else{if(cwd===void 0)cwd=process.cwd();path=cwd}if(assertPath(path),path.length===0)continue;resolvedPath=path+\"/\"+resolvedPath,resolvedAbsolute=path.charCodeAt(0)===47}if(resolvedPath=normalizeStringPosix(resolvedPath,!resolvedAbsolute),resolvedAbsolute)if(resolvedPath.length>0)return\"/\"+resolvedPath;else return\"/\";else if(resolvedPath.length>0)return resolvedPath;else return\".\"}function normalize(path){if(assertPath(path),path.length===0)return\".\";var isAbsolute=path.charCodeAt(0)===47,trailingSeparator=path.charCodeAt(path.length-1)===47;if(path=normalizeStringPosix(path,!isAbsolute),path.length===0&&!isAbsolute)path=\".\";if(path.length>0&&trailingSeparator)path+=\"/\";if(isAbsolute)return\"/\"+path;return path}function isAbsolute(path){return assertPath(path),path.length>0&&path.charCodeAt(0)===47}function join(){if(arguments.length===0)return\".\";var joined;for(var i=0;i<arguments.length;++i){var arg=arguments[i];if(assertPath(arg),arg.length>0)if(joined===void 0)joined=arg;else joined+=\"/\"+arg}if(joined===void 0)return\".\";return normalize(joined)}function relative(from,to){if(assertPath(from),assertPath(to),from===to)return\"\";if(from=resolve(from),to=resolve(to),from===to)return\"\";var fromStart=1;for(;fromStart<from.length;++fromStart)if(from.charCodeAt(fromStart)!==47)break;var fromEnd=from.length,fromLen=fromEnd-fromStart,toStart=1;for(;toStart<to.length;++toStart)if(to.charCodeAt(toStart)!==47)break;var toEnd=to.length,toLen=toEnd-toStart,length=fromLen<toLen?fromLen:toLen,lastCommonSep=-1,i=0;for(;i<=length;++i){if(i===length){if(toLen>length){if(to.charCodeAt(toStart+i)===47)return to.slice(toStart+i+1);else if(i===0)return to.slice(toStart+i)}else if(fromLen>length){if(from.charCodeAt(fromStart+i)===47)lastCommonSep=i;else if(i===0)lastCommonSep=0}break}var fromCode=from.charCodeAt(fromStart+i),toCode=to.charCodeAt(toStart+i);if(fromCode!==toCode)break;else if(fromCode===47)lastCommonSep=i}var out=\"\";for(i=fromStart+lastCommonSep+1;i<=fromEnd;++i)if(i===fromEnd||from.charCodeAt(i)===47)if(out.length===0)out+=\"..\";else out+=\"/..\";if(out.length>0)return out+to.slice(toStart+lastCommonSep);else{if(toStart+=lastCommonSep,to.charCodeAt(toStart)===47)++toStart;return to.slice(toStart)}}function _makeLong(path){return path}function dirname(path){if(assertPath(path),path.length===0)return\".\";var code=path.charCodeAt(0),hasRoot=code===47,end=-1,matchedSlash=!0;for(var i=path.length-1;i>=1;--i)if(code=path.charCodeAt(i),code===47){if(!matchedSlash){end=i;break}}else matchedSlash=!1;if(end===-1)return hasRoot?\"/\":\".\";if(hasRoot&&end===1)return\"//\";return path.slice(0,end)}function basename(path,ext){if(ext!==void 0&&typeof ext!==\"string\")throw TypeError('\"ext\" argument must be a string');assertPath(path);var start=0,end=-1,matchedSlash=!0,i;if(ext!==void 0&&ext.length>0&&ext.length<=path.length){if(ext.length===path.length&&ext===path)return\"\";var extIdx=ext.length-1,firstNonSlashEnd=-1;for(i=path.length-1;i>=0;--i){var code=path.charCodeAt(i);if(code===47){if(!matchedSlash){start=i+1;break}}else{if(firstNonSlashEnd===-1)matchedSlash=!1,firstNonSlashEnd=i+1;if(extIdx>=0)if(code===ext.charCodeAt(extIdx)){if(--extIdx===-1)end=i}else extIdx=-1,end=firstNonSlashEnd}}if(start===end)end=firstNonSlashEnd;else if(end===-1)end=path.length;return path.slice(start,end)}else{for(i=path.length-1;i>=0;--i)if(path.charCodeAt(i)===47){if(!matchedSlash){start=i+1;break}}else if(end===-1)matchedSlash=!1,end=i+1;if(end===-1)return\"\";return path.slice(start,end)}}function extname(path){assertPath(path);var startDot=-1,startPart=0,end=-1,matchedSlash=!0,preDotState=0;for(var i=path.length-1;i>=0;--i){var code=path.charCodeAt(i);if(code===47){if(!matchedSlash){startPart=i+1;break}continue}if(end===-1)matchedSlash=!1,end=i+1;if(code===46){if(startDot===-1)startDot=i;else if(preDotState!==1)preDotState=1}else if(startDot!==-1)preDotState=-1}if(startDot===-1||end===-1||preDotState===0||preDotState===1&&startDot===end-1&&startDot===startPart+1)return\"\";return path.slice(startDot,end)}function format(pathObject){if(pathObject===null||typeof pathObject!==\"object\")throw TypeError('The \"pathObject\" argument must be of type Object. Received type '+typeof pathObject);return _format(\"/\",pathObject)}function parse(path){assertPath(path);var ret={root:\"\",dir:\"\",base:\"\",ext:\"\",name:\"\"};if(path.length===0)return ret;var code=path.charCodeAt(0),isAbsolute2=code===47,start;if(isAbsolute2)ret.root=\"/\",start=1;else start=0;var startDot=-1,startPart=0,end=-1,matchedSlash=!0,i=path.length-1,preDotState=0;for(;i>=start;--i){if(code=path.charCodeAt(i),code===47){if(!matchedSlash){startPart=i+1;break}continue}if(end===-1)matchedSlash=!1,end=i+1;if(code===46){if(startDot===-1)startDot=i;else if(preDotState!==1)preDotState=1}else if(startDot!==-1)preDotState=-1}if(startDot===-1||end===-1||preDotState===0||preDotState===1&&startDot===end-1&&startDot===startPart+1){if(end!==-1)if(startPart===0&&isAbsolute2)ret.base=ret.name=path.slice(1,end);else ret.base=ret.name=path.slice(startPart,end)}else{if(startPart===0&&isAbsolute2)ret.name=path.slice(1,startDot),ret.base=path.slice(1,end);else ret.name=path.slice(startPart,startDot),ret.base=path.slice(startPart,end);ret.ext=path.slice(startDot,end)}if(startPart>0)ret.dir=path.slice(0,startPart-1);else if(isAbsolute2)ret.dir=\"/\";return ret}var sep=\"/\",delimiter=\":\",posix=((p)=>(p.posix=p,p))({resolve,normalize,isAbsolute,join,relative,_makeLong,dirname,basename,extname,format,parse,sep,delimiter,win32:null,posix:null});var path_default=posix;export{sep,resolve,relative,posix,parse,normalize,join,isAbsolute,format,extname,dirname,delimiter,path_default as default,basename,_makeLong};"
|
|
7
|
+
],
|
|
8
|
+
"mappings": "6BAAA,4CCAA,SAAS,CAAU,CAAC,EAAK,CAAC,GAAG,OAAO,IAAO,SAAS,MAAM,UAAU,mCAAmC,KAAK,UAAU,CAAI,CAAC,EAAE,SAAS,CAAoB,CAAC,EAAK,EAAe,CAAC,IAAI,EAAI,GAAG,EAAkB,EAAE,EAAU,GAAG,EAAK,EAAE,EAAK,QAAQ,EAAE,EAAE,GAAG,EAAK,OAAO,EAAE,EAAE,CAAC,GAAG,EAAE,EAAK,OAAO,EAAK,EAAK,WAAW,CAAC,EAAO,QAAG,IAAO,GAAG,MAAW,OAAK,GAAG,GAAG,IAAO,GAAG,CAAC,GAAG,IAAY,EAAE,GAAG,IAAO,GAAQ,QAAG,IAAY,EAAE,GAAG,IAAO,EAAE,CAAC,GAAG,EAAI,OAAO,GAAG,IAAoB,GAAG,EAAI,WAAW,EAAI,OAAO,CAAC,IAAI,IAAI,EAAI,WAAW,EAAI,OAAO,CAAC,IAAI,IAAI,GAAG,EAAI,OAAO,EAAE,CAAC,IAAI,EAAe,EAAI,YAAY,GAAG,EAAE,GAAG,IAAiB,EAAI,OAAO,EAAE,CAAC,GAAG,IAAiB,GAAG,EAAI,GAAG,EAAkB,EAAO,OAAI,EAAI,MAAM,EAAE,CAAc,EAAE,EAAkB,EAAI,OAAO,EAAE,EAAI,YAAY,GAAG,EAAE,EAAU,EAAE,EAAK,EAAE,UAAe,QAAG,EAAI,SAAS,GAAG,EAAI,SAAS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EhD,GAAI,IAAoB,EACvB,OAGD,EAAmB,GAIrB,SAAS,CAAkB,CAAC,EAAmB,EAA6C,CAC3F,GAAI,CAAC,EAAmB,EAAW,EAAQ,WAAW,EACrD,MAAO,GAGR,OAAQ,EAAQ,eAAiB,CAAC,GAAG,MAAM,CAAC,IAAiB,EAAW,EAAQ,EAAW,CAAY,CAAC,CAAC,EAG1G,SAAS,CAAkB,CAAC,EAAmB,EAA0C,CACxF,GAAI,CAAC,EACJ,MAAO,GAGR,IAAM,EAAkB,EAAQ,EAAW,cAAc,EAEzD,GAAI,CAAC,EAAW,CAAe,EAC9B,MAAO,GAGR,GAAI,CAEH,OADoB,KAAK,MAAM,EAAa,EAAiB,MAAM,CAAC,EACjD,OAAS,EAC3B,KAAM,CACP,MAAO,IAIT,SAAS,CAAiB,CAAC,EAAiC,CAC3D,OAAO,MAAM,KAAK,IAAI,IAAI,EAAY,IAAI,CAAC,IAAc,EAAQ,CAAS,CAAC,CAAC,CAAC,EAG9E,SAAS,CAA6B,CAAC,EAAoC,EAAoC,CAC9G,IAAM,EAAgB,CACrB,EAAQ,YAAc,gBAAgB,KAAK,UAAU,EAAQ,WAAW,IAAM,OAC9E,EAAQ,eAAe,OACpB,SAAS,EAAQ,cAAc,IAAI,CAAC,IAAS,KAAK,UAAU,CAAI,CAAC,EAAE,KAAK,IAAI,IAC5E,MACJ,EACE,OAAO,CAAC,IAA6B,OAAO,IAAW,QAAQ,EAC/D,KAAK,OAAO,EAEd,MAAO,mCAAmC,EAAgB,aAAa,IAAkB,WAAW,EAAiB,KAAK,IAAI",
|
|
9
|
+
"debugId": "092C65A79F3C884364756E2164756E21",
|
|
10
|
+
"names": []
|
|
11
|
+
}
|
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
import type { JsxRenderable } from '@ecopages/jsx';
|
|
2
|
+
import type { RenderToStringOptions } from '@ecopages/jsx/server';
|
|
3
|
+
import type { ContextType, UnknownContext } from '../context/types';
|
|
4
|
+
import { type ServerRenderEnvironment } from './light-dom-shim';
|
|
5
|
+
/** Default response header carrying the fragment render timestamp. */
|
|
6
|
+
export declare const RENDERED_COMPONENT_GENERATED_AT_HEADER = "x-generated-at";
|
|
7
|
+
/** Default response header carrying the custom-element tag name for the fragment. */
|
|
8
|
+
export declare const RENDERED_COMPONENT_TAG_NAME_HEADER = "x-radiant-tag-name";
|
|
9
|
+
/** Default response header carrying the client module URL for the fragment. */
|
|
10
|
+
export declare const RENDERED_COMPONENT_CLIENT_MODULE_HEADER = "x-radiant-client-module";
|
|
11
|
+
/** Default response header carrying serialized fragment asset metadata. */
|
|
12
|
+
export declare const RENDERED_COMPONENT_ASSETS_HEADER = "x-radiant-assets";
|
|
13
|
+
/** Asset dependency emitted by a rendered fragment. */
|
|
14
|
+
export type RenderedComponentAsset = {
|
|
15
|
+
/** Browser module specifier that must be loaded to activate the fragment. */
|
|
16
|
+
kind: 'script-module';
|
|
17
|
+
/** Runtime loading policy for the module. */
|
|
18
|
+
stage?: 'hydrate' | 'idle' | 'immediate';
|
|
19
|
+
/** Module specifier or browser-importable URL. */
|
|
20
|
+
src: string;
|
|
21
|
+
} | {
|
|
22
|
+
/** Module graph preload hint for adapters that control the document head. */
|
|
23
|
+
kind: 'modulepreload';
|
|
24
|
+
/** Module specifier or browser-importable URL. */
|
|
25
|
+
href: string;
|
|
26
|
+
} | {
|
|
27
|
+
/** Stylesheet dependency required by the rendered fragment. */
|
|
28
|
+
kind: 'style';
|
|
29
|
+
/** Browser-importable stylesheet URL. */
|
|
30
|
+
href: string;
|
|
31
|
+
/** Optional media query applied to the stylesheet link. */
|
|
32
|
+
media?: string;
|
|
33
|
+
};
|
|
34
|
+
/** Creates a module asset entry for a rendered fragment. */
|
|
35
|
+
export declare function scriptModuleAsset(src: string, stage?: 'hydrate' | 'idle' | 'immediate'): RenderedComponentAsset;
|
|
36
|
+
/** Creates a modulepreload hint for a rendered fragment. */
|
|
37
|
+
export declare function modulePreloadAsset(href: string): RenderedComponentAsset;
|
|
38
|
+
/** Creates a stylesheet asset entry for a rendered fragment. */
|
|
39
|
+
export declare function styleAsset(href: string, media?: string): RenderedComponentAsset;
|
|
40
|
+
/** Portable metadata for a server-rendered custom-element fragment. */
|
|
41
|
+
export type RenderedComponentMetadata = {
|
|
42
|
+
/** Asset dependencies required by the rendered fragment. */
|
|
43
|
+
assets: readonly RenderedComponentAsset[];
|
|
44
|
+
/** Browser-importable client module URL used to register the component before hydration. */
|
|
45
|
+
clientModuleUrl?: string;
|
|
46
|
+
/** ISO timestamp describing when the fragment was rendered. */
|
|
47
|
+
generatedAt: string;
|
|
48
|
+
/** Custom-element tag name emitted at the fragment root. */
|
|
49
|
+
tagName: string;
|
|
50
|
+
};
|
|
51
|
+
/** Canonical server render result returned by `renderComponent()`. */
|
|
52
|
+
export type RenderedComponent = {
|
|
53
|
+
/** Serialized custom-element host markup. */
|
|
54
|
+
markup: string;
|
|
55
|
+
/** Transport-agnostic metadata that adapters can map onto headers or JSON. */
|
|
56
|
+
metadata: RenderedComponentMetadata;
|
|
57
|
+
/** JSX-compatible preview value that can be embedded into a larger SSR shell. */
|
|
58
|
+
preview: JsxRenderable;
|
|
59
|
+
};
|
|
60
|
+
/** Serializable metadata for a server-rendered custom-element fragment. */
|
|
61
|
+
export type RenderedComponentPayload = {
|
|
62
|
+
/** Asset dependencies required by the rendered fragment. */
|
|
63
|
+
assets?: readonly RenderedComponentAsset[];
|
|
64
|
+
/** Browser-importable client module URL used to register the component before hydration. */
|
|
65
|
+
clientModuleSrc?: string;
|
|
66
|
+
/** ISO timestamp describing when the fragment was rendered. */
|
|
67
|
+
generatedAt: string;
|
|
68
|
+
/** Serialized custom-element host markup. */
|
|
69
|
+
markup: string;
|
|
70
|
+
/** Custom-element tag name emitted at the fragment root. */
|
|
71
|
+
tagName: string;
|
|
72
|
+
};
|
|
73
|
+
/** Full SSR result including a JSX-compatible preview value for shell composition. */
|
|
74
|
+
export type StreamableRenderedComponent = RenderedComponentPayload & {
|
|
75
|
+
/** JSX-compatible preview value that can be embedded into a larger SSR shell. */
|
|
76
|
+
preview: JsxRenderable;
|
|
77
|
+
};
|
|
78
|
+
/** Minimal component contract needed for framework-agnostic SSR helpers. */
|
|
79
|
+
export type ServerRenderableComponent = {
|
|
80
|
+
renderHost?: () => JsxRenderable;
|
|
81
|
+
renderHostToString: (options?: RenderToStringOptions) => string;
|
|
82
|
+
};
|
|
83
|
+
/** Constructor shape for a server-renderable component. */
|
|
84
|
+
export type ServerRenderableComponentConstructor<TComponent extends ServerRenderableComponent> = CustomElementConstructor & {
|
|
85
|
+
new (): TComponent;
|
|
86
|
+
};
|
|
87
|
+
/**
|
|
88
|
+
* Resolves the browser-importable client module URL for a component constructor.
|
|
89
|
+
*
|
|
90
|
+
* Use this when the server adapter can derive the client entry lazily instead of
|
|
91
|
+
* hardcoding `clientModuleSrc` for every render call.
|
|
92
|
+
*/
|
|
93
|
+
export type ResolveRenderedComponentClientModule<TComponent extends ServerRenderableComponent> = (component: ServerRenderableComponentConstructor<TComponent>) => string | undefined | Promise<string | undefined>;
|
|
94
|
+
/**
|
|
95
|
+
* Resolves fragment assets for a component constructor.
|
|
96
|
+
*
|
|
97
|
+
* Prefer this over `resolveClientModuleSrc(...)` for new adapters so assets can
|
|
98
|
+
* describe scripts, styles, and preload hints through one transport-agnostic shape.
|
|
99
|
+
*/
|
|
100
|
+
export type ResolveRenderedComponentAssets<TComponent extends ServerRenderableComponent> = (component: ServerRenderableComponentConstructor<TComponent>) => readonly RenderedComponentAsset[] | undefined | Promise<readonly RenderedComponentAsset[] | undefined>;
|
|
101
|
+
/**
|
|
102
|
+
* Prepares a component host before SSR so slot-aware logic can observe authored
|
|
103
|
+
* light-DOM content during render.
|
|
104
|
+
*/
|
|
105
|
+
export type PrepareRenderedComponentHost<TComponent extends ServerRenderableComponent> = (host: TComponent & HTMLElement, environment: ServerRenderEnvironment) => void;
|
|
106
|
+
/**
|
|
107
|
+
* Ambient SSR context value visible while a standalone component render runs.
|
|
108
|
+
*
|
|
109
|
+
* This lets adapters provide ancestor-like context to `consumeContext(...)` and
|
|
110
|
+
* `contextSelector(...)` without needing to instantiate a real provider host.
|
|
111
|
+
*/
|
|
112
|
+
export type RenderComponentSsrContextEntry<TContext extends UnknownContext = UnknownContext> = {
|
|
113
|
+
context: TContext;
|
|
114
|
+
value: ContextType<TContext>;
|
|
115
|
+
};
|
|
116
|
+
type RenderComponentSharedOptions<TComponent extends ServerRenderableComponent> = {
|
|
117
|
+
/** Asset dependencies required by the rendered fragment. */
|
|
118
|
+
assets?: readonly RenderedComponentAsset[];
|
|
119
|
+
/** Serialized authored light-DOM content to attach to the host before rendering. */
|
|
120
|
+
authoredContent?: string;
|
|
121
|
+
/** Browser-importable client module URL used to register the component before hydration. */
|
|
122
|
+
clientModuleSrc?: string;
|
|
123
|
+
/** Initializes the component instance before the host is rendered. */
|
|
124
|
+
initialize?: (component: TComponent) => void;
|
|
125
|
+
/** SSR environment responsible for preparing the host runtime and authored content. */
|
|
126
|
+
environment?: ServerRenderEnvironment;
|
|
127
|
+
/**
|
|
128
|
+
* Dedicated host-preparation hook for slot-aware SSR.
|
|
129
|
+
*
|
|
130
|
+
* Use this when the server needs to append or mutate authored light-DOM
|
|
131
|
+
* nodes directly instead of passing `authoredContent` as a string.
|
|
132
|
+
*/
|
|
133
|
+
prepareHost?: PrepareRenderedComponentHost<TComponent>;
|
|
134
|
+
/**
|
|
135
|
+
* Ambient SSR context entries that should be visible while the component is
|
|
136
|
+
* instantiated and rendered.
|
|
137
|
+
*
|
|
138
|
+
* This solves standalone fragment renders that need to consume context from a
|
|
139
|
+
* parent-like server environment.
|
|
140
|
+
*/
|
|
141
|
+
ssrContext?: readonly RenderComponentSsrContextEntry[];
|
|
142
|
+
/** Clock override used by tests and adapters that need deterministic timestamps. */
|
|
143
|
+
now?: () => Date;
|
|
144
|
+
/** JSX server-renderer options forwarded to `renderHostToString()`. */
|
|
145
|
+
renderOptions?: RenderToStringOptions;
|
|
146
|
+
/** Lazy asset resolver used when `assets` are not provided directly. */
|
|
147
|
+
resolveAssets?: ResolveRenderedComponentAssets<TComponent>;
|
|
148
|
+
/** Lazy client-module resolver used when `clientModuleSrc` is not provided directly. */
|
|
149
|
+
resolveClientModuleSrc?: ResolveRenderedComponentClientModule<TComponent>;
|
|
150
|
+
/** Explicit tag-name override when `@customElement(...)` metadata is not desired. */
|
|
151
|
+
tagName?: string;
|
|
152
|
+
};
|
|
153
|
+
/** Options accepted by the reusable SSR component rendering helpers. */
|
|
154
|
+
export type RenderComponentOptions<TComponent extends ServerRenderableComponent> = RenderComponentSharedOptions<TComponent> & ({
|
|
155
|
+
component: ServerRenderableComponentConstructor<TComponent>;
|
|
156
|
+
} | {
|
|
157
|
+
load: () => Promise<ServerRenderableComponentConstructor<TComponent>>;
|
|
158
|
+
});
|
|
159
|
+
/** Call-site options used when the component constructor is passed directly. */
|
|
160
|
+
export type RenderComponentCallOptions<TComponent extends ServerRenderableComponent> = RenderComponentSharedOptions<TComponent>;
|
|
161
|
+
/**
|
|
162
|
+
* Serializes a custom element into HTML, inferring its tag name from
|
|
163
|
+
* `@customElement(...)` metadata when the caller does not provide one.
|
|
164
|
+
*/
|
|
165
|
+
export declare function renderComponentToString<TComponent extends ServerRenderableComponent>(component: ServerRenderableComponentConstructor<TComponent>, options?: RenderComponentCallOptions<TComponent>): Promise<string>;
|
|
166
|
+
export declare function renderComponentToString<TComponent extends ServerRenderableComponent>(options: RenderComponentOptions<TComponent>): Promise<string>;
|
|
167
|
+
/**
|
|
168
|
+
* Renders a custom element into the canonical portable server-rendered shape,
|
|
169
|
+
* separating transport-agnostic metadata from any HTTP-specific adapter.
|
|
170
|
+
*/
|
|
171
|
+
export declare function renderComponent<TComponent extends ServerRenderableComponent>(component: ServerRenderableComponentConstructor<TComponent>, options?: RenderComponentCallOptions<TComponent>): Promise<RenderedComponent>;
|
|
172
|
+
export declare function renderComponent<TComponent extends ServerRenderableComponent>(options: RenderComponentOptions<TComponent>): Promise<RenderedComponent>;
|
|
173
|
+
/**
|
|
174
|
+
* Serializes a custom element into a fragment payload that frameworks can
|
|
175
|
+
* attach to any response shape they prefer.
|
|
176
|
+
*/
|
|
177
|
+
export declare function renderComponentToPayload<TComponent extends ServerRenderableComponent>(component: ServerRenderableComponentConstructor<TComponent>, options?: RenderComponentCallOptions<TComponent>): Promise<RenderedComponentPayload>;
|
|
178
|
+
export declare function renderComponentToPayload<TComponent extends ServerRenderableComponent>(options: RenderComponentOptions<TComponent>): Promise<RenderedComponentPayload>;
|
|
179
|
+
/**
|
|
180
|
+
* Renders a component into both fragment metadata and a JSX-compatible preview
|
|
181
|
+
* value that can be embedded into a larger server-rendered shell.
|
|
182
|
+
*/
|
|
183
|
+
export declare function renderStreamableComponent<TComponent extends ServerRenderableComponent>(component: ServerRenderableComponentConstructor<TComponent>, options?: RenderComponentCallOptions<TComponent>): Promise<StreamableRenderedComponent>;
|
|
184
|
+
export declare function renderStreamableComponent<TComponent extends ServerRenderableComponent>(options: RenderComponentOptions<TComponent>): Promise<StreamableRenderedComponent>;
|
|
185
|
+
/**
|
|
186
|
+
* Drops the preview renderable so the result can be sent through lightweight
|
|
187
|
+
* framework adapters or JSON/HTML fragment endpoints.
|
|
188
|
+
*/
|
|
189
|
+
export declare function toRenderedComponentPayload(render: StreamableRenderedComponent | RenderedComponent): RenderedComponentPayload;
|
|
190
|
+
/**
|
|
191
|
+
* Converts a rendered fragment payload into the standard metadata headers used
|
|
192
|
+
* by client-side fragment loaders.
|
|
193
|
+
*/
|
|
194
|
+
export declare function createRenderedComponentHeaders(render: RenderedComponent | RenderedComponentMetadata | RenderedComponentPayload | StreamableRenderedComponent): Record<string, string>;
|
|
195
|
+
export {};
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import{d as Z}from"../chunk-jce9gqqw.js";import{Ya as Y}from"../chunk-ms6a9zdt.js";import{Za as X}from"../chunk-dx1wqc00.js";import"../chunk-4cc2syf5.js";import"../chunk-8xy18qmz.js";var x="x-generated-at",L="x-radiant-tag-name",P="x-radiant-client-module",T="x-radiant-assets";function A(j,q="hydrate"){return{kind:"script-module",src:j,stage:q}}function C(j){return{kind:"modulepreload",href:j}}function z(j,q){return q?{kind:"style",href:j,media:q}:{kind:"style",href:j}}async function c(j,q){return(await J(K(j,q))).markup}async function O(j,q){return J(K(j,q))}async function l(j,q){return D(await J(K(j,q)))}async function m(j,q){return f(await J(K(j,q)))}async function J(j){let q=j.environment??Z(),B=X(_(j.ssrContext));try{let F="component"in j?j.component:await j.load(),G=new F;R(q,G,j.authoredContent,j.prepareHost),j.initialize?.(G);let Q=j.clientModuleSrc??await j.resolveClientModuleSrc?.(F),b=j.assets??await j.resolveAssets?.(F)??[],V=v(b,Q),w=E(V)??Q,I=j.tagName??S(F),U=(j.now??N)().toISOString(),k=h(j.renderOptions),W=G.renderHostToString(k);return{markup:W,metadata:{assets:V,clientModuleUrl:w,generatedAt:U,tagName:I},preview:G.renderHost?.()??{nodeType:1,outerHTML:W}}}finally{B()}}function R(j,q,B,F){if(!y(q)){if(B===void 0&&F===void 0)return;throw Error(`${q.constructor.name} cannot prepare SSR host content because it does not expose an innerHTML host surface.`)}j.prepareHost(q,{authoredContent:B}),F?.(q,j)}function _(j){if(!j||j.length===0)return[];return j.map((q)=>({getContext:()=>q.value,getContextKey:()=>q.context,renderHydrationScript:()=>{return},renderHydrationScriptTag:()=>{return}}))}function D(j){if("metadata"in j)return{assets:j.metadata.assets,clientModuleSrc:j.metadata.clientModuleUrl,generatedAt:j.metadata.generatedAt,markup:j.markup,tagName:j.metadata.tagName};let{preview:q,...B}=j;return B}function p(j){let q=H(j);return{...q.assets.length>0?{[T]:JSON.stringify(q.assets)}:{},...q.clientModuleUrl?{[P]:q.clientModuleUrl}:{},[x]:q.generatedAt,[L]:q.tagName}}function H(j){if("metadata"in j)return j.metadata;if("markup"in j)return{assets:j.assets??$(j.clientModuleSrc),clientModuleUrl:j.clientModuleSrc,generatedAt:j.generatedAt,tagName:j.tagName};return j}function f(j){return{assets:j.metadata.assets,clientModuleSrc:j.metadata.clientModuleUrl,generatedAt:j.metadata.generatedAt,markup:j.markup,preview:j.preview,tagName:j.metadata.tagName}}function N(){return new Date}function $(j){if(!j)return[];return[A(j)]}function v(j,q){if(!q)return j;if(j.some((B)=>B.kind==="script-module"&&B.src===q))return j;return[...$(q),...j]}function E(j){return j.find((q)=>q.kind==="script-module")?.src}function K(j,q){if(typeof j==="function")return{...q,component:j};return j}function h(j){if(j?.hydrate!==void 0)return j;return{...j,hydrate:!0}}function y(j){return"innerHTML"in j}function S(j){let q=Y(j);if(!q)throw Error(`${j.name} is missing @customElement metadata.`);return q}export{D as toRenderedComponentPayload,z as styleAsset,A as scriptModuleAsset,m as renderStreamableComponent,c as renderComponentToString,l as renderComponentToPayload,O as renderComponent,C as modulePreloadAsset,p as createRenderedComponentHeaders,L as RENDERED_COMPONENT_TAG_NAME_HEADER,x as RENDERED_COMPONENT_GENERATED_AT_HEADER,P as RENDERED_COMPONENT_CLIENT_MODULE_HEADER,T as RENDERED_COMPONENT_ASSETS_HEADER};
|
|
2
|
+
|
|
3
|
+
//# debugId=E62B78C0A966A7EC64756E2164756E21
|