@ubnt/store.core 9.57.0 → 9.57.2-new-design
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 +123 -1
- package/lib/_virtual/_virtual_multi-entry.js +13 -10
- package/lib/_virtual/_virtual_multi-entry.js.map +1 -1
- package/lib/_virtual/_virtual_multi-entry.mjs +13 -11
- package/lib/_virtual/_virtual_multi-entry.mjs.map +1 -1
- package/lib/apis/smartcat.d.ts +12 -2
- package/lib/apis/smartcat.js +27 -4
- package/lib/apis/smartcat.js.map +1 -1
- package/lib/apis/smartcat.mjs +27 -4
- package/lib/apis/smartcat.mjs.map +1 -1
- package/lib/assets/cart-secondary.svg +5 -0
- package/lib/assets/icon-location-pin.svg +5 -0
- package/lib/assets/icons/cart-secondary.svg.js +27 -0
- package/lib/assets/icons/cart-secondary.svg.js.map +1 -0
- package/lib/assets/icons/cart-secondary.svg.mjs +3 -0
- package/lib/assets/icons/cart-secondary.svg.mjs.map +1 -0
- package/lib/assets/icons/menu/{icon-globe.svg.js → icon-location-pin.svg.js} +6 -6
- package/lib/assets/icons/menu/icon-location-pin.svg.js.map +1 -0
- package/lib/assets/icons/menu/icon-location-pin.svg.mjs +3 -0
- package/lib/assets/icons/menu/icon-location-pin.svg.mjs.map +1 -0
- package/lib/assets/logoUnifi.svg +10 -2
- package/lib/assets/minus4.svg +8 -8
- package/lib/assets/minus5.svg +8 -8
- package/lib/assets/plus5.svg +9 -9
- package/lib/assets/plus6.svg +9 -9
- 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 +1 -0
- package/lib/components/Button/Button.js +12 -5
- package/lib/components/Button/Button.js.map +1 -1
- package/lib/components/Button/Button.mjs +8 -1
- package/lib/components/Button/Button.mjs.map +1 -1
- package/lib/components/Button/CartButton.d.ts +3 -1
- package/lib/components/Button/CartButton.js +11 -6
- package/lib/components/Button/CartButton.js.map +1 -1
- package/lib/components/Button/CartButton.mjs +8 -4
- package/lib/components/Button/CartButton.mjs.map +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.d.ts +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.js +16 -9
- package/lib/components/ButtonGroup/ButtonGroup.js.map +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.mjs +16 -9
- package/lib/components/ButtonGroup/ButtonGroup.mjs.map +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.styles.d.ts +10 -6
- package/lib/components/ButtonGroup/ButtonGroup.styles.js +60 -20
- package/lib/components/ButtonGroup/ButtonGroup.styles.js.map +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.styles.mjs +60 -20
- package/lib/components/ButtonGroup/ButtonGroup.styles.mjs.map +1 -1
- package/lib/components/ButtonGroup/ButtonGroup.types.d.ts +5 -0
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.d.ts +1 -1
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.js +16 -4
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.js.map +1 -1
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.mjs +17 -5
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.mjs.map +1 -1
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.d.ts +5 -1
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.js +82 -17
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.js.map +1 -1
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.mjs +82 -17
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.styles.mjs.map +1 -1
- package/lib/components/ButtonGroupBasic/ButtonGroupBasic.types.d.ts +4 -0
- package/lib/components/ButtonGroupBasic/index.stories.d.ts +6 -0
- 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 +4 -2
- package/lib/components/CategoryTabs/CategoryTabs.styles.js +8 -5
- package/lib/components/CategoryTabs/CategoryTabs.styles.js.map +1 -1
- package/lib/components/CategoryTabs/CategoryTabs.styles.mjs +7 -6
- 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 +5 -4
- package/lib/components/Container/Container.js.map +1 -1
- package/lib/components/Container/Container.mjs +5 -4
- 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 +22 -22
- 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 +30 -20
- package/lib/components/Header/AccountMenu/AccountMenu.js.map +1 -1
- package/lib/components/Header/AccountMenu/AccountMenu.mjs +13 -3
- 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.stories.d.ts +111 -0
- package/lib/components/Header/Header.styles.d.ts +7 -12
- package/lib/components/Header/Header.styles.js +10 -32
- package/lib/components/Header/Header.styles.js.map +1 -1
- package/lib/components/Header/Header.styles.mjs +10 -31
- package/lib/components/Header/Header.styles.mjs.map +1 -1
- package/lib/components/Header/Header.types.d.ts +29 -5
- package/lib/components/Header/Header.types.js +2 -1
- package/lib/components/Header/Header.types.js.map +1 -1
- package/lib/components/Header/Header.types.mjs +2 -1
- package/lib/components/Header/Header.types.mjs.map +1 -1
- package/lib/components/Header/IsolatedHeader.d.ts +1 -0
- package/lib/components/Header/IsolatedHeader.js +50 -50
- package/lib/components/Header/IsolatedHeader.js.map +1 -1
- package/lib/components/Header/IsolatedHeader.mjs +47 -46
- package/lib/components/Header/IsolatedHeader.mjs.map +1 -1
- package/lib/components/Header/LanguageFrame/LanguageFrame.js +6 -6
- package/lib/components/Header/LogoIcon/LogoIcon.d.ts +7 -0
- package/lib/components/Header/LogoIcon/LogoIcon.js +46 -0
- package/lib/components/Header/LogoIcon/LogoIcon.js.map +1 -0
- package/lib/components/Header/LogoIcon/LogoIcon.mjs +36 -0
- package/lib/components/Header/LogoIcon/LogoIcon.mjs.map +1 -0
- package/lib/components/Header/LogoIcon/index.d.ts +1 -0
- package/lib/components/Header/LogoIcon/index.js +6 -0
- package/lib/components/Header/LogoIcon/index.js.map +1 -0
- package/lib/components/Header/LogoIcon/index.mjs +3 -0
- package/lib/components/Header/LogoIcon/index.mjs.map +1 -0
- 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 +1 -0
- 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 +116 -109
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.js.map +1 -1
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.mjs +111 -104
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.mjs.map +1 -1
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.d.ts +9 -0
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.js +15 -1
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.js.map +1 -1
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.mjs +13 -2
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.styles.mjs.map +1 -1
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.types.d.ts +12 -6
- package/lib/components/Header/Overlay/Overlay.js +3 -3
- package/lib/components/Header/ProHeader/ProHeader.d.ts +9 -5
- package/lib/components/Header/ProHeader/ProHeader.js +270 -189
- package/lib/components/Header/ProHeader/ProHeader.js.map +1 -1
- package/lib/components/Header/ProHeader/ProHeader.mjs +251 -171
- package/lib/components/Header/ProHeader/ProHeader.mjs.map +1 -1
- package/lib/components/Header/ProHeader/ProHeader.styles.d.ts +30 -25
- package/lib/components/Header/ProHeader/ProHeader.styles.js +119 -66
- package/lib/components/Header/ProHeader/ProHeader.styles.js.map +1 -1
- package/lib/components/Header/ProHeader/ProHeader.styles.mjs +112 -65
- package/lib/components/Header/ProHeader/ProHeader.styles.mjs.map +1 -1
- package/lib/components/Header/translations/ar.json.js +4 -1
- package/lib/components/Header/translations/ar.json.js.map +1 -1
- package/lib/components/Header/translations/ar.json.mjs +4 -2
- package/lib/components/Header/translations/ar.json.mjs.map +1 -1
- package/lib/components/Header/translations/de.json.js +4 -1
- package/lib/components/Header/translations/de.json.js.map +1 -1
- package/lib/components/Header/translations/de.json.mjs +4 -2
- package/lib/components/Header/translations/de.json.mjs.map +1 -1
- package/lib/components/Header/translations/el.json.js +4 -1
- package/lib/components/Header/translations/el.json.js.map +1 -1
- package/lib/components/Header/translations/el.json.mjs +4 -2
- package/lib/components/Header/translations/el.json.mjs.map +1 -1
- package/lib/components/Header/translations/en.json.js +7 -1
- package/lib/components/Header/translations/en.json.js.map +1 -1
- package/lib/components/Header/translations/en.json.mjs +6 -2
- package/lib/components/Header/translations/en.json.mjs.map +1 -1
- package/lib/components/Header/translations/es.json.js +4 -1
- package/lib/components/Header/translations/es.json.js.map +1 -1
- package/lib/components/Header/translations/es.json.mjs +4 -2
- package/lib/components/Header/translations/es.json.mjs.map +1 -1
- package/lib/components/Header/translations/fr.json.js +4 -1
- package/lib/components/Header/translations/fr.json.js.map +1 -1
- package/lib/components/Header/translations/fr.json.mjs +4 -2
- package/lib/components/Header/translations/fr.json.mjs.map +1 -1
- package/lib/components/Header/translations/it.json.js +4 -1
- package/lib/components/Header/translations/it.json.js.map +1 -1
- package/lib/components/Header/translations/it.json.mjs +4 -2
- package/lib/components/Header/translations/it.json.mjs.map +1 -1
- package/lib/components/Header/translations/ja.json.js +4 -1
- package/lib/components/Header/translations/ja.json.js.map +1 -1
- package/lib/components/Header/translations/ja.json.mjs +4 -2
- package/lib/components/Header/translations/ja.json.mjs.map +1 -1
- package/lib/components/Header/translations/pt-BR.json.js +4 -1
- package/lib/components/Header/translations/pt-BR.json.js.map +1 -1
- package/lib/components/Header/translations/pt-BR.json.mjs +4 -2
- package/lib/components/Header/translations/pt-BR.json.mjs.map +1 -1
- package/lib/components/Header/translations/zh-Hans.json.js +4 -1
- package/lib/components/Header/translations/zh-Hans.json.js.map +1 -1
- package/lib/components/Header/translations/zh-Hans.json.mjs +4 -2
- package/lib/components/Header/translations/zh-Hans.json.mjs.map +1 -1
- package/lib/components/Header/translations/zh-Hant-TW.json.js +4 -1
- package/lib/components/Header/translations/zh-Hant-TW.json.js.map +1 -1
- package/lib/components/Header/translations/zh-Hant-TW.json.mjs +4 -2
- 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 +33 -29
- package/lib/components/ImageCarousel/ImageCarousel.js.map +1 -1
- package/lib/components/ImageCarousel/ImageCarousel.mjs +4 -0
- package/lib/components/ImageCarousel/ImageCarousel.mjs.map +1 -1
- 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 +3 -1
- package/lib/components/LoaderDots/LoaderDots.js.map +1 -1
- package/lib/components/LoaderDots/LoaderDots.mjs +3 -1
- package/lib/components/LoaderDots/LoaderDots.mjs.map +1 -1
- package/lib/components/LoaderDots/LoaderDots.styles.d.ts +2 -1
- package/lib/components/LoaderDots/LoaderDots.styles.js +11 -1
- package/lib/components/LoaderDots/LoaderDots.styles.js.map +1 -1
- package/lib/components/LoaderDots/LoaderDots.styles.mjs +11 -1
- package/lib/components/LoaderDots/LoaderDots.styles.mjs.map +1 -1
- package/lib/components/LoaderDots/LoaderDots.types.d.ts +2 -0
- 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 +12 -12
- 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 +4 -2
- package/lib/components/ModelCompareV3/data/products/cloudKeyEnterprise.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/cloudKeyEnterprise.mjs +4 -2
- 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 +4 -2
- package/lib/components/ModelCompareV3/data/products/gatewayEnterprise.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayEnterprise.mjs +4 -2
- package/lib/components/ModelCompareV3/data/products/gatewayEnterprise.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayLite.js +4 -2
- package/lib/components/ModelCompareV3/data/products/gatewayLite.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayLite.mjs +4 -2
- package/lib/components/ModelCompareV3/data/products/gatewayLite.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayMax.js +4 -2
- package/lib/components/ModelCompareV3/data/products/gatewayMax.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayMax.mjs +4 -2
- package/lib/components/ModelCompareV3/data/products/gatewayMax.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayProfessional.js +4 -2
- package/lib/components/ModelCompareV3/data/products/gatewayProfessional.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/gatewayProfessional.mjs +4 -2
- package/lib/components/ModelCompareV3/data/products/gatewayProfessional.mjs.map +1 -1
- package/lib/components/ModelCompareV3/data/products/officialUniFiHosting.js +3 -1
- package/lib/components/ModelCompareV3/data/products/officialUniFiHosting.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/officialUniFiHosting.mjs +3 -1
- 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 +5 -41
- package/lib/components/ModelCompareV3/data/products/udr.js.map +1 -1
- package/lib/components/ModelCompareV3/data/products/udr.mjs +5 -21
- 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/ProductTechSpecsV2/ProductTechSpecs.d.ts +2 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.js +81 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.js.map +1 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.mjs +73 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.mjs.map +1 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.stories.d.ts +5 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.styles.d.ts +11 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.styles.js +80 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.styles.js.map +1 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.styles.mjs +66 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.styles.mjs.map +1 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.types.d.ts +12 -0
- package/lib/components/ProductTechSpecsV2/index.d.ts +1 -0
- package/lib/components/ProductTechSpecsV2/index.js +6 -0
- package/lib/components/ProductTechSpecsV2/index.js.map +1 -0
- package/lib/components/ProductTechSpecsV2/index.mjs +3 -0
- package/lib/components/ProductTechSpecsV2/index.mjs.map +1 -0
- 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 +6 -1
- package/lib/components/QuantityInput/QuantityInput.js.map +1 -1
- package/lib/components/QuantityInput/QuantityInput.mjs +6 -1
- 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 +6 -6
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/CounterSection.mjs +2 -2
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/InputSections/SliderSection.js +3 -3
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/minus.svg.js +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/minus.svg.mjs +2 -2
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/plus.svg.js +1 -1
- package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/components/InputCard/assets/plus.svg.mjs +2 -2
- 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 +17 -17
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/PoeConsumerSelectModal/PoeConsumerSelectModal.mjs +2 -2
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/minus.svg.js +1 -1
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/minus.svg.mjs +2 -2
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/plus.svg.js +1 -1
- package/lib/components/ResourceCalculatorV1/PoeCalculator/components/PoeConsumerConfigurator/assets/plus.svg.mjs +2 -2
- 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 +33 -25
- package/lib/components/ScrollWrapper/ScrollWrapper.js.map +1 -1
- package/lib/components/ScrollWrapper/ScrollWrapper.mjs +16 -8
- package/lib/components/ScrollWrapper/ScrollWrapper.mjs.map +1 -1
- package/lib/components/ScrollWrapper/ScrollWrapper.types.d.ts +2 -0
- 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 +0 -1
- package/lib/components/Search/Input/Input.styles.js.map +1 -1
- package/lib/components/Search/Input/Input.styles.mjs +0 -1
- package/lib/components/Search/Input/Input.styles.mjs.map +1 -1
- package/lib/components/Search/Input/Input.types.d.ts +3 -2
- 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 +19 -19
- package/lib/components/index.d.ts +1 -0
- package/lib/components/index.js +2 -0
- package/lib/components/index.js.map +1 -1
- package/lib/components/index.mjs +2 -0
- package/lib/components/index.mjs.map +1 -1
- package/lib/constants/proStoreCategories/mapping/filters.d.ts +17 -0
- package/lib/constants/proStoreCategories/mapping/filters.js +17 -0
- package/lib/constants/proStoreCategories/mapping/filters.js.map +1 -1
- package/lib/constants/proStoreCategories/mapping/filters.mjs +17 -0
- package/lib/constants/proStoreCategories/mapping/filters.mjs.map +1 -1
- package/lib/constants/proStoreCategories/mapping/index.d.ts +4 -2
- package/lib/constants/proStoreCategories/mapping/index.js +50 -51
- 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 +5 -0
- package/lib/constants/proStoreCategories/mapping/redirects.js +18 -3
- package/lib/constants/proStoreCategories/mapping/redirects.js.map +1 -1
- package/lib/constants/proStoreCategories/mapping/redirects.mjs +18 -3
- 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 +7 -3
- package/lib/constants/proStoreCategories/translations/ar.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/ar.json.mjs +7 -4
- package/lib/constants/proStoreCategories/translations/ar.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/de.json.js +7 -3
- package/lib/constants/proStoreCategories/translations/de.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/de.json.mjs +7 -4
- package/lib/constants/proStoreCategories/translations/de.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/el.json.js +7 -3
- package/lib/constants/proStoreCategories/translations/el.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/el.json.mjs +7 -4
- package/lib/constants/proStoreCategories/translations/el.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/en.json.js +7 -3
- package/lib/constants/proStoreCategories/translations/en.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/en.json.mjs +7 -4
- package/lib/constants/proStoreCategories/translations/en.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/es.json.js +7 -3
- package/lib/constants/proStoreCategories/translations/es.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/es.json.mjs +7 -4
- package/lib/constants/proStoreCategories/translations/es.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/fr.json.js +7 -3
- package/lib/constants/proStoreCategories/translations/fr.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/fr.json.mjs +7 -4
- package/lib/constants/proStoreCategories/translations/fr.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/it.json.js +7 -3
- package/lib/constants/proStoreCategories/translations/it.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/it.json.mjs +7 -4
- package/lib/constants/proStoreCategories/translations/it.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/ja.json.js +7 -3
- package/lib/constants/proStoreCategories/translations/ja.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/ja.json.mjs +7 -4
- package/lib/constants/proStoreCategories/translations/ja.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/pt-BR.json.js +7 -3
- package/lib/constants/proStoreCategories/translations/pt-BR.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/pt-BR.json.mjs +7 -4
- package/lib/constants/proStoreCategories/translations/pt-BR.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/zh-Hans.json.js +7 -3
- package/lib/constants/proStoreCategories/translations/zh-Hans.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/zh-Hans.json.mjs +7 -4
- package/lib/constants/proStoreCategories/translations/zh-Hans.json.mjs.map +1 -1
- package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.js +7 -3
- package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.js.map +1 -1
- package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.mjs +7 -4
- package/lib/constants/proStoreCategories/translations/zh-Hant-TW.json.mjs.map +1 -1
- package/lib/constants/proStoreFilters/mapping.d.ts +55 -3
- package/lib/constants/proStoreFilters/mapping.js +140 -10
- package/lib/constants/proStoreFilters/mapping.js.map +1 -1
- package/lib/constants/proStoreFilters/mapping.mjs +140 -10
- package/lib/constants/proStoreFilters/mapping.mjs.map +1 -1
- package/lib/constants/theme.js +4 -0
- package/lib/constants/theme.js.map +1 -1
- package/lib/constants/theme.mjs +4 -0
- 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 +1 -0
- 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 +8 -0
- package/lib/helpers/ux.js +15 -0
- package/lib/helpers/ux.js.map +1 -1
- package/lib/helpers/ux.mjs +15 -1
- 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/icons/menu/icon-globe.svg.js.map +0 -1
- package/lib/assets/icons/menu/icon-globe.svg.mjs +0 -3
- package/lib/assets/icons/menu/icon-globe.svg.mjs.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"QuantityInput.mjs","sources":["../../../src/components/QuantityInput/QuantityInput.tsx"],"sourcesContent":["import { minus, plus } from \"../../assets/icons/wizard\";\nimport { StyleableSvgImage } from \"../StyleableSvgImage\";\nimport * as S from \"./QuantityInput.styles\";\nimport type { QuantityInputProps } from \"./QuantityInput.types\";\n\n/**\n * TODO: Wrong plus and minus icons - should be reexported from the figma\n */\nexport const QuantityInput = ({\n quantity,\n onIncreaseQuantity,\n onDecreaseQuantity,\n onUpdateQuantity,\n disabled,\n label,\n className,\n maxQuantity = 999,\n}: QuantityInputProps) => {\n return (\n <S.Container className={className}>\n {label && <S.Label>{label}</S.Label>}\n <S.QuantityAdjustWrap $disabled={disabled}>\n <S.MinusAdjustButton\n data-test-id=\"decrease\"\n onClick={(e) => {\n e?.stopPropagation();\n onDecreaseQuantity?.(e);\n }}\n disabled={quantity === 0 || disabled}\n >\n <StyleableSvgImage src={minus} width={8} height={8} />\n </S.MinusAdjustButton>\n <S.QuantityInput\n data-test-id=\"item-quantity\"\n min=\"0\"\n type=\"text\"\n pattern=\"[0-9]*\"\n maxLength={5}\n value={quantity}\n onChange={(e) => {\n e?.stopPropagation();\n onUpdateQuantity?.(e);\n }}\n onClick={(e) => e
|
|
1
|
+
{"version":3,"file":"QuantityInput.mjs","sources":["../../../src/components/QuantityInput/QuantityInput.tsx"],"sourcesContent":["import { minus, plus } from \"../../assets/icons/wizard\";\nimport { StyleableSvgImage } from \"../StyleableSvgImage\";\nimport * as S from \"./QuantityInput.styles\";\nimport type { QuantityInputProps } from \"./QuantityInput.types\";\n\n/**\n * TODO: Wrong plus and minus icons - should be reexported from the figma\n */\nexport const QuantityInput = ({\n quantity,\n onIncreaseQuantity,\n onDecreaseQuantity,\n onUpdateQuantity,\n disabled,\n label,\n className,\n maxQuantity = 999,\n}: QuantityInputProps) => {\n return (\n <S.Container className={className}>\n {label && <S.Label>{label}</S.Label>}\n <S.QuantityAdjustWrap $disabled={disabled}>\n <S.MinusAdjustButton\n data-test-id=\"decrease\"\n onClick={(e) => {\n e?.stopPropagation();\n e?.preventDefault();\n onDecreaseQuantity?.(e);\n }}\n disabled={quantity === 0 || disabled}\n >\n <StyleableSvgImage src={minus} width={8} height={8} />\n </S.MinusAdjustButton>\n <S.QuantityInput\n data-test-id=\"item-quantity\"\n min=\"0\"\n type=\"text\"\n pattern=\"[0-9]*\"\n maxLength={5}\n value={quantity}\n onChange={(e) => {\n e?.stopPropagation();\n onUpdateQuantity?.(e);\n }}\n onClick={(e) => {\n e?.stopPropagation();\n e?.preventDefault();\n }}\n disabled={disabled}\n />\n <S.PlusAdjustButton\n data-test-id=\"increase\"\n onClick={(e) => {\n e?.stopPropagation();\n e?.preventDefault();\n onIncreaseQuantity?.(e);\n }}\n disabled={(quantity || 0) >= maxQuantity || disabled}\n >\n <StyleableSvgImage src={plus} width={8} height={8} />\n </S.PlusAdjustButton>\n </S.QuantityAdjustWrap>\n </S.Container>\n );\n};\n"],"names":["QuantityInput","quantity","onIncreaseQuantity","onDecreaseQuantity","onUpdateQuantity","disabled","label","className","maxQuantity","jsxs","S.Container","children","jsx","S.Label","S.QuantityAdjustWrap","$disabled","S.MinusAdjustButton","onClick","e","stopPropagation","preventDefault","StyleableSvgImage","src","minus","width","height","S.QuantityInput","min","type","pattern","maxLength","value","onChange","S.PlusAdjustButton","plus"],"mappings":";;;;;;;;AAQO,MAAMA,gBAAgBA,CAAC;EAC5BC,QAAA;EACAC,kBAAA;EACAC,kBAAA;EACAC,gBAAA;EACAC,QAAA;EACAC,KAAA;EACAC,SAAA;EACAC,WAAc,GAAA;AAChB,CAA0B,KAAA;EACxB,OAAA,eACGC,IAAA,CAAAC,SAAA,EAAA;IAAYH,SACV;IAAAI,QAAA,EAAA,CAAAL,KAAA,IAAU,eAAAM,GAAA,CAAAC,KAAA,EAAA;MAASF,QAAM,EAAAL;IAAA,CAAA,CAAA,EACzB,eAAAG,IAAA,CAAAK,kBAAA,EAAA;MAAqBC,WAAWV,QAC/B;MAAAM,QAAA,EAAA,CAAA,eAAAC,GAAA,CAACI,iBAAE,EAAF;QACC,cAAa,EAAA,UAAA;QACbC,OAAA,EAAUC,CAAM,IAAA;UACdA,CAAA,EAAGC,eAAgB,CAAA,CAAA;UACnBD,CAAA,EAAGE,cAAe,CAAA,CAAA;UAClBjB,kBAAA,GAAqBe,CAAC,CAAA;QACxB,CAAA;QACAb,QAAA,EAAUJ,aAAa,CAAK,IAAAI,QAAA;QAE5BM,6BAACU,iBAAkB,EAAA;UAAAC,GAAA,EAAKC;UAAOC,KAAO,EAAA,CAAA;UAAGC,QAAQ;SAAG;MAAA,CACtD,CAAA,EAAA,eACAb,GAAA,CAACc,eAAE,EAAF;QACC,cAAa,EAAA,eAAA;QACbC,GAAI,EAAA,GAAA;QACJC,IAAK,EAAA,MAAA;QACLC,OAAQ,EAAA,QAAA;QACRC,SAAW,EAAA,CAAA;QACXC,KAAO,EAAA9B,QAAA;QACP+B,QAAA,EAAWd,CAAM,IAAA;UACfA,CAAA,EAAGC,eAAgB,CAAA,CAAA;UACnBf,gBAAA,GAAmBc,CAAC,CAAA;QACtB,CAAA;QACAD,OAAA,EAAUC,CAAM,IAAA;UACdA,CAAA,EAAGC,eAAgB,CAAA,CAAA;UACnBD,CAAA,EAAGE,cAAe,CAAA,CAAA;QACpB,CAAA;QACAf;MAAA,CACF,CAAA,EAAA,eACAO,GAAA,CAACqB,gBAAE,EAAF;QACC,cAAa,EAAA,UAAA;QACbhB,OAAA,EAAUC,CAAM,IAAA;UACdA,CAAA,EAAGC,eAAgB,CAAA,CAAA;UACnBD,CAAA,EAAGE,cAAe,CAAA,CAAA;UAClBlB,kBAAA,GAAqBgB,CAAC,CAAA;QACxB,CAAA;QACAb,QAAA,EAAA,CAAWJ,QAAY,IAAA,CAAA,KAAMO,WAAe,IAAAH,QAAA;QAE5CM,6BAACU,iBAAkB,EAAA;UAAAC,GAAA,EAAKY;UAAMV,KAAO,EAAA,CAAA;UAAGC,QAAQ;SAAG;MAAA,CACrD,CAAA;KACF,CAAA;EACF,CAAA,CAAA;AAEJ,CAAA;"}
|
|
@@ -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/addToCart.svg.js');
|
|
6
6
|
require('../../utils/money/index.js');
|
|
7
7
|
require('../ProductCardPopup/index.js');
|
|
@@ -30,10 +30,10 @@ const RelatedProducts = ({
|
|
|
30
30
|
renderImage,
|
|
31
31
|
translations
|
|
32
32
|
}) => {
|
|
33
|
-
const isLoading =
|
|
34
|
-
const [popupProduct, setPopupProduct] =
|
|
35
|
-
const isPopupOpen =
|
|
36
|
-
|
|
33
|
+
const isLoading = React.useMemo(() => categories === null, [categories]);
|
|
34
|
+
const [popupProduct, setPopupProduct] = React.useState(activePopupProduct);
|
|
35
|
+
const isPopupOpen = React.useMemo(() => !!activePopupProduct, [activePopupProduct]);
|
|
36
|
+
React.useEffect(() => {
|
|
37
37
|
if (activePopupProduct !== void 0) {
|
|
38
38
|
setPopupProduct(activePopupProduct);
|
|
39
39
|
}
|
package/lib/components/ResourceCalculatorV1/ComputeResourceCalculator/ComputeResourceCalculator.js
CHANGED
|
@@ -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 useHddRetentionCalculator = require('../../../hooks/useHddRetentionCalculator.js');
|
|
6
6
|
require('../assets/icons/access.png.js');
|
|
7
7
|
require('../assets/icons/network.png.js');
|
|
@@ -58,12 +58,12 @@ const ComputeResourceCalculator = ({
|
|
|
58
58
|
const {
|
|
59
59
|
formatMessage
|
|
60
60
|
} = useResourceCalculatorTranslation.useResourceCalculatorTranslation();
|
|
61
|
-
const defaultActiveDevice =
|
|
61
|
+
const defaultActiveDevice = React.useMemo(() => {
|
|
62
62
|
const foundDevice = ComputeResourceCalculator_constants.DEVICES.find(item => item.id === defaultActiveDeviceId);
|
|
63
63
|
return foundDevice || ComputeResourceCalculator_constants.DEVICES[0];
|
|
64
64
|
}, [defaultActiveDeviceId]);
|
|
65
|
-
const [device, setDevice] =
|
|
66
|
-
const supportedFeatures =
|
|
65
|
+
const [device, setDevice] = React.useState(defaultActiveDevice);
|
|
66
|
+
const supportedFeatures = React.useMemo(() => {
|
|
67
67
|
return {
|
|
68
68
|
[ComputeResourceCalculator_types.FeatureId.Network]: !!device.loadData?.Network,
|
|
69
69
|
[ComputeResourceCalculator_types.FeatureId.Protect]: !!device.loadData?.Protect,
|
|
@@ -71,7 +71,7 @@ const ComputeResourceCalculator = ({
|
|
|
71
71
|
[ComputeResourceCalculator_types.FeatureId.Access]: !!device.loadData?.Access
|
|
72
72
|
};
|
|
73
73
|
}, [device]);
|
|
74
|
-
const forcedFeatures =
|
|
74
|
+
const forcedFeatures = React.useMemo(() => {
|
|
75
75
|
return {
|
|
76
76
|
[ComputeResourceCalculator_types.FeatureId.Network]: !!device.settings?.forcedFeatures?.includes(ComputeResourceCalculator_types.FeatureId.Network),
|
|
77
77
|
[ComputeResourceCalculator_types.FeatureId.Protect]: !!device.settings?.forcedFeatures?.includes(ComputeResourceCalculator_types.FeatureId.Protect),
|
|
@@ -79,22 +79,22 @@ const ComputeResourceCalculator = ({
|
|
|
79
79
|
[ComputeResourceCalculator_types.FeatureId.Access]: !!device.settings?.forcedFeatures?.includes(ComputeResourceCalculator_types.FeatureId.Access)
|
|
80
80
|
};
|
|
81
81
|
}, [device]);
|
|
82
|
-
const [enabledFeatures, setEnabledFeatures] =
|
|
83
|
-
const handleToggleFeature =
|
|
82
|
+
const [enabledFeatures, setEnabledFeatures] = React.useState(getDefaultActiveFeatures(device));
|
|
83
|
+
const handleToggleFeature = React.useCallback(key => enabled => {
|
|
84
84
|
setEnabledFeatures({
|
|
85
85
|
...enabledFeatures,
|
|
86
86
|
[key]: enabled
|
|
87
87
|
});
|
|
88
88
|
}, [enabledFeatures, setEnabledFeatures]);
|
|
89
|
-
const enabledFeaturesCount =
|
|
90
|
-
const maxEnabledFeaturesReached =
|
|
89
|
+
const enabledFeaturesCount = React.useMemo(() => Object.values(enabledFeatures).filter(item => item).length, [enabledFeatures]);
|
|
90
|
+
const maxEnabledFeaturesReached = React.useMemo(() => {
|
|
91
91
|
const maxFeatures = device.settings?.maxFeatures;
|
|
92
92
|
if (!maxFeatures) {
|
|
93
93
|
return false;
|
|
94
94
|
}
|
|
95
95
|
return maxFeatures === enabledFeaturesCount;
|
|
96
96
|
}, [device.settings?.maxFeatures, enabledFeaturesCount]);
|
|
97
|
-
const maxFeaturesReachedNote =
|
|
97
|
+
const maxFeaturesReachedNote = React.useMemo(() => {
|
|
98
98
|
const maxFeatures = device.settings?.maxFeatures;
|
|
99
99
|
if (!maxFeatures) {
|
|
100
100
|
return "";
|
|
@@ -103,15 +103,15 @@ const ComputeResourceCalculator = ({
|
|
|
103
103
|
maxFeatures
|
|
104
104
|
});
|
|
105
105
|
}, [device.settings?.maxFeatures, formatMessage]);
|
|
106
|
-
const defaultNetworkInputState =
|
|
106
|
+
const defaultNetworkInputState = React.useMemo(() => ({
|
|
107
107
|
accessPoints: 0,
|
|
108
108
|
vpn: false,
|
|
109
109
|
detections: false,
|
|
110
110
|
adBlocking: false,
|
|
111
111
|
qos: false
|
|
112
112
|
}), []);
|
|
113
|
-
const [networkInputState, setNetworkInputState] =
|
|
114
|
-
const networkCard =
|
|
113
|
+
const [networkInputState, setNetworkInputState] = React.useState(defaultNetworkInputState);
|
|
114
|
+
const networkCard = React.useMemo(() => {
|
|
115
115
|
const isEnabled = enabledFeatures[ComputeResourceCalculator_types.FeatureId.Network];
|
|
116
116
|
return /* @__PURE__ */jsxRuntime.jsx(InputCard.InputCard, {
|
|
117
117
|
id: "computeResourceCalculator__inputCard__network",
|
|
@@ -186,14 +186,14 @@ const ComputeResourceCalculator = ({
|
|
|
186
186
|
}]
|
|
187
187
|
});
|
|
188
188
|
}, [networkInputState, setNetworkInputState, handleToggleFeature, enabledFeatures, supportedFeatures, maxEnabledFeaturesReached, maxFeaturesReachedNote, forcedFeatures, device.loadData.Network?.accessPoint.max, formatMessage]);
|
|
189
|
-
const defaultProtectInputState =
|
|
189
|
+
const defaultProtectInputState = React.useMemo(() => ({
|
|
190
190
|
cameraHd: 0,
|
|
191
191
|
camera2k: 0,
|
|
192
192
|
camera4k: 0,
|
|
193
193
|
daysOfStorage: 0
|
|
194
194
|
}), []);
|
|
195
|
-
const [protectInputState, setProtectInputState] =
|
|
196
|
-
const maxCameras =
|
|
195
|
+
const [protectInputState, setProtectInputState] = React.useState(defaultProtectInputState);
|
|
196
|
+
const maxCameras = React.useMemo(() => {
|
|
197
197
|
if (!device.loadData.Protect) {
|
|
198
198
|
return {
|
|
199
199
|
cameraHd: 0,
|
|
@@ -213,20 +213,20 @@ const ComputeResourceCalculator = ({
|
|
|
213
213
|
camera4k: device.loadData.Protect.camera4k.max
|
|
214
214
|
};
|
|
215
215
|
}, [device, enabledFeaturesCount]);
|
|
216
|
-
const maxHdds =
|
|
216
|
+
const maxHdds = React.useMemo(() => {
|
|
217
217
|
return device.settings?.hdd?.max || 0;
|
|
218
218
|
}, [device]);
|
|
219
|
-
const hddGigabyteOptions =
|
|
219
|
+
const hddGigabyteOptions = React.useMemo(() => {
|
|
220
220
|
const defaultGigabytes = [1e3, 8e3, 16e3, 24e3];
|
|
221
221
|
return device.settings?.hdd?.gigabyteOptions || defaultGigabytes;
|
|
222
222
|
}, [device.settings?.hdd?.gigabyteOptions]);
|
|
223
|
-
const getDefaultHddGigabyteOption =
|
|
223
|
+
const getDefaultHddGigabyteOption = React.useCallback(options => {
|
|
224
224
|
if (!options || options.includes(DEFAULT_HDD_GB_OPTION)) {
|
|
225
225
|
return DEFAULT_HDD_GB_OPTION;
|
|
226
226
|
}
|
|
227
227
|
return options[0];
|
|
228
228
|
}, []);
|
|
229
|
-
const getHddSizeLabel =
|
|
229
|
+
const getHddSizeLabel = React.useCallback(gigaBytes => {
|
|
230
230
|
if (gigaBytes === 0) {
|
|
231
231
|
return formatMessage("protect.noStorage");
|
|
232
232
|
}
|
|
@@ -235,17 +235,17 @@ const ComputeResourceCalculator = ({
|
|
|
235
235
|
}
|
|
236
236
|
return `${gigaBytes / 1e3}TB`;
|
|
237
237
|
}, [formatMessage]);
|
|
238
|
-
const [hddGigabytes, setHddGigabytes] =
|
|
239
|
-
const totalCameras =
|
|
238
|
+
const [hddGigabytes, setHddGigabytes] = React.useState(getDefaultHddGigabyteOption(device.settings?.hdd?.gigabyteOptions));
|
|
239
|
+
const totalCameras = React.useMemo(() => {
|
|
240
240
|
return protectInputState["cameraHd"] + protectInputState["camera2k"] + protectInputState["camera4k"];
|
|
241
241
|
}, [protectInputState]);
|
|
242
|
-
const parityDisks =
|
|
242
|
+
const parityDisks = React.useMemo(() => {
|
|
243
243
|
return device.settings?.hdd?.parityDisks || 0;
|
|
244
244
|
}, [device.settings?.hdd?.parityDisks]);
|
|
245
|
-
const hideHddSizeOptions =
|
|
245
|
+
const hideHddSizeOptions = React.useMemo(() => {
|
|
246
246
|
return maxHdds === 0;
|
|
247
247
|
}, [maxHdds]);
|
|
248
|
-
const hideRetentionCalculation =
|
|
248
|
+
const hideRetentionCalculation = React.useMemo(() => {
|
|
249
249
|
return hideHddSizeOptions || hddGigabytes === 0;
|
|
250
250
|
}, [hideHddSizeOptions, hddGigabytes]);
|
|
251
251
|
const {
|
|
@@ -264,7 +264,7 @@ const ComputeResourceCalculator = ({
|
|
|
264
264
|
hddTerabytes: hddGigabytes / 1e3,
|
|
265
265
|
format: RETENTION_TIME_FORMAT
|
|
266
266
|
});
|
|
267
|
-
const hddSlots =
|
|
267
|
+
const hddSlots = React.useMemo(() => {
|
|
268
268
|
const handleHddSlotClick = daysOfStorage => {
|
|
269
269
|
setProtectInputState({
|
|
270
270
|
...protectInputState,
|
|
@@ -287,7 +287,7 @@ const ComputeResourceCalculator = ({
|
|
|
287
287
|
})
|
|
288
288
|
});
|
|
289
289
|
}, [protectInputState, totalCameras, maxHdds, getRequiredHddsByRetention, retentionHddItems, parityDisks, minRetentionStorage, formatMessage, hddGigabytes, getHddSizeLabel]);
|
|
290
|
-
const handleUpdateCameraInputChange =
|
|
290
|
+
const handleUpdateCameraInputChange = React.useCallback((cameraType, newValue) => {
|
|
291
291
|
if (Object.values(maxCameras).some(max => max === 0)) {
|
|
292
292
|
return;
|
|
293
293
|
}
|
|
@@ -328,7 +328,7 @@ const ComputeResourceCalculator = ({
|
|
|
328
328
|
...evaluatedCameras
|
|
329
329
|
});
|
|
330
330
|
}, [protectInputState, maxCameras]);
|
|
331
|
-
const protectCard =
|
|
331
|
+
const protectCard = React.useMemo(() => {
|
|
332
332
|
const isActive = enabledFeatures[ComputeResourceCalculator_types.FeatureId.Protect];
|
|
333
333
|
const deviceSpecificNote = {
|
|
334
334
|
[ComputeResourceCalculator_types.DeviceId.CkG2Plus]: formatMessage("protect.CkG2PlusNote"),
|
|
@@ -416,12 +416,12 @@ const ComputeResourceCalculator = ({
|
|
|
416
416
|
}]
|
|
417
417
|
});
|
|
418
418
|
}, [protectInputState, setProtectInputState, enabledFeatures, handleToggleFeature, supportedFeatures, hideRetentionCalculation, hddSlots, getHddSizeLabel, hddGigabyteOptions, hideHddSizeOptions, maxCameras, maxEnabledFeaturesReached, maxFeaturesReachedNote, forcedFeatures, totalCameras, handleUpdateCameraInputChange, maxHdds, device.id, maxRetention, hddGigabytes, formatMessage]);
|
|
419
|
-
const defaultTalkInputState =
|
|
419
|
+
const defaultTalkInputState = React.useMemo(() => ({
|
|
420
420
|
phones: 0,
|
|
421
421
|
record: false
|
|
422
422
|
}), []);
|
|
423
|
-
const [talkInputState, setTalkInputState] =
|
|
424
|
-
const talkCard =
|
|
423
|
+
const [talkInputState, setTalkInputState] = React.useState(defaultTalkInputState);
|
|
424
|
+
const talkCard = React.useMemo(() => {
|
|
425
425
|
const isActive = enabledFeatures[ComputeResourceCalculator_types.FeatureId.Talk];
|
|
426
426
|
return /* @__PURE__ */jsxRuntime.jsx(InputCard.InputCard, {
|
|
427
427
|
id: "computeResourceCalculator__inputCard__talk",
|
|
@@ -460,11 +460,11 @@ const ComputeResourceCalculator = ({
|
|
|
460
460
|
}]
|
|
461
461
|
});
|
|
462
462
|
}, [talkInputState, setTalkInputState, enabledFeatures, handleToggleFeature, supportedFeatures, maxEnabledFeaturesReached, maxFeaturesReachedNote, forcedFeatures, device.loadData.Talk?.phone.max, formatMessage]);
|
|
463
|
-
const defaultAccessInputState =
|
|
463
|
+
const defaultAccessInputState = React.useMemo(() => ({
|
|
464
464
|
doors: 0
|
|
465
465
|
}), []);
|
|
466
|
-
const [accessInputState, setAccessInputState] =
|
|
467
|
-
const accessCard =
|
|
466
|
+
const [accessInputState, setAccessInputState] = React.useState(defaultAccessInputState);
|
|
467
|
+
const accessCard = React.useMemo(() => {
|
|
468
468
|
const isActive = enabledFeatures[ComputeResourceCalculator_types.FeatureId.Access];
|
|
469
469
|
return /* @__PURE__ */jsxRuntime.jsx(InputCard.InputCard, {
|
|
470
470
|
id: "computeResourceCalculator__inputCard__access",
|
|
@@ -492,11 +492,11 @@ const ComputeResourceCalculator = ({
|
|
|
492
492
|
}]
|
|
493
493
|
});
|
|
494
494
|
}, [accessInputState, setAccessInputState, enabledFeatures, handleToggleFeature, supportedFeatures, maxEnabledFeaturesReached, maxFeaturesReachedNote, forcedFeatures, device.loadData.Access?.door.max, formatMessage]);
|
|
495
|
-
const resetInputState =
|
|
495
|
+
const resetInputState = React.useCallback(deviceItem => {
|
|
496
496
|
setEnabledFeatures(getDefaultActiveFeatures(deviceItem));
|
|
497
497
|
setHddGigabytes(getDefaultHddGigabyteOption(deviceItem.settings?.hdd?.gigabyteOptions));
|
|
498
498
|
}, [getDefaultHddGigabyteOption]);
|
|
499
|
-
const selectDevice =
|
|
499
|
+
const selectDevice = React.useCallback(deviceItem => {
|
|
500
500
|
resetInputState(deviceItem);
|
|
501
501
|
setDevice(deviceItem);
|
|
502
502
|
}, [resetInputState]);
|
|
@@ -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 layout = require('../../../../../constants/layout.js');
|
|
7
7
|
var asset = require('../../../../../utils/asset.js');
|
|
@@ -28,15 +28,15 @@ const DeviceSelect = ({
|
|
|
28
28
|
const {
|
|
29
29
|
formatMessage
|
|
30
30
|
} = useResourceCalculatorTranslation.useResourceCalculatorTranslation();
|
|
31
|
-
const defaultCollapsedState =
|
|
31
|
+
const defaultCollapsedState = React.useMemo(() => {
|
|
32
32
|
const activeItemIndex = items.findIndex(item => item.active);
|
|
33
33
|
return !!collapseAt && activeItemIndex < collapseAt;
|
|
34
34
|
}, [collapseAt, items]);
|
|
35
|
-
const [isCollapsed, setIsCollapsed] =
|
|
36
|
-
const handleToggleCollapse =
|
|
35
|
+
const [isCollapsed, setIsCollapsed] = React.useState(defaultCollapsedState);
|
|
36
|
+
const handleToggleCollapse = React.useCallback(() => {
|
|
37
37
|
setIsCollapsed(!isCollapsed);
|
|
38
38
|
}, [isCollapsed]);
|
|
39
|
-
const mappedItems =
|
|
39
|
+
const mappedItems = React.useMemo(() => {
|
|
40
40
|
return items.map((item, i) => {
|
|
41
41
|
const isHidden = collapseAt !== void 0 && isCollapsed && i >= collapseAt;
|
|
42
42
|
return /* @__PURE__ */jsxRuntime.jsxs(DeviceSelect_styles.DeviceItem, {
|
|
@@ -69,9 +69,9 @@ const DeviceSelect = ({
|
|
|
69
69
|
}, item.id);
|
|
70
70
|
});
|
|
71
71
|
}, [items, isCollapsed, collapseAt, formatMessage]);
|
|
72
|
-
const scrollContainerRef =
|
|
72
|
+
const scrollContainerRef = React.useRef(null);
|
|
73
73
|
const isTablet = reactUse.useMedia(layout.BREAKPOINTS.TABLET_AND_DOWN, false);
|
|
74
|
-
const handleScrollToMax =
|
|
74
|
+
const handleScrollToMax = React.useCallback(scrollTo => {
|
|
75
75
|
if (scrollContainerRef.current) {
|
|
76
76
|
const left = scrollTo === "left" ? 0 : scrollContainerRef.current.scrollWidth;
|
|
77
77
|
scrollContainerRef.current.scrollTo({
|
|
@@ -80,11 +80,11 @@ const DeviceSelect = ({
|
|
|
80
80
|
});
|
|
81
81
|
}
|
|
82
82
|
}, [scrollContainerRef]);
|
|
83
|
-
const [showScrollBtn, setShowScrollBtn] =
|
|
83
|
+
const [showScrollBtn, setShowScrollBtn] = React.useState({
|
|
84
84
|
left: false,
|
|
85
85
|
right: false
|
|
86
86
|
});
|
|
87
|
-
const evaluateShowScrollBtn =
|
|
87
|
+
const evaluateShowScrollBtn = React.useCallback(() => {
|
|
88
88
|
if (!scrollContainerRef.current) {
|
|
89
89
|
return;
|
|
90
90
|
}
|
|
@@ -103,10 +103,10 @@ const DeviceSelect = ({
|
|
|
103
103
|
right: evaluateScrollBtn("right")
|
|
104
104
|
});
|
|
105
105
|
}, [isTablet]);
|
|
106
|
-
|
|
106
|
+
React.useEffect(() => {
|
|
107
107
|
evaluateShowScrollBtn();
|
|
108
108
|
}, [isCollapsed, evaluateShowScrollBtn]);
|
|
109
|
-
|
|
109
|
+
React.useEffect(() => {
|
|
110
110
|
const scrollEl = scrollContainerRef.current;
|
|
111
111
|
if (scrollEl) {
|
|
112
112
|
scrollEl.addEventListener("scroll", evaluateShowScrollBtn);
|
|
@@ -117,7 +117,7 @@ const DeviceSelect = ({
|
|
|
117
117
|
}
|
|
118
118
|
};
|
|
119
119
|
}, [evaluateShowScrollBtn]);
|
|
120
|
-
const scrollHelperButtons =
|
|
120
|
+
const scrollHelperButtons = React.useMemo(() => {
|
|
121
121
|
if (!scrollContainerRef.current) {
|
|
122
122
|
return null;
|
|
123
123
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
4
|
var Checkbox = require('@ubnt/ui-components/Checkbox');
|
|
5
|
-
var
|
|
5
|
+
var React = require('react');
|
|
6
6
|
var reactUse = require('react-use');
|
|
7
7
|
var layout = require('../../../../../constants/layout.js');
|
|
8
8
|
var asset = require('../../../../../utils/asset.js');
|
|
@@ -38,17 +38,17 @@ const InputCard = ({
|
|
|
38
38
|
const {
|
|
39
39
|
formatMessage
|
|
40
40
|
} = useResourceCalculatorTranslation.useResourceCalculatorTranslation();
|
|
41
|
-
const handleToggleEnabled =
|
|
41
|
+
const handleToggleEnabled = React.useCallback(event => {
|
|
42
42
|
onToggleEnabled?.(event.target.checked);
|
|
43
43
|
}, [onToggleEnabled]);
|
|
44
|
-
const disabledCard =
|
|
44
|
+
const disabledCard = React.useMemo(() => {
|
|
45
45
|
return Boolean(!active || notAvailable);
|
|
46
46
|
}, [active, notAvailable]);
|
|
47
|
-
const renderHeader =
|
|
47
|
+
const renderHeader = React.useMemo(() => {
|
|
48
48
|
return Boolean(notAvailable || header?.icon || header?.title);
|
|
49
49
|
}, [header, notAvailable]);
|
|
50
50
|
const isMobile = reactUse.useMedia(layout.BREAKPOINTS.MOBILE_AND_DOWN, false);
|
|
51
|
-
const hideCardContent =
|
|
51
|
+
const hideCardContent = React.useMemo(() => {
|
|
52
52
|
return isMobile && disabledCard;
|
|
53
53
|
}, [disabledCard, isMobile]);
|
|
54
54
|
return /* @__PURE__ */jsxRuntime.jsxs(InputCard_styles.Card, {
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
4
|
var Checkbox = require('@ubnt/ui-components/Checkbox');
|
|
5
|
-
var
|
|
5
|
+
var React = require('react');
|
|
6
6
|
var Layout_styles = require('./Layout.styles.js');
|
|
7
7
|
"use strict";
|
|
8
8
|
const CheckboxSection = ({
|
|
@@ -13,7 +13,7 @@ const CheckboxSection = ({
|
|
|
13
13
|
checked,
|
|
14
14
|
disabled
|
|
15
15
|
}) => {
|
|
16
|
-
const handleChange =
|
|
16
|
+
const handleChange = React.useCallback(event => {
|
|
17
17
|
onChange(event.target.checked);
|
|
18
18
|
}, [onChange]);
|
|
19
19
|
return /* @__PURE__ */jsxRuntime.jsxs(Layout_styles.InputWrapper, {
|
|
@@ -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 styled = require('styled-components');
|
|
6
6
|
var asset = require('../../../../../../utils/asset.js');
|
|
7
7
|
require('../../../../../CustomImage/index.js');
|
|
@@ -11,8 +11,8 @@ require('../assets/plus.svg.js');
|
|
|
11
11
|
var Layout_styles = require('./Layout.styles.js');
|
|
12
12
|
var CustomImage = require('../../../../../CustomImage/CustomImage.js');
|
|
13
13
|
var StyleableSvgImage = require('../../../../../StyleableSvgImage/StyleableSvgImage.js');
|
|
14
|
-
var MinusIcon = require("../../../../../../assets/
|
|
15
|
-
var PlusIcon = require("../../../../../../assets/
|
|
14
|
+
var MinusIcon = require("../../../../../../assets/minus5.svg");
|
|
15
|
+
var PlusIcon = require("../../../../../../assets/plus6.svg");
|
|
16
16
|
function _interopDefault(e) {
|
|
17
17
|
return e && e.__esModule ? e : {
|
|
18
18
|
default: e
|
|
@@ -31,17 +31,17 @@ const CounterSection = ({
|
|
|
31
31
|
valueIcon,
|
|
32
32
|
disabled
|
|
33
33
|
}) => {
|
|
34
|
-
|
|
34
|
+
React.useEffect(() => {
|
|
35
35
|
if (value > max) {
|
|
36
36
|
onChange(max);
|
|
37
37
|
} else if (value < min) {
|
|
38
38
|
onChange(min);
|
|
39
39
|
}
|
|
40
40
|
}, [value, min, max, onChange]);
|
|
41
|
-
const handleIncrement =
|
|
41
|
+
const handleIncrement = React.useCallback(() => {
|
|
42
42
|
onChange(value + 1);
|
|
43
43
|
}, [value, onChange]);
|
|
44
|
-
const handleDecrement =
|
|
44
|
+
const handleDecrement = React.useCallback(() => {
|
|
45
45
|
onChange(value - 1);
|
|
46
46
|
}, [value, onChange]);
|
|
47
47
|
return /* @__PURE__ */jsxRuntime.jsxs(Layout_styles.InputWrapper, {
|
|
@@ -9,8 +9,8 @@ import '../assets/plus.svg.mjs';
|
|
|
9
9
|
import { InputWrapper, Label, InputFlexWrapper } from './Layout.styles.mjs';
|
|
10
10
|
import { CustomImage } from '../../../../../CustomImage/CustomImage.mjs';
|
|
11
11
|
import { StyleableSvgImage } from '../../../../../StyleableSvgImage/StyleableSvgImage.mjs';
|
|
12
|
-
import MinusIcon__default from "../../../../../../assets/
|
|
13
|
-
import PlusIcon__default from "../../../../../../assets/
|
|
12
|
+
import MinusIcon__default from "../../../../../../assets/minus5.svg";
|
|
13
|
+
import PlusIcon__default from "../../../../../../assets/plus6.svg";
|
|
14
14
|
"use strict";
|
|
15
15
|
const CounterSection = ({
|
|
16
16
|
value,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
var jsxRuntime = require('react/jsx-runtime');
|
|
4
4
|
var Slider = require('@ubnt/ui-components/Slider');
|
|
5
|
-
var
|
|
5
|
+
var React = require('react');
|
|
6
6
|
var styled = require('styled-components');
|
|
7
7
|
require('../../../../../StyleableSvgImage/index.js');
|
|
8
8
|
require('../assets/silder-grip.svg.js');
|
|
@@ -26,14 +26,14 @@ const SliderSection = ({
|
|
|
26
26
|
disabled,
|
|
27
27
|
hideSlider
|
|
28
28
|
}) => {
|
|
29
|
-
|
|
29
|
+
React.useEffect(() => {
|
|
30
30
|
if (value > max) {
|
|
31
31
|
onChange(max);
|
|
32
32
|
} else if (value < min) {
|
|
33
33
|
onChange(min);
|
|
34
34
|
}
|
|
35
35
|
}, [value, min, max, onChange]);
|
|
36
|
-
const handleChange =
|
|
36
|
+
const handleChange = React.useCallback(e => {
|
|
37
37
|
const value2 = parseInt(e.target.value, 10);
|
|
38
38
|
if (disabled) {
|
|
39
39
|
return;
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
var MinusIcon = require("../../../../../../assets/
|
|
6
|
+
var MinusIcon = require("../../../../../../assets/minus5.svg");
|
|
7
7
|
function _interopDefault(e) {
|
|
8
8
|
return e && e.__esModule ? e : {
|
|
9
9
|
default: e
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from "../../../../../../assets/
|
|
2
|
-
export { default } from "../../../../../../assets/
|
|
1
|
+
export * from "../../../../../../assets/minus5.svg";
|
|
2
|
+
export { default } from "../../../../../../assets/minus5.svg";
|
|
3
3
|
//# sourceMappingURL=minus.svg.mjs.map
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, '__esModule', {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
var PlusIcon = require("../../../../../../assets/
|
|
6
|
+
var PlusIcon = require("../../../../../../assets/plus6.svg");
|
|
7
7
|
function _interopDefault(e) {
|
|
8
8
|
return e && e.__esModule ? e : {
|
|
9
9
|
default: e
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from "../../../../../../assets/
|
|
2
|
-
export { default } from "../../../../../../assets/
|
|
1
|
+
export * from "../../../../../../assets/plus6.svg";
|
|
2
|
+
export { default } from "../../../../../../assets/plus6.svg";
|
|
3
3
|
//# sourceMappingURL=plus.svg.mjs.map
|
|
@@ -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 asset = require('../../../../../utils/asset.js');
|
|
6
6
|
require('./assets/attention.svg.js');
|
|
7
7
|
var Part = require('./Part.js');
|
|
@@ -21,9 +21,9 @@ const ProgressBarChart = ({
|
|
|
21
21
|
warnLabel,
|
|
22
22
|
warnThresholdPercentDecimal
|
|
23
23
|
}) => {
|
|
24
|
-
const progressBarRef =
|
|
25
|
-
const [progressBarContainerWidth, setProgressBarContainerWidth] =
|
|
26
|
-
|
|
24
|
+
const progressBarRef = React.useRef(null);
|
|
25
|
+
const [progressBarContainerWidth, setProgressBarContainerWidth] = React.useState(0);
|
|
26
|
+
React.useEffect(() => {
|
|
27
27
|
if (!progressBarRef.current) {
|
|
28
28
|
return;
|
|
29
29
|
}
|
|
@@ -35,7 +35,7 @@ const ProgressBarChart = ({
|
|
|
35
35
|
resizeObserver.observe(progressBarRef.current);
|
|
36
36
|
return () => resizeObserver.disconnect();
|
|
37
37
|
}, [setProgressBarContainerWidth, progressBarRef]);
|
|
38
|
-
const parts =
|
|
38
|
+
const parts = React.useMemo(() => {
|
|
39
39
|
const partsCount = Math.floor((progressBarContainerWidth + Part.PART_GAP_PX) / (Part.PART_WIDTH_PX + Part.PART_GAP_PX));
|
|
40
40
|
const parts2 = [];
|
|
41
41
|
for (let i = 0; i < partsCount; i++) {
|
|
@@ -43,10 +43,10 @@ const ProgressBarChart = ({
|
|
|
43
43
|
}
|
|
44
44
|
return parts2;
|
|
45
45
|
}, [progressBarContainerWidth]);
|
|
46
|
-
const isWarnLimitExceeded =
|
|
46
|
+
const isWarnLimitExceeded = React.useMemo(() => {
|
|
47
47
|
return warnThresholdPercentDecimal !== void 0 && warnThresholdPercentDecimal <= progressBarPercentDecimal;
|
|
48
48
|
}, [warnThresholdPercentDecimal, progressBarPercentDecimal]);
|
|
49
|
-
const mappedParts =
|
|
49
|
+
const mappedParts = React.useMemo(() => {
|
|
50
50
|
const lastActivePartIndex = Math.round(parts.length * progressBarPercentDecimal);
|
|
51
51
|
if (warnThresholdPercentDecimal && isWarnLimitExceeded) {
|
|
52
52
|
const thresholdPartIndex = Math.round(parts.length * warnThresholdPercentDecimal);
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var React = require('react');
|
|
4
4
|
var ComputeResourceCalculator_types = require('./ComputeResourceCalculator.types.js');
|
|
5
5
|
"use strict";
|
|
6
6
|
const useComputeResourceCalculator = ({
|
|
7
7
|
deviceResourceData,
|
|
8
8
|
inputs
|
|
9
9
|
}) => {
|
|
10
|
-
const networkResources =
|
|
10
|
+
const networkResources = React.useMemo(() => {
|
|
11
11
|
const networkDeviceResources = deviceResourceData.Network;
|
|
12
12
|
const networkInputs = inputs[ComputeResourceCalculator_types.FeatureId.Network];
|
|
13
13
|
if (!networkInputs.enabled || !networkDeviceResources) {
|
|
@@ -46,7 +46,7 @@ const useComputeResourceCalculator = ({
|
|
|
46
46
|
}
|
|
47
47
|
return sum;
|
|
48
48
|
}, [deviceResourceData, inputs]);
|
|
49
|
-
const protectResources =
|
|
49
|
+
const protectResources = React.useMemo(() => {
|
|
50
50
|
const protectDeviceResources = deviceResourceData.Protect;
|
|
51
51
|
const protectInputs = inputs[ComputeResourceCalculator_types.FeatureId.Protect];
|
|
52
52
|
const CAMERA_WEIGHT_FACTOR = 1.5;
|
|
@@ -76,7 +76,7 @@ const useComputeResourceCalculator = ({
|
|
|
76
76
|
}
|
|
77
77
|
return sum;
|
|
78
78
|
}, [deviceResourceData, inputs]);
|
|
79
|
-
const talkResources =
|
|
79
|
+
const talkResources = React.useMemo(() => {
|
|
80
80
|
const talkDeviceResources = deviceResourceData.Talk;
|
|
81
81
|
const talkInputs = inputs[ComputeResourceCalculator_types.FeatureId.Talk];
|
|
82
82
|
if (!talkInputs.enabled || !talkDeviceResources) {
|
|
@@ -100,7 +100,7 @@ const useComputeResourceCalculator = ({
|
|
|
100
100
|
}
|
|
101
101
|
return sum;
|
|
102
102
|
}, [deviceResourceData, inputs]);
|
|
103
|
-
const accessResources =
|
|
103
|
+
const accessResources = React.useMemo(() => {
|
|
104
104
|
const accessDeviceResources = deviceResourceData.Access;
|
|
105
105
|
const accessInputs = inputs[ComputeResourceCalculator_types.FeatureId.Access];
|
|
106
106
|
if (!accessInputs.enabled || !accessDeviceResources) {
|
|
@@ -119,7 +119,7 @@ const useComputeResourceCalculator = ({
|
|
|
119
119
|
}
|
|
120
120
|
return sum;
|
|
121
121
|
}, [deviceResourceData, inputs]);
|
|
122
|
-
const computedResourcesLoadRatio =
|
|
122
|
+
const computedResourcesLoadRatio = React.useMemo(() => {
|
|
123
123
|
return networkResources + talkResources + accessResources + protectResources;
|
|
124
124
|
}, [networkResources, talkResources, accessResources, protectResources]);
|
|
125
125
|
return {
|