infinity-forge 0.54.3 → 0.54.5

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 (190) hide show
  1. package/dist/ui/components/carousel/swiper/components-shared/get-changed-params.d.ts +2 -0
  2. package/dist/ui/components/carousel/swiper/components-shared/get-changed-params.js +51 -0
  3. package/dist/ui/components/carousel/swiper/components-shared/get-changed-params.js.map +1 -0
  4. package/dist/ui/components/carousel/swiper/components-shared/get-element-params.d.ts +5 -0
  5. package/dist/ui/components/carousel/swiper/components-shared/get-element-params.js +148 -0
  6. package/dist/ui/components/carousel/swiper/components-shared/get-element-params.js.map +1 -0
  7. package/dist/ui/components/carousel/swiper/components-shared/get-params.d.ts +9 -0
  8. package/dist/ui/components/carousel/swiper/components-shared/get-params.js +61 -0
  9. package/dist/ui/components/carousel/swiper/components-shared/get-params.js.map +1 -0
  10. package/dist/ui/components/carousel/swiper/components-shared/mount-swiper.d.ts +9 -0
  11. package/dist/ui/components/carousel/swiper/components-shared/mount-swiper.js +24 -0
  12. package/dist/ui/components/carousel/swiper/components-shared/mount-swiper.js.map +1 -0
  13. package/dist/ui/components/carousel/swiper/components-shared/params-list.d.ts +2 -0
  14. package/dist/ui/components/carousel/swiper/components-shared/params-list.js +125 -0
  15. package/dist/ui/components/carousel/swiper/components-shared/params-list.js.map +1 -0
  16. package/dist/ui/components/carousel/swiper/components-shared/update-on-virtual-data.d.ts +1 -0
  17. package/dist/ui/components/carousel/swiper/components-shared/update-on-virtual-data.js +18 -0
  18. package/dist/ui/components/carousel/swiper/components-shared/update-on-virtual-data.js.map +1 -0
  19. package/dist/ui/components/carousel/swiper/components-shared/update-swiper.d.ts +11 -0
  20. package/dist/ui/components/carousel/swiper/components-shared/update-swiper.js +208 -0
  21. package/dist/ui/components/carousel/swiper/components-shared/update-swiper.js.map +1 -0
  22. package/dist/ui/components/carousel/swiper/components-shared/utils.d.ts +9 -0
  23. package/dist/ui/components/carousel/swiper/components-shared/utils.js +77 -0
  24. package/dist/ui/components/carousel/swiper/components-shared/utils.js.map +1 -0
  25. package/dist/ui/components/carousel/swiper/core/breakpoints/getBreakpoint.d.ts +1 -0
  26. package/dist/ui/components/carousel/swiper/core/breakpoints/getBreakpoint.js +35 -0
  27. package/dist/ui/components/carousel/swiper/core/breakpoints/getBreakpoint.js.map +1 -0
  28. package/dist/ui/components/carousel/swiper/core/breakpoints/index.d.ts +7 -0
  29. package/dist/ui/components/carousel/swiper/core/breakpoints/index.js +9 -0
  30. package/dist/ui/components/carousel/swiper/core/breakpoints/index.js.map +1 -0
  31. package/dist/ui/components/carousel/swiper/core/breakpoints/setBreakpoint.d.ts +1 -0
  32. package/dist/ui/components/carousel/swiper/core/breakpoints/setBreakpoint.js +94 -0
  33. package/dist/ui/components/carousel/swiper/core/breakpoints/setBreakpoint.js.map +1 -0
  34. package/dist/ui/components/carousel/swiper/core/check-overflow/index.d.ts +5 -0
  35. package/dist/ui/components/carousel/swiper/core/check-overflow/index.js +31 -0
  36. package/dist/ui/components/carousel/swiper/core/check-overflow/index.js.map +1 -0
  37. package/dist/ui/components/carousel/swiper/core/classes/addClasses.d.ts +1 -0
  38. package/dist/ui/components/carousel/swiper/core/classes/addClasses.js +43 -0
  39. package/dist/ui/components/carousel/swiper/core/classes/addClasses.js.map +1 -0
  40. package/dist/ui/components/carousel/swiper/core/classes/index.d.ts +7 -0
  41. package/dist/ui/components/carousel/swiper/core/classes/index.js +9 -0
  42. package/dist/ui/components/carousel/swiper/core/classes/index.js.map +1 -0
  43. package/dist/ui/components/carousel/swiper/core/classes/removeClasses.d.ts +1 -0
  44. package/dist/ui/components/carousel/swiper/core/classes/removeClasses.js +13 -0
  45. package/dist/ui/components/carousel/swiper/core/classes/removeClasses.js.map +1 -0
  46. package/dist/ui/components/carousel/swiper/core/core.js +12 -12
  47. package/dist/ui/components/carousel/swiper/core/events/index.d.ts +7 -0
  48. package/dist/ui/components/carousel/swiper/core/events/index.js +77 -0
  49. package/dist/ui/components/carousel/swiper/core/events/index.js.map +1 -0
  50. package/dist/ui/components/carousel/swiper/core/events/onClick.d.ts +1 -0
  51. package/dist/ui/components/carousel/swiper/core/events/onClick.js +17 -0
  52. package/dist/ui/components/carousel/swiper/core/events/onClick.js.map +1 -0
  53. package/dist/ui/components/carousel/swiper/core/events/onDocumentTouchStart.d.ts +1 -0
  54. package/dist/ui/components/carousel/swiper/core/events/onDocumentTouchStart.js +13 -0
  55. package/dist/ui/components/carousel/swiper/core/events/onDocumentTouchStart.js.map +1 -0
  56. package/dist/ui/components/carousel/swiper/core/events/onLoad.d.ts +1 -0
  57. package/dist/ui/components/carousel/swiper/core/events/onLoad.js +14 -0
  58. package/dist/ui/components/carousel/swiper/core/events/onLoad.js.map +1 -0
  59. package/dist/ui/components/carousel/swiper/core/events/onResize.d.ts +1 -0
  60. package/dist/ui/components/carousel/swiper/core/events/onResize.js +53 -0
  61. package/dist/ui/components/carousel/swiper/core/events/onResize.js.map +1 -0
  62. package/dist/ui/components/carousel/swiper/core/events/onScroll.d.ts +1 -0
  63. package/dist/ui/components/carousel/swiper/core/events/onScroll.js +34 -0
  64. package/dist/ui/components/carousel/swiper/core/events/onScroll.js.map +1 -0
  65. package/dist/ui/components/carousel/swiper/core/events/onTouchEnd.d.ts +1 -0
  66. package/dist/ui/components/carousel/swiper/core/events/onTouchEnd.js +194 -0
  67. package/dist/ui/components/carousel/swiper/core/events/onTouchEnd.js.map +1 -0
  68. package/dist/ui/components/carousel/swiper/core/events/onTouchMove.d.ts +1 -0
  69. package/dist/ui/components/carousel/swiper/core/events/onTouchMove.js +314 -0
  70. package/dist/ui/components/carousel/swiper/core/events/onTouchMove.js.map +1 -0
  71. package/dist/ui/components/carousel/swiper/core/events/onTouchStart.d.ts +1 -0
  72. package/dist/ui/components/carousel/swiper/core/events/onTouchStart.js +153 -0
  73. package/dist/ui/components/carousel/swiper/core/events/onTouchStart.js.map +1 -0
  74. package/dist/ui/components/carousel/swiper/core/grab-cursor/index.d.ts +7 -0
  75. package/dist/ui/components/carousel/swiper/core/grab-cursor/index.js +12 -0
  76. package/dist/ui/components/carousel/swiper/core/grab-cursor/index.js.map +1 -0
  77. package/dist/ui/components/carousel/swiper/core/grab-cursor/setGrabCursor.d.ts +1 -0
  78. package/dist/ui/components/carousel/swiper/core/grab-cursor/setGrabCursor.js +22 -0
  79. package/dist/ui/components/carousel/swiper/core/grab-cursor/setGrabCursor.js.map +1 -0
  80. package/dist/ui/components/carousel/swiper/core/grab-cursor/unsetGrabCursor.d.ts +1 -0
  81. package/dist/ui/components/carousel/swiper/core/grab-cursor/unsetGrabCursor.js +19 -0
  82. package/dist/ui/components/carousel/swiper/core/grab-cursor/unsetGrabCursor.js.map +1 -0
  83. package/dist/ui/components/carousel/swiper/core/loop/index.d.ts +9 -0
  84. package/dist/ui/components/carousel/swiper/core/loop/index.js +14 -0
  85. package/dist/ui/components/carousel/swiper/core/loop/index.js.map +1 -0
  86. package/dist/ui/components/carousel/swiper/core/loop/loopCreate.d.ts +1 -0
  87. package/dist/ui/components/carousel/swiper/core/loop/loopCreate.js +57 -0
  88. package/dist/ui/components/carousel/swiper/core/loop/loopCreate.js.map +1 -0
  89. package/dist/ui/components/carousel/swiper/core/loop/loopDestroy.d.ts +1 -0
  90. package/dist/ui/components/carousel/swiper/core/loop/loopDestroy.js +26 -0
  91. package/dist/ui/components/carousel/swiper/core/loop/loopDestroy.js.map +1 -0
  92. package/dist/ui/components/carousel/swiper/core/loop/loopFix.d.ts +9 -0
  93. package/dist/ui/components/carousel/swiper/core/loop/loopFix.js +230 -0
  94. package/dist/ui/components/carousel/swiper/core/loop/loopFix.js.map +1 -0
  95. package/dist/ui/components/carousel/swiper/core/modules/observer/observer.d.ts +6 -0
  96. package/dist/ui/components/carousel/swiper/core/modules/observer/observer.js +71 -0
  97. package/dist/ui/components/carousel/swiper/core/modules/observer/observer.js.map +1 -0
  98. package/dist/ui/components/carousel/swiper/core/modules/resize/resize.d.ts +5 -0
  99. package/dist/ui/components/carousel/swiper/core/modules/resize/resize.js +71 -0
  100. package/dist/ui/components/carousel/swiper/core/modules/resize/resize.js.map +1 -0
  101. package/dist/ui/components/carousel/swiper/core/slide/index.d.ts +17 -0
  102. package/dist/ui/components/carousel/swiper/core/slide/index.js +22 -0
  103. package/dist/ui/components/carousel/swiper/core/slide/index.js.map +1 -0
  104. package/dist/ui/components/carousel/swiper/core/slide/slideNext.d.ts +1 -0
  105. package/dist/ui/components/carousel/swiper/core/slide/slideNext.js +38 -0
  106. package/dist/ui/components/carousel/swiper/core/slide/slideNext.js.map +1 -0
  107. package/dist/ui/components/carousel/swiper/core/slide/slidePrev.d.ts +1 -0
  108. package/dist/ui/components/carousel/swiper/core/slide/slidePrev.js +69 -0
  109. package/dist/ui/components/carousel/swiper/core/slide/slidePrev.js.map +1 -0
  110. package/dist/ui/components/carousel/swiper/core/slide/slideReset.d.ts +1 -0
  111. package/dist/ui/components/carousel/swiper/core/slide/slideReset.js +15 -0
  112. package/dist/ui/components/carousel/swiper/core/slide/slideReset.js.map +1 -0
  113. package/dist/ui/components/carousel/swiper/core/slide/slideTo.d.ts +1 -0
  114. package/dist/ui/components/carousel/swiper/core/slide/slideTo.js +160 -0
  115. package/dist/ui/components/carousel/swiper/core/slide/slideTo.js.map +1 -0
  116. package/dist/ui/components/carousel/swiper/core/slide/slideToClickedSlide.d.ts +1 -0
  117. package/dist/ui/components/carousel/swiper/core/slide/slideToClickedSlide.js +46 -0
  118. package/dist/ui/components/carousel/swiper/core/slide/slideToClickedSlide.js.map +1 -0
  119. package/dist/ui/components/carousel/swiper/core/slide/slideToClosest.d.ts +1 -0
  120. package/dist/ui/components/carousel/swiper/core/slide/slideToClosest.js +40 -0
  121. package/dist/ui/components/carousel/swiper/core/slide/slideToClosest.js.map +1 -0
  122. package/dist/ui/components/carousel/swiper/core/slide/slideToLoop.d.ts +1 -0
  123. package/dist/ui/components/carousel/swiper/core/slide/slideToLoop.js +84 -0
  124. package/dist/ui/components/carousel/swiper/core/slide/slideToLoop.js.map +1 -0
  125. package/dist/ui/components/carousel/swiper/core/transition/index.d.ts +9 -0
  126. package/dist/ui/components/carousel/swiper/core/transition/index.js +14 -0
  127. package/dist/ui/components/carousel/swiper/core/transition/index.js.map +1 -0
  128. package/dist/ui/components/carousel/swiper/core/transition/setTransition.d.ts +1 -0
  129. package/dist/ui/components/carousel/swiper/core/transition/setTransition.js +12 -0
  130. package/dist/ui/components/carousel/swiper/core/transition/setTransition.js.map +1 -0
  131. package/dist/ui/components/carousel/swiper/core/transition/transitionEmit.d.ts +6 -0
  132. package/dist/ui/components/carousel/swiper/core/transition/transitionEmit.js +31 -0
  133. package/dist/ui/components/carousel/swiper/core/transition/transitionEmit.js.map +1 -0
  134. package/dist/ui/components/carousel/swiper/core/transition/transitionEnd.d.ts +1 -0
  135. package/dist/ui/components/carousel/swiper/core/transition/transitionEnd.js +18 -0
  136. package/dist/ui/components/carousel/swiper/core/transition/transitionEnd.js.map +1 -0
  137. package/dist/ui/components/carousel/swiper/core/transition/transitionStart.d.ts +1 -0
  138. package/dist/ui/components/carousel/swiper/core/transition/transitionStart.js +19 -0
  139. package/dist/ui/components/carousel/swiper/core/transition/transitionStart.js.map +1 -0
  140. package/dist/ui/components/carousel/swiper/core/translate/getTranslate.d.ts +1 -0
  141. package/dist/ui/components/carousel/swiper/core/translate/getTranslate.js +21 -0
  142. package/dist/ui/components/carousel/swiper/core/translate/getTranslate.js.map +1 -0
  143. package/dist/ui/components/carousel/swiper/core/translate/index.d.ts +13 -0
  144. package/dist/ui/components/carousel/swiper/core/translate/index.js +18 -0
  145. package/dist/ui/components/carousel/swiper/core/translate/index.js.map +1 -0
  146. package/dist/ui/components/carousel/swiper/core/translate/maxTranslate.d.ts +1 -0
  147. package/dist/ui/components/carousel/swiper/core/translate/maxTranslate.js +7 -0
  148. package/dist/ui/components/carousel/swiper/core/translate/maxTranslate.js.map +1 -0
  149. package/dist/ui/components/carousel/swiper/core/translate/minTranslate.d.ts +1 -0
  150. package/dist/ui/components/carousel/swiper/core/translate/minTranslate.js +7 -0
  151. package/dist/ui/components/carousel/swiper/core/translate/minTranslate.js.map +1 -0
  152. package/dist/ui/components/carousel/swiper/core/translate/setTranslate.d.ts +1 -0
  153. package/dist/ui/components/carousel/swiper/core/translate/setTranslate.js +48 -0
  154. package/dist/ui/components/carousel/swiper/core/translate/setTranslate.js.map +1 -0
  155. package/dist/ui/components/carousel/swiper/core/translate/translateTo.d.ts +1 -0
  156. package/dist/ui/components/carousel/swiper/core/translate/translateTo.js +81 -0
  157. package/dist/ui/components/carousel/swiper/core/translate/translateTo.js.map +1 -0
  158. package/dist/ui/components/carousel/swiper/core/update/index.d.ts +21 -0
  159. package/dist/ui/components/carousel/swiper/core/update/index.js +26 -0
  160. package/dist/ui/components/carousel/swiper/core/update/index.js.map +1 -0
  161. package/dist/ui/components/carousel/swiper/core/update/updateActiveIndex.d.ts +2 -0
  162. package/dist/ui/components/carousel/swiper/core/update/updateActiveIndex.js +125 -0
  163. package/dist/ui/components/carousel/swiper/core/update/updateActiveIndex.js.map +1 -0
  164. package/dist/ui/components/carousel/swiper/core/update/updateAutoHeight.d.ts +1 -0
  165. package/dist/ui/components/carousel/swiper/core/update/updateAutoHeight.js +52 -0
  166. package/dist/ui/components/carousel/swiper/core/update/updateAutoHeight.js.map +1 -0
  167. package/dist/ui/components/carousel/swiper/core/update/updateClickedSlide.d.ts +1 -0
  168. package/dist/ui/components/carousel/swiper/core/update/updateClickedSlide.js +55 -0
  169. package/dist/ui/components/carousel/swiper/core/update/updateClickedSlide.js.map +1 -0
  170. package/dist/ui/components/carousel/swiper/core/update/updateProgress.d.ts +1 -0
  171. package/dist/ui/components/carousel/swiper/core/update/updateProgress.js +67 -0
  172. package/dist/ui/components/carousel/swiper/core/update/updateProgress.js.map +1 -0
  173. package/dist/ui/components/carousel/swiper/core/update/updateSize.d.ts +1 -0
  174. package/dist/ui/components/carousel/swiper/core/update/updateSize.js +45 -0
  175. package/dist/ui/components/carousel/swiper/core/update/updateSize.js.map +1 -0
  176. package/dist/ui/components/carousel/swiper/core/update/updateSlides.d.ts +1 -0
  177. package/dist/ui/components/carousel/swiper/core/update/updateSlides.js +306 -0
  178. package/dist/ui/components/carousel/swiper/core/update/updateSlides.js.map +1 -0
  179. package/dist/ui/components/carousel/swiper/core/update/updateSlidesClasses.d.ts +1 -0
  180. package/dist/ui/components/carousel/swiper/core/update/updateSlidesClasses.js +69 -0
  181. package/dist/ui/components/carousel/swiper/core/update/updateSlidesClasses.js.map +1 -0
  182. package/dist/ui/components/carousel/swiper/core/update/updateSlidesOffset.d.ts +1 -0
  183. package/dist/ui/components/carousel/swiper/core/update/updateSlidesOffset.js +20 -0
  184. package/dist/ui/components/carousel/swiper/core/update/updateSlidesOffset.js.map +1 -0
  185. package/dist/ui/components/carousel/swiper/core/update/updateSlidesProgress.d.ts +1 -0
  186. package/dist/ui/components/carousel/swiper/core/update/updateSlidesProgress.js +62 -0
  187. package/dist/ui/components/carousel/swiper/core/update/updateSlidesProgress.js.map +1 -0
  188. package/dist/ui/components/carousel/swiper/react/swiper-slide.js +1 -1
  189. package/dist/ui/components/carousel/swiper/react/swiper.js +6 -6
  190. package/package.json +1 -1
@@ -0,0 +1,314 @@
1
+ "use strict";
2
+ var __spreadArray = (this && this.__spreadArray) || function (to, from, pack) {
3
+ if (pack || arguments.length === 2) for (var i = 0, l = from.length, ar; i < l; i++) {
4
+ if (ar || !(i in from)) {
5
+ if (!ar) ar = Array.prototype.slice.call(from, 0, i);
6
+ ar[i] = from[i];
7
+ }
8
+ }
9
+ return to.concat(ar || Array.prototype.slice.call(from));
10
+ };
11
+ Object.defineProperty(exports, "__esModule", { value: true });
12
+ //@ts-nocheck
13
+ var ssr_window_1 = require("ssr-window");
14
+ var utils_1 = require("../../shared/utils.js");
15
+ function onTouchMove(event) {
16
+ var document = (0, ssr_window_1.getDocument)();
17
+ var swiper = this;
18
+ var data = swiper.touchEventsData;
19
+ var params = swiper.params, touches = swiper.touches, rtl = swiper.rtlTranslate, enabled = swiper.enabled;
20
+ if (!enabled)
21
+ return;
22
+ if (!params.simulateTouch && event.pointerType === 'mouse')
23
+ return;
24
+ var e = event;
25
+ if (e.originalEvent)
26
+ e = e.originalEvent;
27
+ if (e.type === 'pointermove') {
28
+ if (data.touchId !== null)
29
+ return; // return from pointer if we use touch
30
+ var id = e.pointerId;
31
+ if (id !== data.pointerId)
32
+ return;
33
+ }
34
+ var targetTouch;
35
+ if (e.type === 'touchmove') {
36
+ targetTouch = __spreadArray([], e.changedTouches, true).filter(function (t) { return t.identifier === data.touchId; })[0];
37
+ if (!targetTouch || targetTouch.identifier !== data.touchId)
38
+ return;
39
+ }
40
+ else {
41
+ targetTouch = e;
42
+ }
43
+ if (!data.isTouched) {
44
+ if (data.startMoving && data.isScrolling) {
45
+ swiper.emit('touchMoveOpposite', e);
46
+ }
47
+ return;
48
+ }
49
+ var pageX = targetTouch.pageX;
50
+ var pageY = targetTouch.pageY;
51
+ if (e.preventedByNestedSwiper) {
52
+ touches.startX = pageX;
53
+ touches.startY = pageY;
54
+ return;
55
+ }
56
+ if (!swiper.allowTouchMove) {
57
+ if (!e.target.matches(data.focusableElements)) {
58
+ swiper.allowClick = false;
59
+ }
60
+ if (data.isTouched) {
61
+ Object.assign(touches, {
62
+ startX: pageX,
63
+ startY: pageY,
64
+ currentX: pageX,
65
+ currentY: pageY,
66
+ });
67
+ data.touchStartTime = (0, utils_1.now)();
68
+ }
69
+ return;
70
+ }
71
+ if (params.touchReleaseOnEdges && !params.loop) {
72
+ if (swiper.isVertical()) {
73
+ // Vertical
74
+ if ((pageY < touches.startY && swiper.translate <= swiper.maxTranslate()) ||
75
+ (pageY > touches.startY && swiper.translate >= swiper.minTranslate())) {
76
+ data.isTouched = false;
77
+ data.isMoved = false;
78
+ return;
79
+ }
80
+ }
81
+ else if ((pageX < touches.startX && swiper.translate <= swiper.maxTranslate()) ||
82
+ (pageX > touches.startX && swiper.translate >= swiper.minTranslate())) {
83
+ return;
84
+ }
85
+ }
86
+ if (document.activeElement) {
87
+ if (e.target === document.activeElement && e.target.matches(data.focusableElements)) {
88
+ data.isMoved = true;
89
+ swiper.allowClick = false;
90
+ return;
91
+ }
92
+ }
93
+ if (data.allowTouchCallbacks) {
94
+ swiper.emit('touchMove', e);
95
+ }
96
+ touches.previousX = touches.currentX;
97
+ touches.previousY = touches.currentY;
98
+ touches.currentX = pageX;
99
+ touches.currentY = pageY;
100
+ var diffX = touches.currentX - touches.startX;
101
+ var diffY = touches.currentY - touches.startY;
102
+ if (swiper.params.threshold && Math.sqrt(Math.pow(diffX, 2) + Math.pow(diffY, 2)) < swiper.params.threshold)
103
+ return;
104
+ if (typeof data.isScrolling === 'undefined') {
105
+ var touchAngle = void 0;
106
+ if ((swiper.isHorizontal() && touches.currentY === touches.startY) ||
107
+ (swiper.isVertical() && touches.currentX === touches.startX)) {
108
+ data.isScrolling = false;
109
+ }
110
+ else {
111
+ // eslint-disable-next-line
112
+ if (diffX * diffX + diffY * diffY >= 25) {
113
+ touchAngle = (Math.atan2(Math.abs(diffY), Math.abs(diffX)) * 180) / Math.PI;
114
+ data.isScrolling = swiper.isHorizontal()
115
+ ? touchAngle > params.touchAngle
116
+ : 90 - touchAngle > params.touchAngle;
117
+ }
118
+ }
119
+ }
120
+ if (data.isScrolling) {
121
+ swiper.emit('touchMoveOpposite', e);
122
+ }
123
+ if (typeof data.startMoving === 'undefined') {
124
+ if (touches.currentX !== touches.startX || touches.currentY !== touches.startY) {
125
+ data.startMoving = true;
126
+ }
127
+ }
128
+ if (data.isScrolling || (e.type === 'touchmove' && data.preventTouchMoveFromPointerMove)) {
129
+ data.isTouched = false;
130
+ return;
131
+ }
132
+ if (!data.startMoving) {
133
+ return;
134
+ }
135
+ swiper.allowClick = false;
136
+ if (!params.cssMode && e.cancelable) {
137
+ e.preventDefault();
138
+ }
139
+ if (params.touchMoveStopPropagation && !params.nested) {
140
+ e.stopPropagation();
141
+ }
142
+ var diff = swiper.isHorizontal() ? diffX : diffY;
143
+ var touchesDiff = swiper.isHorizontal()
144
+ ? touches.currentX - touches.previousX
145
+ : touches.currentY - touches.previousY;
146
+ if (params.oneWayMovement) {
147
+ diff = Math.abs(diff) * (rtl ? 1 : -1);
148
+ touchesDiff = Math.abs(touchesDiff) * (rtl ? 1 : -1);
149
+ }
150
+ touches.diff = diff;
151
+ diff *= params.touchRatio;
152
+ if (rtl) {
153
+ diff = -diff;
154
+ touchesDiff = -touchesDiff;
155
+ }
156
+ var prevTouchesDirection = swiper.touchesDirection;
157
+ swiper.swipeDirection = diff > 0 ? 'prev' : 'next';
158
+ swiper.touchesDirection = touchesDiff > 0 ? 'prev' : 'next';
159
+ var isLoop = swiper.params.loop && !params.cssMode;
160
+ var allowLoopFix = (swiper.touchesDirection === 'next' && swiper.allowSlideNext) ||
161
+ (swiper.touchesDirection === 'prev' && swiper.allowSlidePrev);
162
+ if (!data.isMoved) {
163
+ if (isLoop && allowLoopFix) {
164
+ swiper.loopFix({ direction: swiper.swipeDirection });
165
+ }
166
+ data.startTranslate = swiper.getTranslate();
167
+ swiper.setTransition(0);
168
+ if (swiper.animating) {
169
+ var evt = new window.CustomEvent('transitionend', {
170
+ bubbles: true,
171
+ cancelable: true,
172
+ detail: {
173
+ bySwiperTouchMove: true,
174
+ },
175
+ });
176
+ swiper.wrapperEl.dispatchEvent(evt);
177
+ }
178
+ data.allowMomentumBounce = false;
179
+ // Grab Cursor
180
+ if (params.grabCursor && (swiper.allowSlideNext === true || swiper.allowSlidePrev === true)) {
181
+ swiper.setGrabCursor(true);
182
+ }
183
+ swiper.emit('sliderFirstMove', e);
184
+ }
185
+ var loopFixed;
186
+ var time = new Date().getTime();
187
+ if (data.isMoved &&
188
+ data.allowThresholdMove &&
189
+ prevTouchesDirection !== swiper.touchesDirection &&
190
+ isLoop &&
191
+ allowLoopFix &&
192
+ Math.abs(diff) >= 1) {
193
+ Object.assign(touches, {
194
+ startX: pageX,
195
+ startY: pageY,
196
+ currentX: pageX,
197
+ currentY: pageY,
198
+ startTranslate: data.currentTranslate,
199
+ });
200
+ data.loopSwapReset = true;
201
+ data.startTranslate = data.currentTranslate;
202
+ return;
203
+ }
204
+ swiper.emit('sliderMove', e);
205
+ data.isMoved = true;
206
+ data.currentTranslate = diff + data.startTranslate;
207
+ var disableParentSwiper = true;
208
+ var resistanceRatio = params.resistanceRatio;
209
+ if (params.touchReleaseOnEdges) {
210
+ resistanceRatio = 0;
211
+ }
212
+ if (diff > 0) {
213
+ if (isLoop &&
214
+ allowLoopFix &&
215
+ !loopFixed &&
216
+ data.allowThresholdMove &&
217
+ data.currentTranslate >
218
+ (params.centeredSlides
219
+ ? swiper.minTranslate() - swiper.slidesSizesGrid[swiper.activeIndex + 1]
220
+ : swiper.minTranslate())) {
221
+ swiper.loopFix({ direction: 'prev', setTranslate: true, activeSlideIndex: 0 });
222
+ }
223
+ if (data.currentTranslate > swiper.minTranslate()) {
224
+ disableParentSwiper = false;
225
+ if (params.resistance) {
226
+ data.currentTranslate =
227
+ swiper.minTranslate() -
228
+ 1 +
229
+ Math.pow((-swiper.minTranslate() + data.startTranslate + diff), resistanceRatio);
230
+ }
231
+ }
232
+ }
233
+ else if (diff < 0) {
234
+ if (isLoop &&
235
+ allowLoopFix &&
236
+ !loopFixed &&
237
+ data.allowThresholdMove &&
238
+ data.currentTranslate <
239
+ (params.centeredSlides
240
+ ? swiper.maxTranslate() + swiper.slidesSizesGrid[swiper.slidesSizesGrid.length - 1]
241
+ : swiper.maxTranslate())) {
242
+ swiper.loopFix({
243
+ direction: 'next',
244
+ setTranslate: true,
245
+ activeSlideIndex: swiper.slides.length -
246
+ (params.slidesPerView === 'auto'
247
+ ? swiper.slidesPerViewDynamic()
248
+ : Math.ceil(parseFloat(params.slidesPerView, 10))),
249
+ });
250
+ }
251
+ if (data.currentTranslate < swiper.maxTranslate()) {
252
+ disableParentSwiper = false;
253
+ if (params.resistance) {
254
+ data.currentTranslate =
255
+ swiper.maxTranslate() +
256
+ 1 -
257
+ Math.pow((swiper.maxTranslate() - data.startTranslate - diff), resistanceRatio);
258
+ }
259
+ }
260
+ }
261
+ if (disableParentSwiper) {
262
+ e.preventedByNestedSwiper = true;
263
+ }
264
+ // Directions locks
265
+ if (!swiper.allowSlideNext &&
266
+ swiper.swipeDirection === 'next' &&
267
+ data.currentTranslate < data.startTranslate) {
268
+ data.currentTranslate = data.startTranslate;
269
+ }
270
+ if (!swiper.allowSlidePrev &&
271
+ swiper.swipeDirection === 'prev' &&
272
+ data.currentTranslate > data.startTranslate) {
273
+ data.currentTranslate = data.startTranslate;
274
+ }
275
+ if (!swiper.allowSlidePrev && !swiper.allowSlideNext) {
276
+ data.currentTranslate = data.startTranslate;
277
+ }
278
+ // Threshold
279
+ if (params.threshold > 0) {
280
+ if (Math.abs(diff) > params.threshold || data.allowThresholdMove) {
281
+ if (!data.allowThresholdMove) {
282
+ data.allowThresholdMove = true;
283
+ touches.startX = touches.currentX;
284
+ touches.startY = touches.currentY;
285
+ data.currentTranslate = data.startTranslate;
286
+ touches.diff = swiper.isHorizontal()
287
+ ? touches.currentX - touches.startX
288
+ : touches.currentY - touches.startY;
289
+ return;
290
+ }
291
+ }
292
+ else {
293
+ data.currentTranslate = data.startTranslate;
294
+ return;
295
+ }
296
+ }
297
+ if (!params.followFinger || params.cssMode)
298
+ return;
299
+ // Update active index in free mode
300
+ if ((params.freeMode && params.freeMode.enabled && swiper.freeMode) ||
301
+ params.watchSlidesProgress) {
302
+ swiper.updateActiveIndex();
303
+ swiper.updateSlidesClasses();
304
+ }
305
+ if (params.freeMode && params.freeMode.enabled && swiper.freeMode) {
306
+ swiper.freeMode.onTouchMove();
307
+ }
308
+ // Update progress
309
+ swiper.updateProgress(data.currentTranslate);
310
+ // Update translate
311
+ swiper.setTranslate(data.currentTranslate);
312
+ }
313
+ exports.default = onTouchMove;
314
+ //# sourceMappingURL=onTouchMove.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"onTouchMove.js","sourceRoot":"","sources":["../../../../../../../src/ui/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I,MAAM,CAAC,QAAQ,CAAC;QAC/D,MAAM,CAAC,mBAAmB,EAC1B,CAAC;QACD,MAAM,CAAC,iBAAiB,EAAE,CAAC;QAC3B,MAAM,CAAC,mBAAmB,EAAE,CAAC;IAC/B,CAAC;IACD,IAAI,MAAM,CAAC,QAAQ,IAAI,MAAM,CAAC,QAAQ,CAAC,OAAO,IAAI,MAAM,CAAC,QAAQ,EAAE,CAAC;QAClE,MAAM,CAAC,QAAQ,CAAC,WAAW,EAAE,CAAC;IAChC,CAAC;IACD,kBAAkB;IAClB,MAAM,CAAC,cAAc,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;IAC7C,mBAAmB;IACnB,MAAM,CAAC,YAAY,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;AAC7C,CAAC;AA1UD,8BA0UC"}
@@ -0,0 +1 @@
1
+ export default function onTouchStart(event: any): void;
@@ -0,0 +1,153 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //@ts-nocheck
4
+ var ssr_window_1 = require("ssr-window");
5
+ var utils_1 = require("../../shared/utils.js");
6
+ // Modified from https://stackoverflow.com/questions/54520554/custom-element-getrootnode-closest-function-crossing-multiple-parent-shadowd
7
+ function closestElement(selector, base) {
8
+ if (base === void 0) { base = this; }
9
+ function __closestFrom(el) {
10
+ if (!el || el === (0, ssr_window_1.getDocument)() || el === (0, ssr_window_1.getWindow)())
11
+ return null;
12
+ if (el.assignedSlot)
13
+ el = el.assignedSlot;
14
+ var found = el.closest(selector);
15
+ if (!found && !el.getRootNode) {
16
+ return null;
17
+ }
18
+ return found || __closestFrom(el.getRootNode().host);
19
+ }
20
+ return __closestFrom(base);
21
+ }
22
+ function preventEdgeSwipe(swiper, event, startX) {
23
+ var window = (0, ssr_window_1.getWindow)();
24
+ var params = swiper.params;
25
+ var edgeSwipeDetection = params.edgeSwipeDetection;
26
+ var edgeSwipeThreshold = params.edgeSwipeThreshold;
27
+ if (edgeSwipeDetection &&
28
+ (startX <= edgeSwipeThreshold || startX >= window.innerWidth - edgeSwipeThreshold)) {
29
+ if (edgeSwipeDetection === 'prevent') {
30
+ event.preventDefault();
31
+ return true;
32
+ }
33
+ return false;
34
+ }
35
+ return true;
36
+ }
37
+ function onTouchStart(event) {
38
+ var swiper = this;
39
+ var document = (0, ssr_window_1.getDocument)();
40
+ var e = event;
41
+ if (e.originalEvent)
42
+ e = e.originalEvent;
43
+ var data = swiper.touchEventsData;
44
+ if (e.type === 'pointerdown') {
45
+ if (data.pointerId !== null && data.pointerId !== e.pointerId) {
46
+ return;
47
+ }
48
+ data.pointerId = e.pointerId;
49
+ }
50
+ else if (e.type === 'touchstart' && e.targetTouches.length === 1) {
51
+ data.touchId = e.targetTouches[0].identifier;
52
+ }
53
+ if (e.type === 'touchstart') {
54
+ // don't proceed touch event
55
+ preventEdgeSwipe(swiper, e, e.targetTouches[0].pageX);
56
+ return;
57
+ }
58
+ var params = swiper.params, touches = swiper.touches, enabled = swiper.enabled;
59
+ if (!enabled)
60
+ return;
61
+ if (!params.simulateTouch && e.pointerType === 'mouse')
62
+ return;
63
+ if (swiper.animating && params.preventInteractionOnTransition) {
64
+ return;
65
+ }
66
+ if (!swiper.animating && params.cssMode && params.loop) {
67
+ swiper.loopFix();
68
+ }
69
+ var targetEl = e.target;
70
+ if (params.touchEventsTarget === 'wrapper') {
71
+ if (!swiper.wrapperEl.contains(targetEl))
72
+ return;
73
+ }
74
+ if ('which' in e && e.which === 3)
75
+ return;
76
+ if ('button' in e && e.button > 0)
77
+ return;
78
+ if (data.isTouched && data.isMoved)
79
+ return;
80
+ // change target el for shadow root component
81
+ var swipingClassHasValue = !!params.noSwipingClass && params.noSwipingClass !== '';
82
+ // eslint-disable-next-line
83
+ var eventPath = e.composedPath ? e.composedPath() : e.path;
84
+ if (swipingClassHasValue && e.target && e.target.shadowRoot && eventPath) {
85
+ targetEl = eventPath[0];
86
+ }
87
+ var noSwipingSelector = params.noSwipingSelector
88
+ ? params.noSwipingSelector
89
+ : ".".concat(params.noSwipingClass);
90
+ var isTargetShadow = !!(e.target && e.target.shadowRoot);
91
+ // use closestElement for shadow root element to get the actual closest for nested shadow root element
92
+ if (params.noSwiping &&
93
+ (isTargetShadow
94
+ ? closestElement(noSwipingSelector, targetEl)
95
+ : targetEl.closest(noSwipingSelector))) {
96
+ swiper.allowClick = true;
97
+ return;
98
+ }
99
+ if (params.swipeHandler) {
100
+ if (!targetEl.closest(params.swipeHandler))
101
+ return;
102
+ }
103
+ touches.currentX = e.pageX;
104
+ touches.currentY = e.pageY;
105
+ var startX = touches.currentX;
106
+ var startY = touches.currentY;
107
+ // Do NOT start if iOS edge swipe is detected. Otherwise iOS app cannot swipe-to-go-back anymore
108
+ if (!preventEdgeSwipe(swiper, e, startX)) {
109
+ return;
110
+ }
111
+ Object.assign(data, {
112
+ isTouched: true,
113
+ isMoved: false,
114
+ allowTouchCallbacks: true,
115
+ isScrolling: undefined,
116
+ startMoving: undefined,
117
+ });
118
+ touches.startX = startX;
119
+ touches.startY = startY;
120
+ data.touchStartTime = (0, utils_1.now)();
121
+ swiper.allowClick = true;
122
+ swiper.updateSize();
123
+ swiper.swipeDirection = undefined;
124
+ if (params.threshold > 0)
125
+ data.allowThresholdMove = false;
126
+ var preventDefault = true;
127
+ if (targetEl.matches(data.focusableElements)) {
128
+ preventDefault = false;
129
+ if (targetEl.nodeName === 'SELECT') {
130
+ data.isTouched = false;
131
+ }
132
+ }
133
+ if (document.activeElement &&
134
+ document.activeElement.matches(data.focusableElements) &&
135
+ document.activeElement !== targetEl) {
136
+ document.activeElement.blur();
137
+ }
138
+ var shouldPreventDefault = preventDefault && swiper.allowTouchMove && params.touchStartPreventDefault;
139
+ if ((params.touchStartForcePreventDefault || shouldPreventDefault) &&
140
+ !targetEl.isContentEditable) {
141
+ e.preventDefault();
142
+ }
143
+ if (params.freeMode &&
144
+ params.freeMode.enabled &&
145
+ swiper.freeMode &&
146
+ swiper.animating &&
147
+ !params.cssMode) {
148
+ swiper.freeMode.onTouchStart();
149
+ }
150
+ swiper.emit('touchStart', e);
151
+ }
152
+ exports.default = onTouchStart;
153
+ //# sourceMappingURL=onTouchStart.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"onTouchStart.js","sourceRoot":"","sources":["../../../../../../../src/ui/components/carousel/swiper/core/events/onTouchStart.tsx"],"names":[],"mappings":";;AAAA,aAAa;AACb,yCAAoD;AACpD,4CAAyC;AAEzC,0IAA0I;AAC1I,SAAS,cAAc,CAAC,QAAQ,EAAE,IAAW;IAAX,qBAAA,EAAA,WAAW;IAC3C,SAAS,aAAa,CAAC,EAAE;QACvB,IAAI,CAAC,EAAE,IAAI,EAAE,KAAK,IAAA,wBAAW,GAAE,IAAI,EAAE,KAAK,IAAA,sBAAS,GAAE;YAAE,OAAO,IAAI,CAAC;QACnE,IAAI,EAAE,CAAC,YAAY;YAAE,EAAE,GAAG,EAAE,CAAC,YAAY,CAAC;QAC1C,IAAM,KAAK,GAAG,EAAE,CAAC,OAAO,CAAC,QAAQ,CAAC,CAAC;QACnC,IAAI,CAAC,KAAK,IAAI,CAAC,EAAE,CAAC,WAAW,EAAE,CAAC;YAC9B,OAAO,IAAI,CAAC;QACd,CAAC;QACD,OAAO,KAAK,IAAI,aAAa,CAAC,EAAE,CAAC,WAAW,EAAE,CAAC,IAAI,CAAC,CAAC;IACvD,CAAC;IACD,OAAO,aAAa,CAAC,IAAI,CAAC,CAAC;AAC7B,CAAC;AAED,SAAS,gBAAgB,CAAC,MAAM,EAAE,KAAK,EAAE,MAAM;IAC7C,IAAM,MAAM,GAAG,IAAA,sBAAS,GAAE,CAAC;IACnB,IAAA,MAAM,GAAK,MAAM,OAAX,CAAY;IAC1B,IAAM,kBAAkB,GAAG,MAAM,CAAC,kBAAkB,CAAC;IACrD,IAAM,kBAAkB,GAAG,MAAM,CAAC,kBAAkB,CAAC;IACrD,IACE,kBAAkB;QAClB,CAAC,MAAM,IAAI,kBAAkB,IAAI,MAAM,IAAI,MAAM,C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AAC,CAAC,CAAC;AAC/B,CAAC;AA/HD,+BA+HC"}
@@ -0,0 +1,7 @@
1
+ import setGrabCursor from './setGrabCursor.js';
2
+ import unsetGrabCursor from './unsetGrabCursor.js';
3
+ declare const _default: {
4
+ setGrabCursor: typeof setGrabCursor;
5
+ unsetGrabCursor: typeof unsetGrabCursor;
6
+ };
7
+ export default _default;
@@ -0,0 +1,12 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ var setGrabCursor_1 = __importDefault(require("./setGrabCursor.js"));
7
+ var unsetGrabCursor_1 = __importDefault(require("./unsetGrabCursor.js"));
8
+ exports.default = {
9
+ setGrabCursor: setGrabCursor_1.default,
10
+ unsetGrabCursor: unsetGrabCursor_1.default,
11
+ };
12
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../src/ui/components/carousel/swiper/core/grab-cursor/index.tsx"],"names":[],"mappings":";;;;;AAAA,kEAA4C;AAC5C,sEAAgD;AAEhD,kBAAe;IACb,aAAa,yBAAA;IACb,eAAe,2BAAA;CAChB,CAAC"}
@@ -0,0 +1 @@
1
+ export default function setGrabCursor(moving: any): void;
@@ -0,0 +1,22 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ function setGrabCursor(moving) {
4
+ var swiper = this;
5
+ if (!swiper.params.simulateTouch ||
6
+ (swiper.params.watchOverflow && swiper.isLocked) ||
7
+ swiper.params.cssMode)
8
+ return;
9
+ var el = swiper.params.touchEventsTarget === 'container' ? swiper.el : swiper.wrapperEl;
10
+ if (swiper.isElement) {
11
+ swiper.__preventObserver__ = true;
12
+ }
13
+ el.style.cursor = 'move';
14
+ el.style.cursor = moving ? 'grabbing' : 'grab';
15
+ if (swiper.isElement) {
16
+ requestAnimationFrame(function () {
17
+ swiper.__preventObserver__ = false;
18
+ });
19
+ }
20
+ }
21
+ exports.default = setGrabCursor;
22
+ //# sourceMappingURL=setGrabCursor.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"setGrabCursor.js","sourceRoot":"","sources":["../../../../../../../src/ui/components/carousel/swiper/core/grab-cursor/setGrabCursor.tsx"],"names":[],"mappings":";;AAAA,SAAwB,aAAa,CAAC,MAAM;IAC1C,IAAM,MAAM,GAAG,IAAI,CAAC;IACpB,IACE,CAAC,MAAM,CAAC,MAAM,CAAC,aAAa;QAC5B,CAAC,MAAM,CAAC,MAAM,CAAC,aAAa,IAAI,MAAM,CAAC,QAAQ,CAAC;QAChD,MAAM,CAAC,MAAM,CAAC,OAAO;QAErB,OAAO;IACT,IAAM,EAAE,GAAG,MAAM,CAAC,MAAM,CAAC,iBAAiB,KAAK,WAAW,CAAC,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,CAAC,CAAC,MAAM,CAAC,SAAS,CAAC;IAC1F,IAAI,MAAM,CAAC,SAAS,EAAE,CAAC;QACrB,MAAM,CAAC,mBAAmB,GAAG,IAAI,CAAC;IACpC,CAAC;IACD,EAAE,CAAC,KAAK,CAAC,MAAM,GAAG,MAAM,CAAC;IACzB,EAAE,CAAC,KAAK,CAAC,MAAM,GAAG,MAAM,CAAC,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,MAAM,CAAC;IAC/C,IAAI,MAAM,CAAC,SAAS,EAAE,CAAC;QACrB,qBAAqB,CAAC;YACpB,MAAM,CAAC,mBAAmB,GAAG,KAAK,CAAC;QACrC,CAAC,CAAC,CAAC;IACL,CAAC;AACH,CAAC;AAnBD,gCAmBC"}
@@ -0,0 +1 @@
1
+ export default function unsetGrabCursor(): void;
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ function unsetGrabCursor() {
4
+ var swiper = this;
5
+ if ((swiper.params.watchOverflow && swiper.isLocked) || swiper.params.cssMode) {
6
+ return;
7
+ }
8
+ if (swiper.isElement) {
9
+ swiper.__preventObserver__ = true;
10
+ }
11
+ swiper[swiper.params.touchEventsTarget === 'container' ? 'el' : 'wrapperEl'].style.cursor = '';
12
+ if (swiper.isElement) {
13
+ requestAnimationFrame(function () {
14
+ swiper.__preventObserver__ = false;
15
+ });
16
+ }
17
+ }
18
+ exports.default = unsetGrabCursor;
19
+ //# sourceMappingURL=unsetGrabCursor.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"unsetGrabCursor.js","sourceRoot":"","sources":["../../../../../../../src/ui/components/carousel/swiper/core/grab-cursor/unsetGrabCursor.tsx"],"names":[],"mappings":";;AAAA,SAAwB,eAAe;IACrC,IAAM,MAAM,GAAG,IAAI,CAAC;IACpB,IAAI,CAAC,MAAM,CAAC,MAAM,CAAC,aAAa,IAAI,MAAM,CAAC,QAAQ,CAAC,IAAI,MAAM,CAAC,MAAM,CAAC,OAAO,EAAE,CAAC;QAC9E,OAAO;IACT,CAAC;IACD,IAAI,MAAM,CAAC,SAAS,EAAE,CAAC;QACrB,MAAM,CAAC,mBAAmB,GAAG,IAAI,CAAC;IACpC,CAAC;IACD,MAAM,CAAC,MAAM,CAAC,MAAM,CAAC,iBAAiB,KAAK,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,WAAW,CAAC,CAAC,KAAK,CAAC,MAAM,GAAG,EAAE,CAAC;IAC/F,IAAI,MAAM,CAAC,SAAS,EAAE,CAAC;QACrB,qBAAqB,CAAC;YACpB,MAAM,CAAC,mBAAmB,GAAG,KAAK,CAAC;QACrC,CAAC,CAAC,CAAC;IACL,CAAC;AACH,CAAC;AAdD,kCAcC"}
@@ -0,0 +1,9 @@
1
+ import loopCreate from './loopCreate.js';
2
+ import loopFix from './loopFix.js';
3
+ import loopDestroy from './loopDestroy.js';
4
+ declare const _default: {
5
+ loopCreate: typeof loopCreate;
6
+ loopFix: typeof loopFix;
7
+ loopDestroy: typeof loopDestroy;
8
+ };
9
+ export default _default;
@@ -0,0 +1,14 @@
1
+ "use strict";
2
+ var __importDefault = (this && this.__importDefault) || function (mod) {
3
+ return (mod && mod.__esModule) ? mod : { "default": mod };
4
+ };
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ var loopCreate_1 = __importDefault(require("./loopCreate.js"));
7
+ var loopFix_1 = __importDefault(require("./loopFix.js"));
8
+ var loopDestroy_1 = __importDefault(require("./loopDestroy.js"));
9
+ exports.default = {
10
+ loopCreate: loopCreate_1.default,
11
+ loopFix: loopFix_1.default,
12
+ loopDestroy: loopDestroy_1.default,
13
+ };
14
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../../../src/ui/components/carousel/swiper/core/loop/index.tsx"],"names":[],"mappings":";;;;;AAAA,4DAAsC;AACtC,sDAAgC;AAChC,8DAAwC;AAExC,kBAAe;IACb,UAAU,sBAAA;IACV,OAAO,mBAAA;IACP,WAAW,uBAAA;CACZ,CAAC"}
@@ -0,0 +1 @@
1
+ export default function loopCreate(slideRealIndex: any): void;