@ubnt/store.core 9.62.0-beta.0 → 9.62.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 (832) hide show
  1. package/CHANGELOG.md +15 -591
  2. package/lib/_virtual/_virtual_multi-entry.js +2 -15
  3. package/lib/_virtual/_virtual_multi-entry.js.map +1 -1
  4. package/lib/_virtual/_virtual_multi-entry.mjs +0 -2
  5. package/lib/_virtual/_virtual_multi-entry.mjs.map +1 -1
  6. package/lib/assets/attention.svg +5 -5
  7. package/lib/assets/attention2.svg +5 -5
  8. package/lib/assets/minus4.svg +8 -8
  9. package/lib/assets/minus5.svg +8 -8
  10. package/lib/assets/plus5.svg +9 -9
  11. package/lib/assets/plus6.svg +9 -9
  12. package/lib/assets/poe2.svg +3 -2
  13. package/lib/assets/poe3.svg +2 -3
  14. package/lib/assets/port.svg +4 -2
  15. package/lib/assets/port2.svg +2 -4
  16. package/lib/assets/ucgMax.jpg +0 -0
  17. package/lib/assets/ucgMax2.jpg +0 -0
  18. package/lib/assets/ucgUltra.jpg +0 -0
  19. package/lib/assets/ucgUltra2.jpg +0 -0
  20. package/lib/assets/udmPro.jpg +0 -0
  21. package/lib/assets/udmPro2.jpg +0 -0
  22. package/lib/assets/udmProMax.jpg +0 -0
  23. package/lib/assets/udmProMax2.jpg +0 -0
  24. package/lib/assets/udmProSpecial.jpg +0 -0
  25. package/lib/assets/udmProSpecial2.jpg +0 -0
  26. package/lib/components/Accordion/Accordion.js +9 -9
  27. package/lib/components/Accordion/Accordion.js.map +1 -1
  28. package/lib/components/Accordion/Accordion.mjs +9 -9
  29. package/lib/components/Accordion/Accordion.mjs.map +1 -1
  30. package/lib/components/Accordion/Accordion.styles.d.ts +18 -18
  31. package/lib/components/Accordion/Accordion.styles.js +22 -28
  32. package/lib/components/Accordion/Accordion.styles.js.map +1 -1
  33. package/lib/components/Accordion/Accordion.styles.mjs +22 -28
  34. package/lib/components/Accordion/Accordion.styles.mjs.map +1 -1
  35. package/lib/components/AppDownloadBanner/AppDownloadBanner.styles.d.ts +21 -23
  36. package/lib/components/Avatar/Avatar.js +3 -4
  37. package/lib/components/Avatar/Avatar.js.map +1 -1
  38. package/lib/components/Avatar/Avatar.mjs +3 -4
  39. package/lib/components/Avatar/Avatar.mjs.map +1 -1
  40. package/lib/components/Avatar/Avatar.styles.d.ts +2 -2
  41. package/lib/components/BackInStock/BackInStock.styles.d.ts +7 -12
  42. package/lib/components/BackInStock/BackInStock.types.d.ts +0 -1
  43. package/lib/components/Badge/Badge.styles.d.ts +2 -2
  44. package/lib/components/Banner/Banner.js +4 -4
  45. package/lib/components/Banner/Banner.js.map +1 -1
  46. package/lib/components/Banner/Banner.mjs +4 -4
  47. package/lib/components/Banner/Banner.mjs.map +1 -1
  48. package/lib/components/Banner/Banner.styles.d.ts +16 -16
  49. package/lib/components/Banner/Banner.styles.js +9 -9
  50. package/lib/components/Banner/Banner.styles.js.map +1 -1
  51. package/lib/components/Banner/Banner.styles.mjs +9 -9
  52. package/lib/components/Banner/Banner.styles.mjs.map +1 -1
  53. package/lib/components/Breadcrumbs/Breadcrumbs.styles.d.ts +2 -2
  54. package/lib/components/BuiltFeaturesSection/BuiltFeaturesSection.styles.d.ts +9 -9
  55. package/lib/components/Button/Button.styles.d.ts +4 -4
  56. package/lib/components/ButtonGroup/ButtonGroup.js +5 -5
  57. package/lib/components/ButtonGroup/ButtonGroup.js.map +1 -1
  58. package/lib/components/ButtonGroup/ButtonGroup.mjs +5 -5
  59. package/lib/components/ButtonGroup/ButtonGroup.mjs.map +1 -1
  60. package/lib/components/ButtonGroup/ButtonGroup.styles.d.ts +13 -13
  61. package/lib/components/ButtonGroup/ButtonGroup.styles.js +15 -15
  62. package/lib/components/ButtonGroup/ButtonGroup.styles.js.map +1 -1
  63. package/lib/components/ButtonGroup/ButtonGroup.styles.mjs +15 -15
  64. package/lib/components/ButtonGroup/ButtonGroup.styles.mjs.map +1 -1
  65. package/lib/components/ButtonGroupBasic/ButtonGroupBasic.d.ts +1 -1
  66. package/lib/components/ButtonGroupBasic/ButtonGroupBasic.js +4 -16
  67. package/lib/components/ButtonGroupBasic/ButtonGroupBasic.js.map +1 -1
  68. package/lib/components/ButtonGroupBasic/ButtonGroupBasic.mjs +5 -17
  69. package/lib/components/ButtonGroupBasic/ButtonGroupBasic.mjs.map +1 -1
  70. package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.d.ts +4 -8
  71. package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.js +17 -82
  72. package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.js.map +1 -1
  73. package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.mjs +17 -82
  74. package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.mjs.map +1 -1
  75. package/lib/components/ButtonGroupBasic/ButtonGroupBasic.types.d.ts +0 -4
  76. package/lib/components/CardSection/Card/Card.js +11 -10
  77. package/lib/components/CardSection/Card/Card.js.map +1 -1
  78. package/lib/components/CardSection/Card/Card.mjs +11 -10
  79. package/lib/components/CardSection/Card/Card.mjs.map +1 -1
  80. package/lib/components/CardSection/Card/Card.styles.d.ts +21 -21
  81. package/lib/components/CardSection/Card/Card.styles.js +22 -22
  82. package/lib/components/CardSection/Card/Card.styles.js.map +1 -1
  83. package/lib/components/CardSection/Card/Card.styles.mjs +22 -22
  84. package/lib/components/CardSection/Card/Card.styles.mjs.map +1 -1
  85. package/lib/components/CardSection/CardSection.styles.d.ts +4 -4
  86. package/lib/components/CarouselGallery/CarouselGallery.styles.d.ts +11 -11
  87. package/lib/components/CartIcon/CartIcon.js +2 -2
  88. package/lib/components/CartIcon/CartIcon.js.map +1 -1
  89. package/lib/components/CartIcon/CartIcon.mjs +2 -2
  90. package/lib/components/CartIcon/CartIcon.mjs.map +1 -1
  91. package/lib/components/CartIcon/CartIcon.styles.d.ts +5 -5
  92. package/lib/components/CartIcon/CartIcon.styles.js +4 -4
  93. package/lib/components/CartIcon/CartIcon.styles.js.map +1 -1
  94. package/lib/components/CartIcon/CartIcon.styles.mjs +4 -4
  95. package/lib/components/CartIcon/CartIcon.styles.mjs.map +1 -1
  96. package/lib/components/CartSummary/CartSummary.js +1 -1
  97. package/lib/components/CartSummary/CartSummary.js.map +1 -1
  98. package/lib/components/CartSummary/CartSummary.mjs +1 -1
  99. package/lib/components/CartSummary/CartSummary.mjs.map +1 -1
  100. package/lib/components/CartSummary/CartSummary.styles.d.ts +13 -19
  101. package/lib/components/CartSummary/CartSummary.styles.js +2 -2
  102. package/lib/components/CartSummary/CartSummary.styles.js.map +1 -1
  103. package/lib/components/CartSummary/CartSummary.styles.mjs +2 -2
  104. package/lib/components/CartSummary/CartSummary.styles.mjs.map +1 -1
  105. package/lib/components/CategoryTabs/CategoryTabs.styles.d.ts +6 -6
  106. package/lib/components/CategoryTabs/CategoryTabs.styles.js +1 -1
  107. package/lib/components/CategoryTabs/CategoryTabs.styles.js.map +1 -1
  108. package/lib/components/CategoryTabs/CategoryTabs.styles.mjs +1 -1
  109. package/lib/components/CategoryTabs/CategoryTabs.styles.mjs.map +1 -1
  110. package/lib/components/Checkbox/Checkbox.js +0 -3
  111. package/lib/components/Checkbox/Checkbox.js.map +1 -1
  112. package/lib/components/Checkbox/Checkbox.mjs +0 -3
  113. package/lib/components/Checkbox/Checkbox.mjs.map +1 -1
  114. package/lib/components/Checkbox/Checkbox.styles.d.ts +3 -3
  115. package/lib/components/Checkbox/Checkbox.types.d.ts +1 -1
  116. package/lib/components/CloserLookSection/CloserLookSection.styles.d.ts +8 -8
  117. package/lib/components/CloserLookSection/RecommendedAddons/RecommendedAddons.styles.d.ts +3 -3
  118. package/lib/components/Compare/Compare.styles.d.ts +34 -36
  119. package/lib/components/CompareChart/CompareChart.styles.d.ts +36 -40
  120. package/lib/components/CompareSection/CompareSection.styles.d.ts +16 -18
  121. package/lib/components/Container/Container.styles.d.ts +3 -3
  122. package/lib/components/CustomImage/CustomImage.styles.d.ts +12 -12
  123. package/lib/components/DeploymentGallery/DeploymentGallery.styles.d.ts +4 -4
  124. package/lib/components/Explore/Explore.styles.d.ts +28 -36
  125. package/lib/components/Explore/Explore.styles.js +6 -6
  126. package/lib/components/Explore/Explore.styles.js.map +1 -1
  127. package/lib/components/Explore/Explore.styles.mjs +6 -6
  128. package/lib/components/Explore/Explore.styles.mjs.map +1 -1
  129. package/lib/components/Explore/ExploreData.js +12 -12
  130. package/lib/components/Explore/ExploreData.js.map +1 -1
  131. package/lib/components/Explore/ExploreData.mjs +12 -12
  132. package/lib/components/Explore/ExploreData.mjs.map +1 -1
  133. package/lib/components/FeaturesSection_deprecated/AllFeaturesButton/AllFeaturesButton.styles.d.ts +3 -5
  134. package/lib/components/FeaturesSection_deprecated/Features/Features.styles.d.ts +15 -15
  135. package/lib/components/FeaturesSection_deprecated/FeaturesSection.styles.d.ts +22 -22
  136. package/lib/components/Footer/Footer.js +1 -0
  137. package/lib/components/Footer/Footer.js.map +1 -1
  138. package/lib/components/Footer/Footer.mjs +1 -0
  139. package/lib/components/Footer/Footer.mjs.map +1 -1
  140. package/lib/components/Footer/Footer.styles.d.ts +34 -39
  141. package/lib/components/Footer/Footer.styles.js +1 -1
  142. package/lib/components/Footer/Footer.styles.js.map +1 -1
  143. package/lib/components/Footer/Footer.styles.mjs +1 -1
  144. package/lib/components/Footer/Footer.styles.mjs.map +1 -1
  145. package/lib/components/Gallery/Gallery.js +1 -1
  146. package/lib/components/Gallery/Gallery.js.map +1 -1
  147. package/lib/components/Gallery/Gallery.mjs +1 -1
  148. package/lib/components/Gallery/Gallery.mjs.map +1 -1
  149. package/lib/components/Gallery/Gallery.styles.d.ts +8 -12
  150. package/lib/components/Gallery/Gallery.styles.js +1 -3
  151. package/lib/components/Gallery/Gallery.styles.js.map +1 -1
  152. package/lib/components/Gallery/Gallery.styles.mjs +1 -3
  153. package/lib/components/Gallery/Gallery.styles.mjs.map +1 -1
  154. package/lib/components/Gallery/GalleryControls/GalleryControls.js +1 -1
  155. package/lib/components/Gallery/GalleryControls/GalleryControls.js.map +1 -1
  156. package/lib/components/Gallery/GalleryControls/GalleryControls.mjs +1 -1
  157. package/lib/components/Gallery/GalleryControls/GalleryControls.mjs.map +1 -1
  158. package/lib/components/Gallery/GalleryControls/GalleryControls.styles.d.ts +9 -9
  159. package/lib/components/Gallery/GalleryControls/GalleryControls.styles.js +2 -2
  160. package/lib/components/Gallery/GalleryControls/GalleryControls.styles.js.map +1 -1
  161. package/lib/components/Gallery/GalleryControls/GalleryControls.styles.mjs +2 -2
  162. package/lib/components/Gallery/GalleryControls/GalleryControls.styles.mjs.map +1 -1
  163. package/lib/components/Gallery/GalleryItem/GalleryItem.js +5 -5
  164. package/lib/components/Gallery/GalleryItem/GalleryItem.js.map +1 -1
  165. package/lib/components/Gallery/GalleryItem/GalleryItem.mjs +5 -5
  166. package/lib/components/Gallery/GalleryItem/GalleryItem.mjs.map +1 -1
  167. package/lib/components/Gallery/GalleryItem/GalleryItem.styles.d.ts +10 -10
  168. package/lib/components/Gallery/GalleryItem/GalleryItem.styles.js +11 -11
  169. package/lib/components/Gallery/GalleryItem/GalleryItem.styles.js.map +1 -1
  170. package/lib/components/Gallery/GalleryItem/GalleryItem.styles.mjs +11 -11
  171. package/lib/components/Gallery/GalleryItem/GalleryItem.styles.mjs.map +1 -1
  172. package/lib/components/Gallery/GalleryThumbnails/GalleryThumbnails.styles.d.ts +8 -8
  173. package/lib/components/GradientButton/GradientButton.d.ts +1 -1
  174. package/lib/components/GradientButton/GradientButton.js +0 -2
  175. package/lib/components/GradientButton/GradientButton.js.map +1 -1
  176. package/lib/components/GradientButton/GradientButton.mjs +0 -2
  177. package/lib/components/GradientButton/GradientButton.mjs.map +1 -1
  178. package/lib/components/GradientButton/GradientButton.styles.d.ts +4 -4
  179. package/lib/components/GradientButton/GradientButton.styles.js +6 -6
  180. package/lib/components/GradientButton/GradientButton.styles.js.map +1 -1
  181. package/lib/components/GradientButton/GradientButton.styles.mjs +6 -6
  182. package/lib/components/GradientButton/GradientButton.styles.mjs.map +1 -1
  183. package/lib/components/GridGallery/GridGallery.js +1 -1
  184. package/lib/components/GridGallery/GridGallery.js.map +1 -1
  185. package/lib/components/GridGallery/GridGallery.mjs +1 -1
  186. package/lib/components/GridGallery/GridGallery.mjs.map +1 -1
  187. package/lib/components/GridGallery/GridGallery.styles.d.ts +13 -13
  188. package/lib/components/GridGallery/GridGallery.styles.js +2 -2
  189. package/lib/components/GridGallery/GridGallery.styles.js.map +1 -1
  190. package/lib/components/GridGallery/GridGallery.styles.mjs +2 -2
  191. package/lib/components/GridGallery/GridGallery.styles.mjs.map +1 -1
  192. package/lib/components/GridGallery/GridModal/GridModal.js +1 -1
  193. package/lib/components/GridGallery/GridModal/GridModal.js.map +1 -1
  194. package/lib/components/GridGallery/GridModal/GridModal.mjs +1 -1
  195. package/lib/components/GridGallery/GridModal/GridModal.mjs.map +1 -1
  196. package/lib/components/GridGallery/GridModal/GridModal.styles.d.ts +7 -7
  197. package/lib/components/GridGallery/GridModal/GridModal.styles.js +4 -4
  198. package/lib/components/GridGallery/GridModal/GridModal.styles.js.map +1 -1
  199. package/lib/components/GridGallery/GridModal/GridModal.styles.mjs +4 -4
  200. package/lib/components/GridGallery/GridModal/GridModal.styles.mjs.map +1 -1
  201. package/lib/components/Header/AccountFrame/AccountFrame.js +1 -1
  202. package/lib/components/Header/AccountFrame/AccountFrame.js.map +1 -1
  203. package/lib/components/Header/AccountFrame/AccountFrame.mjs +1 -1
  204. package/lib/components/Header/AccountFrame/AccountFrame.mjs.map +1 -1
  205. package/lib/components/Header/AccountFrame/AccountFrame.styles.d.ts +15 -19
  206. package/lib/components/Header/AccountFrame/AccountFrame.styles.js +2 -2
  207. package/lib/components/Header/AccountFrame/AccountFrame.styles.js.map +1 -1
  208. package/lib/components/Header/AccountFrame/AccountFrame.styles.mjs +2 -2
  209. package/lib/components/Header/AccountFrame/AccountFrame.styles.mjs.map +1 -1
  210. package/lib/components/Header/AccountFrame/Mobile/Mobile.styles.d.ts +3 -3
  211. package/lib/components/Header/AccountMenu/AccountMenu.styles.d.ts +12 -30
  212. package/lib/components/Header/CartModal/CartModal.styles.d.ts +13 -15
  213. package/lib/components/Header/CartModal/Empty/Empty.styles.d.ts +1 -1
  214. package/lib/components/Header/CartModal/Item/Item.styles.d.ts +10 -10
  215. package/lib/components/Header/CartModalV2/CartModal.styles.d.ts +21 -23
  216. package/lib/components/Header/CartModalV2/Item/Item.styles.d.ts +13 -13
  217. package/lib/components/Header/Header.js +3 -3
  218. package/lib/components/Header/Header.js.map +1 -1
  219. package/lib/components/Header/Header.mjs +3 -3
  220. package/lib/components/Header/Header.mjs.map +1 -1
  221. package/lib/components/Header/Header.styles.d.ts +41 -45
  222. package/lib/components/Header/Header.styles.js +1 -1
  223. package/lib/components/Header/Header.styles.js.map +1 -1
  224. package/lib/components/Header/Header.styles.mjs +1 -1
  225. package/lib/components/Header/Header.styles.mjs.map +1 -1
  226. package/lib/components/Header/LanguageFrame/LanguageFrame.styles.d.ts +17 -14
  227. package/lib/components/Header/LanguageFrame/LanguageFrame.styles.js +51 -0
  228. package/lib/components/Header/LanguageFrame/LanguageFrame.styles.js.map +1 -1
  229. package/lib/components/Header/LanguageFrame/LanguageFrame.styles.mjs +47 -1
  230. package/lib/components/Header/LanguageFrame/LanguageFrame.styles.mjs.map +1 -1
  231. package/lib/components/Header/LanguageFrame/Mobile/Mobile.styles.d.ts +3 -3
  232. package/lib/components/Header/LinksModal/LinksModal.styles.d.ts +4 -4
  233. package/lib/components/Header/MenuItem/MenuItem.js +5 -4
  234. package/lib/components/Header/MenuItem/MenuItem.js.map +1 -1
  235. package/lib/components/Header/MenuItem/MenuItem.mjs +5 -4
  236. package/lib/components/Header/MenuItem/MenuItem.mjs.map +1 -1
  237. package/lib/components/Header/MenuItem/MenuItem.styles.d.ts +15 -15
  238. package/lib/components/Header/MenuItem/MenuItem.styles.js +8 -8
  239. package/lib/components/Header/MenuItem/MenuItem.styles.js.map +1 -1
  240. package/lib/components/Header/MenuItem/MenuItem.styles.mjs +8 -8
  241. package/lib/components/Header/MenuItem/MenuItem.styles.mjs.map +1 -1
  242. package/lib/components/Header/Navigation/Carousel/Carousel.js +6 -6
  243. package/lib/components/Header/Navigation/Carousel/Carousel.js.map +1 -1
  244. package/lib/components/Header/Navigation/Carousel/Carousel.mjs +6 -6
  245. package/lib/components/Header/Navigation/Carousel/Carousel.mjs.map +1 -1
  246. package/lib/components/Header/Navigation/Carousel/Carousel.styles.d.ts +20 -20
  247. package/lib/components/Header/Navigation/Carousel/Carousel.styles.js +16 -16
  248. package/lib/components/Header/Navigation/Carousel/Carousel.styles.js.map +1 -1
  249. package/lib/components/Header/Navigation/Carousel/Carousel.styles.mjs +16 -16
  250. package/lib/components/Header/Navigation/Carousel/Carousel.styles.mjs.map +1 -1
  251. package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.js +7 -7
  252. package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.js.map +1 -1
  253. package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.mjs +7 -7
  254. package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.mjs.map +1 -1
  255. package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.styles.d.ts +23 -29
  256. package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.styles.js +19 -19
  257. package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.styles.js.map +1 -1
  258. package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.styles.mjs +19 -19
  259. package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.styles.mjs.map +1 -1
  260. package/lib/components/Header/Navigation/MobileMenu/MobileMenu.js +9 -9
  261. package/lib/components/Header/Navigation/MobileMenu/MobileMenu.js.map +1 -1
  262. package/lib/components/Header/Navigation/MobileMenu/MobileMenu.mjs +9 -9
  263. package/lib/components/Header/Navigation/MobileMenu/MobileMenu.mjs.map +1 -1
  264. package/lib/components/Header/Navigation/MobileMenu/MobileMenu.styles.d.ts +36 -40
  265. package/lib/components/Header/Navigation/MobileMenu/MobileMenu.styles.js +18 -18
  266. package/lib/components/Header/Navigation/MobileMenu/MobileMenu.styles.js.map +1 -1
  267. package/lib/components/Header/Navigation/MobileMenu/MobileMenu.styles.mjs +18 -18
  268. package/lib/components/Header/Navigation/MobileMenu/MobileMenu.styles.mjs.map +1 -1
  269. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.js +9 -9
  270. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.js.map +1 -1
  271. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.mjs +9 -9
  272. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.mjs.map +1 -1
  273. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.d.ts +5 -7
  274. package/lib/components/Header/Overlay/Overlay.styles.d.ts +2 -2
  275. package/lib/components/Header/ProHeader/ProHeader.styles.d.ts +28 -34
  276. package/lib/components/Header/ProHeader/ProHeader.styles.js +2 -2
  277. package/lib/components/Header/ProHeader/ProHeader.styles.js.map +1 -1
  278. package/lib/components/Header/ProHeader/ProHeader.styles.mjs +2 -2
  279. package/lib/components/Header/ProHeader/ProHeader.styles.mjs.map +1 -1
  280. package/lib/components/Header/SearchTab/SearchTab.styles.d.ts +3 -3
  281. package/lib/components/Hero/Hero.styles.d.ts +28 -28
  282. package/lib/components/HeroFadeGallery/HeroFadeGallery.styles.d.ts +12 -12
  283. package/lib/components/HeroVideo/HeroVideo.styles.d.ts +7 -7
  284. package/lib/components/HowToUseSection/HowToUseSection.styles.d.ts +14 -14
  285. package/lib/components/ImageCarousel/ImageCarousel.styles.d.ts +34 -38
  286. package/lib/components/ImageCarousel/ImageCarousel.styles.js +4 -5
  287. package/lib/components/ImageCarousel/ImageCarousel.styles.js.map +1 -1
  288. package/lib/components/ImageCarousel/ImageCarousel.styles.mjs +4 -5
  289. package/lib/components/ImageCarousel/ImageCarousel.styles.mjs.map +1 -1
  290. package/lib/components/ImageModal/ImageModal.styles.d.ts +6 -8
  291. package/lib/components/ImageSequence/ImageSequence.styles.d.ts +8 -8
  292. package/lib/components/InputSelect/InputSelect.styles.d.ts +8 -4
  293. package/lib/components/LandingPage/Block/Block.styles.d.ts +4 -4
  294. package/lib/components/LandingPage/Cards/Card/Card.styles.d.ts +17 -17
  295. package/lib/components/LandingPage/Cards/Cards.styles.d.ts +9 -9
  296. package/lib/components/LandingPage/Cards/Cards.styles.js +1 -1
  297. package/lib/components/LandingPage/Cards/Cards.styles.js.map +1 -1
  298. package/lib/components/LandingPage/Cards/Cards.styles.mjs +1 -1
  299. package/lib/components/LandingPage/Cards/Cards.styles.mjs.map +1 -1
  300. package/lib/components/LandingPage/LandingPage.styles.d.ts +5 -5
  301. package/lib/components/LandingPagePro/LandingPagePro.styles.d.ts +3 -3
  302. package/lib/components/LandingPageSearch/LandingPageSearch.styles.d.ts +2 -2
  303. package/lib/components/LandingPageSearch/Modal/Modal.styles.d.ts +22 -26
  304. package/lib/components/LandingPageSidebar/LandingPageSidebar.styles.d.ts +22 -22
  305. package/lib/components/LayoutRenderer/LayoutRenderer.styles.d.ts +21 -23
  306. package/lib/components/LayoutRendererV1/LayoutRenderer.styles.d.ts +54 -60
  307. package/lib/components/LayoutRendererV2/LayoutRenderer.styles.d.ts +49 -57
  308. package/lib/components/LearnMoreLink/LearnMoreLink.styles.d.ts +2 -2
  309. package/lib/components/Loader/Loader.styles.d.ts +4 -4
  310. package/lib/components/Loader/Spinner/Spinner.styles.d.ts +3 -3
  311. package/lib/components/LoaderDots/LoaderDots.styles.d.ts +2 -2
  312. package/lib/components/MeetUniFiVideoPlayer/EpisodeCard/EpisodeCard.styles.d.ts +9 -11
  313. package/lib/components/MeetUniFiVideoPlayer/MeetUniFiVideoPlayer.styles.d.ts +25 -25
  314. package/lib/components/MicrositeBuyButton/MicrositeBuyButton.js +2 -2
  315. package/lib/components/MicrositeBuyButton/MicrositeBuyButton.js.map +1 -1
  316. package/lib/components/MicrositeBuyButton/MicrositeBuyButton.mjs +2 -2
  317. package/lib/components/MicrositeBuyButton/MicrositeBuyButton.mjs.map +1 -1
  318. package/lib/components/MicrositeColumnFeatureProgressBar/MicrositeColumnFeatureProgressBar.styles.d.ts +6 -6
  319. package/lib/components/MicrositeExploreCards/MicrositeExploreCards.styles.d.ts +8 -8
  320. package/lib/components/MicrositeFeatureChecklist/MicrositeFeatureChecklist.styles.d.ts +18 -20
  321. package/lib/components/MicrositeFeatureChecklist/MicrositeFeatureChecklist.styles.js +2 -2
  322. package/lib/components/MicrositeFeatureChecklist/MicrositeFeatureChecklist.styles.js.map +1 -1
  323. package/lib/components/MicrositeFeatureChecklist/MicrositeFeatureChecklist.styles.mjs +2 -2
  324. package/lib/components/MicrositeFeatureChecklist/MicrositeFeatureChecklist.styles.mjs.map +1 -1
  325. package/lib/components/MicrositeFeatureIcons/MicrositeFeatureIcons.styles.d.ts +11 -11
  326. package/lib/components/MicrositeFeatureList/MicrositeFeatureList.styles.d.ts +14 -14
  327. package/lib/components/MicrositeFeatureProgressBar/MicrositeFeatureProgressBar.styles.d.ts +24 -28
  328. package/lib/components/MicrositeFeatureProgressBar/MicrositeFeatureProgressBar.styles.js +2 -2
  329. package/lib/components/MicrositeFeatureProgressBar/MicrositeFeatureProgressBar.styles.js.map +1 -1
  330. package/lib/components/MicrositeFeatureProgressBar/MicrositeFeatureProgressBar.styles.mjs +2 -2
  331. package/lib/components/MicrositeFeatureProgressBar/MicrositeFeatureProgressBar.styles.mjs.map +1 -1
  332. package/lib/components/MicrositeHero/MicrositeHero.styles.d.ts +41 -41
  333. package/lib/components/MicrositeIntroductionBlock/MicrositeIntroductionBlock.styles.d.ts +6 -6
  334. package/lib/components/MicrositeMediaGrid/MicrositeMediaGrid.styles.d.ts +15 -15
  335. package/lib/components/MicrositeProductGrid/MicrositeProductGrid.styles.d.ts +15 -15
  336. package/lib/components/MicrositeProductLearnMoreBlock/MicrositeProductLearnMoreBlock.styles.d.ts +12 -14
  337. package/lib/components/MicrositeProductLearnMoreBlock/MicrositeProductLearnMoreBlock.styles.js +2 -2
  338. package/lib/components/MicrositeProductLearnMoreBlock/MicrositeProductLearnMoreBlock.styles.js.map +1 -1
  339. package/lib/components/MicrositeProductLearnMoreBlock/MicrositeProductLearnMoreBlock.styles.mjs +2 -2
  340. package/lib/components/MicrositeProductLearnMoreBlock/MicrositeProductLearnMoreBlock.styles.mjs.map +1 -1
  341. package/lib/components/MicrositeSection/AllFeaturesButton/AllFeaturesButton.styles.d.ts +3 -5
  342. package/lib/components/MicrositeSection/Features/Features.styles.d.ts +15 -15
  343. package/lib/components/MicrositeSection/MicrositeSection.styles.d.ts +24 -24
  344. package/lib/components/MicrositeSectionWrap/MicrositeSectionWrap.styles.d.ts +6 -8
  345. package/lib/components/MicrositeSubSubNavigation/MicrositeSubSubNavigation.styles.d.ts +2 -2
  346. package/lib/components/MicrositeVideoSlideshow/MicrositeVideoSlideshow.styles.d.ts +17 -17
  347. package/lib/components/Microsites/MicrositeProductPage.styles.d.ts +8 -16
  348. package/lib/components/MobileModal/MobileModal.styles.d.ts +8 -8
  349. package/lib/components/Modal/Modal.styles.d.ts +1 -1
  350. package/lib/components/ModelCompareV3/ModelCompareV3.styles.d.ts +34 -84
  351. package/lib/components/ModelCompareV3/ModelCompareV3.styles.js +7 -8
  352. package/lib/components/ModelCompareV3/ModelCompareV3.styles.js.map +1 -1
  353. package/lib/components/ModelCompareV3/ModelCompareV3.styles.mjs +7 -8
  354. package/lib/components/ModelCompareV3/ModelCompareV3.styles.mjs.map +1 -1
  355. package/lib/components/ModelCompareV3/ModelCompareV3.types.d.ts +0 -1
  356. package/lib/components/ModelCompareV3/StickyGrid/StickyGridItem.d.ts +2 -2
  357. package/lib/components/ModelCompareV3/StickyGrid/StickyGridOverlay.d.ts +1 -1
  358. package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/ucgMax.jpg.js +5 -5
  359. package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/ucgMax.jpg.mjs +2 -2
  360. package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/ucgUltra.jpg.js +5 -5
  361. package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/ucgUltra.jpg.mjs +2 -2
  362. package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmPro.jpg.js +5 -5
  363. package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmPro.jpg.mjs +2 -2
  364. package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProMax.jpg.js +5 -5
  365. package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProMax.jpg.mjs +2 -2
  366. package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProSpecial.jpg.js +5 -5
  367. package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProSpecial.jpg.mjs +2 -2
  368. package/lib/components/ModelCompareV3/assets/Consoles/ucgMax.jpg.js +1 -1
  369. package/lib/components/ModelCompareV3/assets/Consoles/ucgMax.jpg.mjs +2 -2
  370. package/lib/components/ModelCompareV3/assets/Consoles/ucgUltra.jpg.js +1 -1
  371. package/lib/components/ModelCompareV3/assets/Consoles/ucgUltra.jpg.mjs +2 -2
  372. package/lib/components/ModelCompareV3/assets/Consoles/udmPro.jpg.js +1 -1
  373. package/lib/components/ModelCompareV3/assets/Consoles/udmPro.jpg.mjs +2 -2
  374. package/lib/components/ModelCompareV3/assets/Consoles/udmProMax.jpg.js +1 -1
  375. package/lib/components/ModelCompareV3/assets/Consoles/udmProMax.jpg.mjs +2 -2
  376. package/lib/components/ModelCompareV3/assets/Consoles/udmProSpecial.jpg.js +1 -1
  377. package/lib/components/ModelCompareV3/assets/Consoles/udmProSpecial.jpg.mjs +2 -2
  378. package/lib/components/ModelCompareV3/assets/poe.svg.js +1 -1
  379. package/lib/components/ModelCompareV3/assets/poe.svg.mjs +2 -2
  380. package/lib/components/ModelCompareV3/assets/port.svg.js +1 -1
  381. package/lib/components/ModelCompareV3/assets/port.svg.mjs +2 -2
  382. package/lib/components/ModelCompareV3/data/CloudGateways.js +15 -15
  383. package/lib/components/ModelCompareV3/data/CloudGateways.mjs +10 -10
  384. package/lib/components/ModelCompareV3/data/EnterpriseSwitching.js +2 -3
  385. package/lib/components/ModelCompareV3/data/EnterpriseSwitching.js.map +1 -1
  386. package/lib/components/ModelCompareV3/data/EnterpriseSwitching.mjs +2 -3
  387. package/lib/components/ModelCompareV3/data/EnterpriseSwitching.mjs.map +1 -1
  388. package/lib/components/ModelCompareV3/data/ProfessionalMaxSwitching.js +3 -10
  389. package/lib/components/ModelCompareV3/data/ProfessionalMaxSwitching.js.map +1 -1
  390. package/lib/components/ModelCompareV3/data/ProfessionalMaxSwitching.mjs +3 -10
  391. package/lib/components/ModelCompareV3/data/ProfessionalMaxSwitching.mjs.map +1 -1
  392. package/lib/components/ModelCompareV3/data/Switching.js +2 -3
  393. package/lib/components/ModelCompareV3/data/Switching.js.map +1 -1
  394. package/lib/components/ModelCompareV3/data/Switching.mjs +2 -3
  395. package/lib/components/ModelCompareV3/data/Switching.mjs.map +1 -1
  396. package/lib/components/ModelCompareV3/data/products/aggregation.js +0 -7
  397. package/lib/components/ModelCompareV3/data/products/aggregation.js.map +1 -1
  398. package/lib/components/ModelCompareV3/data/products/aggregation.mjs +0 -7
  399. package/lib/components/ModelCompareV3/data/products/aggregation.mjs.map +1 -1
  400. package/lib/components/ModelCompareV3/data/products/cloudKeyEnterprise.js +2 -4
  401. package/lib/components/ModelCompareV3/data/products/cloudKeyEnterprise.js.map +1 -1
  402. package/lib/components/ModelCompareV3/data/products/cloudKeyEnterprise.mjs +2 -4
  403. package/lib/components/ModelCompareV3/data/products/cloudKeyEnterprise.mjs.map +1 -1
  404. package/lib/components/ModelCompareV3/data/products/cloudKeyG2Plus.js +2 -2
  405. package/lib/components/ModelCompareV3/data/products/cloudKeyG2Plus.js.map +1 -1
  406. package/lib/components/ModelCompareV3/data/products/cloudKeyG2Plus.mjs +2 -2
  407. package/lib/components/ModelCompareV3/data/products/cloudKeyG2Plus.mjs.map +1 -1
  408. package/lib/components/ModelCompareV3/data/products/enterpriseAggregation.js +0 -7
  409. package/lib/components/ModelCompareV3/data/products/enterpriseAggregation.js.map +1 -1
  410. package/lib/components/ModelCompareV3/data/products/enterpriseAggregation.mjs +0 -7
  411. package/lib/components/ModelCompareV3/data/products/enterpriseAggregation.mjs.map +1 -1
  412. package/lib/components/ModelCompareV3/data/products/enterpriseCampus24PoE.js +0 -7
  413. package/lib/components/ModelCompareV3/data/products/enterpriseCampus24PoE.js.map +1 -1
  414. package/lib/components/ModelCompareV3/data/products/enterpriseCampus24PoE.mjs +0 -7
  415. package/lib/components/ModelCompareV3/data/products/enterpriseCampus24PoE.mjs.map +1 -1
  416. package/lib/components/ModelCompareV3/data/products/enterpriseCampus48PoE.js +0 -7
  417. package/lib/components/ModelCompareV3/data/products/enterpriseCampus48PoE.js.map +1 -1
  418. package/lib/components/ModelCompareV3/data/products/enterpriseCampus48PoE.mjs +0 -7
  419. package/lib/components/ModelCompareV3/data/products/enterpriseCampus48PoE.mjs.map +1 -1
  420. package/lib/components/ModelCompareV3/data/products/express.js +3 -3
  421. package/lib/components/ModelCompareV3/data/products/express.js.map +1 -1
  422. package/lib/components/ModelCompareV3/data/products/express.mjs +3 -3
  423. package/lib/components/ModelCompareV3/data/products/express.mjs.map +1 -1
  424. package/lib/components/ModelCompareV3/data/products/g4Instant.js +2 -2
  425. package/lib/components/ModelCompareV3/data/products/g4Instant.js.map +1 -1
  426. package/lib/components/ModelCompareV3/data/products/g4Instant.mjs +2 -2
  427. package/lib/components/ModelCompareV3/data/products/g4Instant.mjs.map +1 -1
  428. package/lib/components/ModelCompareV3/data/products/gatewayEnterprise.js +2 -4
  429. package/lib/components/ModelCompareV3/data/products/gatewayEnterprise.js.map +1 -1
  430. package/lib/components/ModelCompareV3/data/products/gatewayEnterprise.mjs +2 -4
  431. package/lib/components/ModelCompareV3/data/products/gatewayEnterprise.mjs.map +1 -1
  432. package/lib/components/ModelCompareV3/data/products/gatewayLite.js +2 -4
  433. package/lib/components/ModelCompareV3/data/products/gatewayLite.js.map +1 -1
  434. package/lib/components/ModelCompareV3/data/products/gatewayLite.mjs +2 -4
  435. package/lib/components/ModelCompareV3/data/products/gatewayLite.mjs.map +1 -1
  436. package/lib/components/ModelCompareV3/data/products/gatewayMax.js +2 -4
  437. package/lib/components/ModelCompareV3/data/products/gatewayMax.js.map +1 -1
  438. package/lib/components/ModelCompareV3/data/products/gatewayMax.mjs +2 -4
  439. package/lib/components/ModelCompareV3/data/products/gatewayMax.mjs.map +1 -1
  440. package/lib/components/ModelCompareV3/data/products/gatewayProfessional.js +2 -4
  441. package/lib/components/ModelCompareV3/data/products/gatewayProfessional.js.map +1 -1
  442. package/lib/components/ModelCompareV3/data/products/gatewayProfessional.mjs +2 -4
  443. package/lib/components/ModelCompareV3/data/products/gatewayProfessional.mjs.map +1 -1
  444. package/lib/components/ModelCompareV3/data/products/highCapacityAggregation.js +0 -7
  445. package/lib/components/ModelCompareV3/data/products/highCapacityAggregation.js.map +1 -1
  446. package/lib/components/ModelCompareV3/data/products/highCapacityAggregation.mjs +0 -7
  447. package/lib/components/ModelCompareV3/data/products/highCapacityAggregation.mjs.map +1 -1
  448. package/lib/components/ModelCompareV3/data/products/missionCritical.js +0 -7
  449. package/lib/components/ModelCompareV3/data/products/missionCritical.js.map +1 -1
  450. package/lib/components/ModelCompareV3/data/products/missionCritical.mjs +0 -7
  451. package/lib/components/ModelCompareV3/data/products/missionCritical.mjs.map +1 -1
  452. package/lib/components/ModelCompareV3/data/products/officialUniFiHosting.js +1 -3
  453. package/lib/components/ModelCompareV3/data/products/officialUniFiHosting.js.map +1 -1
  454. package/lib/components/ModelCompareV3/data/products/officialUniFiHosting.mjs +1 -3
  455. package/lib/components/ModelCompareV3/data/products/officialUniFiHosting.mjs.map +1 -1
  456. package/lib/components/ModelCompareV3/data/products/professionalHd24.js +2 -11
  457. package/lib/components/ModelCompareV3/data/products/professionalHd24.js.map +1 -1
  458. package/lib/components/ModelCompareV3/data/products/professionalHd24.mjs +2 -11
  459. package/lib/components/ModelCompareV3/data/products/professionalHd24.mjs.map +1 -1
  460. package/lib/components/ModelCompareV3/data/products/professionalHd24Poe.js +2 -9
  461. package/lib/components/ModelCompareV3/data/products/professionalHd24Poe.js.map +1 -1
  462. package/lib/components/ModelCompareV3/data/products/professionalHd24Poe.mjs +2 -9
  463. package/lib/components/ModelCompareV3/data/products/professionalHd24Poe.mjs.map +1 -1
  464. package/lib/components/ModelCompareV3/data/products/professionalMax16.js +0 -7
  465. package/lib/components/ModelCompareV3/data/products/professionalMax16.js.map +1 -1
  466. package/lib/components/ModelCompareV3/data/products/professionalMax16.mjs +0 -7
  467. package/lib/components/ModelCompareV3/data/products/professionalMax16.mjs.map +1 -1
  468. package/lib/components/ModelCompareV3/data/products/professionalMax16PoE.js +0 -7
  469. package/lib/components/ModelCompareV3/data/products/professionalMax16PoE.js.map +1 -1
  470. package/lib/components/ModelCompareV3/data/products/professionalMax16PoE.mjs +0 -7
  471. package/lib/components/ModelCompareV3/data/products/professionalMax16PoE.mjs.map +1 -1
  472. package/lib/components/ModelCompareV3/data/products/professionalMax24.js +0 -7
  473. package/lib/components/ModelCompareV3/data/products/professionalMax24.js.map +1 -1
  474. package/lib/components/ModelCompareV3/data/products/professionalMax24.mjs +0 -7
  475. package/lib/components/ModelCompareV3/data/products/professionalMax24.mjs.map +1 -1
  476. package/lib/components/ModelCompareV3/data/products/professionalMax24PoE.js +0 -7
  477. package/lib/components/ModelCompareV3/data/products/professionalMax24PoE.js.map +1 -1
  478. package/lib/components/ModelCompareV3/data/products/professionalMax24PoE.mjs +0 -7
  479. package/lib/components/ModelCompareV3/data/products/professionalMax24PoE.mjs.map +1 -1
  480. package/lib/components/ModelCompareV3/data/products/professionalMax48.js +0 -7
  481. package/lib/components/ModelCompareV3/data/products/professionalMax48.js.map +1 -1
  482. package/lib/components/ModelCompareV3/data/products/professionalMax48.mjs +0 -7
  483. package/lib/components/ModelCompareV3/data/products/professionalMax48.mjs.map +1 -1
  484. package/lib/components/ModelCompareV3/data/products/professionalMax48PoE.js +0 -7
  485. package/lib/components/ModelCompareV3/data/products/professionalMax48PoE.js.map +1 -1
  486. package/lib/components/ModelCompareV3/data/products/professionalMax48PoE.mjs +0 -7
  487. package/lib/components/ModelCompareV3/data/products/professionalMax48PoE.mjs.map +1 -1
  488. package/lib/components/ModelCompareV3/data/products/switchesEnterprise.js +0 -8
  489. package/lib/components/ModelCompareV3/data/products/switchesEnterprise.js.map +1 -1
  490. package/lib/components/ModelCompareV3/data/products/switchesEnterprise.mjs +0 -8
  491. package/lib/components/ModelCompareV3/data/products/switchesEnterprise.mjs.map +1 -1
  492. package/lib/components/ModelCompareV3/data/products/switchesProfessional.js +0 -7
  493. package/lib/components/ModelCompareV3/data/products/switchesProfessional.js.map +1 -1
  494. package/lib/components/ModelCompareV3/data/products/switchesProfessional.mjs +0 -7
  495. package/lib/components/ModelCompareV3/data/products/switchesProfessional.mjs.map +1 -1
  496. package/lib/components/ModelCompareV3/data/products/switchesProfessionalHd.js +0 -7
  497. package/lib/components/ModelCompareV3/data/products/switchesProfessionalHd.js.map +1 -1
  498. package/lib/components/ModelCompareV3/data/products/switchesProfessionalHd.mjs +0 -7
  499. package/lib/components/ModelCompareV3/data/products/switchesProfessionalHd.mjs.map +1 -1
  500. package/lib/components/ModelCompareV3/data/products/switchesProfessionalMax.js +1 -10
  501. package/lib/components/ModelCompareV3/data/products/switchesProfessionalMax.js.map +1 -1
  502. package/lib/components/ModelCompareV3/data/products/switchesProfessionalMax.mjs +1 -10
  503. package/lib/components/ModelCompareV3/data/products/switchesProfessionalMax.mjs.map +1 -1
  504. package/lib/components/ModelCompareV3/data/products/switchesStandard.js +0 -7
  505. package/lib/components/ModelCompareV3/data/products/switchesStandard.js.map +1 -1
  506. package/lib/components/ModelCompareV3/data/products/switchesStandard.mjs +0 -7
  507. package/lib/components/ModelCompareV3/data/products/switchesStandard.mjs.map +1 -1
  508. package/lib/components/ModelCompareV3/data/products/ucgMax.js +2 -2
  509. package/lib/components/ModelCompareV3/data/products/ucgMax.js.map +1 -1
  510. package/lib/components/ModelCompareV3/data/products/ucgMax.mjs +2 -2
  511. package/lib/components/ModelCompareV3/data/products/ucgMax.mjs.map +1 -1
  512. package/lib/components/ModelCompareV3/data/products/ucgUltra.js +4 -4
  513. package/lib/components/ModelCompareV3/data/products/ucgUltra.js.map +1 -1
  514. package/lib/components/ModelCompareV3/data/products/ucgUltra.mjs +4 -4
  515. package/lib/components/ModelCompareV3/data/products/ucgUltra.mjs.map +1 -1
  516. package/lib/components/ModelCompareV3/data/products/udmPro.js +4 -4
  517. package/lib/components/ModelCompareV3/data/products/udmPro.js.map +1 -1
  518. package/lib/components/ModelCompareV3/data/products/udmPro.mjs +4 -4
  519. package/lib/components/ModelCompareV3/data/products/udmPro.mjs.map +1 -1
  520. package/lib/components/ModelCompareV3/data/products/udmProMax.js +4 -4
  521. package/lib/components/ModelCompareV3/data/products/udmProMax.js.map +1 -1
  522. package/lib/components/ModelCompareV3/data/products/udmProMax.mjs +4 -4
  523. package/lib/components/ModelCompareV3/data/products/udmProMax.mjs.map +1 -1
  524. package/lib/components/ModelCompareV3/data/products/udmProSpecial.js +4 -4
  525. package/lib/components/ModelCompareV3/data/products/udmProSpecial.js.map +1 -1
  526. package/lib/components/ModelCompareV3/data/products/udmProSpecial.mjs +4 -4
  527. package/lib/components/ModelCompareV3/data/products/udmProSpecial.mjs.map +1 -1
  528. package/lib/components/ModelCompareV3/data/products/udr.js +41 -5
  529. package/lib/components/ModelCompareV3/data/products/udr.js.map +1 -1
  530. package/lib/components/ModelCompareV3/data/products/udr.mjs +21 -5
  531. package/lib/components/ModelCompareV3/data/products/udr.mjs.map +1 -1
  532. package/lib/components/ModelCompareV3/data/products/udw.js +3 -3
  533. package/lib/components/ModelCompareV3/data/products/udw.js.map +1 -1
  534. package/lib/components/ModelCompareV3/data/products/udw.mjs +3 -3
  535. package/lib/components/ModelCompareV3/data/products/udw.mjs.map +1 -1
  536. package/lib/components/ModelCompareV3/data/properties/index.d.ts +0 -1
  537. package/lib/components/ModelCompareV3/data/properties/index.js +0 -2
  538. package/lib/components/ModelCompareV3/data/properties/index.js.map +1 -1
  539. package/lib/components/ModelCompareV3/data/properties/index.mjs +0 -1
  540. package/lib/components/ModelCompareV3/data/properties/index.mjs.map +1 -1
  541. package/lib/components/ModelCompareV3/data/properties/powerMethodPoe.js +1 -1
  542. package/lib/components/ModelCompareV3/data/properties/powerMethodPoe.mjs +1 -1
  543. package/lib/components/ModelCompareV3/data/properties/readerPowerMethod.js +1 -1
  544. package/lib/components/ModelCompareV3/data/properties/readerPowerMethod.mjs +1 -1
  545. package/lib/components/ModelCompareV3/data/properties/redundantRj45Port.js +1 -1
  546. package/lib/components/ModelCompareV3/data/properties/redundantRj45Port.mjs +1 -1
  547. package/lib/components/ModelCompareV3/translations/ar.json.js +10 -11
  548. package/lib/components/ModelCompareV3/translations/ar.json.js.map +1 -1
  549. package/lib/components/ModelCompareV3/translations/ar.json.mjs +10 -11
  550. package/lib/components/ModelCompareV3/translations/ar.json.mjs.map +1 -1
  551. package/lib/components/ModelCompareV3/translations/de.json.js +2 -3
  552. package/lib/components/ModelCompareV3/translations/de.json.js.map +1 -1
  553. package/lib/components/ModelCompareV3/translations/de.json.mjs +2 -3
  554. package/lib/components/ModelCompareV3/translations/de.json.mjs.map +1 -1
  555. package/lib/components/ModelCompareV3/translations/el.json.js +1 -2
  556. package/lib/components/ModelCompareV3/translations/el.json.js.map +1 -1
  557. package/lib/components/ModelCompareV3/translations/el.json.mjs +1 -2
  558. package/lib/components/ModelCompareV3/translations/el.json.mjs.map +1 -1
  559. package/lib/components/ModelCompareV3/translations/en.json.js +0 -3
  560. package/lib/components/ModelCompareV3/translations/en.json.js.map +1 -1
  561. package/lib/components/ModelCompareV3/translations/en.json.mjs +0 -3
  562. package/lib/components/ModelCompareV3/translations/en.json.mjs.map +1 -1
  563. package/lib/components/ModelCompareV3/translations/es.json.js +2 -3
  564. package/lib/components/ModelCompareV3/translations/es.json.js.map +1 -1
  565. package/lib/components/ModelCompareV3/translations/es.json.mjs +2 -3
  566. package/lib/components/ModelCompareV3/translations/es.json.mjs.map +1 -1
  567. package/lib/components/ModelCompareV3/translations/fr.json.js +1 -2
  568. package/lib/components/ModelCompareV3/translations/fr.json.js.map +1 -1
  569. package/lib/components/ModelCompareV3/translations/fr.json.mjs +1 -2
  570. package/lib/components/ModelCompareV3/translations/fr.json.mjs.map +1 -1
  571. package/lib/components/ModelCompareV3/translations/it.json.js +1 -2
  572. package/lib/components/ModelCompareV3/translations/it.json.js.map +1 -1
  573. package/lib/components/ModelCompareV3/translations/it.json.mjs +1 -2
  574. package/lib/components/ModelCompareV3/translations/it.json.mjs.map +1 -1
  575. package/lib/components/ModelCompareV3/translations/ja.json.js +7 -8
  576. package/lib/components/ModelCompareV3/translations/ja.json.js.map +1 -1
  577. package/lib/components/ModelCompareV3/translations/ja.json.mjs +7 -8
  578. package/lib/components/ModelCompareV3/translations/ja.json.mjs.map +1 -1
  579. package/lib/components/ModelCompareV3/translations/pt-BR.json.js +1 -2
  580. package/lib/components/ModelCompareV3/translations/pt-BR.json.js.map +1 -1
  581. package/lib/components/ModelCompareV3/translations/pt-BR.json.mjs +1 -2
  582. package/lib/components/ModelCompareV3/translations/pt-BR.json.mjs.map +1 -1
  583. package/lib/components/ModelCompareV3/translations/useModelCompareTranslation.d.ts +2 -2
  584. package/lib/components/ModelCompareV3/translations/zh-Hans.json.js +5 -6
  585. package/lib/components/ModelCompareV3/translations/zh-Hans.json.js.map +1 -1
  586. package/lib/components/ModelCompareV3/translations/zh-Hans.json.mjs +5 -6
  587. package/lib/components/ModelCompareV3/translations/zh-Hans.json.mjs.map +1 -1
  588. package/lib/components/ModelCompareV3/translations/zh-Hant-TW.json.js +8 -9
  589. package/lib/components/ModelCompareV3/translations/zh-Hant-TW.json.js.map +1 -1
  590. package/lib/components/ModelCompareV3/translations/zh-Hant-TW.json.mjs +8 -9
  591. package/lib/components/ModelCompareV3/translations/zh-Hant-TW.json.mjs.map +1 -1
  592. package/lib/components/NewToUnifiBox/NewToUnifiBox.styles.d.ts +5 -5
  593. package/lib/components/Pagination/Pagination.styles.d.ts +4 -4
  594. package/lib/components/Popover/Popover.styles.d.ts +7 -11
  595. package/lib/components/PriceRangeSlider/PriceRangeSlider.styles.d.ts +7 -7
  596. package/lib/components/ProductCard/ProductCard.styles.d.ts +16 -16
  597. package/lib/components/ProductCardPopup/ProductCardPopup.styles.d.ts +37 -45
  598. package/lib/components/ProductCardPopup/ProductCardPopup.styles.js +3 -3
  599. package/lib/components/ProductCardPopup/ProductCardPopup.styles.js.map +1 -1
  600. package/lib/components/ProductCardPopup/ProductCardPopup.styles.mjs +3 -3
  601. package/lib/components/ProductCardPopup/ProductCardPopup.styles.mjs.map +1 -1
  602. package/lib/components/ProductCompare/ProductCompare.styles.d.ts +18 -18
  603. package/lib/components/ProductDetails/ProductDetails.styles.d.ts +2 -2
  604. package/lib/components/ProductGrid/ProductGrid.styles.d.ts +13 -10
  605. package/lib/components/ProductKeyFeatures/ProductKeyFeatures.styles.d.ts +6 -6
  606. package/lib/components/ProductRecommendedAccessories/ProductRecommendedAccessories.styles.d.ts +9 -11
  607. package/lib/components/ProductSectionNavigation/ProductSectionNavigation.styles.d.ts +6 -6
  608. package/lib/components/ProductSectionNavigationV2/ProductSectionNavigation.styles.d.ts +7 -7
  609. package/lib/components/ProductSectionTabs/ProductSectionTabs.styles.d.ts +6 -6
  610. package/lib/components/ProductTechSpecs/ProductTechSpecs.styles.d.ts +14 -14
  611. package/lib/components/ProductUpsell/ProductUpsell.styles.d.ts +18 -20
  612. package/lib/components/ProductWizard/Options/Options.styles.d.ts +2 -2
  613. package/lib/components/ProductWizard/ProductWizard.styles.d.ts +16 -22
  614. package/lib/components/ProductWizardFootnotes/ProductWizardFootnotes.styles.d.ts +9 -9
  615. package/lib/components/ProductWizardFootnotes/ProductWizardFootnotes.styles.js +1 -1
  616. package/lib/components/ProductWizardFootnotes/ProductWizardFootnotes.styles.js.map +1 -1
  617. package/lib/components/ProductWizardFootnotes/ProductWizardFootnotes.styles.mjs +1 -1
  618. package/lib/components/ProductWizardFootnotes/ProductWizardFootnotes.styles.mjs.map +1 -1
  619. package/lib/components/QuantityControls/QuantityControls.styles.d.ts +2 -2
  620. package/lib/components/QuantityInput/QuantityInput.styles.d.ts +12 -16
  621. package/lib/components/RelatedProducts/RelatedProducts.styles.d.ts +14 -14
  622. package/lib/components/RelatedProducts/RelatedProducts.styles.js +2 -2
  623. package/lib/components/RelatedProducts/RelatedProducts.styles.js.map +1 -1
  624. package/lib/components/RelatedProducts/RelatedProducts.styles.mjs +2 -2
  625. package/lib/components/RelatedProducts/RelatedProducts.styles.mjs.map +1 -1
  626. package/lib/components/RelatedProductsVariantSelector/RelatedProductsVariantSelector.styles.d.ts +21 -23
  627. package/lib/components/RelatedProductsVariantSelectorV1/RelatedProductsVariantSelector.styles.d.ts +16 -36
  628. package/lib/components/RelatedProductsVariantSelectorV2/RelatedProductsVariantSelector.styles.d.ts +16 -38
  629. package/lib/components/RelatedProductsVariantSelectorsV2/RelatedProductsVariantSelectors.styles.d.ts +1 -1
  630. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.styles.d.ts +6 -6
  631. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/DeviceSelect.styles.d.ts +13 -13
  632. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.js +1 -1
  633. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.mjs +1 -1
  634. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.styles.d.ts +20 -20
  635. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/CounterSection.js +2 -2
  636. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/CounterSection.mjs +2 -2
  637. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/Layout.styles.d.ts +6 -6
  638. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/attention.svg.js +1 -1
  639. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/attention.svg.mjs +2 -2
  640. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/minus.svg.js +1 -1
  641. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/minus.svg.mjs +2 -2
  642. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/plus.svg.js +1 -1
  643. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/plus.svg.mjs +2 -2
  644. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/ProgressBarChart/ProgressBarChart.js +1 -1
  645. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/ProgressBarChart/ProgressBarChart.mjs +1 -1
  646. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/ProgressBarChart/ProgressBarChart.styles.d.ts +9 -9
  647. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/ProgressBarChart/assets/attention.svg.js +1 -1
  648. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/ProgressBarChart/assets/attention.svg.mjs +2 -2
  649. package/lib/components/ResourceCalculatorV1/PoeCalculator/PoeCalculator.styles.d.ts +1 -1
  650. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/DesignCenterBanner/DesignCenterBanner.styles.d.ts +5 -5
  651. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerConfigurator.styles.d.ts +10 -10
  652. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.js +2 -2
  653. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.mjs +2 -2
  654. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.styles.d.ts +17 -19
  655. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/minus.svg.js +1 -1
  656. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/minus.svg.mjs +2 -2
  657. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/plus.svg.js +1 -1
  658. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/plus.svg.mjs +2 -2
  659. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/RecommendedPoeSwitches/RecommendedPoeSwitches.js +2 -2
  660. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/RecommendedPoeSwitches/RecommendedPoeSwitches.mjs +2 -2
  661. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/RecommendedPoeSwitches/RecommendedPoeSwitches.styles.d.ts +16 -16
  662. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/RecommendedPoeSwitches/assets/poe.svg.js +1 -1
  663. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/RecommendedPoeSwitches/assets/poe.svg.mjs +2 -2
  664. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/RecommendedPoeSwitches/assets/port.svg.js +1 -1
  665. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/RecommendedPoeSwitches/assets/port.svg.mjs +2 -2
  666. package/lib/components/ResourceCalculatorV1/ResourceCalculator.styles.d.ts +3 -3
  667. package/lib/components/ResourceCalculatorV1/components/HorizontalOptionSelect/HorizontalOptionSelect.styles.d.ts +3 -3
  668. package/lib/components/ReverseLoopingVideo/ReverseLoopingVideo.styles.d.ts +3 -3
  669. package/lib/components/ScrollWrapper/ScrollWrapper.styles.d.ts +14 -18
  670. package/lib/components/Search/Input/Input.styles.d.ts +11 -13
  671. package/lib/components/Search/Input/Input.styles.js +1 -1
  672. package/lib/components/Search/Input/Input.styles.js.map +1 -1
  673. package/lib/components/Search/Input/Input.styles.mjs +1 -1
  674. package/lib/components/Search/Input/Input.styles.mjs.map +1 -1
  675. package/lib/components/Search/Modal/Modal.styles.d.ts +18 -20
  676. package/lib/components/SearchInput/Input.styles.d.ts +7 -9
  677. package/lib/components/SkeletonFootnote/SkeletonFootnote.d.ts +1 -1
  678. package/lib/components/SkeletonLoader/SkeletonCircleLoader/SkeletonCircleLoader.styles.d.ts +3 -3
  679. package/lib/components/SkeletonLoader/SkeletonLinearLoader/SkeletonLinearLoader.styles.d.ts +3 -3
  680. package/lib/components/SkeletonLoader/SkeletonLoaderTable/SkeletonLoaderTable.styles.d.ts +8 -8
  681. package/lib/components/StaticModal/StaticModal.styles.d.ts +2 -2
  682. package/lib/components/StorageSliders/Slider/Slider.styles.d.ts +5 -7
  683. package/lib/components/StorageSliders/StorageSliders.styles.d.ts +12 -12
  684. package/lib/components/StorybookUtils/StoryButtonColumn.d.ts +1 -1
  685. package/lib/components/StorybookUtils/StoryButtonRow.d.ts +1 -1
  686. package/lib/components/StorybookUtils/StoryWrapper.d.ts +2 -2
  687. package/lib/components/TabinationButtons/TabinationButtons.styles.d.ts +9 -9
  688. package/lib/components/Toggle/Toggle.styles.d.ts +3 -3
  689. package/lib/components/Toggle/Toggle.styles.js +1 -1
  690. package/lib/components/Toggle/Toggle.styles.js.map +1 -1
  691. package/lib/components/Toggle/Toggle.styles.mjs +1 -1
  692. package/lib/components/Toggle/Toggle.styles.mjs.map +1 -1
  693. package/lib/components/Tooltip/Tooltip.styles.d.ts +3 -33
  694. package/lib/components/TopologyScheme/TopologyScheme.styles.d.ts +17 -17
  695. package/lib/components/UICare/UICare.styles.d.ts +16 -19
  696. package/lib/components/VariantSelector/CheckBox/CheckBox.styles.d.ts +6 -6
  697. package/lib/components/VariantSelector/Variant/BundleOffer/BundleOffer.styles.d.ts +7 -7
  698. package/lib/components/VariantSelector/Variant/Compatibility/Compatibility.styles.d.ts +18 -18
  699. package/lib/components/VariantSelector/Variant/Variant.styles.d.ts +65 -75
  700. package/lib/components/VariantSelector/VariantSelector.styles.d.ts +13 -17
  701. package/lib/components/VariantSelectorItem/VariantSelectorItem.styles.d.ts +3 -3
  702. package/lib/components/VariantSelectorV1/VariantSelector.styles.d.ts +28 -32
  703. package/lib/components/VariantSelectorV2/VariantSelector.styles.d.ts +19 -23
  704. package/lib/components/VideoCookiesConsent/VideoCookiesConsent.styles.d.ts +6 -8
  705. package/lib/components/VideoPlayer/VideoPlayer.styles.d.ts +5 -5
  706. package/lib/components/VideoPlayerNew/VideoPlayer.styles.d.ts +28 -31
  707. package/lib/components/VideoPlayerNew/VideoPlayer.styles.js +2 -2
  708. package/lib/components/VideoPlayerNew/VideoPlayer.styles.js.map +1 -1
  709. package/lib/components/VideoPlayerNew/VideoPlayer.styles.mjs +2 -2
  710. package/lib/components/VideoPlayerNew/VideoPlayer.styles.mjs.map +1 -1
  711. package/lib/constants/icons/options/colors/black.svg.js +5 -5
  712. package/lib/constants/icons/options/colors/index.js +3 -3
  713. package/lib/constants/icons/options/styles/black.svg.js +5 -5
  714. package/lib/constants/icons/options/styles/index.js +3 -3
  715. package/lib/constants/mixin.d.ts +3 -3
  716. package/lib/constants/optionIcons.js +6 -6
  717. package/lib/constants/optionIcons.mjs +4 -4
  718. package/lib/constants/proStoreCategories/mapping/index.d.ts +2 -2
  719. package/lib/constants/proStoreCategories/mapping/index.js +47 -32
  720. package/lib/constants/proStoreCategories/mapping/index.js.map +1 -1
  721. package/lib/constants/proStoreCategories/mapping/index.mjs +45 -31
  722. package/lib/constants/proStoreCategories/mapping/index.mjs.map +1 -1
  723. package/lib/constants/proStoreCategories/mapping/redirects.js +3 -18
  724. package/lib/constants/proStoreCategories/mapping/redirects.js.map +1 -1
  725. package/lib/constants/proStoreCategories/mapping/redirects.mjs +3 -18
  726. package/lib/constants/proStoreCategories/mapping/redirects.mjs.map +1 -1
  727. package/lib/constants/proStoreCategories/mapping/unifi.d.ts +9 -7
  728. package/lib/constants/proStoreCategories/mapping/unifi.js +9 -7
  729. package/lib/constants/proStoreCategories/mapping/unifi.js.map +1 -1
  730. package/lib/constants/proStoreCategories/mapping/unifi.mjs +9 -7
  731. package/lib/constants/proStoreCategories/mapping/unifi.mjs.map +1 -1
  732. package/lib/constants/proStoreCategories/translations/ar.json.js +2 -5
  733. package/lib/constants/proStoreCategories/translations/ar.json.js.map +1 -1
  734. package/lib/constants/proStoreCategories/translations/ar.json.mjs +3 -5
  735. package/lib/constants/proStoreCategories/translations/ar.json.mjs.map +1 -1
  736. package/lib/constants/proStoreCategories/translations/de.json.js +2 -5
  737. package/lib/constants/proStoreCategories/translations/de.json.js.map +1 -1
  738. package/lib/constants/proStoreCategories/translations/de.json.mjs +3 -5
  739. package/lib/constants/proStoreCategories/translations/de.json.mjs.map +1 -1
  740. package/lib/constants/proStoreCategories/translations/el.json.js +2 -5
  741. package/lib/constants/proStoreCategories/translations/el.json.js.map +1 -1
  742. package/lib/constants/proStoreCategories/translations/el.json.mjs +3 -5
  743. package/lib/constants/proStoreCategories/translations/el.json.mjs.map +1 -1
  744. package/lib/constants/proStoreCategories/translations/en.json.js +2 -2
  745. package/lib/constants/proStoreCategories/translations/en.json.mjs +2 -2
  746. package/lib/constants/proStoreCategories/translations/es.json.js +2 -5
  747. package/lib/constants/proStoreCategories/translations/es.json.js.map +1 -1
  748. package/lib/constants/proStoreCategories/translations/es.json.mjs +3 -5
  749. package/lib/constants/proStoreCategories/translations/es.json.mjs.map +1 -1
  750. package/lib/constants/proStoreCategories/translations/fr.json.js +2 -2
  751. package/lib/constants/proStoreCategories/translations/fr.json.mjs +2 -2
  752. package/lib/constants/proStoreCategories/translations/it.json.js +2 -5
  753. package/lib/constants/proStoreCategories/translations/it.json.js.map +1 -1
  754. package/lib/constants/proStoreCategories/translations/it.json.mjs +3 -5
  755. package/lib/constants/proStoreCategories/translations/it.json.mjs.map +1 -1
  756. package/lib/constants/proStoreCategories/translations/ja.json.js +2 -5
  757. package/lib/constants/proStoreCategories/translations/ja.json.js.map +1 -1
  758. package/lib/constants/proStoreCategories/translations/ja.json.mjs +3 -5
  759. package/lib/constants/proStoreCategories/translations/ja.json.mjs.map +1 -1
  760. package/lib/constants/proStoreCategories/translations/pt-BR.json.js +2 -5
  761. package/lib/constants/proStoreCategories/translations/pt-BR.json.js.map +1 -1
  762. package/lib/constants/proStoreCategories/translations/pt-BR.json.mjs +3 -5
  763. package/lib/constants/proStoreCategories/translations/pt-BR.json.mjs.map +1 -1
  764. package/lib/constants/proStoreCategories/translations/zh-Hans.json.js +2 -2
  765. package/lib/constants/proStoreCategories/translations/zh-Hans.json.mjs +2 -2
  766. package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.js +2 -2
  767. package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.mjs +2 -2
  768. package/lib/constants/proStoreFilters/mapping.d.ts +1 -17
  769. package/lib/constants/proStoreFilters/mapping.js +0 -16
  770. package/lib/constants/proStoreFilters/mapping.js.map +1 -1
  771. package/lib/constants/proStoreFilters/mapping.mjs +0 -16
  772. package/lib/constants/proStoreFilters/mapping.mjs.map +1 -1
  773. package/lib/contexts/MenuContext/presets.d.ts +1 -1
  774. package/lib/contexts/MenuContext/presets.js +2 -4
  775. package/lib/contexts/MenuContext/presets.js.map +1 -1
  776. package/lib/contexts/MenuContext/presets.mjs +2 -4
  777. package/lib/contexts/MenuContext/presets.mjs.map +1 -1
  778. package/lib/helpers/index.d.ts +0 -1
  779. package/lib/helpers/index.js +0 -11
  780. package/lib/helpers/index.js.map +1 -1
  781. package/lib/helpers/index.mjs +0 -1
  782. package/lib/helpers/index.mjs.map +1 -1
  783. package/lib/types/generated.d.ts +1 -1
  784. package/lib/types/generated.js.map +1 -1
  785. package/lib/types/generated.mjs.map +1 -1
  786. package/lib/types/index.d.ts +0 -1
  787. package/lib/types/index.js +0 -2
  788. package/lib/types/index.js.map +1 -1
  789. package/lib/types/index.mjs +0 -1
  790. package/lib/types/index.mjs.map +1 -1
  791. package/lib/utils/address.d.ts +62 -278
  792. package/lib/utils/address.js +8 -11
  793. package/lib/utils/address.js.map +1 -1
  794. package/lib/utils/address.mjs +8 -11
  795. package/lib/utils/address.mjs.map +1 -1
  796. package/lib/utils/array.d.ts +0 -4
  797. package/lib/utils/array.js +0 -10
  798. package/lib/utils/array.js.map +1 -1
  799. package/lib/utils/array.mjs +1 -10
  800. package/lib/utils/array.mjs.map +1 -1
  801. package/package.json +43 -42
  802. package/lib/assets/crestron.svg +0 -3
  803. package/lib/components/ModelCompareV3/assets/crestron.svg.js +0 -27
  804. package/lib/components/ModelCompareV3/assets/crestron.svg.js.map +0 -1
  805. package/lib/components/ModelCompareV3/assets/crestron.svg.mjs +0 -3
  806. package/lib/components/ModelCompareV3/assets/crestron.svg.mjs.map +0 -1
  807. package/lib/components/ModelCompareV3/data/properties/crestronNaxNvxCertified.d.ts +0 -2
  808. package/lib/components/ModelCompareV3/data/properties/crestronNaxNvxCertified.js +0 -18
  809. package/lib/components/ModelCompareV3/data/properties/crestronNaxNvxCertified.js.map +0 -1
  810. package/lib/components/ModelCompareV3/data/properties/crestronNaxNvxCertified.mjs +0 -10
  811. package/lib/components/ModelCompareV3/data/properties/crestronNaxNvxCertified.mjs.map +0 -1
  812. package/lib/helpers/product.d.ts +0 -87
  813. package/lib/helpers/product.js +0 -346
  814. package/lib/helpers/product.js.map +0 -1
  815. package/lib/helpers/product.mjs +0 -335
  816. package/lib/helpers/product.mjs.map +0 -1
  817. package/lib/helpers/product.test.d.ts +0 -1
  818. package/lib/types/product.d.ts +0 -87
  819. package/lib/types/product.js +0 -14
  820. package/lib/types/product.js.map +0 -1
  821. package/lib/types/product.mjs +0 -13
  822. package/lib/types/product.mjs.map +0 -1
  823. package/lib/utils/productSort.d.ts +0 -41
  824. package/lib/utils/productSort.js +0 -67
  825. package/lib/utils/productSort.js.map +0 -1
  826. package/lib/utils/productSort.mjs +0 -60
  827. package/lib/utils/productSort.mjs.map +0 -1
  828. package/lib/utils/validations/lastNameSuperRefinement.d.ts +0 -11
  829. package/lib/utils/validations/lastNameSuperRefinement.js +0 -25
  830. package/lib/utils/validations/lastNameSuperRefinement.js.map +0 -1
  831. package/lib/utils/validations/lastNameSuperRefinement.mjs +0 -21
  832. package/lib/utils/validations/lastNameSuperRefinement.mjs.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"GalleryItem.styles.mjs","sources":["../../../../src/components/Gallery/GalleryItem/GalleryItem.styles.tsx"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { CustomImage } from \"../../CustomImage\";\n\nexport const GalleryItemWrapper = styled.div<{\n $fade?: boolean;\n $isActive: boolean;\n $isVisible: boolean;\n $couldBeNext: boolean;\n $hoverable?: boolean;\n}>`\n position: relative;\n flex: 1 0 100%;\n height: 100%;\n display: none;\n\n ${({ $couldBeNext, $isActive }) =>\n ($couldBeNext || $isActive) &&\n css`\n display: block;\n `}\n\n ${({ $fade, $isActive, $isVisible }) =>\n $fade &&\n css`\n opacity: 0;\n position: absolute;\n inset: 0;\n will-change: opacity;\n transition: 0.5s opacity;\n visibility: hidden;\n\n ${$isActive && \"opacity: 1;\"}\n\n ${$isVisible && \"visibility: visible;\"}\n `};\n\n /* For manual video gallery change cursor to be hoverable */\n ${({ $hoverable }) =>\n !!$hoverable &&\n css`\n &:hover {\n cursor: pointer;\n }\n `}\n`;\n\nexport const GalleryImage = styled(CustomImage)`\n position: absolute;\n display: block;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n user-select: none;\n -webkit-user-drag: none;\n`;\n\nexport const Video = styled.video<{\n $aspectRatio: number;\n}>`\n width: 100%;\n height: auto;\n max-height: 100%;\n object-fit: contain;\n aspect-ratio: ${({ $aspectRatio }) => $aspectRatio};\n position: absolute;\n top: 0;\n left: 0;\n -webkit-user-drag: none;\n`;\n"],"names":["GalleryItemWrapper","styled","div","$couldBeNext","$isActive","css","$fade","$isVisible","$hoverable","GalleryImage","CustomImage","Video","video","$aspectRatio"],"mappings":";;;;AAIO,MAAMA,qBAAqBC,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAYrC,CAAC;EAAEC,YAAA;EAAcC;AAAU,CAAA,KAAA,CAC1BD,gBAAgBC,SACjB,KAAAC,GAAA;AAAA;AAAA,KAEC;AAAA;AAAA,IAED,CAAC;EAAEC,KAAA;EAAOF,SAAW;EAAAG;MACrBD,KACA,IAAAD,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,QAQID,aAAa,aAAa;AAAA;AAAA,QAE1BG,cAAc,sBAAsB;AAAA,KACvC;AAAA;AAAA;AAAA,IAGD,CAAC;EAAEC;AAAA,CACH,KAAA,CAAC,CAACA,UACF,IAAAH,GAAA;AAAA;AAAA;AAAA;AAAA,KAIC;AAAA,CAAA;AAGQ,MAAAI,YAAA,GAAeR,OAAOS,WAAW,CAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAWvC,MAAMC,QAAQV,MAAO,CAAAW,KAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAOV,CAAC;EAAEC;AAAa,CAAA,KAAMA,YAAY;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;"}
1
+ {"version":3,"file":"GalleryItem.styles.mjs","sources":["../../../../src/components/Gallery/GalleryItem/GalleryItem.styles.tsx"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { CustomImage } from \"../../CustomImage\";\n\nexport const GalleryItemWrapper = styled.div<{\n fade?: boolean;\n isActive: boolean;\n isVisible: boolean;\n couldBeNext: boolean;\n hoverable?: boolean;\n}>`\n position: relative;\n flex: 1 0 100%;\n height: 100%;\n display: none;\n\n ${({ couldBeNext, isActive }) =>\n (couldBeNext || isActive) &&\n css`\n display: block;\n `}\n\n ${({ fade, isActive, isVisible }) =>\n fade &&\n css`\n opacity: 0;\n position: absolute;\n inset: 0;\n will-change: opacity;\n transition: 0.5s opacity;\n visibility: hidden;\n\n ${isActive && \"opacity: 1;\"}\n\n ${isVisible && \"visibility: visible;\"}\n `};\n\n /* For manual video gallery change cursor to be hoverable */\n ${({ hoverable }) =>\n !!hoverable &&\n css`\n &:hover {\n cursor: pointer;\n }\n `}\n`;\n\nexport const GalleryImage = styled(CustomImage)`\n position: absolute;\n display: block;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n user-select: none;\n -webkit-user-drag: none;\n`;\n\nexport const Video = styled.video<{\n $aspectRatio: number;\n}>`\n width: 100%;\n height: auto;\n max-height: 100%;\n object-fit: contain;\n aspect-ratio: ${({ $aspectRatio }) => $aspectRatio};\n position: absolute;\n top: 0;\n left: 0;\n -webkit-user-drag: none;\n`;\n"],"names":["GalleryItemWrapper","styled","div","couldBeNext","isActive","css","fade","isVisible","hoverable","GalleryImage","CustomImage","Video","video","$aspectRatio"],"mappings":";;;;AAIO,MAAMA,qBAAqBC,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAYrC,CAAC;EAAEC,WAAA;EAAaC;AAAS,CAAA,KAAA,CACxBD,eAAeC,QAChB,KAAAC,GAAA;AAAA;AAAA,KAEC;AAAA;AAAA,IAED,CAAC;EAAEC,IAAA;EAAMF,QAAU;EAAAG;MACnBD,IACA,IAAAD,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,QAQID,YAAY,aAAa;AAAA;AAAA,QAEzBG,aAAa,sBAAsB;AAAA,KACtC;AAAA;AAAA;AAAA,IAGD,CAAC;EAAEC;AAAA,CACH,KAAA,CAAC,CAACA,SACF,IAAAH,GAAA;AAAA;AAAA;AAAA;AAAA,KAIC;AAAA,CAAA;AAGQ,MAAAI,YAAA,GAAeR,OAAOS,WAAW,CAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAWvC,MAAMC,QAAQV,MAAO,CAAAW,KAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAOV,CAAC;EAAEC;AAAa,CAAA,KAAMA,YAAY;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;"}
@@ -1,19 +1,19 @@
1
1
  export declare const GALLERY_TRANSITION_MS = 400;
2
2
  export declare const GALLERY_THUMBNAILS_GAP = 8;
3
3
  export declare const GALLERY_THUMBNAILS_SIDE_PADDING = 8;
4
- export declare const ThumbnailsWrap: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
5
- export declare const ThumbnailsInnerWrap: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
6
- export declare const ThumbnailWrap: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
7
- export declare const Thumbnail: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
4
+ export declare const ThumbnailsWrap: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
5
+ export declare const ThumbnailsInnerWrap: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
6
+ export declare const ThumbnailWrap: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
7
+ export declare const Thumbnail: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
8
8
  $active: boolean;
9
9
  $expanded: boolean;
10
10
  $index: number;
11
11
  $scrollOffset: number;
12
12
  $containerWidth: number;
13
13
  $itemsCount: number;
14
- }>> & string;
15
- export declare const Image: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("../../CustomImage/CustomImage.types").CustomImageProps, never>> & string & Omit<({ motif, asset, sizes, className, margin, priority, fallbackImageSize, responsive, layout, renderImage, disableSkeleton, objectFit, disableBorderRadius, canFullscreen, onFullscreenChange, }: import("../../CustomImage/CustomImage.types").CustomImageProps) => JSX.Element, keyof import("react").Component<any, {}, any>>;
16
- export declare const Wrap: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
14
+ }, never>;
15
+ export declare const Image: import("styled-components").StyledComponent<({ motif, asset, sizes, className, margin, priority, fallbackImageSize, responsive, layout, renderImage, disableSkeleton, objectFit, disableBorderRadius, canFullscreen, onFullscreenChange, }: import("../../CustomImage/CustomImage.types").CustomImageProps) => JSX.Element, import("styled-components").DefaultTheme, {}, never>;
16
+ export declare const Wrap: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
17
17
  $expanded: boolean;
18
18
  $allowPointers?: boolean;
19
- }>> & string;
19
+ }, never>;
@@ -1,2 +1,2 @@
1
1
  import type { GradientButtonProps } from "./GradientButton.types";
2
- export declare const GradientButton: ({ children, active, className, borderRadius, ...props }: GradientButtonProps) => JSX.Element;
2
+ export declare const GradientButton: ({ children, active, className, ...props }: GradientButtonProps) => JSX.Element;
@@ -7,13 +7,11 @@ const GradientButton = ({
7
7
  children,
8
8
  active,
9
9
  className,
10
- borderRadius,
11
10
  ...props
12
11
  }) => {
13
12
  return /* @__PURE__ */jsxRuntime.jsx(GradientButton_styles.StyledButton, {
14
13
  className,
15
14
  active,
16
- $borderRadius: borderRadius,
17
15
  ...props,
18
16
  children: /* @__PURE__ */jsxRuntime.jsx(GradientButton_styles.StyledButtonInner, {
19
17
  children
@@ -1 +1 @@
1
- {"version":3,"file":"GradientButton.js","sources":["../../../src/components/GradientButton/GradientButton.tsx"],"sourcesContent":["import * as S from \"./GradientButton.styles\";\nimport type { GradientButtonProps } from \"./GradientButton.types\";\n\nexport const GradientButton = ({\n children,\n active,\n className,\n borderRadius,\n ...props\n}: GradientButtonProps) => {\n return (\n <S.StyledButton\n className={className}\n active={active}\n $borderRadius={borderRadius}\n {...props}\n >\n <S.StyledButtonInner>{children}</S.StyledButtonInner>\n </S.StyledButton>\n );\n};\n"],"names":["GradientButton","children","active","className","borderRadius","props","jsx","S.StyledButton","StyledButton","$borderRadius","S.StyledButtonInner"],"mappings":";;;;;AAGO,MAAMA,iBAAiBA,CAAC;EAC7BC,QAAA;EACAC,MAAA;EACAC,SAAA;EACAC,YAAA;EACA,GAAGC;AACL,CAA2B,KAAA;EAEvB,sBAAAC,UAAA,CAAAA,GAAA,CAACC,qBAAE,CAAAC,YAAA,EAAF;IACCL,SAAA;IACAD,MAAA;IACAO,aAAe,EAAAL,YAAA;IACd,GAAGC,KAAA;IAEJJ,QAAC,iBAAAK,UAAA,CAAAA,GAAA,CAAAI,uCAAA,EAAA;MAAqBT;IAAS,CAAA;EAAA,CAAA,CACjC;AAEJ,CAAA;"}
1
+ {"version":3,"file":"GradientButton.js","sources":["../../../src/components/GradientButton/GradientButton.tsx"],"sourcesContent":["import * as S from \"./GradientButton.styles\";\nimport type { GradientButtonProps } from \"./GradientButton.types\";\n\nexport const GradientButton = ({\n children,\n active,\n className,\n ...props\n}: GradientButtonProps) => {\n return (\n <S.StyledButton className={className} active={active} {...props}>\n <S.StyledButtonInner>{children}</S.StyledButtonInner>\n </S.StyledButton>\n );\n};\n"],"names":["GradientButton","children","active","className","props","jsx","S.StyledButton","StyledButton","S.StyledButtonInner","StyledButtonInner"],"mappings":";;;;;AAGO,MAAMA,iBAAiBA,CAAC;EAC7BC,QAAA;EACAC,MAAA;EACAC,SAAA;EACA,GAAGC;AACL,CAA2B,KAAA;EACzB,OAAA,eACGC,UAAA,CAAAA,GAAA,CAAAC,qBAAA,CAAAC,YAAA,EAAA;IAAeJ,SAAsB;IAAAD,MAAA;IAAiB,GAAGE,KAAA;IACxDH,QAAC,EAAA,eAAAI,UAAA,CAAAA,GAAA,CAAAG,qBAAA,CAAAC,iBAAA,EAAA;MAAqBR;IAAS,CAAA;EACjC,CAAA,CAAA;AAEJ,CAAA;"}
@@ -5,13 +5,11 @@ const GradientButton = ({
5
5
  children,
6
6
  active,
7
7
  className,
8
- borderRadius,
9
8
  ...props
10
9
  }) => {
11
10
  return /* @__PURE__ */jsx(StyledButton, {
12
11
  className,
13
12
  active,
14
- $borderRadius: borderRadius,
15
13
  ...props,
16
14
  children: /* @__PURE__ */jsx(StyledButtonInner, {
17
15
  children
@@ -1 +1 @@
1
- {"version":3,"file":"GradientButton.mjs","sources":["../../../src/components/GradientButton/GradientButton.tsx"],"sourcesContent":["import * as S from \"./GradientButton.styles\";\nimport type { GradientButtonProps } from \"./GradientButton.types\";\n\nexport const GradientButton = ({\n children,\n active,\n className,\n borderRadius,\n ...props\n}: GradientButtonProps) => {\n return (\n <S.StyledButton\n className={className}\n active={active}\n $borderRadius={borderRadius}\n {...props}\n >\n <S.StyledButtonInner>{children}</S.StyledButtonInner>\n </S.StyledButton>\n );\n};\n"],"names":["GradientButton","children","active","className","borderRadius","props","jsx","S.StyledButton","$borderRadius","S.StyledButtonInner"],"mappings":";;;AAGO,MAAMA,iBAAiBA,CAAC;EAC7BC,QAAA;EACAC,MAAA;EACAC,SAAA;EACAC,YAAA;EACA,GAAGC;AACL,CAA2B,KAAA;EAEvB,sBAAAC,GAAA,CAACC,YAAE,EAAF;IACCJ,SAAA;IACAD,MAAA;IACAM,aAAe,EAAAJ,YAAA;IACd,GAAGC,KAAA;IAEJJ,QAAC,iBAAAK,GAAA,CAAAG,iBAAA,EAAA;MAAqBR;IAAS,CAAA;EAAA,CAAA,CACjC;AAEJ,CAAA;"}
1
+ {"version":3,"file":"GradientButton.mjs","sources":["../../../src/components/GradientButton/GradientButton.tsx"],"sourcesContent":["import * as S from \"./GradientButton.styles\";\nimport type { GradientButtonProps } from \"./GradientButton.types\";\n\nexport const GradientButton = ({\n children,\n active,\n className,\n ...props\n}: GradientButtonProps) => {\n return (\n <S.StyledButton className={className} active={active} {...props}>\n <S.StyledButtonInner>{children}</S.StyledButtonInner>\n </S.StyledButton>\n );\n};\n"],"names":["GradientButton","children","active","className","props","jsx","S.StyledButton","S.StyledButtonInner"],"mappings":";;;AAGO,MAAMA,iBAAiBA,CAAC;EAC7BC,QAAA;EACAC,MAAA;EACAC,SAAA;EACA,GAAGC;AACL,CAA2B,KAAA;EACzB,OAAA,eACGC,GAAA,CAAAC,YAAA,EAAA;IAAeH,SAAsB;IAAAD,MAAA;IAAiB,GAAGE,KAAA;IACxDH,QAAC,EAAA,eAAAI,GAAA,CAAAE,iBAAA,EAAA;MAAqBN;IAAS,CAAA;EACjC,CAAA,CAAA;AAEJ,CAAA;"}
@@ -1,5 +1,5 @@
1
- export declare const StyledButton: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, {
1
+ export declare const StyledButton: import("styled-components").StyledComponent<"button", import("styled-components").DefaultTheme, {
2
2
  active?: boolean;
3
- $borderRadius?: number;
4
- }>> & string;
5
- export declare const StyledButtonInner: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, never>> & string;
3
+ borderRadius?: number;
4
+ }, never>;
5
+ export declare const StyledButtonInner: import("styled-components").StyledComponent<"span", import("styled-components").DefaultTheme, {}, never>;
@@ -30,15 +30,15 @@ const StyledButton = styled__default["default"].button`
30
30
  background: transparent;
31
31
  background-clip: padding-box;
32
32
  border-radius: ${({
33
- $borderRadius
34
- }) => `${$borderRadius || BORDER_RADIUS}px`};
33
+ borderRadius
34
+ }) => `${borderRadius || BORDER_RADIUS}px`};
35
35
 
36
36
  &::after {
37
37
  content: "";
38
38
  position: absolute;
39
39
  border-radius: ${({
40
- $borderRadius
41
- }) => `${($borderRadius || BORDER_RADIUS) - DEFAULT_BORDER_WIDTH}px`};
40
+ borderRadius
41
+ }) => `${(borderRadius || BORDER_RADIUS) - DEFAULT_BORDER_WIDTH}px`};
42
42
  inset: -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px;
43
43
  background: ${theme.theme.colors.white};
44
44
  z-index: 2;
@@ -54,7 +54,7 @@ const StyledButton = styled__default["default"].button`
54
54
 
55
55
  ${({
56
56
  active,
57
- $borderRadius
57
+ borderRadius
58
58
  }) => active ? styled.css`
59
59
  &::before {
60
60
  background: linear-gradient(
@@ -65,7 +65,7 @@ const StyledButton = styled__default["default"].button`
65
65
  }
66
66
 
67
67
  &::after {
68
- border-radius: ${($borderRadius || BORDER_RADIUS) - ACTIVE_BORDER_WIDTH}px;
68
+ border-radius: ${(borderRadius || BORDER_RADIUS) - ACTIVE_BORDER_WIDTH}px;
69
69
  inset: ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px
70
70
  ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px;
71
71
  }
@@ -1 +1 @@
1
- {"version":3,"file":"GradientButton.styles.js","sources":["../../../src/components/GradientButton/GradientButton.styles.tsx"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { theme } from \"../../constants/theme\";\n\nconst ACTIVE_BORDER_WIDTH = 2;\nconst DEFAULT_BORDER_WIDTH = 1;\nconst BORDER_RADIUS = 12;\n\nexport const StyledButton = styled.button<{\n active?: boolean;\n $borderRadius?: number;\n}>`\n display: flex;\n justify-content: center;\n align-items: center;\n width: 100%;\n border: ${ACTIVE_BORDER_WIDTH}px solid transparent;\n font-size: 16px;\n line-height: 1.25;\n font-weight: ${theme.fontWeight.bold};\n\n position: relative;\n padding: 6px 16px;\n box-sizing: border-box;\n height: 50px;\n\n background: transparent;\n background-clip: padding-box;\n border-radius: ${({ $borderRadius }) =>\n `${$borderRadius || BORDER_RADIUS}px`};\n\n &::after {\n content: \"\";\n position: absolute;\n border-radius: ${({ $borderRadius }) =>\n `${($borderRadius || BORDER_RADIUS) - DEFAULT_BORDER_WIDTH}px`};\n inset: -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px;\n background: ${theme.colors.white};\n z-index: 2;\n }\n\n &::before {\n content: \"\";\n position: absolute;\n inset: -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px;\n z-index: 1;\n border-radius: inherit;\n }\n\n ${({ active, $borderRadius }) =>\n active\n ? css`\n &::before {\n background: linear-gradient(\n 96.1deg,\n ${theme.colors.dodgerblue} 0.54%,\n #6bd2fd 100%\n );\n }\n\n &::after {\n border-radius: ${($borderRadius || BORDER_RADIUS) -\n ACTIVE_BORDER_WIDTH}px;\n inset: ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px\n ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px;\n }\n `\n : css`\n &::before {\n background: #f0f0f0;\n }\n `}\n`;\n\nexport const StyledButtonInner = styled.span`\n position: relative;\n z-index: 3;\n display: flex;\n justify-content: center;\n align-items: center;\n gap: 8px;\n`;\n"],"names":["ACTIVE_BORDER_WIDTH","DEFAULT_BORDER_WIDTH","BORDER_RADIUS","StyledButton","styled","button","theme","fontWeight","bold","$borderRadius","colors","white","active","css","dodgerblue","StyledButtonInner","span"],"mappings":";;;;;;;;;;;AAIA,MAAMA,mBAAsB,GAAA,CAAA;AAC5B,MAAMC,oBAAuB,GAAA,CAAA;AAC7B,MAAMC,aAAgB,GAAA,EAAA;AAEf,MAAMC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ton.styles.js","sources":["../../../src/components/GradientButton/GradientButton.styles.tsx"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { theme } from \"../../constants/theme\";\n\nconst ACTIVE_BORDER_WIDTH = 2;\nconst DEFAULT_BORDER_WIDTH = 1;\nconst BORDER_RADIUS = 12;\n\nexport const StyledButton = styled.button<{\n active?: boolean;\n borderRadius?: number;\n}>`\n display: flex;\n justify-content: center;\n align-items: center;\n width: 100%;\n border: ${ACTIVE_BORDER_WIDTH}px solid transparent;\n font-size: 16px;\n line-height: 1.25;\n font-weight: ${theme.fontWeight.bold};\n\n position: relative;\n padding: 6px 16px;\n box-sizing: border-box;\n height: 50px;\n\n background: transparent;\n background-clip: padding-box;\n border-radius: ${({ borderRadius }) => `${borderRadius || BORDER_RADIUS}px`};\n\n &::after {\n content: \"\";\n position: absolute;\n border-radius: ${({ borderRadius }) =>\n `${(borderRadius || BORDER_RADIUS) - DEFAULT_BORDER_WIDTH}px`};\n inset: -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px;\n background: ${theme.colors.white};\n z-index: 2;\n }\n\n &::before {\n content: \"\";\n position: absolute;\n inset: -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px;\n z-index: 1;\n border-radius: inherit;\n }\n\n ${({ active, borderRadius }) =>\n active\n ? css`\n &::before {\n background: linear-gradient(\n 96.1deg,\n ${theme.colors.dodgerblue} 0.54%,\n #6bd2fd 100%\n );\n }\n\n &::after {\n border-radius: ${(borderRadius || BORDER_RADIUS) -\n ACTIVE_BORDER_WIDTH}px;\n inset: ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px\n ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px;\n }\n `\n : css`\n &::before {\n background: #f0f0f0;\n }\n `}\n`;\n\nexport const StyledButtonInner = styled.span`\n position: relative;\n z-index: 3;\n display: flex;\n justify-content: center;\n align-items: center;\n gap: 8px;\n`;\n"],"names":["ACTIVE_BORDER_WIDTH","DEFAULT_BORDER_WIDTH","BORDER_RADIUS","StyledButton","styled","button","theme","fontWeight","bold","borderRadius","colors","white","active","css","dodgerblue","StyledButtonInner","span"],"mappings":";;;;;;;;;;;AAIA,MAAMA,mBAAsB,GAAA,CAAA;AAC5B,MAAMC,oBAAuB,GAAA,CAAA;AAC7B,MAAMC,aAAgB,GAAA,EAAA;AAEf,MAAMC,eAAeC,eAAO,CAAA,SAAA,CAAA,CAAAC,MAAA;AAAA;AAAA;AAAA;AAAA;AAAA,YAQvBL,mBAAmB;AAAA;AAAA;AAAA,iBAGdM,KAAA,CAAAA,KAAA,CAAMC,WAAWC,IAAI;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBASnB,CAAC;EAAEC;MAAmB,GAAGA,YAAA,IAAgBP,aAAa,IAAI;AAAA;AAAA;AAAA;AAAA;AAAA,qBAKxD,CAAC;EAAEO;AAAa,CAAA,KAC/B,IAAIA,YAAgB,IAAAP,aAAA,IAAiBD,oBAAoB,IAAI;AAAA,cACrDA,oBAAoB,OAAOA,oBAAoB,OAAOA,oBAAoB,OAAOA,oBAAoB;AAAA,kBACjGK,KAAA,CAAAA,KAAA,CAAMI,OAAOC,KAAK;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,cAOtBX,mBAAmB,OAAOA,mBAAmB,OAAOA,mBAAmB,OAAOA,mBAAmB;AAAA;AAAA;AAAA;AAAA;AAAA,IAK3G,CAAC;EAAEY,MAAQ;EAAAH;AAAA,MACXG,MACI,GAAAC,MAAAA,CAAAA,GAAA;AAAA;AAAA;AAAA;AAAA,gBAIQP,KAAA,CAAAA,KAAA,CAAMI,OAAOI,UAAU;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,6BAMT,CAAAL,YAAA,IAAgBP,iBAClCF,mBAAmB;AAAA,qBACV,CAAI,GAAAA,mBAAmB,MAAM,CAAA,GAAIA,mBAAmB;AAAA,gBACzD,CAAI,GAAAA,mBAAmB,MAAM,CAAA,GAAIA,mBAAmB;AAAA;AAAA,SAG5D,GAAAa,MAAAA,CAAAA,GAAA;AAAA;AAAA;AAAA;AAAA,SAIC;AAAA,CAAA;AAGF,MAAME,oBAAoBX,eAAO,CAAA,SAAA,CAAA,CAAAY,IAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;;"}
@@ -22,15 +22,15 @@ const StyledButton = styled.button`
22
22
  background: transparent;
23
23
  background-clip: padding-box;
24
24
  border-radius: ${({
25
- $borderRadius
26
- }) => `${$borderRadius || BORDER_RADIUS}px`};
25
+ borderRadius
26
+ }) => `${borderRadius || BORDER_RADIUS}px`};
27
27
 
28
28
  &::after {
29
29
  content: "";
30
30
  position: absolute;
31
31
  border-radius: ${({
32
- $borderRadius
33
- }) => `${($borderRadius || BORDER_RADIUS) - DEFAULT_BORDER_WIDTH}px`};
32
+ borderRadius
33
+ }) => `${(borderRadius || BORDER_RADIUS) - DEFAULT_BORDER_WIDTH}px`};
34
34
  inset: -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px;
35
35
  background: ${theme.colors.white};
36
36
  z-index: 2;
@@ -46,7 +46,7 @@ const StyledButton = styled.button`
46
46
 
47
47
  ${({
48
48
  active,
49
- $borderRadius
49
+ borderRadius
50
50
  }) => active ? css`
51
51
  &::before {
52
52
  background: linear-gradient(
@@ -57,7 +57,7 @@ const StyledButton = styled.button`
57
57
  }
58
58
 
59
59
  &::after {
60
- border-radius: ${($borderRadius || BORDER_RADIUS) - ACTIVE_BORDER_WIDTH}px;
60
+ border-radius: ${(borderRadius || BORDER_RADIUS) - ACTIVE_BORDER_WIDTH}px;
61
61
  inset: ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px
62
62
  ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px;
63
63
  }
@@ -1 +1 @@
1
- {"version":3,"file":"GradientButton.styles.mjs","sources":["../../../src/components/GradientButton/GradientButton.styles.tsx"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { theme } from \"../../constants/theme\";\n\nconst ACTIVE_BORDER_WIDTH = 2;\nconst DEFAULT_BORDER_WIDTH = 1;\nconst BORDER_RADIUS = 12;\n\nexport const StyledButton = styled.button<{\n active?: boolean;\n $borderRadius?: number;\n}>`\n display: flex;\n justify-content: center;\n align-items: center;\n width: 100%;\n border: ${ACTIVE_BORDER_WIDTH}px solid transparent;\n font-size: 16px;\n line-height: 1.25;\n font-weight: ${theme.fontWeight.bold};\n\n position: relative;\n padding: 6px 16px;\n box-sizing: border-box;\n height: 50px;\n\n background: transparent;\n background-clip: padding-box;\n border-radius: ${({ $borderRadius }) =>\n `${$borderRadius || BORDER_RADIUS}px`};\n\n &::after {\n content: \"\";\n position: absolute;\n border-radius: ${({ $borderRadius }) =>\n `${($borderRadius || BORDER_RADIUS) - DEFAULT_BORDER_WIDTH}px`};\n inset: -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px;\n background: ${theme.colors.white};\n z-index: 2;\n }\n\n &::before {\n content: \"\";\n position: absolute;\n inset: -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px;\n z-index: 1;\n border-radius: inherit;\n }\n\n ${({ active, $borderRadius }) =>\n active\n ? css`\n &::before {\n background: linear-gradient(\n 96.1deg,\n ${theme.colors.dodgerblue} 0.54%,\n #6bd2fd 100%\n );\n }\n\n &::after {\n border-radius: ${($borderRadius || BORDER_RADIUS) -\n ACTIVE_BORDER_WIDTH}px;\n inset: ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px\n ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px;\n }\n `\n : css`\n &::before {\n background: #f0f0f0;\n }\n `}\n`;\n\nexport const StyledButtonInner = styled.span`\n position: relative;\n z-index: 3;\n display: flex;\n justify-content: center;\n align-items: center;\n gap: 8px;\n`;\n"],"names":["ACTIVE_BORDER_WIDTH","DEFAULT_BORDER_WIDTH","BORDER_RADIUS","StyledButton","styled","button","theme","fontWeight","bold","$borderRadius","colors","white","active","css","dodgerblue","StyledButtonInner","span"],"mappings":";;;AAIA,MAAMA,mBAAsB,GAAA,CAAA;AAC5B,MAAMC,oBAAuB,GAAA,CAAA;AAC7B,MAAMC,aAAgB,GAAA,EAAA;AAEf,MAAMC,eAAeC,MAAO,CAAAC,MAAA;AAAA;AAAA;AAAA;AAAA;AAAA,YAQvBL,mBAAmB;AAAA;AAAA;AAAA,iBAGdM,KAAA,CAAMC,WAAWC,IAAI;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBASnB,CAAC;EAAEC;MAClB,GAAGA,aAAA,IAAiBP,aAAa,IAAI;AAAA;AAAA;AAAA;AAAA;AAAA,qBAKpB,CAAC;EAAEO;AAAc,CAAA,KAChC,IAAIA,aAAiB,IAAAP,aAAA,IAAiBD,oBAAoB,IAAI;AAAA,cACtDA,oBAAoB,OAAOA,oBAAoB,OAAOA,oBAAoB,OAAOA,oBAAoB;AAAA,kBACjGK,KAAA,CAAMI,OAAOC,KAAK;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,cAOtBX,mBAAmB,OAAOA,mBAAmB,OAAOA,mBAAmB,OAAOA,mBAAmB;AAAA;AAAA;AAAA;AAAA;AAAA,IAK3G,CAAC;EAAEY,MAAQ;EAAAH;AAAA,MACXG,MACI,GAAAC,GAAA;AAAA;AAAA;AAAA;AAAA,gBAIQP,KAAA,CAAMI,OAAOI,UAAU;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,6BAMT,CAAAL,aAAA,IAAiBP,iBACnCF,mBAAmB;AAAA,qBACV,CAAI,GAAAA,mBAAmB,MAAM,CAAA,GAAIA,mBAAmB;AAAA,gBACzD,CAAI,GAAAA,mBAAmB,MAAM,CAAA,GAAIA,mBAAmB;AAAA;AAAA,SAG5D,GAAAa,GAAA;AAAA;AAAA;AAAA;AAAA,SAIC;AAAA,CAAA;AAGF,MAAME,oBAAoBX,MAAO,CAAAY,IAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;"}
1
+ {"version":3,"file":"GradientButton.styles.mjs","sources":["../../../src/components/GradientButton/GradientButton.styles.tsx"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { theme } from \"../../constants/theme\";\n\nconst ACTIVE_BORDER_WIDTH = 2;\nconst DEFAULT_BORDER_WIDTH = 1;\nconst BORDER_RADIUS = 12;\n\nexport const StyledButton = styled.button<{\n active?: boolean;\n borderRadius?: number;\n}>`\n display: flex;\n justify-content: center;\n align-items: center;\n width: 100%;\n border: ${ACTIVE_BORDER_WIDTH}px solid transparent;\n font-size: 16px;\n line-height: 1.25;\n font-weight: ${theme.fontWeight.bold};\n\n position: relative;\n padding: 6px 16px;\n box-sizing: border-box;\n height: 50px;\n\n background: transparent;\n background-clip: padding-box;\n border-radius: ${({ borderRadius }) => `${borderRadius || BORDER_RADIUS}px`};\n\n &::after {\n content: \"\";\n position: absolute;\n border-radius: ${({ borderRadius }) =>\n `${(borderRadius || BORDER_RADIUS) - DEFAULT_BORDER_WIDTH}px`};\n inset: -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px -${DEFAULT_BORDER_WIDTH}px;\n background: ${theme.colors.white};\n z-index: 2;\n }\n\n &::before {\n content: \"\";\n position: absolute;\n inset: -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px -${ACTIVE_BORDER_WIDTH}px;\n z-index: 1;\n border-radius: inherit;\n }\n\n ${({ active, borderRadius }) =>\n active\n ? css`\n &::before {\n background: linear-gradient(\n 96.1deg,\n ${theme.colors.dodgerblue} 0.54%,\n #6bd2fd 100%\n );\n }\n\n &::after {\n border-radius: ${(borderRadius || BORDER_RADIUS) -\n ACTIVE_BORDER_WIDTH}px;\n inset: ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px\n ${2 - ACTIVE_BORDER_WIDTH}px ${2 - ACTIVE_BORDER_WIDTH}px;\n }\n `\n : css`\n &::before {\n background: #f0f0f0;\n }\n `}\n`;\n\nexport const StyledButtonInner = styled.span`\n position: relative;\n z-index: 3;\n display: flex;\n justify-content: center;\n align-items: center;\n gap: 8px;\n`;\n"],"names":["ACTIVE_BORDER_WIDTH","DEFAULT_BORDER_WIDTH","BORDER_RADIUS","StyledButton","styled","button","theme","fontWeight","bold","borderRadius","colors","white","active","css","dodgerblue","StyledButtonInner","span"],"mappings":";;;AAIA,MAAMA,mBAAsB,GAAA,CAAA;AAC5B,MAAMC,oBAAuB,GAAA,CAAA;AAC7B,MAAMC,aAAgB,GAAA,EAAA;AAEf,MAAMC,eAAeC,MAAO,CAAAC,MAAA;AAAA;AAAA;AAAA;AAAA;AAAA,YAQvBL,mBAAmB;AAAA;AAAA;AAAA,iBAGdM,KAAA,CAAMC,WAAWC,IAAI;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,mBASnB,CAAC;EAAEC;MAAmB,GAAGA,YAAA,IAAgBP,aAAa,IAAI;AAAA;AAAA;AAAA;AAAA;AAAA,qBAKxD,CAAC;EAAEO;AAAa,CAAA,KAC/B,IAAIA,YAAgB,IAAAP,aAAA,IAAiBD,oBAAoB,IAAI;AAAA,cACrDA,oBAAoB,OAAOA,oBAAoB,OAAOA,oBAAoB,OAAOA,oBAAoB;AAAA,kBACjGK,KAAA,CAAMI,OAAOC,KAAK;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,cAOtBX,mBAAmB,OAAOA,mBAAmB,OAAOA,mBAAmB,OAAOA,mBAAmB;AAAA;AAAA;AAAA;AAAA;AAAA,IAK3G,CAAC;EAAEY,MAAQ;EAAAH;AAAA,MACXG,MACI,GAAAC,GAAA;AAAA;AAAA;AAAA;AAAA,gBAIQP,KAAA,CAAMI,OAAOI,UAAU;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,6BAMT,CAAAL,YAAA,IAAgBP,iBAClCF,mBAAmB;AAAA,qBACV,CAAI,GAAAA,mBAAmB,MAAM,CAAA,GAAIA,mBAAmB;AAAA,gBACzD,CAAI,GAAAA,mBAAmB,MAAM,CAAA,GAAIA,mBAAmB;AAAA;AAAA,SAG5D,GAAAa,GAAA;AAAA;AAAA;AAAA;AAAA,SAIC;AAAA,CAAA;AAGF,MAAME,oBAAoBX,MAAO,CAAAY,IAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;"}
@@ -164,7 +164,7 @@ const GridGallery = function GridGallery2({
164
164
  type: "video/mp4"
165
165
  })
166
166
  }), /* @__PURE__ */jsxRuntime.jsx(GridGallery_styles.VideoOverlay, {
167
- $hasVideo: !!previewVideo,
167
+ hasVideo: !!previewVideo,
168
168
  onClick: () => !!previewVideo && setActiveModalId(asset.src),
169
169
  children: !!previewVideo && /* @__PURE__ */jsxRuntime.jsx(StyleableSvgImage.StyleableSvgImage, {
170
170
  src: PlayIcon__default["default"],
@@ -1 +1 @@
1
- {"version":3,"file":"GridGallery.js","sources":["../../../src/components/GridGallery/GridGallery.tsx"],"sourcesContent":["import { useCallback, useEffect, useMemo, useState } from \"react\";\nimport { useMedia } from \"react-use\";\n\nimport PlayIcon from \"../../assets/icons/play-big.svg\";\nimport { BREAKPOINTS } from \"../../constants/layout\";\nimport { findClosestNumber } from \"../../utils/number\";\nimport { StyleableSvgImage } from \"../StyleableSvgImage\";\nimport * as S from \"./GridGallery.styles\";\nimport type {\n GridGalleryAssetRow,\n GridGalleryParsedAsset,\n GridGalleryProps,\n} from \"./GridGallery.types\";\nimport { RatioType } from \"./GridGallery.types\";\nimport { GridModal } from \"./GridModal/GridModal\";\n\nexport const GridGallery = function GridGallery({\n className,\n renderImage,\n assets: assetsInitial,\n priority,\n onModalToggle,\n}: GridGalleryProps) {\n const isTablet = useMedia(BREAKPOINTS.TABLET_AND_DOWN, false);\n\n const [activeModalId, setActiveModalId] = useState<string>(\"\");\n useEffect(() => {\n onModalToggle?.(activeModalId);\n }, [onModalToggle, activeModalId]);\n\n // #############################################################################\n // Asset helpers\n // #############################################################################\n const getAssetAspectRatioType = useCallback(\n (asset: GridGalleryProps[\"assets\"][number]): RatioType => {\n // Get asset height ratio\n const aspectHeightRatio = asset.height / asset.width;\n\n // Find the closest height ratio the image uses\n const heightRatios = Object.values(S.GRID_GALLERY_RATIOS).map(\n (ratios) => ratios.height,\n );\n const heightRatio = findClosestNumber(heightRatios, aspectHeightRatio);\n\n // Reverse find the ratio type used\n for (const [ratioType, ratios] of Object.entries(S.GRID_GALLERY_RATIOS)) {\n if (ratios.height === heightRatio) {\n return ratioType as RatioType;\n }\n }\n\n // Default to square\n return RatioType.OneThird;\n },\n [],\n );\n\n // #############################################################################\n // Parse assets\n // #############################################################################\n const parsedAssets = useMemo((): GridGalleryParsedAsset[] => {\n // Parse items\n const parsed = assetsInitial.map((asset) => {\n const ratioType = getAssetAspectRatioType(asset);\n\n return {\n ...asset,\n ratioType,\n };\n });\n\n // Find how many non-OneWhole items there are\n const nonOneWholeCount = parsed.filter(\n (asset) => asset.ratioType !== RatioType.OneWhole,\n ).length;\n\n // If the count is odd, make the first video full size\n let setFirstVideoAsOneWhole = (nonOneWholeCount & 1) === 1;\n\n return parsed.map((asset) => {\n if (asset.isVideo && setFirstVideoAsOneWhole) {\n // Don't adjust other videos\n setFirstVideoAsOneWhole = false;\n // Set as one whole\n asset.ratioType = RatioType.OneWhole;\n }\n\n return asset;\n });\n }, [assetsInitial, getAssetAspectRatioType]);\n\n // #############################################################################\n // Asset rows\n // #############################################################################\n const [assetRows, setAssetRows] = useState<GridGalleryAssetRow[]>([]);\n\n const createAssetRows = useCallback(() => {\n // Rows that have all space filled\n const fullRows: GridGalleryAssetRow[] = [];\n // Rows with less items to fill the row\n const partialRows: GridGalleryAssetRow[] = [];\n\n // Clone assets for mutation\n const availableAssets = [...parsedAssets];\n\n // Find and splice helper\n const findAndSpliceByRatioType = (\n ratioType: GridGalleryParsedAsset[\"ratioType\"],\n // Finding a matching asset for a video\n forVideo?: boolean,\n ): GridGalleryParsedAsset | undefined => {\n const index = availableAssets.findIndex((asset) => {\n if (forVideo) {\n // Find any that is not full width\n return asset.ratioType !== RatioType.OneWhole;\n }\n\n // Match the aspect ratio\n return asset.ratioType === ratioType;\n });\n\n if (index === -1) return;\n\n return availableAssets.splice(index, 1)[0];\n };\n\n // Assign rows until all assets are used\n while (availableAssets.length > 0) {\n // Group assets that can all fit the row\n const rowAssets: GridGalleryAssetRow[\"assets\"] = [];\n\n // Take and remove the first asset\n const asset = availableAssets.splice(0, 1)[0];\n if (!asset) break;\n\n // Check if can take more items\n switch (asset.ratioType) {\n case RatioType.OneThird:\n // Add next two one-third assets\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(asset.ratioType, asset.isVideo),\n // Skip the second item if current asset is a video\n !asset.isVideo &&\n findAndSpliceByRatioType(asset.ratioType, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.ThreeTwos:\n // Add one two-thirds item\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(RatioType.TwoThirds, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.TwoThirds:\n // Add one three-twos item\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(RatioType.ThreeTwos, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.OneWhole:\n default:\n // None\n break;\n }\n\n if (\n // Matching assets not found\n !rowAssets.length &&\n // Unless it's one whole which fills it alone\n asset.ratioType !== RatioType.OneWhole\n ) {\n // Add to partial rows\n partialRows.push({\n assets: [asset],\n partial: true,\n });\n } else {\n // Add to full rows\n // Counting 1+1 one-third items as full (can grow to one-half with css)\n fullRows.push({\n assets: [asset, ...rowAssets],\n partial: false,\n });\n }\n }\n\n // Combine partial rows as groups of two\n // Here can only reside 1xRow one-thirds or 1xRow two-thirds/three-twos(one of)\n // TODO future improvement is perhaps to not combine 2x three-twos and try for three-twos and one-third\n const partialRowAssets = partialRows.flatMap((row) => row.assets);\n\n for (let i = 0; i < partialRowAssets.length; i += 2) {\n const combinedRowAssets = [\n partialRowAssets[i],\n partialRowAssets[i + 1],\n ].filter((item): item is GridGalleryParsedAsset => !!item);\n\n if (combinedRowAssets.length) {\n fullRows.push({\n assets: combinedRowAssets,\n partial: true,\n });\n }\n }\n\n // Set the rows\n setAssetRows(fullRows);\n }, [parsedAssets]);\n\n // Create rows on assets change\n useEffect(() => {\n createAssetRows();\n }, [\n // HACK: needed parsedAssets to retrigger the effect\n\n parsedAssets,\n createAssetRows,\n ]);\n\n // #############################################################################\n // Render (Mobile)\n // #############################################################################\n if (isTablet) {\n return (\n <S.MobileGalleryOuterWrap>\n {assetsInitial\n // No videos on small devices\n .filter((asset) => !asset.isVideo)\n .map((asset, i) => (\n <S.MobileAssetWrap key={asset.src + i}>\n <S.MobileImage\n asset={asset}\n sizes=\"100%\"\n responsive\n renderImage={renderImage}\n />\n </S.MobileAssetWrap>\n ))}\n </S.MobileGalleryOuterWrap>\n );\n }\n\n // #############################################################################\n // Render (Desktop)\n // #############################################################################\n return (\n <S.Wrap className={className}>\n {assetRows.map((row, rowIndex) => (\n <S.ImagesRow key={rowIndex} $center={row.partial}>\n {row.assets.map((asset, assetIndex) => {\n const previewVideo = asset.childAssets?.find(\n (childAsset) => childAsset.isVideo,\n );\n const videoPoster = asset.childAssets?.find(\n (childAsset) => !childAsset.isVideo,\n );\n\n return (\n <S.ImageWrap\n key={`${asset.src}-${assetIndex}`}\n $ratioType={asset.ratioType}\n // ? This can be adjusted if the look is too weird/scaled\n $grow={row.assets.length !== 1}\n >\n {asset.isVideo ? (\n <>\n <S.Video\n width={asset.width}\n height={asset.height}\n autoPlay\n playsInline\n muted\n poster={videoPoster?.src}\n loop\n >\n <source src={asset.src} type=\"video/mp4\" />\n </S.Video>\n <S.VideoOverlay\n $hasVideo={!!previewVideo}\n onClick={() =>\n !!previewVideo && setActiveModalId(asset.src)\n }\n >\n {!!previewVideo && (\n <StyleableSvgImage\n src={PlayIcon}\n width={48}\n height={48}\n />\n )}\n </S.VideoOverlay>\n {activeModalId === asset.src && previewVideo && (\n <GridModal\n onClose={() => setActiveModalId(\"\")}\n open\n src={previewVideo.src}\n width={previewVideo.width}\n height={previewVideo.height}\n videoStartTime={asset.videoStartTime}\n />\n )}\n </>\n ) : (\n <S.Image\n asset={asset}\n renderImage={renderImage}\n sizes=\"100%\"\n objectFit=\"cover\"\n layout=\"responsive\"\n responsive\n priority={priority}\n />\n )}\n </S.ImageWrap>\n );\n })}\n </S.ImagesRow>\n ))}\n </S.Wrap>\n );\n};\n"],"names":["GridGallery","GridGallery2","className","renderImage","assets","assetsInitial","priority","onModalToggle","isTablet","useMedia","BREAKPOINTS","TABLET_AND_DOWN","activeModalId","setActiveModalId","useState","useEffect","getAssetAspectRatioType","useCallback","asset","aspectHeightRatio","height","width","heightRatios","Object","values","S.GRID_GALLERY_RATIOS","map","ratios","heightRatio","findClosestNumber","ratioType","entries","RatioType","OneThird","parsedAssets","useMemo","parsed","nonOneWholeCount","filter","OneWhole","length","setFirstVideoAsOneWhole","isVideo","assetRows","setAssetRows","createAssetRows","fullRows","partialRows","availableAssets","findAndSpliceByRatioType","forVideo","index","findIndex","splice","rowAssets","push","item","ThreeTwos","TwoThirds","partial","partialRowAssets","flatMap","row","i","combinedRowAssets","S.MobileGalleryOuterWrap","children","jsx","S.MobileAssetWrap","S.MobileImage","MobileImage","sizes","responsive","src","S.Wrap","rowIndex","S.ImagesRow","ImagesRow","$center","assetIndex","previewVideo","childAssets","find","childAsset","videoPoster","S.ImageWrap","ImageWrap","$ratioType","$grow","jsxs","Fragment","S.Video","Video","autoPlay","playsInline","muted","poster","loop","type","S.VideoOverlay","VideoOverlay","$hasVideo","onClick","StyleableSvgImage","PlayIcon","GridModal","onClose","open","videoStartTime","S.Image","Image","objectFit","layout"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAgBa,MAAAA,WAAA,GAAc,SAASA,YAAYC,CAAA;EAC9CC,SAAA;EACAC,WAAA;EACAC,MAAQ,EAAAC,aAAA;EACRC,QAAA;EACAC;AACF,CAAqB,EAAA;EACnB,MAAMC,QAAW,GAAAC,QAAA,CAAAA,QAAA,CAASC,MAAY,CAAAA,WAAA,CAAAC,eAAA,EAAiB,KAAK,CAAA;EAE5D,MAAM,CAACC,aAAA,EAAeC,gBAAgB,CAAA,GAAIC,eAAiB,EAAE,CAAA;EAC7DC,KAAAA,CAAAA,SAAA,CAAU,MAAM;IACdR,aAAA,GAAgBK,aAAa,CAAA;EAAA,CAC5B,EAAA,CAACL,aAAe,EAAAK,aAAa,CAAC,CAAA;EAKjC,MAAMI,uBAA0B,GAAAC,KAAA,CAAAA,WAAA,CAC7BC,KAAyD,IAAA;IAElD,MAAAC,iBAAA,GAAoBD,KAAM,CAAAE,MAAA,GAASF,KAAM,CAAAG,KAAA;IAG/C,MAAMC,YAAe,GAAAC,MAAA,CAAOC,MAAO,CAAAC,kBAAAA,CAAAA,mBAAqB,CAAE,CAAAC,GAAA,CACvDC,UAAWA,MAAO,CAAAP,MAAA,CACrB;IACM,MAAAQ,WAAA,GAAcC,MAAAA,CAAAA,iBAAkB,CAAAP,YAAA,EAAcH,iBAAiB,CAAA;IAG1D,KAAA,MAAA,CAACW,WAAWH,MAAM,CAAA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2D,YAAa,CAAA3D,KAAA;cACpBD,QAAQ4D,YAAa,CAAA5D,MAAA;cACrBwF,gBAAgB1F,KAAM,CAAA0F;YAAA,CACxB,CAAA;UAAA,CAEJ,CAEA,GAAA,eAAAzC,UAAA,CAAAA,GAAA,CAAC0C,kBAAE,CAAAC,KAAA,EAAF;YACC5F,KAAA;YACAf,WAAA;YACAoE,KAAM,EAAA,MAAA;YACNwC,SAAU,EAAA,OAAA;YACVC,MAAO,EAAA,YAAA;YACPxC,UAAU,EAAA,IAAA;YACVlE;UAAA,CACF;QAAA,CAAA,EApDG,GAAGY,KAAA,CAAMuD,GAAG,IAAIM,UAAU,EAAA,CAsDjC;MAEH,CAAA;KAAA,EAnEeJ,QAoElB,CACD;EACH,CAAA,CAAA;AAEJ,CAAA;"}
1
+ {"version":3,"file":"GridGallery.js","sources":["../../../src/components/GridGallery/GridGallery.tsx"],"sourcesContent":["import { useCallback, useEffect, useMemo, useState } from \"react\";\nimport { useMedia } from \"react-use\";\n\nimport PlayIcon from \"../../assets/icons/play-big.svg\";\nimport { BREAKPOINTS } from \"../../constants/layout\";\nimport { findClosestNumber } from \"../../utils/number\";\nimport { StyleableSvgImage } from \"../StyleableSvgImage\";\nimport * as S from \"./GridGallery.styles\";\nimport type {\n GridGalleryAssetRow,\n GridGalleryParsedAsset,\n GridGalleryProps,\n} from \"./GridGallery.types\";\nimport { RatioType } from \"./GridGallery.types\";\nimport { GridModal } from \"./GridModal/GridModal\";\n\nexport const GridGallery = function GridGallery({\n className,\n renderImage,\n assets: assetsInitial,\n priority,\n onModalToggle,\n}: GridGalleryProps) {\n const isTablet = useMedia(BREAKPOINTS.TABLET_AND_DOWN, false);\n\n const [activeModalId, setActiveModalId] = useState<string>(\"\");\n useEffect(() => {\n onModalToggle?.(activeModalId);\n }, [onModalToggle, activeModalId]);\n\n // #############################################################################\n // Asset helpers\n // #############################################################################\n const getAssetAspectRatioType = useCallback(\n (asset: GridGalleryProps[\"assets\"][number]): RatioType => {\n // Get asset height ratio\n const aspectHeightRatio = asset.height / asset.width;\n\n // Find the closest height ratio the image uses\n const heightRatios = Object.values(S.GRID_GALLERY_RATIOS).map(\n (ratios) => ratios.height,\n );\n const heightRatio = findClosestNumber(heightRatios, aspectHeightRatio);\n\n // Reverse find the ratio type used\n for (const [ratioType, ratios] of Object.entries(S.GRID_GALLERY_RATIOS)) {\n if (ratios.height === heightRatio) {\n return ratioType as RatioType;\n }\n }\n\n // Default to square\n return RatioType.OneThird;\n },\n [],\n );\n\n // #############################################################################\n // Parse assets\n // #############################################################################\n const parsedAssets = useMemo((): GridGalleryParsedAsset[] => {\n // Parse items\n const parsed = assetsInitial.map((asset) => {\n const ratioType = getAssetAspectRatioType(asset);\n\n return {\n ...asset,\n ratioType,\n };\n });\n\n // Find how many non-OneWhole items there are\n const nonOneWholeCount = parsed.filter(\n (asset) => asset.ratioType !== RatioType.OneWhole,\n ).length;\n\n // If the count is odd, make the first video full size\n let setFirstVideoAsOneWhole = (nonOneWholeCount & 1) === 1;\n\n return parsed.map((asset) => {\n if (asset.isVideo && setFirstVideoAsOneWhole) {\n // Don't adjust other videos\n setFirstVideoAsOneWhole = false;\n // Set as one whole\n asset.ratioType = RatioType.OneWhole;\n }\n\n return asset;\n });\n }, [assetsInitial, getAssetAspectRatioType]);\n\n // #############################################################################\n // Asset rows\n // #############################################################################\n const [assetRows, setAssetRows] = useState<GridGalleryAssetRow[]>([]);\n\n const createAssetRows = useCallback(() => {\n // Rows that have all space filled\n const fullRows: GridGalleryAssetRow[] = [];\n // Rows with less items to fill the row\n const partialRows: GridGalleryAssetRow[] = [];\n\n // Clone assets for mutation\n const availableAssets = [...parsedAssets];\n\n // Find and splice helper\n const findAndSpliceByRatioType = (\n ratioType: GridGalleryParsedAsset[\"ratioType\"],\n // Finding a matching asset for a video\n forVideo?: boolean,\n ): GridGalleryParsedAsset | undefined => {\n const index = availableAssets.findIndex((asset) => {\n if (forVideo) {\n // Find any that is not full width\n return asset.ratioType !== RatioType.OneWhole;\n }\n\n // Match the aspect ratio\n return asset.ratioType === ratioType;\n });\n\n if (index === -1) return;\n\n return availableAssets.splice(index, 1)[0];\n };\n\n // Assign rows until all assets are used\n while (availableAssets.length > 0) {\n // Group assets that can all fit the row\n const rowAssets: GridGalleryAssetRow[\"assets\"] = [];\n\n // Take and remove the first asset\n const asset = availableAssets.splice(0, 1)[0];\n if (!asset) break;\n\n // Check if can take more items\n switch (asset.ratioType) {\n case RatioType.OneThird:\n // Add next two one-third assets\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(asset.ratioType, asset.isVideo),\n // Skip the second item if current asset is a video\n !asset.isVideo &&\n findAndSpliceByRatioType(asset.ratioType, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.ThreeTwos:\n // Add one two-thirds item\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(RatioType.TwoThirds, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.TwoThirds:\n // Add one three-twos item\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(RatioType.ThreeTwos, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.OneWhole:\n default:\n // None\n break;\n }\n\n if (\n // Matching assets not found\n !rowAssets.length &&\n // Unless it's one whole which fills it alone\n asset.ratioType !== RatioType.OneWhole\n ) {\n // Add to partial rows\n partialRows.push({\n assets: [asset],\n partial: true,\n });\n } else {\n // Add to full rows\n // Counting 1+1 one-third items as full (can grow to one-half with css)\n fullRows.push({\n assets: [asset, ...rowAssets],\n partial: false,\n });\n }\n }\n\n // Combine partial rows as groups of two\n // Here can only reside 1xRow one-thirds or 1xRow two-thirds/three-twos(one of)\n // TODO future improvement is perhaps to not combine 2x three-twos and try for three-twos and one-third\n const partialRowAssets = partialRows.flatMap((row) => row.assets);\n\n for (let i = 0; i < partialRowAssets.length; i += 2) {\n const combinedRowAssets = [\n partialRowAssets[i],\n partialRowAssets[i + 1],\n ].filter((item): item is GridGalleryParsedAsset => !!item);\n\n if (combinedRowAssets.length) {\n fullRows.push({\n assets: combinedRowAssets,\n partial: true,\n });\n }\n }\n\n // Set the rows\n setAssetRows(fullRows);\n }, [parsedAssets]);\n\n // Create rows on assets change\n useEffect(() => {\n createAssetRows();\n }, [\n // HACK: needed parsedAssets to retrigger the effect\n\n parsedAssets,\n createAssetRows,\n ]);\n\n // #############################################################################\n // Render (Mobile)\n // #############################################################################\n if (isTablet) {\n return (\n <S.MobileGalleryOuterWrap>\n {assetsInitial\n // No videos on small devices\n .filter((asset) => !asset.isVideo)\n .map((asset, i) => (\n <S.MobileAssetWrap key={asset.src + i}>\n <S.MobileImage\n asset={asset}\n sizes=\"100%\"\n responsive\n renderImage={renderImage}\n />\n </S.MobileAssetWrap>\n ))}\n </S.MobileGalleryOuterWrap>\n );\n }\n\n // #############################################################################\n // Render (Desktop)\n // #############################################################################\n return (\n <S.Wrap className={className}>\n {assetRows.map((row, rowIndex) => (\n <S.ImagesRow key={rowIndex} $center={row.partial}>\n {row.assets.map((asset, assetIndex) => {\n const previewVideo = asset.childAssets?.find(\n (childAsset) => childAsset.isVideo,\n );\n const videoPoster = asset.childAssets?.find(\n (childAsset) => !childAsset.isVideo,\n );\n\n return (\n <S.ImageWrap\n key={`${asset.src}-${assetIndex}`}\n $ratioType={asset.ratioType}\n // ? This can be adjusted if the look is too weird/scaled\n $grow={row.assets.length !== 1}\n >\n {asset.isVideo ? (\n <>\n <S.Video\n width={asset.width}\n height={asset.height}\n autoPlay\n playsInline\n muted\n poster={videoPoster?.src}\n loop\n >\n <source src={asset.src} type=\"video/mp4\" />\n </S.Video>\n <S.VideoOverlay\n hasVideo={!!previewVideo}\n onClick={() =>\n !!previewVideo && setActiveModalId(asset.src)\n }\n >\n {!!previewVideo && (\n <StyleableSvgImage\n src={PlayIcon}\n width={48}\n height={48}\n />\n )}\n </S.VideoOverlay>\n {activeModalId === asset.src && previewVideo && (\n <GridModal\n onClose={() => setActiveModalId(\"\")}\n open\n src={previewVideo.src}\n width={previewVideo.width}\n height={previewVideo.height}\n videoStartTime={asset.videoStartTime}\n />\n )}\n </>\n ) : (\n <S.Image\n asset={asset}\n renderImage={renderImage}\n sizes=\"100%\"\n objectFit=\"cover\"\n layout=\"responsive\"\n responsive\n priority={priority}\n />\n )}\n </S.ImageWrap>\n );\n })}\n </S.ImagesRow>\n ))}\n </S.Wrap>\n );\n};\n"],"names":["GridGallery","GridGallery2","className","renderImage","assets","assetsInitial","priority","onModalToggle","isTablet","useMedia","BREAKPOINTS","TABLET_AND_DOWN","activeModalId","setActiveModalId","useState","useEffect","getAssetAspectRatioType","useCallback","asset","aspectHeightRatio","height","width","heightRatios","Object","values","S.GRID_GALLERY_RATIOS","map","ratios","heightRatio","findClosestNumber","ratioType","entries","RatioType","OneThird","parsedAssets","useMemo","parsed","nonOneWholeCount","filter","OneWhole","length","setFirstVideoAsOneWhole","isVideo","assetRows","setAssetRows","createAssetRows","fullRows","partialRows","availableAssets","findAndSpliceByRatioType","forVideo","index","findIndex","splice","rowAssets","push","item","ThreeTwos","TwoThirds","partial","partialRowAssets","flatMap","row","i","combinedRowAssets","S.MobileGalleryOuterWrap","children","jsx","S.MobileAssetWrap","S.MobileImage","MobileImage","sizes","responsive","src","S.Wrap","rowIndex","S.ImagesRow","ImagesRow","$center","assetIndex","previewVideo","childAssets","find","childAsset","videoPoster","S.ImageWrap","ImageWrap","$ratioType","$grow","jsxs","Fragment","S.Video","Video","autoPlay","playsInline","muted","poster","loop","type","S.VideoOverlay","VideoOverlay","hasVideo","onClick","StyleableSvgImage","PlayIcon","GridModal","onClose","open","videoStartTime","S.Image","Image","objectFit","layout"],"mappings":";;;;;;;;;;;;;;;;;;;;;AAgBa,MAAAA,WAAA,GAAc,SAASA,YAAYC,CAAA;EAC9CC,SAAA;EACAC,WAAA;EACAC,MAAQ,EAAAC,aAAA;EACRC,QAAA;EACAC;AACF,CAAqB,EAAA;EACnB,MAAM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({
156
156
  type: "video/mp4"
157
157
  })
158
158
  }), /* @__PURE__ */jsx(VideoOverlay, {
159
- $hasVideo: !!previewVideo,
159
+ hasVideo: !!previewVideo,
160
160
  onClick: () => !!previewVideo && setActiveModalId(asset.src),
161
161
  children: !!previewVideo && /* @__PURE__ */jsx(StyleableSvgImage, {
162
162
  src: PlayIcon__default,
@@ -1 +1 @@
1
- {"version":3,"file":"GridGallery.mjs","sources":["../../../src/components/GridGallery/GridGallery.tsx"],"sourcesContent":["import { useCallback, useEffect, useMemo, useState } from \"react\";\nimport { useMedia } from \"react-use\";\n\nimport PlayIcon from \"../../assets/icons/play-big.svg\";\nimport { BREAKPOINTS } from \"../../constants/layout\";\nimport { findClosestNumber } from \"../../utils/number\";\nimport { StyleableSvgImage } from \"../StyleableSvgImage\";\nimport * as S from \"./GridGallery.styles\";\nimport type {\n GridGalleryAssetRow,\n GridGalleryParsedAsset,\n GridGalleryProps,\n} from \"./GridGallery.types\";\nimport { RatioType } from \"./GridGallery.types\";\nimport { GridModal } from \"./GridModal/GridModal\";\n\nexport const GridGallery = function GridGallery({\n className,\n renderImage,\n assets: assetsInitial,\n priority,\n onModalToggle,\n}: GridGalleryProps) {\n const isTablet = useMedia(BREAKPOINTS.TABLET_AND_DOWN, false);\n\n const [activeModalId, setActiveModalId] = useState<string>(\"\");\n useEffect(() => {\n onModalToggle?.(activeModalId);\n }, [onModalToggle, activeModalId]);\n\n // #############################################################################\n // Asset helpers\n // #############################################################################\n const getAssetAspectRatioType = useCallback(\n (asset: GridGalleryProps[\"assets\"][number]): RatioType => {\n // Get asset height ratio\n const aspectHeightRatio = asset.height / asset.width;\n\n // Find the closest height ratio the image uses\n const heightRatios = Object.values(S.GRID_GALLERY_RATIOS).map(\n (ratios) => ratios.height,\n );\n const heightRatio = findClosestNumber(heightRatios, aspectHeightRatio);\n\n // Reverse find the ratio type used\n for (const [ratioType, ratios] of Object.entries(S.GRID_GALLERY_RATIOS)) {\n if (ratios.height === heightRatio) {\n return ratioType as RatioType;\n }\n }\n\n // Default to square\n return RatioType.OneThird;\n },\n [],\n );\n\n // #############################################################################\n // Parse assets\n // #############################################################################\n const parsedAssets = useMemo((): GridGalleryParsedAsset[] => {\n // Parse items\n const parsed = assetsInitial.map((asset) => {\n const ratioType = getAssetAspectRatioType(asset);\n\n return {\n ...asset,\n ratioType,\n };\n });\n\n // Find how many non-OneWhole items there are\n const nonOneWholeCount = parsed.filter(\n (asset) => asset.ratioType !== RatioType.OneWhole,\n ).length;\n\n // If the count is odd, make the first video full size\n let setFirstVideoAsOneWhole = (nonOneWholeCount & 1) === 1;\n\n return parsed.map((asset) => {\n if (asset.isVideo && setFirstVideoAsOneWhole) {\n // Don't adjust other videos\n setFirstVideoAsOneWhole = false;\n // Set as one whole\n asset.ratioType = RatioType.OneWhole;\n }\n\n return asset;\n });\n }, [assetsInitial, getAssetAspectRatioType]);\n\n // #############################################################################\n // Asset rows\n // #############################################################################\n const [assetRows, setAssetRows] = useState<GridGalleryAssetRow[]>([]);\n\n const createAssetRows = useCallback(() => {\n // Rows that have all space filled\n const fullRows: GridGalleryAssetRow[] = [];\n // Rows with less items to fill the row\n const partialRows: GridGalleryAssetRow[] = [];\n\n // Clone assets for mutation\n const availableAssets = [...parsedAssets];\n\n // Find and splice helper\n const findAndSpliceByRatioType = (\n ratioType: GridGalleryParsedAsset[\"ratioType\"],\n // Finding a matching asset for a video\n forVideo?: boolean,\n ): GridGalleryParsedAsset | undefined => {\n const index = availableAssets.findIndex((asset) => {\n if (forVideo) {\n // Find any that is not full width\n return asset.ratioType !== RatioType.OneWhole;\n }\n\n // Match the aspect ratio\n return asset.ratioType === ratioType;\n });\n\n if (index === -1) return;\n\n return availableAssets.splice(index, 1)[0];\n };\n\n // Assign rows until all assets are used\n while (availableAssets.length > 0) {\n // Group assets that can all fit the row\n const rowAssets: GridGalleryAssetRow[\"assets\"] = [];\n\n // Take and remove the first asset\n const asset = availableAssets.splice(0, 1)[0];\n if (!asset) break;\n\n // Check if can take more items\n switch (asset.ratioType) {\n case RatioType.OneThird:\n // Add next two one-third assets\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(asset.ratioType, asset.isVideo),\n // Skip the second item if current asset is a video\n !asset.isVideo &&\n findAndSpliceByRatioType(asset.ratioType, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.ThreeTwos:\n // Add one two-thirds item\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(RatioType.TwoThirds, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.TwoThirds:\n // Add one three-twos item\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(RatioType.ThreeTwos, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.OneWhole:\n default:\n // None\n break;\n }\n\n if (\n // Matching assets not found\n !rowAssets.length &&\n // Unless it's one whole which fills it alone\n asset.ratioType !== RatioType.OneWhole\n ) {\n // Add to partial rows\n partialRows.push({\n assets: [asset],\n partial: true,\n });\n } else {\n // Add to full rows\n // Counting 1+1 one-third items as full (can grow to one-half with css)\n fullRows.push({\n assets: [asset, ...rowAssets],\n partial: false,\n });\n }\n }\n\n // Combine partial rows as groups of two\n // Here can only reside 1xRow one-thirds or 1xRow two-thirds/three-twos(one of)\n // TODO future improvement is perhaps to not combine 2x three-twos and try for three-twos and one-third\n const partialRowAssets = partialRows.flatMap((row) => row.assets);\n\n for (let i = 0; i < partialRowAssets.length; i += 2) {\n const combinedRowAssets = [\n partialRowAssets[i],\n partialRowAssets[i + 1],\n ].filter((item): item is GridGalleryParsedAsset => !!item);\n\n if (combinedRowAssets.length) {\n fullRows.push({\n assets: combinedRowAssets,\n partial: true,\n });\n }\n }\n\n // Set the rows\n setAssetRows(fullRows);\n }, [parsedAssets]);\n\n // Create rows on assets change\n useEffect(() => {\n createAssetRows();\n }, [\n // HACK: needed parsedAssets to retrigger the effect\n\n parsedAssets,\n createAssetRows,\n ]);\n\n // #############################################################################\n // Render (Mobile)\n // #############################################################################\n if (isTablet) {\n return (\n <S.MobileGalleryOuterWrap>\n {assetsInitial\n // No videos on small devices\n .filter((asset) => !asset.isVideo)\n .map((asset, i) => (\n <S.MobileAssetWrap key={asset.src + i}>\n <S.MobileImage\n asset={asset}\n sizes=\"100%\"\n responsive\n renderImage={renderImage}\n />\n </S.MobileAssetWrap>\n ))}\n </S.MobileGalleryOuterWrap>\n );\n }\n\n // #############################################################################\n // Render (Desktop)\n // #############################################################################\n return (\n <S.Wrap className={className}>\n {assetRows.map((row, rowIndex) => (\n <S.ImagesRow key={rowIndex} $center={row.partial}>\n {row.assets.map((asset, assetIndex) => {\n const previewVideo = asset.childAssets?.find(\n (childAsset) => childAsset.isVideo,\n );\n const videoPoster = asset.childAssets?.find(\n (childAsset) => !childAsset.isVideo,\n );\n\n return (\n <S.ImageWrap\n key={`${asset.src}-${assetIndex}`}\n $ratioType={asset.ratioType}\n // ? This can be adjusted if the look is too weird/scaled\n $grow={row.assets.length !== 1}\n >\n {asset.isVideo ? (\n <>\n <S.Video\n width={asset.width}\n height={asset.height}\n autoPlay\n playsInline\n muted\n poster={videoPoster?.src}\n loop\n >\n <source src={asset.src} type=\"video/mp4\" />\n </S.Video>\n <S.VideoOverlay\n $hasVideo={!!previewVideo}\n onClick={() =>\n !!previewVideo && setActiveModalId(asset.src)\n }\n >\n {!!previewVideo && (\n <StyleableSvgImage\n src={PlayIcon}\n width={48}\n height={48}\n />\n )}\n </S.VideoOverlay>\n {activeModalId === asset.src && previewVideo && (\n <GridModal\n onClose={() => setActiveModalId(\"\")}\n open\n src={previewVideo.src}\n width={previewVideo.width}\n height={previewVideo.height}\n videoStartTime={asset.videoStartTime}\n />\n )}\n </>\n ) : (\n <S.Image\n asset={asset}\n renderImage={renderImage}\n sizes=\"100%\"\n objectFit=\"cover\"\n layout=\"responsive\"\n responsive\n priority={priority}\n />\n )}\n </S.ImageWrap>\n );\n })}\n </S.ImagesRow>\n ))}\n </S.Wrap>\n );\n};\n"],"names":["GridGallery","GridGallery2","className","renderImage","assets","assetsInitial","priority","onModalToggle","isTablet","useMedia","BREAKPOINTS","TABLET_AND_DOWN","activeModalId","setActiveModalId","useState","useEffect","getAssetAspectRatioType","useCallback","asset","aspectHeightRatio","height","width","heightRatios","Object","values","S.GRID_GALLERY_RATIOS","map","ratios","heightRatio","findClosestNumber","ratioType","entries","RatioType","OneThird","parsedAssets","useMemo","parsed","nonOneWholeCount","filter","OneWhole","length","setFirstVideoAsOneWhole","isVideo","assetRows","setAssetRows","createAssetRows","fullRows","partialRows","availableAssets","findAndSpliceByRatioType","forVideo","index","findIndex","splice","rowAssets","push","item","ThreeTwos","TwoThirds","partial","partialRowAssets","flatMap","row","i","combinedRowAssets","S.MobileGalleryOuterWrap","children","jsx","S.MobileAssetWrap","S.MobileImage","sizes","responsive","src","S.Wrap","rowIndex","S.ImagesRow","$center","assetIndex","previewVideo","childAssets","find","childAsset","videoPoster","S.ImageWrap","$ratioType","$grow","jsxs","Fragment","S.Video","autoPlay","playsInline","muted","poster","loop","type","S.VideoOverlay","$hasVideo","onClick","StyleableSvgImage","PlayIcon","GridModal","onClose","open","videoStartTime","S.Image","objectFit","layout"],"mappings":";;;;;;;;;;;;;AAgBa,MAAAA,WAAA,GAAc,SAASA,YAAYC,CAAA;EAC9CC,SAAA;EACAC,WAAA;EACAC,MAAQ,EAAAC,aAAA;EACRC,QAAA;EACAC;AACF,CAAqB,EAAA;EACnB,MAAMC,QAAW,GAAAC,QAAA,CAASC,WAAY,CAAAC,eAAA,EAAiB,KAAK,CAAA;EAE5D,MAAM,CAACC,aAAA,EAAeC,gBAAgB,CAAA,GAAIC,SAAiB,EAAE,CAAA;EAC7DC,SAAA,CAAU,MAAM;IACdR,aAAA,GAAgBK,aAAa,CAAA;EAAA,CAC5B,EAAA,CAACL,aAAe,EAAAK,aAAa,CAAC,CAAA;EAKjC,MAAMI,uBAA0B,GAAAC,WAAA,CAC7BC,KA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ACAmE,KAAM,EAAA,MAAA;YACNmC,SAAU,EAAA,OAAA;YACVC,MAAO,EAAA,YAAA;YACPnC,UAAU,EAAA,IAAA;YACVjE;UAAA,CACF;QAAA,CAAA,EApDG,GAAGY,KAAA,CAAMsD,GAAG,IAAIK,UAAU,EAAA,CAsDjC;MAEH,CAAA;KAAA,EAnEeH,QAoElB,CACD;EACH,CAAA,CAAA;AAEJ,CAAA;"}
1
+ {"version":3,"file":"GridGallery.mjs","sources":["../../../src/components/GridGallery/GridGallery.tsx"],"sourcesContent":["import { useCallback, useEffect, useMemo, useState } from \"react\";\nimport { useMedia } from \"react-use\";\n\nimport PlayIcon from \"../../assets/icons/play-big.svg\";\nimport { BREAKPOINTS } from \"../../constants/layout\";\nimport { findClosestNumber } from \"../../utils/number\";\nimport { StyleableSvgImage } from \"../StyleableSvgImage\";\nimport * as S from \"./GridGallery.styles\";\nimport type {\n GridGalleryAssetRow,\n GridGalleryParsedAsset,\n GridGalleryProps,\n} from \"./GridGallery.types\";\nimport { RatioType } from \"./GridGallery.types\";\nimport { GridModal } from \"./GridModal/GridModal\";\n\nexport const GridGallery = function GridGallery({\n className,\n renderImage,\n assets: assetsInitial,\n priority,\n onModalToggle,\n}: GridGalleryProps) {\n const isTablet = useMedia(BREAKPOINTS.TABLET_AND_DOWN, false);\n\n const [activeModalId, setActiveModalId] = useState<string>(\"\");\n useEffect(() => {\n onModalToggle?.(activeModalId);\n }, [onModalToggle, activeModalId]);\n\n // #############################################################################\n // Asset helpers\n // #############################################################################\n const getAssetAspectRatioType = useCallback(\n (asset: GridGalleryProps[\"assets\"][number]): RatioType => {\n // Get asset height ratio\n const aspectHeightRatio = asset.height / asset.width;\n\n // Find the closest height ratio the image uses\n const heightRatios = Object.values(S.GRID_GALLERY_RATIOS).map(\n (ratios) => ratios.height,\n );\n const heightRatio = findClosestNumber(heightRatios, aspectHeightRatio);\n\n // Reverse find the ratio type used\n for (const [ratioType, ratios] of Object.entries(S.GRID_GALLERY_RATIOS)) {\n if (ratios.height === heightRatio) {\n return ratioType as RatioType;\n }\n }\n\n // Default to square\n return RatioType.OneThird;\n },\n [],\n );\n\n // #############################################################################\n // Parse assets\n // #############################################################################\n const parsedAssets = useMemo((): GridGalleryParsedAsset[] => {\n // Parse items\n const parsed = assetsInitial.map((asset) => {\n const ratioType = getAssetAspectRatioType(asset);\n\n return {\n ...asset,\n ratioType,\n };\n });\n\n // Find how many non-OneWhole items there are\n const nonOneWholeCount = parsed.filter(\n (asset) => asset.ratioType !== RatioType.OneWhole,\n ).length;\n\n // If the count is odd, make the first video full size\n let setFirstVideoAsOneWhole = (nonOneWholeCount & 1) === 1;\n\n return parsed.map((asset) => {\n if (asset.isVideo && setFirstVideoAsOneWhole) {\n // Don't adjust other videos\n setFirstVideoAsOneWhole = false;\n // Set as one whole\n asset.ratioType = RatioType.OneWhole;\n }\n\n return asset;\n });\n }, [assetsInitial, getAssetAspectRatioType]);\n\n // #############################################################################\n // Asset rows\n // #############################################################################\n const [assetRows, setAssetRows] = useState<GridGalleryAssetRow[]>([]);\n\n const createAssetRows = useCallback(() => {\n // Rows that have all space filled\n const fullRows: GridGalleryAssetRow[] = [];\n // Rows with less items to fill the row\n const partialRows: GridGalleryAssetRow[] = [];\n\n // Clone assets for mutation\n const availableAssets = [...parsedAssets];\n\n // Find and splice helper\n const findAndSpliceByRatioType = (\n ratioType: GridGalleryParsedAsset[\"ratioType\"],\n // Finding a matching asset for a video\n forVideo?: boolean,\n ): GridGalleryParsedAsset | undefined => {\n const index = availableAssets.findIndex((asset) => {\n if (forVideo) {\n // Find any that is not full width\n return asset.ratioType !== RatioType.OneWhole;\n }\n\n // Match the aspect ratio\n return asset.ratioType === ratioType;\n });\n\n if (index === -1) return;\n\n return availableAssets.splice(index, 1)[0];\n };\n\n // Assign rows until all assets are used\n while (availableAssets.length > 0) {\n // Group assets that can all fit the row\n const rowAssets: GridGalleryAssetRow[\"assets\"] = [];\n\n // Take and remove the first asset\n const asset = availableAssets.splice(0, 1)[0];\n if (!asset) break;\n\n // Check if can take more items\n switch (asset.ratioType) {\n case RatioType.OneThird:\n // Add next two one-third assets\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(asset.ratioType, asset.isVideo),\n // Skip the second item if current asset is a video\n !asset.isVideo &&\n findAndSpliceByRatioType(asset.ratioType, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.ThreeTwos:\n // Add one two-thirds item\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(RatioType.TwoThirds, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.TwoThirds:\n // Add one three-twos item\n rowAssets.push(\n ...[\n findAndSpliceByRatioType(RatioType.ThreeTwos, asset.isVideo),\n ].filter((item): item is GridGalleryParsedAsset => !!item),\n );\n break;\n\n case RatioType.OneWhole:\n default:\n // None\n break;\n }\n\n if (\n // Matching assets not found\n !rowAssets.length &&\n // Unless it's one whole which fills it alone\n asset.ratioType !== RatioType.OneWhole\n ) {\n // Add to partial rows\n partialRows.push({\n assets: [asset],\n partial: true,\n });\n } else {\n // Add to full rows\n // Counting 1+1 one-third items as full (can grow to one-half with css)\n fullRows.push({\n assets: [asset, ...rowAssets],\n partial: false,\n });\n }\n }\n\n // Combine partial rows as groups of two\n // Here can only reside 1xRow one-thirds or 1xRow two-thirds/three-twos(one of)\n // TODO future improvement is perhaps to not combine 2x three-twos and try for three-twos and one-third\n const partialRowAssets = partialRows.flatMap((row) => row.assets);\n\n for (let i = 0; i < partialRowAssets.length; i += 2) {\n const combinedRowAssets = [\n partialRowAssets[i],\n partialRowAssets[i + 1],\n ].filter((item): item is GridGalleryParsedAsset => !!item);\n\n if (combinedRowAssets.length) {\n fullRows.push({\n assets: combinedRowAssets,\n partial: true,\n });\n }\n }\n\n // Set the rows\n setAssetRows(fullRows);\n }, [parsedAssets]);\n\n // Create rows on assets change\n useEffect(() => {\n createAssetRows();\n }, [\n // HACK: needed parsedAssets to retrigger the effect\n\n parsedAssets,\n createAssetRows,\n ]);\n\n // #############################################################################\n // Render (Mobile)\n // #############################################################################\n if (isTablet) {\n return (\n <S.MobileGalleryOuterWrap>\n {assetsInitial\n // No videos on small devices\n .filter((asset) => !asset.isVideo)\n .map((asset, i) => (\n <S.MobileAssetWrap key={asset.src + i}>\n <S.MobileImage\n asset={asset}\n sizes=\"100%\"\n responsive\n renderImage={renderImage}\n />\n </S.MobileAssetWrap>\n ))}\n </S.MobileGalleryOuterWrap>\n );\n }\n\n // #############################################################################\n // Render (Desktop)\n // #############################################################################\n return (\n <S.Wrap className={className}>\n {assetRows.map((row, rowIndex) => (\n <S.ImagesRow key={rowIndex} $center={row.partial}>\n {row.assets.map((asset, assetIndex) => {\n const previewVideo = asset.childAssets?.find(\n (childAsset) => childAsset.isVideo,\n );\n const videoPoster = asset.childAssets?.find(\n (childAsset) => !childAsset.isVideo,\n );\n\n return (\n <S.ImageWrap\n key={`${asset.src}-${assetIndex}`}\n $ratioType={asset.ratioType}\n // ? This can be adjusted if the look is too weird/scaled\n $grow={row.assets.length !== 1}\n >\n {asset.isVideo ? (\n <>\n <S.Video\n width={asset.width}\n height={asset.height}\n autoPlay\n playsInline\n muted\n poster={videoPoster?.src}\n loop\n >\n <source src={asset.src} type=\"video/mp4\" />\n </S.Video>\n <S.VideoOverlay\n hasVideo={!!previewVideo}\n onClick={() =>\n !!previewVideo && setActiveModalId(asset.src)\n }\n >\n {!!previewVideo && (\n <StyleableSvgImage\n src={PlayIcon}\n width={48}\n height={48}\n />\n )}\n </S.VideoOverlay>\n {activeModalId === asset.src && previewVideo && (\n <GridModal\n onClose={() => setActiveModalId(\"\")}\n open\n src={previewVideo.src}\n width={previewVideo.width}\n height={previewVideo.height}\n videoStartTime={asset.videoStartTime}\n />\n )}\n </>\n ) : (\n <S.Image\n asset={asset}\n renderImage={renderImage}\n sizes=\"100%\"\n objectFit=\"cover\"\n layout=\"responsive\"\n responsive\n priority={priority}\n />\n )}\n </S.ImageWrap>\n );\n })}\n </S.ImagesRow>\n ))}\n </S.Wrap>\n );\n};\n"],"names":["GridGallery","GridGallery2","className","renderImage","assets","assetsInitial","priority","onModalToggle","isTablet","useMedia","BREAKPOINTS","TABLET_AND_DOWN","activeModalId","setActiveModalId","useState","useEffect","getAssetAspectRatioType","useCallback","asset","aspectHeightRatio","height","width","heightRatios","Object","values","S.GRID_GALLERY_RATIOS","map","ratios","heightRatio","findClosestNumber","ratioType","entries","RatioType","OneThird","parsedAssets","useMemo","parsed","nonOneWholeCount","filter","OneWhole","length","setFirstVideoAsOneWhole","isVideo","assetRows","setAssetRows","createAssetRows","fullRows","partialRows","availableAssets","findAndSpliceByRatioType","forVideo","index","findIndex","splice","rowAssets","push","item","ThreeTwos","TwoThirds","partial","partialRowAssets","flatMap","row","i","combinedRowAssets","S.MobileGalleryOuterWrap","children","jsx","S.MobileAssetWrap","S.MobileImage","sizes","responsive","src","S.Wrap","rowIndex","S.ImagesRow","$center","assetIndex","previewVideo","childAssets","find","childAsset","videoPoster","S.ImageWrap","$ratioType","$grow","jsxs","Fragment","S.Video","autoPlay","playsInline","muted","poster","loop","type","S.VideoOverlay","hasVideo","onClick","StyleableSvgImage","PlayIcon","GridModal","onClose","open","videoStartTime","S.Image","objectFit","layout"],"mappings":";;;;;;;;;;;;;AAgBa,MAAAA,WAAA,GAAc,SAASA,YAAYC,CAAA;EAC9CC,SAAA;EACAC,WAAA;EACAC,MAAQ,EAAAC,aAAA;EACRC,QAAA;EACAC;AACF,CAAqB,EAAA;EACnB,MAAMC,QAAW,GAAAC,QAAA,CAASC,WAAY,CAAAC,eAAA,EAAiB,KAAK,CAAA;EAE5D,MAAM,CAACC,aAAA,EAAeC,gBAAgB,CAAA,GAAIC,SAAiB,EAAE,CAAA;EAC7DC,SAAA,CAAU,MAAM;IACdR,aAAA,GAAgBK,aAAa,CAAA;EAAA,CAC5B,EAAA,CAACL,aAAe,EAAAK,aAAa,CAAC,CAAA;EAKjC,MAAMI,uBAA0B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ACCtF,KAAA;YACAf,WAAA;YACAmE,KAAM,EAAA,MAAA;YACNmC,SAAU,EAAA,OAAA;YACVC,MAAO,EAAA,YAAA;YACPnC,UAAU,EAAA,IAAA;YACVjE;UAAA,CACF;QAAA,CAAA,EApDG,GAAGY,KAAA,CAAMsD,GAAG,IAAIK,UAAU,EAAA,CAsDjC;MAEH,CAAA;KAAA,EAnEeH,QAoElB,CACD;EACH,CAAA,CAAA;AAEJ,CAAA;"}
@@ -27,19 +27,19 @@ export declare const GRID_GALLERY_RATIOS: {
27
27
  readonly width: 0.577;
28
28
  };
29
29
  };
30
- export declare const Wrap: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
31
- export declare const ImagesRow: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
30
+ export declare const Wrap: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
31
+ export declare const ImagesRow: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
32
32
  $center: boolean;
33
- }>> & string;
34
- export declare const ImageWrap: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
33
+ }, never>;
34
+ export declare const ImageWrap: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
35
35
  $ratioType: RatioType;
36
36
  $grow: boolean;
37
- }>> & string;
38
- export declare const Image: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("../CustomImage/CustomImage.types").CustomImageProps, never>> & string & Omit<({ motif, asset, sizes, className, margin, priority, fallbackImageSize, responsive, layout, renderImage, disableSkeleton, objectFit, disableBorderRadius, canFullscreen, onFullscreenChange, }: import("../CustomImage/CustomImage.types").CustomImageProps) => JSX.Element, keyof import("react").Component<any, {}, any>>;
39
- export declare const Video: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").VideoHTMLAttributes<HTMLVideoElement>, HTMLVideoElement>, never>> & string;
40
- export declare const VideoOverlay: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components/dist/types").Substitute<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {
41
- $hasVideo: boolean;
42
- }>> & string;
43
- export declare const MobileImage: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("../CustomImage/CustomImage.types").CustomImageProps, never>> & string & Omit<({ motif, asset, sizes, className, margin, priority, fallbackImageSize, responsive, layout, renderImage, disableSkeleton, objectFit, disableBorderRadius, canFullscreen, onFullscreenChange, }: import("../CustomImage/CustomImage.types").CustomImageProps) => JSX.Element, keyof import("react").Component<any, {}, any>>;
44
- export declare const MobileAssetWrap: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
45
- export declare const MobileGalleryOuterWrap: import("styled-components/dist/types").IStyledComponentBase<"web", import("styled-components").FastOmit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, never>> & string;
37
+ }, never>;
38
+ export declare const Image: import("styled-components").StyledComponent<({ motif, asset, sizes, className, margin, priority, fallbackImageSize, responsive, layout, renderImage, disableSkeleton, objectFit, disableBorderRadius, canFullscreen, onFullscreenChange, }: import("../CustomImage/CustomImage.types").CustomImageProps) => JSX.Element, import("styled-components").DefaultTheme, {}, never>;
39
+ export declare const Video: import("styled-components").StyledComponent<"video", import("styled-components").DefaultTheme, {}, never>;
40
+ export declare const VideoOverlay: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
41
+ hasVideo: boolean;
42
+ }, never>;
43
+ export declare const MobileImage: import("styled-components").StyledComponent<({ motif, asset, sizes, className, margin, priority, fallbackImageSize, responsive, layout, renderImage, disableSkeleton, objectFit, disableBorderRadius, canFullscreen, onFullscreenChange, }: import("../CustomImage/CustomImage.types").CustomImageProps) => JSX.Element, import("styled-components").DefaultTheme, {}, never>;
44
+ export declare const MobileAssetWrap: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
45
+ export declare const MobileGalleryOuterWrap: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
@@ -93,8 +93,8 @@ const VideoOverlay = styled__default["default"].div`
93
93
  transition: background-color 0.2s;
94
94
 
95
95
  ${({
96
- $hasVideo
97
- }) => $hasVideo && styled.css`
96
+ hasVideo
97
+ }) => hasVideo && styled.css`
98
98
  cursor: pointer;
99
99
 
100
100
  &:hover {
@@ -1 +1 @@
1
- {"version":3,"file":"GridGallery.styles.js","sources":["../../../src/components/GridGallery/GridGallery.styles.ts"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { BREAKPOINTS } from \"../../constants/layout\";\nimport { CustomImage } from \"../CustomImage\";\nimport { RatioType } from \"./GridGallery.types\";\n\n// #############################################################################\n// Constants\n// #############################################################################\nexport const GRID_GALLERY_ITEMS_GAP = 20;\n\n/**\n * # Height\n * Width to height ratio - height is divided by the width.\n * E.g. 350/980=0.357142857 (rounded up to 3 decimals)\n *\n * # Width\n * Width to full width ratio - width is divided by the container width.\n * E.g. 565/980=0.576530612244898 (rounded up to 3 decimals)\n */\nexport const GRID_GALLERY_RATIOS = {\n [RatioType.OneWhole]: {\n height: 0.357, // 350/980,\n width: 1, // 980/980\n },\n [RatioType.OneThird]: {\n height: 1, // 350/350,\n width: 0.357, // 350/980\n },\n [RatioType.TwoThirds]: {\n height: 0.886, // 350/395,\n width: 0.403, // 395/980\n },\n [RatioType.ThreeTwos]: {\n height: 0.619, // 350/565,\n width: 0.577, // 565/980\n },\n} as const;\n\n// #############################################################################\n// Components\n// #############################################################################\nexport const Wrap = styled.div`\n display: flex;\n flex-direction: column;\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n`;\n\nexport const ImagesRow = styled.div<{ $center: boolean }>`\n display: flex;\n justify-content: ${({ $center }) => ($center ? \"center\" : \"space-between\")};\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n`;\n\nexport const ImageWrap = styled.div<{\n $ratioType: RatioType;\n $grow: boolean;\n}>`\n position: relative;\n width: ${({ $ratioType }) =>\n Math.round(GRID_GALLERY_RATIOS[$ratioType].width * 100)}%;\n aspect-ratio: ${({ $ratioType }) =>\n 1 / GRID_GALLERY_RATIOS[$ratioType].height};\n overflow: hidden;\n max-height: 350px;\n\n ${({ $grow }) =>\n $grow &&\n css`\n flex-grow: 1;\n `}\n`;\n\nexport const Image = styled(CustomImage)`\n user-select: none;\n\n img {\n -webkit-user-drag: none;\n }\n`;\n\nexport const Video = styled.video`\n user-select: none;\n width: 100%;\n height: 100%;\n object-fit: cover;\n display: block;\n`;\n\nexport const VideoOverlay = styled.div<{\n $hasVideo: boolean;\n}>`\n position: absolute;\n inset: 0;\n background-color: rgb(0 0 0 / 0.5);\n display: flex;\n justify-content: center;\n align-items: center;\n color: white;\n transition: background-color 0.2s;\n\n ${({ $hasVideo }) =>\n $hasVideo &&\n css`\n cursor: pointer;\n\n &:hover {\n background-color: rgb(0 0 0 / 0.45);\n }\n `}\n`;\n\nexport const MobileImage = styled(CustomImage)``;\n\nexport const MobileAssetWrap = styled.div`\n position: relative;\n border-radius: 4px;\n overflow: hidden;\n width: 100%;\n`;\n\nexport const MobileGalleryOuterWrap = styled.div`\n display: flex;\n flex-direction: column;\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n\n @media ${BREAKPOINTS.TABLET_UP} {\n display: none;\n }\n`;\n"],"names":["GRID_GALLERY_ITEMS_GAP","GRID_GALLERY_RATIOS","RatioType","OneWhole","height","width","OneThird","TwoThirds","ThreeTwos","Wrap","styled","div","ImagesRow","$center","ImageWrap","$ratioType","Math","round","$grow","css","Image","CustomImage","Video","video","VideoOverlay","$hasVideo","MobileImage","MobileAssetWrap","MobileGalleryOuterWrap","BREAKPOINTS","TABLET_UP"],"mappings":";;;;;;;;;;;;;;AASO,MAAMA,sBAAyB,GAAA,EAAA;AAW/B,MAAMC,mBAAsB,GAAA;EACjC,CAACC,iBAAAA,CAAAA,SAAU,CAAAC,QAAQ,GAAG;IACpBC,MAAQ,EAAA,KAAA;IAAA;IACRC,KAAO,EAAA;IAAA;EACT,CAAA;EACA,CAACH,iBAAAA,CAAAA,SAAU,CAAAI,QAAQ,GAAG;IACpBF,MAAQ,EAAA,CAAA;IAAA;IACRC,KAAO,EAAA;IAAA;EACT,CAAA;EACA,CAACH,iBAAAA,CAAAA,SAAU,CAAAK,SAAS,GAAG;IACrBH,MAAQ,EAAA,KAAA;IAAA;IACRC,KAAO,EAAA;IAAA;EACT,CAAA;EACA,CAACH,iBAAAA,CAAAA,SAAU,CAAAM,SAAS,GAAG;IACrBJ,MAAQ,EAAA,KAAA;IAAA;IACRC,KAAO,EAAA;IAAA;EACT;AACF,CAAA;AAKO,MAAMI,OAAOC,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA,SAGlBX,sBAAsB;AAAA,CAAA;AAGxB,MAAMY,YAAYF,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA,qBAEX,CAAC;EAAEE;AAAA,CAAe,KAAAA,OAAA,GAAU,WAAW,eAAgB;AAAA,SACnEb,sBAAsB;AAAA,CAAA;AAGxB,MAAMc,YAAYJ,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA,WAKrB,CAAC;EAAEI;AACV,CAAA,KAAAC,IAAA,CAAKC,KAAM,CAAAhB,mBAAA,CAAoBc,UAAU,CAAA,CAAEV,KAAQ,GAAA,GAAG,CAAC;AAAA,kBACzC,CAAC;EAAEU;CAAW,KAC5B,IAAId,mBAAoB,CAAAc,UAAU,EAAEX,MAAM;AAAA;AAAA;AAAA;AAAA,IAI1C,CAAC;EAAEc;CAAM,KACTA,KACA,IAAAC,MAAAA,CAAAA,GAAA;AAAA;AAAA,KAEC;AAAA,CAAA;AAGQ,MAAAC,KAAA,GAAQV,eAAAA,CAAAA,SAAAA,EAAOW,WAAAA,CAAAA,WAAW,CAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAQhC,MAAMC,QAAQZ,eAAO,CAAA,SAAA,CAAA,CAAAa,KAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAQrB,MAAMC,eAAed,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAY/B,CAAC;EAAEc;CAAU,KACbA,SACA,IAAAN,MAAAA,CAAAA,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,KAMC;AAAA,CAAA;AAGQ,MAAAO,WAAA,GAAchB,eAAAA,CAAAA,SAAAA,EAAOW,WAAW,CAAAA,WAAA,CAAA,EAAA;AAEtC,MAAMM,kBAAkBjB,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAO/B,MAAMiB,yBAAyBlB,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA,SAGpCX,sBAAsB;AAAA;AAAA,WAEpB6B,MAAAA,CAAAA,YAAYC,SAAS;AAAA;AAAA;AAAA,CAAA;;;;;;;;;;;"}
1
+ {"version":3,"file":"GridGallery.styles.js","sources":["../../../src/components/GridGallery/GridGallery.styles.ts"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { BREAKPOINTS } from \"../../constants/layout\";\nimport { CustomImage } from \"../CustomImage\";\nimport { RatioType } from \"./GridGallery.types\";\n\n// #############################################################################\n// Constants\n// #############################################################################\nexport const GRID_GALLERY_ITEMS_GAP = 20;\n\n/**\n * # Height\n * Width to height ratio - height is divided by the width.\n * E.g. 350/980=0.357142857 (rounded up to 3 decimals)\n *\n * # Width\n * Width to full width ratio - width is divided by the container width.\n * E.g. 565/980=0.576530612244898 (rounded up to 3 decimals)\n */\nexport const GRID_GALLERY_RATIOS = {\n [RatioType.OneWhole]: {\n height: 0.357, // 350/980,\n width: 1, // 980/980\n },\n [RatioType.OneThird]: {\n height: 1, // 350/350,\n width: 0.357, // 350/980\n },\n [RatioType.TwoThirds]: {\n height: 0.886, // 350/395,\n width: 0.403, // 395/980\n },\n [RatioType.ThreeTwos]: {\n height: 0.619, // 350/565,\n width: 0.577, // 565/980\n },\n} as const;\n\n// #############################################################################\n// Components\n// #############################################################################\nexport const Wrap = styled.div`\n display: flex;\n flex-direction: column;\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n`;\n\nexport const ImagesRow = styled.div<{ $center: boolean }>`\n display: flex;\n justify-content: ${({ $center }) => ($center ? \"center\" : \"space-between\")};\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n`;\n\nexport const ImageWrap = styled.div<{\n $ratioType: RatioType;\n $grow: boolean;\n}>`\n position: relative;\n width: ${({ $ratioType }) =>\n Math.round(GRID_GALLERY_RATIOS[$ratioType].width * 100)}%;\n aspect-ratio: ${({ $ratioType }) =>\n 1 / GRID_GALLERY_RATIOS[$ratioType].height};\n overflow: hidden;\n max-height: 350px;\n\n ${({ $grow }) =>\n $grow &&\n css`\n flex-grow: 1;\n `}\n`;\n\nexport const Image = styled(CustomImage)`\n user-select: none;\n\n img {\n -webkit-user-drag: none;\n }\n`;\n\nexport const Video = styled.video`\n user-select: none;\n width: 100%;\n height: 100%;\n object-fit: cover;\n display: block;\n`;\n\nexport const VideoOverlay = styled.div<{\n hasVideo: boolean;\n}>`\n position: absolute;\n inset: 0;\n background-color: rgb(0 0 0 / 0.5);\n display: flex;\n justify-content: center;\n align-items: center;\n color: white;\n transition: background-color 0.2s;\n\n ${({ hasVideo }) =>\n hasVideo &&\n css`\n cursor: pointer;\n\n &:hover {\n background-color: rgb(0 0 0 / 0.45);\n }\n `}\n`;\n\nexport const MobileImage = styled(CustomImage)``;\n\nexport const MobileAssetWrap = styled.div`\n position: relative;\n border-radius: 4px;\n overflow: hidden;\n width: 100%;\n`;\n\nexport const MobileGalleryOuterWrap = styled.div`\n display: flex;\n flex-direction: column;\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n\n @media ${BREAKPOINTS.TABLET_UP} {\n display: none;\n }\n`;\n"],"names":["GRID_GALLERY_ITEMS_GAP","GRID_GALLERY_RATIOS","RatioType","OneWhole","height","width","OneThird","TwoThirds","ThreeTwos","Wrap","styled","div","ImagesRow","$center","ImageWrap","$ratioType","Math","round","$grow","css","Image","CustomImage","Video","video","VideoOverlay","hasVideo","MobileImage","MobileAssetWrap","MobileGalleryOuterWrap","BREAKPOINTS","TABLET_UP"],"mappings":";;;;;;;;;;;;;;AASO,MAAMA,sBAAyB,GAAA,EAAA;AAW/B,MAAMC,mBAAsB,GAAA;EACjC,CAACC,iBAAAA,CAAAA,SAAU,CAAAC,QAAQ,GAAG;IACpBC,MAAQ,EAAA,KAAA;IAAA;IACRC,KAAO,EAAA;IAAA;EACT,CAAA;EACA,CAACH,iBAAAA,CAAAA,SAAU,CAAAI,QAAQ,GAAG;IACpBF,MAAQ,EAAA,CAAA;IAAA;IACRC,KAAO,EAAA;IAAA;EACT,CAAA;EACA,CAACH,iBAAAA,CAAAA,SAAU,CAAAK,SAAS,GAAG;IACrBH,MAAQ,EAAA,KAAA;IAAA;IACRC,KAAO,EAAA;IAAA;EACT,CAAA;EACA,CAACH,iBAAAA,CAAAA,SAAU,CAAAM,SAAS,GAAG;IACrBJ,MAAQ,EAAA,KAAA;IAAA;IACRC,KAAO,EAAA;IAAA;EACT;AACF,CAAA;AAKO,MAAMI,OAAOC,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA,SAGlBX,sBAAsB;AAAA,CAAA;AAGxB,MAAMY,YAAYF,eAA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SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA,SAGpCX,sBAAsB;AAAA;AAAA,WAEpB6B,MAAAA,CAAAA,YAAYC,SAAS;AAAA;AAAA;AAAA,CAAA;;;;;;;;;;;"}
@@ -85,8 +85,8 @@ const VideoOverlay = styled.div`
85
85
  transition: background-color 0.2s;
86
86
 
87
87
  ${({
88
- $hasVideo
89
- }) => $hasVideo && css`
88
+ hasVideo
89
+ }) => hasVideo && css`
90
90
  cursor: pointer;
91
91
 
92
92
  &:hover {
@@ -1 +1 @@
1
- {"version":3,"file":"GridGallery.styles.mjs","sources":["../../../src/components/GridGallery/GridGallery.styles.ts"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { BREAKPOINTS } from \"../../constants/layout\";\nimport { CustomImage } from \"../CustomImage\";\nimport { RatioType } from \"./GridGallery.types\";\n\n// #############################################################################\n// Constants\n// #############################################################################\nexport const GRID_GALLERY_ITEMS_GAP = 20;\n\n/**\n * # Height\n * Width to height ratio - height is divided by the width.\n * E.g. 350/980=0.357142857 (rounded up to 3 decimals)\n *\n * # Width\n * Width to full width ratio - width is divided by the container width.\n * E.g. 565/980=0.576530612244898 (rounded up to 3 decimals)\n */\nexport const GRID_GALLERY_RATIOS = {\n [RatioType.OneWhole]: {\n height: 0.357, // 350/980,\n width: 1, // 980/980\n },\n [RatioType.OneThird]: {\n height: 1, // 350/350,\n width: 0.357, // 350/980\n },\n [RatioType.TwoThirds]: {\n height: 0.886, // 350/395,\n width: 0.403, // 395/980\n },\n [RatioType.ThreeTwos]: {\n height: 0.619, // 350/565,\n width: 0.577, // 565/980\n },\n} as const;\n\n// #############################################################################\n// Components\n// #############################################################################\nexport const Wrap = styled.div`\n display: flex;\n flex-direction: column;\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n`;\n\nexport const ImagesRow = styled.div<{ $center: boolean }>`\n display: flex;\n justify-content: ${({ $center }) => ($center ? \"center\" : \"space-between\")};\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n`;\n\nexport const ImageWrap = styled.div<{\n $ratioType: RatioType;\n $grow: boolean;\n}>`\n position: relative;\n width: ${({ $ratioType }) =>\n Math.round(GRID_GALLERY_RATIOS[$ratioType].width * 100)}%;\n aspect-ratio: ${({ $ratioType }) =>\n 1 / GRID_GALLERY_RATIOS[$ratioType].height};\n overflow: hidden;\n max-height: 350px;\n\n ${({ $grow }) =>\n $grow &&\n css`\n flex-grow: 1;\n `}\n`;\n\nexport const Image = styled(CustomImage)`\n user-select: none;\n\n img {\n -webkit-user-drag: none;\n }\n`;\n\nexport const Video = styled.video`\n user-select: none;\n width: 100%;\n height: 100%;\n object-fit: cover;\n display: block;\n`;\n\nexport const VideoOverlay = styled.div<{\n $hasVideo: boolean;\n}>`\n position: absolute;\n inset: 0;\n background-color: rgb(0 0 0 / 0.5);\n display: flex;\n justify-content: center;\n align-items: center;\n color: white;\n transition: background-color 0.2s;\n\n ${({ $hasVideo }) =>\n $hasVideo &&\n css`\n cursor: pointer;\n\n &:hover {\n background-color: rgb(0 0 0 / 0.45);\n }\n `}\n`;\n\nexport const MobileImage = styled(CustomImage)``;\n\nexport const MobileAssetWrap = styled.div`\n position: relative;\n border-radius: 4px;\n overflow: hidden;\n width: 100%;\n`;\n\nexport const MobileGalleryOuterWrap = styled.div`\n display: flex;\n flex-direction: column;\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n\n @media ${BREAKPOINTS.TABLET_UP} {\n display: none;\n }\n`;\n"],"names":["GRID_GALLERY_ITEMS_GAP","GRID_GALLERY_RATIOS","RatioType","OneWhole","height","width","OneThird","TwoThirds","ThreeTwos","Wrap","styled","div","ImagesRow","$center","ImageWrap","$ratioType","Math","round","$grow","css","Image","CustomImage","Video","video","VideoOverlay","$hasVideo","MobileImage","MobileAssetWrap","MobileGalleryOuterWrap","BREAKPOINTS","TABLET_UP"],"mappings":";;;;;;AASO,MAAMA,sBAAyB,GAAA,EAAA;AAW/B,MAAMC,mBAAsB,GAAA;EACjC,CAAC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AAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAY/B,CAAC;EAAEc;CAAU,KACbA,SACA,IAAAN,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,KAMC;AAAA,CAAA;AAGQ,MAAAO,WAAA,GAAchB,OAAOW,WAAW,CAAA,EAAA;AAEtC,MAAMM,kBAAkBjB,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAO/B,MAAMiB,yBAAyBlB,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA,SAGpCX,sBAAsB;AAAA;AAAA,WAEpB6B,YAAYC,SAAS;AAAA;AAAA;AAAA,CAAA;"}
1
+ {"version":3,"file":"GridGallery.styles.mjs","sources":["../../../src/components/GridGallery/GridGallery.styles.ts"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { BREAKPOINTS } from \"../../constants/layout\";\nimport { CustomImage } from \"../CustomImage\";\nimport { RatioType } from \"./GridGallery.types\";\n\n// #############################################################################\n// Constants\n// #############################################################################\nexport const GRID_GALLERY_ITEMS_GAP = 20;\n\n/**\n * # Height\n * Width to height ratio - height is divided by the width.\n * E.g. 350/980=0.357142857 (rounded up to 3 decimals)\n *\n * # Width\n * Width to full width ratio - width is divided by the container width.\n * E.g. 565/980=0.576530612244898 (rounded up to 3 decimals)\n */\nexport const GRID_GALLERY_RATIOS = {\n [RatioType.OneWhole]: {\n height: 0.357, // 350/980,\n width: 1, // 980/980\n },\n [RatioType.OneThird]: {\n height: 1, // 350/350,\n width: 0.357, // 350/980\n },\n [RatioType.TwoThirds]: {\n height: 0.886, // 350/395,\n width: 0.403, // 395/980\n },\n [RatioType.ThreeTwos]: {\n height: 0.619, // 350/565,\n width: 0.577, // 565/980\n },\n} as const;\n\n// #############################################################################\n// Components\n// #############################################################################\nexport const Wrap = styled.div`\n display: flex;\n flex-direction: column;\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n`;\n\nexport const ImagesRow = styled.div<{ $center: boolean }>`\n display: flex;\n justify-content: ${({ $center }) => ($center ? \"center\" : \"space-between\")};\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n`;\n\nexport const ImageWrap = styled.div<{\n $ratioType: RatioType;\n $grow: boolean;\n}>`\n position: relative;\n width: ${({ $ratioType }) =>\n Math.round(GRID_GALLERY_RATIOS[$ratioType].width * 100)}%;\n aspect-ratio: ${({ $ratioType }) =>\n 1 / GRID_GALLERY_RATIOS[$ratioType].height};\n overflow: hidden;\n max-height: 350px;\n\n ${({ $grow }) =>\n $grow &&\n css`\n flex-grow: 1;\n `}\n`;\n\nexport const Image = styled(CustomImage)`\n user-select: none;\n\n img {\n -webkit-user-drag: none;\n }\n`;\n\nexport const Video = styled.video`\n user-select: none;\n width: 100%;\n height: 100%;\n object-fit: cover;\n display: block;\n`;\n\nexport const VideoOverlay = styled.div<{\n hasVideo: boolean;\n}>`\n position: absolute;\n inset: 0;\n background-color: rgb(0 0 0 / 0.5);\n display: flex;\n justify-content: center;\n align-items: center;\n color: white;\n transition: background-color 0.2s;\n\n ${({ hasVideo }) =>\n hasVideo &&\n css`\n cursor: pointer;\n\n &:hover {\n background-color: rgb(0 0 0 / 0.45);\n }\n `}\n`;\n\nexport const MobileImage = styled(CustomImage)``;\n\nexport const MobileAssetWrap = styled.div`\n position: relative;\n border-radius: 4px;\n overflow: hidden;\n width: 100%;\n`;\n\nexport const MobileGalleryOuterWrap = styled.div`\n display: flex;\n flex-direction: column;\n gap: ${GRID_GALLERY_ITEMS_GAP}px;\n\n @media ${BREAKPOINTS.TABLET_UP} {\n display: none;\n }\n`;\n"],"names":["GRID_GALLERY_ITEMS_GAP","GRID_GALLERY_RATIOS","RatioType","OneWhole","height","width","OneThird","TwoThirds","ThreeTwos","Wrap","styled","div","ImagesRow","$center","ImageWrap","$ratioType","Math","round","$grow","css","Image","CustomImage","Video","video","VideoOverlay","hasVideo","MobileImage","MobileAssetWrap","MobileGalleryOuterWrap","BREAKPOINTS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