motionary 13.5.0 → 13.7.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/CHANGELOG.md +90 -0
- package/README.md +1 -1
- package/bin/mcp-browser.mjs +167 -0
- package/bin/mcp-tools-2.mjs +187 -0
- package/bin/motionary-mcp.mjs +140 -34
- package/dist/chunks/{anim-image-CSVlsA0t.cjs → anim-image-CI1zz699.cjs} +2 -2
- package/dist/chunks/{anim-image-D6yGJ5SF.js → anim-image-DbZ01u7s.js} +2 -2
- package/dist/chunks/audio-CZgCXg1t.js +1 -1
- package/dist/chunks/audio-D0LwPShE.cjs +1 -1
- package/dist/chunks/badge-wall-C0gJ_Kck.js +1 -1
- package/dist/chunks/badge-wall-CITexuW7.cjs +1 -1
- package/dist/chunks/base-BvH4nAcv.cjs +1 -1
- package/dist/chunks/base-C9CJrhL3.js +1 -1
- package/dist/chunks/bg-generator-CML8tPN8.cjs +1 -1
- package/dist/chunks/bg-generator-oRwfTA5B.js +1 -1
- package/dist/chunks/bind-B_CTL6Qn.js +1 -1
- package/dist/chunks/bind-Ui43-n2d.cjs +1 -1
- package/dist/chunks/builtins-DweCp29Z.cjs +1 -1
- package/dist/chunks/builtins-SwWQKzb-.js +1 -1
- package/dist/chunks/carousel-DU3rHTq0.cjs +1 -1
- package/dist/chunks/carousel-u6rqMqGu.js +1 -1
- package/dist/chunks/cart-drawer-CEIZfCw8.js +1 -1
- package/dist/chunks/cart-drawer-CkFMKMhx.cjs +1 -1
- package/dist/chunks/code-export-PdGSl9WE.cjs +1 -1
- package/dist/chunks/code-export-wdrBIWRv.js +1 -1
- package/dist/chunks/color-picker-B_xWVH8H.cjs +1 -1
- package/dist/chunks/color-picker-CN8ThZfh.js +1 -1
- package/dist/chunks/command-palette-IJuNiXhv.js +1 -1
- package/dist/chunks/command-palette-ISetAeX1.cjs +1 -1
- package/dist/chunks/core-B9Sjd4AV.js +1 -1
- package/dist/chunks/core-BZhM_0Zh.js +1 -1
- package/dist/chunks/core-BjcOCpJt.cjs +1 -1
- package/dist/chunks/core-DbAYRKnS.cjs +1 -1
- package/dist/chunks/core-Dj6iomdc.js +1 -1
- package/dist/chunks/core-DjjKLmZ6.cjs +1 -1
- package/dist/chunks/countdown-RQViryt7.cjs +1 -1
- package/dist/chunks/countdown-WDZxXQz7.js +1 -1
- package/dist/chunks/date-picker-BgApzPNn.cjs +1 -1
- package/dist/chunks/date-picker-D4yqKTMJ.js +1 -1
- package/dist/chunks/ease-HwYZnZat.cjs +1 -1
- package/dist/chunks/ease-XN8_0sXu.js +1 -1
- package/dist/chunks/equalizer-CwGL1sD8.js +1 -1
- package/dist/chunks/equalizer-_eD_ZdCl.cjs +1 -1
- package/dist/chunks/festival-banner-Bs18K0MJ.cjs +1 -1
- package/dist/chunks/festival-banner-Dslu8K1g.js +1 -1
- package/dist/chunks/field-DALTalya.js +1 -1
- package/dist/chunks/field-Dwq8-CLN.cjs +1 -1
- package/dist/chunks/fx-DaVuB89C.cjs +1 -1
- package/dist/chunks/fx-Dc1sMyNg.js +1 -1
- package/dist/chunks/generative-BKoxWOSP.cjs +1 -1
- package/dist/chunks/generative-DWdAwxYB.js +1 -1
- package/dist/chunks/{gl-scene-Ccn_PpRS.cjs → gl-scene-CZHMOsiS.cjs} +2 -2
- package/dist/chunks/{gl-scene-BjQkVhUh.js → gl-scene-Cz74D0PJ.js} +2 -2
- package/dist/chunks/globe-D56xlOmk.js +1 -1
- package/dist/chunks/globe-DA0jyb6s.cjs +1 -1
- package/dist/chunks/gpu-7AY-uzNc.js +1 -1
- package/dist/chunks/gpu-DTO3JmAF.cjs +1 -1
- package/dist/chunks/gpu-particles-4DBj91f-.js +1 -1
- package/dist/chunks/gpu-particles-wEO_rds1.cjs +1 -1
- package/dist/chunks/index-tags-B-JBecYg.js +1 -1
- package/dist/chunks/index-tags-hLIF2Clq.cjs +1 -1
- package/dist/chunks/key-click-BLm3BI8_.js +1 -1
- package/dist/chunks/key-click-v7I4K5Sr.cjs +1 -1
- package/dist/chunks/{keyframes-t521frAa.js → keyframes-Cy-Ya5VG.js} +2 -2
- package/dist/chunks/{keyframes-DyniziL4.cjs → keyframes-DgqHSGbC.cjs} +2 -2
- package/dist/chunks/leaderboard-DvSSQ8o3.cjs +1 -1
- package/dist/chunks/leaderboard-_UPi0KQX.js +1 -1
- package/dist/chunks/location-card-Bq596aK5.js +1 -1
- package/dist/chunks/location-card-DSPTApUe.cjs +1 -1
- package/dist/chunks/lottie-icon-BoxkukMd.cjs +1 -1
- package/dist/chunks/lottie-icon-pqBgCV0y.js +1 -1
- package/dist/chunks/{lottie-player-D6YGOx39.cjs → lottie-player-0-dmhjY3.cjs} +2 -2
- package/dist/chunks/{lottie-player-C9X0Gp_E.js → lottie-player-cHCLzYaM.js} +2 -2
- package/dist/chunks/lyrics-CRB7dA1j.cjs +1 -1
- package/dist/chunks/lyrics-D7mzxVIq.js +1 -1
- package/dist/chunks/manifest-CqfKtjeL.js +1 -1
- package/dist/chunks/manifest-xr3WET80.cjs +1 -1
- package/dist/chunks/menu-CZ1zHTT9.cjs +1 -1
- package/dist/chunks/menu-XcdMtcfw.js +1 -1
- package/dist/chunks/menu-toggle-DGXN4VsN.cjs +1 -1
- package/dist/chunks/menu-toggle-RD6Fu1Gm.js +1 -1
- package/dist/chunks/nav-morph-C4rD3wrU.cjs +1 -1
- package/dist/chunks/nav-morph-F6qzM20K.js +1 -1
- package/dist/chunks/otp-BJKyY7I3.js +1 -1
- package/dist/chunks/otp-DUyEWYMi.cjs +1 -1
- package/dist/chunks/pagination-D6iMBStU.js +1 -1
- package/dist/chunks/pagination-DHmYZZU9.cjs +1 -1
- package/dist/chunks/{physics-playground-BJx2yVvV.cjs → physics-playground-11Y_zOVT.cjs} +2 -2
- package/dist/chunks/{physics-playground-C8jCWhgK.js → physics-playground-C5U58CX8.js} +2 -2
- package/dist/chunks/player-BTaPvK8G.js +1 -1
- package/dist/chunks/player-BZOkQbZ9.cjs +1 -1
- package/dist/chunks/presence-6eQ9t5vX.js +1 -1
- package/dist/chunks/presence-DAthlALi.cjs +1 -1
- package/dist/chunks/presets-BYBVJVeP.js +1 -1
- package/dist/chunks/presets-CUHys3sK.cjs +1 -1
- package/dist/chunks/prize-wheel-CpGVo8QG.js +1 -1
- package/dist/chunks/prize-wheel-emDopI5c.cjs +1 -1
- package/dist/chunks/product-gallery-BmnYLKAQ.js +1 -1
- package/dist/chunks/product-gallery-CKtSVhZk.cjs +1 -1
- package/dist/chunks/progress-ring-C75O4MUi.cjs +1 -1
- package/dist/chunks/progress-ring-CKgR1GRB.js +1 -1
- package/dist/chunks/prop-panel-BjbCiPAB.js +1 -1
- package/dist/chunks/prop-panel-DFqga6H5.cjs +1 -1
- package/dist/chunks/radar-D-bZRrgs.cjs +1 -1
- package/dist/chunks/radar-rBQT1BFh.js +1 -1
- package/dist/chunks/reactions-BL2iO8iy.cjs +1 -1
- package/dist/chunks/reactions-CsdP0Su5.js +1 -1
- package/dist/chunks/{registry-Ng9TVXnA.js → registry-CX6Esj3Z.js} +2 -2
- package/dist/chunks/registry-CibnX7Ui.cjs +1 -1
- package/dist/chunks/registry-DKs_BiEo.js +1 -1
- package/dist/chunks/{registry-D4qv6B49.cjs → registry-DlT6mFCX.cjs} +2 -2
- package/dist/chunks/retro-button-Bw4sqAkl.js +1 -1
- package/dist/chunks/retro-button-DrrBZ6w8.cjs +1 -1
- package/dist/chunks/rive-D6X4J0Mi.cjs +1 -1
- package/dist/chunks/rive-FjeW9KDl.js +1 -1
- package/dist/chunks/{runtime-link-DDGDuR6q.cjs → runtime-link-CZme1oj-.cjs} +2 -2
- package/dist/chunks/{runtime-link-BZd9tPZE.js → runtime-link-DycKZ8ru.js} +2 -2
- package/dist/chunks/scroll-driven-CQbwzCdn.cjs +1 -1
- package/dist/chunks/scroll-driven-LghshrWq.js +1 -1
- package/dist/chunks/{scroll-scene-Ch5d1PER.cjs → scroll-scene-RCH_NMdX.cjs} +3 -3
- package/dist/chunks/{scroll-scene-CgFA-E0N.js → scroll-scene-nnC31K0L.js} +3 -3
- package/dist/chunks/segmented-BEep92iW.js +1 -1
- package/dist/chunks/segmented-CpB4mKIn.cjs +1 -1
- package/dist/chunks/shader-backdrop-C4UhepvI.cjs +1 -1
- package/dist/chunks/shader-backdrop-DC0ZvVMV.js +1 -1
- package/dist/chunks/shared-Bf72wLyt.cjs +1 -1
- package/dist/chunks/shared-CkKHWrtJ.js +1 -1
- package/dist/chunks/shared-jkgRH-Hx.cjs +1 -1
- package/dist/chunks/shared-o9CtwHmi.js +1 -1
- package/dist/chunks/sheet-B38ylIEW.cjs +1 -1
- package/dist/chunks/sheet-BHTMF8qx.js +1 -1
- package/dist/chunks/sign-DvZ1jHxE.js +1 -1
- package/dist/chunks/sign-RAkQIWrM.cjs +1 -1
- package/dist/chunks/skeleton-reveal-BMrbmru6.js +1 -1
- package/dist/chunks/skeleton-reveal-Dsd3Wp0n.cjs +1 -1
- package/dist/chunks/sparkline-DeKhZpVo.cjs +1 -1
- package/dist/chunks/sparkline-htTaTcgs.js +1 -1
- package/dist/chunks/spring-DBCejV_z.js +1 -1
- package/dist/chunks/spring-XEl_diDJ.cjs +1 -1
- package/dist/chunks/stagger-B9sKPwQB.js +1 -1
- package/dist/chunks/stagger-DFKwqOQG.cjs +1 -1
- package/dist/chunks/suggestion-chips-CAcbFTr4.cjs +1 -1
- package/dist/chunks/suggestion-chips-Cj70JCtZ.js +1 -1
- package/dist/chunks/switch-CnSs8nDn.js +1 -1
- package/dist/chunks/switch-DiTlApGd.cjs +1 -1
- package/dist/chunks/tab-bar-B7hFB974.js +1 -1
- package/dist/chunks/tab-bar-BBlVAqbq.cjs +1 -1
- package/dist/chunks/{ticker-DZN0D39q.js → ticker-B4Xe-qCg.js} +2 -2
- package/dist/chunks/{ticker-Bcx-J0T3.cjs → ticker-BP_jd4sz.cjs} +2 -2
- package/dist/chunks/tip-VGS3qAUm.cjs +1 -1
- package/dist/chunks/tip-ylGHoOIf.js +1 -1
- package/dist/chunks/toast-stack-DprisNp_.cjs +1 -1
- package/dist/chunks/toast-stack-Z_5cS1Nz.js +1 -1
- package/dist/chunks/{tween-DZdCTOBG.js → tween-bb-hNM7p.js} +2 -2
- package/dist/chunks/{tween-C755kVRe.cjs → tween-qF0Mcf3-.cjs} +2 -2
- package/dist/chunks/upload-progress-CEAWkP-p.cjs +1 -1
- package/dist/chunks/upload-progress-y7N0eaM4.js +1 -1
- package/dist/chunks/variants-BtqEJuki.cjs +1 -1
- package/dist/chunks/variants-MxfB3UVB.js +1 -1
- package/dist/chunks/viewport-BAXHhZLV.js +1 -1
- package/dist/chunks/viewport-EFYGqMNa.cjs +1 -1
- package/dist/chunks/voice-button-9UauxvT9.cjs +1 -1
- package/dist/chunks/voice-button-DFEoNe24.js +1 -1
- package/dist/chunks/weather-card-4Eg6e43D.cjs +1 -1
- package/dist/chunks/weather-card-NR0i507J.js +1 -1
- package/dist/chunks/worker-canvas-BMBXAFWp.cjs +1 -1
- package/dist/chunks/worker-canvas-CPZvzrWQ.js +1 -1
- package/dist/chunks/xp-bar-DAbx1LZ_.js +1 -1
- package/dist/chunks/xp-bar-DkWfCTfB.cjs +1 -1
- package/dist/components/a11y.cjs +1 -1
- package/dist/components/a11y.js +1 -1
- package/dist/components/ai.cjs +1 -1
- package/dist/components/ai.js +1 -1
- package/dist/components/angular.cjs +1 -1
- package/dist/components/angular.js +1 -1
- package/dist/components/background.cjs +1 -1
- package/dist/components/background.js +1 -1
- package/dist/components/bridge.cjs +1 -1
- package/dist/components/bridge.js +1 -1
- package/dist/components/cards.cjs +1 -1
- package/dist/components/cards.js +1 -1
- package/dist/components/click.cjs +1 -1
- package/dist/components/click.js +1 -1
- package/dist/components/core.cjs +1 -1
- package/dist/components/core.js +1 -1
- package/dist/components/depth.cjs +1 -1
- package/dist/components/depth.js +1 -1
- package/dist/components/design.cjs +1 -1
- package/dist/components/design.js +1 -1
- package/dist/components/dotlottie.cjs +3 -3
- package/dist/components/dotlottie.js +3 -3
- package/dist/components/dsl.cjs +1 -1
- package/dist/components/dsl.js +1 -1
- package/dist/components/effects.cjs +1 -1
- package/dist/components/effects.js +1 -1
- package/dist/components/engine.cjs +1 -1
- package/dist/components/engine.js +1 -1
- package/dist/components/feedback.cjs +1 -1
- package/dist/components/feedback.js +1 -1
- package/dist/components/fx-3d.cjs +1 -1
- package/dist/components/fx-3d.js +1 -1
- package/dist/components/fx-ai.cjs +1 -1
- package/dist/components/fx-ai.js +1 -1
- package/dist/components/fx-chart.cjs +1 -1
- package/dist/components/fx-chart.js +1 -1
- package/dist/components/fx-cinema.cjs +1 -1
- package/dist/components/fx-cinema.js +1 -1
- package/dist/components/fx-cyber.cjs +1 -1
- package/dist/components/fx-cyber.js +1 -1
- package/dist/components/fx-festival.cjs +1 -1
- package/dist/components/fx-festival.js +1 -1
- package/dist/components/fx-focus.cjs +1 -1
- package/dist/components/fx-focus.js +1 -1
- package/dist/components/fx-form.cjs +1 -1
- package/dist/components/fx-form.js +1 -1
- package/dist/components/fx-game.cjs +1 -1
- package/dist/components/fx-game.js +1 -1
- package/dist/components/fx-genart.cjs +1 -1
- package/dist/components/fx-genart.js +1 -1
- package/dist/components/fx-geo.cjs +1 -1
- package/dist/components/fx-geo.js +1 -1
- package/dist/components/fx-gesture.cjs +1 -1
- package/dist/components/fx-gesture.js +1 -1
- package/dist/components/fx-gpu.cjs +1 -1
- package/dist/components/fx-gpu.js +1 -1
- package/dist/components/fx-light.cjs +1 -1
- package/dist/components/fx-light.js +1 -1
- package/dist/components/fx-lottie.cjs +1 -1
- package/dist/components/fx-lottie.js +1 -1
- package/dist/components/fx-morph.cjs +1 -1
- package/dist/components/fx-morph.js +1 -1
- package/dist/components/fx-music.cjs +1 -1
- package/dist/components/fx-music.js +1 -1
- package/dist/components/fx-organic.cjs +1 -1
- package/dist/components/fx-organic.js +1 -1
- package/dist/components/fx-paper.cjs +1 -1
- package/dist/components/fx-paper.js +1 -1
- package/dist/components/fx-perf.cjs +1 -1
- package/dist/components/fx-perf.js +1 -1
- package/dist/components/fx-physics.cjs +1 -1
- package/dist/components/fx-physics.js +1 -1
- package/dist/components/fx-retro.cjs +1 -1
- package/dist/components/fx-retro.js +1 -1
- package/dist/components/fx-safe.cjs +1 -1
- package/dist/components/fx-safe.js +1 -1
- package/dist/components/fx-shop.cjs +1 -1
- package/dist/components/fx-shop.js +1 -1
- package/dist/components/fx-social.cjs +1 -1
- package/dist/components/fx-social.js +1 -1
- package/dist/components/fx-spatial.cjs +1 -1
- package/dist/components/fx-spatial.js +1 -1
- package/dist/components/fx-surface.cjs +1 -1
- package/dist/components/fx-surface.js +1 -1
- package/dist/components/fx-text.cjs +1 -1
- package/dist/components/fx-text.js +1 -1
- package/dist/components/fx-transitions.cjs +1 -1
- package/dist/components/fx-transitions.js +1 -1
- package/dist/components/fx-video.cjs +1 -1
- package/dist/components/fx-video.js +1 -1
- package/dist/components/fx-weather.cjs +1 -1
- package/dist/components/fx-weather.js +1 -1
- package/dist/components/fx.cjs +1 -1
- package/dist/components/fx.js +1 -1
- package/dist/components/fx2.cjs +1 -1
- package/dist/components/fx2.js +1 -1
- package/dist/components/gesture.cjs +1 -1
- package/dist/components/gesture.js +1 -1
- package/dist/components/gl-model.cjs +3 -3
- package/dist/components/gl-model.js +3 -3
- package/dist/components/interaction.cjs +1 -1
- package/dist/components/interaction.js +1 -1
- package/dist/components/jsx.cjs +1 -1
- package/dist/components/jsx.js +1 -1
- package/dist/components/layout.cjs +1 -1
- package/dist/components/layout.js +1 -1
- package/dist/components/lazy.cjs +1 -1
- package/dist/components/lazy.js +1 -1
- package/dist/components/lite.cjs +1 -1
- package/dist/components/lite.js +1 -1
- package/dist/components/marketplace.cjs +1 -1
- package/dist/components/marketplace.js +1 -1
- package/dist/components/native.cjs +1 -1
- package/dist/components/native.js +1 -1
- package/dist/components/offscreen.cjs +1 -1
- package/dist/components/offscreen.js +1 -1
- package/dist/components/packs.cjs +1 -1
- package/dist/components/packs.js +1 -1
- package/dist/components/page.cjs +1 -1
- package/dist/components/page.js +1 -1
- package/dist/components/perf-tasks.cjs +1 -1
- package/dist/components/perf-tasks.js +1 -1
- package/dist/components/perf.cjs +1 -1
- package/dist/components/perf.js +1 -1
- package/dist/components/physics.cjs +1 -1
- package/dist/components/physics.js +1 -1
- package/dist/components/plugins.cjs +1 -1
- package/dist/components/plugins.js +1 -1
- package/dist/components/react.cjs +1 -1
- package/dist/components/react.js +1 -1
- package/dist/components/reveal.cjs +1 -1
- package/dist/components/reveal.js +1 -1
- package/dist/components/snap-carousel.cjs +2 -2
- package/dist/components/snap-carousel.js +2 -2
- package/dist/components/solid.cjs +1 -1
- package/dist/components/solid.js +1 -1
- package/dist/components/svelte.cjs +1 -1
- package/dist/components/svelte.js +1 -1
- package/dist/components/svg.cjs +1 -1
- package/dist/components/svg.js +1 -1
- package/dist/components/text.cjs +1 -1
- package/dist/components/text.js +1 -1
- package/dist/components/timeline-editor.cjs +1172 -0
- package/dist/components/timeline-editor.d.cts +455 -0
- package/dist/components/timeline-editor.d.ts +455 -0
- package/dist/components/timeline-editor.js +1129 -0
- package/dist/components/timeline.cjs +1 -1
- package/dist/components/timeline.js +1 -1
- package/dist/components/tokens.cjs +1 -1
- package/dist/components/tokens.js +1 -1
- package/dist/components/transitions.cjs +1 -1
- package/dist/components/transitions.js +1 -1
- package/dist/components/ui.cjs +1 -1
- package/dist/components/ui.js +1 -1
- package/dist/components/vue.cjs +1 -1
- package/dist/components/vue.js +1 -1
- package/dist/components/webgl.cjs +1 -1
- package/dist/components/webgl.js +1 -1
- package/dist/components/widgets.cjs +5 -5
- package/dist/components/widgets.js +7 -7
- package/dist/components.cjs +1 -1
- package/dist/components.js +1 -1
- package/dist/components.umd.js +1 -1
- package/dist/effects/achievement-unlock.cjs +1 -1
- package/dist/effects/achievement-unlock.js +1 -1
- package/dist/effects/aurora-veil.cjs +1 -1
- package/dist/effects/aurora-veil.js +1 -1
- package/dist/effects/badge-pop.cjs +1 -1
- package/dist/effects/badge-pop.js +1 -1
- package/dist/effects/bars-grow.cjs +1 -1
- package/dist/effects/bars-grow.js +1 -1
- package/dist/effects/beat-bounce.cjs +1 -1
- package/dist/effects/beat-bounce.js +1 -1
- package/dist/effects/blob-button.cjs +1 -1
- package/dist/effects/blob-button.js +1 -1
- package/dist/effects/bloom.cjs +1 -1
- package/dist/effects/bloom.js +1 -1
- package/dist/effects/breathe.cjs +1 -1
- package/dist/effects/breathe.js +1 -1
- package/dist/effects/brushed-metal.cjs +1 -1
- package/dist/effects/brushed-metal.js +1 -1
- package/dist/effects/camera-dolly.cjs +1 -1
- package/dist/effects/camera-dolly.js +1 -1
- package/dist/effects/card-flip-3d.cjs +1 -1
- package/dist/effects/card-flip-3d.js +1 -1
- package/dist/effects/chest-open.cjs +1 -1
- package/dist/effects/chest-open.js +1 -1
- package/dist/effects/cloth.cjs +1 -1
- package/dist/effects/cloth.js +1 -1
- package/dist/effects/coin-burst.cjs +1 -1
- package/dist/effects/coin-burst.js +1 -1
- package/dist/effects/color-pulse.cjs +1 -1
- package/dist/effects/color-pulse.js +1 -1
- package/dist/effects/crt-power.cjs +1 -1
- package/dist/effects/crt-power.js +1 -1
- package/dist/effects/crumple.cjs +1 -1
- package/dist/effects/crumple.js +1 -1
- package/dist/effects/data-decode.cjs +1 -1
- package/dist/effects/data-decode.js +1 -1
- package/dist/effects/day-cycle.cjs +1 -1
- package/dist/effects/day-cycle.js +1 -1
- package/dist/effects/depth-in.cjs +1 -1
- package/dist/effects/depth-in.js +1 -1
- package/dist/effects/depth-pop.cjs +1 -1
- package/dist/effects/depth-pop.js +1 -1
- package/dist/effects/depth-stack.cjs +1 -1
- package/dist/effects/depth-stack.js +1 -1
- package/dist/effects/dolly-in.cjs +1 -1
- package/dist/effects/dolly-in.js +1 -1
- package/dist/effects/dots-pop.cjs +1 -1
- package/dist/effects/dots-pop.js +1 -1
- package/dist/effects/field-shake.cjs +1 -1
- package/dist/effects/field-shake.js +1 -1
- package/dist/effects/field-success.cjs +1 -1
- package/dist/effects/field-success.js +1 -1
- package/dist/effects/film-burn.cjs +1 -1
- package/dist/effects/film-burn.js +1 -1
- package/dist/effects/fire.cjs +1 -1
- package/dist/effects/fire.js +1 -1
- package/dist/effects/fireflies.cjs +1 -1
- package/dist/effects/fireflies.js +1 -1
- package/dist/effects/firework-burst.cjs +1 -1
- package/dist/effects/firework-burst.js +1 -1
- package/dist/effects/flip-chars.cjs +1 -1
- package/dist/effects/flip-chars.js +1 -1
- package/dist/effects/fluid.cjs +1 -1
- package/dist/effects/fluid.js +1 -1
- package/dist/effects/fly-to-cart.cjs +1 -1
- package/dist/effects/fly-to-cart.js +1 -1
- package/dist/effects/focus-draw.cjs +1 -1
- package/dist/effects/focus-draw.js +1 -1
- package/dist/effects/focus-glow.cjs +1 -1
- package/dist/effects/focus-glow.js +1 -1
- package/dist/effects/fog.cjs +1 -1
- package/dist/effects/fog.js +1 -1
- package/dist/effects/font-breathe.cjs +1 -1
- package/dist/effects/font-breathe.js +1 -1
- package/dist/effects/form-cascade.cjs +1 -1
- package/dist/effects/form-cascade.js +1 -1
- package/dist/effects/gen-skeleton.cjs +1 -1
- package/dist/effects/gen-skeleton.js +1 -1
- package/dist/effects/glass-frost.cjs +1 -1
- package/dist/effects/glass-frost.js +1 -1
- package/dist/effects/glitch-text.cjs +1 -1
- package/dist/effects/glitch-text.js +1 -1
- package/dist/effects/globe-spin.cjs +1 -1
- package/dist/effects/globe-spin.js +1 -1
- package/dist/effects/god-rays.cjs +1 -1
- package/dist/effects/god-rays.js +1 -1
- package/dist/effects/gpu-lift.cjs +1 -1
- package/dist/effects/gpu-lift.js +1 -1
- package/dist/effects/grain-flicker.cjs +1 -1
- package/dist/effects/grain-flicker.js +1 -1
- package/dist/effects/halftone-in.cjs +1 -1
- package/dist/effects/halftone-in.js +1 -1
- package/dist/effects/highlight-sweep.cjs +1 -1
- package/dist/effects/highlight-sweep.js +1 -1
- package/dist/effects/hologram.cjs +1 -1
- package/dist/effects/hologram.js +1 -1
- package/dist/effects/hud-frame.cjs +1 -1
- package/dist/effects/hud-frame.js +1 -1
- package/dist/effects/icon-pop.cjs +1 -1
- package/dist/effects/icon-pop.js +1 -1
- package/dist/effects/icon-swap.cjs +1 -1
- package/dist/effects/icon-swap.js +1 -1
- package/dist/effects/idle-reveal.cjs +1 -1
- package/dist/effects/idle-reveal.js +1 -1
- package/dist/effects/ink.cjs +1 -1
- package/dist/effects/ink.js +1 -1
- package/dist/effects/jump-cut.cjs +1 -1
- package/dist/effects/jump-cut.js +1 -1
- package/dist/effects/kaleido.cjs +1 -1
- package/dist/effects/kaleido.js +1 -1
- package/dist/effects/label-float.cjs +1 -1
- package/dist/effects/label-float.js +1 -1
- package/dist/effects/lantern-rise.cjs +1 -1
- package/dist/effects/lantern-rise.js +1 -1
- package/dist/effects/leaves.cjs +1 -1
- package/dist/effects/leaves.js +1 -1
- package/dist/effects/letterbox.cjs +1 -1
- package/dist/effects/letterbox.js +1 -1
- package/dist/effects/level-up.cjs +1 -1
- package/dist/effects/level-up.js +1 -1
- package/dist/effects/light-follow.cjs +1 -1
- package/dist/effects/light-follow.js +1 -1
- package/dist/effects/lightning.cjs +1 -1
- package/dist/effects/lightning.js +1 -1
- package/dist/effects/line-draw.cjs +1 -1
- package/dist/effects/line-draw.js +1 -1
- package/dist/effects/liquid-text.cjs +1 -1
- package/dist/effects/liquid-text.js +1 -1
- package/dist/effects/liquid-wipe.cjs +1 -1
- package/dist/effects/liquid-wipe.js +1 -1
- package/dist/effects/lottie-play.cjs +1 -1
- package/dist/effects/lottie-play.js +1 -1
- package/dist/effects/magnet.cjs +1 -1
- package/dist/effects/magnet.js +1 -1
- package/dist/effects/marching-ants.cjs +1 -1
- package/dist/effects/marching-ants.js +1 -1
- package/dist/effects/marker-pulse.cjs +1 -1
- package/dist/effects/marker-pulse.js +1 -1
- package/dist/effects/mention-glow.cjs +1 -1
- package/dist/effects/mention-glow.js +1 -1
- package/dist/effects/mesh-drift.cjs +1 -1
- package/dist/effects/mesh-drift.js +1 -1
- package/dist/effects/message-in.cjs +1 -1
- package/dist/effects/message-in.js +1 -1
- package/dist/effects/mosaic-flip.cjs +1 -1
- package/dist/effects/mosaic-flip.js +1 -1
- package/dist/effects/neon-ignite.cjs +1 -1
- package/dist/effects/neon-ignite.js +1 -1
- package/dist/effects/neon-pulse.cjs +1 -1
- package/dist/effects/neon-pulse.js +1 -1
- package/dist/effects/neon-write.cjs +1 -1
- package/dist/effects/neon-write.js +1 -1
- package/dist/effects/neu-press.cjs +1 -1
- package/dist/effects/neu-press.js +1 -1
- package/dist/effects/noise-reveal.cjs +1 -1
- package/dist/effects/noise-reveal.js +1 -1
- package/dist/effects/number-roll.cjs +1 -1
- package/dist/effects/number-roll.js +1 -1
- package/dist/effects/orbit-camera.cjs +1 -1
- package/dist/effects/orbit-camera.js +1 -1
- package/dist/effects/orbit-in.cjs +1 -1
- package/dist/effects/orbit-in.js +1 -1
- package/dist/effects/origami.cjs +1 -1
- package/dist/effects/origami.js +1 -1
- package/dist/effects/page-curl.cjs +1 -1
- package/dist/effects/page-curl.js +1 -1
- package/dist/effects/pan-reveal.cjs +1 -1
- package/dist/effects/pan-reveal.js +1 -1
- package/dist/effects/paper-unfold.cjs +1 -1
- package/dist/effects/paper-unfold.js +1 -1
- package/dist/effects/particle-text.cjs +1 -1
- package/dist/effects/particle-text.js +1 -1
- package/dist/effects/path-morph.cjs +1 -1
- package/dist/effects/path-morph.js +1 -1
- package/dist/effects/pearlescent.cjs +1 -1
- package/dist/effects/pearlescent.js +1 -1
- package/dist/effects/pencil-sketch.cjs +1 -1
- package/dist/effects/pencil-sketch.js +1 -1
- package/dist/effects/pin-drop.cjs +1 -1
- package/dist/effects/pin-drop.js +1 -1
- package/dist/effects/pinball.cjs +1 -1
- package/dist/effects/pinball.js +1 -1
- package/dist/effects/pinch-hint.cjs +1 -1
- package/dist/effects/pinch-hint.js +1 -1
- package/dist/effects/pixelate-in.cjs +1 -1
- package/dist/effects/pixelate-in.js +1 -1
- package/dist/effects/pointer-shadow.cjs +1 -1
- package/dist/effects/pointer-shadow.js +1 -1
- package/dist/effects/portal-open.cjs +1 -1
- package/dist/effects/portal-open.js +1 -1
- package/dist/effects/price-flip.cjs +1 -1
- package/dist/effects/price-flip.js +1 -1
- package/dist/effects/product-spin.cjs +1 -1
- package/dist/effects/product-spin.js +1 -1
- package/dist/effects/rack-focus.cjs +1 -1
- package/dist/effects/rack-focus.js +1 -1
- package/dist/effects/radial-spectrum.cjs +1 -1
- package/dist/effects/radial-spectrum.js +1 -1
- package/dist/effects/rain-glass.cjs +1 -1
- package/dist/effects/rain-glass.js +1 -1
- package/dist/effects/reaction-burst.cjs +1 -1
- package/dist/effects/reaction-burst.js +1 -1
- package/dist/effects/read-receipt.cjs +1 -1
- package/dist/effects/read-receipt.js +1 -1
- package/dist/effects/refraction.cjs +1 -1
- package/dist/effects/refraction.js +1 -1
- package/dist/effects/ring-sweep.cjs +1 -1
- package/dist/effects/ring-sweep.js +1 -1
- package/dist/effects/ripple-dissolve.cjs +1 -1
- package/dist/effects/ripple-dissolve.js +1 -1
- package/dist/effects/rope.cjs +1 -1
- package/dist/effects/rope.js +1 -1
- package/dist/effects/route-draw.cjs +1 -1
- package/dist/effects/route-draw.js +1 -1
- package/dist/effects/safe-fade.cjs +1 -1
- package/dist/effects/safe-fade.js +1 -1
- package/dist/effects/sakura.cjs +1 -1
- package/dist/effects/sakura.js +1 -1
- package/dist/effects/sale-shine.cjs +1 -1
- package/dist/effects/sale-shine.js +1 -1
- package/dist/effects/sankey-flow.cjs +1 -1
- package/dist/effects/sankey-flow.js +1 -1
- package/dist/effects/scanline-sweep.cjs +1 -1
- package/dist/effects/scanline-sweep.js +1 -1
- package/dist/effects/shatter.cjs +1 -1
- package/dist/effects/shatter.js +1 -1
- package/dist/effects/smoke.cjs +1 -1
- package/dist/effects/smoke.js +1 -1
- package/dist/effects/snowfall.cjs +1 -1
- package/dist/effects/snowfall.js +1 -1
- package/dist/effects/soft-body.cjs +1 -1
- package/dist/effects/soft-body.js +1 -1
- package/dist/effects/sound-particles.cjs +1 -1
- package/dist/effects/sound-particles.js +1 -1
- package/dist/effects/spatial-float.cjs +1 -1
- package/dist/effects/spatial-float.js +1 -1
- package/dist/effects/spectrum-mirror.cjs +1 -1
- package/dist/effects/spectrum-mirror.js +1 -1
- package/dist/effects/splash.cjs +1 -1
- package/dist/effects/splash.js +1 -1
- package/dist/effects/spooky-float.cjs +1 -1
- package/dist/effects/spooky-float.js +1 -1
- package/dist/effects/stock-pulse.cjs +1 -1
- package/dist/effects/stock-pulse.js +1 -1
- package/dist/effects/stream-text.cjs +1 -1
- package/dist/effects/stream-text.js +1 -1
- package/dist/effects/stroke-draw.cjs +1 -1
- package/dist/effects/stroke-draw.js +1 -1
- package/dist/effects/success-check.cjs +1 -1
- package/dist/effects/success-check.js +1 -1
- package/dist/effects/swipe-hint.cjs +1 -1
- package/dist/effects/swipe-hint.js +1 -1
- package/dist/effects/text-trail.cjs +1 -1
- package/dist/effects/text-trail.js +1 -1
- package/dist/effects/thinking-glow.cjs +1 -1
- package/dist/effects/thinking-glow.js +1 -1
- package/dist/effects/tilt-wobble.cjs +1 -1
- package/dist/effects/tilt-wobble.js +1 -1
- package/dist/effects/typing-dots.cjs +1 -1
- package/dist/effects/typing-dots.js +1 -1
- package/dist/effects/underline-sweep.cjs +1 -1
- package/dist/effects/underline-sweep.js +1 -1
- package/dist/effects/vhs-glitch.cjs +1 -1
- package/dist/effects/vhs-glitch.js +1 -1
- package/dist/effects/vine-grow.cjs +1 -1
- package/dist/effects/vine-grow.js +1 -1
- package/dist/effects/vinyl-spin.cjs +1 -1
- package/dist/effects/vinyl-spin.js +1 -1
- package/dist/effects/voice-wave.cjs +1 -1
- package/dist/effects/voice-wave.js +1 -1
- package/dist/effects/water-drop.cjs +1 -1
- package/dist/effects/water-drop.js +1 -1
- package/dist/effects/watercolor.cjs +1 -1
- package/dist/effects/watercolor.js +1 -1
- package/dist/effects/waveform-scope.cjs +1 -1
- package/dist/effects/waveform-scope.js +1 -1
- package/dist/effects/xmas-snow.cjs +1 -1
- package/dist/effects/xmas-snow.js +1 -1
- package/dist/effects/xp-gain.cjs +1 -1
- package/dist/effects/xp-gain.js +1 -1
- package/dist/effects/y2k-shine.cjs +1 -1
- package/dist/effects/y2k-shine.js +1 -1
- package/dist/element.cjs +1 -1
- package/dist/element.js +1 -1
- package/dist/element.umd.js +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.js +1 -1
- package/dist/index.umd.js +1 -1
- package/dist/llms-full.txt +24 -18
- package/dist/llms.txt +1 -1
- package/dist/manifest.json +28 -26
- package/dist/presets/extended.cjs +1 -1
- package/dist/presets/extended.js +1 -1
- package/dist/presets-extended.umd.js +1 -1
- package/dist/react.cjs +1 -1
- package/dist/react.js +1 -1
- package/dist/runtime/drag-snap.cjs +2 -2
- package/dist/runtime/drag-snap.iife.js +1 -1
- package/dist/runtime/drag-snap.js +2 -2
- package/dist/runtime/format-apng.cjs +3 -3
- package/dist/runtime/format-apng.iife.js +1 -1
- package/dist/runtime/format-apng.js +3 -3
- package/dist/runtime/format-css.cjs +3 -3
- package/dist/runtime/format-css.iife.js +1 -1
- package/dist/runtime/format-css.js +3 -3
- package/dist/runtime/format-gif.cjs +3 -3
- package/dist/runtime/format-gif.iife.js +1 -1
- package/dist/runtime/format-gif.js +3 -3
- package/dist/runtime/format-gltf.cjs +2 -2
- package/dist/runtime/format-gltf.iife.js +1 -1
- package/dist/runtime/format-gltf.js +2 -2
- package/dist/runtime/format-motion.cjs +4 -4
- package/dist/runtime/format-motion.iife.js +1 -1
- package/dist/runtime/format-motion.js +4 -4
- package/dist/runtime/format-obj.cjs +2 -2
- package/dist/runtime/format-obj.iife.js +1 -1
- package/dist/runtime/format-obj.js +2 -2
- package/dist/runtime/format-scene.cjs +2 -2
- package/dist/runtime/format-scene.iife.js +1 -1
- package/dist/runtime/format-scene.js +2 -2
- package/dist/runtime/format-sprite.cjs +3 -3
- package/dist/runtime/format-sprite.iife.js +1 -1
- package/dist/runtime/format-sprite.js +3 -3
- package/dist/runtime/format-svg.cjs +3 -3
- package/dist/runtime/format-svg.iife.js +1 -1
- package/dist/runtime/format-svg.js +3 -3
- package/dist/runtime/format-webp.cjs +3 -3
- package/dist/runtime/format-webp.iife.js +1 -1
- package/dist/runtime/format-webp.js +3 -3
- package/dist/runtime/gl.cjs +2 -2
- package/dist/runtime/gl.iife.js +1 -1
- package/dist/runtime/gl.js +2 -2
- package/dist/runtime/gltf-anim.cjs +2 -2
- package/dist/runtime/gltf-anim.iife.js +1 -1
- package/dist/runtime/gltf-anim.js +2 -2
- package/dist/runtime/gltf-decoders.cjs +2 -2
- package/dist/runtime/gltf-decoders.iife.js +1 -1
- package/dist/runtime/gltf-decoders.js +2 -2
- package/dist/runtime/lottie-state.cjs +2 -2
- package/dist/runtime/lottie-state.iife.js +1 -1
- package/dist/runtime/lottie-state.js +2 -2
- package/dist/runtime/physics.cjs +2 -2
- package/dist/runtime/physics.iife.js +1 -1
- package/dist/runtime/physics.js +2 -2
- package/dist/runtime/scroll.cjs +3 -3
- package/dist/runtime/scroll.iife.js +1 -1
- package/dist/runtime/scroll.js +3 -3
- package/dist/runtime/smooth.cjs +2 -2
- package/dist/runtime/smooth.iife.js +1 -1
- package/dist/runtime/smooth.js +2 -2
- package/dist/runtime/text.cjs +2 -2
- package/dist/runtime/text.iife.js +1 -1
- package/dist/runtime/text.js +2 -2
- package/dist/runtime/vector.cjs +3 -3
- package/dist/runtime/vector.iife.js +1 -1
- package/dist/runtime/vector.js +3 -3
- package/dist/runtime.cjs +4 -4
- package/dist/runtime.d.cts +1 -1
- package/dist/runtime.d.ts +1 -1
- package/dist/runtime.iife.js +2 -2
- package/dist/runtime.js +6 -6
- package/dist/solid.cjs +1 -1
- package/dist/solid.js +1 -1
- package/dist/svelte.cjs +1 -1
- package/dist/svelte.js +1 -1
- package/dist/vue.cjs +1 -1
- package/dist/vue.js +1 -1
- package/dist/widgets/add-to-cart.cjs +1 -1
- package/dist/widgets/add-to-cart.js +1 -1
- package/dist/widgets/badge-wall.cjs +1 -1
- package/dist/widgets/badge-wall.js +1 -1
- package/dist/widgets/bar-chart.cjs +1 -1
- package/dist/widgets/bar-chart.js +1 -1
- package/dist/widgets/bg-generator.cjs +1 -1
- package/dist/widgets/bg-generator.js +1 -1
- package/dist/widgets/carousel.cjs +1 -1
- package/dist/widgets/carousel.js +1 -1
- package/dist/widgets/cart-drawer.cjs +1 -1
- package/dist/widgets/cart-drawer.js +1 -1
- package/dist/widgets/chapter-nav.cjs +1 -1
- package/dist/widgets/chapter-nav.js +1 -1
- package/dist/widgets/chat-composer.cjs +1 -1
- package/dist/widgets/chat-composer.js +1 -1
- package/dist/widgets/clock-control.cjs +1 -1
- package/dist/widgets/clock-control.js +1 -1
- package/dist/widgets/code-export.cjs +1 -1
- package/dist/widgets/code-export.js +1 -1
- package/dist/widgets/color-picker.cjs +1 -1
- package/dist/widgets/color-picker.js +1 -1
- package/dist/widgets/command-palette.cjs +1 -1
- package/dist/widgets/command-palette.js +1 -1
- package/dist/widgets/compare.cjs +1 -1
- package/dist/widgets/compare.js +1 -1
- package/dist/widgets/countdown.cjs +1 -1
- package/dist/widgets/countdown.js +1 -1
- package/dist/widgets/cube-gallery.cjs +1 -1
- package/dist/widgets/cube-gallery.js +1 -1
- package/dist/widgets/date-picker.cjs +1 -1
- package/dist/widgets/date-picker.js +1 -1
- package/dist/widgets/disclosure.cjs +1 -1
- package/dist/widgets/disclosure.js +1 -1
- package/dist/widgets/dock.cjs +1 -1
- package/dist/widgets/dock.js +1 -1
- package/dist/widgets/dotlottie.cjs +1 -1
- package/dist/widgets/dotlottie.js +1 -1
- package/dist/widgets/equalizer.cjs +1 -1
- package/dist/widgets/equalizer.js +1 -1
- package/dist/widgets/festival-banner.cjs +1 -1
- package/dist/widgets/festival-banner.js +1 -1
- package/dist/widgets/field.cjs +1 -1
- package/dist/widgets/field.js +1 -1
- package/dist/widgets/file-drop.cjs +1 -1
- package/dist/widgets/file-drop.js +1 -1
- package/dist/widgets/gauge.cjs +1 -1
- package/dist/widgets/gauge.js +1 -1
- package/dist/widgets/gen-art.cjs +1 -1
- package/dist/widgets/gen-art.js +1 -1
- package/dist/widgets/gesture-sticker.cjs +1 -1
- package/dist/widgets/gesture-sticker.js +1 -1
- package/dist/widgets/gl-model.cjs +1 -1
- package/dist/widgets/gl-model.js +1 -1
- package/dist/widgets/gl-scene.cjs +2 -2
- package/dist/widgets/gl-scene.js +2 -2
- package/dist/widgets/globe.cjs +1 -1
- package/dist/widgets/globe.js +1 -1
- package/dist/widgets/gpu-particles.cjs +1 -1
- package/dist/widgets/gpu-particles.js +1 -1
- package/dist/widgets/gyro-card.cjs +1 -1
- package/dist/widgets/gyro-card.js +1 -1
- package/dist/widgets/hero-video.cjs +1 -1
- package/dist/widgets/hero-video.js +1 -1
- package/dist/widgets/hud-panel.cjs +1 -1
- package/dist/widgets/hud-panel.js +1 -1
- package/dist/widgets/hydrate.cjs +1 -1
- package/dist/widgets/hydrate.js +1 -1
- package/dist/widgets/install-button.cjs +1 -1
- package/dist/widgets/install-button.js +1 -1
- package/dist/widgets/kanban.cjs +1 -1
- package/dist/widgets/kanban.js +1 -1
- package/dist/widgets/keyframe-editor.cjs +1 -1
- package/dist/widgets/keyframe-editor.js +1 -1
- package/dist/widgets/kpi.cjs +1 -1
- package/dist/widgets/kpi.js +1 -1
- package/dist/widgets/leaderboard.cjs +1 -1
- package/dist/widgets/leaderboard.js +1 -1
- package/dist/widgets/liquid-nav.cjs +1 -1
- package/dist/widgets/liquid-nav.js +1 -1
- package/dist/widgets/location-card.cjs +1 -1
- package/dist/widgets/location-card.js +1 -1
- package/dist/widgets/lottie-icon.cjs +1 -1
- package/dist/widgets/lottie-icon.js +1 -1
- package/dist/widgets/lottie-player.cjs +2 -2
- package/dist/widgets/lottie-player.js +2 -2
- package/dist/widgets/lottie.cjs +1 -1
- package/dist/widgets/lottie.js +1 -1
- package/dist/widgets/lyrics.cjs +1 -1
- package/dist/widgets/lyrics.js +1 -1
- package/dist/widgets/masonry-flow.cjs +1 -1
- package/dist/widgets/masonry-flow.js +1 -1
- package/dist/widgets/menu-toggle.cjs +1 -1
- package/dist/widgets/menu-toggle.js +1 -1
- package/dist/widgets/menu.cjs +1 -1
- package/dist/widgets/menu.js +1 -1
- package/dist/widgets/message-list.cjs +1 -1
- package/dist/widgets/message-list.js +1 -1
- package/dist/widgets/milestones.cjs +1 -1
- package/dist/widgets/milestones.js +1 -1
- package/dist/widgets/modal.cjs +1 -1
- package/dist/widgets/modal.js +1 -1
- package/dist/widgets/motion-inspector.cjs +2 -2
- package/dist/widgets/motion-inspector.js +2 -2
- package/dist/widgets/motion-prefs.cjs +1 -1
- package/dist/widgets/motion-prefs.js +1 -1
- package/dist/widgets/motion-prompt.cjs +1 -1
- package/dist/widgets/motion-prompt.js +1 -1
- package/dist/widgets/motion-spec.cjs +1 -1
- package/dist/widgets/motion-spec.js +1 -1
- package/dist/widgets/motion.cjs +1 -1
- package/dist/widgets/motion.js +1 -1
- package/dist/widgets/music-player.cjs +1 -1
- package/dist/widgets/music-player.js +1 -1
- package/dist/widgets/native-preview.cjs +1 -1
- package/dist/widgets/native-preview.js +1 -1
- package/dist/widgets/nav-morph.cjs +1 -1
- package/dist/widgets/nav-morph.js +1 -1
- package/dist/widgets/notification-bell.cjs +1 -1
- package/dist/widgets/notification-bell.js +1 -1
- package/dist/widgets/odometer.cjs +1 -1
- package/dist/widgets/odometer.js +1 -1
- package/dist/widgets/organic-card.cjs +1 -1
- package/dist/widgets/organic-card.js +1 -1
- package/dist/widgets/otp.cjs +1 -1
- package/dist/widgets/otp.js +1 -1
- package/dist/widgets/pagination.cjs +1 -1
- package/dist/widgets/pagination.js +1 -1
- package/dist/widgets/panorama.cjs +1 -1
- package/dist/widgets/panorama.js +1 -1
- package/dist/widgets/parallax-layers.cjs +1 -1
- package/dist/widgets/parallax-layers.js +1 -1
- package/dist/widgets/pause-all.cjs +1 -1
- package/dist/widgets/pause-all.js +1 -1
- package/dist/widgets/perf-monitor.cjs +1 -1
- package/dist/widgets/perf-monitor.js +1 -1
- package/dist/widgets/physics-playground.cjs +2 -2
- package/dist/widgets/physics-playground.js +2 -2
- package/dist/widgets/plugin-card.cjs +3 -3
- package/dist/widgets/plugin-card.js +3 -3
- package/dist/widgets/plugin-store.cjs +1 -1
- package/dist/widgets/plugin-store.js +1 -1
- package/dist/widgets/presence.cjs +1 -1
- package/dist/widgets/presence.js +1 -1
- package/dist/widgets/prize-wheel.cjs +1 -1
- package/dist/widgets/prize-wheel.js +1 -1
- package/dist/widgets/product-gallery.cjs +1 -1
- package/dist/widgets/product-gallery.js +1 -1
- package/dist/widgets/progress-ring.cjs +1 -1
- package/dist/widgets/progress-ring.js +1 -1
- package/dist/widgets/prop-panel.cjs +1 -1
- package/dist/widgets/prop-panel.js +1 -1
- package/dist/widgets/pull-cord.cjs +1 -1
- package/dist/widgets/pull-cord.js +1 -1
- package/dist/widgets/radar.cjs +1 -1
- package/dist/widgets/radar.js +1 -1
- package/dist/widgets/reactions.cjs +1 -1
- package/dist/widgets/reactions.js +1 -1
- package/dist/widgets/red-envelope.cjs +1 -1
- package/dist/widgets/red-envelope.js +1 -1
- package/dist/widgets/retro-button.cjs +1 -1
- package/dist/widgets/retro-button.js +1 -1
- package/dist/widgets/rive.cjs +1 -1
- package/dist/widgets/rive.js +1 -1
- package/dist/widgets/route-transition.cjs +1 -1
- package/dist/widgets/route-transition.js +1 -1
- package/dist/widgets/scene.cjs +1 -1
- package/dist/widgets/scene.js +1 -1
- package/dist/widgets/scroll-ring.cjs +1 -1
- package/dist/widgets/scroll-ring.js +1 -1
- package/dist/widgets/scroll-scene.cjs +2 -2
- package/dist/widgets/scroll-scene.js +2 -2
- package/dist/widgets/segmented.cjs +1 -1
- package/dist/widgets/segmented.js +1 -1
- package/dist/widgets/shader-backdrop.cjs +1 -1
- package/dist/widgets/shader-backdrop.js +1 -1
- package/dist/widgets/sheet.cjs +1 -1
- package/dist/widgets/sheet.js +1 -1
- package/dist/widgets/shortcut.cjs +1 -1
- package/dist/widgets/shortcut.js +1 -1
- package/dist/widgets/skeleton-reveal.cjs +1 -1
- package/dist/widgets/skeleton-reveal.js +1 -1
- package/dist/widgets/sketch-chart.cjs +1 -1
- package/dist/widgets/sketch-chart.js +1 -1
- package/dist/widgets/smooth-scroll.cjs +2 -2
- package/dist/widgets/smooth-scroll.js +2 -2
- package/dist/widgets/snap-carousel.cjs +1 -1
- package/dist/widgets/snap-carousel.js +1 -1
- package/dist/widgets/sparkline.cjs +1 -1
- package/dist/widgets/sparkline.js +1 -1
- package/dist/widgets/spatial-card.cjs +1 -1
- package/dist/widgets/spatial-card.js +1 -1
- package/dist/widgets/star-rating.cjs +1 -1
- package/dist/widgets/star-rating.js +1 -1
- package/dist/widgets/stepper.cjs +1 -1
- package/dist/widgets/stepper.js +1 -1
- package/dist/widgets/sticky-wall.cjs +1 -1
- package/dist/widgets/sticky-wall.js +1 -1
- package/dist/widgets/stories.cjs +1 -1
- package/dist/widgets/stories.js +1 -1
- package/dist/widgets/suggestion-chips.cjs +1 -1
- package/dist/widgets/suggestion-chips.js +1 -1
- package/dist/widgets/swipe-deck.cjs +1 -1
- package/dist/widgets/swipe-deck.js +1 -1
- package/dist/widgets/switch.cjs +1 -1
- package/dist/widgets/switch.js +1 -1
- package/dist/widgets/tab-bar.cjs +1 -1
- package/dist/widgets/tab-bar.js +1 -1
- package/dist/widgets/terminal.cjs +1 -1
- package/dist/widgets/terminal.js +1 -1
- package/dist/widgets/text-splitter.cjs +3 -3
- package/dist/widgets/text-splitter.js +3 -3
- package/dist/widgets/theme-surface.cjs +1 -1
- package/dist/widgets/theme-surface.js +1 -1
- package/dist/widgets/theme-switcher.cjs +1 -1
- package/dist/widgets/theme-switcher.js +1 -1
- package/dist/widgets/tip.cjs +1 -1
- package/dist/widgets/tip.js +1 -1
- package/dist/widgets/toast-stack.cjs +1 -1
- package/dist/widgets/toast-stack.js +1 -1
- package/dist/widgets/token-editor.cjs +1 -1
- package/dist/widgets/token-editor.js +1 -1
- package/dist/widgets/upload-progress.cjs +1 -1
- package/dist/widgets/upload-progress.js +1 -1
- package/dist/widgets/video-card.cjs +1 -1
- package/dist/widgets/video-card.js +1 -1
- package/dist/widgets/voice-button.cjs +1 -1
- package/dist/widgets/voice-button.js +1 -1
- package/dist/widgets/volume-knob.cjs +1 -1
- package/dist/widgets/volume-knob.js +1 -1
- package/dist/widgets/weather-card.cjs +1 -1
- package/dist/widgets/weather-card.js +1 -1
- package/dist/widgets/worker-canvas.cjs +1 -1
- package/dist/widgets/worker-canvas.js +1 -1
- package/dist/widgets/xp-bar.cjs +1 -1
- package/dist/widgets/xp-bar.js +1 -1
- package/dist/widgets.umd.js +2 -2
- package/docs/components/usa-auto-animate.md +4 -2
- package/docs/components/usa-badge-wall.md +1 -1
- package/docs/components/usa-bar-chart.md +1 -1
- package/docs/components/usa-cart-drawer.md +1 -1
- package/docs/components/usa-chat-composer.md +1 -1
- package/docs/components/usa-clock-control.md +3 -0
- package/docs/components/usa-command-palette.md +1 -1
- package/docs/components/usa-equalizer.md +1 -1
- package/docs/components/usa-file-drop.md +1 -0
- package/docs/components/usa-globe.md +1 -1
- package/docs/components/usa-keyframe-editor.md +1 -0
- package/docs/components/usa-leaderboard.md +1 -1
- package/docs/components/usa-loading-bar.md +1 -1
- package/docs/components/usa-message-list.md +1 -1
- package/docs/components/usa-notification-bell.md +1 -1
- package/docs/components/usa-otp.md +1 -1
- package/docs/components/usa-pull-refresh.md +1 -1
- package/docs/components/usa-upload-progress.md +1 -1
- package/docs/components/usa-voice-button.md +1 -1
- package/docs/components/usa-xp-bar.md +3 -1
- package/docs/mcp-gateway-interop.md +77 -0
- package/docs/public-api.md +1 -1
- package/docs/timeline-doc.schema.json +158 -0
- package/docs/timeline-editor.md +132 -0
- package/package.json +11 -1
package/CHANGELOG.md
CHANGED
|
@@ -7,6 +7,96 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [13.7.0] - 2026-10-11
|
|
11
|
+
|
|
12
|
+
AI tools 2.0 — `motionary-mcp` 2.1 (the MCP server in the package, `npx -p motionary motionary-mcp`). Additive only:
|
|
13
|
+
`list_components`, `search_components` and `get_component` keep their input schema and result fields, no runtime
|
|
14
|
+
code changed, zero runtime dependencies, no size budget raised. [docs/mcp-gateway-interop.md](docs/mcp-gateway-interop.md)
|
|
15
|
+
|
|
16
|
+
### Added
|
|
17
|
+
|
|
18
|
+
- **`check_compatibility`** tool — framework (html / esm / react / vue / svelte / solid / angular, with setup notes),
|
|
19
|
+
version (added in / changed after the installed version) and browser support (engines the browser suite tests,
|
|
20
|
+
minimum versions, web-platform features with their fallback) for components or for the components a snippet uses;
|
|
21
|
+
`compatible: false` when a component is unknown or newer than the installed version.
|
|
22
|
+
- **`suggest_fix`** tool — concrete `{ find, replace }` patches: wrong tag names (closest real tag), mistyped or
|
|
23
|
+
deprecated attributes, components used but never imported / defined, bare `motionary/…` imports in CDN pages (→ the
|
|
24
|
+
CDN module URL of the same major), missing `motionary/runtime` prerequisites, import paths / event names / CDN pins
|
|
25
|
+
removed in 13.0; `fixed` (all patches applied) and what the validator still reports.
|
|
26
|
+
- **`validate_snippet { browser: true | 'auto' }`** — runs the snippet in a real headless browser (Playwright, optional
|
|
27
|
+
peer, never a dependency) against the local build: HTML as a whole page with its own scripts, ESM behind an import
|
|
28
|
+
map; falls back to the static checks when no browser is available (`mode: 'browser' | 'static'`, `mount.skipped`).
|
|
29
|
+
- Versioned tool schemas: `_meta["motionary/schemaVersion"]` on every tool, `outputSchema` + a `schema` id in the
|
|
30
|
+
results of the new tools.
|
|
31
|
+
- Generated-example regression set (`scripts/mcp-examples.mjs`): every component's scaffold in seven frameworks; CI
|
|
32
|
+
runs all HTML + ESM ones (418) in Chromium through `validate_snippet { browser: true }` and fails on any uncaught
|
|
33
|
+
error or Motionary console error (`test/browser/mcp-examples.spec.mjs`); static checks for all of them in
|
|
34
|
+
`test/ai-tools-13-7.test.ts`.
|
|
35
|
+
- MCP Gateway interop: `scripts/gateway-interop.mjs` + workflow **Gateway interop** run `motionary-mcp` behind
|
|
36
|
+
`npx @winstonsayno/mcp-gateway@latest` and call the new tools through it (the gateway is fetched in that job only).
|
|
37
|
+
|
|
38
|
+
### Changed
|
|
39
|
+
|
|
40
|
+
- `search_components` ranking: an exact tag (typed bare, with the `usa-` prefix, in angle brackets or as words such as `pull refresh`) always comes
|
|
41
|
+
first, exact tag segments / keywords outrank substrings, typos still match (`acordion` finds the accordion), ties
|
|
42
|
+
break on the tag so results are stable. Same result fields.
|
|
43
|
+
- `scaffold_snippet`: elements an example uses besides its own are registered too (an add-to-cart
|
|
44
|
+
example that flies into a cart drawer), imports are merged per module (one name imported once), CDN pages import modules from the CDN
|
|
45
|
+
instead of bare `motionary/…` specifiers; React output renames DOM attributes and styles properly; solid and angular
|
|
46
|
+
scaffolds.
|
|
47
|
+
|
|
48
|
+
### Fixed
|
|
49
|
+
|
|
50
|
+
- 50 of 418 generated HTML / ESM examples failed in a real browser (measured on 13.1 / 13.2): example scripts used
|
|
51
|
+
undeclared element variables (`wall`, `cart`, `bar` …), a placeholder `…` inside a script, `fetch('/api')`, undefined
|
|
52
|
+
`a` / `b`, a missing `.grid`, bare `motionary/…` imports in CDN pages, a second element the example needs was never
|
|
53
|
+
registered, a duplicated import, method calls before the element mounted. All examples now run clean in Chromium
|
|
54
|
+
(the official Rive runtime example still needs `@rive-app/canvas`, which the offline test cannot fetch — it is
|
|
55
|
+
expected to report that peer).
|
|
56
|
+
- `validate_snippet`: words inside quoted attribute values were reported as unknown attributes; a runtime module loaded
|
|
57
|
+
as `runtime/*.iife.js` (or named in an HTML comment) was reported as "imported but never registered".
|
|
58
|
+
|
|
59
|
+
## [13.6.0] - 2026-10-11
|
|
60
|
+
|
|
61
|
+
Timeline editing model. A new editor-only entry, `motionary/components/timeline-editor`, gives timeline UIs (the
|
|
62
|
+
Timeline Playground, your own tools) a versioned document format, layer and keyframe batch operations, undo / redo
|
|
63
|
+
and a reproducible preview. Additive only: no existing API changed, nothing in `motionary`, `motionary/core`,
|
|
64
|
+
`motionary/components/lite` or `motionary/components/timeline` imports it. Zero runtime dependencies; existing size
|
|
65
|
+
budgets unchanged (`motionary/components/lite` 69.99 / 70.00 KB); the new entry has its own budget (10 KB gzip). [docs/timeline-editor.md](docs/timeline-editor.md)
|
|
66
|
+
|
|
67
|
+
### Added
|
|
68
|
+
|
|
69
|
+
- **Format `motionary-timeline` v1** — layers (tracks and groups; `locked`, `muted`, `solo`), keyframes with
|
|
70
|
+
per-segment easing, `seed`, free-form `meta`. `validateTimelineDoc` (every problem with its path, never throws),
|
|
71
|
+
`parseTimelineDoc` (throws `TimelineDocError`; rejects malformed, oversized, unknown-key, newer-version,
|
|
72
|
+
prototype-polluting and cyclic input), `serializeTimelineDoc` (canonical and lossless: parse → serialize →
|
|
73
|
+
parse is deep-equal and serializing again is byte-identical), `TIMELINE_DOC_SCHEMA` +
|
|
74
|
+
[docs/timeline-doc.schema.json](docs/timeline-doc.schema.json) (JSON Schema 2020-12), golden fixtures
|
|
75
|
+
(`test/fixtures/timeline/`).
|
|
76
|
+
- Player JSON interop (`use-scroll-animate/animation` v1): `timelineDocToAnimation` (mute / solo applied, seeded `random()` resolved) and
|
|
77
|
+
`timelineDocFromAnimation` (keyframe and preset tracks).
|
|
78
|
+
- **Layers**: `addLayer`, `removeLayers`, `updateLayers`, `groupLayers`, `ungroupLayer`, `moveLayer` (reorder, into /
|
|
79
|
+
out of groups), `isLayerActive`, `isLayerLocked`.
|
|
80
|
+
- **Keyframe batch editing**: `shiftKeyframes`, `scaleKeyframes`, `setKeyframeEasing`, `copyKeyframes` /
|
|
81
|
+
`pasteKeyframes`, `removeKeyframes`, `setKeyframeProps`, `addKeyframe`, `editableKeyframes`; locked layers are
|
|
82
|
+
never edited; operations are pure and share unchanged layers.
|
|
83
|
+
- **Undo / redo**: `createTimelineHistory` (bounded stack, coalescing by key and time window, `begin` / `commit` /
|
|
84
|
+
`cancel` gestures, labels, `subscribe`), `bindHistoryKeys` (⌘/Ctrl+Z, ⇧⌘/Ctrl+Shift+Z, Ctrl+Y; ignored in text
|
|
85
|
+
fields), `historyKeyAction`.
|
|
86
|
+
- **Reproducible preview**: `sampleTimelineDoc(doc, t)` (pure: same time → same frame state), `interpolateValue`,
|
|
87
|
+
seeded `random(a, b)` values (`createSeededRandom`, `resolveRandom`), `createFixedClock`, `createTimelinePreview`
|
|
88
|
+
(writes the full state on every seek, clears what stopped animating).
|
|
89
|
+
- Tests: `test/timeline-editor-13-6.test.ts` (54) and `test/browser/timeline-editor.spec.mjs` (DOM-state determinism
|
|
90
|
+
in Chromium, Firefox and WebKit; pixel-identical snapshots in Chromium after stepping, jumping, scrubbing backwards
|
|
91
|
+
and reloading).
|
|
92
|
+
|
|
93
|
+
### Deferred
|
|
94
|
+
|
|
95
|
+
- The Timeline Playground UI on top of this model (layer panel, marquee multi-select, curve editor, undo buttons) —
|
|
96
|
+
moves to the Motion Studio work (14.4). The keyframe-editor widget and the showcase playground are unchanged.
|
|
97
|
+
- Visual snapshot baselines committed to the repository: 13.6 compares pixels within a run (stepped vs jumped vs
|
|
98
|
+
reloaded), which is font- and GPU-independent.
|
|
99
|
+
|
|
10
100
|
## [13.5.0] - 2026-10-11
|
|
11
101
|
|
|
12
102
|
Framework integration hardening. A new regression matrix server-renders and hydrates a small app per framework
|
package/README.md
CHANGED
|
@@ -389,7 +389,7 @@ Coming from another library: [AOS](./docs/migration-from-aos.md) · [GSAP Scroll
|
|
|
389
389
|
|
|
390
390
|
| Topic | Docs |
|
|
391
391
|
|---|---|
|
|
392
|
-
| Reference | [API](./docs/API.md) · [Presets](./docs/presets.md) (all 214) · [Components](./docs/components.md) · [Entry points](./docs/entry-points.md) · [Public API by layer](./docs/public-api.md) · [Motion Core](./docs/core.md) |
|
|
392
|
+
| Reference | [API](./docs/API.md) · [Presets](./docs/presets.md) (all 214) · [Components](./docs/components.md) · [Entry points](./docs/entry-points.md) · [Public API by layer](./docs/public-api.md) · [Motion Core](./docs/core.md) · [Timeline editor model](./docs/timeline-editor.md) |
|
|
393
393
|
| Runtime | [Runtime tiers](./docs/runtime-tiers.md) · [Modules](./docs/runtime/) · [Compatibility matrix](./docs/compat-matrix.md) |
|
|
394
394
|
| Platforms | [Frameworks & SSR](./docs/frameworks-ssr.md) · [Framework matrix](./docs/frameworks-matrix.md) · [Windows apps](./docs/windows-apps.md) · [Hybrid apps (MAUI, Flutter, Electron, Tauri)](./docs/hybrid-apps.md) · [Cross-platform export](./docs/cross-platform.md) · [Examples](./examples/) |
|
|
395
395
|
| Design & AI | [Motion tokens](./docs/motion-tokens.md) · [Figma plugin](./figma-plugin/README.md) · [MCP server](./docs/mcp.md) · [AI provider](./docs/ai-provider.md) · [Prompt guide](./docs/ai-prompt-guide.md) |
|
|
@@ -0,0 +1,167 @@
|
|
|
1
|
+
// motionary-mcp 13.2 — validate_snippet { browser: true }: run the snippet in a real headless browser (Playwright, optional peer)
|
|
2
|
+
// instead of jsdom. jsdom stays the default for { mount: true }; this is the opt-in, slower and more faithful check.
|
|
3
|
+
// • HTML snippets run as a whole document, their own scripts included. CDN URLs for motionary / use-scroll-animate
|
|
4
|
+
// (unpkg, jsDelivr, any version) are served from the local build, so the snippet runs against the package under test.
|
|
5
|
+
// • ESM snippets (npm + bundler style) run as a module behind an import map that resolves every `motionary/*` subpath the
|
|
6
|
+
// way package.json `exports` names it; the markup comes from the snippet's `/* HTML: … */` block.
|
|
7
|
+
// • JSX / Vue / Svelte / Solid / Angular need their compiler, so only their markup is mounted (with the prerequisites the
|
|
8
|
+
// snippet registers, loaded in the right order) — `run: 'markup'` says so. Real framework builds: scripts/build-examples.mjs.
|
|
9
|
+
// Every other network request is blocked (an official runtime the snippet loads from a CDN is reported, not fetched).
|
|
10
|
+
// Then the same contract checks as the jsdom mount run in the page: defined + upgraded, observed attributes, event names,
|
|
11
|
+
// plus uncaught errors / rejections and motionary console errors from the real run.
|
|
12
|
+
import { readFileSync, existsSync } from 'node:fs';
|
|
13
|
+
import { join, extname } from 'node:path';
|
|
14
|
+
import { markupOf, listenedEvents, LEGACY_EVENTS_12 } from './mcp-mount.mjs';
|
|
15
|
+
|
|
16
|
+
const ORIGIN = 'http://motionary.test';
|
|
17
|
+
const TYPES = { '.js': 'text/javascript', '.mjs': 'text/javascript', '.cjs': 'text/javascript', '.css': 'text/css', '.json': 'application/json', '.wasm': 'application/wasm', '.svg': 'image/svg+xml', '.png': 'image/png' };
|
|
18
|
+
const CDN = /^https?:\/\/(?:unpkg\.com|cdn\.jsdelivr\.net\/npm)\/(?:motionary|use-scroll-animate)(?:@[^/]+)?\/dist\/([^?#]+)/;
|
|
19
|
+
const GLOBAL = new Set(['class', 'id', 'style', 'role', 'slot', 'hidden', 'tabindex', 'title', 'lang', 'dir', 'part', 'is', 'inert', 'nonce', 'popover', 'translate', 'draggable', 'contenteditable', 'autofocus', 'key', 'ref', 'classname']);
|
|
20
|
+
|
|
21
|
+
/** How a snippet can run in a browser: 'document' (HTML), 'module' (ESM + bundler) or 'markup' (needs a framework compiler). */
|
|
22
|
+
export function snippetKind(code) {
|
|
23
|
+
const s = String(code || '');
|
|
24
|
+
const noBlock = s.replace(/\/\*[\s\S]*?\*\//g, '');
|
|
25
|
+
const startsWithImport = /^\s*(?:\/\/[^\n]*\n\s*)*import[\s{*'"]/.test(noBlock);
|
|
26
|
+
const framework = /<script\s+setup|<template[\s>]|\bexport\s+(?:default\s+)?(?:function|class)\b|@Component\(|className=|\sattr:[\w-]+=|=\{|<script(?![^>]*\b(?:src|type)=)[^>]*>[\s\S]*?\bimport\s/.test(s);
|
|
27
|
+
if (framework) return 'markup';
|
|
28
|
+
if (startsWithImport) return /<[a-z][\w-]*[\s>/]/i.test(noBlock) ? 'markup' : 'module';
|
|
29
|
+
return /<[a-z!]/i.test(s) ? 'document' : 'markup';
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
/** package.json `exports` → import map entries ('motionary/runtime' → '/dist/runtime.js'). */
|
|
33
|
+
export function exportsToImports(exports, base = '/dist/') {
|
|
34
|
+
const map = {};
|
|
35
|
+
for (const [k, v] of Object.entries(exports || {})) {
|
|
36
|
+
const t = typeof v === 'string' ? v : v && (v.import ? (typeof v.import === 'string' ? v.import : v.import.default) : v.default);
|
|
37
|
+
if (typeof t === 'string' && t.startsWith('./dist/') && /\.m?js$/.test(t)) map[k === '.' ? 'motionary' : 'motionary/' + k.slice(2)] = base + t.slice(7);
|
|
38
|
+
}
|
|
39
|
+
return map;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
/** Playwright from the user's project: playwright, playwright-core or @playwright/test (all optional). */
|
|
43
|
+
export async function loadPlaywright() {
|
|
44
|
+
for (const id of ['playwright', 'playwright-core', '@playwright/test']) {
|
|
45
|
+
try {
|
|
46
|
+
const mod = await import(id);
|
|
47
|
+
const pw = mod.chromium ? mod : mod.default;
|
|
48
|
+
if (pw && pw.chromium) return pw;
|
|
49
|
+
} catch { /* next */ }
|
|
50
|
+
}
|
|
51
|
+
throw new Error('playwright is not installed');
|
|
52
|
+
}
|
|
53
|
+
|
|
54
|
+
const esc = (s) => String(s).replace(/</g, '\\u003c');
|
|
55
|
+
|
|
56
|
+
function pageFor(kind, code, { imports, runtimeIds, bundles }) {
|
|
57
|
+
if (kind === 'document') {
|
|
58
|
+
const s = String(code);
|
|
59
|
+
return /<html|<!doctype/i.test(s) ? s : `<!doctype html><html lang="en"><head><meta charset="utf-8"></head><body>\n${s}\n</body></html>`;
|
|
60
|
+
}
|
|
61
|
+
const head = ['<!doctype html><html lang="en"><head><meta charset="utf-8">'];
|
|
62
|
+
let body = '';
|
|
63
|
+
if (kind === 'module') {
|
|
64
|
+
const html = (String(code).match(/\/\*\s*(?:then use it in your )?HTML:?\s*\n?([\s\S]*?)\*\//i) || [])[1] || markupOf(code);
|
|
65
|
+
head.push(`<script type="importmap">${esc(JSON.stringify({ imports }))}</script>`);
|
|
66
|
+
body = `${html}\n<script type="module">\n${String(code).replace(/\/\*[\s\S]*?\*\//g, '')}\n</script>`;
|
|
67
|
+
} else {
|
|
68
|
+
if (runtimeIds.length) { head.push(`<script src="/dist/runtime.iife.js"></script>`); for (const r of runtimeIds) if (r !== 'core') head.push(`<script src="/dist/runtime/${r}.iife.js"></script>`); }
|
|
69
|
+
for (const b of bundles) head.push(`<script src="/dist/${b}"></script>`);
|
|
70
|
+
body = markupOf(code);
|
|
71
|
+
}
|
|
72
|
+
return `${head.join('\n')}</head><body>\n${body}\n</body></html>`;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
/**
|
|
76
|
+
* Run and check. Returns { mounted, environment, run, components:[{tag, defined, upgraded}], errors, warnings, blocked }
|
|
77
|
+
* or { mounted:false, skipped }. opts: distDir, findComponent, runtimeIds, browser (a launched Playwright browser to reuse),
|
|
78
|
+
* browserName ('chromium' | 'firefox' | 'webkit'), executablePath, loadPlaywright, settle (ms after load, default 400).
|
|
79
|
+
*/
|
|
80
|
+
export async function runSnippet(m, code, opts = {}) {
|
|
81
|
+
const { distDir, findComponent, runtimeIds = [], settle = 400 } = opts;
|
|
82
|
+
if (!distDir || !existsSync(join(distDir, 'components.umd.js'))) return { mounted: false, skipped: `no built bundles in ${distDir} — run npm run build` };
|
|
83
|
+
let browser = opts.browser, own = false;
|
|
84
|
+
if (!browser) {
|
|
85
|
+
let pw;
|
|
86
|
+
try { pw = await (opts.loadPlaywright || loadPlaywright)(); } catch {
|
|
87
|
+
return { mounted: false, skipped: 'playwright is not installed — `npm i -D playwright && npx playwright install chromium` (optional peer) to run snippets in a real browser; the static checks still ran' };
|
|
88
|
+
}
|
|
89
|
+
const name = opts.browserName || process.env.MOTIONARY_BROWSER || 'chromium';
|
|
90
|
+
const executablePath = opts.executablePath || process.env.MOTIONARY_BROWSER_PATH || (name === 'chromium' ? process.env.CHROME_PATH : undefined) || undefined;
|
|
91
|
+
try { browser = await pw[name].launch({ headless: true, ...(executablePath ? { executablePath } : {}) }); own = true; } catch (e) {
|
|
92
|
+
return { mounted: false, skipped: `playwright could not start ${name}: ${String(e.message || e).split('\n')[0]} — \`npx playwright install ${name}\`; the static checks still ran` };
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
const pkgFile = join(distDir, '..', 'package.json');
|
|
96
|
+
const pkg = existsSync(pkgFile) ? JSON.parse(readFileSync(pkgFile, 'utf8')) : { exports: {} };
|
|
97
|
+
const kind = snippetKind(code);
|
|
98
|
+
const markup = markupOf(code);
|
|
99
|
+
const tags = [...new Set([...(kind === 'document' ? String(code) : markup).matchAll(/<(usa-[a-z0-9-]+)/gi)].map((x) => x[1].toLowerCase()))];
|
|
100
|
+
const widgets = tags.some((t) => /widgets\.umd/.test((findComponent && findComponent(m, t) || {}).cdn || ''));
|
|
101
|
+
const html = pageFor(kind, code, { imports: exportsToImports(pkg.exports), runtimeIds, bundles: ['components.umd.js', ...(widgets ? ['widgets.umd.js'] : [])] });
|
|
102
|
+
const errors = [], warnings = [], blocked = [], seen = new Set();
|
|
103
|
+
const note = (list, msg) => { if (!seen.has(msg)) { seen.add(msg); list.push(msg); } };
|
|
104
|
+
const context = await browser.newContext({ reducedMotion: 'no-preference', viewport: { width: 1024, height: 768 } });
|
|
105
|
+
try {
|
|
106
|
+
await context.route('**/*', async (route) => {
|
|
107
|
+
const url = route.request().url();
|
|
108
|
+
if (url === `${ORIGIN}/`) return route.fulfill({ status: 200, contentType: 'text/html; charset=utf-8', body: html });
|
|
109
|
+
let file = null;
|
|
110
|
+
if (url.startsWith(`${ORIGIN}/dist/`)) file = url.slice(ORIGIN.length + 6).split(/[?#]/)[0];
|
|
111
|
+
else { const c = url.match(CDN); if (c) file = c[1]; }
|
|
112
|
+
if (file != null) {
|
|
113
|
+
const p = join(distDir, file);
|
|
114
|
+
if (existsSync(p)) return route.fulfill({ status: 200, contentType: TYPES[extname(p)] || 'application/octet-stream', body: readFileSync(p), headers: { 'access-control-allow-origin': '*' } });
|
|
115
|
+
return route.fulfill({ status: 404, body: '' });
|
|
116
|
+
}
|
|
117
|
+
if (/^(data|blob):/.test(url)) return route.continue();
|
|
118
|
+
const type = route.request().resourceType();
|
|
119
|
+
if (type === 'script' || type === 'fetch' || type === 'xhr') blocked.push(url);
|
|
120
|
+
return route.abort('blockedbyclient');
|
|
121
|
+
});
|
|
122
|
+
const page = await context.newPage();
|
|
123
|
+
page.on('pageerror', (e) => note(errors, `run: ${String(e.message || e).split('\n')[0]}`));
|
|
124
|
+
page.on('console', (msg) => {
|
|
125
|
+
const t = msg.text();
|
|
126
|
+
if (msg.type() === 'error') {
|
|
127
|
+
if (/Failed to load resource|net::ERR_BLOCKED|blockedbyclient/i.test(t)) return;
|
|
128
|
+
if (/\[motionary\]|requires motionary|Error|error/.test(t)) note(errors, `run: ${t.split('\n')[0]}`);
|
|
129
|
+
} else if (msg.type() === 'warning' && /\[motionary\]/.test(t) && !/lacks .* motionary 5\.0 requires/.test(t)) note(warnings, `run: ${t.split('\n')[0]}`);
|
|
130
|
+
});
|
|
131
|
+
await page.addInitScript(() => { addEventListener('unhandledrejection', (e) => console.error('Unhandled rejection: ' + ((e.reason && e.reason.message) || e.reason))); });
|
|
132
|
+
await page.goto(`${ORIGIN}/`, { waitUntil: 'load', timeout: 20000 });
|
|
133
|
+
await page.waitForTimeout(settle);
|
|
134
|
+
await page.evaluate(() => new Promise((r) => requestAnimationFrame(() => requestAnimationFrame(r))));
|
|
135
|
+
const rows = await page.evaluate((list) => list.map((tag) => {
|
|
136
|
+
const ctor = customElements.get(tag), el = document.querySelector(tag);
|
|
137
|
+
return { tag, defined: !!ctor, upgraded: !!(ctor && el instanceof ctor), observed: ctor ? (ctor.observedAttributes || []).map(String) : [], attrs: el ? el.getAttributeNames() : [] };
|
|
138
|
+
}), tags);
|
|
139
|
+
const components = [];
|
|
140
|
+
for (const row of rows) {
|
|
141
|
+
components.push({ tag: row.tag, defined: row.defined, upgraded: row.upgraded });
|
|
142
|
+
const c = findComponent ? findComponent(m, row.tag) : null;
|
|
143
|
+
if (!c) continue;
|
|
144
|
+
if (!row.defined) { note(errors, `<${row.tag}> was never defined in the page — ${kind === 'markup' ? `import it from '${c.import.path}' and call ${c.import.define}()` : `load ${/widgets\.umd/.test(c.cdn) ? 'widgets.umd.js' : 'components.umd.js'} or call ${c.import.define}()`}`); continue; }
|
|
145
|
+
if (!row.upgraded) note(errors, `<${row.tag}> is defined but the element in the page did not upgrade`);
|
|
146
|
+
const observed = new Set(row.observed.map((a) => a.toLowerCase()));
|
|
147
|
+
for (const a of row.attrs) {
|
|
148
|
+
const k = a.toLowerCase();
|
|
149
|
+
if (GLOBAL.has(k) || k.startsWith('data-') || k.startsWith('aria-') || k.startsWith('on') || /[:@()]/.test(k)) continue;
|
|
150
|
+
if ((c.attributes || []).includes(k) && !observed.has(k)) note(warnings, `<${row.tag} ${k}>: the element reads "${k}" but does not observe it — set it before mount; changing it later has no effect (contract exemption)`);
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
const used = components.map((x) => findComponent && findComponent(m, x.tag)).filter(Boolean);
|
|
154
|
+
const emitted = new Set(used.flatMap((c) => c.events || []));
|
|
155
|
+
for (const ev of listenedEvents(code)) {
|
|
156
|
+
if (LEGACY_EVENTS_12[ev]) note(errors, `event "${ev}" was removed in 12.0 — listen to "${LEGACY_EVENTS_12[ev]}" (npx usa-codemod-12 --write)`);
|
|
157
|
+
else if (ev.startsWith('usa:') && used.length && !emitted.has(ev)) note(warnings, `no component in this snippet emits "${ev}" (they emit: ${[...emitted].join(', ') || 'no usa:* events'})`);
|
|
158
|
+
}
|
|
159
|
+
for (const u of [...new Set(blocked)]) note(warnings, `network request blocked: ${u} (the validation browser is offline; an official runtime from a CDN is not fetched)`);
|
|
160
|
+
return { mounted: true, environment: `${browser.browserType().name()} ${browser.version()}`, run: kind, components, errors, warnings, blocked: [...new Set(blocked)] };
|
|
161
|
+
} finally {
|
|
162
|
+
await context.close().catch(() => {});
|
|
163
|
+
if (own) await browser.close().catch(() => {});
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
|
|
167
|
+
export const PAGE_ORIGIN = ORIGIN;
|
|
@@ -0,0 +1,187 @@
|
|
|
1
|
+
// motionary-mcp 2.1 (13.7) — "AI tools 2.0": versioned result schemas, compatibility checks and auto-fix suggestions.
|
|
2
|
+
// Pure functions over the AI manifest; no dependencies, no network, never writes files. The catalog helpers
|
|
3
|
+
// (findComponent, searchComponents, validateSnippet, cdnImports …) are passed in by bin/motionary-mcp.mjs.
|
|
4
|
+
import { transform as codemod13 } from './usa-codemod-13.mjs';
|
|
5
|
+
import { compatAt, cmpVer } from './compat-history.mjs';
|
|
6
|
+
|
|
7
|
+
/** Result schema versions of the 13.7 tools (bumped on any incompatible change; fields are only ever added within a major). */
|
|
8
|
+
export const SCHEMAS = { search: 'motionary-mcp/search@1', compatibility: 'motionary-mcp/check_compatibility@1', validation: 'motionary-mcp/validate_snippet@1', fix: 'motionary-mcp/suggest_fix@1' };
|
|
9
|
+
|
|
10
|
+
export function levenshtein(a, b) {
|
|
11
|
+
a = String(a); b = String(b);
|
|
12
|
+
if (a === b) return 0;
|
|
13
|
+
const p = Array.from({ length: b.length + 1 }, (_, i) => i);
|
|
14
|
+
for (let i = 1; i <= a.length; i++) {
|
|
15
|
+
let prev = p[0]; p[0] = i;
|
|
16
|
+
for (let j = 1; j <= b.length; j++) { const t = p[j]; p[j] = Math.min(p[j] + 1, p[j - 1] + 1, prev + (a[i - 1] === b[j - 1] ? 0 : 1)); prev = t; }
|
|
17
|
+
}
|
|
18
|
+
return p[b.length];
|
|
19
|
+
}
|
|
20
|
+
const near = (w, x) => { if (w.length < 4 || x.length < 3) return false; const d = levenshtein(w, x); return d <= (w.length >= 7 ? 2 : 1); };
|
|
21
|
+
|
|
22
|
+
/** 13.7 ranking: exact tag (as typed, with or without usa-, spaces or hyphens) first, then exact tag segment / keyword /
|
|
23
|
+
* category, then substring matches, then typo-tolerant (fuzzy) matches; ties break on the tag name, so results are stable. */
|
|
24
|
+
export function rankComponents(m, query) {
|
|
25
|
+
const q = String(query || '').toLowerCase().trim().replace(/^<|\/?>$/g, '');
|
|
26
|
+
const words = q.split(/[^a-z0-9\u00c0-\uffff-]+/).filter(Boolean);
|
|
27
|
+
if (!words.length) return [];
|
|
28
|
+
const joined = 'usa-' + q.replace(/^usa-/, '').split(/[\s_]+/).filter(Boolean).join('-');
|
|
29
|
+
return m.components.map((c) => {
|
|
30
|
+
const tag = c.tag, segs = tag.slice(4).split('-'), title = String(c.title || '').toLowerCase(), kws = (c.keywords || []).map((k) => String(k).toLowerCase()), kw = kws.join(' '), desc = String(c.description || '').toLowerCase(), cat = String(c.category || '').toLowerCase();
|
|
31
|
+
let s = tag === joined ? 100 : 0;
|
|
32
|
+
for (const w0 of words) {
|
|
33
|
+
const w = w0.replace(/^usa-/, '');
|
|
34
|
+
let hit = false;
|
|
35
|
+
if (tag === `usa-${w}`) { s += 20; hit = true; } else if (segs.includes(w)) { s += 10; hit = true; } else if (tag.includes(w)) { s += 8; hit = true; }
|
|
36
|
+
if (title.includes(w)) { s += 6; hit = true; }
|
|
37
|
+
if (kws.includes(w)) { s += 7; hit = true; } else if (kw.includes(w)) { s += 5; hit = true; }
|
|
38
|
+
if (cat === w) { s += 4; hit = true; }
|
|
39
|
+
if (desc.includes(w)) { s += 2; hit = true; }
|
|
40
|
+
if ((c.attributes || []).includes(w)) { s += 1; hit = true; }
|
|
41
|
+
if (!hit) s += segs.some((x) => near(w, x) || (w.length >= 4 && x.startsWith(w))) ? 6 : kws.some((x) => near(w, x)) || title.split(/\W+/).some((x) => near(w, x)) ? 3 : 0;
|
|
42
|
+
}
|
|
43
|
+
return { c, s };
|
|
44
|
+
}).filter((x) => x.s > 0).sort((a, b) => b.s - a.s || a.c.tag.localeCompare(b.c.tag));
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
// ---------------------------------------------------------------- check_compatibility
|
|
48
|
+
export const FRAMEWORK_NOTES = {
|
|
49
|
+
html: 'CDN <script> tags or a <script type="module"> — no build step',
|
|
50
|
+
esm: 'npm + any bundler (Vite, webpack, Rollup, esbuild)',
|
|
51
|
+
react: 'React 19 passes attributes and properties to custom elements natively; React 18 sets attributes only (set object properties / listen to usa:* events through a ref)',
|
|
52
|
+
vue: 'Vue 3: compilerOptions.isCustomElement = (t) => t.startsWith("usa-")',
|
|
53
|
+
svelte: 'Svelte 4 / 5: custom elements work as-is',
|
|
54
|
+
solid: 'Solid: use attr:name for attributes (Solid sets properties otherwise)',
|
|
55
|
+
angular: 'Angular 15+: schemas: [CUSTOM_ELEMENTS_SCHEMA] on the standalone component',
|
|
56
|
+
};
|
|
57
|
+
// Engines the browser suite runs every component in on each PR (docs/browser-matrix.md, 13.1) and the web-platform
|
|
58
|
+
// features some components need beyond the Custom Elements + Shadow DOM baseline (with the fallback they use without them).
|
|
59
|
+
export const ENGINES = ['chromium', 'firefox', 'webkit'];
|
|
60
|
+
const BASELINE = { chrome: '90', edge: '90', firefox: '90', safari: '15' };
|
|
61
|
+
const FEATURES = [
|
|
62
|
+
{ id: 'webgl2', test: (c) => c.requires.some((r) => /^(gl|format-gltf|gltf-anim|gltf-decoders|format-obj)$/.test(r)) || /^usa-gl-/.test(c.tag), note: 'WebGL2 — without it the element renders nothing and reports data-backend="none"', fallback: 'none' },
|
|
63
|
+
{ id: 'webgl', test: (c) => /^usa-(shader|distort|liquid|post-fx)$/.test(c.tag), note: 'WebGL — falls back to a CSS / canvas2d rendering', fallback: 'css' },
|
|
64
|
+
{ id: 'web-audio', test: (c) => /^usa-(equalizer|audio|waveform|voice-button)/.test(c.tag) || c.requires.includes('audio'), note: 'Web Audio — silent / static bars without it', fallback: 'static' },
|
|
65
|
+
{ id: 'scroll-timeline', test: (c) => c.requires.includes('scroll'), note: 'scroll-driven animations — uses its own scroll scenes where animation-timeline is missing', fallback: 'js' },
|
|
66
|
+
];
|
|
67
|
+
|
|
68
|
+
/** Framework, version and browser support for components (or a whole snippet), from the manifest. */
|
|
69
|
+
export function checkCompatibility(m, a, { findComponent, installedVersion, validateSnippet }) {
|
|
70
|
+
const version = a.version || installedVersion() || m.version;
|
|
71
|
+
let tags = (a.tags || []).slice();
|
|
72
|
+
if (a.code) tags.push(...validateSnippet(m, a.code).components);
|
|
73
|
+
tags = [...new Set(tags)];
|
|
74
|
+
if (!tags.length) throw new Error('give tags or code');
|
|
75
|
+
const framework = a.framework ? String(a.framework).toLowerCase() : null;
|
|
76
|
+
if (framework && !FRAMEWORK_NOTES[framework]) throw new Error(`framework must be one of ${Object.keys(FRAMEWORK_NOTES).join(', ')}`);
|
|
77
|
+
const browsers = (a.browsers || []).map((b) => String(b).toLowerCase());
|
|
78
|
+
const issues = [];
|
|
79
|
+
const components = tags.map((t) => {
|
|
80
|
+
const c = findComponent(m, t);
|
|
81
|
+
if (!c) { issues.push({ tag: t, level: 'error', message: `unknown component ${t} — use search_components` }); return { tag: t, known: false }; }
|
|
82
|
+
const at = compatAt(c, version);
|
|
83
|
+
const features = FEATURES.filter((f) => f.test(c)).map(({ id, note, fallback }) => ({ id, note, fallback }));
|
|
84
|
+
if (!at.available) issues.push({ tag: c.tag, level: 'error', message: `<${c.tag}> needs motionary ${c.since} (you have ${version}) — npm i motionary@${m.version}` });
|
|
85
|
+
for (const ch of at.changedAfter || []) issues.push({ tag: c.tag, level: 'warning', message: `<${c.tag}> changed in ${ch} (after ${version}) — see the CHANGELOG` });
|
|
86
|
+
if (c.stability === 'deprecated') issues.push({ tag: c.tag, level: 'warning', message: `<${c.tag}> is deprecated${c.deprecated?.use ? ` — use ${c.deprecated.use}` : ''}` });
|
|
87
|
+
const peer = (c.prerequisites && c.prerequisites.install) || null;
|
|
88
|
+
for (const b of browsers) {
|
|
89
|
+
const eng = /chrom|edge|chrome/.test(b) ? 'chromium' : /firefox|gecko/.test(b) ? 'firefox' : /safari|webkit|ios/.test(b) ? 'webkit' : null;
|
|
90
|
+
if (!eng) issues.push({ tag: c.tag, level: 'warning', message: `${b}: not covered by the browser suite (Chromium, Firefox, WebKit)` });
|
|
91
|
+
for (const f of features) if (f.fallback === 'none') issues.push({ tag: c.tag, level: 'warning', message: `${b}: <${c.tag}> needs ${f.id}; where the GPU / driver lacks it nothing is drawn` });
|
|
92
|
+
}
|
|
93
|
+
return {
|
|
94
|
+
tag: c.tag, known: true, since: c.since || null, available: at.available, changedAfter: at.changedAfter || [], stability: c.stability || 'stable',
|
|
95
|
+
frameworks: Object.fromEntries(Object.entries(FRAMEWORK_NOTES).filter(([k]) => !framework || k === framework).map(([k, note]) => [k, { supported: true, note }])),
|
|
96
|
+
browsers: { tested: ENGINES, minimum: BASELINE, features },
|
|
97
|
+
prerequisites: (c.requires || []).slice(), ...(peer ? { install: peer } : {}),
|
|
98
|
+
};
|
|
99
|
+
});
|
|
100
|
+
return { schema: SCHEMAS.compatibility, version, catalog: m.version, behind: cmpVer(version, m.version) < 0, compatible: !issues.some((i) => i.level === 'error'), components, issues };
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
// ---------------------------------------------------------------- suggest_fix
|
|
104
|
+
const lineOf = (src, i) => src.slice(0, Math.max(0, i)).split('\n').length;
|
|
105
|
+
const GLOBAL = new Set(['id', 'class', 'style', 'slot', 'hidden', 'title', 'lang', 'dir', 'tabindex', 'role', 'part', 'is', 'key', 'ref', 'classname', 'inert', 'draggable', 'contenteditable', 'exportparts', 'nonce', 'autofocus', 'popover', 'translate', 'spellcheck', 'accesskey', 'enterkeyhint', 'inputmode']);
|
|
106
|
+
|
|
107
|
+
/** Concrete patch suggestions for code using <usa-*> components: wrong tag names, unknown (mistyped / deprecated)
|
|
108
|
+
* attributes, components used but never imported / defined, bare `motionary/…` imports in a CDN page, missing
|
|
109
|
+
* runtime prerequisites, import paths / event names / CDN pins removed in 13.0 (the usa-codemod-13 tables).
|
|
110
|
+
* Each fix is { kind, message, line, patch: { find, replace } }; `fixed` is the code with every patch applied. */
|
|
111
|
+
export function suggestFix(m, code, opts, h) {
|
|
112
|
+
const { findComponent, cdnImports, validateSnippet } = h;
|
|
113
|
+
let src = String(code || '');
|
|
114
|
+
const fixes = [];
|
|
115
|
+
const add = (kind, message, find, replace, at) => { if (find && find !== replace && !fixes.some((f) => f.patch.find === find && f.patch.replace === replace)) fixes.push({ kind, message, line: lineOf(String(code || ''), at ?? String(code || '').indexOf(find)), patch: { find, replace } }); };
|
|
116
|
+
const context = opts.context || (/<html|<script\b|unpkg\.com|jsdelivr\.net/i.test(src) ? 'cdn' : /\bimport\s/.test(src) ? 'esm' : 'html');
|
|
117
|
+
// 1. unknown tags → closest tag (open + close)
|
|
118
|
+
for (const mm of src.matchAll(/<(usa-[a-z0-9-]+)/gi)) {
|
|
119
|
+
const t = mm[1].toLowerCase();
|
|
120
|
+
if (findComponent(m, t)) continue;
|
|
121
|
+
const best = m.components.map((k) => [k.tag, levenshtein(t, k.tag)]).sort((a, b) => a[1] - b[1] || a[0].localeCompare(b[0]))[0];
|
|
122
|
+
const rank = h.searchComponents(m, t.slice(4).replace(/-/g, ' '), 1)[0];
|
|
123
|
+
const to = best && best[1] <= Math.max(2, Math.floor(t.length / 4)) ? best[0] : rank?.tag;
|
|
124
|
+
if (to) { add('unknown-tag', `<${t}> is not a Motionary component — did you mean <${to}>?`, `<${mm[1]}`, `<${to}`, mm.index); add('unknown-tag', `closing tag of <${t}>`, `</${mm[1]}>`, `</${to}>`); }
|
|
125
|
+
}
|
|
126
|
+
// later passes look at the code with the tag names already fixed (patches are applied in order)
|
|
127
|
+
for (const f of fixes) src = src.split(f.patch.find).join(f.patch.replace);
|
|
128
|
+
// 2. unknown attributes → closest attribute of that component (typos and renamed / deprecated attributes)
|
|
129
|
+
for (const mm of src.matchAll(/<(usa-[a-z0-9-]+)([^>]*)>/gi)) {
|
|
130
|
+
const c = findComponent(m, mm[1]);
|
|
131
|
+
if (!c || !(c.attributes || []).length) continue;
|
|
132
|
+
const dep = (m.deprecatedAttributes || {})[c.tag] || {};
|
|
133
|
+
for (const am of mm[2].replace(/=\s*("[^"]*"|'[^']*')/g, (q) => q.replace(/[^\s="']/g, 'x').replace(/\s/g, '_')).matchAll(/(?:^|\s)([a-zA-Z_][\w-]*)(?=\s*=|\s|\/?$)/g)) {
|
|
134
|
+
const a = am[1].toLowerCase();
|
|
135
|
+
if (GLOBAL.has(a) || a.startsWith('data-') || a.startsWith('aria-') || a.startsWith('on') || c.attributes.includes(a)) continue;
|
|
136
|
+
const to = dep[a] || c.attributes.map((x) => [x, levenshtein(a, x)]).filter(([, d]) => d <= 2).sort((p, q) => p[1] - q[1])[0]?.[0];
|
|
137
|
+
if (!to) continue;
|
|
138
|
+
const whole = mm[0], fixed = whole.replace(new RegExp(`(\\s)${am[1]}(?=[\\s=/>])`), `$1${to}`);
|
|
139
|
+
add(dep[a] ? 'deprecated-attribute' : 'unknown-attribute', dep[a] ? `<${c.tag}> attribute "${a}" is deprecated — use "${to}"` : `<${c.tag}> has no attribute "${a}" — did you mean "${to}"?`, whole, fixed, mm.index);
|
|
140
|
+
}
|
|
141
|
+
}
|
|
142
|
+
// 3. removed paths / legacy events / old CDN major pins (usa-codemod-13)
|
|
143
|
+
const cm = codemod13(src);
|
|
144
|
+
if (cm.changes.length) {
|
|
145
|
+
const a = src.split('\n'), b = cm.code.split('\n');
|
|
146
|
+
a.forEach((l, i) => { if (b[i] !== undefined && b[i] !== l) add('deprecated-api', `removed in 13.0: ${cm.changes.join('; ')}`, l, b[i]); });
|
|
147
|
+
}
|
|
148
|
+
// 4. bare `motionary/…` imports inside a page that loads Motionary from a CDN
|
|
149
|
+
if (context === 'cdn' || context === 'html') {
|
|
150
|
+
for (const sm of src.matchAll(/<script\b[^>]*type=["']module["'][^>]*>([\s\S]*?)<\/script>/gi)) {
|
|
151
|
+
for (const lm of sm[1].matchAll(/^.*\b(?:from\s*|import\s*\(?\s*)['"]motionary(?:\/[\w./-]+)?['"].*$/gm)) add('bare-import', 'a CDN page cannot resolve bare `motionary/…` specifiers (no import map) — import the module from the same CDN major', lm[0], cdnImports(m, lm[0]));
|
|
152
|
+
}
|
|
153
|
+
}
|
|
154
|
+
// 5. components used but never imported / defined (ESM)
|
|
155
|
+
const usedTags = [...new Set([...src.matchAll(/<(usa-[a-z0-9-]+)/gi)].map((x) => x[1].toLowerCase()))].map((t) => findComponent(m, t) || findComponent(m, fixes.find((f) => f.kind === 'unknown-tag' && f.patch.find === `<${t}`)?.patch.replace.slice(1) || '')).filter(Boolean);
|
|
156
|
+
if (context === 'esm') {
|
|
157
|
+
const lines = [];
|
|
158
|
+
for (const c of usedTags) if (!src.includes(c.import.define + '(') && !/defineAll\w*\(|defineWidgets\(/.test(src)) lines.push(`import { ${c.import.define} } from '${c.import.path}';\n${c.import.register}`);
|
|
159
|
+
if (lines.length) {
|
|
160
|
+
const imp = [...src.matchAll(/^import .*$/gm)].pop();
|
|
161
|
+
if (imp) add('missing-import', `components used but never defined: ${usedTags.filter((c) => !src.includes(c.import.define + '(')).map((c) => `<${c.tag}>`).join(', ')}`, imp[0], `${imp[0]}\n${lines.join('\n')}`, imp.index);
|
|
162
|
+
else fixes.push({ kind: 'missing-import', message: 'components used but never defined', line: 1, patch: { find: '', replace: lines.join('\n') + '\n', insertAt: 'start' } });
|
|
163
|
+
}
|
|
164
|
+
}
|
|
165
|
+
// 6. missing runtime prerequisites (from the static validator)
|
|
166
|
+
const pre = validateSnippet(m, src).errors.concat(validateSnippet(m, src).warnings).filter((e) => /requires motionary\/runtime/.test(e));
|
|
167
|
+
for (const e of pre) {
|
|
168
|
+
const mod = (e.match(/requires (motionary\/runtime(?:\/[\w-]+)?)/) || [])[1];
|
|
169
|
+
if (!mod) continue;
|
|
170
|
+
const id = mod.split('/')[2], camel = id ? id.replace(/-(\w)/g, (_, x) => x.toUpperCase()) : null;
|
|
171
|
+
if (context === 'esm') {
|
|
172
|
+
const imp = src.match(/^import .*$/m);
|
|
173
|
+
const ins = id ? `import { use } from 'motionary/runtime';\nimport { ${camel} } from '${mod}';\nuse(${camel}); // prerequisites first` : `import 'motionary/runtime';`;
|
|
174
|
+
if (imp && !src.includes(`'${mod}'`)) add('missing-prerequisite', e, imp[0], `${ins}\n${imp[0]}`, imp.index);
|
|
175
|
+
} else {
|
|
176
|
+
const base = m.cdn.runtime.replace(/runtime\.iife\.js$/, '');
|
|
177
|
+
const tagAt = src.search(/<script\b[^>]*src=[^>]*(components|widgets)\.umd\.js/);
|
|
178
|
+
const first = tagAt > -1 ? src.slice(tagAt, src.indexOf('>', tagAt) + 1) : null;
|
|
179
|
+
const ins = `${src.includes('runtime.iife.js') ? '' : `<script src="${m.cdn.runtime}"></script>\n`}${id ? `<script src="${base}runtime/${id}.iife.js"></script>\n` : ''}`;
|
|
180
|
+
if (first && ins) add('missing-prerequisite', e, first, ins + first, tagAt);
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
let fixed = String(code || '');
|
|
184
|
+
for (const f of fixes) fixed = f.patch.insertAt === 'start' ? f.patch.replace + fixed : fixed.split(f.patch.find).join(f.patch.replace);
|
|
185
|
+
const after = validateSnippet(m, fixed);
|
|
186
|
+
return { schema: SCHEMAS.fix, context, fixes, fixed, valid: after.valid, remaining: { errors: after.errors, warnings: after.warnings } };
|
|
187
|
+
}
|