@stfrigerio/sito-template 0.1.75 → 0.1.76

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (178) hide show
  1. package/dist/components/organisms/Calendar/Calendar.d.ts.map +1 -1
  2. package/dist/index.esm.js +5 -3
  3. package/dist/index.esm.js.map +1 -1
  4. package/dist/index.js +5 -3
  5. package/dist/index.js.map +1 -1
  6. package/package.json +1 -1
  7. package/storybook-static/assets/{ASCIIText.stories-Be7IUzBl.js → ASCIIText.stories-jyeGS_ve.js} +1 -1
  8. package/storybook-static/assets/{AllAtoms.stories-C9NutWhw.js → AllAtoms.stories-CemMq1qd.js} +1 -1
  9. package/storybook-static/assets/{AnimatedContent.stories-DAZgqjS_.js → AnimatedContent.stories-DffuqOCI.js} +1 -1
  10. package/storybook-static/assets/{AnimatedList.stories-Br-uT7_K.js → AnimatedList.stories-DuwFQFkj.js} +1 -1
  11. package/storybook-static/assets/{Antigravity.stories-BZViYA2F.js → Antigravity.stories-DcbmxH5R.js} +1 -1
  12. package/storybook-static/assets/{ArrayInput.stories-OZicZh0x.js → ArrayInput.stories-DvZKodHx.js} +1 -1
  13. package/storybook-static/assets/{Aurora.stories-_Kk2dlqT.js → Aurora.stories-BQOm4LDu.js} +1 -1
  14. package/storybook-static/assets/{Beams.stories-BWf6w14D.js → Beams.stories-CzdaOr3E.js} +1 -1
  15. package/storybook-static/assets/{BlobCursor.stories-C8LnoCVY.js → BlobCursor.stories-DKhEEylD.js} +1 -1
  16. package/storybook-static/assets/{BlurText.stories-B-YSXpM4.js → BlurText.stories-BXn21RBW.js} +1 -1
  17. package/storybook-static/assets/{BooleansHeatmap.stories-NVqKfTn7.js → BooleansHeatmap.stories-wo9Pvb36.js} +1 -1
  18. package/storybook-static/assets/{BorderGlow.stories-Cb5lpRXR.js → BorderGlow.stories-BVoYeD5v.js} +1 -1
  19. package/storybook-static/assets/{BubbleMenu.stories-DcO35VF7.js → BubbleMenu.stories-dqsJINuc.js} +1 -1
  20. package/storybook-static/assets/{Button-C8qYbNr4.js → Button-C8DVgvIi.js} +1 -1
  21. package/storybook-static/assets/{Button.stories-DwzHgPep.js → Button.stories-X7b76nlX.js} +1 -1
  22. package/storybook-static/assets/{Calendar.stories-BA2-_mhV.js → Calendar.stories-D0Uw8SPv.js} +2 -2
  23. package/storybook-static/assets/{Card-Cd6nYK-n.js → Card-C1CU1aJ4.js} +1 -1
  24. package/storybook-static/assets/{Card.stories-BR4jTCEu.js → Card.stories-pOZ_I_3_.js} +1 -1
  25. package/storybook-static/assets/{CardNav.stories-BC92ePdS.js → CardNav.stories-OkPJO-Ni.js} +1 -1
  26. package/storybook-static/assets/{Carousel.stories-2zzLsuyG.js → Carousel.stories-D3jZVWZF.js} +1 -1
  27. package/storybook-static/assets/{Checkbox-D1NYWUJY.js → Checkbox-CjfwEqdP.js} +1 -1
  28. package/storybook-static/assets/{Checkbox.stories-5-iRUqeK.js → Checkbox.stories-BklK9_jk.js} +1 -1
  29. package/storybook-static/assets/{ChromaGrid.stories-D8TFP6QH.js → ChromaGrid.stories-Byrw6uQA.js} +1 -1
  30. package/storybook-static/assets/{CircularGallery.stories-JsH1BjyB.js → CircularGallery.stories-fLTqpbyo.js} +1 -1
  31. package/storybook-static/assets/{CircularText.stories-vbhRP9H6.js → CircularText.stories-BA-dJIzs.js} +1 -1
  32. package/storybook-static/assets/{ClickSpark.stories-CjalF_iE.js → ClickSpark.stories-DoEJmAGn.js} +1 -1
  33. package/storybook-static/assets/{ColorBends.stories-DgCt12L9.js → ColorBends.stories-DlI5eNgp.js} +1 -1
  34. package/storybook-static/assets/{CountUp.stories-Bx0w5jtq.js → CountUp.stories-DC06me0h.js} +1 -1
  35. package/storybook-static/assets/{Counter.stories-RAMjdEPH.js → Counter.stories-B0_x7SnO.js} +1 -1
  36. package/storybook-static/assets/{Crosshair.stories-CGuCeDZg.js → Crosshair.stories-MQfVFGQ7.js} +1 -1
  37. package/storybook-static/assets/{Cubes.stories-BpRxVapu.js → Cubes.stories-CB5LyVAa.js} +1 -1
  38. package/storybook-static/assets/{CurvedLoop.stories-B-tYGBma.js → CurvedLoop.stories-pad6C9il.js} +1 -1
  39. package/storybook-static/assets/{DarkVeil.stories-BN90toz_.js → DarkVeil.stories-CjoNpRrA.js} +1 -1
  40. package/storybook-static/assets/{DateInput-De2GsD_W.js → DateInput-BOP5MJAA.js} +1 -1
  41. package/storybook-static/assets/{DateInput.stories-4L2ho_Pi.js → DateInput.stories-DpytWXTi.js} +1 -1
  42. package/storybook-static/assets/{DecayCard.stories-BJ7VTrOs.js → DecayCard.stories-Ci8mCDU2.js} +1 -1
  43. package/storybook-static/assets/{DecryptedText.stories-BhqbuMpe.js → DecryptedText.stories-_OcmqlGZ.js} +1 -1
  44. package/storybook-static/assets/{Dither.stories-UeQDenX9.js → Dither.stories-CoakUTGz.js} +1 -1
  45. package/storybook-static/assets/{Dock.stories-NDUyF4PJ.js → Dock.stories-RZsDkvOK.js} +1 -1
  46. package/storybook-static/assets/{EditFAB.stories-B0wSYqZE.js → EditFAB.stories-BYgIa7Ft.js} +1 -1
  47. package/storybook-static/assets/{EvilEye.stories-CD4zSVsk.js → EvilEye.stories-C9-B_l7O.js} +1 -1
  48. package/storybook-static/assets/{FadeContent.stories-fS_5Hw44.js → FadeContent.stories-BSUfS-Pa.js} +1 -1
  49. package/storybook-static/assets/{FaultyTerminal.stories-BdbWtZwI.js → FaultyTerminal.stories-BaztxBZy.js} +1 -1
  50. package/storybook-static/assets/{Fbo-BuZjyF_I.js → Fbo-BckR5Q0w.js} +1 -1
  51. package/storybook-static/assets/{FloatingLines.stories-a-bJ8W7B.js → FloatingLines.stories-B48w4g-P.js} +1 -1
  52. package/storybook-static/assets/{FlowingMenu.stories-CPFd-oYE.js → FlowingMenu.stories-CGiY3eRk.js} +1 -1
  53. package/storybook-static/assets/{FluidGlass.stories-D70sIzph.js → FluidGlass.stories-CHa9ViPX.js} +1 -1
  54. package/storybook-static/assets/{Folder.stories-BNad9vBK.js → Folder.stories-BolWKAzo.js} +1 -1
  55. package/storybook-static/assets/{FuzzyText.stories-kzTlAczv.js → FuzzyText.stories-CSRaTOLX.js} +1 -1
  56. package/storybook-static/assets/{Galaxy.stories-BcoDoJJH.js → Galaxy.stories-CIg8QFfb.js} +1 -1
  57. package/storybook-static/assets/{GhostCursor.stories-CIQ5oS-a.js → GhostCursor.stories-BQpjOfNR.js} +1 -1
  58. package/storybook-static/assets/{GlareHover.stories-DZKCns9C.js → GlareHover.stories-Di_VEr2R.js} +1 -1
  59. package/storybook-static/assets/{GlassSurface.stories-DRkJx3Za.js → GlassSurface.stories-DAkIcgOf.js} +1 -1
  60. package/storybook-static/assets/{GlitchText.stories-G_9lrKbn.js → GlitchText.stories-BxcuVmW5.js} +1 -1
  61. package/storybook-static/assets/{GooeyNav.stories-CV4BQuUk.js → GooeyNav.stories-CTW-U7xs.js} +1 -1
  62. package/storybook-static/assets/{GradientBlinds.stories-DHrpEpO_.js → GradientBlinds.stories-fBqlT4g6.js} +1 -1
  63. package/storybook-static/assets/{GradientText.stories-CM948FuA.js → GradientText.stories-BZerGqdF.js} +1 -1
  64. package/storybook-static/assets/{Grainient.stories-zUxmkOn4.js → Grainient.stories-CzqvhFb3.js} +1 -1
  65. package/storybook-static/assets/{GridMotion.stories-B0sfK-C-.js → GridMotion.stories-CfjnoneJ.js} +1 -1
  66. package/storybook-static/assets/{ImageSlideshow.stories-rPxMKmHH.js → ImageSlideshow.stories-DQvn07Dy.js} +1 -1
  67. package/storybook-static/assets/{Iridescence.stories-BNNnwiDj.js → Iridescence.stories-DZ0dT4zy.js} +1 -1
  68. package/storybook-static/assets/{LaserFlow.stories-DuoNQh4u.js → LaserFlow.stories-CZg0PMHs.js} +1 -1
  69. package/storybook-static/assets/{LetterGlitch.stories-7kRTByUR.js → LetterGlitch.stories-BNqR58lP.js} +1 -1
  70. package/storybook-static/assets/{LightPillar.stories-DoEKaygk.js → LightPillar.stories-DkmTFDSR.js} +1 -1
  71. package/storybook-static/assets/{LightRays.stories-DsoKnqhC.js → LightRays.stories-CYtKgl66.js} +1 -1
  72. package/storybook-static/assets/{Lightning.stories-BY9AXDxS.js → Lightning.stories-CI_IBNog.js} +1 -1
  73. package/storybook-static/assets/{LineWaves.stories-BW_b_xTw.js → LineWaves.stories-19E6lLvu.js} +1 -1
  74. package/storybook-static/assets/{LiquidChrome.stories--0ZnOsg0.js → LiquidChrome.stories-Ik5wMITA.js} +1 -1
  75. package/storybook-static/assets/{LiquidEther.stories-BwpzjovS.js → LiquidEther.stories-cRVhMCnV.js} +1 -1
  76. package/storybook-static/assets/{LoadingSpinner-1bG1jTA9.js → LoadingSpinner-B3jiWJ5i.js} +1 -1
  77. package/storybook-static/assets/{LoadingSpinner.stories-Bj9WTCwr.js → LoadingSpinner.stories-7o51GOVb.js} +1 -1
  78. package/storybook-static/assets/{MagicRings.stories-BYwozKiq.js → MagicRings.stories-BdhXUzZR.js} +1 -1
  79. package/storybook-static/assets/{Magnet.stories-dCmlUHRm.js → Magnet.stories-BP_O9O9B.js} +1 -1
  80. package/storybook-static/assets/{MagnetLines.stories-Bddr81lJ.js → MagnetLines.stories-DO5Vf2eN.js} +1 -1
  81. package/storybook-static/assets/{Masonry.stories-CsgBFQaq.js → Masonry.stories-CbvsjL9N.js} +1 -1
  82. package/storybook-static/assets/{MetaBalls.stories-r-9Ktern.js → MetaBalls.stories-mzBfHDeT.js} +1 -1
  83. package/storybook-static/assets/{MetallicPaint.stories-DJ1icY96.js → MetallicPaint.stories-DwrE7et4.js} +1 -1
  84. package/storybook-static/assets/{MoodChart.stories-BAN1H65s.js → MoodChart.stories-BW4k1gRH.js} +1 -1
  85. package/storybook-static/assets/{MotionConfigContext-4sobDr_8.js → MotionConfigContext-C6KIXCCK.js} +1 -1
  86. package/storybook-static/assets/{Navbar.stories-DT4E8FDb.js → Navbar.stories-MCOlCO7j.js} +1 -1
  87. package/storybook-static/assets/{Noise.stories-CySeqiK8.js → Noise.stories-BX29bXzI.js} +1 -1
  88. package/storybook-static/assets/{NumberStepper-Bvk5-t63.js → NumberStepper-CGuZE3IG.js} +1 -1
  89. package/storybook-static/assets/{NumberStepper.stories-D0NnhqEp.js → NumberStepper.stories-CM1-xjqx.js} +1 -1
  90. package/storybook-static/assets/{Orb.stories-DETL2oxn.js → Orb.stories-C1U1NFn1.js} +1 -1
  91. package/storybook-static/assets/{OrbitImages.stories-BAyGh6vN.js → OrbitImages.stories-_U1a6MJ2.js} +1 -1
  92. package/storybook-static/assets/{PieChart.stories-C_miXq6_.js → PieChart.stories-U46uc40e.js} +1 -1
  93. package/storybook-static/assets/{PixelBlast.stories-DNnRrF47.js → PixelBlast.stories--1zBJff-.js} +1 -1
  94. package/storybook-static/assets/{PixelCard.stories-Cd6Auu0Y.js → PixelCard.stories-CKIsLyL5.js} +1 -1
  95. package/storybook-static/assets/{PixelSnow.stories-DkN5T7YO.js → PixelSnow.stories-CR4xLE4U.js} +1 -1
  96. package/storybook-static/assets/{PixelTransition.stories-COEvkR-7.js → PixelTransition.stories-Dd9P0Ope.js} +1 -1
  97. package/storybook-static/assets/{Plasma.stories-B22oVtcY.js → Plasma.stories-M-hYDX27.js} +1 -1
  98. package/storybook-static/assets/{Prism.stories-DV0OORlV.js → Prism.stories-DwfbD3cn.js} +1 -1
  99. package/storybook-static/assets/{PrismaticBurst.stories-DCmccTx8.js → PrismaticBurst.stories-CvPmYAX_.js} +1 -1
  100. package/storybook-static/assets/{ProfileCard.stories-CHEs7KlC.js → ProfileCard.stories-DP2eHRdZ.js} +1 -1
  101. package/storybook-static/assets/{QuantifiableHabitsChart.stories-Bl2yVrqA.js → QuantifiableHabitsChart.stories-RglnD2R_.js} +1 -1
  102. package/storybook-static/assets/{Radar.stories-I5P8dO4E.js → Radar.stories-D-LhC9r4.js} +1 -1
  103. package/storybook-static/assets/{Ribbons.stories-D5cJQVM0.js → Ribbons.stories-CJuxGieY.js} +1 -1
  104. package/storybook-static/assets/{RippleGrid.stories-BwtOrFUs.js → RippleGrid.stories-D_3EPPTM.js} +1 -1
  105. package/storybook-static/assets/{RotatingText.stories-DARyQPUz.js → RotatingText.stories-DYP0oyH6.js} +1 -1
  106. package/storybook-static/assets/{ScrollFloat.stories-Dc0orsYz.js → ScrollFloat.stories-Dzwz8uzu.js} +1 -1
  107. package/storybook-static/assets/{ScrollReveal.stories-W8gKKJkz.js → ScrollReveal.stories-C_EqHFb_.js} +1 -1
  108. package/storybook-static/assets/{ScrollVelocity.stories-BtBHIdDh.js → ScrollVelocity.stories-YdJitu_P.js} +1 -1
  109. package/storybook-static/assets/{SearchBar.stories-CKF_skS-.js → SearchBar.stories-BJbLKP2g.js} +1 -1
  110. package/storybook-static/assets/{SearchableDropdown-DjgPBW4S.js → SearchableDropdown-fnf6ZW_h.js} +1 -1
  111. package/storybook-static/assets/{SearchableDropdown.stories-C9lfureo.js → SearchableDropdown.stories-CJ8_zZjz.js} +1 -1
  112. package/storybook-static/assets/{SelectInput-D7sYzDrc.js → SelectInput-DXau1Dph.js} +1 -1
  113. package/storybook-static/assets/{SelectInput.stories-D-o6dXmn.js → SelectInput.stories-DuPwC-pM.js} +1 -1
  114. package/storybook-static/assets/{ShapeBlur.stories-C7c7wicM.js → ShapeBlur.stories-BzSypzdO.js} +1 -1
  115. package/storybook-static/assets/{ShapeGrid.stories-DrVQJIO7.js → ShapeGrid.stories-CDkUZpth.js} +1 -1
  116. package/storybook-static/assets/{ShinyText.stories-Bqs9oVTE.js → ShinyText.stories-CGKy0Lsc.js} +1 -1
  117. package/storybook-static/assets/{Silk.stories-DAfQOgwq.js → Silk.stories-CChDBqxY.js} +1 -1
  118. package/storybook-static/assets/{SleepChart.stories-C0QkrKDH.js → SleepChart.stories-WRltn-Jx.js} +1 -1
  119. package/storybook-static/assets/{Slider-Bdyo6Ygg.js → Slider-BeoCTJYT.js} +1 -1
  120. package/storybook-static/assets/{Slider.stories-DS51oQwf.js → Slider.stories-DVeQHWs3.js} +1 -1
  121. package/storybook-static/assets/{SoftAurora.stories-BTounCNw.js → SoftAurora.stories-DrO_ij-V.js} +1 -1
  122. package/storybook-static/assets/{SoundDemo.stories-DjSqbaqn.js → SoundDemo.stories-f1ehfLPn.js} +1 -1
  123. package/storybook-static/assets/{SplashCursor.stories-B2z2pfTN.js → SplashCursor.stories-BECToVQy.js} +1 -1
  124. package/storybook-static/assets/{SpotlightCard.stories-DFWy3Qsm.js → SpotlightCard.stories-Ck8nALce.js} +1 -1
  125. package/storybook-static/assets/{Stack.stories-eVxU6drS.js → Stack.stories-BdN1_7tM.js} +1 -1
  126. package/storybook-static/assets/{StaggeredMenu.stories-Be8MWGKS.js → StaggeredMenu.stories-CTDmplGV.js} +1 -1
  127. package/storybook-static/assets/{StarBorder.stories-buLGGhWU.js → StarBorder.stories-Bwpc59IM.js} +1 -1
  128. package/storybook-static/assets/{SunburstChart.stories-DwkU63M7.js → SunburstChart.stories-CNOZJwAZ.js} +1 -1
  129. package/storybook-static/assets/{Table.stories-D4MtUw5s.js → Table.stories-Cd6TvRiK.js} +1 -1
  130. package/storybook-static/assets/{Tabs.stories-CPFWVggt.js → Tabs.stories-BoVk_o27.js} +1 -1
  131. package/storybook-static/assets/{TargetCursor.stories-BIbnRiSZ.js → TargetCursor.stories-DdklJLjf.js} +1 -1
  132. package/storybook-static/assets/{TextArea-DDehMfhZ.js → TextArea-BoTwFvlF.js} +1 -1
  133. package/storybook-static/assets/{TextArea.stories-CpREuHFt.js → TextArea.stories-4mPBw5bl.js} +1 -1
  134. package/storybook-static/assets/{TextCursor.stories-BUDnLpvZ.js → TextCursor.stories-Dbz8i54O.js} +1 -1
  135. package/storybook-static/assets/{TextInput-CAzdMbcN.js → TextInput-DTyHhomU.js} +1 -1
  136. package/storybook-static/assets/{TextInput.stories-BfehwbP8.js → TextInput.stories-CjQMs9vK.js} +1 -1
  137. package/storybook-static/assets/{TextPressure.stories-DIKhiUzc.js → TextPressure.stories-Da2afCXS.js} +1 -1
  138. package/storybook-static/assets/{TextType.stories-DRbvgF_m.js → TextType.stories-DP8FaemU.js} +1 -1
  139. package/storybook-static/assets/{ThemeSwitcher.stories-cXhciw3M.js → ThemeSwitcher.stories-BOdoMWBr.js} +1 -1
  140. package/storybook-static/assets/{Threads.stories-xmcTjKpL.js → Threads.stories-Bsyw4BNf.js} +1 -1
  141. package/storybook-static/assets/{TimeInput.stories-DKFZtesR.js → TimeInput.stories-3qbOV7Ls.js} +1 -1
  142. package/storybook-static/assets/{Toggle-CC1WRtNx.js → Toggle-Bwvgtrvs.js} +1 -1
  143. package/storybook-static/assets/{Toggle.stories-BayZsnhd.js → Toggle.stories-BZa844c0.js} +1 -1
  144. package/storybook-static/assets/{ToggleButton-DNwMOk4B.js → ToggleButton-BINAb7TQ.js} +1 -1
  145. package/storybook-static/assets/{ToggleButton.stories-CE4iTjBV.js → ToggleButton.stories-GWQ4L4ac.js} +1 -1
  146. package/storybook-static/assets/{TrueFocus.stories-CaFMcY8L.js → TrueFocus.stories-CiK6TsZ_.js} +1 -1
  147. package/storybook-static/assets/{VariableProximity.stories-ChP4Tjlr.js → VariableProximity.stories-DE-_f9_v.js} +1 -1
  148. package/storybook-static/assets/{Waves.stories-Bv4PvTSw.js → Waves.stories-Bah9ng0K.js} +1 -1
  149. package/storybook-static/assets/{check-BksAJHcR.js → check-bvk6C-TA.js} +1 -1
  150. package/storybook-static/assets/{chevron-down-Ah_Qzuj-.js → chevron-down-Dnj3nVPe.js} +1 -1
  151. package/storybook-static/assets/{chevron-right-RJ7bLHYT.js → chevron-right-FoZPyhXE.js} +1 -1
  152. package/storybook-static/assets/client-Dyko2a81.js +1 -0
  153. package/storybook-static/assets/{createLucideIcon-Cw9oc6nQ.js → createLucideIcon-DvNKQIkb.js} +1 -1
  154. package/storybook-static/assets/{download-DeFjy7YQ.js → download-BEyY_c4w.js} +1 -1
  155. package/storybook-static/assets/{folder-DFqD7Xmc.js → folder-Dr-EdDO1.js} +1 -1
  156. package/storybook-static/assets/{iconBase-B0Y1EhGm.js → iconBase-daIQ2k2U.js} +1 -1
  157. package/storybook-static/assets/{iframe-wVHIxtK4.js → iframe-BmJYCQaV.js} +3 -3
  158. package/storybook-static/assets/{index-C6ccT3Cy.js → index-8y2D1xIF.js} +1 -1
  159. package/storybook-static/assets/{index-D6HUHJ-I.js → index-CCV231j6.js} +1 -1
  160. package/storybook-static/assets/{index-DAgWpYb7.js → index-GkLzrRJX.js} +1 -1
  161. package/storybook-static/assets/{proxy-DtFoluf3.js → proxy-MAU_yIzM.js} +1 -1
  162. package/storybook-static/assets/{react-18-CVRz73bU.js → react-18-DCqWj-iG.js} +1 -1
  163. package/storybook-static/assets/{react-three-fiber.esm-Dk2XrsuX.js → react-three-fiber.esm-J8Ycqtkj.js} +1 -1
  164. package/storybook-static/assets/{search-DdxW2DIt.js → search-T1_DPJWy.js} +1 -1
  165. package/storybook-static/assets/{settings-B7vVk5ZY.js → settings-D0WRQxad.js} +1 -1
  166. package/storybook-static/assets/{sun-E7lh9m5E.js → sun-D1G2h9I4.js} +1 -1
  167. package/storybook-static/assets/{trash-2-BWCK62PC.js → trash-2-B7B7imFa.js} +1 -1
  168. package/storybook-static/assets/{use-animation-frame-ByBIonQ_.js → use-animation-frame-C3OkOmFg.js} +1 -1
  169. package/storybook-static/assets/{use-in-view-BJexGYZY.js → use-in-view-BUiyIXbb.js} +1 -1
  170. package/storybook-static/assets/{use-motion-value-wRl_TaJk.js → use-motion-value-D1yqdG0l.js} +1 -1
  171. package/storybook-static/assets/{use-spring-BOIoQ2Wo.js → use-spring-BwMrSe4y.js} +1 -1
  172. package/storybook-static/assets/{use-transform-DK7n09PB.js → use-transform-CTCcIVjx.js} +1 -1
  173. package/storybook-static/assets/{useSound-DGHMGE7h.js → useSound-C72L733V.js} +1 -1
  174. package/storybook-static/assets/{users-B7vi8Bsk.js → users-DMXSY-kZ.js} +1 -1
  175. package/storybook-static/assets/{x-DxxcvklS.js → x-DzTJWbpQ.js} +1 -1
  176. package/storybook-static/iframe.html +1 -1
  177. package/storybook-static/project.json +1 -1
  178. package/storybook-static/assets/client-DfVgzhP2.js +0 -1
@@ -1,4 +1,4 @@
1
- import{j as u,r as c}from"./iframe-wVHIxtK4.js";import{g as v}from"./index-C8pce-KX.js";import"./preload-helper-C1FmrZbK.js";const W="_menu_hu66r_1",B="_menu__item_hu66r_15",S="_marquee_hu66r_49",T="_marquee__inner_hu66r_60",I="_marquee__part_hu66r_75",L="_marquee__img_hu66r_90",a={"menu-wrap":"_menu-wrap_hu66r_1",menu:W,menu__item:B,"menu__item-link":"_menu__item-link_hu66r_27",marquee:S,"marquee__inner-wrap":"_marquee__inner-wrap_hu66r_60",marquee__inner:T,marquee__part:I,marquee__img:L};function N({items:q=[],speed:l=15,textColor:f="#fff",bgColor:p="#060010",marqueeBgColor:g="#fff",marqueeTextColor:x="#060010",borderColor:C="#fff"}){return u.jsx("div",{className:`${a["menu-wrap"]}`,style:{backgroundColor:p},children:u.jsx("nav",{className:`${a.menu}`,children:q.map((y,i)=>u.jsx(A,{...y,speed:l,textColor:f,marqueeBgColor:g,marqueeTextColor:x,borderColor:C},i))})})}function A({link:q,text:l,image:f,speed:p,textColor:g,marqueeBgColor:x,marqueeTextColor:C,borderColor:y}){const i=c.useRef(null),m=c.useRef(null),o=c.useRef(null),d=c.useRef(null),[w,$]=c.useState(4),k={duration:.6,ease:"expo"},b=(t,e,r,n)=>{const s=j(t,e,r/2,0),_=j(t,e,r/2,n);return s<_?"top":"bottom"},j=(t,e,r,n)=>{const s=t-r,_=e-n;return s*s+_*_};c.useEffect(()=>{const t=()=>{if(!o.current)return;const e=o.current.querySelector("[data-marquee-part]");if(!e)return;const r=e.offsetWidth,n=window.innerWidth,s=Math.ceil(n/r)+2;$(Math.max(4,s))};return t(),window.addEventListener("resize",t),()=>window.removeEventListener("resize",t)},[l,f]),c.useEffect(()=>{const e=setTimeout(()=>{if(!o.current)return;const r=o.current.querySelector("[data-marquee-part]");if(!r)return;const n=r.offsetWidth;n!==0&&(d.current&&d.current.kill(),d.current=v.to(o.current,{x:-n,duration:p,ease:"none",repeat:-1}))},50);return()=>{clearTimeout(e),d.current&&d.current.kill()}},[l,f,w,p]);const D=t=>{if(!i.current||!m.current||!o.current)return;const e=i.current.getBoundingClientRect(),r=t.clientX-e.left,n=t.clientY-e.top,s=b(r,n,e.width,e.height);v.timeline({defaults:k}).set(m.current,{y:s==="top"?"-101%":"101%"},0).set(o.current,{y:s==="top"?"101%":"-101%"},0).to([m.current,o.current],{y:"0%"},0)},V=t=>{if(!i.current||!m.current||!o.current)return;const e=i.current.getBoundingClientRect(),r=t.clientX-e.left,n=t.clientY-e.top,s=b(r,n,e.width,e.height);v.timeline({defaults:k}).to(m.current,{y:s==="top"?"-101%":"101%"},0).to(o.current,{y:s==="top"?"101%":"-101%"},0)};return u.jsxs("div",{className:`${a.menu__item}`,ref:i,style:{borderColor:y},children:[u.jsx("a",{className:`${a["menu__item-link"]}`,href:q,onMouseEnter:D,onMouseLeave:V,style:{color:g},children:l}),u.jsx("div",{className:`${a.marquee}`,ref:m,style:{backgroundColor:x},children:u.jsx("div",{className:`${a["marquee__inner-wrap"]}`,children:u.jsx("div",{className:`${a.marquee__inner}`,ref:o,"aria-hidden":"true",children:[...Array(w)].map((t,e)=>u.jsxs("div",{className:`${a.marquee__part}`,"data-marquee-part":!0,style:{color:C},children:[u.jsx("span",{children:l}),u.jsx("div",{className:`${a.marquee__img}`,style:{backgroundImage:`url(${f})`}})]},e))})})})]})}N.__docgenInfo={description:"",methods:[],displayName:"FlowingMenu",props:{items:{defaultValue:{value:"[]",computed:!1},required:!1},speed:{defaultValue:{value:"15",computed:!1},required:!1},textColor:{defaultValue:{value:"'#fff'",computed:!1},required:!1},bgColor:{defaultValue:{value:"'#060010'",computed:!1},required:!1},marqueeBgColor:{defaultValue:{value:"'#fff'",computed:!1},required:!1},marqueeTextColor:{defaultValue:{value:"'#060010'",computed:!1},required:!1},borderColor:{defaultValue:{value:"'#fff'",computed:!1},required:!1}}};const P={title:"ReactBits/Components/FlowingMenu",component:N,parameters:{layout:"fullscreen"}},h={args:{items:[{link:"#",text:"Home",image:"https://picsum.photos/seed/a/600/400"},{link:"#",text:"About",image:"https://picsum.photos/seed/b/600/400"},{link:"#",text:"Projects",image:"https://picsum.photos/seed/c/600/400"},{link:"#",text:"Contact",image:"https://picsum.photos/seed/d/600/400"}],speed:15,textColor:"#fff",bgColor:"#060010",marqueeBgColor:"#fff",marqueeTextColor:"#060010",borderColor:"#fff"}};var R,M,E;h.parameters={...h.parameters,docs:{...(R=h.parameters)==null?void 0:R.docs,source:{originalSource:`{
1
+ import{j as u,r as c}from"./iframe-BmJYCQaV.js";import{g as v}from"./index-C8pce-KX.js";import"./preload-helper-C1FmrZbK.js";const W="_menu_hu66r_1",B="_menu__item_hu66r_15",S="_marquee_hu66r_49",T="_marquee__inner_hu66r_60",I="_marquee__part_hu66r_75",L="_marquee__img_hu66r_90",a={"menu-wrap":"_menu-wrap_hu66r_1",menu:W,menu__item:B,"menu__item-link":"_menu__item-link_hu66r_27",marquee:S,"marquee__inner-wrap":"_marquee__inner-wrap_hu66r_60",marquee__inner:T,marquee__part:I,marquee__img:L};function N({items:q=[],speed:l=15,textColor:f="#fff",bgColor:p="#060010",marqueeBgColor:g="#fff",marqueeTextColor:x="#060010",borderColor:C="#fff"}){return u.jsx("div",{className:`${a["menu-wrap"]}`,style:{backgroundColor:p},children:u.jsx("nav",{className:`${a.menu}`,children:q.map((y,i)=>u.jsx(A,{...y,speed:l,textColor:f,marqueeBgColor:g,marqueeTextColor:x,borderColor:C},i))})})}function A({link:q,text:l,image:f,speed:p,textColor:g,marqueeBgColor:x,marqueeTextColor:C,borderColor:y}){const i=c.useRef(null),m=c.useRef(null),o=c.useRef(null),d=c.useRef(null),[w,$]=c.useState(4),k={duration:.6,ease:"expo"},b=(t,e,r,n)=>{const s=j(t,e,r/2,0),_=j(t,e,r/2,n);return s<_?"top":"bottom"},j=(t,e,r,n)=>{const s=t-r,_=e-n;return s*s+_*_};c.useEffect(()=>{const t=()=>{if(!o.current)return;const e=o.current.querySelector("[data-marquee-part]");if(!e)return;const r=e.offsetWidth,n=window.innerWidth,s=Math.ceil(n/r)+2;$(Math.max(4,s))};return t(),window.addEventListener("resize",t),()=>window.removeEventListener("resize",t)},[l,f]),c.useEffect(()=>{const e=setTimeout(()=>{if(!o.current)return;const r=o.current.querySelector("[data-marquee-part]");if(!r)return;const n=r.offsetWidth;n!==0&&(d.current&&d.current.kill(),d.current=v.to(o.current,{x:-n,duration:p,ease:"none",repeat:-1}))},50);return()=>{clearTimeout(e),d.current&&d.current.kill()}},[l,f,w,p]);const D=t=>{if(!i.current||!m.current||!o.current)return;const e=i.current.getBoundingClientRect(),r=t.clientX-e.left,n=t.clientY-e.top,s=b(r,n,e.width,e.height);v.timeline({defaults:k}).set(m.current,{y:s==="top"?"-101%":"101%"},0).set(o.current,{y:s==="top"?"101%":"-101%"},0).to([m.current,o.current],{y:"0%"},0)},V=t=>{if(!i.current||!m.current||!o.current)return;const e=i.current.getBoundingClientRect(),r=t.clientX-e.left,n=t.clientY-e.top,s=b(r,n,e.width,e.height);v.timeline({defaults:k}).to(m.current,{y:s==="top"?"-101%":"101%"},0).to(o.current,{y:s==="top"?"101%":"-101%"},0)};return u.jsxs("div",{className:`${a.menu__item}`,ref:i,style:{borderColor:y},children:[u.jsx("a",{className:`${a["menu__item-link"]}`,href:q,onMouseEnter:D,onMouseLeave:V,style:{color:g},children:l}),u.jsx("div",{className:`${a.marquee}`,ref:m,style:{backgroundColor:x},children:u.jsx("div",{className:`${a["marquee__inner-wrap"]}`,children:u.jsx("div",{className:`${a.marquee__inner}`,ref:o,"aria-hidden":"true",children:[...Array(w)].map((t,e)=>u.jsxs("div",{className:`${a.marquee__part}`,"data-marquee-part":!0,style:{color:C},children:[u.jsx("span",{children:l}),u.jsx("div",{className:`${a.marquee__img}`,style:{backgroundImage:`url(${f})`}})]},e))})})})]})}N.__docgenInfo={description:"",methods:[],displayName:"FlowingMenu",props:{items:{defaultValue:{value:"[]",computed:!1},required:!1},speed:{defaultValue:{value:"15",computed:!1},required:!1},textColor:{defaultValue:{value:"'#fff'",computed:!1},required:!1},bgColor:{defaultValue:{value:"'#060010'",computed:!1},required:!1},marqueeBgColor:{defaultValue:{value:"'#fff'",computed:!1},required:!1},marqueeTextColor:{defaultValue:{value:"'#060010'",computed:!1},required:!1},borderColor:{defaultValue:{value:"'#fff'",computed:!1},required:!1}}};const P={title:"ReactBits/Components/FlowingMenu",component:N,parameters:{layout:"fullscreen"}},h={args:{items:[{link:"#",text:"Home",image:"https://picsum.photos/seed/a/600/400"},{link:"#",text:"About",image:"https://picsum.photos/seed/b/600/400"},{link:"#",text:"Projects",image:"https://picsum.photos/seed/c/600/400"},{link:"#",text:"Contact",image:"https://picsum.photos/seed/d/600/400"}],speed:15,textColor:"#fff",bgColor:"#060010",marqueeBgColor:"#fff",marqueeTextColor:"#060010",borderColor:"#fff"}};var R,M,E;h.parameters={...h.parameters,docs:{...(R=h.parameters)==null?void 0:R.docs,source:{originalSource:`{
2
2
  args: {
3
3
  items: [{
4
4
  link: '#',
@@ -1,4 +1,4 @@
1
- import{r as V,j as Ee}from"./iframe-wVHIxtK4.js";import{u as We,a as yt,c as oo,s as os,b as Ut,e as pa,C as as,d as ss}from"./react-three-fiber.esm-Dk2XrsuX.js";import{d as qe,e as ke,aa as bt,ab as Ct,ac as is,u as wt,n as Pe,ad as cs,a0 as ma,ae as ls,af as mr,ag as Ba,ah as va,ai as nn,aj as xn,ak as $e,al as us,am as fs,an as ds,ao as hs,ap as ga,O as Ca,aq as Un,ar as As,t as rn,as as ps,at as ya,au as ms,av as Bs,aw as vs,z as In,a5 as gs,ax as Br,ay as Cs,a7 as ys,az as bs,a1 as or,aA as Fs,x as ba,_ as Fa,p as xt,aB as Es,h as Ea,aC as Ms,M as _n,a8 as Ts,aD as Ds,aE as Gs,aF as Rs,aG as ar,P as xs,r as Ma,a as Is,aH as Ss,aI as ws,aJ as Us,aK as _s,aL as Ta,aM as Ls,a2 as cn,aN as ao,aO as so,aP as io,$ as Da,aQ as ks,aR as Gr,aS as Ga,aT as Os,aU as Hs,aV as Ps,j as Ra,aW as Js,aX as Ns,aY as Ks,q as Rr,i as js,N as Qs,Z as Xs,aZ as Ws,a_ as Ys,S as Vs}from"./three.module--_vTUKhS.js";import{_ as st}from"./extends-CF3RwP-h.js";import{c as zs}from"./client-DfVgzhP2.js";import{u as vr}from"./Fbo-BuZjyF_I.js";import"./preload-helper-C1FmrZbK.js";import"./index-C6ccT3Cy.js";function on(u,t,i){return t in u?Object.defineProperty(u,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):u[t]=i,u}function gr(u,t){(t==null||t>u.length)&&(t=u.length);for(var i=0,c=new Array(t);i<t;i++)c[i]=u[i];return c}function Zs(u,t){if(u){if(typeof u=="string")return gr(u,t);var i=Object.prototype.toString.call(u).slice(8,-1);if(i==="Object"&&u.constructor&&(i=u.constructor.name),i==="Map"||i==="Set")return Array.from(u);if(i==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i))return gr(u,t)}}function qs(u){if(Array.isArray(u))return gr(u)}function $s(u){if(typeof Symbol<"u"&&u[Symbol.iterator]!=null||u["@@iterator"]!=null)return Array.from(u)}function ei(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
1
+ import{r as V,j as Ee}from"./iframe-BmJYCQaV.js";import{u as We,a as yt,c as oo,s as os,b as Ut,e as pa,C as as,d as ss}from"./react-three-fiber.esm-J8Ycqtkj.js";import{d as qe,e as ke,aa as bt,ab as Ct,ac as is,u as wt,n as Pe,ad as cs,a0 as ma,ae as ls,af as mr,ag as Ba,ah as va,ai as nn,aj as xn,ak as $e,al as us,am as fs,an as ds,ao as hs,ap as ga,O as Ca,aq as Un,ar as As,t as rn,as as ps,at as ya,au as ms,av as Bs,aw as vs,z as In,a5 as gs,ax as Br,ay as Cs,a7 as ys,az as bs,a1 as or,aA as Fs,x as ba,_ as Fa,p as xt,aB as Es,h as Ea,aC as Ms,M as _n,a8 as Ts,aD as Ds,aE as Gs,aF as Rs,aG as ar,P as xs,r as Ma,a as Is,aH as Ss,aI as ws,aJ as Us,aK as _s,aL as Ta,aM as Ls,a2 as cn,aN as ao,aO as so,aP as io,$ as Da,aQ as ks,aR as Gr,aS as Ga,aT as Os,aU as Hs,aV as Ps,j as Ra,aW as Js,aX as Ns,aY as Ks,q as Rr,i as js,N as Qs,Z as Xs,aZ as Ws,a_ as Ys,S as Vs}from"./three.module--_vTUKhS.js";import{_ as st}from"./extends-CF3RwP-h.js";import{c as zs}from"./client-Dyko2a81.js";import{u as vr}from"./Fbo-BckR5Q0w.js";import"./preload-helper-C1FmrZbK.js";import"./index-8y2D1xIF.js";function on(u,t,i){return t in u?Object.defineProperty(u,t,{value:i,enumerable:!0,configurable:!0,writable:!0}):u[t]=i,u}function gr(u,t){(t==null||t>u.length)&&(t=u.length);for(var i=0,c=new Array(t);i<t;i++)c[i]=u[i];return c}function Zs(u,t){if(u){if(typeof u=="string")return gr(u,t);var i=Object.prototype.toString.call(u).slice(8,-1);if(i==="Object"&&u.constructor&&(i=u.constructor.name),i==="Map"||i==="Set")return Array.from(u);if(i==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i))return gr(u,t)}}function qs(u){if(Array.isArray(u))return gr(u)}function $s(u){if(typeof Symbol<"u"&&u[Symbol.iterator]!=null||u["@@iterator"]!=null)return Array.from(u)}function ei(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
2
2
  In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ti(u){return qs(u)||$s(u)||Zs(u)||ei()}new qe;new qe;function ni(u,t,i){return Math.max(t,Math.min(i,u))}function ri(u,t){return ni(u-Math.floor(u/t)*t,0,t)}function oi(u,t){var i=ri(t-u,Math.PI*2);return i>Math.PI&&(i-=Math.PI*2),i}function xa(u,t){if(!(u instanceof t))throw new TypeError("Cannot call a class as a function")}var Qe=function u(t,i,c){var n=this;xa(this,u),on(this,"dot2",function(e,r){return n.x*e+n.y*r}),on(this,"dot3",function(e,r,a){return n.x*e+n.y*r+n.z*a}),this.x=t,this.y=i,this.z=c},ai=[new Qe(1,1,0),new Qe(-1,1,0),new Qe(1,-1,0),new Qe(-1,-1,0),new Qe(1,0,1),new Qe(-1,0,1),new Qe(1,0,-1),new Qe(-1,0,-1),new Qe(0,1,1),new Qe(0,-1,1),new Qe(0,1,-1),new Qe(0,-1,-1)],co=[151,160,137,91,90,15,131,13,201,95,96,53,194,233,7,225,140,36,103,30,69,142,8,99,37,240,21,10,23,190,6,148,247,120,234,75,0,26,197,62,94,252,219,203,117,35,11,32,57,177,33,88,237,149,56,87,174,20,125,136,171,168,68,175,74,165,71,134,139,48,27,166,77,146,158,231,83,111,229,122,60,211,133,230,220,105,92,41,55,46,245,40,244,102,143,54,65,25,63,161,1,216,80,73,209,76,132,187,208,89,18,169,200,196,135,130,116,188,159,86,164,100,109,198,173,186,3,64,52,217,226,250,124,123,5,202,38,147,118,126,255,82,85,212,207,206,59,227,47,16,58,17,182,189,28,42,223,183,170,213,119,248,152,2,44,154,163,70,221,153,101,155,167,43,172,9,129,22,39,253,19,98,108,110,79,113,224,232,178,185,112,104,218,246,97,228,251,34,242,193,238,210,144,12,191,179,162,241,81,51,145,235,249,14,239,107,49,192,214,31,181,199,106,157,184,84,204,176,115,121,50,45,127,4,150,254,138,236,205,93,222,114,67,29,24,72,243,141,128,195,78,66,215,61,156,180],lo=new Array(512),uo=new Array(512),si=function(t){t>0&&t<1&&(t*=65536),t=Math.floor(t),t<256&&(t|=t<<8);for(var i=0;i<256;i++){var c;i&1?c=co[i]^t&255:c=co[i]^t>>8&255,lo[i]=lo[i+256]=c,uo[i]=uo[i+256]=ai[c%12]}};si(0);function ii(u){if(typeof u=="number")u=Math.abs(u);else if(typeof u=="string"){var t=u;u=0;for(var i=0;i<t.length;i++)u=(u+(i+1)*(t.charCodeAt(i)%96))%2147483647}return u===0&&(u=311),u}function fo(u){var t=ii(u);return function(){var i=t*48271%2147483647;return t=i,i/2147483647}}var ci=function u(t){var i=this;xa(this,u),on(this,"seed",0),on(this,"init",function(c){i.seed=c,i.value=fo(c)}),on(this,"value",fo(this.seed)),this.init(t)};new ci(Math.random());var li=function(t){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:.01,c=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,n=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1/(2*Math.PI);return c/Math.atan(1/i)*Math.atan(Math.sin(2*Math.PI*t*n)/i)},Ia=function(t){return 1/(1+t+.48*t*t+.235*t*t*t)},ui=function(t){return t},fi={in:function(t){return 1-Math.cos(t*Math.PI/2)},out:function(t){return Math.sin(t*Math.PI/2)},inOut:function(t){return-(Math.cos(Math.PI*t)-1)/2}},di={in:function(t){return t*t*t},out:function(t){return 1-Math.pow(1-t,3)},inOut:function(t){return t<.5?4*t*t*t:1-Math.pow(-2*t+2,3)/2}},hi={in:function(t){return t*t*t*t*t},out:function(t){return 1-Math.pow(1-t,5)},inOut:function(t){return t<.5?16*t*t*t*t*t:1-Math.pow(-2*t+2,5)/2}},Ai={in:function(t){return 1-Math.sqrt(1-Math.pow(t,2))},out:function(t){return Math.sqrt(1-Math.pow(t-1,2))},inOut:function(t){return t<.5?(1-Math.sqrt(1-Math.pow(2*t,2)))/2:(Math.sqrt(1-Math.pow(-2*t+2,2))+1)/2}},pi={in:function(t){return t*t*t*t},out:function(t){return 1- --t*t*t*t},inOut:function(t){return t<.5?8*t*t*t*t:1-8*--t*t*t*t}},mi={in:function(t){return t===0?0:Math.pow(2,10*t-10)},out:function(t){return t===1?1:1-Math.pow(2,-10*t)},inOut:function(t){return t===0?0:t===1?1:t<.5?Math.pow(2,20*t-10)/2:(2-Math.pow(2,-20*t+10))/2}};function Ue(u,t,i){var c=arguments.length>3&&arguments[3]!==void 0?arguments[3]:.25,n=arguments.length>4&&arguments[4]!==void 0?arguments[4]:.01,e=arguments.length>5&&arguments[5]!==void 0?arguments[5]:1/0,r=arguments.length>6&&arguments[6]!==void 0?arguments[6]:Ia,a=arguments.length>7&&arguments[7]!==void 0?arguments[7]:.001,o="velocity_"+t;if(u.__damp===void 0&&(u.__damp={}),u.__damp[o]===void 0&&(u.__damp[o]=0),Math.abs(u[t]-i)<=a)return u[t]=i,!1;c=Math.max(1e-4,c);var s=2/c,l=r(s*n),f=u[t]-i,d=i,h=e*c;f=Math.min(Math.max(f,-h),h),i=u[t]-f;var A=(u.__damp[o]+s*f)*n;u.__damp[o]=(u.__damp[o]-s*A)*l;var m=i+(f+A)*l;return d-u[t]>0==m>d&&(m=d,u.__damp[o]=(m-d)/n),u[t]=m,!0}var Bi=function(t){return t&&t.isCamera},vi=function(t){return t&&t.isLight},Xt=new ke,ho=new bt,Ao=new bt,Wt=new Ct,sr=new ke;function gi(u,t,i,c,n,e,r){typeof t=="number"?Xt.setScalar(t):Array.isArray(t)?Xt.set(t[0],t[1],t[2]):Xt.copy(t);var a=u.parent;u.updateWorldMatrix(!0,!1),sr.setFromMatrixPosition(u.matrixWorld),Bi(u)||vi(u)?Wt.lookAt(sr,Xt,u.up):Wt.lookAt(Xt,sr,u.up),Sn(u.quaternion,Ao.setFromRotationMatrix(Wt),i,c,n,e,r),a&&(Wt.extractRotation(a.matrixWorld),ho.setFromRotationMatrix(Wt),Sn(u.quaternion,Ao.copy(u.quaternion).premultiply(ho.invert()),i,c,n,e,r))}function It(u,t,i,c,n,e,r,a){return Ue(u,t,u[t]+oi(u[t],i),c,n,e,r,a)}var Yt=new qe,po,mo;function Ci(u,t,i,c,n,e,r){return typeof t=="number"?Yt.setScalar(t):Array.isArray(t)?Yt.set(t[0],t[1]):Yt.copy(t),po=Ue(u,"x",Yt.x,i,c,n,e,r),mo=Ue(u,"y",Yt.y,i,c,n,e,r),po||mo}var Dt=new ke,Bo,vo,go;function Cr(u,t,i,c,n,e,r){return typeof t=="number"?Dt.setScalar(t):Array.isArray(t)?Dt.set(t[0],t[1],t[2]):Dt.copy(t),Bo=Ue(u,"x",Dt.x,i,c,n,e,r),vo=Ue(u,"y",Dt.y,i,c,n,e,r),go=Ue(u,"z",Dt.z,i,c,n,e,r),Bo||vo||go}var pt=new wt,Co,yo,bo,Fo;function yi(u,t,i,c,n,e,r){return typeof t=="number"?pt.setScalar(t):Array.isArray(t)?pt.set(t[0],t[1],t[2],t[3]):pt.copy(t),Co=Ue(u,"x",pt.x,i,c,n,e,r),yo=Ue(u,"y",pt.y,i,c,n,e,r),bo=Ue(u,"z",pt.z,i,c,n,e,r),Fo=Ue(u,"w",pt.w,i,c,n,e,r),Co||yo||bo||Fo}var Vt=new cs,Eo,Mo,To;function bi(u,t,i,c,n,e,r){return Array.isArray(t)?Vt.set(t[0],t[1],t[2],t[3]):Vt.copy(t),Eo=It(u,"x",Vt.x,i,c,n,e,r),Mo=It(u,"y",Vt.y,i,c,n,e,r),To=It(u,"z",Vt.z,i,c,n,e,r),Eo||Mo||To}var Gt=new Pe,Do,Go,Ro;function Fi(u,t,i,c,n,e,r){return t instanceof Pe?Gt.copy(t):Array.isArray(t)?Gt.setRGB(t[0],t[1],t[2]):Gt.set(t),Do=Ue(u,"r",Gt.r,i,c,n,e,r),Go=Ue(u,"g",Gt.g,i,c,n,e,r),Ro=Ue(u,"b",Gt.b,i,c,n,e,r),Do||Go||Ro}var Ze=new bt,rt=new wt,xo=new wt,zt=new wt,Io,So,wo,Uo;function Sn(u,t,i,c,n,e,r){var a=u;Array.isArray(t)?Ze.set(t[0],t[1],t[2],t[3]):Ze.copy(t);var o=u.dot(Ze)>0?1:-1;return Ze.x*=o,Ze.y*=o,Ze.z*=o,Ze.w*=o,Io=Ue(u,"x",Ze.x,i,c,n,e,r),So=Ue(u,"y",Ze.y,i,c,n,e,r),wo=Ue(u,"z",Ze.z,i,c,n,e,r),Uo=Ue(u,"w",Ze.w,i,c,n,e,r),rt.set(u.x,u.y,u.z,u.w).normalize(),xo.set(a.__damp.velocity_x,a.__damp.velocity_y,a.__damp.velocity_z,a.__damp.velocity_w),zt.copy(rt).multiplyScalar(xo.dot(rt)/rt.dot(rt)),a.__damp.velocity_x-=zt.x,a.__damp.velocity_y-=zt.y,a.__damp.velocity_z-=zt.z,a.__damp.velocity_w-=zt.w,u.set(rt.x,rt.y,rt.z,rt.w),Io||So||wo||Uo}var Zt=new is,_o,Lo,ko;function Ei(u,t,i,c,n,e,r){return Array.isArray(t)?Zt.set(t[0],t[1],t[2]):Zt.copy(t),_o=Ue(u,"radius",Zt.radius,i,c,n,e,r),Lo=It(u,"phi",Zt.phi,i,c,n,e,r),ko=It(u,"theta",Zt.theta,i,c,n,e,r),_o||Lo||ko}var bn=new Ct,Oo=new ke,Ho=new bt,Po=new ke,Jo,No,Ko;function Mi(u,t,i,c,n,e,r){var a=u;return a.__damp===void 0&&(a.__damp={position:new ke,rotation:new bt,scale:new ke},u.decompose(a.__damp.position,a.__damp.rotation,a.__damp.scale)),Array.isArray(t)?bn.set.apply(bn,ti(t)):bn.copy(t),bn.decompose(Oo,Ho,Po),Jo=Cr(a.__damp.position,Oo,i,c,n,e,r),No=Sn(a.__damp.rotation,Ho,i,c,n,e,r),Ko=Cr(a.__damp.scale,Po,i,c,n,e,r),u.compose(a.__damp.position,a.__damp.rotation,a.__damp.scale),Jo||No||Ko}var yr=Object.freeze({__proto__:null,rsqw:li,exp:Ia,linear:ui,sine:fi,cubic:di,quint:hi,circ:Ai,quart:pi,expo:mi,damp:Ue,dampLookAt:gi,dampAngle:It,damp2:Ci,damp3:Cr,damp4:yi,dampE:bi,dampC:Fi,dampQ:Sn,dampS:Ei,dampM:Mi});const xr=V.createContext(null);function Ir(){return V.useContext(xr)}function Ti({eps:u=1e-5,enabled:t=!0,infinite:i,horizontal:c,pages:n=1,distance:e=1,damping:r=.25,maxSpeed:a=1/0,prepend:o=!1,style:s={},children:l}){const{get:f,setEvents:d,gl:h,size:A,invalidate:m,events:p}=We(),[v]=V.useState(()=>document.createElement("div")),[C]=V.useState(()=>document.createElement("div")),[b]=V.useState(()=>document.createElement("div")),g=h.domElement.parentNode,E=V.useRef(0),D=V.useMemo(()=>({el:v,eps:u,fill:C,fixed:b,horizontal:c,damping:r,offset:0,delta:0,scroll:E,pages:n,range(U,x,K=0){const y=U-K,S=y+x+K*2;return this.offset<y?0:this.offset>S?1:(this.offset-y)/(S-y)},curve(U,x,K=0){return Math.sin(this.range(U,x,K)*Math.PI)},visible(U,x,K=0){const y=U-K,S=y+x+K*2;return this.offset>=y&&this.offset<=S}}),[u,r,c,n]);V.useEffect(()=>{v.style.position="absolute",v.style.width="100%",v.style.height="100%",v.style[c?"overflowX":"overflowY"]="auto",v.style[c?"overflowY":"overflowX"]="hidden",v.style.top="0px",v.style.left="0px";for(const x in s)v.style[x]=s[x];b.style.position="sticky",b.style.top="0px",b.style.left="0px",b.style.width="100%",b.style.height="100%",b.style.overflow="hidden",v.appendChild(b),C.style.height=c?"100%":`${n*e*100}%`,C.style.width=c?`${n*e*100}%`:"100%",C.style.pointerEvents="none",v.appendChild(C),o?g.prepend(v):g.appendChild(v),v[c?"scrollLeft":"scrollTop"]=1;const M=p.connected||h.domElement;requestAnimationFrame(()=>p.connect==null?void 0:p.connect(v));const U=f().events.compute;return d({compute(x,K){const{left:y,top:S}=g.getBoundingClientRect(),G=x.clientX-y,j=x.clientY-S;K.pointer.set(G/K.size.width*2-1,-(j/K.size.height)*2+1),K.raycaster.setFromCamera(K.pointer,K.camera)}}),()=>{g.removeChild(v),d({compute:U}),p.connect==null||p.connect(M)}},[n,e,c,v,C,b,g]),V.useEffect(()=>{if(p.connected===v){const M=A[c?"width":"height"],U=v[c?"scrollWidth":"scrollHeight"],x=U-M;let K=0,y=!0,S=!0;const G=()=>{if(!(!t||S)&&(m(),K=v[c?"scrollLeft":"scrollTop"],E.current=K/x,i)){if(!y){if(K>=x){const P=1-D.offset;v[c?"scrollLeft":"scrollTop"]=1,E.current=D.offset=-P,y=!0}else if(K<=0){const P=1+D.offset;v[c?"scrollLeft":"scrollTop"]=U,E.current=D.offset=P,y=!0}}y&&setTimeout(()=>y=!1,40)}};v.addEventListener("scroll",G,{passive:!0}),requestAnimationFrame(()=>S=!1);const j=P=>v.scrollLeft+=P.deltaY/2;return c&&v.addEventListener("wheel",j,{passive:!0}),()=>{v.removeEventListener("scroll",G),c&&v.removeEventListener("wheel",j)}}},[v,p,A,i,D,m,c,t]);let F=0;return yt((M,U)=>{F=D.offset,yr.damp(D,"offset",E.current,r,U,a,void 0,u),yr.damp(D,"delta",Math.abs(F-D.offset),r,U,a,void 0,u),D.delta>u&&m()}),V.createElement(xr.Provider,{value:D},l)}const Di=V.forwardRef(({children:u},t)=>{const i=V.useRef(null);V.useImperativeHandle(t,()=>i.current,[]);const c=Ir(),{width:n,height:e}=We(r=>r.viewport);return yt(()=>{i.current.position.x=c.horizontal?-n*(c.pages-1)*c.offset:0,i.current.position.y=c.horizontal?0:e*(c.pages-1)*c.offset}),V.createElement("group",{ref:i},u)}),Gi=V.forwardRef(({children:u,style:t,...i},c)=>{const n=Ir(),e=V.useRef(null);V.useImperativeHandle(c,()=>e.current,[]);const{width:r,height:a}=We(l=>l.size),o=V.useContext(oo),s=V.useMemo(()=>zs(n.fixed),[n.fixed]);return yt(()=>{n.delta>n.eps&&(e.current.style.transform=`translate3d(${n.horizontal?-r*(n.pages-1)*n.offset:0}px,${n.horizontal?0:a*(n.pages-1)*-n.offset}px,0)`)}),s.render(V.createElement("div",st({ref:e,style:{...t,position:"absolute",top:0,left:0,willChange:"transform"}},i),V.createElement(xr.Provider,{value:n},V.createElement(oo.Provider,{value:o},u)))),null}),jo=V.forwardRef(({html:u,...t},i)=>{const c=u?Gi:Di;return V.createElement(c,st({ref:i},t))}),Ri=parseInt(ma.replace(/\D+/g,""));function Qo(u,t){if(t===ls)return console.warn("THREE.BufferGeometryUtils.toTrianglesDrawMode(): Geometry already defined as triangles."),u;if(t===mr||t===Ba){let i=u.getIndex();if(i===null){const r=[],a=u.getAttribute("position");if(a!==void 0){for(let o=0;o<a.count;o++)r.push(o);u.setIndex(r),i=u.getIndex()}else return console.error("THREE.BufferGeometryUtils.toTrianglesDrawMode(): Undefined position attribute. Processing not possible."),u}const c=i.count-2,n=[];if(i)if(t===mr)for(let r=1;r<=c;r++)n.push(i.getX(0)),n.push(i.getX(r)),n.push(i.getX(r+1));else for(let r=0;r<c;r++)r%2===0?(n.push(i.getX(r)),n.push(i.getX(r+1)),n.push(i.getX(r+2))):(n.push(i.getX(r+2)),n.push(i.getX(r+1)),n.push(i.getX(r)));n.length/3!==c&&console.error("THREE.BufferGeometryUtils.toTrianglesDrawMode(): Unable to generate correct amount of triangles.");const e=u.clone();return e.setIndex(n),e.clearGroups(),e}else return console.error("THREE.BufferGeometryUtils.toTrianglesDrawMode(): Unknown draw mode:",t),u}function wn(u){if(typeof TextDecoder<"u")return new TextDecoder().decode(u);let t="";for(let i=0,c=u.length;i<c;i++)t+=String.fromCharCode(u[i]);try{return decodeURIComponent(escape(t))}catch{return t}}const vt="srgb",at="srgb-linear",Xo=3001,xi=3e3;class Sr extends va{constructor(t){super(t),this.dracoLoader=null,this.ktx2Loader=null,this.meshoptDecoder=null,this.pluginCallbacks=[],this.register(function(i){return new _i(i)}),this.register(function(i){return new Li(i)}),this.register(function(i){return new Qi(i)}),this.register(function(i){return new Xi(i)}),this.register(function(i){return new Wi(i)}),this.register(function(i){return new Oi(i)}),this.register(function(i){return new Hi(i)}),this.register(function(i){return new Pi(i)}),this.register(function(i){return new Ji(i)}),this.register(function(i){return new Ui(i)}),this.register(function(i){return new Ni(i)}),this.register(function(i){return new ki(i)}),this.register(function(i){return new ji(i)}),this.register(function(i){return new Ki(i)}),this.register(function(i){return new Si(i)}),this.register(function(i){return new Yi(i)}),this.register(function(i){return new Vi(i)})}load(t,i,c,n){const e=this;let r;if(this.resourcePath!=="")r=this.resourcePath;else if(this.path!==""){const s=nn.extractUrlBase(t);r=nn.resolveURL(s,this.path)}else r=nn.extractUrlBase(t);this.manager.itemStart(t);const a=function(s){n?n(s):console.error(s),e.manager.itemError(t),e.manager.itemEnd(t)},o=new xn(this.manager);o.setPath(this.path),o.setResponseType("arraybuffer"),o.setRequestHeader(this.requestHeader),o.setWithCredentials(this.withCredentials),o.load(t,function(s){try{e.parse(s,r,function(l){i(l),e.manager.itemEnd(t)},a)}catch(l){a(l)}},c,a)}setDRACOLoader(t){return this.dracoLoader=t,this}setDDSLoader(){throw new Error('THREE.GLTFLoader: "MSFT_texture_dds" no longer supported. Please update to "KHR_texture_basisu".')}setKTX2Loader(t){return this.ktx2Loader=t,this}setMeshoptDecoder(t){return this.meshoptDecoder=t,this}register(t){return this.pluginCallbacks.indexOf(t)===-1&&this.pluginCallbacks.push(t),this}unregister(t){return this.pluginCallbacks.indexOf(t)!==-1&&this.pluginCallbacks.splice(this.pluginCallbacks.indexOf(t),1),this}parse(t,i,c,n){let e;const r={},a={};if(typeof t=="string")e=JSON.parse(t);else if(t instanceof ArrayBuffer)if(wn(new Uint8Array(t.slice(0,4)))===Sa){try{r[ge.KHR_BINARY_GLTF]=new zi(t)}catch(l){n&&n(l);return}e=JSON.parse(r[ge.KHR_BINARY_GLTF].content)}else e=JSON.parse(wn(new Uint8Array(t)));else e=t;if(e.asset===void 0||e.asset.version[0]<2){n&&n(new Error("THREE.GLTFLoader: Unsupported asset. glTF versions >=2.0 are supported."));return}const o=new lc(e,{path:i||this.resourcePath||"",crossOrigin:this.crossOrigin,requestHeader:this.requestHeader,manager:this.manager,ktx2Loader:this.ktx2Loader,meshoptDecoder:this.meshoptDecoder});o.fileLoader.setRequestHeader(this.requestHeader);for(let s=0;s<this.pluginCallbacks.length;s++){const l=this.pluginCallbacks[s](o);l.name||console.error("THREE.GLTFLoader: Invalid plugin found: missing name"),a[l.name]=l,r[l.name]=!0}if(e.extensionsUsed)for(let s=0;s<e.extensionsUsed.length;++s){const l=e.extensionsUsed[s],f=e.extensionsRequired||[];switch(l){case ge.KHR_MATERIALS_UNLIT:r[l]=new wi;break;case ge.KHR_DRACO_MESH_COMPRESSION:r[l]=new Zi(e,this.dracoLoader);break;case ge.KHR_TEXTURE_TRANSFORM:r[l]=new qi;break;case ge.KHR_MESH_QUANTIZATION:r[l]=new $i;break;default:f.indexOf(l)>=0&&a[l]===void 0&&console.warn('THREE.GLTFLoader: Unknown extension "'+l+'".')}}o.setExtensions(r),o.setPlugins(a),o.parse(c,n)}parseAsync(t,i){const c=this;return new Promise(function(n,e){c.parse(t,i,n,e)})}}function Ii(){let u={};return{get:function(t){return u[t]},add:function(t,i){u[t]=i},remove:function(t){delete u[t]},removeAll:function(){u={}}}}const ge={KHR_BINARY_GLTF:"KHR_binary_glTF",KHR_DRACO_MESH_COMPRESSION:"KHR_draco_mesh_compression",KHR_LIGHTS_PUNCTUAL:"KHR_lights_punctual",KHR_MATERIALS_CLEARCOAT:"KHR_materials_clearcoat",KHR_MATERIALS_DISPERSION:"KHR_materials_dispersion",KHR_MATERIALS_IOR:"KHR_materials_ior",KHR_MATERIALS_SHEEN:"KHR_materials_sheen",KHR_MATERIALS_SPECULAR:"KHR_materials_specular",KHR_MATERIALS_TRANSMISSION:"KHR_materials_transmission",KHR_MATERIALS_IRIDESCENCE:"KHR_materials_iridescence",KHR_MATERIALS_ANISOTROPY:"KHR_materials_anisotropy",KHR_MATERIALS_UNLIT:"KHR_materials_unlit",KHR_MATERIALS_VOLUME:"KHR_materials_volume",KHR_TEXTURE_BASISU:"KHR_texture_basisu",KHR_TEXTURE_TRANSFORM:"KHR_texture_transform",KHR_MESH_QUANTIZATION:"KHR_mesh_quantization",KHR_MATERIALS_EMISSIVE_STRENGTH:"KHR_materials_emissive_strength",EXT_MATERIALS_BUMP:"EXT_materials_bump",EXT_TEXTURE_WEBP:"EXT_texture_webp",EXT_TEXTURE_AVIF:"EXT_texture_avif",EXT_MESHOPT_COMPRESSION:"EXT_meshopt_compression",EXT_MESH_GPU_INSTANCING:"EXT_mesh_gpu_instancing"};class Si{constructor(t){this.parser=t,this.name=ge.KHR_LIGHTS_PUNCTUAL,this.cache={refs:{},uses:{}}}_markDefs(){const t=this.parser,i=this.parser.json.nodes||[];for(let c=0,n=i.length;c<n;c++){const e=i[c];e.extensions&&e.extensions[this.name]&&e.extensions[this.name].light!==void 0&&t._addNodeRef(this.cache,e.extensions[this.name].light)}}_loadLight(t){const i=this.parser,c="light:"+t;let n=i.cache.get(c);if(n)return n;const e=i.json,o=((e.extensions&&e.extensions[this.name]||{}).lights||[])[t];let s;const l=new Pe(16777215);o.color!==void 0&&l.setRGB(o.color[0],o.color[1],o.color[2],at);const f=o.range!==void 0?o.range:0;switch(o.type){case"directional":s=new ds(l),s.target.position.set(0,0,-1),s.add(s.target);break;case"point":s=new fs(l),s.distance=f;break;case"spot":s=new us(l),s.distance=f,o.spot=o.spot||{},o.spot.innerConeAngle=o.spot.innerConeAngle!==void 0?o.spot.innerConeAngle:0,o.spot.outerConeAngle=o.spot.outerConeAngle!==void 0?o.spot.outerConeAngle:Math.PI/4,s.angle=o.spot.outerConeAngle,s.penumbra=1-o.spot.innerConeAngle/o.spot.outerConeAngle,s.target.position.set(0,0,-1),s.add(s.target);break;default:throw new Error("THREE.GLTFLoader: Unexpected light type: "+o.type)}return s.position.set(0,0,0),s.decay=2,ot(s,o),o.intensity!==void 0&&(s.intensity=o.intensity),s.name=i.createUniqueName(o.name||"light_"+t),n=Promise.resolve(s),i.cache.add(c,n),n}getDependency(t,i){if(t==="light")return this._loadLight(i)}createNodeAttachment(t){const i=this,c=this.parser,e=c.json.nodes[t],a=(e.extensions&&e.extensions[this.name]||{}).light;return a===void 0?null:this._loadLight(a).then(function(o){return c._getNodeRef(i.cache,a,o)})}}class wi{constructor(){this.name=ge.KHR_MATERIALS_UNLIT}getMaterialType(){return xt}extendParams(t,i,c){const n=[];t.color=new Pe(1,1,1),t.opacity=1;const e=i.pbrMetallicRoughness;if(e){if(Array.isArray(e.baseColorFactor)){const r=e.baseColorFactor;t.color.setRGB(r[0],r[1],r[2],at),t.opacity=r[3]}e.baseColorTexture!==void 0&&n.push(c.assignTexture(t,"map",e.baseColorTexture,vt))}return Promise.all(n)}}class Ui{constructor(t){this.parser=t,this.name=ge.KHR_MATERIALS_EMISSIVE_STRENGTH}extendMaterialParams(t,i){const n=this.parser.json.materials[t];if(!n.extensions||!n.extensions[this.name])return Promise.resolve();const e=n.extensions[this.name].emissiveStrength;return e!==void 0&&(i.emissiveIntensity=e),Promise.resolve()}}class _i{constructor(t){this.parser=t,this.name=ge.KHR_MATERIALS_CLEARCOAT}getMaterialType(t){const c=this.parser.json.materials[t];return!c.extensions||!c.extensions[this.name]?null:$e}extendMaterialParams(t,i){const c=this.parser,n=c.json.materials[t];if(!n.extensions||!n.extensions[this.name])return Promise.resolve();const e=[],r=n.extensions[this.name];if(r.clearcoatFactor!==void 0&&(i.clearcoat=r.clearcoatFactor),r.clearcoatTexture!==void 0&&e.push(c.assignTexture(i,"clearcoatMap",r.clearcoatTexture)),r.clearcoatRoughnessFactor!==void 0&&(i.clearcoatRoughness=r.clearcoatRoughnessFactor),r.clearcoatRoughnessTexture!==void 0&&e.push(c.assignTexture(i,"clearcoatRoughnessMap",r.clearcoatRoughnessTexture)),r.clearcoatNormalTexture!==void 0&&(e.push(c.assignTexture(i,"clearcoatNormalMap",r.clearcoatNormalTexture)),r.clearcoatNormalTexture.scale!==void 0)){const a=r.clearcoatNormalTexture.scale;i.clearcoatNormalScale=new qe(a,a)}return Promise.all(e)}}class Li{constructor(t){this.parser=t,this.name=ge.KHR_MATERIALS_DISPERSION}getMaterialType(t){const c=this.parser.json.materials[t];return!c.extensions||!c.extensions[this.name]?null:$e}extendMaterialParams(t,i){const n=this.parser.json.materials[t];if(!n.extensions||!n.extensions[this.name])return Promise.resolve();const e=n.extensions[this.name];return i.dispersion=e.dispersion!==void 0?e.dispersion:0,Promise.resolve()}}class ki{constructor(t){this.parser=t,this.name=ge.KHR_MATERIALS_IRIDESCENCE}getMaterialType(t){const c=this.parser.json.materials[t];return!c.extensions||!c.extensions[this.name]?null:$e}extendMaterialParams(t,i){const c=this.parser,n=c.json.materials[t];if(!n.extensions||!n.extensions[this.name])return Promise.resolve();const e=[],r=n.extensions[this.name];return r.iridescenceFactor!==void 0&&(i.iridescence=r.iridescenceFactor),r.iridescenceTexture!==void 0&&e.push(c.assignTexture(i,"iridescenceMap",r.iridescenceTexture)),r.iridescenceIor!==void 0&&(i.iridescenceIOR=r.iridescenceIor),i.iridescenceThicknessRange===void 0&&(i.iridescenceThicknessRange=[100,400]),r.iridescenceThicknessMinimum!==void 0&&(i.iridescenceThicknessRange[0]=r.iridescenceThicknessMinimum),r.iridescenceThicknessMaximum!==void 0&&(i.iridescenceThicknessRange[1]=r.iridescenceThicknessMaximum),r.iridescenceThicknessTexture!==void 0&&e.push(c.assignTexture(i,"iridescenceThicknessMap",r.iridescenceThicknessTexture)),Promise.all(e)}}class Oi{constructor(t){this.parser=t,this.name=ge.KHR_MATERIALS_SHEEN}getMaterialType(t){const c=this.parser.json.materials[t];return!c.extensions||!c.extensions[this.name]?null:$e}extendMaterialParams(t,i){const c=this.parser,n=c.json.materials[t];if(!n.extensions||!n.extensions[this.name])return Promise.resolve();const e=[];i.sheenColor=new Pe(0,0,0),i.sheenRoughness=0,i.sheen=1;const r=n.extensions[this.name];if(r.sheenColorFactor!==void 0){const a=r.sheenColorFactor;i.sheenColor.setRGB(a[0],a[1],a[2],at)}return r.sheenRoughnessFactor!==void 0&&(i.sheenRoughness=r.sheenRoughnessFactor),r.sheenColorTexture!==void 0&&e.push(c.assignTexture(i,"sheenColorMap",r.sheenColorTexture,vt)),r.sheenRoughnessTexture!==void 0&&e.push(c.assignTexture(i,"sheenRoughnessMap",r.sheenRoughnessTexture)),Promise.all(e)}}class Hi{constructor(t){this.parser=t,this.name=ge.KHR_MATERIALS_TRANSMISSION}getMaterialType(t){const c=this.parser.json.materials[t];return!c.extensions||!c.extensions[this.name]?null:$e}extendMaterialParams(t,i){const c=this.parser,n=c.json.materials[t];if(!n.extensions||!n.extensions[this.name])return Promise.resolve();const e=[],r=n.extensions[this.name];return r.transmissionFactor!==void 0&&(i.transmission=r.transmissionFactor),r.transmissionTexture!==void 0&&e.push(c.assignTexture(i,"transmissionMap",r.transmissionTexture)),Promise.all(e)}}class Pi{constructor(t){this.parser=t,this.name=ge.KHR_MATERIALS_VOLUME}getMaterialType(t){const c=this.parser.json.materials[t];return!c.extensions||!c.extensions[this.name]?null:$e}extendMaterialParams(t,i){const c=this.parser,n=c.json.materials[t];if(!n.extensions||!n.extensions[this.name])return Promise.resolve();const e=[],r=n.extensions[this.name];i.thickness=r.thicknessFactor!==void 0?r.thicknessFactor:0,r.thicknessTexture!==void 0&&e.push(c.assignTexture(i,"thicknessMap",r.thicknessTexture)),i.attenuationDistance=r.attenuationDistance||1/0;const a=r.attenuationColor||[1,1,1];return i.attenuationColor=new Pe().setRGB(a[0],a[1],a[2],at),Promise.all(e)}}class Ji{constructor(t){this.parser=t,this.name=ge.KHR_MATERIALS_IOR}getMaterialType(t){const c=this.parser.json.materials[t];return!c.extensions||!c.extensions[this.name]?null:$e}extendMaterialParams(t,i){const n=this.parser.json.materials[t];if(!n.extensions||!n.extensions[this.name])return Promise.resolve();const e=n.extensions[this.name];return i.ior=e.ior!==void 0?e.ior:1.5,Promise.resolve()}}class Ni{constructor(t){this.parser=t,this.name=ge.KHR_MATERIALS_SPECULAR}getMaterialType(t){const c=this.parser.json.materials[t];return!c.extensions||!c.extensions[this.name]?null:$e}extendMaterialParams(t,i){const c=this.parser,n=c.json.materials[t];if(!n.extensions||!n.extensions[this.name])return Promise.resolve();const e=[],r=n.extensions[this.name];i.specularIntensity=r.specularFactor!==void 0?r.specularFactor:1,r.specularTexture!==void 0&&e.push(c.assignTexture(i,"specularIntensityMap",r.specularTexture));const a=r.specularColorFactor||[1,1,1];return i.specularColor=new Pe().setRGB(a[0],a[1],a[2],at),r.specularColorTexture!==void 0&&e.push(c.assignTexture(i,"specularColorMap",r.specularColorTexture,vt)),Promise.all(e)}}class Ki{constructor(t){this.parser=t,this.name=ge.EXT_MATERIALS_BUMP}getMaterialType(t){const c=this.parser.json.materials[t];return!c.extensions||!c.extensions[this.name]?null:$e}extendMaterialParams(t,i){const c=this.parser,n=c.json.materials[t];if(!n.extensions||!n.extensions[this.name])return Promise.resolve();const e=[],r=n.extensions[this.name];return i.bumpScale=r.bumpFactor!==void 0?r.bumpFactor:1,r.bumpTexture!==void 0&&e.push(c.assignTexture(i,"bumpMap",r.bumpTexture)),Promise.all(e)}}class ji{constructor(t){this.parser=t,this.name=ge.KHR_MATERIALS_ANISOTROPY}getMaterialType(t){const c=this.parser.json.materials[t];return!c.extensions||!c.extensions[this.name]?null:$e}extendMaterialParams(t,i){const c=this.parser,n=c.json.materials[t];if(!n.extensions||!n.extensions[this.name])return Promise.resolve();const e=[],r=n.extensions[this.name];return r.anisotropyStrength!==void 0&&(i.anisotropy=r.anisotropyStrength),r.anisotropyRotation!==void 0&&(i.anisotropyRotation=r.anisotropyRotation),r.anisotropyTexture!==void 0&&e.push(c.assignTexture(i,"anisotropyMap",r.anisotropyTexture)),Promise.all(e)}}class Qi{constructor(t){this.parser=t,this.name=ge.KHR_TEXTURE_BASISU}loadTexture(t){const i=this.parser,c=i.json,n=c.textures[t];if(!n.extensions||!n.extensions[this.name])return null;const e=n.extensions[this.name],r=i.options.ktx2Loader;if(!r){if(c.extensionsRequired&&c.extensionsRequired.indexOf(this.name)>=0)throw new Error("THREE.GLTFLoader: setKTX2Loader must be called before loading KTX2 textures");return null}return i.loadTextureImage(t,e.source,r)}}class Xi{constructor(t){this.parser=t,this.name=ge.EXT_TEXTURE_WEBP,this.isSupported=null}loadTexture(t){const i=this.name,c=this.parser,n=c.json,e=n.textures[t];if(!e.extensions||!e.extensions[i])return null;const r=e.extensions[i],a=n.images[r.source];let o=c.textureLoader;if(a.uri){const s=c.options.manager.getHandler(a.uri);s!==null&&(o=s)}return this.detectSupport().then(function(s){if(s)return c.loadTextureImage(t,r.source,o);if(n.extensionsRequired&&n.extensionsRequired.indexOf(i)>=0)throw new Error("THREE.GLTFLoader: WebP required by asset but unsupported.");return c.loadTexture(t)})}detectSupport(){return this.isSupported||(this.isSupported=new Promise(function(t){const i=new Image;i.src="data:image/webp;base64,UklGRiIAAABXRUJQVlA4IBYAAAAwAQCdASoBAAEADsD+JaQAA3AAAAAA",i.onload=i.onerror=function(){t(i.height===1)}})),this.isSupported}}class Wi{constructor(t){this.parser=t,this.name=ge.EXT_TEXTURE_AVIF,this.isSupported=null}loadTexture(t){const i=this.name,c=this.parser,n=c.json,e=n.textures[t];if(!e.extensions||!e.extensions[i])return null;const r=e.extensions[i],a=n.images[r.source];let o=c.textureLoader;if(a.uri){const s=c.options.manager.getHandler(a.uri);s!==null&&(o=s)}return this.detectSupport().then(function(s){if(s)return c.loadTextureImage(t,r.source,o);if(n.extensionsRequired&&n.extensionsRequired.indexOf(i)>=0)throw new Error("THREE.GLTFLoader: AVIF required by asset but unsupported.");return c.loadTexture(t)})}detectSupport(){return this.isSupported||(this.isSupported=new Promise(function(t){const i=new Image;i.src="data:image/avif;base64,AAAAIGZ0eXBhdmlmAAAAAGF2aWZtaWYxbWlhZk1BMUIAAADybWV0YQAAAAAAAAAoaGRscgAAAAAAAAAAcGljdAAAAAAAAAAAAAAAAGxpYmF2aWYAAAAADnBpdG0AAAAAAAEAAAAeaWxvYwAAAABEAAABAAEAAAABAAABGgAAABcAAAAoaWluZgAAAAAAAQAAABppbmZlAgAAAAABAABhdjAxQ29sb3IAAAAAamlwcnAAAABLaXBjbwAAABRpc3BlAAAAAAAAAAEAAAABAAAAEHBpeGkAAAAAAwgICAAAAAxhdjFDgQAMAAAAABNjb2xybmNseAACAAIABoAAAAAXaXBtYQAAAAAAAAABAAEEAQKDBAAAAB9tZGF0EgAKCBgABogQEDQgMgkQAAAAB8dSLfI=",i.onload=i.onerror=function(){t(i.height===1)}})),this.isSupported}}class Yi{constructor(t){this.name=ge.EXT_MESHOPT_COMPRESSION,this.parser=t}loadBufferView(t){const i=this.parser.json,c=i.bufferViews[t];if(c.extensions&&c.extensions[this.name]){const n=c.extensions[this.name],e=this.parser.getDependency("buffer",n.buffer),r=this.parser.options.meshoptDecoder;if(!r||!r.supported){if(i.extensionsRequired&&i.extensionsRequired.indexOf(this.name)>=0)throw new Error("THREE.GLTFLoader: setMeshoptDecoder must be called before loading compressed files");return null}return e.then(function(a){const o=n.byteOffset||0,s=n.byteLength||0,l=n.count,f=n.byteStride,d=new Uint8Array(a,o,s);return r.decodeGltfBufferAsync?r.decodeGltfBufferAsync(l,f,d,n.mode,n.filter).then(function(h){return h.buffer}):r.ready.then(function(){const h=new ArrayBuffer(l*f);return r.decodeGltfBuffer(new Uint8Array(h),l,f,d,n.mode,n.filter),h})})}else return null}}class Vi{constructor(t){this.name=ge.EXT_MESH_GPU_INSTANCING,this.parser=t}createNodeMesh(t){const i=this.parser.json,c=i.nodes[t];if(!c.extensions||!c.extensions[this.name]||c.mesh===void 0)return null;const n=i.meshes[c.mesh];for(const s of n.primitives)if(s.mode!==Xe.TRIANGLES&&s.mode!==Xe.TRIANGLE_STRIP&&s.mode!==Xe.TRIANGLE_FAN&&s.mode!==void 0)return null;const r=c.extensions[this.name].attributes,a=[],o={};for(const s in r)a.push(this.parser.getDependency("accessor",r[s]).then(l=>(o[s]=l,o[s])));return a.length<1?null:(a.push(this.parser.createNodeMesh(t)),Promise.all(a).then(s=>{const l=s.pop(),f=l.isGroup?l.children:[l],d=s[0].count,h=[];for(const A of f){const m=new Ct,p=new ke,v=new bt,C=new ke(1,1,1),b=new hs(A.geometry,A.material,d);for(let g=0;g<d;g++)o.TRANSLATION&&p.fromBufferAttribute(o.TRANSLATION,g),o.ROTATION&&v.fromBufferAttribute(o.ROTATION,g),o.SCALE&&C.fromBufferAttribute(o.SCALE,g),b.setMatrixAt(g,m.compose(p,v,C));for(const g in o)if(g==="_COLOR_0"){const E=o[g];b.instanceColor=new ga(E.array,E.itemSize,E.normalized)}else g!=="TRANSLATION"&&g!=="ROTATION"&&g!=="SCALE"&&A.geometry.setAttribute(g,o[g]);Ca.prototype.copy.call(b,A),this.parser.assignFinalMaterial(b),h.push(b)}return l.isGroup?(l.clear(),l.add(...h),l):h[0]}))}}const Sa="glTF",qt=12,Wo={JSON:1313821514,BIN:5130562};class zi{constructor(t){this.name=ge.KHR_BINARY_GLTF,this.content=null,this.body=null;const i=new DataView(t,0,qt);if(this.header={magic:wn(new Uint8Array(t.slice(0,4))),version:i.getUint32(4,!0),length:i.getUint32(8,!0)},this.header.magic!==Sa)throw new Error("THREE.GLTFLoader: Unsupported glTF-Binary header.");if(this.header.version<2)throw new Error("THREE.GLTFLoader: Legacy binary file detected.");const c=this.header.length-qt,n=new DataView(t,qt);let e=0;for(;e<c;){const r=n.getUint32(e,!0);e+=4;const a=n.getUint32(e,!0);if(e+=4,a===Wo.JSON){const o=new Uint8Array(t,qt+e,r);this.content=wn(o)}else if(a===Wo.BIN){const o=qt+e;this.body=t.slice(o,o+r)}e+=r}if(this.content===null)throw new Error("THREE.GLTFLoader: JSON content not found.")}}class Zi{constructor(t,i){if(!i)throw new Error("THREE.GLTFLoader: No DRACOLoader instance provided.");this.name=ge.KHR_DRACO_MESH_COMPRESSION,this.json=t,this.dracoLoader=i,this.dracoLoader.preload()}decodePrimitive(t,i){const c=this.json,n=this.dracoLoader,e=t.extensions[this.name].bufferView,r=t.extensions[this.name].attributes,a={},o={},s={};for(const l in r){const f=br[l]||l.toLowerCase();a[f]=r[l]}for(const l in t.attributes){const f=br[l]||l.toLowerCase();if(r[l]!==void 0){const d=c.accessors[t.attributes[l]],h=St[d.componentType];s[f]=h.name,o[f]=d.normalized===!0}}return i.getDependency("bufferView",e).then(function(l){return new Promise(function(f,d){n.decodeDracoFile(l,function(h){for(const A in h.attributes){const m=h.attributes[A],p=o[A];p!==void 0&&(m.normalized=p)}f(h)},a,s,at,d)})})}}class qi{constructor(){this.name=ge.KHR_TEXTURE_TRANSFORM}extendTexture(t,i){return(i.texCoord===void 0||i.texCoord===t.channel)&&i.offset===void 0&&i.rotation===void 0&&i.scale===void 0||(t=t.clone(),i.texCoord!==void 0&&(t.channel=i.texCoord),i.offset!==void 0&&t.offset.fromArray(i.offset),i.rotation!==void 0&&(t.rotation=i.rotation),i.scale!==void 0&&t.repeat.fromArray(i.scale),t.needsUpdate=!0),t}}class $i{constructor(){this.name=ge.KHR_MESH_QUANTIZATION}}class wa extends ks{constructor(t,i,c,n){super(t,i,c,n)}copySampleValue_(t){const i=this.resultBuffer,c=this.sampleValues,n=this.valueSize,e=t*n*3+n;for(let r=0;r!==n;r++)i[r]=c[e+r];return i}interpolate_(t,i,c,n){const e=this.resultBuffer,r=this.sampleValues,a=this.valueSize,o=a*2,s=a*3,l=n-i,f=(c-i)/l,d=f*f,h=d*f,A=t*s,m=A-s,p=-2*h+3*d,v=h-d,C=1-p,b=v-d+f;for(let g=0;g!==a;g++){const E=r[m+g+a],D=r[m+g+o]*l,F=r[A+g+a],M=r[A+g]*l;e[g]=C*E+b*D+p*F+v*M}return e}}const ec=new bt;class tc extends wa{interpolate_(t,i,c,n){const e=super.interpolate_(t,i,c,n);return ec.fromArray(e).normalize().toArray(e),e}}const Xe={POINTS:0,LINES:1,LINE_LOOP:2,LINE_STRIP:3,TRIANGLES:4,TRIANGLE_STRIP:5,TRIANGLE_FAN:6},St={5120:Int8Array,5121:Uint8Array,5122:Int16Array,5123:Uint16Array,5125:Uint32Array,5126:Float32Array},Yo={9728:gs,9729:In,9984:vs,9985:Bs,9986:ms,9987:ya},Vo={33071:ys,33648:Cs,10497:Br},ir={SCALAR:1,VEC2:2,VEC3:3,VEC4:4,MAT2:4,MAT3:9,MAT4:16},br={POSITION:"position",NORMAL:"normal",TANGENT:"tangent",...Ri>=152?{TEXCOORD_0:"uv",TEXCOORD_1:"uv1",TEXCOORD_2:"uv2",TEXCOORD_3:"uv3"}:{TEXCOORD_0:"uv",TEXCOORD_1:"uv2"},COLOR_0:"color",WEIGHTS_0:"skinWeight",JOINTS_0:"skinIndex"},dt={scale:"scale",translation:"position",rotation:"quaternion",weights:"morphTargetInfluences"},nc={CUBICSPLINE:void 0,LINEAR:Ta,STEP:_s},cr={OPAQUE:"OPAQUE",MASK:"MASK",BLEND:"BLEND"};function rc(u){return u.DefaultMaterial===void 0&&(u.DefaultMaterial=new ba({color:16777215,emissive:0,metalness:1,roughness:1,transparent:!1,depthTest:!0,side:Da})),u.DefaultMaterial}function mt(u,t,i){for(const c in i.extensions)u[c]===void 0&&(t.userData.gltfExtensions=t.userData.gltfExtensions||{},t.userData.gltfExtensions[c]=i.extensions[c])}function ot(u,t){t.extras!==void 0&&(typeof t.extras=="object"?Object.assign(u.userData,t.extras):console.warn("THREE.GLTFLoader: Ignoring primitive type .extras, "+t.extras))}function oc(u,t,i){let c=!1,n=!1,e=!1;for(let s=0,l=t.length;s<l;s++){const f=t[s];if(f.POSITION!==void 0&&(c=!0),f.NORMAL!==void 0&&(n=!0),f.COLOR_0!==void 0&&(e=!0),c&&n&&e)break}if(!c&&!n&&!e)return Promise.resolve(u);const r=[],a=[],o=[];for(let s=0,l=t.length;s<l;s++){const f=t[s];if(c){const d=f.POSITION!==void 0?i.getDependency("accessor",f.POSITION):u.attributes.position;r.push(d)}if(n){const d=f.NORMAL!==void 0?i.getDependency("accessor",f.NORMAL):u.attributes.normal;a.push(d)}if(e){const d=f.COLOR_0!==void 0?i.getDependency("accessor",f.COLOR_0):u.attributes.color;o.push(d)}}return Promise.all([Promise.all(r),Promise.all(a),Promise.all(o)]).then(function(s){const l=s[0],f=s[1],d=s[2];return c&&(u.morphAttributes.position=l),n&&(u.morphAttributes.normal=f),e&&(u.morphAttributes.color=d),u.morphTargetsRelative=!0,u})}function ac(u,t){if(u.updateMorphTargets(),t.weights!==void 0)for(let i=0,c=t.weights.length;i<c;i++)u.morphTargetInfluences[i]=t.weights[i];if(t.extras&&Array.isArray(t.extras.targetNames)){const i=t.extras.targetNames;if(u.morphTargetInfluences.length===i.length){u.morphTargetDictionary={};for(let c=0,n=i.length;c<n;c++)u.morphTargetDictionary[i[c]]=c}else console.warn("THREE.GLTFLoader: Invalid extras.targetNames length. Ignoring names.")}}function sc(u){let t;const i=u.extensions&&u.extensions[ge.KHR_DRACO_MESH_COMPRESSION];if(i?t="draco:"+i.bufferView+":"+i.indices+":"+lr(i.attributes):t=u.indices+":"+lr(u.attributes)+":"+u.mode,u.targets!==void 0)for(let c=0,n=u.targets.length;c<n;c++)t+=":"+lr(u.targets[c]);return t}function lr(u){let t="";const i=Object.keys(u).sort();for(let c=0,n=i.length;c<n;c++)t+=i[c]+":"+u[i[c]]+";";return t}function Fr(u){switch(u){case Int8Array:return 1/127;case Uint8Array:return 1/255;case Int16Array:return 1/32767;case Uint16Array:return 1/65535;default:throw new Error("THREE.GLTFLoader: Unsupported normalized accessor component type.")}}function ic(u){return u.search(/\.jpe?g($|\?)/i)>0||u.search(/^data\:image\/jpeg/)===0?"image/jpeg":u.search(/\.webp($|\?)/i)>0||u.search(/^data\:image\/webp/)===0?"image/webp":"image/png"}const cc=new Ct;class lc{constructor(t={},i={}){this.json=t,this.extensions={},this.plugins={},this.options=i,this.cache=new Ii,this.associations=new Map,this.primitiveCache={},this.nodeCache={},this.meshCache={refs:{},uses:{}},this.cameraCache={refs:{},uses:{}},this.lightCache={refs:{},uses:{}},this.sourceCache={},this.textureCache={},this.nodeNamesUsed={};let c=!1,n=!1,e=-1;typeof navigator<"u"&&typeof navigator.userAgent<"u"&&(c=/^((?!chrome|android).)*safari/i.test(navigator.userAgent)===!0,n=navigator.userAgent.indexOf("Firefox")>-1,e=n?navigator.userAgent.match(/Firefox\/([0-9]+)\./)[1]:-1),typeof createImageBitmap>"u"||c||n&&e<98?this.textureLoader=new Un(this.options.manager):this.textureLoader=new As(this.options.manager),this.textureLoader.setCrossOrigin(this.options.crossOrigin),this.textureLoader.setRequestHeader(this.options.requestHeader),this.fileLoader=new xn(this.options.manager),this.fileLoader.setResponseType("arraybuffer"),this.options.crossOrigin==="use-credentials"&&this.fileLoader.setWithCredentials(!0)}setExtensions(t){this.extensions=t}setPlugins(t){this.plugins=t}parse(t,i){const c=this,n=this.json,e=this.extensions;this.cache.removeAll(),this.nodeCache={},this._invokeAll(function(r){return r._markDefs&&r._markDefs()}),Promise.all(this._invokeAll(function(r){return r.beforeRoot&&r.beforeRoot()})).then(function(){return Promise.all([c.getDependencies("scene"),c.getDependencies("animation"),c.getDependencies("camera")])}).then(function(r){const a={scene:r[0][n.scene||0],scenes:r[0],animations:r[1],cameras:r[2],asset:n.asset,parser:c,userData:{}};return mt(e,a,n),ot(a,n),Promise.all(c._invokeAll(function(o){return o.afterRoot&&o.afterRoot(a)})).then(function(){for(const o of a.scenes)o.updateMatrixWorld();t(a)})}).catch(i)}_markDefs(){const t=this.json.nodes||[],i=this.json.skins||[],c=this.json.meshes||[];for(let n=0,e=i.length;n<e;n++){const r=i[n].joints;for(let a=0,o=r.length;a<o;a++)t[r[a]].isBone=!0}for(let n=0,e=t.length;n<e;n++){const r=t[n];r.mesh!==void 0&&(this._addNodeRef(this.meshCache,r.mesh),r.skin!==void 0&&(c[r.mesh].isSkinnedMesh=!0)),r.camera!==void 0&&this._addNodeRef(this.cameraCache,r.camera)}}_addNodeRef(t,i){i!==void 0&&(t.refs[i]===void 0&&(t.refs[i]=t.uses[i]=0),t.refs[i]++)}_getNodeRef(t,i,c){if(t.refs[i]<=1)return c;const n=c.clone(),e=(r,a)=>{const o=this.associations.get(r);o!=null&&this.associations.set(a,o);for(const[s,l]of r.children.entries())e(l,a.children[s])};return e(c,n),n.name+="_instance_"+t.uses[i]++,n}_invokeOne(t){const i=Object.values(this.plugins);i.push(this);for(let c=0;c<i.length;c++){const n=t(i[c]);if(n)return n}return null}_invokeAll(t){const i=Object.values(this.plugins);i.unshift(this);const c=[];for(let n=0;n<i.length;n++){const e=t(i[n]);e&&c.push(e)}return c}getDependency(t,i){const c=t+":"+i;let n=this.cache.get(c);if(!n){switch(t){case"scene":n=this.loadScene(i);break;case"node":n=this._invokeOne(function(e){return e.loadNode&&e.loadNode(i)});break;case"mesh":n=this._invokeOne(function(e){return e.loadMesh&&e.loadMesh(i)});break;case"accessor":n=this.loadAccessor(i);break;case"bufferView":n=this._invokeOne(function(e){return e.loadBufferView&&e.loadBufferView(i)});break;case"buffer":n=this.loadBuffer(i);break;case"material":n=this._invokeOne(function(e){return e.loadMaterial&&e.loadMaterial(i)});break;case"texture":n=this._invokeOne(function(e){return e.loadTexture&&e.loadTexture(i)});break;case"skin":n=this.loadSkin(i);break;case"animation":n=this._invokeOne(function(e){return e.loadAnimation&&e.loadAnimation(i)});break;case"camera":n=this.loadCamera(i);break;default:if(n=this._invokeOne(function(e){return e!=this&&e.getDependency&&e.getDependency(t,i)}),!n)throw new Error("Unknown type: "+t);break}this.cache.add(c,n)}return n}getDependencies(t){let i=this.cache.get(t);if(!i){const c=this,n=this.json[t+(t==="mesh"?"es":"s")]||[];i=Promise.all(n.map(function(e,r){return c.getDependency(t,r)})),this.cache.add(t,i)}return i}loadBuffer(t){const i=this.json.buffers[t],c=this.fileLoader;if(i.type&&i.type!=="arraybuffer")throw new Error("THREE.GLTFLoader: "+i.type+" buffer type is not supported.");if(i.uri===void 0&&t===0)return Promise.resolve(this.extensions[ge.KHR_BINARY_GLTF].body);const n=this.options;return new Promise(function(e,r){c.load(nn.resolveURL(i.uri,n.path),e,void 0,function(){r(new Error('THREE.GLTFLoader: Failed to load buffer "'+i.uri+'".'))})})}loadBufferView(t){const i=this.json.bufferViews[t];return this.getDependency("buffer",i.buffer).then(function(c){const n=i.byteLength||0,e=i.byteOffset||0;return c.slice(e,e+n)})}loadAccessor(t){const i=this,c=this.json,n=this.json.accessors[t];if(n.bufferView===void 0&&n.sparse===void 0){const r=ir[n.type],a=St[n.componentType],o=n.normalized===!0,s=new a(n.count*r);return Promise.resolve(new rn(s,r,o))}const e=[];return n.bufferView!==void 0?e.push(this.getDependency("bufferView",n.bufferView)):e.push(null),n.sparse!==void 0&&(e.push(this.getDependency("bufferView",n.sparse.indices.bufferView)),e.push(this.getDependency("bufferView",n.sparse.values.bufferView))),Promise.all(e).then(function(r){const a=r[0],o=ir[n.type],s=St[n.componentType],l=s.BYTES_PER_ELEMENT,f=l*o,d=n.byteOffset||0,h=n.bufferView!==void 0?c.bufferViews[n.bufferView].byteStride:void 0,A=n.normalized===!0;let m,p;if(h&&h!==f){const v=Math.floor(d/h),C="InterleavedBuffer:"+n.bufferView+":"+n.componentType+":"+v+":"+n.count;let b=i.cache.get(C);b||(m=new s(a,v*h,n.count*h/l),b=new ps(m,h/l),i.cache.add(C,b)),p=new Ls(b,o,d%h/l,A)}else a===null?m=new s(n.count*o):m=new s(a,d,n.count*o),p=new rn(m,o,A);if(n.sparse!==void 0){const v=ir.SCALAR,C=St[n.sparse.indices.componentType],b=n.sparse.indices.byteOffset||0,g=n.sparse.values.byteOffset||0,E=new C(r[1],b,n.sparse.count*v),D=new s(r[2],g,n.sparse.count*o);a!==null&&(p=new rn(p.array.slice(),p.itemSize,p.normalized));for(let F=0,M=E.length;F<M;F++){const U=E[F];if(p.setX(U,D[F*o]),o>=2&&p.setY(U,D[F*o+1]),o>=3&&p.setZ(U,D[F*o+2]),o>=4&&p.setW(U,D[F*o+3]),o>=5)throw new Error("THREE.GLTFLoader: Unsupported itemSize in sparse BufferAttribute.")}}return p})}loadTexture(t){const i=this.json,c=this.options,e=i.textures[t].source,r=i.images[e];let a=this.textureLoader;if(r.uri){const o=c.manager.getHandler(r.uri);o!==null&&(a=o)}return this.loadTextureImage(t,e,a)}loadTextureImage(t,i,c){const n=this,e=this.json,r=e.textures[t],a=e.images[i],o=(a.uri||a.bufferView)+":"+r.sampler;if(this.textureCache[o])return this.textureCache[o];const s=this.loadImageSource(i,c).then(function(l){l.flipY=!1,l.name=r.name||a.name||"",l.name===""&&typeof a.uri=="string"&&a.uri.startsWith("data:image/")===!1&&(l.name=a.uri);const d=(e.samplers||{})[r.sampler]||{};return l.magFilter=Yo[d.magFilter]||In,l.minFilter=Yo[d.minFilter]||ya,l.wrapS=Vo[d.wrapS]||Br,l.wrapT=Vo[d.wrapT]||Br,n.associations.set(l,{textures:t}),l}).catch(function(){return null});return this.textureCache[o]=s,s}loadImageSource(t,i){const c=this,n=this.json,e=this.options;if(this.sourceCache[t]!==void 0)return this.sourceCache[t].then(f=>f.clone());const r=n.images[t],a=self.URL||self.webkitURL;let o=r.uri||"",s=!1;if(r.bufferView!==void 0)o=c.getDependency("bufferView",r.bufferView).then(function(f){s=!0;const d=new Blob([f],{type:r.mimeType});return o=a.createObjectURL(d),o});else if(r.uri===void 0)throw new Error("THREE.GLTFLoader: Image "+t+" is missing URI and bufferView");const l=Promise.resolve(o).then(function(f){return new Promise(function(d,h){let A=d;i.isImageBitmapLoader===!0&&(A=function(m){const p=new cn(m);p.needsUpdate=!0,d(p)}),i.load(nn.resolveURL(f,e.path),A,void 0,h)})}).then(function(f){return s===!0&&a.revokeObjectURL(o),ot(f,r),f.userData.mimeType=r.mimeType||ic(r.uri),f}).catch(function(f){throw console.error("THREE.GLTFLoader: Couldn't load texture",o),f});return this.sourceCache[t]=l,l}assignTexture(t,i,c,n){const e=this;return this.getDependency("texture",c.index).then(function(r){if(!r)return null;if(c.texCoord!==void 0&&c.texCoord>0&&(r=r.clone(),r.channel=c.texCoord),e.extensions[ge.KHR_TEXTURE_TRANSFORM]){const a=c.extensions!==void 0?c.extensions[ge.KHR_TEXTURE_TRANSFORM]:void 0;if(a){const o=e.associations.get(r);r=e.extensions[ge.KHR_TEXTURE_TRANSFORM].extendTexture(r,a),e.associations.set(r,o)}}return n!==void 0&&(typeof n=="number"&&(n=n===Xo?vt:at),"colorSpace"in r?r.colorSpace=n:r.encoding=n===vt?Xo:xi),t[i]=r,r})}assignFinalMaterial(t){const i=t.geometry;let c=t.material;const n=i.attributes.tangent===void 0,e=i.attributes.color!==void 0,r=i.attributes.normal===void 0;if(t.isPoints){const a="PointsMaterial:"+c.uuid;let o=this.cache.get(a);o||(o=new bs,or.prototype.copy.call(o,c),o.color.copy(c.color),o.map=c.map,o.sizeAttenuation=!1,this.cache.add(a,o)),c=o}else if(t.isLine){const a="LineBasicMaterial:"+c.uuid;let o=this.cache.get(a);o||(o=new Fs,or.prototype.copy.call(o,c),o.color.copy(c.color),o.map=c.map,this.cache.add(a,o)),c=o}if(n||e||r){let a="ClonedMaterial:"+c.uuid+":";n&&(a+="derivative-tangents:"),e&&(a+="vertex-colors:"),r&&(a+="flat-shading:");let o=this.cache.get(a);o||(o=c.clone(),e&&(o.vertexColors=!0),r&&(o.flatShading=!0),n&&(o.normalScale&&(o.normalScale.y*=-1),o.clearcoatNormalScale&&(o.clearcoatNormalScale.y*=-1)),this.cache.add(a,o),this.associations.set(o,this.associations.get(c))),c=o}t.material=c}getMaterialType(){return ba}loadMaterial(t){const i=this,c=this.json,n=this.extensions,e=c.materials[t];let r;const a={},o=e.extensions||{},s=[];if(o[ge.KHR_MATERIALS_UNLIT]){const f=n[ge.KHR_MATERIALS_UNLIT];r=f.getMaterialType(),s.push(f.extendParams(a,e,i))}else{const f=e.pbrMetallicRoughness||{};if(a.color=new Pe(1,1,1),a.opacity=1,Array.isArray(f.baseColorFactor)){const d=f.baseColorFactor;a.color.setRGB(d[0],d[1],d[2],at),a.opacity=d[3]}f.baseColorTexture!==void 0&&s.push(i.assignTexture(a,"map",f.baseColorTexture,vt)),a.metalness=f.metallicFactor!==void 0?f.metallicFactor:1,a.roughness=f.roughnessFactor!==void 0?f.roughnessFactor:1,f.metallicRoughnessTexture!==void 0&&(s.push(i.assignTexture(a,"metalnessMap",f.metallicRoughnessTexture)),s.push(i.assignTexture(a,"roughnessMap",f.metallicRoughnessTexture))),r=this._invokeOne(function(d){return d.getMaterialType&&d.getMaterialType(t)}),s.push(Promise.all(this._invokeAll(function(d){return d.extendMaterialParams&&d.extendMaterialParams(t,a)})))}e.doubleSided===!0&&(a.side=Fa);const l=e.alphaMode||cr.OPAQUE;if(l===cr.BLEND?(a.transparent=!0,a.depthWrite=!1):(a.transparent=!1,l===cr.MASK&&(a.alphaTest=e.alphaCutoff!==void 0?e.alphaCutoff:.5)),e.normalTexture!==void 0&&r!==xt&&(s.push(i.assignTexture(a,"normalMap",e.normalTexture)),a.normalScale=new qe(1,1),e.normalTexture.scale!==void 0)){const f=e.normalTexture.scale;a.normalScale.set(f,f)}if(e.occlusionTexture!==void 0&&r!==xt&&(s.push(i.assignTexture(a,"aoMap",e.occlusionTexture)),e.occlusionTexture.strength!==void 0&&(a.aoMapIntensity=e.occlusionTexture.strength)),e.emissiveFactor!==void 0&&r!==xt){const f=e.emissiveFactor;a.emissive=new Pe().setRGB(f[0],f[1],f[2],at)}return e.emissiveTexture!==void 0&&r!==xt&&s.push(i.assignTexture(a,"emissiveMap",e.emissiveTexture,vt)),Promise.all(s).then(function(){const f=new r(a);return e.name&&(f.name=e.name),ot(f,e),i.associations.set(f,{materials:t}),e.extensions&&mt(n,f,e),f})}createUniqueName(t){const i=Es.sanitizeNodeName(t||"");return i in this.nodeNamesUsed?i+"_"+ ++this.nodeNamesUsed[i]:(this.nodeNamesUsed[i]=0,i)}loadGeometries(t){const i=this,c=this.extensions,n=this.primitiveCache;function e(a){return c[ge.KHR_DRACO_MESH_COMPRESSION].decodePrimitive(a,i).then(function(o){return zo(o,a,i)})}const r=[];for(let a=0,o=t.length;a<o;a++){const s=t[a],l=sc(s),f=n[l];if(f)r.push(f.promise);else{let d;s.extensions&&s.extensions[ge.KHR_DRACO_MESH_COMPRESSION]?d=e(s):d=zo(new Ea,s,i),n[l]={primitive:s,promise:d},r.push(d)}}return Promise.all(r)}loadMesh(t){const i=this,c=this.json,n=this.extensions,e=c.meshes[t],r=e.primitives,a=[];for(let o=0,s=r.length;o<s;o++){const l=r[o].material===void 0?rc(this.cache):this.getDependency("material",r[o].material);a.push(l)}return a.push(i.loadGeometries(r)),Promise.all(a).then(function(o){const s=o.slice(0,o.length-1),l=o[o.length-1],f=[];for(let h=0,A=l.length;h<A;h++){const m=l[h],p=r[h];let v;const C=s[h];if(p.mode===Xe.TRIANGLES||p.mode===Xe.TRIANGLE_STRIP||p.mode===Xe.TRIANGLE_FAN||p.mode===void 0)v=e.isSkinnedMesh===!0?new Ms(m,C):new _n(m,C),v.isSkinnedMesh===!0&&v.normalizeSkinWeights(),p.mode===Xe.TRIANGLE_STRIP?v.geometry=Qo(v.geometry,Ba):p.mode===Xe.TRIANGLE_FAN&&(v.geometry=Qo(v.geometry,mr));else if(p.mode===Xe.LINES)v=new Ts(m,C);else if(p.mode===Xe.LINE_STRIP)v=new Ds(m,C);else if(p.mode===Xe.LINE_LOOP)v=new Gs(m,C);else if(p.mode===Xe.POINTS)v=new Rs(m,C);else throw new Error("THREE.GLTFLoader: Primitive mode unsupported: "+p.mode);Object.keys(v.geometry.morphAttributes).length>0&&ac(v,e),v.name=i.createUniqueName(e.name||"mesh_"+t),ot(v,e),p.extensions&&mt(n,v,p),i.assignFinalMaterial(v),f.push(v)}for(let h=0,A=f.length;h<A;h++)i.associations.set(f[h],{meshes:t,primitives:h});if(f.length===1)return e.extensions&&mt(n,f[0],e),f[0];const d=new ar;e.extensions&&mt(n,d,e),i.associations.set(d,{meshes:t});for(let h=0,A=f.length;h<A;h++)d.add(f[h]);return d})}loadCamera(t){let i;const c=this.json.cameras[t],n=c[c.type];if(!n){console.warn("THREE.GLTFLoader: Missing camera parameters.");return}return c.type==="perspective"?i=new xs(Ma.radToDeg(n.yfov),n.aspectRatio||1,n.znear||1,n.zfar||2e6):c.type==="orthographic"&&(i=new Is(-n.xmag,n.xmag,n.ymag,-n.ymag,n.znear,n.zfar)),c.name&&(i.name=this.createUniqueName(c.name)),ot(i,c),Promise.resolve(i)}loadSkin(t){const i=this.json.skins[t],c=[];for(let n=0,e=i.joints.length;n<e;n++)c.push(this._loadNodeShallow(i.joints[n]));return i.inverseBindMatrices!==void 0?c.push(this.getDependency("accessor",i.inverseBindMatrices)):c.push(null),Promise.all(c).then(function(n){const e=n.pop(),r=n,a=[],o=[];for(let s=0,l=r.length;s<l;s++){const f=r[s];if(f){a.push(f);const d=new Ct;e!==null&&d.fromArray(e.array,s*16),o.push(d)}else console.warn('THREE.GLTFLoader: Joint "%s" could not be found.',i.joints[s])}return new Ss(a,o)})}loadAnimation(t){const i=this.json,c=this,n=i.animations[t],e=n.name?n.name:"animation_"+t,r=[],a=[],o=[],s=[],l=[];for(let f=0,d=n.channels.length;f<d;f++){const h=n.channels[f],A=n.samplers[h.sampler],m=h.target,p=m.node,v=n.parameters!==void 0?n.parameters[A.input]:A.input,C=n.parameters!==void 0?n.parameters[A.output]:A.output;m.node!==void 0&&(r.push(this.getDependency("node",p)),a.push(this.getDependency("accessor",v)),o.push(this.getDependency("accessor",C)),s.push(A),l.push(m))}return Promise.all([Promise.all(r),Promise.all(a),Promise.all(o),Promise.all(s),Promise.all(l)]).then(function(f){const d=f[0],h=f[1],A=f[2],m=f[3],p=f[4],v=[];for(let C=0,b=d.length;C<b;C++){const g=d[C],E=h[C],D=A[C],F=m[C],M=p[C];if(g===void 0)continue;g.updateMatrix&&g.updateMatrix();const U=c._createAnimationTracks(g,E,D,F,M);if(U)for(let x=0;x<U.length;x++)v.push(U[x])}return new ws(e,void 0,v)})}createNodeMesh(t){const i=this.json,c=this,n=i.nodes[t];return n.mesh===void 0?null:c.getDependency("mesh",n.mesh).then(function(e){const r=c._getNodeRef(c.meshCache,n.mesh,e);return n.weights!==void 0&&r.traverse(function(a){if(a.isMesh)for(let o=0,s=n.weights.length;o<s;o++)a.morphTargetInfluences[o]=n.weights[o]}),r})}loadNode(t){const i=this.json,c=this,n=i.nodes[t],e=c._loadNodeShallow(t),r=[],a=n.children||[];for(let s=0,l=a.length;s<l;s++)r.push(c.getDependency("node",a[s]));const o=n.skin===void 0?Promise.resolve(null):c.getDependency("skin",n.skin);return Promise.all([e,Promise.all(r),o]).then(function(s){const l=s[0],f=s[1],d=s[2];d!==null&&l.traverse(function(h){h.isSkinnedMesh&&h.bind(d,cc)});for(let h=0,A=f.length;h<A;h++)l.add(f[h]);return l})}_loadNodeShallow(t){const i=this.json,c=this.extensions,n=this;if(this.nodeCache[t]!==void 0)return this.nodeCache[t];const e=i.nodes[t],r=e.name?n.createUniqueName(e.name):"",a=[],o=n._invokeOne(function(s){return s.createNodeMesh&&s.createNodeMesh(t)});return o&&a.push(o),e.camera!==void 0&&a.push(n.getDependency("camera",e.camera).then(function(s){return n._getNodeRef(n.cameraCache,e.camera,s)})),n._invokeAll(function(s){return s.createNodeAttachment&&s.createNodeAttachment(t)}).forEach(function(s){a.push(s)}),this.nodeCache[t]=Promise.all(a).then(function(s){let l;if(e.isBone===!0?l=new Us:s.length>1?l=new ar:s.length===1?l=s[0]:l=new Ca,l!==s[0])for(let f=0,d=s.length;f<d;f++)l.add(s[f]);if(e.name&&(l.userData.name=e.name,l.name=r),ot(l,e),e.extensions&&mt(c,l,e),e.matrix!==void 0){const f=new Ct;f.fromArray(e.matrix),l.applyMatrix4(f)}else e.translation!==void 0&&l.position.fromArray(e.translation),e.rotation!==void 0&&l.quaternion.fromArray(e.rotation),e.scale!==void 0&&l.scale.fromArray(e.scale);return n.associations.has(l)||n.associations.set(l,{}),n.associations.get(l).nodes=t,l}),this.nodeCache[t]}loadScene(t){const i=this.extensions,c=this.json.scenes[t],n=this,e=new ar;c.name&&(e.name=n.createUniqueName(c.name)),ot(e,c),c.extensions&&mt(i,e,c);const r=c.nodes||[],a=[];for(let o=0,s=r.length;o<s;o++)a.push(n.getDependency("node",r[o]));return Promise.all(a).then(function(o){for(let l=0,f=o.length;l<f;l++)e.add(o[l]);const s=l=>{const f=new Map;for(const[d,h]of n.associations)(d instanceof or||d instanceof cn)&&f.set(d,h);return l.traverse(d=>{const h=n.associations.get(d);h!=null&&f.set(d,h)}),f};return n.associations=s(e),e})}_createAnimationTracks(t,i,c,n,e){const r=[],a=t.name?t.name:t.uuid,o=[];dt[e.path]===dt.weights?t.traverse(function(d){d.morphTargetInfluences&&o.push(d.name?d.name:d.uuid)}):o.push(a);let s;switch(dt[e.path]){case dt.weights:s=so;break;case dt.rotation:s=io;break;case dt.position:case dt.scale:s=ao;break;default:switch(c.itemSize){case 1:s=so;break;case 2:case 3:default:s=ao;break}break}const l=n.interpolation!==void 0?nc[n.interpolation]:Ta,f=this._getArrayFromAccessor(c);for(let d=0,h=o.length;d<h;d++){const A=new s(o[d]+"."+dt[e.path],i.array,f,l);n.interpolation==="CUBICSPLINE"&&this._createCubicSplineTrackInterpolant(A),r.push(A)}return r}_getArrayFromAccessor(t){let i=t.array;if(t.normalized){const c=Fr(i.constructor),n=new Float32Array(i.length);for(let e=0,r=i.length;e<r;e++)n[e]=i[e]*c;i=n}return i}_createCubicSplineTrackInterpolant(t){t.createInterpolant=function(c){const n=this instanceof io?tc:wa;return new n(this.times,this.values,this.getValueSize()/3,c)},t.createInterpolant.isInterpolantFactoryMethodGLTFCubicSpline=!0}}function uc(u,t,i){const c=t.attributes,n=new Gr;if(c.POSITION!==void 0){const a=i.json.accessors[c.POSITION],o=a.min,s=a.max;if(o!==void 0&&s!==void 0){if(n.set(new ke(o[0],o[1],o[2]),new ke(s[0],s[1],s[2])),a.normalized){const l=Fr(St[a.componentType]);n.min.multiplyScalar(l),n.max.multiplyScalar(l)}}else{console.warn("THREE.GLTFLoader: Missing min/max properties for accessor POSITION.");return}}else return;const e=t.targets;if(e!==void 0){const a=new ke,o=new ke;for(let s=0,l=e.length;s<l;s++){const f=e[s];if(f.POSITION!==void 0){const d=i.json.accessors[f.POSITION],h=d.min,A=d.max;if(h!==void 0&&A!==void 0){if(o.setX(Math.max(Math.abs(h[0]),Math.abs(A[0]))),o.setY(Math.max(Math.abs(h[1]),Math.abs(A[1]))),o.setZ(Math.max(Math.abs(h[2]),Math.abs(A[2]))),d.normalized){const m=Fr(St[d.componentType]);o.multiplyScalar(m)}a.max(o)}else console.warn("THREE.GLTFLoader: Missing min/max properties for accessor POSITION.")}}n.expandByVector(a)}u.boundingBox=n;const r=new Ga;n.getCenter(r.center),r.radius=n.min.distanceTo(n.max)/2,u.boundingSphere=r}function zo(u,t,i){const c=t.attributes,n=[];function e(r,a){return i.getDependency("accessor",r).then(function(o){u.setAttribute(a,o)})}for(const r in c){const a=br[r]||r.toLowerCase();a in u.attributes||n.push(e(c[r],a))}if(t.indices!==void 0&&!u.index){const r=i.getDependency("accessor",t.indices).then(function(a){u.setIndex(a)});n.push(r)}return ot(u,t),uc(u,t,i),Promise.all(n).then(function(){return t.targets!==void 0?oc(u,t.targets,i):u})}const ur=new WeakMap;class fc extends va{constructor(t){super(t),this.decoderPath="",this.decoderConfig={},this.decoderBinary=null,this.decoderPending=null,this.workerLimit=4,this.workerPool=[],this.workerNextTaskID=1,this.workerSourceURL="",this.defaultAttributeIDs={position:"POSITION",normal:"NORMAL",color:"COLOR",uv:"TEX_COORD"},this.defaultAttributeTypes={position:"Float32Array",normal:"Float32Array",color:"Float32Array",uv:"Float32Array"}}setDecoderPath(t){return this.decoderPath=t,this}setDecoderConfig(t){return this.decoderConfig=t,this}setWorkerLimit(t){return this.workerLimit=t,this}load(t,i,c,n){const e=new xn(this.manager);e.setPath(this.path),e.setResponseType("arraybuffer"),e.setRequestHeader(this.requestHeader),e.setWithCredentials(this.withCredentials),e.load(t,r=>{const a={attributeIDs:this.defaultAttributeIDs,attributeTypes:this.defaultAttributeTypes,useUniqueIDs:!1};this.decodeGeometry(r,a).then(i).catch(n)},c,n)}decodeDracoFile(t,i,c,n){const e={attributeIDs:c||this.defaultAttributeIDs,attributeTypes:n||this.defaultAttributeTypes,useUniqueIDs:!!c};this.decodeGeometry(t,e).then(i)}decodeGeometry(t,i){for(const o in i.attributeTypes){const s=i.attributeTypes[o];s.BYTES_PER_ELEMENT!==void 0&&(i.attributeTypes[o]=s.name)}const c=JSON.stringify(i);if(ur.has(t)){const o=ur.get(t);if(o.key===c)return o.promise;if(t.byteLength===0)throw new Error("THREE.DRACOLoader: Unable to re-decode a buffer with different settings. Buffer has already been transferred.")}let n;const e=this.workerNextTaskID++,r=t.byteLength,a=this._getWorker(e,r).then(o=>(n=o,new Promise((s,l)=>{n._callbacks[e]={resolve:s,reject:l},n.postMessage({type:"decode",id:e,taskConfig:i,buffer:t},[t])}))).then(o=>this._createGeometry(o.geometry));return a.catch(()=>!0).then(()=>{n&&e&&this._releaseTask(n,e)}),ur.set(t,{key:c,promise:a}),a}_createGeometry(t){const i=new Ea;t.index&&i.setIndex(new rn(t.index.array,1));for(let c=0;c<t.attributes.length;c++){const n=t.attributes[c],e=n.name,r=n.array,a=n.itemSize;i.setAttribute(e,new rn(r,a))}return i}_loadLibrary(t,i){const c=new xn(this.manager);return c.setPath(this.decoderPath),c.setResponseType(i),c.setWithCredentials(this.withCredentials),new Promise((n,e)=>{c.load(t,n,void 0,e)})}preload(){return this._initDecoder(),this}_initDecoder(){if(this.decoderPending)return this.decoderPending;const t=typeof WebAssembly!="object"||this.decoderConfig.type==="js",i=[];return t?i.push(this._loadLibrary("draco_decoder.js","text")):(i.push(this._loadLibrary("draco_wasm_wrapper.js","text")),i.push(this._loadLibrary("draco_decoder.wasm","arraybuffer"))),this.decoderPending=Promise.all(i).then(c=>{const n=c[0];t||(this.decoderConfig.wasmBinary=c[1]);const e=dc.toString(),r=["/* draco decoder */",n,"","/* worker */",e.substring(e.indexOf("{")+1,e.lastIndexOf("}"))].join(`
3
3
  `);this.workerSourceURL=URL.createObjectURL(new Blob([r]))}),this.decoderPending}_getWorker(t,i){return this._initDecoder().then(()=>{if(this.workerPool.length<this.workerLimit){const n=new Worker(this.workerSourceURL);n._callbacks={},n._taskCosts={},n._taskLoad=0,n.postMessage({type:"init",decoderConfig:this.decoderConfig}),n.onmessage=function(e){const r=e.data;switch(r.type){case"decode":n._callbacks[r.id].resolve(r);break;case"error":n._callbacks[r.id].reject(r);break;default:console.error('THREE.DRACOLoader: Unexpected message, "'+r.type+'"')}},this.workerPool.push(n)}else this.workerPool.sort(function(n,e){return n._taskLoad>e._taskLoad?-1:1});const c=this.workerPool[this.workerPool.length-1];return c._taskCosts[t]=i,c._taskLoad+=i,c})}_releaseTask(t,i){t._taskLoad-=t._taskCosts[i],delete t._callbacks[i],delete t._taskCosts[i]}debug(){console.log("Task load: ",this.workerPool.map(t=>t._taskLoad))}dispose(){for(let t=0;t<this.workerPool.length;++t)this.workerPool[t].terminate();return this.workerPool.length=0,this}}function dc(){let u,t;onmessage=function(r){const a=r.data;switch(a.type){case"init":u=a.decoderConfig,t=new Promise(function(l){u.onModuleLoaded=function(f){l({draco:f})},DracoDecoderModule(u)});break;case"decode":const o=a.buffer,s=a.taskConfig;t.then(l=>{const f=l.draco,d=new f.Decoder,h=new f.DecoderBuffer;h.Init(new Int8Array(o),o.byteLength);try{const A=i(f,d,h,s),m=A.attributes.map(p=>p.array.buffer);A.index&&m.push(A.index.array.buffer),self.postMessage({type:"decode",id:a.id,geometry:A},m)}catch(A){console.error(A),self.postMessage({type:"error",id:a.id,error:A.message})}finally{f.destroy(h),f.destroy(d)}});break}};function i(r,a,o,s){const l=s.attributeIDs,f=s.attributeTypes;let d,h;const A=a.GetEncodedGeometryType(o);if(A===r.TRIANGULAR_MESH)d=new r.Mesh,h=a.DecodeBufferToMesh(o,d);else if(A===r.POINT_CLOUD)d=new r.PointCloud,h=a.DecodeBufferToPointCloud(o,d);else throw new Error("THREE.DRACOLoader: Unexpected geometry type.");if(!h.ok()||d.ptr===0)throw new Error("THREE.DRACOLoader: Decoding failed: "+h.error_msg());const m={index:null,attributes:[]};for(const p in l){const v=self[f[p]];let C,b;if(s.useUniqueIDs)b=l[p],C=a.GetAttributeByUniqueId(d,b);else{if(b=a.GetAttributeId(d,r[l[p]]),b===-1)continue;C=a.GetAttribute(d,b)}m.attributes.push(n(r,a,d,p,v,C))}return A===r.TRIANGULAR_MESH&&(m.index=c(r,a,d)),r.destroy(d),m}function c(r,a,o){const l=o.num_faces()*3,f=l*4,d=r._malloc(f);a.GetTrianglesUInt32Array(o,f,d);const h=new Uint32Array(r.HEAPF32.buffer,d,l).slice();return r._free(d),{array:h,itemSize:1}}function n(r,a,o,s,l,f){const d=f.num_components(),A=o.num_points()*d,m=A*l.BYTES_PER_ELEMENT,p=e(r,l),v=r._malloc(m);a.GetAttributeDataArrayForAllPoints(o,f,p,m,v);const C=new l(r.HEAPF32.buffer,v,A).slice();return r._free(v),{name:s,array:C,itemSize:d}}function e(r,a){switch(a){case Float32Array:return r.DT_FLOAT32;case Int8Array:return r.DT_INT8;case Int16Array:return r.DT_INT16;case Int32Array:return r.DT_INT32;case Uint8Array:return r.DT_UINT8;case Uint16Array:return r.DT_UINT16;case Uint32Array:return r.DT_UINT32}}}let Fn;const fr=()=>{if(Fn)return Fn;const u="B9h9z9tFBBBF8fL9gBB9gLaaaaaFa9gEaaaB9gFaFa9gEaaaFaEMcBFFFGGGEIIILF9wFFFLEFBFKNFaFCx/IFMO/LFVK9tv9t9vq95GBt9f9f939h9z9t9f9j9h9s9s9f9jW9vq9zBBp9tv9z9o9v9wW9f9kv9j9v9kv9WvqWv94h919m9mvqBF8Z9tv9z9o9v9wW9f9kv9j9v9kv9J9u9kv94h919m9mvqBGy9tv9z9o9v9wW9f9kv9j9v9kv9J9u9kv949TvZ91v9u9jvBEn9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9P9jWBIi9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9R919hWBLn9tv9z9o9v9wW9f9kv9j9v9kv69p9sWvq9F949wBKI9z9iqlBOc+x8ycGBM/qQFTa8jUUUUBCU/EBlHL8kUUUUBC9+RKGXAGCFJAI9LQBCaRKAE2BBC+gF9HQBALAEAIJHOAGlAGTkUUUBRNCUoBAG9uC/wgBZHKCUGAKCUG9JyRVAECFJRICBRcGXEXAcAF9PQFAVAFAclAcAVJAF9JyRMGXGXAG9FQBAMCbJHKC9wZRSAKCIrCEJCGrRQANCUGJRfCBRbAIRTEXGXAOATlAQ9PQBCBRISEMATAQJRIGXAS9FQBCBRtCBREEXGXAOAIlCi9PQBCBRISLMANCU/CBJAEJRKGXGXGXGXGXATAECKrJ2BBAtCKZrCEZfIBFGEBMAKhB83EBAKCNJhB83EBSEMAKAI2BIAI2BBHmCKrHYAYCE6HYy86BBAKCFJAICIJAYJHY2BBAmC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BAGCIJHGAF9JQBMMM/hEIGaF97FaL978jUUUUBCTlREGXAF9FQBCBRIEXAEABDBBBHLABCTJHKDBBBHODQILKOSQfbPden8c8d8e8fHNCTD+sFHVCID+rFDMIBAB9DBBU8/DY9D/zI818/DYAVCEDtD9QD/6FD/nFHVALAODQBFGENVcMTtmYi8ZpyHLCTD+rFCTD+sFD/6FD/mFHOAOD/mFAVALCTD+sFD/6FD/mFHcAcD/mFAVANCTD+rFCTD+sFD/6FD/mFHNAND/mFD/kFD/kFD/lFCBDtD+4FD/jF9DB/+g6DYHVD/mF9DBBX9LDYHLD/kFCggEDtHMD9OAcAVD/mFALD/kFCTD+rFD9QHcANAVD/mFALD/kFCTD+rFAOAVD/mFALD/kFAMD9OD9QHVDQBFTtGEmYILPdKOenHLD8dBAEDBIBDyB+t+J83EBABCNJALD8dFAEDBIBDyF+t+J83EBAKAcAVDQNVi8ZcMpySQ8c8dfb8e8fHVD8dBAEDBIBDyG+t+J83EBABCiJAVD8dFAEDBIBDyE+t+J83EBABCAJRBAICIJHIAF9JQBMMM9jFF97GXAGCGrAF9sHG9FQBCBRFEXABABDBBBHECND+rFCND+sFD/6FAECiD+sFCnD+rFCUUU/8EDtD+uFD/mFDMBBABCTJRBAFCIJHFAG9JQBMMM9TFEaCBCB8oGUkUUBHFABCEJC98ZJHBjGUkUUBGXGXAB8/BCTWHGuQBCaREABAGlCggEJCTrXBCa6QFMAFREMAEMMMFBCUNMIT9tBB",i=new Uint8Array([0,97,115,109,1,0,0,0,1,4,1,96,0,0,3,3,2,0,0,5,3,1,0,1,12,1,0,10,22,2,12,0,65,0,65,0,65,0,252,10,0,0,11,7,0,65,0,253,15,26,11]),c=new Uint8Array([32,0,65,253,3,1,2,34,4,106,6,5,11,8,7,20,13,33,12,16,128,9,116,64,19,113,127,15,10,21,22,14,255,66,24,54,136,107,18,23,192,26,114,118,132,17,77,101,130,144,27,87,131,44,45,74,156,154,70,167]);if(typeof WebAssembly!="object")return{supported:!1};let n=u;WebAssembly.validate(i)&&(n=t);let e;const r=WebAssembly.instantiate(a(n),{}).then(f=>{e=f.instance,e.exports.__wasm_call_ctors()});function a(f){const d=new Uint8Array(f.length);for(let A=0;A<f.length;++A){const m=f.charCodeAt(A);d[A]=m>96?m-71:m>64?m-65:m>47?m+4:m>46?63:62}let h=0;for(let A=0;A<f.length;++A)d[h++]=d[A]<60?c[d[A]]:(d[A]-60)*64+d[++A];return d.buffer.slice(0,h)}function o(f,d,h,A,m,p){const v=e.exports.sbrk,C=h+3&-4,b=v(C*A),g=v(m.length),E=new Uint8Array(e.exports.memory.buffer);E.set(m,g);const D=f(b,h,A,g,m.length);if(D===0&&p&&p(b,C,A),d.set(E.subarray(b,b+h*A)),v(b-v(0)),D!==0)throw new Error(`Malformed buffer data: ${D}`)}const s={0:"",1:"meshopt_decodeFilterOct",2:"meshopt_decodeFilterQuat",3:"meshopt_decodeFilterExp",NONE:"",OCTAHEDRAL:"meshopt_decodeFilterOct",QUATERNION:"meshopt_decodeFilterQuat",EXPONENTIAL:"meshopt_decodeFilterExp"},l={0:"meshopt_decodeVertexBuffer",1:"meshopt_decodeIndexBuffer",2:"meshopt_decodeIndexSequence",ATTRIBUTES:"meshopt_decodeVertexBuffer",TRIANGLES:"meshopt_decodeIndexBuffer",INDICES:"meshopt_decodeIndexSequence"};return Fn={ready:r,supported:!0,decodeVertexBuffer(f,d,h,A,m){o(e.exports.meshopt_decodeVertexBuffer,f,d,h,A,e.exports[s[m]])},decodeIndexBuffer(f,d,h,A){o(e.exports.meshopt_decodeIndexBuffer,f,d,h,A)},decodeIndexSequence(f,d,h,A){o(e.exports.meshopt_decodeIndexSequence,f,d,h,A)},decodeGltfBuffer(f,d,h,A,m,p){o(e.exports[l[m]],f,d,h,A,e.exports[s[p]])}},Fn};function hc(){var u=Object.create(null);function t(n,e){var r=n.id,a=n.name,o=n.dependencies;o===void 0&&(o=[]);var s=n.init;s===void 0&&(s=function(){});var l=n.getTransferables;if(l===void 0&&(l=null),!u[r])try{o=o.map(function(d){return d&&d.isWorkerModule&&(t(d,function(h){if(h instanceof Error)throw h}),d=u[d.id].value),d}),s=c("<"+a+">.init",s),l&&(l=c("<"+a+">.getTransferables",l));var f=null;typeof s=="function"?f=s.apply(void 0,o):console.error("worker module init function failed to rehydrate"),u[r]={id:r,value:f,getTransferables:l},e(f)}catch(d){d&&d.noLog||console.error(d),e(d)}}function i(n,e){var r,a=n.id,o=n.args;(!u[a]||typeof u[a].value!="function")&&e(new Error("Worker module "+a+": not found or its 'init' did not return a function"));try{var s=(r=u[a]).value.apply(r,o);s&&typeof s.then=="function"?s.then(l,function(f){return e(f instanceof Error?f:new Error(""+f))}):l(s)}catch(f){e(f)}function l(f){try{var d=u[a].getTransferables&&u[a].getTransferables(f);(!d||!Array.isArray(d)||!d.length)&&(d=void 0),e(f,d)}catch(h){console.error(h),e(h)}}}function c(n,e){var r=void 0;self.troikaDefine=function(o){return r=o};var a=URL.createObjectURL(new Blob(["/** "+n.replace(/\*/g,"")+` **/
4
4
 
@@ -1,4 +1,4 @@
1
- import{r as M,j as f}from"./iframe-wVHIxtK4.js";import"./preload-helper-C1FmrZbK.js";const E="_paper_1xdmc_18",P="_folder__front_1xdmc_22",R="_right_1xdmc_26",X="_open_1xdmc_30",Y="_folder__back_1xdmc_68",l={paper:E,folder__front:P,right:R,open:X,folder__back:Y},h=(n,m)=>{let c=n.startsWith("#")?n.slice(1):n;c.length===3&&(c=c.split("").map(u=>u+u).join(""));const p=parseInt(c,16);let i=p>>16&255,a=p>>8&255,s=p&255;return i=Math.max(0,Math.min(255,Math.floor(i*(1-m)))),a=Math.max(0,Math.min(255,Math.floor(a*(1-m)))),s=Math.max(0,Math.min(255,Math.floor(s*(1-m)))),"#"+((1<<24)+(i<<16)+(a<<8)+s).toString(16).slice(1).toUpperCase()},$=({color:n="#5227FF",size:m=1,items:c=[],className:p=""})=>{const a=c.slice(0,3);for(;a.length<3;)a.push(null);const[s,u]=M.useState(!1),[g,x]=M.useState(Array.from({length:3},()=>({x:0,y:0}))),j=h(n,.08),k=h("#ffffff",.1),C=h("#ffffff",.05),D="#ffffff",N=()=>{u(o=>!o),s&&x(Array.from({length:3},()=>({x:0,y:0})))},I=(o,e)=>{if(!s)return;const t=o.currentTarget.getBoundingClientRect(),r=t.left+t.width/2,d=t.top+t.height/2,V=(o.clientX-r)*.15,z=(o.clientY-d)*.15;x(B=>{const y=[...B];return y[e]={x:V,y:z},y})},O=(o,e)=>{x(t=>{const r=[...t];return r[e]={x:0,y:0},r})},S={"--folder-color":n,"--folder-back-color":j,"--paper-1":k,"--paper-2":C,"--paper-3":D},q=`folder ${s?l.open:""}`.trim(),w={transform:`scale(${m})`};return f.jsx("div",{style:w,className:p,children:f.jsx("div",{className:q,style:S,onClick:N,children:f.jsxs("div",{className:`${l.folder__back}`,children:[a.map((o,e)=>{var t,r;return f.jsx("div",{className:`${l.paper} ${l.paper}-${e+1}`,onMouseMove:d=>I(d,e),onMouseLeave:d=>O(d,e),style:s?{"--magnet-x":`${((t=g[e])==null?void 0:t.x)||0}px`,"--magnet-y":`${((r=g[e])==null?void 0:r.y)||0}px`}:{},children:o},e)}),f.jsx("div",{className:`${l.folder__front}`}),f.jsx("div",{className:`${l.folder__front} ${l.right}`})]})})})};$.__docgenInfo={description:"",methods:[],displayName:"Folder",props:{color:{defaultValue:{value:"'#5227FF'",computed:!1},required:!1},size:{defaultValue:{value:"1",computed:!1},required:!1},items:{defaultValue:{value:"[]",computed:!1},required:!1},className:{defaultValue:{value:"''",computed:!1},required:!1}}};const T={title:"ReactBits/Components/Folder",component:$,parameters:{layout:"fullscreen"}},_={args:{color:"#5227FF",size:1,items:[{label:"Document 1"},{label:"Document 2"},{label:"Document 3"}]}};var v,b,F;_.parameters={..._.parameters,docs:{...(v=_.parameters)==null?void 0:v.docs,source:{originalSource:`{
1
+ import{r as M,j as f}from"./iframe-BmJYCQaV.js";import"./preload-helper-C1FmrZbK.js";const E="_paper_1xdmc_18",P="_folder__front_1xdmc_22",R="_right_1xdmc_26",X="_open_1xdmc_30",Y="_folder__back_1xdmc_68",l={paper:E,folder__front:P,right:R,open:X,folder__back:Y},h=(n,m)=>{let c=n.startsWith("#")?n.slice(1):n;c.length===3&&(c=c.split("").map(u=>u+u).join(""));const p=parseInt(c,16);let i=p>>16&255,a=p>>8&255,s=p&255;return i=Math.max(0,Math.min(255,Math.floor(i*(1-m)))),a=Math.max(0,Math.min(255,Math.floor(a*(1-m)))),s=Math.max(0,Math.min(255,Math.floor(s*(1-m)))),"#"+((1<<24)+(i<<16)+(a<<8)+s).toString(16).slice(1).toUpperCase()},$=({color:n="#5227FF",size:m=1,items:c=[],className:p=""})=>{const a=c.slice(0,3);for(;a.length<3;)a.push(null);const[s,u]=M.useState(!1),[g,x]=M.useState(Array.from({length:3},()=>({x:0,y:0}))),j=h(n,.08),k=h("#ffffff",.1),C=h("#ffffff",.05),D="#ffffff",N=()=>{u(o=>!o),s&&x(Array.from({length:3},()=>({x:0,y:0})))},I=(o,e)=>{if(!s)return;const t=o.currentTarget.getBoundingClientRect(),r=t.left+t.width/2,d=t.top+t.height/2,V=(o.clientX-r)*.15,z=(o.clientY-d)*.15;x(B=>{const y=[...B];return y[e]={x:V,y:z},y})},O=(o,e)=>{x(t=>{const r=[...t];return r[e]={x:0,y:0},r})},S={"--folder-color":n,"--folder-back-color":j,"--paper-1":k,"--paper-2":C,"--paper-3":D},q=`folder ${s?l.open:""}`.trim(),w={transform:`scale(${m})`};return f.jsx("div",{style:w,className:p,children:f.jsx("div",{className:q,style:S,onClick:N,children:f.jsxs("div",{className:`${l.folder__back}`,children:[a.map((o,e)=>{var t,r;return f.jsx("div",{className:`${l.paper} ${l.paper}-${e+1}`,onMouseMove:d=>I(d,e),onMouseLeave:d=>O(d,e),style:s?{"--magnet-x":`${((t=g[e])==null?void 0:t.x)||0}px`,"--magnet-y":`${((r=g[e])==null?void 0:r.y)||0}px`}:{},children:o},e)}),f.jsx("div",{className:`${l.folder__front}`}),f.jsx("div",{className:`${l.folder__front} ${l.right}`})]})})})};$.__docgenInfo={description:"",methods:[],displayName:"Folder",props:{color:{defaultValue:{value:"'#5227FF'",computed:!1},required:!1},size:{defaultValue:{value:"1",computed:!1},required:!1},items:{defaultValue:{value:"[]",computed:!1},required:!1},className:{defaultValue:{value:"''",computed:!1},required:!1}}};const T={title:"ReactBits/Components/Folder",component:$,parameters:{layout:"fullscreen"}},_={args:{color:"#5227FF",size:1,items:[{label:"Document 1"},{label:"Document 2"},{label:"Document 3"}]}};var v,b,F;_.parameters={..._.parameters,docs:{...(v=_.parameters)==null?void 0:v.docs,source:{originalSource:`{
2
2
  args: {
3
3
  color: '#5227FF',
4
4
  size: 1,
@@ -1,4 +1,4 @@
1
- import{r as de,j as Fe,R as Ie}from"./iframe-wVHIxtK4.js";import"./preload-helper-C1FmrZbK.js";const ve=({children:Y,fontSize:d="clamp(2rem, 10vw, 10rem)",fontWeight:E=900,fontFamily:L="inherit",color:P="#fff",enableHover:v=!0,baseIntensity:F=.18,hoverIntensity:J=.5,fuzzRange:n=30,fps:K=60,direction:D="horizontal",transitionDuration:C=0,clickEffect:I=!1,glitchMode:A=!1,glitchInterval:Q=2e3,glitchDuration:U=200,gradient:h=null,letterSpacing:f=0,className:xe=""})=>{const Z=de.useRef(null);return de.useEffect(()=>{let x,y=!1,$,j,M;const a=Z.current;return a?((async()=>{const r=a.getContext("2d");if(!r)return;const S=L==="inherit"?window.getComputedStyle(a).fontFamily||"sans-serif":L,W=typeof d=="number"?`${d}px`:d,ye=`${E} ${W} ${S}`;try{await document.fonts.load(ye)}catch{await document.fonts.ready}if(y)return;let V;if(typeof d=="number")V=d;else{const t=document.createElement("span");t.style.fontSize=d,document.body.appendChild(t);const e=window.getComputedStyle(t).fontSize;V=parseFloat(e),document.body.removeChild(t)}const T=Ie.Children.toArray(Y).join(""),p=document.createElement("canvas"),o=p.getContext("2d");if(!o)return;o.font=`${E} ${W} ${S}`,o.textBaseline="alphabetic";let w=0;if(f!==0){for(const t of T)w+=o.measureText(t).width+f;w-=f}else w=o.measureText(T).width;const g=o.measureText(T),R=g.actualBoundingBoxLeft??0,Te=f!==0?w:g.actualBoundingBoxRight??g.width,b=g.actualBoundingBoxAscent??V,we=g.actualBoundingBoxDescent??V*.2,z=Math.ceil(f!==0?w:R+Te),i=Math.ceil(b+we),ee=10,s=z+ee;p.width=s,p.height=i;const k=ee/2;if(o.font=`${E} ${W} ${S}`,o.textBaseline="alphabetic",h&&Array.isArray(h)&&h.length>=2){const t=o.createLinearGradient(0,0,s,0);h.forEach((e,l)=>t.addColorStop(l/(h.length-1),e)),o.fillStyle=t}else o.fillStyle=P;if(f!==0){let t=k;for(const e of T)o.fillText(e,t,b),t+=o.measureText(e).width+f}else o.fillText(T,k-R,b);const _=n+20,G=0;a.width=s+_*2,a.height=i+G*2,r.translate(_,G);const te=_+k,ae=G,ge=te+z,qe=ae+i;let q=!1,H=!1,N=!1,c=F,u=F,le=0;const ne=1e3/K,oe=()=>{!A||y||($=setTimeout(()=>{y||(N=!0,j=setTimeout(()=>{N=!1,oe()},U))},Q))};A&&oe();const O=t=>{if(!y){if(t-le<ne){x=window.requestAnimationFrame(O);return}if(le=t,r.clearRect(-n-20,-n-10,s+2*(n+20),i+2*(n+10)),H||N?u=1:q?u=J:u=F,C>0){const e=1/(C/ne);c<u?c=Math.min(c+e,u):c>u&&(c=Math.max(c-e,u))}else c=u;if(D==="horizontal")for(let e=0;e<i;e++){const l=Math.floor(c*(Math.random()-.5)*n);r.drawImage(p,0,e,s,1,l,e,s,1)}else if(D==="vertical")for(let e=0;e<s;e++){const l=Math.floor(c*(Math.random()-.5)*n);r.drawImage(p,e,0,1,i,e,l,1,i)}else{for(let l=0;l<i;l++){const m=Math.floor(c*(Math.random()-.5)*n);r.drawImage(p,0,l,s,1,m,l,s,1)}const e=r.getImageData(0,0,s+n,i+n);r.clearRect(-n-20,-n-10,s+2*(n+20),i+2*(n+10)),r.putImageData(e,0,0);for(let l=0;l<s+n;l++){const m=Math.floor(c*(Math.random()-.5)*n*.5),X=r.getImageData(l,0,1,i+n);r.clearRect(l,-n,1,i+2*n),r.putImageData(X,l,m)}}x=window.requestAnimationFrame(O)}};x=window.requestAnimationFrame(O);const re=(t,e)=>t>=te&&t<=ge&&e>=ae&&e<=qe,ie=t=>{if(!v)return;const e=a.getBoundingClientRect(),l=t.clientX-e.left,m=t.clientY-e.top;q=re(l,m)},se=()=>{q=!1},ce=()=>{I&&(H=!0,clearTimeout(M),M=setTimeout(()=>{H=!1},150))},ue=t=>{if(!v)return;t.preventDefault();const e=a.getBoundingClientRect(),l=t.touches[0],m=l.clientX-e.left,X=l.clientY-e.top;q=re(m,X)},fe=()=>{q=!1};v&&(a.addEventListener("mousemove",ie),a.addEventListener("mouseleave",se),a.addEventListener("touchmove",ue,{passive:!1}),a.addEventListener("touchend",fe)),I&&a.addEventListener("click",ce);const Ee=()=>{window.cancelAnimationFrame(x),clearTimeout($),clearTimeout(j),clearTimeout(M),v&&(a.removeEventListener("mousemove",ie),a.removeEventListener("mouseleave",se),a.removeEventListener("touchmove",ue),a.removeEventListener("touchend",fe)),I&&a.removeEventListener("click",ce)};a.cleanupFuzzyText=Ee})(),()=>{y=!0,window.cancelAnimationFrame(x),clearTimeout($),clearTimeout(j),clearTimeout(M),a&&a.cleanupFuzzyText&&a.cleanupFuzzyText()}):void 0},[Y,d,E,L,P,v,F,J,n,K,D,C,I,A,Q,U,h,f]),Fe.jsx("canvas",{ref:Z,className:xe})};ve.__docgenInfo={description:"",methods:[],displayName:"FuzzyText",props:{fontSize:{defaultValue:{value:"'clamp(2rem, 10vw, 10rem)'",computed:!1},required:!1},fontWeight:{defaultValue:{value:"900",computed:!1},required:!1},fontFamily:{defaultValue:{value:"'inherit'",computed:!1},required:!1},color:{defaultValue:{value:"'#fff'",computed:!1},required:!1},enableHover:{defaultValue:{value:"true",computed:!1},required:!1},baseIntensity:{defaultValue:{value:"0.18",computed:!1},required:!1},hoverIntensity:{defaultValue:{value:"0.5",computed:!1},required:!1},fuzzRange:{defaultValue:{value:"30",computed:!1},required:!1},fps:{defaultValue:{value:"60",computed:!1},required:!1},direction:{defaultValue:{value:"'horizontal'",computed:!1},required:!1},transitionDuration:{defaultValue:{value:"0",computed:!1},required:!1},clickEffect:{defaultValue:{value:"false",computed:!1},required:!1},glitchMode:{defaultValue:{value:"false",computed:!1},required:!1},glitchInterval:{defaultValue:{value:"2000",computed:!1},required:!1},glitchDuration:{defaultValue:{value:"200",computed:!1},required:!1},gradient:{defaultValue:{value:"null",computed:!1},required:!1},letterSpacing:{defaultValue:{value:"0",computed:!1},required:!1},className:{defaultValue:{value:"''",computed:!1},required:!1}}};const Le={title:"ReactBits/TextAnimations/FuzzyText",component:ve,parameters:{layout:"fullscreen"}},B={args:{children:"Hello World",fontSize:"clamp(2rem, 10vw, 10rem)",fontWeight:900,fontFamily:"inherit",color:"#fff",enableHover:!0,baseIntensity:.18,hoverIntensity:.5,fuzzRange:30,fps:60,direction:"horizontal",transitionDuration:0,clickEffect:!1,glitchMode:!1,glitchInterval:2e3,glitchDuration:200,gradient:null,letterSpacing:0}};var me,he,pe;B.parameters={...B.parameters,docs:{...(me=B.parameters)==null?void 0:me.docs,source:{originalSource:`{
1
+ import{r as de,j as Fe,R as Ie}from"./iframe-BmJYCQaV.js";import"./preload-helper-C1FmrZbK.js";const ve=({children:Y,fontSize:d="clamp(2rem, 10vw, 10rem)",fontWeight:E=900,fontFamily:L="inherit",color:P="#fff",enableHover:v=!0,baseIntensity:F=.18,hoverIntensity:J=.5,fuzzRange:n=30,fps:K=60,direction:D="horizontal",transitionDuration:C=0,clickEffect:I=!1,glitchMode:A=!1,glitchInterval:Q=2e3,glitchDuration:U=200,gradient:h=null,letterSpacing:f=0,className:xe=""})=>{const Z=de.useRef(null);return de.useEffect(()=>{let x,y=!1,$,j,M;const a=Z.current;return a?((async()=>{const r=a.getContext("2d");if(!r)return;const S=L==="inherit"?window.getComputedStyle(a).fontFamily||"sans-serif":L,W=typeof d=="number"?`${d}px`:d,ye=`${E} ${W} ${S}`;try{await document.fonts.load(ye)}catch{await document.fonts.ready}if(y)return;let V;if(typeof d=="number")V=d;else{const t=document.createElement("span");t.style.fontSize=d,document.body.appendChild(t);const e=window.getComputedStyle(t).fontSize;V=parseFloat(e),document.body.removeChild(t)}const T=Ie.Children.toArray(Y).join(""),p=document.createElement("canvas"),o=p.getContext("2d");if(!o)return;o.font=`${E} ${W} ${S}`,o.textBaseline="alphabetic";let w=0;if(f!==0){for(const t of T)w+=o.measureText(t).width+f;w-=f}else w=o.measureText(T).width;const g=o.measureText(T),R=g.actualBoundingBoxLeft??0,Te=f!==0?w:g.actualBoundingBoxRight??g.width,b=g.actualBoundingBoxAscent??V,we=g.actualBoundingBoxDescent??V*.2,z=Math.ceil(f!==0?w:R+Te),i=Math.ceil(b+we),ee=10,s=z+ee;p.width=s,p.height=i;const k=ee/2;if(o.font=`${E} ${W} ${S}`,o.textBaseline="alphabetic",h&&Array.isArray(h)&&h.length>=2){const t=o.createLinearGradient(0,0,s,0);h.forEach((e,l)=>t.addColorStop(l/(h.length-1),e)),o.fillStyle=t}else o.fillStyle=P;if(f!==0){let t=k;for(const e of T)o.fillText(e,t,b),t+=o.measureText(e).width+f}else o.fillText(T,k-R,b);const _=n+20,G=0;a.width=s+_*2,a.height=i+G*2,r.translate(_,G);const te=_+k,ae=G,ge=te+z,qe=ae+i;let q=!1,H=!1,N=!1,c=F,u=F,le=0;const ne=1e3/K,oe=()=>{!A||y||($=setTimeout(()=>{y||(N=!0,j=setTimeout(()=>{N=!1,oe()},U))},Q))};A&&oe();const O=t=>{if(!y){if(t-le<ne){x=window.requestAnimationFrame(O);return}if(le=t,r.clearRect(-n-20,-n-10,s+2*(n+20),i+2*(n+10)),H||N?u=1:q?u=J:u=F,C>0){const e=1/(C/ne);c<u?c=Math.min(c+e,u):c>u&&(c=Math.max(c-e,u))}else c=u;if(D==="horizontal")for(let e=0;e<i;e++){const l=Math.floor(c*(Math.random()-.5)*n);r.drawImage(p,0,e,s,1,l,e,s,1)}else if(D==="vertical")for(let e=0;e<s;e++){const l=Math.floor(c*(Math.random()-.5)*n);r.drawImage(p,e,0,1,i,e,l,1,i)}else{for(let l=0;l<i;l++){const m=Math.floor(c*(Math.random()-.5)*n);r.drawImage(p,0,l,s,1,m,l,s,1)}const e=r.getImageData(0,0,s+n,i+n);r.clearRect(-n-20,-n-10,s+2*(n+20),i+2*(n+10)),r.putImageData(e,0,0);for(let l=0;l<s+n;l++){const m=Math.floor(c*(Math.random()-.5)*n*.5),X=r.getImageData(l,0,1,i+n);r.clearRect(l,-n,1,i+2*n),r.putImageData(X,l,m)}}x=window.requestAnimationFrame(O)}};x=window.requestAnimationFrame(O);const re=(t,e)=>t>=te&&t<=ge&&e>=ae&&e<=qe,ie=t=>{if(!v)return;const e=a.getBoundingClientRect(),l=t.clientX-e.left,m=t.clientY-e.top;q=re(l,m)},se=()=>{q=!1},ce=()=>{I&&(H=!0,clearTimeout(M),M=setTimeout(()=>{H=!1},150))},ue=t=>{if(!v)return;t.preventDefault();const e=a.getBoundingClientRect(),l=t.touches[0],m=l.clientX-e.left,X=l.clientY-e.top;q=re(m,X)},fe=()=>{q=!1};v&&(a.addEventListener("mousemove",ie),a.addEventListener("mouseleave",se),a.addEventListener("touchmove",ue,{passive:!1}),a.addEventListener("touchend",fe)),I&&a.addEventListener("click",ce);const Ee=()=>{window.cancelAnimationFrame(x),clearTimeout($),clearTimeout(j),clearTimeout(M),v&&(a.removeEventListener("mousemove",ie),a.removeEventListener("mouseleave",se),a.removeEventListener("touchmove",ue),a.removeEventListener("touchend",fe)),I&&a.removeEventListener("click",ce)};a.cleanupFuzzyText=Ee})(),()=>{y=!0,window.cancelAnimationFrame(x),clearTimeout($),clearTimeout(j),clearTimeout(M),a&&a.cleanupFuzzyText&&a.cleanupFuzzyText()}):void 0},[Y,d,E,L,P,v,F,J,n,K,D,C,I,A,Q,U,h,f]),Fe.jsx("canvas",{ref:Z,className:xe})};ve.__docgenInfo={description:"",methods:[],displayName:"FuzzyText",props:{fontSize:{defaultValue:{value:"'clamp(2rem, 10vw, 10rem)'",computed:!1},required:!1},fontWeight:{defaultValue:{value:"900",computed:!1},required:!1},fontFamily:{defaultValue:{value:"'inherit'",computed:!1},required:!1},color:{defaultValue:{value:"'#fff'",computed:!1},required:!1},enableHover:{defaultValue:{value:"true",computed:!1},required:!1},baseIntensity:{defaultValue:{value:"0.18",computed:!1},required:!1},hoverIntensity:{defaultValue:{value:"0.5",computed:!1},required:!1},fuzzRange:{defaultValue:{value:"30",computed:!1},required:!1},fps:{defaultValue:{value:"60",computed:!1},required:!1},direction:{defaultValue:{value:"'horizontal'",computed:!1},required:!1},transitionDuration:{defaultValue:{value:"0",computed:!1},required:!1},clickEffect:{defaultValue:{value:"false",computed:!1},required:!1},glitchMode:{defaultValue:{value:"false",computed:!1},required:!1},glitchInterval:{defaultValue:{value:"2000",computed:!1},required:!1},glitchDuration:{defaultValue:{value:"200",computed:!1},required:!1},gradient:{defaultValue:{value:"null",computed:!1},required:!1},letterSpacing:{defaultValue:{value:"0",computed:!1},required:!1},className:{defaultValue:{value:"''",computed:!1},required:!1}}};const Le={title:"ReactBits/TextAnimations/FuzzyText",component:ve,parameters:{layout:"fullscreen"}},B={args:{children:"Hello World",fontSize:"clamp(2rem, 10vw, 10rem)",fontWeight:900,fontFamily:"inherit",color:"#fff",enableHover:!0,baseIntensity:.18,hoverIntensity:.5,fuzzRange:30,fps:60,direction:"horizontal",transitionDuration:0,clickEffect:!1,glitchMode:!1,glitchInterval:2e3,glitchDuration:200,gradient:null,letterSpacing:0}};var me,he,pe;B.parameters={...B.parameters,docs:{...(me=B.parameters)==null?void 0:me.docs,source:{originalSource:`{
2
2
  args: {
3
3
  children: 'Hello World',
4
4
  fontSize: 'clamp(2rem, 10vw, 10rem)',
@@ -1,4 +1,4 @@
1
- import{r,j as B}from"./iframe-wVHIxtK4.js";import{R as K,P as j,M as Y}from"./Mesh-CwXV3WjE.js";import{T as W}from"./Triangle-64ffRKNB.js";import{C as E}from"./Color-YRkaOI4u.js";import"./preload-helper-C1FmrZbK.js";const X={"galaxy-container":"_galaxy-container_ks78v_1"},$=`
1
+ import{r,j as B}from"./iframe-BmJYCQaV.js";import{R as K,P as j,M as Y}from"./Mesh-CwXV3WjE.js";import{T as W}from"./Triangle-64ffRKNB.js";import{C as E}from"./Color-YRkaOI4u.js";import"./preload-helper-C1FmrZbK.js";const X={"galaxy-container":"_galaxy-container_ks78v_1"},$=`
2
2
  attribute vec2 uv;
3
3
  attribute vec2 position;
4
4
 
@@ -1,4 +1,4 @@
1
- import{r as o,j as je}from"./iframe-wVHIxtK4.js";import{M as Ee,a as Be,h as Xe,F as Ce,i as P,j as ce,d,k as Y,H as $,l as Ke,m as Ye,n as U,e as _,o as $e,p as Je,W as Ze,S as et,q as tt,r as ye}from"./three.module--_vTUKhS.js";import"./preload-helper-C1FmrZbK.js";const J={name:"CopyShader",uniforms:{tDiffuse:{value:null},opacity:{value:1}},vertexShader:`
1
+ import{r as o,j as je}from"./iframe-BmJYCQaV.js";import{M as Ee,a as Be,h as Xe,F as Ce,i as P,j as ce,d,k as Y,H as $,l as Ke,m as Ye,n as U,e as _,o as $e,p as Je,W as Ze,S as et,q as tt,r as ye}from"./three.module--_vTUKhS.js";import"./preload-helper-C1FmrZbK.js";const J={name:"CopyShader",uniforms:{tDiffuse:{value:null},opacity:{value:1}},vertexShader:`
2
2
 
3
3
  varying vec2 vUv;
4
4
 
@@ -1 +1 @@
1
- import{j}from"./iframe-wVHIxtK4.js";import"./preload-helper-C1FmrZbK.js";const f={"glare-hover":"_glare-hover_npabj_1","glare-hover--play-once":"_glare-hover--play-once_npabj_44"},n=({width:i="500px",height:g="500px",background:m="#000",borderRadius:v="10px",borderColor:h="#333",children:$,glareColor:u="#ffffff",glareOpacity:o=.5,glareAngle:b=-45,glareSize:q=250,transitionDuration:V=650,playOnce:x=!1,className:_="",style:y={}})=>{const e=u.replace("#","");let l=u;if(/^[0-9A-Fa-f]{6}$/.test(e)){const r=parseInt(e.slice(0,2),16),s=parseInt(e.slice(2,4),16),t=parseInt(e.slice(4,6),16);l=`rgba(${r}, ${s}, ${t}, ${o})`}else if(/^[0-9A-Fa-f]{3}$/.test(e)){const r=parseInt(e[0]+e[0],16),s=parseInt(e[1]+e[1],16),t=parseInt(e[2]+e[2],16);l=`rgba(${r}, ${s}, ${t}, ${o})`}const I={"--gh-width":i,"--gh-height":g,"--gh-bg":m,"--gh-br":v,"--gh-angle":`${b}deg`,"--gh-duration":`${V}ms`,"--gh-size":`${q}%`,"--gh-rgba":l,"--gh-border":h};return j.jsx("div",{className:`${f["glare-hover"]} ${x?f["glare-hover--play-once"]:""} ${_}`,style:{...I,...y},children:$})};n.__docgenInfo={description:"",methods:[],displayName:"GlareHover",props:{width:{defaultValue:{value:"'500px'",computed:!1},required:!1},height:{defaultValue:{value:"'500px'",computed:!1},required:!1},background:{defaultValue:{value:"'#000'",computed:!1},required:!1},borderRadius:{defaultValue:{value:"'10px'",computed:!1},required:!1},borderColor:{defaultValue:{value:"'#333'",computed:!1},required:!1},glareColor:{defaultValue:{value:"'#ffffff'",computed:!1},required:!1},glareOpacity:{defaultValue:{value:"0.5",computed:!1},required:!1},glareAngle:{defaultValue:{value:"-45",computed:!1},required:!1},glareSize:{defaultValue:{value:"250",computed:!1},required:!1},transitionDuration:{defaultValue:{value:"650",computed:!1},required:!1},playOnce:{defaultValue:{value:"false",computed:!1},required:!1},className:{defaultValue:{value:"''",computed:!1},required:!1},style:{defaultValue:{value:"{}",computed:!1},required:!1}}};const G={title:"ReactBits/Animations/GlareHover",component:n,parameters:{layout:"fullscreen"}},a={};var d,c,p;a.parameters={...a.parameters,docs:{...(d=a.parameters)==null?void 0:d.docs,source:{originalSource:"{}",...(p=(c=a.parameters)==null?void 0:c.docs)==null?void 0:p.source}}};const H=["Default"];export{a as Default,H as __namedExportsOrder,G as default};
1
+ import{j}from"./iframe-BmJYCQaV.js";import"./preload-helper-C1FmrZbK.js";const f={"glare-hover":"_glare-hover_npabj_1","glare-hover--play-once":"_glare-hover--play-once_npabj_44"},n=({width:i="500px",height:g="500px",background:m="#000",borderRadius:v="10px",borderColor:h="#333",children:$,glareColor:u="#ffffff",glareOpacity:o=.5,glareAngle:b=-45,glareSize:q=250,transitionDuration:V=650,playOnce:x=!1,className:_="",style:y={}})=>{const e=u.replace("#","");let l=u;if(/^[0-9A-Fa-f]{6}$/.test(e)){const r=parseInt(e.slice(0,2),16),s=parseInt(e.slice(2,4),16),t=parseInt(e.slice(4,6),16);l=`rgba(${r}, ${s}, ${t}, ${o})`}else if(/^[0-9A-Fa-f]{3}$/.test(e)){const r=parseInt(e[0]+e[0],16),s=parseInt(e[1]+e[1],16),t=parseInt(e[2]+e[2],16);l=`rgba(${r}, ${s}, ${t}, ${o})`}const I={"--gh-width":i,"--gh-height":g,"--gh-bg":m,"--gh-br":v,"--gh-angle":`${b}deg`,"--gh-duration":`${V}ms`,"--gh-size":`${q}%`,"--gh-rgba":l,"--gh-border":h};return j.jsx("div",{className:`${f["glare-hover"]} ${x?f["glare-hover--play-once"]:""} ${_}`,style:{...I,...y},children:$})};n.__docgenInfo={description:"",methods:[],displayName:"GlareHover",props:{width:{defaultValue:{value:"'500px'",computed:!1},required:!1},height:{defaultValue:{value:"'500px'",computed:!1},required:!1},background:{defaultValue:{value:"'#000'",computed:!1},required:!1},borderRadius:{defaultValue:{value:"'10px'",computed:!1},required:!1},borderColor:{defaultValue:{value:"'#333'",computed:!1},required:!1},glareColor:{defaultValue:{value:"'#ffffff'",computed:!1},required:!1},glareOpacity:{defaultValue:{value:"0.5",computed:!1},required:!1},glareAngle:{defaultValue:{value:"-45",computed:!1},required:!1},glareSize:{defaultValue:{value:"250",computed:!1},required:!1},transitionDuration:{defaultValue:{value:"650",computed:!1},required:!1},playOnce:{defaultValue:{value:"false",computed:!1},required:!1},className:{defaultValue:{value:"''",computed:!1},required:!1},style:{defaultValue:{value:"{}",computed:!1},required:!1}}};const G={title:"ReactBits/Animations/GlareHover",component:n,parameters:{layout:"fullscreen"}},a={};var d,c,p;a.parameters={...a.parameters,docs:{...(d=a.parameters)==null?void 0:d.docs,source:{originalSource:"{}",...(p=(c=a.parameters)==null?void 0:c.docs)==null?void 0:p.source}}};const H=["Default"];export{a as Default,H as __namedExportsOrder,G as default};
@@ -1,4 +1,4 @@
1
- import{r,j as t}from"./iframe-wVHIxtK4.js";import"./preload-helper-C1FmrZbK.js";const f={"glass-surface":"_glass-surface_103tm_1","glass-surface__filter":"_glass-surface__filter_103tm_10","glass-surface__content":"_glass-surface__content_103tm_20","glass-surface--svg":"_glass-surface--svg_103tm_32","glass-surface--fallback":"_glass-surface--fallback_103tm_48"},z=({children:F,width:u=200,height:n=80,borderRadius:i=20,borderWidth:g=.07,brightness:h=50,opacity:x=.93,blur:v=11,displace:$=0,backgroundOpacity:O=0,saturation:W=1,distortionScale:b=-180,redOffset:y=0,greenOffset:_=10,blueOffset:R=20,xChannel:S="R",yChannel:G="G",mixBlendMode:q="difference",className:N="",style:T={}})=>{const p=r.useId().replace(/:/g,"-"),m=`glass-filter-${p}`,w=`red-grad-${p}`,V=`blue-grad-${p}`,[H,U]=r.useState(!1),l=r.useRef(null),j=r.useRef(null),C=r.useRef(null),B=r.useRef(null),E=r.useRef(null),I=r.useRef(null),J=()=>{var A;const e=(A=l.current)==null?void 0:A.getBoundingClientRect(),s=(e==null?void 0:e.width)||400,a=(e==null?void 0:e.height)||200,c=Math.min(s,a)*(g*.5),P=`
1
+ import{r,j as t}from"./iframe-BmJYCQaV.js";import"./preload-helper-C1FmrZbK.js";const f={"glass-surface":"_glass-surface_103tm_1","glass-surface__filter":"_glass-surface__filter_103tm_10","glass-surface__content":"_glass-surface__content_103tm_20","glass-surface--svg":"_glass-surface--svg_103tm_32","glass-surface--fallback":"_glass-surface--fallback_103tm_48"},z=({children:F,width:u=200,height:n=80,borderRadius:i=20,borderWidth:g=.07,brightness:h=50,opacity:x=.93,blur:v=11,displace:$=0,backgroundOpacity:O=0,saturation:W=1,distortionScale:b=-180,redOffset:y=0,greenOffset:_=10,blueOffset:R=20,xChannel:S="R",yChannel:G="G",mixBlendMode:q="difference",className:N="",style:T={}})=>{const p=r.useId().replace(/:/g,"-"),m=`glass-filter-${p}`,w=`red-grad-${p}`,V=`blue-grad-${p}`,[H,U]=r.useState(!1),l=r.useRef(null),j=r.useRef(null),C=r.useRef(null),B=r.useRef(null),E=r.useRef(null),I=r.useRef(null),J=()=>{var A;const e=(A=l.current)==null?void 0:A.getBoundingClientRect(),s=(e==null?void 0:e.width)||400,a=(e==null?void 0:e.height)||200,c=Math.min(s,a)*(g*.5),P=`
2
2
  <svg viewBox="0 0 ${s} ${a}" xmlns="http://www.w3.org/2000/svg">
3
3
  <defs>
4
4
  <linearGradient id="${w}" x1="100%" y1="0%" x2="0%" y2="0%">
@@ -1,4 +1,4 @@
1
- import{j as f}from"./iframe-wVHIxtK4.js";import"./preload-helper-C1FmrZbK.js";const m="_glitch_1duah_1",s={glitch:m,"enable-on-hover":"_enable-on-hover_1duah_23"},u=({children:a,speed:t=1,enableShadows:r=!0,enableOnHover:d=!0,className:c=""})=>{const i={"--after-duration":`${t*3}s`,"--before-duration":`${t*2}s`,"--after-shadow":r?"-5px 0 red":"none","--before-shadow":r?"5px 0 cyan":"none"},p=d?s["enable-on-hover"]:"";return f.jsx("div",{className:`${s.glitch} ${p} ${c}`,style:i,"data-text":a,children:a})};u.__docgenInfo={description:"",methods:[],displayName:"GlitchText",props:{speed:{defaultValue:{value:"1",computed:!1},required:!1},enableShadows:{defaultValue:{value:"true",computed:!1},required:!1},enableOnHover:{defaultValue:{value:"true",computed:!1},required:!1},className:{defaultValue:{value:"''",computed:!1},required:!1}}};const x={title:"ReactBits/TextAnimations/GlitchText",component:u,parameters:{layout:"fullscreen"}},e={args:{children:"Hello World",speed:1,enableShadows:!0,enableOnHover:!0}};var l,o,n;e.parameters={...e.parameters,docs:{...(l=e.parameters)==null?void 0:l.docs,source:{originalSource:`{
1
+ import{j as f}from"./iframe-BmJYCQaV.js";import"./preload-helper-C1FmrZbK.js";const m="_glitch_1duah_1",s={glitch:m,"enable-on-hover":"_enable-on-hover_1duah_23"},u=({children:a,speed:t=1,enableShadows:r=!0,enableOnHover:d=!0,className:c=""})=>{const i={"--after-duration":`${t*3}s`,"--before-duration":`${t*2}s`,"--after-shadow":r?"-5px 0 red":"none","--before-shadow":r?"5px 0 cyan":"none"},p=d?s["enable-on-hover"]:"";return f.jsx("div",{className:`${s.glitch} ${p} ${c}`,style:i,"data-text":a,children:a})};u.__docgenInfo={description:"",methods:[],displayName:"GlitchText",props:{speed:{defaultValue:{value:"1",computed:!1},required:!1},enableShadows:{defaultValue:{value:"true",computed:!1},required:!1},enableOnHover:{defaultValue:{value:"true",computed:!1},required:!1},className:{defaultValue:{value:"''",computed:!1},required:!1}}};const x={title:"ReactBits/TextAnimations/GlitchText",component:u,parameters:{layout:"fullscreen"}},e={args:{children:"Hello World",speed:1,enableShadows:!0,enableOnHover:!0}};var l,o,n;e.parameters={...e.parameters,docs:{...(l=e.parameters)==null?void 0:l.docs,source:{originalSource:`{
2
2
  args: {
3
3
  children: 'Hello World',
4
4
  speed: 1,
@@ -1,4 +1,4 @@
1
- import{r as f,j as u}from"./iframe-wVHIxtK4.js";import"./preload-helper-C1FmrZbK.js";const k="_active_81mhv_85",O="_effect_81mhv_95",S="_text_81mhv_108",B="_filter_81mhv_117",G="_particle_81mhv_152",z="_point_81mhv_153",a={"gooey-nav-container":"_gooey-nav-container_81mhv_30",active:k,effect:O,text:S,filter:B,particle:G,point:z},C=({items:T,animationTime:_=600,particleCount:p=15,particleDistances:L=[90,10],particleR:V=100,timeVariance:g=300,colors:b=[1,2,3,1,2,3,1,4],initialActiveIndex:D=0})=>{const d=f.useRef(null),h=f.useRef(null),o=f.useRef(null),l=f.useRef(null),[m,N]=f.useState(D),v=(e=1)=>e/2-Math.random()*e,$=(e,r,t)=>{const s=(360+v(8))/t*r*(Math.PI/180);return[e*Math.cos(s),e*Math.sin(s)]},I=(e,r,t,s)=>{let n=v(s/10);return{start:$(t[0],p-e,p),end:$(t[1]+v(7),p-e,p),time:r,scale:1+v(.2),color:b[Math.floor(Math.random()*b.length)],rotate:n>0?(n+s/20)*10:(n-s/20)*10}},w=e=>{const r=L,t=V,s=_*2+g;e.style.setProperty("--time",`${s}ms`);for(let n=0;n<p;n++){const P=_*2+v(g*2),i=I(n,P,r,t);e.classList.remove(a.active),setTimeout(()=>{const c=document.createElement("span"),j=document.createElement("span");c.classList.add(a.particle),c.style.setProperty("--start-x",`${i.start[0]}px`),c.style.setProperty("--start-y",`${i.start[1]}px`),c.style.setProperty("--end-x",`${i.end[0]}px`),c.style.setProperty("--end-y",`${i.end[1]}px`),c.style.setProperty("--time",`${i.time}ms`),c.style.setProperty("--scale",`${i.scale}`),c.style.setProperty("--color",`var(--color-${i.color}, white)`),c.style.setProperty("--rotate",`${i.rotate}deg`),j.classList.add(a.point),c.appendChild(j),e.appendChild(c),requestAnimationFrame(()=>{e.classList.add(a.active)}),setTimeout(()=>{try{e.removeChild(c)}catch{}},P)},30)}},x=e=>{if(!d.current||!o.current||!l.current)return;const r=d.current.getBoundingClientRect(),t=e.getBoundingClientRect(),s={left:`${t.x-r.x}px`,top:`${t.y-r.y}px`,width:`${t.width}px`,height:`${t.height}px`};Object.assign(o.current.style,s),Object.assign(l.current.style,s),l.current.innerText=e.innerText},R=(e,r)=>{const t=e.currentTarget;m!==r&&(N(r),x(t),o.current&&o.current.querySelectorAll(".particle").forEach(n=>o.current.removeChild(n)),l.current&&(l.current.classList.remove(a.active),l.current.offsetWidth,l.current.classList.add(a.active)),o.current&&w(o.current))},M=(e,r)=>{if(e.key==="Enter"||e.key===" "){e.preventDefault();const t=e.currentTarget.parentElement;t&&R({currentTarget:t},r)}};return f.useEffect(()=>{var t;if(!h.current||!d.current)return;const e=h.current.querySelectorAll("li")[m];e&&(x(e),(t=l.current)==null||t.classList.add(a.active));const r=new ResizeObserver(()=>{var n;const s=(n=h.current)==null?void 0:n.querySelectorAll("li")[m];s&&x(s)});return r.observe(d.current),()=>r.disconnect()},[m]),u.jsxs("div",{className:`${a["gooey-nav-container"]}`,ref:d,children:[u.jsx("nav",{children:u.jsx("ul",{ref:h,children:T.map((e,r)=>u.jsx("li",{className:m===r?a.active:"",children:u.jsx("a",{href:e.href,onClick:t=>R(t,r),onKeyDown:t=>M(t,r),children:e.label})},r))})}),u.jsx("span",{className:`${a.effect} ${a.filter}`,ref:o}),u.jsx("span",{className:`${a.effect} ${a.text}`,ref:l})]})};C.__docgenInfo={description:"",methods:[],displayName:"GooeyNav",props:{animationTime:{defaultValue:{value:"600",computed:!1},required:!1},particleCount:{defaultValue:{value:"15",computed:!1},required:!1},particleDistances:{defaultValue:{value:"[90, 10]",computed:!1},required:!1},particleR:{defaultValue:{value:"100",computed:!1},required:!1},timeVariance:{defaultValue:{value:"300",computed:!1},required:!1},colors:{defaultValue:{value:"[1, 2, 3, 1, 2, 3, 1, 4]",computed:!1},required:!1},initialActiveIndex:{defaultValue:{value:"0",computed:!1},required:!1}}};const F={title:"ReactBits/Components/GooeyNav",component:C,parameters:{layout:"fullscreen"}},y={args:{items:[{label:"Home",href:"#"},{label:"About",href:"#"},{label:"Projects",href:"#"},{label:"Contact",href:"#"}],animationTime:600,particleCount:15,particleDistances:[90,10],particleR:100,timeVariance:300,colors:[1,2,3,1,2,3,1,4],initialActiveIndex:0}};var E,q,A;y.parameters={...y.parameters,docs:{...(E=y.parameters)==null?void 0:E.docs,source:{originalSource:`{
1
+ import{r as f,j as u}from"./iframe-BmJYCQaV.js";import"./preload-helper-C1FmrZbK.js";const k="_active_81mhv_85",O="_effect_81mhv_95",S="_text_81mhv_108",B="_filter_81mhv_117",G="_particle_81mhv_152",z="_point_81mhv_153",a={"gooey-nav-container":"_gooey-nav-container_81mhv_30",active:k,effect:O,text:S,filter:B,particle:G,point:z},C=({items:T,animationTime:_=600,particleCount:p=15,particleDistances:L=[90,10],particleR:V=100,timeVariance:g=300,colors:b=[1,2,3,1,2,3,1,4],initialActiveIndex:D=0})=>{const d=f.useRef(null),h=f.useRef(null),o=f.useRef(null),l=f.useRef(null),[m,N]=f.useState(D),v=(e=1)=>e/2-Math.random()*e,$=(e,r,t)=>{const s=(360+v(8))/t*r*(Math.PI/180);return[e*Math.cos(s),e*Math.sin(s)]},I=(e,r,t,s)=>{let n=v(s/10);return{start:$(t[0],p-e,p),end:$(t[1]+v(7),p-e,p),time:r,scale:1+v(.2),color:b[Math.floor(Math.random()*b.length)],rotate:n>0?(n+s/20)*10:(n-s/20)*10}},w=e=>{const r=L,t=V,s=_*2+g;e.style.setProperty("--time",`${s}ms`);for(let n=0;n<p;n++){const P=_*2+v(g*2),i=I(n,P,r,t);e.classList.remove(a.active),setTimeout(()=>{const c=document.createElement("span"),j=document.createElement("span");c.classList.add(a.particle),c.style.setProperty("--start-x",`${i.start[0]}px`),c.style.setProperty("--start-y",`${i.start[1]}px`),c.style.setProperty("--end-x",`${i.end[0]}px`),c.style.setProperty("--end-y",`${i.end[1]}px`),c.style.setProperty("--time",`${i.time}ms`),c.style.setProperty("--scale",`${i.scale}`),c.style.setProperty("--color",`var(--color-${i.color}, white)`),c.style.setProperty("--rotate",`${i.rotate}deg`),j.classList.add(a.point),c.appendChild(j),e.appendChild(c),requestAnimationFrame(()=>{e.classList.add(a.active)}),setTimeout(()=>{try{e.removeChild(c)}catch{}},P)},30)}},x=e=>{if(!d.current||!o.current||!l.current)return;const r=d.current.getBoundingClientRect(),t=e.getBoundingClientRect(),s={left:`${t.x-r.x}px`,top:`${t.y-r.y}px`,width:`${t.width}px`,height:`${t.height}px`};Object.assign(o.current.style,s),Object.assign(l.current.style,s),l.current.innerText=e.innerText},R=(e,r)=>{const t=e.currentTarget;m!==r&&(N(r),x(t),o.current&&o.current.querySelectorAll(".particle").forEach(n=>o.current.removeChild(n)),l.current&&(l.current.classList.remove(a.active),l.current.offsetWidth,l.current.classList.add(a.active)),o.current&&w(o.current))},M=(e,r)=>{if(e.key==="Enter"||e.key===" "){e.preventDefault();const t=e.currentTarget.parentElement;t&&R({currentTarget:t},r)}};return f.useEffect(()=>{var t;if(!h.current||!d.current)return;const e=h.current.querySelectorAll("li")[m];e&&(x(e),(t=l.current)==null||t.classList.add(a.active));const r=new ResizeObserver(()=>{var n;const s=(n=h.current)==null?void 0:n.querySelectorAll("li")[m];s&&x(s)});return r.observe(d.current),()=>r.disconnect()},[m]),u.jsxs("div",{className:`${a["gooey-nav-container"]}`,ref:d,children:[u.jsx("nav",{children:u.jsx("ul",{ref:h,children:T.map((e,r)=>u.jsx("li",{className:m===r?a.active:"",children:u.jsx("a",{href:e.href,onClick:t=>R(t,r),onKeyDown:t=>M(t,r),children:e.label})},r))})}),u.jsx("span",{className:`${a.effect} ${a.filter}`,ref:o}),u.jsx("span",{className:`${a.effect} ${a.text}`,ref:l})]})};C.__docgenInfo={description:"",methods:[],displayName:"GooeyNav",props:{animationTime:{defaultValue:{value:"600",computed:!1},required:!1},particleCount:{defaultValue:{value:"15",computed:!1},required:!1},particleDistances:{defaultValue:{value:"[90, 10]",computed:!1},required:!1},particleR:{defaultValue:{value:"100",computed:!1},required:!1},timeVariance:{defaultValue:{value:"300",computed:!1},required:!1},colors:{defaultValue:{value:"[1, 2, 3, 1, 2, 3, 1, 4]",computed:!1},required:!1},initialActiveIndex:{defaultValue:{value:"0",computed:!1},required:!1}}};const F={title:"ReactBits/Components/GooeyNav",component:C,parameters:{layout:"fullscreen"}},y={args:{items:[{label:"Home",href:"#"},{label:"About",href:"#"},{label:"Projects",href:"#"},{label:"Contact",href:"#"}],animationTime:600,particleCount:15,particleDistances:[90,10],particleR:100,timeVariance:300,colors:[1,2,3,1,2,3,1,4],initialActiveIndex:0}};var E,q,A;y.parameters={...y.parameters,docs:{...(E=y.parameters)==null?void 0:E.docs,source:{originalSource:`{
2
2
  args: {
3
3
  items: [{
4
4
  label: 'Home',
@@ -1,4 +1,4 @@
1
- import{r as l,j as ee}from"./iframe-wVHIxtK4.js";import{R as te,P as oe,M as re}from"./Mesh-CwXV3WjE.js";import{T as ue}from"./Triangle-64ffRKNB.js";import"./preload-helper-C1FmrZbK.js";const ne={"gradient-blinds-container":"_gradient-blinds-container_g9mdv_1"},S=8,le=u=>{const o=u.replace("#","").padEnd(6,"0"),f=parseInt(o.slice(0,2),16)/255,v=parseInt(o.slice(2,4),16)/255,i=parseInt(o.slice(4,6),16)/255;return[f,v,i]},ae=u=>{const o=(u&&u.length?u:["#FF9FFC","#5227FF"]).slice(0,S);for(o.length===1&&o.push(o[0]);o.length<S;)o.push(o[o.length-1]);const f=[];for(let i=0;i<S;i++)f.push(le(o[i]));const v=Math.max(2,Math.min(S,(u==null?void 0:u.length)??2));return{arr:f,count:v}},j=({className:u,dpr:o,paused:f=!1,gradientColors:v,angle:i=0,noise:b=.3,blindCount:p=16,blindMinWidth:R=60,mouseDampening:M=.15,mirrorGradient:A=!1,spotlightRadius:D=.5,spotlightSoftness:E=1,spotlightOpacity:G=1,distortAmount:O=0,shineDirection:T="left",mixBlendMode:I="lighten"})=>{const P=l.useRef(null),y=l.useRef(null),w=l.useRef(null),g=l.useRef(null),F=l.useRef(null),V=l.useRef(null),_=l.useRef([0,0]),h=l.useRef(0),N=l.useRef(!0);return l.useEffect(()=>{const m=P.current;if(!m)return;const C=new te({dpr:o??(typeof window<"u"&&window.devicePixelRatio||1),alpha:!0,antialias:!0});V.current=C;const n=C.gl,a=n.canvas;a.style.width="100%",a.style.height="100%",a.style.display="block",m.appendChild(a);const J=`
1
+ import{r as l,j as ee}from"./iframe-BmJYCQaV.js";import{R as te,P as oe,M as re}from"./Mesh-CwXV3WjE.js";import{T as ue}from"./Triangle-64ffRKNB.js";import"./preload-helper-C1FmrZbK.js";const ne={"gradient-blinds-container":"_gradient-blinds-container_g9mdv_1"},S=8,le=u=>{const o=u.replace("#","").padEnd(6,"0"),f=parseInt(o.slice(0,2),16)/255,v=parseInt(o.slice(2,4),16)/255,i=parseInt(o.slice(4,6),16)/255;return[f,v,i]},ae=u=>{const o=(u&&u.length?u:["#FF9FFC","#5227FF"]).slice(0,S);for(o.length===1&&o.push(o[0]);o.length<S;)o.push(o[o.length-1]);const f=[];for(let i=0;i<S;i++)f.push(le(o[i]));const v=Math.max(2,Math.min(S,(u==null?void 0:u.length)??2));return{arr:f,count:v}},j=({className:u,dpr:o,paused:f=!1,gradientColors:v,angle:i=0,noise:b=.3,blindCount:p=16,blindMinWidth:R=60,mouseDampening:M=.15,mirrorGradient:A=!1,spotlightRadius:D=.5,spotlightSoftness:E=1,spotlightOpacity:G=1,distortAmount:O=0,shineDirection:T="left",mixBlendMode:I="lighten"})=>{const P=l.useRef(null),y=l.useRef(null),w=l.useRef(null),g=l.useRef(null),F=l.useRef(null),V=l.useRef(null),_=l.useRef([0,0]),h=l.useRef(0),N=l.useRef(!0);return l.useEffect(()=>{const m=P.current;if(!m)return;const C=new te({dpr:o??(typeof window<"u"&&window.devicePixelRatio||1),alpha:!0,antialias:!0});V.current=C;const n=C.gl,a=n.canvas;a.style.width="100%",a.style.height="100%",a.style.display="block",m.appendChild(a);const J=`
2
2
  attribute vec2 position;
3
3
  attribute vec2 uv;
4
4
  varying vec2 vUv;
@@ -1,4 +1,4 @@
1
- import{r as s,j as d}from"./iframe-wVHIxtK4.js";import{u as j}from"./use-motion-value-wRl_TaJk.js";import{u as k}from"./use-animation-frame-ByBIonQ_.js";import{u as S}from"./use-transform-DK7n09PB.js";import{m as f}from"./proxy-DtFoluf3.js";import"./preload-helper-C1FmrZbK.js";import"./MotionConfigContext-4sobDr_8.js";const u={"animated-gradient-text":"_animated-gradient-text_ws0nc_1","with-border":"_with-border_ws0nc_17","gradient-overlay":"_gradient-overlay_ws0nc_21","text-content":"_text-content_ws0nc_47"};function b({children:$,className:w="",colors:m=["#5227FF","#FF9FFC","#B19EEF"],animationSpeed:p=8,showBorder:F=!1,direction:t="horizontal",pauseOnHover:n=!1,yoyo:g=!0}){const[z,h]=s.useState(!1),a=j(0),l=s.useRef(0),o=s.useRef(null),r=p*1e3;k(e=>{if(z){o.current=null;return}if(o.current===null){o.current=e;return}const B=e-o.current;if(o.current=e,l.current+=B,g){const R=r*2,c=l.current%R;c<r?a.set(c/r*100):a.set(100-(c-r)/r*100)}else a.set(l.current/r*100)}),s.useEffect(()=>{l.current=0,a.set(0)},[p,a,g]);const v=S(a,e=>t==="horizontal"?`${e}% 50%`:t==="vertical"?`50% ${e}%`:`${e}% 50%`),C=s.useCallback(()=>{n&&h(!0)},[n]),T=s.useCallback(()=>{n&&h(!1)},[n]),V=t==="horizontal"?"to right":t==="vertical"?"to bottom":"to bottom right",q=[...m,m[0]].join(", "),x={backgroundImage:`linear-gradient(${V}, ${q})`,backgroundSize:t==="horizontal"?"300% 100%":t==="vertical"?"100% 300%":"300% 300%",backgroundRepeat:"repeat"};return d.jsxs(f.div,{className:`${u["animated-gradient-text"]} ${F?u["with-border"]:""} ${w}`,onMouseEnter:C,onMouseLeave:T,children:[F&&d.jsx(f.div,{className:`${u["gradient-overlay"]}`,style:{...x,backgroundPosition:v}}),d.jsx(f.div,{className:`${u["text-content"]}`,style:{...x,backgroundPosition:v},children:$})]})}b.__docgenInfo={description:"",methods:[],displayName:"GradientText",props:{className:{defaultValue:{value:"''",computed:!1},required:!1},colors:{defaultValue:{value:"['#5227FF', '#FF9FFC', '#B19EEF']",computed:!1},required:!1},animationSpeed:{defaultValue:{value:"8",computed:!1},required:!1},showBorder:{defaultValue:{value:"false",computed:!1},required:!1},direction:{defaultValue:{value:"'horizontal'",computed:!1},required:!1},pauseOnHover:{defaultValue:{value:"false",computed:!1},required:!1},yoyo:{defaultValue:{value:"true",computed:!1},required:!1}}};const H={title:"ReactBits/TextAnimations/GradientText",component:b,parameters:{layout:"fullscreen"}},i={args:{children:"Hello World",colors:["#5227FF","#FF9FFC","#B19EEF"],animationSpeed:8,showBorder:!1,direction:"horizontal",pauseOnHover:!1,yoyo:!0}};var _,y,E;i.parameters={...i.parameters,docs:{...(_=i.parameters)==null?void 0:_.docs,source:{originalSource:`{
1
+ import{r as s,j as d}from"./iframe-BmJYCQaV.js";import{u as j}from"./use-motion-value-D1yqdG0l.js";import{u as k}from"./use-animation-frame-C3OkOmFg.js";import{u as S}from"./use-transform-CTCcIVjx.js";import{m as f}from"./proxy-MAU_yIzM.js";import"./preload-helper-C1FmrZbK.js";import"./MotionConfigContext-C6KIXCCK.js";const u={"animated-gradient-text":"_animated-gradient-text_ws0nc_1","with-border":"_with-border_ws0nc_17","gradient-overlay":"_gradient-overlay_ws0nc_21","text-content":"_text-content_ws0nc_47"};function b({children:$,className:w="",colors:m=["#5227FF","#FF9FFC","#B19EEF"],animationSpeed:p=8,showBorder:F=!1,direction:t="horizontal",pauseOnHover:n=!1,yoyo:g=!0}){const[z,h]=s.useState(!1),a=j(0),l=s.useRef(0),o=s.useRef(null),r=p*1e3;k(e=>{if(z){o.current=null;return}if(o.current===null){o.current=e;return}const B=e-o.current;if(o.current=e,l.current+=B,g){const R=r*2,c=l.current%R;c<r?a.set(c/r*100):a.set(100-(c-r)/r*100)}else a.set(l.current/r*100)}),s.useEffect(()=>{l.current=0,a.set(0)},[p,a,g]);const v=S(a,e=>t==="horizontal"?`${e}% 50%`:t==="vertical"?`50% ${e}%`:`${e}% 50%`),C=s.useCallback(()=>{n&&h(!0)},[n]),T=s.useCallback(()=>{n&&h(!1)},[n]),V=t==="horizontal"?"to right":t==="vertical"?"to bottom":"to bottom right",q=[...m,m[0]].join(", "),x={backgroundImage:`linear-gradient(${V}, ${q})`,backgroundSize:t==="horizontal"?"300% 100%":t==="vertical"?"100% 300%":"300% 300%",backgroundRepeat:"repeat"};return d.jsxs(f.div,{className:`${u["animated-gradient-text"]} ${F?u["with-border"]:""} ${w}`,onMouseEnter:C,onMouseLeave:T,children:[F&&d.jsx(f.div,{className:`${u["gradient-overlay"]}`,style:{...x,backgroundPosition:v}}),d.jsx(f.div,{className:`${u["text-content"]}`,style:{...x,backgroundPosition:v},children:$})]})}b.__docgenInfo={description:"",methods:[],displayName:"GradientText",props:{className:{defaultValue:{value:"''",computed:!1},required:!1},colors:{defaultValue:{value:"['#5227FF', '#FF9FFC', '#B19EEF']",computed:!1},required:!1},animationSpeed:{defaultValue:{value:"8",computed:!1},required:!1},showBorder:{defaultValue:{value:"false",computed:!1},required:!1},direction:{defaultValue:{value:"'horizontal'",computed:!1},required:!1},pauseOnHover:{defaultValue:{value:"false",computed:!1},required:!1},yoyo:{defaultValue:{value:"true",computed:!1},required:!1}}};const H={title:"ReactBits/TextAnimations/GradientText",component:b,parameters:{layout:"fullscreen"}},i={args:{children:"Hello World",colors:["#5227FF","#FF9FFC","#B19EEF"],animationSpeed:8,showBorder:!1,direction:"horizontal",pauseOnHover:!1,yoyo:!0}};var _,y,E;i.parameters={...i.parameters,docs:{...(_=i.parameters)==null?void 0:_.docs,source:{originalSource:`{
2
2
  args: {
3
3
  children: 'Hello World',
4
4
  colors: ['#5227FF', '#FF9FFC', '#B19EEF'],
@@ -1,4 +1,4 @@
1
- import{r as I,j as L}from"./iframe-wVHIxtK4.js";import{R as Y,P as $,M as H}from"./Mesh-CwXV3WjE.js";import{T as J}from"./Triangle-64ffRKNB.js";import"./preload-helper-C1FmrZbK.js";const c=t=>{const e=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(t);return e?[parseInt(e[1],16)/255,parseInt(e[2],16)/255,parseInt(e[3],16)/255]:[1,1,1]},K=`#version 300 es
1
+ import{r as I,j as L}from"./iframe-BmJYCQaV.js";import{R as Y,P as $,M as H}from"./Mesh-CwXV3WjE.js";import{T as J}from"./Triangle-64ffRKNB.js";import"./preload-helper-C1FmrZbK.js";const c=t=>{const e=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(t);return e?[parseInt(e[1],16)/255,parseInt(e[2],16)/255,parseInt(e[3],16)/255]:[1,1,1]},K=`#version 300 es
2
2
  in vec2 position;
3
3
  void main() {
4
4
  gl_Position = vec4(position, 0.0, 1.0);
@@ -1,4 +1,4 @@
1
- import{r as n,j as t}from"./iframe-wVHIxtK4.js";import{g as m}from"./index-C8pce-KX.js";import"./preload-helper-C1FmrZbK.js";const k="_noscroll_11mq5_1",D="_intro_11mq5_7",N="_row_11mq5_43",C="_row__item_11mq5_50",A="_fullview_11mq5_84",s={noscroll:k,intro:D,"gridMotion-container":"_gridMotion-container_11mq5_29",row:N,row__item:C,"row__item-inner":"_row__item-inner_11mq5_54","row__item-img":"_row__item-img_11mq5_68","row__item-content":"_row__item-content_11mq5_78",fullview:A},x=({items:a=[],gradientColor:j="black"})=>{const q=n.useRef(null),d=n.useRef([]),u=n.useRef(window.innerWidth/2),h=28,b=Array.from({length:h},(r,e)=>`Item ${e+1}`),y=a.length>0?a.slice(0,h):b;return n.useEffect(()=>{m.ticker.lagSmoothing(0);const r=o=>{u.current=o.clientX},e=()=>{const l=[.6,.4,.3,.2];d.current.forEach((_,g)=>{if(_){const M=g%2===0?1:-1,$=(u.current/window.innerWidth*300-300/2)*M;m.to(_,{x:$,duration:.8+l[g%l.length],ease:"power3.out",overwrite:"auto"})}})},p=m.ticker.add(e);return window.addEventListener("mousemove",r),()=>{window.removeEventListener("mousemove",r),p()}},[]),t.jsx("div",{className:`${s.noscroll} loading`,ref:q,children:t.jsxs("section",{className:`${s.intro}`,style:{background:`radial-gradient(circle, ${j} 0%, transparent 100%)`},children:[t.jsx("div",{className:`${s["gridMotion-container"]}`,children:[...Array(4)].map((r,e)=>t.jsx("div",{className:`${s.row}`,ref:p=>d.current[e]=p,children:[...Array(7)].map((p,o)=>{const i=y[e*7+o];return t.jsx("div",{className:`${s.row__item}`,children:t.jsx("div",{className:`${s["row__item-inner"]}`,style:{backgroundColor:"#111"},children:typeof i=="string"&&i.startsWith("http")?t.jsx("div",{className:`${s["row__item-img"]}`,style:{backgroundImage:`url(${i})`}}):t.jsx("div",{className:`${s["row__item-content"]}`,children:i})})},o)})},e))}),t.jsx("div",{className:`${s.fullview}`})]})})};x.__docgenInfo={description:"",methods:[],displayName:"GridMotion",props:{items:{defaultValue:{value:"[]",computed:!1},required:!1},gradientColor:{defaultValue:{value:"'black'",computed:!1},required:!1}}};const I={title:"ReactBits/Backgrounds/GridMotion",component:x,parameters:{layout:"fullscreen"}},c={args:{items:["https://picsum.photos/seed/a/300/300","https://picsum.photos/seed/b/300/300","Design","https://picsum.photos/seed/c/300/300","Code","https://picsum.photos/seed/d/300/300","Create","https://picsum.photos/seed/e/300/300","Build","https://picsum.photos/seed/f/300/300","https://picsum.photos/seed/g/300/300","Ship","https://picsum.photos/seed/h/300/300","Launch","https://picsum.photos/seed/i/300/300","https://picsum.photos/seed/j/300/300","Iterate","https://picsum.photos/seed/k/300/300","Scale","https://picsum.photos/seed/l/300/300","https://picsum.photos/seed/m/300/300","Deploy","https://picsum.photos/seed/n/300/300","Test","https://picsum.photos/seed/o/300/300","https://picsum.photos/seed/p/300/300","Debug","https://picsum.photos/seed/q/300/300"],gradientColor:"#060010"}};var f,w,v;c.parameters={...c.parameters,docs:{...(f=c.parameters)==null?void 0:f.docs,source:{originalSource:`{
1
+ import{r as n,j as t}from"./iframe-BmJYCQaV.js";import{g as m}from"./index-C8pce-KX.js";import"./preload-helper-C1FmrZbK.js";const k="_noscroll_11mq5_1",D="_intro_11mq5_7",N="_row_11mq5_43",C="_row__item_11mq5_50",A="_fullview_11mq5_84",s={noscroll:k,intro:D,"gridMotion-container":"_gridMotion-container_11mq5_29",row:N,row__item:C,"row__item-inner":"_row__item-inner_11mq5_54","row__item-img":"_row__item-img_11mq5_68","row__item-content":"_row__item-content_11mq5_78",fullview:A},x=({items:a=[],gradientColor:j="black"})=>{const q=n.useRef(null),d=n.useRef([]),u=n.useRef(window.innerWidth/2),h=28,b=Array.from({length:h},(r,e)=>`Item ${e+1}`),y=a.length>0?a.slice(0,h):b;return n.useEffect(()=>{m.ticker.lagSmoothing(0);const r=o=>{u.current=o.clientX},e=()=>{const l=[.6,.4,.3,.2];d.current.forEach((_,g)=>{if(_){const M=g%2===0?1:-1,$=(u.current/window.innerWidth*300-300/2)*M;m.to(_,{x:$,duration:.8+l[g%l.length],ease:"power3.out",overwrite:"auto"})}})},p=m.ticker.add(e);return window.addEventListener("mousemove",r),()=>{window.removeEventListener("mousemove",r),p()}},[]),t.jsx("div",{className:`${s.noscroll} loading`,ref:q,children:t.jsxs("section",{className:`${s.intro}`,style:{background:`radial-gradient(circle, ${j} 0%, transparent 100%)`},children:[t.jsx("div",{className:`${s["gridMotion-container"]}`,children:[...Array(4)].map((r,e)=>t.jsx("div",{className:`${s.row}`,ref:p=>d.current[e]=p,children:[...Array(7)].map((p,o)=>{const i=y[e*7+o];return t.jsx("div",{className:`${s.row__item}`,children:t.jsx("div",{className:`${s["row__item-inner"]}`,style:{backgroundColor:"#111"},children:typeof i=="string"&&i.startsWith("http")?t.jsx("div",{className:`${s["row__item-img"]}`,style:{backgroundImage:`url(${i})`}}):t.jsx("div",{className:`${s["row__item-content"]}`,children:i})})},o)})},e))}),t.jsx("div",{className:`${s.fullview}`})]})})};x.__docgenInfo={description:"",methods:[],displayName:"GridMotion",props:{items:{defaultValue:{value:"[]",computed:!1},required:!1},gradientColor:{defaultValue:{value:"'black'",computed:!1},required:!1}}};const I={title:"ReactBits/Backgrounds/GridMotion",component:x,parameters:{layout:"fullscreen"}},c={args:{items:["https://picsum.photos/seed/a/300/300","https://picsum.photos/seed/b/300/300","Design","https://picsum.photos/seed/c/300/300","Code","https://picsum.photos/seed/d/300/300","Create","https://picsum.photos/seed/e/300/300","Build","https://picsum.photos/seed/f/300/300","https://picsum.photos/seed/g/300/300","Ship","https://picsum.photos/seed/h/300/300","Launch","https://picsum.photos/seed/i/300/300","https://picsum.photos/seed/j/300/300","Iterate","https://picsum.photos/seed/k/300/300","Scale","https://picsum.photos/seed/l/300/300","https://picsum.photos/seed/m/300/300","Deploy","https://picsum.photos/seed/n/300/300","Test","https://picsum.photos/seed/o/300/300","https://picsum.photos/seed/p/300/300","Debug","https://picsum.photos/seed/q/300/300"],gradientColor:"#060010"}};var f,w,v;c.parameters={...c.parameters,docs:{...(f=c.parameters)==null?void 0:f.docs,source:{originalSource:`{
2
2
  args: {
3
3
  items: ['https://picsum.photos/seed/a/300/300', 'https://picsum.photos/seed/b/300/300', 'Design', 'https://picsum.photos/seed/c/300/300', 'Code', 'https://picsum.photos/seed/d/300/300', 'Create', 'https://picsum.photos/seed/e/300/300', 'Build', 'https://picsum.photos/seed/f/300/300', 'https://picsum.photos/seed/g/300/300', 'Ship', 'https://picsum.photos/seed/h/300/300', 'Launch', 'https://picsum.photos/seed/i/300/300', 'https://picsum.photos/seed/j/300/300', 'Iterate', 'https://picsum.photos/seed/k/300/300', 'Scale', 'https://picsum.photos/seed/l/300/300', 'https://picsum.photos/seed/m/300/300', 'Deploy', 'https://picsum.photos/seed/n/300/300', 'Test', 'https://picsum.photos/seed/o/300/300', 'https://picsum.photos/seed/p/300/300', 'Debug', 'https://picsum.photos/seed/q/300/300'],
4
4
  gradientColor: '#060010'
@@ -1,4 +1,4 @@
1
- import{r as o,j as a}from"./iframe-wVHIxtK4.js";import{A as Re}from"./index-DAgWpYb7.js";import{m as x}from"./proxy-DtFoluf3.js";import{c as w}from"./createLucideIcon-Cw9oc6nQ.js";import{C as qe}from"./chevron-right-RJ7bLHYT.js";import{D as Ve}from"./download-DeFjy7YQ.js";import"./preload-helper-C1FmrZbK.js";import"./MotionConfigContext-4sobDr_8.js";/**
1
+ import{r as o,j as a}from"./iframe-BmJYCQaV.js";import{A as Re}from"./index-GkLzrRJX.js";import{m as x}from"./proxy-MAU_yIzM.js";import{c as w}from"./createLucideIcon-DvNKQIkb.js";import{C as qe}from"./chevron-right-FoZPyhXE.js";import{D as Ve}from"./download-BEyY_c4w.js";import"./preload-helper-C1FmrZbK.js";import"./MotionConfigContext-C6KIXCCK.js";/**
2
2
  * @license lucide-react v0.539.0 - ISC
3
3
  *
4
4
  * This source code is licensed under the ISC license.
@@ -1,4 +1,4 @@
1
- import{r as m,j as T}from"./iframe-wVHIxtK4.js";import{R as q,P as F,M as I}from"./Mesh-CwXV3WjE.js";import{T as L}from"./Triangle-64ffRKNB.js";import{C as v}from"./Color-YRkaOI4u.js";import"./preload-helper-C1FmrZbK.js";const z={"iridescence-container":"_iridescence-container_rru4w_1"},B=`
1
+ import{r as m,j as T}from"./iframe-BmJYCQaV.js";import{R as q,P as F,M as I}from"./Mesh-CwXV3WjE.js";import{T as L}from"./Triangle-64ffRKNB.js";import{C as v}from"./Color-YRkaOI4u.js";import"./preload-helper-C1FmrZbK.js";const z={"iridescence-container":"_iridescence-container_rru4w_1"},B=`
2
2
  attribute vec2 uv;
3
3
  attribute vec2 position;
4
4
 
@@ -1,4 +1,4 @@
1
- import{r as l,j as ye}from"./iframe-wVHIxtK4.js";import{W as Me,s as De,S as be,a as Pe,h as We,t as Ie,e as me,u as Ce,v as Ve,w as He,M as Xe,f as Be,d as pe}from"./three.module--_vTUKhS.js";import"./preload-helper-C1FmrZbK.js";const Ne={"laser-flow-container":"_laser-flow-container_f5ui5_1"},qe=`
1
+ import{r as l,j as ye}from"./iframe-BmJYCQaV.js";import{W as Me,s as De,S as be,a as Pe,h as We,t as Ie,e as me,u as Ce,v as Ve,w as He,M as Xe,f as Be,d as pe}from"./three.module--_vTUKhS.js";import"./preload-helper-C1FmrZbK.js";const Ne={"laser-flow-container":"_laser-flow-container_f5ui5_1"},qe=`
2
2
  precision highp float;
3
3
  attribute vec3 position;
4
4
  void main(){
@@ -1 +1 @@
1
- import{r as a,j as d}from"./iframe-wVHIxtK4.js";import"./preload-helper-C1FmrZbK.js";const $=({glitchColors:w=["#2b4539","#61dca3","#61b3dc"],className:q="",glitchSpeed:R=50,centerVignette:A=!1,outerVignette:z=!0,smooth:h=!0,characters:B="ABCDEFGHIJKLMNOPQRSTUVWXYZ!@#$&*()-_+=/[]{};:<>.,0123456789"})=>{const i=a.useRef(null),g=a.useRef(null),n=a.useRef([]),m=a.useRef({columns:0,rows:0}),l=a.useRef(null),x=a.useRef(Date.now()),y=Array.from(B),G=16,M=10,C=20,E=()=>y[Math.floor(Math.random()*y.length)],p=()=>w[Math.floor(Math.random()*w.length)],V=e=>{const r=/^#?([a-f\d])([a-f\d])([a-f\d])$/i;e=e.replace(r,(o,s,c,u)=>s+s+c+c+u+u);const t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?{r:parseInt(t[1],16),g:parseInt(t[2],16),b:parseInt(t[3],16)}:null},j=(e,r,t)=>{const o={r:Math.round(e.r+(r.r-e.r)*t),g:Math.round(e.g+(r.g-e.g)*t),b:Math.round(e.b+(r.b-e.b)*t)};return`rgb(${o.r}, ${o.g}, ${o.b})`},D=(e,r)=>{const t=Math.ceil(e/M),o=Math.ceil(r/C);return{columns:t,rows:o}},I=(e,r)=>{m.current={columns:e,rows:r};const t=e*r;n.current=Array.from({length:t},()=>({char:E(),color:p(),targetColor:p(),colorProgress:1}))},L=()=>{const e=i.current;if(!e)return;const r=e.parentElement;if(!r)return;const t=window.devicePixelRatio||1,o=r.getBoundingClientRect();e.width=o.width*t,e.height=o.height*t,e.style.width=`${o.width}px`,e.style.height=`${o.height}px`,l.current&&l.current.setTransform(t,0,0,t,0,0);const{columns:s,rows:c}=D(o.width,o.height);I(s,c),b()},b=()=>{if(!l.current||n.current.length===0)return;const e=l.current,{width:r,height:t}=i.current.getBoundingClientRect();e.clearRect(0,0,r,t),e.font=`${G}px monospace`,e.textBaseline="top",n.current.forEach((o,s)=>{const c=s%m.current.columns*M,u=Math.floor(s/m.current.columns)*C;e.fillStyle=o.color,e.fillText(o.char,c,u)})},_=()=>{if(!n.current||n.current.length===0)return;const e=Math.max(1,Math.floor(n.current.length*.05));for(let r=0;r<e;r++){const t=Math.floor(Math.random()*n.current.length);n.current[t]&&(n.current[t].char=E(),n.current[t].targetColor=p(),h?n.current[t].colorProgress=0:(n.current[t].color=n.current[t].targetColor,n.current[t].colorProgress=1))}},k=()=>{let e=!1;n.current.forEach(r=>{if(r.colorProgress<1){r.colorProgress+=.05,r.colorProgress>1&&(r.colorProgress=1);const t=V(r.color),o=V(r.targetColor);t&&o&&(r.color=j(t,o,r.colorProgress),e=!0)}}),e&&b()},v=()=>{const e=Date.now();e-x.current>=R&&(_(),b(),x.current=e),h&&k(),g.current=requestAnimationFrame(v)};a.useEffect(()=>{const e=i.current;if(!e)return;l.current=e.getContext("2d"),L(),v();let r;const t=()=>{clearTimeout(r),r=setTimeout(()=>{cancelAnimationFrame(g.current),L(),v()},100)};return window.addEventListener("resize",t),()=>{cancelAnimationFrame(g.current),window.removeEventListener("resize",t)}},[R,h]);const F={position:"relative",width:"100%",height:"100%",backgroundColor:"#000000",overflow:"hidden"},N={display:"block",width:"100%",height:"100%"},H={position:"absolute",top:0,left:0,width:"100%",height:"100%",pointerEvents:"none",background:"radial-gradient(circle, rgba(0,0,0,0) 60%, rgba(0,0,0,1) 100%)"},O={position:"absolute",top:0,left:0,width:"100%",height:"100%",pointerEvents:"none",background:"radial-gradient(circle, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 60%)"};return d.jsxs("div",{style:F,className:q,children:[d.jsx("canvas",{ref:i,style:N}),z&&d.jsx("div",{style:H}),A&&d.jsx("div",{style:O})]})};$.__docgenInfo={description:"",methods:[],displayName:"LetterGlitch",props:{glitchColors:{defaultValue:{value:"['#2b4539', '#61dca3', '#61b3dc']",computed:!1},required:!1},className:{defaultValue:{value:"''",computed:!1},required:!1},glitchSpeed:{defaultValue:{value:"50",computed:!1},required:!1},centerVignette:{defaultValue:{value:"false",computed:!1},required:!1},outerVignette:{defaultValue:{value:"true",computed:!1},required:!1},smooth:{defaultValue:{value:"true",computed:!1},required:!1},characters:{defaultValue:{value:"'ABCDEFGHIJKLMNOPQRSTUVWXYZ!@#$&*()-_+=/[]{};:<>.,0123456789'",computed:!1},required:!1}}};const K={title:"ReactBits/Backgrounds/LetterGlitch",component:$,parameters:{layout:"fullscreen"}},f={};var P,S,T;f.parameters={...f.parameters,docs:{...(P=f.parameters)==null?void 0:P.docs,source:{originalSource:"{}",...(T=(S=f.parameters)==null?void 0:S.docs)==null?void 0:T.source}}};const Q=["Default"];export{f as Default,Q as __namedExportsOrder,K as default};
1
+ import{r as a,j as d}from"./iframe-BmJYCQaV.js";import"./preload-helper-C1FmrZbK.js";const $=({glitchColors:w=["#2b4539","#61dca3","#61b3dc"],className:q="",glitchSpeed:R=50,centerVignette:A=!1,outerVignette:z=!0,smooth:h=!0,characters:B="ABCDEFGHIJKLMNOPQRSTUVWXYZ!@#$&*()-_+=/[]{};:<>.,0123456789"})=>{const i=a.useRef(null),g=a.useRef(null),n=a.useRef([]),m=a.useRef({columns:0,rows:0}),l=a.useRef(null),x=a.useRef(Date.now()),y=Array.from(B),G=16,M=10,C=20,E=()=>y[Math.floor(Math.random()*y.length)],p=()=>w[Math.floor(Math.random()*w.length)],V=e=>{const r=/^#?([a-f\d])([a-f\d])([a-f\d])$/i;e=e.replace(r,(o,s,c,u)=>s+s+c+c+u+u);const t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(e);return t?{r:parseInt(t[1],16),g:parseInt(t[2],16),b:parseInt(t[3],16)}:null},j=(e,r,t)=>{const o={r:Math.round(e.r+(r.r-e.r)*t),g:Math.round(e.g+(r.g-e.g)*t),b:Math.round(e.b+(r.b-e.b)*t)};return`rgb(${o.r}, ${o.g}, ${o.b})`},D=(e,r)=>{const t=Math.ceil(e/M),o=Math.ceil(r/C);return{columns:t,rows:o}},I=(e,r)=>{m.current={columns:e,rows:r};const t=e*r;n.current=Array.from({length:t},()=>({char:E(),color:p(),targetColor:p(),colorProgress:1}))},L=()=>{const e=i.current;if(!e)return;const r=e.parentElement;if(!r)return;const t=window.devicePixelRatio||1,o=r.getBoundingClientRect();e.width=o.width*t,e.height=o.height*t,e.style.width=`${o.width}px`,e.style.height=`${o.height}px`,l.current&&l.current.setTransform(t,0,0,t,0,0);const{columns:s,rows:c}=D(o.width,o.height);I(s,c),b()},b=()=>{if(!l.current||n.current.length===0)return;const e=l.current,{width:r,height:t}=i.current.getBoundingClientRect();e.clearRect(0,0,r,t),e.font=`${G}px monospace`,e.textBaseline="top",n.current.forEach((o,s)=>{const c=s%m.current.columns*M,u=Math.floor(s/m.current.columns)*C;e.fillStyle=o.color,e.fillText(o.char,c,u)})},_=()=>{if(!n.current||n.current.length===0)return;const e=Math.max(1,Math.floor(n.current.length*.05));for(let r=0;r<e;r++){const t=Math.floor(Math.random()*n.current.length);n.current[t]&&(n.current[t].char=E(),n.current[t].targetColor=p(),h?n.current[t].colorProgress=0:(n.current[t].color=n.current[t].targetColor,n.current[t].colorProgress=1))}},k=()=>{let e=!1;n.current.forEach(r=>{if(r.colorProgress<1){r.colorProgress+=.05,r.colorProgress>1&&(r.colorProgress=1);const t=V(r.color),o=V(r.targetColor);t&&o&&(r.color=j(t,o,r.colorProgress),e=!0)}}),e&&b()},v=()=>{const e=Date.now();e-x.current>=R&&(_(),b(),x.current=e),h&&k(),g.current=requestAnimationFrame(v)};a.useEffect(()=>{const e=i.current;if(!e)return;l.current=e.getContext("2d"),L(),v();let r;const t=()=>{clearTimeout(r),r=setTimeout(()=>{cancelAnimationFrame(g.current),L(),v()},100)};return window.addEventListener("resize",t),()=>{cancelAnimationFrame(g.current),window.removeEventListener("resize",t)}},[R,h]);const F={position:"relative",width:"100%",height:"100%",backgroundColor:"#000000",overflow:"hidden"},N={display:"block",width:"100%",height:"100%"},H={position:"absolute",top:0,left:0,width:"100%",height:"100%",pointerEvents:"none",background:"radial-gradient(circle, rgba(0,0,0,0) 60%, rgba(0,0,0,1) 100%)"},O={position:"absolute",top:0,left:0,width:"100%",height:"100%",pointerEvents:"none",background:"radial-gradient(circle, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0) 60%)"};return d.jsxs("div",{style:F,className:q,children:[d.jsx("canvas",{ref:i,style:N}),z&&d.jsx("div",{style:H}),A&&d.jsx("div",{style:O})]})};$.__docgenInfo={description:"",methods:[],displayName:"LetterGlitch",props:{glitchColors:{defaultValue:{value:"['#2b4539', '#61dca3', '#61b3dc']",computed:!1},required:!1},className:{defaultValue:{value:"''",computed:!1},required:!1},glitchSpeed:{defaultValue:{value:"50",computed:!1},required:!1},centerVignette:{defaultValue:{value:"false",computed:!1},required:!1},outerVignette:{defaultValue:{value:"true",computed:!1},required:!1},smooth:{defaultValue:{value:"true",computed:!1},required:!1},characters:{defaultValue:{value:"'ABCDEFGHIJKLMNOPQRSTUVWXYZ!@#$&*()-_+=/[]{};:<>.,0123456789'",computed:!1},required:!1}}};const K={title:"ReactBits/Backgrounds/LetterGlitch",component:$,parameters:{layout:"fullscreen"}},f={};var P,S,T;f.parameters={...f.parameters,docs:{...(P=f.parameters)==null?void 0:P.docs,source:{originalSource:"{}",...(T=(S=f.parameters)==null?void 0:S.docs)==null?void 0:T.source}}};const Q=["Default"];export{f as Default,Q as __namedExportsOrder,K as default};
@@ -1,4 +1,4 @@
1
- import{r as t,j as K}from"./iframe-wVHIxtK4.js";import{d as Z,S as de,a as ve,W as pe,i as he,q as ge,M as Re,n as b,e as _}from"./three.module--_vTUKhS.js";import"./preload-helper-C1FmrZbK.js";const ee={"light-pillar-fallback":"_light-pillar-fallback_pgugz_1","light-pillar-container":"_light-pillar-container_pgugz_15"},oe=({topColor:C="#5227FF",bottomColor:x="#FF9FFC",intensity:S=1,rotationSpeed:y=.3,interactive:l=!1,className:z="",glowAmount:P=.005,pillarWidth:M=3,pillarHeight:E=.4,noiseIntensity:F=.5,mixBlendMode:V="screen",pillarRotation:q=0,quality:p="high"})=>{const s=t.useRef(null),f=t.useRef(null),o=t.useRef(null),e=t.useRef(null),h=t.useRef(null),g=t.useRef(null),R=t.useRef(null),L=t.useRef(new Z(0,0)),A=t.useRef(0),B=t.useRef(y),[I,k]=t.useState(!0);return t.useEffect(()=>{const r=document.createElement("canvas");r.getContext("webgl")||r.getContext("experimental-webgl")||k(!1)},[]),t.useEffect(()=>{if(!s.current||!I)return;const r=s.current,a=r.clientWidth,i=r.clientHeight,G=new de;h.current=G;const ue=new ve(-1,1,1,-1,0,1);g.current=ue;const N=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),ie=N||navigator.hardwareConcurrency&&navigator.hardwareConcurrency<=4;let m=p;ie&&p==="high"&&(m="medium"),N&&p!=="low"&&(m="low");const j={low:{iterations:24,waveIterations:1,pixelRatio:.5,precision:"mediump",stepMultiplier:1.5},medium:{iterations:40,waveIterations:2,pixelRatio:.65,precision:"mediump",stepMultiplier:1.2},high:{iterations:80,waveIterations:4,pixelRatio:Math.min(window.devicePixelRatio,2),precision:"highp",stepMultiplier:1}},c=j[m]||j.medium;let d;try{d=new pe({antialias:!1,alpha:!0,powerPreference:m==="high"?"high-performance":"low-power",precision:c.precision,stencil:!1,depth:!1})}catch{k(!1);return}d.setSize(a,i),d.setPixelRatio(c.pixelRatio),r.appendChild(d.domElement),o.current=d;const H=u=>{const n=new b(u);return new _(n.r,n.g,n.b)},ae=`
1
+ import{r as t,j as K}from"./iframe-BmJYCQaV.js";import{d as Z,S as de,a as ve,W as pe,i as he,q as ge,M as Re,n as b,e as _}from"./three.module--_vTUKhS.js";import"./preload-helper-C1FmrZbK.js";const ee={"light-pillar-fallback":"_light-pillar-fallback_pgugz_1","light-pillar-container":"_light-pillar-container_pgugz_15"},oe=({topColor:C="#5227FF",bottomColor:x="#FF9FFC",intensity:S=1,rotationSpeed:y=.3,interactive:l=!1,className:z="",glowAmount:P=.005,pillarWidth:M=3,pillarHeight:E=.4,noiseIntensity:F=.5,mixBlendMode:V="screen",pillarRotation:q=0,quality:p="high"})=>{const s=t.useRef(null),f=t.useRef(null),o=t.useRef(null),e=t.useRef(null),h=t.useRef(null),g=t.useRef(null),R=t.useRef(null),L=t.useRef(new Z(0,0)),A=t.useRef(0),B=t.useRef(y),[I,k]=t.useState(!0);return t.useEffect(()=>{const r=document.createElement("canvas");r.getContext("webgl")||r.getContext("experimental-webgl")||k(!1)},[]),t.useEffect(()=>{if(!s.current||!I)return;const r=s.current,a=r.clientWidth,i=r.clientHeight,G=new de;h.current=G;const ue=new ve(-1,1,1,-1,0,1);g.current=ue;const N=/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent),ie=N||navigator.hardwareConcurrency&&navigator.hardwareConcurrency<=4;let m=p;ie&&p==="high"&&(m="medium"),N&&p!=="low"&&(m="low");const j={low:{iterations:24,waveIterations:1,pixelRatio:.5,precision:"mediump",stepMultiplier:1.5},medium:{iterations:40,waveIterations:2,pixelRatio:.65,precision:"mediump",stepMultiplier:1.2},high:{iterations:80,waveIterations:4,pixelRatio:Math.min(window.devicePixelRatio,2),precision:"highp",stepMultiplier:1}},c=j[m]||j.medium;let d;try{d=new pe({antialias:!1,alpha:!0,powerPreference:m==="high"?"high-performance":"low-power",precision:c.precision,stencil:!1,depth:!1})}catch{k(!1);return}d.setSize(a,i),d.setPixelRatio(c.pixelRatio),r.appendChild(d.domElement),o.current=d;const H=u=>{const n=new b(u);return new _(n.r,n.g,n.b)},ae=`
2
2
  varying vec2 vUv;
3
3
  void main() {
4
4
  vUv = uv;
@@ -1,4 +1,4 @@
1
- import{r as n,j as J}from"./iframe-wVHIxtK4.js";import{R as K,P as Q,M as Z}from"./Mesh-CwXV3WjE.js";import{T as ee}from"./Triangle-64ffRKNB.js";import"./preload-helper-C1FmrZbK.js";const re="#ffffff",W=l=>{const t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(l);return t?[parseInt(t[1],16)/255,parseInt(t[2],16)/255,parseInt(t[3],16)/255]:[1,1,1]},B=(l,t,a)=>{switch(l){case"top-left":return{anchor:[0,-.2*a],dir:[0,1]};case"top-right":return{anchor:[t,-.2*a],dir:[0,1]};case"left":return{anchor:[-.2*t,.5*a],dir:[1,0]};case"right":return{anchor:[(1+.2)*t,.5*a],dir:[-1,0]};case"bottom-left":return{anchor:[0,(1+.2)*a],dir:[0,-1]};case"bottom-center":return{anchor:[.5*t,(1+.2)*a],dir:[0,-1]};case"bottom-right":return{anchor:[t,(1+.2)*a],dir:[0,-1]};default:return{anchor:[.5*t,-.2*a],dir:[0,1]}}},j=({raysOrigin:l="top-center",raysColor:t=re,raysSpeed:a=1,lightSpread:g=1,rayLength:C=2,pulsating:S=!1,fadeDistance:D=1,saturation:b=1,followMouse:w=!0,mouseInfluence:p=.1,noiseAmount:A=0,distortion:P=0,className:H=""})=>{const o=n.useRef(null),h=n.useRef(null),d=n.useRef(null),T=n.useRef({x:.5,y:.5}),m=n.useRef({x:.5,y:.5}),y=n.useRef(null),E=n.useRef(null),f=n.useRef(null),[I,$]=n.useState(!1),R=n.useRef(null);return n.useEffect(()=>{if(o.current)return R.current=new IntersectionObserver(e=>{const r=e[0];$(r.isIntersecting)},{threshold:.1}),R.current.observe(o.current),()=>{R.current&&(R.current.disconnect(),R.current=null)}},[]),n.useEffect(()=>!I||!o.current?void 0:(f.current&&(f.current(),f.current=null),(async()=>{if(!o.current||(await new Promise(i=>setTimeout(i,10)),!o.current))return;const r=new K({dpr:Math.min(window.devicePixelRatio,2),alpha:!0});d.current=r;const s=r.gl;for(s.canvas.style.width="100%",s.canvas.style.height="100%";o.current.firstChild;)o.current.removeChild(o.current.firstChild);o.current.appendChild(s.canvas);const x=`
1
+ import{r as n,j as J}from"./iframe-BmJYCQaV.js";import{R as K,P as Q,M as Z}from"./Mesh-CwXV3WjE.js";import{T as ee}from"./Triangle-64ffRKNB.js";import"./preload-helper-C1FmrZbK.js";const re="#ffffff",W=l=>{const t=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(l);return t?[parseInt(t[1],16)/255,parseInt(t[2],16)/255,parseInt(t[3],16)/255]:[1,1,1]},B=(l,t,a)=>{switch(l){case"top-left":return{anchor:[0,-.2*a],dir:[0,1]};case"top-right":return{anchor:[t,-.2*a],dir:[0,1]};case"left":return{anchor:[-.2*t,.5*a],dir:[1,0]};case"right":return{anchor:[(1+.2)*t,.5*a],dir:[-1,0]};case"bottom-left":return{anchor:[0,(1+.2)*a],dir:[0,-1]};case"bottom-center":return{anchor:[.5*t,(1+.2)*a],dir:[0,-1]};case"bottom-right":return{anchor:[t,(1+.2)*a],dir:[0,-1]};default:return{anchor:[.5*t,-.2*a],dir:[0,1]}}},j=({raysOrigin:l="top-center",raysColor:t=re,raysSpeed:a=1,lightSpread:g=1,rayLength:C=2,pulsating:S=!1,fadeDistance:D=1,saturation:b=1,followMouse:w=!0,mouseInfluence:p=.1,noiseAmount:A=0,distortion:P=0,className:H=""})=>{const o=n.useRef(null),h=n.useRef(null),d=n.useRef(null),T=n.useRef({x:.5,y:.5}),m=n.useRef({x:.5,y:.5}),y=n.useRef(null),E=n.useRef(null),f=n.useRef(null),[I,$]=n.useState(!1),R=n.useRef(null);return n.useEffect(()=>{if(o.current)return R.current=new IntersectionObserver(e=>{const r=e[0];$(r.isIntersecting)},{threshold:.1}),R.current.observe(o.current),()=>{R.current&&(R.current.disconnect(),R.current=null)}},[]),n.useEffect(()=>!I||!o.current?void 0:(f.current&&(f.current(),f.current=null),(async()=>{if(!o.current||(await new Promise(i=>setTimeout(i,10)),!o.current))return;const r=new K({dpr:Math.min(window.devicePixelRatio,2),alpha:!0});d.current=r;const s=r.gl;for(s.canvas.style.width="100%",s.canvas.style.height="100%";o.current.firstChild;)o.current.removeChild(o.current.firstChild);o.current.appendChild(s.canvas);const x=`
2
2
  attribute vec2 position;
3
3
  varying vec2 vUv;
4
4
  void main() {
@@ -1,4 +1,4 @@
1
- import{r as S,j as V}from"./iframe-wVHIxtK4.js";import"./preload-helper-C1FmrZbK.js";const q={"lightning-container":"_lightning-container_1iiur_1"},R=({hue:s=230,xOffset:c=0,speed:u=1,intensity:f=1,size:l=1})=>{const m=S.useRef(null);return S.useEffect(()=>{const o=m.current;if(!o)return;const a=()=>{o.width=o.clientWidth,o.height=o.clientHeight};a(),window.addEventListener("resize",a);const e=o.getContext("webgl");if(!e){console.error("WebGL not supported");return}const b=`
1
+ import{r as S,j as V}from"./iframe-BmJYCQaV.js";import"./preload-helper-C1FmrZbK.js";const q={"lightning-container":"_lightning-container_1iiur_1"},R=({hue:s=230,xOffset:c=0,speed:u=1,intensity:f=1,size:l=1})=>{const m=S.useRef(null);return S.useEffect(()=>{const o=m.current;if(!o)return;const a=()=>{o.width=o.clientWidth,o.height=o.clientHeight};a(),window.addEventListener("resize",a);const e=o.getContext("webgl");if(!e){console.error("WebGL not supported");return}const b=`
2
2
  attribute vec2 aPosition;
3
3
  void main() {
4
4
  gl_Position = vec4(aPosition, 0.0, 1.0);
@@ -1,4 +1,4 @@
1
- import{r as F,j as D}from"./iframe-wVHIxtK4.js";import{R as P,P as Y,M as k}from"./Mesh-CwXV3WjE.js";import{T as z}from"./Triangle-64ffRKNB.js";import"./preload-helper-C1FmrZbK.js";const N={"line-waves-container":"_line-waves-container_hnom3_1"};function p(r){const t=r.replace("#","");return[parseInt(t.slice(0,2),16)/255,parseInt(t.slice(2,4),16)/255,parseInt(t.slice(4,6),16)/255]}const O=`
1
+ import{r as F,j as D}from"./iframe-BmJYCQaV.js";import{R as P,P as Y,M as k}from"./Mesh-CwXV3WjE.js";import{T as z}from"./Triangle-64ffRKNB.js";import"./preload-helper-C1FmrZbK.js";const N={"line-waves-container":"_line-waves-container_hnom3_1"};function p(r){const t=r.replace("#","");return[parseInt(t.slice(0,2),16)/255,parseInt(t.slice(2,4),16)/255,parseInt(t.slice(4,6),16)/255]}const O=`
2
2
  attribute vec2 uv;
3
3
  attribute vec2 position;
4
4
  varying vec2 vUv;
@@ -1,4 +1,4 @@
1
- import{r as R,j as U}from"./iframe-wVHIxtK4.js";import{R as X,P as Y,M as V}from"./Mesh-CwXV3WjE.js";import{T as b}from"./Triangle-64ffRKNB.js";import"./preload-helper-C1FmrZbK.js";const z={"liquidChrome-container":"_liquidChrome-container_19fmq_1"},_=({baseColor:d=[.1,.1,.1],speed:p=.2,amplitude:h=.3,frequencyX:g=3,frequencyY:y=3,interactive:s=!0,...A})=>{const l=R.useRef(null);return R.useEffect(()=>{if(!l.current)return;const n=l.current,c=new X({antialias:!0}),e=c.gl;e.clearColor(1,1,1,1);const L=`
1
+ import{r as R,j as U}from"./iframe-BmJYCQaV.js";import{R as X,P as Y,M as V}from"./Mesh-CwXV3WjE.js";import{T as b}from"./Triangle-64ffRKNB.js";import"./preload-helper-C1FmrZbK.js";const z={"liquidChrome-container":"_liquidChrome-container_19fmq_1"},_=({baseColor:d=[.1,.1,.1],speed:p=.2,amplitude:h=.3,frequencyX:g=3,frequencyY:y=3,interactive:s=!0,...A})=>{const l=R.useRef(null);return R.useEffect(()=>{if(!l.current)return;const n=l.current,c=new X({antialias:!0}),e=c.gl;e.clearColor(1,1,1,1);const L=`
2
2
  attribute vec2 position;
3
3
  attribute vec2 uv;
4
4
  varying vec2 vUv;