@ubnt/store.core 9.17.0-alpha.4 → 9.17.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 (429) hide show
  1. package/CHANGELOG.md +2 -154
  2. package/lib/_virtual/_virtual_multi-entry.js +12 -27
  3. package/lib/_virtual/_virtual_multi-entry.js.map +1 -1
  4. package/lib/_virtual/_virtual_multi-entry.mjs +10 -14
  5. package/lib/_virtual/_virtual_multi-entry.mjs.map +1 -1
  6. package/lib/apis/smartcat.js +1 -4
  7. package/lib/apis/smartcat.js.map +1 -1
  8. package/lib/apis/smartcat.mjs +1 -4
  9. package/lib/apis/smartcat.mjs.map +1 -1
  10. package/lib/{components/ResourceCalculatorV1/assets/consoles/ucg-max.png.js → assets/icons/menu/icon-globe.svg.js} +6 -6
  11. package/lib/assets/icons/menu/icon-globe.svg.js.map +1 -0
  12. package/lib/assets/icons/menu/icon-globe.svg.mjs +3 -0
  13. package/lib/assets/icons/menu/icon-globe.svg.mjs.map +1 -0
  14. package/lib/components/CategoryTabs/CategoryTabs.styles.d.ts +1 -1
  15. package/lib/components/CategoryTabs/CategoryTabs.types.d.ts +1 -1
  16. package/lib/components/CloserLookSection/CloserLookSection.js.map +1 -1
  17. package/lib/components/CloserLookSection/CloserLookSection.mjs.map +1 -1
  18. package/lib/components/Compare/Compare.styles.d.ts +5 -5
  19. package/lib/components/Container/Container.d.ts +1 -1
  20. package/lib/components/Container/Container.js +3 -4
  21. package/lib/components/Container/Container.js.map +1 -1
  22. package/lib/components/Container/Container.mjs +4 -5
  23. package/lib/components/Container/Container.mjs.map +1 -1
  24. package/lib/components/CustomImage/CustomImage.js.map +1 -1
  25. package/lib/components/CustomImage/CustomImage.mjs.map +1 -1
  26. package/lib/components/FeaturesSection_deprecated/FeaturesSection.js.map +1 -1
  27. package/lib/components/FeaturesSection_deprecated/FeaturesSection.mjs.map +1 -1
  28. package/lib/components/Footer/hooks/useFooterContent.d.ts +3 -1
  29. package/lib/components/Footer/hooks/useFooterContent.js +8 -1
  30. package/lib/components/Footer/hooks/useFooterContent.js.map +1 -1
  31. package/lib/components/Footer/hooks/useFooterContent.mjs +8 -1
  32. package/lib/components/Footer/hooks/useFooterContent.mjs.map +1 -1
  33. package/lib/components/Footer/translations/ar.json.js +1 -1
  34. package/lib/components/Footer/translations/ar.json.mjs +1 -1
  35. package/lib/components/Footer/translations/de.json.js +1 -1
  36. package/lib/components/Footer/translations/de.json.mjs +1 -1
  37. package/lib/components/Footer/translations/el.json.js +1 -1
  38. package/lib/components/Footer/translations/el.json.mjs +1 -1
  39. package/lib/components/Footer/translations/en.json.js +1 -0
  40. package/lib/components/Footer/translations/en.json.js.map +1 -1
  41. package/lib/components/Footer/translations/en.json.mjs +1 -0
  42. package/lib/components/Footer/translations/en.json.mjs.map +1 -1
  43. package/lib/components/Footer/translations/es.json.js +1 -1
  44. package/lib/components/Footer/translations/es.json.mjs +1 -1
  45. package/lib/components/Footer/translations/fr.json.js +4 -4
  46. package/lib/components/Footer/translations/fr.json.mjs +4 -4
  47. package/lib/components/Footer/translations/it.json.js +1 -1
  48. package/lib/components/Footer/translations/it.json.mjs +1 -1
  49. package/lib/components/Footer/translations/ja.json.js +2 -2
  50. package/lib/components/Footer/translations/ja.json.mjs +2 -2
  51. package/lib/components/Footer/translations/pt-BR.json.js +1 -1
  52. package/lib/components/Footer/translations/pt-BR.json.mjs +1 -1
  53. package/lib/components/Footer/translations/zh-Hans.json.js +4 -4
  54. package/lib/components/Footer/translations/zh-Hans.json.mjs +4 -4
  55. package/lib/components/Footer/translations/zh-Hant-TW.json.js +1 -1
  56. package/lib/components/Footer/translations/zh-Hant-TW.json.mjs +1 -1
  57. package/lib/components/GridGallery/GridGallery.js.map +1 -1
  58. package/lib/components/GridGallery/GridGallery.mjs.map +1 -1
  59. package/lib/components/Header/AccountMenu/AccountMenu.js +12 -20
  60. package/lib/components/Header/AccountMenu/AccountMenu.js.map +1 -1
  61. package/lib/components/Header/AccountMenu/AccountMenu.mjs +14 -22
  62. package/lib/components/Header/AccountMenu/AccountMenu.mjs.map +1 -1
  63. package/lib/components/Header/AccountMenu/megaphone.http.service.js +1 -4
  64. package/lib/components/Header/AccountMenu/megaphone.http.service.js.map +1 -1
  65. package/lib/components/Header/AccountMenu/megaphone.http.service.mjs +1 -4
  66. package/lib/components/Header/AccountMenu/megaphone.http.service.mjs.map +1 -1
  67. package/lib/components/Header/CartModalV2/CartModal.js.map +1 -1
  68. package/lib/components/Header/CartModalV2/CartModal.mjs.map +1 -1
  69. package/lib/components/Header/Header.js.map +1 -1
  70. package/lib/components/Header/Header.mjs.map +1 -1
  71. package/lib/components/Header/Header.styles.d.ts +2 -2
  72. package/lib/components/Header/Header.types.d.ts +4 -8
  73. package/lib/components/Header/Header.types.js +1 -2
  74. package/lib/components/Header/Header.types.js.map +1 -1
  75. package/lib/components/Header/Header.types.mjs +1 -2
  76. package/lib/components/Header/Header.types.mjs.map +1 -1
  77. package/lib/components/Header/LanguageFrame/LanguageFrame.js.map +1 -1
  78. package/lib/components/Header/LanguageFrame/LanguageFrame.mjs.map +1 -1
  79. package/lib/components/Header/LanguageFrame/Mobile/Mobile.js.map +1 -1
  80. package/lib/components/Header/LanguageFrame/Mobile/Mobile.mjs.map +1 -1
  81. package/lib/components/Header/MenuItem/MenuItem.styles.d.ts +1 -1
  82. package/lib/components/Header/MenuItem/MenuItem.styles.js +1 -1
  83. package/lib/components/Header/MenuItem/MenuItem.styles.js.map +1 -1
  84. package/lib/components/Header/MenuItem/MenuItem.styles.mjs +1 -1
  85. package/lib/components/Header/MenuItem/MenuItem.styles.mjs.map +1 -1
  86. package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.styles.d.ts +1 -1
  87. package/lib/components/Header/Navigation/MobileMenu/MobileMenu.styles.d.ts +1 -1
  88. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.d.ts +1 -1
  89. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.js +63 -85
  90. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.js.map +1 -1
  91. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.mjs +64 -86
  92. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.mjs.map +1 -1
  93. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.d.ts +0 -6
  94. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.js +1 -11
  95. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.js.map +1 -1
  96. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.mjs +2 -10
  97. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.mjs.map +1 -1
  98. package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.types.d.ts +1 -5
  99. package/lib/components/Header/Overlay/Overlay.js.map +1 -1
  100. package/lib/components/Header/Overlay/Overlay.mjs.map +1 -1
  101. package/lib/components/Header/ProHeader/ProHeader.d.ts +4 -2
  102. package/lib/components/Header/ProHeader/ProHeader.js +36 -145
  103. package/lib/components/Header/ProHeader/ProHeader.js.map +1 -1
  104. package/lib/components/Header/ProHeader/ProHeader.mjs +39 -146
  105. package/lib/components/Header/ProHeader/ProHeader.mjs.map +1 -1
  106. package/lib/components/Header/ProHeader/ProHeader.styles.d.ts +1 -4
  107. package/lib/components/Header/ProHeader/ProHeader.styles.js +18 -20
  108. package/lib/components/Header/ProHeader/ProHeader.styles.js.map +1 -1
  109. package/lib/components/Header/ProHeader/ProHeader.styles.mjs +19 -18
  110. package/lib/components/Header/ProHeader/ProHeader.styles.mjs.map +1 -1
  111. package/lib/components/Header/translations/en.json.js +1 -4
  112. package/lib/components/Header/translations/en.json.js.map +1 -1
  113. package/lib/components/Header/translations/en.json.mjs +2 -4
  114. package/lib/components/Header/translations/en.json.mjs.map +1 -1
  115. package/lib/components/Hero/Hero.styles.d.ts +2 -2
  116. package/lib/components/HeroFadeGallery/HeroFadeGallery.styles.d.ts +1 -1
  117. package/lib/components/HowToUseSection/HowToUseSection.styles.d.ts +2 -2
  118. package/lib/components/ImageSequence/ImageSequence.js.map +1 -1
  119. package/lib/components/ImageSequence/ImageSequence.mjs.map +1 -1
  120. package/lib/components/LandingPage/Cards/Card/Card.js.map +1 -1
  121. package/lib/components/LandingPage/Cards/Card/Card.mjs.map +1 -1
  122. package/lib/components/LandingPage/Cards/Cards.js.map +1 -1
  123. package/lib/components/LandingPage/Cards/Cards.mjs.map +1 -1
  124. package/lib/components/LandingPagePro/LandingPagePro.d.ts +0 -3
  125. package/lib/components/LandingPagePro/LandingPagePro.js +3 -3
  126. package/lib/components/LandingPagePro/LandingPagePro.js.map +1 -1
  127. package/lib/components/LandingPagePro/LandingPagePro.mjs +2 -2
  128. package/lib/components/LandingPagePro/LandingPagePro.mjs.map +1 -1
  129. package/lib/components/LandingPagePro/LandingPagePro.styles.d.ts +1 -1
  130. package/lib/components/LayoutRenderer/LayoutRenderer.styles.d.ts +1 -1
  131. package/lib/components/LayoutRendererV1/LayoutRenderer.styles.d.ts +3 -3
  132. package/lib/components/LayoutRendererV2/LayoutRenderer.styles.d.ts +3 -3
  133. package/lib/components/MicrositeIntroductionBlock/MicrositeIntroductionBlock.js.map +1 -1
  134. package/lib/components/MicrositeIntroductionBlock/MicrositeIntroductionBlock.mjs.map +1 -1
  135. package/lib/components/MicrositeMediaGrid/MicrositeMediaGrid.js.map +1 -1
  136. package/lib/components/MicrositeMediaGrid/MicrositeMediaGrid.mjs.map +1 -1
  137. package/lib/components/MicrositeProductGrid/MicrositeProductGrid.js.map +1 -1
  138. package/lib/components/MicrositeProductGrid/MicrositeProductGrid.mjs.map +1 -1
  139. package/lib/components/MicrositeSectionWrap/MicrositeSectionWrap.styles.d.ts +1 -1
  140. package/lib/components/Microsites/MicrositeProductPage.js +39 -0
  141. package/lib/components/Microsites/MicrositeProductPage.js.map +1 -1
  142. package/lib/components/Microsites/MicrositeProductPage.mjs +39 -0
  143. package/lib/components/Microsites/MicrositeProductPage.mjs.map +1 -1
  144. package/lib/components/ModelCompareV3/StickyGrid/StickyGridHeader.js.map +1 -1
  145. package/lib/components/ModelCompareV3/StickyGrid/StickyGridHeader.mjs.map +1 -1
  146. package/lib/components/ProductCompare/ProductCompare.js.map +1 -1
  147. package/lib/components/ProductCompare/ProductCompare.mjs.map +1 -1
  148. package/lib/components/ProductSectionNavigation/ProductSectionNavigation.styles.d.ts +1 -1
  149. package/lib/components/ProductSectionNavigationV2/ProductSectionNavigation.styles.d.ts +1 -1
  150. package/lib/components/ProductTechSpecs/ProductTechSpecs.styles.d.ts +1 -1
  151. package/lib/components/QuantityControls/QuantityControls.js.map +1 -1
  152. package/lib/components/QuantityControls/QuantityControls.mjs.map +1 -1
  153. package/lib/components/RelatedProducts/RelatedProducts.js.map +1 -1
  154. package/lib/components/RelatedProducts/RelatedProducts.mjs.map +1 -1
  155. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.constants.js +17 -313
  156. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.constants.js.map +1 -1
  157. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.constants.mjs +17 -311
  158. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.constants.mjs.map +1 -1
  159. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.types.d.ts +2 -3
  160. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.types.js +0 -2
  161. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.types.js.map +1 -1
  162. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.types.mjs +0 -2
  163. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.types.mjs.map +1 -1
  164. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/DeviceSelect.js +34 -120
  165. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/DeviceSelect.js.map +1 -1
  166. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/DeviceSelect.mjs +34 -120
  167. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/DeviceSelect.mjs.map +1 -1
  168. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/DeviceSelect.styles.d.ts +2 -16
  169. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/DeviceSelect.styles.js +12 -54
  170. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/DeviceSelect.styles.js.map +1 -1
  171. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/DeviceSelect.styles.mjs +11 -50
  172. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/DeviceSelect.styles.mjs.map +1 -1
  173. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/assets/ArrowLeftPrimary.svg.js +5 -5
  174. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/assets/ArrowRightPrimary.svg.js +5 -5
  175. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.js +1 -1
  176. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.js.map +1 -1
  177. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.mjs +1 -1
  178. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.mjs.map +1 -1
  179. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.styles.js +0 -2
  180. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.styles.js.map +1 -1
  181. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.styles.mjs +0 -2
  182. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.styles.mjs.map +1 -1
  183. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.js +1 -1
  184. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.js.map +1 -1
  185. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.mjs +1 -1
  186. package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.mjs.map +1 -1
  187. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.js +2 -2
  188. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.js.map +1 -1
  189. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.mjs +2 -2
  190. package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.mjs.map +1 -1
  191. package/lib/components/ResourceCalculatorV1/ResourceCalculator.js +2 -1
  192. package/lib/components/ResourceCalculatorV1/ResourceCalculator.js.map +1 -1
  193. package/lib/components/ResourceCalculatorV1/ResourceCalculator.mjs +2 -1
  194. package/lib/components/ResourceCalculatorV1/ResourceCalculator.mjs.map +1 -1
  195. package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/HorizontalOptionSelect.d.ts +1 -1
  196. package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/HorizontalOptionSelect.js +1 -3
  197. package/lib/components/ResourceCalculatorV1/components/HorizontalOptionSelect/HorizontalOptionSelect.js.map +1 -0
  198. package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/HorizontalOptionSelect.mjs +1 -3
  199. package/lib/components/ResourceCalculatorV1/components/HorizontalOptionSelect/HorizontalOptionSelect.mjs.map +1 -0
  200. package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/HorizontalOptionSelect.styles.d.ts +0 -1
  201. package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/HorizontalOptionSelect.styles.js +7 -10
  202. package/lib/components/ResourceCalculatorV1/components/HorizontalOptionSelect/HorizontalOptionSelect.styles.js.map +1 -0
  203. package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/HorizontalOptionSelect.styles.mjs +7 -10
  204. package/lib/components/ResourceCalculatorV1/components/HorizontalOptionSelect/HorizontalOptionSelect.styles.mjs.map +1 -0
  205. package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/HorizontalOptionSelect.types.d.ts +0 -1
  206. package/lib/components/ResourceCalculatorV1/components/index.d.ts +1 -0
  207. package/lib/components/ResourceCalculatorV1/components/index.js +5 -0
  208. package/lib/components/{Header/Navigation/ProMenu → ResourceCalculatorV1/components}/index.js.map +1 -1
  209. package/lib/components/ResourceCalculatorV1/components/index.mjs +3 -0
  210. package/lib/components/ResourceCalculatorV1/translations/en.json.js +4 -6
  211. package/lib/components/ResourceCalculatorV1/translations/en.json.js.map +1 -1
  212. package/lib/components/ResourceCalculatorV1/translations/en.json.mjs +4 -6
  213. package/lib/components/ResourceCalculatorV1/translations/en.json.mjs.map +1 -1
  214. package/lib/components/ResourceCalculatorV1/translations/useResourceCalculatorTranslation.d.ts +2 -2
  215. package/lib/components/ReverseLoopingVideo/ReverseLoopingVideo.js.map +1 -1
  216. package/lib/components/ReverseLoopingVideo/ReverseLoopingVideo.mjs.map +1 -1
  217. package/lib/components/ScrollWrapper/ScrollWrapper.js.map +1 -1
  218. package/lib/components/ScrollWrapper/ScrollWrapper.mjs.map +1 -1
  219. package/lib/components/StorageSliders/Slider/Slider.js.map +1 -1
  220. package/lib/components/StorageSliders/Slider/Slider.mjs.map +1 -1
  221. package/lib/components/StorageSliders/StorageSliders.context.js.map +1 -1
  222. package/lib/components/StorageSliders/StorageSliders.context.mjs.map +1 -1
  223. package/lib/components/VariantSelector/Variant/Compatibility/Compatibility.js.map +1 -1
  224. package/lib/components/VariantSelector/Variant/Compatibility/Compatibility.mjs.map +1 -1
  225. package/lib/components/VariantSelector/Variant/Variant.js.map +1 -1
  226. package/lib/components/VariantSelector/Variant/Variant.mjs.map +1 -1
  227. package/lib/components/index.d.ts +0 -1
  228. package/lib/components/index.js +0 -2
  229. package/lib/components/index.js.map +1 -1
  230. package/lib/components/index.mjs +0 -2
  231. package/lib/components/index.mjs.map +1 -1
  232. package/lib/constants/proStoreCategories/mapping/index.d.ts +0 -1
  233. package/lib/constants/proStoreCategories/mapping/index.js +10 -15
  234. package/lib/constants/proStoreCategories/mapping/index.js.map +1 -1
  235. package/lib/constants/proStoreCategories/mapping/index.mjs +10 -15
  236. package/lib/constants/proStoreCategories/mapping/index.mjs.map +1 -1
  237. package/lib/constants/proStoreCategories/mapping/unifi.d.ts +1 -2
  238. package/lib/constants/proStoreCategories/mapping/unifi.js +0 -1
  239. package/lib/constants/proStoreCategories/mapping/unifi.js.map +1 -1
  240. package/lib/constants/proStoreCategories/mapping/unifi.mjs +0 -1
  241. package/lib/constants/proStoreCategories/mapping/unifi.mjs.map +1 -1
  242. package/lib/constants/proStoreCategories/translations/en.json.js +0 -3
  243. package/lib/constants/proStoreCategories/translations/en.json.js.map +1 -1
  244. package/lib/constants/proStoreCategories/translations/en.json.mjs +1 -3
  245. package/lib/constants/proStoreCategories/translations/en.json.mjs.map +1 -1
  246. package/lib/constants/proStoreCategories/translations/fr.json.js +1 -1
  247. package/lib/constants/proStoreCategories/translations/fr.json.mjs +1 -1
  248. package/lib/constants/proStoreCategories/translations/zh-Hans.json.js +1 -1
  249. package/lib/constants/proStoreCategories/translations/zh-Hans.json.mjs +1 -1
  250. package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.js +1 -1
  251. package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.mjs +1 -1
  252. package/lib/constants/url.d.ts +2 -1
  253. package/lib/constants/url.js +1 -0
  254. package/lib/constants/url.js.map +1 -1
  255. package/lib/constants/url.mjs +1 -0
  256. package/lib/constants/url.mjs.map +1 -1
  257. package/lib/contexts/MenuContext/context.js +1 -1
  258. package/lib/contexts/MenuContext/context.js.map +1 -1
  259. package/lib/contexts/MenuContext/context.mjs +1 -1
  260. package/lib/contexts/MenuContext/context.mjs.map +1 -1
  261. package/lib/contexts/MenuContext/utils.js +1 -0
  262. package/lib/contexts/MenuContext/utils.js.map +1 -1
  263. package/lib/contexts/MenuContext/utils.mjs +1 -0
  264. package/lib/contexts/MenuContext/utils.mjs.map +1 -1
  265. package/lib/helpers/index.d.ts +0 -1
  266. package/lib/helpers/index.js +0 -11
  267. package/lib/helpers/index.js.map +1 -1
  268. package/lib/helpers/index.mjs +0 -1
  269. package/lib/helpers/index.mjs.map +1 -1
  270. package/lib/helpers/ux.d.ts +1 -9
  271. package/lib/helpers/ux.js +0 -15
  272. package/lib/helpers/ux.js.map +1 -1
  273. package/lib/helpers/ux.mjs +1 -15
  274. package/lib/helpers/ux.mjs.map +1 -1
  275. package/lib/hooks/useHasTouch.js.map +1 -1
  276. package/lib/hooks/useHasTouch.mjs.map +1 -1
  277. package/lib/hooks/useHorizontalScroll.js.map +1 -1
  278. package/lib/hooks/useHorizontalScroll.mjs.map +1 -1
  279. package/lib/types/index.d.ts +0 -1
  280. package/lib/types/index.js +0 -2
  281. package/lib/types/index.js.map +1 -1
  282. package/lib/types/index.mjs +0 -1
  283. package/lib/types/index.mjs.map +1 -1
  284. package/lib/utils/array.d.ts +0 -4
  285. package/lib/utils/array.js +0 -10
  286. package/lib/utils/array.js.map +1 -1
  287. package/lib/utils/array.mjs +1 -10
  288. package/lib/utils/array.mjs.map +1 -1
  289. package/lib/utils/money/constants.d.ts +25 -56
  290. package/lib/utils/money/constants.js +7 -72
  291. package/lib/utils/money/constants.js.map +1 -1
  292. package/lib/utils/money/constants.mjs +7 -70
  293. package/lib/utils/money/constants.mjs.map +1 -1
  294. package/lib/utils/money/format.d.ts +5 -10
  295. package/lib/utils/money/format.js +14 -22
  296. package/lib/utils/money/format.js.map +1 -1
  297. package/lib/utils/money/format.mjs +16 -23
  298. package/lib/utils/money/format.mjs.map +1 -1
  299. package/lib/utils/money/index.d.ts +1 -4
  300. package/lib/utils/money/index.js +8 -26
  301. package/lib/utils/money/index.js.map +1 -1
  302. package/lib/utils/money/index.mjs +4 -8
  303. package/lib/utils/money/index.mjs.map +1 -1
  304. package/lib/utils/money/misc.d.ts +28 -68
  305. package/lib/utils/money/misc.js +64 -35
  306. package/lib/utils/money/misc.js.map +1 -1
  307. package/lib/utils/money/misc.mjs +43 -32
  308. package/lib/utils/money/misc.mjs.map +1 -1
  309. package/lib/utils/money/tax.d.ts +2 -38
  310. package/lib/utils/money/tax.js +10 -46
  311. package/lib/utils/money/tax.js.map +1 -1
  312. package/lib/utils/money/tax.mjs +11 -42
  313. package/lib/utils/money/tax.mjs.map +1 -1
  314. package/lib/utils/money/types.d.ts +3 -78
  315. package/lib/utils/number.d.ts +1 -1
  316. package/lib/utils/number.js +1 -1
  317. package/lib/utils/number.js.map +1 -1
  318. package/lib/utils/number.mjs +1 -1
  319. package/lib/utils/number.mjs.map +1 -1
  320. package/lib/utils/validations/postalCodeSuperRefinement.js +3 -0
  321. package/lib/utils/validations/postalCodeSuperRefinement.js.map +1 -1
  322. package/lib/utils/validations/postalCodeSuperRefinement.mjs +3 -0
  323. package/lib/utils/validations/postalCodeSuperRefinement.mjs.map +1 -1
  324. package/lib/utils/validations/stateRegistrationNumberSuperRefinement.js +2 -0
  325. package/lib/utils/validations/stateRegistrationNumberSuperRefinement.js.map +1 -1
  326. package/lib/utils/validations/stateRegistrationNumberSuperRefinement.mjs +2 -0
  327. package/lib/utils/validations/stateRegistrationNumberSuperRefinement.mjs.map +1 -1
  328. package/lib/utils/validations/taxIdSuperRefinement.js +2 -0
  329. package/lib/utils/validations/taxIdSuperRefinement.js.map +1 -1
  330. package/lib/utils/validations/taxIdSuperRefinement.mjs +2 -0
  331. package/lib/utils/validations/taxIdSuperRefinement.mjs.map +1 -1
  332. package/lib/utils/validations.d.ts +15 -0
  333. package/lib/utils/validations.js +23 -0
  334. package/lib/utils/validations.js.map +1 -0
  335. package/lib/utils/validations.mjs +21 -0
  336. package/lib/utils/validations.mjs.map +1 -0
  337. package/lib/utils/variant.js.map +1 -1
  338. package/lib/utils/variant.mjs.map +1 -1
  339. package/lib/utils/wattage.js.map +1 -1
  340. package/lib/utils/wattage.mjs.map +1 -1
  341. package/package.json +1 -1
  342. package/lib/assets/efg.png +0 -0
  343. package/lib/assets/icon-location-pin.svg +0 -5
  344. package/lib/assets/icons/menu/icon-location-pin.svg.js +0 -27
  345. package/lib/assets/icons/menu/icon-location-pin.svg.js.map +0 -1
  346. package/lib/assets/icons/menu/icon-location-pin.svg.mjs +0 -3
  347. package/lib/assets/icons/menu/icon-location-pin.svg.mjs.map +0 -1
  348. package/lib/assets/ucg-max.png +0 -0
  349. package/lib/components/Header/Navigation/ProMenu/ProMenu.d.ts +0 -2
  350. package/lib/components/Header/Navigation/ProMenu/ProMenu.js +0 -109
  351. package/lib/components/Header/Navigation/ProMenu/ProMenu.js.map +0 -1
  352. package/lib/components/Header/Navigation/ProMenu/ProMenu.mjs +0 -87
  353. package/lib/components/Header/Navigation/ProMenu/ProMenu.mjs.map +0 -1
  354. package/lib/components/Header/Navigation/ProMenu/ProMenu.styles.d.ts +0 -24
  355. package/lib/components/Header/Navigation/ProMenu/ProMenu.styles.js +0 -154
  356. package/lib/components/Header/Navigation/ProMenu/ProMenu.styles.js.map +0 -1
  357. package/lib/components/Header/Navigation/ProMenu/ProMenu.styles.mjs +0 -138
  358. package/lib/components/Header/Navigation/ProMenu/ProMenu.styles.mjs.map +0 -1
  359. package/lib/components/Header/Navigation/ProMenu/ProMenu.types.d.ts +0 -13
  360. package/lib/components/Header/Navigation/ProMenu/index.d.ts +0 -1
  361. package/lib/components/Header/Navigation/ProMenu/index.js +0 -6
  362. package/lib/components/Header/Navigation/ProMenu/index.mjs +0 -3
  363. package/lib/components/HorizontalOptionSelect/HorizontalOptionSelect.js.map +0 -1
  364. package/lib/components/HorizontalOptionSelect/HorizontalOptionSelect.mjs.map +0 -1
  365. package/lib/components/HorizontalOptionSelect/HorizontalOptionSelect.styles.js.map +0 -1
  366. package/lib/components/HorizontalOptionSelect/HorizontalOptionSelect.styles.mjs.map +0 -1
  367. package/lib/components/ResourceCalculatorV1/assets/consoles/efg.png.js +0 -27
  368. package/lib/components/ResourceCalculatorV1/assets/consoles/efg.png.js.map +0 -1
  369. package/lib/components/ResourceCalculatorV1/assets/consoles/efg.png.mjs +0 -3
  370. package/lib/components/ResourceCalculatorV1/assets/consoles/efg.png.mjs.map +0 -1
  371. package/lib/components/ResourceCalculatorV1/assets/consoles/ucg-max.png.js.map +0 -1
  372. package/lib/components/ResourceCalculatorV1/assets/consoles/ucg-max.png.mjs +0 -3
  373. package/lib/components/ResourceCalculatorV1/assets/consoles/ucg-max.png.mjs.map +0 -1
  374. package/lib/helpers/product.d.ts +0 -87
  375. package/lib/helpers/product.js +0 -346
  376. package/lib/helpers/product.js.map +0 -1
  377. package/lib/helpers/product.mjs +0 -335
  378. package/lib/helpers/product.mjs.map +0 -1
  379. package/lib/types/product.d.ts +0 -87
  380. package/lib/types/product.js +0 -14
  381. package/lib/types/product.js.map +0 -1
  382. package/lib/types/product.mjs +0 -13
  383. package/lib/types/product.mjs.map +0 -1
  384. package/lib/utils/money/allocators/fixedAmount.d.ts +0 -26
  385. package/lib/utils/money/allocators/fixedAmount.js +0 -55
  386. package/lib/utils/money/allocators/fixedAmount.js.map +0 -1
  387. package/lib/utils/money/allocators/fixedAmount.mjs +0 -53
  388. package/lib/utils/money/allocators/fixedAmount.mjs.map +0 -1
  389. package/lib/utils/money/allocators/index.d.ts +0 -2
  390. package/lib/utils/money/allocators/index.js +0 -8
  391. package/lib/utils/money/allocators/index.js.map +0 -1
  392. package/lib/utils/money/allocators/index.mjs +0 -4
  393. package/lib/utils/money/allocators/index.mjs.map +0 -1
  394. package/lib/utils/money/allocators/productAmount.d.ts +0 -13
  395. package/lib/utils/money/allocators/productAmount.js +0 -110
  396. package/lib/utils/money/allocators/productAmount.js.map +0 -1
  397. package/lib/utils/money/allocators/productAmount.mjs +0 -108
  398. package/lib/utils/money/allocators/productAmount.mjs.map +0 -1
  399. package/lib/utils/money/exchangeRate.d.ts +0 -31
  400. package/lib/utils/money/exchangeRate.js +0 -27
  401. package/lib/utils/money/exchangeRate.js.map +0 -1
  402. package/lib/utils/money/exchangeRate.mjs +0 -23
  403. package/lib/utils/money/exchangeRate.mjs.map +0 -1
  404. package/lib/utils/money/misc.private.d.ts +0 -23
  405. package/lib/utils/money/misc.private.js +0 -46
  406. package/lib/utils/money/misc.private.js.map +0 -1
  407. package/lib/utils/money/misc.private.mjs +0 -21
  408. package/lib/utils/money/misc.private.mjs.map +0 -1
  409. package/lib/utils/money/shipping.d.ts +0 -5
  410. package/lib/utils/money/shipping.js +0 -8
  411. package/lib/utils/money/shipping.js.map +0 -1
  412. package/lib/utils/money/shipping.mjs +0 -6
  413. package/lib/utils/money/shipping.mjs.map +0 -1
  414. package/lib/utils/money/tax.private.d.ts +0 -17
  415. package/lib/utils/money/tax.private.js +0 -65
  416. package/lib/utils/money/tax.private.js.map +0 -1
  417. package/lib/utils/money/tax.private.mjs +0 -60
  418. package/lib/utils/money/tax.private.mjs.map +0 -1
  419. package/lib/utils/productSort.d.ts +0 -41
  420. package/lib/utils/productSort.js +0 -66
  421. package/lib/utils/productSort.js.map +0 -1
  422. package/lib/utils/productSort.mjs +0 -59
  423. package/lib/utils/productSort.mjs.map +0 -1
  424. /package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/index.d.ts +0 -0
  425. /package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/index.js +0 -0
  426. /package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/index.js.map +0 -0
  427. /package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/index.mjs +0 -0
  428. /package/lib/components/{HorizontalOptionSelect → ResourceCalculatorV1/components/HorizontalOptionSelect}/index.mjs.map +0 -0
  429. /package/lib/components/{Header/Navigation/ProMenu → ResourceCalculatorV1/components}/index.mjs.map +0 -0
@@ -1,22 +1,20 @@
1
1
  import { jsx, jsxs } from 'react/jsx-runtime';
2
2
  import { useState, useCallback, useMemo } from 'react';
3
+ import '../../../../assets/icons/menu/icon-globe.svg.mjs';
3
4
  import '../../../../assets/icons/menu/icon-history.svg.mjs';
4
- import '../../../../assets/icons/menu/icon-location-pin.svg.mjs';
5
5
  import '../../../../constants/icons/index.mjs';
6
6
  import '../../../../contexts/MenuContext/index.mjs';
7
- import { imageSrc } from '../../../../utils/asset.mjs';
8
7
  import { useFooterContent } from '../../../Footer/hooks/useFooterContent.mjs';
9
8
  import '../../../StyleableSvgImage/index.mjs';
10
9
  import { getSupportLinkMapping } from '../../LinksModal/mapping.mjs';
11
- import { NewLabel, Wrap, Container, InnerWrap, Section, SectionItemsGroup, SectionItem, SectionItemArrowButton, ButtonIcon } from '../MobileMenu/MobileMenu.styles.mjs';
12
- import { SectionItemIcon, ProSectionItemButton, ButtonContent, ButtonGroup, CustomButton } from './ProMobileMenu.styles.mjs';
10
+ import { NewLabel, SectionItemButton, Wrap, Container, InnerWrap, Section, SectionItemsGroup, SectionItem, SectionItemArrowButton, ButtonIcon } from '../MobileMenu/MobileMenu.styles.mjs';
11
+ import { SectionItemIcon, ButtonGroup, CustomButton } from './ProMobileMenu.styles.mjs';
13
12
  import { useMenu } from '../../../../contexts/MenuContext/context.mjs';
14
13
  import HistoryIcon__default from "../../../../assets/icon-history.svg";
15
- import LocationPinIcon__default from "../../../../assets/icon-location-pin.svg";
14
+ import GlobeIcon__default from "../../../../assets/globe.svg";
16
15
  import { StyleableSvgImage } from '../../../StyleableSvgImage/StyleableSvgImage.mjs';
17
16
  import _externalAssets_BAXELvSy__default from "../../../../assets/collapseArrow.svg";
18
17
  "use strict";
19
- const motif = "light";
20
18
  const NavigationProMobileMenu = function NavigationProMobileMenu2({
21
19
  translations,
22
20
  onClose,
@@ -28,9 +26,9 @@ const NavigationProMobileMenu = function NavigationProMobileMenu2({
28
26
  handleProductLineChange,
29
27
  productLineValue,
30
28
  productLineOptions,
31
- extraSectionItems,
32
- inlineCategoryTabs
29
+ extraSectionItems
33
30
  }) {
31
+ const motif = "light";
34
32
  const {
35
33
  footerContent,
36
34
  socialContent
@@ -49,7 +47,7 @@ const NavigationProMobileMenu = function NavigationProMobileMenu2({
49
47
  id: "order-history",
50
48
  label: translations.orderHistory,
51
49
  icon: {
52
- src: imageSrc(HistoryIcon__default),
50
+ src: typeof HistoryIcon__default === "string" ? HistoryIcon__default : HistoryIcon__default.src,
53
51
  width: 16,
54
52
  height: 16
55
53
  },
@@ -61,7 +59,7 @@ const NavigationProMobileMenu = function NavigationProMobileMenu2({
61
59
  id: "purchased-product-history",
62
60
  label: translations.purchasedProductHistory,
63
61
  icon: {
64
- src: imageSrc(HistoryIcon__default),
62
+ src: typeof HistoryIcon__default === "string" ? HistoryIcon__default : HistoryIcon__default.src,
65
63
  width: 16,
66
64
  height: 16
67
65
  },
@@ -88,22 +86,55 @@ const NavigationProMobileMenu = function NavigationProMobileMenu2({
88
86
  // subItems: [],
89
87
  // },
90
88
  ]
91
- }, inlineCategoryTabs ? {
92
- id: "categories",
93
- items: inlineCategoryTabs.categories.map(category => ({
94
- id: category.id,
95
- label: category.label,
96
- url: category.href ?? null,
97
- subItems: []
98
- }))
99
- } : null, currentCountryName ? {
89
+ }, {
90
+ id: "extra",
91
+ items: extraSectionItems ?? [{
92
+ id: "support",
93
+ label: translations.support,
94
+ url: null,
95
+ subItems: getSupportLinkMapping(context).map(item => ({
96
+ id: item.id,
97
+ label: item.name,
98
+ url: item.url
99
+ }))
100
+ }, {
101
+ id: "social",
102
+ label: translations.social,
103
+ url: null,
104
+ subItems: socialContent.items.map(item => ({
105
+ id: item.id,
106
+ label: item.label,
107
+ url: item.src
108
+ }))
109
+ }, ...[{
110
+ key: "company",
111
+ label: translations.company
112
+ }, {
113
+ key: "training",
114
+ label: translations.training
115
+ }, {
116
+ key: "tools",
117
+ label: translations.tools
118
+ }].map(({
119
+ key,
120
+ label
121
+ }) => ({
122
+ id: key,
123
+ label,
124
+ url: null,
125
+ subItems: footerContent[key].items.map(item => ({
126
+ id: item.id,
127
+ label: item.label,
128
+ url: item.src
129
+ }))
130
+ }))]
131
+ }, currentCountryName ? {
100
132
  id: "country-selector",
101
133
  items: [{
102
134
  id: "current-country-name",
103
- label: translations.region,
104
- value: currentCountryName,
135
+ label: currentCountryName,
105
136
  icon: {
106
- src: imageSrc(LocationPinIcon__default),
137
+ src: typeof GlobeIcon__default === "string" ? GlobeIcon__default : GlobeIcon__default.src,
107
138
  width: 17,
108
139
  height: 17
109
140
  },
@@ -112,51 +143,9 @@ const NavigationProMobileMenu = function NavigationProMobileMenu2({
112
143
  },
113
144
  subItems: []
114
145
  }]
115
- } : null, ...(extraSectionItems ?? [{
116
- id: "support",
117
- label: translations.support,
118
- url: null,
119
- subItems: getSupportLinkMapping(context).map(item => ({
120
- id: item.id,
121
- label: item.name,
122
- url: item.url
123
- }))
124
- }, {
125
- id: "social",
126
- label: translations.social,
127
- url: null,
128
- subItems: socialContent.items.map(item => ({
129
- id: item.id,
130
- label: item.label,
131
- url: item.src
132
- }))
133
- }, ...[{
134
- key: "company",
135
- label: translations.company
136
- }, {
137
- key: "training",
138
- label: translations.training
139
- }, {
140
- key: "tools",
141
- label: translations.tools
142
- }].map(({
143
- key,
144
- label
145
- }) => ({
146
- id: key,
147
- label,
148
- url: null,
149
- subItems: footerContent[key].items.map(item => ({
150
- id: item.id,
151
- label: item.label,
152
- url: item.src
153
- }))
154
- }))]).map(item => ({
155
- id: `extra-${item.id}`,
156
- items: [item]
157
- }))];
146
+ } : null];
158
147
  return _sections.filter(el => !!el);
159
- }, [handleOrderHistoryClick, translations.orderHistory, translations.purchasedProductHistory, translations.support, translations.social, translations.company, translations.training, translations.tools, translations.region, handlePurchaseHistoryClick, inlineCategoryTabs, extraSectionItems, context, socialContent.items, currentCountryName, footerContent, handleStorePickerClick]);
148
+ }, [context, currentCountryName, extraSectionItems, footerContent, handleOrderHistoryClick, handlePurchaseHistoryClick, handleStorePickerClick, socialContent.items, translations.company, translations.orderHistory, translations.purchasedProductHistory, translations.social, translations.support, translations.tools, translations.training]);
160
149
  const renderSectionItemIcon = useCallback(item => {
161
150
  return item.icon && /* @__PURE__ */jsx(SectionItemIcon, {
162
151
  children: /* @__PURE__ */jsx(StyleableSvgImage, {
@@ -171,45 +160,34 @@ const NavigationProMobileMenu = function NavigationProMobileMenu2({
171
160
  const NewLabelNode = "isNew" in item && item.isNew ? /* @__PURE__ */jsx(NewLabel, {
172
161
  children: translations.new
173
162
  }) : null;
174
- const ValueNode = !!item.value && /* @__PURE__ */jsx("div", {
175
- children: item.value
176
- });
177
163
  const target = "targetBlank" in item && item.targetBlank ? "_blank" : void 0;
178
164
  const url = item.url;
179
165
  if (!url) {
180
- return /* @__PURE__ */jsxs(ProSectionItemButton, {
166
+ return /* @__PURE__ */jsxs(SectionItemButton, {
181
167
  motif,
182
168
  onClick: () => toggleExpandedSectionItemId(item.id),
183
- children: [/* @__PURE__ */jsxs(ButtonContent, {
184
- children: [IconNode, item.label]
185
- }), ValueNode]
169
+ children: [IconNode, item.label]
186
170
  });
187
171
  }
188
- if (typeof url === "string" || typeof url === "object") {
189
- const href = typeof url === "string" ? url : void 0;
190
- const anchor = /* @__PURE__ */jsxs(ProSectionItemButton, {
172
+ if (typeof url === "string") {
173
+ return /* @__PURE__ */jsxs(SectionItemButton, {
191
174
  motif,
192
175
  as: "a",
193
- href,
176
+ href: url,
194
177
  onClick: onClose,
195
178
  target,
196
- children: [/* @__PURE__ */jsxs(ButtonContent, {
197
- children: [IconNode, item.label, NewLabelNode]
198
- }), ValueNode]
179
+ children: [IconNode, item.label, NewLabelNode]
199
180
  });
200
- return inlineCategoryTabs?.renderLink?.(anchor) ?? anchor;
201
181
  }
202
- return /* @__PURE__ */jsxs(ProSectionItemButton, {
182
+ return /* @__PURE__ */jsxs(SectionItemButton, {
203
183
  motif,
204
184
  onClick: () => {
205
185
  url();
206
186
  onClose();
207
187
  },
208
- children: [/* @__PURE__ */jsxs(ButtonContent, {
209
- children: [IconNode, item.label]
210
- }), ValueNode]
188
+ children: [IconNode, item.label]
211
189
  });
212
- }, [inlineCategoryTabs, onClose, renderSectionItemIcon, toggleExpandedSectionItemId, translations.new]);
190
+ }, [onClose, renderSectionItemIcon, toggleExpandedSectionItemId, translations.new]);
213
191
  return /* @__PURE__ */jsx(Wrap, {
214
192
  motif,
215
193
  children: /* @__PURE__ */jsx(Container, {
@@ -1 +1 @@
1
- {"version":3,"file":"ProMobileMenu.mjs","sources":["../../../../../src/components/Header/Navigation/ProMobileMenu/ProMobileMenu.tsx"],"sourcesContent":["/* eslint-disable @next/next/no-img-element */\nimport type { Motif } from \"@ubnt/ui-components/utils\";\nimport { useCallback, useMemo, useState } from \"react\";\n\n// import EAIcon from \"../../../../assets/icons/menu/icon-ea.svg\";\nimport HistoryIcon from \"../../../../assets/icons/menu/icon-history.svg\";\nimport LocationPinIcon from \"../../../../assets/icons/menu/icon-location-pin.svg\";\nimport * as icons from \"../../../../constants/icons\";\nimport { useMenu } from \"../../../../contexts/MenuContext\";\nimport { imageSrc } from \"../../../../utils/asset\";\nimport { useFooterContent } from \"../../../Footer/hooks/useFooterContent\";\nimport { StyleableSvgImage } from \"../../../StyleableSvgImage\";\nimport { getSupportLinkMapping } from \"../../LinksModal/mapping\";\nimport * as S from \"../MobileMenu/MobileMenu.styles\";\nimport * as S2 from \"./ProMobileMenu.styles\";\nimport type {\n NavigationProMobileMenuProps,\n ProMobileMenuSection,\n ProMobileMenuSectionItem,\n ProMobileMenuSectionSubItem,\n} from \"./ProMobileMenu.types\";\n\nconst motif: Motif = \"light\";\n\nexport const NavigationProMobileMenu = function NavigationProMobileMenu({\n translations,\n onClose,\n currentCountryName,\n handleStorePickerClick,\n // handleEarlyAccessClick,\n handleOrderHistoryClick,\n handlePurchaseHistoryClick,\n handleProductLineChange,\n productLineValue,\n productLineOptions,\n extraSectionItems,\n inlineCategoryTabs,\n}: NavigationProMobileMenuProps) {\n const { footerContent, socialContent } = useFooterContent();\n const { context } = useMenu();\n\n // #############################################################################\n // Section toggling\n // #############################################################################\n const [expandedSectionItemId, setExpandedSectionItemId] = useState<\n string | null\n >(null);\n\n const toggleExpandedSectionItemId = useCallback(\n (itemId: string) => {\n setExpandedSectionItemId(\n expandedSectionItemId === itemId ? null : itemId,\n );\n },\n [expandedSectionItemId],\n );\n\n // #############################################################################\n // Menu sections\n // #############################################################################\n const sections = useMemo((): ProMobileMenuSection[] => {\n const _sections: Array<ProMobileMenuSection | null> = [\n {\n id: \"store-link-stuff\",\n items: [\n ...(handleOrderHistoryClick\n ? [\n {\n id: \"order-history\",\n label: translations.orderHistory,\n icon: {\n src: imageSrc(HistoryIcon),\n width: 16,\n height: 16,\n },\n url: () => {\n handleOrderHistoryClick?.();\n },\n subItems: [],\n },\n ]\n : []),\n ...(handlePurchaseHistoryClick\n ? [\n {\n id: \"purchased-product-history\",\n label: translations.purchasedProductHistory,\n icon: {\n src: imageSrc(HistoryIcon),\n width: 16,\n height: 16,\n },\n url: () => {\n handlePurchaseHistoryClick?.();\n },\n subItems: [],\n },\n ]\n : []),\n /**\n * NOTE: Disabled per Kaspars request (09.06.)\n * @see https://ui.slack.com/archives/C050CTJSE80/p1686331781297389\n */\n // {\n // id: \"early-access\",\n // label: translations.earlyAccess,\n // icon: {\n // src: typeof EAIcon === \"string\" ? EAIcon : EAIcon.src,\n // width: 20,\n // height: 16,\n // },\n // url: () => {\n // handleEarlyAccessClick?.();\n // },\n // subItems: [],\n // },\n ],\n },\n inlineCategoryTabs\n ? {\n id: \"categories\",\n items: inlineCategoryTabs.categories.map(\n (category): ProMobileMenuSectionItem => ({\n id: category.id,\n label: category.label,\n url: category.href ?? null,\n subItems: [],\n }),\n ),\n }\n : null,\n currentCountryName\n ? {\n id: \"country-selector\",\n items: [\n {\n id: \"current-country-name\",\n label: translations.region,\n value: currentCountryName,\n icon: {\n src: imageSrc(LocationPinIcon),\n width: 17,\n height: 17,\n },\n url: () => {\n handleStorePickerClick?.();\n },\n subItems: [],\n },\n ],\n }\n : null,\n\n ...(\n extraSectionItems ?? [\n {\n id: \"support\",\n label: translations.support,\n url: null,\n subItems: getSupportLinkMapping(context).map((item) => ({\n id: item.id,\n label: item.name,\n url: item.url,\n })),\n },\n {\n id: \"social\",\n label: translations.social,\n url: null,\n subItems: socialContent.items.map((item) => ({\n id: item.id,\n label: item.label,\n url: item.src,\n })),\n },\n ...(\n [\n { key: \"company\", label: translations.company },\n { key: \"training\", label: translations.training },\n { key: \"tools\", label: translations.tools },\n ] as const\n ).map(({ key, label }) => ({\n id: key,\n label,\n url: null,\n subItems: footerContent[key].items.map((item) => ({\n id: item.id,\n label: item.label,\n url: item.src,\n })),\n })),\n ]\n ).map((item) => ({\n id: `extra-${item.id}`,\n items: [item],\n })),\n ];\n\n return _sections.filter((el): el is ProMobileMenuSection => !!el);\n }, [\n handleOrderHistoryClick,\n translations.orderHistory,\n translations.purchasedProductHistory,\n translations.support,\n translations.social,\n translations.company,\n translations.training,\n translations.tools,\n translations.region,\n handlePurchaseHistoryClick,\n inlineCategoryTabs,\n extraSectionItems,\n context,\n socialContent.items,\n currentCountryName,\n footerContent,\n handleStorePickerClick,\n ]);\n\n // #############################################################################\n // Render helpers\n // #############################################################################\n const renderSectionItemIcon = useCallback(\n (item: ProMobileMenuSection[\"items\"][number]): React.ReactNode => {\n return (\n item.icon && (\n <S2.SectionItemIcon>\n <StyleableSvgImage\n src={item.icon.src}\n width={item.icon.width}\n height={item.icon.height}\n />\n </S2.SectionItemIcon>\n )\n );\n },\n [],\n );\n\n const renderSectionItemButton = useCallback(\n (\n item: ProMobileMenuSectionItem | ProMobileMenuSectionSubItem,\n ): React.ReactNode => {\n const IconNode = \"subItems\" in item && renderSectionItemIcon(item);\n const NewLabelNode =\n \"isNew\" in item && item.isNew ? (\n <S.NewLabel>{translations.new}</S.NewLabel>\n ) : null;\n const ValueNode = !!item.value && <div>{item.value}</div>;\n\n const target =\n \"targetBlank\" in item && item.targetBlank ? \"_blank\" : undefined;\n const url = item.url;\n\n if (!url) {\n return (\n <S2.ProSectionItemButton\n motif={motif}\n onClick={() => toggleExpandedSectionItemId(item.id)}\n >\n <S2.ButtonContent>\n {IconNode}\n {item.label}\n </S2.ButtonContent>\n {ValueNode}\n </S2.ProSectionItemButton>\n );\n }\n\n if (typeof url === \"string\" || typeof url === \"object\") {\n const href = typeof url === \"string\" ? url : undefined;\n const anchor = (\n <S2.ProSectionItemButton\n motif={motif}\n as=\"a\"\n href={href}\n onClick={onClose}\n target={target}\n >\n <S2.ButtonContent>\n {IconNode}\n {item.label}\n {NewLabelNode}\n </S2.ButtonContent>\n {ValueNode}\n </S2.ProSectionItemButton>\n );\n\n return inlineCategoryTabs?.renderLink?.(anchor) ?? anchor;\n }\n\n return (\n <S2.ProSectionItemButton\n motif={motif}\n onClick={() => {\n url();\n onClose();\n }}\n >\n <S2.ButtonContent>\n {IconNode}\n {item.label}\n </S2.ButtonContent>\n {ValueNode}\n </S2.ProSectionItemButton>\n );\n },\n [\n inlineCategoryTabs,\n onClose,\n renderSectionItemIcon,\n toggleExpandedSectionItemId,\n translations.new,\n ],\n );\n\n // #############################################################################\n // Render\n // #############################################################################\n return (\n <S.Wrap motif={motif}>\n <S.Container size=\"mobile\" noVerticalMargin>\n <S.InnerWrap>\n {/* Product line */}\n {!!productLineOptions?.length && (\n <S2.ButtonGroup>\n {productLineOptions.map((option) => (\n <S2.CustomButton\n full\n key={option.value}\n variant=\"gray\"\n $active={option.value === productLineValue}\n onClick={() => {\n handleProductLineChange?.(option.value);\n onClose();\n }}\n >\n {option.label}\n </S2.CustomButton>\n ))}\n </S2.ButtonGroup>\n )}\n\n {/* Sections */}\n {sections.map((section) => (\n <S.Section motif={motif} key={section.id}>\n {section.items.map((item) => (\n <S.SectionItemsGroup\n motif={motif}\n key={item.id}\n $active={item.id === expandedSectionItemId}\n >\n <S.SectionItem motif={motif}>\n {renderSectionItemButton(item)}\n\n {item.subItems.length > 0 && (\n <S.SectionItemArrowButton\n motif={motif}\n onClick={() => toggleExpandedSectionItemId(item.id)}\n >\n <S.ButtonIcon>\n <StyleableSvgImage\n src={icons.generic.collapseArrow}\n width={13}\n height={8}\n />\n </S.ButtonIcon>\n </S.SectionItemArrowButton>\n )}\n </S.SectionItem>\n\n {item.id === expandedSectionItemId &&\n item.subItems.length > 0 &&\n item.subItems.map((subItem) => (\n <S.SectionItem key={subItem.id} motif={motif} $secondary>\n {renderSectionItemButton(subItem)}\n </S.SectionItem>\n ))}\n </S.SectionItemsGroup>\n ))}\n </S.Section>\n ))}\n </S.InnerWrap>\n </S.Container>\n </S.Wrap>\n );\n};\n"],"names":["motif","NavigationProMobileMenu","NavigationProMobileMenu2","translations","onClose","currentCountryName","handleStorePickerClick","handleOrderHistoryClick","handlePurchaseHistoryClick","handleProductLineChange","productLineValue","productLineOptions","extraSectionItems","inlineCategoryTabs","footerContent","socialContent","useFooterContent","context","useMenu","expandedSectionItemId","setExpandedSectionItemId","useState","toggleExpandedSectionItemId","useCallback","itemId","sections","useMemo","_sections","id","items","label","orderHistory","icon","src","imageSrc","HistoryIcon","width","height","url","subItems","purchasedProductHistory","categories","map","category","href","region","value","LocationPinIcon","support","getSupportLinkMapping","item","name","social","key","company","training","tools","filter","el","renderSectionItemIcon","jsx","S2.SectionItemIcon","children","StyleableSvgImage","renderSectionItemButton","IconNode","NewLabelNode","isNew","S.NewLabel","new","ValueNode","target","targetBlank","jsxs","S2.ProSectionItemButton","onClick","S2.ButtonContent","anchor","as","renderLink","S.Wrap","S.Container","size","noVerticalMargin","S.InnerWrap","length","S2.ButtonGroup","option","S2.CustomButton","full","variant","$active","section","S.Section","S.SectionItemsGroup","S.SectionItem","S.SectionItemArrowButton","S.ButtonIcon","icons.generic.collapseArrow","subItem","$secondary"],"mappings":";;;;;;;;;;;;;;;;;;AAsBA,MAAMA,KAAe,GAAA,OAAA;AAER,MAAAC,uBAAA,GAA0B,SAASA,wBAAwBC,CAAA;EACtEC,YAAA;EACAC,OAAA;EACAC,kBAAA;EACAC,sBAAA;EAAA;EAEAC,uBAAA;EACAC,0BAAA;EACAC,uBAAA;EACAC,gBAAA;EACAC,kBAAA;EACAC,iBAAA;EACAC;AACF,CAAiC,EAAA;EAC/B,MAAM;IAAEC,aAAA;IAAeC;EAAc,CAAA,GAAIC,gBAAiB,CAAA,CAAA;EACpD,MAAA;IAAEC;GAAQ,GAAIC,OAAQ,EAAA;EAK5B,MAAM,CAACC,qBAAA,EAAuBC,wBAAwB,CAAA,GAAIC,SAExD,IAAI,CAAA;EAEN,MAAMC,2BAA8B,GAAAC,WAAA,CACjCC,MAAmB,IAAA;IAClBJ,wBAAA,CACED,qBAAA,KAA0BK,SAAS,IAAO,GAAAA,MAAA,CAC5C;EACF,CAAA,EACA,CAACL,qBAAqB,CAAA,CACxB;EAKM,MAAAM,QAAA,GAAWC,QAAQ,MAA8B;IACrD,MAAMC,SAAgD,GAAA,CACpD;MACEC,EAAI,EAAA,kBAAA;MACJC,KAAO,EAAA,CACL,IAAItB,uBACA,GAAA,CACE;QACEqB,EAAI,EAAA,eAAA;QACJE,OAAO3B,YAAa,CAAA4B,YAAA;QACpBC,IAAM,EAAA;UACJC,GAAA,EAAKC,SAASC,oBAAW,CAAA;UACzBC,KAAO,EAAA,EAAA;UACPC,MAAQ,EAAA;QACV,CAAA;QACAC,K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AAAsB,WAAA,EAAA;cAAc/F,KACZ;cAAA8D,QAAA,EAAA,CAAAE,uBAAA,CAAwBd,IAAI,CAAA,EAE5BA,IAAA,CAAKX,QAAS,CAAA8C,MAAA,GAAS,CACtB,mBAAAzB,GAAA,CAACoC,sBAAE,EAAF;gBACChG,KAAA;gBACA2E,OAAS,EAAAA,CAAA,KAAMrD,2BAA4B,CAAA4B,IAAA,CAAKtB,EAAE,CAAA;gBAElDkC,QAAA,iBAAAF,GAAA,CAACqC,UAAE,EAAF;kBACCnC,QAAA,EAAA,eAAAF,GAAA,CAACG,iBAAA,EAAA;oBACC9B,GAAA,EAAKiE,iCAAc;oBACnB9D,KAAO,EAAA,EAAA;oBACPC,MAAQ,EAAA;kBAAA,CAAA;iBAEZ;cAAA,CACF,CAAA;aAEJ,CAAA,EAECa,IAAA,CAAKtB,EAAO,KAAAT,qBAAA,IACX+B,IAAK,CAAAX,QAAA,CAAS8C,SAAS,CACvB,IAAAnC,IAAA,CAAKX,QAAS,CAAAG,GAAA,CAAKyD,OAAA,IAAA,mBAChBJ,WAAE,EAAF;cAA+B/F,KAAA;cAAcoG,UAAU,EAAA,IAAA;cACrDtC,kCAAwBqC,OAAO;YAAA,CAAA,EADdA,OAAQ,CAAAvE,EAE5B,CACD,CAAA;UAAA,CAAA,EA5BEsB,IAAK,CAAAtB,EAAA,CA8Bb;QAAA,CAAA,EAlC2BgE,OAAQ,CAAAhE,EAmCtC,CACD,CAAA;OACH;KACF;EACF,CAAA,CAAA;AAEJ,CAAA;"}
1
+ {"version":3,"file":"ProMobileMenu.mjs","sources":["../../../../../src/components/Header/Navigation/ProMobileMenu/ProMobileMenu.tsx"],"sourcesContent":["/* eslint-disable @next/next/no-img-element */\nimport type { Motif } from \"@ubnt/ui-components/utils\";\nimport { useCallback, useMemo, useState } from \"react\";\n\n// import EAIcon from \"../../../../assets/icons/menu/icon-ea.svg\";\nimport GlobeIcon from \"../../../../assets/icons/menu/icon-globe.svg\";\nimport HistoryIcon from \"../../../../assets/icons/menu/icon-history.svg\";\nimport * as icons from \"../../../../constants/icons\";\nimport { useMenu } from \"../../../../contexts/MenuContext\";\nimport { useFooterContent } from \"../../../Footer/hooks/useFooterContent\";\nimport { StyleableSvgImage } from \"../../../StyleableSvgImage\";\nimport { getSupportLinkMapping } from \"../../LinksModal/mapping\";\nimport * as S from \"../MobileMenu/MobileMenu.styles\";\nimport * as S2 from \"./ProMobileMenu.styles\";\nimport type {\n NavigationProMobileMenuProps,\n ProMobileMenuSection,\n ProMobileMenuSectionItem,\n ProMobileMenuSectionSubItem,\n} from \"./ProMobileMenu.types\";\n\nexport const NavigationProMobileMenu = function NavigationProMobileMenu({\n translations,\n onClose,\n currentCountryName,\n handleStorePickerClick,\n // handleEarlyAccessClick,\n handleOrderHistoryClick,\n handlePurchaseHistoryClick,\n handleProductLineChange,\n productLineValue,\n productLineOptions,\n extraSectionItems,\n}: NavigationProMobileMenuProps) {\n const motif: Motif = \"light\";\n\n const { footerContent, socialContent } = useFooterContent();\n const { context } = useMenu();\n\n // #############################################################################\n // Section toggling\n // #############################################################################\n const [expandedSectionItemId, setExpandedSectionItemId] = useState<\n string | null\n >(null);\n\n const toggleExpandedSectionItemId = useCallback(\n (itemId: string) => {\n setExpandedSectionItemId(\n expandedSectionItemId === itemId ? null : itemId,\n );\n },\n [expandedSectionItemId],\n );\n\n // #############################################################################\n // Menu sections\n // #############################################################################\n const sections = useMemo((): ProMobileMenuSection[] => {\n const _sections: Array<ProMobileMenuSection | null> = [\n {\n id: \"store-link-stuff\",\n items: [\n ...(handleOrderHistoryClick\n ? [\n {\n id: \"order-history\",\n label: translations.orderHistory,\n icon: {\n src:\n typeof HistoryIcon === \"string\"\n ? HistoryIcon\n : HistoryIcon.src,\n width: 16,\n height: 16,\n },\n url: () => {\n handleOrderHistoryClick?.();\n },\n subItems: [],\n },\n ]\n : []),\n ...(handlePurchaseHistoryClick\n ? [\n {\n id: \"purchased-product-history\",\n label: translations.purchasedProductHistory,\n icon: {\n src:\n typeof HistoryIcon === \"string\"\n ? HistoryIcon\n : HistoryIcon.src,\n width: 16,\n height: 16,\n },\n url: () => {\n handlePurchaseHistoryClick?.();\n },\n subItems: [],\n },\n ]\n : []),\n /**\n * NOTE: Disabled per Kaspars request (09.06.)\n * @see https://ui.slack.com/archives/C050CTJSE80/p1686331781297389\n */\n // {\n // id: \"early-access\",\n // label: translations.earlyAccess,\n // icon: {\n // src: typeof EAIcon === \"string\" ? EAIcon : EAIcon.src,\n // width: 20,\n // height: 16,\n // },\n // url: () => {\n // handleEarlyAccessClick?.();\n // },\n // subItems: [],\n // },\n ],\n },\n {\n id: \"extra\",\n items: extraSectionItems ?? [\n {\n id: \"support\",\n label: translations.support,\n url: null,\n subItems: getSupportLinkMapping(context).map((item) => ({\n id: item.id,\n label: item.name,\n url: item.url,\n })),\n },\n {\n id: \"social\",\n label: translations.social,\n url: null,\n subItems: socialContent.items.map((item) => ({\n id: item.id,\n label: item.label,\n url: item.src,\n })),\n },\n ...(\n [\n { key: \"company\", label: translations.company },\n { key: \"training\", label: translations.training },\n { key: \"tools\", label: translations.tools },\n ] as const\n ).map(({ key, label }) => ({\n id: key,\n label,\n url: null,\n subItems: footerContent[key].items.map((item) => ({\n id: item.id,\n label: item.label,\n url: item.src,\n })),\n })),\n ],\n },\n currentCountryName\n ? {\n id: \"country-selector\",\n items: [\n {\n id: \"current-country-name\",\n label: currentCountryName,\n icon: {\n src:\n typeof GlobeIcon === \"string\" ? GlobeIcon : GlobeIcon.src,\n width: 17,\n height: 17,\n },\n url: () => {\n handleStorePickerClick?.();\n },\n subItems: [],\n },\n ],\n }\n : null,\n ];\n\n return _sections.filter((el): el is ProMobileMenuSection => !!el);\n }, [\n context,\n currentCountryName,\n extraSectionItems,\n footerContent,\n handleOrderHistoryClick,\n handlePurchaseHistoryClick,\n handleStorePickerClick,\n socialContent.items,\n translations.company,\n translations.orderHistory,\n translations.purchasedProductHistory,\n translations.social,\n translations.support,\n translations.tools,\n translations.training,\n ]);\n\n // #############################################################################\n // Render helpers\n // #############################################################################\n const renderSectionItemIcon = useCallback(\n (item: ProMobileMenuSection[\"items\"][number]): React.ReactNode => {\n return (\n item.icon && (\n <S2.SectionItemIcon>\n <StyleableSvgImage\n src={item.icon.src}\n width={item.icon.width}\n height={item.icon.height}\n />\n </S2.SectionItemIcon>\n )\n );\n },\n [],\n );\n\n const renderSectionItemButton = useCallback(\n (\n item: ProMobileMenuSectionItem | ProMobileMenuSectionSubItem,\n ): React.ReactNode => {\n const IconNode = \"subItems\" in item && renderSectionItemIcon(item);\n const NewLabelNode =\n \"isNew\" in item && item.isNew ? (\n <S.NewLabel>{translations.new}</S.NewLabel>\n ) : null;\n const target =\n \"targetBlank\" in item && item.targetBlank ? \"_blank\" : undefined;\n const url = item.url;\n\n if (!url) {\n return (\n <S.SectionItemButton\n motif={motif}\n onClick={() => toggleExpandedSectionItemId(item.id)}\n >\n {IconNode}\n {item.label}\n </S.SectionItemButton>\n );\n }\n\n if (typeof url === \"string\") {\n return (\n <S.SectionItemButton\n motif={motif}\n as=\"a\"\n href={url}\n onClick={onClose}\n target={target}\n >\n {IconNode}\n {item.label}\n {NewLabelNode}\n </S.SectionItemButton>\n );\n }\n\n return (\n <S.SectionItemButton\n motif={motif}\n onClick={() => {\n url();\n onClose();\n }}\n >\n {IconNode}\n {item.label}\n </S.SectionItemButton>\n );\n },\n [\n onClose,\n renderSectionItemIcon,\n toggleExpandedSectionItemId,\n translations.new,\n ],\n );\n\n // #############################################################################\n // Render\n // #############################################################################\n return (\n <S.Wrap motif={motif}>\n <S.Container size=\"mobile\" noVerticalMargin>\n <S.InnerWrap>\n {/* Product line */}\n {!!productLineOptions?.length && (\n <S2.ButtonGroup>\n {productLineOptions.map((option) => (\n <S2.CustomButton\n full\n key={option.value}\n variant=\"gray\"\n $active={option.value === productLineValue}\n onClick={() => {\n handleProductLineChange?.(option.value);\n onClose();\n }}\n >\n {option.label}\n </S2.CustomButton>\n ))}\n </S2.ButtonGroup>\n )}\n\n {/* Sections */}\n {sections.map((section) => (\n <S.Section motif={motif} key={section.id}>\n {section.items.map((item) => (\n <S.SectionItemsGroup\n motif={motif}\n key={item.id}\n $active={item.id === expandedSectionItemId}\n >\n <S.SectionItem motif={motif}>\n {renderSectionItemButton(item)}\n\n {item.subItems.length > 0 && (\n <S.SectionItemArrowButton\n motif={motif}\n onClick={() => toggleExpandedSectionItemId(item.id)}\n >\n <S.ButtonIcon>\n <StyleableSvgImage\n src={icons.generic.collapseArrow}\n width={13}\n height={8}\n />\n </S.ButtonIcon>\n </S.SectionItemArrowButton>\n )}\n </S.SectionItem>\n\n {item.id === expandedSectionItemId &&\n item.subItems.length > 0 &&\n item.subItems.map((subItem) => (\n <S.SectionItem key={subItem.id} motif={motif} $secondary>\n {renderSectionItemButton(subItem)}\n </S.SectionItem>\n ))}\n </S.SectionItemsGroup>\n ))}\n </S.Section>\n ))}\n </S.InnerWrap>\n </S.Container>\n </S.Wrap>\n );\n};\n"],"names":["NavigationProMobileMenu","NavigationProMobileMenu2","translations","onClose","currentCountryName","handleStorePickerClick","handleOrderHistoryClick","handlePurchaseHistoryClick","handleProductLineChange","productLineValue","productLineOptions","extraSectionItems","motif","footerContent","socialContent","useFooterContent","context","useMenu","expandedSectionItemId","setExpandedSectionItemId","useState","toggleExpandedSectionItemId","useCallback","itemId","sections","useMemo","_sections","id","items","label","orderHistory","icon","src","HistoryIcon","width","height","url","subItems","purchasedProductHistory","support","getSupportLinkMapping","map","item","name","social","key","company","training","tools","GlobeIcon","filter","el","renderSectionItemIcon","jsx","S2.SectionItemIcon","children","StyleableSvgImage","renderSectionItemButton","IconNode","NewLabelNode","isNew","S.NewLabel","new","target","targetBlank","jsxs","S.SectionItemButton","onClick","as","href","S.Wrap","S.Container","size","noVerticalMargin","S.InnerWrap","length","S2.ButtonGroup","option","S2.CustomButton","full","variant","$active","value","section","S.Section","S.SectionItemsGroup","S.SectionItem","S.SectionItemArrowButton","S.ButtonIcon","icons.generic.collapseArrow","subIt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AAA,CAAC,eAAAU,IAAA,CAAAqB,WAAA,EAAA;cAAc1E,KACZ;cAAA2C,QAAA,EAAA,CAAAE,uBAAA,CAAwBf,IAAI,CAAA,EAE5BA,IAAA,CAAKL,QAAS,CAAAsC,MAAA,GAAS,CACtB,mBAAAtB,GAAA,CAACkC,sBAAE,EAAF;gBACC3E,KAAA;gBACAuD,OAAS,EAAAA,CAAA,KAAM9C,2BAA4B,CAAAqB,IAAA,CAAKf,EAAE,CAAA;gBAElD4B,QAAA,iBAAAF,GAAA,CAACmC,UAAE,EAAF;kBACCjC,QAAA,EAAA,eAAAF,GAAA,CAACG,iBAAA,EAAA;oBACCxB,GAAA,EAAKyD,iCAAc;oBACnBvD,KAAO,EAAA,EAAA;oBACPC,MAAQ,EAAA;kBAAA,CAAA;iBAEZ;cAAA,CACF,CAAA;aAEJ,CAAA,EAECO,IAAA,CAAKf,EAAO,KAAAT,qBAAA,IACXwB,IAAK,CAAAL,QAAA,CAASsC,SAAS,CACvB,IAAAjC,IAAA,CAAKL,QAAS,CAAAI,GAAA,CAAKiD,OAAA,IAAA,mBAChBJ,WAAE,EAAF;cAA+B1E,KAAA;cAAc+E,UAAU,EAAA,IAAA;cACrDpC,kCAAwBmC,OAAO;YAAA,CAAA,EADdA,OAAQ,CAAA/D,EAE5B,CACD,CAAA;UAAA,CAAA,EA5BEe,IAAK,CAAAf,EAAA,CA8Bb;QAAA,CAAA,EAlC2BwD,OAAQ,CAAAxD,EAmCtC,CACD,CAAA;OACH;KACF;EACF,CAAA,CAAA;AAEJ,CAAA;"}
@@ -5,9 +5,3 @@ export declare const CustomButton: import("styled-components").StyledComponent<i
5
5
  $active?: boolean;
6
6
  }, never>;
7
7
  export declare const ButtonGroup: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
8
- export declare const ButtonContent: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
9
- export declare const ProSectionItemButton: import("styled-components").StyledComponent<"button", import("styled-components").DefaultTheme, {
10
- motif: import("@ubnt/ui-components").Motif;
11
- $link?: boolean;
12
- $bold?: boolean;
13
- }, never>;
@@ -3,7 +3,6 @@
3
3
  var styled = require('styled-components');
4
4
  var theme = require('../../../../constants/theme.js');
5
5
  require('../../../Button/index.js');
6
- var MobileMenu_styles = require('../MobileMenu/MobileMenu.styles.js');
7
6
  var Button = require('../../../Button/Button.js');
8
7
  function _interopDefault(e) {
9
8
  return e && e.__esModule ? e : {
@@ -15,6 +14,7 @@ var styled__default = /*#__PURE__*/_interopDefault(styled);
15
14
  const SectionItemIcon = styled__default["default"].div`
16
15
  width: 20px;
17
16
  height: 20px;
17
+ margin-right: 10px;
18
18
  color: ${theme.theme.colors.black};
19
19
 
20
20
  display: flex;
@@ -39,17 +39,7 @@ const ButtonGroup = styled__default["default"].div`
39
39
  display: flex;
40
40
  gap: 8px;
41
41
  `;
42
- const ButtonContent = styled__default["default"].div`
43
- display: flex;
44
- align-items: center;
45
- gap: 10px;
46
- `;
47
- const ProSectionItemButton = styled__default["default"](MobileMenu_styles.SectionItemButton)`
48
- justify-content: space-between;
49
- `;
50
- exports.ButtonContent = ButtonContent;
51
42
  exports.ButtonGroup = ButtonGroup;
52
43
  exports.CustomButton = CustomButton;
53
- exports.ProSectionItemButton = ProSectionItemButton;
54
44
  exports.SectionItemIcon = SectionItemIcon;
55
45
  //# sourceMappingURL=ProMobileMenu.styles.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"ProMobileMenu.styles.js","sources":["../../../../../src/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.tsx"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { theme } from \"../../../../constants/theme\";\nimport { Button } from \"../../../Button\";\nimport { SectionItemButton } from \"../MobileMenu/MobileMenu.styles\";\n\nexport const SectionItemIcon = styled.div`\n width: 20px;\n height: 20px;\n color: ${theme.colors.black};\n\n display: flex;\n align-items: center;\n justify-content: center;\n`;\n\n// FIXME i should be using Motif here but...\nexport const CustomButton = styled(Button)<{ $active?: boolean }>`\n height: 46px;\n font-size: ${theme.font.size14};\n line-height: 1;\n border-radius: 6px;\n\n ${({ $active }) =>\n $active &&\n css`\n background: ${theme.colors.white} !important;\n border-width: 4px;\n color: ${theme.colors.primaryBlue};\n `}\n`;\n\nexport const ButtonGroup = styled.div`\n display: flex;\n gap: 8px;\n`;\n\nexport const ButtonContent = styled.div`\n display: flex;\n align-items: center;\n gap: 10px;\n`;\n\nexport const ProSectionItemButton = styled(SectionItemButton)`\n justify-content: space-between;\n`;\n"],"names":["SectionItemIcon","styled","div","theme","colors","black","CustomButton","Button","font","size14","$active","css","white","primaryBlue","ButtonGroup","ButtonContent","ProSectionItemButton","SectionItemButton"],"mappings":";;;;;;;;;;;;;;AAMO,MAAMA,kBAAkBC,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA,WAG3BC,KAAA,CAAAA,KAAA,CAAMC,OAAOC,KAAK;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAQhB,MAAAC,YAAA,GAAeL,eAAAA,CAAAA,SAAAA,EAAOM,MAAAA,CAAAA,MAAM,CAAA;AAAA;AAAA,eAE1BJ,KAAA,CAAAA,KAAA,CAAMK,KAAKC,MAAM;AAAA;AAAA;AAAA;AAAA,IAI5B,CAAC;EAAEC;CAAQ,KACXA,OACA,IAAAC,MAAAA,CAAAA,GAAA;AAAA,oBACgBR,KAAA,CAAAA,KAAA,CAAMC,OAAOQ,KAAK;AAAA;AAAA,eAEvBT,KAAA,CAAAA,KAAA,CAAMC,OAAOS,WAAW;AAAA,KAClC;AAAA,CAAA;AAGE,MAAMC,cAAcb,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA,CAAA;AAK3B,MAAMa,gBAAgBd,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAMvB,MAAAc,oBAAA,GAAuBf,eAAAA,CAAAA,SAAAA,EAAOgB,iBAAAA,CAAAA,iBAAiB,CAAA;AAAA;AAAA,CAAA;;;;;"}
1
+ {"version":3,"file":"ProMobileMenu.styles.js","sources":["../../../../../src/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.tsx"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { theme } from \"../../../../constants/theme\";\nimport { Button } from \"../../../Button\";\n\nexport const SectionItemIcon = styled.div`\n width: 20px;\n height: 20px;\n margin-right: 10px;\n color: ${theme.colors.black};\n\n display: flex;\n align-items: center;\n justify-content: center;\n`;\n\n// FIXME i should be using Motif here but...\nexport const CustomButton = styled(Button)<{ $active?: boolean }>`\n height: 46px;\n font-size: ${theme.font.size14};\n line-height: 1;\n border-radius: 6px;\n\n ${({ $active }) =>\n $active &&\n css`\n background: ${theme.colors.white} !important;\n border-width: 4px;\n color: ${theme.colors.primaryBlue};\n `}\n`;\n\nexport const ButtonGroup = styled.div`\n display: flex;\n gap: 8px;\n`;\n"],"names":["SectionItemIcon","styled","div","theme","colors","black","CustomButton","Button","font","size14","$active","css","white","primaryBlue","ButtonGroup"],"mappings":";;;;;;;;;;;;;AAKO,MAAMA,kBAAkBC,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA,WAI3BC,KAAA,CAAAA,KAAA,CAAMC,OAAOC,KAAK;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAQhB,MAAAC,YAAA,GAAeL,eAAAA,CAAAA,SAAAA,EAAOM,MAAAA,CAAAA,MAAM,CAAA;AAAA;AAAA,eAE1BJ,KAAA,CAAAA,KAAA,CAAMK,KAAKC,MAAM;AAAA;AAAA;AAAA;AAAA,IAI5B,CAAC;EAAEC;CAAQ,KACXA,OACA,IAAAC,MAAAA,CAAAA,GAAA;AAAA,oBACgBR,KAAA,CAAAA,KAAA,CAAMC,OAAOQ,KAAK;AAAA;AAAA,eAEvBT,KAAA,CAAAA,KAAA,CAAMC,OAAOS,WAAW;AAAA,KAClC;AAAA,CAAA;AAGE,MAAMC,cAAcb,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA,CAAA;;;"}
@@ -1,12 +1,12 @@
1
1
  import styled, { css } from 'styled-components';
2
2
  import { theme } from '../../../../constants/theme.mjs';
3
3
  import '../../../Button/index.mjs';
4
- import { SectionItemButton } from '../MobileMenu/MobileMenu.styles.mjs';
5
4
  import { Button } from '../../../Button/Button.mjs';
6
5
  "use strict";
7
6
  const SectionItemIcon = styled.div`
8
7
  width: 20px;
9
8
  height: 20px;
9
+ margin-right: 10px;
10
10
  color: ${theme.colors.black};
11
11
 
12
12
  display: flex;
@@ -31,13 +31,5 @@ const ButtonGroup = styled.div`
31
31
  display: flex;
32
32
  gap: 8px;
33
33
  `;
34
- const ButtonContent = styled.div`
35
- display: flex;
36
- align-items: center;
37
- gap: 10px;
38
- `;
39
- const ProSectionItemButton = styled(SectionItemButton)`
40
- justify-content: space-between;
41
- `;
42
- export { ButtonContent, ButtonGroup, CustomButton, ProSectionItemButton, SectionItemIcon };
34
+ export { ButtonGroup, CustomButton, SectionItemIcon };
43
35
  //# sourceMappingURL=ProMobileMenu.styles.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"ProMobileMenu.styles.mjs","sources":["../../../../../src/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.tsx"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { theme } from \"../../../../constants/theme\";\nimport { Button } from \"../../../Button\";\nimport { SectionItemButton } from \"../MobileMenu/MobileMenu.styles\";\n\nexport const SectionItemIcon = styled.div`\n width: 20px;\n height: 20px;\n color: ${theme.colors.black};\n\n display: flex;\n align-items: center;\n justify-content: center;\n`;\n\n// FIXME i should be using Motif here but...\nexport const CustomButton = styled(Button)<{ $active?: boolean }>`\n height: 46px;\n font-size: ${theme.font.size14};\n line-height: 1;\n border-radius: 6px;\n\n ${({ $active }) =>\n $active &&\n css`\n background: ${theme.colors.white} !important;\n border-width: 4px;\n color: ${theme.colors.primaryBlue};\n `}\n`;\n\nexport const ButtonGroup = styled.div`\n display: flex;\n gap: 8px;\n`;\n\nexport const ButtonContent = styled.div`\n display: flex;\n align-items: center;\n gap: 10px;\n`;\n\nexport const ProSectionItemButton = styled(SectionItemButton)`\n justify-content: space-between;\n`;\n"],"names":["SectionItemIcon","styled","div","theme","colors","black","CustomButton","Button","font","size14","$active","css","white","primaryBlue","ButtonGroup","ButtonContent","ProSectionItemButton","SectionItemButton"],"mappings":";;;;;;AAMO,MAAMA,kBAAkBC,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA,WAG3BC,KAAA,CAAMC,OAAOC,KAAK;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAQhB,MAAAC,YAAA,GAAeL,OAAOM,MAAM,CAAA;AAAA;AAAA,eAE1BJ,KAAA,CAAMK,KAAKC,MAAM;AAAA;AAAA;AAAA;AAAA,IAI5B,CAAC;EAAEC;CAAQ,KACXA,OACA,IAAAC,GAAA;AAAA,oBACgBR,KAAA,CAAMC,OAAOQ,KAAK;AAAA;AAAA,eAEvBT,KAAA,CAAMC,OAAOS,WAAW;AAAA,KAClC;AAAA,CAAA;AAGE,MAAMC,cAAcb,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA,CAAA;AAK3B,MAAMa,gBAAgBd,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAMvB,MAAAc,oBAAA,GAAuBf,OAAOgB,iBAAiB,CAAA;AAAA;AAAA,CAAA;"}
1
+ {"version":3,"file":"ProMobileMenu.styles.mjs","sources":["../../../../../src/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.tsx"],"sourcesContent":["import styled, { css } from \"styled-components\";\n\nimport { theme } from \"../../../../constants/theme\";\nimport { Button } from \"../../../Button\";\n\nexport const SectionItemIcon = styled.div`\n width: 20px;\n height: 20px;\n margin-right: 10px;\n color: ${theme.colors.black};\n\n display: flex;\n align-items: center;\n justify-content: center;\n`;\n\n// FIXME i should be using Motif here but...\nexport const CustomButton = styled(Button)<{ $active?: boolean }>`\n height: 46px;\n font-size: ${theme.font.size14};\n line-height: 1;\n border-radius: 6px;\n\n ${({ $active }) =>\n $active &&\n css`\n background: ${theme.colors.white} !important;\n border-width: 4px;\n color: ${theme.colors.primaryBlue};\n `}\n`;\n\nexport const ButtonGroup = styled.div`\n display: flex;\n gap: 8px;\n`;\n"],"names":["SectionItemIcon","styled","div","theme","colors","black","CustomButton","Button","font","size14","$active","css","white","primaryBlue","ButtonGroup"],"mappings":";;;;;AAKO,MAAMA,kBAAkBC,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA,WAI3BC,KAAA,CAAMC,OAAOC,KAAK;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAQhB,MAAAC,YAAA,GAAeL,OAAOM,MAAM,CAAA;AAAA;AAAA,eAE1BJ,KAAA,CAAMK,KAAKC,MAAM;AAAA;AAAA;AAAA;AAAA,IAI5B,CAAC;EAAEC;CAAQ,KACXA,OACA,IAAAC,GAAA;AAAA,oBACgBR,KAAA,CAAMC,OAAOQ,KAAK;AAAA;AAAA,eAEvBT,KAAA,CAAMC,OAAOS,WAAW;AAAA,KAClC;AAAA,CAAA;AAGE,MAAMC,cAAcb,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA,CAAA;"}
@@ -1,10 +1,8 @@
1
1
  import type { ProductLine } from "../../../../types";
2
- import type { CategoryTabsProps, Href } from "../../../CategoryTabs/CategoryTabs.types";
3
2
  import type { HeaderTranslations, ProHeaderProps } from "../../Header.types";
4
3
  export type ProMobileMenuSectionSubItem = {
5
4
  id: string;
6
5
  label: string;
7
- value?: string;
8
6
  url: string | (() => void);
9
7
  isNew?: boolean;
10
8
  targetBlank?: boolean;
@@ -12,13 +10,12 @@ export type ProMobileMenuSectionSubItem = {
12
10
  export type ProMobileMenuSectionItem = {
13
11
  id: string;
14
12
  label: string;
15
- value?: string;
16
13
  icon?: {
17
14
  src: string;
18
15
  width: number;
19
16
  height: number;
20
17
  };
21
- url: string | (() => void) | Href | null;
18
+ url: string | (() => void) | null;
22
19
  subItems: Array<ProMobileMenuSectionSubItem>;
23
20
  };
24
21
  export interface ProMobileMenuSection {
@@ -40,5 +37,4 @@ export interface NavigationProMobileMenuProps {
40
37
  }>;
41
38
  hideExtraSection?: boolean;
42
39
  extraSectionItems?: Array<ProMobileMenuSectionItem>;
43
- inlineCategoryTabs?: CategoryTabsProps;
44
40
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Overlay.js","sources":["../../../../src/components/Header/Overlay/Overlay.tsx"],"sourcesContent":["import { useCallback, useMemo } from \"react\";\nimport { useKeyPressEvent } from \"react-use\";\n\nimport { ModalId } from \"../../../contexts/MenuContext/types\";\nimport { useLockBodyScrollCustom } from \"../../../hooks\";\nimport * as S from \"./Overlay.styles\";\nimport type { HeaderOverlayProps } from \"./Overlay.types\";\n\nexport const HeaderOverlay = function HeaderOverlay({\n className,\n showForModal,\n onClose,\n}: HeaderOverlayProps) {\n // #############################################################################\n // Lock body when open\n // #############################################################################\n useLockBodyScrollCustom(!!showForModal);\n\n // #############################################################################\n // Close events\n // #############################################################################\n const canManualClose = useMemo(() => {\n // For now, allow for all but cart modal\n return showForModal !== ModalId.Cart;\n }, [showForModal]);\n\n const handleManualClose = useCallback(() => {\n if (!canManualClose) return;\n\n onClose?.();\n }, [canManualClose, onClose]);\n\n // When escape is pressed\n useKeyPressEvent(\"Escape\", handleManualClose);\n\n // #############################################################################\n // Render\n // #############################################################################\n if (!showForModal) {\n return null;\n }\n\n return (\n <S.Wrap\n className={className}\n onClick={handleManualClose}\n $modalId={showForModal}\n />\n );\n};\n"],"names":["HeaderOverlay","HeaderOverlay2","className","showForModal","onClose","useLockBodyScrollCustom","canManualClose","useMemo","ModalId","Cart","handleManualClose","useCallback","useKeyPressEvent","jsx","S.Wrap","Wrap","onClick","$modalId"],"mappings":";;;;;;;;;;AAQa,MAAAA,aAAA,GAAgB,SAASA,cAAcC,CAAA;EAClDC,SAAA;EACAC,YAAA;EACAC;AACF,CAAuB,EAAA;EAIGC,+CAAA,CAAA,CAAC,CAACF,YAAY,CAAA;EAKhC,MAAAG,cAAA,GAAiBC,KAAAA,CAAAA,QAAQ,MAAM;IAEnC,OAAOJ,iBAAiBK,KAAQ,CAAAA,OAAA,CAAAC,IAAA;EAAA,CAClC,EAAG,CAACN,YAAY,CAAC,CAAA;EAEX,MAAAO,iBAAA,GAAoBC,KAAAA,CAAAA,YAAY,MAAM;IAC1C,IAAI,CAACL,cAAA,EAAgB;IAEXF,OAAA,IAAA;EAAA,CACT,EAAA,CAACE,cAAgB,EAAAF,OAAO,CAAC,CAAA;EAG5BQ,yBAAA,CAAiB,UAAUF,iBAAiB,CAAA;EAK5C,IAAI,CAACP,YAAc,EAAA;IACV,OAAA,IAAA;EACT;EAGE,sBAAAU,UAAA,CAAAA,GAAA,CAACC,cAAE,CAAAC,IAAA,EAAF;IACCb,SAAA;IACAc,OAAS,EAAAN,iBAAA;IACTO,QAAU,EAAAd;EAAA,CAAA,CACZ;AAEJ,CAAA;"}
1
+ {"version":3,"file":"Overlay.js","sources":["../../../../src/components/Header/Overlay/Overlay.tsx"],"sourcesContent":["import { useCallback, useMemo } from \"react\";\nimport { useKeyPressEvent } from \"react-use\";\n\nimport { ModalId } from \"../../../contexts/MenuContext/types\";\nimport { useLockBodyScrollCustom } from \"../../../hooks\";\nimport * as S from \"./Overlay.styles\";\nimport type { HeaderOverlayProps } from \"./Overlay.types\";\n\nexport const HeaderOverlay = function HeaderOverlay({\n className,\n showForModal,\n onClose,\n}: HeaderOverlayProps) {\n // #############################################################################\n // Lock body when open\n // #############################################################################\n useLockBodyScrollCustom(!!showForModal);\n\n // #############################################################################\n // Close events\n // #############################################################################\n const canManualClose = useMemo(() => {\n // For now, allow for all but cart modal\n return showForModal !== ModalId.Cart;\n }, [showForModal]);\n\n const handleManualClose = useCallback(() => {\n if (!canManualClose) return;\n\n onClose?.();\n }, [canManualClose, onClose]);\n\n // When escape is pressed\n useKeyPressEvent(\"Escape\", handleManualClose);\n\n // #############################################################################\n // Render\n // #############################################################################\n if (!showForModal) {\n return null;\n }\n\n return (\n <S.Wrap\n className={className}\n onClick={handleManualClose}\n $modalId={showForModal}\n />\n );\n};\n"],"names":["HeaderOverlay","HeaderOverlay2","className","showForModal","onClose","useLockBodyScrollCustom","canManualClose","useMemo","ModalId","Cart","handleManualClose","useCallback","useKeyPressEvent","jsx","S.Wrap","Wrap","onClick","$modalId"],"mappings":";;;;;;;;;;AAQa,MAAAA,aAAA,GAAgB,SAASA,cAAcC,CAAA;EAClDC,SAAA;EACAC,YAAA;EACAC;AACF,CAAuB,EAAA;EAIGC,+CAAA,CAAA,CAAC,CAACF,YAAY,CAAA;EAKhC,MAAAG,cAAA,GAAiBC,KAAAA,CAAAA,QAAQ,MAAM;IAEnC,OAAOJ,iBAAiBK,KAAQ,CAAAA,OAAA,CAAAC,IAAA;EAAA,CAClC,EAAG,CAACN,YAAY,CAAC,CAAA;EAEX,MAAAO,iBAAA,GAAoBC,KAAAA,CAAAA,YAAY,MAAM;IAC1C,IAAI,CAACL,cAAgB,EAAA;IAEXF,OAAA,IAAA;EAAA,CACT,EAAA,CAACE,cAAgB,EAAAF,OAAO,CAAC,CAAA;EAG5BQ,yBAAA,CAAiB,UAAUF,iBAAiB,CAAA;EAK5C,IAAI,CAACP,YAAc,EAAA;IACV,OAAA,IAAA;EACT;EAGE,sBAAAU,UAAA,CAAAA,GAAA,CAACC,cAAE,CAAAC,IAAA,EAAF;IACCb,SAAA;IACAc,OAAS,EAAAN,iBAAA;IACTO,QAAU,EAAAd;EAAA,CAAA,CACZ;AAEJ,CAAA;"}
@@ -1 +1 @@
1
- {"version":3,"file":"Overlay.mjs","sources":["../../../../src/components/Header/Overlay/Overlay.tsx"],"sourcesContent":["import { useCallback, useMemo } from \"react\";\nimport { useKeyPressEvent } from \"react-use\";\n\nimport { ModalId } from \"../../../contexts/MenuContext/types\";\nimport { useLockBodyScrollCustom } from \"../../../hooks\";\nimport * as S from \"./Overlay.styles\";\nimport type { HeaderOverlayProps } from \"./Overlay.types\";\n\nexport const HeaderOverlay = function HeaderOverlay({\n className,\n showForModal,\n onClose,\n}: HeaderOverlayProps) {\n // #############################################################################\n // Lock body when open\n // #############################################################################\n useLockBodyScrollCustom(!!showForModal);\n\n // #############################################################################\n // Close events\n // #############################################################################\n const canManualClose = useMemo(() => {\n // For now, allow for all but cart modal\n return showForModal !== ModalId.Cart;\n }, [showForModal]);\n\n const handleManualClose = useCallback(() => {\n if (!canManualClose) return;\n\n onClose?.();\n }, [canManualClose, onClose]);\n\n // When escape is pressed\n useKeyPressEvent(\"Escape\", handleManualClose);\n\n // #############################################################################\n // Render\n // #############################################################################\n if (!showForModal) {\n return null;\n }\n\n return (\n <S.Wrap\n className={className}\n onClick={handleManualClose}\n $modalId={showForModal}\n />\n );\n};\n"],"names":["HeaderOverlay","HeaderOverlay2","className","showForModal","onClose","useLockBodyScrollCustom","canManualClose","useMemo","ModalId","Cart","handleManualClose","useCallback","useKeyPressEvent","jsx","S.Wrap","onClick","$modalId"],"mappings":";;;;;;;;AAQa,MAAAA,aAAA,GAAgB,SAASA,cAAcC,CAAA;EAClDC,SAAA;EACAC,YAAA;EACAC;AACF,CAAuB,EAAA;EAIGC,uBAAA,CAAA,CAAC,CAACF,YAAY,CAAA;EAKhC,MAAAG,cAAA,GAAiBC,QAAQ,MAAM;IAEnC,OAAOJ,iBAAiBK,OAAQ,CAAAC,IAAA;EAAA,CAClC,EAAG,CAACN,YAAY,CAAC,CAAA;EAEX,MAAAO,iBAAA,GAAoBC,YAAY,MAAM;IAC1C,IAAI,CAACL,cAAA,EAAgB;IAEXF,OAAA,IAAA;EAAA,CACT,EAAA,CAACE,cAAgB,EAAAF,OAAO,CAAC,CAAA;EAG5BQ,gBAAA,CAAiB,UAAUF,iBAAiB,CAAA;EAK5C,IAAI,CAACP,YAAc,EAAA;IACV,OAAA,IAAA;EACT;EAGE,sBAAAU,GAAA,CAACC,IAAE,EAAF;IACCZ,SAAA;IACAa,OAAS,EAAAL,iBAAA;IACTM,QAAU,EAAAb;EAAA,CAAA,CACZ;AAEJ,CAAA;"}
1
+ {"version":3,"file":"Overlay.mjs","sources":["../../../../src/components/Header/Overlay/Overlay.tsx"],"sourcesContent":["import { useCallback, useMemo } from \"react\";\nimport { useKeyPressEvent } from \"react-use\";\n\nimport { ModalId } from \"../../../contexts/MenuContext/types\";\nimport { useLockBodyScrollCustom } from \"../../../hooks\";\nimport * as S from \"./Overlay.styles\";\nimport type { HeaderOverlayProps } from \"./Overlay.types\";\n\nexport const HeaderOverlay = function HeaderOverlay({\n className,\n showForModal,\n onClose,\n}: HeaderOverlayProps) {\n // #############################################################################\n // Lock body when open\n // #############################################################################\n useLockBodyScrollCustom(!!showForModal);\n\n // #############################################################################\n // Close events\n // #############################################################################\n const canManualClose = useMemo(() => {\n // For now, allow for all but cart modal\n return showForModal !== ModalId.Cart;\n }, [showForModal]);\n\n const handleManualClose = useCallback(() => {\n if (!canManualClose) return;\n\n onClose?.();\n }, [canManualClose, onClose]);\n\n // When escape is pressed\n useKeyPressEvent(\"Escape\", handleManualClose);\n\n // #############################################################################\n // Render\n // #############################################################################\n if (!showForModal) {\n return null;\n }\n\n return (\n <S.Wrap\n className={className}\n onClick={handleManualClose}\n $modalId={showForModal}\n />\n );\n};\n"],"names":["HeaderOverlay","HeaderOverlay2","className","showForModal","onClose","useLockBodyScrollCustom","canManualClose","useMemo","ModalId","Cart","handleManualClose","useCallback","useKeyPressEvent","jsx","S.Wrap","onClick","$modalId"],"mappings":";;;;;;;;AAQa,MAAAA,aAAA,GAAgB,SAASA,cAAcC,CAAA;EAClDC,SAAA;EACAC,YAAA;EACAC;AACF,CAAuB,EAAA;EAIGC,uBAAA,CAAA,CAAC,CAACF,YAAY,CAAA;EAKhC,MAAAG,cAAA,GAAiBC,QAAQ,MAAM;IAEnC,OAAOJ,iBAAiBK,OAAQ,CAAAC,IAAA;EAAA,CAClC,EAAG,CAACN,YAAY,CAAC,CAAA;EAEX,MAAAO,iBAAA,GAAoBC,YAAY,MAAM;IAC1C,IAAI,CAACL,cAAgB,EAAA;IAEXF,OAAA,IAAA;EAAA,CACT,EAAA,CAACE,cAAgB,EAAAF,OAAO,CAAC,CAAA;EAG5BQ,gBAAA,CAAiB,UAAUF,iBAAiB,CAAA;EAK5C,IAAI,CAACP,YAAc,EAAA;IACV,OAAA,IAAA;EACT;EAGE,sBAAAU,GAAA,CAACC,IAAE,EAAF;IACCZ,SAAA;IACAa,OAAS,EAAAL,iBAAA;IACTM,QAAU,EAAAb;EAAA,CAAA,CACZ;AAEJ,CAAA;"}
@@ -6,7 +6,10 @@ export declare const ProHeader: import("react").NamedExoticComponent<Pick<import
6
6
  earlyAccess?: import("../Header.types").ProHeaderEarlyAccess;
7
7
  handlePurchaseHistoryClick?: () => void;
8
8
  handleOrderHistoryClick?: () => void;
9
- productLineOptions?: import("../Header.types").HeaderProductLineOption[];
9
+ productLineOptions?: {
10
+ value: ProductLine;
11
+ label: string;
12
+ }[];
10
13
  productLineValue?: ProductLine;
11
14
  handleProductLineChange?: (type: ProductLine) => void;
12
15
  handleMobileMenuClick?: () => void;
@@ -16,5 +19,4 @@ export declare const ProHeader: import("react").NamedExoticComponent<Pick<import
16
19
  onSearchFocus?: () => void;
17
20
  onSearchBlur?: () => void;
18
21
  onSearchClick?: () => void;
19
- inlineCategoryTabs?: import("../../CategoryTabs/CategoryTabs.types").CategoryTabsProps;
20
22
  }>;