@skodaflow/web-library 7.13.1 → 7.14.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (338) hide show
  1. package/cjs/components/backdrop/backdrop.d.ts +1 -2
  2. package/cjs/components/backdrop/backdrop.js.map +1 -1
  3. package/cjs/components/cardMenu/cardMenu.d.ts +1 -2
  4. package/cjs/components/cardMenu/cardMenu.js.map +1 -1
  5. package/cjs/components/cardMenu/styled/drawerStyled.d.ts +1 -1
  6. package/cjs/components/cardMenu/styled/drawerStyled.js +1 -1
  7. package/cjs/components/cardMenu/styled/drawerStyled.js.map +1 -1
  8. package/cjs/components/cardMenu/styled/popperStyled.d.ts +1 -1
  9. package/cjs/components/cardMenu/styled/popperStyled.js +1 -1
  10. package/cjs/components/cardMenu/styled/popperStyled.js.map +1 -1
  11. package/cjs/components/carousel/navigation.js +1 -1
  12. package/cjs/components/carousel/navigation.js.map +1 -1
  13. package/cjs/components/carousel/pagination.d.ts +5 -1
  14. package/cjs/components/carousel/pagination.js +1 -1
  15. package/cjs/components/carousel/pagination.js.map +1 -1
  16. package/cjs/components/chip/chipFocusVisibleStyled.d.ts +1 -1
  17. package/cjs/components/chip/chipFocusVisibleStyled.js +1 -1
  18. package/cjs/components/chip/chipFocusVisibleStyled.js.map +1 -1
  19. package/cjs/components/common/menuContainer.js +1 -1
  20. package/cjs/components/common/menuContainer.js.map +1 -1
  21. package/cjs/components/common/styled/buttonFocusVisibleStyled.d.ts +1 -1
  22. package/cjs/components/common/styled/buttonFocusVisibleStyled.js +1 -1
  23. package/cjs/components/common/styled/buttonFocusVisibleStyled.js.map +1 -1
  24. package/cjs/components/common/styled/formControlLabelStyled.d.ts +1 -1
  25. package/cjs/components/common/styled/formControlLabelStyled.js +1 -1
  26. package/cjs/components/common/styled/formControlLabelStyled.js.map +1 -1
  27. package/cjs/components/common/styled/helperTextContainerStyled.d.ts +1 -1
  28. package/cjs/components/common/styled/sliderValuesStyled.d.ts +1 -1
  29. package/cjs/components/common/styled/sliderValuesStyled.js +1 -1
  30. package/cjs/components/common/styled/sliderValuesStyled.js.map +1 -1
  31. package/cjs/components/customPickersActionBar/index.js +1 -1
  32. package/cjs/components/customPickersActionBar/index.js.map +1 -1
  33. package/cjs/components/grid/grid.d.ts +3 -100
  34. package/cjs/components/grid/grid.js.map +1 -1
  35. package/cjs/components/icon/filled/BatteryDischargeFilledIcon.d.ts +6 -0
  36. package/cjs/components/icon/filled/BatteryDischargeFilledIcon.js +2 -0
  37. package/cjs/components/icon/filled/BatteryDischargeFilledIcon.js.map +1 -0
  38. package/cjs/components/icon/filled/BicycleFilledIcon.d.ts +6 -0
  39. package/cjs/components/icon/filled/BicycleFilledIcon.js +2 -0
  40. package/cjs/components/icon/filled/BicycleFilledIcon.js.map +1 -0
  41. package/cjs/components/icon/filled/BoltDischargeFilledIcon.d.ts +6 -0
  42. package/cjs/components/icon/filled/BoltDischargeFilledIcon.js +2 -0
  43. package/cjs/components/icon/filled/BoltDischargeFilledIcon.js.map +1 -0
  44. package/cjs/components/icon/filled/BoltOffFilledIcon.d.ts +6 -0
  45. package/cjs/components/icon/filled/BoltOffFilledIcon.js +2 -0
  46. package/cjs/components/icon/filled/BoltOffFilledIcon.js.map +1 -0
  47. package/cjs/components/icon/filled/index.d.ts +4 -0
  48. package/cjs/components/icon/icon.definitions.js +1 -1
  49. package/cjs/components/icon/icon.definitions.js.map +1 -1
  50. package/cjs/components/icon/stroke/BatteryDischargeIcon.d.ts +6 -0
  51. package/cjs/components/icon/stroke/BatteryDischargeIcon.js +2 -0
  52. package/cjs/components/icon/stroke/BatteryDischargeIcon.js.map +1 -0
  53. package/cjs/components/icon/stroke/BicycleIcon.d.ts +6 -0
  54. package/cjs/components/icon/stroke/BicycleIcon.js +2 -0
  55. package/cjs/components/icon/stroke/BicycleIcon.js.map +1 -0
  56. package/cjs/components/icon/stroke/BoltDischargeIcon.d.ts +6 -0
  57. package/cjs/components/icon/stroke/BoltDischargeIcon.js +2 -0
  58. package/cjs/components/icon/stroke/BoltDischargeIcon.js.map +1 -0
  59. package/cjs/components/icon/stroke/BoltOffIcon.d.ts +6 -0
  60. package/cjs/components/icon/stroke/BoltOffIcon.js +2 -0
  61. package/cjs/components/icon/stroke/BoltOffIcon.js.map +1 -0
  62. package/cjs/components/icon/stroke/index.d.ts +4 -0
  63. package/cjs/components/label/label.d.ts +1 -1
  64. package/cjs/components/label/label.js +1 -1
  65. package/cjs/components/label/label.js.map +1 -1
  66. package/cjs/components/logo/Logo.d.ts +1 -1
  67. package/cjs/components/logo/Logo.js.map +1 -1
  68. package/cjs/components/mobileStepper/mobileStepperButton.js +1 -1
  69. package/cjs/components/mobileStepper/mobileStepperButton.js.map +1 -1
  70. package/cjs/components/search/search.js +1 -1
  71. package/cjs/components/search/search.js.map +1 -1
  72. package/cjs/components/segmentedControls/{segmentedControls.js → SegmentedControls.js} +1 -1
  73. package/cjs/components/segmentedControls/{segmentedControls.js.map → SegmentedControls.js.map} +1 -1
  74. package/cjs/components/segmentedControls/index.d.ts +1 -1
  75. package/cjs/components/stepper/model.d.ts +1 -3
  76. package/cjs/components/stepper/model.js.map +1 -1
  77. package/cjs/components/textAndCta/textAndCta.js +1 -1
  78. package/cjs/components/textAndCta/textAndCta.js.map +1 -1
  79. package/cjs/components/upload/UploadPreviewList.js +1 -1
  80. package/cjs/components/upload/UploadPreviewList.js.map +1 -1
  81. package/cjs/index.js +1 -1
  82. package/cjs/layout/Header/Header.js +1 -1
  83. package/cjs/layout/Header/Header.js.map +1 -1
  84. package/cjs/layout/Header/HeaderLanguageSelect.d.ts +1 -1
  85. package/cjs/layout/Header/HeaderLanguageSelect.js +1 -1
  86. package/cjs/layout/Header/HeaderLanguageSelect.js.map +1 -1
  87. package/cjs/layout/Header/HeaderNavigationHero.js +1 -1
  88. package/cjs/layout/Header/HeaderNavigationHero.js.map +1 -1
  89. package/cjs/layout/Header/HeaderOverheadItem.js +1 -1
  90. package/cjs/layout/Header/HeaderOverheadItem.js.map +1 -1
  91. package/cjs/materialui/accordion/AccordionSummaryExpandIcon.js +1 -1
  92. package/cjs/materialui/accordion/AccordionSummaryExpandIcon.js.map +1 -1
  93. package/cjs/materialui/accordion/accordionSummary.theme.js +1 -1
  94. package/cjs/materialui/accordion/accordionSummary.theme.js.map +1 -1
  95. package/cjs/materialui/button/button.theme.js +1 -1
  96. package/cjs/materialui/button/button.theme.js.map +1 -1
  97. package/cjs/materialui/button/interactive.d.ts +2 -1
  98. package/cjs/materialui/button/interactive.js +1 -1
  99. package/cjs/materialui/button/interactive.js.map +1 -1
  100. package/cjs/materialui/card/Card.js +1 -1
  101. package/cjs/materialui/card/Card.js.map +1 -1
  102. package/cjs/materialui/card/FlippingCardContent.d.ts +2 -2
  103. package/cjs/materialui/card/FlippingCardContent.js +1 -1
  104. package/cjs/materialui/card/FlippingCardContent.js.map +1 -1
  105. package/cjs/materialui/card/card.theme.js +1 -1
  106. package/cjs/materialui/card/card.theme.js.map +1 -1
  107. package/cjs/materialui/chip/chip.theme.js +1 -1
  108. package/cjs/materialui/chip/chip.theme.js.map +1 -1
  109. package/cjs/materialui/fab/fab.theme.js +1 -1
  110. package/cjs/materialui/fab/fab.theme.js.map +1 -1
  111. package/cjs/materialui/iconButton/iconButton.theme.js +1 -1
  112. package/cjs/materialui/iconButton/iconButton.theme.js.map +1 -1
  113. package/cjs/materialui/skeleton/skeleton.theme.js +1 -1
  114. package/cjs/materialui/skeleton/skeleton.theme.js.map +1 -1
  115. package/cjs/materialui/slider/sliderValues.js +1 -1
  116. package/cjs/materialui/slider/sliderValues.js.map +1 -1
  117. package/cjs/materialui/stepper/StepLabelIcon.js +1 -1
  118. package/cjs/materialui/stepper/StepLabelIcon.js.map +1 -1
  119. package/cjs/materialui/stepper/stepper.theme.js +1 -1
  120. package/cjs/materialui/stepper/stepper.theme.js.map +1 -1
  121. package/{materialui/tabs/scrollButtonComponent.d.ts → cjs/materialui/tabs/ScrollButton.d.ts} +2 -1
  122. package/cjs/materialui/tabs/ScrollButton.js +2 -0
  123. package/cjs/materialui/tabs/ScrollButton.js.map +1 -0
  124. package/cjs/materialui/tabs/{tabComponent.d.ts → Tab.d.ts} +1 -1
  125. package/cjs/materialui/tabs/{tabComponent.js → Tab.js} +2 -2
  126. package/cjs/materialui/tabs/Tab.js.map +1 -0
  127. package/cjs/materialui/tabs/{tabPanel.d.ts → TabPanel.d.ts} +0 -4
  128. package/cjs/materialui/tabs/{tabPanel.js → TabPanel.js} +2 -2
  129. package/cjs/materialui/tabs/TabPanel.js.map +1 -0
  130. package/cjs/materialui/tabs/index.d.ts +3 -3
  131. package/cjs/materialui/tabs/tab.theme.js +1 -1
  132. package/cjs/materialui/tabs/tab.theme.js.map +1 -1
  133. package/cjs/materialui/tabs/tabs.theme.js +1 -1
  134. package/cjs/materialui/tabs/tabs.theme.js.map +1 -1
  135. package/cjs/materialui/textfield/textField.theme.js +1 -1
  136. package/cjs/materialui/textfield/textField.theme.js.map +1 -1
  137. package/cjs/node_modules/swiper/modules/keyboard.js +1 -1
  138. package/cjs/node_modules/swiper/modules/keyboard.js.map +1 -1
  139. package/cjs/node_modules/swiper/shared/ssr-window.esm.js.map +1 -1
  140. package/cjs/node_modules/swiper/shared/swiper-core.js +1 -1
  141. package/cjs/node_modules/swiper/shared/swiper-core.js.map +1 -1
  142. package/cjs/node_modules/swiper/swiper-react.js.map +1 -1
  143. package/cjs/organisms/cardPhotoFixed/cardPhotoFixed.js +1 -1
  144. package/cjs/organisms/cardPhotoFixed/cardPhotoFixed.js.map +1 -1
  145. package/cjs/organisms/carousel/styledComponents/styledCarouselHorizontal.d.ts +1 -1
  146. package/cjs/organisms/carousel/styledComponents/styledCarouselHorizontal.js +1 -1
  147. package/cjs/organisms/carousel/styledComponents/styledCarouselHorizontal.js.map +1 -1
  148. package/cjs/organisms/carousel/styledComponents/styledCarouselVertical.d.ts +1 -1
  149. package/cjs/organisms/carousel/styledComponents/styledCarouselVertical.js +1 -1
  150. package/cjs/organisms/carousel/styledComponents/styledCarouselVertical.js.map +1 -1
  151. package/cjs/organisms/carousel2/galleryCarousel/galleryCarousel.js +1 -1
  152. package/cjs/organisms/carousel2/galleryCarousel/galleryCarousel.js.map +1 -1
  153. package/cjs/organisms/carousel2/galleryCarousel/galleryCarouselItem.js +1 -1
  154. package/cjs/organisms/carousel2/galleryCarousel/galleryCarouselItem.js.map +1 -1
  155. package/cjs/organisms/carousel2/styledComponents/styledCarouselHorizontal.d.ts +1 -1
  156. package/cjs/organisms/common/menuCardComponent/menuCardComponent.d.ts +1 -2
  157. package/cjs/organisms/common/menuCardComponent/menuCardComponent.js +1 -1
  158. package/cjs/organisms/common/menuCardComponent/menuCardComponent.js.map +1 -1
  159. package/cjs/organisms/notification/NotificationCenterHeaderButton.js +1 -1
  160. package/cjs/organisms/notification/NotificationCenterHeaderButton.js.map +1 -1
  161. package/cjs/organisms/textCta/textCta.js +1 -1
  162. package/cjs/organisms/textCta/textCta.js.map +1 -1
  163. package/cjs/organisms/tile/tile.js +1 -1
  164. package/cjs/organisms/tile/tile.js.map +1 -1
  165. package/cjs/production/Button/Button.js +1 -1
  166. package/cjs/production/Button/Button.js.map +1 -1
  167. package/components/backdrop/backdrop.d.ts +1 -2
  168. package/components/backdrop/backdrop.js.map +1 -1
  169. package/components/cardMenu/cardMenu.d.ts +1 -2
  170. package/components/cardMenu/cardMenu.js.map +1 -1
  171. package/components/cardMenu/styled/drawerStyled.d.ts +1 -1
  172. package/components/cardMenu/styled/drawerStyled.js +1 -1
  173. package/components/cardMenu/styled/drawerStyled.js.map +1 -1
  174. package/components/cardMenu/styled/popperStyled.d.ts +1 -1
  175. package/components/cardMenu/styled/popperStyled.js +1 -1
  176. package/components/cardMenu/styled/popperStyled.js.map +1 -1
  177. package/components/carousel/navigation.js +1 -1
  178. package/components/carousel/navigation.js.map +1 -1
  179. package/components/carousel/pagination.d.ts +5 -1
  180. package/components/carousel/pagination.js +1 -1
  181. package/components/carousel/pagination.js.map +1 -1
  182. package/components/chip/chipFocusVisibleStyled.d.ts +1 -1
  183. package/components/chip/chipFocusVisibleStyled.js +1 -1
  184. package/components/chip/chipFocusVisibleStyled.js.map +1 -1
  185. package/components/common/menuContainer.js +1 -1
  186. package/components/common/menuContainer.js.map +1 -1
  187. package/components/common/styled/buttonFocusVisibleStyled.d.ts +1 -1
  188. package/components/common/styled/buttonFocusVisibleStyled.js +1 -1
  189. package/components/common/styled/buttonFocusVisibleStyled.js.map +1 -1
  190. package/components/common/styled/formControlLabelStyled.d.ts +1 -1
  191. package/components/common/styled/formControlLabelStyled.js +1 -1
  192. package/components/common/styled/formControlLabelStyled.js.map +1 -1
  193. package/components/common/styled/helperTextContainerStyled.d.ts +1 -1
  194. package/components/common/styled/sliderValuesStyled.d.ts +1 -1
  195. package/components/common/styled/sliderValuesStyled.js +1 -1
  196. package/components/common/styled/sliderValuesStyled.js.map +1 -1
  197. package/components/customPickersActionBar/index.js +1 -1
  198. package/components/customPickersActionBar/index.js.map +1 -1
  199. package/components/grid/grid.d.ts +3 -100
  200. package/components/grid/grid.js.map +1 -1
  201. package/components/icon/filled/BatteryDischargeFilledIcon.d.ts +6 -0
  202. package/components/icon/filled/BatteryDischargeFilledIcon.js +2 -0
  203. package/components/icon/filled/BatteryDischargeFilledIcon.js.map +1 -0
  204. package/components/icon/filled/BicycleFilledIcon.d.ts +6 -0
  205. package/components/icon/filled/BicycleFilledIcon.js +2 -0
  206. package/components/icon/filled/BicycleFilledIcon.js.map +1 -0
  207. package/components/icon/filled/BoltDischargeFilledIcon.d.ts +6 -0
  208. package/components/icon/filled/BoltDischargeFilledIcon.js +2 -0
  209. package/components/icon/filled/BoltDischargeFilledIcon.js.map +1 -0
  210. package/components/icon/filled/BoltOffFilledIcon.d.ts +6 -0
  211. package/components/icon/filled/BoltOffFilledIcon.js +2 -0
  212. package/components/icon/filled/BoltOffFilledIcon.js.map +1 -0
  213. package/components/icon/filled/index.d.ts +4 -0
  214. package/components/icon/icon.definitions.js +1 -1
  215. package/components/icon/icon.definitions.js.map +1 -1
  216. package/components/icon/stroke/BatteryDischargeIcon.d.ts +6 -0
  217. package/components/icon/stroke/BatteryDischargeIcon.js +2 -0
  218. package/components/icon/stroke/BatteryDischargeIcon.js.map +1 -0
  219. package/components/icon/stroke/BicycleIcon.d.ts +6 -0
  220. package/components/icon/stroke/BicycleIcon.js +2 -0
  221. package/components/icon/stroke/BicycleIcon.js.map +1 -0
  222. package/components/icon/stroke/BoltDischargeIcon.d.ts +6 -0
  223. package/components/icon/stroke/BoltDischargeIcon.js +2 -0
  224. package/components/icon/stroke/BoltDischargeIcon.js.map +1 -0
  225. package/components/icon/stroke/BoltOffIcon.d.ts +6 -0
  226. package/components/icon/stroke/BoltOffIcon.js +2 -0
  227. package/components/icon/stroke/BoltOffIcon.js.map +1 -0
  228. package/components/icon/stroke/index.d.ts +4 -0
  229. package/components/label/label.d.ts +1 -1
  230. package/components/label/label.js +1 -1
  231. package/components/label/label.js.map +1 -1
  232. package/components/logo/Logo.d.ts +1 -1
  233. package/components/logo/Logo.js.map +1 -1
  234. package/components/mobileStepper/mobileStepperButton.js +1 -1
  235. package/components/mobileStepper/mobileStepperButton.js.map +1 -1
  236. package/components/search/search.js +1 -1
  237. package/components/search/search.js.map +1 -1
  238. package/components/segmentedControls/{segmentedControls.js → SegmentedControls.js} +1 -1
  239. package/components/segmentedControls/{segmentedControls.js.map → SegmentedControls.js.map} +1 -1
  240. package/components/segmentedControls/index.d.ts +1 -1
  241. package/components/stepper/model.d.ts +1 -3
  242. package/components/stepper/model.js.map +1 -1
  243. package/components/textAndCta/textAndCta.js +1 -1
  244. package/components/textAndCta/textAndCta.js.map +1 -1
  245. package/components/upload/UploadPreviewList.js +1 -1
  246. package/components/upload/UploadPreviewList.js.map +1 -1
  247. package/index.js +1 -1
  248. package/layout/Header/Header.js +1 -1
  249. package/layout/Header/Header.js.map +1 -1
  250. package/layout/Header/HeaderLanguageSelect.d.ts +1 -1
  251. package/layout/Header/HeaderLanguageSelect.js +1 -1
  252. package/layout/Header/HeaderLanguageSelect.js.map +1 -1
  253. package/layout/Header/HeaderNavigationHero.js +1 -1
  254. package/layout/Header/HeaderNavigationHero.js.map +1 -1
  255. package/layout/Header/HeaderOverheadItem.js +1 -1
  256. package/layout/Header/HeaderOverheadItem.js.map +1 -1
  257. package/materialui/accordion/AccordionSummaryExpandIcon.js +1 -1
  258. package/materialui/accordion/AccordionSummaryExpandIcon.js.map +1 -1
  259. package/materialui/accordion/accordionSummary.theme.js +1 -1
  260. package/materialui/accordion/accordionSummary.theme.js.map +1 -1
  261. package/materialui/button/button.theme.js +1 -1
  262. package/materialui/button/button.theme.js.map +1 -1
  263. package/materialui/button/interactive.d.ts +2 -1
  264. package/materialui/button/interactive.js +1 -1
  265. package/materialui/button/interactive.js.map +1 -1
  266. package/materialui/card/Card.js +1 -1
  267. package/materialui/card/Card.js.map +1 -1
  268. package/materialui/card/FlippingCardContent.d.ts +2 -2
  269. package/materialui/card/FlippingCardContent.js +1 -1
  270. package/materialui/card/FlippingCardContent.js.map +1 -1
  271. package/materialui/card/card.theme.js +1 -1
  272. package/materialui/card/card.theme.js.map +1 -1
  273. package/materialui/chip/chip.theme.js +1 -1
  274. package/materialui/chip/chip.theme.js.map +1 -1
  275. package/materialui/fab/fab.theme.js +1 -1
  276. package/materialui/fab/fab.theme.js.map +1 -1
  277. package/materialui/iconButton/iconButton.theme.js +1 -1
  278. package/materialui/iconButton/iconButton.theme.js.map +1 -1
  279. package/materialui/skeleton/skeleton.theme.js +1 -1
  280. package/materialui/skeleton/skeleton.theme.js.map +1 -1
  281. package/materialui/slider/sliderValues.js +1 -1
  282. package/materialui/slider/sliderValues.js.map +1 -1
  283. package/materialui/stepper/StepLabelIcon.js +1 -1
  284. package/materialui/stepper/StepLabelIcon.js.map +1 -1
  285. package/materialui/stepper/stepper.theme.js +1 -1
  286. package/materialui/stepper/stepper.theme.js.map +1 -1
  287. package/{cjs/materialui/tabs/scrollButtonComponent.d.ts → materialui/tabs/ScrollButton.d.ts} +2 -1
  288. package/materialui/tabs/ScrollButton.js +2 -0
  289. package/materialui/tabs/ScrollButton.js.map +1 -0
  290. package/materialui/tabs/{tabComponent.d.ts → Tab.d.ts} +1 -1
  291. package/materialui/tabs/{tabComponent.js → Tab.js} +2 -2
  292. package/materialui/tabs/Tab.js.map +1 -0
  293. package/materialui/tabs/{tabPanel.d.ts → TabPanel.d.ts} +0 -4
  294. package/materialui/tabs/TabPanel.js +2 -0
  295. package/materialui/tabs/TabPanel.js.map +1 -0
  296. package/materialui/tabs/index.d.ts +3 -3
  297. package/materialui/tabs/tab.theme.js +1 -1
  298. package/materialui/tabs/tab.theme.js.map +1 -1
  299. package/materialui/tabs/tabs.theme.js +1 -1
  300. package/materialui/tabs/tabs.theme.js.map +1 -1
  301. package/materialui/textfield/textField.theme.js +1 -1
  302. package/materialui/textfield/textField.theme.js.map +1 -1
  303. package/organisms/cardPhotoFixed/cardPhotoFixed.js +1 -1
  304. package/organisms/cardPhotoFixed/cardPhotoFixed.js.map +1 -1
  305. package/organisms/carousel/styledComponents/styledCarouselHorizontal.d.ts +1 -1
  306. package/organisms/carousel/styledComponents/styledCarouselHorizontal.js +1 -1
  307. package/organisms/carousel/styledComponents/styledCarouselHorizontal.js.map +1 -1
  308. package/organisms/carousel/styledComponents/styledCarouselVertical.d.ts +1 -1
  309. package/organisms/carousel/styledComponents/styledCarouselVertical.js +1 -1
  310. package/organisms/carousel/styledComponents/styledCarouselVertical.js.map +1 -1
  311. package/organisms/carousel2/galleryCarousel/galleryCarousel.js +1 -1
  312. package/organisms/carousel2/galleryCarousel/galleryCarousel.js.map +1 -1
  313. package/organisms/carousel2/galleryCarousel/galleryCarouselItem.js +1 -1
  314. package/organisms/carousel2/galleryCarousel/galleryCarouselItem.js.map +1 -1
  315. package/organisms/carousel2/styledComponents/styledCarouselHorizontal.d.ts +1 -1
  316. package/organisms/common/menuCardComponent/menuCardComponent.d.ts +1 -2
  317. package/organisms/common/menuCardComponent/menuCardComponent.js +1 -1
  318. package/organisms/common/menuCardComponent/menuCardComponent.js.map +1 -1
  319. package/organisms/notification/NotificationCenterHeaderButton.js +1 -1
  320. package/organisms/notification/NotificationCenterHeaderButton.js.map +1 -1
  321. package/organisms/textCta/textCta.js +1 -1
  322. package/organisms/textCta/textCta.js.map +1 -1
  323. package/organisms/tile/tile.js +1 -1
  324. package/organisms/tile/tile.js.map +1 -1
  325. package/package.json +1 -1
  326. package/production/Button/Button.js +1 -1
  327. package/production/Button/Button.js.map +1 -1
  328. package/cjs/materialui/tabs/scrollButtonComponent.js +0 -2
  329. package/cjs/materialui/tabs/scrollButtonComponent.js.map +0 -1
  330. package/cjs/materialui/tabs/tabComponent.js.map +0 -1
  331. package/cjs/materialui/tabs/tabPanel.js.map +0 -1
  332. package/materialui/tabs/scrollButtonComponent.js +0 -2
  333. package/materialui/tabs/scrollButtonComponent.js.map +0 -1
  334. package/materialui/tabs/tabComponent.js.map +0 -1
  335. package/materialui/tabs/tabPanel.js +0 -2
  336. package/materialui/tabs/tabPanel.js.map +0 -1
  337. /package/cjs/components/segmentedControls/{segmentedControls.d.ts → SegmentedControls.d.ts} +0 -0
  338. /package/components/segmentedControls/{segmentedControls.d.ts → SegmentedControls.d.ts} +0 -0
@@ -1,6 +1,5 @@
1
1
  import React, { HTMLAttributes, ReactNode } from 'react';
2
- import { SxProps } from '@mui/system';
3
- import { Theme } from '@mui/material';
2
+ import { SxProps, Theme } from '@mui/material';
4
3
  export interface BackdropProps extends HTMLAttributes<HTMLDivElement> {
5
4
  /**
6
5
  * If true, the component is shown. Default value false
@@ -1 +1 @@
1
- {"version":3,"file":"backdrop.js","sources":["../../../../../src/components/backdrop/backdrop.tsx"],"sourcesContent":["import React, { HTMLAttributes, ReactNode, forwardRef, useEffect } from 'react';\nimport { SxProps } from '@mui/system';\nimport useBackdrop from '../../components/common/hook/backdrop';\nimport { styled, Theme, Backdrop as MuiBackdrop } from '@mui/material';\n\nexport interface BackdropProps extends HTMLAttributes<HTMLDivElement> {\n /**\n * If true, the component is shown. Default value false\n */\n open: boolean;\n /**\n * Override or extend the styles applied to the component.\n */\n classes?: object;\n /**\n * The component used for the root node. Either a string to use a HTML element or a component.\n */\n component?: string | ReactNode;\n /**\n * The components used for each slot inside the Backdrop. Either a string to use a HTML element or a component.\n */\n components?: object;\n /**\n * The props used for each slot inside the Backdrop.\n */\n componentsProps?: object;\n /**\n * If true, the backdrop is invisible. It can be used when rendering a popover or a custom select component. Default value is false\n */\n invisible?: boolean;\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles. See the `sx` page for more details.\n */\n sx?: SxProps<Theme>;\n /**\n The duration for the transition, in milliseconds. You may specify a single timeout for all transitions, or individually with an object.\n */\n transitionDuration?: number | object;\n /**\n * Additional onClose callback that needs to be provided when the state of the backdrop is controlled from outside.\n */\n onClose?: (isOpen: boolean) => void;\n}\n\n/**\n * @deprecated This component is deprecated. Use themed Backdrop component from @mui/material instead\n */\nexport const Backdrop = forwardRef<HTMLDivElement, BackdropProps>(({ open, onClose, ...props }, ref) => {\n const { openBackdrop, handleCloseBackdrop, setOpenBackdrop } = useBackdrop();\n\n const handleClose = () => {\n handleCloseBackdrop();\n onClose && onClose(false);\n };\n\n useEffect(() => {\n setOpenBackdrop(open);\n }, [open, setOpenBackdrop]);\n\n return (\n <BackdropStyled\n ref={ref}\n classes={props.classes}\n open={openBackdrop}\n onClick={handleClose}\n invisible={props.invisible}\n sx={props.sx}\n transitionDuration={props.transitionDuration}\n >\n {props.children}\n </BackdropStyled>\n );\n});\n\nconst BackdropStyled = styled(MuiBackdrop)<BackdropProps>(({ theme, ...args }) => {\n if (args.invisible)\n return {\n backgroundColor: theme.palette.transparent.backdrop,\n backdropFilter: 'blur(0px)',\n };\n\n return null;\n});\n"],"names":["Backdrop","forwardRef","_a","ref","open","onClose","props","__rest","openBackdrop","handleCloseBackdrop","setOpenBackdrop","useBackdrop","useEffect","_jsx","BackdropStyled","classes","onClick","invisible","sx","transitionDuration","children","styled","MuiBackdrop","theme","backgroundColor","palette","transparent","backdrop","backdropFilter"],"mappings":"yJA+Ca,MAAAA,EAAWC,EAAUA,YAAgC,CAACC,EAA6BC,SAA7BC,KAAEA,EAAIC,QAAEA,GAAOH,EAAKI,EAAKC,EAAAA,OAAAL,EAAzB,oBACjE,MAAMM,aAAEA,EAAYC,oBAAEA,EAAmBC,gBAAEA,GAAoBC,EAAAA,UAW/D,OAJAC,EAAAA,WAAU,KACRF,EAAgBN,EAAK,GACpB,CAACA,EAAMM,IAGRG,MAACC,EAAc,CACbX,IAAKA,EACLY,QAAST,EAAMS,QACfX,KAAMI,EACNQ,QAdgB,KAClBP,IACAJ,GAAWA,GAAQ,EAAM,EAavBY,UAAWX,EAAMW,UACjBC,GAAIZ,EAAMY,GACVC,mBAAoBb,EAAMa,mBAAkBC,SAE3Cd,EAAMc,UACQ,IAIfN,EAAiBO,EAAMA,OAACC,WAAPD,EAAoCnB,IAAA,IAAAqB,MAAEA,GAAgBrB,EAC3E,OADyEK,EAAAA,OAAAL,EAAhB,WAChDe,UACA,CACLO,gBAAiBD,EAAME,QAAQC,YAAYC,SAC3CC,eAAgB,aAGb,IAAI"}
1
+ {"version":3,"file":"backdrop.js","sources":["../../../../../src/components/backdrop/backdrop.tsx"],"sourcesContent":["import React, { HTMLAttributes, ReactNode, forwardRef, useEffect } from 'react';\nimport useBackdrop from '../../components/common/hook/backdrop';\nimport { SxProps, styled, Theme, Backdrop as MuiBackdrop } from '@mui/material';\n\nexport interface BackdropProps extends HTMLAttributes<HTMLDivElement> {\n /**\n * If true, the component is shown. Default value false\n */\n open: boolean;\n /**\n * Override or extend the styles applied to the component.\n */\n classes?: object;\n /**\n * The component used for the root node. Either a string to use a HTML element or a component.\n */\n component?: string | ReactNode;\n /**\n * The components used for each slot inside the Backdrop. Either a string to use a HTML element or a component.\n */\n components?: object;\n /**\n * The props used for each slot inside the Backdrop.\n */\n componentsProps?: object;\n /**\n * If true, the backdrop is invisible. It can be used when rendering a popover or a custom select component. Default value is false\n */\n invisible?: boolean;\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles. See the `sx` page for more details.\n */\n sx?: SxProps<Theme>;\n /**\n The duration for the transition, in milliseconds. You may specify a single timeout for all transitions, or individually with an object.\n */\n transitionDuration?: number | object;\n /**\n * Additional onClose callback that needs to be provided when the state of the backdrop is controlled from outside.\n */\n onClose?: (isOpen: boolean) => void;\n}\n\n/**\n * @deprecated This component is deprecated. Use themed Backdrop component from @mui/material instead\n */\nexport const Backdrop = forwardRef<HTMLDivElement, BackdropProps>(({ open, onClose, ...props }, ref) => {\n const { openBackdrop, handleCloseBackdrop, setOpenBackdrop } = useBackdrop();\n\n const handleClose = () => {\n handleCloseBackdrop();\n onClose && onClose(false);\n };\n\n useEffect(() => {\n setOpenBackdrop(open);\n }, [open, setOpenBackdrop]);\n\n return (\n <BackdropStyled\n ref={ref}\n classes={props.classes}\n open={openBackdrop}\n onClick={handleClose}\n invisible={props.invisible}\n sx={props.sx}\n transitionDuration={props.transitionDuration}\n >\n {props.children}\n </BackdropStyled>\n );\n});\n\nconst BackdropStyled = styled(MuiBackdrop)<BackdropProps>(({ theme, ...args }) => {\n if (args.invisible)\n return {\n backgroundColor: theme.palette.transparent.backdrop,\n backdropFilter: 'blur(0px)',\n };\n\n return null;\n});\n"],"names":["Backdrop","forwardRef","_a","ref","open","onClose","props","__rest","openBackdrop","handleCloseBackdrop","setOpenBackdrop","useBackdrop","useEffect","_jsx","BackdropStyled","classes","onClick","invisible","sx","transitionDuration","children","styled","MuiBackdrop","theme","backgroundColor","palette","transparent","backdrop","backdropFilter"],"mappings":"yJA8Ca,MAAAA,EAAWC,EAAUA,YAAgC,CAACC,EAA6BC,SAA7BC,KAAEA,EAAIC,QAAEA,GAAOH,EAAKI,EAAKC,EAAAA,OAAAL,EAAzB,oBACjE,MAAMM,aAAEA,EAAYC,oBAAEA,EAAmBC,gBAAEA,GAAoBC,EAAAA,UAW/D,OAJAC,EAAAA,WAAU,KACRF,EAAgBN,EAAK,GACpB,CAACA,EAAMM,IAGRG,MAACC,EAAc,CACbX,IAAKA,EACLY,QAAST,EAAMS,QACfX,KAAMI,EACNQ,QAdgB,KAClBP,IACAJ,GAAWA,GAAQ,EAAM,EAavBY,UAAWX,EAAMW,UACjBC,GAAIZ,EAAMY,GACVC,mBAAoBb,EAAMa,mBAAkBC,SAE3Cd,EAAMc,UACQ,IAIfN,EAAiBO,EAAMA,OAACC,WAAPD,EAAoCnB,IAAA,IAAAqB,MAAEA,GAAgBrB,EAC3E,OADyEK,EAAAA,OAAAL,EAAhB,WAChDe,UACA,CACLO,gBAAiBD,EAAME,QAAQC,YAAYC,SAC3CC,eAAgB,aAGb,IAAI"}
@@ -1,7 +1,6 @@
1
1
  import React, { HTMLAttributes } from 'react';
2
+ import { SxProps, Theme } from '@mui/material';
2
3
  import { IconNameProp } from '../icon';
3
- import { SxProps } from '@mui/system';
4
- import { Theme } from '@mui/material/styles';
5
4
  import { Placement } from '../../utils/enum';
6
5
  /**
7
6
  * @interface CardMenuItem
@@ -1 +1 @@
1
- {"version":3,"file":"cardMenu.js","sources":["../../../../../src/components/cardMenu/cardMenu.tsx"],"sourcesContent":["import React, { HTMLAttributes, forwardRef } from 'react';\nimport useWindowSize from '../common/hook/useWindowSize';\nimport {\n List,\n ListItem,\n ListItemButton,\n ListItemIcon,\n ListItemText,\n MenuItem,\n ClickAwayListener,\n Divider,\n} from '@mui/material';\nimport { Icon, IconNameProp } from '../icon';\nimport { Checkbox } from '../checkbox';\nimport { SxProps } from '@mui/system';\nimport { Theme } from '@mui/material/styles';\nimport { Placement } from '../../utils/enum';\nimport { ToggleSwitch } from '../toggleSwitch';\nimport { useCardMenu } from './hooks/useCardMenu';\nimport { PopperStyled } from './styled/popperStyled';\nimport { MenuListStyled } from './styled/menuListStyled';\nimport { DrawerStyled } from './styled/drawerStyled';\n\n/**\n * @interface CardMenuItem\n * @description The interface describing the object that has to be provided to the array property 'items' in CardMenu component.\n * If url is provided the menuItem becomes link.\n */\nexport interface CardMenuItem {\n text: string;\n callback?: () => void;\n disabled?: boolean;\n icon?: IconNameProp;\n isChecked?: boolean;\n url?: string;\n target?: string;\n}\n/**\n * @type CardMenuItemsArray\n * @description Array of CardMenuItem.\n */\nexport type CardMenuItemsArray = Array<CardMenuItem>;\n\n/**\n * @interface CardMenuProps\n * @description Base definition of SkodaFlow CardMenu independent on core implementation.\n * Properties are inherited from HTML Div element.\n */\nexport interface CardMenuProps extends HTMLAttributes<HTMLDivElement> {\n /**\n * If true the drawer is shown.\n */\n open: boolean;\n /**\n * The content of the component.\n */\n items: CardMenuItemsArray;\n /**\n * React useState hook set function used to update the passed items to the component.\n */\n setItems?: React.Dispatch<React.SetStateAction<CardMenuItemsArray>>;\n /**\n * Callback fired when the component requests to be closed.\n */\n onClose: () => void;\n /**\n * An HTML element used to set the position of the popper.\n */\n anchorRef: React.RefObject<HTMLElement>;\n /**\n * If header is provided, a text will be displayed on top of the elements.\n */\n header?: string;\n /**\n * If true, multiple item select will be enabled. Property 'setItems' must be provided in order allowMultiselect to work.\n * Items: CardMenuItemsArray provided to the component must have isChecked propery provided in order allowMultiselect to work..\n */\n allowMultiselect?: boolean;\n /**\n * Callback fired when item is clicked.\n */\n onItemClick?: (itemText: string) => void;\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx?: SxProps<Theme>;\n /**\n * Override or extend the styles applied to the component.\n */\n classes?: object;\n /**\n * Popper placement. Default is 'bottom'.\n */\n placement?: Placement;\n /**\n * If true, a switch button is added to the items allowing to select or deselect all of the items.\n * Property allowMultiselect should be true in order hasToggleSelection to work. Only available for the desktop version of the MenuCard.\n */\n hasToggleSelection?: boolean;\n /**\n * The toggle label displayed when groupToggleSelection is true. Default is \"Select all\".\n */\n toggleLabel?: string;\n /** Renders the popper with border radius */\n rounded?: boolean;\n}\n\n/** @deprecated Use Menu component from @mui/material */\nexport const CardMenu = forwardRef<HTMLDivElement, CardMenuProps>(\n (\n {\n items,\n setItems,\n open,\n header,\n anchorRef,\n allowMultiselect,\n hasToggleSelection,\n onItemClick,\n onClose,\n sx,\n classes,\n placement,\n toggleLabel,\n rounded,\n },\n ref,\n ) => {\n const { isMobile } = useWindowSize();\n const { isToggleChecked, onClickHandler, onToggleChange } = useCardMenu(\n items,\n allowMultiselect,\n setItems,\n onItemClick,\n onClose,\n );\n\n return (\n <>\n {isMobile ? (\n <DrawerStyled\n open={open}\n onClose={onClose}\n anchor=\"bottom\"\n sx={sx}\n ref={ref}\n classes={classes}\n hasHeader={!!header}\n data-testid=\"CardMenu\"\n >\n {header && (\n <div className=\"drawer-header\" data-testid=\"CardMenu.header\">\n {header}\n </div>\n )}\n <List>\n {items.map((item) => {\n return (\n <React.Fragment key={item.text}>\n <ListItem\n data-testid=\"CardMenu.item\"\n data-state={item.disabled ? 'disabled' : undefined}\n disableGutters\n >\n <ListItemButton disabled={item.disabled} onClick={() => onClickHandler(item)}>\n {item.icon && (\n <ListItemIcon>\n <Icon name={item.icon} fontSize=\"small\" />\n </ListItemIcon>\n )}\n <ListItemText primaryTypographyProps={{ noWrap: true }} primary={item.text} />\n {allowMultiselect && (\n <Checkbox checked={item.isChecked} disabled={item.disabled} data-testid=\"CardMenu.check\" />\n )}\n </ListItemButton>\n </ListItem>\n <Divider variant=\"middle\" />\n </React.Fragment>\n );\n })}\n </List>\n </DrawerStyled>\n ) : (\n <PopperStyled\n open={open}\n anchorEl={anchorRef.current}\n placement={placement}\n ref={ref}\n rounded={rounded}\n data-testid=\"CardMenu\"\n >\n <ClickAwayListener onClickAway={onClose}>\n <MenuListStyled allowMultiselect={allowMultiselect} sx={sx} classes={classes}>\n {header && (\n <MenuItem className=\"menu-item-header\" data-testid=\"CardMenu.header\">\n <ListItemText primaryTypographyProps={{ noWrap: true }} primary={header} />\n <ListItemIcon onClick={onClose} data-testid=\"CardMenu.close\">\n <Icon name=\"close\" fontSize=\"small\" />\n </ListItemIcon>\n </MenuItem>\n )}\n {header && <Divider variant=\"middle\" className=\"menu-item-divider\" />}\n {allowMultiselect && hasToggleSelection && (\n <MenuItem className=\"menu-select-all\" data-testid=\"CardMenu.toggle\">\n <ListItemText\n primaryTypographyProps={{ noWrap: true }}\n primary={toggleLabel ? toggleLabel : 'Select all'}\n />\n <ToggleSwitch onChange={onToggleChange} checked={isToggleChecked} compact />\n </MenuItem>\n )}\n\n <div className=\"menu-content-items\">\n {items.map((item) => {\n return (\n <MenuItem\n key={item.text}\n disabled={item.disabled}\n onClick={() => onClickHandler(item)}\n data-testid=\"CardMenu.item\"\n data-state={item.disabled ? 'disabled' : undefined}\n >\n {item.icon && (\n <ListItemIcon>\n <Icon name={item.icon} fontSize=\"small\" />\n </ListItemIcon>\n )}\n <ListItemText primaryTypographyProps={{ noWrap: true }} primary={item.text} />\n {allowMultiselect && (\n <Checkbox checked={item.isChecked} disabled={item.disabled} data-testid=\"CardMenu.check\" />\n )}\n </MenuItem>\n );\n })}\n </div>\n </MenuListStyled>\n </ClickAwayListener>\n </PopperStyled>\n )}\n </>\n );\n },\n);\n"],"names":["CardMenu","forwardRef","items","setItems","open","header","anchorRef","allowMultiselect","hasToggleSelection","onItemClick","onClose","sx","classes","placement","toggleLabel","rounded","ref","isMobile","useWindowSize","isToggleChecked","onClickHandler","onToggleChange","useCardMenu","_jsx","jsx","_Fragment","children","_jsxs","DrawerStyled","anchor","hasHeader","className","List","map","item","jsxs","React","default","Fragment","ListItem","disabled","undefined","disableGutters","ListItemButton","onClick","icon","ListItemIcon","Icon","name","fontSize","ListItemText","primaryTypographyProps","noWrap","primary","text","Checkbox","checked","isChecked","Divider","variant","PopperStyled","anchorEl","current","ClickAwayListener","onClickAway","MenuListStyled","MenuItem","ToggleSwitch","onChange","compact"],"mappings":"2fA4Ga,MAAAA,EAAWC,EAAAA,YACtB,EAEIC,QACAC,WACAC,OACAC,SACAC,YACAC,mBACAC,qBACAC,cACAC,UACAC,KACAC,UACAC,YACAC,cACAC,WAEFC,KAEA,MAAMC,SAAEA,GAAaC,aACfC,gBAAEA,EAAe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.js","sources":["../../../../../src/components/cardMenu/cardMenu.tsx"],"sourcesContent":["import React, { HTMLAttributes, forwardRef } from 'react';\nimport useWindowSize from '../common/hook/useWindowSize';\nimport {\n List,\n ListItem,\n ListItemButton,\n ListItemIcon,\n ListItemText,\n MenuItem,\n ClickAwayListener,\n Divider,\n SxProps,\n Theme,\n} from '@mui/material';\nimport { Icon, IconNameProp } from '../icon';\nimport { Checkbox } from '../checkbox';\nimport { Placement } from '../../utils/enum';\nimport { ToggleSwitch } from '../toggleSwitch';\nimport { useCardMenu } from './hooks/useCardMenu';\nimport { PopperStyled } from './styled/popperStyled';\nimport { MenuListStyled } from './styled/menuListStyled';\nimport { DrawerStyled } from './styled/drawerStyled';\n\n/**\n * @interface CardMenuItem\n * @description The interface describing the object that has to be provided to the array property 'items' in CardMenu component.\n * If url is provided the menuItem becomes link.\n */\nexport interface CardMenuItem {\n text: string;\n callback?: () => void;\n disabled?: boolean;\n icon?: IconNameProp;\n isChecked?: boolean;\n url?: string;\n target?: string;\n}\n/**\n * @type CardMenuItemsArray\n * @description Array of CardMenuItem.\n */\nexport type CardMenuItemsArray = Array<CardMenuItem>;\n\n/**\n * @interface CardMenuProps\n * @description Base definition of SkodaFlow CardMenu independent on core implementation.\n * Properties are inherited from HTML Div element.\n */\nexport interface CardMenuProps extends HTMLAttributes<HTMLDivElement> {\n /**\n * If true the drawer is shown.\n */\n open: boolean;\n /**\n * The content of the component.\n */\n items: CardMenuItemsArray;\n /**\n * React useState hook set function used to update the passed items to the component.\n */\n setItems?: React.Dispatch<React.SetStateAction<CardMenuItemsArray>>;\n /**\n * Callback fired when the component requests to be closed.\n */\n onClose: () => void;\n /**\n * An HTML element used to set the position of the popper.\n */\n anchorRef: React.RefObject<HTMLElement>;\n /**\n * If header is provided, a text will be displayed on top of the elements.\n */\n header?: string;\n /**\n * If true, multiple item select will be enabled. Property 'setItems' must be provided in order allowMultiselect to work.\n * Items: CardMenuItemsArray provided to the component must have isChecked propery provided in order allowMultiselect to work..\n */\n allowMultiselect?: boolean;\n /**\n * Callback fired when item is clicked.\n */\n onItemClick?: (itemText: string) => void;\n /**\n * The system prop that allows defining system overrides as well as additional CSS styles.\n */\n sx?: SxProps<Theme>;\n /**\n * Override or extend the styles applied to the component.\n */\n classes?: object;\n /**\n * Popper placement. Default is 'bottom'.\n */\n placement?: Placement;\n /**\n * If true, a switch button is added to the items allowing to select or deselect all of the items.\n * Property allowMultiselect should be true in order hasToggleSelection to work. Only available for the desktop version of the MenuCard.\n */\n hasToggleSelection?: boolean;\n /**\n * The toggle label displayed when groupToggleSelection is true. Default is \"Select all\".\n */\n toggleLabel?: string;\n /** Renders the popper with border radius */\n rounded?: boolean;\n}\n\n/** @deprecated Use Menu component from @mui/material */\nexport const CardMenu = forwardRef<HTMLDivElement, CardMenuProps>(\n (\n {\n items,\n setItems,\n open,\n header,\n anchorRef,\n allowMultiselect,\n hasToggleSelection,\n onItemClick,\n onClose,\n sx,\n classes,\n placement,\n toggleLabel,\n rounded,\n },\n ref,\n ) => {\n const { isMobile } = useWindowSize();\n const { isToggleChecked, onClickHandler, onToggleChange } = useCardMenu(\n items,\n allowMultiselect,\n setItems,\n onItemClick,\n onClose,\n );\n\n return (\n <>\n {isMobile ? (\n <DrawerStyled\n open={open}\n onClose={onClose}\n anchor=\"bottom\"\n sx={sx}\n ref={ref}\n classes={classes}\n hasHeader={!!header}\n data-testid=\"CardMenu\"\n >\n {header && (\n <div className=\"drawer-header\" data-testid=\"CardMenu.header\">\n {header}\n </div>\n )}\n <List>\n {items.map((item) => {\n return (\n <React.Fragment key={item.text}>\n <ListItem\n data-testid=\"CardMenu.item\"\n data-state={item.disabled ? 'disabled' : undefined}\n disableGutters\n >\n <ListItemButton disabled={item.disabled} onClick={() => onClickHandler(item)}>\n {item.icon && (\n <ListItemIcon>\n <Icon name={item.icon} fontSize=\"small\" />\n </ListItemIcon>\n )}\n <ListItemText primaryTypographyProps={{ noWrap: true }} primary={item.text} />\n {allowMultiselect && (\n <Checkbox checked={item.isChecked} disabled={item.disabled} data-testid=\"CardMenu.check\" />\n )}\n </ListItemButton>\n </ListItem>\n <Divider variant=\"middle\" />\n </React.Fragment>\n );\n })}\n </List>\n </DrawerStyled>\n ) : (\n <PopperStyled\n open={open}\n anchorEl={anchorRef.current}\n placement={placement}\n ref={ref}\n rounded={rounded}\n data-testid=\"CardMenu\"\n >\n <ClickAwayListener onClickAway={onClose}>\n <MenuListStyled allowMultiselect={allowMultiselect} sx={sx} classes={classes}>\n {header && (\n <MenuItem className=\"menu-item-header\" data-testid=\"CardMenu.header\">\n <ListItemText primaryTypographyProps={{ noWrap: true }} primary={header} />\n <ListItemIcon onClick={onClose} data-testid=\"CardMenu.close\">\n <Icon name=\"close\" fontSize=\"small\" />\n </ListItemIcon>\n </MenuItem>\n )}\n {header && <Divider variant=\"middle\" className=\"menu-item-divider\" />}\n {allowMultiselect && hasToggleSelection && (\n <MenuItem className=\"menu-select-all\" data-testid=\"CardMenu.toggle\">\n <ListItemText\n primaryTypographyProps={{ noWrap: true }}\n primary={toggleLabel ? toggleLabel : 'Select all'}\n />\n <ToggleSwitch onChange={onToggleChange} checked={isToggleChecked} compact />\n </MenuItem>\n )}\n\n <div className=\"menu-content-items\">\n {items.map((item) => {\n return (\n <MenuItem\n key={item.text}\n disabled={item.disabled}\n onClick={() => onClickHandler(item)}\n data-testid=\"CardMenu.item\"\n data-state={item.disabled ? 'disabled' : undefined}\n >\n {item.icon && (\n <ListItemIcon>\n <Icon name={item.icon} fontSize=\"small\" />\n </ListItemIcon>\n )}\n <ListItemText primaryTypographyProps={{ noWrap: true }} primary={item.text} />\n {allowMultiselect && (\n <Checkbox checked={item.isChecked} disabled={item.disabled} data-testid=\"CardMenu.check\" />\n )}\n </MenuItem>\n );\n })}\n </div>\n </MenuListStyled>\n </ClickAwayListener>\n </PopperStyled>\n )}\n </>\n );\n },\n);\n"],"names":["CardMenu","forwardRef","items","setItems","open","header","anchorRef","allowMultiselect","hasToggleSelection","onItemClick","onClose","sx","classes","placement","toggleLabel","rounded","ref","isMobile","useWindowSize","isToggleChecked","onClickHandler","onToggleChange","useCardMenu","_jsx","jsx","_Fragment","children","_jsxs","DrawerStyled","anchor","hasHeader","className","List","map","item","jsxs","React","default","Fragment","ListItem","disabled","undefined","disableGutters","ListItemButton","onClick","icon","ListItemIcon","Icon","name","fontSize","ListItemText","primaryTypographyProps","noWrap","primary","text","Checkbox","checked","isChecked","Divider","variant","PopperStyled","anchorEl","current","ClickAwayListener","onClickAway","MenuListStyled","MenuItem","ToggleSwitch","onChange","compact"],"mappings":"2fA4Ga,MAAAA,EAAWC,EAAAA,YACtB,EAEIC,QACAC,WACAC,OACAC,SACAC,YACAC,mBACAC,qBACAC,cACAC,UACAC,KACAC,UACAC,YACAC,cACAC,WAEFC,KAEA,MAAMC,SAAEA,GAAaC,aACfC,gBAAEA,EAAeC,eAAEA,EAAcC,eAAEA,GAAmBC,EAAAA,YAC1DpB,EACAK,EACAJ,EACAM,EACAC,GAGF,OACEa,EAAAC,IAAAC,WAAA,CAAAC,SACGT,EACCU,EAAAA,KAACC,EAAYA,aAAA,CACXxB,KAAMA,EACNM,QAASA,EACTmB,OAAO,SACPlB,GAAIA,EACJK,IAAKA,EACLJ,QAASA,EACTkB,YAAazB,EACD,cAAA,WAEXqB,SAAA,CAAArB,GACCkB,MAAK,MAAA,CAAAQ,UAAU,gBAAe,cAAa,kBAAiBL,SACzDrB,IAGLkB,MAACS,EAAAA,KAAI,CAAAN,SACFxB,EAAM+B,KAAKC,GAERP,EAACQ,KAAAC,EAAKC,QAACC,SACL,CAAAZ,SAAA,CAAAH,EAAAC,IAACe,EAAQA,SAAA,CAAA,cACK,gBAAe,aACfL,EAAKM,SAAW,gBAAaC,EACzCC,gBAAc,EAAAhB,SAEdC,EAACQ,KAAAQ,EAAcA,eAAC,CAAAH,SAAUN,EAAKM,SAAUI,QAAS,IAAMxB,EAAec,GACpER,SAAA,CAAAQ,EAAKW,MACJtB,EAAAA,IAACuB,EAAAA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MAAA,CAAKQ,UAAU,8BACZ7B,EAAM+B,KAAKC,GAERP,OAACuC,EAAQA,SAAA,CAEP1B,SAAUN,EAAKM,SACfI,QAAS,IAAMxB,EAAec,GAAK,cACvB,gBAAe,aACfA,EAAKM,SAAW,gBAAaC,EAExCf,SAAA,CAAAQ,EAAKW,MACJtB,EAAAA,IAACuB,EAAAA,aAAY,CAAApB,SACXH,EAACC,IAAAuB,EAAIA,MAACC,KAAMd,EAAKW,KAAMI,SAAS,YAGpC1B,EAAAA,IAAC2B,EAAAA,aAAa,CAAAC,uBAAwB,CAAEC,QAAQ,GAAQC,QAASnB,EAAKoB,OACrE/C,GACCgB,MAACgC,EAAAA,UAASC,QAAStB,EAAKuB,UAAWjB,SAAUN,EAAKM,SAAQ,cAAc,qBAbrEN,EAAKoB,kBAuBzB"}
@@ -1,3 +1,3 @@
1
- export declare const DrawerStyled: import("@emotion/styled").StyledComponent<import("@mui/material").DrawerProps & import("@mui/system").MUIStyledCommonProps<import("@mui/system").Theme> & {
1
+ export declare const DrawerStyled: import("@emotion/styled").StyledComponent<import("@mui/material").DrawerProps & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
2
2
  hasHeader: boolean;
3
3
  }, {}, {}>;
@@ -1,2 +1,2 @@
1
- "use strict";var e=require("@mui/system"),i=require("@mui/material");const r=e.styled(i.Drawer,{shouldForwardProp:e=>"hasHeader"!==e})((({theme:e,hasHeader:i})=>({"& .MuiPaper-root > .MuiList-root":{fontSize:"16px",fontWeight:400,paddingBottom:"32px",listStyleType:"none",maxHeight:"201px",marginTop:i?"9px":"0px","& > .MuiListItem-root":{lineHeight:"24px",padding:"23px 16px 11px 16px",display:"flex","&:hover":{background:e.palette.surface.primary},"& > .MuiListItemIcon-root":{display:"inline-block",lineHeight:"21px",minWidth:"unset",width:"20px",marginRight:"8px","& > .MuiIcon-root":{color:e.palette.text.primary,display:"inline"}},"& > .MuiTypography-root":{flex:1}}},".MuiPaper-root > .drawer-header":{padding:"16px 16px 0px 16px",fontWeight:"bold",lineHeight:"24px",fontSize:"20px",wordBreak:"break-all"},"& > .MuiPaper-root":{borderTopLeftRadius:"16px",borderTopRightRadius:"16px"}})));exports.DrawerStyled=r;
1
+ "use strict";var e=require("@mui/material/styles"),i=require("@mui/material");const r=e.styled(i.Drawer,{shouldForwardProp:e=>"hasHeader"!==e})((({theme:e,hasHeader:i})=>({"& .MuiPaper-root > .MuiList-root":{fontSize:"16px",fontWeight:400,paddingBottom:"32px",listStyleType:"none",maxHeight:"201px",marginTop:i?"9px":"0px","& > .MuiListItem-root":{lineHeight:"24px",padding:"23px 16px 11px 16px",display:"flex","&:hover":{background:e.palette.surface.primary},"& > .MuiListItemIcon-root":{display:"inline-block",lineHeight:"21px",minWidth:"unset",width:"20px",marginRight:"8px","& > .MuiIcon-root":{color:e.palette.text.primary,display:"inline"}},"& > .MuiTypography-root":{flex:1}}},".MuiPaper-root > .drawer-header":{padding:"16px 16px 0px 16px",fontWeight:"bold",lineHeight:"24px",fontSize:"20px",wordBreak:"break-all"},"& > .MuiPaper-root":{borderTopLeftRadius:"16px",borderTopRightRadius:"16px"}})));exports.DrawerStyled=r;
2
2
  //# sourceMappingURL=drawerStyled.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"drawerStyled.js","sources":["../../../../../../src/components/cardMenu/styled/drawerStyled.tsx"],"sourcesContent":["import { styled } from '@mui/system';\nimport { Drawer } from '@mui/material';\n\nexport const DrawerStyled = styled(Drawer, {\n shouldForwardProp: (prop) => prop !== 'hasHeader',\n})<{ hasHeader: boolean }>(({ theme, hasHeader }) => {\n return {\n '& .MuiPaper-root > .MuiList-root': {\n fontSize: '16px',\n fontWeight: 400,\n paddingBottom: '32px',\n listStyleType: 'none',\n maxHeight: '201px',\n marginTop: hasHeader ? '9px' : '0px',\n '& > .MuiListItem-root': {\n lineHeight: '24px',\n padding: '23px 16px 11px 16px',\n display: 'flex',\n '&:hover': {\n background: theme.palette.surface.primary,\n },\n '& > .MuiListItemIcon-root': {\n display: 'inline-block',\n lineHeight: '21px',\n minWidth: 'unset',\n width: '20px',\n marginRight: '8px',\n '& > .MuiIcon-root': {\n color: theme.palette.text.primary,\n display: 'inline',\n },\n },\n '& > .MuiTypography-root': {\n flex: 1,\n },\n },\n },\n '.MuiPaper-root > .drawer-header': {\n padding: '16px 16px 0px 16px',\n fontWeight: 'bold',\n lineHeight: '24px',\n fontSize: '20px',\n wordBreak: 'break-all',\n },\n '& > .MuiPaper-root': {\n borderTopLeftRadius: '16px',\n borderTopRightRadius: '16px',\n },\n };\n});\n"],"names":["DrawerStyled","styled","Drawer","shouldForwardProp","prop","theme","hasHeader","fontSize","fontWeight","paddingBottom","listStyleType","maxHeight","marginTop","lineHeight","padding","display","background","palette","surface","primary","minWidth","width","marginRight","color","text","flex","wordBreak","borderTopLeftRadius","borderTopRightRadius"],"mappings":"qEAGa,MAAAA,EAAeC,EAAMA,OAACC,SAAQ,CACzCC,kBAAoBC,GAAkB,cAATA,GADHH,EAED,EAAGI,QAAOC,gBAC5B,CACL,mCAAoC,CAClCC,SAAU,OACVC,WAAY,IACZC,cAAe,OACfC,cAAe,OACfC,UAAW,QACXC,UAAWN,EAAY,MAAQ,MAC/B,wBAAyB,CACvBO,WAAY,OACZC,QAAS,sBACTC,QAAS,OACT,UAAW,CACTC,WAAYX,EAAMY,QAAQC,QAAQC,SAEpC,4BAA6B,CAC3BJ,QAAS,eACTF,WAAY,OACZO,SAAU,QACVC,MAAO,OACPC,YAAa,MACb,oBAAqB,CACnBC,MAAOlB,EAAMY,QAAQO,KAAKL,QAC1BJ,QAAS,WAGb,0BAA2B,CACzBU,KAAM,KAIZ,kCAAmC,CACjCX,QAAS,qBACTN,WAAY,OACZK,WAAY,OACZN,SAAU,OACVmB,UAAW,aAEb,qBAAsB,CACpBC,oBAAqB,OACrBC,qBAAsB"}
1
+ {"version":3,"file":"drawerStyled.js","sources":["../../../../../../src/components/cardMenu/styled/drawerStyled.tsx"],"sourcesContent":["import { styled } from '@mui/material/styles';\nimport { Drawer } from '@mui/material';\n\nexport const DrawerStyled = styled(Drawer, {\n shouldForwardProp: (prop) => prop !== 'hasHeader',\n})<{ hasHeader: boolean }>(({ theme, hasHeader }) => {\n return {\n '& .MuiPaper-root > .MuiList-root': {\n fontSize: '16px',\n fontWeight: 400,\n paddingBottom: '32px',\n listStyleType: 'none',\n maxHeight: '201px',\n marginTop: hasHeader ? '9px' : '0px',\n '& > .MuiListItem-root': {\n lineHeight: '24px',\n padding: '23px 16px 11px 16px',\n display: 'flex',\n '&:hover': {\n background: theme.palette.surface.primary,\n },\n '& > .MuiListItemIcon-root': {\n display: 'inline-block',\n lineHeight: '21px',\n minWidth: 'unset',\n width: '20px',\n marginRight: '8px',\n '& > .MuiIcon-root': {\n color: theme.palette.text.primary,\n display: 'inline',\n },\n },\n '& > .MuiTypography-root': {\n flex: 1,\n },\n },\n },\n '.MuiPaper-root > .drawer-header': {\n padding: '16px 16px 0px 16px',\n fontWeight: 'bold',\n lineHeight: '24px',\n fontSize: '20px',\n wordBreak: 'break-all',\n },\n '& > .MuiPaper-root': {\n borderTopLeftRadius: '16px',\n borderTopRightRadius: '16px',\n },\n };\n});\n"],"names":["DrawerStyled","styled","Drawer","shouldForwardProp","prop","theme","hasHeader","fontSize","fontWeight","paddingBottom","listStyleType","maxHeight","marginTop","lineHeight","padding","display","background","palette","surface","primary","minWidth","width","marginRight","color","text","flex","wordBreak","borderTopLeftRadius","borderTopRightRadius"],"mappings":"8EAGa,MAAAA,EAAeC,EAAMA,OAACC,SAAQ,CACzCC,kBAAoBC,GAAkB,cAATA,GADHH,EAED,EAAGI,QAAOC,gBAC5B,CACL,mCAAoC,CAClCC,SAAU,OACVC,WAAY,IACZC,cAAe,OACfC,cAAe,OACfC,UAAW,QACXC,UAAWN,EAAY,MAAQ,MAC/B,wBAAyB,CACvBO,WAAY,OACZC,QAAS,sBACTC,QAAS,OACT,UAAW,CACTC,WAAYX,EAAMY,QAAQC,QAAQC,SAEpC,4BAA6B,CAC3BJ,QAAS,eACTF,WAAY,OACZO,SAAU,QACVC,MAAO,OACPC,YAAa,MACb,oBAAqB,CACnBC,MAAOlB,EAAMY,QAAQO,KAAKL,QAC1BJ,QAAS,WAGb,0BAA2B,CACzBU,KAAM,KAIZ,kCAAmC,CACjCX,QAAS,qBACTN,WAAY,OACZK,WAAY,OACZN,SAAU,OACVmB,UAAW,aAEb,qBAAsB,CACpBC,oBAAqB,OACrBC,qBAAsB"}
@@ -1,4 +1,4 @@
1
- export declare const PopperStyled: import("@emotion/styled").StyledComponent<import("@mui/base").PopperOwnProps & Omit<any, keyof import("@mui/base").PopperOwnProps> & import("@mui/system").MUIStyledCommonProps<import("@mui/system").Theme> & {
1
+ export declare const PopperStyled: import("@emotion/styled").StyledComponent<import("@mui/material").PopperProps & import("react").RefAttributes<HTMLDivElement> & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
2
2
  theme?: any;
3
3
  isMobile?: boolean;
4
4
  rounded?: boolean;
@@ -1,2 +1,2 @@
1
- "use strict";var e=require("@mui/system"),r=require("@mui/base");const d=e.styled(r.Popper,{shouldForwardProp:e=>"rounded"!==e})((({theme:e,rounded:r})=>({zIndex:"100",background:e.palette.background.primary,"& > *":{borderRadius:r?"4px":void 0}})));exports.PopperStyled=d;
1
+ "use strict";var r=require("@mui/material/styles"),e=require("@mui/material");const d=r.styled(e.Popper,{shouldForwardProp:r=>"rounded"!==r})((({theme:r,rounded:e})=>({zIndex:"100",background:r.palette.background.primary,"& > *":{borderRadius:e?"4px":void 0}})));exports.PopperStyled=d;
2
2
  //# sourceMappingURL=popperStyled.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"popperStyled.js","sources":["../../../../../../src/components/cardMenu/styled/popperStyled.tsx"],"sourcesContent":["import { styled } from '@mui/system';\nimport { Popper } from '@mui/base';\n\nexport const PopperStyled = styled(Popper, {\n shouldForwardProp: (propName) => propName !== 'rounded',\n})<{\n theme?: any;\n isMobile?: boolean;\n rounded?: boolean;\n}>(({ theme, rounded }) => {\n return {\n zIndex: '100',\n background: theme.palette.background.primary,\n '& > *': {\n borderRadius: rounded ? '4px' : undefined,\n },\n };\n});\n"],"names":["PopperStyled","styled","Popper","shouldForwardProp","propName","theme","rounded","zIndex","background","palette","primary","borderRadius","undefined"],"mappings":"iEAGa,MAAAA,EAAeC,EAAMA,OAACC,SAAQ,CACzCC,kBAAoBC,GAA0B,YAAbA,GADPH,EAMzB,EAAGI,QAAOC,cACJ,CACLC,OAAQ,MACRC,WAAYH,EAAMI,QAAQD,WAAWE,QACrC,QAAS,CACPC,aAAcL,EAAU,WAAQM"}
1
+ {"version":3,"file":"popperStyled.js","sources":["../../../../../../src/components/cardMenu/styled/popperStyled.tsx"],"sourcesContent":["import { styled } from '@mui/material/styles';\nimport { Popper } from '@mui/material';\n\nexport const PopperStyled = styled(Popper, {\n shouldForwardProp: (propName) => propName !== 'rounded',\n})<{\n theme?: any;\n isMobile?: boolean;\n rounded?: boolean;\n}>(({ theme, rounded }) => {\n return {\n zIndex: '100',\n background: theme.palette.background.primary,\n '& > *': {\n borderRadius: rounded ? '4px' : undefined,\n },\n };\n});\n"],"names":["PopperStyled","styled","Popper","shouldForwardProp","propName","theme","rounded","zIndex","background","palette","primary","borderRadius","undefined"],"mappings":"8EAGa,MAAAA,EAAeC,EAAMA,OAACC,SAAQ,CACzCC,kBAAoBC,GAA0B,YAAbA,GADPH,EAMzB,EAAGI,QAAOC,cACJ,CACLC,OAAQ,MACRC,WAAYH,EAAMI,QAAQD,WAAWE,QACrC,QAAS,CACPC,aAAcL,EAAU,WAAQM"}
@@ -1,2 +1,2 @@
1
- "use strict";var e=require("tslib"),r=require("react/jsx-runtime"),s=require("react"),o=require("./hooks.js"),n=require("@mui/system"),t=require("@mui/material"),i=require("../icon/stroke/ChevronLeftIcon.js"),a=require("../icon/stroke/ChevronRightIcon.js"),c=require("../icon/stroke/ArrowLeftIcon.js"),l=require("../icon/stroke/ArrowRightIcon.js"),u=require("../../materialui/button/interactive.js");exports.CarouselNavigation=function({carousel:d,peekEffect:b=!1,prevButtonProps:g,prevIconProps:p,PrevIconComponent:j,nextButtonProps:x,nextIconProps:m,NextIconComponent:f,arrows:v=!0,onBackground:C=!1}){const I=o.useCarousel(),h=d||I,k="fade"!==(null==h?void 0:h.originalParams.effect)&&b,O=n.useTheme(),q=t.useMediaQuery(O.breakpoints.up("md")),P=g||{},{sx:y}=P,M=e.__rest(P,["sx"]),B=x||{},{sx:L}=B,w=e.__rest(B,["sx"]),[E,A]=o.useCarouselPeekEffect(h),N=j||(v?c.ArrowLeftIcon:i.ChevronLeftIcon),R=f||(v?l.ArrowRightIcon:a.ChevronRightIcon),_=s.useMemo((()=>Object.assign(Object.assign({position:"absolute",zIndex:"100",top:"50%",mt:"-22px"},u.getInteractiveStyle({color:"text.primary",borderColor:C?"transparent.transparent":"onSurface.os600",backgroundColor:C?"transparent.transparent":"surface.primary"},{backgroundColor:"surface.secondary"})),{"&.Mui-disabled":{color:"disabled.tertiary",borderColor:"disabled.primary",backgroundColor:C?"transparent.transparent":"disabled.secondary"}})),[]);return r.jsxs(r.Fragment,{children:[r.jsx(t.IconButton,Object.assign({disabled:h&&!h.originalParams.loop&&h.isBeginning,onClick:()=>{null==h||h.slidePrev(),k&&E&&A("reset")},onMouseEnter:()=>q&&k&&A("prev"),onMouseLeave:()=>k&&E&&A("reset"),sx:Object.assign(Object.assign(Object.assign({},_),{left:"16px"}),y),"aria-label":"Previous slide","aria-controls":"carousel",color:"surface"},M,{children:"rtl"===O.direction?r.jsx(R,Object.assign({},p)):r.jsx(N,Object.assign({},p))})),r.jsx(t.IconButton,Object.assign({disabled:h&&!h.originalParams.loop&&h.isEnd,onClick:()=>{null==h||h.slideNext(),k&&E&&A("reset")},onMouseEnter:()=>q&&k&&A("next"),onMouseLeave:()=>k&&E&&A("reset"),sx:Object.assign(Object.assign(Object.assign({},_),{right:"16px"}),L),"aria-label":"Next slide","aria-controls":"carousel",color:"surface"},w,{children:"rtl"===O.direction?r.jsx(N,Object.assign({},m)):r.jsx(R,Object.assign({},m))}))]})};
1
+ "use strict";var e=require("tslib"),r=require("react/jsx-runtime"),s=require("react"),o=require("./hooks.js"),n=require("@mui/material"),t=require("../icon/stroke/ChevronLeftIcon.js"),a=require("../icon/stroke/ChevronRightIcon.js"),i=require("../icon/stroke/ArrowLeftIcon.js"),c=require("../icon/stroke/ArrowRightIcon.js"),l=require("../../materialui/button/interactive.js");exports.CarouselNavigation=function({carousel:u,peekEffect:d=!1,prevButtonProps:x,prevIconProps:p,PrevIconComponent:g,nextButtonProps:b,nextIconProps:j,NextIconComponent:m,arrows:f=!0,onBackground:v=!1}){const h=o.useCarousel(),I=u||h,C="fade"!==(null==I?void 0:I.originalParams.effect)&&d,k=n.useTheme(),O=n.useMediaQuery(k.breakpoints.up("md")),P=x||{},{sx:q}=P,y=e.__rest(P,["sx"]),M=b||{},{sx:w}=M,B=e.__rest(M,["sx"]),[L,E]=o.useCarouselPeekEffect(I),A=g||(f?i.ArrowLeftIcon:t.ChevronLeftIcon),N=m||(f?c.ArrowRightIcon:a.ChevronRightIcon),R=s.useMemo((()=>Object.assign(Object.assign({position:"absolute",zIndex:"100",top:"50%",mt:"-22px",width:{xs:"32px",md:"40px",xl:"44px"},height:{xs:"32px",md:"40px",xl:"44px"},"& .MuiSvgIcon-root":{fontSize:{xs:"17px",xl:"20px"}}},l.getInteractiveStyle({color:"text.primary",borderColor:v?"transparent.transparent":"onSurface.os100",backgroundColor:v?"transparent.transparent":"surface.primary"},{backgroundColor:"surface.secondary"})),{"&.Mui-disabled":{color:"disabled.tertiary",borderColor:v?"transparent.transparent":"disabled.secondary",backgroundColor:v?"transparent.transparent":"disabled.secondary"}})),[]);return r.jsxs(r.Fragment,{children:[r.jsx(n.IconButton,Object.assign({disabled:I&&!I.originalParams.loop&&I.isBeginning,onClick:()=>{null==I||I.slidePrev(),C&&L&&E("reset")},onMouseEnter:()=>O&&C&&E("prev"),onMouseLeave:()=>C&&L&&E("reset"),sx:Object.assign(Object.assign(Object.assign({},R),{left:"16px"}),q),"aria-label":"Previous slide","aria-controls":"carousel",color:"surface",size:"medium"},y,{children:"rtl"===k.direction?r.jsx(N,Object.assign({},p)):r.jsx(A,Object.assign({},p))})),r.jsx(n.IconButton,Object.assign({disabled:I&&!I.originalParams.loop&&I.isEnd,onClick:()=>{null==I||I.slideNext(),C&&L&&E("reset")},onMouseEnter:()=>O&&C&&E("next"),onMouseLeave:()=>C&&L&&E("reset"),sx:Object.assign(Object.assign(Object.assign({},R),{right:"16px"}),w),"aria-label":"Next slide","aria-controls":"carousel",color:"surface"},B,{children:"rtl"===k.direction?r.jsx(A,Object.assign({},j)):r.jsx(N,Object.assign({},j))}))]})};
2
2
  //# sourceMappingURL=navigation.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"navigation.js","sources":["../../../../../src/components/carousel/navigation.tsx"],"sourcesContent":["import React, { useMemo, ElementType } from 'react';\nimport { useCarousel, useCarouselPeekEffect } from './hooks';\nimport { useTheme } from '@mui/system';\nimport { CSSObject, IconButton, IconButtonProps, SvgIconProps, useMediaQuery } from '@mui/material';\nimport type { Swiper as CarouselInstance } from 'swiper';\nimport { ChevronLeftIcon } from '@/src/components/icon/stroke/ChevronLeftIcon';\nimport { ChevronRightIcon } from '@/src/components/icon/stroke/ChevronRightIcon';\nimport { ArrowLeftIcon } from '@/src/components/icon/stroke/ArrowLeftIcon';\nimport { ArrowRightIcon } from '@/src/components/icon/stroke/ArrowRightIcon';\nimport { getInteractiveStyle } from '@/src/materialui/button/interactive';\n\nexport interface CarouselNavigationProps {\n /**\n * Optional Carousel instance from useCarouselInstance hook\n */\n carousel?: CarouselInstance;\n /**\n * Enable/disable peek effect on hover\n * @default: false\n */\n peekEffect?: boolean;\n /**\n * Previous Slide IconButton\n */\n prevButtonProps?: Partial<IconButtonProps>;\n /**\n * Previous icon props\n */\n prevIconProps?: SvgIconProps;\n /**\n * Previous icon node\n */\n PrevIconComponent?: ElementType<SvgIconProps>;\n /**\n * Next Slide IconButton\n */\n nextButtonProps?: Partial<IconButtonProps>;\n /**\n * Previous icon props\n */\n nextIconProps?: SvgIconProps;\n /**\n * Next icon node\n */\n NextIconComponent?: ElementType<SvgIconProps>;\n /**\n * Replaces Chevrons with Arrows\n * @default true\n */\n arrows?: boolean;\n /**\n * Enable if placing on a plain background (not on top of an image/video)\n * @default false\n */\n onBackground?: boolean;\n}\n\n/**\n * Left & Right navigation arrows\n */\nexport function CarouselNavigation({\n carousel: carouselProp,\n peekEffect: propPeekEffect = false,\n prevButtonProps,\n prevIconProps,\n PrevIconComponent,\n nextButtonProps,\n nextIconProps,\n NextIconComponent,\n arrows = true,\n onBackground = false,\n}: CarouselNavigationProps) {\n const carouselHook = useCarousel();\n const carousel = carouselProp || carouselHook;\n const peekEffect = carousel?.originalParams.effect !== 'fade' && propPeekEffect;\n const theme = useTheme();\n const upMD = useMediaQuery(theme.breakpoints.up('md'));\n const { sx: prevSx, ...restPrev } = prevButtonProps || {};\n const { sx: nextSx, ...restNext } = nextButtonProps || {};\n const [peek, setPeek] = useCarouselPeekEffect(carousel);\n const PrevIcon = PrevIconComponent || (arrows ? ArrowLeftIcon : ChevronLeftIcon);\n const NextIcon = NextIconComponent || (arrows ? ArrowRightIcon : ChevronRightIcon);\n\n // shared style between buttons\n const sharedSx = useMemo<CSSObject>(\n () => ({\n // absolute inside the carousel position\n position: 'absolute',\n zIndex: '100',\n top: '50%',\n // manual v-align, half the icon size\n mt: '-22px',\n // highlight border\n ...getInteractiveStyle(\n {\n color: 'text.primary',\n borderColor: onBackground ? 'transparent.transparent' : 'onSurface.os600',\n backgroundColor: onBackground ? 'transparent.transparent' : 'surface.primary',\n },\n {\n backgroundColor: 'surface.secondary',\n },\n ),\n // disabled state\n '&.Mui-disabled': {\n color: 'disabled.tertiary',\n borderColor: 'disabled.primary',\n backgroundColor: onBackground ? 'transparent.transparent' : 'disabled.secondary',\n },\n }),\n [],\n );\n\n return (\n <>\n <IconButton\n disabled={carousel && !carousel.originalParams.loop && carousel.isBeginning}\n onClick={() => {\n carousel?.slidePrev();\n peekEffect && peek && setPeek('reset');\n }}\n onMouseEnter={() => upMD && peekEffect && setPeek('prev')}\n onMouseLeave={() => peekEffect && peek && setPeek('reset')}\n sx={{\n ...sharedSx,\n left: '16px',\n ...prevSx,\n }}\n aria-label=\"Previous slide\"\n aria-controls=\"carousel\"\n color=\"surface\"\n {...restPrev}\n >\n {theme.direction === 'rtl' ? <NextIcon {...prevIconProps} /> : <PrevIcon {...prevIconProps} />}\n </IconButton>\n <IconButton\n disabled={carousel && !carousel.originalParams.loop && carousel.isEnd}\n onClick={() => {\n carousel?.slideNext();\n peekEffect && peek && setPeek('reset');\n }}\n onMouseEnter={() => upMD && peekEffect && setPeek('next')}\n onMouseLeave={() => peekEffect && peek && setPeek('reset')}\n sx={{\n ...sharedSx,\n right: '16px',\n ...nextSx,\n }}\n aria-label=\"Next slide\"\n aria-controls=\"carousel\"\n color=\"surface\"\n {...restNext}\n >\n {theme.direction === 'rtl' ? <PrevIcon {...nextIconProps} /> : <NextIcon {...nextIconProps} />}\n </IconButton>\n </>\n );\n}\n"],"names":["carousel","carouselProp","peekEffect","propPeekEffect","prevButtonProps","prevIconProps","PrevIconComponent","nextButtonProps","nextIconProps","NextIconComponent","arrows","onBackground","carouselHook","useCarousel","originalParams","effect","theme","useTheme","upMD","useMediaQuery","breakpoints","up","_a","sx","prevSx","restPrev","__rest","_b","nextSx","restNext","peek","setPeek","useCarouselPeekEffect","PrevIcon","ArrowLeftIcon","ChevronLeftIcon","NextIcon","ArrowRightIcon","ChevronRightIcon","sharedSx","useMemo","Object","assign","position","zIndex","top","mt","getInteractiveStyle","color","borderColor","backgroundColor","_jsxs","_jsx","IconButton","disabled","loop","isBeginning","onClick","slidePrev","onMouseEnter","onMouseLeave","left","children","direction","isEnd","slideNext","right"],"mappings":"2aA4DgB,UACdA,SAAUC,EACVC,WAAYC,GAAiB,EAAKC,gBAClCA,EAAeC,cACfA,EAAaC,kB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H,GACH,CAAAsB,KAAM,SACHrC,GAEM,aAAA,iCACG,WACdwB,MAAM,WACFvB,EAAQ,CAAAqC,SAES,QAApB9C,EAAM+C,UAAsBX,EAAAA,IAAChB,EAAaK,OAAAC,OAAA,CAAA,EAAArC,IAAoB+C,EAAAA,IAACnB,mBAAa5B,OAE/E+C,EAAAA,IAACC,EAAAA,WACCZ,OAAAC,OAAA,CAAAY,SAAUtD,IAAaA,EAASc,eAAeyC,MAAQvD,EAASgE,MAChEP,QAAS,KACPzD,SAAAA,EAAUiE,YACV/D,GAAc4B,GAAQC,EAAQ,QAAQ,EAExC4B,aAAc,IAAMzC,GAAQhB,GAAc6B,EAAQ,QAClD6B,aAAc,IAAM1D,GAAc4B,GAAQC,EAAQ,SAClDR,GAAEkB,OAAAC,OAAAD,OAAAC,OAAAD,OAAAC,OAAA,CAAA,EACGH,GAAQ,CACX2B,MAAO,SACJtC,GAEM,aAAA,aACG,gBAAA,WACdoB,MAAM,WACFnB,EAEH,CAAAiC,SAAoB,QAApB9C,EAAM+C,UAAsBX,EAAAA,IAACnB,EAAQQ,OAAAC,OAAA,CAAA,EAAKlC,IAAoB4C,EAAAA,IAAChB,mBAAa5B,SAIrF"}
1
+ {"version":3,"file":"navigation.js","sources":["../../../../../src/components/carousel/navigation.tsx"],"sourcesContent":["import React, { useMemo, ElementType } from 'react';\nimport { useCarousel, useCarouselPeekEffect } from './hooks';\nimport { useTheme, IconButton, IconButtonProps, SvgIconProps, useMediaQuery } from '@mui/material';\nimport type { Swiper as CarouselInstance } from 'swiper';\nimport { ChevronLeftIcon } from '@/src/components/icon/stroke/ChevronLeftIcon';\nimport { ChevronRightIcon } from '@/src/components/icon/stroke/ChevronRightIcon';\nimport { ArrowLeftIcon } from '@/src/components/icon/stroke/ArrowLeftIcon';\nimport { ArrowRightIcon } from '@/src/components/icon/stroke/ArrowRightIcon';\nimport { getInteractiveStyle } from '@/src/materialui/button/interactive';\n\nexport interface CarouselNavigationProps {\n /**\n * Optional Carousel instance from useCarouselInstance hook\n */\n carousel?: CarouselInstance;\n /**\n * Enable/disable peek effect on hover\n * @default: false\n */\n peekEffect?: boolean;\n /**\n * Previous Slide IconButton\n */\n prevButtonProps?: Partial<IconButtonProps>;\n /**\n * Previous icon props\n */\n prevIconProps?: SvgIconProps;\n /**\n * Previous icon node\n */\n PrevIconComponent?: ElementType<SvgIconProps>;\n /**\n * Next Slide IconButton\n */\n nextButtonProps?: Partial<IconButtonProps>;\n /**\n * Previous icon props\n */\n nextIconProps?: SvgIconProps;\n /**\n * Next icon node\n */\n NextIconComponent?: ElementType<SvgIconProps>;\n /**\n * Replaces Chevrons with Arrows\n * @default true\n */\n arrows?: boolean;\n /**\n * Enable if placing on a plain background (not on top of an image/video)\n * @default false\n */\n onBackground?: boolean;\n}\n\n/**\n * Left & Right navigation arrows\n */\nexport function CarouselNavigation({\n carousel: carouselProp,\n peekEffect: propPeekEffect = false,\n prevButtonProps,\n prevIconProps,\n PrevIconComponent,\n nextButtonProps,\n nextIconProps,\n NextIconComponent,\n arrows = true,\n onBackground = false,\n}: CarouselNavigationProps) {\n const carouselHook = useCarousel();\n const carousel = carouselProp || carouselHook;\n const peekEffect = carousel?.originalParams.effect !== 'fade' && propPeekEffect;\n const theme = useTheme();\n const upMD = useMediaQuery(theme.breakpoints.up('md'));\n const { sx: prevSx, ...restPrev } = prevButtonProps || {};\n const { sx: nextSx, ...restNext } = nextButtonProps || {};\n const [peek, setPeek] = useCarouselPeekEffect(carousel);\n const PrevIcon = PrevIconComponent || (arrows ? ArrowLeftIcon : ChevronLeftIcon);\n const NextIcon = NextIconComponent || (arrows ? ArrowRightIcon : ChevronRightIcon);\n\n // shared style between buttons\n const sharedSx = useMemo(\n () => ({\n // absolute inside the carousel position\n position: 'absolute',\n zIndex: '100',\n top: '50%',\n // manual v-align, half the icon size\n mt: '-22px',\n // responsive\n width: { xs: '32px', md: '40px', xl: '44px' },\n height: { xs: '32px', md: '40px', xl: '44px' },\n '& .MuiSvgIcon-root': {\n fontSize: { xs: '17px', xl: '20px' },\n },\n // highlight border\n ...getInteractiveStyle(\n {\n color: 'text.primary',\n borderColor: onBackground ? 'transparent.transparent' : 'onSurface.os100',\n backgroundColor: onBackground ? 'transparent.transparent' : 'surface.primary',\n },\n {\n backgroundColor: 'surface.secondary',\n },\n ),\n // disabled state\n '&.Mui-disabled': {\n color: 'disabled.tertiary',\n borderColor: onBackground ? 'transparent.transparent' : 'disabled.secondary',\n backgroundColor: onBackground ? 'transparent.transparent' : 'disabled.secondary',\n },\n }),\n [],\n );\n\n return (\n <>\n <IconButton\n disabled={carousel && !carousel.originalParams.loop && carousel.isBeginning}\n onClick={() => {\n carousel?.slidePrev();\n peekEffect && peek && setPeek('reset');\n }}\n onMouseEnter={() => upMD && peekEffect && setPeek('prev')}\n onMouseLeave={() => peekEffect && peek && setPeek('reset')}\n sx={{\n ...sharedSx,\n left: '16px',\n ...prevSx,\n }}\n aria-label=\"Previous slide\"\n aria-controls=\"carousel\"\n color=\"surface\"\n size=\"medium\"\n {...restPrev}\n >\n {theme.direction === 'rtl' ? <NextIcon {...prevIconProps} /> : <PrevIcon {...prevIconProps} />}\n </IconButton>\n <IconButton\n disabled={carousel && !carousel.originalParams.loop && carousel.isEnd}\n onClick={() => {\n carousel?.slideNext();\n peekEffect && peek && setPeek('reset');\n }}\n onMouseEnter={() => upMD && peekEffect && setPeek('next')}\n onMouseLeave={() => peekEffect && peek && setPeek('reset')}\n sx={{\n ...sharedSx,\n right: '16px',\n ...nextSx,\n }}\n aria-label=\"Next slide\"\n aria-controls=\"carousel\"\n color=\"surface\"\n {...restNext}\n >\n {theme.direction === 'rtl' ? <PrevIcon {...nextIconProps} /> : <NextIcon {...nextIconProps} />}\n </IconButton>\n </>\n );\n}\n"],"names":["carousel","carouselProp","peekEffect","propPeekEffect","prevButtonProps","prevIconProps","PrevIconComponent","nextButtonProps","nextIconProps","NextIconComponent","arrows","onBackground","carouselHook","useCarousel","originalParams","effect","theme","useTheme","upMD","useMediaQuery","breakpoints","up","_a","sx","prevSx","restPrev","__rest","_b","nextSx","restNext","peek","setPeek","useCarouselPeekEffect","PrevIcon","ArrowLeftIcon","ChevronLeftIcon","NextIcon","ArrowRightIcon","ChevronRightIcon","sharedSx","useMemo","Object","assign","position","zIndex","top","mt","width","xs","md","xl","height","fontSize","getInteractiveStyle","color","borderColor","backgroundColor","_jsxs","_jsx","IconButton","disabled","loop","isBeginning","onClick","slidePrev","onMouseEnter","onMouseLeave","left","size","children","direction","jsx","isEnd","slideNext","right"],"mappings":"kZA2DgB,UACdA,SAAUC,EACVC,WAAYC,GAAiB,EAAKC,gBAClCA,EAAeC,cACfA,EAAaC,kBACbA,EAAiBC,gBACjBA,EAAeC,cACfA,EAAaC,kBACbA,EAAiBC,OACjBA,GAAS,EAAIC,aACbA,GAAe,IAEf,MAAMC,EAAeC,EAAAA,cACfb,EAAWC,GAAgBW,EAC3BV,EAAiD,UAApCF,aAAA,EAAAA,EAAUc,eAAeC,SAAqBZ,EAC3Da,EAAQC,EAAAA,WACRC,EAAOC,EAAAA,cAAcH,EAAMI,YAAYC,GAAG,OAC1CC,EAA8BlB,GAAmB,IAA/CmB,GAAIC,KAAWC,EAAjBC,EAAAA,OAAAJ,EAAA,CAAA,OACAK,EAA8BpB,GAAmB,IAA/CgB,GAAIK,KAAWC,EAAjBH,EAAAA,OAAAC,EAAA,CAAA,QACCG,EAAMC,GAAWC,EAAAA,sBAAsBhC,GACxCiC,EAAW3B,IAAsBI,EAASwB,EAAAA,cAAgBC,EAAAA,iBAC1DC,EAAW3B,IAAsBC,EAAS2B,EAAAA,eAAiBC,EAAAA,kBAG3DC,EAAWC,EAAAA,SACf,IAAMC,OAAAC,OAAAD,OAAAC,OAAA,CAEJC,SAAU,WACVC,OAAQ,MACRC,IAAK,MAELC,GAAI,QAEJC,MAAO,CAAEC,GAAI,OAAQC,GAAI,OAAQC,GAAI,QACrCC,OAAQ,CAAEH,GAAI,OAAQC,GAAI,OAAQC,GAAI,QACtC,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AAAwC,SAAoB,QAApBrD,EAAMsD,UAAsBZ,EAAAA,IAACzB,EAAQQ,OAAAC,OAAA,CAAA,EAAKlC,IAAoBkD,EAAAA,IAACtB,mBAAa5B,SAIrF"}
@@ -9,10 +9,14 @@ export interface CarouselPaginationVariantProps extends Omit<BoxProps<ElementTyp
9
9
  }
10
10
  export interface CarouselPaginationDotsProps extends CarouselPaginationVariantProps {
11
11
  variant?: 'dots';
12
+ /**
13
+ * Properties applied to wrapper of dots
14
+ */
15
+ dotsWrapperProps?: BoxProps<ElementType>;
12
16
  /**
13
17
  * Properties applied to each dot
14
18
  */
15
- dotProps?: Partial<BoxProps<ElementType>>;
19
+ dotProps?: BoxProps<ElementType>;
16
20
  }
17
21
  export interface CarouselPaginationFractionProps extends CarouselPaginationVariantProps {
18
22
  variant?: 'fraction';
@@ -1,2 +1,2 @@
1
- "use strict";var e=require("tslib"),r=require("react/jsx-runtime"),s=require("react"),o=require("@mui/material"),i=require("./hooks.js"),n=require("../../materialui/button/interactive.js"),t=require("../../materialui/slider/sliderContainer.js");const a=s.forwardRef(((o,n)=>{var{carousel:t,position:a,variant:p,sx:g}=o,f=e.__rest(o,["carousel","position","variant","sx"]);const h=i.useCarousel(),v=t||h,b=s.useMemo((()=>{switch(p){case"scrollbar":return x;case"slider":case"progress":return d;case"fraction":return c;case"lines":return u;default:return l}}),[p]),m=s.useMemo((()=>"inside"===a?Object.assign({position:"absolute",zIndex:"90",bottom:"0",left:"0",right:"0"},g):g),[a,JSON.stringify(g)]);return r.jsx(b,Object.assign({carousel:v,sx:m,ref:n},f))})),l=s.forwardRef(((s,i)=>{var{carousel:n,dotProps:t,sx:a}=s,l=e.__rest(s,["carousel","dotProps","sx"]);const c=t||{},{sx:u}=c,d=e.__rest(c,["sx"]);return r.jsx(o.Box,Object.assign({sx:Object.assign({px:2,height:"40px",display:"flex",alignItems:"center",justifyContent:"center",gap:1,pointerEvents:"none"},a),ref:i},l,{children:[...Array((null==n?void 0:n.slides.length)||0)].map(((e,s)=>r.jsx(o.Box,Object.assign({className:!(null==n?void 0:n.originalParams.loop)&&(null==n?void 0:n.isEnd)&&s===((null==n?void 0:n.slides.length)||0)-1?"active":(null==n?void 0:n.isEnd)&&!n.originalParams.loop||s!==(null==n?void 0:n.realIndex)?void 0:"active",sx:Object.assign({p:"0",width:"8px",height:"8px",borderRadius:"100%",backgroundColor:"onSurface.os500",transition:"all 0.3s ease-out","&.active":{width:"12px",height:"12px",backgroundColor:"text.primary"}},u)},d),s)))}))})),c=s.forwardRef(((s,i)=>{var{carousel:t,buttonProps:a,sx:l}=s,c=e.__rest(s,["carousel","buttonProps","sx"]);const u=a||{},{sx:d}=u,x=e.__rest(u,["sx"]);return r.jsx(o.Box,Object.assign({sx:Object.assign({display:"flex",alignItems:"center",justifyContent:"center",p:2},l),ref:i},c,{children:r.jsx(o.Button,Object.assign({variant:"text","aria-controls":"carousel",sx:Object.assign(Object.assign({px:2,py:.25,borderRadius:"4px",fontSize:"18px",lineHeight:"28px",letterSpacing:"0.02em"},n.getInteractiveStyle({backgroundColor:"transparent.backdrop"},{backgroundColor:"onSurface.os100"})),d),onClick:()=>(null==t?void 0:t.isEnd)&&!t.originalParams.loop?null==t?void 0:t.slideTo(0):null==t?void 0:t.slideNext()},x,{children:r.jsxs(o.Box,{component:"span",children:[r.jsx(o.Box,{component:"span",sx:{fontWeight:"700",color:"onSurface.os900"},children:`${((null==t?void 0:t.realIndex)||0)+1}`}),r.jsx(o.Box,{component:"span",sx:{color:"onSurface.os700",fontWeight:"400",mx:.5},children:" / "}),r.jsx(o.Box,{component:"span",sx:{color:"onSurface.os700",fontWeight:"300"},children:`${(null==t?void 0:t.slides.length)||0}`})]})}))}))})),u=s.forwardRef(((s,i)=>{var{carousel:t,sx:a,linesProps:l,lineProgress:c,lineProgressProps:u}=s,d=e.__rest(s,["carousel","sx","linesProps","lineProgress","lineProgressProps"]);const x=l||{},{sx:p}=x,g=e.__rest(x,["sx"]),f=u||{},{sx:h}=f,v=e.__rest(f,["sx"]);return r.jsx(o.Box,Object.assign({sx:Object.assign({display:"flex",alignItems:"center",justifyContent:{xs:"stretch",md:"center"},flexGrow:{xs:"1",md:0},gap:1,p:2},a),ref:i},d,{children:[...Array((null==t?void 0:t.slides.length)||0)].map(((e,s)=>{const i=!(null==t?void 0:t.originalParams.loop)&&(null==t?void 0:t.isEnd)&&s===((null==t?void 0:t.slides.length)||0)-1||(!(null==t?void 0:t.isEnd)||t.originalParams.loop)&&s===(null==t?void 0:t.realIndex),a=s<=((null==t?void 0:t.realIndex)||0);return r.jsxs(o.Button,Object.assign({color:"inherit",className:i?"active":void 0,sx:Object.assign(Object.assign({p:0,minHeight:"0",height:i||a?"8px":"4px",borderRadius:i||a?"4px":"2px",width:{xs:"100%",md:"56px"},justifyContent:"flex-start"},n.getInteractiveStyle({backgroundColor:"surface.primary","& .progress-line":{backgroundColor:"brand.secondary"}},{backgroundColor:"surface.secondary","& .progress-line":{backgroundColor:"brandHover.secondary"}})),p),"aria-controls":"carousel",onClick:()=>null==t?void 0:t[t.originalParams.loop?"slideToLoop":"slideTo"](s)},g,{children:[r.jsx(o.Box,{sx:{position:"absolute",top:"50%",left:"0",right:"0",height:"24px",transform:"translateY(-50%)",pointerEvents:"auto"}}),r.jsx(o.Box,{sx:{borderRadius:"4px",height:"100%",width:"100%",overflow:"hidden"},children:r.jsx(o.Box,Object.assign({className:"progress-line",role:i?"progress":void 0,"aria-valuenow":i?c:void 0,"aria-valuemin":0,"aria-valuemax":100,sx:Object.assign({opacity:void 0!==c||a?"1":"0",width:"100%",backgroundColor:"brand.secondary",height:"100%",transformOrigin:"left",transform:`scaleX(${void 0!==c&&i?c/100:a?1:0})`,transition:(void 0!==c?"transform 300ms ease-in-out, ":"")+"opacity 300ms ease-out, background-color 300ms ease-out"},h)},v))})]}),s)}))}))})),d=s.forwardRef(((i,n)=>{var t,{carousel:a,sliderProps:l,sx:c,progressProps:u}=i,d=e.__rest(i,["carousel","sliderProps","sx","progressProps"]);const x=l||{},{sx:p}=x,g=e.__rest(x,["sx"]),[f,h]=s.useState(Math.round(100*((null==a?void 0:a.progress)||0))),v=s.useRef(!1),[,b]=s.useState({});return s.useEffect((()=>{v.current||h(Math.round(100*((null==a?void 0:a.progress)||0)))}),[null==a?void 0:a.progress]),s.useEffect((()=>{if(a){const e=()=>{v.current||b({})};return a.on("sliderMove",e),()=>{a.off("sliderMove",e)}}}),[a]),r.jsx(o.Box,Object.assign({sx:Object.assign({my:2},c),ref:n},d,{children:r.jsx(o.Slider,Object.assign({value:f,min:0,max:100,onChange:(e,r)=>{v.current=!0,null==a||a.setProgress(r/100,150),h(r)},onChangeCommitted:()=>{null==a||a.slideToClosest(300),v.current=!1},sx:Object.assign({display:"block",height:"4px",".MuiSlider-rail":{color:"surface.primary"},".MuiSlider-track":{color:"onSurface.os500",transitionDuration:`${null!==(t=null==a?void 0:a.originalParams.speed)&&void 0!==t?t:300}ms`},".MuiSlider-thumb":{display:"none"}},p),"aria-controls":"carousel"},g))}))})),x=s.forwardRef(((o,i)=>{var n,a,{carousel:l,sliderProps:c}=o,u=e.__rest(o,["carousel","sliderProps"]);const x=c||{},{sx:p}=x,g=e.__rest(x,["sx"]),[f,h]=s.useState(!1),[,v]=s.useState({});s.useEffect((()=>{if(l){const e=()=>h(!0),r=()=>h(!1),s=()=>v({});return l.on("touchStart",e),l.on("touchEnd",r),l.on("resize",s),()=>{l.off("touchStart",e),l.off("touchEnd",r),l.off("resize",s)}}}),[l]);const b=s.useMemo((()=>{var e,r;if((null===(e=null==l?void 0:l.wrapperEl)||void 0===e?void 0:e.scrollWidth)&&(null==l?void 0:l.width)){const e=Math.ceil((null==l?void 0:l.width)**2/(null===(r=null==l?void 0:l.wrapperEl)||void 0===r?void 0:r.scrollWidth));return Math.max(e,40)}return 40}),[null===(n=null==l?void 0:l.wrapperEl)||void 0===n?void 0:n.scrollWidth,null==l?void 0:l.width]);return r.jsx(d,Object.assign({ref:i,carousel:l,component:t.SliderContainer,thumbSize:b,sliderProps:Object.assign({tabIndex:-1,valueLabelDisplay:"off",sx:Object.assign({display:"block",height:"4px",".MuiSlider-rail, .MuiSlider-track":{color:"surface.primary"},".MuiSlider-thumb":Object.assign(Object.assign({display:"flex",width:`${b}px`,height:"4px",border:"none",backgroundColor:"onSurface.os500"},!f&&{transition:`left ${null!==(a=null==l?void 0:l.originalParams.speed)&&void 0!==a?a:300}ms ease-out`}),{"&.Mui-focusVisible":{boxShadow:"none","&:before":{content:"none"}}})},p)},g)},u))}));exports.CarouselPagination=a,exports.DotsVariant=l,exports.FractionVariant=c,exports.LinesVariant=u,exports.ScrollbarVariant=x,exports.SliderVariant=d;
1
+ "use strict";var s=require("tslib"),e=require("react/jsx-runtime"),r=require("react"),o=require("@mui/material"),i=require("./hooks.js"),n=require("../../materialui/button/interactive.js"),t=require("../../materialui/slider/sliderContainer.js");const a=r.forwardRef(((o,n)=>{var{carousel:t,position:a,variant:x,sx:g}=o,f=s.__rest(o,["carousel","position","variant","sx"]);const v=i.useCarousel(),b=t||v,h=r.useMemo((()=>{switch(x){case"scrollbar":return p;case"slider":case"progress":return c;case"fraction":return u;case"lines":return d;default:return l}}),[x]),m=r.useMemo((()=>"inside"===a?Object.assign({position:"absolute",zIndex:"90",bottom:"0",left:"0",right:"0"},g):g),[a,JSON.stringify(g)]);return e.jsx(h,Object.assign({carousel:b,sx:m,ref:n,position:a},f))})),l=r.forwardRef(((r,i)=>{var{carousel:n,dotsWrapperProps:t,dotProps:a,position:l,sx:u}=r,d=s.__rest(r,["carousel","dotsWrapperProps","dotProps","position","sx"]);const c=null!=t?t:{},{sx:p}=c,x=s.__rest(c,["sx"]),g=null!=a?a:{},{sx:f}=g,v=s.__rest(g,["sx"]);return e.jsx(o.Box,Object.assign({sx:Object.assign({p:2,display:"flex",alignItems:"center",justifyContent:"center"},u),ref:i},d,{children:e.jsx(o.Box,Object.assign({sx:Object.assign(Object.assign({display:"flex",alignItems:"center",justifyContent:"center",borderRadius:"1000px",py:.5,px:1,gap:.5,width:12*((null==n?void 0:n.slides.length)||0)+4*(((null==n?void 0:n.slides.length)||1)-1)+4+16+"px"},"inside"===l&&{backgroundColor:s=>"dark"===s.palette.mode?"surface.primary":"transparent.backdrop"}),p)},x,{children:[...Array((null==n?void 0:n.slides.length)||0)].map(((s,r)=>e.jsx(o.Box,Object.assign({className:!(null==n?void 0:n.originalParams.loop)&&(null==n?void 0:n.isEnd)&&r===((null==n?void 0:n.slides.length)||0)-1?"active":(null==n?void 0:n.isEnd)&&!n.originalParams.loop||r!==(null==n?void 0:n.realIndex)?void 0:"active",sx:Object.assign({p:"0",width:"12px",height:"12px",transform:"scale(0.6667)",borderRadius:"100%",backgroundColor:"onSurface.os500",transition:"transform 0.3s ease-out, background-color 0.3s ease-out, margin 0.3s ease-out","&.active":{transform:"scale(1)",backgroundColor:"text.primary",margin:"0 2px"}},f)},v),r)))}))}))})),u=r.forwardRef(((r,i)=>{var{carousel:t,buttonProps:a,position:l,sx:u}=r,d=s.__rest(r,["carousel","buttonProps","position","sx"]);const c=null!=a?a:{},{sx:p}=c,x=s.__rest(c,["sx"]);return e.jsx(o.Box,Object.assign({sx:Object.assign({display:"flex",alignItems:"center",justifyContent:"center",p:2},u),ref:i},d,{children:e.jsx(o.Button,Object.assign({variant:"text","aria-controls":"carousel",sx:Object.assign(Object.assign({px:2,py:.25,borderRadius:"4px",fontSize:"18px",lineHeight:"28px",letterSpacing:"0.02em"},n.getInteractiveStyle({backgroundColor:"transparent.backdrop"},{backgroundColor:"onSurface.os100"})),p),onClick:()=>(null==t?void 0:t.isEnd)&&!t.originalParams.loop?null==t?void 0:t.slideTo(0):null==t?void 0:t.slideNext()},x,{children:e.jsxs(o.Box,{component:"span",children:[e.jsx(o.Box,{component:"span",sx:{fontWeight:"700",color:"onSurface.os900"},children:`${((null==t?void 0:t.realIndex)||0)+1}`}),e.jsx(o.Box,{component:"span",sx:{color:"onSurface.os700",fontWeight:"400",mx:.5},children:" / "}),e.jsx(o.Box,{component:"span",sx:{color:"onSurface.os700",fontWeight:"300"},children:`${(null==t?void 0:t.slides.length)||0}`})]})}))}))})),d=r.forwardRef(((r,i)=>{var{carousel:t,sx:a,linesProps:l,lineProgress:u,lineProgressProps:d,position:c}=r,p=s.__rest(r,["carousel","sx","linesProps","lineProgress","lineProgressProps","position"]);const x=null!=l?l:{},{sx:g}=x,f=s.__rest(x,["sx"]),v=null!=d?d:{},{sx:b}=v,h=s.__rest(v,["sx"]);return e.jsx(o.Box,Object.assign({sx:Object.assign({display:"flex",alignItems:"center",justifyContent:{xs:"stretch",md:"center"},flexGrow:{xs:"1",md:0},gap:1,p:2},a),ref:i},p,{children:[...Array((null==t?void 0:t.slides.length)||0)].map(((s,r)=>{const i=!(null==t?void 0:t.originalParams.loop)&&(null==t?void 0:t.isEnd)&&r===((null==t?void 0:t.slides.length)||0)-1||(!(null==t?void 0:t.isEnd)||t.originalParams.loop)&&r===(null==t?void 0:t.realIndex),a=r<=((null==t?void 0:t.realIndex)||0);return e.jsxs(o.Button,Object.assign({color:"inherit",className:i?"active":void 0,sx:Object.assign(Object.assign({p:0,minHeight:"0",height:i||a?"8px":"4px",borderRadius:i||a?"4px":"2px",width:{xs:"100%",md:"56px"},justifyContent:"flex-start"},n.getInteractiveStyle({backgroundColor:"surface.primary","& .progress-line":{backgroundColor:"brand.secondary"}},{backgroundColor:"surface.secondary","& .progress-line":{backgroundColor:"brandHover.secondary"}})),g),"aria-controls":"carousel",onClick:()=>null==t?void 0:t[t.originalParams.loop?"slideToLoop":"slideTo"](r)},f,{children:[e.jsx(o.Box,{sx:{position:"absolute",top:"50%",left:"0",right:"0",height:"24px",transform:"translateY(-50%)",pointerEvents:"auto"}}),e.jsx(o.Box,{sx:{borderRadius:"4px",height:"100%",width:"100%",overflow:"hidden"},children:e.jsx(o.Box,Object.assign({className:"progress-line",role:i?"progress":void 0,"aria-valuenow":i?u:void 0,"aria-valuemin":0,"aria-valuemax":100,sx:Object.assign({opacity:void 0!==u||a?"1":"0",width:"100%",backgroundColor:"brand.secondary",height:"100%",transformOrigin:"left",transform:`scaleX(${void 0!==u&&i?u/100:a?1:0})`,transition:(void 0!==u?"transform 300ms ease-in-out, ":"")+"opacity 300ms ease-out, background-color 300ms ease-out"},b)},h))})]}),r)}))}))})),c=r.forwardRef(((i,n)=>{var t,{carousel:a,sliderProps:l,sx:u,progressProps:d,position:c}=i,p=s.__rest(i,["carousel","sliderProps","sx","progressProps","position"]);const x=null!=l?l:{},{sx:g}=x,f=s.__rest(x,["sx"]),[v,b]=r.useState(Math.round(100*((null==a?void 0:a.progress)||0))),h=r.useRef(!1),[,m]=r.useState({});return r.useEffect((()=>{h.current||b(Math.round(100*((null==a?void 0:a.progress)||0)))}),[null==a?void 0:a.progress]),r.useEffect((()=>{if(a){const s=()=>{h.current||m({})};return a.on("sliderMove",s),()=>{a.off("sliderMove",s)}}}),[a]),e.jsx(o.Box,Object.assign({sx:Object.assign({my:2},u),ref:n},p,{children:e.jsx(o.Slider,Object.assign({value:v,min:0,max:100,onChange:(s,e)=>{h.current=!0,null==a||a.setProgress(e/100,150),b(e)},onChangeCommitted:()=>{null==a||a.slideToClosest(300),h.current=!1},sx:Object.assign({display:"block",height:"4px",".MuiSlider-rail":{color:"surface.primary"},".MuiSlider-track":{color:"onSurface.os500",transitionDuration:`${null!==(t=null==a?void 0:a.originalParams.speed)&&void 0!==t?t:300}ms`},".MuiSlider-thumb":{display:"none"}},g),"aria-controls":"carousel"},f))}))})),p=r.forwardRef(((o,i)=>{var n,a,{carousel:l,sliderProps:u,position:d}=o,p=s.__rest(o,["carousel","sliderProps","position"]);const x=null!=u?u:{},{sx:g}=x,f=s.__rest(x,["sx"]),[v,b]=r.useState(!1),[,h]=r.useState({});r.useEffect((()=>{if(l){const s=()=>b(!0),e=()=>b(!1),r=()=>h({});return l.on("touchStart",s),l.on("touchEnd",e),l.on("resize",r),()=>{l.off("touchStart",s),l.off("touchEnd",e),l.off("resize",r)}}}),[l]);const m=r.useMemo((()=>{var s,e;if((null===(s=null==l?void 0:l.wrapperEl)||void 0===s?void 0:s.scrollWidth)&&(null==l?void 0:l.width)){const s=Math.ceil((null==l?void 0:l.width)**2/(null===(e=null==l?void 0:l.wrapperEl)||void 0===e?void 0:e.scrollWidth));return Math.max(s,40)}return 40}),[null===(n=null==l?void 0:l.wrapperEl)||void 0===n?void 0:n.scrollWidth,null==l?void 0:l.width]);return e.jsx(c,Object.assign({ref:i,carousel:l,component:t.SliderContainer,thumbSize:m,sliderProps:Object.assign({tabIndex:-1,valueLabelDisplay:"off",sx:Object.assign({display:"block",height:"4px",".MuiSlider-rail, .MuiSlider-track":{color:"surface.primary"},".MuiSlider-thumb":Object.assign(Object.assign({display:"flex",width:`${m}px`,height:"4px",border:"none",backgroundColor:"onSurface.os500"},!v&&{transition:`left ${null!==(a=null==l?void 0:l.originalParams.speed)&&void 0!==a?a:300}ms ease-out`}),{"&.Mui-focusVisible":{boxShadow:"none","&:before":{content:"none"}}})},g)},f)},p))}));exports.CarouselPagination=a,exports.DotsVariant=l,exports.FractionVariant=u,exports.LinesVariant=d,exports.ScrollbarVariant=p,exports.SliderVariant=c;
2
2
  //# sourceMappingURL=pagination.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"pagination.js","sources":["../../../../../src/components/carousel/pagination.tsx"],"sourcesContent":["import React, { ElementType, forwardRef, useEffect, useMemo, useState, useRef } from 'react';\nimport { Box, BoxProps, Button, ButtonProps, Slider, SliderProps, LinearProgressProps, CSSObject } from '@mui/material';\nimport { useCarousel } from './hooks';\nimport type { Swiper as CarouselInstance } from 'swiper';\nimport { getInteractiveStyle } from '@/src/materialui/button/interactive';\nimport { SliderContainer } from '@/src/materialui/slider/sliderContainer';\n\nexport interface CarouselPaginationVariantProps extends Omit<BoxProps<ElementType>, 'children' | 'position'> {\n /**\n * Carousel instance from useCarousel hook\n */\n carousel: CarouselInstance;\n}\nexport interface CarouselPaginationDotsProps extends CarouselPaginationVariantProps {\n variant?: 'dots';\n /**\n * Properties applied to each dot\n */\n dotProps?: Partial<BoxProps<ElementType>>;\n}\nexport interface CarouselPaginationFractionProps extends CarouselPaginationVariantProps {\n variant?: 'fraction';\n /**\n * Properties applied to button used to render text\n */\n buttonProps?: ButtonProps;\n}\nexport interface CarouselPaginationLinesProps extends CarouselPaginationVariantProps {\n variant?: 'lines';\n /**\n * Properties applied to each line\n */\n linesProps?: ButtonProps;\n /**\n * Show progress in active line instead\n */\n lineProgress?: number;\n /**\n * Properties applied to active line progress\n */\n lineProgressProps?: BoxProps<ElementType>;\n}\n/**\n * @deprecated use `slider` variant instead\n */\nexport interface CarouselPaginationProgressProps extends CarouselPaginationVariantProps {\n variant?: 'progress';\n /**\n * @deprecated\n */\n progressProps?: LinearProgressProps;\n /**\n * Properties applied to Slider\n */\n sliderProps?: SliderProps;\n}\nexport interface CarouselPaginationSliderProps extends CarouselPaginationVariantProps {\n variant?: 'slider';\n /**\n * Properties applied to Slider\n */\n sliderProps?: SliderProps;\n}\nexport interface CarouselPaginationScrollbarProps extends CarouselPaginationVariantProps {\n variant?: 'scrollbar';\n /**\n * Properties applied to Slider\n */\n sliderProps?: SliderProps;\n}\nexport interface CarouselPaginationBaseProps {\n /**\n * Optional Carousel instance from useCarouselInstance hook\n */\n carousel?: CarouselInstance;\n /**\n * Append style to wrapper box to change position of control\n * @default outside\n */\n position?: 'outside' | 'inside';\n}\nexport type CarouselPaginationProps = CarouselPaginationBaseProps &\n (\n | Omit<CarouselPaginationDotsProps, 'carousel'>\n | Omit<CarouselPaginationFractionProps, 'carousel'>\n | Omit<CarouselPaginationLinesProps, 'carousel'>\n | Omit<CarouselPaginationProgressProps, 'carousel'>\n | Omit<CarouselPaginationSliderProps, 'carousel'>\n | Omit<CarouselPaginationScrollbarProps, 'carousel'>\n );\n\n/**\n * Pagination controls\n */\nexport const CarouselPagination: React.FC<CarouselPaginationProps> = forwardRef(\n ({ carousel: carouselProp, position, variant, sx: rawSx, ...rest }, ref) => {\n const carouselHook = useCarousel();\n const carousel = carouselProp || carouselHook;\n // decide on component used\n const VariantComponent = useMemo(() => {\n switch (variant) {\n case 'scrollbar':\n return ScrollbarVariant;\n case 'slider':\n case 'progress':\n return SliderVariant;\n case 'fraction':\n return FractionVariant;\n case 'lines':\n return LinesVariant;\n case 'dots':\n return DotsVariant;\n default:\n return DotsVariant;\n }\n }, [variant]);\n // position extra styling applied to wrapper\n const sx = useMemo<CSSObject | BoxProps['sx']>(() => {\n if (position === 'inside') {\n return {\n position: 'absolute',\n zIndex: '90',\n bottom: '0',\n left: '0',\n right: '0',\n ...rawSx,\n };\n } else {\n return rawSx;\n }\n }, [position, JSON.stringify(rawSx)]);\n\n return <VariantComponent carousel={carousel} sx={sx} ref={ref} {...rest} />;\n },\n);\n\n/**\n * Dots variant (...)\n */\nexport const DotsVariant: React.FC<CarouselPaginationDotsProps> = forwardRef(\n ({ carousel, dotProps, sx, ...rest }, ref) => {\n const { sx: dotSx, ...restDot } = dotProps || {};\n\n return (\n <Box\n sx={{\n px: 2,\n height: '40px',\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n gap: 1,\n pointerEvents: 'none',\n ...sx,\n }}\n ref={ref}\n {...rest}\n >\n {[...Array(carousel?.slides.length || 0)].map((_, idx) => (\n <Box\n key={idx}\n className={\n !carousel?.originalParams.loop && carousel?.isEnd && idx === (carousel?.slides.length || 0) - 1\n ? 'active'\n : (!carousel?.isEnd || carousel.originalParams.loop) && idx === carousel?.realIndex\n ? 'active'\n : undefined\n }\n sx={{\n p: '0',\n width: '8px',\n height: '8px',\n borderRadius: '100%',\n backgroundColor: 'onSurface.os500',\n transition: 'all 0.3s ease-out',\n '&.active': {\n width: '12px',\n height: '12px',\n backgroundColor: 'text.primary',\n },\n ...dotSx,\n }}\n {...restDot}\n />\n ))}\n </Box>\n );\n },\n);\n\n/**\n * Fraction variant (text 1/3)\n */\nexport const FractionVariant: React.FC<CarouselPaginationFractionProps> = forwardRef(\n ({ carousel, buttonProps, sx, ...rest }, ref) => {\n const { sx: buttonSx, ...restButton } = buttonProps || {};\n\n return (\n <Box\n sx={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n // space is needed for focus overflow\n p: 2,\n ...sx,\n }}\n ref={ref}\n {...rest}\n >\n <Button\n variant=\"text\"\n aria-controls=\"carousel\"\n sx={{\n px: 2,\n py: 0.25,\n borderRadius: '4px',\n // custom typography according to Figma (Pagination/Compact)\n fontSize: '18px',\n lineHeight: '28px',\n letterSpacing: '0.02em',\n ...getInteractiveStyle(\n {\n backgroundColor: 'transparent.backdrop',\n },\n {\n backgroundColor: 'onSurface.os100',\n },\n ),\n ...buttonSx,\n }}\n onClick={() =>\n // at the end, slide to beginning\n carousel?.isEnd && !carousel.originalParams.loop ? carousel?.slideTo(0) : carousel?.slideNext()\n }\n {...restButton}\n >\n <Box component=\"span\">\n <Box component=\"span\" sx={{ fontWeight: '700', color: 'onSurface.os900' }}>\n {`${(carousel?.realIndex || 0) + 1}`}\n </Box>\n <Box component=\"span\" sx={{ color: 'onSurface.os700', fontWeight: '400', mx: 0.5 }}>\n {' / '}\n </Box>\n <Box component=\"span\" sx={{ color: 'onSurface.os700', fontWeight: '300' }}>\n {`${carousel?.slides.length || 0}`}\n </Box>\n </Box>\n </Button>\n </Box>\n );\n },\n);\n\n/**\n * Lines variant (- - -)\n */\nexport const LinesVariant: React.FC<CarouselPaginationLinesProps> = forwardRef(\n ({ carousel, sx, linesProps, lineProgress, lineProgressProps, ...rest }, ref) => {\n const { sx: lineSx, ...lineRest } = linesProps || {};\n const { sx: lineProgressSx, ...lineProgressRest } = lineProgressProps || {};\n\n return (\n <Box\n sx={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: { xs: 'stretch', md: 'center' },\n flexGrow: { xs: '1', md: 0 },\n gap: 1,\n // space is needed for focus overflow\n p: 2,\n ...sx,\n }}\n ref={ref}\n {...rest}\n >\n {[...Array(carousel?.slides.length || 0)].map((_, idx) => {\n const active =\n (!carousel?.originalParams.loop && carousel?.isEnd && idx === (carousel?.slides.length || 0) - 1) ||\n ((!carousel?.isEnd || carousel.originalParams.loop) && idx === carousel?.realIndex);\n const seen = idx <= (carousel?.realIndex || 0);\n\n return (\n <Button\n key={idx}\n color=\"inherit\"\n className={active ? 'active' : undefined}\n sx={{\n p: 0,\n minHeight: '0',\n height: active || seen ? '8px' : '4px',\n borderRadius: active || seen ? '4px' : '2px',\n width: { xs: '100%', md: '56px' },\n justifyContent: 'flex-start',\n ...getInteractiveStyle(\n {\n backgroundColor: 'surface.primary',\n '& .progress-line': {\n backgroundColor: 'brand.secondary',\n },\n },\n {\n backgroundColor: 'surface.secondary',\n '& .progress-line': {\n backgroundColor: 'brandHover.secondary',\n },\n },\n ),\n ...lineSx,\n }}\n aria-controls=\"carousel\"\n onClick={() => carousel?.[carousel.originalParams.loop ? 'slideToLoop' : 'slideTo'](idx)}\n {...lineRest}\n >\n <Box\n sx={{\n // invisible hitbox expanding clickable area\n position: 'absolute',\n top: '50%',\n left: '0',\n right: '0',\n height: '24px', // Minimum a11y click area\n transform: 'translateY(-50%)',\n pointerEvents: 'auto',\n }}\n />\n <Box sx={{ borderRadius: '4px', height: '100%', width: '100%', overflow: 'hidden' }}>\n <Box\n className=\"progress-line\"\n role={active ? 'progress' : undefined} // Only the active one gets a role\n aria-valuenow={active ? lineProgress : undefined}\n aria-valuemin={0}\n aria-valuemax={100}\n sx={{\n opacity: lineProgress !== undefined || seen ? '1' : '0',\n width: '100%',\n backgroundColor: 'brand.secondary',\n height: '100%',\n transformOrigin: 'left',\n transform: `scaleX(${lineProgress !== undefined && active ? lineProgress / 100 : seen ? 1 : 0})`,\n transition: `${lineProgress !== undefined ? 'transform 300ms ease-in-out, ' : ''}opacity 300ms ease-out, background-color 300ms ease-out`,\n ...lineProgressSx,\n }}\n {...lineProgressRest}\n />\n </Box>\n </Button>\n );\n })}\n </Box>\n );\n },\n);\n\n/**\n * Slider variant (___)\n */\nexport const SliderVariant: React.FC<CarouselPaginationSliderProps> = forwardRef(\n ({ carousel, sliderProps, sx, progressProps: __, ...rest }, ref) => {\n const { sx: sliderSx, ...restSlider } = sliderProps || {};\n // slider current value that might not match carousel progress\n const [value, setValue] = useState<number>(Math.round((carousel?.progress || 0) * 100));\n // watch user manipulating slider\n const dragging = useRef<boolean>(false);\n const [, setRerender] = useState({});\n // monitor carousel progress to update slider value\n useEffect(() => {\n if (!dragging.current) {\n setValue(Math.round((carousel?.progress || 0) * 100));\n }\n }, [carousel?.progress]);\n // extra monitor of states\n useEffect(() => {\n if (carousel) {\n const handleMove = () => {\n if (!dragging.current) {\n setRerender({});\n }\n };\n\n // monitor of movement to immediately move thumb\n carousel.on('sliderMove', handleMove);\n\n return () => {\n carousel.off('sliderMove', handleMove);\n };\n }\n }, [carousel]);\n\n return (\n <Box sx={{ my: 2, ...sx }} ref={ref} {...rest}>\n <Slider\n value={value}\n min={0}\n max={100}\n onChange={(_, newValue: number) => {\n // prevent value updates from carousel progress\n dragging.current = true;\n // smoothly move carousel\n carousel?.setProgress(newValue / 100, 150);\n // update slider value\n setValue(newValue);\n }}\n onChangeCommitted={() => {\n // make sure to slide to correct position after user stop touching slider\n carousel?.slideToClosest(300);\n // enable changing value from carousel progress\n dragging.current = false;\n }}\n sx={{\n display: 'block',\n height: '4px',\n // restyle to less prominent variant\n '.MuiSlider-rail': {\n color: 'surface.primary',\n },\n '.MuiSlider-track': {\n color: 'onSurface.os500',\n // match transition speed of carousel\n transitionDuration: `${carousel?.originalParams.speed ?? 300}ms`,\n },\n // hide control thumb\n '.MuiSlider-thumb': {\n display: 'none',\n },\n ...sliderSx,\n }}\n aria-controls=\"carousel\"\n {...restSlider}\n />\n </Box>\n );\n },\n);\n\n/**\n * Scrollbar variant (_--)\n */\nexport const ScrollbarVariant: React.FC<CarouselPaginationSliderProps> = forwardRef(\n ({ carousel, sliderProps, ...rest }, ref) => {\n const { sx: sliderSx, ...restSlider } = sliderProps || {};\n // watch states\n const [carouselDragging, setCarouselDragging] = useState<boolean>(false);\n const [, setRerender] = useState({});\n // extra monitor of states\n useEffect(() => {\n if (carousel) {\n const handleDragStart = () => setCarouselDragging(true);\n const handleDragEnd = () => setCarouselDragging(false);\n const handleResize = () => setRerender({});\n\n // monitor of dragging to remove thumb transition for immediate feedback\n carousel.on('touchStart', handleDragStart);\n carousel.on('touchEnd', handleDragEnd);\n // monitor resize to change size of the thumb\n carousel.on('resize', handleResize);\n\n return () => {\n carousel.off('touchStart', handleDragStart);\n carousel.off('touchEnd', handleDragEnd);\n carousel.off('resize', handleResize);\n };\n }\n }, [carousel]);\n // calculate size of the thumb based on the visible content and full content\n const thumbSize = useMemo<number>(() => {\n if (carousel?.wrapperEl?.scrollWidth && carousel?.width) {\n const size = Math.ceil(carousel?.width ** 2 / carousel?.wrapperEl?.scrollWidth);\n return Math.max(size, 40);\n }\n return 40;\n }, [carousel?.wrapperEl?.scrollWidth, carousel?.width]);\n\n return (\n <SliderVariant\n ref={ref}\n carousel={carousel}\n component={SliderContainer}\n thumbSize={thumbSize}\n sliderProps={{\n // prevent selection via keyboard, Carousel can be already controlled with Keyboard and we are not showing focus ring\n tabIndex: -1,\n // remove valueLabel tooltip above thumb\n valueLabelDisplay: 'off',\n sx: {\n display: 'block',\n height: '4px',\n // restyle to match scrollbar\n '.MuiSlider-rail, .MuiSlider-track': {\n color: 'surface.primary',\n },\n '.MuiSlider-thumb': {\n display: 'flex',\n width: `${thumbSize}px`,\n height: '4px',\n border: 'none',\n backgroundColor: 'onSurface.os500',\n // match transition speed of carousel\n ...(!carouselDragging && {\n transition: `left ${carousel?.originalParams.speed ?? 300}ms ease-out`,\n }),\n // remove focus style\n '&.Mui-focusVisible': {\n boxShadow: 'none',\n '&:before': {\n content: 'none',\n },\n },\n },\n ...sliderSx,\n },\n ...restSlider,\n }}\n {...rest}\n />\n );\n },\n);\n"],"names":["CarouselPagination","forwardRef","_a","ref","carousel","carouselProp","position","variant","sx","rawSx","rest","__rest","carouselHook","useCarousel","VariantComponent","useMemo","ScrollbarVariant","SliderVariant","FractionVariant","LinesVariant","DotsVariant","Object","assign","zIndex","bottom","left","right","JSON","stringify","_jsx","dotProps","_b","dotSx","restDot","jsx","Box","px","height","display","alignItems","justifyContent","gap","pointerEvents","children","Array","slides","length","map","_","idx","className","originalParams","loop","isEnd","realIndex","undefined","p","width","borderRadius","backgroundColor","transition","buttonProps","buttonSx","restButton","Button","py","fontSize","lineHeight","letterSpacing","getInteractiveStyle","onClick","slideTo","slideNext","_jsxs","component","fontWeight","color","mx","linesProps","lineProgress","lineProgressProps","lineSx","lineRest","_c","lineProgressSx","lineProgressRest","xs","md","flexGrow","active","seen","jsxs","minHeight","top","transform","overflow","role","opacity","transformOrigin","sliderProps","progressProps","__","sliderSx","restSlider","value","setValue","useState","Math","round","progress","dragging","useRef","setRerender","useEffect","current","handleMove","on","off","my","Slider","min","max","onChange","newValue","setProgress","onChangeCommitted","slideToClosest","transitionDuration","speed","_d","carouselDragging","setCarouselDragging","handleDragStart","handleDragEnd","handleResize","thumbSize","wrapperEl","scrollWidth","size","ceil","SliderContainer","tabIndex","valueLabelDisplay","border","boxShadow","content"],"mappings":"qPA8Fa,MAAAA,EAAwDC,EAAUA,YAC7E,CAACC,EAAmEC,KAAnE,IAAEC,SAAUC,EAAYC,SAAEA,EAAQC,QAAEA,EAASC,GAAIC,GAAgBP,EAANQ,EAAIC,EAAAA,OAAAT,EAA/D,wCACC,MAAMU,EAAeC,EAAAA,cACfT,EAAWC,GAAgBO,EAE3BE,EAAmBC,EAAAA,SAAQ,KAC/B,OAAQR,GACN,IAAK,YACH,OAAOS,EACT,IAAK,SACL,IAAK,WACH,OAAOC,EACT,IAAK,WACH,OAAOC,EACT,IAAK,QACH,OAAOC,EAGT,QACE,OAAOC,KAEV,CAACb,IAEEC,EAAKO,EAAAA,SAAoC,IAC5B,WAAbT,EAEAe,OAAAC,OAAA,CAAAhB,SAAU,WACViB,OAAQ,KACRC,OAAQ,IACRC,KAAM,IACNC,MAAO,KACJjB,GAGEA,GAER,CAACH,EAAUqB,KAAKC,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AAsC,QAA9BuB,EAAA/E,aAAQ,EAARA,EAAU+C,eAAe6E,aAAK,IAAA7C,EAAAA,EAAI,mBACtD,CAEF,qBAAsB,CACpB6D,UAAW,OACX,WAAY,CACVC,QAAS,YAIZ3C,IAEFC,IAED7F,GACJ"}
1
+ {"version":3,"file":"pagination.js","sources":["../../../../../src/components/carousel/pagination.tsx"],"sourcesContent":["import React, { ElementType, forwardRef, useEffect, useMemo, useState, useRef } from 'react';\nimport { Box, BoxProps, Button, ButtonProps, Slider, SliderProps, LinearProgressProps, CSSObject } from '@mui/material';\nimport { useCarousel } from './hooks';\nimport type { Swiper as CarouselInstance } from 'swiper';\nimport { getInteractiveStyle } from '@/src/materialui/button/interactive';\nimport { SliderContainer } from '@/src/materialui/slider/sliderContainer';\n\nexport interface CarouselPaginationVariantProps extends Omit<BoxProps<ElementType>, 'children' | 'position'> {\n /**\n * Carousel instance from useCarousel hook\n */\n carousel: CarouselInstance;\n}\nexport interface CarouselPaginationDotsProps extends CarouselPaginationVariantProps {\n variant?: 'dots';\n /**\n * Properties applied to wrapper of dots\n */\n dotsWrapperProps?: BoxProps<ElementType>;\n /**\n * Properties applied to each dot\n */\n dotProps?: BoxProps<ElementType>;\n}\nexport interface CarouselPaginationFractionProps extends CarouselPaginationVariantProps {\n variant?: 'fraction';\n /**\n * Properties applied to button used to render text\n */\n buttonProps?: ButtonProps;\n}\nexport interface CarouselPaginationLinesProps extends CarouselPaginationVariantProps {\n variant?: 'lines';\n /**\n * Properties applied to each line\n */\n linesProps?: ButtonProps;\n /**\n * Show progress in active line instead\n */\n lineProgress?: number;\n /**\n * Properties applied to active line progress\n */\n lineProgressProps?: BoxProps<ElementType>;\n}\n/**\n * @deprecated use `slider` variant instead\n */\nexport interface CarouselPaginationProgressProps extends CarouselPaginationVariantProps {\n variant?: 'progress';\n /**\n * @deprecated\n */\n progressProps?: LinearProgressProps;\n /**\n * Properties applied to Slider\n */\n sliderProps?: SliderProps;\n}\nexport interface CarouselPaginationSliderProps extends CarouselPaginationVariantProps {\n variant?: 'slider';\n /**\n * Properties applied to Slider\n */\n sliderProps?: SliderProps;\n}\nexport interface CarouselPaginationScrollbarProps extends CarouselPaginationVariantProps {\n variant?: 'scrollbar';\n /**\n * Properties applied to Slider\n */\n sliderProps?: SliderProps;\n}\nexport interface CarouselPaginationBaseProps {\n /**\n * Optional Carousel instance from useCarouselInstance hook\n */\n carousel?: CarouselInstance;\n /**\n * Append style to wrapper box to change position of control\n * @default outside\n */\n position?: 'outside' | 'inside';\n}\nexport type CarouselPaginationProps = CarouselPaginationBaseProps &\n (\n | Omit<CarouselPaginationDotsProps, 'carousel'>\n | Omit<CarouselPaginationFractionProps, 'carousel'>\n | Omit<CarouselPaginationLinesProps, 'carousel'>\n | Omit<CarouselPaginationProgressProps, 'carousel'>\n | Omit<CarouselPaginationSliderProps, 'carousel'>\n | Omit<CarouselPaginationScrollbarProps, 'carousel'>\n );\n\n/**\n * Pagination controls\n */\nexport const CarouselPagination: React.FC<CarouselPaginationProps> = forwardRef(\n ({ carousel: carouselProp, position, variant, sx: rawSx, ...rest }, ref) => {\n const carouselHook = useCarousel();\n const carousel = carouselProp || carouselHook;\n // decide on component used\n const VariantComponent = useMemo(() => {\n switch (variant) {\n case 'scrollbar':\n return ScrollbarVariant;\n case 'slider':\n case 'progress':\n return SliderVariant;\n case 'fraction':\n return FractionVariant;\n case 'lines':\n return LinesVariant;\n case 'dots':\n return DotsVariant;\n default:\n return DotsVariant;\n }\n }, [variant]);\n // position extra styling applied to wrapper\n const sx = useMemo<CSSObject | BoxProps['sx']>(() => {\n if (position === 'inside') {\n return {\n position: 'absolute',\n zIndex: '90',\n bottom: '0',\n left: '0',\n right: '0',\n ...rawSx,\n };\n } else {\n return rawSx;\n }\n }, [position, JSON.stringify(rawSx)]);\n\n return <VariantComponent carousel={carousel} sx={sx} ref={ref} position={position} {...rest} />;\n },\n);\n\n/**\n * Dots variant (...)\n */\nexport const DotsVariant: React.FC<CarouselPaginationDotsProps> = forwardRef(\n ({ carousel, dotsWrapperProps, dotProps, position, sx, ...rest }, ref) => {\n const { sx: dotsWrapperSx, ...restDotsWrapper } = dotsWrapperProps ?? {};\n const { sx: dotSx, ...restDot } = dotProps ?? {};\n\n return (\n <Box\n sx={{\n p: 2,\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n ...sx,\n }}\n ref={ref}\n {...rest}\n >\n <Box\n sx={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n borderRadius: '1000px',\n py: 0.5,\n px: 1,\n gap: 0.5,\n // ensure width does not change during transition\n // dots width space + gap space + extra active dot space + padding\n width: `${(carousel?.slides.length || 0) * 12 + ((carousel?.slides.length || 1) - 1) * 4 + 4 + 16}px`,\n // on image variant from Figma\n ...(position === 'inside' && {\n backgroundColor: (theme) => (theme.palette.mode === 'dark' ? 'surface.primary' : 'transparent.backdrop'),\n }),\n ...dotsWrapperSx,\n }}\n {...restDotsWrapper}\n >\n {[...Array(carousel?.slides.length || 0)].map((_, idx) => (\n <Box\n key={idx}\n className={\n !carousel?.originalParams.loop && carousel?.isEnd && idx === (carousel?.slides.length || 0) - 1\n ? 'active'\n : (!carousel?.isEnd || carousel.originalParams.loop) && idx === carousel?.realIndex\n ? 'active'\n : undefined\n }\n sx={{\n p: '0',\n width: '12px',\n height: '12px',\n // scale to 8px\n transform: 'scale(0.6667)',\n borderRadius: '100%',\n backgroundColor: 'onSurface.os500',\n transition: 'transform 0.3s ease-out, background-color 0.3s ease-out, margin 0.3s ease-out',\n '&.active': {\n transform: 'scale(1)',\n backgroundColor: 'text.primary',\n margin: '0 2px',\n },\n ...dotSx,\n }}\n {...restDot}\n />\n ))}\n </Box>\n </Box>\n );\n },\n);\n\n/**\n * Fraction variant (text 1/3)\n */\nexport const FractionVariant: React.FC<CarouselPaginationFractionProps> = forwardRef(\n ({ carousel, buttonProps, position, sx, ...rest }, ref) => {\n const { sx: buttonSx, ...restButton } = buttonProps ?? {};\n\n return (\n <Box\n sx={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: 'center',\n // space is needed for focus overflow\n p: 2,\n ...sx,\n }}\n ref={ref}\n {...rest}\n >\n <Button\n variant=\"text\"\n aria-controls=\"carousel\"\n sx={{\n px: 2,\n py: 0.25,\n borderRadius: '4px',\n // custom typography according to Figma (Pagination/Compact)\n fontSize: '18px',\n lineHeight: '28px',\n letterSpacing: '0.02em',\n ...getInteractiveStyle(\n {\n backgroundColor: 'transparent.backdrop',\n },\n {\n backgroundColor: 'onSurface.os100',\n },\n ),\n ...buttonSx,\n }}\n onClick={() =>\n // at the end, slide to beginning\n carousel?.isEnd && !carousel.originalParams.loop ? carousel?.slideTo(0) : carousel?.slideNext()\n }\n {...restButton}\n >\n <Box component=\"span\">\n <Box component=\"span\" sx={{ fontWeight: '700', color: 'onSurface.os900' }}>\n {`${(carousel?.realIndex || 0) + 1}`}\n </Box>\n <Box component=\"span\" sx={{ color: 'onSurface.os700', fontWeight: '400', mx: 0.5 }}>\n {' / '}\n </Box>\n <Box component=\"span\" sx={{ color: 'onSurface.os700', fontWeight: '300' }}>\n {`${carousel?.slides.length || 0}`}\n </Box>\n </Box>\n </Button>\n </Box>\n );\n },\n);\n\n/**\n * Lines variant (- - -)\n */\nexport const LinesVariant: React.FC<CarouselPaginationLinesProps> = forwardRef(\n ({ carousel, sx, linesProps, lineProgress, lineProgressProps, position, ...rest }, ref) => {\n const { sx: lineSx, ...lineRest } = linesProps ?? {};\n const { sx: lineProgressSx, ...lineProgressRest } = lineProgressProps ?? {};\n\n return (\n <Box\n sx={{\n display: 'flex',\n alignItems: 'center',\n justifyContent: { xs: 'stretch', md: 'center' },\n flexGrow: { xs: '1', md: 0 },\n gap: 1,\n // space is needed for focus overflow\n p: 2,\n ...sx,\n }}\n ref={ref}\n {...rest}\n >\n {[...Array(carousel?.slides.length || 0)].map((_, idx) => {\n const active =\n (!carousel?.originalParams.loop && carousel?.isEnd && idx === (carousel?.slides.length || 0) - 1) ||\n ((!carousel?.isEnd || carousel.originalParams.loop) && idx === carousel?.realIndex);\n const seen = idx <= (carousel?.realIndex || 0);\n\n return (\n <Button\n key={idx}\n color=\"inherit\"\n className={active ? 'active' : undefined}\n sx={{\n p: 0,\n minHeight: '0',\n height: active || seen ? '8px' : '4px',\n borderRadius: active || seen ? '4px' : '2px',\n width: { xs: '100%', md: '56px' },\n justifyContent: 'flex-start',\n ...getInteractiveStyle(\n {\n backgroundColor: 'surface.primary',\n '& .progress-line': {\n backgroundColor: 'brand.secondary',\n },\n },\n {\n backgroundColor: 'surface.secondary',\n '& .progress-line': {\n backgroundColor: 'brandHover.secondary',\n },\n },\n ),\n ...lineSx,\n }}\n aria-controls=\"carousel\"\n onClick={() => carousel?.[carousel.originalParams.loop ? 'slideToLoop' : 'slideTo'](idx)}\n {...lineRest}\n >\n <Box\n sx={{\n // invisible hitbox expanding clickable area\n position: 'absolute',\n top: '50%',\n left: '0',\n right: '0',\n height: '24px', // Minimum a11y click area\n transform: 'translateY(-50%)',\n pointerEvents: 'auto',\n }}\n />\n <Box sx={{ borderRadius: '4px', height: '100%', width: '100%', overflow: 'hidden' }}>\n <Box\n className=\"progress-line\"\n role={active ? 'progress' : undefined} // Only the active one gets a role\n aria-valuenow={active ? lineProgress : undefined}\n aria-valuemin={0}\n aria-valuemax={100}\n sx={{\n opacity: lineProgress !== undefined || seen ? '1' : '0',\n width: '100%',\n backgroundColor: 'brand.secondary',\n height: '100%',\n transformOrigin: 'left',\n transform: `scaleX(${lineProgress !== undefined && active ? lineProgress / 100 : seen ? 1 : 0})`,\n transition: `${lineProgress !== undefined ? 'transform 300ms ease-in-out, ' : ''}opacity 300ms ease-out, background-color 300ms ease-out`,\n ...lineProgressSx,\n }}\n {...lineProgressRest}\n />\n </Box>\n </Button>\n );\n })}\n </Box>\n );\n },\n);\n\n/**\n * Slider variant (___)\n */\nexport const SliderVariant: React.FC<CarouselPaginationSliderProps> = forwardRef(\n ({ carousel, sliderProps, sx, progressProps: __, position, ...rest }, ref) => {\n const { sx: sliderSx, ...restSlider } = sliderProps ?? {};\n // slider current value that might not match carousel progress\n const [value, setValue] = useState<number>(Math.round((carousel?.progress || 0) * 100));\n // watch user manipulating slider\n const dragging = useRef<boolean>(false);\n const [, setRerender] = useState({});\n // monitor carousel progress to update slider value\n useEffect(() => {\n if (!dragging.current) {\n setValue(Math.round((carousel?.progress || 0) * 100));\n }\n }, [carousel?.progress]);\n // extra monitor of states\n useEffect(() => {\n if (carousel) {\n const handleMove = () => {\n if (!dragging.current) {\n setRerender({});\n }\n };\n\n // monitor of movement to immediately move thumb\n carousel.on('sliderMove', handleMove);\n\n return () => {\n carousel.off('sliderMove', handleMove);\n };\n }\n }, [carousel]);\n\n return (\n <Box sx={{ my: 2, ...sx }} ref={ref} {...rest}>\n <Slider\n value={value}\n min={0}\n max={100}\n onChange={(_, newValue: number) => {\n // prevent value updates from carousel progress\n dragging.current = true;\n // smoothly move carousel\n carousel?.setProgress(newValue / 100, 150);\n // update slider value\n setValue(newValue);\n }}\n onChangeCommitted={() => {\n // make sure to slide to correct position after user stop touching slider\n carousel?.slideToClosest(300);\n // enable changing value from carousel progress\n dragging.current = false;\n }}\n sx={{\n display: 'block',\n height: '4px',\n // restyle to less prominent variant\n '.MuiSlider-rail': {\n color: 'surface.primary',\n },\n '.MuiSlider-track': {\n color: 'onSurface.os500',\n // match transition speed of carousel\n transitionDuration: `${carousel?.originalParams.speed ?? 300}ms`,\n },\n // hide control thumb\n '.MuiSlider-thumb': {\n display: 'none',\n },\n ...sliderSx,\n }}\n aria-controls=\"carousel\"\n {...restSlider}\n />\n </Box>\n );\n },\n);\n\n/**\n * Scrollbar variant (_--)\n */\nexport const ScrollbarVariant: React.FC<CarouselPaginationSliderProps> = forwardRef(\n ({ carousel, sliderProps, position, ...rest }, ref) => {\n const { sx: sliderSx, ...restSlider } = sliderProps ?? {};\n // watch states\n const [carouselDragging, setCarouselDragging] = useState<boolean>(false);\n const [, setRerender] = useState({});\n // extra monitor of states\n useEffect(() => {\n if (carousel) {\n const handleDragStart = () => setCarouselDragging(true);\n const handleDragEnd = () => setCarouselDragging(false);\n const handleResize = () => setRerender({});\n\n // monitor of dragging to remove thumb transition for immediate feedback\n carousel.on('touchStart', handleDragStart);\n carousel.on('touchEnd', handleDragEnd);\n // monitor resize to change size of the thumb\n carousel.on('resize', handleResize);\n\n return () => {\n carousel.off('touchStart', handleDragStart);\n carousel.off('touchEnd', handleDragEnd);\n carousel.off('resize', handleResize);\n };\n }\n }, [carousel]);\n // calculate size of the thumb based on the visible content and full content\n const thumbSize = useMemo<number>(() => {\n if (carousel?.wrapperEl?.scrollWidth && carousel?.width) {\n const size = Math.ceil(carousel?.width ** 2 / carousel?.wrapperEl?.scrollWidth);\n return Math.max(size, 40);\n }\n return 40;\n }, [carousel?.wrapperEl?.scrollWidth, carousel?.width]);\n\n return (\n <SliderVariant\n ref={ref}\n carousel={carousel}\n component={SliderContainer}\n thumbSize={thumbSize}\n sliderProps={{\n // prevent selection via keyboard, Carousel can be already controlled with Keyboard and we are not showing focus ring\n tabIndex: -1,\n // remove valueLabel tooltip above thumb\n valueLabelDisplay: 'off',\n sx: {\n display: 'block',\n height: '4px',\n // restyle to match scrollbar\n '.MuiSlider-rail, .MuiSlider-track': {\n color: 'surface.primary',\n },\n '.MuiSlider-thumb': {\n display: 'flex',\n width: `${thumbSize}px`,\n height: '4px',\n border: 'none',\n backgroundColor: 'onSurface.os500',\n // match transition speed of carousel\n ...(!carouselDragging && {\n transition: `left ${carousel?.originalParams.speed ?? 300}ms ease-out`,\n }),\n // remove focus style\n '&.Mui-focusVisible': {\n boxShadow: 'none',\n '&:before': {\n content: 'none',\n },\n },\n },\n ...sliderSx,\n },\n ...restSlider,\n }}\n {...rest}\n />\n );\n },\n);\n"],"names":["CarouselPagination","forwardRef","_a","ref","carousel","carouselProp","position","variant","sx","rawSx","rest","__rest","carouselHook","useCarousel","VariantComponent","useMemo","ScrollbarVariant","SliderVariant","FractionVariant","LinesVariant","DotsVariant","Object","assign","zIndex","bottom","left","right","JSON","stringify","_jsx","dotsWrapperProps","dotProps","_b","dotsWrapperSx","restDotsWrapper","_c","dotSx","restDot","Box","p","display","alignItems","justifyContent","children","jsx","borderRadius","py","px","gap","width","slides","length","backgroundColor","theme","palette","mode","Array","map","_","idx","className","originalParams","loop","isEnd","realIndex","undefined","height","transform","transition","margin","buttonProps","buttonSx","restButton","Button","fontSize","lineHeight","letterSpacing","getInteractiveStyle","onClick","slideTo","slideNext","_jsxs","component","fontWeight","color","mx","linesProps","lineProgress","lineProgressProps","lineSx","lineRest","lineProgressSx","lineProgressRest","xs","md","flexGrow","active","seen","jsxs","minHeight","top","pointerEvents","overflow","role","opacity","transformOrigin","sliderProps","progressProps","__","sliderSx","restSlider","value","setValue","useState","Math","round","progress","dragging","useRef","setRerender","useEffect","current","handleMove","on","off","my","Slider","min","max","onChange","newValue","setProgress","onChangeCommitted","slideToClosest","transitionDuration","speed","_d","carouselDragging","setCarouselDragging","handleDragStart","handleDragEnd","handleResize","thumbSize","wrapperEl","scrollWidth","size","ceil","SliderContainer","tabIndex","valueLabelDisplay","border","boxShadow","content"],"mappings":"qPAkGa,MAAAA,EAAwDC,EAAUA,YAC7E,CAACC,EAAmEC,KAAnE,IAAEC,SAAUC,EAAYC,SAAEA,EAAQC,QAAEA,EAASC,GAAIC,GAAgBP,EAANQ,EAAIC,EAAAA,OAAAT,EAA/D,wCACC,MAAMU,EAAeC,EAAAA,cACfT,EAAWC,GAAgBO,EAE3BE,EAAmBC,EAAAA,SAAQ,KAC/B,OAAQR,GACN,IAAK,YACH,OAAOS,EACT,IAAK,SACL,IAAK,WACH,OAAOC,EACT,IAAK,WACH,OAAOC,EACT,IAAK,QACH,OAAOC,EAGT,QACE,OAAOC,KAEV,CAACb,IAEEC,EAAKO,EAAAA,SAAoC,IAC5B,WAAbT,EAEAe,OAAAC,OAAA,CAAAhB,SAAU,WACViB,OAAQ,KACRC,OAAQ,IACRC,KAAM,IACNC,MAAO,KACJjB,GAGEA,GAER,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A,EAAU6C,OAAO,CACvD,MAAMgG,EAAO/B,KAAKgC,MAAK9I,aAAA,EAAAA,EAAU6C,QAAS,GAAuB,QAAnBjB,EAAA5B,aAAQ,EAARA,EAAU2I,iBAAS,IAAA/G,OAAA,EAAAA,EAAEgH,cACnE,OAAO9B,KAAKc,IAAIiB,EAAM,IAExB,OAAO,EAAE,GACR,CAAoB,QAAnBjH,EAAA5B,aAAQ,EAARA,EAAU2I,iBAAS,IAAA/G,OAAA,EAAAA,EAAEgH,YAAa5I,aAAQ,EAARA,EAAU6C,QAEhD,OACEpB,EAAAA,IAACZ,EAAaI,OAAAC,OAAA,CACZnB,IAAKA,EACLC,SAAUA,EACV8E,UAAWiE,EAAAA,gBACXL,UAAWA,EACXpC,YAAWrF,OAAAC,OAAA,CAET8H,UAAY,EAEZC,kBAAmB,MACnB7I,GAAEa,OAAAC,OAAA,CACAkB,QAAS,QACT0B,OAAQ,MAER,oCAAqC,CACnCkB,MAAO,mBAET,mBACE/D,OAAAC,OAAAD,OAAAC,OAAA,CAAAkB,QAAS,OACTS,MAAO,GAAG6F,MACV5E,OAAQ,MACRoF,OAAQ,OACRlG,gBAAiB,oBAEZqF,GAAoB,CACvBrE,WAAY,QAAsC,QAA9BjC,EAAA/B,aAAQ,EAARA,EAAUyD,eAAe0E,aAAK,IAAApG,EAAAA,EAAI,mBACtD,CAEF,qBAAsB,CACpBoH,UAAW,OACX,WAAY,CACVC,QAAS,YAIZ3C,IAEFC,IAEDpG,GACJ"}
@@ -1,4 +1,4 @@
1
- declare const ChipFocusVisibleStyled: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/system").Theme> & {
1
+ declare const ChipFocusVisibleStyled: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & {
2
2
  focusVisible: boolean;
3
3
  variant: any;
4
4
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const e=require("@mui/system").styled("div")((({theme:e,focusVisible:i,variant:t})=>({display:"inline-flex",borderRadius:"image"===t?6:50,transition:"none",boxShadow:i?`0 0 0 2px ${e.palette.onSurface.os900}`:void 0})));exports.default=e;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const e=require("@mui/material/styles").styled("div")((({theme:e,focusVisible:i,variant:t})=>({display:"inline-flex",borderRadius:"image"===t?6:50,transition:"none",boxShadow:i?`0 0 0 2px ${e.palette.onSurface.os900}`:void 0})));exports.default=e;
2
2
  //# sourceMappingURL=chipFocusVisibleStyled.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"chipFocusVisibleStyled.js","sources":["../../../../../src/components/chip/chipFocusVisibleStyled.tsx"],"sourcesContent":["import { styled } from '@mui/system';\n\nconst ChipFocusVisibleStyled = styled('div')<{ focusVisible: boolean; variant: any }>(({\n theme,\n focusVisible,\n variant,\n}) => {\n return {\n display: 'inline-flex',\n borderRadius: variant === 'image' ? 6 : 50,\n transition: 'none',\n boxShadow: focusVisible ? `0 0 0 2px ${theme.palette.onSurface.os900}` : undefined,\n };\n});\n\nexport default ChipFocusVisibleStyled;\n"],"names":["ChipFocusVisibleStyled","styled","theme","focusVisible","variant","display","borderRadius","transition","boxShadow","palette","onSurface","os900","undefined"],"mappings":"oEAEA,MAAMA,yBAA+BC,OAAC,MAAPA,EAAuD,EACpFC,QACAC,eACAC,cAEO,CACLC,QAAS,cACTC,aAA0B,UAAZF,EAAsB,EAAI,GACxCG,WAAY,OACZC,UAAWL,EAAe,aAAaD,EAAMO,QAAQC,UAAUC,aAAUC"}
1
+ {"version":3,"file":"chipFocusVisibleStyled.js","sources":["../../../../../src/components/chip/chipFocusVisibleStyled.tsx"],"sourcesContent":["import { styled } from '@mui/material/styles';\n\nconst ChipFocusVisibleStyled = styled('div')<{ focusVisible: boolean; variant: any }>(({\n theme,\n focusVisible,\n variant,\n}) => {\n return {\n display: 'inline-flex',\n borderRadius: variant === 'image' ? 6 : 50,\n transition: 'none',\n boxShadow: focusVisible ? `0 0 0 2px ${theme.palette.onSurface.os900}` : undefined,\n };\n});\n\nexport default ChipFocusVisibleStyled;\n"],"names":["ChipFocusVisibleStyled","styled","theme","focusVisible","variant","display","borderRadius","transition","boxShadow","palette","onSurface","os900","undefined"],"mappings":"oEAEA,MAAMA,kCAA+BC,OAAC,MAAPA,EAAuD,EACpFC,QACAC,eACAC,cAEO,CACLC,QAAS,cACTC,aAA0B,UAAZF,EAAsB,EAAI,GACxCG,WAAY,OACZC,UAAWL,EAAe,aAAaD,EAAMO,QAAQC,UAAUC,aAAUC"}
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),t=require("@mui/system"),s=require("../menu/menu.js"),n=require("./menuEmpty.js");const r=t.styled("div")((i=>{var{theme:t}=i,s=e.__rest(i,["theme"]);let n={};return n={width:s.width,marginTop:s.marginTop,transition:"0.3s ease-out",display:"inline-block",position:"absolute",zIndex:"10"},n=s.isOpen&&!s.disabled?Object.assign(Object.assign({},n),{visibility:"visible",opacity:"100%"}):Object.assign(Object.assign({},n),{visibility:"hidden",opacity:"0%"}),n}));exports.default=t=>{var{setIsOpen:l,isEmptyMenu:o}=t,a=e.__rest(t,["setIsOpen","isEmptyMenu"]);return i.jsx(r,{marginTop:a.marginTop+"px",width:a.fullWidth?"100%":a.width+"px",isOpen:a.isOpen,disabled:a.disabled,children:o?i.jsx(n.MenuEmpty,{children:a.children}):i.jsx(s.Menu,{items:a.items,hasIcon:a.hasIcon,multipleSelection:a.multipleSelection,groupToggleSelection:a.groupToggleSelection,groupLabel:a.groupLabel,reactHook:a.reactHook,setIsOpen:l,toggleLabel:a.toggleLabel})})};
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("tslib"),i=require("react/jsx-runtime"),t=require("@mui/material/styles"),s=require("../menu/menu.js"),n=require("./menuEmpty.js");const r=t.styled("div")((i=>{var{theme:t}=i,s=e.__rest(i,["theme"]);let n={};return n={width:s.width,marginTop:s.marginTop,transition:"0.3s ease-out",display:"inline-block",position:"absolute",zIndex:"10"},n=s.isOpen&&!s.disabled?Object.assign(Object.assign({},n),{visibility:"visible",opacity:"100%"}):Object.assign(Object.assign({},n),{visibility:"hidden",opacity:"0%"}),n}));exports.default=t=>{var{setIsOpen:l,isEmptyMenu:o}=t,a=e.__rest(t,["setIsOpen","isEmptyMenu"]);return i.jsx(r,{marginTop:a.marginTop+"px",width:a.fullWidth?"100%":a.width+"px",isOpen:a.isOpen,disabled:a.disabled,children:o?i.jsx(n.MenuEmpty,{children:a.children}):i.jsx(s.Menu,{items:a.items,hasIcon:a.hasIcon,multipleSelection:a.multipleSelection,groupToggleSelection:a.groupToggleSelection,groupLabel:a.groupLabel,reactHook:a.reactHook,setIsOpen:l,toggleLabel:a.toggleLabel})})};
2
2
  //# sourceMappingURL=menuContainer.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"menuContainer.js","sources":["../../../../../src/components/common/menuContainer.tsx"],"sourcesContent":["import React from 'react';\nimport { styled } from '@mui/system';\nimport { Menu, MenuReactUseStateHook, MenuItems } from '../menu';\nimport MenuEmpty from './menuEmpty';\n\nexport interface MenuContainerProps {\n disabled?: boolean;\n items?: MenuItems;\n hasIcon?: boolean;\n multipleSelection?: boolean;\n groupLabel?: string;\n reactHook?: MenuReactUseStateHook;\n groupToggleSelection?: boolean;\n isOpen?: boolean;\n marginTop?: number;\n width?: number;\n fullWidth?: boolean;\n setIsOpen?: React.Dispatch<React.SetStateAction<boolean>>;\n isEmptyMenu?: boolean;\n toggleLabel?: string;\n children?: React.ReactNode;\n}\n\nconst MenuContainer: React.FC<MenuContainerProps> = ({ setIsOpen, isEmptyMenu, ...props }) => {\n return (\n <StyledDiv\n marginTop={props.marginTop + 'px'}\n width={props.fullWidth ? '100%' : props.width + 'px'}\n isOpen={props.isOpen}\n disabled={props.disabled}\n >\n {isEmptyMenu ? (\n <MenuEmpty>{props.children}</MenuEmpty>\n ) : (\n <Menu\n items={props.items}\n hasIcon={props.hasIcon}\n multipleSelection={props.multipleSelection}\n groupToggleSelection={props.groupToggleSelection}\n groupLabel={props.groupLabel}\n reactHook={props.reactHook}\n setIsOpen={setIsOpen}\n toggleLabel={props.toggleLabel}\n />\n )}\n </StyledDiv>\n );\n};\n\nconst StyledDiv = styled('div')<{\n marginTop?: string;\n isOpen: boolean;\n disabled: boolean;\n width?: string;\n}>(({ theme, ...args }) => {\n let styles = {};\n\n styles = {\n width: args.width,\n marginTop: args.marginTop,\n transition: '0.3s ease-out',\n display: 'inline-block',\n position: 'absolute',\n zIndex: '10',\n };\n\n if (args.isOpen && !args.disabled) {\n styles = { ...styles, visibility: 'visible', opacity: '100%' };\n } else {\n styles = { ...styles, visibility: 'hidden', opacity: '0%' };\n }\n\n return styles;\n});\n\nexport default MenuContainer;\n"],"names":["StyledDiv","styled","_a","theme","args","__rest","styles","width","marginTop","transition","display","position","zIndex","isOpen","disabled","Object","assign","visibility","opacity","setIsOpen","isEmptyMenu","props","_jsx","jsx","fullWidth","children","MenuEmpty","Menu","items","hasIcon","multipleSelection","groupToggleSelection","groupLabel","reactHook","toggleLabel"],"mappings":"4MAuBA,MA0BMA,EAAYC,EAAMA,OAAC,MAAPA,EAKdC,IAAA,IAAAC,MAAEA,GAAgBD,EAANE,EAAIC,EAAAA,OAAAH,EAAhB,WACF,IAAII,EAAS,CAAE,EAiBf,OAfAA,EAAS,CACPC,MAAOH,EAAKG,MACZC,UAAWJ,EAAKI,UAChBC,WAAY,gBACZC,QAAS,eACTC,SAAU,WACVC,OAAQ,MAIRN,EADEF,EAAKS,SAAWT,EAAKU,SACjBC,OAAAC,OAAAD,OAAAC,OAAA,CAAA,EAAQV,GAAM,CAAEW,WAAY,UAAWC,QAAS,SAEhDH,OAAAC,OAAAD,OAAAC,OAAA,CAAA,EAAQV,GAAM,CAAEW,WAAY,SAAUC,QAAS,OAGhDZ,CAAM,oBAjDsCJ,QAAAiB,UAAEA,EAASC,YAAEA,GAAWlB,EAAKmB,EAAKhB,EAAAA,OAAAH,EAAlC,6BACnD,OACEoB,EAACC,IAAAvB,EACC,CAAAQ,UAAWa,EAAMb,UAAY,KAC7BD,MAAOc,EAAMG,UAAY,OAASH,EAAMd,MAAQ,KAChDM,OAAQQ,EAAMR,OACdC,SAAUO,EAAMP,SAEfW,SAAAL,EACCE,EAAAA,IAACI,EAAAA,UAAW,CAAAD,SAAAJ,EAAMI,WAElBH,EAAAA,IAACK,EAAAA,KAAI,CACHC,MAAOP,EAAMO,MACbC,QAASR,EAAMQ,QACfC,kBAAmBT,EAAMS,kBACzBC,qBAAsBV,EAAMU,qBAC5BC,WAAYX,EAAMW,WAClBC,UAAWZ,EAAMY,UACjBd,UAAWA,EACXe,YAAab,EAAMa,eAGb"}
1
+ {"version":3,"file":"menuContainer.js","sources":["../../../../../src/components/common/menuContainer.tsx"],"sourcesContent":["import React from 'react';\nimport { styled } from '@mui/material/styles';\nimport { Menu, MenuReactUseStateHook, MenuItems } from '../menu';\nimport MenuEmpty from './menuEmpty';\n\nexport interface MenuContainerProps {\n disabled?: boolean;\n items?: MenuItems;\n hasIcon?: boolean;\n multipleSelection?: boolean;\n groupLabel?: string;\n reactHook?: MenuReactUseStateHook;\n groupToggleSelection?: boolean;\n isOpen?: boolean;\n marginTop?: number;\n width?: number;\n fullWidth?: boolean;\n setIsOpen?: React.Dispatch<React.SetStateAction<boolean>>;\n isEmptyMenu?: boolean;\n toggleLabel?: string;\n children?: React.ReactNode;\n}\n\nconst MenuContainer: React.FC<MenuContainerProps> = ({ setIsOpen, isEmptyMenu, ...props }) => {\n return (\n <StyledDiv\n marginTop={props.marginTop + 'px'}\n width={props.fullWidth ? '100%' : props.width + 'px'}\n isOpen={props.isOpen}\n disabled={props.disabled}\n >\n {isEmptyMenu ? (\n <MenuEmpty>{props.children}</MenuEmpty>\n ) : (\n <Menu\n items={props.items}\n hasIcon={props.hasIcon}\n multipleSelection={props.multipleSelection}\n groupToggleSelection={props.groupToggleSelection}\n groupLabel={props.groupLabel}\n reactHook={props.reactHook}\n setIsOpen={setIsOpen}\n toggleLabel={props.toggleLabel}\n />\n )}\n </StyledDiv>\n );\n};\n\nconst StyledDiv = styled('div')<{\n marginTop?: string;\n isOpen: boolean;\n disabled: boolean;\n width?: string;\n}>(({ theme, ...args }) => {\n let styles = {};\n\n styles = {\n width: args.width,\n marginTop: args.marginTop,\n transition: '0.3s ease-out',\n display: 'inline-block',\n position: 'absolute',\n zIndex: '10',\n };\n\n if (args.isOpen && !args.disabled) {\n styles = { ...styles, visibility: 'visible', opacity: '100%' };\n } else {\n styles = { ...styles, visibility: 'hidden', opacity: '0%' };\n }\n\n return styles;\n});\n\nexport default MenuContainer;\n"],"names":["StyledDiv","styled","_a","theme","args","__rest","styles","width","marginTop","transition","display","position","zIndex","isOpen","disabled","Object","assign","visibility","opacity","setIsOpen","isEmptyMenu","props","_jsx","jsx","fullWidth","children","MenuEmpty","Menu","items","hasIcon","multipleSelection","groupToggleSelection","groupLabel","reactHook","toggleLabel"],"mappings":"qNAuBA,MA0BMA,EAAYC,EAAMA,OAAC,MAAPA,EAKdC,IAAA,IAAAC,MAAEA,GAAgBD,EAANE,EAAIC,EAAAA,OAAAH,EAAhB,WACF,IAAII,EAAS,CAAE,EAiBf,OAfAA,EAAS,CACPC,MAAOH,EAAKG,MACZC,UAAWJ,EAAKI,UAChBC,WAAY,gBACZC,QAAS,eACTC,SAAU,WACVC,OAAQ,MAIRN,EADEF,EAAKS,SAAWT,EAAKU,SACjBC,OAAAC,OAAAD,OAAAC,OAAA,CAAA,EAAQV,GAAM,CAAEW,WAAY,UAAWC,QAAS,SAEhDH,OAAAC,OAAAD,OAAAC,OAAA,CAAA,EAAQV,GAAM,CAAEW,WAAY,SAAUC,QAAS,OAGhDZ,CAAM,oBAjDsCJ,QAAAiB,UAAEA,EAASC,YAAEA,GAAWlB,EAAKmB,EAAKhB,EAAAA,OAAAH,EAAlC,6BACnD,OACEoB,EAACC,IAAAvB,EACC,CAAAQ,UAAWa,EAAMb,UAAY,KAC7BD,MAAOc,EAAMG,UAAY,OAASH,EAAMd,MAAQ,KAChDM,OAAQQ,EAAMR,OACdC,SAAUO,EAAMP,SAEfW,SAAAL,EACCE,EAAAA,IAACI,EAAAA,UAAW,CAAAD,SAAAJ,EAAMI,WAElBH,EAAAA,IAACK,EAAAA,KAAI,CACHC,MAAOP,EAAMO,MACbC,QAASR,EAAMQ,QACfC,kBAAmBT,EAAMS,kBACzBC,qBAAsBV,EAAMU,qBAC5BC,WAAYX,EAAMW,WAClBC,UAAWZ,EAAMY,UACjBd,UAAWA,EACXe,YAAab,EAAMa,eAGb"}
@@ -1,4 +1,4 @@
1
- declare const ButtonFocusVisibleStyled: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/system").Theme> & {
1
+ declare const ButtonFocusVisibleStyled: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & {
2
2
  focusVisible: boolean;
3
3
  isNavigationVariant: boolean;
4
4
  fullWidth?: boolean;
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const e=require("@mui/system").styled("div")((({theme:e,focusVisible:i,isNavigationVariant:t,fullWidth:s})=>({display:"inline-flex",padding:1,borderRadius:t?4:50,transition:"none",boxShadow:i?`0 0 0 2px ${e.palette.onSurface.os900}`:void 0,width:s?"100%":null})));exports.default=e;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});const e=require("@mui/material/styles").styled("div")((({theme:e,focusVisible:i,isNavigationVariant:t,fullWidth:s})=>({display:"inline-flex",padding:1,borderRadius:t?4:50,transition:"none",boxShadow:i?`0 0 0 2px ${e.palette.onSurface.os900}`:void 0,width:s?"100%":null})));exports.default=e;
2
2
  //# sourceMappingURL=buttonFocusVisibleStyled.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"buttonFocusVisibleStyled.js","sources":["../../../../../../src/components/common/styled/buttonFocusVisibleStyled.tsx"],"sourcesContent":["import { styled } from '@mui/system';\n\nconst ButtonFocusVisibleStyled = styled('div')<{\n focusVisible: boolean;\n isNavigationVariant: boolean;\n fullWidth?: boolean;\n}>(({ theme, focusVisible, isNavigationVariant, fullWidth }) => {\n return {\n display: 'inline-flex',\n padding: 1,\n borderRadius: isNavigationVariant ? 4 : 50,\n transition: 'none',\n boxShadow: focusVisible ? `0 0 0 2px ${theme.palette.onSurface.os900}` : undefined,\n width: fullWidth ? '100%' : null,\n };\n});\n\nexport default ButtonFocusVisibleStyled;\n"],"names":["ButtonFocusVisibleStyled","styled","theme","focusVisible","isNavigationVariant","fullWidth","display","padding","borderRadius","transition","boxShadow","palette","onSurface","os900","undefined","width"],"mappings":"oEAEA,MAAMA,yBAA2BC,OAAO,MAAPA,EAI9B,EAAGC,QAAOC,eAAcC,sBAAqBC,gBACvC,CACLC,QAAS,cACTC,QAAS,EACTC,aAAcJ,EAAsB,EAAI,GACxCK,WAAY,OACZC,UAAWP,EAAe,aAAaD,EAAMS,QAAQC,UAAUC,aAAUC,EACzEC,MAAOV,EAAY,OAAS"}
1
+ {"version":3,"file":"buttonFocusVisibleStyled.js","sources":["../../../../../../src/components/common/styled/buttonFocusVisibleStyled.tsx"],"sourcesContent":["import { styled } from '@mui/material/styles';\n\nconst ButtonFocusVisibleStyled = styled('div')<{\n focusVisible: boolean;\n isNavigationVariant: boolean;\n fullWidth?: boolean;\n}>(({ theme, focusVisible, isNavigationVariant, fullWidth }) => {\n return {\n display: 'inline-flex',\n padding: 1,\n borderRadius: isNavigationVariant ? 4 : 50,\n transition: 'none',\n boxShadow: focusVisible ? `0 0 0 2px ${theme.palette.onSurface.os900}` : undefined,\n width: fullWidth ? '100%' : null,\n };\n});\n\nexport default ButtonFocusVisibleStyled;\n"],"names":["ButtonFocusVisibleStyled","styled","theme","focusVisible","isNavigationVariant","fullWidth","display","padding","borderRadius","transition","boxShadow","palette","onSurface","os900","undefined","width"],"mappings":"oEAEA,MAAMA,kCAA2BC,OAAO,MAAPA,EAI9B,EAAGC,QAAOC,eAAcC,sBAAqBC,gBACvC,CACLC,QAAS,cACTC,QAAS,EACTC,aAAcJ,EAAsB,EAAI,GACxCK,WAAY,OACZC,UAAWP,EAAe,aAAaD,EAAMS,QAAQC,UAAUC,aAAUC,EACzEC,MAAOV,EAAY,OAAS"}
@@ -1,5 +1,5 @@
1
1
  import { FormControlLabelProps as MuiFormControlLabelProps } from '@mui/material';
2
- declare const FormControlLabelStyled: import("@emotion/styled").StyledComponent<MuiFormControlLabelProps & import("@mui/system").MUIStyledCommonProps<import("@mui/system").Theme> & {
2
+ declare const FormControlLabelStyled: import("@emotion/styled").StyledComponent<MuiFormControlLabelProps & import("@mui/system").MUIStyledCommonProps<import("@mui/material").Theme> & {
3
3
  error?: boolean;
4
4
  theme?: any;
5
5
  }, {}, {}>;
@@ -1,2 +1,2 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("@mui/system"),r=require("@mui/material");const o=e.styled(r.FormControlLabel,{shouldForwardProp:e=>"error"!==e})((({theme:e,error:r})=>({color:r?e.palette.alert.main:void 0})));exports.default=o;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("@mui/material/styles"),r=require("@mui/material");const t=e.styled(r.FormControlLabel,{shouldForwardProp:e=>"error"!==e})((({theme:e,error:r})=>({color:r?e.palette.alert.main:void 0})));exports.default=t;
2
2
  //# sourceMappingURL=formControlLabelStyled.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"formControlLabelStyled.js","sources":["../../../../../../src/components/common/styled/formControlLabelStyled.tsx"],"sourcesContent":["import { styled } from '@mui/system';\nimport {\n FormControlLabelProps as MuiFormControlLabelProps,\n FormControlLabel as MuiFormControlLabel,\n} from '@mui/material';\n\nconst FormControlLabelStyled = styled(MuiFormControlLabel, {\n shouldForwardProp: (prop) => prop !== 'error',\n})<MuiFormControlLabelProps & { error?: boolean; theme?: any }>(({ theme, error }) => {\n return {\n color: error ? theme.palette.alert['main'] : undefined,\n };\n});\n\nexport default FormControlLabelStyled;\n"],"names":["FormControlLabelStyled","styled","MuiFormControlLabel","shouldForwardProp","prop","theme","error","color","palette","alert","undefined"],"mappings":"4HAMA,MAAMA,EAAyBC,EAAMA,OAACC,mBAAqB,CACzDC,kBAAoBC,GAAkB,UAATA,GADAH,EAEiC,EAAGI,QAAOC,YACjE,CACLC,MAAOD,EAAQD,EAAMG,QAAQC,MAAY,UAAIC"}
1
+ {"version":3,"file":"formControlLabelStyled.js","sources":["../../../../../../src/components/common/styled/formControlLabelStyled.tsx"],"sourcesContent":["import { styled } from '@mui/material/styles';\nimport {\n FormControlLabelProps as MuiFormControlLabelProps,\n FormControlLabel as MuiFormControlLabel,\n} from '@mui/material';\n\nconst FormControlLabelStyled = styled(MuiFormControlLabel, {\n shouldForwardProp: (prop) => prop !== 'error',\n})<MuiFormControlLabelProps & { error?: boolean; theme?: any }>(({ theme, error }) => {\n return {\n color: error ? theme.palette.alert['main'] : undefined,\n };\n});\n\nexport default FormControlLabelStyled;\n"],"names":["FormControlLabelStyled","styled","MuiFormControlLabel","shouldForwardProp","prop","theme","error","color","palette","alert","undefined"],"mappings":"qIAMA,MAAMA,EAAyBC,EAAMA,OAACC,mBAAqB,CACzDC,kBAAoBC,GAAkB,UAATA,GADAH,EAEiC,EAAGI,QAAOC,YACjE,CACLC,MAAOD,EAAQD,EAAMG,QAAQC,MAAY,UAAIC"}
@@ -1,4 +1,4 @@
1
- declare const HelperTextContainerStyled: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/system").Theme> & {
1
+ declare const HelperTextContainerStyled: import("@emotion/styled").StyledComponent<import("@mui/system").MUIStyledCommonProps<import("@mui/material/styles").Theme> & {
2
2
  theme?: any;
3
3
  disabled?: boolean;
4
4
  hasError?: boolean;