@ubnt/store.core 9.58.0-new-design → 9.58.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.
- package/CHANGELOG.md +1 -116
- package/lib/_virtual/_virtual_multi-entry.js +10 -13
- package/lib/_virtual/_virtual_multi-entry.js.map +1 -1
- package/lib/_virtual/_virtual_multi-entry.mjs +11 -13
- package/lib/_virtual/_virtual_multi-entry.mjs.map +1 -1
- package/lib/apis/smartcat.d.ts +2 -12
- package/lib/apis/smartcat.js +4 -27
- package/lib/apis/smartcat.js.map +1 -1
- package/lib/apis/smartcat.mjs +4 -27
- package/lib/apis/smartcat.mjs.map +1 -1
- package/lib/assets/close2.svg +3 -2
- package/lib/assets/close3.svg +2 -3
- package/lib/assets/icons/menu/{icon-location-pin.svg.js → icon-globe.svg.js} +6 -6
- package/lib/assets/icons/menu/icon-globe.svg.js.map +1 -0
- package/lib/assets/icons/menu/icon-globe.svg.mjs +3 -0
- package/lib/assets/icons/menu/icon-globe.svg.mjs.map +1 -0
- package/lib/assets/logoUnifi.svg +2 -10
- package/lib/assets/pause.svg +3 -3
- package/lib/assets/pause2.svg +3 -3
- package/lib/assets/udmPro.jpg +0 -0
- package/lib/assets/udmPro2.jpg +0 -0
- package/lib/assets/udmProMax.jpg +0 -0
- package/lib/assets/udmProMax2.jpg +0 -0
- package/lib/assets/udmProSpecial.jpg +0 -0
- package/lib/assets/udmProSpecial2.jpg +0 -0
- package/lib/components/Accordion/Accordion.js +4 -4
- package/lib/components/Avatar/Avatar.js +2 -2
- package/lib/components/BackInStock/BackInStock.types.d.ts +0 -1
- package/lib/components/Button/Button.js +5 -12
- package/lib/components/Button/Button.js.map +1 -1
- package/lib/components/Button/Button.mjs +1 -8
- package/lib/components/Button/Button.mjs.map +1 -1
- package/lib/components/Button/CartButton.d.ts +1 -3
- package/lib/components/Button/CartButton.js +6 -11
- package/lib/components/Button/CartButton.js.map +1 -1
- package/lib/components/Button/CartButton.mjs +4 -8
- package/lib/components/Button/CartButton.mjs.map +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.d.ts +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.js +9 -16
- package/lib/components/ButtonGroup/ButtonGroup.js.map +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.mjs +9 -16
- package/lib/components/ButtonGroup/ButtonGroup.mjs.map +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.styles.d.ts +6 -10
- package/lib/components/ButtonGroup/ButtonGroup.styles.js +20 -60
- package/lib/components/ButtonGroup/ButtonGroup.styles.js.map +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.styles.mjs +20 -60
- package/lib/components/ButtonGroup/ButtonGroup.styles.mjs.map +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.types.d.ts +0 -5
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.d.ts +1 -1
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.js +4 -16
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.js.map +1 -1
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.mjs +5 -17
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.mjs.map +1 -1
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.d.ts +1 -5
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.js +17 -82
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.js.map +1 -1
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.mjs +17 -82
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.mjs.map +1 -1
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.types.d.ts +0 -4
- package/lib/components/CardSection/Card/Card.js +6 -6
- package/lib/components/CardSection/CardSection.js +2 -2
- package/lib/components/CardSection/CardSection.styles.d.ts +1 -1
- package/lib/components/CartIcon/CartIcon.js +2 -2
- package/lib/components/CategoryTabs/CategoryTabs.styles.d.ts +2 -4
- package/lib/components/CategoryTabs/CategoryTabs.styles.js +5 -8
- package/lib/components/CategoryTabs/CategoryTabs.styles.js.map +1 -1
- package/lib/components/CategoryTabs/CategoryTabs.styles.mjs +6 -7
- package/lib/components/CategoryTabs/CategoryTabs.styles.mjs.map +1 -1
- package/lib/components/Checkbox/Checkbox.js +4 -4
- package/lib/components/CloserLookSection/CloserLookSection.js +11 -11
- package/lib/components/CloserLookSection/RecommendedAddons/RecommendedAddons.js +5 -5
- package/lib/components/Compare/Compare.styles.d.ts +5 -5
- package/lib/components/Container/Container.d.ts +1 -1
- package/lib/components/Container/Container.js +4 -5
- package/lib/components/Container/Container.js.map +1 -1
- package/lib/components/Container/Container.mjs +4 -5
- package/lib/components/Container/Container.mjs.map +1 -1
- package/lib/components/Container/index.stories.d.ts +5 -5
- package/lib/components/CustomImage/CustomImage.js +12 -12
- package/lib/components/Explore/Explore.js +5 -5
- package/lib/components/Explore/ExploreData.js +12 -12
- package/lib/components/Explore/ExploreData.js.map +1 -1
- package/lib/components/Explore/ExploreData.mjs +12 -12
- package/lib/components/Explore/ExploreData.mjs.map +1 -1
- package/lib/components/FeaturesSection_deprecated/Features/Features.js +2 -2
- package/lib/components/FeaturesSection_deprecated/FeaturesSection.js +23 -23
- package/lib/components/FeaturesSection_deprecated/FeaturesSection.mjs +1 -1
- package/lib/components/FeaturesSection_deprecated/assets/close.svg.js +1 -1
- package/lib/components/FeaturesSection_deprecated/assets/close.svg.mjs +2 -2
- package/lib/components/Footer/Footer.js +2 -2
- package/lib/components/Footer/hooks/useFooterContent.js +5 -5
- package/lib/components/Gallery/Gallery.context.js +17 -17
- package/lib/components/Gallery/Gallery.js +9 -9
- package/lib/components/Gallery/GalleryControls/GalleryControls.js +4 -4
- package/lib/components/Gallery/GalleryItem/GalleryItem.js +8 -8
- package/lib/components/Gallery/GalleryThumbnails/GalleryThumbnails.js +8 -8
- package/lib/components/GridGallery/GridGallery.js +8 -8
- package/lib/components/GridGallery/GridModal/GridModal.js +6 -6
- package/lib/components/Header/AccountFrame/AccountFrame.js +11 -11
- package/lib/components/Header/AccountFrame/Mobile/Mobile.js +4 -4
- package/lib/components/Header/AccountMenu/AccountMenu.js +20 -30
- package/lib/components/Header/AccountMenu/AccountMenu.js.map +1 -1
- package/lib/components/Header/AccountMenu/AccountMenu.mjs +3 -13
- package/lib/components/Header/AccountMenu/AccountMenu.mjs.map +1 -1
- package/lib/components/Header/CartModal/Empty/Empty.js +3 -3
- package/lib/components/Header/CartModalV2/CartModal.js +5 -5
- package/lib/components/Header/CartModalV2/Item/Item.js +4 -4
- package/lib/components/Header/CartModalV2/Item/Item.styles.d.ts +1 -1
- package/lib/components/Header/Header.js +43 -43
- package/lib/components/Header/Header.js.map +1 -1
- package/lib/components/Header/Header.mjs +9 -9
- package/lib/components/Header/Header.mjs.map +1 -1
- package/lib/components/Header/Header.styles.d.ts +12 -7
- package/lib/components/Header/Header.styles.js +32 -10
- package/lib/components/Header/Header.styles.js.map +1 -1
- package/lib/components/Header/Header.styles.mjs +31 -10
- package/lib/components/Header/Header.styles.mjs.map +1 -1
- package/lib/components/Header/Header.types.d.ts +5 -29
- package/lib/components/Header/Header.types.js +1 -2
- package/lib/components/Header/Header.types.js.map +1 -1
- package/lib/components/Header/Header.types.mjs +1 -2
- package/lib/components/Header/Header.types.mjs.map +1 -1
- package/lib/components/Header/IsolatedHeader.d.ts +0 -1
- package/lib/components/Header/IsolatedHeader.js +50 -50
- package/lib/components/Header/IsolatedHeader.js.map +1 -1
- package/lib/components/Header/IsolatedHeader.mjs +46 -47
- package/lib/components/Header/IsolatedHeader.mjs.map +1 -1
- package/lib/components/Header/LanguageFrame/LanguageFrame.js +6 -6
- package/lib/components/Header/MenuItem/MenuItem.styles.d.ts +1 -1
- package/lib/components/Header/MenuItem/MenuItem.styles.js +3 -3
- package/lib/components/Header/MenuItem/MenuItem.styles.js.map +1 -1
- package/lib/components/Header/MenuItem/MenuItem.styles.mjs +3 -3
- package/lib/components/Header/MenuItem/MenuItem.styles.mjs.map +1 -1
- package/lib/components/Header/MenuItem/MenuItem.types.d.ts +0 -1
- package/lib/components/Header/Navigation/Carousel/Carousel.js +5 -5
- package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.js +12 -12
- package/lib/components/Header/Navigation/MicrositeMenu/MicrositeMenu.styles.d.ts +1 -1
- package/lib/components/Header/Navigation/MobileMenu/MobileMenu.js +6 -6
- package/lib/components/Header/Navigation/MobileMenu/MobileMenu.styles.d.ts +1 -1
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.d.ts +1 -1
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.js +109 -116
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.js.map +1 -1
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.mjs +104 -111
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.mjs.map +1 -1
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.d.ts +0 -9
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.js +1 -15
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.js.map +1 -1
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.mjs +2 -13
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.mjs.map +1 -1
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.types.d.ts +6 -12
- package/lib/components/Header/Overlay/Overlay.js +3 -3
- package/lib/components/Header/ProHeader/ProHeader.d.ts +5 -9
- package/lib/components/Header/ProHeader/ProHeader.js +189 -270
- package/lib/components/Header/ProHeader/ProHeader.js.map +1 -1
- package/lib/components/Header/ProHeader/ProHeader.mjs +171 -251
- package/lib/components/Header/ProHeader/ProHeader.mjs.map +1 -1
- package/lib/components/Header/ProHeader/ProHeader.styles.d.ts +25 -30
- package/lib/components/Header/ProHeader/ProHeader.styles.js +66 -119
- package/lib/components/Header/ProHeader/ProHeader.styles.js.map +1 -1
- package/lib/components/Header/ProHeader/ProHeader.styles.mjs +65 -112
- package/lib/components/Header/ProHeader/ProHeader.styles.mjs.map +1 -1
- package/lib/components/Header/translations/ar.json.js +1 -4
- package/lib/components/Header/translations/ar.json.js.map +1 -1
- package/lib/components/Header/translations/ar.json.mjs +2 -4
- package/lib/components/Header/translations/ar.json.mjs.map +1 -1
- package/lib/components/Header/translations/de.json.js +1 -4
- package/lib/components/Header/translations/de.json.js.map +1 -1
- package/lib/components/Header/translations/de.json.mjs +2 -4
- package/lib/components/Header/translations/de.json.mjs.map +1 -1
- package/lib/components/Header/translations/el.json.js +1 -4
- package/lib/components/Header/translations/el.json.js.map +1 -1
- package/lib/components/Header/translations/el.json.mjs +2 -4
- package/lib/components/Header/translations/el.json.mjs.map +1 -1
- package/lib/components/Header/translations/en.json.js +1 -7
- package/lib/components/Header/translations/en.json.js.map +1 -1
- package/lib/components/Header/translations/en.json.mjs +2 -6
- package/lib/components/Header/translations/en.json.mjs.map +1 -1
- package/lib/components/Header/translations/es.json.js +1 -4
- package/lib/components/Header/translations/es.json.js.map +1 -1
- package/lib/components/Header/translations/es.json.mjs +2 -4
- package/lib/components/Header/translations/es.json.mjs.map +1 -1
- package/lib/components/Header/translations/fr.json.js +1 -4
- package/lib/components/Header/translations/fr.json.js.map +1 -1
- package/lib/components/Header/translations/fr.json.mjs +2 -4
- package/lib/components/Header/translations/fr.json.mjs.map +1 -1
- package/lib/components/Header/translations/it.json.js +1 -4
- package/lib/components/Header/translations/it.json.js.map +1 -1
- package/lib/components/Header/translations/it.json.mjs +2 -4
- package/lib/components/Header/translations/it.json.mjs.map +1 -1
- package/lib/components/Header/translations/ja.json.js +1 -4
- package/lib/components/Header/translations/ja.json.js.map +1 -1
- package/lib/components/Header/translations/ja.json.mjs +2 -4
- package/lib/components/Header/translations/ja.json.mjs.map +1 -1
- package/lib/components/Header/translations/pt-BR.json.js +1 -4
- package/lib/components/Header/translations/pt-BR.json.js.map +1 -1
- package/lib/components/Header/translations/pt-BR.json.mjs +2 -4
- package/lib/components/Header/translations/pt-BR.json.mjs.map +1 -1
- package/lib/components/Header/translations/zh-Hans.json.js +1 -4
- package/lib/components/Header/translations/zh-Hans.json.js.map +1 -1
- package/lib/components/Header/translations/zh-Hans.json.mjs +2 -4
- package/lib/components/Header/translations/zh-Hans.json.mjs.map +1 -1
- package/lib/components/Header/translations/zh-Hant-TW.json.js +1 -4
- package/lib/components/Header/translations/zh-Hant-TW.json.js.map +1 -1
- package/lib/components/Header/translations/zh-Hant-TW.json.mjs +2 -4
- package/lib/components/Header/translations/zh-Hant-TW.json.mjs.map +1 -1
- package/lib/components/Hero/Hero.js +5 -5
- package/lib/components/Hero/Hero.styles.d.ts +2 -2
- package/lib/components/HeroFadeGallery/HeroFadeGallery.styles.d.ts +1 -1
- package/lib/components/HeroVideo/HeroVideo.js +5 -5
- package/lib/components/HowToUseSection/HowToUseSection.styles.d.ts +2 -2
- package/lib/components/ImageCarousel/ImageCarousel.js +30 -30
- package/lib/components/ImageSequence/ImageSequence.js +8 -8
- package/lib/components/LandingPage/Cards/Card/Card.js +4 -4
- package/lib/components/LandingPage/Cards/Cards.js +10 -10
- package/lib/components/LandingPage/LandingPage.js +2 -2
- package/lib/components/LandingPagePro/LandingPagePro.js +13 -13
- package/lib/components/LandingPagePro/LandingPagePro.styles.d.ts +1 -1
- package/lib/components/LandingPageSearch/LandingPageSearch.js +2 -2
- package/lib/components/LandingPageSearch/Modal/Modal.js +9 -9
- package/lib/components/LandingPageSidebar/LandingPageSidebar.js +12 -12
- package/lib/components/LayoutRenderer/LayoutRenderer.js +8 -8
- package/lib/components/LayoutRenderer/LayoutRenderer.styles.d.ts +1 -1
- package/lib/components/LayoutRendererV1/LayoutRenderer.styles.d.ts +3 -3
- package/lib/components/LayoutRendererV2/LayoutRenderer.styles.d.ts +3 -3
- package/lib/components/LoaderDots/LoaderDots.d.ts +1 -1
- package/lib/components/LoaderDots/LoaderDots.js +1 -3
- package/lib/components/LoaderDots/LoaderDots.js.map +1 -1
- package/lib/components/LoaderDots/LoaderDots.mjs +1 -3
- package/lib/components/LoaderDots/LoaderDots.mjs.map +1 -1
- package/lib/components/LoaderDots/LoaderDots.styles.d.ts +1 -2
- package/lib/components/LoaderDots/LoaderDots.styles.js +1 -11
- package/lib/components/LoaderDots/LoaderDots.styles.js.map +1 -1
- package/lib/components/LoaderDots/LoaderDots.styles.mjs +1 -11
- package/lib/components/LoaderDots/LoaderDots.styles.mjs.map +1 -1
- package/lib/components/LoaderDots/LoaderDots.types.d.ts +0 -2
- package/lib/components/MeetUniFiVideoPlayer/EpisodeCard/EpisodeCard.js +7 -7
- package/lib/components/MeetUniFiVideoPlayer/MeetUniFiVideoPlayer.js +18 -18
- package/lib/components/MeetUniFiVideoPlayer/MeetUniFiVideoPlayer.styles.d.ts +1 -1
- package/lib/components/MicrositeColumnFeatureProgressBar/MicrositeColumnFeatureProgressBar.js +2 -2
- package/lib/components/MicrositeFeatureChecklist/MicrositeFeatureChecklist.js +3 -3
- package/lib/components/MicrositeFeatureProgressBar/MicrositeFeatureProgressBar.js +3 -3
- package/lib/components/MicrositeHero/MicrositeHero.js +18 -18
- package/lib/components/MicrositeIntroductionBlock/MicrositeIntroductionBlock.js +4 -4
- package/lib/components/MicrositeMediaGrid/MicrositeMediaGrid.js +9 -9
- package/lib/components/MicrositeProductGrid/MicrositeProductGrid.js +8 -8
- package/lib/components/MicrositeProductLearnMoreBlock/MicrositeProductLearnMoreBlockWrap.js +2 -2
- package/lib/components/MicrositeSectionWrap/MicrositeSectionWrap.styles.d.ts +1 -1
- package/lib/components/MicrositeSubSubNavigation/MicrositeSubSubNavigation.js +3 -3
- package/lib/components/MicrositeVideoSlideshow/MicrositeVideoSlideshow.js +13 -13
- package/lib/components/MicrositeVideoSlideshow/MicrositeVideoSlideshow.mjs +1 -1
- package/lib/components/MicrositeVideoSlideshow/assets/pause.svg.js +1 -1
- package/lib/components/MicrositeVideoSlideshow/assets/pause.svg.mjs +2 -2
- package/lib/components/Microsites/MicrositePageContext.js +2 -2
- package/lib/components/Microsites/MicrositeProductPage.js +3 -3
- package/lib/components/Microsites/context/MicrositeProductPageContext.js +3 -3
- package/lib/components/MobileModal/MobileModal.js +4 -4
- package/lib/components/Modal/Modal.js +3 -3
- package/lib/components/ModelCompareV3/ModelCompareOverflowScrollButton.js +3 -3
- package/lib/components/ModelCompareV3/ModelComparePropertyValueGridItem.js +2 -2
- package/lib/components/ModelCompareV3/ModelCompareV3.js +14 -14
- package/lib/components/ModelCompareV3/ProductGroupsGrid.js +3 -3
- package/lib/components/ModelCompareV3/ScrollGroup/ScrollGroup.js +5 -5
- package/lib/components/ModelCompareV3/ScrollGroup/context.js +3 -3
- package/lib/components/ModelCompareV3/ScrollGroup/useScrollGroupItem.js +8 -8
- package/lib/components/ModelCompareV3/ScrollGroup/useScrollGroupSetScroll.js +2 -2
- package/lib/components/ModelCompareV3/ScrollGroup/useScrollGroupTo.js +2 -2
- package/lib/components/ModelCompareV3/StickyGrid/StickyGrid.js +7 -7
- package/lib/components/ModelCompareV3/StickyGrid/StickyGridBody.js +2 -2
- package/lib/components/ModelCompareV3/StickyGrid/StickyGridHeader.js +5 -5
- package/lib/components/ModelCompareV3/StickyGrid/StickyGridItem.js +2 -2
- package/lib/components/ModelCompareV3/StickyGrid/context.js +3 -3
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmPro.jpg.js +5 -5
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmPro.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProMax.jpg.js +5 -5
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProMax.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProSpecial.jpg.js +5 -5
- package/lib/components/ModelCompareV3/assets/Consoles/bigCompare/udmProSpecial.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/udmPro.jpg.js +1 -1
- package/lib/components/ModelCompareV3/assets/Consoles/udmPro.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/udmProMax.jpg.js +1 -1
- package/lib/components/ModelCompareV3/assets/Consoles/udmProMax.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/assets/Consoles/udmProSpecial.jpg.js +1 -1
- package/lib/components/ModelCompareV3/assets/Consoles/udmProSpecial.jpg.mjs +2 -2
- package/lib/components/ModelCompareV3/data/CloudGateways.js +9 -9
- package/lib/components/ModelCompareV3/data/CloudGateways.mjs +6 -6
- package/lib/components/ModelCompareV3/data/products/cloudKeyEnterprise.js +2 -4
- package/lib/components/ModelCompareV3/data/products/cloudKeyEnterprise.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/cloudKeyEnterprise.mjs +2 -4
- package/lib/components/ModelCompareV3/data/products/cloudKeyEnterprise.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/cloudKeyG2Plus.js +2 -2
- package/lib/components/ModelCompareV3/data/products/cloudKeyG2Plus.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/cloudKeyG2Plus.mjs +2 -2
- package/lib/components/ModelCompareV3/data/products/cloudKeyG2Plus.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/express.js +3 -3
- package/lib/components/ModelCompareV3/data/products/express.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/express.mjs +3 -3
- package/lib/components/ModelCompareV3/data/products/express.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayEnterprise.js +2 -4
- package/lib/components/ModelCompareV3/data/products/gatewayEnterprise.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayEnterprise.mjs +2 -4
- package/lib/components/ModelCompareV3/data/products/gatewayEnterprise.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayLite.js +2 -4
- package/lib/components/ModelCompareV3/data/products/gatewayLite.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayLite.mjs +2 -4
- package/lib/components/ModelCompareV3/data/products/gatewayLite.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayMax.js +2 -4
- package/lib/components/ModelCompareV3/data/products/gatewayMax.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayMax.mjs +2 -4
- package/lib/components/ModelCompareV3/data/products/gatewayMax.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayProfessional.js +2 -4
- package/lib/components/ModelCompareV3/data/products/gatewayProfessional.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayProfessional.mjs +2 -4
- package/lib/components/ModelCompareV3/data/products/gatewayProfessional.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/officialUniFiHosting.js +1 -3
- package/lib/components/ModelCompareV3/data/products/officialUniFiHosting.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/officialUniFiHosting.mjs +1 -3
- package/lib/components/ModelCompareV3/data/products/officialUniFiHosting.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/ucgMax.js +1 -1
- package/lib/components/ModelCompareV3/data/products/ucgMax.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/ucgMax.mjs +1 -1
- package/lib/components/ModelCompareV3/data/products/ucgMax.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/ucgUltra.js +3 -3
- package/lib/components/ModelCompareV3/data/products/ucgUltra.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/ucgUltra.mjs +3 -3
- package/lib/components/ModelCompareV3/data/products/ucgUltra.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/udmPro.js +4 -4
- package/lib/components/ModelCompareV3/data/products/udmPro.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/udmPro.mjs +4 -4
- package/lib/components/ModelCompareV3/data/products/udmPro.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/udmProMax.js +4 -4
- package/lib/components/ModelCompareV3/data/products/udmProMax.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/udmProMax.mjs +4 -4
- package/lib/components/ModelCompareV3/data/products/udmProMax.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/udmProSpecial.js +4 -4
- package/lib/components/ModelCompareV3/data/products/udmProSpecial.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/udmProSpecial.mjs +4 -4
- package/lib/components/ModelCompareV3/data/products/udmProSpecial.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/udr.js +41 -5
- package/lib/components/ModelCompareV3/data/products/udr.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/udr.mjs +21 -5
- package/lib/components/ModelCompareV3/data/products/udr.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/udw.js +3 -3
- package/lib/components/ModelCompareV3/data/products/udw.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/udw.mjs +3 -3
- package/lib/components/ModelCompareV3/data/products/udw.mjs.map +1 -1
- package/lib/components/Pagination/Pagination.js +3 -3
- package/lib/components/PriceRangeSlider/PriceRangeSlider.js +16 -16
- package/lib/components/ProductCard/ProductCard.js +7 -7
- package/lib/components/ProductCardPopup/ProductCardPopup.js +8 -8
- package/lib/components/ProductCompare/ProductCompare.js +7 -7
- package/lib/components/ProductDetails/ProductDetails.js +5 -5
- package/lib/components/ProductGrid/ProductGrid.js +10 -10
- package/lib/components/ProductKeyFeatures/ProductKeyFeatures.js +3 -3
- package/lib/components/ProductSectionNavigation/ProductSectionNavigation.styles.d.ts +1 -1
- package/lib/components/ProductSectionNavigationV2/ProductSectionNavigation.styles.d.ts +1 -1
- package/lib/components/ProductSectionTabs/ProductSectionTabs.js +2 -2
- package/lib/components/ProductTechSpecs/ProductTechSpecs.styles.d.ts +2 -2
- package/lib/components/ProductWizard/Options/Options.js +3 -3
- package/lib/components/ProductWizard/ProductWizard.js +2 -2
- package/lib/components/ProductWizardFootnotes/ProductWizardFootnotes.js +5 -5
- package/lib/components/ProgressCircle/ProgressCircle.js +4 -4
- package/lib/components/QuantityControls/QuantityControls.js +6 -6
- package/lib/components/QuantityControls/QuantityControls.js.map +1 -1
- package/lib/components/QuantityControls/QuantityControls.mjs +2 -2
- package/lib/components/QuantityControls/QuantityControls.mjs.map +1 -1
- package/lib/components/QuantityControls/QuantityControls.types.d.ts +1 -1
- package/lib/components/QuantityInput/QuantityInput.js +1 -6
- package/lib/components/QuantityInput/QuantityInput.js.map +1 -1
- package/lib/components/QuantityInput/QuantityInput.mjs +1 -6
- package/lib/components/QuantityInput/QuantityInput.mjs.map +1 -1
- package/lib/components/RelatedProducts/RelatedProducts.js +5 -5
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.js +36 -36
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/DeviceSelect/DeviceSelect.js +12 -12
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputCard.js +5 -5
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/CheckboxSection.js +2 -2
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/CounterSection.js +4 -4
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/SliderSection.js +3 -3
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/ProgressBarChart/ProgressBarChart.js +7 -7
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/useComputeResourceCalculator.js +6 -6
- package/lib/components/ResourceCalculatorV1/PoeCalculator/PoeCalculator.js +9 -9
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerConfigurator.js +10 -10
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.js +15 -15
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/RecommendedPoeSwitches/RecommendedPoeSwitches.js +2 -2
- package/lib/components/ResourceCalculatorV1/ResourceCalculator.js +6 -6
- package/lib/components/ReverseLoopingVideo/ReverseLoopingVideo.js +5 -5
- package/lib/components/ScrollWrapper/ScrollWrapper.d.ts +1 -1
- package/lib/components/ScrollWrapper/ScrollWrapper.js +25 -33
- package/lib/components/ScrollWrapper/ScrollWrapper.js.map +1 -1
- package/lib/components/ScrollWrapper/ScrollWrapper.mjs +8 -16
- package/lib/components/ScrollWrapper/ScrollWrapper.mjs.map +1 -1
- package/lib/components/ScrollWrapper/ScrollWrapper.types.d.ts +0 -2
- package/lib/components/Search/Input/Input.d.ts +1 -1
- package/lib/components/Search/Input/Input.js +8 -8
- package/lib/components/Search/Input/Input.js.map +1 -1
- package/lib/components/Search/Input/Input.mjs +4 -4
- package/lib/components/Search/Input/Input.mjs.map +1 -1
- package/lib/components/Search/Input/Input.styles.js +1 -0
- package/lib/components/Search/Input/Input.styles.js.map +1 -1
- package/lib/components/Search/Input/Input.styles.mjs +1 -0
- package/lib/components/Search/Input/Input.styles.mjs.map +1 -1
- package/lib/components/Search/Input/Input.types.d.ts +2 -3
- package/lib/components/Search/Modal/Modal.js +3 -3
- package/lib/components/StorageSliders/Slider/Slider.js +3 -3
- package/lib/components/StorageSliders/StorageSliders.context.js +20 -20
- package/lib/components/StorageSliders/StorageSliders.js +4 -4
- package/lib/components/Tooltip/Tooltip.js +5 -5
- package/lib/components/VariantSelector/Variant/Compatibility/Compatibility.js +7 -7
- package/lib/components/VariantSelector/Variant/Variant.js +40 -40
- package/lib/components/VariantSelector/VariantSelector.js +16 -16
- package/lib/components/VideoPlayerNew/VideoPlayer.js +21 -21
- package/lib/components/VideoPlayerNew/VideoPlayer.mjs +2 -2
- package/lib/components/VideoPlayerNew/assets/close.svg.js +1 -1
- package/lib/components/VideoPlayerNew/assets/close.svg.mjs +2 -2
- package/lib/components/VideoPlayerNew/assets/pause.svg.js +1 -1
- package/lib/components/VideoPlayerNew/assets/pause.svg.mjs +2 -2
- package/lib/components/index.d.ts +0 -1
- package/lib/components/index.js +0 -2
- package/lib/components/index.js.map +1 -1
- package/lib/components/index.mjs +0 -2
- package/lib/components/index.mjs.map +1 -1
- package/lib/constants/proStoreCategories/mapping/filters.d.ts +0 -17
- package/lib/constants/proStoreCategories/mapping/filters.js +0 -17
- package/lib/constants/proStoreCategories/mapping/filters.js.map +1 -1
- package/lib/constants/proStoreCategories/mapping/filters.mjs +0 -17
- package/lib/constants/proStoreCategories/mapping/filters.mjs.map +1 -1
- package/lib/constants/proStoreCategories/mapping/index.d.ts +2 -4
- package/lib/constants/proStoreCategories/mapping/index.js +51 -50
- package/lib/constants/proStoreCategories/mapping/index.js.map +1 -1
- package/lib/constants/proStoreCategories/mapping/index.mjs +49 -49
- package/lib/constants/proStoreCategories/mapping/index.mjs.map +1 -1
- package/lib/constants/proStoreCategories/mapping/mapping.d.ts +0 -5
- package/lib/constants/proStoreCategories/mapping/redirects.js +3 -18
- package/lib/constants/proStoreCategories/mapping/redirects.js.map +1 -1
- package/lib/constants/proStoreCategories/mapping/redirects.mjs +3 -18
- package/lib/constants/proStoreCategories/mapping/redirects.mjs.map +1 -1
- package/lib/constants/proStoreCategories/mapping/unifi.d.ts +9 -9
- package/lib/constants/proStoreCategories/mapping/unifi.js +9 -9
- package/lib/constants/proStoreCategories/mapping/unifi.js.map +1 -1
- package/lib/constants/proStoreCategories/mapping/unifi.mjs +9 -9
- package/lib/constants/proStoreCategories/mapping/unifi.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/ar.json.js +3 -7
- package/lib/constants/proStoreCategories/translations/ar.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/ar.json.mjs +4 -7
- package/lib/constants/proStoreCategories/translations/ar.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/de.json.js +3 -7
- package/lib/constants/proStoreCategories/translations/de.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/de.json.mjs +4 -7
- package/lib/constants/proStoreCategories/translations/de.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/el.json.js +3 -7
- package/lib/constants/proStoreCategories/translations/el.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/el.json.mjs +4 -7
- package/lib/constants/proStoreCategories/translations/el.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/en.json.js +3 -7
- package/lib/constants/proStoreCategories/translations/en.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/en.json.mjs +4 -7
- package/lib/constants/proStoreCategories/translations/en.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/es.json.js +3 -7
- package/lib/constants/proStoreCategories/translations/es.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/es.json.mjs +4 -7
- package/lib/constants/proStoreCategories/translations/es.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/fr.json.js +3 -7
- package/lib/constants/proStoreCategories/translations/fr.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/fr.json.mjs +4 -7
- package/lib/constants/proStoreCategories/translations/fr.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/it.json.js +3 -7
- package/lib/constants/proStoreCategories/translations/it.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/it.json.mjs +4 -7
- package/lib/constants/proStoreCategories/translations/it.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/ja.json.js +3 -7
- package/lib/constants/proStoreCategories/translations/ja.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/ja.json.mjs +4 -7
- package/lib/constants/proStoreCategories/translations/ja.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/pt-BR.json.js +3 -7
- package/lib/constants/proStoreCategories/translations/pt-BR.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/pt-BR.json.mjs +4 -7
- package/lib/constants/proStoreCategories/translations/pt-BR.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/zh-Hans.json.js +3 -7
- package/lib/constants/proStoreCategories/translations/zh-Hans.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/zh-Hans.json.mjs +4 -7
- package/lib/constants/proStoreCategories/translations/zh-Hans.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.js +3 -7
- package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.mjs +4 -7
- package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.mjs.map +1 -1
- package/lib/constants/proStoreFilters/mapping.d.ts +3 -55
- package/lib/constants/proStoreFilters/mapping.js +10 -140
- package/lib/constants/proStoreFilters/mapping.js.map +1 -1
- package/lib/constants/proStoreFilters/mapping.mjs +10 -140
- package/lib/constants/proStoreFilters/mapping.mjs.map +1 -1
- package/lib/constants/theme.js +0 -4
- package/lib/constants/theme.js.map +1 -1
- package/lib/constants/theme.mjs +0 -4
- package/lib/constants/theme.mjs.map +1 -1
- package/lib/contexts/MenuContext/context.js +34 -34
- package/lib/contexts/MenuContext/context.js.map +1 -1
- package/lib/contexts/MenuContext/context.mjs +1 -1
- package/lib/contexts/MenuContext/context.mjs.map +1 -1
- package/lib/contexts/MenuContext/mapping.js.map +1 -1
- package/lib/contexts/MenuContext/mapping.mjs.map +1 -1
- package/lib/helpers/index.js +0 -1
- package/lib/helpers/index.js.map +1 -1
- package/lib/helpers/index.mjs +1 -1
- package/lib/helpers/proStoreCategories.js +2 -2
- package/lib/helpers/ux.d.ts +0 -8
- package/lib/helpers/ux.js +0 -15
- package/lib/helpers/ux.js.map +1 -1
- package/lib/helpers/ux.mjs +1 -15
- package/lib/helpers/ux.mjs.map +1 -1
- package/lib/hooks/useHasTouch.js +3 -3
- package/lib/hooks/useHddRetentionCalculator.js +5 -5
- package/lib/hooks/useHorizontalScroll.js +2 -2
- package/lib/hooks/useLockBodyScrollCustom.js +3 -3
- package/lib/hooks/useScrollToY.js +2 -2
- package/lib/hooks/useTestMediaElementVolumeSetter.js +3 -3
- package/lib/hooks/useTranslation.js +6 -6
- package/lib/utils/nextjs/ssr/registry.js +2 -2
- package/package.json +1 -1
- package/lib/assets/cart-secondary.svg +0 -5
- package/lib/assets/icon-location-pin.svg +0 -5
- package/lib/assets/icons/cart-secondary.svg.js +0 -27
- package/lib/assets/icons/cart-secondary.svg.js.map +0 -1
- package/lib/assets/icons/cart-secondary.svg.mjs +0 -3
- package/lib/assets/icons/cart-secondary.svg.mjs.map +0 -1
- package/lib/assets/icons/menu/icon-location-pin.svg.js.map +0 -1
- package/lib/assets/icons/menu/icon-location-pin.svg.mjs +0 -3
- package/lib/assets/icons/menu/icon-location-pin.svg.mjs.map +0 -1
- package/lib/components/ButtonGroupBasic/index.stories.d.ts +0 -6
- package/lib/components/Header/Header.stories.d.ts +0 -111
- package/lib/components/Header/LogoIcon/LogoIcon.d.ts +0 -7
- package/lib/components/Header/LogoIcon/LogoIcon.js +0 -46
- package/lib/components/Header/LogoIcon/LogoIcon.js.map +0 -1
- package/lib/components/Header/LogoIcon/LogoIcon.mjs +0 -36
- package/lib/components/Header/LogoIcon/LogoIcon.mjs.map +0 -1
- package/lib/components/Header/LogoIcon/index.d.ts +0 -1
- package/lib/components/Header/LogoIcon/index.js +0 -6
- package/lib/components/Header/LogoIcon/index.js.map +0 -1
- package/lib/components/Header/LogoIcon/index.mjs +0 -3
- package/lib/components/Header/LogoIcon/index.mjs.map +0 -1
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.d.ts +0 -2
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.js +0 -81
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.js.map +0 -1
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.mjs +0 -73
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.mjs.map +0 -1
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.stories.d.ts +0 -5
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.styles.d.ts +0 -11
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.styles.js +0 -80
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.styles.js.map +0 -1
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.styles.mjs +0 -66
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.styles.mjs.map +0 -1
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.types.d.ts +0 -12
- package/lib/components/ProductTechSpecsV2/index.d.ts +0 -1
- package/lib/components/ProductTechSpecsV2/index.js +0 -6
- package/lib/components/ProductTechSpecsV2/index.js.map +0 -1
- package/lib/components/ProductTechSpecsV2/index.mjs +0 -3
- package/lib/components/ProductTechSpecsV2/index.mjs.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Input.styles.mjs","sources":["../../../../src/components/Search/Input/Input.styles.ts"],"sourcesContent":["import type { Motif } from \"@ubnt/ui-components/utils\";\nimport styled, { css } from \"styled-components\";\n\nimport { BREAKPOINTS } from \"../../../constants/layout\";\nimport { theme } from \"../../../constants/theme\";\n\nexport const SearchInputContainer = styled.div<{\n height?: number;\n width?: number;\n transparent?: boolean;\n motif: Motif;\n}>`\n position: relative;\n display: flex;\n height: ${({ height }) => (height ? `${height}px` : \"32px\")};\n align-items: center;\n flex-wrap: nowrap;\n max-width: ${({ width }) => (width ? `${width}px` : \"100%\")};\n width: 100%;\n`;\n\nexport const IconWrap = styled.div<{\n show: boolean;\n motif: Motif;\n active?: boolean;\n}>`\n display: flex;\n align-items: center;\n margin: 0 8px;\n visibility: ${(props) => (props.show ? \"visible\" : \"hidden\")};\n color: ${({ motif, active }) =>\n active\n ? theme.colors.menu.active[motif]\n : motif === \"dark\"\n ? \"#909090\"\n : theme.colors.menu.text[motif]};\n`;\n\nexport const CancelIconWrap = styled(IconWrap)`\n cursor: pointer;\n`;\n\nexport const IconAfterWrap = styled.div`\n display: flex;\n justify-content: flex-end;\n align-items: center;\n gap: 10px;\n`;\n\nexport const InputWrap = styled.div<{\n transparent?: boolean;\n}>`\n display: flex;\n width: 100%;\n border-radius: 4px;\n background-color: ${theme.colors.athensGreyLight};\n height: 100%;\n padding: 0 8px;\n border: 1px solid ${theme.colors.mischka};\n\n /* &:hover {\n background-color: ${theme.colors.athensGreyLight};\n } */\n\n ${({ transparent }) =>\n transparent &&\n css`\n &,\n &:hover {\n background-color: transparent;\n }\n `}\n`;\n\nexport const Input = styled.input<{\n motif: Motif;\n}>`\n border: 0;\n width: 100%;\n background-color: transparent;\n color: ${({ motif }) =>\n motif === \"dark\" ? theme.colors.athensGreyLight : theme.colors.black65};\n padding: 0 8px;\n font-size: 14px;\n\n caret-color: ${theme.colors.primaryBlue};\n text-overflow: ellipsis;\n\n ::placeholder {\n color: ${({ motif }) =>\n motif === \"dark\" ? \"hsla(0,0%,100%,.45)\" : theme.colors.black45};\n font-size: 14px;\n }\n\n &:focus {\n outline: none;\n }\n\n @media ${BREAKPOINTS.MOBILE_AND_DOWN} {\n /** @see https://stackoverflow.com/a/7655319 */\n font-size: ${theme.font.size16};\n }\n`;\n"],"names":["SearchInputContainer","styled","div","height","width","IconWrap","props","show","motif","active","theme","colors","menu","text","CancelIconWrap","IconAfterWrap","InputWrap","athensGreyLight","mischka","transparent","css","Input","input","black65","primaryBlue","black45","BREAKPOINTS","MOBILE_AND_DOWN","font","size16"],"mappings":";;;;AAMO,MAAMA,uBAAuBC,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA,
|
|
1
|
+
{"version":3,"file":"Input.styles.mjs","sources":["../../../../src/components/Search/Input/Input.styles.ts"],"sourcesContent":["import type { Motif } from \"@ubnt/ui-components/utils\";\nimport styled, { css } from \"styled-components\";\n\nimport { BREAKPOINTS } from \"../../../constants/layout\";\nimport { theme } from \"../../../constants/theme\";\n\nexport const SearchInputContainer = styled.div<{\n height?: number;\n width?: number;\n transparent?: boolean;\n motif: Motif;\n}>`\n position: relative;\n display: flex;\n overflow: hidden;\n height: ${({ height }) => (height ? `${height}px` : \"32px\")};\n align-items: center;\n flex-wrap: nowrap;\n max-width: ${({ width }) => (width ? `${width}px` : \"100%\")};\n width: 100%;\n`;\n\nexport const IconWrap = styled.div<{\n show: boolean;\n motif: Motif;\n active?: boolean;\n}>`\n display: flex;\n align-items: center;\n margin: 0 8px;\n visibility: ${(props) => (props.show ? \"visible\" : \"hidden\")};\n color: ${({ motif, active }) =>\n active\n ? theme.colors.menu.active[motif]\n : motif === \"dark\"\n ? \"#909090\"\n : theme.colors.menu.text[motif]};\n`;\n\nexport const CancelIconWrap = styled(IconWrap)`\n cursor: pointer;\n`;\n\nexport const IconAfterWrap = styled.div`\n display: flex;\n justify-content: flex-end;\n align-items: center;\n gap: 10px;\n`;\n\nexport const InputWrap = styled.div<{\n transparent?: boolean;\n}>`\n display: flex;\n width: 100%;\n border-radius: 4px;\n background-color: ${theme.colors.athensGreyLight};\n height: 100%;\n padding: 0 8px;\n border: 1px solid ${theme.colors.mischka};\n\n /* &:hover {\n background-color: ${theme.colors.athensGreyLight};\n } */\n\n ${({ transparent }) =>\n transparent &&\n css`\n &,\n &:hover {\n background-color: transparent;\n }\n `}\n`;\n\nexport const Input = styled.input<{\n motif: Motif;\n}>`\n border: 0;\n width: 100%;\n background-color: transparent;\n color: ${({ motif }) =>\n motif === \"dark\" ? theme.colors.athensGreyLight : theme.colors.black65};\n padding: 0 8px;\n font-size: 14px;\n\n caret-color: ${theme.colors.primaryBlue};\n text-overflow: ellipsis;\n\n ::placeholder {\n color: ${({ motif }) =>\n motif === \"dark\" ? \"hsla(0,0%,100%,.45)\" : theme.colors.black45};\n font-size: 14px;\n }\n\n &:focus {\n outline: none;\n }\n\n @media ${BREAKPOINTS.MOBILE_AND_DOWN} {\n /** @see https://stackoverflow.com/a/7655319 */\n font-size: ${theme.font.size16};\n }\n`;\n"],"names":["SearchInputContainer","styled","div","height","width","IconWrap","props","show","motif","active","theme","colors","menu","text","CancelIconWrap","IconAfterWrap","InputWrap","athensGreyLight","mischka","transparent","css","Input","input","black65","primaryBlue","black45","BREAKPOINTS","MOBILE_AND_DOWN","font","size16"],"mappings":";;;;AAMO,MAAMA,uBAAuBC,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA,YAS/B,CAAC;EAAEC;AAAO,CAAA,KAAOA,SAAS,GAAGA,MAAM,OAAO,MAAO;AAAA;AAAA;AAAA,eAG9C,CAAC;EAAEC;AAAM,CAAA,KAAOA,QAAQ,GAAGA,KAAK,OAAO,MAAO;AAAA;AAAA,CAAA;AAItD,MAAMC,WAAWJ,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA,gBAQdI,KAAA,IAAWA,KAAM,CAAAC,IAAA,GAAO,YAAY,QAAS;AAAA,WACnD,CAAC;EAAEC,KAAO;EAAAC;MACjBA,MACI,GAAAC,KAAA,CAAMC,OAAOC,IAAK,CAAAH,MAAA,CAAOD,KAAK,CAC9B,GAAAA,KAAA,KAAU,SACR,SACA,GAAAE,KAAA,CAAMC,OAAOC,IAAK,CAAAC,IAAA,CAAKL,KAAK,CAAC;AAAA,CAAA;AAG1B,MAAAM,cAAA,GAAiBb,OAAOI,QAAQ,CAAA;AAAA;AAAA,CAAA;AAItC,MAAMU,gBAAgBd,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAO7B,MAAMc,YAAYf,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA,sBAMVQ,KAAA,CAAMC,OAAOM,eAAe;AAAA;AAAA;AAAA,sBAG5BP,KAAA,CAAMC,OAAOO,OAAO;AAAA;AAAA;AAAA,wBAGlBR,KAAA,CAAMC,OAAOM,eAAe;AAAA;AAAA;AAAA,IAGhD,CAAC;EAAEE;CAAY,KACfA,WACA,IAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,KAKC;AAAA,CAAA;AAGE,MAAMC,QAAQpB,MAAO,CAAAqB,KAAA;AAAA;AAAA;AAAA;AAAA,WAMjB,CAAC;EAAEd;CACV,KAAAA,KAAA,KAAU,MAAS,GAAAE,KAAA,CAAMC,MAAO,CAAAM,eAAA,GAAkBP,KAAM,CAAAC,MAAA,CAAOY,OAAO;AAAA;AAAA;AAAA;AAAA,iBAIzDb,KAAA,CAAMC,OAAOa,WAAW;AAAA;AAAA;AAAA;AAAA,aAI5B,CAAC;EAAEhB;AAAM,CAAA,KAChBA,UAAU,MAAS,GAAA,qBAAA,GAAwBE,KAAM,CAAAC,MAAA,CAAOc,OAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,WAQ1DC,YAAYC,eAAe;AAAA;AAAA,iBAErBjB,KAAA,CAAMkB,KAAKC,MAAM;AAAA;AAAA,CAAA;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { Motif } from "@ubnt/ui-components/utils";
|
|
2
|
-
import type { ChangeEventHandler, FocusEventHandler, KeyboardEventHandler, MouseEventHandler,
|
|
2
|
+
import type { ChangeEventHandler, Dispatch, FocusEventHandler, KeyboardEventHandler, MouseEventHandler, SetStateAction } from "react";
|
|
3
3
|
export interface SearchInputProps {
|
|
4
4
|
value: string;
|
|
5
5
|
onValueChange: ChangeEventHandler<HTMLInputElement>;
|
|
@@ -11,10 +11,9 @@ export interface SearchInputProps {
|
|
|
11
11
|
onFocus?: FocusEventHandler<HTMLInputElement>;
|
|
12
12
|
onBlur?: FocusEventHandler<HTMLInputElement>;
|
|
13
13
|
onKeyPress?: KeyboardEventHandler<HTMLInputElement>;
|
|
14
|
-
setInputRef?:
|
|
14
|
+
setInputRef?: Dispatch<SetStateAction<HTMLInputElement | null>>;
|
|
15
15
|
motif?: Motif;
|
|
16
16
|
transparent?: boolean;
|
|
17
17
|
loading?: boolean;
|
|
18
18
|
className?: string;
|
|
19
|
-
children?: ReactNode;
|
|
20
19
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
|
-
var
|
|
4
|
+
var react = require('react');
|
|
5
5
|
require('../../../assets/icons/carouselArrow.svg.js');
|
|
6
6
|
require('../../CustomImage/index.js');
|
|
7
7
|
require('../../Loader/index.js');
|
|
@@ -29,8 +29,8 @@ const SearchModal = function SearchModal2({
|
|
|
29
29
|
search,
|
|
30
30
|
mobileMenu
|
|
31
31
|
}) {
|
|
32
|
-
const noResults =
|
|
33
|
-
const showSearchResultsLink =
|
|
32
|
+
const noResults = react.useMemo(() => !search.loading && !search.items?.length && !!formattedQuerySearchTerm, [formattedQuerySearchTerm, search.items?.length, search.loading]);
|
|
33
|
+
const showSearchResultsLink = react.useMemo(() => search.totalItemsCount > MAX_SEARCH_RESULTS, [search]);
|
|
34
34
|
return /* @__PURE__ */jsxRuntime.jsxs(Modal_styles.Container, {
|
|
35
35
|
center: !!(search.loading || noResults),
|
|
36
36
|
mobileMenu,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
|
-
var
|
|
4
|
+
var react = require('react');
|
|
5
5
|
var Slider_styles = require('./Slider.styles.js');
|
|
6
6
|
"use strict";
|
|
7
7
|
const StorageSlidersSlider = function StorageSlidersSlider2({
|
|
@@ -11,14 +11,14 @@ const StorageSlidersSlider = function StorageSlidersSlider2({
|
|
|
11
11
|
min = 0,
|
|
12
12
|
max = 100
|
|
13
13
|
}) {
|
|
14
|
-
const handleOnChange =
|
|
14
|
+
const handleOnChange = react.useCallback(e => {
|
|
15
15
|
if (disabled) return;
|
|
16
16
|
const newValue = parseInt(e.target.value);
|
|
17
17
|
if (!Number.isNaN(newValue)) {
|
|
18
18
|
onChange?.(newValue);
|
|
19
19
|
}
|
|
20
20
|
}, [disabled, onChange]);
|
|
21
|
-
const thumbLeftPercent =
|
|
21
|
+
const thumbLeftPercent = react.useMemo(() => {
|
|
22
22
|
return (value - min) / (max - min) * 100;
|
|
23
23
|
}, [max, min, value]);
|
|
24
24
|
return /* @__PURE__ */jsxRuntime.jsxs(Slider_styles.Wrap, {
|
|
@@ -1,35 +1,35 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
|
-
var
|
|
4
|
+
var react = require('react');
|
|
5
5
|
var StorageSliders_constants = require('./StorageSliders.constants.js');
|
|
6
6
|
var StorageSliders_types = require('./StorageSliders.types.js');
|
|
7
7
|
var StorageSliders_utils = require('./StorageSliders.utils.js');
|
|
8
8
|
"use strict";
|
|
9
|
-
const StorageSlidersContext =
|
|
9
|
+
const StorageSlidersContext = react.createContext(null);
|
|
10
10
|
const StorageSlidersProvider = ({
|
|
11
11
|
hddTerabytes = 8,
|
|
12
12
|
sku,
|
|
13
13
|
children
|
|
14
14
|
}) => {
|
|
15
|
-
const data =
|
|
15
|
+
const data = react.useMemo(() => {
|
|
16
16
|
return StorageSliders_constants.storageSlidersDataBySku[sku] ?? null;
|
|
17
17
|
}, [sku]);
|
|
18
|
-
const [cameraType, setCameraType] =
|
|
19
|
-
const [cameras, setCameras] =
|
|
20
|
-
const [hours, setHours] =
|
|
21
|
-
const reset =
|
|
18
|
+
const [cameraType, setCameraType] = react.useState(StorageSliders_types.CameraType.Camera2K);
|
|
19
|
+
const [cameras, setCameras] = react.useState(0);
|
|
20
|
+
const [hours, setHours] = react.useState(0);
|
|
21
|
+
const reset = react.useCallback(() => {
|
|
22
22
|
setCameraType(StorageSliders_types.CameraType.Camera2K);
|
|
23
23
|
setCameras(0);
|
|
24
24
|
setHours(0);
|
|
25
25
|
}, []);
|
|
26
|
-
const cameraTypeData =
|
|
26
|
+
const cameraTypeData = react.useMemo(() => {
|
|
27
27
|
return data?.cameraTypeData[cameraType] ?? null;
|
|
28
28
|
}, [cameraType, data?.cameraTypeData]);
|
|
29
|
-
const maxCameras =
|
|
29
|
+
const maxCameras = react.useMemo(() => {
|
|
30
30
|
return cameraTypeData?.maxCameras ?? 0;
|
|
31
31
|
}, [cameraTypeData?.maxCameras]);
|
|
32
|
-
const storageHoursPerHdd =
|
|
32
|
+
const storageHoursPerHdd = react.useMemo(() => {
|
|
33
33
|
if (!data?.maxHdds || !cameraTypeData?.powerUsage || !cameras) {
|
|
34
34
|
return [];
|
|
35
35
|
}
|
|
@@ -58,7 +58,7 @@ const StorageSlidersProvider = ({
|
|
|
58
58
|
storageHours.reverse();
|
|
59
59
|
return storageHours;
|
|
60
60
|
}, [cameraTypeData?.powerUsage, cameras, data?.maxHdds, hddTerabytes]);
|
|
61
|
-
const maxHours =
|
|
61
|
+
const maxHours = react.useMemo(() => {
|
|
62
62
|
if (!data?.maxHdds || !cameraTypeData?.powerUsage) {
|
|
63
63
|
return 0;
|
|
64
64
|
}
|
|
@@ -70,7 +70,7 @@ const StorageSlidersProvider = ({
|
|
|
70
70
|
terabytes: hddTerabytes
|
|
71
71
|
});
|
|
72
72
|
}, [cameraTypeData?.powerUsage, cameras, data?.maxHdds, hddTerabytes]);
|
|
73
|
-
|
|
73
|
+
react.useEffect(() => {
|
|
74
74
|
if (hours > maxHours) {
|
|
75
75
|
setHours(maxHours);
|
|
76
76
|
}
|
|
@@ -78,21 +78,21 @@ const StorageSlidersProvider = ({
|
|
|
78
78
|
setCameras(maxCameras);
|
|
79
79
|
}
|
|
80
80
|
}, [cameras, hours, maxCameras, maxHours]);
|
|
81
|
-
const hdds =
|
|
81
|
+
const hdds = react.useMemo(() => {
|
|
82
82
|
if (!storageHoursPerHdd || !cameras || !hours) {
|
|
83
83
|
return 0;
|
|
84
84
|
}
|
|
85
85
|
const item = [...storageHoursPerHdd].reverse().find(el => el.hours <= hours);
|
|
86
86
|
return item?.hdds ?? 1;
|
|
87
87
|
}, [cameras, hours, storageHoursPerHdd]);
|
|
88
|
-
const [queuedSetHdds, setQueuedSetHdds] =
|
|
89
|
-
const handleSetHdds =
|
|
88
|
+
const [queuedSetHdds, setQueuedSetHdds] = react.useState();
|
|
89
|
+
const handleSetHdds = react.useCallback(count => {
|
|
90
90
|
if (!cameras) {
|
|
91
91
|
setCameras(1);
|
|
92
92
|
}
|
|
93
93
|
setQueuedSetHdds(count);
|
|
94
94
|
}, [cameras]);
|
|
95
|
-
|
|
95
|
+
react.useEffect(() => {
|
|
96
96
|
if (queuedSetHdds == null) return;
|
|
97
97
|
const item = storageHoursPerHdd.find(({
|
|
98
98
|
hdds: hdds2
|
|
@@ -100,7 +100,7 @@ const StorageSlidersProvider = ({
|
|
|
100
100
|
setHours(item?.hours ?? 0);
|
|
101
101
|
setQueuedSetHdds(void 0);
|
|
102
102
|
}, [queuedSetHdds, storageHoursPerHdd]);
|
|
103
|
-
const handleSetCameras =
|
|
103
|
+
const handleSetCameras = react.useCallback(value2 => {
|
|
104
104
|
if (hours === 0 && value2 > 0) {
|
|
105
105
|
setHours(1);
|
|
106
106
|
} else if (value2 === 0) {
|
|
@@ -108,13 +108,13 @@ const StorageSlidersProvider = ({
|
|
|
108
108
|
}
|
|
109
109
|
setCameras(value2);
|
|
110
110
|
}, [hours]);
|
|
111
|
-
const handleSetHours =
|
|
111
|
+
const handleSetHours = react.useCallback(value2 => {
|
|
112
112
|
if (cameras === 0 && value2 > 0) {
|
|
113
113
|
setCameras(1);
|
|
114
114
|
}
|
|
115
115
|
setHours(value2);
|
|
116
116
|
}, [cameras]);
|
|
117
|
-
const value =
|
|
117
|
+
const value = react.useMemo(() => {
|
|
118
118
|
return {
|
|
119
119
|
cameraType,
|
|
120
120
|
setCameraType,
|
|
@@ -137,7 +137,7 @@ const StorageSlidersProvider = ({
|
|
|
137
137
|
});
|
|
138
138
|
};
|
|
139
139
|
function useStorageSliders() {
|
|
140
|
-
const context =
|
|
140
|
+
const context = react.useContext(StorageSlidersContext);
|
|
141
141
|
if (context === null) {
|
|
142
142
|
throw new Error("useStorageSliders must be used within a StorageSlidersProvider");
|
|
143
143
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
4
|
var merge = require('lodash/merge');
|
|
5
|
-
var
|
|
5
|
+
var react = require('react');
|
|
6
6
|
var reactUse = require('react-use');
|
|
7
7
|
require('./Slider/index.js');
|
|
8
8
|
var StorageSliders_constants = require('./StorageSliders.constants.js');
|
|
@@ -23,7 +23,7 @@ const StorageSliders = function StorageSliders2({
|
|
|
23
23
|
translations: initialTranslations,
|
|
24
24
|
disabled
|
|
25
25
|
}) {
|
|
26
|
-
const translations =
|
|
26
|
+
const translations = react.useMemo(() => {
|
|
27
27
|
return merge__default["default"](StorageSliders_constants.defaultStorageSlidersTranslations, initialTranslations);
|
|
28
28
|
}, [initialTranslations]);
|
|
29
29
|
const {
|
|
@@ -40,9 +40,9 @@ const StorageSliders = function StorageSliders2({
|
|
|
40
40
|
maxHdds,
|
|
41
41
|
hddTerabytes
|
|
42
42
|
} = StorageSliders_context.useStorageSliders();
|
|
43
|
-
const [localHours, setLocalHours] =
|
|
43
|
+
const [localHours, setLocalHours] = react.useState(hours);
|
|
44
44
|
reactUse.useDebounce(() => setHours(localHours), 5, [localHours]);
|
|
45
|
-
const [storageItemHoverIndex, setStorageItemHoverIndex] =
|
|
45
|
+
const [storageItemHoverIndex, setStorageItemHoverIndex] = react.useState(null);
|
|
46
46
|
return /* @__PURE__ */jsxRuntime.jsxs(StorageSliders_styles.Wrap, {
|
|
47
47
|
className,
|
|
48
48
|
children: [/* @__PURE__ */jsxRuntime.jsxs(StorageSliders_styles.SlidersContainer, {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
|
-
var
|
|
4
|
+
var react = require('react');
|
|
5
5
|
var reactUse = require('react-use');
|
|
6
6
|
var Tooltip_styles = require('./Tooltip.styles.js');
|
|
7
7
|
"use strict";
|
|
@@ -10,13 +10,13 @@ const Tooltip = ({
|
|
|
10
10
|
tooltipClassName,
|
|
11
11
|
...rest
|
|
12
12
|
}) => {
|
|
13
|
-
const target =
|
|
14
|
-
const tooltipRef =
|
|
13
|
+
const target = react.useRef(null);
|
|
14
|
+
const tooltipRef = react.useRef(null);
|
|
15
15
|
const {
|
|
16
16
|
y: scrollY
|
|
17
17
|
} = reactUse.useWindowScroll();
|
|
18
|
-
const [isOpen, setIsOpen] =
|
|
19
|
-
|
|
18
|
+
const [isOpen, setIsOpen] = react.useState();
|
|
19
|
+
react.useEffect(() => {
|
|
20
20
|
setIsOpen(false);
|
|
21
21
|
}, [
|
|
22
22
|
// HACK: needed scrollY to retrigger the effect
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
4
|
var LineLoader = require('@ubnt/ui-components/LineLoader');
|
|
5
5
|
var Tooltip = require('@ubnt/ui-components/Tooltip');
|
|
6
|
-
var
|
|
6
|
+
var react = require('react');
|
|
7
7
|
var reactUse = require('react-use');
|
|
8
8
|
require('../../../../assets/icons/carouselArrow.svg.js');
|
|
9
9
|
var layout = require('../../../../constants/layout.js');
|
|
@@ -24,13 +24,13 @@ const VariantCompatibility = ({
|
|
|
24
24
|
compatibleProducts,
|
|
25
25
|
hideBottomSeparator
|
|
26
26
|
}) => {
|
|
27
|
-
const [canExpand, setCanExpand] =
|
|
28
|
-
const [isExpanded, setIsExpanded] =
|
|
29
|
-
const overflowRef =
|
|
27
|
+
const [canExpand, setCanExpand] = react.useState(false);
|
|
28
|
+
const [isExpanded, setIsExpanded] = react.useState(false);
|
|
29
|
+
const overflowRef = react.useRef(null);
|
|
30
30
|
const {
|
|
31
31
|
width: windowWidth
|
|
32
32
|
} = reactUse.useWindowSize();
|
|
33
|
-
|
|
33
|
+
react.useEffect(() => {
|
|
34
34
|
const overflowEl = overflowRef.current;
|
|
35
35
|
if (!overflowEl) return;
|
|
36
36
|
const canvas = document.createElement("canvas");
|
|
@@ -51,7 +51,7 @@ const VariantCompatibility = ({
|
|
|
51
51
|
children: [/* @__PURE__ */jsxRuntime.jsxs(Compatibility_styles.TextOverflow, {
|
|
52
52
|
ref: overflowRef,
|
|
53
53
|
$overflow: compatibleProducts.length > 1,
|
|
54
|
-
children: ["Compatibility", !isExpanded && ": ", !isExpanded && compatibleProducts.map((product, i, els) => /* @__PURE__ */jsxRuntime.jsxs(
|
|
54
|
+
children: ["Compatibility", !isExpanded && ": ", !isExpanded && compatibleProducts.map((product, i, els) => /* @__PURE__ */jsxRuntime.jsxs(react.Fragment, {
|
|
55
55
|
children: [/* @__PURE__ */jsxRuntime.jsx(CompatibleProductLink, {
|
|
56
56
|
renderImage,
|
|
57
57
|
product
|
|
@@ -84,7 +84,7 @@ const CompatibleProductLink = ({
|
|
|
84
84
|
product
|
|
85
85
|
}) => {
|
|
86
86
|
const isMobile = reactUse.useMedia(layout.BREAKPOINTS.MOBILE_AND_DOWN, false);
|
|
87
|
-
const [loading, setLoading] =
|
|
87
|
+
const [loading, setLoading] = react.useState(false);
|
|
88
88
|
return /* @__PURE__ */jsxRuntime.jsx(Tooltip.Tooltip, {
|
|
89
89
|
className: Compatibility_styles.TOOLTIP_CLASS_NAME,
|
|
90
90
|
motif: "light",
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
4
|
var dinero_js = require('dinero.js');
|
|
5
|
-
var
|
|
5
|
+
var react = require('react');
|
|
6
6
|
require('../../../assets/icons/reload.svg.js');
|
|
7
7
|
var url = require('../../../constants/url.js');
|
|
8
8
|
require('../../../utils/money/index.js');
|
|
@@ -70,37 +70,37 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
70
70
|
backInStockProps,
|
|
71
71
|
getEndPrice
|
|
72
72
|
}) {
|
|
73
|
-
const handleOnClick =
|
|
73
|
+
const handleOnClick = react.useCallback(() => {
|
|
74
74
|
if (!selected) {
|
|
75
75
|
onClick?.();
|
|
76
76
|
}
|
|
77
77
|
}, [onClick, selected]);
|
|
78
|
-
const subtitle =
|
|
78
|
+
const subtitle = react.useMemo(() => {
|
|
79
79
|
if (selected) {
|
|
80
80
|
return variant.getSkuText(variant$1.sku || variant$1.baseSku, variant$1.skuExtraLabel);
|
|
81
81
|
}
|
|
82
82
|
return variant$1.callout;
|
|
83
83
|
}, [selected, variant$1.baseSku, variant$1.callout, variant$1.sku, variant$1.skuExtraLabel]);
|
|
84
|
-
const [localQuantity, setLocalQuantity] =
|
|
85
|
-
const [localUpsellQuantity, setLocalUpsellQuantity] =
|
|
86
|
-
const endVariantPrice =
|
|
84
|
+
const [localQuantity, setLocalQuantity] = react.useState(DEFAULT_LOCAL_QUANTITY);
|
|
85
|
+
const [localUpsellQuantity, setLocalUpsellQuantity] = react.useState(DEFAULT_LOCAL_UPSELL_QUANTITY);
|
|
86
|
+
const endVariantPrice = react.useMemo(() => {
|
|
87
87
|
return getEndPrice(variant$1.displayPrice);
|
|
88
88
|
}, [getEndPrice, variant$1.displayPrice]);
|
|
89
|
-
const [showUpsellModal, setShowUpsellModal] =
|
|
89
|
+
const [showUpsellModal, setShowUpsellModal] = react.useState(false);
|
|
90
90
|
const {
|
|
91
91
|
reset: resetStorageSliders,
|
|
92
92
|
hdds,
|
|
93
93
|
setHdds
|
|
94
94
|
} = StorageSliders_context.useStorageSliders();
|
|
95
|
-
|
|
95
|
+
react.useEffect(() => {
|
|
96
96
|
setLocalUpsellQuantity(hdds * localQuantity);
|
|
97
97
|
}, [hdds, localQuantity]);
|
|
98
|
-
const handleUpsellReset =
|
|
98
|
+
const handleUpsellReset = react.useCallback(() => {
|
|
99
99
|
setLocalUpsellQuantity(DEFAULT_LOCAL_UPSELL_QUANTITY);
|
|
100
100
|
resetStorageSliders();
|
|
101
101
|
}, [resetStorageSliders]);
|
|
102
|
-
const [bundleOfferSelected, setBundleOfferSelected] =
|
|
103
|
-
|
|
102
|
+
const [bundleOfferSelected, setBundleOfferSelected] = react.useState(false);
|
|
103
|
+
react.useEffect(() => {
|
|
104
104
|
const bundleOffer = variant$1.bundleOffer;
|
|
105
105
|
let selected2 = !!bundleOffer?.preSelect;
|
|
106
106
|
if (bundleOffer?.requiresLogin || bundleOffer?.remainingRedeemQty === 0) {
|
|
@@ -108,20 +108,20 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
108
108
|
}
|
|
109
109
|
setBundleOfferSelected(selected2);
|
|
110
110
|
}, [variant$1.bundleOffer]);
|
|
111
|
-
const bundleOfferQuantity =
|
|
111
|
+
const bundleOfferQuantity = react.useMemo(() => {
|
|
112
112
|
if (!variant$1.bundleOffer || !bundleOfferSelected) {
|
|
113
113
|
return 0;
|
|
114
114
|
}
|
|
115
115
|
return getBundleOfferQuantity.getBundleOfferQuantity(variant$1.bundleOffer, localQuantity);
|
|
116
116
|
}, [bundleOfferSelected, localQuantity, variant$1.bundleOffer]);
|
|
117
|
-
|
|
117
|
+
react.useEffect(() => {
|
|
118
118
|
setLocalQuantity(DEFAULT_LOCAL_QUANTITY);
|
|
119
119
|
handleUpsellReset();
|
|
120
120
|
}, [handleUpsellReset,
|
|
121
121
|
// HACK: needed selected to retrigger the effect
|
|
122
122
|
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
123
123
|
selected]);
|
|
124
|
-
const handleAddToCart =
|
|
124
|
+
const handleAddToCart = react.useCallback(async () => {
|
|
125
125
|
if (localQuantity < 1) return;
|
|
126
126
|
const addItems = [{
|
|
127
127
|
variantId: variant$1.variantId,
|
|
@@ -143,14 +143,14 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
143
143
|
setLocalQuantity(DEFAULT_LOCAL_QUANTITY);
|
|
144
144
|
handleUpsellReset();
|
|
145
145
|
}, [handleUpsellReset, bundleOfferQuantity, localQuantity, localUpsellQuantity, onVariantAddToCart, variant$1.bundleOffer, variant$1.upsellVariant, variant$1.variantId]);
|
|
146
|
-
const [popupProduct, setPopupProduct] =
|
|
147
|
-
const isPopupOpen =
|
|
148
|
-
|
|
146
|
+
const [popupProduct, setPopupProduct] = react.useState(variant$1.inlineAccessories?.activePopupProduct);
|
|
147
|
+
const isPopupOpen = react.useMemo(() => !!variant$1.inlineAccessories?.activePopupProduct, [variant$1.inlineAccessories?.activePopupProduct]);
|
|
148
|
+
react.useEffect(() => {
|
|
149
149
|
if (variant$1.inlineAccessories?.activePopupProduct !== void 0) {
|
|
150
150
|
setPopupProduct(variant$1.inlineAccessories?.activePopupProduct);
|
|
151
151
|
}
|
|
152
152
|
}, [variant$1.inlineAccessories?.activePopupProduct]);
|
|
153
|
-
const campaignDiscountPrice =
|
|
153
|
+
const campaignDiscountPrice = react.useMemo(() => {
|
|
154
154
|
const {
|
|
155
155
|
displayPrice,
|
|
156
156
|
campaignDiscount
|
|
@@ -165,10 +165,10 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
165
165
|
}
|
|
166
166
|
return misc.money(discountAllocation);
|
|
167
167
|
}, [localQuantity, variant$1]);
|
|
168
|
-
const endCampaignDiscountPrice =
|
|
168
|
+
const endCampaignDiscountPrice = react.useMemo(() => {
|
|
169
169
|
return campaignDiscountPrice && getEndPrice(campaignDiscountPrice);
|
|
170
170
|
}, [campaignDiscountPrice, getEndPrice]);
|
|
171
|
-
const campaignUpsellDiscountPrice =
|
|
171
|
+
const campaignUpsellDiscountPrice = react.useMemo(() => {
|
|
172
172
|
if (!variant$1.upsellVariant) {
|
|
173
173
|
return null;
|
|
174
174
|
}
|
|
@@ -181,10 +181,10 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
181
181
|
const multipliedPrice = dinero_js.multiply(misc.getDinero(campaignDiscount.fixedAmountPrice, campaignDiscount.fixedAmountCurrency), campaignDiscount.maxProductQty ? Math.min(localUpsellQuantity, campaignDiscount.maxProductQty) : localUpsellQuantity);
|
|
182
182
|
return misc.money(multipliedPrice);
|
|
183
183
|
}, [localUpsellQuantity, variant$1.upsellVariant]);
|
|
184
|
-
const endCampaignUpsellDiscountPrice =
|
|
184
|
+
const endCampaignUpsellDiscountPrice = react.useMemo(() => {
|
|
185
185
|
return campaignUpsellDiscountPrice && getEndPrice(campaignUpsellDiscountPrice);
|
|
186
186
|
}, [campaignUpsellDiscountPrice, getEndPrice]);
|
|
187
|
-
const totalPrice =
|
|
187
|
+
const totalPrice = react.useMemo(() => {
|
|
188
188
|
const {
|
|
189
189
|
displayPrice,
|
|
190
190
|
upsellVariant,
|
|
@@ -204,13 +204,13 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
204
204
|
});
|
|
205
205
|
return misc.money(dinero_js.add(dinero_js.add(dinero_js.add(variantPriceTotalWithDiscount, upsellPriceTotalWithDiscount), inlineAccessoriesPriceTotal), bundleOfferPriceTotal));
|
|
206
206
|
}, [campaignDiscountPrice, campaignUpsellDiscountPrice, bundleOfferQuantity, localQuantity, localUpsellQuantity, variant$1]);
|
|
207
|
-
const originalPrice =
|
|
207
|
+
const originalPrice = react.useMemo(() => {
|
|
208
208
|
return variant$1.originalPrice && getEndPrice(variant$1.originalPrice);
|
|
209
209
|
}, [getEndPrice, variant$1.originalPrice]);
|
|
210
|
-
const savedPrice =
|
|
210
|
+
const savedPrice = react.useMemo(() => {
|
|
211
211
|
return !!originalPrice && originalPrice.price.currency === endVariantPrice.price.currency && originalPrice.price.amount > endVariantPrice.price.amount ? dinero_js.subtract(misc.getDinero(originalPrice.price.amount, originalPrice.price.currency), misc.getDinero(endVariantPrice.price.amount, endVariantPrice.price.currency)) : null;
|
|
212
212
|
}, [originalPrice, endVariantPrice.price.currency, endVariantPrice.price.amount]);
|
|
213
|
-
const jsxVariantFooter =
|
|
213
|
+
const jsxVariantFooter = react.useMemo(() => {
|
|
214
214
|
const showBackInStock = !!backInStockProps && (!variant$1.isInStock || !!variant$1.isSoldOut || !!variant$1.isComingSoon);
|
|
215
215
|
const showTotalPrice = totalPrice.amount !== variant$1.displayPrice.amount;
|
|
216
216
|
const cartButton = {
|
|
@@ -276,16 +276,16 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
276
276
|
})]
|
|
277
277
|
});
|
|
278
278
|
}, [backInStockProps, variant$1.isInStock, variant$1.isSoldOut, variant$1.isComingSoon, variant$1.comingSoonDate, variant$1.isSubscription, variant$1.isRegionNotAvailable, variant$1.displayPrice.amount, localQuantity, translations, totalPrice, wizardProps, handleAddToCart, getEndPrice]);
|
|
279
|
-
const getActiveCategoryItems =
|
|
279
|
+
const getActiveCategoryItems = react.useCallback(items => {
|
|
280
280
|
return items.find(categorySubItem => activeCategories?.includes(categorySubItem.id))?.items || [];
|
|
281
281
|
}, [activeCategories]);
|
|
282
|
-
const secondLevelCategories =
|
|
282
|
+
const secondLevelCategories = react.useMemo(() => {
|
|
283
283
|
if (!variant$1?.category?.items?.length) {
|
|
284
284
|
return void 0;
|
|
285
285
|
}
|
|
286
286
|
return variant$1?.category?.items;
|
|
287
287
|
}, [variant$1?.category?.items]);
|
|
288
|
-
const secondLevelNavigation =
|
|
288
|
+
const secondLevelNavigation = react.useMemo(() => {
|
|
289
289
|
if (!secondLevelCategories) {
|
|
290
290
|
return void 0;
|
|
291
291
|
}
|
|
@@ -307,13 +307,13 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
307
307
|
}
|
|
308
308
|
};
|
|
309
309
|
}, [activeCategories, categoryChangeHandler, secondLevelCategories, variant$1.isInStock]);
|
|
310
|
-
const thirdLevelCategories =
|
|
310
|
+
const thirdLevelCategories = react.useMemo(() => {
|
|
311
311
|
if (secondLevelCategories) {
|
|
312
312
|
return getActiveCategoryItems(secondLevelCategories);
|
|
313
313
|
}
|
|
314
314
|
return void 0;
|
|
315
315
|
}, [getActiveCategoryItems, secondLevelCategories]);
|
|
316
|
-
const thirdLevelButtons =
|
|
316
|
+
const thirdLevelButtons = react.useMemo(() => {
|
|
317
317
|
if (!thirdLevelCategories) {
|
|
318
318
|
return void 0;
|
|
319
319
|
}
|
|
@@ -327,13 +327,13 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
327
327
|
onClick: categoryChangeHandler
|
|
328
328
|
};
|
|
329
329
|
}, [activeCategories, categoryChangeHandler, thirdLevelCategories]);
|
|
330
|
-
const fourthLevelCategories =
|
|
330
|
+
const fourthLevelCategories = react.useMemo(() => {
|
|
331
331
|
if (thirdLevelCategories) {
|
|
332
332
|
return getActiveCategoryItems(thirdLevelCategories);
|
|
333
333
|
}
|
|
334
334
|
return void 0;
|
|
335
335
|
}, [thirdLevelCategories, getActiveCategoryItems]);
|
|
336
|
-
const fourthLevelButtons =
|
|
336
|
+
const fourthLevelButtons = react.useMemo(() => {
|
|
337
337
|
if (!fourthLevelCategories) {
|
|
338
338
|
return void 0;
|
|
339
339
|
}
|
|
@@ -347,13 +347,13 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
347
347
|
onClick: categoryChangeHandler
|
|
348
348
|
};
|
|
349
349
|
}, [activeCategories, categoryChangeHandler, fourthLevelCategories]);
|
|
350
|
-
const title =
|
|
350
|
+
const title = react.useMemo(() => {
|
|
351
351
|
if (!variant$1?.category?.title || selected) {
|
|
352
352
|
return variant$1.title;
|
|
353
353
|
}
|
|
354
354
|
return variant$1.category.title;
|
|
355
355
|
}, [selected, variant$1?.category?.title, variant$1.title]);
|
|
356
|
-
const price =
|
|
356
|
+
const price = react.useMemo(() => {
|
|
357
357
|
const endPrice = endVariantPrice;
|
|
358
358
|
const endFromPrice = variant$1?.fromPrice && getEndPrice(variant$1.fromPrice);
|
|
359
359
|
const price2 = endPrice.formattedPrice;
|
|
@@ -367,7 +367,7 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
367
367
|
totalWithTax: priceWithTaxString
|
|
368
368
|
};
|
|
369
369
|
}, [selected, translations, variant$1.fromPrice, variant$1.isSubscription, endVariantPrice, getEndPrice]);
|
|
370
|
-
const image =
|
|
370
|
+
const image = react.useMemo(() => {
|
|
371
371
|
const variantImages = variant$1.images?.filter(image2 => !image2.isVideo);
|
|
372
372
|
const foundVariantImage = variantImages?.find(image2 => variant$1?.currentVariantGalleryIds?.includes(image2.id));
|
|
373
373
|
if (foundVariantImage) {
|
|
@@ -375,7 +375,7 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
375
375
|
}
|
|
376
376
|
return variantImages?.[0];
|
|
377
377
|
}, [variant$1?.currentVariantGalleryIds, variant$1.images]);
|
|
378
|
-
const handleInlineAccessoriesCheckbox =
|
|
378
|
+
const handleInlineAccessoriesCheckbox = react.useCallback(accessory => {
|
|
379
379
|
if (accessory.isSelected) {
|
|
380
380
|
accessory.handleSelect(0);
|
|
381
381
|
} else {
|
|
@@ -383,13 +383,13 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
383
383
|
accessory.handleSelect(quantity);
|
|
384
384
|
}
|
|
385
385
|
}, [localQuantity]);
|
|
386
|
-
|
|
386
|
+
react.useEffect(() => {
|
|
387
387
|
const uiCareAccessory = variant$1?.inlineAccessories?.items?.find(accessory => accessory.isUICare);
|
|
388
388
|
if (uiCareAccessory?.isSelected) {
|
|
389
389
|
uiCareAccessory.handleSelect(localQuantity);
|
|
390
390
|
}
|
|
391
391
|
}, [localQuantity]);
|
|
392
|
-
const jsxDiscount =
|
|
392
|
+
const jsxDiscount = react.useMemo(() => {
|
|
393
393
|
const {
|
|
394
394
|
campaignDiscount,
|
|
395
395
|
shortTitle
|
|
@@ -416,7 +416,7 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
416
416
|
})]
|
|
417
417
|
});
|
|
418
418
|
}, [endCampaignDiscountPrice, localQuantity, translations, variant$1]);
|
|
419
|
-
const jsxUpsellDiscount =
|
|
419
|
+
const jsxUpsellDiscount = react.useMemo(() => {
|
|
420
420
|
if (!variant$1.upsellVariant) {
|
|
421
421
|
return null;
|
|
422
422
|
}
|
|
@@ -453,7 +453,7 @@ const VariantSelectorVariant = function VariantSelectorVariant2({
|
|
|
453
453
|
})]
|
|
454
454
|
});
|
|
455
455
|
}, [localUpsellQuantity, setHdds, translations, variant$1.shortTitle, variant$1.title, variant$1.upsellVariant, endCampaignUpsellDiscountPrice]);
|
|
456
|
-
const jsxProductBundleNotes =
|
|
456
|
+
const jsxProductBundleNotes = react.useMemo(() => {
|
|
457
457
|
if (!variant$1.productBundleNotes?.length) {
|
|
458
458
|
return null;
|
|
459
459
|
}
|