meticulous-ui 3.7.12 → 3.7.13

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 (310) hide show
  1. package/components/Button/Button.js +46 -67
  2. package/components/Carousel/Carousel.js +127 -72
  3. package/components/DatePicker/DatePicker.js +181 -142
  4. package/components/DatePicker/constants.js +14 -1
  5. package/components/DatePicker/utils.js +1 -5
  6. package/components/Dropdown/Dropdown.js +114 -80
  7. package/components/Glass/Glass.js +2 -8
  8. package/components/Icons/Add.js +44 -11
  9. package/components/Icons/AddCircle.js +29 -8
  10. package/components/Icons/AddCircleFilled.js +20 -5
  11. package/components/Icons/ArrowDown.js +20 -5
  12. package/components/Icons/ArrowLeft.js +21 -5
  13. package/components/Icons/ArrowRight.js +21 -5
  14. package/components/Icons/ArrowUp.js +20 -5
  15. package/components/Icons/BagFilled.js +20 -5
  16. package/components/Icons/BagOutline.js +30 -8
  17. package/components/Icons/BellFilled.js +31 -8
  18. package/components/Icons/BellOffFilled.js +40 -9
  19. package/components/Icons/BellOffOutline.js +42 -9
  20. package/components/Icons/BellOutline.js +33 -8
  21. package/components/Icons/BookmarkFilled.js +23 -10
  22. package/components/Icons/BookmarkOutline.js +20 -5
  23. package/components/Icons/BoxCoveredFilled.js +41 -10
  24. package/components/Icons/BoxCoveredOutline.js +31 -8
  25. package/components/Icons/BoxFilled.js +34 -9
  26. package/components/Icons/BoxOutline.js +31 -8
  27. package/components/Icons/CalendarDays.js +20 -5
  28. package/components/Icons/CalendarLinesPen.js +21 -5
  29. package/components/Icons/CartCheckFilled.js +36 -9
  30. package/components/Icons/CartCheckOutline.js +46 -10
  31. package/components/Icons/CartCrossFilled.js +36 -9
  32. package/components/Icons/CartCrossOutline.js +45 -10
  33. package/components/Icons/CartFilled.js +34 -9
  34. package/components/Icons/CartMinusFilled.js +36 -9
  35. package/components/Icons/CartMinusOutline.js +47 -11
  36. package/components/Icons/CartOutline.js +46 -10
  37. package/components/Icons/CartPlusFilled.js +36 -9
  38. package/components/Icons/CartPlusOutline.js +45 -10
  39. package/components/Icons/Check.js +21 -5
  40. package/components/Icons/CheckDouble.js +21 -5
  41. package/components/Icons/ChevronDown.js +21 -5
  42. package/components/Icons/ChevronLeft.js +21 -5
  43. package/components/Icons/ChevronRight.js +21 -5
  44. package/components/Icons/ChevronUp.js +21 -5
  45. package/components/Icons/ClockCircleOutline.js +24 -8
  46. package/components/Icons/ClockSquareOutline.js +31 -8
  47. package/components/Icons/Close.js +18 -5
  48. package/components/Icons/CloseCircleFilled.js +20 -5
  49. package/components/Icons/CloseCircleOutline.js +21 -5
  50. package/components/Icons/CommentBubbleFilled.js +23 -10
  51. package/components/Icons/CommentBubbleOutline.js +23 -10
  52. package/components/Icons/CommentFilled.js +23 -10
  53. package/components/Icons/CommentLineFilled.js +23 -10
  54. package/components/Icons/CommentLineOutline.js +23 -10
  55. package/components/Icons/CommentOutline.js +23 -10
  56. package/components/Icons/ContactDetailsFilled.js +15 -8
  57. package/components/Icons/ContactDetailsOutline.js +15 -8
  58. package/components/Icons/DeliveryTruckFastFilled.js +26 -13
  59. package/components/Icons/DeliveryTruckFastOutline.js +26 -13
  60. package/components/Icons/DeliveryTruckLeftFilled.js +22 -9
  61. package/components/Icons/DeliveryTruckLeftOutline.js +22 -9
  62. package/components/Icons/DeliveryTruckRightFilled.js +21 -8
  63. package/components/Icons/DeliveryTruckRightOutline.js +21 -8
  64. package/components/Icons/DetailsOutline.js +15 -8
  65. package/components/Icons/DiscordConversation.js +27 -8
  66. package/components/Icons/DiscordFilled.js +21 -8
  67. package/components/Icons/DiscordOutline.js +25 -9
  68. package/components/Icons/DoorClosedFilled.js +20 -5
  69. package/components/Icons/DoorClosedOutline.js +21 -5
  70. package/components/Icons/DoorOpenFilled.js +20 -5
  71. package/components/Icons/DoorOpenOutline.js +21 -5
  72. package/components/Icons/DotsHorizontalFilled.js +34 -9
  73. package/components/Icons/DotsHorizontalOutline.js +43 -9
  74. package/components/Icons/DotsVerticalFilled.js +34 -9
  75. package/components/Icons/DotsVerticalOutline.js +43 -9
  76. package/components/Icons/Download.js +27 -8
  77. package/components/Icons/DownloadBoxFilled.js +20 -5
  78. package/components/Icons/DownloadBoxOutline.js +36 -9
  79. package/components/Icons/EditBoxThick.js +21 -5
  80. package/components/Icons/EditBoxThin.js +33 -8
  81. package/components/Icons/EmailFilled.js +19 -6
  82. package/components/Icons/EmailOutline.js +19 -6
  83. package/components/Icons/ExitArrowInOutline.js +21 -5
  84. package/components/Icons/ExitArrowOutOutline.js +33 -8
  85. package/components/Icons/ExitFullScreen.js +19 -5
  86. package/components/Icons/ExitFullScreenThick.js +19 -5
  87. package/components/Icons/EyeClosed.js +20 -5
  88. package/components/Icons/EyeFilled.js +29 -8
  89. package/components/Icons/EyeOutline.js +33 -8
  90. package/components/Icons/FacebookFilled.js +19 -6
  91. package/components/Icons/FacebookMessengerOutline.js +29 -8
  92. package/components/Icons/FacebookOutline.js +20 -5
  93. package/components/Icons/FacebookRoundFilled.js +18 -5
  94. package/components/Icons/Filter.js +17 -10
  95. package/components/Icons/FilterList.js +21 -5
  96. package/components/Icons/FilterThickFilled.js +18 -5
  97. package/components/Icons/FilterThickOutline.js +19 -5
  98. package/components/Icons/FullScreenArrowThick.js +19 -5
  99. package/components/Icons/FullScreenArrowThin.js +19 -5
  100. package/components/Icons/FullScreenExit.js +41 -10
  101. package/components/Icons/FullScreenFilled.js +20 -5
  102. package/components/Icons/FullScreenOutline.js +20 -5
  103. package/components/Icons/HamburgerMenu.js +40 -9
  104. package/components/Icons/HamburgerSpaced.js +23 -10
  105. package/components/Icons/HeartFilled.js +18 -5
  106. package/components/Icons/HeartOutline.js +23 -5
  107. package/components/Icons/Help.js +21 -5
  108. package/components/Icons/HelpCircleFilled.js +20 -5
  109. package/components/Icons/HelpCircleOutline.js +41 -9
  110. package/components/Icons/HomeFilled.js +20 -5
  111. package/components/Icons/HomeOutline.js +20 -5
  112. package/components/Icons/Info.js +27 -8
  113. package/components/Icons/InfoCircleFilled.js +20 -5
  114. package/components/Icons/InfoCircleOutline.js +16 -9
  115. package/components/Icons/InfoSquareFilled.js +20 -5
  116. package/components/Icons/InfoSquareOutline.js +23 -9
  117. package/components/Icons/InstagramOuline.js +21 -8
  118. package/components/Icons/InstagramRoundFilled.js +44 -13
  119. package/components/Icons/KeyFilled.js +20 -5
  120. package/components/Icons/KeyInSquareFilled.js +29 -8
  121. package/components/Icons/KeyInSquareOutline.js +38 -9
  122. package/components/Icons/KeyOutline.js +31 -8
  123. package/components/Icons/KeySideSquareFilled.js +29 -8
  124. package/components/Icons/KeySideSquareOutline.js +20 -5
  125. package/components/Icons/KeySquareFilled.js +29 -8
  126. package/components/Icons/KeySquareOutline.js +20 -5
  127. package/components/Icons/Link.js +31 -8
  128. package/components/Icons/LinkedinFilled.js +19 -6
  129. package/components/Icons/LinkedinOutline.js +19 -5
  130. package/components/Icons/LinkedinRoundFilled.js +19 -6
  131. package/components/Icons/Loading.js +21 -8
  132. package/components/Icons/LocationArrowFilled.js +12 -5
  133. package/components/Icons/LocationArrowOutline.js +21 -5
  134. package/components/Icons/LocationFilled.js +23 -10
  135. package/components/Icons/LocationOutline.js +23 -10
  136. package/components/Icons/LockKeyhole.js +20 -5
  137. package/components/Icons/LockKeyholeOutline.js +31 -9
  138. package/components/Icons/LockKeyholeUnlocked.js +20 -5
  139. package/components/Icons/LockKeyholeUnlockedOutline.js +31 -9
  140. package/components/Icons/MediaPauseCircleFilled.js +20 -5
  141. package/components/Icons/MediaPauseCircleOuline.js +36 -9
  142. package/components/Icons/MediaPauseFilled.js +27 -8
  143. package/components/Icons/MediaPauseOutline.js +31 -8
  144. package/components/Icons/MediaPlayCircleFilled.js +20 -5
  145. package/components/Icons/MediaPlayCircleOutline.js +31 -8
  146. package/components/Icons/MediaPlayFilled.js +18 -5
  147. package/components/Icons/MediaPlayOutline.js +20 -5
  148. package/components/Icons/MediaStopCircleFilled.js +20 -5
  149. package/components/Icons/MediaStopCircleOutline.js +31 -8
  150. package/components/Icons/MediaStopFilled.js +18 -5
  151. package/components/Icons/MediaStopOutline.js +20 -5
  152. package/components/Icons/Minus.js +21 -5
  153. package/components/Icons/MinusCircle.js +23 -10
  154. package/components/Icons/MinusCircleFilled.js +23 -10
  155. package/components/Icons/MoneyBagOutline.js +46 -10
  156. package/components/Icons/MoneyBriefcaseFilled.js +20 -5
  157. package/components/Icons/MoneyBriefcaseOutline.js +38 -9
  158. package/components/Icons/NoEntry.js +19 -5
  159. package/components/Icons/NoEntryFilled.js +18 -5
  160. package/components/Icons/NoEntryOutline.js +21 -8
  161. package/components/Icons/PaymentCardFilled.js +16 -9
  162. package/components/Icons/PaymentCardOutline.js +16 -9
  163. package/components/Icons/PhoneCallingFilled.js +36 -9
  164. package/components/Icons/PhoneCallingOutline.js +38 -9
  165. package/components/Icons/PhoneFilled.js +18 -5
  166. package/components/Icons/PhoneOutline.js +18 -5
  167. package/components/Icons/Pin.js +21 -5
  168. package/components/Icons/PinAddFilled.js +17 -10
  169. package/components/Icons/PinAddOutline.js +17 -10
  170. package/components/Icons/PinCircleFilled.js +20 -5
  171. package/components/Icons/PinCircleOutline.js +21 -8
  172. package/components/Icons/PinFilled.js +18 -5
  173. package/components/Icons/PinOutline.js +20 -5
  174. package/components/Icons/PinSubFilled.js +17 -10
  175. package/components/Icons/PinSubOutline.js +17 -10
  176. package/components/Icons/PinterestFilled.js +17 -10
  177. package/components/Icons/PinterestOutline.js +21 -5
  178. package/components/Icons/ProfileFemaleOutline.js +19 -6
  179. package/components/Icons/ProfileGroupFilled.js +28 -8
  180. package/components/Icons/ProfileMaleFilled.js +28 -8
  181. package/components/Icons/ProfileMaleOutline.js +19 -6
  182. package/components/Icons/RedditFilled.js +17 -10
  183. package/components/Icons/RedditOutline.js +43 -10
  184. package/components/Icons/RedditRoundFilled.js +52 -15
  185. package/components/Icons/RedditRoundOutline.js +53 -16
  186. package/components/Icons/RupeeOutlined.js +18 -5
  187. package/components/Icons/RupeeSign.js +21 -5
  188. package/components/Icons/SaveFilled.js +23 -10
  189. package/components/Icons/SaveOutline.js +23 -10
  190. package/components/Icons/Search.js +23 -10
  191. package/components/Icons/SettingFilled.js +18 -5
  192. package/components/Icons/SettingOutline.js +18 -5
  193. package/components/Icons/ShareAllFilled.js +20 -5
  194. package/components/Icons/ShareAllOutline.js +39 -11
  195. package/components/Icons/ShareBoxOutline.js +18 -5
  196. package/components/Icons/ShareFilled.js +29 -8
  197. package/components/Icons/ShareOutline.js +32 -8
  198. package/components/Icons/ShareThickFilled.js +18 -5
  199. package/components/Icons/ShieldCheckFilled.js +20 -5
  200. package/components/Icons/ShieldCheckOutline.js +31 -8
  201. package/components/Icons/ShieldCrossFilled.js +20 -5
  202. package/components/Icons/ShieldCrossOutline.js +30 -8
  203. package/components/Icons/ShieldFilled.js +18 -5
  204. package/components/Icons/ShieldOutline.js +20 -5
  205. package/components/Icons/ShieldWarningFilled.js +20 -5
  206. package/components/Icons/ShieldWarningOutline.js +23 -9
  207. package/components/Icons/SnapchatFilled.js +17 -10
  208. package/components/Icons/SnapchatOutline.js +20 -5
  209. package/components/Icons/SortBottomToTop.js +26 -10
  210. package/components/Icons/SortHorizontal.js +20 -5
  211. package/components/Icons/SortTopToBottom.js +26 -10
  212. package/components/Icons/SortVertical.js +20 -5
  213. package/components/Icons/StarFilled.js +19 -6
  214. package/components/Icons/StarOutline.js +19 -6
  215. package/components/Icons/TelegramFilled.js +22 -9
  216. package/components/Icons/TelegramOutline.js +20 -5
  217. package/components/Icons/TelegramRoundFilled.js +22 -9
  218. package/components/Icons/ThumbsDownFilled.js +18 -5
  219. package/components/Icons/ThumbsDownOutline.js +18 -5
  220. package/components/Icons/ThumbsUpFilled.js +18 -5
  221. package/components/Icons/ThumbsUpOutline.js +18 -5
  222. package/components/Icons/TiktokBox.js +18 -5
  223. package/components/Icons/TiktokThickFilled.js +21 -8
  224. package/components/Icons/TiktokThinFilled.js +32 -8
  225. package/components/Icons/TrashBigFilled.js +23 -10
  226. package/components/Icons/TrashBigOutline.js +23 -10
  227. package/components/Icons/TrashFilled.js +27 -8
  228. package/components/Icons/TrashLinesFilled.js +29 -8
  229. package/components/Icons/TrashLinesOutline.js +33 -11
  230. package/components/Icons/TrashOutline.js +31 -9
  231. package/components/Icons/Upload.js +27 -8
  232. package/components/Icons/UploadBoxFilled.js +20 -5
  233. package/components/Icons/UploadBoxOutline.js +36 -9
  234. package/components/Icons/VolumeFilled.js +30 -11
  235. package/components/Icons/VolumeMuteFilled.js +30 -11
  236. package/components/Icons/VolumeMuteOutline.js +30 -11
  237. package/components/Icons/VolumeOffFilled.js +30 -11
  238. package/components/Icons/VolumeOffOutline.js +30 -11
  239. package/components/Icons/VolumeOutline.js +30 -11
  240. package/components/Icons/WalletFilled.js +23 -10
  241. package/components/Icons/WalletOutline.js +23 -10
  242. package/components/Icons/Warning.js +21 -5
  243. package/components/Icons/WarningCircleFilled.js +18 -5
  244. package/components/Icons/WarningCircleOutline.js +18 -5
  245. package/components/Icons/WarningSmall.js +21 -5
  246. package/components/Icons/WarningTriangleFilled.js +21 -8
  247. package/components/Icons/WarningTriangleOutline.js +21 -5
  248. package/components/Icons/WhatsappFilled.js +17 -10
  249. package/components/Icons/WhatsappOutline.js +20 -5
  250. package/components/Icons/Youtube.js +18 -5
  251. package/components/Icons/YoutubeFilled.js +23 -10
  252. package/components/Icons/YoutubeRoundFilled.js +22 -9
  253. package/components/Image/Image.js +33 -27
  254. package/components/Input/Checkbox/Checkbox.js +30 -20
  255. package/components/Input/FileUploader/FileUploader.js +73 -82
  256. package/components/Input/Input/Input.js +49 -47
  257. package/components/Input/Radio/Radio.js +18 -17
  258. package/components/Input/RadioGroup/RadioGroup.js +33 -16
  259. package/components/Input/Textarea/SvgIcon.js +1 -7
  260. package/components/Input/Textarea/Textarea.js +54 -54
  261. package/components/Loader/Loader.js +18 -29
  262. package/components/Loader/constants.js +3 -12
  263. package/components/MenuItem/MenuItem.js +30 -28
  264. package/components/Modal/Modal.js +58 -37
  265. package/components/OtpInput/OtpInput.js +28 -28
  266. package/components/PageLoader/PageLoader.js +13 -9
  267. package/components/Pagination/Pagination.js +87 -95
  268. package/components/Ripple/Ripple.js +12 -2
  269. package/components/RootComponent/RootComponent.js +1 -4
  270. package/components/Selectbox/Selectbox.js +143 -101
  271. package/components/Shimmer/Shimmer.js +17 -13
  272. package/components/Spinner/Spinner.js +29 -22
  273. package/components/Timer/Timer.js +154 -92
  274. package/components/Timer/components/TimerRing/TimerRing.js +56 -11
  275. package/components/Toast/Toast.js +76 -81
  276. package/components/Typography/Headings/H1.js +2 -8
  277. package/components/Typography/Headings/H2.js +2 -8
  278. package/components/Typography/Headings/H3.js +2 -8
  279. package/components/Typography/Headings/H4.js +2 -8
  280. package/components/Typography/Headings/H5.js +2 -8
  281. package/components/Typography/Headings/H6.js +2 -8
  282. package/components/Typography/Headings/index.js +1 -8
  283. package/components/Typography/P/P.js +3 -12
  284. package/components/VideoPlayer/VideoPlayer.js +19 -23
  285. package/components/VideoPlayer/components/Volumebar/Volumebar.js +2 -6
  286. package/components/VideoPlayer/useSpacebarToggle.js +11 -1
  287. package/components/VideoPlayer/useVolumeOverlay.js +1 -4
  288. package/hooks/useThrottle.js +6 -3
  289. package/hooks/useWindowSize.js +1 -4
  290. package/package.json +1 -1
  291. package/reactUtils/composeProviders.js +1 -3
  292. package/reactUtils/lazyImport.js +1 -3
  293. package/reactUtils/withErrorBoundary.js +2 -8
  294. package/utils/cancelablePromise.js +4 -5
  295. package/utils/createPubSub.js +9 -12
  296. package/utils/formatCompactNumber.js +3 -4
  297. package/utils/formatCurrency.js +1 -4
  298. package/utils/formatDate.js +3 -5
  299. package/utils/handleKeyboardNavigation.js +1 -5
  300. package/utils/isAuthenticated.js +1 -3
  301. package/utils/logError.js +1 -4
  302. package/utils/logInfo.js +1 -6
  303. package/utils/logWarn.js +1 -6
  304. package/utils/mergeDeep.js +1 -3
  305. package/utils/multiSort.js +1 -4
  306. package/utils/scrollToElement.js +1 -4
  307. package/utils/scrollToTop.js +1 -4
  308. package/utils/timeAgo.js +1 -3
  309. package/utils/trackEvent.js +1 -5
  310. package/utils/withTimeout.js +3 -1
@@ -10,46 +10,27 @@ import { MEDIUM as P, SIZE as S } from "./constants.js";
10
10
  import t from "prop-types";
11
11
  import l, { css as a } from "styled-components";
12
12
  const K = l.button`
13
- height: ${({
14
- $height: o
15
- }) => o}rem;
16
- width: ${({
17
- $width: o
18
- }) => o}rem;
13
+ height: ${({ $height: o }) => o}rem;
14
+ width: ${({ $width: o }) => o}rem;
19
15
  border-radius: 0.96rem;
20
16
  border: none;
21
17
  padding: 0.96rem 0.64rem;
22
18
  position: relative;
23
19
  overflow: hidden;
24
- background-color: ${({
25
- $selectedColor: o,
26
- disabled: e
27
- }) => e ? y.m500 : o};
28
- cursor: ${({
29
- disabled: o,
30
- $isLoading: e
31
- }) => o ? "not-allowed" : e ? "auto" : "pointer"};
20
+ background-color: ${({ $selectedColor: o, disabled: e }) => e ? y.m500 : o};
21
+ cursor: ${({ disabled: o, $isLoading: e }) => o ? "not-allowed" : e ? "auto" : "pointer"};
32
22
 
33
- ${({
34
- $isLoading: o
35
- }) => o && a`
23
+ ${({ $isLoading: o }) => o && a`
36
24
  pointer-events: none;
37
25
  `};
38
26
 
39
- ${({
40
- disabled: o,
41
- $isLoading: e
42
- }) => !(o || e) && a`
27
+ ${({ disabled: o, $isLoading: e }) => !(o || e) && a`
43
28
  &:hover {
44
- background-color: ${({
45
- $hoverColor: r
46
- }) => r};
29
+ background-color: ${({ $hoverColor: r }) => r};
47
30
  }
48
31
 
49
32
  &:active {
50
- background-color: ${({
51
- $activeColor: r
52
- }) => r};
33
+ background-color: ${({ $activeColor: r }) => r};
53
34
  }
54
35
  `};
55
36
 
@@ -57,34 +38,21 @@ const K = l.button`
57
38
  outline: none;
58
39
  }
59
40
  `, M = l.div`
60
- font-size: ${({
61
- $font: o
62
- }) => o}rem;
41
+ font-size: ${({ $font: o }) => o}rem;
63
42
  font-weight: 500;
64
43
  max-width: 100%;
65
44
  overflow: hidden;
66
- color: ${({
67
- $textColor: o
68
- }) => o};
69
- opacity: ${({
70
- $isLoading: o
71
- }) => o ? 0 : 1};
45
+ color: ${({ $textColor: o }) => o};
46
+ opacity: ${({ $isLoading: o }) => o ? 0 : 1};
72
47
  transition: opacity 0.3s ease;
73
48
  `, W = l.div`
74
- height: ${({
75
- $height: o
76
- }) => o}rem;
77
- width: ${({
78
- $width: o
79
- }) => o}rem;
49
+ height: ${({ $height: o }) => o}rem;
50
+ width: ${({ $width: o }) => o}rem;
80
51
  display: inline-block;
81
52
  position: relative;
82
53
  border-radius: 0.96rem;
83
54
 
84
- ${({
85
- disabled: o,
86
- $isLoading: e
87
- }) => !(o || e) && a`
55
+ ${({ disabled: o, $isLoading: e }) => !(o || e) && a`
88
56
  box-shadow: 0 0.4rem 1.5rem rgba(0, 0, 0, 0.2);
89
57
  transition:
90
58
  transform 0.2s,
@@ -102,15 +70,10 @@ const K = l.button`
102
70
  display: flex;
103
71
  align-items: center;
104
72
  justify-content: center;
105
- opacity: ${({
106
- $isLoading: o
107
- }) => o ? 1 : 0};
73
+ opacity: ${({ $isLoading: o }) => o ? 1 : 0};
108
74
  transition: opacity 0.3s ease;
109
75
  pointer-events: none;
110
- `, U = ({
111
- theme: o,
112
- children: e
113
- }) => /* @__PURE__ */ i(B, { rippleColor: o.m100, children: e }), Y = (o) => {
76
+ `, U = ({ theme: o, children: e }) => /* @__PURE__ */ i(B, { rippleColor: o.m100, children: e }), Y = (o) => {
114
77
  var b;
115
78
  const {
116
79
  children: e,
@@ -133,19 +96,35 @@ const K = l.button`
133
96
  p.current = g;
134
97
  }
135
98
  d == null || d(s);
136
- }, {
137
- m400: k,
138
- m500: I,
139
- m600: L
140
- } = (b = j[r]) != null ? b : w, {
141
- height: h,
142
- width: f,
143
- font: T
144
- } = S[v] || {}, $ = ["white", "yellow"].includes(r) ? y.m600 : E, u = /* @__PURE__ */ z(K, { type: "button", ...C, onKeyDown: x, $hoverColor: I, $activeColor: L, $selectedColor: k, $height: h, $width: c || f, disabled: o.disabled, $isLoading: n, children: [
145
- /* @__PURE__ */ i(O, { $isLoading: n, children: /* @__PURE__ */ i(R, { size: "small", color: m || $ }) }),
146
- /* @__PURE__ */ i(M, { $isLoading: n, $textColor: m || $, $font: T, children: e })
147
- ] });
148
- return /* @__PURE__ */ i(W, { $height: h, $width: c || f, disabled: o.disabled, $isLoading: n, children: n ? u : /* @__PURE__ */ i(U, { theme: r, children: u }) });
99
+ }, { m400: k, m500: I, m600: L } = (b = j[r]) != null ? b : w, { height: h, width: f, font: T } = S[v] || {}, $ = ["white", "yellow"].includes(r) ? y.m600 : E, u = /* @__PURE__ */ z(
100
+ K,
101
+ {
102
+ type: "button",
103
+ ...C,
104
+ onKeyDown: x,
105
+ $hoverColor: I,
106
+ $activeColor: L,
107
+ $selectedColor: k,
108
+ $height: h,
109
+ $width: c || f,
110
+ disabled: o.disabled,
111
+ $isLoading: n,
112
+ children: [
113
+ /* @__PURE__ */ i(O, { $isLoading: n, children: /* @__PURE__ */ i(R, { size: "small", color: m || $ }) }),
114
+ /* @__PURE__ */ i(M, { $isLoading: n, $textColor: m || $, $font: T, children: e })
115
+ ]
116
+ }
117
+ );
118
+ return /* @__PURE__ */ i(
119
+ W,
120
+ {
121
+ $height: h,
122
+ $width: c || f,
123
+ disabled: o.disabled,
124
+ $isLoading: n,
125
+ children: n ? u : /* @__PURE__ */ i(U, { theme: r, children: u })
126
+ }
127
+ );
149
128
  };
150
129
  Y.propTypes = {
151
130
  /** Button label or content */
@@ -155,7 +134,7 @@ Y.propTypes = {
155
134
  /** Button size variant: `'small'`, `'medium'`, `'large'`, or `'ex-large'` */
156
135
  size: t.string,
157
136
  /** Override the button width */
158
- width: /* @__PURE__ */ t.oneOfType([t.string, t.number]),
137
+ width: t.oneOfType([t.string, t.number]),
159
138
  /** Icon component rendered to the left of the label */
160
139
  leftIcon: t.elementType,
161
140
  /** Icon component rendered to the right of the label */
@@ -18,41 +18,29 @@ const xe = o.div`
18
18
  overflow: hidden;
19
19
  width: 100%;
20
20
  outline: none;
21
- cursor: ${({
22
- $draggable: t
23
- }) => t ? "grab" : "default"};
21
+ cursor: ${({ $draggable: t }) => t ? "grab" : "default"};
24
22
 
25
23
  &:active {
26
- cursor: ${({
27
- $draggable: t
28
- }) => t ? "grabbing" : "default"};
24
+ cursor: ${({ $draggable: t }) => t ? "grabbing" : "default"};
29
25
  }
30
26
  `, we = o.div`
31
27
  display: flex;
32
28
  width: 100%;
33
- transform: translateX(${({
34
- $translateX: t
35
- }) => t}%);
36
- transition: ${({
37
- $dragging: t
38
- }) => t ? "none" : "transform 0.35s ease"};
29
+ transform: translateX(${({ $translateX: t }) => t}%);
30
+ transition: ${({ $dragging: t }) => t ? "none" : "transform 0.35s ease"};
39
31
 
40
32
  @media (prefers-reduced-motion: reduce) {
41
33
  transition: none;
42
34
  }
43
35
 
44
36
  & > * {
45
- flex: 0 0 ${({
46
- $visibleSlides: t
47
- }) => 100 / t}%;
37
+ flex: 0 0 ${({ $visibleSlides: t }) => 100 / t}%;
48
38
  min-width: 0;
49
39
  box-sizing: border-box;
50
40
  }
51
41
  `, J = o.button`
52
42
  position: absolute;
53
- top: ${({
54
- $arrowTop: t
55
- }) => t != null ? t : "50%"};
43
+ top: ${({ $arrowTop: t }) => t != null ? t : "50%"};
56
44
  transform: translateY(-50%);
57
45
  z-index: 1;
58
46
  display: flex;
@@ -70,10 +58,7 @@ const xe = o.div`
70
58
  opacity 0.3s;
71
59
  padding: 0;
72
60
 
73
- ${({
74
- $direction: t,
75
- $overlay: u
76
- }) => t === "prev" ? `left: ${u ? "12px" : "-16px"};` : `right: ${u ? "12px" : "-16px"};`}
61
+ ${({ $direction: t, $overlay: u }) => t === "prev" ? `left: ${u ? "12px" : "-16px"};` : `right: ${u ? "12px" : "-16px"};`}
77
62
 
78
63
  &:hover:not(:disabled) {
79
64
  background: #f5f5f5;
@@ -90,16 +75,11 @@ const xe = o.div`
90
75
  border-color: #f9a8c0;
91
76
  }
92
77
 
93
- ${({
94
- $viewportFocused: t
95
- }) => t && `
78
+ ${({ $viewportFocused: t }) => t && `
96
79
  border-color: #bdbdbd;
97
80
  `}
98
81
 
99
- ${({
100
- $overlay: t,
101
- $visible: u
102
- }) => t && !u && `
82
+ ${({ $overlay: t, $visible: u }) => t && !u && `
103
83
  opacity: 0;
104
84
  pointer-events: none;
105
85
  `}
@@ -108,15 +88,11 @@ const xe = o.div`
108
88
  gap: 6px;
109
89
  align-items: center;
110
90
  `, ke = o.button`
111
- width: ${({
112
- $active: t
113
- }) => t ? "20px" : "8px"};
91
+ width: ${({ $active: t }) => t ? "20px" : "8px"};
114
92
  height: 8px;
115
93
  border-radius: 4px;
116
94
  border: none;
117
- background: ${({
118
- $active: t
119
- }) => t ? "#333" : "#ccc"};
95
+ background: ${({ $active: t }) => t ? "#333" : "#ccc"};
120
96
  cursor: pointer;
121
97
  padding: 0;
122
98
  transition:
@@ -139,12 +115,8 @@ const xe = o.div`
139
115
  inset: 0;
140
116
  width: 0%;
141
117
  background: #333;
142
- animation: ${ye} ${({
143
- $duration: t
144
- }) => t}s linear forwards;
145
- animation-play-state: ${({
146
- $paused: t
147
- }) => t ? "paused" : "running"};
118
+ animation: ${ye} ${({ $duration: t }) => t}s linear forwards;
119
+ animation-play-state: ${({ $paused: t }) => t ? "paused" : "running"};
148
120
 
149
121
  @media (prefers-reduced-motion: reduce) {
150
122
  animation: none;
@@ -249,37 +221,120 @@ const xe = o.div`
249
221
  }, ue = (e) => {
250
222
  e.key === "ArrowLeft" ? (e.preventDefault(), M()) : e.key === "ArrowRight" && (e.preventDefault(), E());
251
223
  }, Y = (G = (A = U.current) == null ? void 0 : A.clientWidth) != null ? G : 0, de = Y > 0 ? te / Y * 100 : 0, fe = -(i * (100 / L)) + de, q = v !== void 0 ? typeof v == "number" ? `${v}px` : v : void 0, z = s + 1;
252
- return /* @__PURE__ */ C(xe, { onClick: K, onMouseEnter: ne, onMouseLeave: re, onMouseMove: ce, onMouseUp: le, onKeyDown: ue, role: "region", "aria-label": "Carousel", ...ee, children: [
253
- /* @__PURE__ */ C(me, { onTouchStart: ie, onTouchMove: oe, onTouchEnd: se, children: [
254
- V && /* @__PURE__ */ r(J, { onClick: M, disabled: !h && i === 0, "aria-label": "Previous slide", $direction: "prev", $overlay: a, $visible: W, $arrowTop: q, $viewportFocused: F, children: /* @__PURE__ */ r(pe, { size: 20, "aria-hidden": "true" }) }),
255
- /* @__PURE__ */ r(ve, { ref: U, tabIndex: 0, "aria-label": "Carousel slides. Use arrow keys to navigate.", $draggable: $, onFocus: () => {
256
- j(!0), g(!0);
257
- }, onBlur: () => {
258
- j(!1), g(!1);
259
- }, onMouseDown: ae, onMouseLeave: (e) => {
260
- e.buttons !== 1 && (k && _ && (m(!1), x(0)), c.current = null);
261
- }, children: /* @__PURE__ */ r(we, { $translateX: fe, $visibleSlides: L, $dragging: _, children: t.map(u) }) }),
262
- V && /* @__PURE__ */ r(J, { onClick: E, disabled: !h && i === s, "aria-label": "Next slide", $direction: "next", $overlay: a, $visible: W, $arrowTop: q, $viewportFocused: F, children: /* @__PURE__ */ r(be, { size: 20, "aria-hidden": "true" }) }),
263
- w && /* @__PURE__ */ r(Ee, { onClick: () => g((e) => !e), "aria-label": b ? "Play slideshow" : "Pause slideshow", children: b ? /* @__PURE__ */ r(Te, {}) : /* @__PURE__ */ r(Ie, {}) })
264
- ] }),
265
- /* @__PURE__ */ C("div", { "aria-live": "polite", "aria-atomic": "true", style: {
266
- position: "absolute",
267
- width: 1,
268
- height: 1,
269
- overflow: "hidden",
270
- clip: "rect(0,0,0,0)",
271
- whiteSpace: "nowrap"
272
- }, children: [
273
- "Slide ",
274
- i + 1,
275
- " of ",
276
- z
277
- ] }),
278
- w && Z && /* @__PURE__ */ r(Me, { $duration: D, $paused: b }, i),
279
- !Q && /* @__PURE__ */ r($e, { children: Array.from({
280
- length: z
281
- }).map((e, n) => /* @__PURE__ */ r(ke, { $active: n === i, onClick: () => y(n), "aria-label": `Slide ${n + 1} of ${z}`, "aria-current": n === i ? "true" : void 0 }, n)) })
282
- ] });
224
+ return /* @__PURE__ */ C(
225
+ xe,
226
+ {
227
+ onClick: K,
228
+ onMouseEnter: ne,
229
+ onMouseLeave: re,
230
+ onMouseMove: ce,
231
+ onMouseUp: le,
232
+ onKeyDown: ue,
233
+ role: "region",
234
+ "aria-label": "Carousel",
235
+ ...ee,
236
+ children: [
237
+ /* @__PURE__ */ C(
238
+ me,
239
+ {
240
+ onTouchStart: ie,
241
+ onTouchMove: oe,
242
+ onTouchEnd: se,
243
+ children: [
244
+ V && /* @__PURE__ */ r(
245
+ J,
246
+ {
247
+ onClick: M,
248
+ disabled: !h && i === 0,
249
+ "aria-label": "Previous slide",
250
+ $direction: "prev",
251
+ $overlay: a,
252
+ $visible: W,
253
+ $arrowTop: q,
254
+ $viewportFocused: F,
255
+ children: /* @__PURE__ */ r(pe, { size: 20, "aria-hidden": "true" })
256
+ }
257
+ ),
258
+ /* @__PURE__ */ r(
259
+ ve,
260
+ {
261
+ ref: U,
262
+ tabIndex: 0,
263
+ "aria-label": "Carousel slides. Use arrow keys to navigate.",
264
+ $draggable: $,
265
+ onFocus: () => {
266
+ j(!0), g(!0);
267
+ },
268
+ onBlur: () => {
269
+ j(!1), g(!1);
270
+ },
271
+ onMouseDown: ae,
272
+ onMouseLeave: (e) => {
273
+ e.buttons !== 1 && (k && _ && (m(!1), x(0)), c.current = null);
274
+ },
275
+ children: /* @__PURE__ */ r(we, { $translateX: fe, $visibleSlides: L, $dragging: _, children: t.map(u) })
276
+ }
277
+ ),
278
+ V && /* @__PURE__ */ r(
279
+ J,
280
+ {
281
+ onClick: E,
282
+ disabled: !h && i === s,
283
+ "aria-label": "Next slide",
284
+ $direction: "next",
285
+ $overlay: a,
286
+ $visible: W,
287
+ $arrowTop: q,
288
+ $viewportFocused: F,
289
+ children: /* @__PURE__ */ r(be, { size: 20, "aria-hidden": "true" })
290
+ }
291
+ ),
292
+ w && /* @__PURE__ */ r(
293
+ Ee,
294
+ {
295
+ onClick: () => g((e) => !e),
296
+ "aria-label": b ? "Play slideshow" : "Pause slideshow",
297
+ children: b ? /* @__PURE__ */ r(Te, {}) : /* @__PURE__ */ r(Ie, {})
298
+ }
299
+ )
300
+ ]
301
+ }
302
+ ),
303
+ /* @__PURE__ */ C(
304
+ "div",
305
+ {
306
+ "aria-live": "polite",
307
+ "aria-atomic": "true",
308
+ style: {
309
+ position: "absolute",
310
+ width: 1,
311
+ height: 1,
312
+ overflow: "hidden",
313
+ clip: "rect(0,0,0,0)",
314
+ whiteSpace: "nowrap"
315
+ },
316
+ children: [
317
+ "Slide ",
318
+ i + 1,
319
+ " of ",
320
+ z
321
+ ]
322
+ }
323
+ ),
324
+ w && Z && /* @__PURE__ */ r(Me, { $duration: D, $paused: b }, i),
325
+ !Q && /* @__PURE__ */ r($e, { children: Array.from({ length: z }).map((e, n) => /* @__PURE__ */ r(
326
+ ke,
327
+ {
328
+ $active: n === i,
329
+ onClick: () => y(n),
330
+ "aria-label": `Slide ${n + 1} of ${z}`,
331
+ "aria-current": n === i ? "true" : void 0
332
+ },
333
+ n
334
+ )) })
335
+ ]
336
+ }
337
+ );
283
338
  };
284
339
  export {
285
340
  Pe as default