@yewdiel21/motion-kit 0.9.0 → 0.10.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/NOTICE +3 -35
- package/README.md +93 -81
- package/dist/auto/index.d.ts +22 -3
- package/dist/auto/index.js +43 -5
- package/dist/auto/index.js.map +1 -1
- package/dist/{chunk-KLY5BRRI.js → chunk-34EZ7DF4.js} +1 -1
- package/dist/chunk-34EZ7DF4.js.map +1 -0
- package/dist/{chunk-RFDIZYFX.js → chunk-DOOMULVV.js} +20 -20
- package/dist/chunk-DOOMULVV.js.map +1 -0
- package/dist/{chunk-ABNRDDO7.js → chunk-I3DXF2KQ.js} +2 -2
- package/dist/{chunk-Q4LVFNLN.js → chunk-IKQ5FODN.js} +4 -4
- package/dist/chunk-IKQ5FODN.js.map +1 -0
- package/dist/{chunk-2BQGFOA7.js → chunk-J6OCFNGU.js} +2 -2
- package/dist/chunk-J6OCFNGU.js.map +1 -0
- package/dist/{chunk-6OJAP6ZL.js → chunk-QFBOHPWZ.js} +3 -3
- package/dist/chunk-QFBOHPWZ.js.map +1 -0
- package/dist/{chunk-J27KH2A2.js → chunk-RVSKEBIC.js} +1 -1
- package/dist/chunk-RVSKEBIC.js.map +1 -0
- package/dist/{chunk-34XYOXHG.js → chunk-TFNRIZHU.js} +1615 -12
- package/dist/chunk-TFNRIZHU.js.map +1 -0
- package/dist/{chunk-FS2HJVVY.js → chunk-XAKC2QY7.js} +1204 -5
- package/dist/chunk-XAKC2QY7.js.map +1 -0
- package/dist/css/components/calendar.css +159 -0
- package/dist/css/components/chat-background.css +2 -2
- package/dist/css/components/chat.css +1 -1
- package/dist/css/components/cursor.css +3 -3
- package/dist/css/components/dialog.css +3 -3
- package/dist/css/components/hover-card.css +14 -0
- package/dist/css/components/input-otp.css +10 -0
- package/dist/css/components/island.css +1 -1
- package/dist/css/components/menu.css +1 -1
- package/dist/css/components/nav.css +1 -5
- package/dist/css/components/pagination.css +11 -0
- package/dist/css/components/quantity.css +16 -0
- package/dist/css/components/slot-picker.css +126 -0
- package/dist/css/components/steps.css +2 -2
- package/dist/css/components/studio-dock.css +35 -0
- package/dist/css/components/theme-picker.css +1 -1
- package/dist/css/components/toast.css +1 -1
- package/dist/css/components/trailer.css +37 -0
- package/dist/css/controls.css +78 -13
- package/dist/css/effects.css +8 -8
- package/dist/css/fonts.css +1 -1
- package/dist/css/themes/black-green.css +1 -1
- package/dist/css/themes/black.css +1 -1
- package/dist/css/themes/blue.css +1 -1
- package/dist/css/themes/brown.css +1 -1
- package/dist/css/themes/cold-blue.css +1 -1
- package/dist/css/themes/funny.css +1 -1
- package/dist/css/themes/gray.css +1 -1
- package/dist/css/themes/green.css +1 -1
- package/dist/css/themes/modern-1.css +1 -1
- package/dist/css/themes/neogreen.css +1 -1
- package/dist/css/themes/new.css +1 -1
- package/dist/css/themes/new2.css +1 -1
- package/dist/css/themes/oled.css +1 -1
- package/dist/css/themes/orange.css +1 -1
- package/dist/css/themes/pastel-pink.css +1 -1
- package/dist/css/themes/pink.css +1 -1
- package/dist/css/themes/purple.css +1 -1
- package/dist/css/themes/red.css +1 -1
- package/dist/css/themes/super-blue.css +1 -1
- package/dist/css/themes.css +19 -19
- package/dist/css/tokens.css +9 -9
- package/dist/elements/index.d.ts +75 -7
- package/dist/elements/index.js +172 -6
- package/dist/elements/index.js.map +1 -1
- package/dist/{engine-CUr9QijM.d.ts → engine-GDGwQnJE.d.ts} +2 -2
- package/dist/gl/index.js +3 -3
- package/dist/index.css +1076 -63
- package/dist/index.d.ts +17 -17
- package/dist/index.js +49 -7
- package/dist/index.js.map +1 -1
- package/dist/react/index.d.ts +139 -40
- package/dist/react/index.js +355 -8
- package/dist/react/index.js.map +1 -1
- package/dist/{reduced-BM4Ls0g5.d.ts → reduced-BmBzKH94.d.ts} +215 -18
- package/dist/{reveal-WFUWDrei.d.ts → reveal-jsX-uwUz.d.ts} +233 -24
- package/dist/{store-Bqy_obnD.d.ts → store-DYb3tTsZ.d.ts} +5 -5
- package/dist/theme/generate.d.ts +1 -1
- package/dist/theme/generate.js +2 -2
- package/dist/theme/generate.js.map +1 -1
- package/dist/theme/index.d.ts +2 -2
- package/dist/theme/index.js +2 -2
- package/dist/{theme-BFMoCzi6.d.ts → theme-Bjf9qIIy.d.ts} +1 -1
- package/package.json +2 -2
- package/registry.json +230 -156
- package/skills/motion-kit/SKILL.md +209 -189
- package/skills/motion-kit/reference/components.md +5 -5
- package/skills/motion-kit/reference/design.md +14 -14
- package/skills/motion-kit/reference/recipes.md +48 -49
- package/src/auto/auto-init.ts +38 -0
- package/src/components/calendar/README.md +82 -0
- package/src/components/calendar/calendar.css +158 -0
- package/src/components/calendar/element.ts +27 -0
- package/src/components/calendar/engine.ts +412 -0
- package/src/components/calendar/react.tsx +69 -0
- package/src/components/chat/README.md +1 -3
- package/src/components/chat/chat.css +1 -1
- package/src/components/chat/engine.ts +1 -1
- package/src/components/chat/react.tsx +1 -1
- package/src/components/chat-background/README.md +1 -3
- package/src/components/chat-background/audio.ts +1 -1
- package/src/components/chat-background/chat-background.css +2 -2
- package/src/components/chat-background/engine.ts +1 -1
- package/src/components/chat-background/react.tsx +1 -1
- package/src/components/cursor/README.md +3 -5
- package/src/components/cursor/cursor.css +3 -3
- package/src/components/cursor/element.ts +2 -2
- package/src/components/cursor/engine.ts +5 -5
- package/src/components/cursor/react.tsx +1 -1
- package/src/components/dialog/README.md +4 -8
- package/src/components/dialog/dialog.css +3 -3
- package/src/components/dialog/engine.ts +2 -2
- package/src/components/dialog/react.tsx +1 -1
- package/src/components/hover-card/README.md +16 -0
- package/src/components/hover-card/element.ts +8 -0
- package/src/components/hover-card/engine.ts +69 -0
- package/src/components/hover-card/hover-card.css +13 -0
- package/src/components/hover-card/react.tsx +19 -0
- package/src/components/input-otp/README.md +18 -0
- package/src/components/input-otp/element.ts +14 -0
- package/src/components/input-otp/engine.ts +106 -0
- package/src/components/input-otp/input-otp.css +9 -0
- package/src/components/input-otp/react.tsx +21 -0
- package/src/components/island/README.md +7 -7
- package/src/components/island/engine.ts +3 -3
- package/src/components/island/island.css +1 -1
- package/src/components/island/react.tsx +3 -3
- package/src/components/menu/README.md +2 -4
- package/src/components/menu/engine.ts +1 -1
- package/src/components/menu/menu.css +1 -1
- package/src/components/menu/react.tsx +1 -1
- package/src/components/nav/README.md +12 -14
- package/src/components/nav/engine.ts +5 -5
- package/src/components/nav/nav.css +1 -5
- package/src/components/nav/react.tsx +3 -3
- package/src/components/pagination/README.md +17 -0
- package/src/components/pagination/element.ts +14 -0
- package/src/components/pagination/engine.ts +102 -0
- package/src/components/pagination/pagination.css +10 -0
- package/src/components/pagination/react.tsx +22 -0
- package/src/components/quantity/README.md +20 -0
- package/src/components/quantity/element.ts +14 -0
- package/src/components/quantity/engine.ts +85 -0
- package/src/components/quantity/quantity.css +15 -0
- package/src/components/quantity/react.tsx +21 -0
- package/src/components/slot-picker/README.md +68 -0
- package/src/components/slot-picker/element.ts +27 -0
- package/src/components/slot-picker/engine.ts +412 -0
- package/src/components/slot-picker/react.tsx +76 -0
- package/src/components/slot-picker/slot-picker.css +125 -0
- package/src/components/steps/README.md +1 -3
- package/src/components/steps/engine.ts +3 -3
- package/src/components/steps/react.tsx +2 -2
- package/src/components/steps/steps.css +2 -2
- package/src/components/studio-dock/README.md +44 -0
- package/src/components/studio-dock/element.ts +11 -0
- package/src/components/studio-dock/engine.ts +212 -0
- package/src/components/studio-dock/react.tsx +23 -0
- package/src/components/studio-dock/studio-dock.css +34 -0
- package/src/components/theme-picker/README.md +3 -5
- package/src/components/theme-picker/engine.ts +2 -2
- package/src/components/theme-picker/react.tsx +1 -1
- package/src/components/theme-picker/theme-picker.css +1 -1
- package/src/components/toast/README.md +1 -3
- package/src/components/toast/engine.ts +2 -2
- package/src/components/toast/react.tsx +1 -1
- package/src/components/toast/store.ts +1 -2
- package/src/components/toast/toast.css +1 -1
- package/src/components/trailer/README.md +28 -0
- package/src/components/trailer/element.ts +13 -0
- package/src/components/trailer/engine.ts +189 -0
- package/src/components/trailer/react.tsx +16 -0
- package/src/components/trailer/trailer.css +36 -0
- package/src/core/channels.ts +3 -3
- package/src/core/curves.ts +3 -3
- package/src/core/dates.ts +98 -0
- package/src/core/gsap.ts +2 -2
- package/src/core/loop.ts +1 -1
- package/src/core/math.ts +1 -1
- package/src/core/physics-spring.ts +2 -2
- package/src/core/scroll-track.ts +2 -4
- package/src/core/spring.ts +1 -1
- package/src/core/timing.ts +21 -22
- package/src/css/controls/README.md +24 -20
- package/src/css/controls/burger.css +1 -1
- package/src/css/controls/button.css +4 -4
- package/src/css/controls/checkbox.css +1 -1
- package/src/css/controls/chip.css +1 -1
- package/src/css/controls/field.css +2 -2
- package/src/css/controls/glass.css +4 -4
- package/src/css/controls/status.css +63 -0
- package/src/css/default-theme.css +1 -1
- package/src/css/effects/README.md +19 -21
- package/src/css/effects/anim.css +1 -1
- package/src/css/effects/fade.css +1 -1
- package/src/css/effects/float.css +1 -1
- package/src/css/effects/frost.css +1 -1
- package/src/css/effects/grain.css +1 -1
- package/src/css/effects/loading.css +1 -1
- package/src/css/effects/success.css +1 -1
- package/src/css/effects/text.css +1 -1
- package/src/css/fonts.css +1 -1
- package/src/css/states.css +1 -1
- package/src/css/themes/black-green.css +1 -1
- package/src/css/themes/black.css +1 -1
- package/src/css/themes/blue.css +1 -1
- package/src/css/themes/brown.css +1 -1
- package/src/css/themes/cold-blue.css +1 -1
- package/src/css/themes/funny.css +1 -1
- package/src/css/themes/gray.css +1 -1
- package/src/css/themes/green.css +1 -1
- package/src/css/themes/modern-1.css +1 -1
- package/src/css/themes/neogreen.css +1 -1
- package/src/css/themes/new.css +1 -1
- package/src/css/themes/new2.css +1 -1
- package/src/css/themes/oled.css +1 -1
- package/src/css/themes/orange.css +1 -1
- package/src/css/themes/pastel-pink.css +1 -1
- package/src/css/themes/pink.css +1 -1
- package/src/css/themes/purple.css +1 -1
- package/src/css/themes/red.css +1 -1
- package/src/css/themes/super-blue.css +1 -1
- package/src/css/tokens.css +8 -8
- package/src/elements/index.ts +24 -0
- package/src/gl/liquid-blend/README.md +3 -3
- package/src/gl/matcap/README.md +3 -3
- package/src/gl/particle-hero/README.md +1 -1
- package/src/gl/particle-hero/create-particle-hero.ts +3 -5
- package/src/gl/particle-hero/shaders.ts +1 -1
- package/src/gl/shader-blur/README.md +3 -3
- package/src/gl/shader-grain/README.md +3 -3
- package/src/index.ts +25 -0
- package/src/motion/chat.ts +2 -2
- package/src/motion/confetti.ts +1 -1
- package/src/motion/count.ts +1 -1
- package/src/motion/details.ts +1 -1
- package/src/motion/drag-dismiss.ts +1 -1
- package/src/motion/effects.ts +1 -1
- package/src/motion/entrances.ts +1 -1
- package/src/motion/floating.ts +1 -1
- package/src/motion/flow.ts +2 -2
- package/src/motion/indicator.ts +1 -1
- package/src/motion/layout.ts +1 -1
- package/src/motion/liquid.ts +1 -1
- package/src/motion/morph.ts +2 -2
- package/src/motion/reveal.ts +1 -1
- package/src/motion/sheet.ts +1 -1
- package/src/motion/surface.ts +1 -1
- package/src/react/animated-number.tsx +2 -2
- package/src/react/flip-group.tsx +1 -1
- package/src/react/frost.tsx +1 -1
- package/src/react/index.ts +21 -0
- package/src/react/slot-text.tsx +1 -1
- package/src/react/use-action-button.ts +6 -0
- package/src/react/use-card-dock.ts +1 -1
- package/src/react/use-cascade.ts +1 -1
- package/src/react/use-contrast.ts +1 -1
- package/src/react/use-depth-grid.ts +1 -1
- package/src/react/use-editorial-reveal.ts +7 -0
- package/src/react/use-fill-text.ts +1 -1
- package/src/react/use-film-hero.ts +6 -0
- package/src/react/use-font-cycle.ts +7 -0
- package/src/react/use-frame-zoom.ts +1 -1
- package/src/react/use-image-zoom.ts +5 -0
- package/src/react/use-joined-cta.ts +5 -0
- package/src/react/use-letters.ts +1 -1
- package/src/react/use-local-clock.ts +5 -0
- package/src/react/use-marquee.ts +1 -1
- package/src/react/use-mask-text.ts +1 -1
- package/src/react/use-parallax.ts +1 -1
- package/src/react/use-particle-hero.ts +1 -1
- package/src/react/use-scroll-dock.ts +5 -0
- package/src/react/use-snap-strip.ts +1 -1
- package/src/react/use-sticker.ts +5 -0
- package/src/react/use-studio-dock.ts +8 -0
- package/src/react/use-text-roll.ts +1 -1
- package/src/react/use-thumbnail-nav.ts +7 -0
- package/src/react/use-trailer.ts +6 -0
- package/src/react/use-weight-hover.ts +5 -0
- package/src/recipes/action-button/README.md +31 -0
- package/src/recipes/action-button/action-button.css +113 -0
- package/src/recipes/action-button/create-action-button.ts +56 -0
- package/src/recipes/card-dock/README.md +1 -1
- package/src/recipes/card-dock/card-dock.css +1 -1
- package/src/recipes/card-dock/create-card-dock.ts +2 -2
- package/src/recipes/cascade/README.md +1 -3
- package/src/recipes/cascade/create-cascade.ts +3 -3
- package/src/recipes/contrast/README.md +0 -2
- package/src/recipes/contrast/create-contrast.ts +1 -1
- package/src/recipes/counter/README.md +0 -2
- package/src/recipes/counter/create-counter.ts +1 -1
- package/src/recipes/curved-carousel/README.md +0 -2
- package/src/recipes/curved-carousel/create-curved-carousel.ts +2 -2
- package/src/recipes/curved-carousel/curved-carousel.css +1 -1
- package/src/recipes/depth-grid/README.md +0 -2
- package/src/recipes/depth-grid/create-depth-grid.ts +3 -4
- package/src/recipes/details/README.md +0 -2
- package/src/recipes/details/create-details.ts +1 -1
- package/src/recipes/dock-pill/README.md +3 -3
- package/src/recipes/drag-ruler/README.md +3 -3
- package/src/recipes/editorial-reveal/README.md +35 -0
- package/src/recipes/editorial-reveal/create-editorial-reveal.ts +91 -0
- package/src/recipes/editorial-reveal/editorial-reveal.css +17 -0
- package/src/recipes/fill-text/README.md +1 -1
- package/src/recipes/fill-text/create-fill-text.ts +1 -1
- package/src/recipes/film-hero/README.md +23 -0
- package/src/recipes/film-hero/create-film-hero.ts +65 -0
- package/src/recipes/film-hero/film-hero.css +29 -0
- package/src/recipes/fit-text/README.md +0 -2
- package/src/recipes/flow/README.md +0 -2
- package/src/recipes/flow/create-flow.ts +1 -1
- package/src/recipes/font-cycle/README.md +11 -0
- package/src/recipes/font-cycle/create-font-cycle.ts +126 -0
- package/src/recipes/font-cycle/font-cycle.css +36 -0
- package/src/recipes/frame-zoom/README.md +1 -3
- package/src/recipes/frame-zoom/create-frame-zoom.ts +2 -2
- package/src/recipes/image-zoom/README.md +16 -0
- package/src/recipes/image-zoom/create-image-zoom.ts +27 -0
- package/src/recipes/image-zoom/image-zoom.css +7 -0
- package/src/recipes/infinite-reel/README.md +3 -3
- package/src/recipes/joined-cta/README.md +13 -0
- package/src/recipes/joined-cta/create-joined-cta.ts +22 -0
- package/src/recipes/joined-cta/joined-cta.css +17 -0
- package/src/recipes/letters/README.md +2 -4
- package/src/recipes/letters/create-letters.ts +3 -3
- package/src/recipes/local-clock/README.md +31 -0
- package/src/recipes/local-clock/create-local-clock.ts +61 -0
- package/src/recipes/marquee/README.md +0 -2
- package/src/recipes/marquee/create-marquee.ts +3 -3
- package/src/recipes/marquee/marquee.css +1 -1
- package/src/recipes/mask-text/README.md +3 -5
- package/src/recipes/mask-text/create-mask-text.ts +4 -4
- package/src/recipes/parallax/README.md +1 -3
- package/src/recipes/parallax/create-parallax.ts +1 -1
- package/src/recipes/pile/README.md +0 -2
- package/src/recipes/pile/create-pile.ts +1 -1
- package/src/recipes/pile/pile-math.ts +1 -1
- package/src/recipes/pile/pile.css +1 -1
- package/src/recipes/pill/README.md +0 -2
- package/src/recipes/pill/pill.css +2 -2
- package/src/recipes/pop/README.md +0 -2
- package/src/recipes/pop/create-pop.ts +1 -1
- package/src/recipes/radial-menu/README.md +0 -2
- package/src/recipes/radial-menu/create-radial-menu.ts +1 -1
- package/src/recipes/radial-menu/radial-menu.css +1 -1
- package/src/recipes/reflow/README.md +3 -5
- package/src/recipes/reflow/create-reflow.ts +1 -1
- package/src/recipes/repel-bento/README.md +3 -3
- package/src/recipes/reveal/README.md +0 -2
- package/src/recipes/reveal/create-reveal.ts +1 -1
- package/src/recipes/rotator/README.md +3 -3
- package/src/recipes/scroll-dock/README.md +46 -0
- package/src/recipes/scroll-dock/create-scroll-dock.ts +72 -0
- package/src/recipes/scroll-dock/scroll-dock.css +70 -0
- package/src/recipes/slot-text/README.md +0 -2
- package/src/recipes/slot-text/create-slot-text.ts +1 -1
- package/src/recipes/snap-strip/README.md +1 -1
- package/src/recipes/snap-strip/create-snap-strip.ts +5 -6
- package/src/recipes/snap-strip/snap-strip.css +1 -1
- package/src/recipes/sortable/README.md +3 -5
- package/src/recipes/sortable/create-sortable.ts +4 -4
- package/src/recipes/sortable/sortable.css +1 -1
- package/src/recipes/spring-cards/README.md +0 -2
- package/src/recipes/spring-cards/create-spring-cards.ts +1 -1
- package/src/recipes/spring-cards/spring-cards.css +1 -1
- package/src/recipes/sticker/README.md +59 -0
- package/src/recipes/sticker/create-sticker.ts +490 -0
- package/src/recipes/sticker/sticker.css +112 -0
- package/src/recipes/stretch-footer/README.md +0 -2
- package/src/recipes/stretch-footer/create-stretch-footer.ts +1 -1
- package/src/recipes/stretch-footer/stretch-footer.css +1 -1
- package/src/recipes/tabs/README.md +0 -2
- package/src/recipes/tabs/create-tabs.ts +1 -1
- package/src/recipes/text-roll/README.md +1 -3
- package/src/recipes/text-roll/create-text-roll.ts +3 -3
- package/src/recipes/text-roll/text-roll.css +1 -1
- package/src/recipes/thumbnail-nav/README.md +16 -0
- package/src/recipes/thumbnail-nav/create-thumbnail-nav.ts +165 -0
- package/src/recipes/thumbnail-nav/thumbnail-nav.css +108 -0
- package/src/recipes/ticket-menu/README.md +3 -3
- package/src/recipes/weight-hover/README.md +37 -0
- package/src/recipes/weight-hover/create-weight-hover.ts +136 -0
- package/src/recipes/weight-hover/weight-hover.css +7 -0
- package/src/recipes/words/README.md +0 -2
- package/src/recipes/words/create-words.ts +1 -1
- package/src/theme/generate.ts +1 -1
- package/src/theme/presets.ts +2 -2
- package/src/theme/theme.ts +1 -2
- package/dist/chunk-2BQGFOA7.js.map +0 -1
- package/dist/chunk-34XYOXHG.js.map +0 -1
- package/dist/chunk-6OJAP6ZL.js.map +0 -1
- package/dist/chunk-FS2HJVVY.js.map +0 -1
- package/dist/chunk-J27KH2A2.js.map +0 -1
- package/dist/chunk-KLY5BRRI.js.map +0 -1
- package/dist/chunk-Q4LVFNLN.js.map +0 -1
- package/dist/chunk-RFDIZYFX.js.map +0 -1
- /package/dist/{chunk-ABNRDDO7.js.map → chunk-I3DXF2KQ.js.map} +0 -0
package/dist/react/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/react/use-recipe.ts","../../src/react/use-spring-cards.ts","../../src/react/use-curved-carousel.ts","../../src/react/use-pile.ts","../../src/react/use-words.ts","../../src/react/use-flow.ts","../../src/react/use-pop.ts","../../src/react/use-fit-text.ts","../../src/react/use-stretch-footer.ts","../../src/react/use-radial-menu.ts","../../src/react/use-tabs.ts","../../src/react/use-counter.ts","../../src/react/use-details.ts","../../src/react/use-reveal.ts","../../src/react/use-reflow.ts","../../src/react/use-slot-text.ts","../../src/react/use-sortable.ts","../../src/react/use-mask-text.ts","../../src/react/use-cascade.ts","../../src/react/use-text-roll.ts","../../src/react/use-letters.ts","../../src/react/use-parallax.ts","../../src/react/use-depth-grid.ts","../../src/react/use-frame-zoom.ts","../../src/react/use-contrast.ts","../../src/react/use-marquee.ts","../../src/react/use-card-dock.ts","../../src/react/use-snap-strip.ts","../../src/react/use-fill-text.ts","../../src/react/use-ticket-menu.ts","../../src/react/use-infinite-reel.ts","../../src/react/use-repel-bento.ts","../../src/react/use-rotator.ts","../../src/react/use-drag-ruler.ts","../../src/react/use-dock-pill.ts","../../src/react/use-liquid-blend.ts","../../src/react/use-matcap.ts","../../src/react/use-shader-grain.ts","../../src/react/use-shader-blur.ts","../../src/react/use-particle-hero.ts","../../src/react/theme-provider.tsx","../../src/components/theme-picker/react.tsx","../../src/react/slot-text.tsx","../../src/react/animated-number.tsx","../../src/react/flip-group.tsx","../../src/components/dialog/react.tsx","../../src/components/icon.tsx","../../src/components/menu/react.tsx","../../src/components/toast/react.tsx","../../src/components/chat-background/react.tsx","../../src/components/chat/react.tsx","../../src/components/nav/react.tsx","../../src/components/steps/react.tsx","../../src/components/cursor/react.tsx","../../src/react/frost.tsx","../../src/components/island/react.tsx"],"sourcesContent":["'use client';\n\nimport { useEffect, useLayoutEffect, useRef, type DependencyList, type RefObject } from 'react';\nimport type { Instance } from '../core/types';\n\n/** useLayoutEffect in the browser (no flash), useEffect during SSR (no warning). */\nexport const useIsomorphicLayoutEffect = typeof window !== 'undefined' ? useLayoutEffect : useEffect;\n\n/**\n * Create a recipe on `ref.current` after mount and destroy it on unmount or when\n * `deps` change. Returns a ref holding the live instance (controls like `next()`).\n */\nexport function useRecipe<I extends Instance, O>(\n ref: RefObject<HTMLElement | null>,\n factory: (el: HTMLElement | null, options?: O) => I,\n options?: O,\n deps: DependencyList = [],\n): RefObject<I | null> {\n const instance = useRef<I | null>(null);\n useIsomorphicLayoutEffect(() => {\n const created = factory(ref.current, options);\n instance.current = created;\n return () => {\n created.destroy();\n instance.current = null;\n };\n // Options are read once per creation; pass `deps` to recreate when they change.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, deps);\n return instance;\n}\n\n/** Keep the latest callback in a ref so recipes do not restart on every render. */\nexport function useLatest<T>(value: T) {\n const ref = useRef(value);\n ref.current = value;\n return ref;\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createSpringCards, type SpringCardsOptions } from '../recipes/spring-cards/create-spring-cards';\n\nexport const useSpringCards = (ref: RefObject<HTMLElement | null>, options?: SpringCardsOptions, deps?: DependencyList) =>\n useRecipe(ref, createSpringCards, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createCurvedCarousel, type CurvedCarouselOptions } from '../recipes/curved-carousel/create-curved-carousel';\n\nexport function useCurvedCarousel(ref: RefObject<HTMLElement | null>, options: CurvedCarouselOptions = {}, deps?: DependencyList) {\n const onSelect = useLatest(options.onSelect);\n return useRecipe(ref, createCurvedCarousel, { ...options, onSelect: (index, slide) => onSelect.current?.(index, slide) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createPile, type PileOptions } from '../recipes/pile/create-pile';\n\nexport const usePile = (ref: RefObject<HTMLElement | null>, options?: PileOptions, deps?: DependencyList) =>\n useRecipe(ref, createPile, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createWords, type WordsOptions } from '../recipes/words/create-words';\n\nexport const useWords = (ref: RefObject<HTMLElement | null>, options?: WordsOptions, deps?: DependencyList) =>\n useRecipe(ref, createWords, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createFlow, type FlowOptions } from '../recipes/flow/create-flow';\n\nexport const useFlow = (ref: RefObject<HTMLElement | null>, options?: FlowOptions, deps?: DependencyList) =>\n useRecipe(ref, createFlow, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createPop, type PopOptions } from '../recipes/pop/create-pop';\n\nexport const usePop = (ref: RefObject<HTMLElement | null>, options?: PopOptions, deps?: DependencyList) =>\n useRecipe(ref, createPop, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createFitText, type FitTextOptions } from '../recipes/fit-text/create-fit-text';\n\nexport const useFitText = (ref: RefObject<HTMLElement | null>, options?: FitTextOptions, deps?: DependencyList) =>\n useRecipe(ref, createFitText, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createStretchFooter, type StretchFooterOptions } from '../recipes/stretch-footer/create-stretch-footer';\n\nexport interface UseStretchFooterOptions extends Omit<StretchFooterOptions, 'phantom' | 'title'> {\n phantomRef?: RefObject<HTMLElement | null>;\n titleRef?: RefObject<HTMLElement | null>;\n}\n\nexport function useStretchFooter(ref: RefObject<HTMLElement | null>, options: UseStretchFooterOptions = {}, deps?: DependencyList) {\n const { phantomRef, titleRef, ...rest } = options;\n return useRecipe(\n ref,\n (el) => createStretchFooter(el, { ...rest, phantom: phantomRef?.current ?? undefined, title: titleRef?.current ?? undefined }),\n undefined,\n deps,\n );\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createRadialMenu, type RadialMenuOptions } from '../recipes/radial-menu/create-radial-menu';\n\nexport function useRadialMenu(ref: RefObject<HTMLElement | null>, options: RadialMenuOptions = {}, deps?: DependencyList) {\n const onToggle = useLatest(options.onToggle);\n return useRecipe(ref, createRadialMenu, { ...options, onToggle: (open) => onToggle.current?.(open) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createTabs, type TabsOptions } from '../recipes/tabs/create-tabs';\n\nexport function useTabs(ref: RefObject<HTMLElement | null>, options: TabsOptions = {}, deps?: DependencyList) {\n const onSelect = useLatest(options.onSelect);\n return useRecipe(ref, createTabs, { ...options, onSelect: (index, tab) => onSelect.current?.(index, tab) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createCounter, type CounterOptions } from '../recipes/counter/create-counter';\n\nexport const useCounter = (ref: RefObject<HTMLElement | null>, options?: CounterOptions, deps?: DependencyList) =>\n useRecipe(ref, createCounter, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createDetails } from '../recipes/details/create-details';\n\nexport const useDetails = (ref: RefObject<HTMLElement | null>, deps?: DependencyList) => useRecipe(ref, createDetails, undefined, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createReveal, type RevealRecipeOptions } from '../recipes/reveal/create-reveal';\n\nexport const useReveal = (ref: RefObject<HTMLElement | null>, options?: RevealRecipeOptions, deps?: DependencyList) =>\n useRecipe(ref, createReveal, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createReflow, type ReflowOptions } from '../recipes/reflow/create-reflow';\n\n/** Call `.current.capture()` before the state change and `.current.play()` in a layout effect after it. */\nexport const useReflow = (ref: RefObject<HTMLElement | null>, options?: ReflowOptions, deps?: DependencyList) =>\n useRecipe(ref, createReflow, options, deps);\n","'use client';\n\nimport type { RefObject } from 'react';\nimport { useIsomorphicLayoutEffect, useRecipe } from './use-recipe';\nimport { createSlotText, type SlotTextOptions } from '../recipes/slot-text/create-slot-text';\n\n/**\n * Rolls `text` into `ref` whenever it changes. The element must render no\n * children of its own: the recipe writes the letters (see `<SlotText>`).\n */\nexport function useSlotText(ref: RefObject<HTMLElement | null>, text: string, options: Omit<SlotTextOptions, 'text'> = {}) {\n const instance = useRecipe(ref, createSlotText, { ...options, text });\n useIsomorphicLayoutEffect(() => {\n instance.current?.set(text);\n }, [text]);\n return instance;\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createSortable, type SortableOptions } from '../recipes/sortable/create-sortable';\n\n/**\n * Drag to reorder a list React renders: answer `onReorder` by updating your state\n * (React moves the DOM; the engine waits for it and lands the item). `mutate` is off.\n */\nexport function useSortable(ref: RefObject<HTMLElement | null>, options: SortableOptions = {}, deps?: DependencyList) {\n const onReorder = useLatest(options.onReorder);\n return useRecipe(ref, createSortable, { mutate: false, ...options, onReorder: (detail) => onReorder.current?.(detail) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createMaskText, type MaskTextOptions } from '../recipes/mask-text/create-mask-text';\n\n/** Masked lines / words / letters rising into view (OFFFICE). */\nexport const useMaskText = (ref: RefObject<HTMLElement | null>, options?: MaskTextOptions, deps?: DependencyList) =>\n useRecipe(ref, createMaskText, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createCascade, type CascadeOptions } from '../recipes/cascade/create-cascade';\n\n/** Siena's reveal group: rules, fades and rises one after another. */\nexport const useCascade = (ref: RefObject<HTMLElement | null>, options?: CascadeOptions, deps?: DependencyList) =>\n useRecipe(ref, createCascade, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createTextRoll, type TextRollOptions } from '../recipes/text-roll/create-text-roll';\n\n/** Siena's slot title. `.current.play()` spins it. */\nexport const useTextRoll = (ref: RefObject<HTMLElement | null>, options?: TextRollOptions, deps?: DependencyList) =>\n useRecipe(ref, createTextRoll, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createLetters, type LettersOptions } from '../recipes/letters/create-letters';\n\n/** Dousan's hero letters (scale on hover or pastel blink). */\nexport const useLetters = (ref: RefObject<HTMLElement | null>, options?: LettersOptions, deps?: DependencyList) =>\n useRecipe(ref, createLetters, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createParallax, type ParallaxOptions } from '../recipes/parallax/create-parallax';\n\n/** Siena's photo parallax inside its frame. */\nexport const useParallax = (ref: RefObject<HTMLElement | null>, options?: ParallaxOptions, deps?: DependencyList) =>\n useRecipe(ref, createParallax, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createDepthGrid, type DepthGridOptions } from '../recipes/depth-grid/create-depth-grid';\n\n/** Siena's grid gathering from depth as it scrolls. */\nexport const useDepthGrid = (ref: RefObject<HTMLElement | null>, options?: DepthGridOptions, deps?: DependencyList) =>\n useRecipe(ref, createDepthGrid, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createFrameZoom, type FrameZoomOptions } from '../recipes/frame-zoom/create-frame-zoom';\n\n/** Siena's video mask: frame and picture scale in opposite directions. */\nexport const useFrameZoom = (ref: RefObject<HTMLElement | null>, options?: FrameZoomOptions, deps?: DependencyList) =>\n useRecipe(ref, createFrameZoom, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createContrast, type ContrastOptions } from '../recipes/contrast/create-contrast';\n\n/** Siena's header contrast from the section under it. */\nexport const useContrast = (ref: RefObject<HTMLElement | null>, options?: ContrastOptions, deps?: DependencyList) =>\n useRecipe(ref, createContrast, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createMarquee, type MarqueeOptions } from '../recipes/marquee/create-marquee';\n\n/** Siena's seamless marquee. */\nexport const useMarquee = (ref: RefObject<HTMLElement | null>, options?: MarqueeOptions, deps?: DependencyList) =>\n useRecipe(ref, createMarquee, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createCardDock, type CardDockOptions } from '../recipes/card-dock/create-card-dock';\n\n/** iyo.ai's product dock (stacked glass cards that spread on hover). */\nexport const useCardDock = (ref: RefObject<HTMLElement | null>, options?: CardDockOptions, deps?: DependencyList) =>\n useRecipe(ref, createCardDock, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createSnapStrip, type SnapStripOptions } from '../recipes/snap-strip/create-snap-strip';\n\n/** iyo.ai's phone cards: an autoplaying scroll-snap strip. */\nexport const useSnapStrip = (ref: RefObject<HTMLElement | null>, options?: SnapStripOptions, deps?: DependencyList) =>\n useRecipe(ref, createSnapStrip, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createFillText, type FillTextOptions } from '../recipes/fill-text/create-fill-text';\n\n/** iyo.ai's fill-text: letters fill in as the text scrolls up. */\nexport const useFillText = (ref: RefObject<HTMLElement | null>, options?: FillTextOptions, deps?: DependencyList) =>\n useRecipe(ref, createFillText, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createTicketMenu, type TicketMenuOptions } from '../recipes/ticket-menu/create-ticket-menu';\n\nexport function useTicketMenu(ref: RefObject<HTMLElement | null>, options: TicketMenuOptions = {}, deps?: DependencyList) {\n const latest = useLatest(options);\n return useRecipe(ref, createTicketMenu, {\n ...options,\n onSelect: (value, item) => latest.current.onSelect?.(value, item),\n onOpen: () => latest.current.onOpen?.(),\n onClose: () => latest.current.onClose?.(),\n }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createInfiniteReel, type InfiniteReelOptions } from '../recipes/infinite-reel/create-infinite-reel';\n\nexport const useInfiniteReel = (ref: RefObject<HTMLElement | null>, options?: InfiniteReelOptions, deps?: DependencyList) =>\n useRecipe(ref, createInfiniteReel, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createRepelBento, type RepelBentoOptions } from '../recipes/repel-bento/create-repel-bento';\n\nexport const useRepelBento = (ref: RefObject<HTMLElement | null>, options?: RepelBentoOptions, deps?: DependencyList) =>\n useRecipe(ref, createRepelBento, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createRotator, type RotatorOptions } from '../recipes/rotator/create-rotator';\n\nexport function useRotator(ref: RefObject<HTMLElement | null>, options: RotatorOptions = {}, deps?: DependencyList) {\n const callback = useLatest(options.onChange);\n return useRecipe(ref, createRotator, { ...options, onChange: (index) => callback.current?.(index) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createDragRuler, type DragRulerOptions } from '../recipes/drag-ruler/create-drag-ruler';\n\nexport function useDragRuler(ref: RefObject<HTMLElement | null>, options: DragRulerOptions = {}, deps?: DependencyList) {\n const callback = useLatest(options.onChange);\n return useRecipe(ref, createDragRuler, { ...options, onChange: (value) => callback.current?.(value) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createDockPill, type DockPillOptions } from '../recipes/dock-pill/create-dock-pill';\n\nexport function useDockPill(ref: RefObject<HTMLElement | null>, options: DockPillOptions = {}, deps?: DependencyList) {\n const callback = useLatest(options.onSelect);\n return useRecipe(ref, createDockPill, { ...options, onSelect: (index, item) => callback.current?.(index, item) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createLiquidBlend, type LiquidBlendOptions } from '../gl/liquid-blend/create-liquid-blend';\n\nexport const useLiquidBlend = (ref: RefObject<HTMLElement | null>, options?: LiquidBlendOptions, deps?: DependencyList) =>\n useRecipe(ref, createLiquidBlend, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createMatcap, type MatcapOptions } from '../gl/matcap/create-matcap';\n\nexport const useMatcap = (ref: RefObject<HTMLElement | null>, options?: MatcapOptions, deps?: DependencyList) =>\n useRecipe(ref, createMatcap, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createShaderGrain, type ShaderGrainOptions } from '../gl/shader-grain/create-shader-grain';\n\nexport const useShaderGrain = (ref: RefObject<HTMLElement | null>, options?: ShaderGrainOptions, deps?: DependencyList) =>\n useRecipe(ref, createShaderGrain, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createShaderBlur, type ShaderBlurOptions } from '../gl/shader-blur/create-shader-blur';\n\nexport const useShaderBlur = (ref: RefObject<HTMLElement | null>, options?: ShaderBlurOptions, deps?: DependencyList) =>\n useRecipe(ref, createShaderBlur, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createParticleHero, type ParticleHeroOptions } from '../gl/particle-hero/create-particle-hero';\n\n/** iyo.ai's particle hero (WebGL2, Canvas2D fallback). The canvas joins the ref's element. */\nexport const useParticleHero = (ref: RefObject<HTMLElement | null>, options?: ParticleHeroOptions, deps?: DependencyList) =>\n useRecipe(ref, createParticleHero, options, deps);\n","'use client';\n\nimport { createContext, useContext, useMemo, useState, type ReactNode } from 'react';\nimport { useIsomorphicLayoutEffect } from './use-recipe';\nimport { DEFAULT_THEME } from '../theme/presets';\nimport { THEME_EVENT, initTheme, setMode, setTheme, type InitThemeOptions, type ThemeMode, type ThemeState } from '../theme/theme';\n\nexport interface ThemeContextValue extends ThemeState {\n setTheme: typeof setTheme;\n setMode: typeof setMode;\n}\n\nconst ThemeContext = createContext<ThemeContextValue | null>(null);\n\nexport interface ThemeProviderProps {\n children?: ReactNode;\n defaultTheme?: InitThemeOptions['default'];\n mode?: ThemeMode;\n storageKey?: string;\n}\n\n/**\n * Applies the stored (or default) theme on mount and shares it. Add\n * MK_THEME_HEAD_SCRIPT to <head> as well, so the first paint already has it.\n */\nexport function ThemeProvider({ children, defaultTheme, mode, storageKey }: ThemeProviderProps) {\n const [state, setState] = useState<ThemeState>(() => ({ id: defaultTheme ?? DEFAULT_THEME, mode: mode ?? 'system', resolved: 'light' }));\n useIsomorphicLayoutEffect(() => {\n const onChange = (event: Event) => setState((event as CustomEvent<ThemeState>).detail);\n document.addEventListener(THEME_EVENT, onChange);\n setState(initTheme({ default: defaultTheme, mode, storageKey }));\n return () => document.removeEventListener(THEME_EVENT, onChange);\n }, [defaultTheme, mode, storageKey]);\n const value = useMemo(() => ({ ...state, setTheme, setMode }), [state]);\n return <ThemeContext.Provider value={value}>{children}</ThemeContext.Provider>;\n}\n\nexport function useTheme(): ThemeContextValue {\n const value = useContext(ThemeContext);\n if (!value) throw new Error('useTheme() needs a <ThemeProvider> above it');\n return value;\n}\n","'use client';\n\nimport { useRef, type CSSProperties } from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createThemePicker, type ThemePickerOptions } from './engine';\n\nexport interface ThemePickerProps extends ThemePickerOptions {\n className?: string;\n style?: CSSProperties;\n /** Skip the base class (style it yourself). */\n unstyled?: boolean;\n}\n\n/** Stepbro's theme picker. Wrap the app in <ThemeProvider> to read the choice. */\nexport function ThemePicker({ className, style, unstyled, themes, showHidden, labels, onChange }: ThemePickerProps) {\n const ref = useRef<HTMLDivElement>(null);\n const change = useLatest(onChange);\n const themeKey = themes?.join(',');\n useIsomorphicLayoutEffect(() => {\n const picker = createThemePicker(ref.current, {\n themes: themeKey ? themeKey.split(',') : undefined,\n showHidden,\n labels,\n onChange: (id) => change.current?.(id),\n });\n return () => picker.destroy();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [themeKey, showHidden, labels?.group]);\n const classes = [unstyled ? null : 'mk-theme-picker', className].filter(Boolean).join(' ');\n return <div ref={ref} className={classes || undefined} style={style} />;\n}\n","'use client';\n\nimport { useRef, useState } from 'react';\nimport { useIsomorphicLayoutEffect } from './use-recipe';\nimport { createSlotText, type SlotTextInstance, type SlotTextOptions } from '../recipes/slot-text/create-slot-text';\n\nexport interface SlotTextProps extends Omit<SlotTextOptions, 'text' | 'accessibleCopy'> {\n text: string;\n className?: string;\n}\n\nconst escapeHtml = (text: string) => text.replace(/[&<>\"']/g, (c) => `&#${c.charCodeAt(0)};`);\n\n/**\n * Text whose letters roll when it changes (Stepbro's SlotText). The server\n * renders the text itself; React never reconciles the letters (they belong to\n * the recipe), and screen readers read the plain copy.\n */\nexport function SlotText({ text, className, direction, duration, stagger, exitOffset, colorFade, maxTilt }: SlotTextProps) {\n const ref = useRef<HTMLSpanElement>(null);\n const instance = useRef<SlotTextInstance | null>(null);\n const [initial] = useState(text);\n // A stable object: React 19 re-applies innerHTML when this prop changes identity.\n const [html] = useState(() => ({ __html: escapeHtml(text) }));\n useIsomorphicLayoutEffect(() => {\n const created = createSlotText(ref.current, { direction, duration, stagger, exitOffset, colorFade, maxTilt, text: initial, accessibleCopy: false });\n instance.current = created;\n return () => {\n created.destroy();\n instance.current = null;\n };\n // The recipe is created once; the text is pushed below.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n useIsomorphicLayoutEffect(() => {\n instance.current?.set(text);\n }, [text]);\n return (\n <span className={className}>\n <span className=\"mk-sr-only\">{text}</span>\n <span ref={ref} aria-hidden=\"true\" dangerouslySetInnerHTML={html} />\n </span>\n );\n}\n","'use client';\n\nimport { useEffect, useRef, useState } from 'react';\nimport { tweenNumber } from '../motion/count';\n\nexport interface AnimatedNumberProps {\n value: number;\n /** How the shown value is written. Default: whole numbers. */\n format?: (shown: number) => string;\n /** Seconds. Default 0.6 (Stepbro's numberSoft); prices use 0.7. */\n duration?: number;\n}\n\nconst whole = (shown: number) => String(Math.round(shown));\n\n/** A number that counts to each new value from the one shown (Stepbro's AnimatedNumber). */\nexport function AnimatedNumber({ value, format = whole, duration }: AnimatedNumberProps) {\n const [shown, setShown] = useState(value);\n const current = useRef(value);\n useEffect(() => {\n const tween = tweenNumber(current.current, value, (next) => {\n current.current = next;\n setShown(next);\n }, { duration });\n return () => {\n tween?.kill();\n };\n }, [value, duration]);\n return <>{format(shown)}</>;\n}\n","'use client';\n\nimport { Component, type ReactNode, type RefObject } from 'react';\nimport { captureLayout, reflowLayout, type CapturedLayout } from '../motion/layout';\n\nexport interface FlipGroupProps {\n /** The list element. */\n root: RefObject<HTMLElement | null>;\n /** Items inside it; they need a stable `data-flip-id`. */\n selector?: string;\n /** Changes whenever the layout should animate (order, filter, grouping): e.g. the ids joined. */\n signature: string;\n children?: ReactNode;\n}\n\n/**\n * Plays Stepbro's layout reflow when `signature` changes: the layout is\n * measured just before React commits and the items travel from there. A class\n * component, because only `getSnapshotBeforeUpdate` reads the DOM before the commit.\n */\nexport class FlipGroup extends Component<FlipGroupProps> {\n private flip: ReturnType<typeof reflowLayout> = null;\n\n override getSnapshotBeforeUpdate(previous: Readonly<FlipGroupProps>): CapturedLayout | null {\n const node = this.props.root.current;\n if (previous.signature === this.props.signature || !node) return null;\n return captureLayout(node, this.props.selector ?? '[data-flip-id]');\n }\n\n override componentDidUpdate(_previous: unknown, _state: unknown, before: CapturedLayout | null) {\n const node = this.props.root.current;\n if (!before || !node) return;\n this.flip?.kill();\n this.flip = reflowLayout(node, this.props.selector ?? '[data-flip-id]', before);\n }\n\n override componentWillUnmount() {\n this.flip?.kill();\n }\n\n override render() {\n return this.props.children;\n }\n}\n","'use client';\n\nimport {\n createContext,\n useCallback,\n useContext,\n useMemo,\n useRef,\n useState,\n type ButtonHTMLAttributes,\n type DialogHTMLAttributes,\n type HTMLAttributes,\n type MutableRefObject,\n type ReactNode,\n} from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { MkIcon } from '../icon';\nimport { createDialog, type DialogInstance, type DialogOptions } from './engine';\n\nexport { MkIcon };\n\nexport type SurfaceOptions = Omit<DialogOptions, 'onOpen' | 'onClose' | 'triggers'>;\n\nexport interface SurfaceContextValue<I> {\n open: boolean;\n setOpen: (open: boolean) => void;\n /** The control the next open grows from (set by the Trigger). */\n origin: MutableRefObject<HTMLElement | null>;\n instance: MutableRefObject<I | null>;\n options: SurfaceOptions;\n}\n\nexport interface SurfaceRootProps extends SurfaceOptions {\n open?: boolean;\n defaultOpen?: boolean;\n onOpenChange?: (open: boolean) => void;\n children?: ReactNode;\n}\n\n/** Open state (controlled or not) shared by a surface's parts. Used by Dialog and Menu. */\nexport function useSurfaceRoot<I>({ open: controlled, defaultOpen = false, onOpenChange, children: _children, ...options }: SurfaceRootProps): SurfaceContextValue<I> {\n const [uncontrolled, setUncontrolled] = useState(defaultOpen);\n const open = controlled ?? uncontrolled;\n const current = useLatest(open);\n const change = useLatest(onOpenChange);\n const isControlled = controlled !== undefined;\n const setOpen = useCallback(\n (next: boolean) => {\n if (next === current.current) return;\n current.current = next;\n if (!isControlled) setUncontrolled(next);\n change.current?.(next);\n },\n [isControlled, current, change],\n );\n const origin = useRef<HTMLElement | null>(null);\n const instance = useRef<I | null>(null);\n const optionKey = JSON.stringify(options);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n const stable = useMemo(() => options, [optionKey]);\n return useMemo(() => ({ open, setOpen, origin, instance, options: stable }), [open, setOpen, stable]);\n}\n\nconst DialogContext = createContext<SurfaceContextValue<DialogInstance> | null>(null);\n\nfunction useDialogContext(part: string) {\n const value = useContext(DialogContext);\n if (!value) throw new Error(`<Dialog.${part}> must be inside <Dialog.Root>`);\n return value;\n}\n\nfunction Root(props: SurfaceRootProps) {\n const value = useSurfaceRoot<DialogInstance>(props);\n return <DialogContext.Provider value={value}>{props.children}</DialogContext.Provider>;\n}\n\n/** A button that opens the dialog and is the shape it grows from. */\nfunction Trigger({ onClick, children, ...props }: ButtonHTMLAttributes<HTMLButtonElement>) {\n const context = useDialogContext('Trigger');\n return (\n <button\n type=\"button\"\n aria-haspopup=\"dialog\"\n aria-expanded={context.open}\n {...props}\n onClick={(event) => {\n onClick?.(event);\n if (event.defaultPrevented) return;\n context.origin.current = event.currentTarget;\n context.setOpen(!context.open);\n }}\n >\n {children}\n </button>\n );\n}\n\nexport interface DialogContentProps extends Omit<DialogHTMLAttributes<HTMLDialogElement>, 'open'> {\n size?: 'sm' | 'md' | 'lg' | 'xl';\n /** Skip the base class (style it yourself). */\n unstyled?: boolean;\n}\n\n/**\n * Runs a surface engine on a <dialog> and follows the root's open state.\n * Shared with Menu (which passes its own engine).\n */\nexport function useSurfaceEngine<I extends DialogInstance>(\n context: SurfaceContextValue<I>,\n create: (dialog: HTMLDialogElement, options: DialogOptions) => I,\n) {\n const ref = useRef<HTMLDialogElement>(null);\n const setOpen = useLatest(context.setOpen);\n useIsomorphicLayoutEffect(() => {\n const dialog = ref.current;\n if (!dialog) return;\n const created = create(dialog, { ...context.options, triggers: false, onClose: () => setOpen.current(false) });\n context.instance.current = created;\n if (context.open) created.open(context.origin.current ?? undefined);\n return () => {\n created.destroy();\n context.instance.current = null;\n };\n // The engine is rebuilt only when its options change; open state is followed below.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [context.options]);\n useIsomorphicLayoutEffect(() => {\n const instance = context.instance.current;\n if (!instance) return;\n if (context.open && !instance.isOpen) {\n instance.open(context.origin.current ?? undefined);\n context.origin.current = null;\n } else if (!context.open && instance.isOpen) instance.close();\n }, [context.open]);\n return ref;\n}\n\nfunction Content({ size = 'md', unstyled, className, children, ...props }: DialogContentProps) {\n const context = useDialogContext('Content');\n const ref = useSurfaceEngine(context, createDialog);\n const classes = [unstyled ? null : 'mk-dialog', !unstyled && size !== 'md' ? `mk-dialog--${size}` : null, className].filter(Boolean).join(' ');\n return (\n <dialog ref={ref} className={classes || undefined} {...props}>\n {children}\n </dialog>\n );\n}\n\nconst partOf = (name: string) =>\n function Part({ children, ...props }: HTMLAttributes<HTMLElement>) {\n const Tag = (name === 'header' ? 'header' : name === 'footer' ? 'footer' : name === 'title' ? 'h2' : name === 'description' ? 'p' : 'div') as 'div';\n return (\n <Tag data-mk-part={name} {...props}>\n {children}\n </Tag>\n );\n };\n\nfunction Close({ children, label = 'Cerrar', ...props }: ButtonHTMLAttributes<HTMLButtonElement> & { label?: string }) {\n return (\n <button type=\"button\" data-mk-part=\"close\" aria-label={children ? undefined : label} {...props}>\n {children ?? <MkIcon name=\"close\" />}\n </button>\n );\n}\n\nfunction Handle({ children, ...props }: ButtonHTMLAttributes<HTMLButtonElement>) {\n return (\n <button type=\"button\" data-mk-part=\"handle\" {...props}>\n {children ?? <MkIcon name=\"expand\" size={18} />}\n </button>\n );\n}\n\n/**\n * Stepbro's dialog for React:\n * <Dialog.Root><Dialog.Trigger>Crear</Dialog.Trigger><Dialog.Content>\n * <Dialog.Header><Dialog.Title>…</Dialog.Title><Dialog.Close /></Dialog.Header>\n * <Dialog.Body>…</Dialog.Body><Dialog.Footer>…</Dialog.Footer>\n * </Dialog.Content></Dialog.Root>\n */\nexport const Dialog = {\n Root,\n Trigger,\n Content,\n Header: partOf('header'),\n Title: partOf('title'),\n Description: partOf('description'),\n Actions: partOf('actions'),\n Body: partOf('body'),\n Footer: partOf('footer'),\n Close,\n Handle,\n};\n\n/** The dialog instance of the surrounding <Dialog.Root> (open, close, float…). */\nexport function useDialog() {\n const context = useDialogContext('useDialog');\n return { open: context.open, setOpen: context.setOpen, instance: context.instance };\n}\n","import { ICON_PATHS, type IconName } from './icons';\n\n/** The same stroke icons the vanilla components use (aria-hidden). */\nexport function MkIcon({ name, size = 20 }: { name: IconName; size?: number }) {\n return (\n <svg aria-hidden=\"true\" width={size} height={size} viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" strokeWidth={2} strokeLinecap=\"round\" strokeLinejoin=\"round\">\n <path d={ICON_PATHS[name]} />\n </svg>\n );\n}\n","'use client';\n\nimport { createContext, useContext, useRef, type ButtonHTMLAttributes, type DialogHTMLAttributes, type MutableRefObject, type ReactNode } from 'react';\nimport { useLatest } from '../../react/use-recipe';\nimport { useSurfaceEngine, useSurfaceRoot, type SurfaceContextValue, type SurfaceRootProps } from '../dialog/react';\nimport { createMenu, type MenuInstance } from './engine';\n\ninterface MenuContextValue extends SurfaceContextValue<MenuInstance> {\n ticket: boolean;\n onSelect: MutableRefObject<((value: string, item: HTMLElement) => void) | undefined>;\n closeOnSelect: boolean;\n}\n\nconst MenuContext = createContext<MenuContextValue | null>(null);\n\nfunction useMenuContext(part: string) {\n const value = useContext(MenuContext);\n if (!value) throw new Error(`<Menu.${part}> must be inside <Menu.Root>`);\n return value;\n}\n\nexport interface MenuRootProps extends Omit<SurfaceRootProps, 'placement' | 'backdrop' | 'drag' | 'autoResize'> {\n ticket?: boolean;\n onSelect?: (value: string, item: HTMLElement) => void;\n closeOnSelect?: boolean;\n children?: ReactNode;\n}\n\nfunction Root({ onSelect, closeOnSelect = true, ticket = false, children, ...props }: MenuRootProps) {\n const surface = useSurfaceRoot<MenuInstance>(props);\n const select = useLatest(onSelect);\n return <MenuContext.Provider value={{ ...surface, onSelect: select, closeOnSelect, ticket }}>{children}</MenuContext.Provider>;\n}\n\nfunction Trigger({ onClick, children, ...props }: ButtonHTMLAttributes<HTMLButtonElement>) {\n const context = useMenuContext('Trigger');\n return (\n <button\n type=\"button\"\n aria-haspopup=\"menu\"\n aria-expanded={context.open}\n {...props}\n onClick={(event) => {\n onClick?.(event);\n if (event.defaultPrevented) return;\n context.origin.current = event.currentTarget;\n context.setOpen(!context.open);\n }}\n >\n {children}\n </button>\n );\n}\n\nfunction Content({ className, children, ...props }: Omit<DialogHTMLAttributes<HTMLDialogElement>, 'open'>) {\n const context = useMenuContext('Content');\n const closeOnSelect = useRef(context.closeOnSelect);\n closeOnSelect.current = context.closeOnSelect;\n const ref = useSurfaceEngine(context, (dialog, options) =>\n createMenu(dialog, { ...options, ticket: context.ticket, closeOnSelect: closeOnSelect.current, onSelect: (value, item) => context.onSelect.current?.(value, item) }),\n );\n return (\n <dialog ref={ref} className={['mk-dialog mk-menu', className].filter(Boolean).join(' ')} {...props}>\n {children}\n </dialog>\n );\n}\n\nfunction Item({ value, children, ...props }: ButtonHTMLAttributes<HTMLButtonElement> & { value?: string }) {\n return (\n <button type=\"button\" data-mk-item=\"\" data-mk-value={value} {...props}>\n {children}\n </button>\n );\n}\n\nfunction Separator() {\n return <hr data-mk-separator=\"\" />;\n}\n\n/** Stepbro's options menu: <Menu.Root onSelect><Menu.Trigger/><Menu.Content><Menu.Item value/>…</Menu.Content></Menu.Root>. */\nexport const Menu = { Root, Trigger, Content, Item, Separator };\n","'use client';\n\nimport { useRef } from 'react';\nimport { useIsomorphicLayoutEffect } from '../../react/use-recipe';\nimport { createToaster, type ToasterLabels } from './engine';\n\nexport interface ToasterProps {\n labels?: ToasterLabels;\n}\n\n/** Stepbro's toast deck. Mount once near the root; show toasts with `toast()`. */\nexport function Toaster({ labels }: ToasterProps) {\n const ref = useRef<HTMLDivElement>(null);\n const dismiss = labels?.dismiss;\n useIsomorphicLayoutEffect(() => {\n const toaster = createToaster(ref.current, { labels: { dismiss } });\n return () => toaster.destroy();\n }, [dismiss]);\n return <div ref={ref} className=\"mk-toaster\" />;\n}\n\nexport { toast, dismissToast, clearToasts, type ToastOptions, type ToastTone, type ToastAction } from './store';\n","'use client';\n\nimport { useRef, type CSSProperties } from 'react';\nimport { useIsomorphicLayoutEffect } from '../../react/use-recipe';\nimport { createChatBackground, type ChatBackgroundInstance } from './engine';\n\nexport interface ChatBackgroundProps {\n /** 0…1 (the microphone's, see audioEnergy); onboarding's busy state goes to 1.6. */\n energy?: number;\n scale?: number;\n className?: string;\n style?: CSSProperties;\n}\n\n/** Stepbro's chat background. Put it first inside a positioned container. */\nexport function ChatBackground({ energy = 0, scale = 1, className, style }: ChatBackgroundProps) {\n const ref = useRef<HTMLDivElement>(null);\n const instance = useRef<ChatBackgroundInstance | null>(null);\n useIsomorphicLayoutEffect(() => {\n const created = createChatBackground(ref.current, { energy, scale });\n instance.current = created;\n return () => {\n created.destroy();\n instance.current = null;\n };\n // Created once; energy and scale are pushed below.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n useIsomorphicLayoutEffect(() => {\n instance.current?.setEnergy(energy);\n }, [energy]);\n useIsomorphicLayoutEffect(() => {\n instance.current?.setScale(scale);\n }, [scale]);\n return <div ref={ref} className={['mk-chat-background', className].filter(Boolean).join(' ')} style={style} />;\n}\n","'use client';\n\nimport {\n Component,\n createContext,\n useContext,\n useRef,\n type ContextType,\n type HTMLAttributes,\n type MutableRefObject,\n type ReactNode,\n type TextareaHTMLAttributes,\n} from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { MkIcon } from '../icon';\nimport { TIMING } from '../../core/timing';\nimport { PENDING_ID, capturePending, createChat, morphPendingToReply, type ChatInstance, type ChatLabels, type ChatRole } from './engine';\n\ninterface ChatContextValue {\n instance: MutableRefObject<ChatInstance | null>;\n labels: ChatLabels;\n}\n\nconst ChatContext = createContext<ChatContextValue | null>(null);\n\nexport interface ChatRootProps extends HTMLAttributes<HTMLDivElement> {\n onSend?: (text: string) => void;\n animateExisting?: boolean;\n labels?: ChatLabels;\n children?: ReactNode;\n}\n\nfunction Root({ onSend, animateExisting, labels = {}, className, children, ...props }: ChatRootProps) {\n const ref = useRef<HTMLDivElement>(null);\n const instance = useRef<ChatInstance | null>(null);\n const send = useLatest(onSend);\n useIsomorphicLayoutEffect(() => {\n const created = createChat(ref.current, { animateExisting, labels, onSend: (text) => send.current?.(text) });\n instance.current = created;\n return () => {\n created.destroy();\n instance.current = null;\n };\n // The engine is created once; callbacks are read through refs.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n return (\n <ChatContext.Provider value={{ instance, labels }}>\n <div ref={ref} className={['mk-chat', className].filter(Boolean).join(' ')} {...props}>\n {children}\n </div>\n </ChatContext.Provider>\n );\n}\n\nexport interface ChatMessagesProps {\n /** Waiting for an answer: \"Pensando…\" shows after 500 ms and morphs into the next assistant message. */\n pending?: boolean;\n children?: ReactNode;\n}\n\ninterface MessagesState {\n showPending: boolean;\n}\n\ntype Snapshot = ReturnType<typeof capturePending>;\n\n/**\n * The message list. A class component: only getSnapshotBeforeUpdate can measure\n * the placeholder before React replaces it with the answer.\n */\nclass Messages extends Component<ChatMessagesProps, MessagesState> {\n static contextType = ChatContext;\n declare context: ContextType<typeof ChatContext>;\n state: MessagesState = { showPending: false };\n private list: HTMLDivElement | null = null;\n private timer: ReturnType<typeof setTimeout> | undefined;\n\n override componentDidMount() {\n if (this.props.pending) this.wait();\n }\n\n override componentDidUpdate(previous: ChatMessagesProps, _state: MessagesState, snapshot: Snapshot) {\n if (this.props.pending && !previous.pending) this.wait();\n if (!this.props.pending && previous.pending) {\n clearTimeout(this.timer);\n if (this.state.showPending) this.setState({ showPending: false });\n }\n if (!snapshot || !this.list) return;\n const answers = [...this.list.querySelectorAll<HTMLElement>('[data-mk-message][data-mk-role=\"assistant\"]:not([data-mk-pending])')];\n const reply = answers[answers.length - 1];\n if (!reply) return;\n this.context?.instance.current?.adopt(reply);\n morphPendingToReply(snapshot, reply, this.list);\n }\n\n override getSnapshotBeforeUpdate(previous: ChatMessagesProps): Snapshot {\n // The answer arrives as `pending` turns off: measure the placeholder while it is still there.\n if (!previous.pending || this.props.pending || !this.state.showPending || !this.list) return null;\n return capturePending(this.list.querySelector('[data-mk-pending]'));\n }\n\n override componentWillUnmount() {\n clearTimeout(this.timer);\n }\n\n private wait() {\n clearTimeout(this.timer);\n this.timer = setTimeout(() => {\n if (this.props.pending) this.setState({ showPending: true });\n }, TIMING.chat.pendingDelayMs);\n }\n\n override render() {\n const thinking = this.context?.labels.thinking ?? 'Pensando...';\n return (\n <div\n ref={(node) => {\n this.list = node;\n }}\n data-mk-part=\"messages\"\n >\n {this.props.children}\n {this.props.pending && this.state.showPending ? (\n <div data-mk-message=\"\" data-mk-role=\"assistant\" data-mk-pending=\"\" data-flip-id={PENDING_ID}>\n <span className=\"mk-chat__thinking\">\n <MkIcon name=\"sparkle\" size={18} />\n <span>{thinking}</span>\n </span>\n </div>\n ) : null}\n </div>\n );\n }\n}\n\nexport interface ChatMessageProps extends HTMLAttributes<HTMLDivElement> {\n role?: ChatRole;\n children?: ReactNode;\n}\n\nfunction Message({ role = 'assistant', children, ...props }: ChatMessageProps) {\n return (\n <div data-mk-message=\"\" data-mk-role={role} {...props}>\n <div data-mk-text=\"\">{children}</div>\n </div>\n );\n}\n\nexport interface ChatComposerProps extends TextareaHTMLAttributes<HTMLTextAreaElement> {\n /** Extra buttons before send (a microphone…). */\n actions?: ReactNode;\n sendLabel?: string;\n}\n\nfunction Composer({ actions, sendLabel = 'Enviar', placeholder = 'Escribe un mensaje...', ...props }: ChatComposerProps) {\n return (\n <form data-mk-part=\"composer\">\n <textarea data-mk-part=\"input\" rows={1} placeholder={placeholder} aria-label={placeholder} {...props} />\n <div data-mk-part=\"buttons\">\n {actions}\n <button type=\"submit\" data-mk-part=\"send\" aria-label={sendLabel}>\n <MkIcon name=\"send\" size={22} />\n </button>\n </div>\n </form>\n );\n}\n\nfunction Confirm({ children, ...props }: HTMLAttributes<HTMLDivElement>) {\n const ref = useRef<HTMLDivElement>(null);\n const context = useContext(ChatContext);\n useIsomorphicLayoutEffect(() => {\n if (ref.current) context?.instance.current?.confirm(ref.current);\n // Plays once, when the bar appears.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n return (\n <div ref={ref} data-mk-part=\"confirm\" {...props}>\n {children}\n </div>\n );\n}\n\n/**\n * Stepbro's chat: <Chat.Root onSend><ChatBackground /><Chat.Messages pending>{messages.map(m =>\n * <Chat.Message role>)}</Chat.Messages><Chat.Composer /></Chat.Root>.\n */\nexport const Chat = { Root, Messages, Message, Composer, Confirm };\n\n/** The chat engine of the surrounding <Chat.Root> (setRecording, scrollToLatest…). */\nexport function useChat() {\n const context = useContext(ChatContext);\n if (!context) throw new Error('useChat() needs a <Chat.Root> above it');\n return context.instance;\n}\n","'use client';\n\nimport { useRef, type HTMLAttributes, type MouseEvent, type ReactNode } from 'react';\nimport { useIsomorphicLayoutEffect } from '../../react/use-recipe';\nimport { revealShell, type NavStyle } from './engine';\n\nexport interface NavItem {\n value: string;\n label: ReactNode;\n icon?: ReactNode;\n /** Render a link instead of a button. */\n href?: string;\n /** Hidden in the phone bar (Stepbro's hide-on-mobile). */\n hideOnMobile?: boolean;\n}\n\nexport interface NavProps extends Omit<HTMLAttributes<HTMLElement>, 'onSelect'> {\n items: NavItem[];\n /** Value of the current page. */\n active?: string;\n onSelect?: (value: string, event: MouseEvent<HTMLElement>) => void;\n navStyle?: NavStyle;\n accent?: boolean;\n /** Reveal the surrounding .mk-shell from the first button on mount. */\n reveal?: boolean;\n /** The top button (workspace, account…): give it className \"mk-nav__button mk-nav__button--first\". */\n first?: ReactNode;\n /** Buttons at the end (className \"mk-nav__button mk-nav__button--action\"). */\n actions?: ReactNode;\n}\n\n/** Stepbro's navigation. Put it inside a <div className=\"mk-shell\"> next to <main className=\"mk-shell__view\">. */\nexport function Nav({\n items,\n active,\n onSelect,\n navStyle = 'bonita',\n accent = false,\n reveal = false,\n first,\n actions,\n className,\n ...props\n}: NavProps) {\n const ref = useRef<HTMLElement>(null);\n useIsomorphicLayoutEffect(() => {\n if (!reveal || !ref.current) return;\n const handle = revealShell(ref.current);\n return () => handle?.cancel();\n // Only on mount, like Stepbro.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n const classes = ['mk-nav', `mk-nav--${navStyle}`, accent && 'mk-nav--accent', className].filter(Boolean).join(' ');\n return (\n <nav ref={ref} aria-label=\"Principal\" {...props} className={classes}>\n {first}\n <div className=\"mk-nav__buttons\">\n {items.map((item) => {\n const shared = {\n className: 'mk-nav__button',\n 'aria-current': item.value === active ? ('page' as const) : undefined,\n 'data-mk-value': item.value,\n 'data-mk-hide-mobile': item.hideOnMobile ? '' : undefined,\n onClick: (event: MouseEvent<HTMLElement>) => onSelect?.(item.value, event),\n };\n const content = (\n <>\n {item.icon ? (\n <span className=\"mk-nav__icon\" aria-hidden=\"true\">\n {item.icon}\n </span>\n ) : null}\n <span className=\"mk-nav__name\">{item.label}</span>\n </>\n );\n return item.href ? (\n <a key={item.value} href={item.href} {...shared}>\n {content}\n </a>\n ) : (\n <button key={item.value} type=\"button\" {...shared}>\n {content}\n </button>\n );\n })}\n </div>\n {actions ? <div className=\"mk-nav__actions\">{actions}</div> : null}\n </nav>\n );\n}\n","'use client';\n\nimport {\n Children,\n createContext,\n isValidElement,\n useContext,\n useRef,\n type HTMLAttributes,\n type ReactNode,\n} from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createSteps, type StepsInstance } from './engine';\n\ninterface StepsContextValue {\n /** The step shown on the first render: React sets `hidden` once, then the engine owns it. */\n initial: number;\n}\n\nconst StepsContext = createContext<StepsContextValue>({ initial: 0 });\nconst StepIndex = createContext(-1);\n\nexport interface StepsProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange'> {\n /** Current step (0-based). Changing it flows to that step. */\n index?: number;\n onChange?: (index: number, previous: number) => void;\n /** A step is working: the chat background inside speeds up (Stepbro's onBusy). */\n busy?: boolean;\n duration?: number;\n children?: ReactNode;\n}\n\nfunction Root({ index = 0, onChange, busy = false, duration, className, children, ...props }: StepsProps) {\n const ref = useRef<HTMLDivElement>(null);\n const instance = useRef<StepsInstance | null>(null);\n const initial = useRef(index);\n const change = useLatest(onChange);\n useIsomorphicLayoutEffect(() => {\n const created = createSteps(ref.current, { index: initial.current, duration, onChange: (i, previous) => change.current?.(i, previous) });\n instance.current = created;\n return () => {\n created.destroy();\n instance.current = null;\n };\n // Created once; index and busy are pushed below.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n useIsomorphicLayoutEffect(() => {\n void instance.current?.goTo(index);\n }, [index]);\n useIsomorphicLayoutEffect(() => {\n instance.current?.busy(busy);\n }, [busy]);\n let count = 0;\n const numbered = Children.map(children, (child) =>\n isValidElement(child) && child.type === Step ? <StepIndex.Provider value={count++}>{child}</StepIndex.Provider> : child,\n );\n return (\n <StepsContext.Provider value={{ initial: initial.current }}>\n <div ref={ref} className={['mk-steps', className].filter(Boolean).join(' ')} {...props}>\n {numbered}\n </div>\n </StepsContext.Provider>\n );\n}\n\nfunction Step({ children, ...props }: HTMLAttributes<HTMLElement>) {\n const { initial } = useContext(StepsContext);\n const index = useContext(StepIndex);\n return (\n <section data-mk-step=\"\" hidden={index !== initial} {...props}>\n {children}\n </section>\n );\n}\n\n/** The step number; the engine rolls it (React only writes the first value). */\nfunction Counter(props: HTMLAttributes<HTMLSpanElement>) {\n const { initial } = useContext(StepsContext);\n return (\n <span data-mk-counter=\"\" suppressHydrationWarning {...props}>\n {initial + 1}\n </span>\n );\n}\n\n/**\n * Stepbro's onboarding: <Steps index={i} busy={working}><ChatBackground /><Steps.Counter />\n * <Steps.Step><h2 data-mk-flow-item>…</h2></Steps.Step>…</Steps>. Steps must be direct children.\n */\nexport const Steps = Object.assign(Root, { Step, Counter });\n","'use client';\n\nimport { useRef } from 'react';\nimport { useIsomorphicLayoutEffect } from '../../react/use-recipe';\nimport { createCursor, type CursorOptions, type CursorVariant } from './engine';\n\nexport interface CursorProps {\n /** 'chip' (Dousan, default) or 'dot' (Siena). */\n variant?: CursorVariant;\n /** dot: the word when nothing under the pointer gives one. */\n text?: string;\n arrows?: CursorOptions['arrows'];\n /** CSS selector of the zone (dot: default the parent). */\n zone?: string;\n className?: string;\n}\n\n/** Put <Cursor /> once in the layout (chip), or inside the zone (dot). */\nexport function Cursor({ variant = 'chip', text, arrows, zone, className }: CursorProps) {\n const ref = useRef<HTMLDivElement>(null);\n useIsomorphicLayoutEffect(() => {\n const cursor = createCursor(ref.current, { variant, text, arrows, zone: zone ? document.querySelector(zone) : undefined });\n return () => cursor.destroy();\n }, [variant, text, arrows, zone]);\n return <div ref={ref} className={className} />;\n}\n","import type { CSSProperties } from 'react';\n\nexport interface FrostProps {\n /** Which edge the blur grows toward (default bottom). */\n position?: 'bottom' | 'top';\n /** Pin it to the window instead of the positioned parent. */\n fixed?: boolean;\n height?: number | string;\n /** Multiplies the five blurs (default 1). */\n strength?: number;\n className?: string;\n style?: CSSProperties;\n}\n\n/** Dousan's progressive frost: five blur layers. Put it inside a positioned container (or use `fixed`). */\nexport function Frost({ position = 'bottom', fixed = false, height, strength, className, style }: FrostProps) {\n const vars: Record<string, string> = {};\n if (height !== undefined) vars['--mk-frost-height'] = typeof height === 'number' ? `${height}px` : height;\n if (strength !== undefined) vars['--mk-frost-strength'] = String(strength);\n return (\n <div\n aria-hidden=\"true\"\n className={['mk-frost', position === 'top' && 'mk-frost--top', fixed && 'mk-frost--fixed', className].filter(Boolean).join(' ')}\n style={{ ...style, ...vars } as CSSProperties}\n >\n <i />\n <i />\n <i />\n <i />\n <i />\n </div>\n );\n}\n","'use client';\n\nimport { useRef, type HTMLAttributes, type ReactNode } from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createIsland, type IslandInstance, type IslandOptions } from './engine';\n\nexport interface IslandPanel {\n name: string;\n /** Accessible name of its button. */\n label: string;\n /** Button content; the menu's nine dots by default. */\n icon?: ReactNode;\n /** Light button (iyo's cart). */\n light?: boolean;\n content: ReactNode;\n}\n\nexport interface IslandProps extends Omit<HTMLAttributes<HTMLElement>, 'onChange'>, Omit<IslandOptions, 'onChange'> {\n brand?: ReactNode;\n /** The call to action that fades out while a panel is open. */\n cta?: { href: string; label: ReactNode };\n panels: IslandPanel[];\n /** Keep it (and its backdrop) inside a positioned parent instead of fixed over the page. */\n contained?: boolean;\n onChange?: (active: string | null) => void;\n /** Receives the live instance (open, close, toggle, ready). */\n instanceRef?: { current: IslandInstance | null };\n}\n\n/** The nine static dots of iyo's menu button. */\nexport function IslandDots() {\n return (\n <span className=\"mk-island__dots\" aria-hidden=\"true\">\n {Array.from({ length: 9 }, (_, i) => (\n <i key={i} />\n ))}\n </span>\n );\n}\n\n/** iyo.ai's floating navbar. */\nexport function Island({\n brand,\n cta,\n panels,\n contained = false,\n entrance,\n closeOnScroll,\n closeOnNavigate,\n focusOnOpen,\n onChange,\n instanceRef,\n className,\n ...props\n}: IslandProps) {\n const ref = useRef<HTMLElement>(null);\n const change = useLatest(onChange);\n useIsomorphicLayoutEffect(() => {\n const instance = createIsland(ref.current, {\n entrance,\n closeOnScroll,\n closeOnNavigate,\n focusOnOpen,\n onChange: (active) => change.current?.(active),\n });\n if (instanceRef) instanceRef.current = instance;\n return () => {\n instance.destroy();\n if (instanceRef) instanceRef.current = null;\n };\n // The panels' names define the markup the engine reads.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [panels.map((panel) => panel.name).join(), entrance, closeOnScroll, closeOnNavigate, focusOnOpen]);\n const classes = ['mk-island', contained && 'mk-island--contained', className].filter(Boolean).join(' ');\n return (\n <nav ref={ref} aria-label=\"Principal\" {...props} className={classes}>\n <button type=\"button\" className=\"mk-island__backdrop\" data-mk-island-close tabIndex={-1} aria-label=\"Cerrar\" />\n <div className=\"mk-island__shell\">\n <div className=\"mk-island__glass\" aria-hidden=\"true\" />\n <div className=\"mk-island__header\">\n {brand ? <span className=\"mk-island__brand\">{brand}</span> : <span />}\n <div className=\"mk-island__actions\">\n {cta ? (\n <a className=\"mk-island__cta\" href={cta.href}>\n {cta.label}\n </a>\n ) : null}\n {panels.map((panel, i) => (\n <span key={panel.name} style={{ display: 'contents' }}>\n {i > 0 ? <span className=\"mk-island__separator\" aria-hidden=\"true\" /> : null}\n <button\n type=\"button\"\n className={panel.light ? 'mk-island__button mk-island__button--light' : 'mk-island__button'}\n data-mk-island-toggle={panel.name}\n aria-label={panel.label}\n >\n {panel.icon ?? <IslandDots />}\n </button>\n </span>\n ))}\n </div>\n </div>\n <div className=\"mk-island__content\">\n <div>\n {panels.map((panel) => (\n <section key={panel.name} className=\"mk-island__panel\" data-mk-island-panel={panel.name} aria-label={panel.label}>\n {panel.content}\n </section>\n ))}\n </div>\n </div>\n </div>\n </nav>\n );\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,SAAS,WAAW,iBAAiB,cAAmD;AAIjF,IAAM,4BAA4B,OAAO,WAAW,cAAc,kBAAkB;AAMpF,SAAS,UACd,KACA,SACA,SACA,OAAuB,CAAC,GACH;AACrB,QAAM,WAAW,OAAiB,IAAI;AACtC,4BAA0B,MAAM;AAC9B,UAAM,UAAU,QAAQ,IAAI,SAAS,OAAO;AAC5C,aAAS,UAAU;AACnB,WAAO,MAAM;AACX,cAAQ,QAAQ;AAChB,eAAS,UAAU;AAAA,IACrB;AAAA,EAGF,GAAG,IAAI;AACP,SAAO;AACT;AAGO,SAAS,UAAa,OAAU;AACrC,QAAM,MAAM,OAAO,KAAK;AACxB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AAQ,gBAAAA,MAAC,cAAW;AAAA;AAAA,YAC7B;AAAA,eATS,MAAM,IAUjB,CACD;AAAA,WACH;AAAA,SACF;AAAA,MACA,gBAAAA,MAAC,SAAI,WAAU,sBACb,0BAAAA,MAAC,SACE,iBAAO,IAAI,CAAC,UACX,gBAAAA,MAAC,aAAyB,WAAU,oBAAmB,wBAAsB,MAAM,MAAM,cAAY,MAAM,OACxG,gBAAM,WADK,MAAM,IAEpB,CACD,GACH,GACF;AAAA,OACF;AAAA,KACF;AAEJ;","names":["useRef","jsx","useRef","useRef","useState","jsx","useRef","useState","useEffect","useRef","useState","jsx","useState","useRef","useEffect","createContext","useContext","useMemo","useRef","useState","jsx","jsx","useState","useRef","useMemo","createContext","useContext","jsx","createContext","useContext","useRef","jsx","createContext","useContext","Root","Trigger","Content","useRef","useRef","jsx","useRef","useRef","jsx","useRef","Component","createContext","useContext","useRef","jsx","jsxs","createContext","Root","useRef","Component","useContext","useRef","Fragment","jsx","jsxs","useRef","createContext","useContext","useRef","jsx","createContext","Root","useRef","useContext","useRef","jsx","useRef","jsx","jsxs","useRef","jsx","jsxs","useRef"]}
|
|
1
|
+
{"version":3,"sources":["../../src/react/use-recipe.ts","../../src/react/use-spring-cards.ts","../../src/react/use-curved-carousel.ts","../../src/react/use-pile.ts","../../src/react/use-words.ts","../../src/react/use-flow.ts","../../src/react/use-pop.ts","../../src/react/use-fit-text.ts","../../src/react/use-stretch-footer.ts","../../src/react/use-radial-menu.ts","../../src/react/use-tabs.ts","../../src/react/use-counter.ts","../../src/react/use-details.ts","../../src/react/use-reveal.ts","../../src/react/use-reflow.ts","../../src/react/use-slot-text.ts","../../src/react/use-sortable.ts","../../src/react/use-mask-text.ts","../../src/react/use-cascade.ts","../../src/react/use-text-roll.ts","../../src/react/use-letters.ts","../../src/react/use-parallax.ts","../../src/react/use-depth-grid.ts","../../src/react/use-frame-zoom.ts","../../src/react/use-contrast.ts","../../src/react/use-marquee.ts","../../src/react/use-card-dock.ts","../../src/react/use-snap-strip.ts","../../src/react/use-fill-text.ts","../../src/react/use-ticket-menu.ts","../../src/react/use-infinite-reel.ts","../../src/react/use-repel-bento.ts","../../src/react/use-rotator.ts","../../src/react/use-drag-ruler.ts","../../src/react/use-dock-pill.ts","../../src/react/use-liquid-blend.ts","../../src/react/use-matcap.ts","../../src/react/use-shader-grain.ts","../../src/react/use-shader-blur.ts","../../src/react/use-particle-hero.ts","../../src/react/theme-provider.tsx","../../src/components/theme-picker/react.tsx","../../src/react/slot-text.tsx","../../src/react/animated-number.tsx","../../src/react/flip-group.tsx","../../src/components/dialog/react.tsx","../../src/components/icon.tsx","../../src/components/menu/react.tsx","../../src/components/toast/react.tsx","../../src/components/chat-background/react.tsx","../../src/components/chat/react.tsx","../../src/components/nav/react.tsx","../../src/components/steps/react.tsx","../../src/components/cursor/react.tsx","../../src/react/frost.tsx","../../src/components/island/react.tsx","../../src/components/quantity/react.tsx","../../src/components/pagination/react.tsx","../../src/components/hover-card/react.tsx","../../src/components/input-otp/react.tsx","../../src/react/use-joined-cta.ts","../../src/react/use-image-zoom.ts","../../src/react/use-font-cycle.ts","../../src/react/use-thumbnail-nav.ts","../../src/react/use-action-button.ts","../../src/react/use-film-hero.ts","../../src/react/use-editorial-reveal.ts","../../src/react/use-studio-dock.ts","../../src/react/use-trailer.ts","../../src/components/studio-dock/react.tsx","../../src/components/trailer/react.tsx","../../src/components/calendar/react.tsx","../../src/components/slot-picker/react.tsx","../../src/react/use-weight-hover.ts","../../src/react/use-sticker.ts","../../src/react/use-scroll-dock.ts","../../src/react/use-local-clock.ts"],"sourcesContent":["'use client';\n\nimport { useEffect, useLayoutEffect, useRef, type DependencyList, type RefObject } from 'react';\nimport type { Instance } from '../core/types';\n\n/** useLayoutEffect in the browser (no flash), useEffect during SSR (no warning). */\nexport const useIsomorphicLayoutEffect = typeof window !== 'undefined' ? useLayoutEffect : useEffect;\n\n/**\n * Create a recipe on `ref.current` after mount and destroy it on unmount or when\n * `deps` change. Returns a ref holding the live instance (controls like `next()`).\n */\nexport function useRecipe<I extends Instance, O>(\n ref: RefObject<HTMLElement | null>,\n factory: (el: HTMLElement | null, options?: O) => I,\n options?: O,\n deps: DependencyList = [],\n): RefObject<I | null> {\n const instance = useRef<I | null>(null);\n useIsomorphicLayoutEffect(() => {\n const created = factory(ref.current, options);\n instance.current = created;\n return () => {\n created.destroy();\n instance.current = null;\n };\n // Options are read once per creation; pass `deps` to recreate when they change.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, deps);\n return instance;\n}\n\n/** Keep the latest callback in a ref so recipes do not restart on every render. */\nexport function useLatest<T>(value: T) {\n const ref = useRef(value);\n ref.current = value;\n return ref;\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createSpringCards, type SpringCardsOptions } from '../recipes/spring-cards/create-spring-cards';\n\nexport const useSpringCards = (ref: RefObject<HTMLElement | null>, options?: SpringCardsOptions, deps?: DependencyList) =>\n useRecipe(ref, createSpringCards, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createCurvedCarousel, type CurvedCarouselOptions } from '../recipes/curved-carousel/create-curved-carousel';\n\nexport function useCurvedCarousel(ref: RefObject<HTMLElement | null>, options: CurvedCarouselOptions = {}, deps?: DependencyList) {\n const onSelect = useLatest(options.onSelect);\n return useRecipe(ref, createCurvedCarousel, { ...options, onSelect: (index, slide) => onSelect.current?.(index, slide) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createPile, type PileOptions } from '../recipes/pile/create-pile';\n\nexport const usePile = (ref: RefObject<HTMLElement | null>, options?: PileOptions, deps?: DependencyList) =>\n useRecipe(ref, createPile, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createWords, type WordsOptions } from '../recipes/words/create-words';\n\nexport const useWords = (ref: RefObject<HTMLElement | null>, options?: WordsOptions, deps?: DependencyList) =>\n useRecipe(ref, createWords, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createFlow, type FlowOptions } from '../recipes/flow/create-flow';\n\nexport const useFlow = (ref: RefObject<HTMLElement | null>, options?: FlowOptions, deps?: DependencyList) =>\n useRecipe(ref, createFlow, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createPop, type PopOptions } from '../recipes/pop/create-pop';\n\nexport const usePop = (ref: RefObject<HTMLElement | null>, options?: PopOptions, deps?: DependencyList) =>\n useRecipe(ref, createPop, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createFitText, type FitTextOptions } from '../recipes/fit-text/create-fit-text';\n\nexport const useFitText = (ref: RefObject<HTMLElement | null>, options?: FitTextOptions, deps?: DependencyList) =>\n useRecipe(ref, createFitText, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createStretchFooter, type StretchFooterOptions } from '../recipes/stretch-footer/create-stretch-footer';\n\nexport interface UseStretchFooterOptions extends Omit<StretchFooterOptions, 'phantom' | 'title'> {\n phantomRef?: RefObject<HTMLElement | null>;\n titleRef?: RefObject<HTMLElement | null>;\n}\n\nexport function useStretchFooter(ref: RefObject<HTMLElement | null>, options: UseStretchFooterOptions = {}, deps?: DependencyList) {\n const { phantomRef, titleRef, ...rest } = options;\n return useRecipe(\n ref,\n (el) => createStretchFooter(el, { ...rest, phantom: phantomRef?.current ?? undefined, title: titleRef?.current ?? undefined }),\n undefined,\n deps,\n );\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createRadialMenu, type RadialMenuOptions } from '../recipes/radial-menu/create-radial-menu';\n\nexport function useRadialMenu(ref: RefObject<HTMLElement | null>, options: RadialMenuOptions = {}, deps?: DependencyList) {\n const onToggle = useLatest(options.onToggle);\n return useRecipe(ref, createRadialMenu, { ...options, onToggle: (open) => onToggle.current?.(open) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createTabs, type TabsOptions } from '../recipes/tabs/create-tabs';\n\nexport function useTabs(ref: RefObject<HTMLElement | null>, options: TabsOptions = {}, deps?: DependencyList) {\n const onSelect = useLatest(options.onSelect);\n return useRecipe(ref, createTabs, { ...options, onSelect: (index, tab) => onSelect.current?.(index, tab) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createCounter, type CounterOptions } from '../recipes/counter/create-counter';\n\nexport const useCounter = (ref: RefObject<HTMLElement | null>, options?: CounterOptions, deps?: DependencyList) =>\n useRecipe(ref, createCounter, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createDetails } from '../recipes/details/create-details';\n\nexport const useDetails = (ref: RefObject<HTMLElement | null>, deps?: DependencyList) => useRecipe(ref, createDetails, undefined, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createReveal, type RevealRecipeOptions } from '../recipes/reveal/create-reveal';\n\nexport const useReveal = (ref: RefObject<HTMLElement | null>, options?: RevealRecipeOptions, deps?: DependencyList) =>\n useRecipe(ref, createReveal, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createReflow, type ReflowOptions } from '../recipes/reflow/create-reflow';\n\n/** Call `.current.capture()` before the state change and `.current.play()` in a layout effect after it. */\nexport const useReflow = (ref: RefObject<HTMLElement | null>, options?: ReflowOptions, deps?: DependencyList) =>\n useRecipe(ref, createReflow, options, deps);\n","'use client';\n\nimport type { RefObject } from 'react';\nimport { useIsomorphicLayoutEffect, useRecipe } from './use-recipe';\nimport { createSlotText, type SlotTextOptions } from '../recipes/slot-text/create-slot-text';\n\n/**\n * Rolls `text` into `ref` whenever it changes. The element must render no\n * children of its own: the recipe writes the letters (see `<SlotText>`).\n */\nexport function useSlotText(ref: RefObject<HTMLElement | null>, text: string, options: Omit<SlotTextOptions, 'text'> = {}) {\n const instance = useRecipe(ref, createSlotText, { ...options, text });\n useIsomorphicLayoutEffect(() => {\n instance.current?.set(text);\n }, [text]);\n return instance;\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createSortable, type SortableOptions } from '../recipes/sortable/create-sortable';\n\n/**\n * Drag to reorder a list React renders: answer `onReorder` by updating your state\n * (React moves the DOM; the engine waits for it and lands the item). `mutate` is off.\n */\nexport function useSortable(ref: RefObject<HTMLElement | null>, options: SortableOptions = {}, deps?: DependencyList) {\n const onReorder = useLatest(options.onReorder);\n return useRecipe(ref, createSortable, { mutate: false, ...options, onReorder: (detail) => onReorder.current?.(detail) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createMaskText, type MaskTextOptions } from '../recipes/mask-text/create-mask-text';\n\n/** Masked lines / words / letters rising into view. */\nexport const useMaskText = (ref: RefObject<HTMLElement | null>, options?: MaskTextOptions, deps?: DependencyList) =>\n useRecipe(ref, createMaskText, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createCascade, type CascadeOptions } from '../recipes/cascade/create-cascade';\n\n/** reveal group: rules, fades and rises one after another. */\nexport const useCascade = (ref: RefObject<HTMLElement | null>, options?: CascadeOptions, deps?: DependencyList) =>\n useRecipe(ref, createCascade, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createTextRoll, type TextRollOptions } from '../recipes/text-roll/create-text-roll';\n\n/** slot title. `.current.play()` spins it. */\nexport const useTextRoll = (ref: RefObject<HTMLElement | null>, options?: TextRollOptions, deps?: DependencyList) =>\n useRecipe(ref, createTextRoll, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createLetters, type LettersOptions } from '../recipes/letters/create-letters';\n\n/** hero letters (scale on hover or pastel blink). */\nexport const useLetters = (ref: RefObject<HTMLElement | null>, options?: LettersOptions, deps?: DependencyList) =>\n useRecipe(ref, createLetters, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createParallax, type ParallaxOptions } from '../recipes/parallax/create-parallax';\n\n/** photo parallax inside its frame. */\nexport const useParallax = (ref: RefObject<HTMLElement | null>, options?: ParallaxOptions, deps?: DependencyList) =>\n useRecipe(ref, createParallax, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createDepthGrid, type DepthGridOptions } from '../recipes/depth-grid/create-depth-grid';\n\n/** grid gathering from depth as it scrolls. */\nexport const useDepthGrid = (ref: RefObject<HTMLElement | null>, options?: DepthGridOptions, deps?: DependencyList) =>\n useRecipe(ref, createDepthGrid, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createFrameZoom, type FrameZoomOptions } from '../recipes/frame-zoom/create-frame-zoom';\n\n/** video mask: frame and picture scale in opposite directions. */\nexport const useFrameZoom = (ref: RefObject<HTMLElement | null>, options?: FrameZoomOptions, deps?: DependencyList) =>\n useRecipe(ref, createFrameZoom, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createContrast, type ContrastOptions } from '../recipes/contrast/create-contrast';\n\n/** header contrast from the section under it. */\nexport const useContrast = (ref: RefObject<HTMLElement | null>, options?: ContrastOptions, deps?: DependencyList) =>\n useRecipe(ref, createContrast, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createMarquee, type MarqueeOptions } from '../recipes/marquee/create-marquee';\n\n/** seamless marquee. */\nexport const useMarquee = (ref: RefObject<HTMLElement | null>, options?: MarqueeOptions, deps?: DependencyList) =>\n useRecipe(ref, createMarquee, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createCardDock, type CardDockOptions } from '../recipes/card-dock/create-card-dock';\n\n/** product dock (stacked glass cards that spread on hover). */\nexport const useCardDock = (ref: RefObject<HTMLElement | null>, options?: CardDockOptions, deps?: DependencyList) =>\n useRecipe(ref, createCardDock, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createSnapStrip, type SnapStripOptions } from '../recipes/snap-strip/create-snap-strip';\n\n/** phone cards: an autoplaying scroll-snap strip. */\nexport const useSnapStrip = (ref: RefObject<HTMLElement | null>, options?: SnapStripOptions, deps?: DependencyList) =>\n useRecipe(ref, createSnapStrip, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createFillText, type FillTextOptions } from '../recipes/fill-text/create-fill-text';\n\n/** fill-text: letters fill in as the text scrolls up. */\nexport const useFillText = (ref: RefObject<HTMLElement | null>, options?: FillTextOptions, deps?: DependencyList) =>\n useRecipe(ref, createFillText, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createTicketMenu, type TicketMenuOptions } from '../recipes/ticket-menu/create-ticket-menu';\n\nexport function useTicketMenu(ref: RefObject<HTMLElement | null>, options: TicketMenuOptions = {}, deps?: DependencyList) {\n const latest = useLatest(options);\n return useRecipe(ref, createTicketMenu, {\n ...options,\n onSelect: (value, item) => latest.current.onSelect?.(value, item),\n onOpen: () => latest.current.onOpen?.(),\n onClose: () => latest.current.onClose?.(),\n }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createInfiniteReel, type InfiniteReelOptions } from '../recipes/infinite-reel/create-infinite-reel';\n\nexport const useInfiniteReel = (ref: RefObject<HTMLElement | null>, options?: InfiniteReelOptions, deps?: DependencyList) =>\n useRecipe(ref, createInfiniteReel, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createRepelBento, type RepelBentoOptions } from '../recipes/repel-bento/create-repel-bento';\n\nexport const useRepelBento = (ref: RefObject<HTMLElement | null>, options?: RepelBentoOptions, deps?: DependencyList) =>\n useRecipe(ref, createRepelBento, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createRotator, type RotatorOptions } from '../recipes/rotator/create-rotator';\n\nexport function useRotator(ref: RefObject<HTMLElement | null>, options: RotatorOptions = {}, deps?: DependencyList) {\n const callback = useLatest(options.onChange);\n return useRecipe(ref, createRotator, { ...options, onChange: (index) => callback.current?.(index) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createDragRuler, type DragRulerOptions } from '../recipes/drag-ruler/create-drag-ruler';\n\nexport function useDragRuler(ref: RefObject<HTMLElement | null>, options: DragRulerOptions = {}, deps?: DependencyList) {\n const callback = useLatest(options.onChange);\n return useRecipe(ref, createDragRuler, { ...options, onChange: (value) => callback.current?.(value) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createDockPill, type DockPillOptions } from '../recipes/dock-pill/create-dock-pill';\n\nexport function useDockPill(ref: RefObject<HTMLElement | null>, options: DockPillOptions = {}, deps?: DependencyList) {\n const callback = useLatest(options.onSelect);\n return useRecipe(ref, createDockPill, { ...options, onSelect: (index, item) => callback.current?.(index, item) }, deps);\n}\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createLiquidBlend, type LiquidBlendOptions } from '../gl/liquid-blend/create-liquid-blend';\n\nexport const useLiquidBlend = (ref: RefObject<HTMLElement | null>, options?: LiquidBlendOptions, deps?: DependencyList) =>\n useRecipe(ref, createLiquidBlend, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createMatcap, type MatcapOptions } from '../gl/matcap/create-matcap';\n\nexport const useMatcap = (ref: RefObject<HTMLElement | null>, options?: MatcapOptions, deps?: DependencyList) =>\n useRecipe(ref, createMatcap, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createShaderGrain, type ShaderGrainOptions } from '../gl/shader-grain/create-shader-grain';\n\nexport const useShaderGrain = (ref: RefObject<HTMLElement | null>, options?: ShaderGrainOptions, deps?: DependencyList) =>\n useRecipe(ref, createShaderGrain, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createShaderBlur, type ShaderBlurOptions } from '../gl/shader-blur/create-shader-blur';\n\nexport const useShaderBlur = (ref: RefObject<HTMLElement | null>, options?: ShaderBlurOptions, deps?: DependencyList) =>\n useRecipe(ref, createShaderBlur, options, deps);\n","'use client';\n\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createParticleHero, type ParticleHeroOptions } from '../gl/particle-hero/create-particle-hero';\n\n/** particle hero (WebGL2, Canvas2D fallback). The canvas joins the ref's element. */\nexport const useParticleHero = (ref: RefObject<HTMLElement | null>, options?: ParticleHeroOptions, deps?: DependencyList) =>\n useRecipe(ref, createParticleHero, options, deps);\n","'use client';\n\nimport { createContext, useContext, useMemo, useState, type ReactNode } from 'react';\nimport { useIsomorphicLayoutEffect } from './use-recipe';\nimport { DEFAULT_THEME } from '../theme/presets';\nimport { THEME_EVENT, initTheme, setMode, setTheme, type InitThemeOptions, type ThemeMode, type ThemeState } from '../theme/theme';\n\nexport interface ThemeContextValue extends ThemeState {\n setTheme: typeof setTheme;\n setMode: typeof setMode;\n}\n\nconst ThemeContext = createContext<ThemeContextValue | null>(null);\n\nexport interface ThemeProviderProps {\n children?: ReactNode;\n defaultTheme?: InitThemeOptions['default'];\n mode?: ThemeMode;\n storageKey?: string;\n}\n\n/**\n * Applies the stored (or default) theme on mount and shares it. Add\n * MK_THEME_HEAD_SCRIPT to <head> as well, so the first paint already has it.\n */\nexport function ThemeProvider({ children, defaultTheme, mode, storageKey }: ThemeProviderProps) {\n const [state, setState] = useState<ThemeState>(() => ({ id: defaultTheme ?? DEFAULT_THEME, mode: mode ?? 'system', resolved: 'light' }));\n useIsomorphicLayoutEffect(() => {\n const onChange = (event: Event) => setState((event as CustomEvent<ThemeState>).detail);\n document.addEventListener(THEME_EVENT, onChange);\n setState(initTheme({ default: defaultTheme, mode, storageKey }));\n return () => document.removeEventListener(THEME_EVENT, onChange);\n }, [defaultTheme, mode, storageKey]);\n const value = useMemo(() => ({ ...state, setTheme, setMode }), [state]);\n return <ThemeContext.Provider value={value}>{children}</ThemeContext.Provider>;\n}\n\nexport function useTheme(): ThemeContextValue {\n const value = useContext(ThemeContext);\n if (!value) throw new Error('useTheme() needs a <ThemeProvider> above it');\n return value;\n}\n","'use client';\n\nimport { useRef, type CSSProperties } from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createThemePicker, type ThemePickerOptions } from './engine';\n\nexport interface ThemePickerProps extends ThemePickerOptions {\n className?: string;\n style?: CSSProperties;\n /** Skip the base class (style it yourself). */\n unstyled?: boolean;\n}\n\n/** theme picker. Wrap the app in <ThemeProvider> to read the choice. */\nexport function ThemePicker({ className, style, unstyled, themes, showHidden, labels, onChange }: ThemePickerProps) {\n const ref = useRef<HTMLDivElement>(null);\n const change = useLatest(onChange);\n const themeKey = themes?.join(',');\n useIsomorphicLayoutEffect(() => {\n const picker = createThemePicker(ref.current, {\n themes: themeKey ? themeKey.split(',') : undefined,\n showHidden,\n labels,\n onChange: (id) => change.current?.(id),\n });\n return () => picker.destroy();\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [themeKey, showHidden, labels?.group]);\n const classes = [unstyled ? null : 'mk-theme-picker', className].filter(Boolean).join(' ');\n return <div ref={ref} className={classes || undefined} style={style} />;\n}\n","'use client';\n\nimport { useRef, useState } from 'react';\nimport { useIsomorphicLayoutEffect } from './use-recipe';\nimport { createSlotText, type SlotTextInstance, type SlotTextOptions } from '../recipes/slot-text/create-slot-text';\n\nexport interface SlotTextProps extends Omit<SlotTextOptions, 'text' | 'accessibleCopy'> {\n text: string;\n className?: string;\n}\n\nconst escapeHtml = (text: string) => text.replace(/[&<>\"']/g, (c) => `&#${c.charCodeAt(0)};`);\n\n/**\n * Text whose letters roll when it changes. The server\n * renders the text itself; React never reconciles the letters (they belong to\n * the recipe), and screen readers read the plain copy.\n */\nexport function SlotText({ text, className, direction, duration, stagger, exitOffset, colorFade, maxTilt }: SlotTextProps) {\n const ref = useRef<HTMLSpanElement>(null);\n const instance = useRef<SlotTextInstance | null>(null);\n const [initial] = useState(text);\n // A stable object: React 19 re-applies innerHTML when this prop changes identity.\n const [html] = useState(() => ({ __html: escapeHtml(text) }));\n useIsomorphicLayoutEffect(() => {\n const created = createSlotText(ref.current, { direction, duration, stagger, exitOffset, colorFade, maxTilt, text: initial, accessibleCopy: false });\n instance.current = created;\n return () => {\n created.destroy();\n instance.current = null;\n };\n // The recipe is created once; the text is pushed below.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n useIsomorphicLayoutEffect(() => {\n instance.current?.set(text);\n }, [text]);\n return (\n <span className={className}>\n <span className=\"mk-sr-only\">{text}</span>\n <span ref={ref} aria-hidden=\"true\" dangerouslySetInnerHTML={html} />\n </span>\n );\n}\n","'use client';\n\nimport { useEffect, useRef, useState } from 'react';\nimport { tweenNumber } from '../motion/count';\n\nexport interface AnimatedNumberProps {\n value: number;\n /** How the shown value is written. Default: whole numbers. */\n format?: (shown: number) => string;\n /** Seconds. Default 0.6; prices use 0.7. */\n duration?: number;\n}\n\nconst whole = (shown: number) => String(Math.round(shown));\n\n/** A number that counts to each new value from the one shown. */\nexport function AnimatedNumber({ value, format = whole, duration }: AnimatedNumberProps) {\n const [shown, setShown] = useState(value);\n const current = useRef(value);\n useEffect(() => {\n const tween = tweenNumber(current.current, value, (next) => {\n current.current = next;\n setShown(next);\n }, { duration });\n return () => {\n tween?.kill();\n };\n }, [value, duration]);\n return <>{format(shown)}</>;\n}\n","'use client';\n\nimport { Component, type ReactNode, type RefObject } from 'react';\nimport { captureLayout, reflowLayout, type CapturedLayout } from '../motion/layout';\n\nexport interface FlipGroupProps {\n /** The list element. */\n root: RefObject<HTMLElement | null>;\n /** Items inside it; they need a stable `data-flip-id`. */\n selector?: string;\n /** Changes whenever the layout should animate (order, filter, grouping): e.g. the ids joined. */\n signature: string;\n children?: ReactNode;\n}\n\n/**\n * Plays layout reflow when `signature` changes: the layout is\n * measured just before React commits and the items travel from there. A class\n * component, because only `getSnapshotBeforeUpdate` reads the DOM before the commit.\n */\nexport class FlipGroup extends Component<FlipGroupProps> {\n private flip: ReturnType<typeof reflowLayout> = null;\n\n override getSnapshotBeforeUpdate(previous: Readonly<FlipGroupProps>): CapturedLayout | null {\n const node = this.props.root.current;\n if (previous.signature === this.props.signature || !node) return null;\n return captureLayout(node, this.props.selector ?? '[data-flip-id]');\n }\n\n override componentDidUpdate(_previous: unknown, _state: unknown, before: CapturedLayout | null) {\n const node = this.props.root.current;\n if (!before || !node) return;\n this.flip?.kill();\n this.flip = reflowLayout(node, this.props.selector ?? '[data-flip-id]', before);\n }\n\n override componentWillUnmount() {\n this.flip?.kill();\n }\n\n override render() {\n return this.props.children;\n }\n}\n","'use client';\n\nimport {\n createContext,\n useCallback,\n useContext,\n useMemo,\n useRef,\n useState,\n type ButtonHTMLAttributes,\n type DialogHTMLAttributes,\n type HTMLAttributes,\n type MutableRefObject,\n type ReactNode,\n} from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { MkIcon } from '../icon';\nimport { createDialog, type DialogInstance, type DialogOptions } from './engine';\n\nexport { MkIcon };\n\nexport type SurfaceOptions = Omit<DialogOptions, 'onOpen' | 'onClose' | 'triggers'>;\n\nexport interface SurfaceContextValue<I> {\n open: boolean;\n setOpen: (open: boolean) => void;\n /** The control the next open grows from (set by the Trigger). */\n origin: MutableRefObject<HTMLElement | null>;\n instance: MutableRefObject<I | null>;\n options: SurfaceOptions;\n}\n\nexport interface SurfaceRootProps extends SurfaceOptions {\n open?: boolean;\n defaultOpen?: boolean;\n onOpenChange?: (open: boolean) => void;\n children?: ReactNode;\n}\n\n/** Open state (controlled or not) shared by a surface's parts. Used by Dialog and Menu. */\nexport function useSurfaceRoot<I>({ open: controlled, defaultOpen = false, onOpenChange, children: _children, ...options }: SurfaceRootProps): SurfaceContextValue<I> {\n const [uncontrolled, setUncontrolled] = useState(defaultOpen);\n const open = controlled ?? uncontrolled;\n const current = useLatest(open);\n const change = useLatest(onOpenChange);\n const isControlled = controlled !== undefined;\n const setOpen = useCallback(\n (next: boolean) => {\n if (next === current.current) return;\n current.current = next;\n if (!isControlled) setUncontrolled(next);\n change.current?.(next);\n },\n [isControlled, current, change],\n );\n const origin = useRef<HTMLElement | null>(null);\n const instance = useRef<I | null>(null);\n const optionKey = JSON.stringify(options);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n const stable = useMemo(() => options, [optionKey]);\n return useMemo(() => ({ open, setOpen, origin, instance, options: stable }), [open, setOpen, stable]);\n}\n\nconst DialogContext = createContext<SurfaceContextValue<DialogInstance> | null>(null);\n\nfunction useDialogContext(part: string) {\n const value = useContext(DialogContext);\n if (!value) throw new Error(`<Dialog.${part}> must be inside <Dialog.Root>`);\n return value;\n}\n\nfunction Root(props: SurfaceRootProps) {\n const value = useSurfaceRoot<DialogInstance>(props);\n return <DialogContext.Provider value={value}>{props.children}</DialogContext.Provider>;\n}\n\n/** A button that opens the dialog and is the shape it grows from. */\nfunction Trigger({ onClick, children, ...props }: ButtonHTMLAttributes<HTMLButtonElement>) {\n const context = useDialogContext('Trigger');\n return (\n <button\n type=\"button\"\n aria-haspopup=\"dialog\"\n aria-expanded={context.open}\n {...props}\n onClick={(event) => {\n onClick?.(event);\n if (event.defaultPrevented) return;\n context.origin.current = event.currentTarget;\n context.setOpen(!context.open);\n }}\n >\n {children}\n </button>\n );\n}\n\nexport interface DialogContentProps extends Omit<DialogHTMLAttributes<HTMLDialogElement>, 'open'> {\n size?: 'sm' | 'md' | 'lg' | 'xl';\n /** Skip the base class (style it yourself). */\n unstyled?: boolean;\n}\n\n/**\n * Runs a surface engine on a <dialog> and follows the root's open state.\n * Shared with Menu (which passes its own engine).\n */\nexport function useSurfaceEngine<I extends DialogInstance>(\n context: SurfaceContextValue<I>,\n create: (dialog: HTMLDialogElement, options: DialogOptions) => I,\n) {\n const ref = useRef<HTMLDialogElement>(null);\n const setOpen = useLatest(context.setOpen);\n useIsomorphicLayoutEffect(() => {\n const dialog = ref.current;\n if (!dialog) return;\n const created = create(dialog, { ...context.options, triggers: false, onClose: () => setOpen.current(false) });\n context.instance.current = created;\n if (context.open) created.open(context.origin.current ?? undefined);\n return () => {\n created.destroy();\n context.instance.current = null;\n };\n // The engine is rebuilt only when its options change; open state is followed below.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [context.options]);\n useIsomorphicLayoutEffect(() => {\n const instance = context.instance.current;\n if (!instance) return;\n if (context.open && !instance.isOpen) {\n instance.open(context.origin.current ?? undefined);\n context.origin.current = null;\n } else if (!context.open && instance.isOpen) instance.close();\n }, [context.open]);\n return ref;\n}\n\nfunction Content({ size = 'md', unstyled, className, children, ...props }: DialogContentProps) {\n const context = useDialogContext('Content');\n const ref = useSurfaceEngine(context, createDialog);\n const classes = [unstyled ? null : 'mk-dialog', !unstyled && size !== 'md' ? `mk-dialog--${size}` : null, className].filter(Boolean).join(' ');\n return (\n <dialog ref={ref} className={classes || undefined} {...props}>\n {children}\n </dialog>\n );\n}\n\nconst partOf = (name: string) =>\n function Part({ children, ...props }: HTMLAttributes<HTMLElement>) {\n const Tag = (name === 'header' ? 'header' : name === 'footer' ? 'footer' : name === 'title' ? 'h2' : name === 'description' ? 'p' : 'div') as 'div';\n return (\n <Tag data-mk-part={name} {...props}>\n {children}\n </Tag>\n );\n };\n\nfunction Close({ children, label = 'Cerrar', ...props }: ButtonHTMLAttributes<HTMLButtonElement> & { label?: string }) {\n return (\n <button type=\"button\" data-mk-part=\"close\" aria-label={children ? undefined : label} {...props}>\n {children ?? <MkIcon name=\"close\" />}\n </button>\n );\n}\n\nfunction Handle({ children, ...props }: ButtonHTMLAttributes<HTMLButtonElement>) {\n return (\n <button type=\"button\" data-mk-part=\"handle\" {...props}>\n {children ?? <MkIcon name=\"expand\" size={18} />}\n </button>\n );\n}\n\n/**\n * dialog for React:\n * <Dialog.Root><Dialog.Trigger>Crear</Dialog.Trigger><Dialog.Content>\n * <Dialog.Header><Dialog.Title>…</Dialog.Title><Dialog.Close /></Dialog.Header>\n * <Dialog.Body>…</Dialog.Body><Dialog.Footer>…</Dialog.Footer>\n * </Dialog.Content></Dialog.Root>\n */\nexport const Dialog = {\n Root,\n Trigger,\n Content,\n Header: partOf('header'),\n Title: partOf('title'),\n Description: partOf('description'),\n Actions: partOf('actions'),\n Body: partOf('body'),\n Footer: partOf('footer'),\n Close,\n Handle,\n};\n\n/** The dialog instance of the surrounding <Dialog.Root> (open, close, float…). */\nexport function useDialog() {\n const context = useDialogContext('useDialog');\n return { open: context.open, setOpen: context.setOpen, instance: context.instance };\n}\n","import { ICON_PATHS, type IconName } from './icons';\n\n/** The same stroke icons the vanilla components use (aria-hidden). */\nexport function MkIcon({ name, size = 20 }: { name: IconName; size?: number }) {\n return (\n <svg aria-hidden=\"true\" width={size} height={size} viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" strokeWidth={2} strokeLinecap=\"round\" strokeLinejoin=\"round\">\n <path d={ICON_PATHS[name]} />\n </svg>\n );\n}\n","'use client';\n\nimport { createContext, useContext, useRef, type ButtonHTMLAttributes, type DialogHTMLAttributes, type MutableRefObject, type ReactNode } from 'react';\nimport { useLatest } from '../../react/use-recipe';\nimport { useSurfaceEngine, useSurfaceRoot, type SurfaceContextValue, type SurfaceRootProps } from '../dialog/react';\nimport { createMenu, type MenuInstance } from './engine';\n\ninterface MenuContextValue extends SurfaceContextValue<MenuInstance> {\n ticket: boolean;\n onSelect: MutableRefObject<((value: string, item: HTMLElement) => void) | undefined>;\n closeOnSelect: boolean;\n}\n\nconst MenuContext = createContext<MenuContextValue | null>(null);\n\nfunction useMenuContext(part: string) {\n const value = useContext(MenuContext);\n if (!value) throw new Error(`<Menu.${part}> must be inside <Menu.Root>`);\n return value;\n}\n\nexport interface MenuRootProps extends Omit<SurfaceRootProps, 'placement' | 'backdrop' | 'drag' | 'autoResize'> {\n ticket?: boolean;\n onSelect?: (value: string, item: HTMLElement) => void;\n closeOnSelect?: boolean;\n children?: ReactNode;\n}\n\nfunction Root({ onSelect, closeOnSelect = true, ticket = false, children, ...props }: MenuRootProps) {\n const surface = useSurfaceRoot<MenuInstance>(props);\n const select = useLatest(onSelect);\n return <MenuContext.Provider value={{ ...surface, onSelect: select, closeOnSelect, ticket }}>{children}</MenuContext.Provider>;\n}\n\nfunction Trigger({ onClick, children, ...props }: ButtonHTMLAttributes<HTMLButtonElement>) {\n const context = useMenuContext('Trigger');\n return (\n <button\n type=\"button\"\n aria-haspopup=\"menu\"\n aria-expanded={context.open}\n {...props}\n onClick={(event) => {\n onClick?.(event);\n if (event.defaultPrevented) return;\n context.origin.current = event.currentTarget;\n context.setOpen(!context.open);\n }}\n >\n {children}\n </button>\n );\n}\n\nfunction Content({ className, children, ...props }: Omit<DialogHTMLAttributes<HTMLDialogElement>, 'open'>) {\n const context = useMenuContext('Content');\n const closeOnSelect = useRef(context.closeOnSelect);\n closeOnSelect.current = context.closeOnSelect;\n const ref = useSurfaceEngine(context, (dialog, options) =>\n createMenu(dialog, { ...options, ticket: context.ticket, closeOnSelect: closeOnSelect.current, onSelect: (value, item) => context.onSelect.current?.(value, item) }),\n );\n return (\n <dialog ref={ref} className={['mk-dialog mk-menu', className].filter(Boolean).join(' ')} {...props}>\n {children}\n </dialog>\n );\n}\n\nfunction Item({ value, children, ...props }: ButtonHTMLAttributes<HTMLButtonElement> & { value?: string }) {\n return (\n <button type=\"button\" data-mk-item=\"\" data-mk-value={value} {...props}>\n {children}\n </button>\n );\n}\n\nfunction Separator() {\n return <hr data-mk-separator=\"\" />;\n}\n\n/** options menu: <Menu.Root onSelect><Menu.Trigger/><Menu.Content><Menu.Item value/>…</Menu.Content></Menu.Root>. */\nexport const Menu = { Root, Trigger, Content, Item, Separator };\n","'use client';\n\nimport { useRef } from 'react';\nimport { useIsomorphicLayoutEffect } from '../../react/use-recipe';\nimport { createToaster, type ToasterLabels } from './engine';\n\nexport interface ToasterProps {\n labels?: ToasterLabels;\n}\n\n/** toast deck. Mount once near the root; show toasts with `toast()`. */\nexport function Toaster({ labels }: ToasterProps) {\n const ref = useRef<HTMLDivElement>(null);\n const dismiss = labels?.dismiss;\n useIsomorphicLayoutEffect(() => {\n const toaster = createToaster(ref.current, { labels: { dismiss } });\n return () => toaster.destroy();\n }, [dismiss]);\n return <div ref={ref} className=\"mk-toaster\" />;\n}\n\nexport { toast, dismissToast, clearToasts, type ToastOptions, type ToastTone, type ToastAction } from './store';\n","'use client';\n\nimport { useRef, type CSSProperties } from 'react';\nimport { useIsomorphicLayoutEffect } from '../../react/use-recipe';\nimport { createChatBackground, type ChatBackgroundInstance } from './engine';\n\nexport interface ChatBackgroundProps {\n /** 0…1 (the microphone's, see audioEnergy); onboarding's busy state goes to 1.6. */\n energy?: number;\n scale?: number;\n className?: string;\n style?: CSSProperties;\n}\n\n/** chat background. Put it first inside a positioned container. */\nexport function ChatBackground({ energy = 0, scale = 1, className, style }: ChatBackgroundProps) {\n const ref = useRef<HTMLDivElement>(null);\n const instance = useRef<ChatBackgroundInstance | null>(null);\n useIsomorphicLayoutEffect(() => {\n const created = createChatBackground(ref.current, { energy, scale });\n instance.current = created;\n return () => {\n created.destroy();\n instance.current = null;\n };\n // Created once; energy and scale are pushed below.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n useIsomorphicLayoutEffect(() => {\n instance.current?.setEnergy(energy);\n }, [energy]);\n useIsomorphicLayoutEffect(() => {\n instance.current?.setScale(scale);\n }, [scale]);\n return <div ref={ref} className={['mk-chat-background', className].filter(Boolean).join(' ')} style={style} />;\n}\n","'use client';\n\nimport {\n Component,\n createContext,\n useContext,\n useRef,\n type ContextType,\n type HTMLAttributes,\n type MutableRefObject,\n type ReactNode,\n type TextareaHTMLAttributes,\n} from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { MkIcon } from '../icon';\nimport { TIMING } from '../../core/timing';\nimport { PENDING_ID, capturePending, createChat, morphPendingToReply, type ChatInstance, type ChatLabels, type ChatRole } from './engine';\n\ninterface ChatContextValue {\n instance: MutableRefObject<ChatInstance | null>;\n labels: ChatLabels;\n}\n\nconst ChatContext = createContext<ChatContextValue | null>(null);\n\nexport interface ChatRootProps extends HTMLAttributes<HTMLDivElement> {\n onSend?: (text: string) => void;\n animateExisting?: boolean;\n labels?: ChatLabels;\n children?: ReactNode;\n}\n\nfunction Root({ onSend, animateExisting, labels = {}, className, children, ...props }: ChatRootProps) {\n const ref = useRef<HTMLDivElement>(null);\n const instance = useRef<ChatInstance | null>(null);\n const send = useLatest(onSend);\n useIsomorphicLayoutEffect(() => {\n const created = createChat(ref.current, { animateExisting, labels, onSend: (text) => send.current?.(text) });\n instance.current = created;\n return () => {\n created.destroy();\n instance.current = null;\n };\n // The engine is created once; callbacks are read through refs.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n return (\n <ChatContext.Provider value={{ instance, labels }}>\n <div ref={ref} className={['mk-chat', className].filter(Boolean).join(' ')} {...props}>\n {children}\n </div>\n </ChatContext.Provider>\n );\n}\n\nexport interface ChatMessagesProps {\n /** Waiting for an answer: \"Pensando…\" shows after 500 ms and morphs into the next assistant message. */\n pending?: boolean;\n children?: ReactNode;\n}\n\ninterface MessagesState {\n showPending: boolean;\n}\n\ntype Snapshot = ReturnType<typeof capturePending>;\n\n/**\n * The message list. A class component: only getSnapshotBeforeUpdate can measure\n * the placeholder before React replaces it with the answer.\n */\nclass Messages extends Component<ChatMessagesProps, MessagesState> {\n static contextType = ChatContext;\n declare context: ContextType<typeof ChatContext>;\n state: MessagesState = { showPending: false };\n private list: HTMLDivElement | null = null;\n private timer: ReturnType<typeof setTimeout> | undefined;\n\n override componentDidMount() {\n if (this.props.pending) this.wait();\n }\n\n override componentDidUpdate(previous: ChatMessagesProps, _state: MessagesState, snapshot: Snapshot) {\n if (this.props.pending && !previous.pending) this.wait();\n if (!this.props.pending && previous.pending) {\n clearTimeout(this.timer);\n if (this.state.showPending) this.setState({ showPending: false });\n }\n if (!snapshot || !this.list) return;\n const answers = [...this.list.querySelectorAll<HTMLElement>('[data-mk-message][data-mk-role=\"assistant\"]:not([data-mk-pending])')];\n const reply = answers[answers.length - 1];\n if (!reply) return;\n this.context?.instance.current?.adopt(reply);\n morphPendingToReply(snapshot, reply, this.list);\n }\n\n override getSnapshotBeforeUpdate(previous: ChatMessagesProps): Snapshot {\n // The answer arrives as `pending` turns off: measure the placeholder while it is still there.\n if (!previous.pending || this.props.pending || !this.state.showPending || !this.list) return null;\n return capturePending(this.list.querySelector('[data-mk-pending]'));\n }\n\n override componentWillUnmount() {\n clearTimeout(this.timer);\n }\n\n private wait() {\n clearTimeout(this.timer);\n this.timer = setTimeout(() => {\n if (this.props.pending) this.setState({ showPending: true });\n }, TIMING.chat.pendingDelayMs);\n }\n\n override render() {\n const thinking = this.context?.labels.thinking ?? 'Pensando...';\n return (\n <div\n ref={(node) => {\n this.list = node;\n }}\n data-mk-part=\"messages\"\n >\n {this.props.children}\n {this.props.pending && this.state.showPending ? (\n <div data-mk-message=\"\" data-mk-role=\"assistant\" data-mk-pending=\"\" data-flip-id={PENDING_ID}>\n <span className=\"mk-chat__thinking\">\n <MkIcon name=\"sparkle\" size={18} />\n <span>{thinking}</span>\n </span>\n </div>\n ) : null}\n </div>\n );\n }\n}\n\nexport interface ChatMessageProps extends HTMLAttributes<HTMLDivElement> {\n role?: ChatRole;\n children?: ReactNode;\n}\n\nfunction Message({ role = 'assistant', children, ...props }: ChatMessageProps) {\n return (\n <div data-mk-message=\"\" data-mk-role={role} {...props}>\n <div data-mk-text=\"\">{children}</div>\n </div>\n );\n}\n\nexport interface ChatComposerProps extends TextareaHTMLAttributes<HTMLTextAreaElement> {\n /** Extra buttons before send (a microphone…). */\n actions?: ReactNode;\n sendLabel?: string;\n}\n\nfunction Composer({ actions, sendLabel = 'Enviar', placeholder = 'Escribe un mensaje...', ...props }: ChatComposerProps) {\n return (\n <form data-mk-part=\"composer\">\n <textarea data-mk-part=\"input\" rows={1} placeholder={placeholder} aria-label={placeholder} {...props} />\n <div data-mk-part=\"buttons\">\n {actions}\n <button type=\"submit\" data-mk-part=\"send\" aria-label={sendLabel}>\n <MkIcon name=\"send\" size={22} />\n </button>\n </div>\n </form>\n );\n}\n\nfunction Confirm({ children, ...props }: HTMLAttributes<HTMLDivElement>) {\n const ref = useRef<HTMLDivElement>(null);\n const context = useContext(ChatContext);\n useIsomorphicLayoutEffect(() => {\n if (ref.current) context?.instance.current?.confirm(ref.current);\n // Plays once, when the bar appears.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n return (\n <div ref={ref} data-mk-part=\"confirm\" {...props}>\n {children}\n </div>\n );\n}\n\n/**\n * chat: <Chat.Root onSend><ChatBackground /><Chat.Messages pending>{messages.map(m =>\n * <Chat.Message role>)}</Chat.Messages><Chat.Composer /></Chat.Root>.\n */\nexport const Chat = { Root, Messages, Message, Composer, Confirm };\n\n/** The chat engine of the surrounding <Chat.Root> (setRecording, scrollToLatest…). */\nexport function useChat() {\n const context = useContext(ChatContext);\n if (!context) throw new Error('useChat() needs a <Chat.Root> above it');\n return context.instance;\n}\n","'use client';\n\nimport { useRef, type HTMLAttributes, type MouseEvent, type ReactNode } from 'react';\nimport { useIsomorphicLayoutEffect } from '../../react/use-recipe';\nimport { revealShell, type NavStyle } from './engine';\n\nexport interface NavItem {\n value: string;\n label: ReactNode;\n icon?: ReactNode;\n /** Render a link instead of a button. */\n href?: string;\n /** Hidden in the phone bar. */\n hideOnMobile?: boolean;\n}\n\nexport interface NavProps extends Omit<HTMLAttributes<HTMLElement>, 'onSelect'> {\n items: NavItem[];\n /** Value of the current page. */\n active?: string;\n onSelect?: (value: string, event: MouseEvent<HTMLElement>) => void;\n navStyle?: NavStyle;\n accent?: boolean;\n /** Reveal the surrounding .mk-shell from the first button on mount. */\n reveal?: boolean;\n /** The top button (workspace, account…): give it className \"mk-nav__button mk-nav__button--first\". */\n first?: ReactNode;\n /** Buttons at the end (className \"mk-nav__button mk-nav__button--action\"). */\n actions?: ReactNode;\n}\n\n/** navigation. Put it inside a <div className=\"mk-shell\"> next to <main className=\"mk-shell__view\">. */\nexport function Nav({\n items,\n active,\n onSelect,\n navStyle = 'bonita',\n accent = false,\n reveal = false,\n first,\n actions,\n className,\n ...props\n}: NavProps) {\n const ref = useRef<HTMLElement>(null);\n useIsomorphicLayoutEffect(() => {\n if (!reveal || !ref.current) return;\n const handle = revealShell(ref.current);\n return () => handle?.cancel();\n // Only on mount.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n const classes = ['mk-nav', `mk-nav--${navStyle}`, accent && 'mk-nav--accent', className].filter(Boolean).join(' ');\n return (\n <nav ref={ref} aria-label=\"Principal\" {...props} className={classes}>\n {first}\n <div className=\"mk-nav__buttons\">\n {items.map((item) => {\n const shared = {\n className: 'mk-nav__button',\n 'aria-current': item.value === active ? ('page' as const) : undefined,\n 'data-mk-value': item.value,\n 'data-mk-hide-mobile': item.hideOnMobile ? '' : undefined,\n onClick: (event: MouseEvent<HTMLElement>) => onSelect?.(item.value, event),\n };\n const content = (\n <>\n {item.icon ? (\n <span className=\"mk-nav__icon\" aria-hidden=\"true\">\n {item.icon}\n </span>\n ) : null}\n <span className=\"mk-nav__name\">{item.label}</span>\n </>\n );\n return item.href ? (\n <a key={item.value} href={item.href} {...shared}>\n {content}\n </a>\n ) : (\n <button key={item.value} type=\"button\" {...shared}>\n {content}\n </button>\n );\n })}\n </div>\n {actions ? <div className=\"mk-nav__actions\">{actions}</div> : null}\n </nav>\n );\n}\n","'use client';\n\nimport {\n Children,\n createContext,\n isValidElement,\n useContext,\n useRef,\n type HTMLAttributes,\n type ReactNode,\n} from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createSteps, type StepsInstance } from './engine';\n\ninterface StepsContextValue {\n /** The step shown on the first render: React sets `hidden` once, then the engine owns it. */\n initial: number;\n}\n\nconst StepsContext = createContext<StepsContextValue>({ initial: 0 });\nconst StepIndex = createContext(-1);\n\nexport interface StepsProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange'> {\n /** Current step (0-based). Changing it flows to that step. */\n index?: number;\n onChange?: (index: number, previous: number) => void;\n /** A step is working: the chat background inside speeds up. */\n busy?: boolean;\n duration?: number;\n children?: ReactNode;\n}\n\nfunction Root({ index = 0, onChange, busy = false, duration, className, children, ...props }: StepsProps) {\n const ref = useRef<HTMLDivElement>(null);\n const instance = useRef<StepsInstance | null>(null);\n const initial = useRef(index);\n const change = useLatest(onChange);\n useIsomorphicLayoutEffect(() => {\n const created = createSteps(ref.current, { index: initial.current, duration, onChange: (i, previous) => change.current?.(i, previous) });\n instance.current = created;\n return () => {\n created.destroy();\n instance.current = null;\n };\n // Created once; index and busy are pushed below.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, []);\n useIsomorphicLayoutEffect(() => {\n void instance.current?.goTo(index);\n }, [index]);\n useIsomorphicLayoutEffect(() => {\n instance.current?.busy(busy);\n }, [busy]);\n let count = 0;\n const numbered = Children.map(children, (child) =>\n isValidElement(child) && child.type === Step ? <StepIndex.Provider value={count++}>{child}</StepIndex.Provider> : child,\n );\n return (\n <StepsContext.Provider value={{ initial: initial.current }}>\n <div ref={ref} className={['mk-steps', className].filter(Boolean).join(' ')} {...props}>\n {numbered}\n </div>\n </StepsContext.Provider>\n );\n}\n\nfunction Step({ children, ...props }: HTMLAttributes<HTMLElement>) {\n const { initial } = useContext(StepsContext);\n const index = useContext(StepIndex);\n return (\n <section data-mk-step=\"\" hidden={index !== initial} {...props}>\n {children}\n </section>\n );\n}\n\n/** The step number; the engine rolls it (React only writes the first value). */\nfunction Counter(props: HTMLAttributes<HTMLSpanElement>) {\n const { initial } = useContext(StepsContext);\n return (\n <span data-mk-counter=\"\" suppressHydrationWarning {...props}>\n {initial + 1}\n </span>\n );\n}\n\n/**\n * onboarding: <Steps index={i} busy={working}><ChatBackground /><Steps.Counter />\n * <Steps.Step><h2 data-mk-flow-item>…</h2></Steps.Step>…</Steps>. Steps must be direct children.\n */\nexport const Steps = Object.assign(Root, { Step, Counter });\n","'use client';\n\nimport { useRef } from 'react';\nimport { useIsomorphicLayoutEffect } from '../../react/use-recipe';\nimport { createCursor, type CursorOptions, type CursorVariant } from './engine';\n\nexport interface CursorProps {\n /** 'chip' (default) or 'dot'. */\n variant?: CursorVariant;\n /** dot: the word when nothing under the pointer gives one. */\n text?: string;\n arrows?: CursorOptions['arrows'];\n /** CSS selector of the zone (dot: default the parent). */\n zone?: string;\n className?: string;\n}\n\n/** Put <Cursor /> once in the layout (chip), or inside the zone (dot). */\nexport function Cursor({ variant = 'chip', text, arrows, zone, className }: CursorProps) {\n const ref = useRef<HTMLDivElement>(null);\n useIsomorphicLayoutEffect(() => {\n const cursor = createCursor(ref.current, { variant, text, arrows, zone: zone ? document.querySelector(zone) : undefined });\n return () => cursor.destroy();\n }, [variant, text, arrows, zone]);\n return <div ref={ref} className={className} />;\n}\n","import type { CSSProperties } from 'react';\n\nexport interface FrostProps {\n /** Which edge the blur grows toward (default bottom). */\n position?: 'bottom' | 'top';\n /** Pin it to the window instead of the positioned parent. */\n fixed?: boolean;\n height?: number | string;\n /** Multiplies the five blurs (default 1). */\n strength?: number;\n className?: string;\n style?: CSSProperties;\n}\n\n/** progressive frost: five blur layers. Put it inside a positioned container (or use `fixed`). */\nexport function Frost({ position = 'bottom', fixed = false, height, strength, className, style }: FrostProps) {\n const vars: Record<string, string> = {};\n if (height !== undefined) vars['--mk-frost-height'] = typeof height === 'number' ? `${height}px` : height;\n if (strength !== undefined) vars['--mk-frost-strength'] = String(strength);\n return (\n <div\n aria-hidden=\"true\"\n className={['mk-frost', position === 'top' && 'mk-frost--top', fixed && 'mk-frost--fixed', className].filter(Boolean).join(' ')}\n style={{ ...style, ...vars } as CSSProperties}\n >\n <i />\n <i />\n <i />\n <i />\n <i />\n </div>\n );\n}\n","'use client';\n\nimport { useRef, type HTMLAttributes, type ReactNode } from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createIsland, type IslandInstance, type IslandOptions } from './engine';\n\nexport interface IslandPanel {\n name: string;\n /** Accessible name of its button. */\n label: string;\n /** Button content; the menu's nine dots by default. */\n icon?: ReactNode;\n /** Light button. */\n light?: boolean;\n content: ReactNode;\n}\n\nexport interface IslandProps extends Omit<HTMLAttributes<HTMLElement>, 'onChange'>, Omit<IslandOptions, 'onChange'> {\n brand?: ReactNode;\n /** The call to action that fades out while a panel is open. */\n cta?: { href: string; label: ReactNode };\n panels: IslandPanel[];\n /** Keep it (and its backdrop) inside a positioned parent instead of fixed over the page. */\n contained?: boolean;\n onChange?: (active: string | null) => void;\n /** Receives the live instance (open, close, toggle, ready). */\n instanceRef?: { current: IslandInstance | null };\n}\n\n/** The nine static dots of the island menu button. */\nexport function IslandDots() {\n return (\n <span className=\"mk-island__dots\" aria-hidden=\"true\">\n {Array.from({ length: 9 }, (_, i) => (\n <i key={i} />\n ))}\n </span>\n );\n}\n\n/** floating navbar. */\nexport function Island({\n brand,\n cta,\n panels,\n contained = false,\n entrance,\n closeOnScroll,\n closeOnNavigate,\n focusOnOpen,\n onChange,\n instanceRef,\n className,\n ...props\n}: IslandProps) {\n const ref = useRef<HTMLElement>(null);\n const change = useLatest(onChange);\n useIsomorphicLayoutEffect(() => {\n const instance = createIsland(ref.current, {\n entrance,\n closeOnScroll,\n closeOnNavigate,\n focusOnOpen,\n onChange: (active) => change.current?.(active),\n });\n if (instanceRef) instanceRef.current = instance;\n return () => {\n instance.destroy();\n if (instanceRef) instanceRef.current = null;\n };\n // The panels' names define the markup the engine reads.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [panels.map((panel) => panel.name).join(), entrance, closeOnScroll, closeOnNavigate, focusOnOpen]);\n const classes = ['mk-island', contained && 'mk-island--contained', className].filter(Boolean).join(' ');\n return (\n <nav ref={ref} aria-label=\"Principal\" {...props} className={classes}>\n <button type=\"button\" className=\"mk-island__backdrop\" data-mk-island-close tabIndex={-1} aria-label=\"Cerrar\" />\n <div className=\"mk-island__shell\">\n <div className=\"mk-island__glass\" aria-hidden=\"true\" />\n <div className=\"mk-island__header\">\n {brand ? <span className=\"mk-island__brand\">{brand}</span> : <span />}\n <div className=\"mk-island__actions\">\n {cta ? (\n <a className=\"mk-island__cta\" href={cta.href}>\n {cta.label}\n </a>\n ) : null}\n {panels.map((panel, i) => (\n <span key={panel.name} style={{ display: 'contents' }}>\n {i > 0 ? <span className=\"mk-island__separator\" aria-hidden=\"true\" /> : null}\n <button\n type=\"button\"\n className={panel.light ? 'mk-island__button mk-island__button--light' : 'mk-island__button'}\n data-mk-island-toggle={panel.name}\n aria-label={panel.label}\n >\n {panel.icon ?? <IslandDots />}\n </button>\n </span>\n ))}\n </div>\n </div>\n <div className=\"mk-island__content\">\n <div>\n {panels.map((panel) => (\n <section key={panel.name} className=\"mk-island__panel\" data-mk-island-panel={panel.name} aria-label={panel.label}>\n {panel.content}\n </section>\n ))}\n </div>\n </div>\n </div>\n </nav>\n );\n}\n","'use client';\nimport { useRef, type HTMLAttributes } from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createQuantity, type QuantityOptions } from './engine';\nexport interface QuantityProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange' | 'defaultValue'>, QuantityOptions {\n label?: string; decreaseLabel?: string; increaseLabel?: string; name?: string;\n}\nexport function Quantity({ min, max, step, value, disabled, onChange, label = 'Cantidad', decreaseLabel = 'Disminuir', increaseLabel = 'Aumentar', name, className, ...props }: QuantityProps) {\n const ref = useRef<HTMLDivElement>(null);\n const edited = useRef<number | undefined>(undefined);\n const change = useLatest(onChange);\n useIsomorphicLayoutEffect(() => {\n const instance = createQuantity(ref.current, { min, max, step, value: value ?? edited.current, disabled, onChange: (n) => change.current?.(n) });\n return () => { edited.current = instance.value; instance.destroy(); };\n }, [min, max, step, value, disabled]);\n return <div {...props} ref={ref} className={['mk-quantity', className].filter(Boolean).join(' ')} role=\"group\" aria-label={label}>\n <button type=\"button\" data-mk-quantity-decrease aria-label={decreaseLabel}>−</button>\n <input data-mk-quantity-input type=\"number\" aria-label={label} name={name} defaultValue={value ?? min ?? 1} disabled={disabled} />\n <button type=\"button\" data-mk-quantity-increase aria-label={increaseLabel}>+</button>\n </div>;\n}\n","'use client';\nimport { useRef, type HTMLAttributes } from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createPagination, type PaginationOptions } from './engine';\nexport interface PaginationProps extends Omit<HTMLAttributes<HTMLElement>, 'onChange'>, PaginationOptions {\n previousLabel?: string; nextLabel?: string;\n}\nexport function Pagination({ totalPages, page, siblings, pageLabel, onChange, previousLabel = 'Página anterior', nextLabel = 'Página siguiente', className, ...props }: PaginationProps) {\n const ref = useRef<HTMLElement>(null);\n const selected = useRef<number | undefined>(undefined);\n const change = useLatest(onChange);\n const label = useLatest(pageLabel);\n useIsomorphicLayoutEffect(() => {\n const instance = createPagination(ref.current, { totalPages, page: page ?? selected.current, siblings, pageLabel: (n) => label.current?.(n) ?? `Página ${n}`, onChange: (n) => change.current?.(n) });\n return () => { selected.current = instance.page; instance.destroy(); };\n }, [totalPages, page, siblings, pageLabel]);\n return <nav aria-label=\"Paginación\" {...props} ref={ref} className={['mk-pagination', className].filter(Boolean).join(' ')}>\n <button type=\"button\" data-mk-pagination-previous aria-label={previousLabel}>←</button>\n <span data-mk-pagination-pages />\n <button type=\"button\" data-mk-pagination-next aria-label={nextLabel}>→</button>\n </nav>;\n}\n","'use client';\nimport { useRef, type HTMLAttributes, type ReactNode } from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createHoverCard, type HoverCardOptions } from './engine';\nexport interface HoverCardProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange'>, HoverCardOptions {\n trigger: ReactNode; children: ReactNode; triggerLabel?: string; panelLabel?: string;\n}\nexport function HoverCard({ trigger, children, triggerLabel, panelLabel = 'Vista previa', openDelay, closeDelay, placement, onOpenChange, className, ...props }: HoverCardProps) {\n const ref = useRef<HTMLDivElement>(null);\n const change = useLatest(onOpenChange);\n useIsomorphicLayoutEffect(() => {\n const instance = createHoverCard(ref.current, { openDelay, closeDelay, placement, onOpenChange: (n) => change.current?.(n) });\n return () => instance.destroy();\n }, [openDelay, closeDelay, placement]);\n return <div {...props} ref={ref} className={['mk-hover-card', className].filter(Boolean).join(' ')}>\n <button type=\"button\" className=\"mk-button mk-button--tonal\" data-mk-hover-trigger aria-label={triggerLabel} aria-expanded=\"false\">{trigger}</button>\n <div data-mk-hover-panel role=\"region\" aria-label={panelLabel} hidden>{children}</div>\n </div>;\n}\n","'use client';\nimport { useRef, type HTMLAttributes } from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createInputOtp, type InputOtpOptions } from './engine';\nexport interface InputOtpProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange' | 'onComplete' | 'defaultValue'>, InputOtpOptions {\n label?: string; name?: string; disabled?: boolean; required?: boolean; invalid?: boolean; defaultValue?: string;\n}\nexport function InputOtp({ length, value, defaultValue, mask, onChange, onComplete, label = 'Código de verificación', name, disabled, required, invalid, className, ...props }: InputOtpProps) {\n const ref = useRef<HTMLDivElement>(null);\n const edited = useRef<string | undefined>(undefined);\n const change = useLatest(onChange);\n const complete = useLatest(onComplete);\n useIsomorphicLayoutEffect(() => {\n const instance = createInputOtp(ref.current, { length, value: value ?? edited.current, mask, onChange: (n) => change.current?.(n), onComplete: (n) => complete.current?.(n) });\n return () => { edited.current = instance.value; instance.destroy(); };\n }, [length, value, mask]);\n return <div {...props} ref={ref} className={['mk-input-otp', className].filter(Boolean).join(' ')}>\n <span data-mk-otp-slots aria-hidden=\"true\" />\n <input data-mk-otp-input type=\"text\" aria-label={label} name={name} defaultValue={value ?? defaultValue ?? ''} disabled={disabled} required={required} aria-invalid={invalid || undefined} />\n </div>;\n}\n","'use client';\nimport type { RefObject, DependencyList } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createJoinedCta, type JoinedCtaOptions } from '../recipes/joined-cta/create-joined-cta';\nexport const useJoinedCta = (ref: RefObject<HTMLElement | null>, options?: JoinedCtaOptions, deps?: DependencyList) => useRecipe(ref, createJoinedCta, options, deps);\n","'use client';\nimport type { RefObject, DependencyList } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createImageZoom, type ImageZoomOptions } from '../recipes/image-zoom/create-image-zoom';\nexport const useImageZoom = (ref: RefObject<HTMLElement | null>, options?: ImageZoomOptions, deps?: DependencyList) => useRecipe(ref, createImageZoom, options, deps);\n","'use client';\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createFontCycle, type FontCycleOptions } from '../recipes/font-cycle/create-font-cycle';\n\nexport const useFontCycle = (ref: RefObject<HTMLElement | null>, options?: FontCycleOptions, deps?: DependencyList) =>\n useRecipe(ref, createFontCycle, options, deps);\n","'use client';\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createThumbnailNav, type ThumbnailNavOptions } from '../recipes/thumbnail-nav/create-thumbnail-nav';\n\nexport const useThumbnailNav = (ref: RefObject<HTMLElement | null>, options?: ThumbnailNavOptions, deps?: DependencyList) =>\n useRecipe(ref, createThumbnailNav, options, deps);\n","'use client';\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createActionButton, type ActionButtonOptions } from '../recipes/action-button/create-action-button';\nexport const useActionButton = (ref: RefObject<HTMLElement | null>, options?: ActionButtonOptions, deps?: DependencyList) =>\n useRecipe(ref, createActionButton, options, deps);\n","'use client';\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createFilmHero, type FilmHeroOptions } from '../recipes/film-hero/create-film-hero';\nexport const useFilmHero = (ref: RefObject<HTMLElement | null>, options?: FilmHeroOptions, deps?: DependencyList) =>\n useRecipe(ref, createFilmHero, options, deps);\n","'use client';\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createEditorialReveal, type EditorialRevealOptions } from '../recipes/editorial-reveal/create-editorial-reveal';\nexport function useEditorialReveal(ref: RefObject<HTMLElement | null>, options: EditorialRevealOptions = {}, deps?: DependencyList) {\n return useRecipe(ref, createEditorialReveal, options, deps);\n}\n","'use client';\nimport type { DependencyList, RefObject } from 'react';\nimport { useLatest, useRecipe } from './use-recipe';\nimport { createStudioDock, type StudioDockOptions } from '../components/studio-dock/engine';\nexport function useStudioDock(ref: RefObject<HTMLElement | null>, options: StudioDockOptions = {}, deps?: DependencyList) {\n const change = useLatest(options.onChange);\n return useRecipe(ref, createStudioDock, { ...options, onChange: state => change.current?.(state) }, deps);\n}\n","'use client';\nimport type { DependencyList, RefObject } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createTrailer, type TrailerOptions } from '../components/trailer/engine';\nexport const useTrailer = (ref: RefObject<HTMLElement | null>, options?: TrailerOptions, deps?: DependencyList) =>\n useRecipe(ref, createTrailer, options, deps);\n","'use client';\nimport { useRef, type HTMLAttributes } from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createStudioDock, type StudioDockInstance, type StudioDockOptions } from './engine';\n\nexport interface StudioDockProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange'>, StudioDockOptions {\n /** Default stays inside its positioned demo/app panel. */\n fixed?: boolean;\n instanceRef?: { current: StudioDockInstance | null };\n}\n/** Composable light-DOM shell; use the data-mk-studio-* slots shown in the README. */\nexport function StudioDock({ duration, ease, focusOnOpen, trapFocus, onChange, fixed = false, instanceRef, className, children, ...props }: StudioDockProps) {\n const ref = useRef<HTMLDivElement>(null);\n const change = useLatest(onChange);\n useIsomorphicLayoutEffect(() => {\n const instance = createStudioDock(ref.current, { duration, ease, focusOnOpen, trapFocus, onChange: state => change.current?.(state) });\n if (instanceRef) instanceRef.current = instance;\n return () => { instance.destroy(); if (instanceRef) instanceRef.current = null; };\n }, [duration, ease, focusOnOpen, trapFocus]);\n return <div {...props} ref={ref} className={['mk-studio-dock', fixed && 'mk-studio-dock--fixed', className].filter(Boolean).join(' ')}>{children}</div>;\n}\n\nexport { useStudioDock } from '../../react/use-studio-dock';\n","'use client';\nimport { useRef, type DialogHTMLAttributes } from 'react';\nimport { useRecipe } from '../../react/use-recipe';\nimport { createTrailer, type TrailerOptions } from './engine';\n\nexport interface TrailerProps extends Omit<DialogHTMLAttributes<HTMLDialogElement>, 'open' | 'onClose'> {\n options?: TrailerOptions;\n}\n/** Consumer supplies <video>, optional controls and tracks; no remote media is injected. */\nexport function Trailer({ options, className, children, ...props }: TrailerProps) {\n const ref = useRef<HTMLDialogElement>(null);\n useRecipe(ref, createTrailer, options);\n return <dialog {...props} ref={ref} className={['mk-trailer', className].filter(Boolean).join(' ')}>{children}</dialog>;\n}\n\nexport { useTrailer } from '../../react/use-trailer';\n","'use client';\n\nimport { useRef, type HTMLAttributes } from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createCalendar, type CalendarInstance, type CalendarOptions, type CalendarView } from './engine';\nimport type { DateInput } from '../../core/dates';\n\nexport interface CalendarProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onSelect'>, CalendarOptions {\n /** Hide the month/week switch. */\n hideViews?: boolean;\n labels?: CalendarOptions['labels'] & { previous?: string; next?: string; today?: string; month?: string; week?: string };\n}\n\nexport function Calendar({\n date, view, firstDay, locale, events, maxEvents, selected, today, labels, onSelect, onEventClick, onNavigate,\n hideViews, className, ...props\n}: CalendarProps) {\n const ref = useRef<HTMLDivElement>(null);\n const instance = useRef<CalendarInstance | null>(null);\n const kept = useRef<{ date?: DateInput; view?: CalendarView; selected?: DateInput | null }>({});\n const select = useLatest(onSelect);\n const eventClick = useLatest(onEventClick);\n const navigate = useLatest(onNavigate);\n useIsomorphicLayoutEffect(() => {\n const created = createCalendar(ref.current, {\n date: date ?? kept.current.date,\n view: view ?? kept.current.view,\n selected: selected !== undefined ? selected : kept.current.selected,\n firstDay, locale, events, maxEvents, today, labels,\n onSelect: (d) => select.current?.(d),\n onEventClick: (e) => eventClick.current?.(e),\n onNavigate: (r) => navigate.current?.(r),\n });\n instance.current = created;\n return () => {\n kept.current = { date: created.date, view: created.view, selected: created.selected };\n created.destroy();\n instance.current = null;\n };\n // Events and selection update in place; the rest recreates the grid.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [date, view, firstDay, locale, maxEvents, today]);\n // Re-index only when the events' content changes, not on every new array identity.\n const eventsKey = JSON.stringify(events ?? []);\n const firstEvents = useRef(true);\n useIsomorphicLayoutEffect(() => {\n if (firstEvents.current) { firstEvents.current = false; return; }\n instance.current?.setEvents(events ?? []);\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [eventsKey]);\n useIsomorphicLayoutEffect(() => { if (selected !== undefined) instance.current?.select(selected, false); }, [selected]);\n return (\n <div {...props} ref={ref} className={['mk-calendar', className].filter(Boolean).join(' ')}>\n <div className=\"mk-calendar__header\">\n <h3 className=\"mk-calendar__title\" data-mk-calendar-title />\n {!hideViews && (\n <div className=\"mk-calendar__views\" role=\"group\" aria-label=\"Vista\">\n <button type=\"button\" data-mk-calendar-view=\"month\">{labels?.month ?? 'Mes'}</button>\n <button type=\"button\" data-mk-calendar-view=\"week\">{labels?.week ?? 'Semana'}</button>\n </div>\n )}\n <button type=\"button\" className=\"mk-calendar__nav\" data-mk-calendar-prev aria-label={labels?.previous ?? 'Anterior'}>←</button>\n <button type=\"button\" className=\"mk-calendar__nav\" data-mk-calendar-today>{labels?.today ?? 'Hoy'}</button>\n <button type=\"button\" className=\"mk-calendar__nav\" data-mk-calendar-next aria-label={labels?.next ?? 'Siguiente'}>→</button>\n </div>\n <div data-mk-calendar-grid />\n </div>\n );\n}\n","'use client';\n\nimport { useRef, type HTMLAttributes, type ReactNode } from 'react';\nimport { useIsomorphicLayoutEffect, useLatest } from '../../react/use-recipe';\nimport { createSlotPicker, type SlotPickerInstance, type SlotPickerOptions } from './engine';\n\nexport interface SlotPickerProps extends Omit<HTMLAttributes<HTMLDivElement>, 'onChange'>, SlotPickerOptions {\n /** Form field name: a hidden input carries \"YYYY-MM-DDTHH:mm\". */\n name?: string;\n labels?: SlotPickerOptions['labels'] & { previous?: string; next?: string };\n /** Rendered under the times (e.g. a submit button). */\n actions?: ReactNode;\n}\n\nexport function SlotPicker({\n date, value, slots, min, max, closedDays, isDisabled, firstDay, locale, labels, onChange, onDateChange,\n name, actions, className, ...props\n}: SlotPickerProps) {\n const ref = useRef<HTMLDivElement>(null);\n const instance = useRef<SlotPickerInstance | null>(null);\n const kept = useRef<string | Date | null>(null);\n const change = useLatest(onChange);\n const dateChange = useLatest(onDateChange);\n const disabledFn = useLatest(isDisabled);\n // A function source is read through a ref (inline functions do not reload);\n // lists and maps reload when their content changes.\n const source = useLatest(slots);\n const slotsKey = typeof slots === 'function' ? 'function' : JSON.stringify(slots ?? []);\n const stable = () => {\n const current = source.current;\n return typeof current === 'function' ? (d: Date) => (source.current as (day: Date) => string[] | Promise<string[]>)(d) : current ?? [];\n };\n useIsomorphicLayoutEffect(() => {\n const keep = kept.current;\n const created = createSlotPicker(ref.current, {\n date: date ?? (keep instanceof Date ? keep : undefined),\n value: value !== undefined ? value : typeof keep === 'string' ? keep : undefined,\n slots: stable(), min, max, closedDays, firstDay, locale, labels,\n isDisabled: (d) => disabledFn.current?.(d) ?? false,\n onChange: (v) => change.current?.(v),\n onDateChange: (d) => dateChange.current?.(d),\n });\n instance.current = created;\n return () => {\n kept.current = created.value ?? created.date;\n created.destroy();\n instance.current = null;\n };\n // `slots` updates in place; the rest recreates the picker.\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [date, value, min, max, firstDay, locale, JSON.stringify(closedDays ?? [])]);\n const firstSlots = useRef(true);\n useIsomorphicLayoutEffect(() => {\n if (firstSlots.current) { firstSlots.current = false; return; }\n instance.current?.setSlots(stable());\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [slotsKey]);\n return (\n <div {...props} ref={ref} className={['mk-slot-picker', className].filter(Boolean).join(' ')}>\n <div className=\"mk-slot-picker__calendar\">\n <div className=\"mk-slot-picker__month\">\n <h3 className=\"mk-slot-picker__title\" data-mk-slot-title />\n <button type=\"button\" className=\"mk-slot-picker__nav\" data-mk-slot-prev aria-label={labels?.previous ?? 'Mes anterior'}>←</button>\n <button type=\"button\" className=\"mk-slot-picker__nav\" data-mk-slot-next aria-label={labels?.next ?? 'Mes siguiente'}>→</button>\n </div>\n <div data-mk-slot-days />\n </div>\n <div className=\"mk-slot-picker__panel\">\n <p className=\"mk-slot-picker__heading\" data-mk-slot-heading />\n <div data-mk-slot-times />\n {name && <input type=\"hidden\" name={name} data-mk-slot-value />}\n {actions && <div className=\"mk-slot-picker__actions\">{actions}</div>}\n </div>\n </div>\n );\n}\n","'use client';\nimport type { RefObject, DependencyList } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createWeightHover, type WeightHoverOptions } from '../recipes/weight-hover/create-weight-hover';\nexport const useWeightHover = (ref: RefObject<HTMLElement | null>, options?: WeightHoverOptions, deps?: DependencyList) => useRecipe(ref, createWeightHover, options, deps);\n","'use client';\nimport type { RefObject, DependencyList } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createSticker, type StickerOptions } from '../recipes/sticker/create-sticker';\nexport const useSticker = (ref: RefObject<HTMLElement | null>, options?: StickerOptions, deps?: DependencyList) => useRecipe(ref, createSticker, options, deps);\n","'use client';\nimport type { RefObject, DependencyList } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createScrollDock, type ScrollDockOptions } from '../recipes/scroll-dock/create-scroll-dock';\nexport const useScrollDock = (ref: RefObject<HTMLElement | null>, options?: ScrollDockOptions, deps?: DependencyList) => useRecipe(ref, createScrollDock, options, deps);\n","'use client';\nimport type { RefObject, DependencyList } from 'react';\nimport { useRecipe } from './use-recipe';\nimport { createLocalClock, type LocalClockOptions } from '../recipes/local-clock/create-local-clock';\nexport const useLocalClock = (ref: RefObject<HTMLElement | null>, options?: LocalClockOptions, deps?: DependencyList) => useRecipe(ref, createLocalClock, options, deps);\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAEA,SAAS,WAAW,iBAAiB,cAAmD;AAIjF,IAAM,4BAA4B,OAAO,WAAW,cAAc,kBAAkB;AAMpF,SAAS,UACd,KACA,SACA,SACA,OAAuB,CAAC,GACH;AACrB,QAAM,WAAW,OAAiB,IAAI;AACtC,4BAA0B,MAAM;AAC9B,UAAM,UAAU,QAAQ,IAAI,SAAS,OAAO;AAC5C,aAAS,UAAU;AACnB,WAAO,MAAM;AACX,cAAQ,QAAQ;AAChB,eAAS,UAAU;AAAA,IACrB;AAAA,EAGF,GAAG,IAAI;AACP,SAAO;AACT;AAGO,SAAS,UAAa,OAAU;AACrC,QAA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kB,SAAS,IAAI;","names":["useRef","jsx","useRef","useRef","useState","jsx","useRef","useState","useEffect","useRef","useState","jsx","useState","useRef","useEffect","createContext","useContext","useMemo","useRef","useState","jsx","jsx","useState","useRef","useMemo","createContext","useContext","jsx","createContext","useContext","useRef","jsx","createContext","useContext","Root","Trigger","Content","useRef","useRef","jsx","useRef","useRef","jsx","useRef","Component","createContext","useContext","useRef","jsx","jsxs","createContext","Root","useRef","Component","useContext","useRef","Fragment","jsx","jsxs","useRef","createContext","useContext","useRef","jsx","createContext","Root","useRef","useContext","useRef","jsx","useRef","jsx","jsxs","useRef","jsx","jsxs","useRef","useRef","jsx","jsxs","useRef","useRef","jsx","jsxs","useRef","useRef","jsx","jsxs","useRef","useRef","jsx","jsxs","useRef","useRef","jsx","useRef","useRef","jsx","useRef","useRef","jsx","jsxs","useRef","useRef","jsx","jsxs","useRef"]}
|