@nethesis/phone-island 1.1.4 → 1.1.5-dev.1

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 (456) hide show
  1. package/dist/App.js.map +1 -1
  2. package/dist/components/AlertView/index.js.map +1 -1
  3. package/dist/components/AudioBars.js.map +1 -1
  4. package/dist/components/AudioPlayerView/PlayerFooterActions.js +1 -1
  5. package/dist/components/AudioPlayerView/PlayerFooterActions.js.map +1 -1
  6. package/dist/components/AudioPlayerView/Progress.js.map +1 -1
  7. package/dist/components/AudioPlayerView/index.js +1 -1
  8. package/dist/components/AudioPlayerView/index.js.map +1 -1
  9. package/dist/components/CallView/Actions.js +1 -1
  10. package/dist/components/CallView/Actions.js.map +1 -1
  11. package/dist/components/CallView/BackCall.js +1 -1
  12. package/dist/components/CallView/BackCall.js.map +1 -1
  13. package/dist/components/CallView/DeviceIcon.js +1 -1
  14. package/dist/components/CallView/DeviceIcon.js.map +1 -1
  15. package/dist/components/CallView/DisplayName.js +1 -1
  16. package/dist/components/CallView/DisplayName.js.map +1 -1
  17. package/dist/components/CallView/DisplayNameUtils.js.map +1 -1
  18. package/dist/components/CallView/Number.js +1 -1
  19. package/dist/components/CallView/Number.js.map +1 -1
  20. package/dist/components/CallView/NumberPopover.js +1 -1
  21. package/dist/components/CallView/NumberPopover.js.map +1 -1
  22. package/dist/components/CallView/index.js +1 -1
  23. package/dist/components/CallView/index.js.map +1 -1
  24. package/dist/components/ConferenceView/ConferenceUsersList.js +1 -1
  25. package/dist/components/ConferenceView/ConferenceUsersList.js.map +1 -1
  26. package/dist/components/ConferenceView/index.js +1 -1
  27. package/dist/components/ConferenceView/index.js.map +1 -1
  28. package/dist/components/ContactView/ContactListView.js +1 -1
  29. package/dist/components/ContactView/ContactListView.js.map +1 -1
  30. package/dist/components/ContactView/SelectContactNumberView.js +1 -1
  31. package/dist/components/ContactView/SelectContactNumberView.js.map +1 -1
  32. package/dist/components/ContactView/TransferActions.js +1 -1
  33. package/dist/components/ContactView/TransferActions.js.map +1 -1
  34. package/dist/components/Hangup.js +1 -1
  35. package/dist/components/Hangup.js.map +1 -1
  36. package/dist/components/KeypadView/index.js +1 -1
  37. package/dist/components/KeypadView/index.js.map +1 -1
  38. package/dist/components/OperatorBusyView/index.js +1 -1
  39. package/dist/components/OperatorBusyView/index.js.map +1 -1
  40. package/dist/components/PhysicalRecorderView/index.js +1 -1
  41. package/dist/components/PhysicalRecorderView/index.js.map +1 -1
  42. package/dist/components/RecorderView/Actions.js +1 -1
  43. package/dist/components/RecorderView/Actions.js.map +1 -1
  44. package/dist/components/RecorderView/BarsGroup.js.map +1 -1
  45. package/dist/components/RecorderView/index.js +1 -1
  46. package/dist/components/RecorderView/index.js.map +1 -1
  47. package/dist/components/SettingsView/AudioView.js +1 -1
  48. package/dist/components/SettingsView/AudioView.js.map +1 -1
  49. package/dist/components/SettingsView/MicrophoneView.js +1 -1
  50. package/dist/components/SettingsView/MicrophoneView.js.map +1 -1
  51. package/dist/components/SettingsView/SettingsHeader.js +1 -1
  52. package/dist/components/SettingsView/SettingsHeader.js.map +1 -1
  53. package/dist/components/SettingsView/ThemeView.js +1 -1
  54. package/dist/components/SettingsView/ThemeView.js.map +1 -1
  55. package/dist/components/SettingsView/index.js +1 -1
  56. package/dist/components/SettingsView/index.js.map +1 -1
  57. package/dist/components/SideView/SideView.js +1 -1
  58. package/dist/components/SideView/SideView.js.map +1 -1
  59. package/dist/components/SideView/hooks/useSideViewLogic.js.map +1 -1
  60. package/dist/components/Socket.js.map +1 -1
  61. package/dist/components/SwitchDeviceView/index.js +1 -1
  62. package/dist/components/SwitchDeviceView/index.js.map +1 -1
  63. package/dist/components/SwitchInputView/DropdownContent.js +1 -1
  64. package/dist/components/SwitchInputView/DropdownContent.js.map +1 -1
  65. package/dist/components/SwitchInputView/Index.js +1 -1
  66. package/dist/components/TextScroll.js +1 -1
  67. package/dist/components/TextScroll.js.map +1 -1
  68. package/dist/components/TranscriptionView/TranscriptionView.js +1 -1
  69. package/dist/components/TranscriptionView/TranscriptionView.js.map +1 -1
  70. package/dist/components/VideoStreamingEmptyState/index.js +1 -1
  71. package/dist/components/VideoStreamingEmptyState/index.js.map +1 -1
  72. package/dist/components/VideoStreamingSkeleton/index.js +1 -1
  73. package/dist/components/VideoStreamingSkeleton/index.js.map +1 -1
  74. package/dist/components/VideoView/index.js.map +1 -1
  75. package/dist/components/WebRTC.js.map +1 -1
  76. package/dist/events/SocketEvents.js.map +1 -1
  77. package/dist/lib/i18n.js +1 -1
  78. package/dist/lib/i18n.js.map +1 -1
  79. package/dist/lib/phone/call.js +1 -1
  80. package/dist/lib/phone/call.js.map +1 -1
  81. package/dist/lib/phone/counterpartDevice.js.map +1 -1
  82. package/dist/lib/phone/video.js.map +1 -1
  83. package/dist/lib/player/audio.js.map +1 -1
  84. package/dist/lib/user/default_device.js.map +1 -1
  85. package/dist/lib/user/extensions.js.map +1 -1
  86. package/dist/models/currentCall.js.map +1 -1
  87. package/dist/models/island.js.map +1 -1
  88. package/dist/models/player.js +1 -1
  89. package/dist/models/player.js.map +1 -1
  90. package/dist/node_modules/classnames/index.js +1 -1
  91. package/dist/node_modules/framer-motion/dist/es/animation/hooks/animation-controls.mjs.js +1 -1
  92. package/dist/node_modules/framer-motion/dist/es/animation/hooks/animation-controls.mjs.js.map +1 -1
  93. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/PopChild.mjs.js +1 -1
  94. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/PopChild.mjs.js.map +1 -1
  95. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/PresenceChild.mjs.js +1 -1
  96. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/PresenceChild.mjs.js.map +1 -1
  97. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs.js +1 -1
  98. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/index.mjs.js.map +1 -1
  99. package/dist/node_modules/framer-motion/dist/es/components/AnimatePresence/utils.mjs.js.map +1 -1
  100. package/dist/node_modules/framer-motion/dist/es/context/LayoutGroupContext.mjs.js.map +1 -1
  101. package/dist/node_modules/framer-motion/dist/es/context/LazyContext.mjs.js.map +1 -1
  102. package/dist/node_modules/framer-motion/dist/es/context/MotionConfigContext.mjs.js.map +1 -1
  103. package/dist/node_modules/framer-motion/dist/es/context/SwitchLayoutGroupContext.mjs.js.map +1 -1
  104. package/dist/node_modules/framer-motion/dist/es/gestures/drag/index.mjs.js +1 -1
  105. package/dist/node_modules/framer-motion/dist/es/gestures/drag/index.mjs.js.map +1 -1
  106. package/dist/node_modules/framer-motion/dist/es/gestures/drag/use-drag-controls.mjs.js.map +1 -1
  107. package/dist/node_modules/framer-motion/dist/es/gestures/hover.mjs.js +1 -1
  108. package/dist/node_modules/framer-motion/dist/es/gestures/hover.mjs.js.map +1 -1
  109. package/dist/node_modules/framer-motion/dist/es/gestures/pan/index.mjs.js +1 -1
  110. package/dist/node_modules/framer-motion/dist/es/gestures/pan/index.mjs.js.map +1 -1
  111. package/dist/node_modules/framer-motion/dist/es/gestures/press.mjs.js +1 -1
  112. package/dist/node_modules/framer-motion/dist/es/gestures/press.mjs.js.map +1 -1
  113. package/dist/node_modules/framer-motion/dist/es/motion/features/animation/exit.mjs.js +1 -1
  114. package/dist/node_modules/framer-motion/dist/es/motion/features/animation/exit.mjs.js.map +1 -1
  115. package/dist/node_modules/framer-motion/dist/es/motion/features/animation/index.mjs.js +1 -1
  116. package/dist/node_modules/framer-motion/dist/es/motion/features/animation/index.mjs.js.map +1 -1
  117. package/dist/node_modules/framer-motion/dist/es/motion/features/definitions.mjs.js +1 -1
  118. package/dist/node_modules/framer-motion/dist/es/motion/features/definitions.mjs.js.map +1 -1
  119. package/dist/node_modules/framer-motion/dist/es/motion/features/layout/MeasureLayout.mjs.js +1 -1
  120. package/dist/node_modules/framer-motion/dist/es/motion/features/layout/MeasureLayout.mjs.js.map +1 -1
  121. package/dist/node_modules/framer-motion/dist/es/motion/index.mjs.js +1 -1
  122. package/dist/node_modules/framer-motion/dist/es/motion/index.mjs.js.map +1 -1
  123. package/dist/node_modules/framer-motion/dist/es/motion/utils/symbol.mjs.js.map +1 -1
  124. package/dist/node_modules/framer-motion/dist/es/motion/utils/use-visual-element.mjs.js +1 -1
  125. package/dist/node_modules/framer-motion/dist/es/motion/utils/use-visual-element.mjs.js.map +1 -1
  126. package/dist/node_modules/framer-motion/dist/es/motion/utils/valid-prop.mjs.js +1 -1
  127. package/dist/node_modules/framer-motion/dist/es/motion/utils/valid-prop.mjs.js.map +1 -1
  128. package/dist/node_modules/framer-motion/dist/es/render/components/motion/feature-bundle.mjs.js +1 -1
  129. package/dist/node_modules/framer-motion/dist/es/render/components/motion/feature-bundle.mjs.js.map +1 -1
  130. package/dist/node_modules/framer-motion/dist/es/render/dom/use-render.mjs.js +1 -1
  131. package/dist/node_modules/framer-motion/dist/es/render/dom/use-render.mjs.js.map +1 -1
  132. package/dist/node_modules/framer-motion/dist/es/render/dom/utils/filter-props.mjs.js +1 -1
  133. package/dist/node_modules/framer-motion/dist/es/render/dom/utils/filter-props.mjs.js.map +1 -1
  134. package/dist/node_modules/framer-motion/dist/es/render/svg/use-props.mjs.js +1 -1
  135. package/dist/node_modules/framer-motion/dist/es/render/svg/use-props.mjs.js.map +1 -1
  136. package/dist/node_modules/i18next/dist/esm/i18next.js +1 -1
  137. package/dist/node_modules/i18next/dist/esm/i18next.js.map +1 -1
  138. package/dist/node_modules/js-base64/base64.mjs.js +1 -1
  139. package/dist/node_modules/js-base64/base64.mjs.js.map +1 -1
  140. package/dist/node_modules/motion-dom/dist/es/animation/AsyncMotionValueAnimation.mjs.js +1 -1
  141. package/dist/node_modules/motion-dom/dist/es/animation/AsyncMotionValueAnimation.mjs.js.map +1 -1
  142. package/dist/node_modules/motion-dom/dist/es/animation/JSAnimation.mjs.js +1 -1
  143. package/dist/node_modules/motion-dom/dist/es/animation/JSAnimation.mjs.js.map +1 -1
  144. package/dist/node_modules/motion-dom/dist/es/animation/NativeAnimation.mjs.js +1 -1
  145. package/dist/node_modules/motion-dom/dist/es/animation/NativeAnimation.mjs.js.map +1 -1
  146. package/dist/node_modules/motion-dom/dist/es/animation/NativeAnimationExtended.mjs.js +1 -1
  147. package/dist/node_modules/motion-dom/dist/es/animation/NativeAnimationExtended.mjs.js.map +1 -1
  148. package/dist/node_modules/motion-dom/dist/es/animation/animate/single-value.mjs.js +1 -1
  149. package/dist/node_modules/motion-dom/dist/es/animation/animate/single-value.mjs.js.map +1 -1
  150. package/dist/node_modules/motion-dom/dist/es/animation/drivers/frame.mjs.js +1 -1
  151. package/dist/node_modules/motion-dom/dist/es/animation/drivers/frame.mjs.js.map +1 -1
  152. package/dist/node_modules/motion-dom/dist/es/animation/generators/inertia.mjs.js +1 -1
  153. package/dist/node_modules/motion-dom/dist/es/animation/generators/inertia.mjs.js.map +1 -1
  154. package/dist/node_modules/motion-dom/dist/es/animation/generators/keyframes.mjs.js +1 -1
  155. package/dist/node_modules/motion-dom/dist/es/animation/generators/keyframes.mjs.js.map +1 -1
  156. package/dist/node_modules/motion-dom/dist/es/animation/generators/spring.mjs.js +1 -1
  157. package/dist/node_modules/motion-dom/dist/es/animation/generators/spring.mjs.js.map +1 -1
  158. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/calc-duration.mjs.js +1 -1
  159. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/calc-duration.mjs.js.map +1 -1
  160. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/create-generator-easing.mjs.js +1 -1
  161. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/create-generator-easing.mjs.js.map +1 -1
  162. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/velocity.mjs.js +1 -1
  163. package/dist/node_modules/motion-dom/dist/es/animation/generators/utils/velocity.mjs.js.map +1 -1
  164. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/motion-value.mjs.js +1 -1
  165. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/motion-value.mjs.js.map +1 -1
  166. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element-target.mjs.js +1 -1
  167. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element-target.mjs.js.map +1 -1
  168. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element-variant.mjs.js +1 -1
  169. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element-variant.mjs.js.map +1 -1
  170. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element.mjs.js +1 -1
  171. package/dist/node_modules/motion-dom/dist/es/animation/interfaces/visual-element.mjs.js.map +1 -1
  172. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/DOMKeyframesResolver.mjs.js +1 -1
  173. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/DOMKeyframesResolver.mjs.js.map +1 -1
  174. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/KeyframesResolver.mjs.js +1 -1
  175. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/KeyframesResolver.mjs.js.map +1 -1
  176. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/get-final.mjs.js +1 -1
  177. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/get-final.mjs.js.map +1 -1
  178. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/make-none-animatable.mjs.js +1 -1
  179. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/make-none-animatable.mjs.js.map +1 -1
  180. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/unit-conversion.mjs.js +1 -1
  181. package/dist/node_modules/motion-dom/dist/es/animation/keyframes/utils/unit-conversion.mjs.js.map +1 -1
  182. package/dist/node_modules/motion-dom/dist/es/animation/optimized-appear/data-id.mjs.js +1 -1
  183. package/dist/node_modules/motion-dom/dist/es/animation/optimized-appear/data-id.mjs.js.map +1 -1
  184. package/dist/node_modules/motion-dom/dist/es/animation/utils/WithPromise.mjs.js +1 -1
  185. package/dist/node_modules/motion-dom/dist/es/animation/utils/WithPromise.mjs.js.map +1 -1
  186. package/dist/node_modules/motion-dom/dist/es/animation/utils/can-animate.mjs.js +1 -1
  187. package/dist/node_modules/motion-dom/dist/es/animation/utils/can-animate.mjs.js.map +1 -1
  188. package/dist/node_modules/motion-dom/dist/es/animation/utils/css-variables-conversion.mjs.js +1 -1
  189. package/dist/node_modules/motion-dom/dist/es/animation/utils/css-variables-conversion.mjs.js.map +1 -1
  190. package/dist/node_modules/motion-dom/dist/es/animation/utils/is-transition-defined.mjs.js +1 -1
  191. package/dist/node_modules/motion-dom/dist/es/animation/utils/is-transition-defined.mjs.js.map +1 -1
  192. package/dist/node_modules/motion-dom/dist/es/animation/utils/notify-inspector.mjs.js +2 -0
  193. package/dist/node_modules/motion-dom/dist/es/animation/utils/notify-inspector.mjs.js.map +1 -0
  194. package/dist/node_modules/motion-dom/dist/es/animation/utils/resolve-start-time.mjs.js +2 -0
  195. package/dist/node_modules/motion-dom/dist/es/animation/utils/resolve-start-time.mjs.js.map +1 -0
  196. package/dist/node_modules/motion-dom/dist/es/animation/waapi/supports/waapi.mjs.js +1 -1
  197. package/dist/node_modules/motion-dom/dist/es/animation/waapi/supports/waapi.mjs.js.map +1 -1
  198. package/dist/node_modules/motion-dom/dist/es/animation/waapi/transforms/TransformAnimation.mjs.js +2 -0
  199. package/dist/node_modules/motion-dom/dist/es/animation/waapi/transforms/TransformAnimation.mjs.js.map +1 -0
  200. package/dist/node_modules/motion-dom/dist/es/animation/waapi/transforms/groups.mjs.js +2 -0
  201. package/dist/node_modules/motion-dom/dist/es/animation/waapi/transforms/groups.mjs.js.map +1 -0
  202. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/accelerated-values.mjs.js +1 -1
  203. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/accelerated-values.mjs.js.map +1 -1
  204. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/needs-mixer.mjs.js +2 -0
  205. package/dist/node_modules/motion-dom/dist/es/animation/waapi/utils/needs-mixer.mjs.js.map +1 -0
  206. package/dist/node_modules/motion-dom/dist/es/events/add-pointer-event.mjs.js +2 -0
  207. package/dist/node_modules/motion-dom/dist/es/events/add-pointer-event.mjs.js.map +1 -0
  208. package/dist/node_modules/motion-dom/dist/es/events/event-info.mjs.js +2 -0
  209. package/dist/node_modules/motion-dom/dist/es/events/event-info.mjs.js.map +1 -0
  210. package/dist/node_modules/motion-dom/dist/es/frameloop/batcher.mjs.js +1 -1
  211. package/dist/node_modules/motion-dom/dist/es/frameloop/batcher.mjs.js.map +1 -1
  212. package/dist/node_modules/motion-dom/dist/es/frameloop/frame-data.mjs.js +2 -0
  213. package/dist/node_modules/motion-dom/dist/es/frameloop/frame-data.mjs.js.map +1 -0
  214. package/dist/node_modules/motion-dom/dist/es/frameloop/frame.mjs.js +1 -1
  215. package/dist/node_modules/motion-dom/dist/es/frameloop/frame.mjs.js.map +1 -1
  216. package/dist/node_modules/motion-dom/dist/es/frameloop/render-step.mjs.js +1 -1
  217. package/dist/node_modules/motion-dom/dist/es/frameloop/render-step.mjs.js.map +1 -1
  218. package/dist/node_modules/motion-dom/dist/es/frameloop/sync-time.mjs.js +1 -1
  219. package/dist/node_modules/motion-dom/dist/es/frameloop/sync-time.mjs.js.map +1 -1
  220. package/dist/node_modules/motion-dom/dist/es/gestures/drag/VisualElementDragControls.mjs.js +2 -0
  221. package/dist/node_modules/motion-dom/dist/es/gestures/drag/VisualElementDragControls.mjs.js.map +1 -0
  222. package/dist/node_modules/motion-dom/dist/es/gestures/drag/utils/constraints.mjs.js +2 -0
  223. package/dist/node_modules/motion-dom/dist/es/gestures/drag/utils/constraints.mjs.js.map +1 -0
  224. package/dist/node_modules/motion-dom/dist/es/gestures/hover.mjs.js +1 -1
  225. package/dist/node_modules/motion-dom/dist/es/gestures/hover.mjs.js.map +1 -1
  226. package/dist/node_modules/motion-dom/dist/es/gestures/pan/PanSession.mjs.js +2 -0
  227. package/dist/node_modules/motion-dom/dist/es/gestures/pan/PanSession.mjs.js.map +1 -0
  228. package/dist/node_modules/motion-dom/dist/es/gestures/press/index.mjs.js +1 -1
  229. package/dist/node_modules/motion-dom/dist/es/gestures/press/index.mjs.js.map +1 -1
  230. package/dist/node_modules/motion-dom/dist/es/gestures/press/utils/keyboard.mjs.js +1 -1
  231. package/dist/node_modules/motion-dom/dist/es/gestures/press/utils/keyboard.mjs.js.map +1 -1
  232. package/dist/node_modules/motion-dom/dist/es/gestures/utils/setup.mjs.js +1 -1
  233. package/dist/node_modules/motion-dom/dist/es/gestures/utils/setup.mjs.js.map +1 -1
  234. package/dist/node_modules/motion-dom/dist/es/projection/animation/mix-values.mjs.js +1 -1
  235. package/dist/node_modules/motion-dom/dist/es/projection/animation/mix-values.mjs.js.map +1 -1
  236. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-apply.mjs.js +1 -1
  237. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-apply.mjs.js.map +1 -1
  238. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-calc.mjs.js +1 -1
  239. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-calc.mjs.js.map +1 -1
  240. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-remove.mjs.js +1 -1
  241. package/dist/node_modules/motion-dom/dist/es/projection/geometry/delta-remove.mjs.js.map +1 -1
  242. package/dist/node_modules/motion-dom/dist/es/projection/geometry/round.mjs.js +2 -0
  243. package/dist/node_modules/motion-dom/dist/es/projection/geometry/round.mjs.js.map +1 -0
  244. package/dist/node_modules/motion-dom/dist/es/projection/node/DocumentProjectionNode.mjs.js +1 -1
  245. package/dist/node_modules/motion-dom/dist/es/projection/node/DocumentProjectionNode.mjs.js.map +1 -1
  246. package/dist/node_modules/motion-dom/dist/es/projection/node/HTMLProjectionNode.mjs.js +1 -1
  247. package/dist/node_modules/motion-dom/dist/es/projection/node/HTMLProjectionNode.mjs.js.map +1 -1
  248. package/dist/node_modules/motion-dom/dist/es/projection/node/create-projection-node.mjs.js +1 -1
  249. package/dist/node_modules/motion-dom/dist/es/projection/node/create-projection-node.mjs.js.map +1 -1
  250. package/dist/node_modules/motion-dom/dist/es/projection/node/root.mjs.js +2 -0
  251. package/dist/node_modules/motion-dom/dist/es/projection/node/root.mjs.js.map +1 -0
  252. package/dist/node_modules/motion-dom/dist/es/projection/styles/default-scale-correctors.mjs.js +2 -0
  253. package/dist/node_modules/motion-dom/dist/es/projection/styles/default-scale-correctors.mjs.js.map +1 -0
  254. package/dist/node_modules/motion-dom/dist/es/projection/styles/scale-correction.mjs.js +1 -1
  255. package/dist/node_modules/motion-dom/dist/es/projection/styles/scale-correction.mjs.js.map +1 -1
  256. package/dist/node_modules/motion-dom/dist/es/projection/styles/transform.mjs.js +1 -1
  257. package/dist/node_modules/motion-dom/dist/es/projection/styles/transform.mjs.js.map +1 -1
  258. package/dist/node_modules/motion-dom/dist/es/projection/utils/each-axis.mjs.js.map +1 -1
  259. package/dist/node_modules/motion-dom/dist/es/projection/utils/has-transform.mjs.js +1 -1
  260. package/dist/node_modules/motion-dom/dist/es/projection/utils/has-transform.mjs.js.map +1 -1
  261. package/dist/node_modules/motion-dom/dist/es/projection/utils/measure.mjs.js +1 -1
  262. package/dist/node_modules/motion-dom/dist/es/projection/utils/measure.mjs.js.map +1 -1
  263. package/dist/node_modules/motion-dom/dist/es/render/VisualElement.mjs.js +1 -1
  264. package/dist/node_modules/motion-dom/dist/es/render/VisualElement.mjs.js.map +1 -1
  265. package/dist/node_modules/motion-dom/dist/es/render/dom/DOMVisualElement.mjs.js.map +1 -1
  266. package/dist/node_modules/motion-dom/dist/es/render/dom/parse-transform.mjs.js +1 -1
  267. package/dist/node_modules/motion-dom/dist/es/render/dom/parse-transform.mjs.js.map +1 -1
  268. package/dist/node_modules/motion-dom/dist/es/render/html/HTMLVisualElement.mjs.js +1 -1
  269. package/dist/node_modules/motion-dom/dist/es/render/html/HTMLVisualElement.mjs.js.map +1 -1
  270. package/dist/node_modules/motion-dom/dist/es/render/html/utils/build-transform.mjs.js +1 -1
  271. package/dist/node_modules/motion-dom/dist/es/render/html/utils/build-transform.mjs.js.map +1 -1
  272. package/dist/node_modules/motion-dom/dist/es/render/svg/SVGVisualElement.mjs.js +1 -1
  273. package/dist/node_modules/motion-dom/dist/es/render/svg/SVGVisualElement.mjs.js.map +1 -1
  274. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/build-attrs.mjs.js +1 -1
  275. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/build-attrs.mjs.js.map +1 -1
  276. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/scrape-motion-values.mjs.js +1 -1
  277. package/dist/node_modules/motion-dom/dist/es/render/svg/utils/scrape-motion-values.mjs.js.map +1 -1
  278. package/dist/node_modules/motion-dom/dist/es/render/utils/animation-state.mjs.js +1 -1
  279. package/dist/node_modules/motion-dom/dist/es/render/utils/animation-state.mjs.js.map +1 -1
  280. package/dist/node_modules/motion-dom/dist/es/render/utils/is-controlling-variants.mjs.js +1 -1
  281. package/dist/node_modules/motion-dom/dist/es/render/utils/is-controlling-variants.mjs.js.map +1 -1
  282. package/dist/node_modules/motion-dom/dist/es/render/utils/keys-transform.mjs.js +1 -1
  283. package/dist/node_modules/motion-dom/dist/es/render/utils/keys-transform.mjs.js.map +1 -1
  284. package/dist/node_modules/motion-dom/dist/es/render/utils/resolve-dynamic-variants.mjs.js +1 -1
  285. package/dist/node_modules/motion-dom/dist/es/render/utils/resolve-dynamic-variants.mjs.js.map +1 -1
  286. package/dist/node_modules/motion-dom/dist/es/render/utils/resolve-variants.mjs.js +1 -1
  287. package/dist/node_modules/motion-dom/dist/es/render/utils/resolve-variants.mjs.js.map +1 -1
  288. package/dist/node_modules/motion-dom/dist/es/render/utils/variant-props.mjs.js +1 -1
  289. package/dist/node_modules/motion-dom/dist/es/render/utils/variant-props.mjs.js.map +1 -1
  290. package/dist/node_modules/motion-dom/dist/es/resize/index.mjs.js +1 -1
  291. package/dist/node_modules/motion-dom/dist/es/resize/index.mjs.js.map +1 -1
  292. package/dist/node_modules/motion-dom/dist/es/scope/active.mjs.js +2 -0
  293. package/dist/node_modules/motion-dom/dist/es/scope/active.mjs.js.map +1 -0
  294. package/dist/node_modules/motion-dom/dist/es/stats/buffer.mjs.js +2 -0
  295. package/dist/node_modules/motion-dom/dist/es/stats/buffer.mjs.js.map +1 -0
  296. package/dist/node_modules/motion-dom/dist/es/utils/delay.mjs.js +1 -1
  297. package/dist/node_modules/motion-dom/dist/es/utils/delay.mjs.js.map +1 -1
  298. package/dist/node_modules/motion-dom/dist/es/utils/distance.mjs.js.map +1 -0
  299. package/dist/node_modules/motion-dom/dist/es/utils/interpolate.mjs.js +1 -1
  300. package/dist/node_modules/motion-dom/dist/es/utils/interpolate.mjs.js.map +1 -1
  301. package/dist/node_modules/motion-dom/dist/es/utils/is-ref-object.mjs.js.map +1 -0
  302. package/dist/node_modules/motion-dom/dist/es/utils/mix/color.mjs.js +1 -1
  303. package/dist/node_modules/motion-dom/dist/es/utils/mix/color.mjs.js.map +1 -1
  304. package/dist/node_modules/motion-dom/dist/es/utils/mix/complex.mjs.js +1 -1
  305. package/dist/node_modules/motion-dom/dist/es/utils/mix/complex.mjs.js.map +1 -1
  306. package/dist/node_modules/motion-dom/dist/es/utils/mix/index.mjs.js +1 -1
  307. package/dist/node_modules/motion-dom/dist/es/utils/mix/index.mjs.js.map +1 -1
  308. package/dist/node_modules/motion-dom/dist/es/utils/resolve-elements.mjs.js +1 -1
  309. package/dist/node_modules/motion-dom/dist/es/utils/resolve-elements.mjs.js.map +1 -1
  310. package/dist/node_modules/motion-dom/dist/es/value/index.mjs.js +1 -1
  311. package/dist/node_modules/motion-dom/dist/es/value/index.mjs.js.map +1 -1
  312. package/dist/node_modules/motion-dom/dist/es/value/types/color/hex.mjs.js +1 -1
  313. package/dist/node_modules/motion-dom/dist/es/value/types/color/hex.mjs.js.map +1 -1
  314. package/dist/node_modules/motion-dom/dist/es/value/types/complex/index.mjs.js +1 -1
  315. package/dist/node_modules/motion-dom/dist/es/value/types/complex/index.mjs.js.map +1 -1
  316. package/dist/node_modules/motion-dom/dist/es/value/types/utils/animatable-none.mjs.js +1 -1
  317. package/dist/node_modules/motion-dom/dist/es/value/types/utils/animatable-none.mjs.js.map +1 -1
  318. package/dist/node_modules/motion-dom/dist/es/value/utils/as-number.mjs.js +2 -0
  319. package/dist/node_modules/motion-dom/dist/es/value/utils/as-number.mjs.js.map +1 -0
  320. package/dist/node_modules/motion-utils/dist/es/easing/circ.mjs.js.map +1 -1
  321. package/dist/node_modules/motion-utils/dist/es/easing/cubic-bezier.mjs.js +1 -1
  322. package/dist/node_modules/motion-utils/dist/es/easing/cubic-bezier.mjs.js.map +1 -1
  323. package/dist/node_modules/motion-utils/dist/es/easing/utils/map.mjs.js +1 -1
  324. package/dist/node_modules/motion-utils/dist/es/easing/utils/map.mjs.js.map +1 -1
  325. package/dist/node_modules/motion-utils/dist/es/errors.mjs.js +1 -1
  326. package/dist/node_modules/motion-utils/dist/es/errors.mjs.js.map +1 -1
  327. package/dist/node_modules/motion-utils/dist/es/subscription-manager.mjs.js +1 -1
  328. package/dist/node_modules/motion-utils/dist/es/subscription-manager.mjs.js.map +1 -1
  329. package/dist/node_modules/react-i18next/dist/es/context.js +1 -1
  330. package/dist/node_modules/react-i18next/dist/es/context.js.map +1 -1
  331. package/dist/node_modules/react-i18next/dist/es/defaults.js +1 -1
  332. package/dist/node_modules/react-i18next/dist/es/defaults.js.map +1 -1
  333. package/dist/node_modules/react-i18next/dist/es/i18nInstance.js +1 -1
  334. package/dist/node_modules/react-i18next/dist/es/i18nInstance.js.map +1 -1
  335. package/dist/node_modules/react-i18next/dist/es/initReactI18next.js +1 -1
  336. package/dist/node_modules/react-i18next/dist/es/initReactI18next.js.map +1 -1
  337. package/dist/node_modules/react-i18next/dist/es/unescape.js +1 -1
  338. package/dist/node_modules/react-i18next/dist/es/unescape.js.map +1 -1
  339. package/dist/node_modules/react-i18next/dist/es/useTranslation.js +1 -1
  340. package/dist/node_modules/react-i18next/dist/es/useTranslation.js.map +1 -1
  341. package/dist/node_modules/react-i18next/dist/es/utils.js +1 -1
  342. package/dist/node_modules/react-i18next/dist/es/utils.js.map +1 -1
  343. package/dist/node_modules/react-redux/node_modules/react-is/index.js +1 -1
  344. package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js +1 -1
  345. package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js +1 -1
  346. package/dist/node_modules/use-sync-external-store/shim/index.js +1 -1
  347. package/dist/package.json.js +1 -1
  348. package/dist/services/astproxy.js +1 -1
  349. package/dist/services/astproxy.js.map +1 -1
  350. package/dist/services/phonebook.js +1 -1
  351. package/dist/services/phonebook.js.map +1 -1
  352. package/dist/utils/customHooks/useLocalStorage.js.map +1 -1
  353. package/dist/utils/deviceUtils.js.map +1 -1
  354. package/package.json +6 -6
  355. package/dist/_virtual/arrayLikeToArray.js +0 -2
  356. package/dist/_virtual/arrayLikeToArray.js.map +0 -1
  357. package/dist/_virtual/arrayWithHoles.js +0 -2
  358. package/dist/_virtual/arrayWithHoles.js.map +0 -1
  359. package/dist/_virtual/classCallCheck.js +0 -2
  360. package/dist/_virtual/classCallCheck.js.map +0 -1
  361. package/dist/_virtual/createClass.js +0 -2
  362. package/dist/_virtual/createClass.js.map +0 -1
  363. package/dist/_virtual/defineProperty.js +0 -2
  364. package/dist/_virtual/defineProperty.js.map +0 -1
  365. package/dist/_virtual/iterableToArrayLimit.js +0 -2
  366. package/dist/_virtual/iterableToArrayLimit.js.map +0 -1
  367. package/dist/_virtual/nonIterableRest.js +0 -2
  368. package/dist/_virtual/nonIterableRest.js.map +0 -1
  369. package/dist/_virtual/objectWithoutProperties.js +0 -2
  370. package/dist/_virtual/objectWithoutProperties.js.map +0 -1
  371. package/dist/_virtual/objectWithoutPropertiesLoose.js +0 -2
  372. package/dist/_virtual/objectWithoutPropertiesLoose.js.map +0 -1
  373. package/dist/_virtual/slicedToArray.js +0 -2
  374. package/dist/_virtual/slicedToArray.js.map +0 -1
  375. package/dist/_virtual/toPrimitive.js +0 -2
  376. package/dist/_virtual/toPrimitive.js.map +0 -1
  377. package/dist/_virtual/toPropertyKey.js +0 -2
  378. package/dist/_virtual/toPropertyKey.js.map +0 -1
  379. package/dist/_virtual/typeof.js +0 -2
  380. package/dist/_virtual/typeof.js.map +0 -1
  381. package/dist/_virtual/unsupportedIterableToArray.js +0 -2
  382. package/dist/_virtual/unsupportedIterableToArray.js.map +0 -1
  383. package/dist/node_modules/@babel/runtime/helpers/arrayLikeToArray.js +0 -2
  384. package/dist/node_modules/@babel/runtime/helpers/arrayLikeToArray.js.map +0 -1
  385. package/dist/node_modules/@babel/runtime/helpers/arrayWithHoles.js +0 -2
  386. package/dist/node_modules/@babel/runtime/helpers/arrayWithHoles.js.map +0 -1
  387. package/dist/node_modules/@babel/runtime/helpers/classCallCheck.js +0 -2
  388. package/dist/node_modules/@babel/runtime/helpers/classCallCheck.js.map +0 -1
  389. package/dist/node_modules/@babel/runtime/helpers/createClass.js +0 -2
  390. package/dist/node_modules/@babel/runtime/helpers/createClass.js.map +0 -1
  391. package/dist/node_modules/@babel/runtime/helpers/defineProperty.js +0 -2
  392. package/dist/node_modules/@babel/runtime/helpers/defineProperty.js.map +0 -1
  393. package/dist/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js +0 -2
  394. package/dist/node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js.map +0 -1
  395. package/dist/node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js +0 -2
  396. package/dist/node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js.map +0 -1
  397. package/dist/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js +0 -2
  398. package/dist/node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js.map +0 -1
  399. package/dist/node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js +0 -2
  400. package/dist/node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js.map +0 -1
  401. package/dist/node_modules/@babel/runtime/helpers/esm/inherits.js +0 -2
  402. package/dist/node_modules/@babel/runtime/helpers/esm/inherits.js.map +0 -1
  403. package/dist/node_modules/@babel/runtime/helpers/esm/iterableToArray.js +0 -2
  404. package/dist/node_modules/@babel/runtime/helpers/esm/iterableToArray.js.map +0 -1
  405. package/dist/node_modules/@babel/runtime/helpers/esm/nonIterableRest.js +0 -2
  406. package/dist/node_modules/@babel/runtime/helpers/esm/nonIterableRest.js.map +0 -1
  407. package/dist/node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js +0 -2
  408. package/dist/node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js.map +0 -1
  409. package/dist/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js +0 -2
  410. package/dist/node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js.map +0 -1
  411. package/dist/node_modules/@babel/runtime/helpers/esm/toArray.js +0 -2
  412. package/dist/node_modules/@babel/runtime/helpers/esm/toArray.js.map +0 -1
  413. package/dist/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js +0 -2
  414. package/dist/node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js.map +0 -1
  415. package/dist/node_modules/@babel/runtime/helpers/iterableToArrayLimit.js +0 -2
  416. package/dist/node_modules/@babel/runtime/helpers/iterableToArrayLimit.js.map +0 -1
  417. package/dist/node_modules/@babel/runtime/helpers/nonIterableRest.js +0 -2
  418. package/dist/node_modules/@babel/runtime/helpers/nonIterableRest.js.map +0 -1
  419. package/dist/node_modules/@babel/runtime/helpers/objectWithoutProperties.js +0 -2
  420. package/dist/node_modules/@babel/runtime/helpers/objectWithoutProperties.js.map +0 -1
  421. package/dist/node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js +0 -2
  422. package/dist/node_modules/@babel/runtime/helpers/objectWithoutPropertiesLoose.js.map +0 -1
  423. package/dist/node_modules/@babel/runtime/helpers/slicedToArray.js +0 -2
  424. package/dist/node_modules/@babel/runtime/helpers/slicedToArray.js.map +0 -1
  425. package/dist/node_modules/@babel/runtime/helpers/toPrimitive.js +0 -2
  426. package/dist/node_modules/@babel/runtime/helpers/toPrimitive.js.map +0 -1
  427. package/dist/node_modules/@babel/runtime/helpers/toPropertyKey.js +0 -2
  428. package/dist/node_modules/@babel/runtime/helpers/toPropertyKey.js.map +0 -1
  429. package/dist/node_modules/@babel/runtime/helpers/typeof.js +0 -2
  430. package/dist/node_modules/@babel/runtime/helpers/typeof.js.map +0 -1
  431. package/dist/node_modules/@babel/runtime/helpers/unsupportedIterableToArray.js +0 -2
  432. package/dist/node_modules/@babel/runtime/helpers/unsupportedIterableToArray.js.map +0 -1
  433. package/dist/node_modules/framer-motion/dist/es/events/add-pointer-event.mjs.js +0 -2
  434. package/dist/node_modules/framer-motion/dist/es/events/add-pointer-event.mjs.js.map +0 -1
  435. package/dist/node_modules/framer-motion/dist/es/events/event-info.mjs.js +0 -2
  436. package/dist/node_modules/framer-motion/dist/es/events/event-info.mjs.js.map +0 -1
  437. package/dist/node_modules/framer-motion/dist/es/gestures/drag/VisualElementDragControls.mjs.js +0 -2
  438. package/dist/node_modules/framer-motion/dist/es/gestures/drag/VisualElementDragControls.mjs.js.map +0 -1
  439. package/dist/node_modules/framer-motion/dist/es/gestures/drag/utils/constraints.mjs.js +0 -2
  440. package/dist/node_modules/framer-motion/dist/es/gestures/drag/utils/constraints.mjs.js.map +0 -1
  441. package/dist/node_modules/framer-motion/dist/es/gestures/pan/PanSession.mjs.js +0 -2
  442. package/dist/node_modules/framer-motion/dist/es/gestures/pan/PanSession.mjs.js.map +0 -1
  443. package/dist/node_modules/framer-motion/dist/es/utils/distance.mjs.js.map +0 -1
  444. package/dist/node_modules/framer-motion/dist/es/utils/get-context-window.mjs.js +0 -2
  445. package/dist/node_modules/framer-motion/dist/es/utils/get-context-window.mjs.js.map +0 -1
  446. package/dist/node_modules/framer-motion/dist/es/utils/is-ref-object.mjs.js.map +0 -1
  447. package/dist/node_modules/html-parse-stringify/dist/html-parse-stringify.js +0 -2
  448. package/dist/node_modules/html-parse-stringify/dist/html-parse-stringify.js.map +0 -1
  449. package/dist/node_modules/motion-dom/dist/es/render/utils/get-variant-context.mjs.js +0 -2
  450. package/dist/node_modules/motion-dom/dist/es/render/utils/get-variant-context.mjs.js.map +0 -1
  451. package/dist/node_modules/motion-dom/dist/es/value/types/utils/find.mjs.js +0 -2
  452. package/dist/node_modules/motion-dom/dist/es/value/types/utils/find.mjs.js.map +0 -1
  453. package/dist/node_modules/void-elements/index.js +0 -2
  454. package/dist/node_modules/void-elements/index.js.map +0 -1
  455. /package/dist/node_modules/{framer-motion → motion-dom}/dist/es/utils/distance.mjs.js +0 -0
  456. /package/dist/node_modules/{framer-motion → motion-dom}/dist/es/utils/is-ref-object.mjs.js +0 -0
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs.js","sources":["../../../../../../node_modules/motion-dom/dist/es/value/index.mjs"],"sourcesContent":["import { warnOnce, SubscriptionManager, velocityPerSecond } from 'motion-utils';\nimport { time } from '../frameloop/sync-time.mjs';\nimport { frame } from '../frameloop/frame.mjs';\n\n/**\n * Maximum time between the value of two frames, beyond which we\n * assume the velocity has since been 0.\n */\nconst MAX_VELOCITY_DELTA = 30;\nconst isFloat = (value) => {\n return !isNaN(parseFloat(value));\n};\nconst collectMotionValues = {\n current: undefined,\n};\n/**\n * `MotionValue` is used to track the state and velocity of motion values.\n *\n * @public\n */\nclass MotionValue {\n /**\n * @param init - The initiating value\n * @param config - Optional configuration options\n *\n * - `transformer`: A function to transform incoming values with.\n */\n constructor(init, options = {}) {\n /**\n * Tracks whether this value can output a velocity. Currently this is only true\n * if the value is numerical, but we might be able to widen the scope here and support\n * other value types.\n *\n * @internal\n */\n this.canTrackVelocity = null;\n /**\n * An object containing a SubscriptionManager for each active event.\n */\n this.events = {};\n this.updateAndNotify = (v) => {\n const currentTime = time.now();\n /**\n * If we're updating the value during another frame or eventloop\n * than the previous frame, then the we set the previous frame value\n * to current.\n */\n if (this.updatedAt !== currentTime) {\n this.setPrevFrameValue();\n }\n this.prev = this.current;\n this.setCurrent(v);\n // Update update subscribers\n if (this.current !== this.prev) {\n this.events.change?.notify(this.current);\n if (this.dependents) {\n for (const dependent of this.dependents) {\n dependent.dirty();\n }\n }\n }\n };\n this.hasAnimated = false;\n this.setCurrent(init);\n this.owner = options.owner;\n }\n setCurrent(current) {\n this.current = current;\n this.updatedAt = time.now();\n if (this.canTrackVelocity === null && current !== undefined) {\n this.canTrackVelocity = isFloat(this.current);\n }\n }\n setPrevFrameValue(prevFrameValue = this.current) {\n this.prevFrameValue = prevFrameValue;\n this.prevUpdatedAt = this.updatedAt;\n }\n /**\n * Adds a function that will be notified when the `MotionValue` is updated.\n *\n * It returns a function that, when called, will cancel the subscription.\n *\n * When calling `onChange` inside a React component, it should be wrapped with the\n * `useEffect` hook. As it returns an unsubscribe function, this should be returned\n * from the `useEffect` function to ensure you don't add duplicate subscribers..\n *\n * ```jsx\n * export const MyComponent = () => {\n * const x = useMotionValue(0)\n * const y = useMotionValue(0)\n * const opacity = useMotionValue(1)\n *\n * useEffect(() => {\n * function updateOpacity() {\n * const maxXY = Math.max(x.get(), y.get())\n * const newOpacity = transform(maxXY, [0, 100], [1, 0])\n * opacity.set(newOpacity)\n * }\n *\n * const unsubscribeX = x.on(\"change\", updateOpacity)\n * const unsubscribeY = y.on(\"change\", updateOpacity)\n *\n * return () => {\n * unsubscribeX()\n * unsubscribeY()\n * }\n * }, [])\n *\n * return <motion.div style={{ x }} />\n * }\n * ```\n *\n * @param subscriber - A function that receives the latest value.\n * @returns A function that, when called, will cancel this subscription.\n *\n * @deprecated\n */\n onChange(subscription) {\n if (process.env.NODE_ENV !== \"production\") {\n warnOnce(false, `value.onChange(callback) is deprecated. Switch to value.on(\"change\", callback).`);\n }\n return this.on(\"change\", subscription);\n }\n on(eventName, callback) {\n if (!this.events[eventName]) {\n this.events[eventName] = new SubscriptionManager();\n }\n const unsubscribe = this.events[eventName].add(callback);\n if (eventName === \"change\") {\n return () => {\n unsubscribe();\n /**\n * If we have no more change listeners by the start\n * of the next frame, stop active animations.\n */\n frame.read(() => {\n if (!this.events.change.getSize()) {\n this.stop();\n }\n });\n };\n }\n return unsubscribe;\n }\n clearListeners() {\n for (const eventManagers in this.events) {\n this.events[eventManagers].clear();\n }\n }\n /**\n * Attaches a passive effect to the `MotionValue`.\n */\n attach(passiveEffect, stopPassiveEffect) {\n this.passiveEffect = passiveEffect;\n this.stopPassiveEffect = stopPassiveEffect;\n }\n /**\n * Sets the state of the `MotionValue`.\n *\n * @remarks\n *\n * ```jsx\n * const x = useMotionValue(0)\n * x.set(10)\n * ```\n *\n * @param latest - Latest value to set.\n * @param render - Whether to notify render subscribers. Defaults to `true`\n *\n * @public\n */\n set(v) {\n if (!this.passiveEffect) {\n this.updateAndNotify(v);\n }\n else {\n this.passiveEffect(v, this.updateAndNotify);\n }\n }\n setWithVelocity(prev, current, delta) {\n this.set(current);\n this.prev = undefined;\n this.prevFrameValue = prev;\n this.prevUpdatedAt = this.updatedAt - delta;\n }\n /**\n * Set the state of the `MotionValue`, stopping any active animations,\n * effects, and resets velocity to `0`.\n */\n jump(v, endAnimation = true) {\n this.updateAndNotify(v);\n this.prev = v;\n this.prevUpdatedAt = this.prevFrameValue = undefined;\n endAnimation && this.stop();\n if (this.stopPassiveEffect)\n this.stopPassiveEffect();\n }\n dirty() {\n this.events.change?.notify(this.current);\n }\n addDependent(dependent) {\n if (!this.dependents) {\n this.dependents = new Set();\n }\n this.dependents.add(dependent);\n }\n removeDependent(dependent) {\n if (this.dependents) {\n this.dependents.delete(dependent);\n }\n }\n /**\n * Returns the latest state of `MotionValue`\n *\n * @returns - The latest state of `MotionValue`\n *\n * @public\n */\n get() {\n if (collectMotionValues.current) {\n collectMotionValues.current.push(this);\n }\n return this.current;\n }\n /**\n * @public\n */\n getPrevious() {\n return this.prev;\n }\n /**\n * Returns the latest velocity of `MotionValue`\n *\n * @returns - The latest velocity of `MotionValue`. Returns `0` if the state is non-numerical.\n *\n * @public\n */\n getVelocity() {\n const currentTime = time.now();\n if (!this.canTrackVelocity ||\n this.prevFrameValue === undefined ||\n currentTime - this.updatedAt > MAX_VELOCITY_DELTA) {\n return 0;\n }\n const delta = Math.min(this.updatedAt - this.prevUpdatedAt, MAX_VELOCITY_DELTA);\n // Casts because of parseFloat's poor typing\n return velocityPerSecond(parseFloat(this.current) -\n parseFloat(this.prevFrameValue), delta);\n }\n /**\n * Registers a new animation to control this `MotionValue`. Only one\n * animation can drive a `MotionValue` at one time.\n *\n * ```jsx\n * value.start()\n * ```\n *\n * @param animation - A function that starts the provided animation\n */\n start(startAnimation) {\n this.stop();\n return new Promise((resolve) => {\n this.hasAnimated = true;\n this.animation = startAnimation(resolve);\n if (this.events.animationStart) {\n this.events.animationStart.notify();\n }\n }).then(() => {\n if (this.events.animationComplete) {\n this.events.animationComplete.notify();\n }\n this.clearAnimation();\n });\n }\n /**\n * Stop the currently active animation.\n *\n * @public\n */\n stop() {\n if (this.animation) {\n this.animation.stop();\n if (this.events.animationCancel) {\n this.events.animationCancel.notify();\n }\n }\n this.clearAnimation();\n }\n /**\n * Returns `true` if this value is currently animating.\n *\n * @public\n */\n isAnimating() {\n return !!this.animation;\n }\n clearAnimation() {\n delete this.animation;\n }\n /**\n * Destroy and clean up subscribers to this `MotionValue`.\n *\n * The `MotionValue` hooks like `useMotionValue` and `useTransform` automatically\n * handle the lifecycle of the returned `MotionValue`, so this method is only necessary if you've manually\n * created a `MotionValue` via the `motionValue` function.\n *\n * @public\n */\n destroy() {\n this.dependents?.clear();\n this.events.destroy?.notify();\n this.clearListeners();\n this.stop();\n if (this.stopPassiveEffect) {\n this.stopPassiveEffect();\n }\n }\n}\nfunction motionValue(init, options) {\n return new MotionValue(init, options);\n}\n\nexport { MotionValue, collectMotionValues, motionValue };\n//# sourceMappingURL=index.mjs.map\n"],"names":["MotionValue","constructor","init","options","this","canTrackVelocity","events","updateAndNotify","v","currentTime","time","now","updatedAt","setPrevFrameValue","prev","current","setCurrent","change","notify","dependents","dependent","dirty","hasAnimated","owner","value","undefined","isNaN","parseFloat","prevFrameValue","prevUpdatedAt","onChange","subscription","process","env","NODE_ENV","warnOnce","on","eventName","callback","SubscriptionManager","unsubscribe","add","frame","read","getSize","stop","clearListeners","eventManagers","clear","attach","passiveEffect","stopPassiveEffect","set","setWithVelocity","delta","jump","endAnimation","addDependent","Set","removeDependent","delete","get","getPrevious","getVelocity","Math","min","velocityPerSecond","start","startAnimation","Promise","resolve","animation","animationStart","then","animationComplete","clearAnimation","animationCancel","isAnimating","destroy"],"mappings":"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"}
1
+ {"version":3,"file":"index.mjs.js","sources":["../../../../../../node_modules/motion-dom/dist/es/value/index.mjs"],"sourcesContent":["import { warnOnce, SubscriptionManager, velocityPerSecond } from 'motion-utils';\nimport { time } from '../frameloop/sync-time.mjs';\nimport { frame } from '../frameloop/frame.mjs';\n\n/**\n * Maximum time between the value of two frames, beyond which we\n * assume the velocity has since been 0.\n */\nconst MAX_VELOCITY_DELTA = 30;\nconst isFloat = (value) => {\n return !isNaN(parseFloat(value));\n};\nconst collectMotionValues = {\n current: undefined,\n};\n/**\n * `MotionValue` is used to track the state and velocity of motion values.\n *\n * @public\n */\nclass MotionValue {\n /**\n * @param init - The initiating value\n * @param config - Optional configuration options\n *\n * - `transformer`: A function to transform incoming values with.\n */\n constructor(init, options = {}) {\n /**\n * Tracks whether this value can output a velocity. Currently this is only true\n * if the value is numerical, but we might be able to widen the scope here and support\n * other value types.\n *\n * @internal\n */\n this.canTrackVelocity = null;\n /**\n * An object containing a SubscriptionManager for each active event.\n */\n this.events = {};\n this.updateAndNotify = (v) => {\n const currentTime = time.now();\n /**\n * If we're updating the value during another frame or eventloop\n * than the previous frame, then the we set the previous frame value\n * to current.\n */\n if (this.updatedAt !== currentTime) {\n this.setPrevFrameValue();\n }\n this.prev = this.current;\n this.setCurrent(v);\n // Update update subscribers\n if (this.current !== this.prev) {\n this.dirty();\n if (this.dependents) {\n for (const dependent of this.dependents) {\n dependent.dirty();\n }\n }\n }\n };\n this.hasAnimated = false;\n this.setCurrent(init);\n this.owner = options.owner;\n }\n setCurrent(current) {\n this.current = current;\n this.updatedAt = time.now();\n if (this.canTrackVelocity === null && current !== undefined) {\n this.canTrackVelocity = isFloat(this.current);\n }\n }\n setPrevFrameValue(prevFrameValue = this.current) {\n this.prevFrameValue = prevFrameValue;\n this.prevUpdatedAt = this.updatedAt;\n }\n /**\n * Adds a function that will be notified when the `MotionValue` is updated.\n *\n * It returns a function that, when called, will cancel the subscription.\n *\n * When calling `onChange` inside a React component, it should be wrapped with the\n * `useEffect` hook. As it returns an unsubscribe function, this should be returned\n * from the `useEffect` function to ensure you don't add duplicate subscribers..\n *\n * ```jsx\n * export const MyComponent = () => {\n * const x = useMotionValue(0)\n * const y = useMotionValue(0)\n * const opacity = useMotionValue(1)\n *\n * useEffect(() => {\n * function updateOpacity() {\n * const maxXY = Math.max(x.get(), y.get())\n * const newOpacity = transform(maxXY, [0, 100], [1, 0])\n * opacity.set(newOpacity)\n * }\n *\n * const unsubscribeX = x.on(\"change\", updateOpacity)\n * const unsubscribeY = y.on(\"change\", updateOpacity)\n *\n * return () => {\n * unsubscribeX()\n * unsubscribeY()\n * }\n * }, [])\n *\n * return <motion.div style={{ x }} />\n * }\n * ```\n *\n * @param subscriber - A function that receives the latest value.\n * @returns A function that, when called, will cancel this subscription.\n *\n * @deprecated\n */\n onChange(subscription) {\n if (process.env.NODE_ENV !== \"production\") {\n warnOnce(false, `value.onChange(callback) is deprecated. Switch to value.on(\"change\", callback).`);\n }\n return this.on(\"change\", subscription);\n }\n on(eventName, callback) {\n var _a;\n if (eventName === \"change\")\n return this.onChangeSubscribe(callback);\n return ((_a = this.events)[eventName] || (_a[eventName] = new SubscriptionManager())).add(callback);\n }\n onChangeSubscribe(callback) {\n const { events } = this;\n if (!events.change && !this.changeSubscriber) {\n this.changeSubscriber = callback;\n }\n else {\n if (!events.change) {\n events.change = new SubscriptionManager();\n events.change.add(this.changeSubscriber);\n this.changeSubscriber = undefined;\n }\n events.change.add(callback);\n }\n return () => {\n if (this.changeSubscriber === callback) {\n this.changeSubscriber = undefined;\n }\n else {\n events.change?.remove(callback);\n }\n this.stopIfUnobserved();\n };\n }\n /**\n * If we have no more change listeners by the start\n * of the next frame, stop active animations.\n */\n stopIfUnobserved() {\n frame.read(() => {\n if (!this.changeSubscriber && !this.events.change?.getSize()) {\n this.stop();\n }\n });\n }\n clearListeners() {\n this.changeSubscriber = undefined;\n for (const eventManagers in this.events) {\n this.events[eventManagers].clear();\n }\n }\n /**\n * Attaches a passive effect to the `MotionValue`.\n */\n attach(passiveEffect, stopPassiveEffect) {\n this.passiveEffect = passiveEffect;\n this.stopPassiveEffect = stopPassiveEffect;\n }\n /**\n * Sets the state of the `MotionValue`.\n *\n * @remarks\n *\n * ```jsx\n * const x = useMotionValue(0)\n * x.set(10)\n * ```\n *\n * @param latest - Latest value to set.\n * @param render - Whether to notify render subscribers. Defaults to `true`\n *\n * @public\n */\n set(v) {\n this.passiveEffect\n ? this.passiveEffect(v, this.updateAndNotify)\n : this.updateAndNotify(v);\n }\n setWithVelocity(prev, current, delta) {\n this.set(current);\n this.prev = undefined;\n this.prevFrameValue = prev;\n this.prevUpdatedAt = this.updatedAt - delta;\n }\n /**\n * Set the state of the `MotionValue`, stopping any active animations,\n * effects, and resets velocity to `0`.\n */\n jump(v, endAnimation = true) {\n if (endAnimation) {\n /**\n * Stop first, as stopping a running animation can set the\n * value it's showing, which would replace v. Marking the value\n * as updated now skips a JS animation's catch-up tick on stop,\n * which could otherwise complete it.\n */\n this.updatedAt = time.now();\n this.stop();\n }\n this.updateAndNotify(v);\n this.prev = v;\n this.prevUpdatedAt = this.prevFrameValue = undefined;\n this.stopPassiveEffect?.();\n }\n dirty() {\n const { current, changeSubscriber } = this;\n /**\n * One or the other exists. Subscribing during the direct\n * subscriber's call moves it into a new manager, which must not\n * then be notified for the same change.\n */\n if (changeSubscriber) {\n changeSubscriber(current);\n }\n else {\n this.events.change?.notify(current);\n }\n }\n addDependent(dependent) {\n (this.dependents || (this.dependents = new Set())).add(dependent);\n }\n removeDependent(dependent) {\n this.dependents?.delete(dependent);\n }\n /**\n * Returns the latest state of `MotionValue`\n *\n * @returns - The latest state of `MotionValue`\n *\n * @public\n */\n get() {\n collectMotionValues.current?.push(this);\n /**\n * A value animating on the compositor isn't updated every frame,\n * so read it from its animation.\n */\n const sampled = this.animation?.liveValue?.();\n return sampled === undefined ? this.current : sampled;\n }\n /**\n * The value as last set. Unlike get(), this doesn't read an animation\n * running on the compositor, which renders the value itself.\n */\n getCurrent() {\n return this.current;\n }\n /**\n * @public\n */\n getPrevious() {\n return this.prev;\n }\n /**\n * Returns the latest velocity of `MotionValue`\n *\n * @returns - The latest velocity of `MotionValue`. Returns `0` if the state is non-numerical.\n *\n * @public\n */\n getVelocity() {\n const currentTime = time.now();\n if (!this.canTrackVelocity ||\n this.prevFrameValue === undefined ||\n currentTime - this.updatedAt > MAX_VELOCITY_DELTA) {\n return 0;\n }\n const delta = Math.min(this.updatedAt - this.prevUpdatedAt, MAX_VELOCITY_DELTA);\n // Casts because of parseFloat's poor typing\n return velocityPerSecond(parseFloat(this.current) -\n parseFloat(this.prevFrameValue), delta);\n }\n /**\n * Registers a new animation to control this `MotionValue`. Only one\n * animation can drive a `MotionValue` at one time.\n *\n * ```jsx\n * value.start()\n * ```\n *\n * @param animation - A function that starts the provided animation\n */\n start(startAnimation) {\n return new Promise((resolve) => this.run(startAnimation, resolve));\n }\n /**\n * As start(), without making a promise, for animations started\n * internally, which complete through their own controls.\n */\n run(startAnimation, onComplete) {\n this.stop();\n this.hasAnimated = true;\n /**\n * Guard against animations that complete before startAnimation\n * has returned.\n */\n let isComplete = false;\n let animation;\n // eslint-disable-next-line prefer-const -- read by the callback before assignment when completing synchronously\n animation = startAnimation(() => {\n isComplete = true;\n this.events.animationComplete?.notify();\n if (this.animation === animation)\n this.animation = undefined;\n onComplete?.();\n });\n if (!isComplete)\n this.animation = animation;\n this.events.animationStart?.notify();\n }\n /**\n * Stop the currently active animation.\n *\n * @public\n */\n stop() {\n if (this.animation) {\n this.animation.stop();\n this.events.animationCancel?.notify();\n }\n // Assign rather than delete to keep the object's shape stable\n this.animation = undefined;\n }\n /**\n * Returns `true` if this value is currently animating.\n *\n * @public\n */\n isAnimating() {\n return !!this.animation;\n }\n /**\n * Destroy and clean up subscribers to this `MotionValue`.\n *\n * The `MotionValue` hooks like `useMotionValue` and `useTransform` automatically\n * handle the lifecycle of the returned `MotionValue`, so this method is only necessary if you've manually\n * created a `MotionValue` via the `motionValue` function.\n *\n * @public\n */\n destroy() {\n this.dependents?.clear();\n this.events.destroy?.notify();\n this.clearListeners();\n this.stop();\n this.stopPassiveEffect?.();\n }\n}\nfunction motionValue(init, options) {\n return new MotionValue(init, options);\n}\n\nexport { MotionValue, collectMotionValues, motionValue };\n//# sourceMappingURL=index.mjs.map\n"],"names":["collectMotionValues","current","undefined","MotionValue","constructor","init","options","this","canTrackVelocity","events","updateAndNotify","v","currentTime","time","now","updatedAt","setPrevFrameValue","prev","setCurrent","dirty","dependents","dependent","hasAnimated","owner","value","isNaN","parseFloat","prevFrameValue","prevUpdatedAt","onChange","subscription","process","env","NODE_ENV","warnOnce","on","eventName","callback","onChangeSubscribe","_a","SubscriptionManager","add","change","changeSubscriber","remove","stopIfUnobserved","frame","read","getSize","stop","clearListeners","eventManagers","clear","attach","passiveEffect","stopPassiveEffect","set","setWithVelocity","delta","jump","endAnimation","notify","addDependent","Set","removeDependent","delete","get","push","sampled","animation","liveValue","getCurrent","getPrevious","getVelocity","Math","min","velocityPerSecond","start","startAnimation","Promise","resolve","run","onComplete","isComplete","animationComplete","animationStart","animationCancel","isAnimating","destroy"],"mappings":"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"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var s=require("./rgba.mjs.js");const r={test:require("./utils.mjs.js").isColorString("#"),parse:function(s){let r="",t="",e="",n="";return s.length>5?(r=s.substring(1,3),t=s.substring(3,5),e=s.substring(5,7),n=s.substring(7,9)):(r=s.substring(1,2),t=s.substring(2,3),e=s.substring(3,4),n=s.substring(4,5),r+=r,t+=t,e+=e,n+=n),{red:parseInt(r,16),green:parseInt(t,16),blue:parseInt(e,16),alpha:n?parseInt(n,16)/255:1}},transform:s.rgba.transform};exports.hex=r;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var r=require("./rgba.mjs.js"),e=require("./utils.mjs.js");const s=(r,e,s)=>{const t=r.substring(1+e*s,1+(e+1)*s);return s>1?t:t+t};const t={test:e.isColorString("#"),parse:function(r){const e=r.length>5?2:1,t=s(r,3,e);return{red:parseInt(s(r,0,e),16),green:parseInt(s(r,1,e),16),blue:parseInt(s(r,2,e),16),alpha:t?parseInt(t,16)/255:1}},transform:r.rgba.transform};exports.hex=t;
2
2
  //# sourceMappingURL=hex.mjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"hex.mjs.js","sources":["../../../../../../../../node_modules/motion-dom/dist/es/value/types/color/hex.mjs"],"sourcesContent":["import { rgba } from './rgba.mjs';\nimport { isColorString } from './utils.mjs';\n\nfunction parseHex(v) {\n let r = \"\";\n let g = \"\";\n let b = \"\";\n let a = \"\";\n // If we have 6 characters, ie #FF0000\n if (v.length > 5) {\n r = v.substring(1, 3);\n g = v.substring(3, 5);\n b = v.substring(5, 7);\n a = v.substring(7, 9);\n // Or we have 3 characters, ie #F00\n }\n else {\n r = v.substring(1, 2);\n g = v.substring(2, 3);\n b = v.substring(3, 4);\n a = v.substring(4, 5);\n r += r;\n g += g;\n b += b;\n a += a;\n }\n return {\n red: parseInt(r, 16),\n green: parseInt(g, 16),\n blue: parseInt(b, 16),\n alpha: a ? parseInt(a, 16) / 255 : 1,\n };\n}\nconst hex = {\n test: /*@__PURE__*/ isColorString(\"#\"),\n parse: parseHex,\n transform: rgba.transform,\n};\n\nexport { hex };\n//# sourceMappingURL=hex.mjs.map\n"],"names":["hex","test","isColorString","parse","v","r","g","b","a","length","substring","red","parseInt","green","blue","alpha","transform","rgba"],"mappings":"mGAqCO,MAAMA,EAAM,CACfC,+BAAiCC,cAAC,KAClCC,MAnCJ,SAAkBC,GACd,IAAIC,EAAI,GACJC,EAAI,GACJC,EAAI,GACJC,EAAI,GAqBR,OAlBIJ,EAAEK,OAAS,GACXJ,EAAID,EAAEM,UAAU,EAAG,GACnBJ,EAAIF,EAAEM,UAAU,EAAG,GACnBH,EAAIH,EAAEM,UAAU,EAAG,GACnBF,EAAIJ,EAAEM,UAAU,EAAG,KAInBL,EAAID,EAAEM,UAAU,EAAG,GACnBJ,EAAIF,EAAEM,UAAU,EAAG,GACnBH,EAAIH,EAAEM,UAAU,EAAG,GACnBF,EAAIJ,EAAEM,UAAU,EAAG,GACnBL,GAAKA,EACLC,GAAKA,EACLC,GAAKA,EACLC,GAAKA,GAGF,CACHG,IAAKC,SAASP,EAAG,IACjBQ,MAAOD,SAASN,EAAG,IACnBQ,KAAMF,SAASL,EAAG,IAClBQ,MAAOP,EAAII,SAASJ,EAAG,IAAM,IAAM,EAE3C,EAKIQ,UAAWC,EAAIA,KAACD"}
1
+ {"version":3,"file":"hex.mjs.js","sources":["../../../../../../../../node_modules/motion-dom/dist/es/value/types/color/hex.mjs"],"sourcesContent":["import { rgba } from './rgba.mjs';\nimport { isColorString } from './utils.mjs';\n\n/**\n * #FF0000 has two characters per channel, #F00 one, which is doubled.\n */\nconst channel = (v, i, size) => {\n const c = v.substring(1 + i * size, 1 + (i + 1) * size);\n return size > 1 ? c : c + c;\n};\nfunction parseHex(v) {\n const size = v.length > 5 ? 2 : 1;\n const alpha = channel(v, 3, size);\n return {\n red: parseInt(channel(v, 0, size), 16),\n green: parseInt(channel(v, 1, size), 16),\n blue: parseInt(channel(v, 2, size), 16),\n alpha: alpha ? parseInt(alpha, 16) / 255 : 1,\n };\n}\nconst hex = {\n test: /*@__PURE__*/ isColorString(\"#\"),\n parse: parseHex,\n transform: rgba.transform,\n};\n\nexport { hex };\n//# sourceMappingURL=hex.mjs.map\n"],"names":["channel","v","i","size","c","substring","hex","test","isColorString","parse","length","alpha","red","parseInt","green","blue","transform","rgba"],"mappings":"+HAOA,MAAMA,EAAUA,CAACC,EAAWC,EAAWC,KACnC,MAAMC,EAAIH,EAAEI,UAAU,EAAIH,EAAIC,EAAM,GAAKD,EAAI,GAAKC,GAClD,OAAOA,EAAO,EAAIC,EAAIA,EAAIA,GAevB,MAAME,EAAM,CACfC,KAAoBC,EAAaA,cAAC,KAClCC,MAdJ,SAAkBR,GACd,MAAME,EAAOF,EAAES,OAAS,EAAI,EAAI,EAC1BC,EAAQX,EAAQC,EAAG,EAAGE,GAE5B,MAAO,CACHS,IAAKC,SAASb,EAAQC,EAAG,EAAGE,GAAO,IACnCW,MAAOD,SAASb,EAAQC,EAAG,EAAGE,GAAO,IACrCY,KAAMF,SAASb,EAAQC,EAAG,EAAGE,GAAO,IACpCQ,MAAOA,EAAQE,SAASF,EAAO,IAAM,IAAM,EAEnD,EAKIK,UAAWC,EAAIA,KAACD"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../color/index.mjs.js"),t=require("../utils/color-regex.mjs.js"),s=require("../utils/float-regex.mjs.js"),r=require("../utils/sanitize.mjs.js");const o="number",n="color",u=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function l(t){const s=t.toString(),r=[],l={color:[],number:[],var:[]},a=[];let i=0;const c=s.replace(u,t=>(e.color.test(t)?(l.color.push(i),a.push(n),r.push(e.color.parse(t))):t.startsWith("var(")?(l.var.push(i),a.push("var"),r.push(t)):(l.number.push(i),a.push(o),r.push(parseFloat(t))),++i,"${}")).split("${}");return{values:r,split:c,indexes:l,types:a}}function a({split:t,types:s}){const u=t.length;return l=>{let a="";for(let i=0;i<u;i++)if(a+=t[i],void 0!==l[i]){const t=s[i];a+=t===o?r.sanitize(l[i]):t===n?e.color.transform(l[i]):l[i]}return a}}const i=(t,s)=>{return"number"==typeof t?s?.trim().endsWith("/")?t:0:"number"==typeof(r=t)?0:e.color.test(r)?e.color.getAnimatableNone(r):r;var r};const c={test:function(e){return isNaN(e)&&"string"==typeof e&&(e.match(s.floatRegex)?.length||0)+(e.match(t.colorRegex)?.length||0)>0},parse:function(e){return l(e).values},createTransformer:function(e){return a(l(e))},getAnimatableNone:function(e){const t=l(e);return a(t)(t.values.map((e,s)=>i(e,t.split[s])))}};exports.analyseComplexValue=l,exports.complex=c;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../color/index.mjs.js"),t=require("../utils/color-regex.mjs.js"),s=require("../utils/float-regex.mjs.js"),r=require("../utils/sanitize.mjs.js");const o=new RegExp(s.floatRegex.source),n=new RegExp(t.colorRegex.source,"i");const u="number",l="color",i=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)(?![a-z]*\()/giu;function a(t){const s=t.toString(),r=[],o={color:[],number:[],var:[]},n=[];let a=0;const c=s.replace(i,t=>(e.color.test(t)?(o.color.push(a),n.push(l),r.push(e.color.parse(t))):t.startsWith("var(")?(o.var.push(a),n.push("var"),r.push(t)):(o.number.push(a),n.push(u),r.push(parseFloat(t))),++a,"${}")).split("${}");return{values:r,split:c,indexes:o,types:n}}function c({split:t,types:s}){const o=t.length;return n=>{let i="";for(let a=0;a<o;a++)if(i+=t[a],void 0!==n[a]){const t=s[a];i+=t===u?r.sanitize(n[a]):t===l?e.color.transform(n[a]):n[a]}return i}}const p=(t,s)=>{return"number"==typeof t?s?.trim().endsWith("/")?t:0:"number"==typeof(r=t)?0:e.color.test(r)?e.color.getAnimatableNone(r):r;var r};const f={test:function(e){return isNaN(e)&&"string"==typeof e&&(o.test(e)||n.test(e))},parse:function(e){return a(e).values},createTransformer:function(e){return c(a(e))},getAnimatableNone:function(e){const t=a(e);return c(t)(t.values.map((e,s)=>p(e,t.split[s])))}};exports.analyseComplexValue=a,exports.buildTransformer=c,exports.complex=f,exports.hasComplexValues=function(e){const t=e.toString();return o.test(t)||n.test(t)};
2
2
  //# sourceMappingURL=index.mjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs.js","sources":["../../../../../../../../node_modules/motion-dom/dist/es/value/types/complex/index.mjs"],"sourcesContent":["import { color } from '../color/index.mjs';\nimport { colorRegex } from '../utils/color-regex.mjs';\nimport { floatRegex } from '../utils/float-regex.mjs';\nimport { sanitize } from '../utils/sanitize.mjs';\n\nfunction test(v) {\n return (isNaN(v) &&\n typeof v === \"string\" &&\n (v.match(floatRegex)?.length || 0) +\n (v.match(colorRegex)?.length || 0) >\n 0);\n}\nconst NUMBER_TOKEN = \"number\";\nconst COLOR_TOKEN = \"color\";\nconst VAR_TOKEN = \"var\";\nconst VAR_FUNCTION_TOKEN = \"var(\";\nconst SPLIT_TOKEN = \"${}\";\n// this regex consists of the `singleCssVariableRegex|rgbHSLValueRegex|digitRegex`\nconst complexRegex = /var\\s*\\(\\s*--(?:[\\w-]+\\s*|[\\w-]+\\s*,(?:\\s*[^)(\\s]|\\s*\\((?:[^)(]|\\([^)(]*\\))*\\))+\\s*)\\)|#[\\da-f]{3,8}|(?:rgb|hsl)a?\\((?:-?[\\d.]+%?[,\\s]+){2}-?[\\d.]+%?\\s*(?:[,/]\\s*)?(?:\\b\\d+(?:\\.\\d+)?|\\.\\d+)?%?\\)|-?(?:\\d+(?:\\.\\d+)?|\\.\\d+)/giu;\nfunction analyseComplexValue(value) {\n const originalValue = value.toString();\n const values = [];\n const indexes = {\n color: [],\n number: [],\n var: [],\n };\n const types = [];\n let i = 0;\n const tokenised = originalValue.replace(complexRegex, (parsedValue) => {\n if (color.test(parsedValue)) {\n indexes.color.push(i);\n types.push(COLOR_TOKEN);\n values.push(color.parse(parsedValue));\n }\n else if (parsedValue.startsWith(VAR_FUNCTION_TOKEN)) {\n indexes.var.push(i);\n types.push(VAR_TOKEN);\n values.push(parsedValue);\n }\n else {\n indexes.number.push(i);\n types.push(NUMBER_TOKEN);\n values.push(parseFloat(parsedValue));\n }\n ++i;\n return SPLIT_TOKEN;\n });\n const split = tokenised.split(SPLIT_TOKEN);\n return { values, split, indexes, types };\n}\nfunction parseComplexValue(v) {\n return analyseComplexValue(v).values;\n}\nfunction buildTransformer({ split, types }) {\n const numSections = split.length;\n return (v) => {\n let output = \"\";\n for (let i = 0; i < numSections; i++) {\n output += split[i];\n if (v[i] !== undefined) {\n const type = types[i];\n if (type === NUMBER_TOKEN) {\n output += sanitize(v[i]);\n }\n else if (type === COLOR_TOKEN) {\n output += color.transform(v[i]);\n }\n else {\n output += v[i];\n }\n }\n }\n return output;\n };\n}\nfunction createTransformer(source) {\n return buildTransformer(analyseComplexValue(source));\n}\nconst convertNumbersToZero = (v) => typeof v === \"number\" ? 0 : color.test(v) ? color.getAnimatableNone(v) : v;\n/**\n * Convert a parsed value to its zero equivalent, but preserve numbers\n * that act as divisors in CSS calc() expressions.\n *\n * analyseComplexValue extracts numbers from CSS strings and puts the\n * surrounding text into a `split` template array. For example:\n * \"calc(var(--gap) / 5)\" → values: [var(--gap), 5]\n * split: [\"calc(\", \" / \", \")\"]\n *\n * When building a zero-equivalent for animation, naively zeroing all\n * numbers turns the divisor into 0 → \"calc(var(--gap) / 0)\" → NaN.\n * We detect this by checking whether the text preceding a number\n * (split[i]) ends with \"/\" — the CSS calc division operator.\n */\nconst convertToZero = (value, splitBefore) => {\n if (typeof value === \"number\") {\n return splitBefore?.trim().endsWith(\"/\") ? value : 0;\n }\n return convertNumbersToZero(value);\n};\nfunction getAnimatableNone(v) {\n const info = analyseComplexValue(v);\n const transformer = buildTransformer(info);\n return transformer(info.values.map((value, i) => convertToZero(value, info.split[i])));\n}\nconst complex = {\n test,\n parse: parseComplexValue,\n createTransformer,\n getAnimatableNone,\n};\n\nexport { analyseComplexValue, complex };\n//# sourceMappingURL=index.mjs.map\n"],"names":["NUMBER_TOKEN","COLOR_TOKEN","complexRegex","analyseComplexValue","value","originalValue","toString","values","indexes","color","number","var","types","i","split","replace","parsedValue","test","push","parse","startsWith","parseFloat","buildTransformer","numSections","length","v","output","undefined","type","sanitize","transform","convertToZero","splitBefore","trim","endsWith","getAnimatableNone","complex","isNaN","match","floatRegex","colorRegex","createTransformer","source","info","transformer","map"],"mappings":"mOAkBA,MAAMA,EAAe,SACfC,EAAc,QAuBdC,EACF,kOAEE,SAAUC,EACZC,GAEA,MAAMC,EAAgBD,EAAME,WAEtBC,EAAwB,GACxBC,EAAwB,CAC1BC,MAAO,GACPC,OAAQ,GACRC,IAAK,IAEHC,EAAmC,GAEzC,IAAIC,EAAI,EACR,MAiBMC,EAjBYT,EAAcU,QAAQb,EAAec,IAC/CP,EAAKA,MAACQ,KAAKD,IACXR,EAAQC,MAAMS,KAAKL,GACnBD,EAAMM,KAAKjB,GACXM,EAAOW,KAAKT,EAAAA,MAAMU,MAAMH,KACjBA,EAAYI,WA3CJ,SA4CfZ,EAAQG,IAAIO,KAAKL,GACjBD,EAAMM,KA9CA,OA+CNX,EAAOW,KAAKF,KAEZR,EAAQE,OAAOQ,KAAKL,GACpBD,EAAMM,KAAKlB,GACXO,EAAOW,KAAKG,WAAWL,OAEzBH,EAnDU,QAsDQC,MAtDR,OAwDhB,MAAO,CAAEP,SAAQO,QAAON,UAASI,QACrC,CAMA,SAASU,GAAiBR,MAAEA,EAAKF,MAAEA,IAC/B,MAAMW,EAAcT,EAAMU,OAC1B,OAAQC,IACJ,IAAIC,EAAS,GACb,IAAK,IAAIb,EAAI,EAAGA,EAAIU,EAAaV,IAE7B,GADAa,GAAUZ,EAAMD,QACHc,IAATF,EAAEZ,GAAkB,CACpB,MAAMe,EAAOhB,EAAMC,GAEfa,GADAE,IAAS5B,EACC6B,EAAQA,SAACJ,EAAEZ,IACde,IAAS3B,EACNQ,EAAAA,MAAMqB,UAAUL,EAAEZ,IAElBY,EAAEZ,EAEpB,CAGJ,OAAOa,EAEf,CAMA,MAiBMK,EAAgBA,CAClB3B,EACA4B,KAEA,MAAqB,iBAAV5B,EACA4B,GAAaC,OAAOC,SAAS,KAAO9B,EAAQ,EArB1C,iBADaqB,EAwBErB,GAvBJ,EAAIK,EAAKA,MAACQ,KAAKQ,GAAKhB,EAAKA,MAAC0B,kBAAkBV,GAAKA,EAD/CA,OAmCvB,MAAMW,EAAU,CACnBnB,KA3IJ,SAAcQ,GACV,OACIY,MAAMZ,IACO,iBAANA,IACNA,EAAEa,MAAMC,EAAUA,aAAGf,QAAU,IAC3BC,EAAEa,MAAME,EAAAA,aAAahB,QAAU,GAChC,CAEZ,EAoIIL,MAnEJ,SAA2BM,GACvB,OAAOtB,EAAoBsB,GAAGlB,MAClC,EAkEIkC,kBA1CJ,SAA2BC,GACvB,OAAOpB,EAAiBnB,EAAoBuC,GAChD,EAyCIP,kBAZJ,SAA2BV,GACvB,MAAMkB,EAAOxC,EAAoBsB,GAEjC,OADoBH,EAAiBqB,EAC9BC,CACHD,EAAKpC,OAAOsC,IAAI,CAACzC,EAAOS,IAAMkB,EAAc3B,EAAOuC,EAAK7B,MAAMD,KAEtE"}
1
+ {"version":3,"file":"index.mjs.js","sources":["../../../../../../../../node_modules/motion-dom/dist/es/value/types/complex/index.mjs"],"sourcesContent":["import { color } from '../color/index.mjs';\nimport { colorRegex } from '../utils/color-regex.mjs';\nimport { floatRegex } from '../utils/float-regex.mjs';\nimport { sanitize } from '../utils/sanitize.mjs';\n\n/**\n * Non-global copies of the token regexes so test() can use .test()\n * (no match array, stops at the first token) without lastIndex state.\n */\nconst hasFloat = /*@__PURE__*/ new RegExp(floatRegex.source);\nconst hasColor = /*@__PURE__*/ new RegExp(colorRegex.source, \"i\");\nfunction test(v) {\n return (isNaN(v) &&\n typeof v === \"string\" &&\n (hasFloat.test(v) || hasColor.test(v)));\n}\nconst NUMBER_TOKEN = \"number\";\nconst COLOR_TOKEN = \"color\";\nconst VAR_TOKEN = \"var\";\nconst VAR_FUNCTION_TOKEN = \"var(\";\nconst SPLIT_TOKEN = \"${}\";\n// this regex consists of the `singleCssVariableRegex|rgbHSLValueRegex|digitRegex`.\n// The lookahead skips digits in function names, like the 3 in matrix3d(.\nconst complexRegex = /var\\s*\\(\\s*--(?:[\\w-]+\\s*|[\\w-]+\\s*,(?:\\s*[^)(\\s]|\\s*\\((?:[^)(]|\\([^)(]*\\))*\\))+\\s*)\\)|#[\\da-f]{3,8}|(?:rgb|hsl)a?\\((?:-?[\\d.]+%?[,\\s]+){2}-?[\\d.]+%?\\s*(?:[,/]\\s*)?(?:\\b\\d+(?:\\.\\d+)?|\\.\\d+)?%?\\)|-?(?:\\d+(?:\\.\\d+)?|\\.\\d+)(?![a-z]*\\()/giu;\n/**\n * Whether analyseComplexValue(value) would find any values, without\n * tokenising the string. CSS variables are resolved before this is\n * used, so it's enough to look for a number or a color.\n */\nfunction hasComplexValues(value) {\n const asString = value.toString();\n return hasFloat.test(asString) || hasColor.test(asString);\n}\nfunction analyseComplexValue(value) {\n const originalValue = value.toString();\n const values = [];\n const indexes = {\n color: [],\n number: [],\n var: [],\n };\n const types = [];\n let i = 0;\n const tokenised = originalValue.replace(complexRegex, (parsedValue) => {\n if (color.test(parsedValue)) {\n indexes.color.push(i);\n types.push(COLOR_TOKEN);\n values.push(color.parse(parsedValue));\n }\n else if (parsedValue.startsWith(VAR_FUNCTION_TOKEN)) {\n indexes.var.push(i);\n types.push(VAR_TOKEN);\n values.push(parsedValue);\n }\n else {\n indexes.number.push(i);\n types.push(NUMBER_TOKEN);\n values.push(parseFloat(parsedValue));\n }\n ++i;\n return SPLIT_TOKEN;\n });\n const split = tokenised.split(SPLIT_TOKEN);\n return { values, split, indexes, types };\n}\nfunction parseComplexValue(v) {\n return analyseComplexValue(v).values;\n}\nfunction buildTransformer({ split, types }) {\n const numSections = split.length;\n return (v) => {\n let output = \"\";\n for (let i = 0; i < numSections; i++) {\n output += split[i];\n if (v[i] !== undefined) {\n const type = types[i];\n if (type === NUMBER_TOKEN) {\n output += sanitize(v[i]);\n }\n else if (type === COLOR_TOKEN) {\n output += color.transform(v[i]);\n }\n else {\n output += v[i];\n }\n }\n }\n return output;\n };\n}\nfunction createTransformer(source) {\n return buildTransformer(analyseComplexValue(source));\n}\nconst convertNumbersToZero = (v) => typeof v === \"number\" ? 0 : color.test(v) ? color.getAnimatableNone(v) : v;\n/**\n * Convert a parsed value to its zero equivalent, but preserve numbers\n * that act as divisors in CSS calc() expressions.\n *\n * analyseComplexValue extracts numbers from CSS strings and puts the\n * surrounding text into a `split` template array. For example:\n * \"calc(var(--gap) / 5)\" → values: [var(--gap), 5]\n * split: [\"calc(\", \" / \", \")\"]\n *\n * When building a zero-equivalent for animation, naively zeroing all\n * numbers turns the divisor into 0 → \"calc(var(--gap) / 0)\" → NaN.\n * We detect this by checking whether the text preceding a number\n * (split[i]) ends with \"/\" — the CSS calc division operator.\n */\nconst convertToZero = (value, splitBefore) => {\n if (typeof value === \"number\") {\n return splitBefore?.trim().endsWith(\"/\") ? value : 0;\n }\n return convertNumbersToZero(value);\n};\nfunction getAnimatableNone(v) {\n const info = analyseComplexValue(v);\n const transformer = buildTransformer(info);\n return transformer(info.values.map((value, i) => convertToZero(value, info.split[i])));\n}\nconst complex = {\n test,\n parse: parseComplexValue,\n createTransformer,\n getAnimatableNone,\n};\n\nexport { analyseComplexValue, buildTransformer, complex, hasComplexValues };\n//# sourceMappingURL=index.mjs.map\n"],"names":["hasFloat","RegExp","floatRegex","source","hasColor","colorRegex","NUMBER_TOKEN","COLOR_TOKEN","complexRegex","analyseComplexValue","value","originalValue","toString","values","indexes","color","number","var","types","i","split","replace","parsedValue","test","push","parse","startsWith","parseFloat","buildTransformer","numSections","length","v","output","undefined","type","sanitize","transform","convertToZero","splitBefore","trim","endsWith","getAnimatableNone","complex","isNaN","createTransformer","info","transformer","map","asString"],"mappings":"mOAYA,MAAMA,EAAyB,IAAIC,OAAOC,EAAUA,WAACC,QAC/CC,EAAyB,IAAIH,OAAOI,EAAUA,WAACF,OAAQ,KAU7D,MAAMG,EAAe,SACfC,EAAc,QAwBdC,EACF,8OAYE,SAAUC,EACZC,GAEA,MAAMC,EAAgBD,EAAME,WAEtBC,EAAwB,GACxBC,EAAwB,CAC1BC,MAAO,GACPC,OAAQ,GACRC,IAAK,IAEHC,EAAmC,GAEzC,IAAIC,EAAI,EACR,MAiBMC,EAjBYT,EAAcU,QAAQb,EAAec,IAC/CP,EAAKA,MAACQ,KAAKD,IACXR,EAAQC,MAAMS,KAAKL,GACnBD,EAAMM,KAAKjB,GACXM,EAAOW,KAAKT,EAAAA,MAAMU,MAAMH,KACjBA,EAAYI,WAtDJ,SAuDfZ,EAAQG,IAAIO,KAAKL,GACjBD,EAAMM,KAzDA,OA0DNX,EAAOW,KAAKF,KAEZR,EAAQE,OAAOQ,KAAKL,GACpBD,EAAMM,KAAKlB,GACXO,EAAOW,KAAKG,WAAWL,OAEzBH,EA9DU,QAiEQC,MAjER,OAmEhB,MAAO,CAAEP,SAAQO,QAAON,UAASI,QACrC,CAMgBU,SAAAA,GAAiBR,MAAEA,EAAKF,MAAEA,IACtC,MAAMW,EAAcT,EAAMU,OAC1B,OAAQC,IACJ,IAAIC,EAAS,GACb,IAAK,IAAIb,EAAI,EAAGA,EAAIU,EAAaV,IAE7B,GADAa,GAAUZ,EAAMD,QACHc,IAATF,EAAEZ,GAAkB,CACpB,MAAMe,EAAOhB,EAAMC,GAEfa,GADAE,IAAS5B,EACC6B,EAAQA,SAACJ,EAAEZ,IACde,IAAS3B,EACNQ,EAAAA,MAAMqB,UAAUL,EAAEZ,IAElBY,EAAEZ,EAEpB,CAGJ,OAAOa,EAEf,CAMA,MAiBMK,EAAgBA,CAClB3B,EACA4B,KAEA,MAAqB,iBAAV5B,EACA4B,GAAaC,OAAOC,SAAS,KAAO9B,EAAQ,EArB1C,iBADaqB,EAwBErB,GAvBJ,EAAIK,EAAKA,MAACQ,KAAKQ,GAAKhB,EAAKA,MAAC0B,kBAAkBV,GAAKA,EAD/CA,OAmCvB,MAAMW,EAAU,CACnBnB,KApJJ,SAAcQ,GACV,OACIY,MAAMZ,IACO,iBAANA,IACN/B,EAASuB,KAAKQ,IAAM3B,EAASmB,KAAKQ,GAE3C,EA+IIN,MAnEJ,SAA2BM,GACvB,OAAOtB,EAAoBsB,GAAGlB,MAClC,EAkEI+B,kBA1CJ,SAA2BzC,GACvB,OAAOyB,EAAiBnB,EAAoBN,GAChD,EAyCIsC,kBAZJ,SAA2BV,GACvB,MAAMc,EAAOpC,EAAoBsB,GAEjC,OADoBH,EAAiBiB,EAC9BC,CACHD,EAAKhC,OAAOkC,IAAI,CAACrC,EAAOS,IAAMkB,EAAc3B,EAAOmC,EAAKzB,MAAMD,KAEtE,uGAxGM,SAA2BT,GAC7B,MAAMsC,EAAWtC,EAAME,WACvB,OAAOZ,EAASuB,KAAKyB,IAAa5C,EAASmB,KAAKyB,EACpD"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../complex/index.mjs.js"),t=require("../complex/filter.mjs.js"),s=require("../complex/mask.mjs.js"),r=require("../maps/defaults.mjs.js");const a=new Set([t.filter,s.mask]);exports.getAnimatableNone=function(t,s){let l=r.getDefaultValueType(t);return a.has(l)||(l=e.complex),l.getAnimatableNone?l.getAnimatableNone(s):void 0};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../complex/index.mjs.js"),t=require("../complex/filter.mjs.js"),r=require("../complex/mask.mjs.js"),s=require("../maps/defaults.mjs.js");const l=new Set([t.filter,r.mask]);let a,i,m;exports.getAnimatableNone=function(t,r){if(t===a&&r===i)return m;let n=s.getDefaultValueType(t);return l.has(n)||(n=e.complex),m=n.getAnimatableNone?n.getAnimatableNone(r):void 0,a=t,i=r,m};
2
2
  //# sourceMappingURL=animatable-none.mjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"animatable-none.mjs.js","sources":["../../../../../../../../node_modules/motion-dom/dist/es/value/types/utils/animatable-none.mjs"],"sourcesContent":["import { complex } from '../complex/index.mjs';\nimport { filter } from '../complex/filter.mjs';\nimport { mask } from '../complex/mask.mjs';\nimport { getDefaultValueType } from '../maps/defaults.mjs';\n\nconst customTypes = /*@__PURE__*/ new Set([filter, mask]);\nfunction getAnimatableNone(key, value) {\n let defaultValueType = getDefaultValueType(key);\n if (!customTypes.has(defaultValueType))\n defaultValueType = complex;\n // If value is not recognised as animatable, ie \"none\", create an animatable version origin based on the target\n return defaultValueType.getAnimatableNone\n ? defaultValueType.getAnimatableNone(value)\n : undefined;\n}\n\nexport { getAnimatableNone };\n//# sourceMappingURL=animatable-none.mjs.map\n"],"names":["customTypes","Set","filter","mask","key","value","defaultValueType","getDefaultValueType","has","complex","getAnimatableNone","undefined"],"mappings":"4NAKA,MAAMA,EAA4B,IAAIC,IAAI,CAACC,EAAAA,OAAQC,EAAAA,iCAE7C,SAA4BC,EAAaC,GAC3C,IAAIC,EAAmBC,sBAAoBH,GAG3C,OAFKJ,EAAYQ,IAAIF,KAA0BA,EAAmBG,EAAAA,SAE3DH,EAAiBI,kBAClBJ,EAAiBI,kBAAkBL,QACnCM,CACV"}
1
+ {"version":3,"file":"animatable-none.mjs.js","sources":["../../../../../../../../node_modules/motion-dom/dist/es/value/types/utils/animatable-none.mjs"],"sourcesContent":["import { complex } from '../complex/index.mjs';\nimport { filter } from '../complex/filter.mjs';\nimport { mask } from '../complex/mask.mjs';\nimport { getDefaultValueType } from '../maps/defaults.mjs';\n\nconst customTypes = /*@__PURE__*/ new Set([filter, mask]);\n/**\n * The last call and its result. animate() on many elements asks for the\n * same none for each one, and parsing the value is the slow part.\n */\nlet lastKey;\nlet lastValue;\nlet lastNone;\nfunction getAnimatableNone(key, value) {\n if (key === lastKey && value === lastValue)\n return lastNone;\n let defaultValueType = getDefaultValueType(key);\n if (!customTypes.has(defaultValueType))\n defaultValueType = complex;\n // If value is not recognised as animatable, ie \"none\", create an animatable version origin based on the target\n lastNone = defaultValueType.getAnimatableNone\n ? defaultValueType.getAnimatableNone(value)\n : undefined;\n lastKey = key;\n lastValue = value;\n return lastNone;\n}\n\nexport { getAnimatableNone };\n//# sourceMappingURL=animatable-none.mjs.map\n"],"names":["customTypes","Set","filter","mask","lastKey","lastValue","lastNone","key","value","defaultValueType","getDefaultValueType","has","complex","getAnimatableNone","undefined"],"mappings":"4NAKA,MAAMA,EAA4B,IAAIC,IAAI,CAACC,EAAAA,OAAQC,EAAAA,OAMnD,IAAIC,EACAC,EACAC,4BAEE,SAA4BC,EAAaC,GAC3C,GAAID,IAAQH,GAAWI,IAAUH,EAAW,OAAOC,EAEnD,IAAIG,EAAmBC,sBAAoBH,GAS3C,OARKP,EAAYW,IAAIF,KAA0BA,EAAmBG,EAAAA,SAElEN,EAAWG,EAAiBI,kBACtBJ,EAAiBI,kBAAkBL,QACnCM,EACNV,EAAUG,EACVF,EAAYG,EAELF,CACX"}
@@ -0,0 +1,2 @@
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});exports.asNumber=e=>"number"==typeof e?e:parseFloat(e);
2
+ //# sourceMappingURL=as-number.mjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"as-number.mjs.js","sources":["../../../../../../../node_modules/motion-dom/dist/es/value/utils/as-number.mjs"],"sourcesContent":["const asNumber = (v) => typeof v === \"number\" ? v : parseFloat(v);\n\nexport { asNumber };\n//# sourceMappingURL=as-number.mjs.map\n"],"names":["v","parseFloat"],"mappings":"qFAEyBA,GACR,iBAANA,EAAiBA,EAAIC,WAAWD"}
@@ -1 +1 @@
1
- {"version":3,"file":"circ.mjs.js","sources":["../../../../../../node_modules/motion-utils/dist/es/easing/circ.mjs"],"sourcesContent":["import { mirrorEasing } from './modifiers/mirror.mjs';\nimport { reverseEasing } from './modifiers/reverse.mjs';\n\nconst circIn = (p) => 1 - Math.sin(Math.acos(p));\nconst circOut = reverseEasing(circIn);\nconst circInOut = mirrorEasing(circIn);\n\nexport { circIn, circInOut, circOut };\n//# sourceMappingURL=circ.mjs.map\n"],"names":["circIn","p","Math","sin","acos","circOut","reverseEasing","circInOut","mirrorEasing"],"mappings":"+GAIaA,MAAAA,EAA0BC,GAAM,EAAIC,KAAKC,IAAID,KAAKE,KAAKH,IACvDI,wCAAuBC,cAACN,GACxBO,EAAYC,EAAYA,aAACR"}
1
+ {"version":3,"file":"circ.mjs.js","sources":["../../../../../../node_modules/motion-utils/dist/es/easing/circ.mjs"],"sourcesContent":["import { mirrorEasing } from './modifiers/mirror.mjs';\nimport { reverseEasing } from './modifiers/reverse.mjs';\n\nconst circIn = (p) => 1 - Math.sin(Math.acos(p));\nconst circOut = /* @__PURE__ */ reverseEasing(circIn);\nconst circInOut = /* @__PURE__ */ mirrorEasing(circIn);\n\nexport { circIn, circInOut, circOut };\n//# sourceMappingURL=circ.mjs.map\n"],"names":["circIn","p","Math","sin","acos","circOut","reverseEasing","circInOut","mirrorEasing"],"mappings":"+GAIaA,MAAAA,EAA0BC,GAAM,EAAIC,KAAKC,IAAID,KAAKE,KAAKH,IACvDI,wCAAuCC,cAACN,GACxCO,EAA4BC,EAAYA,aAACR"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../noop.mjs.js");const r=(e,r,t)=>(((1-3*t+3*r)*e+(3*t-6*r))*e+3*r)*e;exports.cubicBezier=function(t,o,n,s){if(t===o&&n===s)return e.noop;const u=e=>function(e,t,o,n,s){let u,i,c=0;do{i=t+(o-t)/2,u=r(i,n,s)-e,u>0?o=i:t=i}while(Math.abs(u)>1e-7&&++c<12);return i}(e,0,1,t,n);return e=>0===e||1===e?e:r(u(e),o,s)};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../noop.mjs.js");const r=(e,r,t)=>e*(3*(1-e)*((1-e)*r+e*t)+e*e);exports.cubicBezier=function(t,o,n,s){return t===o&&n===s?e.noop:e=>{let u=0,c=1,i=e;for(let o=0;;o++){i>=u&&i<=c||(i=(u+c)/2);const s=r(i,t,n)-e;if(s*s<1e-28||40===o)break;s>0?c=i:u=i,i-=1e-7*s/(r(i+1e-7,t,n)-e-s)}return r(i,o,s)}};
2
2
  //# sourceMappingURL=cubic-bezier.mjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"cubic-bezier.mjs.js","sources":["../../../../../../node_modules/motion-utils/dist/es/easing/cubic-bezier.mjs"],"sourcesContent":["import { noop } from '../noop.mjs';\n\n/*\n Bezier function generator\n This has been modified from Gaëtan Renaudeau's BezierEasing\n https://github.com/gre/bezier-easing/blob/master/src/index.js\n https://github.com/gre/bezier-easing/blob/master/LICENSE\n \n I've removed the newtonRaphsonIterate algo because in benchmarking it\n wasn't noticeably faster than binarySubdivision, indeed removing it\n usually improved times, depending on the curve.\n I also removed the lookup table, as for the added bundle size and loop we're\n only cutting ~4 or so subdivision iterations. I bumped the max iterations up\n to 12 to compensate and this still tended to be faster for no perceivable\n loss in accuracy.\n Usage\n const easeOut = cubicBezier(.17,.67,.83,.67);\n const x = easeOut(0.5); // returns 0.627...\n*/\n// Returns x(t) given t, x1, and x2, or y(t) given t, y1, and y2.\nconst calcBezier = (t, a1, a2) => (((1.0 - 3.0 * a2 + 3.0 * a1) * t + (3.0 * a2 - 6.0 * a1)) * t + 3.0 * a1) *\n t;\nconst subdivisionPrecision = 0.0000001;\nconst subdivisionMaxIterations = 12;\nfunction binarySubdivide(x, lowerBound, upperBound, mX1, mX2) {\n let currentX;\n let currentT;\n let i = 0;\n do {\n currentT = lowerBound + (upperBound - lowerBound) / 2.0;\n currentX = calcBezier(currentT, mX1, mX2) - x;\n if (currentX > 0.0) {\n upperBound = currentT;\n }\n else {\n lowerBound = currentT;\n }\n } while (Math.abs(currentX) > subdivisionPrecision &&\n ++i < subdivisionMaxIterations);\n return currentT;\n}\n/*#__NO_SIDE_EFFECTS__*/\nfunction cubicBezier(mX1, mY1, mX2, mY2) {\n // If this is a linear gradient, return linear easing\n if (mX1 === mY1 && mX2 === mY2)\n return noop;\n const getTForX = (aX) => binarySubdivide(aX, 0, 1, mX1, mX2);\n // If animation is at start/end, return t without easing\n return (t) => t === 0 || t === 1 ? t : calcBezier(getTForX(t), mY1, mY2);\n}\n\nexport { cubicBezier };\n//# sourceMappingURL=cubic-bezier.mjs.map\n"],"names":["calcBezier","t","a1","a2","mX1","mY1","mX2","mY2","noop","getTForX","aX","x","lowerBound","upperBound","currentX","currentT","i","Math","abs","binarySubdivide"],"mappings":"oGAqBA,MAAMA,EAAaA,CAACC,EAAWC,EAAYC,OACpC,EAAM,EAAMA,EAAK,EAAMD,GAAMD,GAAK,EAAME,EAAK,EAAMD,IAAOD,EAAI,EAAMC,GACvED,sBAiCE,SACFG,EACAC,EACAC,EACAC,GAGA,GAAIH,IAAQC,GAAOC,IAAQC,EAAK,OAAOC,EAAAA,KAEvC,MAAMC,EAAYC,GArCtB,SACIC,EACAC,EACAC,EACAT,EACAE,GAEA,IAAIQ,EACAC,EACAC,EAAY,EAEhB,GACID,EAAWH,GAAcC,EAAaD,GAAc,EACpDE,EAAWd,EAAWe,EAAUX,EAAKE,GAAOK,EACxCG,EAAW,EACXD,EAAaE,EAEbH,EAAaG,QAGjBE,KAAKC,IAAIJ,GAvBY,QAwBnBE,EAvBuB,IA0B7B,OAAOD,CACX,CAYqCI,CAAgBT,EAAI,EAAG,EAAGN,EAAKE,GAGhE,OAAQL,GACE,IAANA,GAAiB,IAANA,EAAUA,EAAID,EAAWS,EAASR,GAAII,EAAKE,EAC9D"}
1
+ {"version":3,"file":"cubic-bezier.mjs.js","sources":["../../../../../../node_modules/motion-utils/dist/es/easing/cubic-bezier.mjs"],"sourcesContent":["import { noop } from '../noop.mjs';\n\n/*\n Bezier function generator\n This has been modified from Gaëtan Renaudeau's BezierEasing\n https://github.com/gre/bezier-easing/blob/master/src/index.js\n https://github.com/gre/bezier-easing/blob/master/LICENSE\n\n t is found for a given x with Newton-Raphson, safeguarded by a bisection\n bracket: whenever a Newton step would leave the bracket (near flat parts\n of the curve), it bisects instead. This converges to full precision in\n ~5 iterations on typical curves, so output is smooth rather than snapped\n to a fixed bisection grid. The slope is estimated with a forward\n difference, and the lookup table is omitted, to save bytes.\n\n x = 0 and x = 1 return exactly 0 and 1. x outside [0, 1] starts outside\n the bracket, so it bisects towards the nearer end and saturates to within\n ~1e-12 of 0 or 1.\n Usage\n const easeOut = cubicBezier(.17,.67,.83,.67);\n const x = easeOut(0.5); // returns 0.627...\n*/\n// Returns x(t) given t, x1, and x2, or y(t) given t, y1, and y2.\n// Bernstein form, so it is exactly 0 at t = 0 and exactly 1 at t = 1.\nconst calcBezier = (t, a1, a2) => t * (3 * (1 - t) * ((1 - t) * a1 + t * a2) + t * t);\n/*#__NO_SIDE_EFFECTS__*/\nfunction cubicBezier(mX1, mY1, mX2, mY2) {\n // If this is a linear gradient, return linear easing\n if (mX1 === mY1 && mX2 === mY2)\n return noop;\n return (x) => {\n let lowerBound = 0;\n let upperBound = 1;\n let t = x;\n for (let i = 0;; i++) {\n // If t is outside the bracket, because x is out of range or a\n // Newton step overshot where the slope is ~0, bisect instead.\n if (!(t >= lowerBound && t <= upperBound)) {\n t = (lowerBound + upperBound) / 2;\n }\n const currentX = calcBezier(t, mX1, mX2) - x;\n if (currentX * currentX < 1e-28 || i === 40)\n break;\n currentX > 0 ? (upperBound = t) : (lowerBound = t);\n // Newton-Raphson step, with dx/dt from a forward difference\n t -=\n (currentX * 1e-7) /\n (calcBezier(t + 1e-7, mX1, mX2) - x - currentX);\n }\n return calcBezier(t, mY1, mY2);\n };\n}\n\nexport { cubicBezier };\n//# sourceMappingURL=cubic-bezier.mjs.map\n"],"names":["calcBezier","t","a1","a2","mX1","mY1","mX2","mY2","noop","x","lowerBound","upperBound","i","currentX"],"mappings":"oGAyBA,MAAMA,EAAaA,CAACC,EAAWC,EAAYC,IACvCF,GAAK,GAAK,EAAIA,KAAO,EAAIA,GAAKC,EAAKD,EAAIE,GAAMF,EAAIA,uBAG/C,SACFG,EACAC,EACAC,EACAC,GAGA,OAAIH,IAAQC,GAAOC,IAAQC,EAAYC,EAAAA,KAE/BC,IACJ,IAAIC,EAAa,EACbC,EAAa,EACbV,EAAIQ,EAER,IAAK,IAAIG,EAAI,GAAKA,IAAK,CAGbX,GAAKS,GAAcT,GAAKU,IAC1BV,GAAKS,EAAaC,GAAc,GAGpC,MAAME,EAAWb,EAAWC,EAAGG,EAAKE,GAAOG,EAC3C,GAAII,EAAWA,EAAW,OAAe,KAAND,EAAU,MAC7CC,EAAW,EAAKF,EAAaV,EAAMS,EAAaT,EAGhDA,GACgB,KAAXY,GACAb,EAAWC,EAAI,KAAMG,EAAKE,GAAOG,EAAII,EAC9C,CAEA,OAAOb,EAAWC,EAAGI,EAAKE,GAElC"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../errors.mjs.js"),i=require("../../noop.mjs.js"),r=require("../anticipate.mjs.js"),n=require("../back.mjs.js"),t=require("../circ.mjs.js"),s=require("../cubic-bezier.mjs.js"),c=require("../ease.mjs.js"),a=require("./is-bezier-definition.mjs.js");const u={linear:i.noop,easeIn:c.easeIn,easeInOut:c.easeInOut,easeOut:c.easeOut,circIn:t.circIn,circInOut:t.circInOut,circOut:t.circOut,backIn:n.backIn,backInOut:n.backInOut,backOut:n.backOut,anticipate:r.anticipate};exports.easingDefinitionToFunction=i=>{if(a.isBezierDefinition(i)){e.invariant(4===i.length,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[r,n,t,c]=i;return s.cubicBezier(r,n,t,c)}return"string"==typeof i?(e.invariant(void 0!==u[i],`Invalid easing type '${i}'`,"invalid-easing-type"),u[i]):i};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../errors.mjs.js"),i=require("../../noop.mjs.js"),r=require("../anticipate.mjs.js"),n=require("../back.mjs.js"),s=require("../circ.mjs.js"),t=require("../cubic-bezier.mjs.js"),c=require("../ease.mjs.js"),u=require("./is-bezier-definition.mjs.js");const a={linear:i.noop,easeIn:c.easeIn,easeInOut:c.easeInOut,easeOut:c.easeOut,circIn:s.circIn,circInOut:s.circInOut,circOut:s.circOut,backIn:n.backIn,backInOut:n.backInOut,backOut:n.backOut,anticipate:r.anticipate};exports.easingDefinitionToFunction=i=>{if(u.isBezierDefinition(i)){"undefined"!=typeof process&&"production"!==process.env.NODE_ENV&&e.invariant(4===i.length,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[r,n,s,c]=i;return t.cubicBezier(r,n,s,c)}return"string"==typeof i?("undefined"!=typeof process&&"production"!==process.env.NODE_ENV&&e.invariant(void 0!==a[i],`Invalid easing type '${i}'`,"invalid-easing-type"),a[i]):i};
2
2
  //# sourceMappingURL=map.mjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"map.mjs.js","sources":["../../../../../../../node_modules/motion-utils/dist/es/easing/utils/map.mjs"],"sourcesContent":["import { invariant } from '../../errors.mjs';\nimport { noop } from '../../noop.mjs';\nimport { anticipate } from '../anticipate.mjs';\nimport { backOut, backInOut, backIn } from '../back.mjs';\nimport { circOut, circInOut, circIn } from '../circ.mjs';\nimport { cubicBezier } from '../cubic-bezier.mjs';\nimport { easeOut, easeInOut, easeIn } from '../ease.mjs';\nimport { isBezierDefinition } from './is-bezier-definition.mjs';\n\nconst easingLookup = {\n linear: noop,\n easeIn,\n easeInOut,\n easeOut,\n circIn,\n circInOut,\n circOut,\n backIn,\n backInOut,\n backOut,\n anticipate,\n};\nconst isValidEasing = (easing) => {\n return typeof easing === \"string\";\n};\nconst easingDefinitionToFunction = (definition) => {\n if (isBezierDefinition(definition)) {\n // If cubic bezier definition, create bezier curve\n invariant(definition.length === 4, `Cubic bezier arrays must contain four numerical values.`, \"cubic-bezier-length\");\n const [x1, y1, x2, y2] = definition;\n return cubicBezier(x1, y1, x2, y2);\n }\n else if (isValidEasing(definition)) {\n // Else lookup from table\n invariant(easingLookup[definition] !== undefined, `Invalid easing type '${definition}'`, \"invalid-easing-type\");\n return easingLookup[definition];\n }\n return definition;\n};\n\nexport { easingDefinitionToFunction };\n//# sourceMappingURL=map.mjs.map\n"],"names":["easingLookup","linear","noop","easeIn","easeInOut","easeOut","circIn","circInOut","circOut","backIn","backInOut","backOut","anticipate","definition","isBezierDefinition","invariant","length","x1","y1","x2","y2","cubicBezier","undefined"],"mappings":"6UAUA,MAAMA,EAAe,CACjBC,OAAQC,EAAIA,YACZC,EAAMA,iBACNC,EAASA,kBACTC,EAAOA,eACPC,EAAMA,iBACNC,EAASA,kBACTC,EAAOA,eACPC,EAAMA,iBACNC,EAASA,kBACTC,EAAOA,QACPC,WAAAA,EAAAA,+CAQAC,IAEA,GAAIC,EAAAA,mBAAmBD,GAAa,CAEhCE,EAASA,UACiB,IAAtBF,EAAWG,OACX,0DACA,uBAGJ,MAAOC,EAAIC,EAAIC,EAAIC,GAAMP,EACzB,OAAOQ,EAAWA,YAACJ,EAAIC,EAAIC,EAAIC,EACnC,CAAO,MAhBkB,iBAgBAP,GAErBE,iBACiCO,IAA7BtB,EAAaa,GACb,wBAAwBA,KACxB,uBAEGb,EAAaa,IAGjBA"}
1
+ {"version":3,"file":"map.mjs.js","sources":["../../../../../../../node_modules/motion-utils/dist/es/easing/utils/map.mjs"],"sourcesContent":["import { invariant } from '../../errors.mjs';\nimport { noop } from '../../noop.mjs';\nimport { anticipate } from '../anticipate.mjs';\nimport { backOut, backInOut, backIn } from '../back.mjs';\nimport { circOut, circInOut, circIn } from '../circ.mjs';\nimport { cubicBezier } from '../cubic-bezier.mjs';\nimport { easeOut, easeInOut, easeIn } from '../ease.mjs';\nimport { isBezierDefinition } from './is-bezier-definition.mjs';\n\nconst easingLookup = {\n linear: noop,\n easeIn,\n easeInOut,\n easeOut,\n circIn,\n circInOut,\n circOut,\n backIn,\n backInOut,\n backOut,\n anticipate,\n};\nconst isValidEasing = (easing) => {\n return typeof easing === \"string\";\n};\nconst easingDefinitionToFunction = (definition) => {\n if (isBezierDefinition(definition)) {\n // If cubic bezier definition, create bezier curve\n typeof process !== \"undefined\" &&\n process.env.NODE_ENV !== \"production\" &&\n invariant(definition.length === 4, `Cubic bezier arrays must contain four numerical values.`, \"cubic-bezier-length\");\n const [x1, y1, x2, y2] = definition;\n return cubicBezier(x1, y1, x2, y2);\n }\n else if (isValidEasing(definition)) {\n // Else lookup from table\n typeof process !== \"undefined\" &&\n process.env.NODE_ENV !== \"production\" &&\n invariant(easingLookup[definition] !== undefined, `Invalid easing type '${definition}'`, \"invalid-easing-type\");\n return easingLookup[definition];\n }\n return definition;\n};\n\nexport { easingDefinitionToFunction };\n//# sourceMappingURL=map.mjs.map\n"],"names":["easingLookup","linear","noop","easeIn","easeInOut","easeOut","circIn","circInOut","circOut","backIn","backInOut","backOut","anticipate","definition","isBezierDefinition","process","env","NODE_ENV","invariant","length","x1","y1","x2","y2","cubicBezier","undefined"],"mappings":"6UAUA,MAAMA,EAAe,CACjBC,OAAQC,EAAIA,YACZC,EAAMA,iBACNC,EAASA,kBACTC,EAAOA,eACPC,EAAMA,iBACNC,EAASA,kBACTC,EAAOA,eACPC,EAAMA,iBACNC,EAASA,kBACTC,EAAOA,QACPC,WAAAA,EAAAA,+CAQAC,IAEA,GAAIC,EAAAA,mBAAmBD,GAAa,CAEb,oBAAZE,SACsB,eAAzBA,QAAQC,IAAIC,UACZC,EAASA,UACiB,IAAtBL,EAAWM,OACX,0DACA,uBAGR,MAAOC,EAAIC,EAAIC,EAAIC,GAAMV,EACzB,OAAOW,EAAWA,YAACJ,EAAIC,EAAIC,EAAIC,EACnC,CAAO,MAlBkB,iBAkBAV,GAEF,oBAAZE,SACsB,eAAzBA,QAAQC,IAAIC,UACZC,iBACiCO,IAA7BzB,EAAaa,GACb,wBAAwBA,KACxB,uBAEDb,EAAaa,IAGjBA"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var r=require("./format-error-message.mjs.js");exports.warning=()=>{},exports.invariant=()=>{},"undefined"!=typeof process&&"production"!==process.env?.NODE_ENV&&(exports.warning=(e,o,s)=>{e||"undefined"==typeof console||console.warn(r.formatErrorMessage(o,s))},exports.invariant=(e,o,s)=>{if(!e)throw new Error(r.formatErrorMessage(o,s))});
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var r=require("./format-error-message.mjs.js");exports.warning=()=>{},exports.invariant=()=>{},"undefined"!=typeof process&&"production"!==process.env.NODE_ENV&&(exports.warning=(e,o,s)=>{e||"undefined"==typeof console||console.warn(r.formatErrorMessage(o,s))},exports.invariant=(e,o,s)=>{if(!e)throw new Error(r.formatErrorMessage(o,s))});
2
2
  //# sourceMappingURL=errors.mjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"errors.mjs.js","sources":["../../../../../node_modules/motion-utils/dist/es/errors.mjs"],"sourcesContent":["import { formatErrorMessage } from './format-error-message.mjs';\n\nlet warning = () => { };\nlet invariant = () => { };\nif (typeof process !== \"undefined\" &&\n process.env?.NODE_ENV !== \"production\") {\n warning = (check, message, errorCode) => {\n if (!check && typeof console !== \"undefined\") {\n console.warn(formatErrorMessage(message, errorCode));\n }\n };\n invariant = (check, message, errorCode) => {\n if (!check) {\n throw new Error(formatErrorMessage(message, errorCode));\n }\n };\n}\n\nexport { invariant, warning };\n//# sourceMappingURL=errors.mjs.map\n"],"names":["warning","invariant","process","env","NODE_ENV","check","message","errorCode","console","warn","formatErrorMessage","Error"],"mappings":"mHAQIA,QAAOA,QAAeA,OACtBC,QAASA,UAAeA,OAGL,oBAAZC,SACmB,eAA1BA,QAAQC,KAAKC,WAEbJ,QAAAA,QAAUA,CAACK,EAAOC,EAASC,KAClBF,GAA4B,oBAAZG,SACjBA,QAAQC,KAAKC,EAAAA,mBAAmBJ,EAASC,KAIjDN,QAAAA,UAAYA,CAACI,EAAOC,EAASC,KACzB,IAAKF,EACD,MAAM,IAAIM,MAAMD,EAAAA,mBAAmBJ,EAASC"}
1
+ {"version":3,"file":"errors.mjs.js","sources":["../../../../../node_modules/motion-utils/dist/es/errors.mjs"],"sourcesContent":["import { formatErrorMessage } from './format-error-message.mjs';\n\nlet warning = () => { };\nlet invariant = () => { };\nif (typeof process !== \"undefined\" && process.env.NODE_ENV !== \"production\") {\n warning = (check, message, errorCode) => {\n if (!check && typeof console !== \"undefined\") {\n console.warn(formatErrorMessage(message, errorCode));\n }\n };\n invariant = (check, message, errorCode) => {\n if (!check) {\n throw new Error(formatErrorMessage(message, errorCode));\n }\n };\n}\n\nexport { invariant, warning };\n//# sourceMappingURL=errors.mjs.map\n"],"names":["warning","invariant","process","env","NODE_ENV","check","message","errorCode","console","warn","formatErrorMessage","Error"],"mappings":"mHAQIA,QAAOA,QAAeA,OACtBC,QAASA,UAAeA,OAEL,oBAAZC,SAAoD,eAAzBA,QAAQC,IAAIC,WAC9CJ,QAAAA,QAAUA,CAACK,EAAOC,EAASC,KAClBF,GAA4B,oBAAZG,SACjBA,QAAQC,KAAKC,EAAAA,mBAAmBJ,EAASC,KAIjDN,QAAAA,UAAYA,CAACI,EAAOC,EAASC,KACzB,IAAKF,EACD,MAAM,IAAIM,MAAMD,EAAAA,mBAAmBJ,EAASC"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var s=require("./array.mjs.js");exports.SubscriptionManager=class{constructor(){this.subscriptions=[]}add(t){return s.addUniqueItem(this.subscriptions,t),()=>s.removeItem(this.subscriptions,t)}notify(s,t,i){const e=this.subscriptions.length;if(e)if(1===e)this.subscriptions[0](s,t,i);else for(let r=0;r<e;r++){const e=this.subscriptions[r];e&&e(s,t,i)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var s=require("./array.mjs.js");exports.SubscriptionManager=class{constructor(){this.subscriptions=[]}add(t){return s.addUniqueItem(this.subscriptions,t),()=>this.remove(t)}remove(t){s.removeItem(this.subscriptions,t)}notify(s,t,i){const e=this.subscriptions.length;if(e)if(1===e)this.subscriptions[0](s,t,i);else for(let r=0;r<e;r++){const e=this.subscriptions[r];e&&e(s,t,i)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}};
2
2
  //# sourceMappingURL=subscription-manager.mjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"subscription-manager.mjs.js","sources":["../../../../../node_modules/motion-utils/dist/es/subscription-manager.mjs"],"sourcesContent":["import { addUniqueItem, removeItem } from './array.mjs';\n\nclass SubscriptionManager {\n constructor() {\n this.subscriptions = [];\n }\n add(handler) {\n addUniqueItem(this.subscriptions, handler);\n return () => removeItem(this.subscriptions, handler);\n }\n notify(a, b, c) {\n const numSubscriptions = this.subscriptions.length;\n if (!numSubscriptions)\n return;\n if (numSubscriptions === 1) {\n /**\n * If there's only a single handler we can just call it without invoking a loop.\n */\n this.subscriptions[0](a, b, c);\n }\n else {\n for (let i = 0; i < numSubscriptions; i++) {\n /**\n * Check whether the handler exists before firing as it's possible\n * the subscriptions were modified during this loop running.\n */\n const handler = this.subscriptions[i];\n handler && handler(a, b, c);\n }\n }\n }\n getSize() {\n return this.subscriptions.length;\n }\n clear() {\n this.subscriptions.length = 0;\n }\n}\n\nexport { SubscriptionManager };\n//# sourceMappingURL=subscription-manager.mjs.map\n"],"names":["constructor","this","subscriptions","add","handler","addUniqueItem","removeItem","notify","a","b","c","numSubscriptions","length","i","getSize","clear"],"mappings":"sIAIAA,WAAAA,GACYC,KAAAC,cAA2B,EAwCvC,CAtCIC,GAAAA,CAAIC,GAEA,OADAC,EAAAA,cAAcJ,KAAKC,cAAeE,GAC3B,IAAME,EAAAA,WAAWL,KAAKC,cAAeE,EAChD,CAEAG,MAAAA,CACIC,EACAC,EACAC,GAEA,MAAMC,EAAmBV,KAAKC,cAAcU,OAE5C,GAAKD,EAEL,GAAyB,IAArBA,EAIAV,KAAKC,cAAc,GAAGM,EAAGC,EAAGC,QAE5B,IAAK,IAAIG,EAAI,EAAGA,EAAIF,EAAkBE,IAAK,CAKvC,MAAMT,EAAUH,KAAKC,cAAcW,GACnCT,GAAWA,EAAQI,EAAGC,EAAGC,EAC7B,CAER,CAEAI,OAAAA,GACI,OAAOb,KAAKC,cAAcU,MAC9B,CAEAG,KAAAA,GACId,KAAKC,cAAcU,OAAS,CAChC"}
1
+ {"version":3,"file":"subscription-manager.mjs.js","sources":["../../../../../node_modules/motion-utils/dist/es/subscription-manager.mjs"],"sourcesContent":["import { addUniqueItem, removeItem } from './array.mjs';\n\nclass SubscriptionManager {\n constructor() {\n this.subscriptions = [];\n }\n add(handler) {\n addUniqueItem(this.subscriptions, handler);\n return () => this.remove(handler);\n }\n remove(handler) {\n removeItem(this.subscriptions, handler);\n }\n notify(a, b, c) {\n const numSubscriptions = this.subscriptions.length;\n if (!numSubscriptions)\n return;\n if (numSubscriptions === 1) {\n /**\n * If there's only a single handler we can just call it without invoking a loop.\n */\n this.subscriptions[0](a, b, c);\n }\n else {\n for (let i = 0; i < numSubscriptions; i++) {\n /**\n * Check whether the handler exists before firing as it's possible\n * the subscriptions were modified during this loop running.\n */\n const handler = this.subscriptions[i];\n handler && handler(a, b, c);\n }\n }\n }\n getSize() {\n return this.subscriptions.length;\n }\n clear() {\n this.subscriptions.length = 0;\n }\n}\n\nexport { SubscriptionManager };\n//# sourceMappingURL=subscription-manager.mjs.map\n"],"names":["constructor","this","subscriptions","add","handler","addUniqueItem","remove","removeItem","notify","a","b","c","numSubscriptions","length","i","getSize","clear"],"mappings":"sIAIAA,WAAAA,GACYC,KAAAC,cAA2B,EA4CvC,CA1CIC,GAAAA,CAAIC,GAEA,OADAC,EAAAA,cAAcJ,KAAKC,cAAeE,GAC3B,IAAMH,KAAKK,OAAOF,EAC7B,CAEAE,MAAAA,CAAOF,GACHG,EAAAA,WAAWN,KAAKC,cAAeE,EACnC,CAEAI,MAAAA,CACIC,EACAC,EACAC,GAEA,MAAMC,EAAmBX,KAAKC,cAAcW,OAE5C,GAAKD,EAEL,GAAyB,IAArBA,EAIAX,KAAKC,cAAc,GAAGO,EAAGC,EAAGC,QAE5B,IAAK,IAAIG,EAAI,EAAGA,EAAIF,EAAkBE,IAAK,CAKvC,MAAMV,EAAUH,KAAKC,cAAcY,GACnCV,GAAWA,EAAQK,EAAGC,EAAGC,EAC7B,CAER,CAEAI,OAAAA,GACI,OAAOd,KAAKC,cAAcW,MAC9B,CAEAG,KAAAA,GACIf,KAAKC,cAAcW,OAAS,CAChC"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),require("../../../@babel/runtime/helpers/defineProperty.js");var e=require("../../../@babel/runtime/helpers/classCallCheck.js"),s=require("../../../@babel/runtime/helpers/createClass.js"),t=require("react").createContext(),r=function(){function t(){e.default(this,t),this.usedNamespaces={}}return s.default(t,[{key:"addUsedNamespaces",value:function(e){var s=this;e.forEach(function(e){s.usedNamespaces[e]||(s.usedNamespaces[e]=!0)})}},{key:"getUsedNamespaces",value:function(){return Object.keys(this.usedNamespaces)}}]),t}();exports.I18nContext=t,exports.ReportNamespaces=r;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const e=require("react").createContext();exports.I18nContext=e,exports.ReportNamespaces=class{constructor(){this.usedNamespaces={}}addUsedNamespaces(e){e.forEach(e=>{this.usedNamespaces[e]||(this.usedNamespaces[e]=!0)})}getUsedNamespaces(){return Object.keys(this.usedNamespaces)}};
2
2
  //# sourceMappingURL=context.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"context.js","sources":["../../../../../node_modules/react-i18next/dist/es/context.js"],"sourcesContent":["import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _classCallCheck from \"@babel/runtime/helpers/classCallCheck\";\nimport _createClass from \"@babel/runtime/helpers/createClass\";\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nimport { createContext } from 'react';\nimport { getDefaults, setDefaults } from './defaults.js';\nimport { getI18n, setI18n } from './i18nInstance.js';\nimport { initReactI18next } from './initReactI18next.js';\nexport { getDefaults, setDefaults, getI18n, setI18n, initReactI18next };\nexport var I18nContext = createContext();\nexport var ReportNamespaces = function () {\n function ReportNamespaces() {\n _classCallCheck(this, ReportNamespaces);\n\n this.usedNamespaces = {};\n }\n\n _createClass(ReportNamespaces, [{\n key: \"addUsedNamespaces\",\n value: function addUsedNamespaces(namespaces) {\n var _this = this;\n\n namespaces.forEach(function (ns) {\n if (!_this.usedNamespaces[ns]) _this.usedNamespaces[ns] = true;\n });\n }\n }, {\n key: \"getUsedNamespaces\",\n value: function getUsedNamespaces() {\n return Object.keys(this.usedNamespaces);\n }\n }]);\n\n return ReportNamespaces;\n}();\nexport function composeInitialProps(ForComponent) {\n return function (ctx) {\n return new Promise(function (resolve) {\n var i18nInitialProps = getInitialProps();\n\n if (ForComponent.getInitialProps) {\n ForComponent.getInitialProps(ctx).then(function (componentsInitialProps) {\n resolve(_objectSpread(_objectSpread({}, componentsInitialProps), i18nInitialProps));\n });\n } else {\n resolve(i18nInitialProps);\n }\n });\n };\n}\nexport function getInitialProps() {\n var i18n = getI18n();\n var namespaces = i18n.reportNamespaces ? i18n.reportNamespaces.getUsedNamespaces() : [];\n var ret = {};\n var initialI18nStore = {};\n i18n.languages.forEach(function (l) {\n initialI18nStore[l] = {};\n namespaces.forEach(function (ns) {\n initialI18nStore[l][ns] = i18n.getResourceBundle(l, ns) || {};\n });\n });\n ret.initialI18nStore = initialI18nStore;\n ret.initialLanguage = i18n.language;\n return ret;\n}"],"names":["I18nContext","createContext","ReportNamespaces","_classCallCheck","this","usedNamespaces","_createClass","key","value","namespaces","_this","forEach","ns","Object","keys"],"mappings":"gQAaWA,mBAAcC,gBACdC,EAAmB,WAC5B,SAASA,IACPC,UAAgBC,KAAMF,GAEtBE,KAAKC,eAAiB,EACxB,CAkBA,OAhBAC,EAAY,QAACJ,EAAkB,CAAC,CAC9BK,IAAK,oBACLC,MAAO,SAA2BC,GAChC,IAAIC,EAAQN,KAEZK,EAAWE,QAAQ,SAAUC,GACtBF,EAAML,eAAeO,KAAKF,EAAML,eAAeO,IAAM,EAC5D,EACF,GACC,CACDL,IAAK,oBACLC,MAAO,WACL,OAAOK,OAAOC,KAAKV,KAAKC,eAC1B,KAGKH,CACT,CAxB8B"}
1
+ {"version":3,"file":"context.js","sources":["../../../../../node_modules/react-i18next/dist/es/context.js"],"sourcesContent":["import { createContext } from 'react';\nimport { getDefaults, setDefaults } from './defaults.js';\nimport { getI18n, setI18n } from './i18nInstance.js';\nimport { initReactI18next } from './initReactI18next.js';\nexport { getDefaults, setDefaults, getI18n, setI18n, initReactI18next };\nexport const I18nContext = createContext();\nexport class ReportNamespaces {\n constructor() {\n this.usedNamespaces = {};\n }\n addUsedNamespaces(namespaces) {\n namespaces.forEach(ns => {\n if (!this.usedNamespaces[ns]) this.usedNamespaces[ns] = true;\n });\n }\n getUsedNamespaces() {\n return Object.keys(this.usedNamespaces);\n }\n}\nexport const composeInitialProps = ForComponent => async ctx => {\n const componentsInitialProps = (await ForComponent.getInitialProps?.(ctx)) ?? {};\n const i18nInitialProps = getInitialProps();\n return {\n ...componentsInitialProps,\n ...i18nInitialProps\n };\n};\nexport const getInitialProps = () => {\n const i18n = getI18n();\n if (!i18n) {\n console.warn('react-i18next:: getInitialProps: You will need to pass in an i18next instance by using initReactI18next');\n return {};\n }\n const namespaces = i18n.reportNamespaces?.getUsedNamespaces() ?? [];\n const ret = {};\n const initialI18nStore = {};\n i18n.languages.forEach(l => {\n initialI18nStore[l] = {};\n namespaces.forEach(ns => {\n initialI18nStore[l][ns] = i18n.getResourceBundle(l, ns) || {};\n });\n });\n ret.initialI18nStore = initialI18nStore;\n ret.initialLanguage = i18n.language;\n return ret;\n};"],"names":["I18nContext","createContext","constructor","this","usedNamespaces","addUsedNamespaces","namespaces","forEach","ns","getUsedNamespaces","Object","keys"],"mappings":"oEAKaA,MAAAA,mBAAcC,+DACpB,MACLC,WAAAA,GACEC,KAAKC,eAAiB,EACxB,CACAC,iBAAAA,CAAkBC,GAChBA,EAAWC,QAAQC,IACZL,KAAKC,eAAeI,KAAKL,KAAKC,eAAeI,IAAM,IAE5D,CACAC,iBAAAA,GACE,OAAOC,OAAOC,KAAKR,KAAKC,eAC1B"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../../@babel/runtime/helpers/defineProperty.js");function r(e,r){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);r&&(n=n.filter(function(r){return Object.getOwnPropertyDescriptor(e,r).enumerable})),t.push.apply(t,n)}return t}function t(t){for(var n=1;n<arguments.length;n++){var o=null!=arguments[n]?arguments[n]:{};n%2?r(Object(o),!0).forEach(function(r){e.default(t,r,o[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(o)):r(Object(o)).forEach(function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(o,e))})}return t}var n={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:require("./unescape.js").unescape};exports.getDefaults=function(){return n},exports.setDefaults=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};n=t(t({},n),e)};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});let e={bindI18n:"languageChanged",bindI18nStore:"",transEmptyNodeValue:"",transSupportBasicHtmlNodes:!0,transWrapTextNodes:"",transKeepBasicHtmlNodesFor:["br","strong","i","p"],useSuspense:!0,unescape:require("./unescape.js").unescape,transDefaultProps:void 0};exports.getDefaults=()=>e;
2
2
  //# sourceMappingURL=defaults.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"defaults.js","sources":["../../../../../node_modules/react-i18next/dist/es/defaults.js"],"sourcesContent":["import _defineProperty from \"@babel/runtime/helpers/defineProperty\";\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nimport { unescape } from './unescape.js';\nvar defaultOptions = {\n bindI18n: 'languageChanged',\n bindI18nStore: '',\n transEmptyNodeValue: '',\n transSupportBasicHtmlNodes: true,\n transWrapTextNodes: '',\n transKeepBasicHtmlNodesFor: ['br', 'strong', 'i', 'p'],\n useSuspense: true,\n unescape: unescape\n};\nexport function setDefaults() {\n var options = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n defaultOptions = _objectSpread(_objectSpread({}, defaultOptions), options);\n}\nexport function getDefaults() {\n return defaultOptions;\n}"],"names":["ownKeys","object","enumerableOnly","keys","Object","getOwnPropertySymbols","symbols","filter","sym","getOwnPropertyDescriptor","enumerable","push","apply","_objectSpread","target","i","arguments","length","source","forEach","key","_defineProperty","getOwnPropertyDescriptors","defineProperties","defineProperty","defaultOptions","bindI18n","bindI18nStore","transEmptyNodeValue","transSupportBasicHtmlNodes","transWrapTextNodes","transKeepBasicHtmlNodesFor","useSuspense","unescape","options","undefined"],"mappings":"uIAEA,SAASA,EAAQC,EAAQC,GAAkB,IAAIC,EAAOC,OAAOD,KAAKF,GAAS,GAAIG,OAAOC,sBAAuB,CAAE,IAAIC,EAAUF,OAAOC,sBAAsBJ,GAAaC,IAAkBI,EAAUA,EAAQC,OAAO,SAAUC,GAAO,OAAOJ,OAAOK,yBAAyBR,EAAQO,GAAKE,UAAY,IAAMP,EAAKQ,KAAKC,MAAMT,EAAMG,EAAU,CAAE,OAAOH,CAAM,CAExV,SAASU,EAAcC,GAAU,IAAK,IAAIC,EAAI,EAAGA,EAAIC,UAAUC,OAAQF,IAAK,CAAE,IAAIG,EAAyB,MAAhBF,UAAUD,GAAaC,UAAUD,GAAK,GAAQA,EAAI,EAAKf,EAAQI,OAAOc,IAAS,GAAMC,QAAQ,SAAUC,GAAOC,EAAAA,QAAgBP,EAAQM,EAAKF,EAAOE,GAAO,GAAehB,OAAOkB,0BAA6BlB,OAAOmB,iBAAiBT,EAAQV,OAAOkB,0BAA0BJ,IAAmBlB,EAAQI,OAAOc,IAASC,QAAQ,SAAUC,GAAOhB,OAAOoB,eAAeV,EAAQM,EAAKhB,OAAOK,yBAAyBS,EAAQE,GAAO,EAAM,CAAE,OAAON,CAAQ,CAGrhB,IAAIW,EAAiB,CACnBC,SAAU,kBACVC,cAAe,GACfC,oBAAqB,GACrBC,4BAA4B,EAC5BC,mBAAoB,GACpBC,2BAA4B,CAAC,KAAM,SAAU,IAAK,KAClDC,aAAa,EACbC,kCAAUA,8BAML,WACL,OAAOR,CACT,sBANO,WACL,IAAIS,EAAUlB,UAAUC,OAAS,QAAsBkB,IAAjBnB,UAAU,GAAmBA,UAAU,GAAK,CAAA,EAClFS,EAAiBZ,EAAcA,EAAc,CAAE,EAAEY,GAAiBS,EACpE"}
1
+ {"version":3,"file":"defaults.js","sources":["../../../../../node_modules/react-i18next/dist/es/defaults.js"],"sourcesContent":["import { unescape } from './unescape.js';\nlet defaultOptions = {\n bindI18n: 'languageChanged',\n bindI18nStore: '',\n transEmptyNodeValue: '',\n transSupportBasicHtmlNodes: true,\n transWrapTextNodes: '',\n transKeepBasicHtmlNodesFor: ['br', 'strong', 'i', 'p'],\n useSuspense: true,\n unescape,\n transDefaultProps: undefined\n};\nexport const setDefaults = (options = {}) => {\n defaultOptions = {\n ...defaultOptions,\n ...options\n };\n};\nexport const getDefaults = () => defaultOptions;"],"names":["defaultOptions","bindI18n","bindI18nStore","transEmptyNodeValue","transSupportBasicHtmlNodes","transWrapTextNodes","transKeepBasicHtmlNodesFor","useSuspense","unescape","transDefaultProps","undefined","getDefaults"],"mappings":"oEACA,IAAIA,EAAiB,CACnBC,SAAU,kBACVC,cAAe,GACfC,oBAAqB,GACrBC,4BAA4B,EAC5BC,mBAAoB,GACpBC,2BAA4B,CAAC,KAAM,SAAU,IAAK,KAClDC,aAAa,oCACLC,SACRC,uBAAmBC,uBAQMC,IAAMX"}
@@ -1,2 +1,2 @@
1
- "use strict";var e;Object.defineProperty(exports,"__esModule",{value:!0}),exports.getI18n=function(){return e},exports.setI18n=function(t){e=t};
1
+ "use strict";let e;Object.defineProperty(exports,"__esModule",{value:!0});exports.getI18n=()=>e,exports.setI18n=t=>{e=t};
2
2
  //# sourceMappingURL=i18nInstance.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"i18nInstance.js","sources":["../../../../../node_modules/react-i18next/dist/es/i18nInstance.js"],"sourcesContent":["var i18nInstance;\nexport function setI18n(instance) {\n i18nInstance = instance;\n}\nexport function getI18n() {\n return i18nInstance;\n}"],"names":["i18nInstance","instance"],"mappings":"aAAA,IAAIA,yEAIG,WACL,OAAOA,CACT,kBALO,SAAiBC,GACtBD,EAAeC,CACjB"}
1
+ {"version":3,"file":"i18nInstance.js","sources":["../../../../../node_modules/react-i18next/dist/es/i18nInstance.js"],"sourcesContent":["let i18nInstance;\nexport const setI18n = instance => {\n i18nInstance = instance;\n};\nexport const getI18n = () => i18nInstance;"],"names":["i18nInstance","getI18n","instance"],"mappings":"aAAA,IAAIA,yEAImBC,IAAMD,kBAHNE,IACrBF,EAAeE"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./defaults.js"),t=require("./i18nInstance.js"),r={type:"3rdParty",init:function(r){e.setDefaults(r.options.react),t.setI18n(r)}};exports.initReactI18next=r;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./i18nInstance.js");const t={type:"3rdParty",init(t){e.setI18n(t)}};exports.initReactI18next=t;
2
2
  //# sourceMappingURL=initReactI18next.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"initReactI18next.js","sources":["../../../../../node_modules/react-i18next/dist/es/initReactI18next.js"],"sourcesContent":["import { setDefaults } from './defaults.js';\nimport { setI18n } from './i18nInstance.js';\nexport var initReactI18next = {\n type: '3rdParty',\n init: function init(instance) {\n setDefaults(instance.options.react);\n setI18n(instance);\n }\n};"],"names":["initReactI18next","type","init","instance","setDefaults","options","react","setI18n"],"mappings":"kIAEWA,EAAmB,CAC5BC,KAAM,WACNC,KAAM,SAAcC,GAClBC,EAAAA,YAAYD,EAASE,QAAQC,OAC7BC,EAAOA,QAACJ,EACV"}
1
+ {"version":3,"file":"initReactI18next.js","sources":["../../../../../node_modules/react-i18next/dist/es/initReactI18next.js"],"sourcesContent":["import { setI18n } from './i18nInstance.js';\nexport const initReactI18next = {\n type: '3rdParty',\n init(instance) {\n setI18n(instance);\n }\n};"],"names":["initReactI18next","type","init","instance","setI18n"],"mappings":"uGACO,MAAMA,EAAmB,CAC9BC,KAAM,WACNC,IAAAA,CAAKC,GACHC,EAAOA,QAACD,EACV"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,t={"&amp;":"&","&#38;":"&","&lt;":"<","&#60;":"<","&gt;":">","&#62;":">","&apos;":"'","&#39;":"'","&quot;":'"',"&#34;":'"',"&nbsp;":" ","&#160;":" ","&copy;":"©","&#169;":"©","&reg;":"®","&#174;":"®","&hellip;":"…","&#8230;":"…","&#x2F;":"/","&#47;":"/"},p=function(e){return t[e]};exports.unescape=function(t){return t.replace(e,p)};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const e=/&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g,p={"&amp;":"&","&#38;":"&","&lt;":"<","&#60;":"<","&gt;":">","&#62;":">","&apos;":"'","&#39;":"'","&quot;":'"',"&#34;":'"',"&nbsp;":" ","&#160;":" ","&copy;":"©","&#169;":"©","&reg;":"®","&#174;":"®","&hellip;":"…","&#8230;":"…","&#x2F;":"/","&#47;":"/"},t=e=>p[e];exports.unescape=p=>p.replace(e,t);
2
2
  //# sourceMappingURL=unescape.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"unescape.js","sources":["../../../../../node_modules/react-i18next/dist/es/unescape.js"],"sourcesContent":["var matchHtmlEntity = /&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g;\nvar htmlEntities = {\n '&amp;': '&',\n '&#38;': '&',\n '&lt;': '<',\n '&#60;': '<',\n '&gt;': '>',\n '&#62;': '>',\n '&apos;': \"'\",\n '&#39;': \"'\",\n '&quot;': '\"',\n '&#34;': '\"',\n '&nbsp;': ' ',\n '&#160;': ' ',\n '&copy;': '©',\n '&#169;': '©',\n '&reg;': '®',\n '&#174;': '®',\n '&hellip;': '…',\n '&#8230;': '…',\n '&#x2F;': '/',\n '&#47;': '/'\n};\n\nvar unescapeHtmlEntity = function unescapeHtmlEntity(m) {\n return htmlEntities[m];\n};\n\nexport var unescape = function unescape(text) {\n return text.replace(matchHtmlEntity, unescapeHtmlEntity);\n};"],"names":["matchHtmlEntity","htmlEntities","unescapeHtmlEntity","m","text","replace"],"mappings":"oEAAA,IAAIA,EAAkB,oGAClBC,EAAe,CACjB,QAAS,IACT,QAAS,IACT,OAAQ,IACR,QAAS,IACT,OAAQ,IACR,QAAS,IACT,SAAU,IACV,QAAS,IACT,SAAU,IACV,QAAS,IACT,SAAU,IACV,SAAU,IACV,SAAU,IACV,SAAU,IACV,QAAS,IACT,SAAU,IACV,WAAY,IACZ,UAAW,IACX,SAAU,IACV,QAAS,KAGPC,EAAqB,SAA4BC,GACnD,OAAOF,EAAaE,EACtB,mBAEsB,SAAkBC,GACtC,OAAOA,EAAKC,QAAQL,EAAiBE,EACvC"}
1
+ {"version":3,"file":"unescape.js","sources":["../../../../../node_modules/react-i18next/dist/es/unescape.js"],"sourcesContent":["const matchHtmlEntity = /&(?:amp|#38|lt|#60|gt|#62|apos|#39|quot|#34|nbsp|#160|copy|#169|reg|#174|hellip|#8230|#x2F|#47);/g;\nconst htmlEntities = {\n '&amp;': '&',\n '&#38;': '&',\n '&lt;': '<',\n '&#60;': '<',\n '&gt;': '>',\n '&#62;': '>',\n '&apos;': \"'\",\n '&#39;': \"'\",\n '&quot;': '\"',\n '&#34;': '\"',\n '&nbsp;': '\\u00A0',\n '&#160;': '\\u00A0',\n '&copy;': '©',\n '&#169;': '©',\n '&reg;': '®',\n '&#174;': '®',\n '&hellip;': '…',\n '&#8230;': '…',\n '&#x2F;': '/',\n '&#47;': '/'\n};\nconst unescapeHtmlEntity = m => htmlEntities[m];\nexport const unescape = text => text.replace(matchHtmlEntity, unescapeHtmlEntity);"],"names":["matchHtmlEntity","htmlEntities","unescapeHtmlEntity","m","text","replace"],"mappings":"oEAAA,MAAMA,EAAkB,oGAClBC,EAAe,CACnB,QAAS,IACT,QAAS,IACT,OAAQ,IACR,QAAS,IACT,OAAQ,IACR,QAAS,IACT,SAAU,IACV,QAAS,IACT,SAAU,IACV,QAAS,IACT,SAAU,IACV,SAAU,IACV,SAAU,IACV,SAAU,IACV,QAAS,IACT,SAAU,IACV,WAAY,IACZ,UAAW,IACX,SAAU,IACV,QAAS,KAELC,EAAqBC,GAAKF,EAAaE,oBACrBC,GAAQA,EAAKC,QAAQL,EAAiBE"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("../../../@babel/runtime/helpers/slicedToArray.js"),t=require("../../../@babel/runtime/helpers/defineProperty.js"),r=require("../../../@babel/runtime/helpers/typeof.js"),n=require("react"),o=require("./context.js"),a=require("./utils.js"),u=require("./defaults.js"),i=require("./i18nInstance.js");function s(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),r.push.apply(r,n)}return r}function c(e){for(var r=1;r<arguments.length;r++){var n=null!=arguments[r]?arguments[r]:{};r%2?s(Object(n),!0).forEach(function(r){t.default(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):s(Object(n)).forEach(function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))})}return e}exports.useTranslation=function(t){var s=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},f=s.i18n,l=n.useContext(o.I18nContext)||{},p=l.i18n,d=l.defaultNS,g=f||p||i.getI18n();if(g&&!g.reportNamespaces&&(g.reportNamespaces=new o.ReportNamespaces),!g){a.warnOnce("You will need to pass in an i18next instance by using initReactI18next");var y=function(e,t){return"string"==typeof t?t:t&&"object"===r.default(t)&&"string"==typeof t.defaultValue?t.defaultValue:Array.isArray(e)?e[e.length-1]:e},b=[y,{},!1];return b.t=y,b.i18n={},b.ready=!1,b}g.options.react&&void 0!==g.options.react.wait&&a.warnOnce("It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.");var j=c(c(c({},u.getDefaults()),g.options.react),s),O=j.useSuspense,m=j.keyPrefix,v=t||d||g.options&&g.options.defaultNS;v="string"==typeof v?[v]:v||["translation"],g.reportNamespaces.addUsedNamespaces&&g.reportNamespaces.addUsedNamespaces(v);var h=(g.isInitialized||g.initializedStoreOnce)&&v.every(function(e){return a.hasLoadedNamespace(e,g,j)});function w(){return g.getFixedT(s.lng||null,"fallback"===j.nsMode?v:v[0],m)}var N=n.useState(w),P=e.default(N,2),x=P[0],S=P[1],q=v.join();s.lng&&(q="".concat(s.lng).concat(q));var I,E,D,R=(I=q,D=n.useRef(),n.useEffect(function(){D.current=E?D.current:I},[I,E]),D.current),k=n.useRef(!0);n.useEffect(function(){var e=j.bindI18n,t=j.bindI18nStore;function r(){k.current&&S(w)}return k.current=!0,h||O||(s.lng?a.loadLanguages(g,s.lng,v,function(){k.current&&S(w)}):a.loadNamespaces(g,v,function(){k.current&&S(w)})),h&&R&&R!==q&&k.current&&S(w),e&&g&&g.on(e,r),t&&g&&g.store.on(t,r),function(){k.current=!1,e&&g&&e.split(" ").forEach(function(e){return g.off(e,r)}),t&&g&&t.split(" ").forEach(function(e){return g.store.off(e,r)})}},[g,q]);var A=n.useRef(!0);n.useEffect(function(){k.current&&!A.current&&S(w),A.current=!1},[g,m]);var L=[x,g,h];if(L.t=x,L.i18n=g,L.ready=h,h)return L;if(!h&&!O)return L;throw new Promise(function(e){s.lng?a.loadLanguages(g,s.lng,v,function(){return e()}):a.loadNamespaces(g,v,function(){return e()})})};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react"),n=require("../../../i18next/dist/esm/i18next.js"),t=require("./context.js"),s=require("./utils.js"),r=require("./defaults.js"),a=require("./i18nInstance.js");const i=e=>new Proxy(e,{get:(e,n)=>"__original"===n?e:Reflect.get(e,n)}),o={t:(e,n)=>{if(s.isString(n))return n;if(s.isObject(n)&&s.isString(n.defaultValue))return n.defaultValue;if("function"==typeof e)return"";if(Array.isArray(e)){const n=e[e.length-1];return"function"==typeof n?"":n}return e},ready:!1},u=()=>()=>{};exports.useTranslation=(l,c={})=>{const{i18n:g}=c,{i18n:d,defaultNS:f}=e.useContext(t.I18nContext)||{},p=g||d||a.getI18n();p&&!p.reportNamespaces&&(p.reportNamespaces=new t.ReportNamespaces),p||s.warnOnce(p,"NO_I18NEXT_INSTANCE","useTranslation: You will need to pass in an i18next instance by using initReactI18next or by passing it via props or context. In monorepo setups, make sure there is only one instance of react-i18next.");const y=e.useMemo(()=>({...r.getDefaults(),...p?.options?.react,...c}),[p,c]),{useSuspense:S,keyPrefix:m,bindI18n:x,bindI18nStore:b}=y,N=l||f||p?.options?.defaultNS,I=s.isString(N)?[N]:N||["translation"],h=JSON.stringify(I),w=e.useMemo(()=>I,[h]);p?.reportNamespaces?.addUsedNamespaces?.(w);const k=e.useRef(0),v=e.useCallback(e=>{if(!p)return u;return((e,{bindI18n:n,bindI18nStore:t},s)=>(n&&e.on(n,s),t&&e.store.on(t,s),()=>{n&&e.off(n,s),t&&e.store.off(t,s)}))(p,{bindI18n:x,bindI18nStore:b},()=>{k.current+=1,e()})},[p,x,b]),E=e.useRef(),_=e.useCallback(()=>{if(!p)return o;const e=!(!p.isInitialized&&!p.initializedStoreOnce)&&w.every(e=>s.hasLoadedNamespace(e,p,y)),t=c.lng||p.language,r=k.current,a="function"==typeof m?n.keyFromSelector(m,{...p.options,ns:w}):m,i=E.current;if(i&&i.i18n===p&&i.ready===e&&i.lng===t&&i.namespaces===w&&i.keyPrefix===a&&i.revision===r)return i;const u={t:p.getFixedT(t,"fallback"===y.nsMode?w:w[0],m,{scopeNs:w}),i18n:p,ready:e,lng:t,namespaces:w,keyPrefix:a,revision:r};return E.current=u,u},[p,w,m,y,c.lng]),[O,j]=e.useState(0);let R,{t:T,ready:L}=e.useSyncExternalStore(v,_,_);p&&S&&!L&&(R=new Promise(e=>{const n=()=>e();c.lng?s.loadLanguages(p,c.lng,w,n):s.loadNamespaces(p,w,n)}),({t:T,ready:L}=_())),e.useEffect(()=>{if(p&&!L&&!S){const e=()=>j(e=>e+1);c.lng?s.loadLanguages(p,c.lng,w,e):s.loadNamespaces(p,w,e)}},[p,c.lng,w,L,S,O]);const P=p||{},q=e.useRef(null),A=e.useMemo(()=>{const e=P,n=`${(t=e).language}|${t.resolvedLanguage}|${t.languages?.join(",")}`;var t;q.current?.original===e&&q.current.lang===n||(q.current={original:e,lang:n,wrapper:i(e)});const r=q.current.wrapper,a=L||S?T:(...e)=>(s.warnOnce(p,"USE_T_BEFORE_READY","useTranslation: t was called before ready. When using useSuspense: false, make sure to check the ready flag before using t."),T(...e)),o=[a,r,L];return o.t=a,o.i18n=r,o.ready=L,o},[T,P,L,P.resolvedLanguage,P.language,P.languages]);if(p&&S&&!L)throw s.inDevelopment()&&s.warnOnce(p,"SUSPENDED_WHILE_LOADING","useTranslation: suspended while translations are loading (useSuspense is true by default). Add a <Suspense> boundary above this component, or set react.useSuspense: false in the i18next init options. https://react.i18next.com/latest/usetranslation-hook"),R;return A};
2
2
  //# sourceMappingURL=useTranslation.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"useTranslation.js","sources":["../../../../../node_modules/react-i18next/dist/es/useTranslation.js"],"sourcesContent":["import _slicedToArray from \"@babel/runtime/helpers/slicedToArray\";\nimport _defineProperty from \"@babel/runtime/helpers/defineProperty\";\nimport _typeof from \"@babel/runtime/helpers/typeof\";\n\nfunction ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }\n\nfunction _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }\n\nimport { useState, useEffect, useContext, useRef } from 'react';\nimport { getI18n, getDefaults, ReportNamespaces, I18nContext } from './context.js';\nimport { warnOnce, loadNamespaces, loadLanguages, hasLoadedNamespace } from './utils.js';\n\nvar usePrevious = function usePrevious(value, ignore) {\n var ref = useRef();\n useEffect(function () {\n ref.current = ignore ? ref.current : value;\n }, [value, ignore]);\n return ref.current;\n};\n\nexport function useTranslation(ns) {\n var props = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n var i18nFromProps = props.i18n;\n\n var _ref = useContext(I18nContext) || {},\n i18nFromContext = _ref.i18n,\n defaultNSFromContext = _ref.defaultNS;\n\n var i18n = i18nFromProps || i18nFromContext || getI18n();\n if (i18n && !i18n.reportNamespaces) i18n.reportNamespaces = new ReportNamespaces();\n\n if (!i18n) {\n warnOnce('You will need to pass in an i18next instance by using initReactI18next');\n\n var notReadyT = function notReadyT(k, optsOrDefaultValue) {\n if (typeof optsOrDefaultValue === 'string') return optsOrDefaultValue;\n if (optsOrDefaultValue && _typeof(optsOrDefaultValue) === 'object' && typeof optsOrDefaultValue.defaultValue === 'string') return optsOrDefaultValue.defaultValue;\n return Array.isArray(k) ? k[k.length - 1] : k;\n };\n\n var retNotReady = [notReadyT, {}, false];\n retNotReady.t = notReadyT;\n retNotReady.i18n = {};\n retNotReady.ready = false;\n return retNotReady;\n }\n\n if (i18n.options.react && i18n.options.react.wait !== undefined) warnOnce('It seems you are still using the old wait option, you may migrate to the new useSuspense behaviour.');\n\n var i18nOptions = _objectSpread(_objectSpread(_objectSpread({}, getDefaults()), i18n.options.react), props);\n\n var useSuspense = i18nOptions.useSuspense,\n keyPrefix = i18nOptions.keyPrefix;\n var namespaces = ns || defaultNSFromContext || i18n.options && i18n.options.defaultNS;\n namespaces = typeof namespaces === 'string' ? [namespaces] : namespaces || ['translation'];\n if (i18n.reportNamespaces.addUsedNamespaces) i18n.reportNamespaces.addUsedNamespaces(namespaces);\n var ready = (i18n.isInitialized || i18n.initializedStoreOnce) && namespaces.every(function (n) {\n return hasLoadedNamespace(n, i18n, i18nOptions);\n });\n\n function getT() {\n return i18n.getFixedT(props.lng || null, i18nOptions.nsMode === 'fallback' ? namespaces : namespaces[0], keyPrefix);\n }\n\n var _useState = useState(getT),\n _useState2 = _slicedToArray(_useState, 2),\n t = _useState2[0],\n setT = _useState2[1];\n\n var joinedNS = namespaces.join();\n if (props.lng) joinedNS = \"\".concat(props.lng).concat(joinedNS);\n var previousJoinedNS = usePrevious(joinedNS);\n var isMounted = useRef(true);\n useEffect(function () {\n var bindI18n = i18nOptions.bindI18n,\n bindI18nStore = i18nOptions.bindI18nStore;\n isMounted.current = true;\n\n if (!ready && !useSuspense) {\n if (props.lng) {\n loadLanguages(i18n, props.lng, namespaces, function () {\n if (isMounted.current) setT(getT);\n });\n } else {\n loadNamespaces(i18n, namespaces, function () {\n if (isMounted.current) setT(getT);\n });\n }\n }\n\n if (ready && previousJoinedNS && previousJoinedNS !== joinedNS && isMounted.current) {\n setT(getT);\n }\n\n function boundReset() {\n if (isMounted.current) setT(getT);\n }\n\n if (bindI18n && i18n) i18n.on(bindI18n, boundReset);\n if (bindI18nStore && i18n) i18n.store.on(bindI18nStore, boundReset);\n return function () {\n isMounted.current = false;\n if (bindI18n && i18n) bindI18n.split(' ').forEach(function (e) {\n return i18n.off(e, boundReset);\n });\n if (bindI18nStore && i18n) bindI18nStore.split(' ').forEach(function (e) {\n return i18n.store.off(e, boundReset);\n });\n };\n }, [i18n, joinedNS]);\n var isInitial = useRef(true);\n useEffect(function () {\n if (isMounted.current && !isInitial.current) {\n setT(getT);\n }\n\n isInitial.current = false;\n }, [i18n, keyPrefix]);\n var ret = [t, i18n, ready];\n ret.t = t;\n ret.i18n = i18n;\n ret.ready = ready;\n if (ready) return ret;\n if (!ready && !useSuspense) return ret;\n throw new Promise(function (resolve) {\n if (props.lng) {\n loadLanguages(i18n, props.lng, namespaces, function () {\n return resolve();\n });\n } else {\n loadNamespaces(i18n, namespaces, function () {\n return resolve();\n });\n }\n });\n}"],"names":["ownKeys","object","enumerableOnly","keys","Object","getOwnPropertySymbols","symbols","filter","sym","getOwnPropertyDescriptor","enumerable","push","apply","_objectSpread","target","i","arguments","length","source","forEach","key","_defineProperty","getOwnPropertyDescriptors","defineProperties","defineProperty","ns","props","undefined","i18nFromProps","i18n","_ref","useContext","I18nContext","i18nFromContext","defaultNSFromContext","defaultNS","getI18n","reportNamespaces","ReportNamespaces","warnOnce","notReadyT","k","optsOrDefaultValue","_typeof","defaultValue","Array","isArray","retNotReady","t","ready","options","react","wait","i18nOptions","getDefaults","useSuspense","keyPrefix","namespaces","addUsedNamespaces","isInitialized","initializedStoreOnce","every","n","hasLoadedNamespace","getT","getFixedT","lng","nsMode","_useState","useState","_useState2","_slicedToArray","setT","joinedNS","join","concat","value","ignore","ref","previousJoinedNS","useRef","useEffect","current","isMounted","bindI18n","bindI18nStore","boundReset","loadLanguages","loadNamespaces","on","store","split","e","off","isInitial","ret","Promise","resolve"],"mappings":"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"}
1
+ {"version":3,"file":"useTranslation.js","sources":["../../../../../node_modules/react-i18next/dist/es/useTranslation.js"],"sourcesContent":["import { useContext, useCallback, useMemo, useEffect, useRef, useState, useSyncExternalStore } from 'react';\nimport { keyFromSelector } from 'i18next';\nimport { getI18n, getDefaults, ReportNamespaces, I18nContext } from './context.js';\nimport { warnOnce, loadNamespaces, loadLanguages, hasLoadedNamespace, isString, isObject, inDevelopment } from './utils.js';\nconst notReadyT = (k, optsOrDefaultValue) => {\n if (isString(optsOrDefaultValue)) return optsOrDefaultValue;\n if (isObject(optsOrDefaultValue) && isString(optsOrDefaultValue.defaultValue)) return optsOrDefaultValue.defaultValue;\n if (typeof k === 'function') return '';\n if (Array.isArray(k)) {\n const last = k[k.length - 1];\n return typeof last === 'function' ? '' : last;\n }\n return k;\n};\nconst languageKey = inst => `${inst.language}|${inst.resolvedLanguage}|${inst.languages?.join(',')}`;\nconst createI18nWrapper = original => new Proxy(original, {\n get: (target, prop) => prop === '__original' ? target : Reflect.get(target, prop)\n});\nconst notReadySnapshot = {\n t: notReadyT,\n ready: false\n};\nconst dummySubscribe = () => () => {};\nconst subscribeToEvents = (i18n, {\n bindI18n,\n bindI18nStore\n}, callback) => {\n if (bindI18n) i18n.on(bindI18n, callback);\n if (bindI18nStore) i18n.store.on(bindI18nStore, callback);\n return () => {\n if (bindI18n) i18n.off(bindI18n, callback);\n if (bindI18nStore) i18n.store.off(bindI18nStore, callback);\n };\n};\nexport const useRerenderOnEvents = i18n => {\n const {\n bindI18n,\n bindI18nStore\n } = {\n ...getDefaults(),\n ...i18n?.options?.react\n };\n const revisionRef = useRef(0);\n const subscribe = useCallback(callback => i18n ? subscribeToEvents(i18n, {\n bindI18n,\n bindI18nStore\n }, () => {\n revisionRef.current += 1;\n callback();\n }) : () => {}, [i18n, bindI18n, bindI18nStore]);\n const getSnapshot = () => bindI18n && i18n ? `${revisionRef.current}|${languageKey(i18n)}` : String(revisionRef.current);\n useSyncExternalStore(subscribe, getSnapshot, getSnapshot);\n};\nexport const useTranslation = (ns, props = {}) => {\n const {\n i18n: i18nFromProps\n } = props;\n const {\n i18n: i18nFromContext,\n defaultNS: defaultNSFromContext\n } = useContext(I18nContext) || {};\n const i18n = i18nFromProps || i18nFromContext || getI18n();\n if (i18n && !i18n.reportNamespaces) i18n.reportNamespaces = new ReportNamespaces();\n if (!i18n) {\n warnOnce(i18n, 'NO_I18NEXT_INSTANCE', 'useTranslation: You will need to pass in an i18next instance by using initReactI18next or by passing it via props or context. In monorepo setups, make sure there is only one instance of react-i18next.');\n }\n const i18nOptions = useMemo(() => ({\n ...getDefaults(),\n ...i18n?.options?.react,\n ...props\n }), [i18n, props]);\n const {\n useSuspense,\n keyPrefix,\n bindI18n,\n bindI18nStore\n } = i18nOptions;\n const nsOrContext = ns || defaultNSFromContext || i18n?.options?.defaultNS;\n const unstableNamespaces = isString(nsOrContext) ? [nsOrContext] : nsOrContext || ['translation'];\n const namespacesKey = JSON.stringify(unstableNamespaces);\n const namespaces = useMemo(() => unstableNamespaces, [namespacesKey]);\n i18n?.reportNamespaces?.addUsedNamespaces?.(namespaces);\n const revisionRef = useRef(0);\n const subscribe = useCallback(callback => {\n if (!i18n) return dummySubscribe;\n const wrappedCallback = () => {\n revisionRef.current += 1;\n callback();\n };\n return subscribeToEvents(i18n, {\n bindI18n,\n bindI18nStore\n }, wrappedCallback);\n }, [i18n, bindI18n, bindI18nStore]);\n const snapshotRef = useRef();\n const getSnapshot = useCallback(() => {\n if (!i18n) {\n return notReadySnapshot;\n }\n const calculatedReady = !!(i18n.isInitialized || i18n.initializedStoreOnce) && namespaces.every(n => hasLoadedNamespace(n, i18n, i18nOptions));\n const currentLng = props.lng || i18n.language;\n const currentRevision = revisionRef.current;\n const keyPrefixKey = typeof keyPrefix === 'function' ? keyFromSelector(keyPrefix, {\n ...i18n.options,\n ns: namespaces\n }) : keyPrefix;\n const lastSnapshot = snapshotRef.current;\n if (lastSnapshot && lastSnapshot.i18n === i18n && lastSnapshot.ready === calculatedReady && lastSnapshot.lng === currentLng && lastSnapshot.namespaces === namespaces && lastSnapshot.keyPrefix === keyPrefixKey && lastSnapshot.revision === currentRevision) {\n return lastSnapshot;\n }\n const calculatedT = i18n.getFixedT(currentLng, i18nOptions.nsMode === 'fallback' ? namespaces : namespaces[0], keyPrefix, {\n scopeNs: namespaces\n });\n const newSnapshot = {\n t: calculatedT,\n i18n,\n ready: calculatedReady,\n lng: currentLng,\n namespaces,\n keyPrefix: keyPrefixKey,\n revision: currentRevision\n };\n snapshotRef.current = newSnapshot;\n return newSnapshot;\n }, [i18n, namespaces, keyPrefix, i18nOptions, props.lng]);\n const [loadCount, setLoadCount] = useState(0);\n let {\n t,\n ready\n } = useSyncExternalStore(subscribe, getSnapshot, getSnapshot);\n let pendingTranslationLoad;\n if (i18n && useSuspense && !ready) {\n pendingTranslationLoad = new Promise(resolve => {\n const onLoaded = () => resolve();\n if (props.lng) {\n loadLanguages(i18n, props.lng, namespaces, onLoaded);\n } else {\n loadNamespaces(i18n, namespaces, onLoaded);\n }\n });\n ({\n t,\n ready\n } = getSnapshot());\n }\n useEffect(() => {\n if (i18n && !ready && !useSuspense) {\n const onLoaded = () => setLoadCount(c => c + 1);\n if (props.lng) {\n loadLanguages(i18n, props.lng, namespaces, onLoaded);\n } else {\n loadNamespaces(i18n, namespaces, onLoaded);\n }\n }\n }, [i18n, props.lng, namespaces, ready, useSuspense, loadCount]);\n const finalI18n = i18n || {};\n const wrapperRef = useRef(null);\n const ret = useMemo(() => {\n const original = finalI18n;\n const lang = languageKey(original);\n if (wrapperRef.current?.original !== original || wrapperRef.current.lang !== lang) {\n wrapperRef.current = {\n original,\n lang,\n wrapper: createI18nWrapper(original)\n };\n }\n const i18nWrapper = wrapperRef.current.wrapper;\n const effectiveT = !ready && !useSuspense ? (...args) => {\n warnOnce(i18n, 'USE_T_BEFORE_READY', 'useTranslation: t was called before ready. When using useSuspense: false, make sure to check the ready flag before using t.');\n return t(...args);\n } : t;\n const arr = [effectiveT, i18nWrapper, ready];\n arr.t = effectiveT;\n arr.i18n = i18nWrapper;\n arr.ready = ready;\n return arr;\n }, [t, finalI18n, ready, finalI18n.resolvedLanguage, finalI18n.language, finalI18n.languages]);\n if (i18n && useSuspense && !ready) {\n if (inDevelopment()) {\n warnOnce(i18n, 'SUSPENDED_WHILE_LOADING', 'useTranslation: suspended while translations are loading (useSuspense is true by default). Add a <Suspense> boundary above this component, or set react.useSuspense: false in the i18next init options. https://react.i18next.com/latest/usetranslation-hook');\n }\n throw pendingTranslationLoad;\n }\n return ret;\n};"],"names":["createI18nWrapper","original","Proxy","get","target","prop","Reflect","notReadySnapshot","t","notReadyT","k","optsOrDefaultValue","isString","isObject","defaultValue","Array","isArray","last","length","ready","dummySubscribe","useTranslation","ns","props","i18n","i18nFromProps","i18nFromContext","defaultNS","defaultNSFromContext","useContext","I18nContext","getI18n","reportNamespaces","ReportNamespaces","warnOnce","i18nOptions","useMemo","getDefaults","options","react","useSuspense","keyPrefix","bindI18n","bindI18nStore","nsOrContext","unstableNamespaces","namespacesKey","JSON","stringify","namespaces","addUsedNamespaces","revisionRef","useRef","subscribe","useCallback","callback","subscribeToEvents","on","store","off","wrappedCallback","current","snapshotRef","getSnapshot","calculatedReady","isInitialized","initializedStoreOnce","every","n","hasLoadedNamespace","currentLng","lng","language","currentRevision","keyPrefixKey","keyFromSelector","lastSnapshot","revision","newSnapshot","getFixedT","nsMode","scopeNs","loadCount","setLoadCount","useState","pendingTranslationLoad","useSyncExternalStore","Promise","resolve","onLoaded","loadLanguages","loadNamespaces","useEffect","c","finalI18n","wrapperRef","ret","lang","inst","resolvedLanguage","languages","join","wrapper","i18nWrapper","effectiveT","args","arr","inDevelopment"],"mappings":"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"}
@@ -1,2 +1,2 @@
1
- "use strict";function n(){if(console&&console.warn){for(var n,e=arguments.length,a=new Array(e),o=0;o<e;o++)a[o]=arguments[o];"string"==typeof a[0]&&(a[0]="react-i18next:: ".concat(a[0])),(n=console).warn.apply(n,a)}}Object.defineProperty(exports,"__esModule",{value:!0});var e={};function a(){for(var a=arguments.length,o=new Array(a),i=0;i<a;i++)o[i]=arguments[i];"string"==typeof o[0]&&e[o[0]]||("string"==typeof o[0]&&(e[o[0]]=new Date),n.apply(void 0,o))}var o=function(n,e){return function(){if(n.isInitialized)e();else{n.on("initialized",function a(){setTimeout(function(){n.off("initialized",a)},0),e()})}}};exports.hasLoadedNamespace=function(n,e){var o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return e.languages&&e.languages.length?void 0!==e.options.ignoreJSONStructure?e.hasLoadedNamespace(n,{lng:o.lng,precheck:function(e,a){if(o.bindI18n&&o.bindI18n.indexOf("languageChanging")>-1&&e.services.backendConnector.backend&&e.isLanguageChangingTo&&!a(e.isLanguageChangingTo,n))return!1}}):function(n,e){var a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},o=e.languages[0],i=!!e.options&&e.options.fallbackLng,t=e.languages[e.languages.length-1];if("cimode"===o.toLowerCase())return!0;var s=function(n,a){var o=e.services.backendConnector.state["".concat(n,"|").concat(a)];return-1===o||2===o};return!(a.bindI18n&&a.bindI18n.indexOf("languageChanging")>-1&&e.services.backendConnector.backend&&e.isLanguageChangingTo&&!s(e.isLanguageChangingTo,n)||!e.hasResourceBundle(o,n)&&e.services.backendConnector.backend&&(!e.options.resources||e.options.partialBundledLanguages)&&(!s(o,n)||i&&!s(t,n)))}(n,e,o):(a("i18n.languages were undefined or empty",e.languages),!0)},exports.loadLanguages=function(n,e,a,i){"string"==typeof a&&(a=[a]),a.forEach(function(e){n.options.ns.indexOf(e)<0&&n.options.ns.push(e)}),n.loadLanguages(e,o(n,i))},exports.loadNamespaces=function(n,e,a){n.loadNamespaces(e,o(n,a))},exports.warn=n,exports.warnOnce=a;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const e=(e,n,a,s)=>{const r=[a,{code:n,...s||{}}];if(e?.services?.logger?.forward)return e.services.logger.forward(r,"warn","react-i18next::",!0);t(r[0])&&(r[0]=`react-i18next:: ${r[0]}`),e?.services?.logger?.warn?e.services.logger.warn(...r):console?.warn&&console.warn(...r)},n=new WeakMap,a=new Set,s=(s,r,o,g)=>{if(t(o)){let e=a;const r=s?.services?.logger||s;if(i(r)&&(e=n.get(r),e||n.set(r,e=new Set)),e.has(o))return;e.add(o)}e(s,r,o,g)},r=(e,n)=>()=>{e.isInitialized?n():e.once("initialized",()=>n())},o=(e,n,a)=>{e.loadNamespaces(n,r(e,a))},t=e=>"string"==typeof e,i=e=>"object"==typeof e&&null!==e;exports.hasLoadedNamespace=(e,n,a={})=>n.languages&&n.languages.length?n.hasLoadedNamespace(e,{lng:a.lng,precheck:(n,s)=>{if(a.bindI18n&&a.bindI18n.indexOf("languageChanging")>-1&&n.services.backendConnector.backend&&n.isLanguageChangingTo&&!s(n.isLanguageChangingTo,e))return!1}}):(s(n,"NO_LANGUAGES","i18n.languages were undefined or empty",{languages:n.languages}),!0),exports.inDevelopment=()=>{try{return"production"!==process.env.NODE_ENV}catch(e){return!1}},exports.isObject=i,exports.isString=t,exports.loadLanguages=(e,n,a,s)=>{if(t(a)&&(a=[a]),e.options.preload&&e.options.preload.indexOf(n)>-1)return o(e,a,s);a.forEach(n=>{e.options.ns.indexOf(n)<0&&e.options.ns.push(n)}),e.loadLanguages(n,r(e,s))},exports.loadNamespaces=o,exports.warn=e,exports.warnOnce=s;
2
2
  //# sourceMappingURL=utils.js.map