vevet 3.19.2 → 4.0.0-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (714) hide show
  1. package/README.md +81 -18
  2. package/lib/cjs/{Application → Vevet}/events/createOnPageLoad/index.js +7 -7
  3. package/lib/cjs/Vevet/events/createOnPageLoad/index.js.map +1 -0
  4. package/lib/cjs/Vevet/events/createOnPageLoad/types.js.map +1 -0
  5. package/lib/cjs/{Application → Vevet}/events/createViewport/index.js +19 -25
  6. package/lib/cjs/Vevet/events/createViewport/index.js.map +1 -0
  7. package/lib/cjs/Vevet/events/createViewport/types.js.map +1 -0
  8. package/lib/cjs/Vevet/exported.js +3 -0
  9. package/lib/cjs/Vevet/exported.js.map +1 -0
  10. package/lib/cjs/Vevet/global.js +3 -0
  11. package/lib/cjs/Vevet/global.js.map +1 -0
  12. package/lib/cjs/Vevet/index.js +94 -0
  13. package/lib/cjs/Vevet/index.js.map +1 -0
  14. package/lib/cjs/{Application → Vevet}/types.js.map +1 -1
  15. package/lib/cjs/{utils/internal → Vevet/utils}/fetchWebpSupport.js +1 -1
  16. package/lib/cjs/Vevet/utils/fetchWebpSupport.js.map +1 -0
  17. package/lib/cjs/Vevet/utils/getDeviceInfo.js.map +1 -0
  18. package/lib/cjs/base/Callbacks/index.js +65 -48
  19. package/lib/cjs/base/Callbacks/index.js.map +1 -1
  20. package/lib/cjs/base/Component/index.js +15 -4
  21. package/lib/cjs/base/Component/index.js.map +1 -1
  22. package/lib/cjs/base/Module/index.js +118 -64
  23. package/lib/cjs/base/Module/index.js.map +1 -1
  24. package/lib/cjs/base/MutableProps/index.js +30 -55
  25. package/lib/cjs/base/MutableProps/index.js.map +1 -1
  26. package/lib/cjs/base/Plugin/index.js +20 -1
  27. package/lib/cjs/base/Plugin/index.js.map +1 -1
  28. package/lib/cjs/components/AnimationFrame/index.js +14 -21
  29. package/lib/cjs/components/AnimationFrame/index.js.map +1 -1
  30. package/lib/cjs/components/Ctx2D/index.js +40 -25
  31. package/lib/cjs/components/Ctx2D/index.js.map +1 -1
  32. package/lib/cjs/components/Ctx2DPrerender/index.js +17 -7
  33. package/lib/cjs/components/Ctx2DPrerender/index.js.map +1 -1
  34. package/lib/cjs/components/CustomCursor/index.js +75 -51
  35. package/lib/cjs/components/CustomCursor/index.js.map +1 -1
  36. package/lib/cjs/components/{SmoothScroll → CustomScroll}/AnimatonFrame.js +2 -2
  37. package/lib/cjs/components/{SmoothScroll → CustomScroll}/AnimatonFrame.js.map +1 -1
  38. package/lib/cjs/components/{SmoothScroll → CustomScroll}/Elements.js +9 -9
  39. package/lib/cjs/components/{SmoothScroll → CustomScroll}/Elements.js.map +1 -1
  40. package/lib/cjs/components/{SmoothScroll → CustomScroll}/index.js +72 -66
  41. package/lib/cjs/components/CustomScroll/index.js.map +1 -0
  42. package/lib/cjs/components/CustomScroll/types.js.map +1 -0
  43. package/lib/cjs/components/{SmoothScrollDragPlugin → CustomScrollDragPlugin}/index.js +45 -44
  44. package/lib/cjs/components/CustomScrollDragPlugin/index.js.map +1 -0
  45. package/lib/cjs/components/CustomScrollDragPlugin/types.js.map +1 -0
  46. package/lib/cjs/components/{SmoothScrollKeyboardPlugin → CustomScrollKeyboardPlugin}/index.js +51 -47
  47. package/lib/cjs/components/CustomScrollKeyboardPlugin/index.js.map +1 -0
  48. package/lib/cjs/components/CustomScrollKeyboardPlugin/types.js.map +1 -0
  49. package/lib/cjs/components/DraggerBase/index.js +74 -26
  50. package/lib/cjs/components/DraggerBase/index.js.map +1 -1
  51. package/lib/cjs/components/DraggerDirection/index.js +12 -6
  52. package/lib/cjs/components/DraggerDirection/index.js.map +1 -1
  53. package/lib/cjs/components/DraggerMove/index.js +44 -13
  54. package/lib/cjs/components/DraggerMove/index.js.map +1 -1
  55. package/lib/cjs/components/Marquee/index.js +240 -160
  56. package/lib/cjs/components/Marquee/index.js.map +1 -1
  57. package/lib/cjs/components/Preloader/index.js +45 -16
  58. package/lib/cjs/components/Preloader/index.js.map +1 -1
  59. package/lib/cjs/components/ProgressPreloader/index.js +79 -41
  60. package/lib/cjs/components/ProgressPreloader/index.js.map +1 -1
  61. package/lib/cjs/components/ProgressPreloader/utils/preloadCustomElement.js +12 -1
  62. package/lib/cjs/components/ProgressPreloader/utils/preloadCustomElement.js.map +1 -1
  63. package/lib/cjs/components/ScrollBar/Bar/index.js +90 -36
  64. package/lib/cjs/components/ScrollBar/Bar/index.js.map +1 -1
  65. package/lib/cjs/components/ScrollBar/index.js +59 -20
  66. package/lib/cjs/components/ScrollBar/index.js.map +1 -1
  67. package/lib/cjs/components/ScrollView/index.js +56 -20
  68. package/lib/cjs/components/ScrollView/index.js.map +1 -1
  69. package/lib/cjs/components/SectionScrollProgress/index.js +68 -31
  70. package/lib/cjs/components/SectionScrollProgress/index.js.map +1 -1
  71. package/lib/cjs/components/SlideProgress/index.js +72 -38
  72. package/lib/cjs/components/SlideProgress/index.js.map +1 -1
  73. package/lib/cjs/components/SplitText/index.js +52 -23
  74. package/lib/cjs/components/SplitText/index.js.map +1 -1
  75. package/lib/cjs/components/SplitText/utils/splitBase.js +6 -1
  76. package/lib/cjs/components/SplitText/utils/splitBase.js.map +1 -1
  77. package/lib/cjs/components/SplitText/utils/wrapLetters.js +11 -3
  78. package/lib/cjs/components/SplitText/utils/wrapLetters.js.map +1 -1
  79. package/lib/cjs/components/SplitText/utils/wrapLines.js +11 -5
  80. package/lib/cjs/components/SplitText/utils/wrapLines.js.map +1 -1
  81. package/lib/cjs/components/SplitText/utils/wrapWords.js +13 -2
  82. package/lib/cjs/components/SplitText/utils/wrapWords.js.map +1 -1
  83. package/lib/cjs/components/Timeline/index.js +77 -21
  84. package/lib/cjs/components/Timeline/index.js.map +1 -1
  85. package/lib/cjs/components/index.js +4 -4
  86. package/lib/cjs/components/index.js.map +1 -1
  87. package/lib/cjs/index.js +10 -3
  88. package/lib/cjs/index.js.map +1 -1
  89. package/lib/cjs/types/index.js +19 -0
  90. package/lib/cjs/types/index.js.map +1 -0
  91. package/lib/cjs/utils/common/PCancelable.js +16 -0
  92. package/lib/cjs/utils/common/PCancelable.js.map +1 -1
  93. package/lib/cjs/utils/common/normalizedTimeoutCallback.js +19 -4
  94. package/lib/cjs/utils/common/normalizedTimeoutCallback.js.map +1 -1
  95. package/lib/cjs/utils/common/objectKeys.js +11 -1
  96. package/lib/cjs/utils/common/objectKeys.js.map +1 -1
  97. package/lib/cjs/utils/common/pickObjectProps.js +14 -2
  98. package/lib/cjs/utils/common/pickObjectProps.js.map +1 -1
  99. package/lib/cjs/utils/common/times.js +12 -3
  100. package/lib/cjs/utils/common/times.js.map +1 -1
  101. package/lib/cjs/utils/common/uid.js +4 -2
  102. package/lib/cjs/utils/common/uid.js.map +1 -1
  103. package/lib/cjs/utils/image/load.js +3 -3
  104. package/lib/cjs/utils/image/load.js.map +1 -1
  105. package/lib/cjs/utils/image/pathsToProps.js +12 -5
  106. package/lib/cjs/utils/image/pathsToProps.js.map +1 -1
  107. package/lib/cjs/utils/image/sizesToSrcSet.js +7 -3
  108. package/lib/cjs/utils/image/sizesToSrcSet.js.map +1 -1
  109. package/lib/cjs/utils/internal/getApp.js +12 -0
  110. package/lib/cjs/utils/internal/getApp.js.map +1 -1
  111. package/lib/cjs/utils/listeners/isIntersectionObserverSupported.js +1 -1
  112. package/lib/cjs/utils/listeners/onResize.js +13 -12
  113. package/lib/cjs/utils/listeners/onResize.js.map +1 -1
  114. package/lib/cjs/utils/math/clamp.js +10 -5
  115. package/lib/cjs/utils/math/clamp.js.map +1 -1
  116. package/lib/cjs/utils/math/clampScope.js +8 -1
  117. package/lib/cjs/utils/math/clampScope.js.map +1 -1
  118. package/lib/cjs/utils/math/easing.js +6 -2
  119. package/lib/cjs/utils/math/easing.js.map +1 -1
  120. package/lib/cjs/utils/math/inScope.js +6 -3
  121. package/lib/cjs/utils/math/inScope.js.map +1 -1
  122. package/lib/cjs/utils/math/lerp.js +11 -3
  123. package/lib/cjs/utils/math/lerp.js.map +1 -1
  124. package/lib/cjs/utils/math/normalizeNestedScope.js +12 -3
  125. package/lib/cjs/utils/math/normalizeNestedScope.js.map +1 -1
  126. package/lib/cjs/utils/math/scoped.js +18 -7
  127. package/lib/cjs/utils/math/scoped.js.map +1 -1
  128. package/lib/cjs/utils/math/spreadScope.js +17 -3
  129. package/lib/cjs/utils/math/spreadScope.js.map +1 -1
  130. package/lib/cjs/utils/math/wrap.js +9 -3
  131. package/lib/cjs/utils/math/wrap.js.map +1 -1
  132. package/lib/cjs/utils/scroll/getScrollValues.js +13 -1
  133. package/lib/cjs/utils/scroll/getScrollValues.js.map +1 -1
  134. package/lib/cjs/utils/scroll/isPageScrolling.js +30 -0
  135. package/lib/cjs/utils/scroll/isPageScrolling.js.map +1 -1
  136. package/lib/cjs/utils/scroll/normalizeWheel.js +7 -2
  137. package/lib/cjs/utils/scroll/normalizeWheel.js.map +1 -1
  138. package/lib/cjs/utils/scroll/onScroll.js +14 -7
  139. package/lib/cjs/utils/scroll/onScroll.js.map +1 -1
  140. package/lib/cjs/utils/scroll/scrollTo.js +8 -7
  141. package/lib/cjs/utils/scroll/scrollTo.js.map +1 -1
  142. package/lib/cjs/utils/scroll/scrollToElement.js +8 -6
  143. package/lib/cjs/utils/scroll/scrollToElement.js.map +1 -1
  144. package/lib/cjs/version.js +1 -1
  145. package/lib/esm/{Application → Vevet}/events/createOnPageLoad/index.js +7 -7
  146. package/lib/esm/Vevet/events/createOnPageLoad/index.js.map +1 -0
  147. package/lib/esm/Vevet/events/createOnPageLoad/types.js.map +1 -0
  148. package/lib/esm/{Application → Vevet}/events/createViewport/index.js +20 -26
  149. package/lib/esm/Vevet/events/createViewport/index.js.map +1 -0
  150. package/lib/esm/Vevet/events/createViewport/types.js.map +1 -0
  151. package/lib/esm/Vevet/exported.js +2 -0
  152. package/lib/esm/Vevet/exported.js.map +1 -0
  153. package/lib/esm/Vevet/global.js +2 -0
  154. package/lib/esm/Vevet/global.js.map +1 -0
  155. package/lib/esm/Vevet/index.js +72 -0
  156. package/lib/esm/Vevet/index.js.map +1 -0
  157. package/lib/esm/{Application → Vevet}/types.js.map +1 -1
  158. package/lib/esm/{utils/internal → Vevet/utils}/fetchWebpSupport.js +1 -1
  159. package/lib/esm/Vevet/utils/fetchWebpSupport.js.map +1 -0
  160. package/lib/esm/Vevet/utils/getDeviceInfo.js.map +1 -0
  161. package/lib/esm/base/Callbacks/index.js +66 -48
  162. package/lib/esm/base/Callbacks/index.js.map +1 -1
  163. package/lib/esm/base/Component/index.js +15 -4
  164. package/lib/esm/base/Component/index.js.map +1 -1
  165. package/lib/esm/base/Module/index.js +119 -65
  166. package/lib/esm/base/Module/index.js.map +1 -1
  167. package/lib/esm/base/MutableProps/index.js +35 -60
  168. package/lib/esm/base/MutableProps/index.js.map +1 -1
  169. package/lib/esm/base/Plugin/index.js +20 -1
  170. package/lib/esm/base/Plugin/index.js.map +1 -1
  171. package/lib/esm/components/AnimationFrame/index.js +14 -21
  172. package/lib/esm/components/AnimationFrame/index.js.map +1 -1
  173. package/lib/esm/components/Ctx2D/index.js +40 -25
  174. package/lib/esm/components/Ctx2D/index.js.map +1 -1
  175. package/lib/esm/components/Ctx2DPrerender/index.js +17 -7
  176. package/lib/esm/components/Ctx2DPrerender/index.js.map +1 -1
  177. package/lib/esm/components/CustomCursor/index.js +75 -51
  178. package/lib/esm/components/CustomCursor/index.js.map +1 -1
  179. package/lib/esm/components/{SmoothScroll → CustomScroll}/AnimatonFrame.js +2 -2
  180. package/lib/esm/components/{SmoothScroll → CustomScroll}/AnimatonFrame.js.map +1 -1
  181. package/lib/esm/components/{SmoothScroll → CustomScroll}/Elements.js +8 -8
  182. package/lib/esm/components/{SmoothScroll → CustomScroll}/Elements.js.map +1 -1
  183. package/lib/esm/components/{SmoothScroll → CustomScroll}/index.js +30 -24
  184. package/lib/esm/components/CustomScroll/index.js.map +1 -0
  185. package/lib/esm/components/CustomScroll/types.js.map +1 -0
  186. package/lib/esm/components/{SmoothScrollDragPlugin → CustomScrollDragPlugin}/index.js +28 -27
  187. package/lib/esm/components/CustomScrollDragPlugin/index.js.map +1 -0
  188. package/lib/esm/components/CustomScrollDragPlugin/types.js.map +1 -0
  189. package/lib/esm/components/{SmoothScrollKeyboardPlugin → CustomScrollKeyboardPlugin}/index.js +37 -33
  190. package/lib/esm/components/CustomScrollKeyboardPlugin/index.js.map +1 -0
  191. package/lib/esm/components/CustomScrollKeyboardPlugin/types.js.map +1 -0
  192. package/lib/esm/components/DraggerBase/index.js +74 -28
  193. package/lib/esm/components/DraggerBase/index.js.map +1 -1
  194. package/lib/esm/components/DraggerDirection/index.js +12 -6
  195. package/lib/esm/components/DraggerDirection/index.js.map +1 -1
  196. package/lib/esm/components/DraggerMove/index.js +44 -13
  197. package/lib/esm/components/DraggerMove/index.js.map +1 -1
  198. package/lib/esm/components/Marquee/index.js +220 -161
  199. package/lib/esm/components/Marquee/index.js.map +1 -1
  200. package/lib/esm/components/Preloader/index.js +45 -16
  201. package/lib/esm/components/Preloader/index.js.map +1 -1
  202. package/lib/esm/components/ProgressPreloader/index.js +79 -40
  203. package/lib/esm/components/ProgressPreloader/index.js.map +1 -1
  204. package/lib/esm/components/ProgressPreloader/utils/preloadCustomElement.js +12 -1
  205. package/lib/esm/components/ProgressPreloader/utils/preloadCustomElement.js.map +1 -1
  206. package/lib/esm/components/ScrollBar/Bar/index.js +89 -32
  207. package/lib/esm/components/ScrollBar/Bar/index.js.map +1 -1
  208. package/lib/esm/components/ScrollBar/index.js +49 -15
  209. package/lib/esm/components/ScrollBar/index.js.map +1 -1
  210. package/lib/esm/components/ScrollView/index.js +56 -20
  211. package/lib/esm/components/ScrollView/index.js.map +1 -1
  212. package/lib/esm/components/SectionScrollProgress/index.js +68 -31
  213. package/lib/esm/components/SectionScrollProgress/index.js.map +1 -1
  214. package/lib/esm/components/SlideProgress/index.js +72 -38
  215. package/lib/esm/components/SlideProgress/index.js.map +1 -1
  216. package/lib/esm/components/SplitText/index.js +52 -23
  217. package/lib/esm/components/SplitText/index.js.map +1 -1
  218. package/lib/esm/components/SplitText/utils/splitBase.js +6 -1
  219. package/lib/esm/components/SplitText/utils/splitBase.js.map +1 -1
  220. package/lib/esm/components/SplitText/utils/wrapLetters.js +11 -3
  221. package/lib/esm/components/SplitText/utils/wrapLetters.js.map +1 -1
  222. package/lib/esm/components/SplitText/utils/wrapLines.js +11 -5
  223. package/lib/esm/components/SplitText/utils/wrapLines.js.map +1 -1
  224. package/lib/esm/components/SplitText/utils/wrapWords.js +13 -2
  225. package/lib/esm/components/SplitText/utils/wrapWords.js.map +1 -1
  226. package/lib/esm/components/Timeline/index.js +70 -22
  227. package/lib/esm/components/Timeline/index.js.map +1 -1
  228. package/lib/esm/components/index.js +4 -4
  229. package/lib/esm/components/index.js.map +1 -1
  230. package/lib/esm/index.js +9 -3
  231. package/lib/esm/index.js.map +1 -1
  232. package/lib/esm/types/index.js +3 -0
  233. package/lib/esm/types/index.js.map +1 -0
  234. package/lib/esm/utils/common/PCancelable.js +16 -0
  235. package/lib/esm/utils/common/PCancelable.js.map +1 -1
  236. package/lib/esm/utils/common/normalizedTimeoutCallback.js +19 -4
  237. package/lib/esm/utils/common/normalizedTimeoutCallback.js.map +1 -1
  238. package/lib/esm/utils/common/objectKeys.js +11 -1
  239. package/lib/esm/utils/common/objectKeys.js.map +1 -1
  240. package/lib/esm/utils/common/pickObjectProps.js +14 -2
  241. package/lib/esm/utils/common/pickObjectProps.js.map +1 -1
  242. package/lib/esm/utils/common/times.js +12 -3
  243. package/lib/esm/utils/common/times.js.map +1 -1
  244. package/lib/esm/utils/common/uid.js +4 -2
  245. package/lib/esm/utils/common/uid.js.map +1 -1
  246. package/lib/esm/utils/image/load.js +3 -3
  247. package/lib/esm/utils/image/load.js.map +1 -1
  248. package/lib/esm/utils/image/pathsToProps.js +12 -5
  249. package/lib/esm/utils/image/pathsToProps.js.map +1 -1
  250. package/lib/esm/utils/image/sizesToSrcSet.js +7 -3
  251. package/lib/esm/utils/image/sizesToSrcSet.js.map +1 -1
  252. package/lib/esm/utils/internal/getApp.js +12 -0
  253. package/lib/esm/utils/internal/getApp.js.map +1 -1
  254. package/lib/esm/utils/listeners/isIntersectionObserverSupported.js +1 -1
  255. package/lib/esm/utils/listeners/onResize.js +11 -12
  256. package/lib/esm/utils/listeners/onResize.js.map +1 -1
  257. package/lib/esm/utils/math/clamp.js +10 -5
  258. package/lib/esm/utils/math/clamp.js.map +1 -1
  259. package/lib/esm/utils/math/clampScope.js +8 -1
  260. package/lib/esm/utils/math/clampScope.js.map +1 -1
  261. package/lib/esm/utils/math/easing.js +6 -2
  262. package/lib/esm/utils/math/easing.js.map +1 -1
  263. package/lib/esm/utils/math/inScope.js +6 -3
  264. package/lib/esm/utils/math/inScope.js.map +1 -1
  265. package/lib/esm/utils/math/lerp.js +11 -3
  266. package/lib/esm/utils/math/lerp.js.map +1 -1
  267. package/lib/esm/utils/math/normalizeNestedScope.js +12 -3
  268. package/lib/esm/utils/math/normalizeNestedScope.js.map +1 -1
  269. package/lib/esm/utils/math/scoped.js +17 -6
  270. package/lib/esm/utils/math/scoped.js.map +1 -1
  271. package/lib/esm/utils/math/spreadScope.js +17 -3
  272. package/lib/esm/utils/math/spreadScope.js.map +1 -1
  273. package/lib/esm/utils/math/wrap.js +9 -3
  274. package/lib/esm/utils/math/wrap.js.map +1 -1
  275. package/lib/esm/utils/scroll/getScrollValues.js +13 -1
  276. package/lib/esm/utils/scroll/getScrollValues.js.map +1 -1
  277. package/lib/esm/utils/scroll/isPageScrolling.js +30 -0
  278. package/lib/esm/utils/scroll/isPageScrolling.js.map +1 -1
  279. package/lib/esm/utils/scroll/normalizeWheel.js +7 -2
  280. package/lib/esm/utils/scroll/normalizeWheel.js.map +1 -1
  281. package/lib/esm/utils/scroll/onScroll.js +14 -7
  282. package/lib/esm/utils/scroll/onScroll.js.map +1 -1
  283. package/lib/esm/utils/scroll/scrollTo.js +8 -7
  284. package/lib/esm/utils/scroll/scrollTo.js.map +1 -1
  285. package/lib/esm/utils/scroll/scrollToElement.js +8 -6
  286. package/lib/esm/utils/scroll/scrollToElement.js.map +1 -1
  287. package/lib/esm/version.js +1 -1
  288. package/lib/styles/base.scss +0 -2
  289. package/lib/styles/components/CustomCursor.scss +7 -7
  290. package/{src/styles/components/SmoothScroll.scss → lib/styles/components/CustomScroll.scss} +3 -3
  291. package/lib/styles/components/Preloader.scss +1 -1
  292. package/lib/styles/components/ScrollBar.scss +4 -4
  293. package/lib/styles/components/index.scss +1 -1
  294. package/lib/styles/index.scss +0 -1
  295. package/lib/types/Vevet/events/createOnPageLoad/index.d.ts +3 -0
  296. package/lib/types/Vevet/events/createOnPageLoad/index.d.ts.map +1 -0
  297. package/lib/types/Vevet/events/createOnPageLoad/types.d.ts +20 -0
  298. package/lib/types/Vevet/events/createOnPageLoad/types.d.ts.map +1 -0
  299. package/lib/types/Vevet/events/createViewport/index.d.ts +4 -0
  300. package/lib/types/Vevet/events/createViewport/index.d.ts.map +1 -0
  301. package/lib/types/Vevet/events/createViewport/types.d.ts +85 -0
  302. package/lib/types/Vevet/events/createViewport/types.d.ts.map +1 -0
  303. package/lib/types/Vevet/exported.d.ts +6 -0
  304. package/lib/types/Vevet/exported.d.ts.map +1 -0
  305. package/lib/types/Vevet/global.d.ts +51 -0
  306. package/lib/types/Vevet/global.d.ts.map +1 -0
  307. package/lib/types/Vevet/index.d.ts +4 -0
  308. package/lib/types/Vevet/index.d.ts.map +1 -0
  309. package/lib/types/Vevet/types.d.ts +43 -0
  310. package/lib/types/Vevet/types.d.ts.map +1 -0
  311. package/lib/types/Vevet/utils/fetchWebpSupport.d.ts +3 -0
  312. package/lib/types/Vevet/utils/fetchWebpSupport.d.ts.map +1 -0
  313. package/lib/types/Vevet/utils/getDeviceInfo.d.ts.map +1 -0
  314. package/lib/types/base/Callbacks/index.d.ts +67 -46
  315. package/lib/types/base/Callbacks/index.d.ts.map +1 -1
  316. package/lib/types/base/Callbacks/types.d.ts +46 -14
  317. package/lib/types/base/Callbacks/types.d.ts.map +1 -1
  318. package/lib/types/base/Component/index.d.ts +19 -5
  319. package/lib/types/base/Component/index.d.ts.map +1 -1
  320. package/lib/types/base/Component/types.d.ts +15 -3
  321. package/lib/types/base/Component/types.d.ts.map +1 -1
  322. package/lib/types/base/Module/index.d.ts +124 -74
  323. package/lib/types/base/Module/index.d.ts.map +1 -1
  324. package/lib/types/base/Module/types.d.ts +29 -3
  325. package/lib/types/base/Module/types.d.ts.map +1 -1
  326. package/lib/types/base/MutableProps/index.d.ts +34 -77
  327. package/lib/types/base/MutableProps/index.d.ts.map +1 -1
  328. package/lib/types/base/MutableProps/types.d.ts +14 -8
  329. package/lib/types/base/MutableProps/types.d.ts.map +1 -1
  330. package/lib/types/base/Plugin/index.d.ts +24 -1
  331. package/lib/types/base/Plugin/index.d.ts.map +1 -1
  332. package/lib/types/base/Plugin/types.d.ts +11 -0
  333. package/lib/types/base/Plugin/types.d.ts.map +1 -1
  334. package/lib/types/components/AnimationFrame/index.d.ts +20 -18
  335. package/lib/types/components/AnimationFrame/index.d.ts.map +1 -1
  336. package/lib/types/components/AnimationFrame/types.d.ts +18 -3
  337. package/lib/types/components/AnimationFrame/types.d.ts.map +1 -1
  338. package/lib/types/components/Ctx2D/index.d.ts +37 -15
  339. package/lib/types/components/Ctx2D/index.d.ts.map +1 -1
  340. package/lib/types/components/Ctx2D/types.d.ts +40 -13
  341. package/lib/types/components/Ctx2D/types.d.ts.map +1 -1
  342. package/lib/types/components/Ctx2DPrerender/index.d.ts +13 -4
  343. package/lib/types/components/Ctx2DPrerender/index.d.ts.map +1 -1
  344. package/lib/types/components/Ctx2DPrerender/types.d.ts +13 -2
  345. package/lib/types/components/Ctx2DPrerender/types.d.ts.map +1 -1
  346. package/lib/types/components/CustomCursor/index.d.ts +59 -36
  347. package/lib/types/components/CustomCursor/index.d.ts.map +1 -1
  348. package/lib/types/components/CustomCursor/types.d.ts +52 -12
  349. package/lib/types/components/CustomCursor/types.d.ts.map +1 -1
  350. package/lib/types/components/{SmoothScroll → CustomScroll}/AnimatonFrame.d.ts.map +1 -1
  351. package/lib/types/components/{SmoothScroll → CustomScroll}/Elements.d.ts +3 -3
  352. package/lib/types/components/{SmoothScroll → CustomScroll}/Elements.d.ts.map +1 -1
  353. package/lib/types/components/{SmoothScroll → CustomScroll}/index.d.ts +46 -32
  354. package/lib/types/components/CustomScroll/index.d.ts.map +1 -0
  355. package/lib/types/components/CustomScroll/types.d.ts +137 -0
  356. package/lib/types/components/CustomScroll/types.d.ts.map +1 -0
  357. package/lib/types/components/CustomScrollDragPlugin/index.d.ts +62 -0
  358. package/lib/types/components/CustomScrollDragPlugin/index.d.ts.map +1 -0
  359. package/lib/types/components/CustomScrollDragPlugin/types.d.ts +52 -0
  360. package/lib/types/components/CustomScrollDragPlugin/types.d.ts.map +1 -0
  361. package/lib/types/components/CustomScrollKeyboardPlugin/index.d.ts +47 -0
  362. package/lib/types/components/CustomScrollKeyboardPlugin/index.d.ts.map +1 -0
  363. package/lib/types/components/CustomScrollKeyboardPlugin/types.d.ts +16 -0
  364. package/lib/types/components/{SmoothScrollKeyboardPlugin → CustomScrollKeyboardPlugin}/types.d.ts.map +1 -1
  365. package/lib/types/components/DraggerBase/index.d.ts +93 -28
  366. package/lib/types/components/DraggerBase/index.d.ts.map +1 -1
  367. package/lib/types/components/DraggerBase/types.d.ts +21 -3
  368. package/lib/types/components/DraggerBase/types.d.ts.map +1 -1
  369. package/lib/types/components/DraggerDirection/index.d.ts +6 -2
  370. package/lib/types/components/DraggerDirection/index.d.ts.map +1 -1
  371. package/lib/types/components/DraggerDirection/types.d.ts +15 -1
  372. package/lib/types/components/DraggerDirection/types.d.ts.map +1 -1
  373. package/lib/types/components/DraggerMove/index.d.ts +38 -8
  374. package/lib/types/components/DraggerMove/index.d.ts.map +1 -1
  375. package/lib/types/components/DraggerMove/types.d.ts +15 -2
  376. package/lib/types/components/DraggerMove/types.d.ts.map +1 -1
  377. package/lib/types/components/Marquee/index.d.ts +59 -36
  378. package/lib/types/components/Marquee/index.d.ts.map +1 -1
  379. package/lib/types/components/Marquee/types.d.ts +18 -8
  380. package/lib/types/components/Marquee/types.d.ts.map +1 -1
  381. package/lib/types/components/Preloader/index.d.ts +52 -15
  382. package/lib/types/components/Preloader/index.d.ts.map +1 -1
  383. package/lib/types/components/Preloader/types.d.ts +16 -5
  384. package/lib/types/components/Preloader/types.d.ts.map +1 -1
  385. package/lib/types/components/ProgressPreloader/index.d.ts +85 -25
  386. package/lib/types/components/ProgressPreloader/index.d.ts.map +1 -1
  387. package/lib/types/components/ProgressPreloader/types.d.ts +51 -14
  388. package/lib/types/components/ProgressPreloader/types.d.ts.map +1 -1
  389. package/lib/types/components/ProgressPreloader/utils/preloadCustomElement.d.ts +3 -0
  390. package/lib/types/components/ProgressPreloader/utils/preloadCustomElement.d.ts.map +1 -1
  391. package/lib/types/components/ScrollBar/Bar/index.d.ts +81 -16
  392. package/lib/types/components/ScrollBar/Bar/index.d.ts.map +1 -1
  393. package/lib/types/components/ScrollBar/Bar/types.d.ts +38 -16
  394. package/lib/types/components/ScrollBar/Bar/types.d.ts.map +1 -1
  395. package/lib/types/components/ScrollBar/index.d.ts +49 -12
  396. package/lib/types/components/ScrollBar/index.d.ts.map +1 -1
  397. package/lib/types/components/ScrollBar/types.d.ts +8 -6
  398. package/lib/types/components/ScrollBar/types.d.ts.map +1 -1
  399. package/lib/types/components/ScrollView/index.d.ts +65 -21
  400. package/lib/types/components/ScrollView/index.d.ts.map +1 -1
  401. package/lib/types/components/SectionScrollProgress/index.d.ts +83 -28
  402. package/lib/types/components/SectionScrollProgress/index.d.ts.map +1 -1
  403. package/lib/types/components/SectionScrollProgress/types.d.ts +15 -6
  404. package/lib/types/components/SectionScrollProgress/types.d.ts.map +1 -1
  405. package/lib/types/components/SlideProgress/index.d.ts +59 -24
  406. package/lib/types/components/SlideProgress/index.d.ts.map +1 -1
  407. package/lib/types/components/SlideProgress/types.d.ts +24 -15
  408. package/lib/types/components/SlideProgress/types.d.ts.map +1 -1
  409. package/lib/types/components/SplitText/index.d.ts +64 -18
  410. package/lib/types/components/SplitText/index.d.ts.map +1 -1
  411. package/lib/types/components/SplitText/types.d.ts +36 -8
  412. package/lib/types/components/SplitText/types.d.ts.map +1 -1
  413. package/lib/types/components/SplitText/utils/splitBase.d.ts +3 -1
  414. package/lib/types/components/SplitText/utils/splitBase.d.ts.map +1 -1
  415. package/lib/types/components/SplitText/utils/wrapLetters.d.ts +3 -1
  416. package/lib/types/components/SplitText/utils/wrapLetters.d.ts.map +1 -1
  417. package/lib/types/components/SplitText/utils/wrapLines.d.ts +3 -1
  418. package/lib/types/components/SplitText/utils/wrapLines.d.ts.map +1 -1
  419. package/lib/types/components/SplitText/utils/wrapWords.d.ts +3 -1
  420. package/lib/types/components/SplitText/utils/wrapWords.d.ts.map +1 -1
  421. package/lib/types/components/Timeline/index.d.ts +69 -21
  422. package/lib/types/components/Timeline/index.d.ts.map +1 -1
  423. package/lib/types/components/Timeline/types.d.ts +32 -7
  424. package/lib/types/components/Timeline/types.d.ts.map +1 -1
  425. package/lib/types/components/index.d.ts +4 -4
  426. package/lib/types/components/index.d.ts.map +1 -1
  427. package/lib/types/index.d.ts +9 -2
  428. package/lib/types/index.d.ts.map +1 -1
  429. package/lib/types/types/index.d.ts +3 -0
  430. package/lib/types/types/index.d.ts.map +1 -0
  431. package/lib/types/types/utility.d.ts +2 -3
  432. package/lib/types/types/utility.d.ts.map +1 -1
  433. package/lib/types/utils/common/PCancelable.d.ts +16 -0
  434. package/lib/types/utils/common/PCancelable.d.ts.map +1 -1
  435. package/lib/types/utils/common/normalizedTimeoutCallback.d.ts +19 -4
  436. package/lib/types/utils/common/normalizedTimeoutCallback.d.ts.map +1 -1
  437. package/lib/types/utils/common/objectKeys.d.ts +11 -1
  438. package/lib/types/utils/common/objectKeys.d.ts.map +1 -1
  439. package/lib/types/utils/common/pickObjectProps.d.ts +14 -2
  440. package/lib/types/utils/common/pickObjectProps.d.ts.map +1 -1
  441. package/lib/types/utils/common/times.d.ts +12 -3
  442. package/lib/types/utils/common/times.d.ts.map +1 -1
  443. package/lib/types/utils/common/uid.d.ts +4 -2
  444. package/lib/types/utils/common/uid.d.ts.map +1 -1
  445. package/lib/types/utils/image/load.d.ts +8 -5
  446. package/lib/types/utils/image/load.d.ts.map +1 -1
  447. package/lib/types/utils/image/pathsToProps.d.ts +10 -4
  448. package/lib/types/utils/image/pathsToProps.d.ts.map +1 -1
  449. package/lib/types/utils/image/sizesToSrcSet.d.ts +7 -3
  450. package/lib/types/utils/image/sizesToSrcSet.d.ts.map +1 -1
  451. package/lib/types/utils/internal/getApp.d.ts +9 -1
  452. package/lib/types/utils/internal/getApp.d.ts.map +1 -1
  453. package/lib/types/utils/listeners/isIntersectionObserverSupported.d.ts +1 -1
  454. package/lib/types/utils/listeners/onResize.d.ts +11 -12
  455. package/lib/types/utils/listeners/onResize.d.ts.map +1 -1
  456. package/lib/types/utils/math/clamp.d.ts +7 -2
  457. package/lib/types/utils/math/clamp.d.ts.map +1 -1
  458. package/lib/types/utils/math/clampScope.d.ts +8 -1
  459. package/lib/types/utils/math/clampScope.d.ts.map +1 -1
  460. package/lib/types/utils/math/easing.d.ts +4 -1
  461. package/lib/types/utils/math/easing.d.ts.map +1 -1
  462. package/lib/types/utils/math/inScope.d.ts +5 -2
  463. package/lib/types/utils/math/inScope.d.ts.map +1 -1
  464. package/lib/types/utils/math/lerp.d.ts +10 -2
  465. package/lib/types/utils/math/lerp.d.ts.map +1 -1
  466. package/lib/types/utils/math/normalizeNestedScope.d.ts +12 -3
  467. package/lib/types/utils/math/normalizeNestedScope.d.ts.map +1 -1
  468. package/lib/types/utils/math/scoped.d.ts +16 -5
  469. package/lib/types/utils/math/scoped.d.ts.map +1 -1
  470. package/lib/types/utils/math/spreadScope.d.ts +17 -3
  471. package/lib/types/utils/math/spreadScope.d.ts.map +1 -1
  472. package/lib/types/utils/math/wrap.d.ts +9 -3
  473. package/lib/types/utils/math/wrap.d.ts.map +1 -1
  474. package/lib/types/utils/scroll/getScrollValues.d.ts +13 -1
  475. package/lib/types/utils/scroll/getScrollValues.d.ts.map +1 -1
  476. package/lib/types/utils/scroll/isPageScrolling.d.ts +20 -0
  477. package/lib/types/utils/scroll/isPageScrolling.d.ts.map +1 -1
  478. package/lib/types/utils/scroll/normalizeWheel.d.ts +10 -2
  479. package/lib/types/utils/scroll/normalizeWheel.d.ts.map +1 -1
  480. package/lib/types/utils/scroll/onScroll.d.ts +10 -5
  481. package/lib/types/utils/scroll/onScroll.d.ts.map +1 -1
  482. package/lib/types/utils/scroll/scrollTo.d.ts +12 -9
  483. package/lib/types/utils/scroll/scrollTo.d.ts.map +1 -1
  484. package/lib/types/utils/scroll/scrollToElement.d.ts +9 -7
  485. package/lib/types/utils/scroll/scrollToElement.d.ts.map +1 -1
  486. package/lib/types/version.d.ts +1 -1
  487. package/package.json +6 -7
  488. package/src/{Application → Vevet}/events/createOnPageLoad/index.ts +8 -8
  489. package/src/Vevet/events/createOnPageLoad/types.ts +21 -0
  490. package/src/{Application → Vevet}/events/createViewport/index.ts +33 -35
  491. package/src/{Application → Vevet}/events/createViewport/stories/index.tsx +7 -5
  492. package/src/Vevet/events/createViewport/types.ts +93 -0
  493. package/src/Vevet/exported.ts +15 -0
  494. package/src/Vevet/global.ts +51 -0
  495. package/src/Vevet/index.ts +98 -0
  496. package/src/{Application → Vevet}/stories/index.tsx +2 -2
  497. package/src/Vevet/types.ts +48 -0
  498. package/src/base/Callbacks/index.ts +70 -51
  499. package/src/base/Callbacks/types.ts +53 -14
  500. package/src/base/Component/index.ts +19 -5
  501. package/src/base/Component/types.ts +15 -3
  502. package/src/base/Module/index.ts +125 -78
  503. package/src/base/Module/types.ts +32 -3
  504. package/src/base/MutableProps/index.ts +44 -73
  505. package/src/base/MutableProps/types.ts +15 -8
  506. package/src/base/Plugin/index.ts +24 -1
  507. package/src/base/Plugin/types.ts +11 -0
  508. package/src/components/AnimationFrame/index.ts +21 -28
  509. package/src/components/AnimationFrame/types.ts +23 -3
  510. package/src/components/Ctx2D/index.ts +46 -34
  511. package/src/components/Ctx2D/types.ts +53 -13
  512. package/src/components/Ctx2DPrerender/index.ts +18 -7
  513. package/src/components/Ctx2DPrerender/types.ts +13 -2
  514. package/src/components/CustomCursor/index.ts +85 -60
  515. package/src/components/CustomCursor/stories/index.tsx +0 -3
  516. package/src/components/CustomCursor/types.ts +63 -12
  517. package/src/components/{SmoothScroll → CustomScroll}/AnimatonFrame.ts +2 -2
  518. package/src/components/{SmoothScroll → CustomScroll}/Elements.ts +14 -14
  519. package/src/components/{SmoothScroll → CustomScroll}/index.ts +61 -44
  520. package/src/components/{SmoothScroll → CustomScroll}/stories/Default.tsx +8 -8
  521. package/src/components/{SmoothScroll → CustomScroll}/stories/WithHorizontal.tsx +9 -9
  522. package/src/components/{SmoothScroll → CustomScroll}/stories/WithInnerLerp.tsx +9 -9
  523. package/src/components/{SmoothScroll → CustomScroll}/stories/index.stories.tsx +1 -1
  524. package/src/components/CustomScroll/types.ts +165 -0
  525. package/src/components/{SmoothScrollDragPlugin → CustomScrollDragPlugin}/index.ts +41 -41
  526. package/src/components/{SmoothScrollDragPlugin → CustomScrollDragPlugin}/stories/index.stories.tsx +1 -1
  527. package/src/components/{SmoothScrollDragPlugin → CustomScrollDragPlugin}/stories/index.tsx +10 -10
  528. package/src/components/CustomScrollDragPlugin/types.ts +59 -0
  529. package/src/components/{SmoothScrollKeyboardPlugin → CustomScrollKeyboardPlugin}/index.ts +47 -43
  530. package/src/components/{SmoothScrollKeyboardPlugin → CustomScrollKeyboardPlugin}/stories/index.stories.tsx +1 -1
  531. package/src/components/{SmoothScrollKeyboardPlugin → CustomScrollKeyboardPlugin}/stories/index.tsx +10 -10
  532. package/src/components/{SmoothScrollKeyboardPlugin → CustomScrollKeyboardPlugin}/types.ts +6 -2
  533. package/src/components/DraggerBase/index.ts +101 -37
  534. package/src/components/DraggerBase/types.ts +25 -3
  535. package/src/components/DraggerDirection/index.ts +12 -6
  536. package/src/components/DraggerDirection/types.ts +18 -1
  537. package/src/components/DraggerMove/index.ts +44 -13
  538. package/src/components/DraggerMove/types.ts +17 -2
  539. package/src/components/Marquee/index.ts +255 -186
  540. package/src/components/Marquee/stories/index.tsx +16 -2
  541. package/src/components/Marquee/types.ts +18 -8
  542. package/src/components/Preloader/index.ts +56 -20
  543. package/src/components/Preloader/types.ts +18 -5
  544. package/src/components/ProgressPreloader/index.ts +104 -48
  545. package/src/components/ProgressPreloader/types.ts +65 -14
  546. package/src/components/ProgressPreloader/utils/preloadCustomElement.ts +13 -2
  547. package/src/components/ScrollBar/Bar/index.ts +112 -62
  548. package/src/components/ScrollBar/Bar/types.ts +46 -17
  549. package/src/components/ScrollBar/index.ts +65 -20
  550. package/src/components/ScrollBar/stories/{WithSmoothScrollComponent.tsx → WithCustomScrollComponent.tsx} +5 -5
  551. package/src/components/ScrollBar/stories/index.stories.tsx +3 -3
  552. package/src/components/ScrollBar/types.ts +10 -6
  553. package/src/components/ScrollView/index.ts +73 -27
  554. package/src/components/ScrollView/stories/index.tsx +5 -2
  555. package/src/components/SectionScrollProgress/index.ts +97 -41
  556. package/src/components/SectionScrollProgress/stories/WithCustomScroll.tsx +6 -6
  557. package/src/components/SectionScrollProgress/types.ts +19 -6
  558. package/src/components/SlideProgress/index.ts +78 -45
  559. package/src/components/SlideProgress/types.ts +24 -15
  560. package/src/components/SplitText/index.ts +71 -31
  561. package/src/components/SplitText/types.ts +48 -8
  562. package/src/components/SplitText/utils/splitBase.ts +6 -2
  563. package/src/components/SplitText/utils/wrapLetters.ts +11 -3
  564. package/src/components/SplitText/utils/wrapLines.ts +11 -5
  565. package/src/components/SplitText/utils/wrapWords.ts +14 -3
  566. package/src/components/Timeline/index.ts +98 -26
  567. package/src/components/Timeline/stories/index.stories.tsx +0 -5
  568. package/src/components/Timeline/types.ts +37 -7
  569. package/src/components/index.ts +4 -4
  570. package/src/index.ts +14 -4
  571. package/src/styles/base.scss +0 -2
  572. package/src/styles/components/CustomCursor.scss +7 -7
  573. package/{lib/styles/components/SmoothScroll.scss → src/styles/components/CustomScroll.scss} +3 -3
  574. package/src/styles/components/Preloader.scss +1 -1
  575. package/src/styles/components/ScrollBar.scss +4 -4
  576. package/src/styles/components/index.scss +1 -1
  577. package/src/styles/index.scss +0 -1
  578. package/src/types/index.ts +2 -0
  579. package/src/types/utility.ts +2 -2
  580. package/src/utils/common/PCancelable.ts +17 -0
  581. package/src/utils/common/normalizedTimeoutCallback.ts +19 -4
  582. package/src/utils/common/objectKeys.ts +12 -2
  583. package/src/utils/common/pickObjectProps.ts +16 -4
  584. package/src/utils/common/times.ts +12 -3
  585. package/src/utils/common/uid.ts +5 -3
  586. package/src/utils/image/load.ts +9 -4
  587. package/src/utils/image/pathsToProps.ts +12 -5
  588. package/src/utils/image/sizesToSrcSet.ts +7 -3
  589. package/src/utils/internal/getApp.ts +25 -0
  590. package/src/utils/listeners/isIntersectionObserverSupported.ts +1 -1
  591. package/src/utils/listeners/onResize.ts +16 -21
  592. package/src/utils/math/clamp.ts +10 -5
  593. package/src/utils/math/clampScope.ts +9 -2
  594. package/src/utils/math/easing.ts +6 -2
  595. package/src/utils/math/inScope.ts +6 -3
  596. package/src/utils/math/lerp.ts +11 -3
  597. package/src/utils/math/normalizeNestedScope.ts +12 -3
  598. package/src/utils/math/scoped.ts +17 -6
  599. package/src/utils/math/spreadScope.ts +17 -3
  600. package/src/utils/math/wrap.ts +9 -3
  601. package/src/utils/scroll/getScrollValues.ts +13 -1
  602. package/src/utils/scroll/isPageScrolling.ts +31 -0
  603. package/src/utils/scroll/normalizeWheel.ts +10 -2
  604. package/src/utils/scroll/onScroll.ts +18 -11
  605. package/src/utils/scroll/scrollTo.ts +16 -10
  606. package/src/utils/scroll/scrollToElement.ts +9 -7
  607. package/src/version.ts +1 -1
  608. package/lib/cjs/Application/events/createOnPageLoad/index.js.map +0 -1
  609. package/lib/cjs/Application/events/createOnPageLoad/types.js.map +0 -1
  610. package/lib/cjs/Application/events/createViewport/index.js.map +0 -1
  611. package/lib/cjs/Application/events/createViewport/types.js.map +0 -1
  612. package/lib/cjs/Application/index.js +0 -222
  613. package/lib/cjs/Application/index.js.map +0 -1
  614. package/lib/cjs/components/BaseTimeline/index.js +0 -125
  615. package/lib/cjs/components/BaseTimeline/index.js.map +0 -1
  616. package/lib/cjs/components/BaseTimeline/types.js.map +0 -1
  617. package/lib/cjs/components/SmoothScroll/index.js.map +0 -1
  618. package/lib/cjs/components/SmoothScroll/types.js.map +0 -1
  619. package/lib/cjs/components/SmoothScrollDragPlugin/index.js.map +0 -1
  620. package/lib/cjs/components/SmoothScrollDragPlugin/types.js.map +0 -1
  621. package/lib/cjs/components/SmoothScrollKeyboardPlugin/index.js.map +0 -1
  622. package/lib/cjs/components/SmoothScrollKeyboardPlugin/types.js +0 -3
  623. package/lib/cjs/components/SmoothScrollKeyboardPlugin/types.js.map +0 -1
  624. package/lib/cjs/utils/internal/fetchWebpSupport.js.map +0 -1
  625. package/lib/cjs/utils/internal/getDeviceInfo.js.map +0 -1
  626. package/lib/cjs/vevet.js +0 -6
  627. package/lib/cjs/vevet.js.map +0 -1
  628. package/lib/esm/Application/events/createOnPageLoad/index.js.map +0 -1
  629. package/lib/esm/Application/events/createOnPageLoad/types.js.map +0 -1
  630. package/lib/esm/Application/events/createViewport/index.js.map +0 -1
  631. package/lib/esm/Application/events/createViewport/types.js.map +0 -1
  632. package/lib/esm/Application/index.js +0 -134
  633. package/lib/esm/Application/index.js.map +0 -1
  634. package/lib/esm/components/BaseTimeline/index.js +0 -75
  635. package/lib/esm/components/BaseTimeline/index.js.map +0 -1
  636. package/lib/esm/components/BaseTimeline/types.js.map +0 -1
  637. package/lib/esm/components/SmoothScroll/index.js.map +0 -1
  638. package/lib/esm/components/SmoothScroll/types.js.map +0 -1
  639. package/lib/esm/components/SmoothScrollDragPlugin/index.js.map +0 -1
  640. package/lib/esm/components/SmoothScrollDragPlugin/types.js.map +0 -1
  641. package/lib/esm/components/SmoothScrollKeyboardPlugin/index.js.map +0 -1
  642. package/lib/esm/components/SmoothScrollKeyboardPlugin/types.js +0 -2
  643. package/lib/esm/components/SmoothScrollKeyboardPlugin/types.js.map +0 -1
  644. package/lib/esm/utils/internal/fetchWebpSupport.js.map +0 -1
  645. package/lib/esm/utils/internal/getDeviceInfo.js.map +0 -1
  646. package/lib/esm/vevet.js +0 -3
  647. package/lib/esm/vevet.js.map +0 -1
  648. package/lib/styles/globals/index.scss +0 -18
  649. package/lib/types/Application/events/createOnPageLoad/index.d.ts +0 -5
  650. package/lib/types/Application/events/createOnPageLoad/index.d.ts.map +0 -1
  651. package/lib/types/Application/events/createOnPageLoad/types.d.ts +0 -5
  652. package/lib/types/Application/events/createOnPageLoad/types.d.ts.map +0 -1
  653. package/lib/types/Application/events/createViewport/index.d.ts +0 -20
  654. package/lib/types/Application/events/createViewport/index.d.ts.map +0 -1
  655. package/lib/types/Application/events/createViewport/types.d.ts +0 -52
  656. package/lib/types/Application/events/createViewport/types.d.ts.map +0 -1
  657. package/lib/types/Application/index.d.ts +0 -89
  658. package/lib/types/Application/index.d.ts.map +0 -1
  659. package/lib/types/Application/types.d.ts +0 -41
  660. package/lib/types/Application/types.d.ts.map +0 -1
  661. package/lib/types/components/BaseTimeline/index.d.ts +0 -40
  662. package/lib/types/components/BaseTimeline/index.d.ts.map +0 -1
  663. package/lib/types/components/BaseTimeline/types.d.ts +0 -34
  664. package/lib/types/components/BaseTimeline/types.d.ts.map +0 -1
  665. package/lib/types/components/SmoothScroll/index.d.ts.map +0 -1
  666. package/lib/types/components/SmoothScroll/types.d.ts +0 -105
  667. package/lib/types/components/SmoothScroll/types.d.ts.map +0 -1
  668. package/lib/types/components/SmoothScrollDragPlugin/index.d.ts +0 -50
  669. package/lib/types/components/SmoothScrollDragPlugin/index.d.ts.map +0 -1
  670. package/lib/types/components/SmoothScrollDragPlugin/types.d.ts +0 -39
  671. package/lib/types/components/SmoothScrollDragPlugin/types.d.ts.map +0 -1
  672. package/lib/types/components/SmoothScrollKeyboardPlugin/index.d.ts +0 -31
  673. package/lib/types/components/SmoothScrollKeyboardPlugin/index.d.ts.map +0 -1
  674. package/lib/types/components/SmoothScrollKeyboardPlugin/types.d.ts +0 -12
  675. package/lib/types/utils/internal/fetchWebpSupport.d.ts +0 -3
  676. package/lib/types/utils/internal/fetchWebpSupport.d.ts.map +0 -1
  677. package/lib/types/utils/internal/getDeviceInfo.d.ts.map +0 -1
  678. package/lib/types/vevet.d.ts +0 -3
  679. package/lib/types/vevet.d.ts.map +0 -1
  680. package/src/Application/events/createOnPageLoad/types.ts +0 -5
  681. package/src/Application/events/createViewport/types.ts +0 -55
  682. package/src/Application/index.ts +0 -204
  683. package/src/Application/types.ts +0 -41
  684. package/src/components/BaseTimeline/index.ts +0 -123
  685. package/src/components/BaseTimeline/stories/Basic.tsx +0 -65
  686. package/src/components/BaseTimeline/stories/Nested.tsx +0 -108
  687. package/src/components/BaseTimeline/stories/index.stories.tsx +0 -16
  688. package/src/components/BaseTimeline/types.ts +0 -36
  689. package/src/components/SmoothScroll/types.ts +0 -114
  690. package/src/components/SmoothScrollDragPlugin/types.ts +0 -40
  691. package/src/components/Timeline/stories/Nested.tsx +0 -135
  692. package/src/styles/globals/index.scss +0 -18
  693. package/src/vevet.ts +0 -4
  694. /package/lib/cjs/{Application → Vevet}/events/createOnPageLoad/types.js +0 -0
  695. /package/lib/cjs/{Application → Vevet}/events/createViewport/types.js +0 -0
  696. /package/lib/cjs/{Application → Vevet}/types.js +0 -0
  697. /package/lib/cjs/{utils/internal → Vevet/utils}/getDeviceInfo.js +0 -0
  698. /package/lib/cjs/components/{BaseTimeline → CustomScroll}/types.js +0 -0
  699. /package/lib/cjs/components/{SmoothScroll → CustomScrollDragPlugin}/types.js +0 -0
  700. /package/lib/cjs/components/{SmoothScrollDragPlugin → CustomScrollKeyboardPlugin}/types.js +0 -0
  701. /package/lib/esm/{Application → Vevet}/events/createOnPageLoad/types.js +0 -0
  702. /package/lib/esm/{Application → Vevet}/events/createViewport/types.js +0 -0
  703. /package/lib/esm/{Application → Vevet}/types.js +0 -0
  704. /package/lib/esm/{utils/internal → Vevet/utils}/getDeviceInfo.js +0 -0
  705. /package/lib/esm/components/{BaseTimeline → CustomScroll}/types.js +0 -0
  706. /package/lib/esm/components/{SmoothScroll → CustomScrollDragPlugin}/types.js +0 -0
  707. /package/lib/esm/components/{SmoothScrollDragPlugin → CustomScrollKeyboardPlugin}/types.js +0 -0
  708. /package/lib/types/{utils/internal → Vevet/utils}/getDeviceInfo.d.ts +0 -0
  709. /package/lib/types/components/{SmoothScroll → CustomScroll}/AnimatonFrame.d.ts +0 -0
  710. /package/src/{Application → Vevet}/events/.eslintrc +0 -0
  711. /package/src/{Application → Vevet}/events/createViewport/stories/index.stories.tsx +0 -0
  712. /package/src/{Application → Vevet}/stories/index.stories.tsx +0 -0
  713. /package/src/{utils/internal → Vevet/utils}/fetchWebpSupport.ts +0 -0
  714. /package/src/{utils/internal → Vevet/utils}/getDeviceInfo.ts +0 -0
@@ -1,81 +1,121 @@
1
1
  import { NComponent } from '../../base/Component/types';
2
2
  export declare namespace NCustomCursor {
3
+ /**
4
+ * Static properties that do not change after initialization.
5
+ */
3
6
  interface IStaticProps extends NComponent.IStaticProps {
4
7
  /**
5
- * Cursor parent element
8
+ * The container where the custom cursor will be active.
9
+ * Can be the `window`, a specific DOM element, or a string selector.
6
10
  * @default window
7
11
  */
8
12
  container: Window | Element | string;
9
13
  /**
10
- * If need to hide the native cursor
14
+ * Determines whether the native cursor should be hidden.
11
15
  * @default false
12
16
  */
13
17
  isNativeCursorHidden?: boolean;
14
18
  }
19
+ /**
20
+ * Changeable properties that can be updated dynamically during the lifecycle of the custom cursor.
21
+ */
15
22
  interface IChangeableProps extends NComponent.IChangeableProps {
16
23
  /**
17
- * Custom cursor is enabled
24
+ * Enables or disables the custom cursor.
18
25
  * @default true
19
26
  */
20
27
  isEnabled?: boolean;
21
28
  /**
29
+ * The width of the custom cursor.
22
30
  * @default 50
23
31
  */
24
32
  width?: number;
25
33
  /**
34
+ * The height of the custom cursor.
26
35
  * @default 50
27
36
  */
28
37
  height?: number;
29
38
  /**
30
- * Coords linear interpolation
39
+ * Linear interpolation factor for smooth cursor movement.
40
+ * A value between `0` and `1` where higher values result in faster movement.
31
41
  * @default 0.2
32
42
  */
33
43
  lerp?: number;
34
44
  /**
35
- * On different screens with different FPS, animation may be slower or faster.
36
- * This property is to normalize animation speed across different screens.
45
+ * Normalizes the animation speed across different screens with varying FPS.
46
+ * Ensures consistent movement speed across different devices.
37
47
  * @default true
38
48
  */
39
49
  isFpsNormalized?: boolean;
40
50
  /**
41
- * Automatically stop rendering after the target and current values are approximated.
51
+ * Automatically stops rendering the cursor once the target coordinates and size
52
+ * approximate the current ones closely enough.
42
53
  * @default true
43
54
  */
44
55
  shouldAutoStop?: boolean;
45
56
  }
57
+ /**
58
+ * Types of callbacks available for the custom cursor component.
59
+ */
46
60
  interface ICallbacksTypes extends NComponent.ICallbacksTypes {
61
+ /**
62
+ * Triggered when the custom cursor is created.
63
+ * Provides access to the outer and inner HTML elements of the cursor.
64
+ */
47
65
  create: {
48
66
  outerElement: HTMLElement;
49
67
  innerElement: HTMLElement;
50
68
  };
69
+ /**
70
+ * Triggered on each render to update the cursor's position.
71
+ * Provides the current x and y coordinates.
72
+ */
51
73
  render: IVector2;
52
74
  }
75
+ /**
76
+ * Represents 2D vector coordinates for cursor position (x, y).
77
+ */
53
78
  interface IVector2 {
54
79
  x: number;
55
80
  y: number;
56
81
  }
82
+ /**
83
+ * Describes the cursor’s coordinates and size for rendering.
84
+ */
57
85
  interface ICoords {
58
86
  x: number;
59
87
  y: number;
60
88
  width: number;
61
89
  height: number;
62
90
  }
91
+ /**
92
+ * Information about the hovered element, which can affect cursor behavior.
93
+ */
63
94
  interface IHoveredElement {
64
- /** Hovered element */
95
+ /**
96
+ * The element currently being hovered over.
97
+ */
65
98
  element: Element;
66
- /** Hover ist sticky */
99
+ /**
100
+ * Whether the hover state should "stick" to the element,
101
+ * meaning the cursor remains over the element even after moving away.
102
+ */
67
103
  isSticky?: boolean;
68
104
  /**
69
- * Target cursor width
105
+ * The target width of the cursor when hovering over this element.
106
+ * Can be set to a specific number, `false` (no change), or `auto`.
70
107
  * @default 'auto'
71
108
  */
72
109
  width?: false | number | 'auto';
73
110
  /**
74
- * Target cursor height
111
+ * The target height of the cursor when hovering over this element.
112
+ * Can be set to a specific number, `false` (no change), or `auto`.
75
113
  * @default 'auto'
76
114
  */
77
115
  height?: false | number | 'auto';
78
- /** Target cursor padding */
116
+ /**
117
+ * Padding around the cursor when hovering over this element.
118
+ */
79
119
  padding?: number;
80
120
  }
81
121
  }
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/CustomCursor/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAEpD,yBAAiB,aAAa,CAAC;IAC7B,UAAiB,YAAa,SAAQ,UAAU,CAAC,YAAY;QAC3D;;;WAGG;QACH,SAAS,EAAE,MAAM,GAAG,OAAO,GAAG,MAAM,CAAC;QACrC;;;WAGG;QACH,oBAAoB,CAAC,EAAE,OAAO,CAAC;KAChC;IAED,UAAiB,gBAAiB,SAAQ,UAAU,CAAC,gBAAgB;QACnE;;;WAGG;QACH,SAAS,CAAC,EAAE,OAAO,CAAC;QACpB;;WAEG;QACH,KAAK,CAAC,EAAE,MAAM,CAAC;QACf;;WAEG;QACH,MAAM,CAAC,EAAE,MAAM,CAAC;QAChB;;;WAGG;QACH,IAAI,CAAC,EAAE,MAAM,CAAC;QACd;;;;WAIG;QACH,eAAe,CAAC,EAAE,OAAO,CAAC;QAC1B;;;WAGG;QACH,cAAc,CAAC,EAAE,OAAO,CAAC;KAC1B;IAED,UAAiB,eAAgB,SAAQ,UAAU,CAAC,eAAe;QACjE,MAAM,EAAE;YACN,YAAY,EAAE,WAAW,CAAC;YAC1B,YAAY,EAAE,WAAW,CAAC;SAC3B,CAAC;QACF,MAAM,EAAE,QAAQ,CAAC;KAClB;IAED,UAAiB,QAAQ;QACvB,CAAC,EAAE,MAAM,CAAC;QACV,CAAC,EAAE,MAAM,CAAC;KACX;IAED,UAAiB,OAAO;QACtB,CAAC,EAAE,MAAM,CAAC;QACV,CAAC,EAAE,MAAM,CAAC;QACV,KAAK,EAAE,MAAM,CAAC;QACd,MAAM,EAAE,MAAM,CAAC;KAChB;IAED,UAAiB,eAAe;QAC9B,sBAAsB;QACtB,OAAO,EAAE,OAAO,CAAC;QACjB,uBAAuB;QACvB,QAAQ,CAAC,EAAE,OAAO,CAAC;QACnB;;;WAGG;QACH,KAAK,CAAC,EAAE,KAAK,GAAG,MAAM,GAAG,MAAM,CAAC;QAChC;;;WAGG;QACH,MAAM,CAAC,EAAE,KAAK,GAAG,MAAM,GAAG,MAAM,CAAC;QACjC,4BAA4B;QAC5B,OAAO,CAAC,EAAE,MAAM,CAAC;KAClB;CACF"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/CustomCursor/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAEpD,yBAAiB,aAAa,CAAC;IAC7B;;OAEG;IACH,UAAiB,YAAa,SAAQ,UAAU,CAAC,YAAY;QAC3D;;;;WAIG;QACH,SAAS,EAAE,MAAM,GAAG,OAAO,GAAG,MAAM,CAAC;QAErC;;;WAGG;QACH,oBAAoB,CAAC,EAAE,OAAO,CAAC;KAChC;IAED;;OAEG;IACH,UAAiB,gBAAiB,SAAQ,UAAU,CAAC,gBAAgB;QACnE;;;WAGG;QACH,SAAS,CAAC,EAAE,OAAO,CAAC;QAEpB;;;WAGG;QACH,KAAK,CAAC,EAAE,MAAM,CAAC;QAEf;;;WAGG;QACH,MAAM,CAAC,EAAE,MAAM,CAAC;QAEhB;;;;WAIG;QACH,IAAI,CAAC,EAAE,MAAM,CAAC;QAEd;;;;WAIG;QACH,eAAe,CAAC,EAAE,OAAO,CAAC;QAE1B;;;;WAIG;QACH,cAAc,CAAC,EAAE,OAAO,CAAC;KAC1B;IAED;;OAEG;IACH,UAAiB,eAAgB,SAAQ,UAAU,CAAC,eAAe;QACjE;;;WAGG;QACH,MAAM,EAAE;YACN,YAAY,EAAE,WAAW,CAAC;YAC1B,YAAY,EAAE,WAAW,CAAC;SAC3B,CAAC;QAEF;;;WAGG;QACH,MAAM,EAAE,QAAQ,CAAC;KAClB;IAED;;OAEG;IACH,UAAiB,QAAQ;QACvB,CAAC,EAAE,MAAM,CAAC;QACV,CAAC,EAAE,MAAM,CAAC;KACX;IAED;;OAEG;IACH,UAAiB,OAAO;QACtB,CAAC,EAAE,MAAM,CAAC;QACV,CAAC,EAAE,MAAM,CAAC;QACV,KAAK,EAAE,MAAM,CAAC;QACd,MAAM,EAAE,MAAM,CAAC;KAChB;IAED;;OAEG;IACH,UAAiB,eAAe;QAC9B;;WAEG;QACH,OAAO,EAAE,OAAO,CAAC;QAEjB;;;WAGG;QACH,QAAQ,CAAC,EAAE,OAAO,CAAC;QAEnB;;;;WAIG;QACH,KAAK,CAAC,EAAE,KAAK,GAAG,MAAM,GAAG,MAAM,CAAC;QAEhC;;;;WAIG;QACH,MAAM,CAAC,EAAE,KAAK,GAAG,MAAM,GAAG,MAAM,CAAC;QAEjC;;WAEG;QACH,OAAO,CAAC,EAAE,MAAM,CAAC;KAClB;CACF"}
@@ -1 +1 @@
1
- {"version":3,"file":"AnimatonFrame.d.ts","sourceRoot":"","sources":["../../../../src/components/SmoothScroll/AnimatonFrame.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,IAAI,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAG1E,UAAU,MAAM;IACd,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,GAAG,EAAE,mBAAmB,GAAG,KAAK,CAAC;CAClC;AAED,qBAAa,cAAc;IAkBb,OAAO,CAAC,MAAM;IAjB1B,4BAA4B;IAC5B,OAAO,CAAC,IAAI,CAAC,CAAsB;IAEnC,OAAO,CAAC,MAAM,CAAC,CAA4B;IAE3C,OAAO,KAAK,GAAG,GAEd;IAED,IAAI,IAAI,WAEP;IAED,OAAO,KAAK,KAAK,GAEhB;gBAEmB,MAAM,EAAE,MAAM;IAE3B,MAAM;IAwBb,wBAAwB;IACjB,OAAO;IAOP,OAAO;CAKf"}
1
+ {"version":3,"file":"AnimatonFrame.d.ts","sourceRoot":"","sources":["../../../../src/components/CustomScroll/AnimatonFrame.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,cAAc,IAAI,mBAAmB,EAAE,MAAM,mBAAmB,CAAC;AAG1E,UAAU,MAAM;IACd,QAAQ,EAAE,MAAM,IAAI,CAAC;IACrB,GAAG,EAAE,mBAAmB,GAAG,KAAK,CAAC;CAClC;AAED,qBAAa,cAAc;IAkBb,OAAO,CAAC,MAAM;IAjB1B,4BAA4B;IAC5B,OAAO,CAAC,IAAI,CAAC,CAAsB;IAEnC,OAAO,CAAC,MAAM,CAAC,CAA4B;IAE3C,OAAO,KAAK,GAAG,GAEd;IAED,IAAI,IAAI,WAEP;IAED,OAAO,KAAK,KAAK,GAEhB;gBAEmB,MAAM,EAAE,MAAM;IAE3B,MAAM;IAwBb,wBAAwB;IACjB,OAAO;IAOP,OAAO;CAKf"}
@@ -1,6 +1,6 @@
1
- import { NSmoothScroll } from './types';
1
+ import { NCustomScroll } from './types';
2
2
  type TPickedProps = 'elements' | 'hasWillChange' | 'translatePrecision';
3
- interface IProps extends Required<Pick<NSmoothScroll.IStaticProps, TPickedProps>> {
3
+ interface IProps extends Required<Pick<NCustomScroll.IStaticProps, TPickedProps>> {
4
4
  container: Element;
5
5
  wrapperClassName: string;
6
6
  }
@@ -10,7 +10,7 @@ export declare class Elements {
10
10
  get wrapper(): HTMLElement;
11
11
  private _wrapperExists;
12
12
  private _elements;
13
- get elements(): NSmoothScroll.IElement[];
13
+ get elements(): NCustomScroll.IElement[];
14
14
  get props(): IProps;
15
15
  constructor(_props: IProps);
16
16
  /** Create scrollable wrapper */
@@ -1 +1 @@
1
- {"version":3,"file":"Elements.d.ts","sourceRoot":"","sources":["../../../../src/components/SmoothScroll/Elements.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAExC,KAAK,YAAY,GAAG,UAAU,GAAG,eAAe,GAAG,oBAAoB,CAAC;AAExE,UAAU,MACR,SAAQ,QAAQ,CAAC,IAAI,CAAC,aAAa,CAAC,YAAY,EAAE,YAAY,CAAC,CAAC;IAChE,SAAS,EAAE,OAAO,CAAC;IACnB,gBAAgB,EAAE,MAAM,CAAC;CAC1B;AAED,qBAAa,QAAQ;IAmBP,OAAO,CAAC,MAAM;IAlB1B,OAAO,CAAC,QAAQ,CAAe;IAE/B,IAAI,OAAO,gBAEV;IAED,OAAO,CAAC,cAAc,CAAW;IAEjC,OAAO,CAAC,SAAS,CAA4B;IAE7C,IAAI,QAAQ,6BAEX;IAED,IAAI,KAAK,WAER;gBAEmB,MAAM,EAAE,MAAM;IAKlC,gCAAgC;IAChC,OAAO,CAAC,cAAc;IAqBtB,iCAAiC;IACjC,OAAO,CAAC,eAAe;IAqBvB,kCAAkC;IAC3B,WAAW,CAAC,UAAU,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM;IAgBxD,OAAO,CAAC,WAAW;IAUnB,sBAAsB;IACf,MAAM;IAWb,8CAA8C;IACvC,UAAU;IAUV,OAAO;CAkBf"}
1
+ {"version":3,"file":"Elements.d.ts","sourceRoot":"","sources":["../../../../src/components/CustomScroll/Elements.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AAExC,KAAK,YAAY,GAAG,UAAU,GAAG,eAAe,GAAG,oBAAoB,CAAC;AAExE,UAAU,MACR,SAAQ,QAAQ,CAAC,IAAI,CAAC,aAAa,CAAC,YAAY,EAAE,YAAY,CAAC,CAAC;IAChE,SAAS,EAAE,OAAO,CAAC;IACnB,gBAAgB,EAAE,MAAM,CAAC;CAC1B;AAED,qBAAa,QAAQ;IAmBP,OAAO,CAAC,MAAM;IAlB1B,OAAO,CAAC,QAAQ,CAAe;IAE/B,IAAI,OAAO,gBAEV;IAED,OAAO,CAAC,cAAc,CAAW;IAEjC,OAAO,CAAC,SAAS,CAA4B;IAE7C,IAAI,QAAQ,6BAEX;IAED,IAAI,KAAK,WAER;gBAEmB,MAAM,EAAE,MAAM;IAKlC,gCAAgC;IAChC,OAAO,CAAC,cAAc;IAqBtB,iCAAiC;IACjC,OAAO,CAAC,eAAe;IAqBvB,kCAAkC;IAC3B,WAAW,CAAC,UAAU,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM;IAgBxD,OAAO,CAAC,WAAW;IAUnB,sBAAsB;IACf,MAAM;IAWb,8CAA8C;IACvC,UAAU;IAUV,OAAO;CAkBf"}
@@ -1,14 +1,17 @@
1
1
  /// <reference types="node" />
2
2
  import { Component as ComponentClass } from '../../base/Component';
3
- import { NSmoothScroll } from './types';
3
+ import { NCustomScroll } from './types';
4
4
  import { IScrollLike } from '../../types/general';
5
5
  import { Elements } from './Elements';
6
6
  import { AnimationFrame } from './AnimatonFrame';
7
- export type { NSmoothScroll };
7
+ export type { NCustomScroll };
8
8
  /**
9
- * Smooth scrolling
9
+ * Custom smooth scrolling component that replaces native scrolling behavior.
10
+ * It provides smooth interpolation, custom scroll events, and integration with other elements.
11
+ *
12
+ * @requires Requires styles: `@import '~vevet/lib/styles/components/CustomScroll';`
10
13
  */
11
- export declare class SmoothScroll<StaticProps extends NSmoothScroll.IStaticProps = NSmoothScroll.IStaticProps, ChangeableProps extends NSmoothScroll.IChangeableProps = NSmoothScroll.IChangeableProps, CallbacksTypes extends NSmoothScroll.ICallbacksTypes = NSmoothScroll.ICallbacksTypes> extends ComponentClass<StaticProps, ChangeableProps, CallbacksTypes> implements IScrollLike {
14
+ export declare class CustomScroll<StaticProps extends NCustomScroll.IStaticProps = NCustomScroll.IStaticProps, ChangeableProps extends NCustomScroll.IChangeableProps = NCustomScroll.IChangeableProps, CallbacksTypes extends NCustomScroll.ICallbacksTypes = NCustomScroll.ICallbacksTypes> extends ComponentClass<StaticProps, ChangeableProps, CallbacksTypes> implements IScrollLike {
12
15
  protected _getDefaultProps(): {
13
16
  container: string;
14
17
  elements: boolean;
@@ -19,6 +22,7 @@ export declare class SmoothScroll<StaticProps extends NSmoothScroll.IStaticProps
19
22
  translatePrecision: number;
20
23
  isEnabled: boolean;
21
24
  hasWheel: boolean;
25
+ wheelSpeed: number;
22
26
  direction: string;
23
27
  isInversedHandlerDirection: boolean;
24
28
  shouldAutoStop: boolean;
@@ -28,79 +32,89 @@ export declare class SmoothScroll<StaticProps extends NSmoothScroll.IStaticProps
28
32
  lerpApproximation: number;
29
33
  };
30
34
  get prefix(): string;
31
- /** Scroll container */
35
+ /** Scroll container element */
32
36
  protected _container: HTMLElement;
33
- /** Scroll container */
37
+ /** Scroll container element */
34
38
  get container(): HTMLElement;
39
+ /**
40
+ * Internal handler for the scroll elements
41
+ * @ignore
42
+ */
35
43
  protected _elements: Elements;
36
44
  /**
37
- * Scroll wrapper. If the element does not exist indide the `container`,
38
- * it will be created automatically
45
+ * Scroll wrapper. If the element does not exist indide the `container`, it will be created automatically
39
46
  */
40
47
  get wrapper(): HTMLElement;
41
- /** `scrollLeft` target value */
48
+ /** The `scrollLeft` target value */
42
49
  protected _targetLeft: number;
43
- /** `scrollLeft` target value */
50
+ /** The `scrollLeft` target value */
44
51
  get targetLeft(): number;
45
52
  set targetLeft(value: number);
46
53
  /** Update `targetLeft` without animation */
47
54
  protected setTargetLeft(value: number): void;
48
- /** `scrollTop` target value */
55
+ /** The `scrollTop` target value */
49
56
  protected _targetTop: number;
50
- /** `scrollTop` target value */
57
+ /** The `scrollTop` target value */
51
58
  get targetTop(): number;
52
59
  set targetTop(value: number);
53
60
  /** Update `targetTop` without animation */
54
61
  protected setTargetTop(value: number): void;
55
- /** `scrollLeft` */
62
+ /** The current `scrollLeft` value */
56
63
  protected _scrollLeft: number;
57
- /** `scrollLeft` */
64
+ /** The current `scrollLeft` value */
58
65
  get scrollLeft(): number;
59
66
  set scrollLeft(value: number);
60
- /** `scrollTop` */
67
+ /** The current `scrollTop` value */
61
68
  protected _scrollTop: number;
62
- /** `scrollTop` */
69
+ /** The current `scrollTop` value */
63
70
  get scrollTop(): number;
64
71
  set scrollTop(value: number);
65
- /** Scroll width */
72
+ /** The scroll width of the container */
66
73
  protected _scrollWidth: number;
67
- /** Scroll width */
74
+ /** The scroll width of the container */
68
75
  get scrollWidth(): number;
69
- /** Scroll height */
76
+ /** The scroll height of the container */
70
77
  protected _scrollHeight: number;
71
- /** Scroll height */
78
+ /** The scroll width of the container */
72
79
  get scrollHeight(): number;
73
- /** Container width */
80
+ /** The container width */
74
81
  protected _clientWidth: number;
75
- /** Container width */
82
+ /** The container width */
76
83
  get clientWidth(): number;
77
- /** Container height */
84
+ /** The container height */
78
85
  protected _clientHeight: number;
79
- /** Container height */
86
+ /** The container height */
80
87
  get clientHeight(): number;
81
- /** Wrapper width */
88
+ /** The wrapper width */
82
89
  protected _wrapperWidth: number;
83
- /** Wrapper height */
90
+ /** The wrapper height */
84
91
  protected _wrapperHeight: number;
85
92
  /** Maximum scrollable area of the X axis */
86
93
  get maxScrollableWidth(): number;
87
94
  /** Maximum scrollable area of the Y axis */
88
95
  get maxScrollableHeight(): number;
89
- /** Has scroll */
96
+ /** The container has scroll */
90
97
  get hasScroll(): boolean;
91
98
  /** If the approximation between the target and current scroll values must be instantaneous */
92
99
  protected _isInstant?: boolean;
93
- /** Animation frame */
100
+ /**
101
+ * Animation frame
102
+ * @ignore
103
+ */
94
104
  protected _raf: AnimationFrame;
95
105
  /** Frame index */
96
106
  protected _frameIndex: number;
97
- /** Equal lerp for all elements */
107
+ /** Use equal lerp for all elements */
98
108
  protected _isEqualLerp: boolean;
99
- /** `_disable` timeout */
109
+ /** Disable timeout */
100
110
  protected _disableDelayDebounce?: NodeJS.Timeout;
101
- get isSmoothScroll(): boolean;
111
+ /** If the component is a custom scroll */
112
+ get isCustomScroll(): boolean;
102
113
  constructor(initialProps?: StaticProps & ChangeableProps, canInit?: boolean);
103
114
  protected _init(): void;
115
+ /**
116
+ * Sets the class names for the elements.
117
+ */
104
118
  protected _setClassNames(isActive: boolean): void;
105
119
  /** Set events */
106
120
  protected _setEvents(): void;
@@ -135,7 +149,7 @@ export declare class SmoothScroll<StaticProps extends NSmoothScroll.IStaticProps
135
149
  /** Interpolate values */
136
150
  protected _lerp(current: number, target: number, ease?: number): number;
137
151
  /** Get lerp */
138
- protected _getLerp(element?: NSmoothScroll.IElement): number;
152
+ protected _getLerp(element?: NCustomScroll.IElement): number;
139
153
  /** Scroll to */
140
154
  scrollTo({ top, left, behavior }: ScrollToOptions): void;
141
155
  /** Destroy the module */
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/CustomScroll/index.ts"],"names":[],"mappings":";AACA,OAAO,EAAE,SAAS,IAAI,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAC/D,OAAO,EAAE,aAAa,EAAE,MAAM,SAAS,CAAC;AACxC,OAAO,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAG9C,OAAO,EAAE,QAAQ,EAAE,MAAM,YAAY,CAAC;AACtC,OAAO,EAAE,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAIjD,YAAY,EAAE,aAAa,EAAE,CAAC;AAE9B;;;;;GAKG;AACH,qBAAa,YAAY,CACrB,WAAW,SAAS,aAAa,CAAC,YAAY,GAAG,aAAa,CAAC,YAAY,EAC3E,eAAe,SACb,aAAa,CAAC,gBAAgB,GAAG,aAAa,CAAC,gBAAgB,EACjE,cAAc,SACZ,aAAa,CAAC,eAAe,GAAG,aAAa,CAAC,eAAe,CAEjE,SAAQ,cAAc,CAAC,WAAW,EAAE,eAAe,EAAE,cAAc,CACnE,YAAW,WAAW;IAEtB,SAAS,CAAC,gBAAgB;;;;;;;;;;;;;;;;;;;IAuB1B,IAAI,MAAM,WAET;IAED,+BAA+B;IAC/B,SAAS,CAAC,UAAU,EAAE,WAAW,CAAC;IAElC,+BAA+B;IAC/B,IAAI,SAAS,gBAEZ;IAED;;;OAGG;IACH,SAAS,CAAC,SAAS,EAAE,QAAQ,CAAC;IAE9B;;OAEG;IACH,IAAI,OAAO,gBAEV;IAED,oCAAoC;IACpC,SAAS,CAAC,WAAW,EAAE,MAAM,CAAC;IAE9B,oCAAoC;IACpC,IAAI,UAAU,WAEb;IAED,IAAI,UAAU,CAAC,KAAK,QAAA,EAGnB;IAED,4CAA4C;IAC5C,SAAS,CAAC,aAAa,CAAC,KAAK,EAAE,MAAM;IAIrC,mCAAmC;IACnC,SAAS,CAAC,UAAU,EAAE,MAAM,CAAC;IAE7B,mCAAmC;IACnC,IAAI,SAAS,WAEZ;IAED,IAAI,SAAS,CAAC,KAAK,QAAA,EAGlB;IAED,2CAA2C;IAC3C,SAAS,CAAC,YAAY,CAAC,KAAK,EAAE,MAAM;IAIpC,qCAAqC;IACrC,SAAS,CAAC,WAAW,EAAE,MAAM,CAAC;IAE9B,qCAAqC;IACrC,IAAI,UAAU,WAEb;IAED,IAAI,UAAU,CAAC,KAAK,QAAA,EAQnB;IAED,oCAAoC;IACpC,SAAS,CAAC,UAAU,EAAE,MAAM,CAAC;IAE7B,oCAAoC;IACpC,IAAI,SAAS,WAEZ;IAED,IAAI,SAAS,CAAC,KAAK,QAAA,EAQlB;IAED,wCAAwC;IACxC,SAAS,CAAC,YAAY,EAAE,MAAM,CAAC;IAE/B,wCAAwC;IACxC,IAAI,WAAW,WAEd;IAED,yCAAyC;IACzC,SAAS,CAAC,aAAa,EAAE,MAAM,CAAC;IAEhC,wCAAwC;IACxC,IAAI,YAAY,WAEf;IAED,0BAA0B;IAC1B,SAAS,CAAC,YAAY,EAAE,MAAM,CAAC;IAE/B,0BAA0B;IAC1B,IAAI,WAAW,WAEd;IAED,2BAA2B;IAC3B,SAAS,CAAC,aAAa,EAAE,MAAM,CAAC;IAEhC,2BAA2B;IAC3B,IAAI,YAAY,WAEf;IAED,wBAAwB;IACxB,SAAS,CAAC,aAAa,EAAE,MAAM,CAAC;IAEhC,yBAAyB;IACzB,SAAS,CAAC,cAAc,EAAE,MAAM,CAAC;IAEjC,4CAA4C;IAC5C,IAAI,kBAAkB,WAErB;IAED,4CAA4C;IAC5C,IAAI,mBAAmB,WAEtB;IAED,+BAA+B;IAC/B,IAAI,SAAS,YAEZ;IAED,8FAA8F;IAC9F,SAAS,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;IAE/B;;;OAGG;IACH,SAAS,CAAC,IAAI,EAAE,cAAc,CAAC;IAE/B,kBAAkB;IAClB,SAAS,CAAC,WAAW,EAAE,MAAM,CAAC;IAE9B,sCAAsC;IACtC,SAAS,CAAC,YAAY,EAAE,OAAO,CAAC;IAEhC,sBAAsB;IACtB,SAAS,CAAC,qBAAqB,CAAC,EAAE,MAAM,CAAC,OAAO,CAAC;IAEjD,0CAA0C;IAC1C,IAAI,cAAc,YAEjB;gBAEW,YAAY,CAAC,EAAE,WAAW,GAAG,eAAe,EAAE,OAAO,UAAO;IAwDxE,SAAS,CAAC,KAAK;IAOf;;OAEG;IACH,SAAS,CAAC,cAAc,CAAC,QAAQ,EAAE,OAAO;IAU1C,iBAAiB;IACjB,SAAS,CAAC,UAAU;IAepB,wBAAwB;IACxB,SAAS,CAAC,UAAU;IA8BpB,iCAAiC;IACjC,SAAS,CAAC,cAAc;IASxB,+BAA+B;IAC/B,SAAS,CAAC,YAAY;IAWtB,uBAAuB;IAChB,MAAM,CAAC,QAAQ,UAAQ;IAU9B,uBAAuB;IACvB,SAAS,CAAC,OAAO;IACf,yDAAyD;IACzD,QAAQ,UAAQ;IAuClB,qBAAqB;IACd,WAAW,CAAC,KAAK,EAAE,UAAU;IA0CpC,mDAAmD;IACnD,SAAS,CAAC,OAAO;IAQjB,uBAAuB;IACvB,SAAS,CAAC,OAAO;IAQjB,wBAAwB;IACxB,SAAS,CAAC,QAAQ;IAIlB,sBAAsB;IACf,MAAM;IAsBb,8BAA8B;IAC9B,SAAS,CAAC,iBAAiB;IAK3B,iCAAiC;IACjC,SAAS,CAAC,mBAAmB;IAqB7B,gEAAgE;IAChE,SAAS,CAAC,cAAc;IAgBxB,yBAAyB;IACzB,SAAS,CAAC,KAAK,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,IAAI,SAAkB;IASvE,eAAe;IACf,SAAS,CAAC,QAAQ,CAAC,OAAO,CAAC,EAAE,aAAa,CAAC,QAAQ;IAYnD,gBAAgB;IACT,QAAQ,CAAC,EAAE,GAAG,EAAE,IAAI,EAAE,QAAQ,EAAE,EAAE,eAAe;IAsBxD,yBAAyB;IACzB,SAAS,CAAC,QAAQ;CAcnB"}
@@ -0,0 +1,137 @@
1
+ import { NComponent } from '../../base/Component/types';
2
+ import { AnimationFrame } from '../AnimationFrame';
3
+ import { TOnResizeTarget } from '../../utils/listeners/onResize';
4
+ export declare namespace NCustomScroll {
5
+ interface IStaticProps extends NComponent.IStaticProps {
6
+ /**
7
+ * Selector or HTMLElement for the scrollable container.
8
+ * @default '#v-custom-scroll'
9
+ */
10
+ container?: string | HTMLElement;
11
+ /**
12
+ * Defines the scrollable elements inside the wrapper. Can be a selector, a list of elements, or a single element.
13
+ * If set to `false`, no specific elements are defined.
14
+ * @default false
15
+ */
16
+ elements?: false | string | NodeListOf<HTMLElement> | HTMLElement | HTMLElement[];
17
+ /**
18
+ * Optional `AnimationFrame` instance to control scrolling animation externally.
19
+ * @default false
20
+ */
21
+ animationFrame?: false | AnimationFrame;
22
+ /**
23
+ * Target for the viewport resize event.
24
+ * @default 'any'
25
+ */
26
+ viewportTarget?: TOnResizeTarget;
27
+ /**
28
+ * Timeout value for the resize event, useful for debouncing resize calculations.
29
+ * @default 0
30
+ */
31
+ resizeDebounce?: number;
32
+ /**
33
+ * If `true`, the `will-change` CSS property will be applied to the scrollable elements to improve performance.
34
+ * @default true
35
+ */
36
+ hasWillChange?: boolean;
37
+ /**
38
+ * Sets precision for the `transform` property by limiting the number of decimal places.
39
+ * Helps prevent choppy scrolling caused by large decimal values in transforms.
40
+ * Set to `false` to disable precision rounding.
41
+ * @default 2
42
+ */
43
+ translatePrecision?: false | number;
44
+ }
45
+ interface IChangeableProps extends NComponent.IChangeableProps {
46
+ /**
47
+ * If `true`, scrolling is enabled.
48
+ * @default true
49
+ */
50
+ isEnabled?: boolean;
51
+ /**
52
+ * If `true`, enables scrolling via mouse wheel.
53
+ * @default true
54
+ */
55
+ hasWheel?: boolean;
56
+ /**
57
+ * Defines the scroll speed multiplier for the mouse wheel.
58
+ * @default 1
59
+ */
60
+ wheelSpeed?: number;
61
+ /**
62
+ * Defines the main scrolling direction. Can be either horizontal or vertical.
63
+ * @default 'vertical'
64
+ */
65
+ direction?: 'horizontal' | 'vertical';
66
+ /**
67
+ * Inverts the scroll direction. Useful for reversed scrolling behaviors.
68
+ * @default false
69
+ */
70
+ isInversedHandlerDirection?: boolean;
71
+ /**
72
+ * Automatically stops the animation frame when the target and current scroll values are equal.
73
+ * Improves performance by preventing unnecessary renders.
74
+ * @default true
75
+ */
76
+ shouldAutoStop?: boolean;
77
+ /**
78
+ * If `true`, stops propagation of the scroll event to parent elements.
79
+ * @default true
80
+ */
81
+ hasStopPropagation?: boolean;
82
+ /**
83
+ * Linear interpolation factor for smooth scrolling. Scroll elements can override this value using the `customScrollLerp` property or the "data-custom-scroll-lerp" attribute.
84
+ * @default 0.1
85
+ */
86
+ lerp?: number;
87
+ /**
88
+ * Normalizes the scroll speed across different screens by accounting for varying FPS rates.
89
+ * @default true
90
+ */
91
+ isFpsNormalized?: boolean;
92
+ /**
93
+ * Approximation factor for interpolation, used to prevent animation from getting too slow at very small differences between current and target values.
94
+ * @default 0.1
95
+ */
96
+ lerpApproximation?: number;
97
+ }
98
+ interface ICallbacksTypes extends NComponent.ICallbacksTypes {
99
+ /**
100
+ * Fired when the component renders a new scroll frame.
101
+ */
102
+ render: undefined;
103
+ /**
104
+ * Fired when the component or viewport is resized.
105
+ */
106
+ resize: undefined;
107
+ /**
108
+ * Fired when a scroll event is detected from a mouse wheel interaction.
109
+ */
110
+ wheel: IWheelParameter;
111
+ }
112
+ interface IWheelParameter {
113
+ /**
114
+ * The original wheel event that triggered the scroll.
115
+ */
116
+ event: WheelEvent;
117
+ }
118
+ /**
119
+ * Represents a scrollable element within the CustomScroll component.
120
+ * These elements can track custom scroll positions and include custom interpolation settings.
121
+ */
122
+ interface IElement extends HTMLElement {
123
+ /**
124
+ * The current custom scroll top value for this element.
125
+ */
126
+ customScrollTop: number;
127
+ /**
128
+ * The current custom scroll left value for this element.
129
+ */
130
+ customScrollLeft: number;
131
+ /**
132
+ * Optional custom interpolation (lerp) value specific to this element.
133
+ */
134
+ customScrollLerp?: number;
135
+ }
136
+ }
137
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/CustomScroll/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AACpD,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAC;AACnD,OAAO,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAE7D,yBAAiB,aAAa,CAAC;IAC7B,UAAiB,YAAa,SAAQ,UAAU,CAAC,YAAY;QAC3D;;;WAGG;QACH,SAAS,CAAC,EAAE,MAAM,GAAG,WAAW,CAAC;QAEjC;;;;WAIG;QACH,QAAQ,CAAC,EACL,KAAK,GACL,MAAM,GACN,UAAU,CAAC,WAAW,CAAC,GACvB,WAAW,GACX,WAAW,EAAE,CAAC;QAElB;;;WAGG;QACH,cAAc,CAAC,EAAE,KAAK,GAAG,cAAc,CAAC;QAExC;;;WAGG;QACH,cAAc,CAAC,EAAE,eAAe,CAAC;QAEjC;;;WAGG;QACH,cAAc,CAAC,EAAE,MAAM,CAAC;QAExB;;;WAGG;QACH,aAAa,CAAC,EAAE,OAAO,CAAC;QAExB;;;;;WAKG;QACH,kBAAkB,CAAC,EAAE,KAAK,GAAG,MAAM,CAAC;KACrC;IAED,UAAiB,gBAAiB,SAAQ,UAAU,CAAC,gBAAgB;QACnE;;;WAGG;QACH,SAAS,CAAC,EAAE,OAAO,CAAC;QAEpB;;;WAGG;QACH,QAAQ,CAAC,EAAE,OAAO,CAAC;QAEnB;;;WAGG;QACH,UAAU,CAAC,EAAE,MAAM,CAAC;QAEpB;;;WAGG;QACH,SAAS,CAAC,EAAE,YAAY,GAAG,UAAU,CAAC;QAEtC;;;WAGG;QACH,0BAA0B,CAAC,EAAE,OAAO,CAAC;QAErC;;;;WAIG;QACH,cAAc,CAAC,EAAE,OAAO,CAAC;QAEzB;;;WAGG;QACH,kBAAkB,CAAC,EAAE,OAAO,CAAC;QAE7B;;;WAGG;QACH,IAAI,CAAC,EAAE,MAAM,CAAC;QAEd;;;WAGG;QACH,eAAe,CAAC,EAAE,OAAO,CAAC;QAE1B;;;WAGG;QACH,iBAAiB,CAAC,EAAE,MAAM,CAAC;KAC5B;IAED,UAAiB,eAAgB,SAAQ,UAAU,CAAC,eAAe;QACjE;;WAEG;QACH,MAAM,EAAE,SAAS,CAAC;QAElB;;WAEG;QACH,MAAM,EAAE,SAAS,CAAC;QAElB;;WAEG;QACH,KAAK,EAAE,eAAe,CAAC;KACxB;IAED,UAAiB,eAAe;QAC9B;;WAEG;QACH,KAAK,EAAE,UAAU,CAAC;KACnB;IAED;;;OAGG;IACH,UAAiB,QAAS,SAAQ,WAAW;QAC3C;;WAEG;QACH,eAAe,EAAE,MAAM,CAAC;QAExB;;WAEG;QACH,gBAAgB,EAAE,MAAM,CAAC;QAEzB;;WAEG;QACH,gBAAgB,CAAC,EAAE,MAAM,CAAC;KAC3B;CACF"}
@@ -0,0 +1,62 @@
1
+ import { Plugin } from '../../base/Plugin';
2
+ import { NCustomScrollDragPlugin } from './types';
3
+ import type { CustomScroll as CustomScrollInstance } from '../CustomScroll';
4
+ import { DraggerMove, NDraggerMove } from '../DraggerMove';
5
+ import { NCallbacks } from '../../base/Callbacks';
6
+ export type { NCustomScrollDragPlugin };
7
+ /**
8
+ * Plugin to add dragging functionality to a `CustomScroll` instance.
9
+ * It allows the user to control the scroll by dragging within the container.
10
+ */
11
+ export declare class CustomScrollDragPlugin<StaticProp extends NCustomScrollDragPlugin.IStaticProps = NCustomScrollDragPlugin.IStaticProps, ChangeableProp extends NCustomScrollDragPlugin.IChangeableProps = NCustomScrollDragPlugin.IChangeableProps, CallbacksTypes extends NCustomScrollDragPlugin.ICallbacksTypes = NCustomScrollDragPlugin.ICallbacksTypes> extends Plugin<StaticProp, ChangeableProp, CallbacksTypes, CustomScrollInstance> {
12
+ protected _getDefaultProps(): {
13
+ isEnabled: boolean;
14
+ speed: number;
15
+ lerp: boolean;
16
+ stopPropagationThreshold: boolean;
17
+ stopPropagationDirection: string;
18
+ };
19
+ /** Instance of the DraggerMove component that handles dragging. */
20
+ protected _dragger?: DraggerMove;
21
+ /** List of callbacks added to the CustomScroll instance. */
22
+ protected _componentCallbacks?: NCallbacks.IAddedCallback[];
23
+ /** Holds the previous lerp value of the CustomScroll component. */
24
+ protected _prevComponentLerp?: number;
25
+ /**
26
+ * Determines whether dragging is currently active.
27
+ */
28
+ get isDragging(): boolean;
29
+ protected _init(): void;
30
+ protected _onPropsMutate(): void;
31
+ /**
32
+ * Enables or disables the dragger based on the `isEnabled` property.
33
+ */
34
+ protected _toggleDragger(): void;
35
+ /**
36
+ * Adds the dragger functionality to the CustomScroll instance.
37
+ */
38
+ protected _addDragger(): void;
39
+ /**
40
+ * Removes the dragger and cleans up callbacks.
41
+ */
42
+ protected _removeDragger(): void;
43
+ /**
44
+ * Determines if dragging is possible based on the current scroll state.
45
+ */
46
+ protected _getIsDragAvailable(): boolean;
47
+ /**
48
+ * Handles the start of dragging.
49
+ */
50
+ protected _handleDragStart(): void;
51
+ /**
52
+ * Handles the dragging move event and updates scroll values.
53
+ */
54
+ protected _handleDragMove({ event, coords, start, step, }: NDraggerMove.ICallbacksTypes['move']): void;
55
+ /**
56
+ * Handles the end of dragging and restores the scroll state.
57
+ */
58
+ protected _handleDragEnd(): void;
59
+ /** Cleans up and destroys the plugin. */
60
+ protected _destroy(): void;
61
+ }
62
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/CustomScrollDragPlugin/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,eAAe,CAAC;AACvC,OAAO,EAAE,uBAAuB,EAAE,MAAM,SAAS,CAAC;AAClD,OAAO,KAAK,EAAE,YAAY,IAAI,oBAAoB,EAAE,MAAM,iBAAiB,CAAC;AAC5E,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC3D,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAE9C,YAAY,EAAE,uBAAuB,EAAE,CAAC;AAExC;;;GAGG;AACH,qBAAa,sBAAsB,CACjC,UAAU,SACR,uBAAuB,CAAC,YAAY,GAAG,uBAAuB,CAAC,YAAY,EAC7E,cAAc,SACZ,uBAAuB,CAAC,gBAAgB,GAAG,uBAAuB,CAAC,gBAAgB,EACrF,cAAc,SACZ,uBAAuB,CAAC,eAAe,GAAG,uBAAuB,CAAC,eAAe,CACnF,SAAQ,MAAM,CACd,UAAU,EACV,cAAc,EACd,cAAc,EACd,oBAAoB,CACrB;IACC,SAAS,CAAC,gBAAgB;;;;;;;IAW1B,mEAAmE;IACnE,SAAS,CAAC,QAAQ,CAAC,EAAE,WAAW,CAAC;IAEjC,4DAA4D;IAC5D,SAAS,CAAC,mBAAmB,CAAC,EAAE,UAAU,CAAC,cAAc,EAAE,CAAC;IAE5D,mEAAmE;IACnE,SAAS,CAAC,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAEtC;;OAEG;IACH,IAAI,UAAU,YAEb;IAED,SAAS,CAAC,KAAK;IAMf,SAAS,CAAC,cAAc;IAMxB;;OAEG;IACH,SAAS,CAAC,cAAc;IAQxB;;OAEG;IACH,SAAS,CAAC,WAAW;IA4BrB;;OAEG;IACH,SAAS,CAAC,cAAc;IAYxB;;OAEG;IACH,SAAS,CAAC,mBAAmB;IAiB7B;;OAEG;IACH,SAAS,CAAC,gBAAgB;IAe1B;;OAEG;IACH,SAAS,CAAC,eAAe,CAAC,EACxB,KAAK,EACL,MAAM,EACN,KAAK,EACL,IAAI,GACL,EAAE,YAAY,CAAC,eAAe,CAAC,MAAM,CAAC;IAqCvC;;OAEG;IACH,SAAS,CAAC,cAAc;IAcxB,yCAAyC;IACzC,SAAS,CAAC,QAAQ;CAKnB"}
@@ -0,0 +1,52 @@
1
+ import { NPlugin } from '../../base/Plugin/types';
2
+ export declare namespace NCustomScrollDragPlugin {
3
+ interface IStaticProps extends NPlugin.IStaticProps {
4
+ }
5
+ interface IChangeableProps extends NPlugin.IChangeableProps {
6
+ /**
7
+ * Determines if the dragger functionality is enabled.
8
+ * @default true
9
+ */
10
+ isEnabled?: boolean;
11
+ /**
12
+ * Defines the speed of the dragger movement.
13
+ * Higher values make the dragging movement faster.
14
+ * @default 1
15
+ */
16
+ speed?: number;
17
+ /**
18
+ * Custom linear interpolation (lerp) value for smooth scrolling.
19
+ * If set to `false`, the lerp value from the `CustomScroll` instance is used.
20
+ * Values range between 0 and 1, with 1 being an instant scroll.
21
+ * @default false
22
+ */
23
+ lerp?: number | false;
24
+ /**
25
+ * Threshold in pixels to stop the event propagation during a drag.
26
+ * If set to `false`, no threshold is applied.
27
+ * @default false
28
+ */
29
+ stopPropagationThreshold?: false | number;
30
+ /**
31
+ * Defines the direction in which to stop event propagation.
32
+ * Either the X-axis ('x') or the Y-axis ('y').
33
+ * @default 'y'
34
+ */
35
+ stopPropagationDirection?: 'x' | 'y';
36
+ }
37
+ interface ICallbacksTypes extends NPlugin.ICallbacksTypes {
38
+ /**
39
+ * Fired when dragging starts.
40
+ */
41
+ start: undefined;
42
+ /**
43
+ * Fired while dragging is in progress.
44
+ */
45
+ move: undefined;
46
+ /**
47
+ * Fired when dragging ends.
48
+ */
49
+ end: undefined;
50
+ }
51
+ }
52
+ //# sourceMappingURL=types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../../src/components/CustomScrollDragPlugin/types.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,qBAAqB,CAAC;AAE9C,yBAAiB,uBAAuB,CAAC;IACvC,UAAiB,YAAa,SAAQ,OAAO,CAAC,YAAY;KAAG;IAE7D,UAAiB,gBAAiB,SAAQ,OAAO,CAAC,gBAAgB;QAChE;;;WAGG;QACH,SAAS,CAAC,EAAE,OAAO,CAAC;QAEpB;;;;WAIG;QACH,KAAK,CAAC,EAAE,MAAM,CAAC;QAEf;;;;;WAKG;QACH,IAAI,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC;QAEtB;;;;WAIG;QACH,wBAAwB,CAAC,EAAE,KAAK,GAAG,MAAM,CAAC;QAE1C;;;;WAIG;QACH,wBAAwB,CAAC,EAAE,GAAG,GAAG,GAAG,CAAC;KACtC;IAED,UAAiB,eAAgB,SAAQ,OAAO,CAAC,eAAe;QAC9D;;WAEG;QACH,KAAK,EAAE,SAAS,CAAC;QAEjB;;WAEG;QACH,IAAI,EAAE,SAAS,CAAC;QAEhB;;WAEG;QACH,GAAG,EAAE,SAAS,CAAC;KAChB;CACF"}
@@ -0,0 +1,47 @@
1
+ /// <reference types="node" />
2
+ import { Plugin } from '../../base/Plugin';
3
+ import { NCustomScrollKeyboardPlugin } from './types';
4
+ import type { CustomScroll as CustomScrollInstance } from '../CustomScroll';
5
+ export type { NCustomScrollKeyboardPlugin };
6
+ /**
7
+ * CustomScrollKeyboardPlugin adds keyboard navigation functionality to the `CustomScroll` component.
8
+ * It allows scrolling the container using keyboard arrow keys, space bar, page up/down, home, end, and tab.
9
+ */
10
+ export declare class CustomScrollKeyboardPlugin<StaticProps extends NCustomScrollKeyboardPlugin.IStaticProps = NCustomScrollKeyboardPlugin.IStaticProps, ChangeableProps extends NCustomScrollKeyboardPlugin.IChangeableProps = NCustomScrollKeyboardPlugin.IChangeableProps, CallbacksTypes extends NCustomScrollKeyboardPlugin.ICallbacksTypes = NCustomScrollKeyboardPlugin.ICallbacksTypes> extends Plugin<StaticProps, ChangeableProps, CallbacksTypes, CustomScrollInstance> {
11
+ protected _getDefaultProps(): {
12
+ iterator: number;
13
+ };
14
+ /**
15
+ * Timeout for handling the Tab key navigation.
16
+ */
17
+ protected _tabTimeout?: NodeJS.Timeout;
18
+ /** Initializes the plugin by adding event listeners for keyboard events. */
19
+ protected _init(): void;
20
+ /**
21
+ * Determines if keyboard events should be ignored, based on the currently active element.
22
+ */
23
+ protected _canIgnoreEvents(): boolean;
24
+ /**
25
+ * Checks if the scroll container is visible in the viewport.
26
+ */
27
+ protected _isInViewport(): boolean;
28
+ /**
29
+ * Determines whether the scroll has reached its end.
30
+ */
31
+ protected _checkIsEndOfScroll(): boolean;
32
+ /**
33
+ * Handles the `keydown` event for navigating the scrollable container with the keyboard.
34
+ */
35
+ protected _handleKeydown(event: KeyboardEvent): void;
36
+ /**
37
+ * Handles the Tab key for focusing elements inside the scrollable container and adjusting the scroll position.
38
+ */
39
+ protected _handleTab(): void;
40
+ /**
41
+ * Handles the Spacebar key to scroll down the container by a fixed amount.
42
+ */
43
+ protected _handleSpace(event: KeyboardEvent): void;
44
+ /** Destroys the plugin and clears any timeouts or event listeners. */
45
+ protected _destroy(): void;
46
+ }
47
+ //# sourceMappingURL=index.d.ts.map