@okam/stack-ui 1.29.1 → 1.30.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (395) hide show
  1. package/components/Accordion/components/AccordionItem.d.ts +1 -0
  2. package/components/Accordion/index.d.ts +2 -1
  3. package/components/Accordion/interface.d.ts +3 -2
  4. package/components/Alerts/components/AlertsCloseButton.d.ts +1 -1
  5. package/components/Alerts/index.d.ts +2 -1
  6. package/components/Alerts/interface.d.ts +4 -3
  7. package/components/Box/index.d.ts +3 -2
  8. package/components/Button/index.d.ts +8 -4
  9. package/components/Button/interface.d.ts +3 -2
  10. package/components/Calendar/index.d.ts +5 -1
  11. package/components/Calendar/interface.d.ts +2 -1
  12. package/components/Carousel/components/CarouselNavigationButton.d.ts +3 -3
  13. package/components/Date/index.d.ts +2 -1
  14. package/components/Date/interface.d.ts +2 -1
  15. package/components/Icon/index.d.ts +2 -1
  16. package/components/Icon/interface.d.ts +2 -1
  17. package/components/Lightbox/hooks/overlay/index.d.ts +75 -0
  18. package/components/Lightbox/index.d.ts +2 -1
  19. package/components/Lightbox/interface.d.ts +3 -2
  20. package/components/Menu/Menu.d.ts +2 -1
  21. package/components/Menu/interface.d.ts +5 -4
  22. package/components/Modal/index.d.ts +2 -1
  23. package/components/Modal/interface.d.ts +2 -1
  24. package/components/Popover/index.d.ts +5 -2
  25. package/components/Popover/interface.d.ts +3 -2
  26. package/components/ShareButton/index.d.ts +2 -1
  27. package/components/ShareButton/interface.d.ts +2 -2
  28. package/components/SidePanel/index.d.ts +3 -3
  29. package/components/SidePanel/interface.d.ts +5 -4
  30. package/components/Typography/index.d.ts +3 -2
  31. package/components/Video/index.d.ts +2 -1
  32. package/components/Video/interface.d.ts +2 -1
  33. package/components/WysiwygBlock/index.d.ts +2 -1
  34. package/components/WysiwygBlock/interface.d.ts +2 -1
  35. package/components/fields/Checkbox/Checkbox.interface.d.ts +2 -1
  36. package/components/fields/Checkbox/index.d.ts +2 -1
  37. package/components/fields/CheckboxGroup/index.d.ts +2 -1
  38. package/components/fields/CheckboxGroup/interface.d.ts +2 -1
  39. package/components/fields/DatePicker/index.d.ts +2 -1
  40. package/components/fields/DatePicker/interface.d.ts +2 -1
  41. package/components/fields/Radio/Radio.interface.d.ts +3 -2
  42. package/components/fields/Radio/index.d.ts +3 -2
  43. package/components/fields/RadioGroup/index.d.ts +2 -1
  44. package/components/fields/RadioGroup/interface.d.ts +2 -1
  45. package/components/fields/SearchField/index.d.ts +2 -1
  46. package/components/fields/SearchField/interface.d.ts +2 -1
  47. package/components/fields/Select/Select.d.ts +2 -1
  48. package/components/fields/Select/Select.interface.d.ts +3 -2
  49. package/components/fields/TextArea/index.d.ts +2 -1
  50. package/components/fields/TextInputField/interface.d.ts +3 -2
  51. package/index.d.ts +1 -0
  52. package/index.js +1 -1
  53. package/index.mjs +41 -38
  54. package/index10.js +1 -1
  55. package/index10.mjs +1 -0
  56. package/index100.js +1 -2
  57. package/index100.mjs +22 -21
  58. package/index101.js +2 -1
  59. package/index101.mjs +22 -63
  60. package/index102.js +1 -1
  61. package/index102.mjs +58 -24
  62. package/index103.js +1 -1
  63. package/index103.mjs +29 -52
  64. package/index104.js +1 -1
  65. package/index104.mjs +52 -4
  66. package/index105.js +1 -1
  67. package/index105.mjs +4 -11
  68. package/index106.js +1 -1
  69. package/index106.mjs +11 -14
  70. package/index107.js +1 -1
  71. package/index107.mjs +13 -22
  72. package/index108.js +1 -1
  73. package/index108.mjs +19 -19
  74. package/index109.js +1 -1
  75. package/index109.mjs +22 -38
  76. package/index11.js +1 -1
  77. package/index11.mjs +2 -2
  78. package/index110.js +1 -2
  79. package/index110.mjs +38 -12
  80. package/index111.js +2 -1
  81. package/index111.mjs +12 -7
  82. package/index112.js +1 -1
  83. package/index112.mjs +7 -21
  84. package/index113.js +1 -1
  85. package/index113.mjs +21 -38
  86. package/index114.js +1 -1
  87. package/index114.mjs +38 -49
  88. package/index115.js +1 -1
  89. package/index115.mjs +49 -40
  90. package/index116.js +1 -1
  91. package/index116.mjs +40 -13
  92. package/index117.js +1 -1
  93. package/index117.mjs +14 -26
  94. package/index118.js +1 -1
  95. package/index118.mjs +29 -18
  96. package/index119.js +1 -1
  97. package/index119.mjs +19 -8
  98. package/index120.js +1 -1
  99. package/index120.mjs +9 -30
  100. package/index121.js +1 -1
  101. package/index121.mjs +30 -15
  102. package/index122.js +1 -1
  103. package/index122.mjs +13 -15
  104. package/index123.js +1 -1
  105. package/index123.mjs +17 -21
  106. package/index124.js +1 -1
  107. package/index124.mjs +21 -11
  108. package/index125.js +1 -2
  109. package/index125.mjs +11 -22
  110. package/index126.js +2 -1
  111. package/index126.mjs +22 -12
  112. package/index127.js +1 -1
  113. package/index127.mjs +23 -23
  114. package/index128.js +1 -1
  115. package/index128.mjs +3 -3
  116. package/index13.js +1 -1
  117. package/index13.mjs +10 -9
  118. package/index130.mjs +6 -6
  119. package/index131.js +1 -1
  120. package/index131.mjs +12 -51
  121. package/index132.js +1 -1
  122. package/index132.mjs +49 -25
  123. package/index133.js +1 -1
  124. package/index133.mjs +25 -19
  125. package/index134.js +1 -1
  126. package/index134.mjs +17 -58
  127. package/index135.js +1 -1
  128. package/index135.mjs +194 -89
  129. package/index136.js +1 -1
  130. package/index136.mjs +63 -30
  131. package/index137.js +1 -1
  132. package/index137.mjs +136 -116
  133. package/index138.js +1 -1
  134. package/index138.mjs +118 -26
  135. package/index139.js +1 -1
  136. package/index139.mjs +212 -119
  137. package/index14.js +1 -1
  138. package/index14.mjs +3 -3
  139. package/index140.js +1 -1
  140. package/index140.mjs +187 -131
  141. package/index141.js +1 -1
  142. package/index141.mjs +69 -14
  143. package/index142.js +1 -1
  144. package/index142.mjs +248 -85
  145. package/index143.js +1 -1
  146. package/index143.mjs +93 -102
  147. package/index144.js +1 -1
  148. package/index144.mjs +174 -5
  149. package/index145.js +1 -1
  150. package/index145.mjs +84 -3
  151. package/index146.js +1 -1
  152. package/index146.mjs +56 -123
  153. package/index147.js +1 -1
  154. package/index147.mjs +125 -28
  155. package/index148.js +1 -1
  156. package/index148.mjs +113 -48
  157. package/index149.js +1 -1
  158. package/index149.mjs +119 -41
  159. package/index150.js +1 -1
  160. package/index150.mjs +71 -36
  161. package/index151.js +1 -1
  162. package/index151.mjs +105 -108
  163. package/index152.js +1 -1
  164. package/index152.mjs +52 -77
  165. package/index153.js +1 -1
  166. package/index153.mjs +93 -101
  167. package/index154.js +1 -1
  168. package/index154.mjs +71 -98
  169. package/index155.js +1 -1
  170. package/index155.mjs +50 -193
  171. package/index156.js +1 -1
  172. package/index156.mjs +91 -56
  173. package/index157.js +5 -1
  174. package/index157.mjs +75 -136
  175. package/index158.js +1 -1
  176. package/index158.mjs +1999 -107
  177. package/index159.js +1 -1
  178. package/index159.mjs +56 -214
  179. package/index16.js +1 -1
  180. package/index16.mjs +2 -2
  181. package/index160.js +1 -1
  182. package/index160.mjs +186 -188
  183. package/index161.js +1 -1
  184. package/index161.mjs +59 -67
  185. package/index162.js +1 -1
  186. package/index162.mjs +88 -252
  187. package/index163.js +1 -1
  188. package/index163.mjs +32 -96
  189. package/index164.js +1 -1
  190. package/index164.mjs +117 -170
  191. package/index165.js +1 -1
  192. package/index165.mjs +26 -83
  193. package/index166.js +1 -1
  194. package/index166.mjs +123 -57
  195. package/index167.js +1 -1
  196. package/index167.mjs +130 -122
  197. package/index168.js +1 -1
  198. package/index168.mjs +14 -116
  199. package/index169.js +1 -1
  200. package/index169.mjs +92 -119
  201. package/index170.js +1 -1
  202. package/index170.mjs +105 -71
  203. package/index171.js +1 -1
  204. package/index171.mjs +5 -110
  205. package/index172.js +1 -1
  206. package/index172.mjs +3 -52
  207. package/index173.js +1 -1
  208. package/index173.mjs +124 -92
  209. package/index174.js +1 -1
  210. package/index174.mjs +29 -70
  211. package/index175.js +1 -1
  212. package/index175.mjs +51 -56
  213. package/index176.js +1 -1
  214. package/index176.mjs +44 -99
  215. package/index177.js +1 -5
  216. package/index177.mjs +36 -79
  217. package/index178.js +1 -1
  218. package/index178.mjs +94 -1992
  219. package/index179.js +1 -1
  220. package/index179.mjs +78 -60
  221. package/index18.js +1 -1
  222. package/index18.mjs +7 -7
  223. package/index180.js +1 -1
  224. package/index180.mjs +95 -182
  225. package/index181.js +1 -1
  226. package/index181.mjs +98 -6
  227. package/index19.js +1 -1
  228. package/index19.mjs +2 -2
  229. package/index190.js +1 -1
  230. package/index190.mjs +5 -313
  231. package/index191.js +1 -1
  232. package/index191.mjs +327 -179
  233. package/index192.js +1 -1
  234. package/index192.mjs +183 -8
  235. package/index193.js +1 -1
  236. package/index193.mjs +7 -25
  237. package/index194.js +1 -1
  238. package/index194.mjs +26 -55
  239. package/index195.js +1 -1
  240. package/index195.mjs +55 -46
  241. package/index196.js +1 -1
  242. package/index196.mjs +45 -123
  243. package/index197.js +1 -1
  244. package/index197.mjs +110 -5
  245. package/index198.js +1 -1
  246. package/index198.mjs +31 -27
  247. package/index199.js +1 -1
  248. package/index199.mjs +6 -7
  249. package/index2.js +1 -1
  250. package/index2.mjs +51 -50
  251. package/index20.js +1 -1
  252. package/index20.mjs +1 -1
  253. package/index200.js +1 -1
  254. package/index200.mjs +28 -7
  255. package/index201.js +1 -1
  256. package/index201.mjs +7 -8
  257. package/index202.js +1 -1
  258. package/index202.mjs +6 -3
  259. package/index203.js +1 -1
  260. package/index203.mjs +7 -5
  261. package/index204.js +1 -1
  262. package/index204.mjs +4 -9
  263. package/index205.js +1 -0
  264. package/index205.mjs +8 -0
  265. package/index206.js +1 -0
  266. package/index206.mjs +12 -0
  267. package/index21.js +1 -1
  268. package/index21.mjs +8 -8
  269. package/index22.js +1 -1
  270. package/index22.mjs +2 -2
  271. package/index23.js +1 -1
  272. package/index23.mjs +40 -39
  273. package/index24.js +1 -1
  274. package/index24.mjs +45 -44
  275. package/index26.js +1 -1
  276. package/index26.mjs +28 -21
  277. package/index27.js +1 -1
  278. package/index27.mjs +12 -12
  279. package/index28.js +1 -1
  280. package/index28.mjs +6 -6
  281. package/index29.js +1 -1
  282. package/index29.mjs +1 -1
  283. package/index30.js +1 -1
  284. package/index30.mjs +14 -8
  285. package/index31.js +1 -1
  286. package/index31.mjs +18 -18
  287. package/index32.js +1 -1
  288. package/index32.mjs +1 -1
  289. package/index33.mjs +43 -43
  290. package/index34.js +1 -1
  291. package/index34.mjs +1 -1
  292. package/index35.js +1 -1
  293. package/index35.mjs +3 -3
  294. package/index36.mjs +10 -10
  295. package/index4.js +1 -1
  296. package/index4.mjs +3 -3
  297. package/index6.js +1 -1
  298. package/index6.mjs +47 -46
  299. package/index65.js +1 -1
  300. package/index65.mjs +1 -1
  301. package/index66.js +1 -1
  302. package/index66.mjs +2 -2
  303. package/index67.js +1 -1
  304. package/index67.mjs +1 -1
  305. package/index69.js +1 -1
  306. package/index69.mjs +1 -1
  307. package/index7.mjs +4 -4
  308. package/index70.js +1 -1
  309. package/index70.mjs +1 -1
  310. package/index71.js +1 -1
  311. package/index71.mjs +1 -1
  312. package/index72.js +2 -1
  313. package/index72.mjs +27 -2
  314. package/index73.js +1 -2
  315. package/index73.mjs +2 -9
  316. package/index74.js +1 -1
  317. package/index74.mjs +7 -6
  318. package/index75.js +1 -1
  319. package/index75.mjs +6 -6
  320. package/index76.js +1 -1
  321. package/index76.mjs +6 -6
  322. package/index77.js +2 -1
  323. package/index77.mjs +8 -25
  324. package/index78.js +1 -1
  325. package/index78.mjs +25 -2
  326. package/index79.js +1 -6
  327. package/index79.mjs +2 -94
  328. package/index8.js +1 -1
  329. package/index8.mjs +42 -23
  330. package/index80.js +6 -1
  331. package/index80.mjs +79 -54
  332. package/index81.js +1 -1
  333. package/index81.mjs +61 -33
  334. package/index82.js +1 -42
  335. package/index82.mjs +34 -67
  336. package/index83.js +42 -1
  337. package/index83.mjs +69 -154
  338. package/index84.js +1 -9
  339. package/index84.mjs +149 -47
  340. package/index85.js +9 -1
  341. package/index85.mjs +48 -36
  342. package/index86.js +1 -1
  343. package/index86.mjs +40 -8
  344. package/index87.js +1 -1
  345. package/index87.mjs +9 -31
  346. package/index88.js +1 -1
  347. package/index88.mjs +38 -6
  348. package/index89.js +1 -12
  349. package/index89.mjs +6 -40
  350. package/index9.js +1 -1
  351. package/index9.mjs +7 -7
  352. package/index90.js +12 -1
  353. package/index90.mjs +36 -25
  354. package/index91.js +1 -1
  355. package/index91.mjs +24 -8
  356. package/index92.js +1 -7
  357. package/index92.mjs +7 -13
  358. package/index93.js +6 -14
  359. package/index93.mjs +13 -65
  360. package/index94.js +15 -1
  361. package/index94.mjs +71 -7
  362. package/index95.js +1 -16
  363. package/index95.mjs +7 -25
  364. package/index96.js +16 -1
  365. package/index96.mjs +20 -37
  366. package/index97.js +1 -1
  367. package/index97.mjs +40 -43
  368. package/index98.js +1 -1
  369. package/index98.mjs +44 -47
  370. package/index99.js +1 -1
  371. package/index99.mjs +48 -17
  372. package/package.json +1 -1
  373. package/providers/Translation/index.d.ts +4 -0
  374. package/providers/Translation/interface.d.ts +16 -0
  375. package/theme/Accordion/index.d.ts +12 -12
  376. package/theme/Alerts/index.d.ts +22 -22
  377. package/theme/Box/index.d.ts +8 -8
  378. package/theme/Button/index.d.ts +2 -2
  379. package/theme/Calendar/index.d.ts +12 -12
  380. package/theme/Carousel/index.d.ts +11 -11
  381. package/theme/Checkbox/index.d.ts +8 -8
  382. package/theme/CheckboxGroup/index.d.ts +3 -3
  383. package/theme/DatePicker/index.d.ts +10 -9
  384. package/theme/Image/index.d.ts +1 -1
  385. package/theme/LightBox/index.d.ts +9 -9
  386. package/theme/Radio/index.d.ts +6 -6
  387. package/theme/RadioGroup/index.d.ts +3 -3
  388. package/theme/Search/index.d.ts +3 -3
  389. package/theme/ShareButton/index.d.ts +10 -10
  390. package/theme/SidePanel/index.d.ts +3 -3
  391. package/theme/TextArea/index.d.ts +2 -2
  392. package/theme/Typography/index.d.ts +2 -2
  393. package/transitions/ModalTransition.d.ts +3 -6
  394. package/transitions/RenderWithSlide.d.ts +3 -6
  395. package/transitions/SidePanelTransition.d.ts +3 -6
package/index139.mjs CHANGED
@@ -1,127 +1,220 @@
1
- import { add as n, subtract as o, set as $, cycleDate as f, constrain as l, setTime as b, cycleTime as x } from "./index140.mjs";
2
- import { compareDate as m, compareTime as v } from "./index131.mjs";
3
- import { dateToString as w, dateTimeToString as D } from "./index141.mjs";
4
- import { GregorianCalendar as T } from "./index142.mjs";
5
- import { toDate as u, toCalendarDateTime as C } from "./index143.mjs";
6
- import { _class_private_field_init as p } from "./index144.mjs";
7
- function y(r) {
8
- let t = typeof r[0] == "object" ? r.shift() : new T(), e;
9
- if (typeof r[0] == "string") e = r.shift();
10
- else {
11
- let s = t.getEras();
12
- e = s[s.length - 1];
13
- }
14
- let a = r.shift(), i = r.shift(), h = r.shift();
15
- return [
16
- t,
17
- e,
18
- a,
19
- i,
20
- h
21
- ];
22
- }
23
- var S = /* @__PURE__ */ new WeakMap();
24
- class d {
25
- /** Returns a copy of this date. */
26
- copy() {
27
- return this.era ? new d(this.calendar, this.era, this.year, this.month, this.day) : new d(this.calendar, this.year, this.month, this.day);
28
- }
29
- /** Returns a new `CalendarDate` with the given duration added to it. */
30
- add(t) {
31
- return n(this, t);
32
- }
33
- /** Returns a new `CalendarDate` with the given duration subtracted from it. */
34
- subtract(t) {
35
- return o(this, t);
36
- }
37
- /** Returns a new `CalendarDate` with the given fields set to the provided values. Other fields will be constrained accordingly. */
38
- set(t) {
39
- return $(this, t);
40
- }
41
- /**
42
- * Returns a new `CalendarDate` with the given field adjusted by a specified amount.
43
- * When the resulting value reaches the limits of the field, it wraps around.
44
- */
45
- cycle(t, e, a) {
46
- return f(this, t, e, a);
47
- }
48
- /** Converts the date to a native JavaScript Date object, with the time set to midnight in the given time zone. */
49
- toDate(t) {
50
- return u(this, t);
51
- }
52
- /** Converts the date to an ISO 8601 formatted string. */
53
- toString() {
54
- return w(this);
55
- }
56
- /** Compares this date with another. A negative result indicates that this date is before the given one, and a positive date indicates that it is after. */
57
- compare(t) {
58
- return m(this, t);
59
- }
60
- constructor(...t) {
61
- p(this, S, {
62
- writable: !0,
63
- value: void 0
1
+ import { c as $ } from "./index185.mjs";
2
+ import { c as w } from "./index184.mjs";
3
+ import { m, f as F, g as P, a as E } from "./index183.mjs";
4
+ function R(D) {
5
+ let {
6
+ swiper: e,
7
+ extendParams: H,
8
+ on: g,
9
+ emit: v
10
+ } = D;
11
+ const d = "swiper-pagination";
12
+ H({
13
+ pagination: {
14
+ el: null,
15
+ bulletElement: "span",
16
+ clickable: !1,
17
+ hideOnClick: !1,
18
+ renderBullet: null,
19
+ renderProgressbar: null,
20
+ renderFraction: null,
21
+ renderCustom: null,
22
+ progressbarOpposite: !1,
23
+ type: "bullets",
24
+ // 'bullets' or 'progressbar' or 'fraction' or 'custom'
25
+ dynamicBullets: !1,
26
+ dynamicMainBullets: 1,
27
+ formatFractionCurrent: (a) => a,
28
+ formatFractionTotal: (a) => a,
29
+ bulletClass: `${d}-bullet`,
30
+ bulletActiveClass: `${d}-bullet-active`,
31
+ modifierClass: `${d}-`,
32
+ currentClass: `${d}-current`,
33
+ totalClass: `${d}-total`,
34
+ hiddenClass: `${d}-hidden`,
35
+ progressbarFillClass: `${d}-progressbar-fill`,
36
+ progressbarOppositeClass: `${d}-progressbar-opposite`,
37
+ clickableClass: `${d}-clickable`,
38
+ lockClass: `${d}-lock`,
39
+ horizontalClass: `${d}-horizontal`,
40
+ verticalClass: `${d}-vertical`,
41
+ paginationDisabledClass: `${d}-disabled`
42
+ }
43
+ }), e.pagination = {
44
+ el: null,
45
+ bullets: []
46
+ };
47
+ let b, u = 0;
48
+ function k() {
49
+ return !e.params.pagination.el || !e.pagination.el || Array.isArray(e.pagination.el) && e.pagination.el.length === 0;
50
+ }
51
+ function x(a, s) {
52
+ const {
53
+ bulletActiveClass: t
54
+ } = e.params.pagination;
55
+ a && (a = a[`${s === "prev" ? "previous" : "next"}ElementSibling`], a && (a.classList.add(`${t}-${s}`), a = a[`${s === "prev" ? "previous" : "next"}ElementSibling`], a && a.classList.add(`${t}-${s}-${s}`)));
56
+ }
57
+ function I(a) {
58
+ const s = a.target.closest($(e.params.pagination.bulletClass));
59
+ if (!s)
60
+ return;
61
+ a.preventDefault();
62
+ const t = P(s) * e.params.slidesPerGroup;
63
+ if (e.params.loop) {
64
+ if (e.realIndex === t) return;
65
+ e.slideToLoop(t);
66
+ } else
67
+ e.slideTo(t);
68
+ }
69
+ function h() {
70
+ const a = e.rtl, s = e.params.pagination;
71
+ if (k()) return;
72
+ let t = e.pagination.el;
73
+ t = m(t);
74
+ let i, p;
75
+ const C = e.virtual && e.params.virtual.enabled ? e.virtual.slides.length : e.slides.length, z = e.params.loop ? Math.ceil(C / e.params.slidesPerGroup) : e.snapGrid.length;
76
+ if (e.params.loop ? (p = e.previousRealIndex || 0, i = e.params.slidesPerGroup > 1 ? Math.floor(e.realIndex / e.params.slidesPerGroup) : e.realIndex) : typeof e.snapIndex < "u" ? (i = e.snapIndex, p = e.previousSnapIndex) : (p = e.previousIndex || 0, i = e.activeIndex || 0), s.type === "bullets" && e.pagination.bullets && e.pagination.bullets.length > 0) {
77
+ const l = e.pagination.bullets;
78
+ let f, c, L;
79
+ if (s.dynamicBullets && (b = F(l[0], e.isHorizontal() ? "width" : "height"), t.forEach((n) => {
80
+ n.style[e.isHorizontal() ? "width" : "height"] = `${b * (s.dynamicMainBullets + 4)}px`;
81
+ }), s.dynamicMainBullets > 1 && p !== void 0 && (u += i - (p || 0), u > s.dynamicMainBullets - 1 ? u = s.dynamicMainBullets - 1 : u < 0 && (u = 0)), f = Math.max(i - u, 0), c = f + (Math.min(l.length, s.dynamicMainBullets) - 1), L = (c + f) / 2), l.forEach((n) => {
82
+ const r = [...["", "-next", "-next-next", "-prev", "-prev-prev", "-main"].map((o) => `${s.bulletActiveClass}${o}`)].map((o) => typeof o == "string" && o.includes(" ") ? o.split(" ") : o).flat();
83
+ n.classList.remove(...r);
84
+ }), t.length > 1)
85
+ l.forEach((n) => {
86
+ const r = P(n);
87
+ r === i ? n.classList.add(...s.bulletActiveClass.split(" ")) : e.isElement && n.setAttribute("part", "bullet"), s.dynamicBullets && (r >= f && r <= c && n.classList.add(...`${s.bulletActiveClass}-main`.split(" ")), r === f && x(n, "prev"), r === c && x(n, "next"));
88
+ });
89
+ else {
90
+ const n = l[i];
91
+ if (n && n.classList.add(...s.bulletActiveClass.split(" ")), e.isElement && l.forEach((r, o) => {
92
+ r.setAttribute("part", o === i ? "bullet-active" : "bullet");
93
+ }), s.dynamicBullets) {
94
+ const r = l[f], o = l[c];
95
+ for (let y = f; y <= c; y += 1)
96
+ l[y] && l[y].classList.add(...`${s.bulletActiveClass}-main`.split(" "));
97
+ x(r, "prev"), x(o, "next");
98
+ }
99
+ }
100
+ if (s.dynamicBullets) {
101
+ const n = Math.min(l.length, s.dynamicMainBullets + 4), r = (b * n - b) / 2 - L * b, o = a ? "right" : "left";
102
+ l.forEach((y) => {
103
+ y.style[e.isHorizontal() ? o : "top"] = `${r}px`;
104
+ });
105
+ }
106
+ }
107
+ t.forEach((l, f) => {
108
+ if (s.type === "fraction" && (l.querySelectorAll($(s.currentClass)).forEach((c) => {
109
+ c.textContent = s.formatFractionCurrent(i + 1);
110
+ }), l.querySelectorAll($(s.totalClass)).forEach((c) => {
111
+ c.textContent = s.formatFractionTotal(z);
112
+ })), s.type === "progressbar") {
113
+ let c;
114
+ s.progressbarOpposite ? c = e.isHorizontal() ? "vertical" : "horizontal" : c = e.isHorizontal() ? "horizontal" : "vertical";
115
+ const L = (i + 1) / z;
116
+ let n = 1, r = 1;
117
+ c === "horizontal" ? n = L : r = L, l.querySelectorAll($(s.progressbarFillClass)).forEach((o) => {
118
+ o.style.transform = `translate3d(0,0,0) scaleX(${n}) scaleY(${r})`, o.style.transitionDuration = `${e.params.speed}ms`;
119
+ });
120
+ }
121
+ s.type === "custom" && s.renderCustom ? (l.innerHTML = s.renderCustom(e, i + 1, z), f === 0 && v("paginationRender", l)) : (f === 0 && v("paginationRender", l), v("paginationUpdate", l)), e.params.watchOverflow && e.enabled && l.classList[e.isLocked ? "add" : "remove"](s.lockClass);
64
122
  });
65
- let [e, a, i, h, s] = y(t);
66
- this.calendar = e, this.era = a, this.year = i, this.month = h, this.day = s, l(this);
67
123
  }
68
- }
69
- var k = /* @__PURE__ */ new WeakMap();
70
- class c {
71
- /** Returns a copy of this date. */
72
- copy() {
73
- return this.era ? new c(this.calendar, this.era, this.year, this.month, this.day, this.hour, this.minute, this.second, this.millisecond) : new c(this.calendar, this.year, this.month, this.day, this.hour, this.minute, this.second, this.millisecond);
74
- }
75
- /** Returns a new `CalendarDateTime` with the given duration added to it. */
76
- add(t) {
77
- return n(this, t);
78
- }
79
- /** Returns a new `CalendarDateTime` with the given duration subtracted from it. */
80
- subtract(t) {
81
- return o(this, t);
82
- }
83
- /** Returns a new `CalendarDateTime` with the given fields set to the provided values. Other fields will be constrained accordingly. */
84
- set(t) {
85
- return $(b(this, t), t);
86
- }
87
- /**
88
- * Returns a new `CalendarDateTime` with the given field adjusted by a specified amount.
89
- * When the resulting value reaches the limits of the field, it wraps around.
90
- */
91
- cycle(t, e, a) {
92
- switch (t) {
93
- case "era":
94
- case "year":
95
- case "month":
96
- case "day":
97
- return f(this, t, e, a);
98
- default:
99
- return x(this, t, e, a);
124
+ function B() {
125
+ const a = e.params.pagination;
126
+ if (k()) return;
127
+ const s = e.virtual && e.params.virtual.enabled ? e.virtual.slides.length : e.grid && e.params.grid.rows > 1 ? e.slides.length / Math.ceil(e.params.grid.rows) : e.slides.length;
128
+ let t = e.pagination.el;
129
+ t = m(t);
130
+ let i = "";
131
+ if (a.type === "bullets") {
132
+ let p = e.params.loop ? Math.ceil(s / e.params.slidesPerGroup) : e.snapGrid.length;
133
+ e.params.freeMode && e.params.freeMode.enabled && p > s && (p = s);
134
+ for (let C = 0; C < p; C += 1)
135
+ a.renderBullet ? i += a.renderBullet.call(e, C, a.bulletClass) : i += `<${a.bulletElement} ${e.isElement ? 'part="bullet"' : ""} class="${a.bulletClass}"></${a.bulletElement}>`;
100
136
  }
137
+ a.type === "fraction" && (a.renderFraction ? i = a.renderFraction.call(e, a.currentClass, a.totalClass) : i = `<span class="${a.currentClass}"></span> / <span class="${a.totalClass}"></span>`), a.type === "progressbar" && (a.renderProgressbar ? i = a.renderProgressbar.call(e, a.progressbarFillClass) : i = `<span class="${a.progressbarFillClass}"></span>`), e.pagination.bullets = [], t.forEach((p) => {
138
+ a.type !== "custom" && (p.innerHTML = i || ""), a.type === "bullets" && e.pagination.bullets.push(...p.querySelectorAll($(a.bulletClass)));
139
+ }), a.type !== "custom" && v("paginationRender", t[0]);
101
140
  }
102
- /** Converts the date to a native JavaScript Date object in the given time zone. */
103
- toDate(t, e) {
104
- return u(this, t, e);
105
- }
106
- /** Converts the date to an ISO 8601 formatted string. */
107
- toString() {
108
- return D(this);
109
- }
110
- /** Compares this date with another. A negative result indicates that this date is before the given one, and a positive date indicates that it is after. */
111
- compare(t) {
112
- let e = m(this, t);
113
- return e === 0 ? v(this, C(t)) : e;
114
- }
115
- constructor(...t) {
116
- p(this, k, {
117
- writable: !0,
118
- value: void 0
141
+ function A() {
142
+ e.params.pagination = w(e, e.originalParams.pagination, e.params.pagination, {
143
+ el: "swiper-pagination"
119
144
  });
120
- let [e, a, i, h, s] = y(t);
121
- this.calendar = e, this.era = a, this.year = i, this.month = h, this.day = s, this.hour = t.shift() || 0, this.minute = t.shift() || 0, this.second = t.shift() || 0, this.millisecond = t.shift() || 0, l(this);
122
- }
145
+ const a = e.params.pagination;
146
+ if (!a.el) return;
147
+ let s;
148
+ typeof a.el == "string" && e.isElement && (s = e.el.querySelector(a.el)), !s && typeof a.el == "string" && (s = [...document.querySelectorAll(a.el)]), s || (s = a.el), !(!s || s.length === 0) && (e.params.uniqueNavElements && typeof a.el == "string" && Array.isArray(s) && s.length > 1 && (s = [...e.el.querySelectorAll(a.el)], s.length > 1 && (s = s.filter((t) => E(t, ".swiper")[0] === e.el)[0])), Array.isArray(s) && s.length === 1 && (s = s[0]), Object.assign(e.pagination, {
149
+ el: s
150
+ }), s = m(s), s.forEach((t) => {
151
+ a.type === "bullets" && a.clickable && t.classList.add(...(a.clickableClass || "").split(" ")), t.classList.add(a.modifierClass + a.type), t.classList.add(e.isHorizontal() ? a.horizontalClass : a.verticalClass), a.type === "bullets" && a.dynamicBullets && (t.classList.add(`${a.modifierClass}${a.type}-dynamic`), u = 0, a.dynamicMainBullets < 1 && (a.dynamicMainBullets = 1)), a.type === "progressbar" && a.progressbarOpposite && t.classList.add(a.progressbarOppositeClass), a.clickable && t.addEventListener("click", I), e.enabled || t.classList.add(a.lockClass);
152
+ }));
153
+ }
154
+ function M() {
155
+ const a = e.params.pagination;
156
+ if (k()) return;
157
+ let s = e.pagination.el;
158
+ s && (s = m(s), s.forEach((t) => {
159
+ t.classList.remove(a.hiddenClass), t.classList.remove(a.modifierClass + a.type), t.classList.remove(e.isHorizontal() ? a.horizontalClass : a.verticalClass), a.clickable && (t.classList.remove(...(a.clickableClass || "").split(" ")), t.removeEventListener("click", I));
160
+ })), e.pagination.bullets && e.pagination.bullets.forEach((t) => t.classList.remove(...a.bulletActiveClass.split(" ")));
161
+ }
162
+ g("changeDirection", () => {
163
+ if (!e.pagination || !e.pagination.el) return;
164
+ const a = e.params.pagination;
165
+ let {
166
+ el: s
167
+ } = e.pagination;
168
+ s = m(s), s.forEach((t) => {
169
+ t.classList.remove(a.horizontalClass, a.verticalClass), t.classList.add(e.isHorizontal() ? a.horizontalClass : a.verticalClass);
170
+ });
171
+ }), g("init", () => {
172
+ e.params.pagination.enabled === !1 ? S() : (A(), B(), h());
173
+ }), g("activeIndexChange", () => {
174
+ typeof e.snapIndex > "u" && h();
175
+ }), g("snapIndexChange", () => {
176
+ h();
177
+ }), g("snapGridLengthChange", () => {
178
+ B(), h();
179
+ }), g("destroy", () => {
180
+ M();
181
+ }), g("enable disable", () => {
182
+ let {
183
+ el: a
184
+ } = e.pagination;
185
+ a && (a = m(a), a.forEach((s) => s.classList[e.enabled ? "remove" : "add"](e.params.pagination.lockClass)));
186
+ }), g("lock unlock", () => {
187
+ h();
188
+ }), g("click", (a, s) => {
189
+ const t = s.target, i = m(e.pagination.el);
190
+ if (e.params.pagination.el && e.params.pagination.hideOnClick && i && i.length > 0 && !t.classList.contains(e.params.pagination.bulletClass)) {
191
+ if (e.navigation && (e.navigation.nextEl && t === e.navigation.nextEl || e.navigation.prevEl && t === e.navigation.prevEl)) return;
192
+ const p = i[0].classList.contains(e.params.pagination.hiddenClass);
193
+ v(p === !0 ? "paginationShow" : "paginationHide"), i.forEach((C) => C.classList.toggle(e.params.pagination.hiddenClass));
194
+ }
195
+ });
196
+ const O = () => {
197
+ e.el.classList.remove(e.params.pagination.paginationDisabledClass);
198
+ let {
199
+ el: a
200
+ } = e.pagination;
201
+ a && (a = m(a), a.forEach((s) => s.classList.remove(e.params.pagination.paginationDisabledClass))), A(), B(), h();
202
+ }, S = () => {
203
+ e.el.classList.add(e.params.pagination.paginationDisabledClass);
204
+ let {
205
+ el: a
206
+ } = e.pagination;
207
+ a && (a = m(a), a.forEach((s) => s.classList.add(e.params.pagination.paginationDisabledClass))), M();
208
+ };
209
+ Object.assign(e.pagination, {
210
+ enable: O,
211
+ disable: S,
212
+ render: B,
213
+ update: h,
214
+ init: A,
215
+ destroy: M
216
+ });
123
217
  }
124
218
  export {
125
- d as CalendarDate,
126
- c as CalendarDateTime
219
+ R as default
127
220
  };
package/index14.js CHANGED
@@ -1,2 +1,2 @@
1
1
  "use client";
2
- "use strict";const a=require("./index106.js"),o=require("react/jsx-runtime"),t=require("react"),v=require("./index64.js"),x=require("./index104.js"),e=r=>Object.freeze(Object.defineProperty({__proto__:null,default:r},Symbol.toStringTag,{value:"Module"})),q=r=>{const{icon:s,...i}=r,n=t.useMemo(()=>t.lazy(()=>a(Object.assign({"../icons/ArrowDown.tsx":()=>Promise.resolve().then(()=>e(require("./index39.js"))),"../icons/ArrowLeft.tsx":()=>Promise.resolve().then(()=>e(require("./index40.js"))),"../icons/ArrowRight.tsx":()=>Promise.resolve().then(()=>e(require("./index41.js"))),"../icons/Check.tsx":()=>Promise.resolve().then(()=>e(require("./index42.js"))),"../icons/ChevronLeft.tsx":()=>Promise.resolve().then(()=>e(require("./index43.js"))),"../icons/ChevronRight.tsx":()=>Promise.resolve().then(()=>e(require("./index44.js"))),"../icons/CloseBtn.tsx":()=>Promise.resolve().then(()=>e(require("./index45.js"))),"../icons/Facebook.tsx":()=>Promise.resolve().then(()=>e(require("./index46.js"))),"../icons/FacebookColored.tsx":()=>Promise.resolve().then(()=>e(require("./index47.js"))),"../icons/FacebookRounded.tsx":()=>Promise.resolve().then(()=>e(require("./index48.js"))),"../icons/Globe.tsx":()=>Promise.resolve().then(()=>e(require("./index49.js"))),"../icons/IconFallback.tsx":()=>Promise.resolve().then(()=>e(require("./index104.js"))),"../icons/Instagram.tsx":()=>Promise.resolve().then(()=>e(require("./index50.js"))),"../icons/InstagramColored.tsx":()=>Promise.resolve().then(()=>e(require("./index51.js"))),"../icons/Link.tsx":()=>Promise.resolve().then(()=>e(require("./index52.js"))),"../icons/LinkedIn.tsx":()=>Promise.resolve().then(()=>e(require("./index53.js"))),"../icons/Mail.tsx":()=>Promise.resolve().then(()=>e(require("./index54.js"))),"../icons/Plus.tsx":()=>Promise.resolve().then(()=>e(require("./index55.js"))),"../icons/Search.tsx":()=>Promise.resolve().then(()=>e(require("./index105.js"))),"../icons/Share.tsx":()=>Promise.resolve().then(()=>e(require("./index56.js"))),"../icons/Twitter.tsx":()=>Promise.resolve().then(()=>e(require("./index57.js"))),"../icons/TwitterColored.tsx":()=>Promise.resolve().then(()=>e(require("./index58.js"))),"../icons/Upload.tsx":()=>Promise.resolve().then(()=>e(require("./index59.js"))),"../icons/X.tsx":()=>Promise.resolve().then(()=>e(require("./index60.js"))),"../icons/YouTube.tsx":()=>Promise.resolve().then(()=>e(require("./index61.js"))),"../icons/YouTubeColored.tsx":()=>Promise.resolve().then(()=>e(require("./index62.js")))}),`../icons/${s||"ArrowRight"}.tsx`,3)),[s]);return o.jsx(t.Suspense,{fallback:o.jsx(x,{className:"overflow-visible pointer-events-none"}),children:o.jsx(n,{...i,className:"overflow-visible pointer-events-none",...r})})},P=r=>{const{icon:s,as:i="span",tokens:n,customTheme:m,themeName:h="icon",children:c,...l}=r,u=v(h,n,m);return typeof s!="string"?o.jsxs(i,{...l,className:u,children:[c,s]}):o.jsxs(i,{className:u,children:[c,o.jsx(q,{icon:s,...l})]})};module.exports=P;
2
+ "use strict";const a=require("./index107.js"),o=require("react/jsx-runtime"),t=require("react"),v=require("./index64.js"),x=require("./index105.js"),e=r=>Object.freeze(Object.defineProperty({__proto__:null,default:r},Symbol.toStringTag,{value:"Module"})),q=r=>{const{icon:s,...i}=r,n=t.useMemo(()=>t.lazy(()=>a(Object.assign({"../icons/ArrowDown.tsx":()=>Promise.resolve().then(()=>e(require("./index39.js"))),"../icons/ArrowLeft.tsx":()=>Promise.resolve().then(()=>e(require("./index40.js"))),"../icons/ArrowRight.tsx":()=>Promise.resolve().then(()=>e(require("./index41.js"))),"../icons/Check.tsx":()=>Promise.resolve().then(()=>e(require("./index42.js"))),"../icons/ChevronLeft.tsx":()=>Promise.resolve().then(()=>e(require("./index43.js"))),"../icons/ChevronRight.tsx":()=>Promise.resolve().then(()=>e(require("./index44.js"))),"../icons/CloseBtn.tsx":()=>Promise.resolve().then(()=>e(require("./index45.js"))),"../icons/Facebook.tsx":()=>Promise.resolve().then(()=>e(require("./index46.js"))),"../icons/FacebookColored.tsx":()=>Promise.resolve().then(()=>e(require("./index47.js"))),"../icons/FacebookRounded.tsx":()=>Promise.resolve().then(()=>e(require("./index48.js"))),"../icons/Globe.tsx":()=>Promise.resolve().then(()=>e(require("./index49.js"))),"../icons/IconFallback.tsx":()=>Promise.resolve().then(()=>e(require("./index105.js"))),"../icons/Instagram.tsx":()=>Promise.resolve().then(()=>e(require("./index50.js"))),"../icons/InstagramColored.tsx":()=>Promise.resolve().then(()=>e(require("./index51.js"))),"../icons/Link.tsx":()=>Promise.resolve().then(()=>e(require("./index52.js"))),"../icons/LinkedIn.tsx":()=>Promise.resolve().then(()=>e(require("./index53.js"))),"../icons/Mail.tsx":()=>Promise.resolve().then(()=>e(require("./index54.js"))),"../icons/Plus.tsx":()=>Promise.resolve().then(()=>e(require("./index55.js"))),"../icons/Search.tsx":()=>Promise.resolve().then(()=>e(require("./index106.js"))),"../icons/Share.tsx":()=>Promise.resolve().then(()=>e(require("./index56.js"))),"../icons/Twitter.tsx":()=>Promise.resolve().then(()=>e(require("./index57.js"))),"../icons/TwitterColored.tsx":()=>Promise.resolve().then(()=>e(require("./index58.js"))),"../icons/Upload.tsx":()=>Promise.resolve().then(()=>e(require("./index59.js"))),"../icons/X.tsx":()=>Promise.resolve().then(()=>e(require("./index60.js"))),"../icons/YouTube.tsx":()=>Promise.resolve().then(()=>e(require("./index61.js"))),"../icons/YouTubeColored.tsx":()=>Promise.resolve().then(()=>e(require("./index62.js")))}),`../icons/${s||"ArrowRight"}.tsx`,3)),[s]);return o.jsx(t.Suspense,{fallback:o.jsx(x,{className:"overflow-visible pointer-events-none"}),children:o.jsx(n,{...i,className:"overflow-visible pointer-events-none",...r})})},P=r=>{const{icon:s,as:i="span",tokens:n,customTheme:m,themeName:h="icon",children:c,...l}=r,u=v(h,n,m);return typeof s!="string"?o.jsxs(i,{...l,className:u,children:[c,s]}):o.jsxs(i,{className:u,children:[c,o.jsx(q,{icon:s,...l})]})};module.exports=P;
package/index14.mjs CHANGED
@@ -1,11 +1,11 @@
1
1
  "use client";
2
- import l from "./index106.mjs";
2
+ import l from "./index107.mjs";
3
3
  import { jsxs as m, jsx as i } from "react/jsx-runtime";
4
4
  import { useMemo as x, lazy as h, Suspense as u } from "react";
5
5
  import d from "./index64.mjs";
6
- import b from "./index104.mjs";
6
+ import b from "./index105.mjs";
7
7
  const f = (t) => {
8
- const { icon: o, ...s } = t, r = x(() => h(() => l(/* @__PURE__ */ Object.assign({ "../icons/ArrowDown.tsx": () => import("./index39.mjs"), "../icons/ArrowLeft.tsx": () => import("./index40.mjs"), "../icons/ArrowRight.tsx": () => import("./index41.mjs"), "../icons/Check.tsx": () => import("./index42.mjs"), "../icons/ChevronLeft.tsx": () => import("./index43.mjs"), "../icons/ChevronRight.tsx": () => import("./index44.mjs"), "../icons/CloseBtn.tsx": () => import("./index45.mjs"), "../icons/Facebook.tsx": () => import("./index46.mjs"), "../icons/FacebookColored.tsx": () => import("./index47.mjs"), "../icons/FacebookRounded.tsx": () => import("./index48.mjs"), "../icons/Globe.tsx": () => import("./index49.mjs"), "../icons/IconFallback.tsx": () => import("./index104.mjs"), "../icons/Instagram.tsx": () => import("./index50.mjs"), "../icons/InstagramColored.tsx": () => import("./index51.mjs"), "../icons/Link.tsx": () => import("./index52.mjs"), "../icons/LinkedIn.tsx": () => import("./index53.mjs"), "../icons/Mail.tsx": () => import("./index54.mjs"), "../icons/Plus.tsx": () => import("./index55.mjs"), "../icons/Search.tsx": () => import("./index105.mjs"), "../icons/Share.tsx": () => import("./index56.mjs"), "../icons/Twitter.tsx": () => import("./index57.mjs"), "../icons/TwitterColored.tsx": () => import("./index58.mjs"), "../icons/Upload.tsx": () => import("./index59.mjs"), "../icons/X.tsx": () => import("./index60.mjs"), "../icons/YouTube.tsx": () => import("./index61.mjs"), "../icons/YouTubeColored.tsx": () => import("./index62.mjs") }), `../icons/${o || "ArrowRight"}.tsx`, 3)), [o]);
8
+ const { icon: o, ...s } = t, r = x(() => h(() => l(/* @__PURE__ */ Object.assign({ "../icons/ArrowDown.tsx": () => import("./index39.mjs"), "../icons/ArrowLeft.tsx": () => import("./index40.mjs"), "../icons/ArrowRight.tsx": () => import("./index41.mjs"), "../icons/Check.tsx": () => import("./index42.mjs"), "../icons/ChevronLeft.tsx": () => import("./index43.mjs"), "../icons/ChevronRight.tsx": () => import("./index44.mjs"), "../icons/CloseBtn.tsx": () => import("./index45.mjs"), "../icons/Facebook.tsx": () => import("./index46.mjs"), "../icons/FacebookColored.tsx": () => import("./index47.mjs"), "../icons/FacebookRounded.tsx": () => import("./index48.mjs"), "../icons/Globe.tsx": () => import("./index49.mjs"), "../icons/IconFallback.tsx": () => import("./index105.mjs"), "../icons/Instagram.tsx": () => import("./index50.mjs"), "../icons/InstagramColored.tsx": () => import("./index51.mjs"), "../icons/Link.tsx": () => import("./index52.mjs"), "../icons/LinkedIn.tsx": () => import("./index53.mjs"), "../icons/Mail.tsx": () => import("./index54.mjs"), "../icons/Plus.tsx": () => import("./index55.mjs"), "../icons/Search.tsx": () => import("./index106.mjs"), "../icons/Share.tsx": () => import("./index56.mjs"), "../icons/Twitter.tsx": () => import("./index57.mjs"), "../icons/TwitterColored.tsx": () => import("./index58.mjs"), "../icons/Upload.tsx": () => import("./index59.mjs"), "../icons/X.tsx": () => import("./index60.mjs"), "../icons/YouTube.tsx": () => import("./index61.mjs"), "../icons/YouTubeColored.tsx": () => import("./index62.mjs") }), `../icons/${o || "ArrowRight"}.tsx`, 3)), [o]);
9
9
  return /* @__PURE__ */ i(u, { fallback: /* @__PURE__ */ i(b, { className: "overflow-visible pointer-events-none" }), children: /* @__PURE__ */ i(r, { ...s, className: "overflow-visible pointer-events-none", ...t }) });
10
10
  }, g = (t) => {
11
11
  const { icon: o, as: s = "span", tokens: r, customTheme: p, themeName: a = "icon", children: n, ...e } = t, c = d(a, r, p);
package/index140.js CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});function $(n,e){let r=n.copy(),a="hour"in r?Y(r,e):0;f(r,e.years||0),r.calendar.balanceYearMonth&&r.calendar.balanceYearMonth(r,n),r.month+=e.months||0,s(r),M(r),r.day+=(e.weeks||0)*7,r.day+=e.days||0,r.day+=a,b(r),r.calendar.balanceDate&&r.calendar.balanceDate(r),r.year<1&&(r.year=1,r.month=1,r.day=1);let c=r.calendar.getYearsInEra(r);if(r.year>c){var d,h;let o=(d=(h=r.calendar).isInverseEra)===null||d===void 0?void 0:d.call(h,r);r.year=c,r.month=o?1:r.calendar.getMonthsInYear(r),r.day=o?1:r.calendar.getDaysInMonth(r)}r.month<1&&(r.month=1,r.day=1);let l=r.calendar.getMonthsInYear(r);return r.month>l&&(r.month=l,r.day=r.calendar.getDaysInMonth(r)),r.day=Math.max(1,Math.min(r.calendar.getDaysInMonth(r),r.day)),r}function f(n,e){var r,a;!((r=(a=n.calendar).isInverseEra)===null||r===void 0)&&r.call(a,n)&&(e=-e),n.year+=e}function s(n){for(;n.month<1;)f(n,-1),n.month+=n.calendar.getMonthsInYear(n);let e=0;for(;n.month>(e=n.calendar.getMonthsInYear(n));)n.month-=e,f(n,1)}function b(n){for(;n.day<1;)n.month--,s(n),n.day+=n.calendar.getDaysInMonth(n);for(;n.day>n.calendar.getDaysInMonth(n);)n.day-=n.calendar.getDaysInMonth(n),n.month++,s(n)}function M(n){n.month=Math.max(1,Math.min(n.calendar.getMonthsInYear(n),n.month)),n.day=Math.max(1,Math.min(n.calendar.getDaysInMonth(n),n.day))}function y(n){n.calendar.constrainDate&&n.calendar.constrainDate(n),n.year=Math.max(1,Math.min(n.calendar.getYearsInEra(n),n.year)),M(n)}function u(n){let e={};for(let r in n)typeof n[r]=="number"&&(e[r]=-n[r]);return e}function g(n,e){return $(n,u(e))}function I(n,e){let r=n.copy();return e.era!=null&&(r.era=e.era),e.year!=null&&(r.year=e.year),e.month!=null&&(r.month=e.month),e.day!=null&&(r.day=e.day),y(r),r}function x(n,e){let r=n.copy();return e.hour!=null&&(r.hour=e.hour),e.minute!=null&&(r.minute=e.minute),e.second!=null&&(r.second=e.second),e.millisecond!=null&&(r.millisecond=e.millisecond),m(r),r}function D(n){n.second+=Math.floor(n.millisecond/1e3),n.millisecond=i(n.millisecond,1e3),n.minute+=Math.floor(n.second/60),n.second=i(n.second,60),n.hour+=Math.floor(n.minute/60),n.minute=i(n.minute,60);let e=Math.floor(n.hour/24);return n.hour=i(n.hour,24),e}function m(n){n.millisecond=Math.max(0,Math.min(n.millisecond,1e3)),n.second=Math.max(0,Math.min(n.second,59)),n.minute=Math.max(0,Math.min(n.minute,59)),n.hour=Math.max(0,Math.min(n.hour,23))}function i(n,e){let r=n%e;return r<0&&(r+=e),r}function Y(n,e){return n.hour+=e.hours||0,n.minute+=e.minutes||0,n.second+=e.seconds||0,n.millisecond+=e.milliseconds||0,D(n)}function w(n,e,r,a){let c=n.copy();switch(e){case"era":{let l=n.calendar.getEras(),o=l.indexOf(n.era);if(o<0)throw new Error("Invalid era: "+n.era);o=t(o,r,0,l.length-1,a==null?void 0:a.round),c.era=l[o],y(c);break}case"year":var d,h;!((d=(h=c.calendar).isInverseEra)===null||d===void 0)&&d.call(h,c)&&(r=-r),c.year=t(n.year,r,-1/0,9999,a==null?void 0:a.round),c.year===-1/0&&(c.year=1),c.calendar.balanceYearMonth&&c.calendar.balanceYearMonth(c,n);break;case"month":c.month=t(n.month,r,1,n.calendar.getMonthsInYear(n),a==null?void 0:a.round);break;case"day":c.day=t(n.day,r,1,n.calendar.getDaysInMonth(n),a==null?void 0:a.round);break;default:throw new Error("Unsupported field "+e)}return n.calendar.balanceDate&&n.calendar.balanceDate(c),y(c),c}function k(n,e,r,a){let c=n.copy();switch(e){case"hour":{let d=n.hour,h=0,l=23;if((a==null?void 0:a.hourCycle)===12){let o=d>=12;h=o?12:0,l=o?23:11}c.hour=t(d,r,h,l,a==null?void 0:a.round);break}case"minute":c.minute=t(n.minute,r,0,59,a==null?void 0:a.round);break;case"second":c.second=t(n.second,r,0,59,a==null?void 0:a.round);break;case"millisecond":c.millisecond=t(n.millisecond,r,0,999,a==null?void 0:a.round);break;default:throw new Error("Unsupported field "+e)}return c}function t(n,e,r,a,c=!1){if(c){n+=Math.sign(e),n<r&&(n=a);let d=Math.abs(e);e>0?n=Math.ceil(n/d)*d:n=Math.floor(n/d)*d,n>a&&(n=r)}else n+=e,n<r?n=a-(r-n-1):n>a&&(n=r+(n-a-1));return n}exports.add=$;exports.constrain=y;exports.constrainTime=m;exports.cycleDate=w;exports.cycleTime=k;exports.invertDuration=u;exports.set=I;exports.setTime=x;exports.subtract=g;
1
+ "use strict";const A=require("./index182.js"),n=require("./index183.js"),I=require("./index184.js"),j=require("./index185.js");function B(x){let{swiper:s,extendParams:q,on:f,emit:g}=x;const y=A.g();let b=!1,w=null,h=null,v,i,p,D;q({scrollbar:{el:null,dragSize:"auto",hide:!1,draggable:!1,snapOnRelease:!0,lockClass:"swiper-scrollbar-lock",dragClass:"swiper-scrollbar-drag",scrollbarDisabledClass:"swiper-scrollbar-disabled",horizontalClass:"swiper-scrollbar-horizontal",verticalClass:"swiper-scrollbar-vertical"}}),s.scrollbar={el:null,dragEl:null};function u(){if(!s.params.scrollbar.el||!s.scrollbar.el)return;const{scrollbar:l,rtlTranslate:a}=s,{dragEl:r,el:e}=l,t=s.params.scrollbar,c=s.params.loop?s.progressLoop:s.progress;let d=i,o=(p-i)*c;a?(o=-o,o>0?(d=i-o,o=0):-o+i>p&&(d=p+o)):o<0?(d=i+o,o=0):o+i>p&&(d=p-o),s.isHorizontal()?(r.style.transform=`translate3d(${o}px, 0, 0)`,r.style.width=`${d}px`):(r.style.transform=`translate3d(0px, ${o}px, 0)`,r.style.height=`${d}px`),t.hide&&(clearTimeout(w),e.style.opacity=1,w=setTimeout(()=>{e.style.opacity=0,e.style.transitionDuration="400ms"},1e3))}function H(l){!s.params.scrollbar.el||!s.scrollbar.el||(s.scrollbar.dragEl.style.transitionDuration=`${l}ms`)}function m(){if(!s.params.scrollbar.el||!s.scrollbar.el)return;const{scrollbar:l}=s,{dragEl:a,el:r}=l;a.style.width="",a.style.height="",p=s.isHorizontal()?r.offsetWidth:r.offsetHeight,D=s.size/(s.virtualSize+s.params.slidesOffsetBefore-(s.params.centeredSlides?s.snapGrid[0]:0)),s.params.scrollbar.dragSize==="auto"?i=p*D:i=parseInt(s.params.scrollbar.dragSize,10),s.isHorizontal()?a.style.width=`${i}px`:a.style.height=`${i}px`,D>=1?r.style.display="none":r.style.display="",s.params.scrollbar.hide&&(r.style.opacity=0),s.params.watchOverflow&&s.enabled&&l.el.classList[s.isLocked?"add":"remove"](s.params.scrollbar.lockClass)}function E(l){return s.isHorizontal()?l.clientX:l.clientY}function S(l){const{scrollbar:a,rtlTranslate:r}=s,{el:e}=a;let t;t=(E(l)-n.b(e)[s.isHorizontal()?"left":"top"]-(v!==null?v:i/2))/(p-i),t=Math.max(Math.min(t,1),0),r&&(t=1-t);const c=s.minTranslate()+(s.maxTranslate()-s.minTranslate())*t;s.updateProgress(c),s.setTranslate(c),s.updateActiveIndex(),s.updateSlidesClasses()}function k(l){const a=s.params.scrollbar,{scrollbar:r,wrapperEl:e}=s,{el:t,dragEl:c}=r;b=!0,v=l.target===c?E(l)-l.target.getBoundingClientRect()[s.isHorizontal()?"left":"top"]:null,l.preventDefault(),l.stopPropagation(),e.style.transitionDuration="100ms",c.style.transitionDuration="100ms",S(l),clearTimeout(h),t.style.transitionDuration="0ms",a.hide&&(t.style.opacity=1),s.params.cssMode&&(s.wrapperEl.style["scroll-snap-type"]="none"),g("scrollbarDragStart",l)}function P(l){const{scrollbar:a,wrapperEl:r}=s,{el:e,dragEl:t}=a;b&&(l.preventDefault?l.preventDefault():l.returnValue=!1,S(l),r.style.transitionDuration="0ms",e.style.transitionDuration="0ms",t.style.transitionDuration="0ms",g("scrollbarDragMove",l))}function M(l){const a=s.params.scrollbar,{scrollbar:r,wrapperEl:e}=s,{el:t}=r;b&&(b=!1,s.params.cssMode&&(s.wrapperEl.style["scroll-snap-type"]="",e.style.transitionDuration=""),a.hide&&(clearTimeout(h),h=n.n(()=>{t.style.opacity=0,t.style.transitionDuration="400ms"},1e3)),g("scrollbarDragEnd",l),a.snapOnRelease&&s.slideToClosest())}function L(l){const{scrollbar:a,params:r}=s,e=a.el;if(!e)return;const t=e,c=r.passiveListeners?{passive:!1,capture:!1}:!1,d=r.passiveListeners?{passive:!0,capture:!1}:!1;if(!t)return;const o=l==="on"?"addEventListener":"removeEventListener";t[o]("pointerdown",k,c),y[o]("pointermove",P,c),y[o]("pointerup",M,d)}function $(){!s.params.scrollbar.el||!s.scrollbar.el||L("on")}function O(){!s.params.scrollbar.el||!s.scrollbar.el||L("off")}function z(){const{scrollbar:l,el:a}=s;s.params.scrollbar=I.c(s,s.originalParams.scrollbar,s.params.scrollbar,{el:"swiper-scrollbar"});const r=s.params.scrollbar;if(!r.el)return;let e;if(typeof r.el=="string"&&s.isElement&&(e=s.el.querySelector(r.el)),!e&&typeof r.el=="string"){if(e=y.querySelectorAll(r.el),!e.length)return}else e||(e=r.el);s.params.uniqueNavElements&&typeof r.el=="string"&&e.length>1&&a.querySelectorAll(r.el).length===1&&(e=a.querySelector(r.el)),e.length>0&&(e=e[0]),e.classList.add(s.isHorizontal()?r.horizontalClass:r.verticalClass);let t;e&&(t=e.querySelector(j.c(s.params.scrollbar.dragClass)),t||(t=n.c("div",s.params.scrollbar.dragClass),e.append(t))),Object.assign(l,{el:e,dragEl:t}),r.draggable&&$(),e&&e.classList[s.enabled?"remove":"add"](...n.h(s.params.scrollbar.lockClass))}function C(){const l=s.params.scrollbar,a=s.scrollbar.el;a&&a.classList.remove(...n.h(s.isHorizontal()?l.horizontalClass:l.verticalClass)),O()}f("changeDirection",()=>{if(!s.scrollbar||!s.scrollbar.el)return;const l=s.params.scrollbar;let{el:a}=s.scrollbar;a=n.m(a),a.forEach(r=>{r.classList.remove(l.horizontalClass,l.verticalClass),r.classList.add(s.isHorizontal()?l.horizontalClass:l.verticalClass)})}),f("init",()=>{s.params.scrollbar.enabled===!1?T():(z(),m(),u())}),f("update resize observerUpdate lock unlock changeDirection",()=>{m()}),f("setTranslate",()=>{u()}),f("setTransition",(l,a)=>{H(a)}),f("enable disable",()=>{const{el:l}=s.scrollbar;l&&l.classList[s.enabled?"remove":"add"](...n.h(s.params.scrollbar.lockClass))}),f("destroy",()=>{C()});const R=()=>{s.el.classList.remove(...n.h(s.params.scrollbar.scrollbarDisabledClass)),s.scrollbar.el&&s.scrollbar.el.classList.remove(...n.h(s.params.scrollbar.scrollbarDisabledClass)),z(),m(),u()},T=()=>{s.el.classList.add(...n.h(s.params.scrollbar.scrollbarDisabledClass)),s.scrollbar.el&&s.scrollbar.el.classList.add(...n.h(s.params.scrollbar.scrollbarDisabledClass)),C()};Object.assign(s.scrollbar,{enable:R,disable:T,updateSize:m,setTranslate:u,init:z,destroy:C})}module.exports=B;