@ubnt/store.core 9.53.0-alpha.5 → 9.53.0-alpha.6
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 +4 -0
- package/lib/_virtual/_virtual_multi-entry.js +14 -12
- package/lib/_virtual/_virtual_multi-entry.js.map +1 -1
- package/lib/_virtual/_virtual_multi-entry.mjs +14 -12
- package/lib/_virtual/_virtual_multi-entry.mjs.map +1 -1
- package/lib/assets/ai-bullet.jpg +0 -0
- package/lib/assets/ai-bullet2.jpg +0 -0
- package/lib/assets/ai-dslr.jpg +0 -0
- package/lib/assets/ai-dslr2.jpg +0 -0
- package/lib/assets/ai-turret.jpg +0 -0
- package/lib/assets/ai-turret2.jpg +0 -0
- package/lib/assets/building-bridge-xg.jpg +0 -0
- package/lib/assets/building-bridge-xg2.jpg +0 -0
- package/lib/assets/building-bridge.jpg +0 -0
- package/lib/assets/building-bridge2.jpg +0 -0
- package/lib/assets/close2.svg +2 -3
- package/lib/assets/close3.svg +3 -2
- package/lib/assets/g5-bullet.jpg +0 -0
- package/lib/assets/g5-bullet2.jpg +0 -0
- package/lib/assets/g5-dome.jpg +0 -0
- package/lib/assets/g5-dome2.jpg +0 -0
- package/lib/assets/industrial.jpg +0 -0
- package/lib/assets/industrial2.jpg +0 -0
- package/lib/assets/interior-design.svg +2 -2
- package/lib/assets/interior-design2.svg +2 -2
- package/lib/assets/minus4.svg +8 -8
- package/lib/assets/minus5.svg +8 -8
- package/lib/assets/plus6.svg +9 -9
- package/lib/assets/plus7.svg +9 -9
- package/lib/assets/reader-lite.jpg +0 -0
- package/lib/assets/reader-lite2.jpg +0 -0
- package/lib/components/Accordion/Accordion.js +4 -4
- package/lib/components/Avatar/Avatar.js +2 -2
- package/lib/components/Button/Button.js +6 -6
- package/lib/components/Button/CartButton.js +2 -2
- package/lib/components/CardSection/Card/Card.js +6 -6
- package/lib/components/CardSection/CardSection.js +2 -2
- package/lib/components/CartIcon/CartIcon.js +2 -2
- 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/Container/Container.js +2 -2
- package/lib/components/CustomImage/CustomImage.js +12 -12
- package/lib/components/Explore/Explore.js +5 -5
- 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 +19 -19
- 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/Header.js +34 -34
- package/lib/components/Header/IsolatedHeader.js +7 -7
- package/lib/components/Header/LanguageFrame/LanguageFrame.js +6 -6
- package/lib/components/Header/MobileLinksModal/MobileMenu.js +3 -3
- 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/MobileMenu/MobileMenu.js +6 -6
- package/lib/components/Header/Navigation/ProMobileMenu/ProMobileMenu.js +6 -6
- package/lib/components/Header/Overlay/Overlay.js +3 -3
- package/lib/components/Header/ProHeader/ProHeader.js +35 -35
- package/lib/components/Hero/Hero.js +5 -5
- package/lib/components/HeroVideo/HeroVideo.js +5 -5
- package/lib/components/ImageCarousel/ImageCarousel.js +29 -29
- 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/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/MeetUniFiVideoPlayer/EpisodeCard/EpisodeCard.js +7 -7
- package/lib/components/MeetUniFiVideoPlayer/MeetUniFiVideoPlayer.js +18 -18
- 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/MicrositeHeader/MicrositeHeader.js +4 -4
- package/lib/components/MicrositeHeader/components/DropdownMenu/DropdownMenu.js +4 -4
- package/lib/components/MicrositeHeader/components/HeaderContent/HeaderContent.js +13 -13
- package/lib/components/MicrositeHeader/components/SiteMap/SiteMap.js +2 -2
- package/lib/components/MicrositeHeader/components/SiteMapColumns/SiteMapColumns.js +15 -15
- package/lib/components/MicrositeHeader/components/VisualTopology/LinePaths.js +3 -3
- package/lib/components/MicrositeHeader/components/VisualTopology/VisualTopology.js +9 -9
- 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/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/ModelCompareV4/CompareTable/CompareTable.js +8 -8
- package/lib/components/ModelCompareV4/CompareTable/CompareTableMarkup.js +14 -14
- package/lib/components/ModelCompareV4/CompareTable/CompareTableOverflowScrollButton.js +3 -3
- package/lib/components/ModelCompareV4/CompareTable/PropertyValueGridItem.js +2 -2
- package/lib/components/ModelCompareV4/CompareTable/ScrollGroup/ScrollGroup.js +5 -5
- package/lib/components/ModelCompareV4/CompareTable/ScrollGroup/context.js +3 -3
- package/lib/components/ModelCompareV4/CompareTable/ScrollGroup/useScrollGroupItem.js +8 -8
- package/lib/components/ModelCompareV4/CompareTable/ScrollGroup/useScrollGroupSetScroll.js +2 -2
- package/lib/components/ModelCompareV4/CompareTable/ScrollGroup/useScrollGroupTo.js +2 -2
- package/lib/components/ModelCompareV4/CompareTable/StickyGrid/StickyGrid.js +7 -7
- package/lib/components/ModelCompareV4/CompareTable/StickyGrid/StickyGridBody.js +2 -2
- package/lib/components/ModelCompareV4/CompareTable/StickyGrid/StickyGridHeader.js +5 -5
- package/lib/components/ModelCompareV4/CompareTable/StickyGrid/StickyGridItem.js +2 -2
- package/lib/components/ModelCompareV4/CompareTable/StickyGrid/context.js +3 -3
- package/lib/components/ModelCompareV4/ModelCompareV4.js +5 -5
- package/lib/components/ModelCompareV4/ProductList/ProductList.js +11 -11
- 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/ProductSectionTabs/ProductSectionTabs.js +2 -2
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.d.ts +2 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.js +79 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.js.map +1 -0
- package/lib/components/ProductTechSpecsV2/ProductTechSpecs.mjs +71 -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 +4 -4
- 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.js +17 -17
- package/lib/components/Search/Input/Input.js +4 -4
- 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/TogglableStaticCompareTables/TogglableStaticCompareTable.js +8 -8
- 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 +20 -20
- package/lib/components/VideoPlayerNew/VideoPlayer.mjs +1 -1
- package/lib/components/VideoPlayerNew/assets/close.svg.js +1 -1
- package/lib/components/VideoPlayerNew/assets/close.svg.mjs +2 -2
- 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/modelCompareData/assets/BuildingBridge/building-bridge-xg.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/BuildingBridge/building-bridge-xg.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/BuildingBridge/building-bridge.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/BuildingBridge/building-bridge.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/Bullet/ai-bullet.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/Bullet/ai-bullet.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/Bullet/ai-dslr.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/Bullet/ai-dslr.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/Bullet/g5-bullet.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/Bullet/g5-bullet.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/DomeTurret/ai-turret.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/DomeTurret/ai-turret.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/DomeTurret/g5-dome.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/DomeTurret/g5-dome.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/DoorAccess/reader-lite.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/DoorAccess/reader-lite.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/Switching/industrial.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/Switching/industrial.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/interior-design.svg.js +1 -1
- package/lib/constants/modelCompareData/assets/interior-design.svg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/bullet/ai-bullet.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/bullet/ai-bullet.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/bullet/ai-dslr.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/bullet/ai-dslr.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/bullet/g5-bullet.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/bullet/g5-bullet.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/dome-and-turret/ai-turret.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/dome-and-turret/ai-turret.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/dome-and-turret/g5-dome.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/dome-and-turret/g5-dome.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/door-access/reader-lite.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/product-list-assets/cameras/door-access/reader-lite.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/product-list-assets/interior-design.svg.js +1 -1
- package/lib/constants/modelCompareData/assets/product-list-assets/interior-design.svg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/product-list-assets/switches/utility/industrial.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/product-list-assets/switches/utility/industrial.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/product-list-assets/wifi/building-bridge/building-bridge-xg.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/product-list-assets/wifi/building-bridge/building-bridge-xg.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/assets/product-list-assets/wifi/building-bridge/building-bridge.jpg.js +1 -1
- package/lib/constants/modelCompareData/assets/product-list-assets/wifi/building-bridge/building-bridge.jpg.mjs +2 -2
- package/lib/constants/modelCompareData/data/button-groups/interiorDesign.js +1 -1
- package/lib/constants/modelCompareData/data/button-groups/interiorDesign.mjs +1 -1
- package/lib/constants/modelCompareData/data/product-groups/cameraSecurity/InteriorDesign.js +1 -1
- package/lib/constants/modelCompareData/data/product-groups/cameraSecurity/InteriorDesign.mjs +1 -1
- package/lib/constants/modelCompareData/data/products/aiBullet.js +2 -2
- package/lib/constants/modelCompareData/data/products/aiBullet.mjs +2 -2
- package/lib/constants/modelCompareData/data/products/aiDslr.js +2 -2
- package/lib/constants/modelCompareData/data/products/aiDslr.mjs +2 -2
- package/lib/constants/modelCompareData/data/products/aiTurret.js +2 -2
- package/lib/constants/modelCompareData/data/products/aiTurret.mjs +2 -2
- package/lib/constants/modelCompareData/data/products/buildingBridge.js +2 -2
- package/lib/constants/modelCompareData/data/products/buildingBridge.mjs +2 -2
- package/lib/constants/modelCompareData/data/products/buildingBridgeXG.js +2 -2
- package/lib/constants/modelCompareData/data/products/buildingBridgeXG.mjs +2 -2
- package/lib/constants/modelCompareData/data/products/g5Bullet.js +2 -2
- package/lib/constants/modelCompareData/data/products/g5Bullet.mjs +2 -2
- package/lib/constants/modelCompareData/data/products/g5Dome.js +2 -2
- package/lib/constants/modelCompareData/data/products/g5Dome.mjs +2 -2
- package/lib/constants/modelCompareData/data/products/industrial.js +2 -2
- package/lib/constants/modelCompareData/data/products/industrial.mjs +2 -2
- package/lib/constants/modelCompareData/data/products/readerLite.js +2 -2
- package/lib/constants/modelCompareData/data/products/readerLite.mjs +2 -2
- package/lib/contexts/MenuContext/context.js +35 -35
- package/lib/contexts/MicrositeMenuContext/context.js +9 -9
- package/lib/helpers/proStoreCategories.js +2 -2
- 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
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ProductTechSpecs.js","sources":["../../../src/components/ProductTechSpecsV2/ProductTechSpecs.tsx"],"sourcesContent":["import React, { useCallback, useMemo } from \"react\";\n\nimport * as S from \"./ProductTechSpecs.styles\";\nimport type { ProductTechSpecsProps } from \"./ProductTechSpecs.types\";\n\nexport const ProductTechSpecs = ({\n sections,\n}: ProductTechSpecsProps): JSX.Element => {\n /**\n * Break value into lines\n */\n const renderFeatureValue = useCallback((value: string): JSX.Element => {\n const lines = value.split(\"\\n\");\n return (\n <S.Cell>\n {lines.map((line, i) => (\n <React.Fragment key={i}>\n {i > 0 && <br />}\n {line}\n </React.Fragment>\n ))}\n </S.Cell>\n );\n }, []);\n\n const parsedSections = useMemo(() => {\n return sections.map((section) => {\n const { withParentId, withoutParentId } = section.features.reduce<{\n withParentId: ProductTechSpecsProps[\"sections\"][number][\"features\"];\n withoutParentId: ProductTechSpecsProps[\"sections\"][number][\"features\"];\n }>(\n (acc, feature) => {\n if (feature.parentId === null) {\n acc.withoutParentId.push(feature);\n } else {\n acc.withParentId.push(feature);\n }\n return acc;\n },\n { withParentId: [], withoutParentId: [] },\n );\n\n const features = withoutParentId.map((parentFeature) => {\n const children = withParentId.filter(\n (childFeature) => childFeature.parentId === parentFeature.id,\n );\n return {\n ...parentFeature,\n children,\n };\n });\n\n return {\n id: section.id,\n label: section.label,\n features,\n };\n });\n }, [sections]);\n\n console.log(parsedSections);\n\n return (\n <S.Wrap>\n {parsedSections.map((section, i) => (\n <React.Fragment key={section.id}>\n {i > 0 && <S.SectionDivider />}\n {/* Section heading */}\n <S.Row>\n <S.Heading>{section.label}</S.Heading>\n </S.Row>\n\n {/* Section feature key value pairs */}\n {section.features.map((feature) => (\n <React.Fragment key={feature.id}>\n <S.Row key={feature.id}>\n <S.Cell>{feature.label}</S.Cell>\n {feature.value && renderFeatureValue(feature.value)}\n </S.Row>\n\n {/* Child features */}\n {feature.children.length > 0 &&\n feature.children.map((childFeature, i) => (\n <S.Row key={childFeature.id}>\n <S.Tree $isLast={i === feature.children.length - 1} />\n <S.Branch />\n\n <S.Cell $isChildRowFirstCell>{childFeature.label}</S.Cell>\n {childFeature.value &&\n renderFeatureValue(childFeature.value)}\n </S.Row>\n ))}\n </React.Fragment>\n ))}\n </React.Fragment>\n ))}\n </S.Wrap>\n );\n};\n"],"names":["ProductTechSpecs","sections","renderFeatureValue","useCallback","value","lines","split","jsx","S.Cell","Cell","children","map","line","i","jsxs","React","Fragment","parsedSections","useMemo","section","withParentId","withoutParentId","features","reduce","acc","feature","parentId","push","parentFeature","filter","childFeature","id","label","console","log","S.Wrap","Wrap","S.SectionDivider","S.Row","Row","S.Heading","length","S.Tree","$isLast","S.Branch","Branch","$isChildRowFirstCell"],"mappings":";;;;;;;;;;;;AAKO,MAAMA,mBAAmBA,CAAC;EAC/BC;AACF,CAA0C,KAAA;EAIlC,MAAAC,kBAAA,GAAqBC,iBAAY,CAACC,KAA+B,IAAA;IAC/D,M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AAf,QAAA,CAASC,GAAI,CAAA,CAACmB,YAAcjB,EAAAA,EAAAA,KAAAA,eACjCC,UAAA,CAAAA,IAAA,CAAAwB,6BAAA;UACC5B,QAAA,EAAA,CAAA,eAACH,cAAA,CAAAmC,uBAAAA,CAAAA,MAAA;YAAOC,OAAA,EAAS9B,OAAMY,OAAQ,CAAAf,QAAA,CAAS+B,SAAS;WAAG,CAAA,EAAA,eACpDlC,UAAA,CAAAA,GAAA,CAACqC,uBAAE,CAAAC,MAAA,EAAF,EAAS,CAAA,EAAA,8BAETrC,uBAAE,CAAAC,IAAA,EAAF;YAAOqC,oBAAoB,EAAA,IAAA;YAAEpC,uBAAasB;WAAM,CAAA,EAChDF,YAAa,CAAA1B,KAAA,IACZF,kBAAmB,CAAA4B,YAAA,CAAa1B,KAAK,CAAA;SAN7B,EAAA0B,YAAA,CAAaC,EAOzB,CACD,CAAA;OAjBgB,EAAAN,OAAA,CAAQM,EAkB7B,CACD,CAAA;IA5BkB,CAAA,EAAAZ,OAAA,CAAQY,EA6B7B,CACD;EACH,CAAA,CAAA;AAEJ,CAAA;"}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { jsx, jsxs } from 'react/jsx-runtime';
|
|
2
|
+
import React, { useCallback, useMemo } from 'react';
|
|
3
|
+
import { Cell, Wrap, SectionDivider, Row, Heading, Tree, Branch } from './ProductTechSpecs.styles.mjs';
|
|
4
|
+
"use strict";
|
|
5
|
+
const ProductTechSpecs = ({
|
|
6
|
+
sections
|
|
7
|
+
}) => {
|
|
8
|
+
const renderFeatureValue = useCallback(value => {
|
|
9
|
+
const lines = value.split("\n");
|
|
10
|
+
return /* @__PURE__ */jsx(Cell, {
|
|
11
|
+
children: lines.map((line, i) => /* @__PURE__ */jsxs(React.Fragment, {
|
|
12
|
+
children: [i > 0 && /* @__PURE__ */jsx("br", {}), line]
|
|
13
|
+
}, i))
|
|
14
|
+
});
|
|
15
|
+
}, []);
|
|
16
|
+
const parsedSections = useMemo(() => {
|
|
17
|
+
return sections.map(section => {
|
|
18
|
+
const {
|
|
19
|
+
withParentId,
|
|
20
|
+
withoutParentId
|
|
21
|
+
} = section.features.reduce((acc, feature) => {
|
|
22
|
+
if (feature.parentId === null) {
|
|
23
|
+
acc.withoutParentId.push(feature);
|
|
24
|
+
} else {
|
|
25
|
+
acc.withParentId.push(feature);
|
|
26
|
+
}
|
|
27
|
+
return acc;
|
|
28
|
+
}, {
|
|
29
|
+
withParentId: [],
|
|
30
|
+
withoutParentId: []
|
|
31
|
+
});
|
|
32
|
+
const features = withoutParentId.map(parentFeature => {
|
|
33
|
+
const children = withParentId.filter(childFeature => childFeature.parentId === parentFeature.id);
|
|
34
|
+
return {
|
|
35
|
+
...parentFeature,
|
|
36
|
+
children
|
|
37
|
+
};
|
|
38
|
+
});
|
|
39
|
+
return {
|
|
40
|
+
id: section.id,
|
|
41
|
+
label: section.label,
|
|
42
|
+
features
|
|
43
|
+
};
|
|
44
|
+
});
|
|
45
|
+
}, [sections]);
|
|
46
|
+
console.log(parsedSections);
|
|
47
|
+
return /* @__PURE__ */jsx(Wrap, {
|
|
48
|
+
children: parsedSections.map((section, i) => /* @__PURE__ */jsxs(React.Fragment, {
|
|
49
|
+
children: [i > 0 && /* @__PURE__ */jsx(SectionDivider, {}), /* @__PURE__ */jsx(Row, {
|
|
50
|
+
children: /* @__PURE__ */jsx(Heading, {
|
|
51
|
+
children: section.label
|
|
52
|
+
})
|
|
53
|
+
}), section.features.map(feature => /* @__PURE__ */jsxs(React.Fragment, {
|
|
54
|
+
children: [/* @__PURE__ */jsxs(Row, {
|
|
55
|
+
children: [/* @__PURE__ */jsx(Cell, {
|
|
56
|
+
children: feature.label
|
|
57
|
+
}), feature.value && renderFeatureValue(feature.value)]
|
|
58
|
+
}, feature.id), feature.children.length > 0 && feature.children.map((childFeature, i2) => /* @__PURE__ */jsxs(Row, {
|
|
59
|
+
children: [/* @__PURE__ */jsx(Tree, {
|
|
60
|
+
$isLast: i2 === feature.children.length - 1
|
|
61
|
+
}), /* @__PURE__ */jsx(Branch, {}), /* @__PURE__ */jsx(Cell, {
|
|
62
|
+
$isChildRowFirstCell: true,
|
|
63
|
+
children: childFeature.label
|
|
64
|
+
}), childFeature.value && renderFeatureValue(childFeature.value)]
|
|
65
|
+
}, childFeature.id))]
|
|
66
|
+
}, feature.id))]
|
|
67
|
+
}, section.id))
|
|
68
|
+
});
|
|
69
|
+
};
|
|
70
|
+
export { ProductTechSpecs };
|
|
71
|
+
//# sourceMappingURL=ProductTechSpecs.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ProductTechSpecs.mjs","sources":["../../../src/components/ProductTechSpecsV2/ProductTechSpecs.tsx"],"sourcesContent":["import React, { useCallback, useMemo } from \"react\";\n\nimport * as S from \"./ProductTechSpecs.styles\";\nimport type { ProductTechSpecsProps } from \"./ProductTechSpecs.types\";\n\nexport const ProductTechSpecs = ({\n sections,\n}: ProductTechSpecsProps): JSX.Element => {\n /**\n * Break value into lines\n */\n const renderFeatureValue = useCallback((value: string): JSX.Element => {\n const lines = value.split(\"\\n\");\n return (\n <S.Cell>\n {lines.map((line, i) => (\n <React.Fragment key={i}>\n {i > 0 && <br />}\n {line}\n </React.Fragment>\n ))}\n </S.Cell>\n );\n }, []);\n\n const parsedSections = useMemo(() => {\n return sections.map((section) => {\n const { withParentId, withoutParentId } = section.features.reduce<{\n withParentId: ProductTechSpecsProps[\"sections\"][number][\"features\"];\n withoutParentId: ProductTechSpecsProps[\"sections\"][number][\"features\"];\n }>(\n (acc, feature) => {\n if (feature.parentId === null) {\n acc.withoutParentId.push(feature);\n } else {\n acc.withParentId.push(feature);\n }\n return acc;\n },\n { withParentId: [], withoutParentId: [] },\n );\n\n const features = withoutParentId.map((parentFeature) => {\n const children = withParentId.filter(\n (childFeature) => childFeature.parentId === parentFeature.id,\n );\n return {\n ...parentFeature,\n children,\n };\n });\n\n return {\n id: section.id,\n label: section.label,\n features,\n };\n });\n }, [sections]);\n\n console.log(parsedSections);\n\n return (\n <S.Wrap>\n {parsedSections.map((section, i) => (\n <React.Fragment key={section.id}>\n {i > 0 && <S.SectionDivider />}\n {/* Section heading */}\n <S.Row>\n <S.Heading>{section.label}</S.Heading>\n </S.Row>\n\n {/* Section feature key value pairs */}\n {section.features.map((feature) => (\n <React.Fragment key={feature.id}>\n <S.Row key={feature.id}>\n <S.Cell>{feature.label}</S.Cell>\n {feature.value && renderFeatureValue(feature.value)}\n </S.Row>\n\n {/* Child features */}\n {feature.children.length > 0 &&\n feature.children.map((childFeature, i) => (\n <S.Row key={childFeature.id}>\n <S.Tree $isLast={i === feature.children.length - 1} />\n <S.Branch />\n\n <S.Cell $isChildRowFirstCell>{childFeature.label}</S.Cell>\n {childFeature.value &&\n renderFeatureValue(childFeature.value)}\n </S.Row>\n ))}\n </React.Fragment>\n ))}\n </React.Fragment>\n ))}\n </S.Wrap>\n );\n};\n"],"names":["ProductTechSpecs","sections","renderFeatureValue","useCallback","value","lines","split","jsx","S.Cell","children","map","line","i","jsxs","React","Fragment","parsedSections","useMemo","section","withParentId","withoutParentId","features","reduce","acc","feature","parentId","push","parentFeature","filter","childFeature","id","label","console","log","S.Wrap","S.SectionDivider","S.Row","S.Heading","length","S.Tree","$isLast","S.Branch","$isChildRowFirstCell"],"mappings":";;;;AAKO,MAAMA,mBAAmBA,CAAC;EAC/BC;AACF,CAA0C,KAAA;EAIlC,MAAAC,kBAAA,GAAqBC,WAAY,CAACC,KAA+B,IAAA;IAC/D,MAAAC,KAAA,GAAQD,KAAM,CAAAE,KAAA,CAAM,IAAI,CAAA;IAC9B,OAAA,eACGC,GAAA,CAAAC,IAAA,EAAA;MACEC,QAAM,EAAAJ,KAAA,CAAAK,GAAA,CAAI,CAACC,IAAA,EAAMC,CAChB,KAAA,eAAAC,IAAA,CAACC,KAAM,CAAAC,QAAA,EAAN;QACEN,QAAA,EAAA,CAAIG,CAAA,GAAA,CAAA,IAAA,mBAAM,IAAG,EAAA,CAAA,CAAA,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;EACH,CAAA,CAAA;AAEJ,CAAA;"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { Meta } from "@storybook/react";
|
|
2
|
+
import { ProductTechSpecs } from "./ProductTechSpecs";
|
|
3
|
+
declare const _default: Meta<typeof ProductTechSpecs>;
|
|
4
|
+
export default _default;
|
|
5
|
+
export declare const Base: import("@storybook/core/types").AnnotatedStoryFn<import("@storybook/react").ReactRenderer, import("./ProductTechSpecs.types").ProductTechSpecsProps>;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export declare const Wrap: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
2
|
+
export declare const Row: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
3
|
+
export declare const Heading: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
4
|
+
export declare const SectionDivider: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
5
|
+
export declare const Cell: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
6
|
+
$isChildRowFirstCell?: boolean;
|
|
7
|
+
}, never>;
|
|
8
|
+
export declare const Tree: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {
|
|
9
|
+
$isLast: boolean;
|
|
10
|
+
}, never>;
|
|
11
|
+
export declare const Branch: import("styled-components").StyledComponent<"div", import("styled-components").DefaultTheme, {}, never>;
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var styled = require('styled-components');
|
|
4
|
+
var layout = require('../../constants/layout.js');
|
|
5
|
+
function _interopDefault(e) {
|
|
6
|
+
return e && e.__esModule ? e : {
|
|
7
|
+
default: e
|
|
8
|
+
};
|
|
9
|
+
}
|
|
10
|
+
var styled__default = /*#__PURE__*/_interopDefault(styled);
|
|
11
|
+
"use strict";
|
|
12
|
+
const TABLE_LEFT_MARGIN = "0px";
|
|
13
|
+
const TREE_LEFT_MARGIN = "8px";
|
|
14
|
+
const Wrap = styled__default["default"].div``;
|
|
15
|
+
const Row = styled__default["default"].div`
|
|
16
|
+
display: grid;
|
|
17
|
+
grid-template-columns: 300px 1fr;
|
|
18
|
+
position: relative;
|
|
19
|
+
&:hover: {
|
|
20
|
+
background-color: #f9f9f9;
|
|
21
|
+
}
|
|
22
|
+
padding-left: ${TABLE_LEFT_MARGIN};
|
|
23
|
+
|
|
24
|
+
@media ${layout.BREAKPOINTS.MOBILE_AND_DOWN} {
|
|
25
|
+
grid-template-columns: 170px 1fr;
|
|
26
|
+
}
|
|
27
|
+
`;
|
|
28
|
+
const Heading = styled__default["default"].div`
|
|
29
|
+
font-size: 20px;
|
|
30
|
+
line-height: 24px;
|
|
31
|
+
font-weight: 700;
|
|
32
|
+
color: #212427;
|
|
33
|
+
margin-bottom: 16px;
|
|
34
|
+
grid-column: 1 / 3;
|
|
35
|
+
`;
|
|
36
|
+
const SectionDivider = styled__default["default"].div`
|
|
37
|
+
height: 1px;
|
|
38
|
+
background-color: #dbdce1;
|
|
39
|
+
margin: 16px 0;
|
|
40
|
+
grid-column: 1 / 3;
|
|
41
|
+
`;
|
|
42
|
+
const Cell = styled__default["default"].div`
|
|
43
|
+
padding: 8px 28px 8px 0;
|
|
44
|
+
font-size: 14px;
|
|
45
|
+
line-height: 20px;
|
|
46
|
+
color: #50565e;
|
|
47
|
+
${({
|
|
48
|
+
$isChildRowFirstCell
|
|
49
|
+
}) => $isChildRowFirstCell && "margin-left: 24px;"}
|
|
50
|
+
`;
|
|
51
|
+
const Tree = styled__default["default"].div`
|
|
52
|
+
${({
|
|
53
|
+
$isLast
|
|
54
|
+
}) => $isLast ? "height: 18px" : "height: 100%"};
|
|
55
|
+
position: absolute;
|
|
56
|
+
top: 0;
|
|
57
|
+
left: calc(${TABLE_LEFT_MARGIN} + ${TREE_LEFT_MARGIN});
|
|
58
|
+
width: 1px;
|
|
59
|
+
background-color: #c5c5c5;
|
|
60
|
+
display: flex;
|
|
61
|
+
justify-content: center;
|
|
62
|
+
align-items: center;
|
|
63
|
+
z-index: 1;
|
|
64
|
+
`;
|
|
65
|
+
const Branch = styled__default["default"].div`
|
|
66
|
+
position: absolute;
|
|
67
|
+
left: calc(${TABLE_LEFT_MARGIN} + ${TREE_LEFT_MARGIN});
|
|
68
|
+
top: 17px;
|
|
69
|
+
width: 11px;
|
|
70
|
+
height: 1px;
|
|
71
|
+
background-color: #c5c5c5;
|
|
72
|
+
`;
|
|
73
|
+
exports.Branch = Branch;
|
|
74
|
+
exports.Cell = Cell;
|
|
75
|
+
exports.Heading = Heading;
|
|
76
|
+
exports.Row = Row;
|
|
77
|
+
exports.SectionDivider = SectionDivider;
|
|
78
|
+
exports.Tree = Tree;
|
|
79
|
+
exports.Wrap = Wrap;
|
|
80
|
+
//# sourceMappingURL=ProductTechSpecs.styles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ProductTechSpecs.styles.js","sources":["../../../src/components/ProductTechSpecsV2/ProductTechSpecs.styles.tsx"],"sourcesContent":["import styled from \"styled-components\";\n\nimport { BREAKPOINTS } from \"../../constants/layout\";\n\nconst TABLE_LEFT_MARGIN = \"0px\";\nconst TREE_LEFT_MARGIN = \"8px\";\n\nexport const Wrap = styled.div``;\n\nexport const Row = styled.div`\n display: grid;\n grid-template-columns: 300px 1fr;\n position: relative;\n &:hover: {\n background-color: #f9f9f9;\n }\n padding-left: ${TABLE_LEFT_MARGIN};\n\n @media ${BREAKPOINTS.MOBILE_AND_DOWN} {\n grid-template-columns: 170px 1fr;\n }\n`;\n\nexport const Heading = styled.div`\n font-size: 20px;\n line-height: 24px;\n font-weight: 700;\n color: #212427;\n margin-bottom: 16px;\n grid-column: 1 / 3;\n`;\n\nexport const SectionDivider = styled.div`\n height: 1px;\n background-color: #dbdce1;\n margin: 16px 0;\n grid-column: 1 / 3;\n`;\n\nexport const Cell = styled.div<{\n // Cell is a child and its the first item on the row.\n $isChildRowFirstCell?: boolean;\n}>`\n padding: 8px 28px 8px 0;\n font-size: 14px;\n line-height: 20px;\n color: #50565e;\n ${({ $isChildRowFirstCell }) => $isChildRowFirstCell && \"margin-left: 24px;\"}\n`;\n\nexport const Tree = styled.div<{\n $isLast: boolean;\n}>`\n ${({ $isLast }) => ($isLast ? \"height: 18px\" : \"height: 100%\")};\n position: absolute;\n top: 0;\n left: calc(${TABLE_LEFT_MARGIN} + ${TREE_LEFT_MARGIN});\n width: 1px;\n background-color: #c5c5c5;\n display: flex;\n justify-content: center;\n align-items: center;\n z-index: 1;\n`;\n\nexport const Branch = styled.div`\n position: absolute;\n left: calc(${TABLE_LEFT_MARGIN} + ${TREE_LEFT_MARGIN});\n top: 17px;\n width: 11px;\n height: 1px;\n background-color: #c5c5c5;\n`;\n"],"names":["TABLE_LEFT_MARGIN","TREE_LEFT_MARGIN","Wrap","styled","div","Row","BREAKPOINTS","MOBILE_AND_DOWN","Heading","SectionDivider","Cell","$isChildRowFirstCell","Tree","$isLast","Branch"],"mappings":";;;;;;;;;;;AAIA,MAAMA,iBAAoB,GAAA,KAAA;AAC1B,MAAMC,gBAAmB,GAAA,KAAA;AAElB,MAAMC,OAAOC,eAAAA,CAAAA,SAAAA,CAAO,CAAAC,GAAA,EAAA;AAEpB,MAAMC,MAAMF,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAORJ,iBAAiB;AAAA;AAAA,WAExBM,MAAAA,CAAAA,YAAYC,eAAe;AAAA;AAAA;AAAA,CAAA;AAK/B,MAAMC,UAAUL,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AASvB,MAAMK,iBAAiBN,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAO9B,MAAMM,OAAOP,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAQvB,CAAC;EAAEO;CAAqB,KAAMA,wBAAwB,oBAAoB;AAAA,CAAA;AAGvE,MAAMC,OAAOT,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA,IAGvB,CAAC;EAAES;AAAA,CAAe,KAAAA,OAAA,GAAU,iBAAiB,cAAe;AAAA;AAAA;AAAA,eAGjDb,iBAAiB,MAAMC,gBAAgB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAS/C,MAAMa,SAASX,eAAO,CAAA,SAAA,CAAA,CAAAC,GAAA;AAAA;AAAA,eAEdJ,iBAAiB,MAAMC,gBAAgB;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;;;;;;;"}
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import styled from 'styled-components';
|
|
2
|
+
import { BREAKPOINTS } from '../../constants/layout.mjs';
|
|
3
|
+
"use strict";
|
|
4
|
+
const TABLE_LEFT_MARGIN = "0px";
|
|
5
|
+
const TREE_LEFT_MARGIN = "8px";
|
|
6
|
+
const Wrap = styled.div``;
|
|
7
|
+
const Row = styled.div`
|
|
8
|
+
display: grid;
|
|
9
|
+
grid-template-columns: 300px 1fr;
|
|
10
|
+
position: relative;
|
|
11
|
+
&:hover: {
|
|
12
|
+
background-color: #f9f9f9;
|
|
13
|
+
}
|
|
14
|
+
padding-left: ${TABLE_LEFT_MARGIN};
|
|
15
|
+
|
|
16
|
+
@media ${BREAKPOINTS.MOBILE_AND_DOWN} {
|
|
17
|
+
grid-template-columns: 170px 1fr;
|
|
18
|
+
}
|
|
19
|
+
`;
|
|
20
|
+
const Heading = styled.div`
|
|
21
|
+
font-size: 20px;
|
|
22
|
+
line-height: 24px;
|
|
23
|
+
font-weight: 700;
|
|
24
|
+
color: #212427;
|
|
25
|
+
margin-bottom: 16px;
|
|
26
|
+
grid-column: 1 / 3;
|
|
27
|
+
`;
|
|
28
|
+
const SectionDivider = styled.div`
|
|
29
|
+
height: 1px;
|
|
30
|
+
background-color: #dbdce1;
|
|
31
|
+
margin: 16px 0;
|
|
32
|
+
grid-column: 1 / 3;
|
|
33
|
+
`;
|
|
34
|
+
const Cell = styled.div`
|
|
35
|
+
padding: 8px 28px 8px 0;
|
|
36
|
+
font-size: 14px;
|
|
37
|
+
line-height: 20px;
|
|
38
|
+
color: #50565e;
|
|
39
|
+
${({
|
|
40
|
+
$isChildRowFirstCell
|
|
41
|
+
}) => $isChildRowFirstCell && "margin-left: 24px;"}
|
|
42
|
+
`;
|
|
43
|
+
const Tree = styled.div`
|
|
44
|
+
${({
|
|
45
|
+
$isLast
|
|
46
|
+
}) => $isLast ? "height: 18px" : "height: 100%"};
|
|
47
|
+
position: absolute;
|
|
48
|
+
top: 0;
|
|
49
|
+
left: calc(${TABLE_LEFT_MARGIN} + ${TREE_LEFT_MARGIN});
|
|
50
|
+
width: 1px;
|
|
51
|
+
background-color: #c5c5c5;
|
|
52
|
+
display: flex;
|
|
53
|
+
justify-content: center;
|
|
54
|
+
align-items: center;
|
|
55
|
+
z-index: 1;
|
|
56
|
+
`;
|
|
57
|
+
const Branch = styled.div`
|
|
58
|
+
position: absolute;
|
|
59
|
+
left: calc(${TABLE_LEFT_MARGIN} + ${TREE_LEFT_MARGIN});
|
|
60
|
+
top: 17px;
|
|
61
|
+
width: 11px;
|
|
62
|
+
height: 1px;
|
|
63
|
+
background-color: #c5c5c5;
|
|
64
|
+
`;
|
|
65
|
+
export { Branch, Cell, Heading, Row, SectionDivider, Tree, Wrap };
|
|
66
|
+
//# sourceMappingURL=ProductTechSpecs.styles.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ProductTechSpecs.styles.mjs","sources":["../../../src/components/ProductTechSpecsV2/ProductTechSpecs.styles.tsx"],"sourcesContent":["import styled from \"styled-components\";\n\nimport { BREAKPOINTS } from \"../../constants/layout\";\n\nconst TABLE_LEFT_MARGIN = \"0px\";\nconst TREE_LEFT_MARGIN = \"8px\";\n\nexport const Wrap = styled.div``;\n\nexport const Row = styled.div`\n display: grid;\n grid-template-columns: 300px 1fr;\n position: relative;\n &:hover: {\n background-color: #f9f9f9;\n }\n padding-left: ${TABLE_LEFT_MARGIN};\n\n @media ${BREAKPOINTS.MOBILE_AND_DOWN} {\n grid-template-columns: 170px 1fr;\n }\n`;\n\nexport const Heading = styled.div`\n font-size: 20px;\n line-height: 24px;\n font-weight: 700;\n color: #212427;\n margin-bottom: 16px;\n grid-column: 1 / 3;\n`;\n\nexport const SectionDivider = styled.div`\n height: 1px;\n background-color: #dbdce1;\n margin: 16px 0;\n grid-column: 1 / 3;\n`;\n\nexport const Cell = styled.div<{\n // Cell is a child and its the first item on the row.\n $isChildRowFirstCell?: boolean;\n}>`\n padding: 8px 28px 8px 0;\n font-size: 14px;\n line-height: 20px;\n color: #50565e;\n ${({ $isChildRowFirstCell }) => $isChildRowFirstCell && \"margin-left: 24px;\"}\n`;\n\nexport const Tree = styled.div<{\n $isLast: boolean;\n}>`\n ${({ $isLast }) => ($isLast ? \"height: 18px\" : \"height: 100%\")};\n position: absolute;\n top: 0;\n left: calc(${TABLE_LEFT_MARGIN} + ${TREE_LEFT_MARGIN});\n width: 1px;\n background-color: #c5c5c5;\n display: flex;\n justify-content: center;\n align-items: center;\n z-index: 1;\n`;\n\nexport const Branch = styled.div`\n position: absolute;\n left: calc(${TABLE_LEFT_MARGIN} + ${TREE_LEFT_MARGIN});\n top: 17px;\n width: 11px;\n height: 1px;\n background-color: #c5c5c5;\n`;\n"],"names":["TABLE_LEFT_MARGIN","TREE_LEFT_MARGIN","Wrap","styled","div","Row","BREAKPOINTS","MOBILE_AND_DOWN","Heading","SectionDivider","Cell","$isChildRowFirstCell","Tree","$isLast","Branch"],"mappings":";;;AAIA,MAAMA,iBAAoB,GAAA,KAAA;AAC1B,MAAMC,gBAAmB,GAAA,KAAA;AAElB,MAAMC,OAAOC,MAAO,CAAAC,GAAA,EAAA;AAEpB,MAAMC,MAAMF,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAORJ,iBAAiB;AAAA;AAAA,WAExBM,YAAYC,eAAe;AAAA;AAAA;AAAA,CAAA;AAK/B,MAAMC,UAAUL,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AASvB,MAAMK,iBAAiBN,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAO9B,MAAMM,OAAOP,MAAO,CAAAC,GAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IAQvB,CAAC;EAAEO;CAAqB,KAAMA,wBAAwB,oBAAoB;AAAA,CAAA;AAGvE,MAAMC,OAAOT,MAAO,CAAAC,GAAA;AAAA,IAGvB,CAAC;EAAES;AAAA,CAAe,KAAAA,OAAA,GAAU,iBAAiB,cAAe;AAAA;AAAA;AAAA,eAGjDb,iBAAiB,MAAMC,gBAAgB;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;AAS/C,MAAMa,SAASX,MAAO,CAAAC,GAAA;AAAA;AAAA,eAEdJ,iBAAiB,MAAMC,gBAAgB;AAAA;AAAA;AAAA;AAAA;AAAA,CAAA;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export { ProductTechSpecs } from "./ProductTechSpecs";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.mjs","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
@@ -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 optionIcons = require('../../../constants/optionIcons.js');
|
|
6
6
|
var asset = require('../../../utils/asset.js');
|
|
7
7
|
require('../../ButtonGroup/index.js');
|
|
@@ -15,7 +15,7 @@ const ProductWizardOptions = function ProductWizardOptions2({
|
|
|
15
15
|
onlyIcons,
|
|
16
16
|
className
|
|
17
17
|
}) {
|
|
18
|
-
const getOptionIcon =
|
|
18
|
+
const getOptionIcon = React.useCallback((optionSlug, optionValueSlug) => {
|
|
19
19
|
const option = optionSlug.toLowerCase();
|
|
20
20
|
const value = optionValueSlug.toLowerCase();
|
|
21
21
|
const icon = optionIcons.OPTION_ICONS[option]?.[value];
|
|
@@ -24,7 +24,7 @@ const ProductWizardOptions = function ProductWizardOptions2({
|
|
|
24
24
|
}
|
|
25
25
|
return asset.imageSrc(icon);
|
|
26
26
|
}, []);
|
|
27
|
-
const getItemsWithIcons =
|
|
27
|
+
const getItemsWithIcons = React.useCallback(option => option.values.map(({
|
|
28
28
|
id,
|
|
29
29
|
title,
|
|
30
30
|
slug,
|
|
@@ -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/wizard/index.js');
|
|
6
6
|
require('../NormalisedImage/index.js');
|
|
7
7
|
require('../ProductWizardFootnotes/index.js');
|
|
@@ -43,7 +43,7 @@ const ProductWizard = function ProductWizard2({
|
|
|
43
43
|
updateQuantity,
|
|
44
44
|
translations
|
|
45
45
|
}) {
|
|
46
|
-
const addToCartBtnText =
|
|
46
|
+
const addToCartBtnText = React.useMemo(() => {
|
|
47
47
|
if (isVariantSoldOut) {
|
|
48
48
|
return translations.addToCartButton.soldOut;
|
|
49
49
|
}
|
|
@@ -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/payment-apple-pay.svg.js');
|
|
6
6
|
require('../../assets/icons/payment-card.svg.js');
|
|
7
7
|
require('../../assets/icons/payment-google-pay.svg.js');
|
|
@@ -77,7 +77,7 @@ const ProductWizardFootnotes = ({
|
|
|
77
77
|
availablePaymentMethods,
|
|
78
78
|
renderImage
|
|
79
79
|
}) => {
|
|
80
|
-
const limitErrorNode =
|
|
80
|
+
const limitErrorNode = React.useMemo(() => {
|
|
81
81
|
if (limitsDisabled) {
|
|
82
82
|
return;
|
|
83
83
|
}
|
|
@@ -101,7 +101,7 @@ const ProductWizardFootnotes = ({
|
|
|
101
101
|
}
|
|
102
102
|
return void 0;
|
|
103
103
|
}, [limitsDisabled, requiresLogin, maxRelevantLimitAddToCartQuantity, showLimitError, translations.errors.limitedToBuy, translations.errors.limitReached, translations.errors.limitErrorPer]);
|
|
104
|
-
const getCardIcons =
|
|
104
|
+
const getCardIcons = React.useCallback(() => {
|
|
105
105
|
const hasPaymentMethods = availablePaymentMethods && Object.keys(availablePaymentMethods).filter(item => {
|
|
106
106
|
return !!availablePaymentMethods[item];
|
|
107
107
|
}).length > 0;
|
|
@@ -119,7 +119,7 @@ const ProductWizardFootnotes = ({
|
|
|
119
119
|
})
|
|
120
120
|
});
|
|
121
121
|
}, [availablePaymentMethods, renderImage]);
|
|
122
|
-
const footnotes =
|
|
122
|
+
const footnotes = React.useMemo(() => /* @__PURE__ */jsxRuntime.jsxs(jsxRuntime.Fragment, {
|
|
123
123
|
children: [getCardIcons(), translations?.footnotes?.shipping?.loading ? /* @__PURE__ */jsxRuntime.jsx(ProductWizardFootnotes_styles.SkeletonFootnote, {
|
|
124
124
|
maxWidth: 120
|
|
125
125
|
}) : translations?.footnotes?.shipping?.value && /* @__PURE__ */jsxRuntime.jsxs(ProductWizardFootnotes_styles.IconTextWrap, {
|
|
@@ -144,7 +144,7 @@ const ProductWizardFootnotes = ({
|
|
|
144
144
|
})]
|
|
145
145
|
})]
|
|
146
146
|
}), [getCardIcons, translations.footnotes.shipping?.loading, translations.footnotes.shipping.value, translations.footnotes.warranty]);
|
|
147
|
-
const hasFootnotes =
|
|
147
|
+
const hasFootnotes = React.useMemo(() => !!footnotes.props.children.filter(child => !!child).length, [footnotes.props.children]);
|
|
148
148
|
if (!hasFootnotes && !enableLimitAndBackInStock && !limitErrorNode) {
|
|
149
149
|
return null;
|
|
150
150
|
}
|
|
@@ -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 theme = require('../../constants/theme.js');
|
|
6
6
|
"use strict";
|
|
7
7
|
const ProgressCircle = ({
|
|
@@ -13,9 +13,9 @@ const ProgressCircle = ({
|
|
|
13
13
|
backgroundColor = theme.theme.colors.white,
|
|
14
14
|
className
|
|
15
15
|
}) => {
|
|
16
|
-
const radius =
|
|
17
|
-
const circumference =
|
|
18
|
-
const strokeDashoffset =
|
|
16
|
+
const radius = React.useMemo(() => (diameter - strokeWidth) / 2, [diameter, strokeWidth]);
|
|
17
|
+
const circumference = React.useMemo(() => radius * 2 * Math.PI, [radius]);
|
|
18
|
+
const strokeDashoffset = React.useMemo(() => circumference - (value ? value / 100 : 0) * circumference, [circumference, value]);
|
|
19
19
|
return /* @__PURE__ */jsxRuntime.jsxs("svg", {
|
|
20
20
|
className,
|
|
21
21
|
width: diameter,
|
|
@@ -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('../Button/index.js');
|
|
6
6
|
var QuantityControls_styles = require('./QuantityControls.styles.js');
|
|
7
7
|
var CartButton = require('../Button/CartButton.js');
|
|
@@ -16,15 +16,15 @@ const QuantityControls = function QuantityControls2({
|
|
|
16
16
|
cartButton,
|
|
17
17
|
allowZero
|
|
18
18
|
}) {
|
|
19
|
-
const handleOnUpdateQuantity =
|
|
19
|
+
const handleOnUpdateQuantity = React.useCallback(e => {
|
|
20
20
|
const value = Math.max(0, parseInt(e.target.value) || 0);
|
|
21
21
|
onUpdateQuantity(value);
|
|
22
22
|
}, [onUpdateQuantity]);
|
|
23
|
-
const handleOnAddToCart =
|
|
23
|
+
const handleOnAddToCart = React.useCallback(() => {
|
|
24
24
|
if (!allowZero && quantity < 1) return;
|
|
25
25
|
onAddToCart?.();
|
|
26
26
|
}, [allowZero, onAddToCart, quantity]);
|
|
27
|
-
const cartButtonDisabled =
|
|
27
|
+
const cartButtonDisabled = React.useMemo(() => {
|
|
28
28
|
return disabled || !allowZero && quantity < 1 || cartButton?.disabled;
|
|
29
29
|
}, [allowZero, cartButton?.disabled, disabled, quantity]);
|
|
30
30
|
return /* @__PURE__ */jsxRuntime.jsxs(QuantityControls_styles.Wrap, {
|
|
@@ -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
|
}
|