@antheo/morph 0.0.0-stage → 0.3.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/LICENSE +21 -0
- package/README.md +266 -2
- package/SKILL.md +61 -0
- package/dist/ai/cli-provider.d.ts +80 -0
- package/dist/ai/cli-provider.js +250 -0
- package/dist/ai/gate.d.ts +39 -0
- package/dist/ai/gate.js +124 -0
- package/dist/ai/provider.d.ts +36 -0
- package/dist/ai/provider.js +168 -0
- package/dist/ai/repair.d.ts +90 -0
- package/dist/ai/repair.js +172 -0
- package/dist/analyzer/deps.d.ts +30 -0
- package/dist/analyzer/deps.js +265 -0
- package/dist/analyzer/manifest.d.ts +5 -0
- package/dist/analyzer/manifest.js +119 -0
- package/dist/analyzer/parse.d.ts +21 -0
- package/dist/analyzer/parse.js +29 -0
- package/dist/batch-worker.d.ts +16 -0
- package/dist/batch-worker.js +10 -0
- package/dist/batch.d.ts +26 -0
- package/dist/batch.js +227 -0
- package/dist/bridge/index.d.ts +26 -0
- package/dist/bridge/index.js +138 -0
- package/dist/bridge/props.d.ts +56 -0
- package/dist/bridge/props.js +191 -0
- package/dist/bridge/wrappers.d.ts +24 -0
- package/dist/bridge/wrappers.js +276 -0
- package/dist/cli/format.d.ts +7 -0
- package/dist/cli/format.js +30 -0
- package/dist/cli.d.ts +2 -0
- package/dist/cli.js +492 -0
- package/dist/fonts/carry.d.ts +34 -0
- package/dist/fonts/carry.js +113 -0
- package/dist/fonts/fallback.d.ts +11 -0
- package/dist/fonts/fallback.js +21 -0
- package/dist/fonts/google.d.ts +65 -0
- package/dist/fonts/google.js +343 -0
- package/dist/fonts/index.d.ts +27 -0
- package/dist/fonts/index.js +48 -0
- package/dist/fonts/local.d.ts +46 -0
- package/dist/fonts/local.js +150 -0
- package/dist/fonts/sfnt.d.ts +19 -0
- package/dist/fonts/sfnt.js +174 -0
- package/dist/fonts/shim.d.ts +14 -0
- package/dist/fonts/shim.js +96 -0
- package/dist/gate.d.ts +105 -0
- package/dist/gate.js +157 -0
- package/dist/index.d.ts +55 -0
- package/dist/index.js +74 -0
- package/dist/ir/annotate.d.ts +16 -0
- package/dist/ir/annotate.js +145 -0
- package/dist/ir/as-child.d.ts +18 -0
- package/dist/ir/as-child.js +239 -0
- package/dist/ir/compounds.d.ts +27 -0
- package/dist/ir/compounds.js +183 -0
- package/dist/ir/contexts.d.ts +26 -0
- package/dist/ir/contexts.js +185 -0
- package/dist/ir/dom.d.ts +11 -0
- package/dist/ir/dom.js +60 -0
- package/dist/ir/effect-returns.d.ts +10 -0
- package/dist/ir/effect-returns.js +25 -0
- package/dist/ir/extract-ui-types.d.ts +33 -0
- package/dist/ir/extract-ui-types.js +224 -0
- package/dist/ir/extract-ui.d.ts +34 -0
- package/dist/ir/extract-ui.js +567 -0
- package/dist/ir/falsy.d.ts +13 -0
- package/dist/ir/falsy.js +66 -0
- package/dist/ir/forward-refs.d.ts +11 -0
- package/dist/ir/forward-refs.js +155 -0
- package/dist/ir/fragment-source.d.ts +4 -0
- package/dist/ir/fragment-source.js +13 -0
- package/dist/ir/fragments.d.ts +32 -0
- package/dist/ir/fragments.js +192 -0
- package/dist/ir/helper-snippets.d.ts +30 -0
- package/dist/ir/helper-snippets.js +550 -0
- package/dist/ir/latest-refs.d.ts +11 -0
- package/dist/ir/latest-refs.js +187 -0
- package/dist/ir/live-args.d.ts +26 -0
- package/dist/ir/live-args.js +335 -0
- package/dist/ir/lower.d.ts +83 -0
- package/dist/ir/lower.js +6016 -0
- package/dist/ir/markup-values.d.ts +16 -0
- package/dist/ir/markup-values.js +188 -0
- package/dist/ir/model.d.ts +605 -0
- package/dist/ir/model.js +1 -0
- package/dist/ir/oracle.d.ts +91 -0
- package/dist/ir/oracle.js +610 -0
- package/dist/ir/radix.d.ts +122 -0
- package/dist/ir/radix.js +344 -0
- package/dist/ir/rename.d.ts +15 -0
- package/dist/ir/rename.js +151 -0
- package/dist/ir/render-props.d.ts +31 -0
- package/dist/ir/render-props.js +67 -0
- package/dist/ir/rewrite.d.ts +44 -0
- package/dist/ir/rewrite.js +381 -0
- package/dist/ir/running-index.d.ts +11 -0
- package/dist/ir/running-index.js +217 -0
- package/dist/ir/snapshots.d.ts +12 -0
- package/dist/ir/snapshots.js +140 -0
- package/dist/ir/style.d.ts +19 -0
- package/dist/ir/style.js +76 -0
- package/dist/ir/types.d.ts +42 -0
- package/dist/ir/types.js +271 -0
- package/dist/ir/walk.d.ts +11 -0
- package/dist/ir/walk.js +18 -0
- package/dist/mcp/server.d.ts +81 -0
- package/dist/mcp/server.js +518 -0
- package/dist/pipeline.d.ts +26 -0
- package/dist/pipeline.js +750 -0
- package/dist/registry/add.d.ts +91 -0
- package/dist/registry/add.js +273 -0
- package/dist/registry/fetch.d.ts +40 -0
- package/dist/registry/fetch.js +186 -0
- package/dist/registry/ip.d.ts +18 -0
- package/dist/registry/ip.js +153 -0
- package/dist/registry/item.d.ts +39 -0
- package/dist/registry/item.js +131 -0
- package/dist/registry/load.d.ts +35 -0
- package/dist/registry/load.js +106 -0
- package/dist/registry/paths.d.ts +8 -0
- package/dist/registry/paths.js +43 -0
- package/dist/registry/publish.d.ts +119 -0
- package/dist/registry/publish.js +439 -0
- package/dist/targets/angular/bank/bank.d.ts +39 -0
- package/dist/targets/angular/bank/bank.js +61 -0
- package/dist/targets/angular/bank/helpers.d.ts +64 -0
- package/dist/targets/angular/bank/helpers.js +246 -0
- package/dist/targets/angular/bank/kept.d.ts +98 -0
- package/dist/targets/angular/bank/kept.js +791 -0
- package/dist/targets/angular/bank/plan-helpers.d.ts +17 -0
- package/dist/targets/angular/bank/plan-helpers.js +286 -0
- package/dist/targets/angular/bank/plan.d.ts +22 -0
- package/dist/targets/angular/bank/plan.js +152 -0
- package/dist/targets/angular/bank/receivers.d.ts +66 -0
- package/dist/targets/angular/bank/receivers.js +293 -0
- package/dist/targets/angular/bank/runtime.d.ts +14 -0
- package/dist/targets/angular/bank/runtime.js +152 -0
- package/dist/targets/angular/controlled.d.ts +7 -0
- package/dist/targets/angular/controlled.js +37 -0
- package/dist/targets/angular/dynamic-tags.d.ts +34 -0
- package/dist/targets/angular/dynamic-tags.js +192 -0
- package/dist/targets/angular/emit.d.ts +41 -0
- package/dist/targets/angular/emit.js +5970 -0
- package/dist/targets/angular/exports.d.ts +48 -0
- package/dist/targets/angular/exports.js +243 -0
- package/dist/targets/angular/helpers.d.ts +15 -0
- package/dist/targets/angular/helpers.js +33 -0
- package/dist/targets/angular/host-boundary.d.ts +5 -0
- package/dist/targets/angular/host-boundary.js +166 -0
- package/dist/targets/angular/host-form.d.ts +150 -0
- package/dist/targets/angular/host-form.js +727 -0
- package/dist/targets/angular/markup-values.d.ts +58 -0
- package/dist/targets/angular/markup-values.js +661 -0
- package/dist/targets/angular/motion-directive.d.ts +12 -0
- package/dist/targets/angular/motion-directive.js +257 -0
- package/dist/targets/angular/motion-hooks.d.ts +73 -0
- package/dist/targets/angular/motion-hooks.js +293 -0
- package/dist/targets/angular/motion-layout.d.ts +14 -0
- package/dist/targets/angular/motion-layout.js +74 -0
- package/dist/targets/angular/motion-templates.d.ts +10 -0
- package/dist/targets/angular/motion-templates.js +65 -0
- package/dist/targets/angular/motion.d.ts +57 -0
- package/dist/targets/angular/motion.js +202 -0
- package/dist/targets/angular/narrowing.d.ts +24 -0
- package/dist/targets/angular/narrowing.js +205 -0
- package/dist/targets/angular/ngc.d.ts +23 -0
- package/dist/targets/angular/ngc.js +134 -0
- package/dist/targets/angular/passed-handle.d.ts +39 -0
- package/dist/targets/angular/passed-handle.js +154 -0
- package/dist/targets/angular/projected.d.ts +9 -0
- package/dist/targets/angular/projected.js +63 -0
- package/dist/targets/angular/radix/cores/alert-dialog.d.ts +13 -0
- package/dist/targets/angular/radix/cores/alert-dialog.js +388 -0
- package/dist/targets/angular/radix/cores/index.d.ts +17 -0
- package/dist/targets/angular/radix/cores/index.js +50 -0
- package/dist/targets/angular/radix/cores/slider.d.ts +8 -0
- package/dist/targets/angular/radix/cores/slider.js +202 -0
- package/dist/targets/angular/radix/index.d.ts +21 -0
- package/dist/targets/angular/radix/index.js +35 -0
- package/dist/targets/angular/radix/packages.d.ts +3 -0
- package/dist/targets/angular/radix/packages.js +558 -0
- package/dist/targets/angular/radix/part.d.ts +236 -0
- package/dist/targets/angular/radix/part.js +71 -0
- package/dist/targets/angular/radix/prepare.d.ts +66 -0
- package/dist/targets/angular/radix/prepare.js +548 -0
- package/dist/targets/angular/radix/template.d.ts +43 -0
- package/dist/targets/angular/radix/template.js +172 -0
- package/dist/targets/angular/refs.d.ts +68 -0
- package/dist/targets/angular/refs.js +443 -0
- package/dist/targets/angular/slots.d.ts +22 -0
- package/dist/targets/angular/slots.js +60 -0
- package/dist/targets/angular/source-types.d.ts +10 -0
- package/dist/targets/angular/source-types.js +45 -0
- package/dist/targets/angular/spread-forward.d.ts +24 -0
- package/dist/targets/angular/spread-forward.js +72 -0
- package/dist/targets/angular/spread.d.ts +32 -0
- package/dist/targets/angular/spread.js +182 -0
- package/dist/targets/angular/svg-hosts.d.ts +25 -0
- package/dist/targets/angular/svg-hosts.js +107 -0
- package/dist/targets/angular/template-expr.d.ts +36 -0
- package/dist/targets/angular/template-expr.js +287 -0
- package/dist/targets/angular/types.d.ts +9 -0
- package/dist/targets/angular/types.js +63 -0
- package/dist/targets/angular/walk.d.ts +11 -0
- package/dist/targets/angular/walk.js +26 -0
- package/dist/targets/react-native/emit.d.ts +14 -0
- package/dist/targets/react-native/emit.js +585 -0
- package/dist/targets/react-native/fidelity.d.ts +5 -0
- package/dist/targets/react-native/fidelity.js +43 -0
- package/dist/targets/react-native/motion.d.ts +10 -0
- package/dist/targets/react-native/motion.js +290 -0
- package/dist/targets/react-native/skia.d.ts +30 -0
- package/dist/targets/react-native/skia.js +358 -0
- package/dist/targets/shared/context.d.ts +47 -0
- package/dist/targets/shared/context.js +195 -0
- package/dist/targets/shared/foreign.d.ts +10 -0
- package/dist/targets/shared/foreign.js +72 -0
- package/dist/targets/shared/fragments.d.ts +21 -0
- package/dist/targets/shared/fragments.js +309 -0
- package/dist/targets/shared/handles.d.ts +65 -0
- package/dist/targets/shared/handles.js +299 -0
- package/dist/targets/shared/inline.d.ts +53 -0
- package/dist/targets/shared/inline.js +524 -0
- package/dist/targets/shared/layout.d.ts +70 -0
- package/dist/targets/shared/layout.js +224 -0
- package/dist/targets/shared/markup.d.ts +26 -0
- package/dist/targets/shared/markup.js +65 -0
- package/dist/targets/shared/module.d.ts +84 -0
- package/dist/targets/shared/module.js +468 -0
- package/dist/targets/shared/motion-hooks.d.ts +37 -0
- package/dist/targets/shared/motion-hooks.js +87 -0
- package/dist/targets/shared/motion-layout.d.ts +70 -0
- package/dist/targets/shared/motion-layout.js +392 -0
- package/dist/targets/shared/portal.d.ts +10 -0
- package/dist/targets/shared/portal.js +23 -0
- package/dist/targets/shared/prop-writes.d.ts +11 -0
- package/dist/targets/shared/prop-writes.js +32 -0
- package/dist/targets/shared/prune.d.ts +54 -0
- package/dist/targets/shared/prune.js +405 -0
- package/dist/targets/shared/react-libs.d.ts +25 -0
- package/dist/targets/shared/react-libs.js +142 -0
- package/dist/targets/shared/react-types.d.ts +16 -0
- package/dist/targets/shared/react-types.js +374 -0
- package/dist/targets/shared/react-values.d.ts +20 -0
- package/dist/targets/shared/react-values.js +145 -0
- package/dist/targets/shared/ref-callback.d.ts +16 -0
- package/dist/targets/shared/ref-callback.js +114 -0
- package/dist/targets/shared/script.d.ts +65 -0
- package/dist/targets/shared/script.js +406 -0
- package/dist/targets/shared/unused.d.ts +12 -0
- package/dist/targets/shared/unused.js +146 -0
- package/dist/targets/svelte/dom-spread.d.ts +27 -0
- package/dist/targets/svelte/dom-spread.js +146 -0
- package/dist/targets/svelte/emit.d.ts +15 -0
- package/dist/targets/svelte/emit.js +3784 -0
- package/dist/targets/svelte/handle-branches.d.ts +22 -0
- package/dist/targets/svelte/handle-branches.js +146 -0
- package/dist/targets/svelte/html-keys.d.ts +9 -0
- package/dist/targets/svelte/html-keys.js +40 -0
- package/dist/targets/svelte/markup-data/data.d.ts +51 -0
- package/dist/targets/svelte/markup-data/data.js +305 -0
- package/dist/targets/svelte/markup-data/helper.d.ts +12 -0
- package/dist/targets/svelte/markup-data/helper.js +81 -0
- package/dist/targets/svelte/markup-data/module-data.d.ts +21 -0
- package/dist/targets/svelte/markup-data/module-data.js +473 -0
- package/dist/targets/svelte/markup-data/sites.d.ts +52 -0
- package/dist/targets/svelte/markup-data/sites.js +303 -0
- package/dist/targets/svelte/motion-layout.d.ts +13 -0
- package/dist/targets/svelte/motion-layout.js +70 -0
- package/dist/targets/svelte/motion-table.d.ts +14 -0
- package/dist/targets/svelte/motion-table.js +308 -0
- package/dist/targets/svelte/motion.d.ts +46 -0
- package/dist/targets/svelte/motion.js +405 -0
- package/dist/targets/svelte/presence.d.ts +71 -0
- package/dist/targets/svelte/presence.js +318 -0
- package/dist/targets/svelte/radix/accordion.d.ts +9 -0
- package/dist/targets/svelte/radix/accordion.js +24 -0
- package/dist/targets/svelte/radix/aspect-ratio.d.ts +6 -0
- package/dist/targets/svelte/radix/aspect-ratio.js +8 -0
- package/dist/targets/svelte/radix/avatar.d.ts +6 -0
- package/dist/targets/svelte/radix/avatar.js +10 -0
- package/dist/targets/svelte/radix/checkbox.d.ts +10 -0
- package/dist/targets/svelte/radix/checkbox.js +24 -0
- package/dist/targets/svelte/radix/collapsible.d.ts +7 -0
- package/dist/targets/svelte/radix/collapsible.js +16 -0
- package/dist/targets/svelte/radix/context-menu.d.ts +8 -0
- package/dist/targets/svelte/radix/context-menu.js +49 -0
- package/dist/targets/svelte/radix/cores/alert-dialog.d.ts +17 -0
- package/dist/targets/svelte/radix/cores/alert-dialog.js +449 -0
- package/dist/targets/svelte/radix/cores/collapsible.d.ts +12 -0
- package/dist/targets/svelte/radix/cores/collapsible.js +214 -0
- package/dist/targets/svelte/radix/cores/core.d.ts +32 -0
- package/dist/targets/svelte/radix/cores/core.js +80 -0
- package/dist/targets/svelte/radix/cores/direction.d.ts +10 -0
- package/dist/targets/svelte/radix/cores/direction.js +64 -0
- package/dist/targets/svelte/radix/cores/index.d.ts +19 -0
- package/dist/targets/svelte/radix/cores/index.js +85 -0
- package/dist/targets/svelte/radix/cores/modal-layer.d.ts +11 -0
- package/dist/targets/svelte/radix/cores/modal-layer.js +244 -0
- package/dist/targets/svelte/radix/cores/presence.d.ts +12 -0
- package/dist/targets/svelte/radix/cores/presence.js +129 -0
- package/dist/targets/svelte/radix/cores/slider-logic.d.ts +10 -0
- package/dist/targets/svelte/radix/cores/slider-logic.js +287 -0
- package/dist/targets/svelte/radix/cores/slider.d.ts +13 -0
- package/dist/targets/svelte/radix/cores/slider.js +267 -0
- package/dist/targets/svelte/radix/dialog.d.ts +8 -0
- package/dist/targets/svelte/radix/dialog.js +20 -0
- package/dist/targets/svelte/radix/dropdown-menu.d.ts +9 -0
- package/dist/targets/svelte/radix/dropdown-menu.js +38 -0
- package/dist/targets/svelte/radix/emit.d.ts +12 -0
- package/dist/targets/svelte/radix/emit.js +1339 -0
- package/dist/targets/svelte/radix/hover-card.d.ts +7 -0
- package/dist/targets/svelte/radix/hover-card.js +22 -0
- package/dist/targets/svelte/radix/index.d.ts +12 -0
- package/dist/targets/svelte/radix/index.js +28 -0
- package/dist/targets/svelte/radix/label.d.ts +3 -0
- package/dist/targets/svelte/radix/label.js +5 -0
- package/dist/targets/svelte/radix/menubar.d.ts +7 -0
- package/dist/targets/svelte/radix/menubar.js +34 -0
- package/dist/targets/svelte/radix/navigation-menu.d.ts +8 -0
- package/dist/targets/svelte/radix/navigation-menu.js +25 -0
- package/dist/targets/svelte/radix/packages.d.ts +34 -0
- package/dist/targets/svelte/radix/packages.js +100 -0
- package/dist/targets/svelte/radix/part.d.ts +161 -0
- package/dist/targets/svelte/radix/part.js +85 -0
- package/dist/targets/svelte/radix/popover.d.ts +7 -0
- package/dist/targets/svelte/radix/popover.js +15 -0
- package/dist/targets/svelte/radix/progress.d.ts +11 -0
- package/dist/targets/svelte/radix/progress.js +27 -0
- package/dist/targets/svelte/radix/radio-group.d.ts +9 -0
- package/dist/targets/svelte/radix/radio-group.js +26 -0
- package/dist/targets/svelte/radix/scroll-area.d.ts +7 -0
- package/dist/targets/svelte/radix/scroll-area.js +19 -0
- package/dist/targets/svelte/radix/select.d.ts +13 -0
- package/dist/targets/svelte/radix/select.js +81 -0
- package/dist/targets/svelte/radix/separator.d.ts +3 -0
- package/dist/targets/svelte/radix/separator.js +5 -0
- package/dist/targets/svelte/radix/slider.d.ts +6 -0
- package/dist/targets/svelte/radix/slider.js +8 -0
- package/dist/targets/svelte/radix/switch.d.ts +6 -0
- package/dist/targets/svelte/radix/switch.js +10 -0
- package/dist/targets/svelte/radix/tabs.d.ts +8 -0
- package/dist/targets/svelte/radix/tabs.js +15 -0
- package/dist/targets/svelte/radix/toggle-group.d.ts +9 -0
- package/dist/targets/svelte/radix/toggle-group.js +17 -0
- package/dist/targets/svelte/radix/toggle.d.ts +6 -0
- package/dist/targets/svelte/radix/toggle.js +9 -0
- package/dist/targets/svelte/radix/tooltip.d.ts +6 -0
- package/dist/targets/svelte/radix/tooltip.js +24 -0
- package/dist/targets/svelte/strip.d.ts +2 -0
- package/dist/targets/svelte/strip.js +5 -0
- package/dist/targets/vue/emit.d.ts +15 -0
- package/dist/targets/vue/emit.js +4092 -0
- package/dist/targets/vue/events.d.ts +11 -0
- package/dist/targets/vue/events.js +13 -0
- package/dist/targets/vue/module-builders.d.ts +28 -0
- package/dist/targets/vue/module-builders.js +258 -0
- package/dist/targets/vue/motion-layout.d.ts +19 -0
- package/dist/targets/vue/motion-layout.js +79 -0
- package/dist/targets/vue/motion.d.ts +12 -0
- package/dist/targets/vue/motion.js +46 -0
- package/dist/targets/vue/radix/accordion.d.ts +3 -0
- package/dist/targets/vue/radix/accordion.js +12 -0
- package/dist/targets/vue/radix/alert-dialog.d.ts +6 -0
- package/dist/targets/vue/radix/alert-dialog.js +18 -0
- package/dist/targets/vue/radix/aspect-ratio.d.ts +6 -0
- package/dist/targets/vue/radix/aspect-ratio.js +8 -0
- package/dist/targets/vue/radix/avatar.d.ts +3 -0
- package/dist/targets/vue/radix/avatar.js +7 -0
- package/dist/targets/vue/radix/checkbox.d.ts +3 -0
- package/dist/targets/vue/radix/checkbox.js +9 -0
- package/dist/targets/vue/radix/collapsible.d.ts +7 -0
- package/dist/targets/vue/radix/collapsible.js +11 -0
- package/dist/targets/vue/radix/context-menu.d.ts +3 -0
- package/dist/targets/vue/radix/context-menu.js +30 -0
- package/dist/targets/vue/radix/dialog.d.ts +3 -0
- package/dist/targets/vue/radix/dialog.js +12 -0
- package/dist/targets/vue/radix/direction.d.ts +7 -0
- package/dist/targets/vue/radix/direction.js +9 -0
- package/dist/targets/vue/radix/dropdown-menu.d.ts +3 -0
- package/dist/targets/vue/radix/dropdown-menu.js +29 -0
- package/dist/targets/vue/radix/hover-card.d.ts +3 -0
- package/dist/targets/vue/radix/hover-card.js +11 -0
- package/dist/targets/vue/radix/index.d.ts +65 -0
- package/dist/targets/vue/radix/index.js +225 -0
- package/dist/targets/vue/radix/label.d.ts +3 -0
- package/dist/targets/vue/radix/label.js +5 -0
- package/dist/targets/vue/radix/menubar.d.ts +6 -0
- package/dist/targets/vue/radix/menubar.js +29 -0
- package/dist/targets/vue/radix/navigation-menu.d.ts +6 -0
- package/dist/targets/vue/radix/navigation-menu.js +21 -0
- package/dist/targets/vue/radix/part.d.ts +41 -0
- package/dist/targets/vue/radix/part.js +46 -0
- package/dist/targets/vue/radix/popover.d.ts +3 -0
- package/dist/targets/vue/radix/popover.js +11 -0
- package/dist/targets/vue/radix/progress.d.ts +3 -0
- package/dist/targets/vue/radix/progress.js +6 -0
- package/dist/targets/vue/radix/radio-group.d.ts +3 -0
- package/dist/targets/vue/radix/radio-group.js +10 -0
- package/dist/targets/vue/radix/scroll-area.d.ts +3 -0
- package/dist/targets/vue/radix/scroll-area.js +11 -0
- package/dist/targets/vue/radix/select.d.ts +3 -0
- package/dist/targets/vue/radix/select.js +29 -0
- package/dist/targets/vue/radix/separator.d.ts +3 -0
- package/dist/targets/vue/radix/separator.js +5 -0
- package/dist/targets/vue/radix/slider.d.ts +3 -0
- package/dist/targets/vue/radix/slider.js +13 -0
- package/dist/targets/vue/radix/switch.d.ts +3 -0
- package/dist/targets/vue/radix/switch.js +9 -0
- package/dist/targets/vue/radix/tabs.d.ts +3 -0
- package/dist/targets/vue/radix/tabs.js +12 -0
- package/dist/targets/vue/radix/toggle-group.d.ts +3 -0
- package/dist/targets/vue/radix/toggle-group.js +10 -0
- package/dist/targets/vue/radix/toggle.d.ts +3 -0
- package/dist/targets/vue/radix/toggle.js +8 -0
- package/dist/targets/vue/radix/tooltip.d.ts +3 -0
- package/dist/targets/vue/radix/tooltip.js +14 -0
- package/dist/targets/vue/render-fn/h.d.ts +52 -0
- package/dist/targets/vue/render-fn/h.js +442 -0
- package/dist/targets/vue/render-fn.d.ts +21 -0
- package/dist/targets/vue/render-fn.js +357 -0
- package/dist/targets/vue/slot.d.ts +9 -0
- package/dist/targets/vue/slot.js +57 -0
- package/dist/typecheck/host.d.ts +45 -0
- package/dist/typecheck/host.js +309 -0
- package/dist/typecheck/index.d.ts +16 -0
- package/dist/typecheck/index.js +17 -0
- package/dist/typecheck/lucide.d.ts +8 -0
- package/dist/typecheck/lucide.js +45 -0
- package/dist/typecheck/sourcemap.d.ts +9 -0
- package/dist/typecheck/sourcemap.js +54 -0
- package/dist/typecheck/svelte.d.ts +9 -0
- package/dist/typecheck/svelte.js +116 -0
- package/dist/typecheck/vue.d.ts +8 -0
- package/dist/typecheck/vue.js +78 -0
- package/dist/types.d.ts +446 -0
- package/dist/types.js +11 -0
- package/dist/utils/cleanup.d.ts +32 -0
- package/dist/utils/cleanup.js +119 -0
- package/dist/utils/errors.d.ts +7 -0
- package/dist/utils/errors.js +15 -0
- package/dist/utils/fs-safe.d.ts +14 -0
- package/dist/utils/fs-safe.js +64 -0
- package/dist/validate.d.ts +16 -0
- package/dist/validate.js +204 -0
- package/dist/verify/auto-steps.d.ts +107 -0
- package/dist/verify/auto-steps.js +471 -0
- package/dist/verify/bundle.d.ts +68 -0
- package/dist/verify/bundle.js +548 -0
- package/dist/verify/diff.d.ts +31 -0
- package/dist/verify/diff.js +133 -0
- package/dist/verify/leaks.d.ts +25 -0
- package/dist/verify/leaks.js +261 -0
- package/dist/verify/link-worker.d.ts +1 -0
- package/dist/verify/link-worker.js +27 -0
- package/dist/verify/runner.d.ts +57 -0
- package/dist/verify/runner.js +867 -0
- package/dist/verify/sandbox.d.ts +40 -0
- package/dist/verify/sandbox.js +496 -0
- package/dist/verify/steps.d.ts +42 -0
- package/dist/verify/steps.js +475 -0
- package/dist/verify/verdict.d.ts +15 -0
- package/dist/verify/verdict.js +19 -0
- package/package.json +118 -4
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
import * as t from '@babel/types';
|
|
2
|
+
import type { AttrNode, ComponentIR, ElementNode, ModuleIR } from '../../ir/model.js';
|
|
3
|
+
import type { NgDirective, NgPartMap } from './radix/part.js';
|
|
4
|
+
/**
|
|
5
|
+
* The host form (H6): a component whose template is one element that is a Radix part on a radix-ng directive (shadcn's
|
|
6
|
+
* `<ToggleGroupPrimitive.Item data-slot … className={cn(…)} {...props}>`) is that element itself. Angular selects the
|
|
7
|
+
* component on the element (`selector: 'button[uiToggleGroupItem]'`), every caller writes the element with the attribute
|
|
8
|
+
* (`<button uiToggleGroupItem …>`), the directive sits on it through `hostDirectives`, and the element's own attributes,
|
|
9
|
+
* classes and listeners are host bindings. No element stands between the part and its caller's elements, as in React:
|
|
10
|
+
* - a radix-ng part in another component finds this one's directive through the injector (the host element is in the
|
|
11
|
+
* chain of the elements its caller writes inside it), where today's `display: contents` host hides it inside the
|
|
12
|
+
* component's own view;
|
|
13
|
+
* - classes that read positions (`first:`, `last:`, `peer-*`, `*:`) see the element among its real siblings.
|
|
14
|
+
* Radix's props and callbacks of the part are the directive's inputs and outputs, bound where the caller writes the
|
|
15
|
+
* element, through the same map and adapters as on a part's element (radix/template.ts); the caller's other attributes
|
|
16
|
+
* and listeners land on the element, as React spreads them onto the part. A hand-written caller does the same: it writes
|
|
17
|
+
* `<button uiToggleGroupItem value="left" aria-label="Left">`, binds radix-ng's inputs and outputs by their own names and
|
|
18
|
+
* shapes (`[controlledValue]="['left']"`, `(onValueChange)="pick($event.value)"`) and puts no `restProps`.
|
|
19
|
+
*/
|
|
20
|
+
/** A component in the host form: the element it is and the part's directive. */
|
|
21
|
+
export interface HostForm {
|
|
22
|
+
/** the root element's tag (`button`), which every caller writes */
|
|
23
|
+
tag: string;
|
|
24
|
+
map: NgPartMap;
|
|
25
|
+
directive: NgDirective;
|
|
26
|
+
pkg: string;
|
|
27
|
+
part: string;
|
|
28
|
+
/**
|
|
29
|
+
* The part renders no element in Radix (Dialog's Root): the component keeps its `display: contents` host and its
|
|
30
|
+
* element selector, and the part's directive is a host directive of that host, where the parts its callers write
|
|
31
|
+
* inside it find it.
|
|
32
|
+
*/
|
|
33
|
+
contents?: boolean;
|
|
34
|
+
}
|
|
35
|
+
/** Each component in the host form, by its IR (set while the Radix parts are prepared, before any file is emitted). */
|
|
36
|
+
export declare const HOST_FORMS: WeakMap<ComponentIR, HostForm>;
|
|
37
|
+
/** The host form of a component, if it has one. */
|
|
38
|
+
export declare function hostFormOf(comp: ComponentIR | null | undefined): HostForm | undefined;
|
|
39
|
+
/**
|
|
40
|
+
* M5: the plain host form. A component whose template is one HTML element with a static tag, and nothing that needs
|
|
41
|
+
* an element of its own around it, is that element too, with no Radix part involved: `selector: 'li[uiItem]'`, the
|
|
42
|
+
* element's own attributes, classes, styles and listeners as host bindings, its children as the template, and every
|
|
43
|
+
* caller writes `<li uiItem …>`. No `display: contents` element stands between the component's root and its parent,
|
|
44
|
+
* so `first:`, `last:`, `odd:`, `peer`, `*:` and `[&>li]:` see the root among its real siblings, as in React.
|
|
45
|
+
* The condition (plainHostFor), everything else keeps today's `<ui-item style="display: contents">`:
|
|
46
|
+
* - the template is one element (no fragment, no `@if` / `@for` / `@switch` at the root), not a component, not a
|
|
47
|
+
* Radix part, with a static HTML tag of HOSTLESS_TAGS (no dynamic tag, no SVG);
|
|
48
|
+
* - no forwarded ref, no ref on the root, no rest props spread (a caller's other attributes would have to land on the
|
|
49
|
+
* element: not built), no render helper written in place, no markup held in data, no Framer props, no portal, no
|
|
50
|
+
* asChild, no inner HTML, no markup passed as a prop on the root, not a field React controls (`value`);
|
|
51
|
+
* - a component of the conversion renders it as a tag (a child; an entry no converted component renders keeps its
|
|
52
|
+
* `ui-` element selector, which hand-written callers and bootstraps use);
|
|
53
|
+
* - its name is never read as a value in any file of the conversion (an NgComponentOutlet or a module table would
|
|
54
|
+
* create it from its selector, which is not proven);
|
|
55
|
+
* - no caller writes children that Angular's template parser closes its element before (CLOSED_BY: a `<div>` or a
|
|
56
|
+
* component inside a `p`, an `li` inside an `li`).
|
|
57
|
+
*/
|
|
58
|
+
export interface PlainHost {
|
|
59
|
+
/** the root element's tag, which every caller writes */
|
|
60
|
+
tag: string;
|
|
61
|
+
}
|
|
62
|
+
/**
|
|
63
|
+
* Notes the names a module reads as values (its components' code and markup, its hooks and module code; not the
|
|
64
|
+
* `Name.displayName = …` lines or `export { Name }` lists that only name a component) and the names it renders as a
|
|
65
|
+
* tag. Called for every Angular module before any is emitted, with the Radix preparation (radix/prepare.ts), so a
|
|
66
|
+
* component's form is known to every caller. `conversion`: an object of the conversion that prepares the module (the
|
|
67
|
+
* same for all its modules).
|
|
68
|
+
*/
|
|
69
|
+
export declare function noteValueReads(mod: ModuleIR, conversion: object): void;
|
|
70
|
+
/** Whether a component takes the plain host form (the condition above), decided once per component. */
|
|
71
|
+
export declare function plainHostFor(comp: ComponentIR | null | undefined): PlainHost | undefined;
|
|
72
|
+
/** The attribute a host-form component is selected by: its element selector camel-cased (`ui-toggle` → `uiToggle`). */
|
|
73
|
+
export declare function hostAttribute(selector: string): string;
|
|
74
|
+
/**
|
|
75
|
+
* Whether a component whose root element `el` is a claimed Radix part takes the host form; checked on the component as
|
|
76
|
+
* lowered (before the part's element is prepared). Narrow on purpose: everything else keeps the element host.
|
|
77
|
+
* - the component is exported (a private one may be written in place by its caller, which has no host to put it on),
|
|
78
|
+
* takes no forwarded ref, has no render helper or markup held in data;
|
|
79
|
+
* - its template is this one element, with a static tag, no Framer props, no portal, no `asChild`, no ref, no inner HTML
|
|
80
|
+
* and no markup passed as a prop;
|
|
81
|
+
* - the element gives the part none of Radix's props or callbacks itself (they reach it only through the rest props,
|
|
82
|
+
* so the caller binds them on the host), and spreads nothing but the component's rest props, which nothing else reads.
|
|
83
|
+
*/
|
|
84
|
+
export declare function hostFormFor(mod: ModuleIR, comp: ComponentIR, el: ElementNode, map: NgPartMap, pkg: string, part: string): HostForm | null;
|
|
85
|
+
/** What a caller's template printer lends the host form: its own printing. */
|
|
86
|
+
export interface HostFormPrinter {
|
|
87
|
+
expr(e: t.Expression, hint: string): string;
|
|
88
|
+
handler(e: t.Expression, event: string): string;
|
|
89
|
+
/** React's type of a value, when the checker gives one */
|
|
90
|
+
typeOf(e: t.Expression): t.TSType | null;
|
|
91
|
+
/** the attributes as the printer writes them on a DOM element of this tag */
|
|
92
|
+
dom(attrs: AttrNode[]): string[];
|
|
93
|
+
/** the attributes as the printer writes them on the component, every value bound (no static attribute) */
|
|
94
|
+
own(attrs: AttrNode[]): string[];
|
|
95
|
+
warn(code: string, message: string, severity: 'warning' | 'error' | 'info', line?: number): void;
|
|
96
|
+
}
|
|
97
|
+
/**
|
|
98
|
+
* The attributes a caller writes on a host-form component's element (`<button uiToggleGroupItem …>`): Radix's props and
|
|
99
|
+
* callbacks of the part as the directive's inputs and outputs (adapted as on a part's element), the component's own
|
|
100
|
+
* props as its inputs (bound, so none lands on the element as an attribute too), and every other attribute and listener
|
|
101
|
+
* as the element's own, as React spreads the rest props onto the part. A part radix-ng finds its root through the
|
|
102
|
+
* injector must be written inside that root (its element, or a host-form component of it) in the caller's template.
|
|
103
|
+
* (M3: `ownEvents`, the event props the child declares: any other handler is the element's listener.)
|
|
104
|
+
*/
|
|
105
|
+
export declare function hostFormCaller(n: ElementNode, form: HostForm, ownKeys: ReadonlySet<string>, p: HostFormPrinter, ownEvents?: ReadonlySet<string>): string[];
|
|
106
|
+
/**
|
|
107
|
+
* Where a caller writes a component that holds a Radix part radix-ng finds (or reads) through the injector outside the
|
|
108
|
+
* component's own template (radixNeedsOf): the caller's template must have, above it, an element of that part or a
|
|
109
|
+
* component in the host form that is one. Otherwise the part would silently run on its own: a located error.
|
|
110
|
+
*/
|
|
111
|
+
export declare function radixNeedsAt(caller: ComponentIR, n: ElementNode, child: ComponentIR | null, formOf: (tag: string) => HostForm | undefined, warn: (message: string, line?: number) => void, note?: (message: string, line?: number) => void): void;
|
|
112
|
+
/**
|
|
113
|
+
* The element a caller writes for a child whose rest props reach a Radix part that renders no element, without the
|
|
114
|
+
* attributes that go nowhere (as in React; radixNeedsAt says them): the child's own props, Radix's props of the part
|
|
115
|
+
* and asChild stay. Any other child: the element as it is.
|
|
116
|
+
*/
|
|
117
|
+
export declare function withoutIgnoredAttrs(n: ElementNode, child: ComponentIR | null): ElementNode;
|
|
118
|
+
/** The decorator and class of a host-form component, from its template as printed (its one root element). */
|
|
119
|
+
export interface HostedClass {
|
|
120
|
+
/** `button[uiToggleGroupItem]` */
|
|
121
|
+
selector: string;
|
|
122
|
+
/** the root element's children */
|
|
123
|
+
template: string;
|
|
124
|
+
/** the root element's attributes, classes and listeners, as host metadata */
|
|
125
|
+
host: t.ObjectExpression;
|
|
126
|
+
hostDirectives: t.ArrayExpression;
|
|
127
|
+
/** class members: the directive, injected, where the template read it by its exportAs (`#toggle="rdxToggle"`) */
|
|
128
|
+
members: t.ClassProperty[];
|
|
129
|
+
/** the directive classes the file imports for it */
|
|
130
|
+
uses: string[];
|
|
131
|
+
}
|
|
132
|
+
/**
|
|
133
|
+
* The class of a host-form component: its root element as printed becomes its host (attributes and bindings as host
|
|
134
|
+
* metadata, the part's directive in hostDirectives with every mapped input and output exposed under radix-ng's names),
|
|
135
|
+
* the element's children its template, and a template reference to the directive a member that injects it (host
|
|
136
|
+
* bindings and the children read it by the same name). A string: why the printed root cannot be the host.
|
|
137
|
+
*/
|
|
138
|
+
export declare function hostedClass(given: HostForm | PlainHost, selector: string, markup: string, api: (name: string) => string): HostedClass | string;
|
|
139
|
+
/**
|
|
140
|
+
* Writes a host-form class into a component's decorator and members as the emitter built them: the attribute selector,
|
|
141
|
+
* the host bindings in place of `display: contents`, the directive in `hostDirectives` (after `imports`), the root's
|
|
142
|
+
* children as the template, and the injected directive first among the members.
|
|
143
|
+
*/
|
|
144
|
+
export declare function applyHostedClass(meta: t.ObjectProperty[], members: t.ClassBody['body'], hosted: HostedClass, template: t.Expression): void;
|
|
145
|
+
/**
|
|
146
|
+
* The members a component injects for the Radix parts its template reads through the injector (radix/template.ts
|
|
147
|
+
* injectedDirectives): `protected readonly accordionItem = inject(RdxAccordionItemDirective);`. `use` names each class
|
|
148
|
+
* for the file's imports (not the decorator's: a class it injects is no template import).
|
|
149
|
+
*/
|
|
150
|
+
export declare function injectedMembers(comp: ComponentIR, inject: () => string, use: (name: string) => void): t.ClassProperty[];
|